mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-05 15:20:38 +02:00
designer: unify menu editor PopupParent/PopupMode code with r51051 #175c0031c0
git-svn-id: trunk@51052 -
This commit is contained in:
parent
175c0031c0
commit
bcca492fd6
@ -13,7 +13,7 @@ object MenuDesigner: TMenuDesigner
|
||||
OnDestroy = FormDestroy
|
||||
Position = poScreenCenter
|
||||
ShowHint = True
|
||||
LCLVersion = '1.4.4.0'
|
||||
LCLVersion = '1.7'
|
||||
object LeftPanel: TPanel
|
||||
Left = 0
|
||||
Height = 345
|
||||
|
@ -28,7 +28,7 @@ interface
|
||||
uses
|
||||
Buttons, Classes, ComponentEditors, Controls, ExtCtrls, Forms,
|
||||
Graphics, LazarusIDEStrConsts, LazIDEIntf, LCLintf, LCLProc, Menus,
|
||||
MenuShadows, PropEdits, StdCtrls, SysUtils, FormEditingIntf;
|
||||
MenuShadows, PropEdits, StdCtrls, SysUtils, FormEditingIntf, IDEWindowIntf;
|
||||
|
||||
type
|
||||
|
||||
@ -143,11 +143,7 @@ begin
|
||||
if (aMenu = nil) then
|
||||
RaiseGDBException(lisMenuEditorShowMenuEditorTMenuParameterIsNil);
|
||||
MenuDesigner.SetMenu(aMenu, nil);
|
||||
MenuDesigner.PopupParent:=GetParentForm(FormEditingHook.GetCurrentObjectInspector, True);
|
||||
if MenuDesigner.PopupParent<>nil then
|
||||
MenuDesigner.PopupMode:=pmExplicit
|
||||
else
|
||||
MenuDesigner.PopupMode:=pmNone;
|
||||
SetPopupModeParentForPropertyEditor(MenuDesigner);
|
||||
MenuDesigner.ShowOnTop;
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user