mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-31 17:20:37 +02:00
anchordocking: disable header options when no headers shown
git-svn-id: trunk@46608 -
This commit is contained in:
parent
23d96e97a5
commit
b516c61568
@ -183,6 +183,7 @@ object AnchorDockOptionsFrame: TAnchorDockOptionsFrame
|
||||
Top = 227
|
||||
Width = 149
|
||||
Caption = 'ShowHeaderCheckBox'
|
||||
OnChange = ShowHeaderCheckBoxChange
|
||||
ParentShowHint = False
|
||||
ShowHint = True
|
||||
TabOrder = 7
|
||||
|
@ -71,6 +71,7 @@ type
|
||||
procedure DragThresholdTrackBarChange(Sender: TObject);
|
||||
procedure HeaderAlignLeftTrackBarChange(Sender: TObject);
|
||||
procedure HeaderAlignTopTrackBarChange(Sender: TObject);
|
||||
procedure ShowHeaderCheckBoxChange(Sender: TObject);
|
||||
procedure SplitterWidthTrackBarChange(Sender: TObject);
|
||||
private
|
||||
FFlags: TAnchorDockOptionsFlags;
|
||||
@ -141,6 +142,11 @@ begin
|
||||
UpdateHeaderAlignTopLabel;
|
||||
end;
|
||||
|
||||
procedure TAnchorDockOptionsFrame.ShowHeaderCheckBoxChange(Sender: TObject);
|
||||
begin
|
||||
ApplyFlags;
|
||||
end;
|
||||
|
||||
procedure TAnchorDockOptionsFrame.SplitterWidthTrackBarChange(Sender: TObject);
|
||||
begin
|
||||
UpdateSplitterWidthLabel;
|
||||
@ -218,9 +224,17 @@ begin
|
||||
end;
|
||||
|
||||
procedure TAnchorDockOptionsFrame.ApplyFlags;
|
||||
var
|
||||
HasHeaders: Boolean;
|
||||
begin
|
||||
ShowHeaderCheckBox.Visible:=adofShow_ShowHeader in Flags;
|
||||
SaveLayoutOnCloseCheckBox.Visible:=adofShow_ShowSaveOnClose in Flags;
|
||||
|
||||
HasHeaders:=ShowHeaderCheckBox.Checked;
|
||||
ShowHeaderCaptionCheckBox.Enabled:=HasHeaders;
|
||||
HideHeaderCaptionForFloatingCheckBox.Enabled:=HasHeaders;
|
||||
FlattenHeaders.Enabled:=HasHeaders;
|
||||
FilledHeaders.Enabled:=HasHeaders;
|
||||
end;
|
||||
|
||||
procedure TAnchorDockOptionsFrame.SaveToMaster;
|
||||
|
Loading…
Reference in New Issue
Block a user