ide: undo r56949 #20bc34c5fe, replace edit-buttons in debugger_general_options by TButton and make them square (issue #32924)

git-svn-id: trunk@56955 -
This commit is contained in:
wp 2018-01-04 20:03:52 +00:00
parent 375c1edea3
commit f0757ff745
2 changed files with 36 additions and 45 deletions

View File

@ -24,23 +24,6 @@ object DebuggerGeneralOptionsFrame: TDebuggerGeneralOptionsFrame
ClientHeight = 64 ClientHeight = 64
ClientWidth = 515 ClientWidth = 515
TabOrder = 0 TabOrder = 0
object cmdOpenDebuggerPath: TSpeedButton
AnchorSideTop.Control = cmbDebuggerPath
AnchorSideRight.Control = gbDebuggerType
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = cmbDebuggerPath
AnchorSideBottom.Side = asrBottom
Left = 496
Height = 23
Top = 35
Width = 13
Anchors = [akTop, akRight, akBottom]
AutoSize = True
BorderSpacing.Right = 6
Caption = '…'
OnClick = cmdOpenDebuggerPathClick
OnResize = ResizeSquare
end
object cmbDebuggerType: TComboBox object cmbDebuggerType: TComboBox
AnchorSideLeft.Control = gbDebuggerType AnchorSideLeft.Control = gbDebuggerType
AnchorSideTop.Control = gbDebuggerType AnchorSideTop.Control = gbDebuggerType
@ -66,7 +49,7 @@ object DebuggerGeneralOptionsFrame: TDebuggerGeneralOptionsFrame
Left = 6 Left = 6
Height = 23 Height = 23
Top = 35 Top = 35
Width = 490 Width = 480
Anchors = [akTop, akLeft, akRight] Anchors = [akTop, akLeft, akRight]
BorderSpacing.Left = 6 BorderSpacing.Left = 6
BorderSpacing.Top = 6 BorderSpacing.Top = 6
@ -74,6 +57,22 @@ object DebuggerGeneralOptionsFrame: TDebuggerGeneralOptionsFrame
ItemHeight = 15 ItemHeight = 15
TabOrder = 1 TabOrder = 1
end end
object cmdOpenDebuggerPath: TButton
AnchorSideTop.Control = cmbDebuggerPath
AnchorSideRight.Control = gbDebuggerType
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = cmbDebuggerPath
AnchorSideBottom.Side = asrBottom
Left = 486
Height = 23
Top = 35
Width = 23
Anchors = [akTop, akRight, akBottom]
BorderSpacing.Right = 6
Caption = '…'
OnClick = cmdOpenDebuggerPathClick
TabOrder = 2
end
end end
object gbAdditionalSearchPath: TGroupBox object gbAdditionalSearchPath: TGroupBox
AnchorSideLeft.Control = Owner AnchorSideLeft.Control = Owner
@ -92,23 +91,6 @@ object DebuggerGeneralOptionsFrame: TDebuggerGeneralOptionsFrame
ClientHeight = 35 ClientHeight = 35
ClientWidth = 515 ClientWidth = 515
TabOrder = 1 TabOrder = 1
object cmdOpenAdditionalPath: TSpeedButton
AnchorSideTop.Control = txtAdditionalPath
AnchorSideRight.Control = gbAdditionalSearchPath
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = txtAdditionalPath
AnchorSideBottom.Side = asrBottom
Left = 496
Height = 23
Top = 6
Width = 13
Anchors = [akTop, akRight, akBottom]
AutoSize = True
BorderSpacing.Right = 6
Caption = '…'
OnClick = cmdOpenAdditionalPathClick
OnResize = ResizeSquare
end
object txtAdditionalPath: TEdit object txtAdditionalPath: TEdit
AnchorSideLeft.Control = gbAdditionalSearchPath AnchorSideLeft.Control = gbAdditionalSearchPath
AnchorSideTop.Control = gbAdditionalSearchPath AnchorSideTop.Control = gbAdditionalSearchPath
@ -116,13 +98,29 @@ object DebuggerGeneralOptionsFrame: TDebuggerGeneralOptionsFrame
Left = 6 Left = 6
Height = 23 Height = 23
Top = 6 Top = 6
Width = 490 Width = 480
Anchors = [akTop, akLeft, akRight] Anchors = [akTop, akLeft, akRight]
BorderSpacing.Left = 6 BorderSpacing.Left = 6
BorderSpacing.Top = 6 BorderSpacing.Top = 6
BorderSpacing.Bottom = 6 BorderSpacing.Bottom = 6
TabOrder = 0 TabOrder = 0
end end
object cmdOpenAdditionalPath: TButton
AnchorSideTop.Control = txtAdditionalPath
AnchorSideRight.Control = gbAdditionalSearchPath
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = txtAdditionalPath
AnchorSideBottom.Side = asrBottom
Left = 486
Height = 23
Top = 6
Width = 23
Anchors = [akTop, akRight, akBottom]
BorderSpacing.Right = 6
Caption = '…'
OnClick = cmdOpenAdditionalPathClick
TabOrder = 1
end
end end
object gcbDebuggerGeneralOptions: TCheckGroup object gcbDebuggerGeneralOptions: TCheckGroup
AnchorSideLeft.Control = Owner AnchorSideLeft.Control = Owner

View File

@ -38,8 +38,8 @@ type
TDebuggerGeneralOptionsFrame = class(TAbstractIDEOptionsEditor) TDebuggerGeneralOptionsFrame = class(TAbstractIDEOptionsEditor)
cmbDebuggerPath: TComboBox; cmbDebuggerPath: TComboBox;
cmbDebuggerType: TComboBox; cmbDebuggerType: TComboBox;
cmdOpenAdditionalPath: TSpeedButton; cmdOpenAdditionalPath: TButton;
cmdOpenDebuggerPath: TSpeedButton; cmdOpenDebuggerPath: TButton;
gbAdditionalSearchPath: TGroupBox; gbAdditionalSearchPath: TGroupBox;
gbDebuggerSpecific: TGroupBox; gbDebuggerSpecific: TGroupBox;
gbDebuggerType: TGroupBox; gbDebuggerType: TGroupBox;
@ -48,7 +48,6 @@ type
procedure cmbDebuggerTypeEditingDone(Sender: TObject); procedure cmbDebuggerTypeEditingDone(Sender: TObject);
procedure cmdOpenAdditionalPathClick(Sender: TObject); procedure cmdOpenAdditionalPathClick(Sender: TObject);
procedure cmdOpenDebuggerPathClick(Sender: TObject); procedure cmdOpenDebuggerPathClick(Sender: TObject);
procedure ResizeSquare(Sender: TObject);
private private
PropertyGrid: TOIPropertyGrid; PropertyGrid: TOIPropertyGrid;
FCurDebuggerClass: TDebuggerClass; // currently shown debugger class FCurDebuggerClass: TDebuggerClass; // currently shown debugger class
@ -125,12 +124,6 @@ begin
end; end;
end; end;
procedure TDebuggerGeneralOptionsFrame.ResizeSquare(Sender: TObject);
begin
with Sender as TControl do
Constraints.MinWidth := Height;
end;
procedure TDebuggerGeneralOptionsFrame.FetchDebuggerClass; procedure TDebuggerGeneralOptionsFrame.FetchDebuggerClass;
var var
n: PtrInt; n: PtrInt;