From f0757ff745f28ff988066f82c04007e4a9837fd8 Mon Sep 17 00:00:00 2001 From: wp Date: Thu, 4 Jan 2018 20:03:52 +0000 Subject: [PATCH] ide: undo r56949 #20bc34c5fe, replace edit-buttons in debugger_general_options by TButton and make them square (issue #32924) git-svn-id: trunk@56955 - --- debugger/frames/debugger_general_options.lfm | 70 ++++++++++---------- debugger/frames/debugger_general_options.pas | 11 +-- 2 files changed, 36 insertions(+), 45 deletions(-) diff --git a/debugger/frames/debugger_general_options.lfm b/debugger/frames/debugger_general_options.lfm index 6a07b729bd..d2224dcdce 100644 --- a/debugger/frames/debugger_general_options.lfm +++ b/debugger/frames/debugger_general_options.lfm @@ -24,23 +24,6 @@ object DebuggerGeneralOptionsFrame: TDebuggerGeneralOptionsFrame ClientHeight = 64 ClientWidth = 515 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 AnchorSideLeft.Control = gbDebuggerType AnchorSideTop.Control = gbDebuggerType @@ -66,7 +49,7 @@ object DebuggerGeneralOptionsFrame: TDebuggerGeneralOptionsFrame Left = 6 Height = 23 Top = 35 - Width = 490 + Width = 480 Anchors = [akTop, akLeft, akRight] BorderSpacing.Left = 6 BorderSpacing.Top = 6 @@ -74,6 +57,22 @@ object DebuggerGeneralOptionsFrame: TDebuggerGeneralOptionsFrame ItemHeight = 15 TabOrder = 1 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 object gbAdditionalSearchPath: TGroupBox AnchorSideLeft.Control = Owner @@ -92,23 +91,6 @@ object DebuggerGeneralOptionsFrame: TDebuggerGeneralOptionsFrame ClientHeight = 35 ClientWidth = 515 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 AnchorSideLeft.Control = gbAdditionalSearchPath AnchorSideTop.Control = gbAdditionalSearchPath @@ -116,13 +98,29 @@ object DebuggerGeneralOptionsFrame: TDebuggerGeneralOptionsFrame Left = 6 Height = 23 Top = 6 - Width = 490 + Width = 480 Anchors = [akTop, akLeft, akRight] BorderSpacing.Left = 6 BorderSpacing.Top = 6 BorderSpacing.Bottom = 6 TabOrder = 0 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 object gcbDebuggerGeneralOptions: TCheckGroup AnchorSideLeft.Control = Owner diff --git a/debugger/frames/debugger_general_options.pas b/debugger/frames/debugger_general_options.pas index c5eb27f8ae..4ed2739698 100644 --- a/debugger/frames/debugger_general_options.pas +++ b/debugger/frames/debugger_general_options.pas @@ -38,8 +38,8 @@ type TDebuggerGeneralOptionsFrame = class(TAbstractIDEOptionsEditor) cmbDebuggerPath: TComboBox; cmbDebuggerType: TComboBox; - cmdOpenAdditionalPath: TSpeedButton; - cmdOpenDebuggerPath: TSpeedButton; + cmdOpenAdditionalPath: TButton; + cmdOpenDebuggerPath: TButton; gbAdditionalSearchPath: TGroupBox; gbDebuggerSpecific: TGroupBox; gbDebuggerType: TGroupBox; @@ -48,7 +48,6 @@ type procedure cmbDebuggerTypeEditingDone(Sender: TObject); procedure cmdOpenAdditionalPathClick(Sender: TObject); procedure cmdOpenDebuggerPathClick(Sender: TObject); - procedure ResizeSquare(Sender: TObject); private PropertyGrid: TOIPropertyGrid; FCurDebuggerClass: TDebuggerClass; // currently shown debugger class @@ -125,12 +124,6 @@ begin end; end; -procedure TDebuggerGeneralOptionsFrame.ResizeSquare(Sender: TObject); -begin - with Sender as TControl do - Constraints.MinWidth := Height; -end; - procedure TDebuggerGeneralOptionsFrame.FetchDebuggerClass; var n: PtrInt;