mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-12-06 17:47:26 +01:00
Qt: fixed crash with QTSCROLLABLEFORMS define under MacOSX.
git-svn-id: trunk@45008 -
This commit is contained in:
parent
d57cd64ddb
commit
c6cd3f4538
@ -8,7 +8,5 @@
|
||||
{$IF DEFINED(DARWIN) AND DEFINED(CPU64)}
|
||||
{$DEFINE QTCOCOA}
|
||||
{$ENDIF}
|
||||
{$IFNDEF QTCOCOA}
|
||||
{$DEFINE QTSCROLLABLEFORMS}
|
||||
{$ENDIF}
|
||||
{$ENDIF}
|
||||
|
||||
@ -3806,8 +3806,14 @@ begin
|
||||
Msg.WheelDelta := -1;
|
||||
Msg.WheelDelta := (120 * Msg.WheelDelta) div Mouse.WheelScrollLines;
|
||||
if FOwner <> nil then
|
||||
CCtl := TQtAbstractScrollArea(FOwner)
|
||||
else
|
||||
begin
|
||||
{$IFDEF QTSCROLLABLEFORMS}
|
||||
if (FOwner is TQtMainWindow) then
|
||||
CCtl := TQtMainWindow(FOwner).ScrollArea
|
||||
else
|
||||
{$ENDIF}
|
||||
CCtl := TQtAbstractScrollArea(FOwner);
|
||||
end else
|
||||
CCtl := TQtAbstractScrollArea(Self);
|
||||
//now fix ugly behaviour.
|
||||
if (Msg.WheelDelta > 0) and (CCtl.FVScrollbar.getVisible) and
|
||||
|
||||
Loading…
Reference in New Issue
Block a user