mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-10 05:16:48 +02:00
win32 interface: fixed scroll wheel message in a listbox (bug #9018)
git-svn-id: trunk@11294 -
This commit is contained in:
parent
ba3e478722
commit
b3246f94ce
@ -1607,17 +1607,13 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
// the mousewheel message is for us
|
// the mousewheel message is for us
|
||||||
// windows handles combobox's mousewheel messages
|
Msg := LM_MOUSEWHEEL;
|
||||||
if (lWinControl=nil) or (lWinControl.FCompStyle <> csComboBox) then
|
Button := LOWORD(WParam);
|
||||||
begin
|
WheelDelta := SmallInt(HIWORD(WParam));
|
||||||
Msg := LM_MOUSEWHEEL;
|
State := GetShiftState;
|
||||||
Button := LOWORD(WParam);
|
Result := 0;
|
||||||
WheelDelta := SmallInt(HIWORD(WParam));
|
UserData := Pointer(GetWindowLong(Window, GWL_USERDATA));
|
||||||
State := GetShiftState;
|
WinProcess := false;
|
||||||
Result := 0;
|
|
||||||
UserData := Pointer(GetWindowLong(Window, GWL_USERDATA));
|
|
||||||
WinProcess := false;
|
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
{$IFDEF EnableWMDropFiles}
|
{$IFDEF EnableWMDropFiles}
|
||||||
|
@ -161,6 +161,13 @@ var
|
|||||||
if not TWinControl(Sender).HandleAllocated then
|
if not TWinControl(Sender).HandleAllocated then
|
||||||
exit;
|
exit;
|
||||||
|
|
||||||
|
with TLMessage(Message) do begin
|
||||||
|
Result := CallDefaultWindowProc(Handle, Msg, WParam, LParam);
|
||||||
|
// Windows handled it, so exit here.
|
||||||
|
if Result<>0 then exit;
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
// send scroll message
|
// send scroll message
|
||||||
FillChar(ScrollInfo, sizeof(ScrollInfo), #0);
|
FillChar(ScrollInfo, sizeof(ScrollInfo), #0);
|
||||||
ScrollInfo.cbSize := sizeof(ScrollInfo);
|
ScrollInfo.cbSize := sizeof(ScrollInfo);
|
||||||
|
Loading…
Reference in New Issue
Block a user