mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-01 21:20:28 +02:00
(Qt): error while creating popup menu
git-svn-id: trunk@11664 -
This commit is contained in:
parent
669a0e96f9
commit
0dae7e211d
@ -35,7 +35,7 @@ uses
|
||||
{$endif}
|
||||
qtwidgets, qtobjects,
|
||||
// LCL
|
||||
SysUtils, Classes, Menus, Forms, LCLType, LCLProc, Graphics,
|
||||
SysUtils, Classes, LCLType, LCLProc, Graphics, Controls, Forms, Menus,
|
||||
// Widgetset
|
||||
WSMenus, WSLCLClasses;
|
||||
|
||||
@ -384,8 +384,8 @@ begin
|
||||
end
|
||||
else if (AMenu is TPopUpMenu) then
|
||||
begin
|
||||
if AMenu.Owner <> nil then
|
||||
Parent := TQtMainWindow(TCustomForm(AMenu.Owner).Handle).Widget
|
||||
if (AMenu.Owner <> nil) and (AMenu.Owner is TWinControl) then
|
||||
Parent := TQtWidget(TWinControl(AMenu.Owner).Handle).Widget
|
||||
else
|
||||
Parent := nil;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user