IDE: Do not trigger palette update with OnComponentVisibleChanged and OnPageVisibleChanged events. Will be triggered by other means.

git-svn-id: trunk@47140 -
This commit is contained in:
juha 2014-12-08 20:22:31 +00:00
parent 4a8e3ccc51
commit cfdbbbb410
3 changed files with 11 additions and 11 deletions

View File

@ -229,7 +229,7 @@ type
function FindButton(Button: TComponent): TRegisteredComponent; function FindButton(Button: TComponent): TRegisteredComponent;
function CreateNewClassName(const Prefix: string): string; function CreateNewClassName(const Prefix: string): string;
function IndexOfPageComponent(AComponent: TComponent): integer; function IndexOfPageComponent(AComponent: TComponent): integer;
procedure Update; virtual; procedure Update; virtual; abstract;
procedure IterateRegisteredClasses(Proc: TGetComponentClassEvent); procedure IterateRegisteredClasses(Proc: TGetComponentClassEvent);
procedure RegisterCustomIDEComponents( procedure RegisterCustomIDEComponents(
const RegisterProc: RegisterUnitComponentProc); virtual; abstract; const RegisterProc: RegisterUnitComponentProc); virtual; abstract;
@ -669,17 +669,12 @@ end;
procedure TBaseComponentPalette.OnComponentVisibleChanged(AComponent: TRegisteredComponent); procedure TBaseComponentPalette.OnComponentVisibleChanged(AComponent: TRegisteredComponent);
begin begin
DoChange; ;
end; end;
procedure TBaseComponentPalette.OnPageVisibleChanged(APage: TBaseComponentPage); procedure TBaseComponentPalette.OnPageVisibleChanged(APage: TBaseComponentPage);
begin begin
DoChange; ;
end;
procedure TBaseComponentPalette.Update;
begin
end; end;
function TBaseComponentPalette.VoteCompVisibility(AComponent: TRegisteredComponent): Boolean; function TBaseComponentPalette.VoteCompVisibility(AComponent: TRegisteredComponent): Boolean;

View File

@ -2939,7 +2939,12 @@ begin
LM_MOUSEMOVE: MouseMoveOnControl(Sender, TLMMouse(TheMessage)); LM_MOUSEMOVE: MouseMoveOnControl(Sender, TLMMouse(TheMessage));
LM_SIZE: Result:=SizeControl(Sender, TLMSize(TheMessage)); LM_SIZE: Result:=SizeControl(Sender, TLMSize(TheMessage));
LM_MOVE: Result:=MoveControl(Sender, TLMMove(TheMessage)); LM_MOVE: Result:=MoveControl(Sender, TLMMove(TheMessage));
LM_ACTIVATE: Result:=DoFormActivated(TLMActivate(TheMessage).Active=WA_ACTIVE); LM_ACTIVATE: begin
{$IFDEF VerboseComponentPalette}
DebugLn('TDesigner.IsDesignMsg: Got LM_ACTIVATE message.');
{$ENDIF}
Result:=DoFormActivated(TLMActivate(TheMessage).Active=WA_ACTIVE);
end;
LM_CLOSEQUERY: Result:=DoFormCloseQuery; LM_CLOSEQUERY: Result:=DoFormCloseQuery;
LM_SETCURSOR: Result:=HandleSetCursor(TheMessage); LM_SETCURSOR: Result:=HandleSetCursor(TheMessage);
LM_CONTEXTMENU: HandlePopupMenu(Sender, TLMContextMenu(TheMessage)); LM_CONTEXTMENU: HandlePopupMenu(Sender, TLMContextMenu(TheMessage));

View File

@ -966,9 +966,9 @@ end;
procedure TComponentPalette.Update; procedure TComponentPalette.Update;
begin begin
inherited Update;
{$IFDEF VerboseComponentPalette} {$IFDEF VerboseComponentPalette}
DebugLn('TComponentPalette.Update, calling UpdateNoteBookButtons'); DebugLn(['TComponentPalette.Update, calling UpdateNoteBookButtons, fUpdatingPageControl=',
fUpdatingPageControl, ', fNoteBookNeedsUpdate=', fNoteBookNeedsUpdate]);
{$ENDIF} {$ENDIF}
UpdateNoteBookButtons; UpdateNoteBookButtons;
end; end;