summaryrefslogtreecommitdiff
path: root/tools/iceit/Unit1.pas
diff options
context:
space:
mode:
authorVadim Dashevskiy <watcherhd@gmail.com>2013-01-18 07:47:34 +0000
committerVadim Dashevskiy <watcherhd@gmail.com>2013-01-18 07:47:34 +0000
commitc8e5289d64b3de8ca4db62c944d9823c38553821 (patch)
treebb011b42f124d9c80b51448d435e5ac7a36ae933 /tools/iceit/Unit1.pas
parent87288bd403cb5b047ec29101107faca7983876aa (diff)
- iceit patcher restructuring (not working yet)
git-svn-id: http://svn.miranda-ng.org/main/trunk@3151 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'tools/iceit/Unit1.pas')
-rw-r--r--tools/iceit/Unit1.pas41
1 files changed, 23 insertions, 18 deletions
diff --git a/tools/iceit/Unit1.pas b/tools/iceit/Unit1.pas
index 6493615a1c..e49f9f40d8 100644
--- a/tools/iceit/Unit1.pas
+++ b/tools/iceit/Unit1.pas
@@ -12,22 +12,22 @@ type
ImageList1: TImageList;
CheckListBox1: TCheckListBox;
Label1: TLabel;
- Button1: TButton;
- Button2: TButton;
- Button3: TButton;
+ btnSelectAll: TButton;
+ btnSelectNone: TButton;
+ btnIceIt: TButton;
+ btnMirandaPath: TButton;
StatusBar1: TStatusBar;
ProgressBar1: TProgressBar;
Edit1: TEdit;
Label2: TLabel;
- Button4: TButton;
OpenDialog1: TOpenDialog;
procedure CheckListBox1DrawItem(Control: TWinControl; Index: Integer;
Rect: TRect; State: TOwnerDrawState);
procedure FormCreate(Sender: TObject);
- procedure Button1Click(Sender: TObject);
- procedure Button2Click(Sender: TObject);
- procedure Button4Click(Sender: TObject);
- procedure Button3Click(Sender: TObject);
+ procedure SelectAllClick(Sender: TObject);
+ procedure SelectNoneClick(Sender: TObject);
+ procedure IceItClick(Sender: TObject);
+ procedure MirandaPathClick(Sender: TObject);
procedure FormDestroy(Sender: TObject);
private
{ Private declarations }
@@ -380,25 +380,27 @@ begin
end;
end;
-procedure TForm1.Button1Click(Sender: TObject);
+procedure TForm1.SelectAllClick(Sender: TObject);
var n: Integer;
begin
for n := 0 to CheckListBox1.Items.Count - 1 do
+ begin
CheckListBox1.Items[n] := SetValue(CheckListBox1.Items[n], 1, 'NONE');
- for n := 0 to CheckListBox1.Items.Count - 1 do
- CheckListBox1.Checked[n] := True;
+ CheckListBox1.Checked[n] := True;
+ end;
end;
-procedure TForm1.Button2Click(Sender: TObject);
+procedure TForm1.SelectNoneClick(Sender: TObject);
var n: Integer;
begin
for n := 0 to CheckListBox1.Items.Count - 1 do
+ begin
CheckListBox1.Items[n] := SetValue(CheckListBox1.Items[n], 1, 'NONE');
- for n := 0 to CheckListBox1.Items.Count - 1 do
CheckListBox1.Checked[n] := False;
+ end;
end;
-procedure TForm1.Button3Click(Sender: TObject);
+procedure TForm1.IceItClick(Sender: TObject);
var
n: Integer;
S: String;
@@ -426,8 +428,11 @@ begin
ProgressBar1.Position := n;
S := GetValue(CheckListBox1.Items[n], 0);
S := LowerCase(S);
- if n < PluginsItem then F := '\icons' else
- if n < CoreItem then F := '\plugins' else F := '\core';
+ // keep the order as for FillCombo function (atm Core<Plugins<Icons)
+ if n < PluginsItem then F := '\core'
+ else if n < IconsItem then F := '\plugins'
+ else F := '\icons';
+
StatusBar1.Panels[0].Text := ' Processing: ' + S;
if (S = 'miranda32') or (S = 'miranda64') then
begin
@@ -452,7 +457,7 @@ begin
xTemp := xFilePath + '.temp';
CopyFile(PChar(xFilePath), Pchar(xTemp), False);
- if ProgressUpdate(xTemp, xIcoPath) then
+ if not ProgressUpdate(xTemp, xIcoPath) then
res := 'ERROR'
else
begin
@@ -476,7 +481,7 @@ begin
StatusBar1.Panels[0].Text := ' Ready';
end;
-procedure TForm1.Button4Click(Sender: TObject);
+procedure TForm1.MirandaPathClick(Sender: TObject);
begin
if OpenDialog1.Execute then Edit1.Text := OpenDialog1.FileName;
end;