мой скрипт
[Setup]
AppId={B4866999-9FF1-4780-A2E9-A952A5E7BBCA}
AppName=[Prototype]
AppVerName=[Prototype]
AppPublisher=Activision
AppVersion=1.0
AppSupportURL=http://activision.custhelp.com/
DefaultDirName={pf}\Prototype
OutputDir=D:\Репаки\Prototype
DefaultGroupName=Activision\Radical Entertainment\Prototype
UninstallFilesDir={app}\Uninstall
Compression=lzma/ultra64
InternalCompressLevel=ultra64
SolidCompression=true
DiskSpanning=yes
SlicesPerDisk=3
DiskSliceSize=1100000000
UninstallDisplayIcon={app}\prototypef.exe, 0
UninstallDisplayName=WarCraft The Frozen Throne 1.24c
DisableReadyPage=true
[Languages]
Name: RUS; MessagesFile: compiler:Languages\Russian.isl
[Files]
Source: "{tmp}\1.bmp"; DestDir: "{tmp}"; Flags: deleteafterinstall dontcopy
Source: "{tmp}\site.bmp"; DestDir: "{tmp}"; Flags: deleteafterinstall dontcopy
Source: "{tmp}\black.cjstyles"; DestDir: "{tmp}"; Flags: deleteafterinstall dontcopy
Source: "{app}\ISSkin.dll"; DestDir: "{app}";
Source: "isgsg.dll"; DestDir: {tmp}; Flags: ignoreversion dontcopy nocompression solidbreak
[CustomMessages]
RUS.BUT=Установить
RUS.SPACE=Доступно места на диске:
RUS.SPACE1=Требуется места на диске:
RUS.DRT=Обновить DirectX
RUS.UP=Идет обновление DirectX...
RUS.Icons=Создать ярлык на рабочем столе
RUS.Group=Создать ярлыки в меню "Пуск"
RUS.Redist=Установить ЫЫЫ
RUS.Finished1=Игра WarCraft The Frozen Throne 1.24c установлена на Ваш компьютер.
RUS.Finished2=Нажмите «Завершить», чтобы выйти из программы установки.
RUS.RunProgram=Запустить WarCraft The Frozen Throne 1.24c
[code]
////////////////////
//Эти данные нужны для создания надписей, при вставке изображения в инстяллятор
var
DirectX, Redist, Icons, Group, RunProgram: TCheckBox; //Чекбоксы
IconsLabel, GroupLabel, RedistLabel, DirectXLabel: TLabel; //Надписи к чекбоксам
SelectDirLabel, SelectDirLabelBrowse, RunProgramLabel: TLabel; //Надписи на странице выбора места установки
PageNameLabel, PageNameLabel1, PageNameLabel2, PageNameLabel3, PageNameLabel4, PageNameLabel5, PageNameLabel6, PageNameLabel7, PageNameLabel8: TLabel; //Заголовок страницы
PageDescriptionLabel, PageDescriptionLabel1, PageDescriptionLabel2, PageDescriptionLabel3, PageDescriptionLabel4, PageDescriptionLabel5, PageDescriptionLabel6, PageDescriptionLabel7, PageDescriptionLabel8: TLabel; //Информация о странице
StatusLabel, FilenameLabel, NeedSpaceLabel,FreeSpaceLabel: TLabel; //Данные на странице установки
WelcomeLabel1, WelcomeLabel2, FinishedLabel, FinishedHeadingLabel: TLabel; //Надписи на на странице приветствия и на финишной странице
SelectStartMenuFolderLabel, SelectStartMenuFolderBrowseLabel, ReadyLabel, NoIconsLabel: TLabel; //Надписи и чекбоксы на странице выбора места установки ярлыков в Главном Меню
LicenseLabel1, LicenseAcceptedLabel, LicenseNotAcceptedLabel: Tlabel; //Надписи на страниые Лицензионнго соглашения
InfoBeforeClickLabel, InfoAfterClickLabel, ComponentsDiskSpaceLabel, SelectComponentsLabel: TLabel; //Надписи на странице компонентов и страницах показа данных до и после установки
NeedSize:Integer; //Нужное место на диске
FreeMB, TotalMB: Cardinal; //нужное место на диске
BmpFile: TBitmapImage; //Вставка изобрпжения в окно инсталлятора
PageID,ResultCode: Integer; //Запуск программы после установки
URLLabel:TLabel;
//Дальше функция проверки чекбоксов
function InstallDirectX: Boolean;
begin
Result:= DirectX.Checked;
end;
function InstallRedist: Boolean;
begin
Result:=Redist.Checked;
end;
function CreateIcons: Boolean;
begin
Result:=Icons.Checked;
end;
function GroupIcons: Boolean;
begin
Result:=Group.Checked;
end;
function Run: Boolean;
begin
Result:=RunProgram.Checked;
end;
//Функция проверки чекбоксов
// задал процедуру, чтоб отмечался чебокс еси кликнуть по надписи
procedure RedistOnClick(Sender: TObject);
begin
if Redist.Checked = False then
Redist.Checked:= True else
Redist.Checked:= False;
end;
procedure DirectXLabelOnClick(Sender: TObject);
begin
if DirectX.Checked = False then
DirectX.Checked:= True else
DirectX.Checked:= False;
end;
procedure IconsOnClick(Sender: TObject);
begin
if Icons.Checked = False then
Icons.Checked:= True else
Icons.Checked:= False;
end;
procedure GroupOnClick(Sender: TObject);
begin
if Group.Checked = False then
Group.Checked:= True else
Group.Checked:= False;
end;
procedure RunProgramOnClick(Sender: TObject);
begin
if RunProgram.Checked = False then
RunProgram.Checked:= True else
RunProgram.Checked:= False;
end;
Procedure NoIconsLabelOnClick (Sender: TObject);
begin
WizardForm.NoIconsCheck.Checked:=Not(WizardForm.NoIconsCheck.Checked)
end;
procedure LicenceAcceptedRadioOnClick(Sender: TObject);
begin
WizardForm.NextButton.Enabled:=True
end;
procedure LicenceNotAcceptedRadioOnClick(Sender: TObject);
begin
WizardForm.NextButton.Enabled:=False
end;
Procedure YesRadioOnClick (Sender: TObject);
begin
WizardForm.LicenseAcceptedRadio.Checked:=True
end;
Procedure NoRadioOnClick (Sender: TObject);
begin
WizardForm.LicenseNotAcceptedRadio.Checked:=True
end;
// задал процедуру, чтоб отмечался чебокс еси кликнуть по надписи lblCheckBox
//Свободное место, отображает сколько нужно и сколько есть места на диске, находтся на странице выбора пути
procedure GetFreeSpaceCaption(Sender: TObject);
var
Path: String;
begin
Path := ExtractFileDrive(WizardForm.DirEdit.Text);
GetSpaceOnDisk(Path, True, FreeMB, TotalMB);
if FreeMB > 1024 then
FreeSpaceLabel.Caption := ExpandConstant('{cm:SPACE} ')+ FloatToStr(round(FreeMB/1024*100)/100) + ' GB' else
FreeSpaceLabel.Caption := ExpandConstant('{cm:SPACE} ')+ IntToStr(FreeMB)+ ' MB';
if FreeMB < NeedSize then
WizardForm.NextButton.Enabled := False else
WizardForm.NextButton.Enabled := True;
end;
procedure GetNeedSpaceCaption;
begin
if NeedSize > 1024 then
NeedSpaceLabel.Caption := ExpandConstant('{cm:SPACE1} ')+ FloatToStr(round(NeedSize/1024*100)/100) + ' GB' else
NeedSpaceLabel.Caption := ExpandConstant('{cm:SPACE1} ')+ IntToStr(NeedSize)+ ' MB';
end;
//Свободное место
procedure FilenameExt();
begin
FilenameLabel.Caption:= ExpandConstant(ExtractFileDir(CurrentFilename)) + '\' + ExtractFilename(CurrentFilename);
end;
procedure InitializeWizard();
begin
WizardForm.WelcomeLabel2.Height := WizardForm.WelcomeLabel2.Height - ScaleY(18);
MouseLabel:=TLabel.Create(WizardForm)
MouseLabel.Width:=WizardForm.Width
MouseLabel.Height:=WizardForm.Height
MouseLabel.Autosize:=False
MouseLabel.Transparent:=True
MouseLabel.OnMouseMove:=@SiteLabelMouseMove2
MouseLabel.Parent:=WizardForm
SiteLabel:=TLabel.Create(WizardForm);
SiteLabel.Left:= WizardForm.NextButton.Left + WizardForm.NextButton.Width;
SiteLabel.Top:= WizardForm.OuterNotebook.Height - SiteLabel.Height;
SiteLabel.Cursor:=crHand
SiteLabel.Font.Color:=clBlue
SiteLabel.Caption:='Forum Ru-Board'
SiteLabel.OnClick:=@SiteLabelOnClick
SiteLabel.OnMouseDown:=@SiteLabelMouseDown
SiteLabel.OnMouseUp:=@SiteLabelMouseUp
SiteLabel.OnMouseMove:=@SiteLabelMouseMove
SiteLabel.Parent:=WizardForm.WelcomePage;
ExtractTemporaryFile('1.bmp'); //Извлекаем файл, который пойдет в окно инсталлятора
NeedSize:= 7980; //Необходимое место для установки
BmpFile:= TBitmapImage.Create(WizardForm);
//Вставляем изображение в окно инсталлятора, для каждой страницы нужно добвлять изображение заново
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp'));
BmpFile.SetBounds(0, 0, 497, 360);
BmpFile.Stretch:= true
BmpFile.Parent:= WizardForm.WelcomePage;
BmpFile:= TBitmapImage.Create(WizardForm);
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp'));
BmpFile.SetBounds(0, 0, 497, 360);
BmpFile.Stretch:= true
BmpFile.Parent:= WizardForm.LicensePage;
BmpFile:= TBitmapImage.Create(WizardForm);
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp'));
BmpFile.SetBounds(0, 0, 497, 360);
BmpFile.Stretch:= true
BmpFile.Parent:= WizardForm.InfoBeforePage;
BmpFile:= TBitmapImage.Create(WizardForm);
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp'));
BmpFile.SetBounds(0, 0, 497, 360);
BmpFile.Stretch:= true
BmpFile.Parent:= WizardForm.SelectDirPage;
BmpFile:= TBitmapImage.Create(WizardForm);
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp'));
BmpFile.SetBounds(0, 0, 497, 360);
BmpFile.Stretch:= true
BmpFile.Parent:= WizardForm.SelectComponentsPage;
BmpFile:= TBitmapImage.Create(WizardForm);
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp'));
BmpFile.SetBounds(0, 0, 497, 360);
BmpFile.Stretch:= true
BmpFile.Parent:= WizardForm.InstallingPage;
BmpFile:= TBitmapImage.Create(WizardForm);
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp'));
BmpFile.SetBounds(0, 0, 497, 360);
BmpFile.Stretch:= true
BmpFile.Parent:= WizardForm.InfoAfterPage;
BmpFile:= TBitmapImage.Create(WizardForm);
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp'));
BmpFile.SetBounds(0, 0, 497, 360);
BmpFile.Stretch:= true
BmpFile.Parent:= WizardForm.FinishedPage;
BmpFile:= TBitmapImage.Create(WizardForm);
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp'));
BmpFile.SetBounds(0, 0, 497, 360);
BmpFile.Stretch:= true
BmpFile.Parent:= WizardForm.SelectProgramGroupPage;
BmpFile:= TBitmapImage.Create(WizardForm);
BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\1.bmp'));
BmpFile.SetBounds(0, 0, 497, 360);
BmpFile.Stretch:= true
BmpFile.Parent:= WizardForm.ReadyPage;
//Вставляем изображение в окно инсталлятора, для каждой страницы нужно добвлять изображение заново
//Скрывем стандартные надписи, значки и чекбоксы
with WizardForm do
begin
PageNameLabel.Hide;
PageDescriptionLabel.Hide;
WelcomeLabel1.Hide;
WelcomeLabel2.Hide;
DiskSpaceLabel.Hide;
SelectDirBitmapImage.Hide;
SelectDirBrowseLabel.Hide;
SelectDirLabel.Hide;
FinishedHeadingLabel.Hide;
FinishedLabel.Hide;
MainPanel.Hide
FilenameLabel.Hide;
StatusLabel.Hide;
SelectStartMenuFolderLabel.Hide;
SelectStartMenuFolderBrowseLabel.Hide;
ReadyLabel.Hide;
LicenseLabel1.Hide;
InfoBeforeClickLabel.Hide;
InfoAfterClickLabel.Hide;
ComponentsDiskSpaceLabel.Hide;
SelectComponentsLabel.Hide;
end;
//Скрывем стандартные надписи, значки и чекбоксы
with WizardForm do
begin
DirBrowseButton.Left:= DirBrowseButton.Left + ScaleX(40); //Местоположение кнопки "Обзор" от левого края, на странице выбора пути установки
DirBrowseButton.Top:= DirBrowseButton.Top + ScaleY(72); //Местоположение кнопки "Обзор" сверху, на странице выбора пути установки
DirEdit.Left:= DirEdit.Left + ScaleX(40); //Местоположение панели, где отображается путь от левого края, на странице выбора пути установки
DirEdit.Top:= DirEdit.Top + ScaleY(72); //Местоположение панели, где отображается путь сверху, на странице выбора пути установки
GroupBrowseButton.Left:= GroupBrowseButton.Left + ScaleX(40); //Местоположение кнопки "Обзор" от левого края, на странице создания ярлыков в Главном Меню
GroupBrowseButton.Top:= GroupBrowseButton.Top + ScaleY(72); //Местоположение кнопки "Обзор" сверху, на странице создания ярлыков в Главном Меню
GroupEdit.Left:= GroupEdit.Left + ScaleX(40); //Местоположение панели, где отображается путь от левого края, на странице создания ярлыков в Главном Меню
GroupEdit.Top:= GroupEdit.Top + ScaleX(72); //Местоположение панели, где отображается путь сверху, на странице создания ярлыков в Главном Меню
GroupEdit.Color:= ClBlack //Цвет панели, где отображается путь, на странице создания ярлыков в Главном Меню
NextButton.BringToFront; //Выносим на передний план кнопки
BackButton.BringToFront; //Выносим на передний план кнопки
CancelButton.BringToFront; //Выносим на передний план кнопки
Font.Style:=[]; //Стиль шрифта, используемого в инсталляторе
Font.Name:= 'MS Sans Serif'; //Имя шрифта, используемого в инсталляторе
DirEdit.Color:=clBlack; //Цвет панели, где отображается путь, на странице выбора пути установки
Font.Color:=clWhite; //Цвет шрифта, используемого в инсталляторе
ProgressGauge.Top:=ScaleY(120); //Местоположение Прогресс-бара сверху
ProgressGauge.Left:=ScaleX(20); //Местоположение Прогресс-бара от левого края
ProgressGauge.Width:=ScaleX(457); //Ширина Прогресс-бара
ReadyMemo.Left:=ScaleX(40); //Местоположение сверху панели где отображаются данные выбранных компонентов, на странице готовности установки
ReadyMemo.Top:= WizardForm.ReadyMemo.Top + ScaleY(72) //Цвет шрифта в панели где отображаются данные выбранных компонентов, на странице готовности установки
ReadyMemo.Font.Color:= clBlack; //Стиль панели где отображаются данные выбранных компонентов, на странице готовности установки. Без скроллов - ssNone, с вертикальным скроллом - ssVertial, с горизонтальным скроллом - ssHorizontal, и со всеми скроллами - просто уберите эту строчку или ssBoth
ReadyMemo.ScrollBars:= ssVertical; //ssNone
end;
//Это нужно для того чтоб картинка нормально отображалась
with WizardForm do
begin
InnerNotebook.Left := ScaleX(0);
InnerNotebook.Top := ScaleY(0);
InnerNotebook.Width := ScaleX(497); //Ширина инсталлятора
InnerNotebook.Height := ScaleY(360); //Высота инсталлятора
OuterNotebook.Left := ScaleX(0);
OuterNotebook.Top := ScaleY(0);
OuterNotebook.Width := ScaleX(497); //Ширина инсталлятора
OuterNotebook.Height := ScaleY(360); //Высота инсталлятора
end;
//Это нужно для того чтоб картинка нормально отображалась
//WelcomePage, создаем надписи на странице
WelcomeLabel1:= TLabel.Create(WizardForm);
with WelcomeLabel1 do
begin
Left:= ScaleX(40);
Top:= ScaleY(33);
Width:= ScaleX(301);
Height:= ScaleY(50);
AutoSize:= false;
Transparent:= true;
WordWrap:= true;
Font.Size:= 14;
Font.Color:=ClWhite
Font.Style := [fsBold]
Parent:= WizardForm.WelcomePage;
Caption:= WizardForm.WelcomeLabel1.Caption;
end;
WelcomeLabel2:=TLabel.Create(WizardForm);
with WelcomeLabel2 do
begin
Left:= ScaleX(40);
Top:= ScaleY(100);
Width:= ScaleX(301);
Height:= ScaleY(300);
AutoSize:= false;
WordWrap:= true;
Transparent:= true;
Parent:= WizardForm.WelcomePage;
Caption:= WizardForm.WelcomeLabel2.Caption;
end;
//WelcomePage
//licensePage, создаем надписи, кнопки на странице
LicenseLabel1:=TLabel.Create(WizardForm)
with LicenseLabel1 do
begin
Left:=40
Top:=70
Width:=465
Height:=28
AutoSize:=False
WordWrap:=True
Transparent:=True
Caption:=WizardForm.LicenseLabel1.Caption
Parent:=WizardForm.LicensePage
end;
WizardForm.LicenseMemo.Left:=40
WizardForm.LicenseMemo.Top:=108
WizardForm.LicenseMemo.Parent:=WizardForm.LicensePage
WizardForm.LicenseAcceptedRadio.Left:=40
WizardForm.LicenseAcceptedRadio.Top:=265
WizardForm.LicenseAcceptedRadio.Width:=14
WizardForm.LicenseAcceptedRadio.Height:=14
WizardForm.LicenseAcceptedRadio.Color:=clBlack
WizardForm.LicenseAcceptedRadio.Parent:=WizardForm.LicensePage
LicenseAcceptedLabel:=TLabel.Create(WizardForm)
with LicenseAcceptedLabel do
begin
Left:=56
Top:=265
Transparent:=True
Caption:=WizardForm.LicenseAcceptedRadio.Caption
Parent:=WizardForm.LicensePage
OnClick:= @YesRadioOnClick
end;
WizardForm.LicenseNotAcceptedRadio.Left:=40
WizardForm.LicenseNotAcceptedRadio.Top:=285
WizardForm.LicenseNotAcceptedRadio.Width:=14
WizardForm.LicenseNotAcceptedRadio.Height:=14
WizardForm.LicenseNotAcceptedRadio.Color:=clBlack
WizardForm.LicenseNotAcceptedRadio.Parent:=WizardForm.LicensePage
LicenseNotAcceptedLabel:=TLabel.Create(WizardForm)
with LicenseNotAcceptedLabel do
begin
Left:=56
Top:=285
Transparent:=True
Caption:=WizardForm.LicenseNotAcceptedRadio.Caption
Parent:=WizardForm.LicensePage;
OnClick:= @NoRadioOnClick;
end;
PageNameLabel:= TLabel.Create(WizardForm);
with PageNameLabel do
begin
Left:= WizardForm.PageNameLabel.Left;
Top:= WizardForm.PageNameLabel.Top;
Width:= ScaleX(300);
Height:= ScaleY(14);
AutoSize:= False;
Font.Style:= [fsBold];
Font.Color:= ClWhite;
Transparent := True;
Parent:= WizardForm.LicensePage;
end;
PageDescriptionLabel:= TLabel.Create(WizardForm);
with PageDescriptionLabel do
begin
Left:= WizardForm.PageDescriptionLabel.Left;
Top:= WizardForm.PageDescriptionLabel.top;
Width:= ScaleX(400);
Height:= WizardForm.PageDescriptionLabel.Height;
AutoSize:= False;
Wordwrap:= True;
Transparent := True;
Parent:= WizardForm.LicensePage;
end;
//LicensePage
//InfoBeforePage
InfoBeforeClickLabel:= TLabel.Create(WizardForm);
with InfoBeforeClickLabel do
begin
Left:= ScaleX(40);
Top:= ScaleY(70)
Width:= WizardForm.InfoBeforeClickLabel.Width;
Height:= WizardForm.InfoBeforeClickLabel.Height;
Transparent:= true;
AutoSize:= False;
WordWrap:= true;
Parent:= WizardForm.InfoBeforePage;
Caption:= WizardForm.InfoBeforeClickLabel.Caption;
end;
WizardForm.InfoBeforeMemo.left:= ScaleX(40);
WizardForm.InfoBeforeMemo.Top:= ScaleY(108);
PageNameLabel2:= TLabel.Create(WizardForm);
with PageNameLabel2 do
begin
Left:= WizardForm.PageNameLabel.Left;
Top:= WizardForm.PageNameLabel.Top;
Width:= ScaleX(300);
Height:= ScaleY(14);
AutoSize:= False;
Font.Style:= [fsBold];
Font.Color:= ClWhite;
Transparent := True;
Parent:= WizardForm.InfoBeforePage;
end;
PageDescriptionLabel2:= TLabel.Create(WizardForm);
with PageDescriptionLabel2 do
begin
Left:= WizardForm.PageDescriptionLabel.Left;
Top:= WizardForm.PageDescriptionLabel.top;
Width:= ScaleX(400);
Height:= WizardForm.PageDescriptionLabel.Height;
AutoSize:= False;
Wordwrap:= True;
Transparent := True;
Parent:= WizardForm.InfoBeforePage;
end;
//InfoBeforePage
//SelectDirPage
SelectDirLabel:= TLabel.Create(WizardForm);
with SelectDirLabel do
begin
Caption:= WizardForm.SelectDirLabel.Caption;
Left:= ScaleX(40);
Top:= WizardForm.SelectDirLabel.Top + ScaleY(62);
Width:= WizardForm.SelectDirLabel.Width;
Height:= WizardForm.SelectDirLabel.Height;
Transparent := True;
Parent:= WizardForm.SelectDirPage;
end;
SelectDirLabelBrowse:= TLabel.Create(WizardForm);
with SelectDirLabelBrowse do
begin
Caption:= WizardForm.SelectDirBrowseLabel.Caption;
Left:= ScaleX(40);
Top:= WizardForm.SelectDirBrowseLabel.Top + ScaleY(62);
Width:= WizardForm.SelectDirBrowseLabel.Width;
Height:= WizardForm.SelectDirBrowseLabel.Height;
WordWrap:= True;
Transparent:= True;
Parent:= WizardForm.SelectDirPage;
end;
PageNameLabel3:= TLabel.Create(WizardForm);
with PageNameLabel3 do
begin
Left:= WizardForm.PageNameLabel.Left;
Top:= WizardForm.PageNameLabel.Top;
Width:= ScaleX(300);
Height:= ScaleY(14);
AutoSize:= False;
Font.Style:= [fsBold];
Font.Color:= ClWhite;
Transparent := True;
Parent:= WizardForm.SelectDirPage;
end;
PageDescriptionLabel3:= TLabel.Create(WizardForm);
with PageDescriptionLabel3 do
begin
Left:= WizardForm.PageDescriptionLabel.Left;
Top:= WizardForm.PageDescriptionLabel.top;
Width:= ScaleX(400);
Height:= WizardForm.PageDescriptionLabel.Height;
AutoSize:= False;
Wordwrap:= True;
Transparent := True;
Parent:= WizardForm.SelectDirPage;
end;
DirectX:= TCheckBox.Create(WizardForm);
with DirectX do
begin
Parent:= WizardForm.SelectDirPage;
Left:= WizardForm.DirEdit.Left + 200;
Top:= WizardForm.DirEdit.Top + 35;
Width:= ScaleX(14);
Height:= ScaleY(14);
TabOrder:= 0;
Checked:= False;
end;
DirectXLabel:= TLabel.Create(WizardForm);
with DirectXLabel do
begin
Caption:= ExpandConstant('{cm:DRT}');
Left:= WizardForm.DirEdit.Left + 220;
Top:= WizardForm.DirEdit.Top + 35;
Width:= ScaleX(150);
Height:= ScaleY(13);
Transparent := True;
Parent:= WizardForm.SelectDirPage;
OnClick:= @DirectXLabelOnClick;
end;
Redist:= TCheckBox.Create(WizardForm);
with Redist do
begin
Parent:= WizardForm.SelectDirPage;
Left:= WizardForm.DirEdit.Left + 200;
Top:= WizardForm.DirEdit.Top + 70;
Width:= ScaleX(14);
Height:= ScaleY(14);
TabOrder:= 1;
Checked:= False;
end;
RedistLabel:= TLabel.Create(WizardForm);
with RedistLabel do
begin
Caption:=ExpandConstant('{cm:Redist}');
Left:= WizardForm.DirEdit.Left + 220;
Top:= WizardForm.DirEdit.Top + 70;
Width:= ScaleX(150);
Height:= ScaleY(13);
Transparent := True;
Parent:= WizardForm.SelectDirPage;
OnClick:= @RedistOnClick;
end;
Icons:= TCheckBox.Create(WizardForm);
with Icons do
begin
Parent:= WizardForm.SelectDirPage;
Left:= WizardForm.DirEdit.Left;
Top:= WizardForm.DirEdit.Top + 35;
Width:= ScaleX(14);
Height:= ScaleY(14);
TabOrder:= 2;
Checked:= False;
end;
IconsLabel:= TLabel.Create(WizardForm);
with IconsLabel do
begin
Caption:=ExpandConstant('{cm:Icons}');
Left:= WizardForm.DirEdit.Left + 20;
Top:= WizardForm.DirEdit.Top + 35;
Width:= ScaleX(150);
Height:= ScaleY(13);
Transparent := True;
Parent:= WizardForm.SelectDirPage;
OnClick:= @IconsOnClick;
end;
Group:= TCheckBox.Create(WizardForm);
with Group do
begin
Parent:= WizardForm.SelectDirPage;
Left:= WizardForm.DirEdit.Left;
Top:= WizardForm.DirEdit.Top + 70;
Width:= ScaleX(14);
Height:= ScaleY(14);
TabOrder:= 3;
Checked:= False;
end;
GroupLabel:= TLabel.Create(WizardForm);
with GroupLabel do
begin
Caption:=ExpandConstant('{cm:Group}');
Left:= WizardForm.DirEdit.Left + 20;
Top:= WizardForm.DirEdit.Top + 70;
Width:= ScaleX(150);
Height:= ScaleY(13);
Transparent := True;
Parent:= WizardForm.SelectDirPage;
OnClick:= @GroupOnClick;
end;
NeedSpaceLabel:= TLabel.Create(WizardForm);
with NeedSpaceLabel do
begin
Parent:= WizardForm.SelectDirPage;
Left:= WizardForm.DirEdit.Left;
Top:= ScaleY(262);
Width:= ScaleX(209);
Height:= ScaleY(13);
Transparent:= True;
end;
FreeSpaceLabel:= TLabel.Create(WizardForm);
with FreeSpaceLabel do
begin
Parent:= WizardForm.SelectDirPage;
Left:= WizardForm.DirEdit.Left;
Top:= ScaleY(250);
Width:= ScaleX(209);
Height:= ScaleY(13);
Transparent:= True;
end;
WizardForm.DirEdit.OnChange:= @GetFreeSpaceCaption;
WizardForm.DirEdit.Text:= WizardForm.DirEdit.Text + #0;
//SelectDirPage
//SelectComponentPage
SelectComponentsLabel:= TLabel.Create(WizardForm)
with SelectComponentsLabel do
begin
Left:= ScaleX(40);
Top:= SelectDirLabel.Top;
Width:= WizardForm.SelectComponentsLabel.Width;
Height:= WizardForm.SelectComponentsLabel.Height;
Autosize:= false;
WordWrap:= true;
Transparent:= true;
Caption:= WizardForm.SelectComponentsLabel.Caption;
Parent:= WizardForm.SelectComponentsPage;
end;
WizardForm.TypesCombo.Left:= ScaleX(40);
WizardForm.TypesCombo.Top:= ScaleY(120)
WizardForm.TypesCombo.Font.Color:= clBlack;
WizardForm.ComponentsList.Left:= ScaleX(40)
WizardForm.ComponentsList.Top:= ScaleY(155);
WizardForm.ComponentsList.Font.Color:= clBlack;
ComponentsDiskSpaceLabel:= TLabel.Create(WizardForm);
with ComponentsDiskSpaceLabel do
begin
Left:= ScaleX(40);
Top:= ScaleY(295);
Width:= WizardForm.ComponentsDiskSpaceLabel.Width;
Height:= WizardForm.ComponentsDiskSpaceLabel.Height;
Autosize:= false;
WordWrap:= true;
Transparent:= true;
Caption:= WizardForm.ComponentsDiskSpaceLabel.Caption;
Parent:= WizardForm.SelectComponentsPage;
end;
PageNameLabel4:= TLabel.Create(WizardForm);
with PageNameLabel4 do
begin
Left:= WizardForm.PageNameLabel.Left;
Top:= WizardForm.PageNameLabel.Top;
Width:= ScaleX(300);
Height:= ScaleY(14);
AutoSize:= False;
Font.Style:= [fsBold];
Font.Color:= ClWhite;
Transparent := True;
Parent:= WizardForm.SelectComponentsPage;
end;
PageDescriptionLabel4:= TLabel.Create(WizardForm);
with PageDescriptionLabel4 do
begin
Left:= WizardForm.PageDescriptionLabel.Left;
Top:= WizardForm.PageDescriptionLabel.top;
Width:= ScaleX(400);
Height:= WizardForm.PageDescriptionLabel.Height;
AutoSize:= False;
Wordwrap:= True;
Transparent := True;
Parent:= WizardForm.SelectComponentsPage;
end;
//SelectComponentPage
//ProgrammGroupPage
SelectStartMenuFolderLabel:=TLabel.Create(WizardForm)
with SelectStartMenuFolderLabel do
begin
Left:= ScaleX(40);
Top:= WizardForm.SelectDirLabel.Top + ScaleY(62);
Width:= WizardForm.SelectDirBrowseLabel.Width;
Height:= WizardForm.SelectDirBrowseLabel.Height;
AutoSize:=False
WordWrap:=True
Transparent:=True
Caption:=WizardForm.SelectStartMenuFolderLabel.Caption
Parent:=WizardForm.SelectProgramGroupPage
end;
SelectStartMenuFolderBrowseLabel:=TLabel.Create(WizardForm)
with SelectStartMenuFolderBrowseLabel do
begin
Left:= ScaleX(40);
Top:= WizardForm.SelectDirBrowseLabel.Top + ScaleY(62);
Width:= WizardForm.SelectDirBrowseLabel.Width
Height:= WizardForm.SelectDirBrowseLabel.Height
AutoSize:=False
WordWrap:=True
Transparent:=True
Caption:=WizardForm.SelectStartMenuFolderBrowseLabel.Caption
Parent:=WizardForm.SelectProgramGroupPage
end;
WizardForm.NoIconsCheck.Left:=ScaleX(40);
WizardForm.NoIconsCheck.Top:= WizardForm.DirEdit.Top + ScaleY(140)
WizardForm.NoIconsCheck.Width:=13
WizardForm.NoIconsCheck.Height:=13
WizardForm.NoIconsCheck.Visible:=True
WizardForm.NoIconsCheck.Parent:= WizardForm.SelectProgramGroupPage
NoIconsLabel:=TLabel.Create(WizardForm)
with NoIconsLabel do
begin
Left:=ScaleX(56);
Top:= WizardForm.DirEdit.Top + ScaleY(140)
Transparent:=True
OnClick:= @NoIconsLabelOnClick
Caption:=WizardForm.NoIconsCheck.Caption
Parent:=WizardForm.SelectProgramGroupPage
end;
PageNameLabel5:= TLabel.Create(WizardForm);
with PageNameLabel5 do
begin
Left:= WizardForm.PageNameLabel.Left;
Top:= WizardForm.PageNameLabel.Top;
Width:= ScaleX(300);
Height:= ScaleY(14);
AutoSize:= False;
Font.Style:= [fsBold];
Font.Color:= ClWhite;
Transparent := True;
Parent:= WizardForm.SelectProgramGroupPage;
end;
PageDescriptionLabel5:= TLabel.Create(WizardForm);
with PageDescriptionLabel5 do
begin
Left:= WizardForm.PageDescriptionLabel.Left;
Top:= WizardForm.PageDescriptionLabel.top;
Width:= ScaleX(400);
Height:= WizardForm.PageDescriptionLabel.Height;
AutoSize:= False;
Wordwrap:= True;
Transparent := True;
Parent:= WizardForm.SelectProgramGroupPage;
end;
//ProgrammGroupPage
//InstallingPage
StatusLabel:= TLabel.Create(WizardForm);
with StatusLabel do
begin
Left:= ScaleX(20);
Top:= ScaleY(80);
Width:= WizardForm.StatusLabel.Width;
Height:= WizardForm.StatusLabel.Height;
AutoSize:= False;
Transparent := True;
Parent:= WizardForm.InstallingPage;
Caption:= 'Распаковка файлов...'
end;
FilenameLabel:= TLabel.Create(WizardForm);
with FilenameLabel do
begin
Left:= ScaleX(20);
Top:= ScaleY(100);
Width:= WizardForm.StatusLabel.Width;
Height:= WizardForm.StatusLabel.Height;
AutoSize:= False;
Transparent := True;
Parent:= WizardForm.InstallingPage;
end;
PageNameLabel7:= TLabel.Create(WizardForm);
with PageNameLabel7 do
begin
Left:= WizardForm.PageNameLabel.Left;
Top:= WizardForm.PageNameLabel.Top;
Width:= ScaleX(300);
Height:= ScaleY(14);
AutoSize:= False;
Font.Style:= [fsBold];
Font.Color:= ClWhite;
Transparent := True;
Parent:= WizardForm.InstallingPage;
end;
PageDescriptionLabel7:= TLabel.Create(WizardForm);
with PageDescriptionLabel7 do
begin
Left:= WizardForm.PageDescriptionLabel.Left;
Top:= WizardForm.PageDescriptionLabel.top;
Width:= ScaleX(400);
Height:= WizardForm.PageDescriptionLabel.Height;
AutoSize:= False;
Wordwrap:= True;
Transparent := True;
Parent:= WizardForm.InstallingPage;
end;
//InstallingPage
//InfoAfterPage
InfoAfterClickLabel:= TLabel.Create(WizardForm);
with InfoAfterClickLabel do
begin
Left:= ScaleX(40);
Top:= ScaleY(70)
Width:= WizardForm.InfoAfterClickLabel.Width;
Height:= WizardForm.InfoAfterClickLabel.Height;
Transparent:= true;
AutoSize:= False;
WordWrap:= true;
Parent:= WizardForm.InfoAfterPage;
Caption:= WizardForm.InfoAfterClickLabel.Caption;
end;
WizardForm.InfoAfterMemo.left:= ScaleX(40);
WizardForm.InfoAfterMemo.Top:= ScaleY(108);
PageNameLabel8:= TLabel.Create(WizardForm);
with PageNameLabel8 do
begin
Left:= WizardForm.PageNameLabel.Left;
Top:= WizardForm.PageNameLabel.Top;
Width:= ScaleX(300);
Height:= ScaleY(14);
AutoSize:= False;
Font.Style:= [fsBold];
Font.Color:= ClWhite;
Transparent := True;
Parent:= WizardForm.InfoAfterPage;
end;
PageDescriptionLabel8:= TLabel.Create(WizardForm);
with PageDescriptionLabel8 do
begin
Left:= WizardForm.PageDescriptionLabel.Left;
Top:= WizardForm.PageDescriptionLabel.top;
Width:= ScaleX(400);
Height:= WizardForm.PageDescriptionLabel.Height;
AutoSize:= False;
Wordwrap:= True;
Transparent := True;
Parent:= WizardForm.InfoAfterPage;
end;
//InfoAfterPage
//FinishedPage
FinishedHeadingLabel:=TLabel.Create(WizardForm);
with FinishedHeadingLabel do
begin
Top:= ScaleY(33);
Left:= ScaleX(40);
Width:= ScaleX(301);
Height:= ScaleY(53);
AutoSize:= false;
WordWrap:= true;
Font.Size:= 14;
Font.Color:=ClWhite
Font.Style := [fsBold]
Transparent:= true;
Parent:= WizardForm.FinishedPage;
Caption:= WizardForm.FinishedHeadingLabel.Caption;
end;
FinishedLabel:= TLabel.Create(WizardForm);
with FinishedLabel do
begin
Left:= ScaleX(40);
Top:= ScaleY(100);
Width:= ScaleX(301);
Height:= ScaleY(54);
AutoSize:= false;
WordWrap:= true;
Transparent:= true;
Parent:= WizardForm.FinishedPage;
Caption:= ExpandConstant('{cm:Finished1}') + #10#13#10 + ExpandConstant('{cm:Finished2}')
end;
RunProgram:= TCheckBox.Create(WizardForm);
with RunProgram do
begin
Parent:= WizardForm.FinishedPage;
Left:= ScaleX(176);
Top:= ScaleY(200);
Width:= ScaleX(14);
Height:= ScaleY(14);
TabOrder:= 4;
Checked:= True;
end;
RunProgramLabel:= TLabel.Create(WizardForm);
with RunProgramLabel do
begin
Caption:=ExpandConstant('{cm:RunProgram}');
Left:= ScaleX(196);
Top:= ScaleY(200);
Width:= ScaleX(150);
Height:= ScaleY(13);
Transparent := True;
Parent:= WizardForm.FinishedPage;
OnClick:= @RunProgramOnClick;
end;
//FinishedPage
end;
///////
procedure LoadSkin(lpszPath: String; lpszIniFileName: String); external 'LoadSkin@files:isskin.dll stdcall';
procedure UnloadSkin(); external 'UnloadSkin@files:isskin.dll stdcall';
function ShowWindow(hWnd: Integer; uType: Integer): Integer; external 'ShowWindow@user32.dll stdcall';
function InitializeSetup:boolean;
begin
ExtractTemporaryFile('black.cjstyles');
LoadSkin(ExpandConstant('{tmp}')+'\black.cjstyles', '');
Result:=True;
end;