Skip to content

Commit

Permalink
Fixed hint
Browse files Browse the repository at this point in the history
  • Loading branch information
davidberneda committed Oct 27, 2023
1 parent 23626cd commit 9172c57
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ object LockedColumnsForm: TLockedColumnsForm
DesignerMasterStyle = 0
object TeeGrid1: TTeeGrid
Columns = <>
ReadOnly = False
CellFormat = <>
Align = Client
Size.Width = 640.000000000000000000
Size.Height = 351.000000000000000000
Expand Down Expand Up @@ -49,6 +49,7 @@ object LockedColumnsForm: TLockedColumnsForm
Size.PlatformDefault = False
StyleLookup = 'segmentedbuttonmiddle'
Text = 'Left'
TextSettings.Trimming = None
OnClick = BNoneClick
end
object BNone: TSpeedButton
Expand All @@ -62,6 +63,7 @@ object LockedColumnsForm: TLockedColumnsForm
Size.PlatformDefault = False
StyleLookup = 'segmentedbuttonleft'
Text = 'None'
TextSettings.Trimming = None
OnClick = BNoneClick
end
object BRight: TSpeedButton
Expand All @@ -74,13 +76,15 @@ object LockedColumnsForm: TLockedColumnsForm
Size.PlatformDefault = False
StyleLookup = 'segmentedbuttonright'
Text = 'Right'
TextSettings.Trimming = None
OnClick = BNoneClick
end
object Label1: TLabel
StyledSettings = [Family, Size, Style]
Position.X = 8.000000000000000000
Position.Y = 6.000000000000000000
TextSettings.FontColor = claWhite
TextSettings.Trimming = None
Text = 'Columns :'
TabOrder = 3
end
Expand All @@ -89,6 +93,7 @@ object LockedColumnsForm: TLockedColumnsForm
Position.X = 191.000000000000000000
Position.Y = 6.000000000000000000
TextSettings.FontColor = claWhite
TextSettings.Trimming = None
Text = 'Locked :'
TabOrder = 4
end
Expand Down
14 changes: 9 additions & 5 deletions demos/FireMonkey/TeeGridFeatures/Views/Unit_Locked_Columns.pas
Original file line number Diff line number Diff line change
Expand Up @@ -102,11 +102,15 @@ procedure TLockedColumnsForm.BNoneClick(Sender: TObject);
Column:=TeeGrid1.Columns[LBColumns.ItemIndex];

if BNone.IsPressed then
Locked:=TColumnLocked(0)
else if BLeft.IsPressed then
Locked:=TColumnLocked(1)
else if BRight.IsPressed then
Locked:=TColumnLocked(2);
Locked:=TColumnLocked.None
else
if BLeft.IsPressed then
Locked:=TColumnLocked.Left
else
if BRight.IsPressed then
Locked:=TColumnLocked.Right
else
Locked:=TColumnLocked.None;

SetLocked(Column,Locked);
end;
Expand Down

0 comments on commit 9172c57

Please sign in to comment.