LCL: Try a generic solution for "WM_MOUSEWHEEL" handling. Issue #25209.

git-svn-id: trunk@47043 -
This commit is contained in:
juha 2014-12-01 08:11:04 +00:00
parent 5ae44ab904
commit 11a4692ad5

View File

@ -272,8 +272,6 @@ var
TmpSize: TSize; // used by WM_MEASUREITEM
Info: TComboboxInfo;
OrgCharCode: word; // used in WM_CHAR handling
SynapticsWindow: HWND; // used by WM_MOUSEWHEEL
SynapticsClassName: PAnsiChar; // used by WM_MOUSEWHEEL
function GetMenuParent(ASearch, AParent: HMENU): HMENU;
var
@ -1865,17 +1863,8 @@ begin
P.Y := Y;
TargetWindow := TWin32WidgetSet(WidgetSet).WindowFromPoint(P);
// For Synaptics and Lenovo (and other?) touchpad driver
SynapticsWindow := Windows.WindowFromPoint(P);
GetMem(SynapticsClassName, 50);
try
GetClassNameA(SynapticsWindow, SynapticsClassName, 50);
// Not only for Synaptics any more
//if SynapticsClassName = 'SynTrackCursorWindowClass' then
TargetWindow := Window;
finally
FreeMem(SynapticsClassName);
end;
if TargetWindow = 0 then
TargetWindow := Window;
if (TargetWindow = 0) or not IsWindowEnabled(TargetWindow) then
exit;