View Single Post
  #508  
Old 21-01-2019, 23:03
Schabik Schabik is offline
Registered User
 
Join Date: Dec 2008
Location: Somewhere in Poland
Posts: 152
Thanks: 17
Thanked 35 Times in 32 Posts
Schabik is on a distinguished road
KaktoR there's a problem with background button in 7.1.1b.Beta3, even if I turn it off (The background I mean) in settings file while running the Installer there is a message that there is an unknown Custom message name "BackgroundON" in cm constant.


Another thing, I think that You forgot to write an IF statement to BackgroundCB and BackgroundButton to look like:


Code:
#if UseInstallBackground == "1"
  BackgroundCB := TNewCheckBox.Create(WizardForm);
  with BackgroundCB do begin
    Parent  := WizardForm;
    Left    := ScaleX(0);
    Top     := ScaleY(0);
    Width   := ScaleX(0);
    Height  := ScaleY(0);
    Visible := False;
    Checked := False;
  end;

  BackgroundButton := TNewButton.Create(WizardForm);
  with BackgroundButton do begin
    Parent  := WizardForm;
    Left    := WebsiteButton.Left - WebsiteButton.Width - 10;
    Top     := WebsiteButton.Top;
    Width   := WebsiteButton.Width;
    Height  := WebsiteButton.Height;
    Caption := ExpandConstant('{cm:BackgroundON}');
    OnClick := @BackgroundButtonClick;
  end;
#endif

Without that no matter if You enable or disable UseInstallBackground it will be enabled, if I recall.

Last edited by Schabik; 21-01-2019 at 23:30.
Reply With Quote
The Following User Says Thank You to Schabik For This Useful Post:
KaktoR (22-01-2019)