Вопрос Окно Деинсталлятора

Код:
procedure InitializeUninstallProgressForm;
var
  Label1: TLabel;

  h:HWND;
  begin
    UninstallProgressForm.AutoScroll := False;
    UninstallProgressForm.ClientWidth := ScaleX(394);
    UninstallProgressForm.ClientHeight := ScaleY(101);
    UninstallProgressForm.Caption :=ExpandConstant('{cm:Uninstall}');

    UninstallProgressForm.InnerNotebook.Left := ScaleX(0);
    UninstallProgressForm.InnerNotebook.Top := ScaleY(0);
    UninstallProgressForm.InnerNotebook.Width := ScaleX(394);
    UninstallProgressForm.InnerNotebook.Height := ScaleY(65);

    UninstallProgressForm.InnerNotebook.Left := ScaleX(0);
    UninstallProgressForm.InnerNotebook.Top := ScaleY(0);
    UninstallProgressForm.OuterNotebook.Width := ScaleX(394);
    UninstallProgressForm.OuterNotebook.Height := ScaleY(65);

    UninstallProgressForm.ProgressBar.Left := ScaleX(10);
    UninstallProgressForm.ProgressBar.Top := ScaleY(45);
    UninstallProgressForm.ProgressBar.Width := ScaleX(374);
    UninstallProgressForm.ProgressBar.Height := ScaleY(15);

    UninstallProgressForm.Color:=clMenu;
    UninstallProgressForm.InstallingPage.Color:=clMenu;
    UninstallProgressForm.Position := poScreenCenter;

    UninstallProgressForm.Bevel.Hide;
    UninstallProgressForm.StatusLabel.Hide;
    UninstallProgressForm.MainPanel.Hide;
    UninstallProgressForm.WizardSmallBitmapImage.Hide;

    UninstallProgressForm.CancelButton.Left := ScaleX(305);
    UninstallProgressForm.CancelButton.Top := ScaleY(70);
    UninstallProgressForm.CancelButton.Width := ScaleX(80);
    UninstallProgressForm.CancelButton.Height := ScaleY(25);
    
  //////////// íàñòðîéêà äåèíñòàëÿòîðà///////////////////////////
  
  Label1 := TLabel.Create(UninstallProgressForm.InstallingPage);
  with Label1 do
  begin
    Parent := UninstallProgressForm.InstallingPage;
    Caption :=ExpandConstant('{cm:StatusUninstall}');
    AutoSize:=False;
    Left := ScaleX(10);   /////  Left — ëåâûé êðàé ïðîãðåññ-áàðà;
    Top := ScaleY(0);     /////  Top — âåðõíèé êðàé ïðîãðåññ-áàðà;
    Width := ScaleX(400);  ////  Width — øèðèíà ïðîãðåññ-áàðà;
    Height := ScaleY(70);  ///// Height — âûñîòà ïðîãðåññ-áàðà.
    Transparent:= true;
    WordWrap:= true;
    Font.Size:=8;
    Font.Color:=clWindowText;
    Font.Style:=[fsBold];
    Font.Name:='Tahoma';
  end;
    h:=UninstallProgressForm.Handle;

    UninstallProgressForm.CancelButton.Visible:=True;
    UninstallProgressForm.CancelButton.Enabled := True;
end;
[/SPOILER]
 
#ifdef ANSI
#define A "W"
#else
#define A "A"
#endif

#define Font "OpenSans-Regular.ttf"
#define FontName "Open Sans"

#define Font2 "OpenSans-Semibold.ttf"
#define FontName2 "Open Sans Semibold"

#define NeedInstallSize 5734
#define NeedMem 512

// '#39' = ' // '#45' = - //

#define AppName "Hitman2'#39'Silent '#45' Assassin"
#define AppName2 "Hitman 2 Silent Assassin"
#define MyAppExe "hitman2.exe"
#define MyAppIcon "hitman2.exe"

;#define Password "" ;ïàðîëü íà àðõèâ
#define MyInfoVer "1.01" ;âåðñèÿ èíñòàëëÿòîðà
#define AppVer "1.1.1.271" ;âåðñèÿ èãðû
#define ApRePack "RePack by EvilAlex " ;ðåëèç

