UPD: Some changes for MultiArchiveFileSource

This commit is contained in:
Alexander Koblov 2010-02-28 12:03:04 +00:00
commit 07b503ebd6
10 changed files with 58 additions and 54 deletions

View file

@ -12,7 +12,7 @@ Extract=%P x -y {%S} %AQA @%LQU
Test=%P t -y {%S} %AQA @%LQU
Delete=%P d -y -r {%S} %AQA @%LQU
Add=%P a -mx -r -y {%S} %AQA @%LQU
ConsoleOutput=0
Output=0
Enabled=0
Debug=0
@ -28,9 +28,8 @@ Extract=%P x -y %AQA @%LQA
Test=%P t -y %AQA
Delete=%P d -y %AQA @%LQA
Add=%P a -y %AQA @%LQA
Move=%P m -y %AQA @%LQA
Enabled=0
ConsoleOutput=0
Output=0
Debug=0
[ARJ]
@ -49,7 +48,7 @@ Test=%P t -y {%S} %AQA
Delete=%P d -y -r {%S} %AQA %FQA
Add=%P a -r -y {%S} %AQA %FQA
Enabled=0
ConsoleOutput=0
Output=0
Debug=0
[RAR]
@ -66,5 +65,5 @@ Test=%P t -y {%S} %AQA
Delete=%P d -y -r {%S} %AQA @%LQ
Add=%P a -r -y {%S} %AQA @%LQ
Enabled=0
ConsoleOutput=0
Output=0
Debug=0

View file

@ -4096,10 +4096,10 @@ object frmOptions: TfrmOptions
ClientHeight = 405
ClientWidth = 550
object gbArchiverOptions: TGroupBox
AnchorSideLeft.Control = lblArchiveMove
AnchorSideTop.Control = edtArchiveEncrypt
AnchorSideLeft.Control = lblArchiveMultiVolume
AnchorSideTop.Control = edtArchiveSelfExtract
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = lblArchiveMove
AnchorSideRight.Control = lblArchiveMultiVolume
AnchorSideRight.Side = asrBottom
Left = 10
Height = 51
@ -4114,7 +4114,7 @@ object frmOptions: TfrmOptions
ClientHeight = 33
ClientWidth = 526
TabOrder = 0
object chkMultiArcConsoleOutput: TCheckBox
object chkMultiArcOutput: TCheckBox
AnchorSideTop.Control = gbArchiverOptions
Left = 10
Height = 17
@ -4137,7 +4137,7 @@ object frmOptions: TfrmOptions
TabOrder = 1
end
end
object lblArchiveMove: TLabel
object lblArchiveMultiVolume: TLabel
AnchorSideLeft.Control = tbArchiverAdditional
AnchorSideTop.Control = edtArchiveTest
AnchorSideTop.Side = asrBottom
@ -4151,14 +4151,14 @@ object frmOptions: TfrmOptions
BorderSpacing.Left = 10
BorderSpacing.Top = 2
BorderSpacing.Right = 10
Caption = 'Move:'
Caption = 'Create multivolume archive:'
ParentColor = False
end
object edtArchiveMove: TEdit
AnchorSideLeft.Control = lblArchiveMove
AnchorSideTop.Control = lblArchiveMove
object edtArchiveMultiVolume: TEdit
AnchorSideLeft.Control = lblArchiveMultiVolume
AnchorSideTop.Control = lblArchiveMultiVolume
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = lblArchiveMove
AnchorSideRight.Control = lblArchiveMultiVolume
AnchorSideRight.Side = asrBottom
Left = 10
Height = 21
@ -4167,11 +4167,11 @@ object frmOptions: TfrmOptions
Anchors = [akTop, akLeft, akRight]
TabOrder = 1
end
object lblArchiveEncrypt: TLabel
AnchorSideLeft.Control = lblArchiveMove
AnchorSideTop.Control = edtArchiveMove
object lblArchiveSelfExtract: TLabel
AnchorSideLeft.Control = lblArchiveMultiVolume
AnchorSideTop.Control = edtArchiveMultiVolume
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = lblArchiveMove
AnchorSideRight.Control = lblArchiveMultiVolume
AnchorSideRight.Side = asrBottom
Left = 10
Height = 14
@ -4179,14 +4179,14 @@ object frmOptions: TfrmOptions
Width = 530
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Top = 4
Caption = 'Encrypt:'
Caption = 'Create self extracting archive:'
ParentColor = False
end
object edtArchiveEncrypt: TEdit
AnchorSideLeft.Control = lblArchiveMove
AnchorSideTop.Control = lblArchiveEncrypt
object edtArchiveSelfExtract: TEdit
AnchorSideLeft.Control = lblArchiveMultiVolume
AnchorSideTop.Control = lblArchiveSelfExtract
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = lblArchiveMove
AnchorSideRight.Control = lblArchiveMultiVolume
AnchorSideRight.Side = asrBottom
Left = 10
Height = 21

