From 27d7dc544871200d2d33f206f0db5fdb5e5957f2 Mon Sep 17 00:00:00 2001 From: mattias Date: Wed, 26 Feb 2014 08:51:28 +0000 Subject: [PATCH] IDEIntf: less unit dependencies, less hints, fixed passing AsLast git-svn-id: trunk@44243 - --- components/ideintf/idecommands.pas | 6 +----- components/ideintf/idemsgintf.pas | 2 +- components/ideintf/menuintf.pas | 6 +++--- components/ideintf/srceditorintf.pas | 8 ++++---- 4 files changed, 9 insertions(+), 13 deletions(-) diff --git a/components/ideintf/idecommands.pas b/components/ideintf/idecommands.pas index 18df6d726b..ba73723410 100644 --- a/components/ideintf/idecommands.pas +++ b/components/ideintf/idecommands.pas @@ -30,7 +30,7 @@ unit IDECommands; interface uses - Classes, SysUtils, LCLProc, Forms, LCLType, Menus, PropEdits, TextTools; + Classes, SysUtils, LCLProc, Forms, LCLType, Menus, PropEdits; const { editor commands constants. see syneditkeycmds.pp for more @@ -1571,15 +1571,11 @@ const ); function IdentToIDECommand(const Ident: string; var Cmd: longint): boolean; -var - IDECommand: TIDECommand; begin Result := IdentToInt(Ident, Cmd, IDEEditorCommandStrs); end; function IDECommandToIdent(Cmd: longint; var Ident: string): boolean; -var - IDECommand: TIDECommand; begin Result := IntToIdent(Cmd, Ident, IDEEditorCommandStrs); end; diff --git a/components/ideintf/idemsgintf.pas b/components/ideintf/idemsgintf.pas index 76f2abe73a..027eabb040 100644 --- a/components/ideintf/idemsgintf.pas +++ b/components/ideintf/idemsgintf.pas @@ -211,7 +211,7 @@ end; uses Classes, SysUtils, Forms, LCLProc, - TextTools, IDECommands, IDEExternToolIntf; + TextTools, IDECommands; type diff --git a/components/ideintf/menuintf.pas b/components/ideintf/menuintf.pas index da4ec06073..c6ba0e5ed0 100644 --- a/components/ideintf/menuintf.pas +++ b/components/ideintf/menuintf.pas @@ -18,7 +18,7 @@ unit MenuIntf; interface uses - Classes, SysUtils, LCLType, LCLProc, Menus, ImgList, Graphics, LazHelpIntf, + Classes, SysUtils, LCLType, LCLProc, Menus, ImgList, Graphics, IDECommands, IDEImagesIntf; type @@ -1509,7 +1509,7 @@ end; procedure TIDEMenuSection.AddHandlerOnShow(const OnShowEvent: TNotifyEvent; AsLast: boolean); begin - AddHandler(imshtOnShow,TMethod(OnShowEvent)); + AddHandler(imshtOnShow,TMethod(OnShowEvent),AsLast); end; procedure TIDEMenuSection.RemoveHandlerOnShow(const OnShowEvent: TNotifyEvent); @@ -1585,7 +1585,7 @@ procedure TIDEMenuSection.AddHandler(HandlerType: TIDEMenuSectionHandlerType; begin if FSectionHandlers[HandlerType]=nil then FSectionHandlers[HandlerType]:=TMethodList.Create; - FSectionHandlers[HandlerType].Add(AMethod); + FSectionHandlers[HandlerType].Add(AMethod,AsLast); end; procedure TIDEMenuSection.RemoveHandler( diff --git a/components/ideintf/srceditorintf.pas b/components/ideintf/srceditorintf.pas index bd5917c2ee..6705a1112a 100644 --- a/components/ideintf/srceditorintf.pas +++ b/components/ideintf/srceditorintf.pas @@ -190,10 +190,10 @@ type procedure CompletePrefix(var Prefix: string); virtual; abstract; function HasCustomPaint: boolean; virtual; - procedure PaintItem(const AKey: string; ACanvas: TCanvas; - X, Y: integer; ItemSelected: boolean; Index: integer); virtual; - function MeasureItem(const AKey: string; ACanvas: TCanvas; - ItemSelected: boolean; Index: integer): TPoint; virtual; + procedure PaintItem(const {%H-}AKey: string; {%H-}ACanvas: TCanvas; + {%H-}X, {%H-}Y: integer; {%H-}ItemSelected: boolean; {%H-}Index: integer); virtual; + function MeasureItem(const {%H-}AKey: string; {%H-}ACanvas: TCanvas; + {%H-}ItemSelected: boolean; {%H-}Index: integer): TPoint; virtual; end; { TSourceEditorWindowInterface }