mirror of
https://github.com/vim/vim.git
synced 2025-09-30 04:44:14 -04:00
patch 9.0.0597: cannot close a tab page with the middle mouse button
Problem: Cannot close a tab page with the middle mouse button. Solution: Support closing a tab page with the middle mouse button, like many other programs. (closes #10746)
This commit is contained in:
@@ -8094,6 +8094,20 @@ tabline_wndproc(
|
||||
}
|
||||
break;
|
||||
}
|
||||
case WM_MBUTTONUP:
|
||||
{
|
||||
TCHITTESTINFO htinfo;
|
||||
|
||||
htinfo.pt.x = GET_X_LPARAM(lParam);
|
||||
htinfo.pt.y = GET_Y_LPARAM(lParam);
|
||||
idx0 = TabCtrl_HitTest(hwnd, &htinfo);
|
||||
if (idx0 != -1)
|
||||
{
|
||||
idx0 += 1;
|
||||
send_tabline_menu_event(idx0, TABLINE_MENU_CLOSE);
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
Reference in New Issue
Block a user