View file

@ -207,10 +207,10 @@ TFRMOPTIONS.LBLARCHIVELISTSTART.CAPTION=Listing start (optional):
TFRMOPTIONS.LBLARCHIVELISTEND.CAPTION=Listing finish (optional):
TFRMOPTIONS.TBARCHIVERADDITIONAL.CAPTION=Additional
TFRMOPTIONS.GBARCHIVEROPTIONS.CAPTION=Options
TFRMOPTIONS.CHKMULTIARCCONSOLEOUTPUT.CAPTION=Show console output
TFRMOPTIONS.CHKMULTIARCOUTPUT.CAPTION=Show console output
TFRMOPTIONS.CHKMULTIARCDEBUG.CAPTION=Debug mode
TFRMOPTIONS.LBLARCHIVEMOVE.CAPTION=Move:
TFRMOPTIONS.LBLARCHIVEENCRYPT.CAPTION=Encrypt:
TFRMOPTIONS.LBLARCHIVEMULTIVOLUME.CAPTION=Create multivolume archive:
TFRMOPTIONS.LBLARCHIVESELFEXTRACT.CAPTION=Create self extracting archive:
TFRMOPTIONS.LBLARCHIVEDELETE.CAPTION=Delete:
TFRMOPTIONS.LBLARCHIVETEST.CAPTION=Test:
TFRMOPTIONS.BTNMULTIARCAPPLY.CAPTION=Apply

View file

@ -138,7 +138,7 @@ type
chkMultiArcEnabled: TCheckBox;
chkAutoFillColumns: TCheckBox;
chkIgnoreEnable: TCheckBox;
chkMultiArcConsoleOutput: TCheckBox;
chkMultiArcOutput: TCheckBox;
chkMultiArcDebug: TCheckBox;
cmbTabsPosition: TComboBox;
cmbAutoSizeColumn: TComboBox;
@ -148,8 +148,8 @@ type
edtArchiveListEnd: TEdit;
edtArchiveListStart: TEdit;
edtArchiveDelete: TEdit;
edtArchiveEncrypt: TEdit;
edtArchiveMove: TEdit;
edtArchiveMultiVolume: TEdit;
edtArchiveSelfExtract: TEdit;
edtArchiveAdd: TEdit;
edtArchiveExtension: TEdit;
edtArchiveExtract: TEdit;
@ -217,8 +217,8 @@ type
lblArchiveListEnd: TLabel;
lblArchiveListStart: TLabel;
lblArchiveDelete: TLabel;
lblArchiveEncrypt: TLabel;
lblArchiveMove: TLabel;
lblArchiveMultiVolume: TLabel;
lblArchiveSelfExtract: TLabel;
lblArchiveAdd: TLabel;
lblArchiveExtension: TLabel;
lblArchiveExtract: TLabel;
@ -1245,9 +1245,9 @@ begin
FAdd:= edtArchiveAdd.Text;
FDelete:= edtArchiveDelete.Text;
FTest:= edtArchiveTest.Text;
FMove:= edtArchiveMove.Text;
FEncrypt:= edtArchiveEncrypt.Text;
FConsoleOutput:= chkMultiArcConsoleOutput.Checked;
FAddMultiVolume:= edtArchiveMultiVolume.Text;
FAddSelfExtract:= edtArchiveSelfExtract.Text;
FOutput:= chkMultiArcOutput.Checked;
FDebug:= chkMultiArcDebug.Checked;
FEnabled:= chkMultiArcEnabled.Checked;
end;
@ -2069,8 +2069,8 @@ begin
edtArchiveAdd.Text:= EmptyStr;
edtArchiveDelete.Text:= EmptyStr;
edtArchiveTest.Text:= EmptyStr;
edtArchiveMove.Text:= EmptyStr;
chkMultiArcConsoleOutput.Checked:= False;
edtArchiveMultiVolume.Text:= EmptyStr;
chkMultiArcOutput.Checked:= False;
chkMultiArcDebug.Checked:= False;
chkMultiArcEnabled.Checked:= False;
pcArchiverCommands.Enabled:= (lbxMultiArc.Count <> 0);
@ -2090,8 +2090,8 @@ begin
edtArchiveAdd.Text:= FAdd;
edtArchiveDelete.Text:= FDelete;
edtArchiveTest.Text:= FTest;
edtArchiveMove.Text:= FMove;
chkMultiArcConsoleOutput.Checked:= FConsoleOutput;
edtArchiveMultiVolume.Text:= FAddMultiVolume;
chkMultiArcOutput.Checked:= FOutput;
chkMultiArcDebug.Checked:= FDebug;
chkMultiArcEnabled.Checked:= FEnabled;
end;

