mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-13 12:59:19 +02:00
improved useability of view project units dialog (issue #1611) from Darius
git-svn-id: trunk@8535 -
This commit is contained in:
parent
8e0de71ba9
commit
65f3a8f2e1
@ -1,20 +1,22 @@
|
||||
object ViewUnitDialog: TViewUnitDialog
|
||||
ActiveControl = Listbox
|
||||
Caption = 'View Project Units'
|
||||
ClientHeight = 204
|
||||
ClientHeight = 213
|
||||
ClientWidth = 416
|
||||
PixelsPerInch = 96
|
||||
Position = poScreenCenter
|
||||
HorzScrollBar.Page = 415
|
||||
VertScrollBar.Page = 203
|
||||
VertScrollBar.Page = 212
|
||||
Left = 337
|
||||
Height = 204
|
||||
Height = 213
|
||||
Top = 295
|
||||
Width = 416
|
||||
object btnOK: TButton
|
||||
Anchors = [akTop, akRight]
|
||||
BorderSpacing.InnerBorder = 2
|
||||
Caption = 'OK'
|
||||
OnClick = BTNOKCLICK
|
||||
TabOrder = 0
|
||||
TabOrder = 1
|
||||
Left = 312
|
||||
Height = 25
|
||||
Top = 10
|
||||
@ -22,9 +24,10 @@ object ViewUnitDialog: TViewUnitDialog
|
||||
end
|
||||
object btnCancel: TButton
|
||||
Anchors = [akTop, akRight]
|
||||
BorderSpacing.InnerBorder = 2
|
||||
Caption = 'Cancel'
|
||||
OnClick = BTNCANCELCLICK
|
||||
TabOrder = 1
|
||||
TabOrder = 2
|
||||
Left = 312
|
||||
Height = 25
|
||||
Top = 45
|
||||
@ -33,7 +36,7 @@ object ViewUnitDialog: TViewUnitDialog
|
||||
object Edit: TEdit
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
Enabled = False
|
||||
TabOrder = 2
|
||||
TabOrder = 3
|
||||
Left = 10
|
||||
Height = 25
|
||||
Top = 10
|
||||
@ -43,9 +46,10 @@ object ViewUnitDialog: TViewUnitDialog
|
||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||
ClickOnSelChange = False
|
||||
OnDblClick = BTNOKCLICK
|
||||
TabOrder = 3
|
||||
OnKeyDown = ListboxKeyDown
|
||||
TabOrder = 0
|
||||
Left = 10
|
||||
Height = 147
|
||||
Height = 156
|
||||
Top = 45
|
||||
Width = 294
|
||||
end
|
||||
@ -54,9 +58,9 @@ object ViewUnitDialog: TViewUnitDialog
|
||||
Caption = 'Multi Select'
|
||||
OnClick = MultiselectCheckBoxClick
|
||||
TabOrder = 4
|
||||
Left = 315
|
||||
Height = 24
|
||||
Left = 312
|
||||
Height = 13
|
||||
Top = 100
|
||||
Width = 90
|
||||
Width = 75
|
||||
end
|
||||
end
|
||||
|
@ -1,21 +1,23 @@
|
||||
{ This is an automatically generated lazarus resource file }
|
||||
|
||||
LazarusResources.Add('TViewUnitDialog','FORMDATA',[
|
||||
'TPF0'#15'TViewUnitDialog'#14'ViewUnitDialog'#7'Caption'#6#18'View Project Un'
|
||||
+'its'#12'ClientHeight'#3#204#0#11'ClientWidth'#3#160#1#13'PixelsPerInch'#2'`'
|
||||
+#8'Position'#7#14'poScreenCenter'#18'HorzScrollBar.Page'#3#159#1#18'VertScro'
|
||||
+'llBar.Page'#3#203#0#4'Left'#3'Q'#1#6'Height'#3#204#0#3'Top'#3''''#1#5'Width'
|
||||
+#3#160#1#0#7'TButton'#5'btnOK'#7'Anchors'#11#5'akTop'#7'akRight'#0#7'Caption'
|
||||
+#6#2'OK'#7'OnClick'#7#10'BTNOKCLICK'#8'TabOrder'#2#0#4'Left'#3'8'#1#6'Height'
|
||||
+#2#25#3'Top'#2#10#5'Width'#2'`'#0#0#7'TButton'#9'btnCancel'#7'Anchors'#11#5
|
||||
+'akTop'#7'akRight'#0#7'Caption'#6#6'Cancel'#7'OnClick'#7#14'BTNCANCELCLICK'#8
|
||||
+'TabOrder'#2#1#4'Left'#3'8'#1#6'Height'#2#25#3'Top'#2'-'#5'Width'#2'`'#0#0#5
|
||||
+'TEdit'#4'Edit'#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRight'#0#7'Enabled'#8#8
|
||||
+'TabOrder'#2#2#4'Left'#2#10#6'Height'#2#25#3'Top'#2#10#5'Width'#3'&'#1#0#0#8
|
||||
+'TListBox'#7'Listbox'#7'Anchors'#11#5'akTop'#6'akLeft'#7'akRight'#8'akBottom'
|
||||
+#0#16'ClickOnSelChange'#8#10'OnDblClick'#7#10'BTNOKCLICK'#8'TabOrder'#2#3#4
|
||||
+'Left'#2#10#6'Height'#3#147#0#3'Top'#2'-'#5'Width'#3'&'#1#0#0#9'TCheckBox'#19
|
||||
+'MultiSelectCheckBox'#7'Anchors'#11#5'akTop'#7'akRight'#0#7'Caption'#6#12'Mu'
|
||||
+'lti Select'#7'OnClick'#7#24'MultiselectCheckBoxClick'#8'TabOrder'#2#4#4'Lef'
|
||||
+'t'#3';'#1#6'Height'#2#24#3'Top'#2'd'#5'Width'#2'Z'#0#0#0
|
||||
'TPF0'#15'TViewUnitDialog'#14'ViewUnitDialog'#13'ActiveControl'#7#7'Listbox'#7
|
||||
+'Caption'#6#18'View Project Units'#12'ClientHeight'#3#213#0#11'ClientWidth'#3
|
||||
+#160#1#13'PixelsPerInch'#2'`'#8'Position'#7#14'poScreenCenter'#18'HorzScroll'
|
||||
+'Bar.Page'#3#159#1#18'VertScrollBar.Page'#3#212#0#4'Left'#3'Q'#1#6'Height'#3
|
||||
+#213#0#3'Top'#3''''#1#5'Width'#3#160#1#0#7'TButton'#5'btnOK'#7'Anchors'#11#5
|
||||
+'akTop'#7'akRight'#0#25'BorderSpacing.InnerBorder'#2#2#7'Caption'#6#2'OK'#7
|
||||
+'OnClick'#7#10'BTNOKCLICK'#8'TabOrder'#2#1#4'Left'#3'8'#1#6'Height'#2#25#3'T'
|
||||
+'op'#2#10#5'Width'#2'`'#0#0#7'TButton'#9'btnCancel'#7'Anchors'#11#5'akTop'#7
|
||||
+'akRight'#0#25'BorderSpacing.InnerBorder'#2#2#7'Caption'#6#6'Cancel'#7'OnCli'
|
||||
+'ck'#7#14'BTNCANCELCLICK'#8'TabOrder'#2#2#4'Left'#3'8'#1#6'Height'#2#25#3'To'
|
||||
+'p'#2'-'#5'Width'#2'`'#0#0#5'TEdit'#4'Edit'#7'Anchors'#11#5'akTop'#6'akLeft'
|
||||
+#7'akRight'#0#7'Enabled'#8#8'TabOrder'#2#3#4'Left'#2#10#6'Height'#2#25#3'Top'
|
||||
+#2#10#5'Width'#3'&'#1#0#0#8'TListBox'#7'Listbox'#7'Anchors'#11#5'akTop'#6'ak'
|
||||
+'Left'#7'akRight'#8'akBottom'#0#16'ClickOnSelChange'#8#10'OnDblClick'#7#10'B'
|
||||
+'TNOKCLICK'#9'OnKeyDown'#7#14'ListboxKeyDown'#8'TabOrder'#2#0#4'Left'#2#10#6
|
||||
+'Height'#3#156#0#3'Top'#2'-'#5'Width'#3'&'#1#0#0#9'TCheckBox'#19'MultiSelect'
|
||||
+'CheckBox'#7'Anchors'#11#5'akTop'#7'akRight'#0#7'Caption'#6#12'Multi Select'
|
||||
+#7'OnClick'#7#24'MultiselectCheckBoxClick'#8'TabOrder'#2#4#4'Left'#3'8'#1#6
|
||||
+'Height'#2#13#3'Top'#2'd'#5'Width'#2'K'#0#0#0
|
||||
]);
|
||||
|
@ -59,6 +59,8 @@ type
|
||||
MultiSelectCheckBox: TCheckBox;
|
||||
Procedure btnOKClick(Sender :TObject);
|
||||
Procedure btnCancelClick(Sender :TObject);
|
||||
procedure ListboxKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState
|
||||
);
|
||||
procedure MultiselectCheckBoxClick(Sender :TObject);
|
||||
public
|
||||
constructor Create(TheOwner: TComponent); override;
|
||||
@ -142,6 +144,14 @@ Begin
|
||||
ModalResult := mrCancel;
|
||||
end;
|
||||
|
||||
procedure TViewUnitDialog.ListboxKeyDown(Sender: TObject; var Key: Word;
|
||||
Shift: TShiftState);
|
||||
begin
|
||||
//ENTER pressed
|
||||
if Key = 13 then
|
||||
btnOKClick(nil);
|
||||
end;
|
||||
|
||||
procedure TViewUnitDialog.MultiselectCheckBoxClick(Sender :TObject);
|
||||
begin
|
||||
ListBox.Multiselect:=MultiselectCheckBox.Checked;
|
||||
|
Loading…
Reference in New Issue
Block a user