MemDS: Localized 'Select dataset to copy from' dilaog. Patch from Marcelo B Paula, part of bug #16909.

git-svn-id: trunk@26601 -
This commit is contained in:
maxim 2010-07-11 17:47:25 +00:00
parent 59f9b13b95
commit 2b701c91a8
2 changed files with 49 additions and 30 deletions

View File

@ -1,62 +1,63 @@
object SelectSrcDatasetForm: TSelectSrcDatasetForm object SelectSrcDatasetForm: TSelectSrcDatasetForm
Left = 364
Height = 282
Top = 233
Width = 355
HorzScrollBar.Page = 356
VertScrollBar.Page = 283
BorderStyle = bsDialog BorderStyle = bsDialog
Caption = 'Select dataset to copy from' Caption = 'Select dataset to copy from'
ClientHeight = 282 ClientHeight = 282
ClientWidth = 355 ClientWidth = 355
HorzScrollBar.Page = 356 OnCreate = FormCreate
VertScrollBar.Page = 283 LCLVersion = '0.9.29'
Left = 374
Height = 282
Top = 194
Width = 355
object CBMetaDataOnly: TCheckBox object CBMetaDataOnly: TCheckBox
AllowGrayed = True
AutoSize = True
Caption = 'Copy only metadata'
DragCursor = 65524
TabOrder = 0
Left = 8 Left = 8
Height = 24 Height = 21
Top = 15 Top = 15
Width = 137 Width = 147
AllowGrayed = True
Caption = 'Copy only metadata'
TabOrder = 0
end end
object LBDatasets: TListBox object LBDatasets: TListBox
OnClick = LBDatasetsClick
TabOrder = 1
TopIndex = -1
Left = 8 Left = 8
Height = 204 Height = 204
Top = 72 Top = 72
Width = 249 Width = 249
ItemHeight = 0
OnClick = LBDatasetsClick
TabOrder = 1
end end
object LLBDatasets: TLabel object LLBDatasets: TLabel
Left = 8
Height = 18
Top = 45
Width = 138
Caption = '&Dataset to copy from:' Caption = '&Dataset to copy from:'
Layout = tlCenter Layout = tlCenter
Left = 8 ParentColor = False
Height = 24
Top = 45
Width = 188
end end
object BOK: TButton object BOK: TButton
Default = True
Enabled = False
ModalResult = 1
Caption = '&OK'
TabOrder = 3
OnClick = BOKClick
Left = 264 Left = 264
Height = 25 Height = 25
Top = 15 Top = 15
Width = 85 Width = 85
Caption = '&OK'
Default = True
Enabled = False
ModalResult = 1
OnClick = BOKClick
TabOrder = 3
end end
object BCancel: TButton object BCancel: TButton
ModalResult = 2
Cancel = True
Caption = '&Cancel'
TabOrder = 4
Left = 264 Left = 264
Height = 25 Height = 25
Top = 48 Top = 48
Width = 83 Width = 83
Cancel = True
Caption = '&Cancel'
ModalResult = 2
TabOrder = 2
end end
end end

View File

@ -37,6 +37,8 @@ Type
Procedure CreateTable; virtual; Procedure CreateTable; virtual;
end; end;
{ TSelectSrcDatasetForm }
TSelectSrcDatasetForm = class(TForm) TSelectSrcDatasetForm = class(TForm)
BOK: TButton; BOK: TButton;
BCancel: TButton; BCancel: TButton;
@ -44,6 +46,7 @@ Type
LLBDatasets: TLabel; LLBDatasets: TLabel;
LBDatasets: TListBox; LBDatasets: TListBox;
procedure BOKClick(Sender: TObject); procedure BOKClick(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure LBDatasetsClick(Sender: TObject); procedure LBDatasetsClick(Sender: TObject);
private private
public public
@ -55,6 +58,12 @@ Resourcestring
SMenuCopyDataset = 'Copy data from Dataset'; SMenuCopyDataset = 'Copy data from Dataset';
SErrSelectDataset = 'Please select a dataset first'; SErrSelectDataset = 'Please select a dataset first';
SCaption = 'Select dataset to copy from';
SCopyMeta = 'Copy only metadata';
SDataset = '&Dataset to copy from:';
SOkBtn = 'OK';
SCancelBtn = 'Cancel';
var var
SelectSrcDatasetForm: TSelectSrcDatasetForm; SelectSrcDatasetForm: TSelectSrcDatasetForm;
@ -171,6 +180,15 @@ begin
Raise Exception.Create(SErrSelectDataset) Raise Exception.Create(SErrSelectDataset)
end; end;
procedure TSelectSrcDatasetForm.FormCreate(Sender: TObject);
begin
Caption := SCaption;
CBMetaDataOnly.Caption := SCopyMeta;
LLBDatasets.Caption := SDataset;
BOK.Caption := SOkBtn;
BCancel.Caption := SCancelBtn;
end;
initialization initialization
{$i memdsicons.lrs} {$i memdsicons.lrs}