mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-17 06:39:34 +02:00
* Extention -> extension (By Reinier, bug ID #25979)
git-svn-id: trunk@27749 -
This commit is contained in:
parent
89c4255ab8
commit
8d4e81702e
@ -9,7 +9,7 @@ resourcestring
|
|||||||
sOptions = 'Options';
|
sOptions = 'Options';
|
||||||
sOk = ' Ok ';
|
sOk = ' Ok ';
|
||||||
sCancel = 'Cancel';
|
sCancel = 'Cancel';
|
||||||
sExtention = 'Extention';
|
sExtension = 'Extension';
|
||||||
sSaveonclose = '_Save on close';
|
sSaveonclose = '_Save on close';
|
||||||
sFileFormat = 'File format';
|
sFileFormat = 'File format';
|
||||||
sMRUcount = 'MRU count';
|
sMRUcount = 'MRU count';
|
||||||
|
@ -1242,7 +1242,7 @@ begin
|
|||||||
else
|
else
|
||||||
FDefs.Write (TheFile, nil, nil);
|
FDefs.Write (TheFile, nil, nil);
|
||||||
TheFile.EndUpdate;
|
TheFile.EndUpdate;
|
||||||
Thefile.SaveToFile (FDefs.UnitName+'.'+FSettings.Extention);
|
Thefile.SaveToFile (FDefs.UnitName+'.'+FSettings.Extension);
|
||||||
finally
|
finally
|
||||||
TheFile.Free;
|
TheFile.Free;
|
||||||
end;
|
end;
|
||||||
@ -1381,7 +1381,7 @@ const
|
|||||||
keySaveOnExit = 'SaveOnExit';
|
keySaveOnExit = 'SaveOnExit';
|
||||||
keyFileFormat = 'TextFormat';
|
keyFileFormat = 'TextFormat';
|
||||||
keyMRUCount = 'MRUCount';
|
keyMRUCount = 'MRUCount';
|
||||||
keyExtention = 'Extention';
|
keyExtension = 'Extention'; //keep wrong spelling so cmpatibility kept with existing settings
|
||||||
keyProgressWindow = 'ShowProgress';
|
keyProgressWindow = 'ShowProgress';
|
||||||
secMRU = 'Last open files';
|
secMRU = 'Last open files';
|
||||||
keyFile = 'File';
|
keyFile = 'File';
|
||||||
@ -1396,7 +1396,7 @@ begin
|
|||||||
try
|
try
|
||||||
saveonclose := readbool (SecSettings, keySaveOnExit, true);
|
saveonclose := readbool (SecSettings, keySaveOnExit, true);
|
||||||
Fileformat := TFileFormat(readinteger (secSettings, keyFileFormat, 2));
|
Fileformat := TFileFormat(readinteger (secSettings, keyFileFormat, 2));
|
||||||
Extention := readstring (secSettings, keyExtention, '.pp');
|
Extension := readstring (secSettings, keyExtension, '.pp');
|
||||||
MRUCount := readinteger (secSettings, keyMRUCount, 5);
|
MRUCount := readinteger (secSettings, keyMRUCount, 5);
|
||||||
ShowProgress := readbool (SecSettings, keyProgressWindow, true);
|
ShowProgress := readbool (SecSettings, keyProgressWindow, true);
|
||||||
FReopenList.capacity := MRUCount;
|
FReopenList.capacity := MRUCount;
|
||||||
@ -1420,7 +1420,7 @@ begin
|
|||||||
try
|
try
|
||||||
writebool (SecSettings, keySaveOnExit, saveonclose);
|
writebool (SecSettings, keySaveOnExit, saveonclose);
|
||||||
writeinteger (secSettings, keyFileFormat, Ord(FileFormat));
|
writeinteger (secSettings, keyFileFormat, Ord(FileFormat));
|
||||||
writestring (secSettings, keyExtention, Extention);
|
writestring (secSettings, keyExtension, Extension);
|
||||||
writeinteger (secSettings, keyMRUCount, MRUCount);
|
writeinteger (secSettings, keyMRUCount, MRUCount);
|
||||||
writebool (SecSettings, keyProgressWindow, ShowProgress);
|
writebool (SecSettings, keyProgressWindow, ShowProgress);
|
||||||
writeinteger (secMRU, keyCount, FReopenlist.count);
|
writeinteger (secMRU, keyCount, FReopenlist.count);
|
||||||
|
@ -15,7 +15,7 @@ type
|
|||||||
TSettingsRec = record
|
TSettingsRec = record
|
||||||
SaveOnClose : boolean;
|
SaveOnClose : boolean;
|
||||||
FileFormat : TFileFormat;
|
FileFormat : TFileFormat;
|
||||||
Extention : string;
|
Extension : string;
|
||||||
MRUCount : integer;
|
MRUCount : integer;
|
||||||
ShowProgress : boolean;
|
ShowProgress : boolean;
|
||||||
end;
|
end;
|
||||||
@ -25,7 +25,7 @@ type
|
|||||||
FCBSaveOnClose : TFPgtkToggleButton;
|
FCBSaveOnClose : TFPgtkToggleButton;
|
||||||
FEFileFormat : TFPgtkOptionMenu;
|
FEFileFormat : TFPgtkOptionMenu;
|
||||||
FMenuFileFormat : TFPgtkMenu;
|
FMenuFileFormat : TFPgtkMenu;
|
||||||
FEExtention : TFPgtkCombo;
|
FEExtension : TFPgtkCombo;
|
||||||
FEMRUCount : TFPgtkSpinButton;
|
FEMRUCount : TFPgtkSpinButton;
|
||||||
FCBProgressWindow : TFPgtkToggleButton;
|
FCBProgressWindow : TFPgtkToggleButton;
|
||||||
procedure BuildDialog;
|
procedure BuildDialog;
|
||||||
@ -108,16 +108,16 @@ begin
|
|||||||
FCBProgressWindow := TFPgtkCheckedButton.CreateWithLabel(sProgressWindow, AGroup);
|
FCBProgressWindow := TFPgtkCheckedButton.CreateWithLabel(sProgressWindow, AGroup);
|
||||||
b.PackStart (FCBProgressWindow, False, False, 10);
|
b.PackStart (FCBProgressWindow, False, False, 10);
|
||||||
|
|
||||||
FEExtention := TFPgtkCombo.Create;
|
FEExtension := TFPgtkCombo.Create;
|
||||||
with FEExtention do
|
with FEExtension do
|
||||||
begin
|
begin
|
||||||
SetValueInList (false, false);
|
SetValueInList (false, false);
|
||||||
List.Add (TFPgtkListItem.CreateWithLabel('pp'));
|
List.Add (TFPgtkListItem.CreateWithLabel('pp'));
|
||||||
List.Add (TFPgtkListItem.CreateWithLabel('pas'));
|
List.Add (TFPgtkListItem.CreateWithLabel('pas'));
|
||||||
end;
|
end;
|
||||||
b := TFPgtkHBox.Create;
|
b := TFPgtkHBox.Create;
|
||||||
b.PackStart (TFPgtkLabel.Create (sExtention), false, false, 0);
|
b.PackStart (TFPgtkLabel.Create (sExtension), false, false, 0);
|
||||||
b.PackStart (FEExtention, false, false, 5);
|
b.PackStart (FEExtension, false, false, 5);
|
||||||
box.PackStart (b, false, false, 10);
|
box.PackStart (b, false, false, 10);
|
||||||
|
|
||||||
FEMRUCount := TFPgtkSpinButton.Create;
|
FEMRUCount := TFPgtkSpinButton.Create;
|
||||||
@ -143,7 +143,7 @@ begin
|
|||||||
begin
|
begin
|
||||||
SaveOnClose := FCBSaveOnClose.Active;
|
SaveOnClose := FCBSaveOnClose.Active;
|
||||||
FileFormat := TFileFormat(FMenuFileFormat.ActiveIndex);
|
FileFormat := TFileFormat(FMenuFileFormat.ActiveIndex);
|
||||||
Extention := FEExtention.Entry.Text;
|
Extension := FEExtension.Entry.Text;
|
||||||
MRUCount := FEMRUCount.AsInteger;
|
MRUCount := FEMRUCount.AsInteger;
|
||||||
ShowProgress := FCBProgressWindow.Active;
|
ShowProgress := FCBProgressWindow.Active;
|
||||||
end;
|
end;
|
||||||
@ -156,7 +156,7 @@ begin
|
|||||||
begin
|
begin
|
||||||
FCBSaveOnClose.Active := SaveOnClose;
|
FCBSaveOnClose.Active := SaveOnClose;
|
||||||
FEFileFormat.SetHistory (ord(FileFormat));
|
FEFileFormat.SetHistory (ord(FileFormat));
|
||||||
FEExtention.Entry.Text := Extention;
|
FEExtension.Entry.Text := Extension;
|
||||||
FEMRUCount.AsInteger := MRUCount;
|
FEMRUCount.AsInteger := MRUCount;
|
||||||
FCBProgressWindow.Active := ShowProgress;
|
FCBProgressWindow.Active := ShowProgress;
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user