View file

@ -218,7 +218,7 @@ end;
procedure TMultiArchiveCopyInOperation.OnReadLn(str: string);
begin
with FMultiArchiveFileSource.MultiArcItem do
if FConsoleOutput or FDebug then
if FOutput or FDebug then
logWrite(Thread, str, lmtInfo, True, False);
end;

View file

@ -438,7 +438,7 @@ end;
procedure TMultiArchiveCopyOutOperation.OnReadLn(str: string);
begin
with FMultiArchiveFileSource.MultiArcItem do
if FConsoleOutput or FDebug then
if FOutput or FDebug then
logWrite(Thread, str, lmtInfo, True, False);
end;

View file

@ -186,7 +186,7 @@ end;
procedure TMultiArchiveDeleteOperation.OnReadLn(str: string);
begin
with FMultiArchiveFileSource.MultiArcItem do
if FConsoleOutput or FDebug then
if FOutput or FDebug then
logWrite(Thread, str, lmtInfo, True, False);
end;

View file

@ -187,7 +187,7 @@ end;
procedure TMultiArchiveTestArchiveOperation.OnReadLn(str: string);
begin
with FMultiArchiveFileSource.MultiArcItem do
if FConsoleOutput or FDebug then
if FOutput or FDebug then
logWrite(Thread, str, lmtInfo, True, False);
end;

View file

@ -288,7 +288,7 @@ function FormatArchiverCommand(const Archiver, sCmd, anArchiveName: UTF8String;
type
TFunctType = (ftNone, ftArchiverLongName, ftArchiverShortName,
ftArchiveLongName, ftArchiveShortName,
ftFileListLongName, ftFileListShortName, ftFileName, ftTargetArchiveDir);
ftFileListLongName, ftFileListShortName, ftFileName, ftTargetArchiveDir, ftVolumeSize);
TStatePos = (spNone, spPercent, spFunction, spComplete);
TFuncModifiers = set of (fmQuoteWithSpaces, fmQuoteAny, fmNameOnly,
fmPathOnly, fmUTF8, fmAnsi);
@ -483,6 +483,11 @@ begin
state.funct := ftTargetArchiveDir;
state.pos := spFunction;
end;
'V':
begin
state.funct := ftVolumeSize;
state.pos := spFunction;
end;
else
state.pos := spFunction;
end;

View file

@ -42,11 +42,11 @@ type
FTest,
FDelete,
FAdd,
FMove,
FEncrypt: UTF8String;
FAddMultiVolume,
FAddSelfExtract: UTF8String;
public
FEnabled: Boolean;
FConsoleOutput: Boolean;
FOutput: Boolean;
FDebug: Boolean;
constructor Create;
destructor Destroy; override;
@ -165,11 +165,11 @@ begin
FTest:= TrimQuotes(IniFile.ReadString(Section, 'Test', EmptyStr));
FDelete:= TrimQuotes(IniFile.ReadString(Section, 'Delete', EmptyStr));
FAdd:= TrimQuotes(IniFile.ReadString(Section, 'Add', EmptyStr));
FMove:= TrimQuotes(IniFile.ReadString(Section, 'Move', EmptyStr));
FEncrypt:= TrimQuotes(IniFile.ReadString(Section, 'Encrypt', EmptyStr));
FAddMultiVolume:= TrimQuotes(IniFile.ReadString(Section, 'AddMultiVolume', EmptyStr));
FAddSelfExtract:= TrimQuotes(IniFile.ReadString(Section, 'AddSelfExtract', EmptyStr));
// optional
FEnabled:= IniFile.ReadBool(Section, 'Enabled', True);
FConsoleOutput:= IniFile.ReadBool(Section, 'ConsoleOutput', False);
FOutput:= IniFile.ReadBool(Section, 'Output', False);
FDebug:= IniFile.ReadBool(Section, 'Debug', False);
end;
FList.AddObject(Section, MultiArcItem);
@ -213,11 +213,11 @@ begin
IniFile.WriteString(Section, 'Test', FTest);
IniFile.WriteString(Section, 'Delete', FDelete);
IniFile.WriteString(Section, 'Add', FAdd);
IniFile.WriteString(Section, 'Move', FMove);
IniFile.WriteString(Section, 'Encrypt', FEncrypt);
IniFile.WriteString(Section, 'AddMultiVolume', FAddMultiVolume);
IniFile.WriteString(Section, 'AddSelfExtract', FAddSelfExtract);
// optional
IniFile.WriteBool(Section, 'Enabled', FEnabled);
IniFile.WriteBool(Section, 'ConsoleOutput', FConsoleOutput);
IniFile.WriteBool(Section, 'Output', FOutput);
IniFile.WriteBool(Section, 'Debug', FDebug);
end;
end;
@ -252,4 +252,4 @@ begin
end;
end.