Skip to content
Snippets Groups Projects
Commit 4a94d09a authored by Mikołaj Zalewski's avatar Mikołaj Zalewski Committed by Alexandre Julliard
Browse files

wineconsole: Allow making selections with a mouse also when not in the QuickEdit mode.

parent c52238d6
No related branches found
No related tags found
No related merge requests found
......@@ -1116,12 +1116,14 @@ static LRESULT CALLBACK WCUSER_Proc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM
WCUSER_GenerateKeyInputRecord(data, uMsg == WM_SYSKEYDOWN, wParam, lParam, TRUE);
break;
case WM_LBUTTONDOWN:
if (data->curcfg.quick_edit)
if (data->curcfg.quick_edit || PRIVATE(data)->has_selection)
{
if (PRIVATE(data)->has_selection)
WCUSER_SetSelection(data, 0);
if (data->curcfg.quick_edit && PRIVATE(data)->has_selection)
{
PRIVATE(data)->has_selection = FALSE;
WCUSER_SetSelection(data, 0);
}
else
{
......@@ -1137,7 +1139,7 @@ static LRESULT CALLBACK WCUSER_Proc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM
}
break;
case WM_MOUSEMOVE:
if (data->curcfg.quick_edit)
if (data->curcfg.quick_edit || PRIVATE(data)->has_selection)
{
if (GetCapture() == PRIVATE(data)->hWnd && PRIVATE(data)->has_selection &&
(wParam & MK_LBUTTON))
......@@ -1151,14 +1153,12 @@ static LRESULT CALLBACK WCUSER_Proc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM
}
break;
case WM_LBUTTONUP:
if (data->curcfg.quick_edit)
if (data->curcfg.quick_edit || PRIVATE(data)->has_selection)
{
if (GetCapture() == PRIVATE(data)->hWnd && PRIVATE(data)->has_selection &&
(wParam& MK_LBUTTON))
if (GetCapture() == PRIVATE(data)->hWnd && PRIVATE(data)->has_selection)
{
WCUSER_MoveSelection(data, PRIVATE(data)->selectPt1, WCUSER_GetCell(data, lParam));
ReleaseCapture();
PRIVATE(data)->has_selection = FALSE;
}
}
else
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment