mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-16 20:49:24 +02:00
DockedFormEditor: fix "cannot focus an inactive window" if showing source-edit hidden in tabbed anchor-docking.
(double click button, while source-edit is cloned to 2nd source-edit, docked into same main window but hidden in nested anchor tabs)
This commit is contained in:
parent
708f754935
commit
20929d2f06
@ -239,6 +239,7 @@ var
|
|||||||
begin
|
begin
|
||||||
{$IFDEF DEBUGDOCKEDFORMEDITOR} DebugLn('TDockedTabMaster.ShowCode'); {$ENDIF}
|
{$IFDEF DEBUGDOCKEDFORMEDITOR} DebugLn('TDockedTabMaster.ShowCode'); {$ENDIF}
|
||||||
if ASourceEditor = nil then Exit;
|
if ASourceEditor = nil then Exit;
|
||||||
|
SourceEditorManagerIntf.ActiveEditor := ASourceEditor;
|
||||||
LPageCtrl := SourceWindows.FindPageControl(ASourceEditor);
|
LPageCtrl := SourceWindows.FindPageControl(ASourceEditor);
|
||||||
LPageCtrl.ShowCode;
|
LPageCtrl.ShowCode;
|
||||||
ASourceEditor.EditorControl.SetFocus;
|
ASourceEditor.EditorControl.SetFocus;
|
||||||
@ -250,6 +251,7 @@ var
|
|||||||
begin
|
begin
|
||||||
{$IFDEF DEBUGDOCKEDFORMEDITOR} DebugLn('TDockedTabMaster.ShowDesigner'); {$ENDIF}
|
{$IFDEF DEBUGDOCKEDFORMEDITOR} DebugLn('TDockedTabMaster.ShowDesigner'); {$ENDIF}
|
||||||
if ASourceEditor = nil then Exit;
|
if ASourceEditor = nil then Exit;
|
||||||
|
SourceEditorManagerIntf.ActiveEditor := ASourceEditor;
|
||||||
LPageCtrl := SourceWindows.FindPageControl(ASourceEditor);
|
LPageCtrl := SourceWindows.FindPageControl(ASourceEditor);
|
||||||
LPageCtrl.ShowDesigner(AIndex);
|
LPageCtrl.ShowDesigner(AIndex);
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user