#define SecondProgressBar

#define records

#define facompress

;#define Redist

#define Slides

[Setup]
AppName={#AppName2}
AppVersion={#AppVer}

VersionInfoDescription=Installer {#AppName2}
VersionInfoProductName=RePack {#AppName2}
AppCopyright={#ApRePack}
VersionInfoVersion={#MyInfoVer}

DefaultDirName={pf}\{#AppName2}
DefaultGroupName={#AppName2}

SetupIconFile=InstallFiles\inicon.ico
UninstallIconFile=InstallFiles\unicon.ico

RawDataResource=font:InstallFiles\{#Font} | font2:InstallFiles\{#Font2}

InternalCompressLevel=ultra64
Compression=lzma2/ultra64
SolidCompression=true

//DiskSpanning=yes
//DiskSliceSize=52000000

DisableReadyPage=true
DisableProgramGroupPage=true
ShowComponentSizes=false

[UninstallDelete]
Type: filesandordirs; Name: {app}

[Files]
Source: InstallFiles\*; DestDir: {tmp}; Flags: dontcopy noencryption
#ifdef Redist
Source: Redist\*; DestDir: "{tmp}\Redist"; MinVersion: 0.0,5.0; Flags: ignoreversion
#endif
Source: Include\Russian.ini; DestDir: {tmp}; Flags: dontcopy
Source: Include\unarc.dll; DestDir: {tmp}; Flags: dontcopy
#ifdef facompress
Source: Include\facompress.dll; DestDir: {tmp}; Flags: dontcopy
#endif
#ifdef records
Source: Include\records.inf; DestDir: {tmp}; Flags: dontcopy
#endif
#ifdef Slides
Source: Slides\isSlideShow.dll; DestDir: {tmp}; Flags: dontcopy
Source: Slides\01.png; DestDir: {tmp}; Flags: dontcopy
Source: Slides\02.png; DestDir: {tmp}; Flags: dontcopy
Source: Slides\03.png; DestDir: {tmp}; Flags: dontcopy
Source: Slides\InnoCallback.dll; DestDir: {tmp}; Flags: dontcopy
#endif

[Languages]
Name: "russian"; MessagesFile: "compiler:Languages\Russian.isl"

#include "Modules\CustomMessages.iss"

[Icons]
Name: "{group}\{#AppName2}"; Filename: "{app}\{#MyAppExe}"; IconFilename: {app}\{#MyAppIcon}; Check: groupicon and CheckError
Name: "{group}\Óäàëèòü {#AppName2}"; Filename: {uninstallexe}; Check: groupicon and CheckError
Name: "{userdesktop}\{#AppName2}"; Filename: "{app}\{#MyAppExe}"; IconFilename: {app}\{#MyAppIcon}; Check: desktopicon and CheckError
Name: "{userappdata}\RePack by EvilAlex\{#AppName2}"; Filename: "{app}\{#MyAppExe}"; IconFilename: {app}\{#MyAppIcon}; Check: quicklaunchicon and CheckError

#ifdef Redist
[Run]
Filename: {tmp}\Redist\dxwebsetup.exe; Parameters: /q; WorkingDir: {tmp}\Redist\; Check: DirectXCheck and CheckError
Filename: {tmp}\Redist\VC_redist.x86.exe; Parameters: /S /I; WorkingDir: {tmp}\Redist\; Check: not IsWin64 and VCRedistCheck and CheckError
Filename: {tmp}\Redist\VC_redist.x64.exe; Parameters: /S /I; WorkingDir: {tmp}\Redist\; Check: IsWin64 and VCRedistCheck and CheckError
#endif

Код:
var
  WelcomeLabel,WelcomeLabel1,WelcomeLabel2,Dirlabel,Grouplabel,Iconslabel,Compslabel,Statuslabel,Label1: TLabel;
  Bevel2,BevelPanel1,BevelPanel2: TBevel;
  Frame,Panel1,Panel2,Panel3: TPanel;
  Desktop,StartMenu,QuickLaunch,DirectX,VCRedist: TCheckBox;
  bmpfile,BmpFile1:TBitmapImage;
  BigOk, BigFail, BigWarn, BigInst: Longint;
#ifdef Slides
  TimerID: LongWord;
  CurrentPicture:integer;
  PicList: TStringlist;
#endif



#include "Modules\botva2.iss"
#include "Modules\TFont.iss"
#include "Modules\WinTB.iss"
#include "Modules\Uninstall.iss"

const
  A1='À';
  Z1='ß';
  A2='à';
  Z2='ÿ';
  X1='¸';
  X2='¨';

function NextButtonClick(CurPageID: Integer): Boolean;
var
  i: integer;
  c: char;
begin
   Result := True;
   if CurPageID = wpSelectDir then begin
      for i:=1 to length(WizardForm.DirEdit.text) do begin
         c:=WizardForm.DirEdit.text[i];
         if (c>=A1)and(c<=Z1) or (c>=A2)and(c<=Z2) or (c=X1) or (c=X2) then begin
            MsgBox( 'Â ïóòè óñòàíîâêè ïðèñóòñòâóþò ðóññêèå áóêâû, ÷òî íåäîïóñòèìî'#13#13'Ïîæàëóéñòà, ïîâòîðèòå ââîä.', mbError, mb_Ok);
            Result := False ;
            exit;
         end;
      end;
   end;
end;

type
  TProc=procedure(HandleW, msg, idEvent, TimeSys: LongWord);

#ifdef Slides
function WrapTimerProc(callback:TProc; paramcount:integer):longword; external 'wrapcallback@files:InnoCallback.dll stdcall';
function SetTimer(hWnd, nIDEvent, uElapse, lpTimerFunc: LongWord): LongWord; external 'SetTimer@user32.dll stdcall';
function KillTimer(hWnd, nIDEvent: LongWord): LongWord; external 'KillTimer@user32.dll stdcall';
function GetSystemMetrics(nIndex:Integer):Integer; external 'GetSystemMetrics@user32.dll stdcall';
procedure InitializeSlideShow(Hwnd:Thandle; l,t,w,h:integer;Animate:boolean; Stretch:integer); external 'InitializeSlideShow@files:isslideshow.dll stdcall';
procedure DeinitializeSlideShow; external 'DeinitializeSlideShow@files:isslideshow.dll stdcall';
procedure ShowImage(ipath:PAnsiChar; Effect:integer); external 'ShowImage@files:isslideshow.dll stdcall';
#endif

function InitializeSetup(): Boolean;
begin
  if not FileExists(ExpandConstant('{tmp}\b2p.dll')) then ExtractTemporaryFile('b2p.dll');
  if not FileExists(ExpandConstant('{tmp}\WinTB.dll')) then ExtractTemporaryFile('WinTB.dll');
  if not FileExists(ExpandConstant('{tmp}\botva2.dll')) then ExtractTemporaryFile('botva2.dll');
  if not FileExists(ExpandConstant('{tmp}\CallbackCtrl.dll')) then ExtractTemporaryFile('CallbackCtrl.dll');
  Result := True;
end;

procedure WizardFormInit;
begin
  ExtractTemporaryFile('no.bmp');
  ExtractTemporaryFile('ok.bmp');
  ExtractTemporaryFile('BG.png');
  ExtractTemporaryFile('BigOk.png');
  ExtractTemporaryFile('BigFail.png');
  ExtractTemporaryFile('BigWarn.png');
  ExtractTemporaryFile('BigInst.png');

  ExtractTemporaryFile('CallbackCtrl.dll');
  ExtractTemporaryFile('botva2.dll');

  with WizardForm do begin
    ClientWidth:=ScaleX(660);  // ðàçìåð îêíà  //
    ClientHeight:=ScaleY(405);
    AutoScroll := False;
    Position := poScreenCenter;
    Color := 13948116;
    InnerNotebook.Hide;
    OuterNotebook.Hide;
    Bevel.Hide;
    Caption := '{#AppName}';
    Application.Title := '{#AppName}';
  end;
  //
  Frame := TPanel.Create(WizardForm);
  with Frame do
  begin
    Parent := WizardForm;
    Left := ScaleX(0);
    Top := ScaleY(0);
    Width := ScaleX(660);
    Height := ScaleY(354);
    Color := 13948116;
    BevelOuter := bvNone;
  end;
  //////////////////////////////////////////////////////
  Bevel2 := TBevel.Create(WizardForm);
  with Bevel2 do
  begin
    Parent := WizardForm;
    Left := ScaleX(30);
    Top := WizardForm.Height-ScaleX(80);
    Width := ScaleX(600);
    Height := ScaleY(2);
  end;

  ImgLoad(Frame.Handle,ExpandConstant('{tmp}\BG.png'),0,0,ScaleX(660),ScaleY(354),True,True);

  BigOk:=ImgLoad(Frame.Handle,ExpandConstant('{tmp}\BigOk.png'),ScaleX(301),ScaleY(50),ScaleX(58),ScaleY(58),True,True);
  BigFail:=ImgLoad(Frame.Handle,ExpandConstant('{tmp}\BigFail.png'),ScaleX(301),ScaleY(50),ScaleX(58),ScaleY(58),True,True);
  BigWarn:=ImgLoad(Frame.Handle,ExpandConstant('{tmp}\BigWarn.png'),ScaleX(301),ScaleY(50),ScaleX(58),ScaleY(58),True,True);
  //BigInst:=ImgLoad(Frame.Handle,ExpandConstant('{tmp}\BigInst.png'),ScaleX(301),ScaleY(50),ScaleX(58),ScaleY(58),True,True);
  

  Label1 := TLabel.Create(WizardForm);
  with Label1 do
  begin
    Parent := WizardForm;
    Caption := '{#ApRePack}';
    Left := ScaleX(85);
    Top := ScaleY(370);
    Width := ScaleX(178);
    Height := ScaleY(25);
    AutoSize:= false;
    Font.Name := '{#FontName}';
    Transparent:= true;
    WordWrap:= true;
    AutoSize:= false;
    Font.Size:=10;
    Font.Color := clBtnShadow;
    Font.Style := [fsBold];
  end;
end;

////////////////////////////////////
#include "Modules\NSize.iss"
////////////////////////////////////

function desktopicon: Boolean;
begin
  Result:=Desktop.Checked;
end;

function groupicon: Boolean;
begin
  Result:= StartMenu.Checked;
end;

procedure StartMenuOnClick(Sender: TObject);
begin
  WizardForm.GroupEdit.Enabled:= StartMenu.Checked;
  WizardForm.GroupBrowseButton.Enabled:= StartMenu.Checked;
end;

function quicklaunchicon: Boolean;
begin
  Result:=QuickLaunch.Checked;
end;
////////////////////////////////////
function DirectXCheck: Boolean;
begin
  StatusLabel.Caption:=ExpandConstant('{cm:Doppo1}');
  Result:=DirectX.Checked;
end;

function VCRedistCheck: Boolean;
begin
  StatusLabel.Caption:=ExpandConstant('{cm:Doppo2}');
  Result:=VCRedist.Checked;
end;
////////////////////////////////////
#include "Modules\ISDone.iss"
////////////////////////////////////

////////////////íàñòðîéêà êíîïîê///////////////

procedure RedesignWizardForm;
begin
  with WizardForm.CancelButton do
  begin
    Parent := WizardForm;
    Left := ScaleX(500);
    Top := ScaleY(368);
    Width:= ScaleX(75);
    Height:= ScaleY(23);
  end;

  with WizardForm.NextButton do
  begin
    Parent := WizardForm;
    Left := ScaleX(400);
    Top := ScaleY(368);
    Width:= ScaleX(75);
    Height:= ScaleY(23);
  end;

  with WizardForm.BackButton do
  begin
    Parent := WizardForm;
    Left := ScaleX(300);
    Top := ScaleY(368);
    Width:= ScaleX(75);
    Height:= ScaleY(23);
  end;

  ///////////////////êîíåö íàñòðîéêè êíîïîê///////////////////
  
  WelcomeLabel:= TLabel.Create(WizardForm);
  with WelcomeLabel do
  begin
    AutoSize:= false;
    Parent := Frame;
    Alignment := taCenter;
    Font.Size:=14;
    Top := ScaleY(95);
    Left := ScaleX(30);
    Width := ScaleX(600);
    Height := ScaleX(100);
    Caption :=ExpandConstant('{cm:WelcomeLabel}');
    Font.Name := '{#FontName}';
    Transparent:= True;
  end;

  WelcomeLabel1:= TLabel.Create(WizardForm);
  with WelcomeLabel1 do
  begin
    AutoSize:= false;
    Parent := Frame;
    Alignment := taCenter;
    Font.Size:=16;
    Top :=WelcomeLabel.Top+ScaleY(30);
    Left := ScaleX(30);
    Width := ScaleX(600);
    Height := ScaleX(100);
    Caption := '{#AppName}';
    Font.Name := '{#FontName2}';
    Transparent:= True;
  end;

  WelcomeLabel2:= TLabel.Create(WizardForm);
  with WelcomeLabel2 do
  begin
    Parent := Frame;
    AutoSize:= false;
    Font.Name := '{#FontName}';
    Alignment := taCenter;
    Transparent:= true;
    WordWrap:= true;
    Top :=WelcomeLabel1.Top+ScaleY(100);
    Left := ScaleX(30);
    Width := ScaleX(600);
    Height := ScaleX(200);
    Caption :=ExpandConstant('{cm:WelcomeLabel2}');
  end;
  //////////////////////////////////////////////////////
  Panel1 := TPanel.Create(WizardForm);
  with Panel1 do
  begin
    Parent := Frame;
    Left := ScaleX(10);
    Top := ScaleY(92);
    Width := ScaleX(642);
    Height := ScaleY(136);
    BevelInner := bvSpace;
    BevelOuter := bvLowered;
    ParentBackground := False;
    Color := 13948116;
  end;

  BevelPanel1 := TBevel.Create(WizardForm);
  with BevelPanel1 do
  begin
    Parent := Panel1;
    Left := ScaleX(492);
    Top := ScaleX(1);
    Width := ScaleX(2);
    Height := Panel1.Height-ScaleY(2);
  end;
  //////////////////////////////////////////////////////
  Panel2 := TPanel.Create(WizardForm);
  with Panel2 do
  begin
    Parent := Frame;
    Left := ScaleX(10);
    Top := Panel1.Top+Panel1.Height+ScaleY(15);
    Width := ScaleX(642);
    Height := ScaleY(96);
    BevelInner := bvSpace;
    BevelOuter := bvLowered;
    ParentBackground := False;
    Color := 13948116;
  end;

  BevelPanel2 := TBevel.Create(WizardForm);
  with BevelPanel2 do
  begin
    Parent := Panel2;
    Left := ScaleX(321);
    Top := ScaleX(1);
    Width := ScaleX(2);
    Height := Panel2.Height-ScaleY(2);
  end;
  //////////////////////////////////////////////////////

  Dirlabel:= TLabel.Create(WizardForm);
  with Dirlabel do
  begin
    Parent := Panel1;
    Left := ScaleY(8);
    Top := ScaleX(13);
    Font.Name := '{#FontName2}';
    Caption :=ExpandConstant('{cm:Dirlabel}');
    Transparent:= True;
  end;
          
  with WizardForm.DirEdit do
  begin
    Parent := Panel1;
    Top := ScaleY(40);
    Left := ScaleX(20);
    Width := ScaleX(360);
    Font.Name := '{#FontName2}';
    Font.Color := clGreen;
  end;

  with WizardForm.DirBrowseButton do
  begin
    Parent := Panel1;
    Top := WizardForm.DirEdit.Top+ScaleY(-1);
    Left := WizardForm.DirEdit.Width+WizardForm.DirEdit.Left+ScaleX(20);
  end;

  Grouplabel:= TLabel.Create(WizardForm);
  with Grouplabel do
  begin
    Parent := Panel1;
    Left := ScaleY(8);
    Top := WizardForm.DirEdit.Top+WizardForm.DirEdit.Height+ScaleY(12);
    Font.Name := '{#FontName2}';
    Caption :=ExpandConstant('{cm:Grouplabel}');
    Transparent:= True;
  end;

  with WizardForm.GroupEdit do
  begin
    Parent := Panel1;
    Top := WizardForm.DirEdit.Top+ScaleY(60);
    Left := ScaleX(20);
    Width := ScaleX(360);
    Font.Name := '{#FontName2}';
    Font.Color := clGreen;
  end;

  with WizardForm.GroupBrowseButton do
  begin
    Parent := Panel1;
    Top := WizardForm.GroupEdit.Top+ScaleY(-1);
    Left := WizardForm.GroupEdit.Width+WizardForm.GroupEdit.Left+ScaleX(20);
  end;
  //////////////////////////////////////////////////////

  TotalSpaceLabel:= TLabel.Create(WizardForm);
  with TotalSpaceLabel do
  begin
    AutoSize:= False;
    Parent := Panel1;
    Left := ScaleX(500);
    Top := ScaleX(13);
    Width := ScaleX(150);
    Height := Panel2.Height-ScaleY(2);
    Font.Name := '{#FontName2}';
    Transparent:= True;
  end;

  FreeSpaceLabel1:= TLabel.Create(WizardForm);
  with FreeSpaceLabel1 do
  begin
    AutoSize:= False;
    Parent := Panel1;
    Left := TotalSpaceLabel.Left;
    Top := TotalSpaceLabel.Top+ScaleX(43);
    Width := ScaleX(150);
    Height := Panel2.Height-ScaleY(2);
    Font.Name := '{#FontName2}';
    Transparent:= True;
    Caption:= ExpandConstant('{cm:Spacelabel1}');
  end;

  FreeSpaceLabel2:= TLabel.Create(WizardForm);
  with FreeSpaceLabel2 do
  begin
    AutoSize:= False;
    Parent := Panel1;
    Left := TotalSpaceLabel.Left+ScaleX(15);
    Top := TotalSpaceLabel.Top+ScaleX(59);
    Width := ScaleX(150);
    Height := Panel2.Height-ScaleY(2);
    Font.Name := '{#FontName2}';
    Transparent:= True;
  end;

  InstallSpacelabel:= TLabel.Create(WizardForm);
  with InstallSpacelabel do
  begin
    AutoSize:= False;
    Parent := Panel1;
    Left := TotalSpaceLabel.Left;
    Top := FreeSpaceLabel1.Top+ScaleX(45);
    Width := ScaleX(150);
    Height := Panel2.Height-ScaleY(2);
    Font.Name := '{#FontName2}';
    Transparent:= True;
  end;

  BmpFile:= TBitmapImage.Create(WizardForm);
  BmpFile.Bitmap.LoadFromFile(ExpandConstant('{tmp}\ok.bmp'));
  BmpFile.SetBounds(ScaleX(500), FreeSpaceLabel2.Top+ScaleY(2), ScaleX(12), ScaleY(12));
  BmpFile.Stretch:= true
  BmpFile.Parent:= Panel1;

  BmpFile1:= TBitmapImage.Create(WizardForm);
  BmpFile1.Bitmap.LoadFromFile(ExpandConstant('{tmp}\no.bmp'));
  BmpFile1.SetBounds(ScaleX(500), FreeSpaceLabel2.Top+ScaleY(2), ScaleX(12), ScaleY(12));
  BmpFile1.Stretch:= true
  BmpFile1.Parent:= Panel1;

  WizardForm.DirEdit.OnChange:=@DirEditOnChange;
  
  //////////////////////////////////////////////////////
  
  Iconslabel:= TLabel.Create(WizardForm);
  with Iconslabel do
  begin
    AutoSize:= False;
    Parent := Panel2;
    Left := ScaleY(8);
    Top := ScaleX(13);
    Width := ScaleX(150);
    Height := ScaleY(20);
    Font.Name := '{#FontName2}';
    Caption :=ExpandConstant('{cm:Iconslabel}');
    Transparent:= True;
  end;

    Desktop:=TCheckBox.Create(WizardForm);
    with Desktop do begin
      Parent:=Panel2;
      Caption :=ExpandConstant('{cm:Desktop}');
      Left:=ScaleX(13);
      Top:=Iconslabel.Top+Iconslabel.Height;
      Width:=ScaleX(300);
      Height:=ScaleY(15);
      Checked:=True;
    end;

    StartMenu:=TCheckBox.Create(WizardForm);
    with StartMenu do begin
      Parent:=Panel2;
      Caption :=ExpandConstant('{cm:StartMenu}');
      Left:=Desktop.Left;
      Top:=Desktop.Top+Desktop.Height+ScaleY(5);
      Width:=ScaleX(300);
      Height:=ScaleY(15);
      Checked:=True;
      OnClick:= @StartMenuOnClick;
    end;

    QuickLaunch:=TCheckBox.Create(WizardForm);
    with QuickLaunch do begin
      Parent:=Panel2;
      Caption :=ExpandConstant('{cm:QuickLaunch}');
      Left:=Desktop.Left;
      Top:=StartMenu.Top+StartMenu.Height+ScaleY(5);
      Width:=ScaleX(300);
      Height:=ScaleY(15);
      Checked:=True;
    end;
  //////////////////////////////////////////////////////
  Compslabel:= TLabel.Create(WizardForm);
  with Compslabel do
  begin
    AutoSize:= False;
    Parent := Panel2;
    Left := BevelPanel2.Left+ScaleY(8);
    Top := ScaleX(13);
    Width := ScaleX(150);
    Height := ScaleY(20);
    Font.Name := '{#FontName2}';
    Caption :=ExpandConstant('{cm:Compslabel}');
    Transparent:= True;
  end;

    DirectX:=TCheckBox.Create(WizardForm);
    with DirectX do begin
      Parent:=Panel2;
    Caption :=ExpandConstant('{cm:DirectX}');
      Left := BevelPanel2.Left+ScaleY(13);
      Top:=Compslabel.Top+Compslabel.Height;
      Width:=ScaleX(300);
      Height:=ScaleY(15);
      TabOrder:=0;
      Checked:=false;
    end;

    VCRedist:=TCheckBox.Create(WizardForm);
    with VCRedist do begin
      Parent:=Panel2;
    Caption :=ExpandConstant('{cm:VCRedist}');
      Left := BevelPanel2.Left+ScaleY(13);
      Top:=DirectX.Top+DirectX.Height+ScaleY(5);
      Width:=ScaleX(300);
      Height:=ScaleY(15);
      TabOrder:=0;
      Checked:=false;
    end;
  //////////////////////////////////////////////////////
  Panel3 := TPanel.Create(WizardForm);
  with Panel3 do
  begin
    Parent := Frame;
    Left := ScaleX(10);
    Top := ScaleY(159);
    Width := ScaleX(642);
    Height := ScaleY(180);
    BevelInner := bvSpace;
    BevelOuter := bvLowered;
    ParentBackground := False;
    Color := 13948116;
  end;

  ///////// øðèôò, öâåò òåêñòà è äðóãèå //////////////
  Statuslabel:= TLabel.Create(WizardForm);
  with Statuslabel do
  begin
    AutoSize:= False;
    Parent := Panel3;
    Left :=ScaleX(40);
    Top := ScaleX(13);
    Width := ScaleX(250);
    Height := ScaleY(200);
    Font.Name := '{#FontName2}';
    Transparent:= True;
  end;
end;
/////////////////////////////////////////////////////////////////////////////
procedure WFDeInit;
begin
  gdipShutDown;
end;

procedure InitializeWizard();
begin
  InitializeWFont;
  WizardFormInit;
  RedesignWizardForm;
  Win7TaskBar20();
  #ifdef Slides
begin
  PicList:=tstringlist.Create;
  ExtractTemporaryFile('01.png');
  ExtractTemporaryFile('02.png');
  ExtractTemporaryFile('03.png');
  piclist.add(ExpandConstant('{tmp}') + '\01.png');
  piclist.add(ExpandConstant('{tmp}') + '\02.png');
  piclist.add(ExpandConstant('{tmp}') + '\03.png');
  end;
#endif
end;
#ifdef Slides
procedure OnTimer(HandleW, msg, idEvent, TimeSys: LongWord);
begin
 CurrentPicture:=CurrentPicture+1;
 if CurrentPicture=piclist.count+1 then CurrentPicture:=1;
 ShowImage(piclist.strings[CurrentPicture - 1], 1);
end;
#endif

procedure HideComponents;
begin
  ImgSetVisibility(BigOk,False);
  ImgSetVisibility(BigWarn,False);
  ImgSetVisibility(BigFail,False);
  ImgSetVisibility(BigInst,False);
  WelcomeLabel.Hide;
  WelcomeLabel1.Hide;
  WelcomeLabel2.Hide;
  Panel1.Hide;
  Panel2.Hide;
  Panel3.Hide;
  Statuslabel.Hide;
end;

Procedure CurPageChanged(CurPageID: Integer);
 Begin
  HideComponents;
case CurPageID of

 wpWelcome:
  begin
  WelcomeLabel.Show;
  WelcomeLabel1.Show;
  WelcomeLabel2.Show;
  end;

 wpSelectDir:
  begin
  Panel1.Show;
  Panel2.Show;
  TotalSpaceLabel.Show;
  If WizardForm.FindComponent('NextButton') is TButton then
  TButton(WizardForm.FindComponent('NextButton')). Caption:=ExpandConstant('{cm:NextButton}');
  DirEditOnChange(nil)
  end;

 wpInstalling:
  begin
  WelcomeLabel1.Show;
  //WelcomeLabel1.Caption:=ExpandConstant('{cm:WelcomeLabel3}');
  ImgSetVisibility(BigInst,True);
  Panel3.Show;
  #ifdef Slides
   InitializeSlideShow(WizardForm.Handle, 10, -40, scaleX(642), ScaleY(270), true, 2);
   CurrentPicture:=1;
   ShowImage(piclist.strings[CurrentPicture-1], 1);
   TimerID:=SetTimer(0, 0, 5000, WrapTimerProc(@OnTimer, 4));
   WizardForm.ProgressGauge.parent:=WizardForm;
   WizardForm.ProgressGauge.setbounds(ScaleX(10), ScaleY(300), ScaleX(385), WizardForm.ProgressGauge.height);
   //WizardForm.CancelButton.Left:=ScaleX(405);
   //WizardForm.CancelButton.Top:=ScaleY(325);
  #endif
  end;


 wpFinished:
  begin
  WelcomeLabel1.Show;
  WelcomeLabel1.Caption:='{#AppName}';
  WelcomeLabel2.Show;
  WelcomeLabel2.Caption:=ExpandConstant('{cm:WelcomeLabel4}');
  ImgSetVisibility(BigOk,True);
#ifdef Slides
 WizardForm.ProgressGauge.visible:=false;
 DeinitializeSlideShow;
 KillTimer(0, TimerID);
#endif
  end;

  end;
  if (CurPageID = wpFinished) and ISDoneError then
  begin
  WelcomeLabel1.Show;
  WelcomeLabel1.Caption:='{#AppName}';
  WelcomeLabel2.Show;
  WelcomeLabel2.Caption:=ExpandConstant('{cm:WelcomeLabel5}');
  ImgSetVisibility(BigOk,False);
  ImgSetVisibility(BigFail,True);
  WizardForm.Caption:= ExpandConstant('{cm:Error}');
  end;

  ImgApplyChanges(Frame.Handle);
 end;

procedure DeinitializeSetup;
begin
  WFDeInit;
  RemoveFontResource(ExpandConstant('{tmp}\{#Font}'), FR_PRIVATE, 0);
  RemoveFontResource(ExpandConstant('{tmp}\{#Font2}'), FR_PRIVATE, 0);
  WizardForm.Free;
  gdipShutdown
  #ifdef Slides
begin
 DeinitializeSlideShow;
 KillTimer(0, TimerID);
end;
#endif
end;

[/SPOILER]
 
Приветствую всех. Подскажите как сотворить вот такое окно деинсталлятора? Пример
Это msgbox
code_language.pascal:
[setup]
appname=app
appvername=app 1.0
CreateAppDir=no

[CustomMessages]
ConfirmUninsGameDir=Оставить сохранения игры на диске?%n(Выбрав "Нет", вы удалите прогресс игры)

[code]
function UserProfile(): string;
begin
  result := RemoveBackslash(GetShellFolderByCSIDL($28, false));
end;

procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
begin
  if CurUninstallStep = usUninstall then
  if MsgBox(CustomMessage('ConfirmUninsGameDir'), mbConfirmation, MB_YESNO or MB_DEFBUTTON2) = IDYES then
    DelTree(AddBackslash(UserProfile)+'Saved Games\My Games\Test', true, true ,true);
end;
 
Назад
Сверху