![]() |
Внимание, важное сообщение: Дорогие Друзья!
В ноябре далекого 2001 года мы решили создать сайт и форум, которые смогут помочь как начинающим, так и продвинутым пользователям разобраться в операционных системах. В 2004-2006г наш проект был одним из самых крупных ИТ ресурсов в рунете, на пике нас посещало более 300 000 человек в день! Наша документация по службам Windows и автоматической установке помогла огромному количеству пользователей и сисадминов. Мы с уверенностью можем сказать, что внесли большой вклад в развитие ИТ сообщества рунета. Но... время меняются, приоритеты тоже. И, к сожалению, пришло время сказать До встречи! После долгих дискуссий было принято решение закрыть наш проект. 1 августа форум переводится в режим Только чтение, а в начале сентября мы переведем рубильник в положение Выключен Огромное спасибо за эти 24 года, это было незабываемое приключение. Сказать спасибо и поделиться своей историей можно в данной теме. С уважением, ваш призрачный админ, BigMac... |
|
Компьютерный форум OSzone.net » Автоматическая установка Windows » Автоматическая установка приложений » Скрипты Inno Setup. Помощь и советы [часть 8] |
|
Скрипты Inno Setup. Помощь и советы [часть 8]
|
Ветеран Сообщения: 1274 |
Внимание! Данная тема предназначена только для обсуждения написания скриптов !
Остальные вопросы, а также последние версии компилятора в теме Inno Setup. Прочие вопросы. Показать/скрыть: Справка, руководство, примеры:
Показать/скрыть: Ссылки на примеры скриптов:
Показать/скрыть: Дополнительные программы для Inno Setup:
Предыдущие ветки обсуждения по ссылкам ниже и в прикреплённых архивах: Скрипты Inno Setup. Помощь и советы (Archive Pack 1):
Скрипты Inno Setup. Помощь и советы [часть 6] Скрипты Inno Setup. Помощь и советы [часть 7] |
|
Отправлено: 08:52, 02-02-2015 |
Пользователь Сообщения: 50
|
Профиль | Отправить PM | Цитировать Нужна помощь, отображаются только первые четыре картинки.
Components
Name: AKM; Description: AKM(AK-47):; Types: full; Flags: fixed; Name: AKM\OPTION1; Description: "Вариант №1"; Types: full; Flags: exclusive; Name: AKM\OPTION2; Description: "Вариант №2"; Types: custom; Flags: exclusive; Name: AKM\OPTION3; Description: "Вариант №3"; Types: custom; Flags: exclusive; Name: AKM\OPTION4; Description: "Вариант №4"; Types: custom; Flags: exclusive; Name: COLT45; Description: Colt.45(Pistol):; Types: full; Flags: fixed; Name: COLT45\OPTION1; Description: "Вариант №1"; Types: full; Flags: exclusive; Name: COLT45\OPTION2; Description: "Вариант №2"; Types: custom; Flags: exclusive; Name: COLT45\OPTION3; Description: "Вариант №3"; Types: custom; Flags: exclusive; Name: COLT45\OPTION4; Description: "Вариант №4"; Types: custom; Flags: exclusive; Name: KAR98K; Description: Kar98k(Rifle):; Types: full; Flags: fixed; Name: KAR98K\OPTION1; Description: "Вариант №1"; Types: full; Flags: exclusive; Name: KAR98K\OPTION2; Description: "Вариант №2"; Types: custom; Flags: exclusive; Name: KAR98K\OPTION3; Description: "Вариант №3"; Types: custom; Flags: exclusive; Name: M16A4; Description: M16A4(M4):; Types: full; Flags: fixed; Name: M16A4\OPTION1; Description: "Вариант №1"; Types: full; Flags: exclusive; Name: M16A4\OPTION2; Description: "Вариант №2"; Types: custom; Flags: exclusive; Name: M16A4\OPTION3; Description: "Вариант №3"; Types: custom; Flags: exclusive; Name: M16A4\OPTION4; Description: "Вариант №4"; Types: custom; Flags: exclusive; Name: UMP9; Description: UMP9(MP5):; Types: full; Flags: fixed; Name: UMP9\OPTION1; Description: "Вариант №1"; Types: full; Flags: exclusive; Name: UMP9\OPTION2; Description: "Вариант №2"; Types: custom; Flags: exclusive; Name: S1897; Description: S1897(ShotGun):; Types: full; Flags: fixed; Name: S1897\OPTION1; Description: "Вариант №1"; Types: full; Flags: exclusive; Name: S1897\OPTION2; Description: "Вариант №2"; Types: custom; Flags: exclusive; Name: UZI; Description: UZI(Micro SMG):; Types: full; Flags: fixed; Name: UZI\OPTION1; Description: "Вариант №1"; Types: full; Flags: exclusive; Name: UZI\OPTION2; Description: "Вариант №2"; Types: custom; Flags: exclusive; Name: UZI\OPTION3; Description: "Вариант №3"; Types: custom; Flags: exclusive; Name: UZI\OPTION4; Description: "Вариант №4"; Types: custom; Flags: exclusive; [Files] Source: "files\other\tool.bat"; DestDir: "{app}"; Flags: ignoreversion Source: "files\other\temp.bat"; DestDir: "{app}"; Flags: ignoreversion Source: "files\other\tool.txt"; DestDir: "{app}"; Flags: ignoreversion Source: "files\other\img.exe"; DestDir: "{app}"; Flags: ignoreversion Source: "files\textures\akm\option 1\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: AKM\OPTION1; Source: "files\textures\akm\option 2\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: AKM\OPTION2; Source: "files\textures\akm\option 3\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: AKM\OPTION3; Source: "files\textures\akm\option 4\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: AKM\OPTION4; Source: "files\textures\colt45\option 1\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: COLT45\OPTION1; Source: "files\textures\colt45\option 2\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: COLT45\OPTION2; Source: "files\textures\colt45\option 3\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: COLT45\OPTION3; Source: "files\textures\colt45\option 4\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: COLT45\OPTION4; Source: "files\textures\kar98k\option 1\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: KAR98K\OPTION1; Source: "files\textures\kar98k\option 2\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: KAR98K\OPTION2; Source: "files\textures\kar98k\option 3\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: KAR98K\OPTION3; Source: "files\textures\m16a4\option 1\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: M16A4\OPTION1; Source: "files\textures\m16a4\option 2\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: M16A4\OPTION2; Source: "files\textures\m16a4\option 3\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: M16A4\OPTION3; Source: "files\textures\m16a4\option 4\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: M16A4\OPTION4; Source: "files\textures\ump9\option 1\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: UMP9\OPTION1; Source: "files\textures\ump9\option 2\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: UMP9\OPTION2; Source: "files\textures\s1897\option 1\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: S1897\OPTION1; Source: "files\textures\s1897\option 2\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: S1897\OPTION2; Source: "files\textures\uzi\option 1\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: UZI\OPTION1; Source: "files\textures\uzi\option 2\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: UZI\OPTION2; Source: "files\textures\uzi\OPTION 3\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: UZI\OPTION3; Source: "files\textures\uzi\OPTION 4\*"; DestDir: "{app}\Textures"; Flags: ignoreversion; Components: UZI\OPTION4; Source: "images\textures\*"; DestDir: {tmp}; Flags: dontcopy; Code
function NextButtonClick(CurPageID: Integer): Boolean; begin Result := True; case CurPageID of wpSelectDir: if not FileExists(ExpandConstant('{app}\gta_sa.exe')) then begin MsgBox('Ошибка! Вы должны указать путь к папке Grand Theft Auto - San Andreas(к файлу gta_sa.exe).', mbError, MB_OK); Result := False; end; end; end; procedure SomeProc; begin end; var DelTmp: TNewCheckBox; function DelTmpCheck(): boolean; begin result := DelTmp.Checked; end; var ImagePanel: TPanel; ComponentsInfoImage: TBitmapImage; procedure ComponentsListClickCheck(Sender: TObject); begin If IsComponentSelected('AKM\OPTION1') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\akm_1.bmp')) else If IsComponentSelected('AKM\OPTION2') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\akm_2.bmp')) else If IsComponentSelected('AKM\OPTION3') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\akm_3.bmp')) else If IsComponentSelected('AKM\OPTION4') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\akm_4.bmp')) else If IsComponentSelected('COLT45\OPTION1') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\colt45_1.bmp')) else If IsComponentSelected('COLT45\OPTION2') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\colt45_2.bmp')) else If IsComponentSelected('COLT45\OPTION3') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\colt45_3.bmp')) else If IsComponentSelected('COLT45\OPTION4') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\colt45_4.bmp')) else If IsComponentSelected('KAR98K\OPTION1') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\kar98k_1.bmp')) else If IsComponentSelected('KAR98K\OPTION2') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\kar98k_2.bmp')) else If IsComponentSelected('KAR98K\OPTION3') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\kar98k_3.bmp')) else If IsComponentSelected('M16A4\OPTION1') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\m4a16_1.bmp')) else If IsComponentSelected('M16A4\OPTION2') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\m4a16_2.bmp')) else If IsComponentSelected('M16A4\OPTION3') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\m4a16_3.bmp')) else If IsComponentSelected('M16A4\OPTION4') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\m4a16_4.bmp')) else If IsComponentSelected('UMP9\OPTION1') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\ump9_1.bmp')) else If IsComponentSelected('UMP9\OPTION2') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\ump9_2.bmp')) else If IsComponentSelected('S1897\OPTION1') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\s1897_1.bmp')) else If IsComponentSelected('S1897\OPTION2') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\s1897_2.bmp')) else If IsComponentSelected('S1897\OPTION3') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\uzi_1.bmp')) else If IsComponentSelected('UZI\OPTION2') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\uzi_2.bmp')) else If IsComponentSelected('UZI\OPTION3') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\uzi_3.bmp')) else If IsComponentSelected('UZI\OPTION4') then ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\uzi_4.bmp')); end; procedure InitializeWizard(); begin WizardForm.TYPESCOMBO.Visible:= false; WizardForm.ComponentsList.Visible := True; WizardForm.ComponentsList.Height := ScaleX(150); WizardForm.ComponentsList.Top := ScaleX(47); WizardForm.ComponentsList.Width := ScaleX(232); WizardForm.ComponentsDiskSpaceLabel.Visible := True; ImagePanel := TPanel.Create(WizardForm); ImagePanel.Parent := WizardForm.SelectComponentsPage; ImagePanel.Caption := ''; ImagePanel.Top := ScaleX(47); ImagePanel.Left := ScaleX(240); ImagePanel.Width := ScaleX(177); ImagePanel.Height := ScaleX(151); ImagePanel.BevelInner := bvRaised; ImagePanel.BevelOuter := bvLowered; ExtractTemporaryFile('akm_1.bmp'); ExtractTemporaryFile('akm_2.bmp'); ExtractTemporaryFile('akm_3.bmp'); ExtractTemporaryFile('akm_4.bmp'); ExtractTemporaryFile('colt45_1.bmp'); ExtractTemporaryFile('colt45_2.bmp'); ExtractTemporaryFile('colt45_3.bmp'); ExtractTemporaryFile('colt45_4.bmp'); ExtractTemporaryFile('kar98k_1.bmp'); ExtractTemporaryFile('kar98k_2.bmp'); ExtractTemporaryFile('kar98k_3.bmp'); ExtractTemporaryFile('m4a16_1.bmp'); ExtractTemporaryFile('m4a16_2.bmp'); ExtractTemporaryFile('m4a16_3.bmp'); ExtractTemporaryFile('m4a16_4.bmp'); ExtractTemporaryFile('ump9_1.bmp'); ExtractTemporaryFile('ump9_2.bmp'); ExtractTemporaryFile('s1897_1.bmp'); ExtractTemporaryFile('s1897_2.bmp'); ExtractTemporaryFile('uzi_1.bmp'); ExtractTemporaryFile('uzi_2.bmp'); ExtractTemporaryFile('uzi_3.bmp'); ExtractTemporaryFile('uzi_4.bmp'); WizardForm.ComponentsList.OnClickCheck:= @ComponentsListClickCheck; ComponentsInfoImage:= TBitmapImage.Create(WizardForm); ComponentsInfoImage.Parent:= ImagePanel; ComponentsInfoImage.Top:= ScaleY(4); ComponentsInfoImage.Left:= ScaleX(4); ComponentsInfoImage.Width:= ScaleX(168); ComponentsInfoImage.Height:= ScaleY(142); ComponentsInfoImage.Stretch:= True; ComponentsInfoImage.BringToFront; end; procedure CurPageChanged(CurPageID: Integer); begin case CurPageID of wpSelectComponents: ComponentsListClickCheck(nil); end; end; |
Последний раз редактировалось TheLeon, 05-12-2017 в 13:14. Отправлено: 16:10, 04-12-2017 | #2291 |
Для отключения данного рекламного блока вам необходимо зарегистрироваться или войти с учетной записью социальной сети. Если же вы забыли свой пароль на форуме, то воспользуйтесь данной ссылкой для восстановления пароля. |
Ветеран Сообщения: 1274
|
Профиль | Отправить PM | Цитировать Цитата TheLeon:
ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\akm_4.bmp')); ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\colt45_4.bmp')); ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\kar98k_3.bmp')); ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\m4a16_4.bmp')); ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\ump9_2.bmp')); ComponentsInfoImage.Bitmap.LoadFromFile(ExpandConstant('{tmp}\s1897_2.bmp')); |
|
Отправлено: 09:07, 05-12-2017 | #2292 |
Пользователь Сообщения: 50
|
Профиль | Отправить PM | Цитировать El Sanchez, также вопрос, как во вкладке выбора компонентов убрать размерность для следующих пунктов?
Components
Name: MAIN; Description: Основное оружие:; Types: full; Flags: fixed; <----- убрать размерность Name: MAIN\AKM; Description: AKM(AK-47):; Types: full; Flags: fixed; <----- убрать размерность Name: MAIN\AKM\OPTION1; Description: "Вариант №1"; Flags: exclusive; Name: MAIN\AKM\OPTION2; Description: "Вариант №2"; Flags: exclusive; Name: MAIN\AKM\OPTION3; Description: "Вариант №3"; Flags: exclusive; Name: MAIN\AKM\OPTION4; Description: "Вариант №4"; Flags: exclusive; Name: MAIN\KAR98K; Description: Kar98k(Rifle):; Types: full; Flags: fixed; <----- убрать размерность Name: MAIN\KAR98K\OPTION1; Description: "Вариант №1"; Flags: exclusive; Name: MAIN\KAR98K\OPTION2; Description: "Вариант №2"; Flags: exclusive; Name: MAIN\KAR98K\OPTION3; Description: "Вариант №3"; Flags: exclusive; Name: MAIN\M16A4; Description: M16A4(M4):; Types: full; Flags: fixed; <----- убрать размерность Name: MAIN\M16A4\OPTION1; Description: "Вариант №1";Flags: exclusive; Name: MAIN\M16A4\OPTION2; Description: "Вариант №2";Flags: exclusive; Name: MAIN\M16A4\OPTION3; Description: "Вариант №3";Flags: exclusive; Name: MAIN\M16A4\OPTION4; Description: "Вариант №4";Flags: exclusive; Name: MAIN\UMP9; Description: UMP9(MP5):; Types: full; Flags: fixed; <----- убрать размерность Name: MAIN\UMP9\OPTION1; Description: "Вариант №1";Flags: exclusive; Name: MAIN\UMP9\OPTION2; Description: "Вариант №2";Flags: exclusive; Name: MAIN\S1897; Description: S1897(ShotGun):; Types: full; Flags: fixed; <----- убрать размерность Name: MAIN\S1897\OPTION1; Description: "Вариант №1";Flags: exclusive; Name: MAIN\S1897\OPTION2; Description: "Вариант №2";Flags: exclusive; Name: MAIN\UZI; Description: UZI(Micro SMG):; Types: full; Flags: fixed; <----- убрать размерность Name: MAIN\UZI\OPTION1; Description: "Вариант №1";Flags: exclusive; Name: MAIN\UZI\OPTION2; Description: "Вариант №2";Flags: exclusive; Name: MAIN\UZI\OPTION3; Description: "Вариант №3";Flags: exclusive; Name: MAIN\UZI\OPTION4; Description: "Вариант №4";Flags: exclusive; Name: ADD; Description: Дополнительное оружие:; Types: full; Flags: fixed; <----- убрать размерность Name: ADD\COLT45; Description: Colt.45(Pistol):; Types: full; Flags: fixed; <----- убрать размерность Name: ADD\COLT45\OPTION1; Description: "Вариант №1";Flags: exclusive; Name: ADD\COLT45\OPTION2; Description: "Вариант №2";Flags: exclusive; Name: ADD\COLT45\OPTION3; Description: "Вариант №3";Flags: exclusive; Name: ADD\COLT45\OPTION4; Description: "Вариант №4";Flags: exclusive; |
Последний раз редактировалось TheLeon, 06-12-2017 в 11:23. Отправлено: 13:05, 05-12-2017 | #2293 |
Новый участник Сообщения: 4
|
Профиль | Отправить PM | Цитировать |
Отправлено: 13:53, 05-12-2017 | #2294 |
Новый участник Сообщения: 4
|
Профиль | Отправить PM | Цитировать Речь идет про повышение привилегий до уровня Администратора..
установка PrivilegesRequired=admin эффекта не дает... То есть, если инсталятор запущен без прав админа, восполнение инструкций требующих права Администратора закончатся сбоем. Даже при наличии PrivilegesRequired=admin |
Отправлено: 14:45, 05-12-2017 | #2295 |
Ветеран Сообщения: 1274
|
Профиль | Отправить PM | Цитировать Цитата TheLeon:
Скрытый текст
[Components] Name: MAIN; Description: {code:CompHelper|Основное оружие:}; Types: full; Flags: fixed Name: MAIN\AKM; Description: {code:CompHelper|AKM(AK-47):}; Types: full; Flags: fixed Name: MAIN\AKM\OPTION1; Description: {code:CompHelper|Вариант №1|akm_1.bmp}; Flags: exclusive Name: MAIN\AKM\OPTION2; Description: {code:CompHelper|Вариант №2|akm_2.bmp}; Flags: exclusive Name: MAIN\AKM\OPTION3; Description: {code:CompHelper|Вариант №3|akm_3.bmp}; Flags: exclusive Name: MAIN\AKM\OPTION4; Description: {code:CompHelper|Вариант №4|akm_4.bmp}; Flags: exclusive Name: MAIN\KAR98K; Description: {code:CompHelper|Kar98k(Rifle):}; Types: full; Flags: fixed Name: MAIN\KAR98K\OPTION1; Description: {code:CompHelper|Вариант №1|kar98k_1.bmp}; Flags: exclusive Name: MAIN\KAR98K\OPTION2; Description: {code:CompHelper|Вариант №2|kar98k_2.bmp}; Flags: exclusive Name: MAIN\KAR98K\OPTION3; Description: {code:CompHelper|Вариант №3|kar98k_3.bmp}; Flags: exclusive Name: MAIN\M16A4; Description: {code:CompHelper|M16A4(M4):}; Types: full; Flags: fixed Name: MAIN\M16A4\OPTION1; Description: {code:CompHelper|Вариант №1|m4a16_1.bmp}; Flags: exclusive Name: MAIN\M16A4\OPTION2; Description: {code:CompHelper|Вариант №2|m4a16_2.bmp}; Flags: exclusive Name: MAIN\M16A4\OPTION3; Description: {code:CompHelper|Вариант №3|m4a16_3.bmp}; Flags: exclusive Name: MAIN\M16A4\OPTION4; Description: {code:CompHelper|Вариант №4|m4a16_4.bmp}; Flags: exclusive Name: MAIN\UMP9; Description: {code:CompHelper|UMP9(MP5):}; Types: full; Flags: fixed Name: MAIN\UMP9\OPTION1; Description: {code:CompHelper|Вариант №1|ump9_1.bmp}; Flags: exclusive Name: MAIN\UMP9\OPTION2; Description: {code:CompHelper|Вариант №2|ump9_2.bmp}; Flags: exclusive Name: MAIN\S1897; Description: {code:CompHelper|S1897(ShotGun):}; Types: full; Flags: fixed Name: MAIN\S1897\OPTION1; Description: {code:CompHelper|Вариант №1|s1897_1.bmp}; Flags: exclusive Name: MAIN\S1897\OPTION2; Description: {code:CompHelper|Вариант №2|s1897_2.bmp}; Flags: exclusive Name: MAIN\UZI; Description: {code:CompHelper|UZI(Micro SMG):}; Types: full; Flags: fixed Name: MAIN\UZI\OPTION1; Description: {code:CompHelper|Вариант №1|uzi_1.bmp}; Flags: exclusive Name: MAIN\UZI\OPTION2; Description: {code:CompHelper|Вариант №2|uzi_2.bmp}; Flags: exclusive Name: MAIN\UZI\OPTION3; Description: {code:CompHelper|Вариант №3|uzi_3.bmp}; Flags: exclusive Name: MAIN\UZI\OPTION4; Description: {code:CompHelper|Вариант №4|uzi_4.bmp}; Flags: exclusive Name: ADD; Description: {code:CompHelper|Дополнительное оружие:}; Types: full; Flags: fixed Name: ADD\COLT45; Description: {code:CompHelper|Colt.45(Pistol):}; Types: full; Flags: fixed Name: ADD\COLT45\OPTION1; Description: {code:CompHelper|Вариант №1|colt45_1.bmp}; Flags: exclusive Name: ADD\COLT45\OPTION2; Description: {code:CompHelper|Вариант №2|colt45_2.bmp}; Flags: exclusive Name: ADD\COLT45\OPTION3; Description: {code:CompHelper|Вариант №3|colt45_3.bmp}; Flags: exclusive Name: ADD\COLT45\OPTION4; Description: {code:CompHelper|Вариант №4|colt45_4.bmp}; Flags: exclusive [Code] var ImagePanel: TPanel; ComponentsInfoImage: TBitmapImage; ComponentHelper: TStringList; function CompHelper(Param: string): string; var Image: TBitmap; Index: Integer; begin Result := ''; with TStringList.Create do try StringChangeEx(Param, '|', #13#10, True); Text := Param; if Count = 0 then Exit; if Count > 0 then // description Index := ComponentHelper.Add(Strings[0]); if Count > 1 then // image begin if not FileExists(ExpandConstant('{tmp}\') + Strings[1]) then ExtractTemporaryFile(Strings[1]); Image := TBitmap.Create; Image.LoadFromFile(ExpandConstant('{tmp}\') + Strings[1]); ComponentHelper.Objects[Index] := Image; end; Result := ComponentHelper[Index]; finally Free; end; end; procedure ComponentsListClickCheck(Sender: TObject); begin if not Assigned(Sender) or (TNewCheckListBox(Sender).ItemIndex = -1) then Exit; ComponentsInfoImage.Bitmap.Assign(TBitmap(ComponentHelper.Objects[TNewCheckListBox(Sender).ItemIndex])); end; function InitializeSetup(): Boolean; begin Result := True; ComponentHelper := TStringList.Create; ComponentHelper.Duplicates := dupIgnore; end; Цитата TheLeon:
|
||
Отправлено: 10:23, 06-12-2017 | #2296 |
Ветеран Сообщения: 1274
|
Профиль | Отправить PM | Цитировать Цитата TheLeon:
|
|
Отправлено: 11:31, 06-12-2017 | #2297 |
Пользователь Сообщения: 50
|
Профиль | Отправить PM | Цитировать Code
function NextButtonClick(CurPageID: Integer): Boolean; begin Result := True; case CurPageID of wpSelectDir: if not FileExists(ExpandConstant('{app}\gta_sa.exe')) then begin MsgBox('Ошибка! Вы должны указать путь к папке Grand Theft Auto - San Andreas', mbError, MB_OK); Result := False; end; end; end; var ImagePanel: TPanel; ComponentsInfoImage: TBitmapImage; ComponentHelper: TStringList; function CompHelper(Param: string): string; var Image: TBitmap; Index: Integer; begin Result := ''; with TStringList.Create do try StringChangeEx(Param, '|', #13#10, True); Text := Param; if Count = 0 then Exit; if Count > 0 then // description Index := ComponentHelper.Add(Strings[0]); if Count > 1 then // image begin if not FileExists(ExpandConstant('{tmp}\') + Strings[1]) then ExtractTemporaryFile(Strings[1]); Image := TBitmap.Create; Image.LoadFromFile(ExpandConstant('{tmp}\') + Strings[1]); ComponentHelper.Objects[Index] := Image; end; Result := ComponentHelper[Index]; finally Free; end; end; procedure ComponentsListClickCheck(Sender: TObject); begin if not Assigned(Sender) or (TNewCheckListBox(Sender).ItemIndex = -1) then Exit; ComponentsInfoImage.Bitmap.Assign(TBitmap(ComponentHelper.Objects[TNewCheckListBox(Sender).ItemIndex])); end; function InitializeSetup(): Boolean; begin Result := True; ComponentHelper := TStringList.Create; ComponentHelper.Duplicates := dupIgnore; end; procedure InitializeWizard(); begin WizardForm.TYPESCOMBO.Visible:= false; WizardForm.ComponentsList.Visible := True; WizardForm.ComponentsList.Height := ScaleX(150); WizardForm.ComponentsList.Top := ScaleX(47); WizardForm.ComponentsList.Width := ScaleX(232); WizardForm.ComponentsDiskSpaceLabel.Visible := True; ImagePanel := TPanel.Create(WizardForm); ImagePanel.Parent := WizardForm.SelectComponentsPage; ImagePanel.Caption := ''; ImagePanel.Top := ScaleX(47); ImagePanel.Left := ScaleX(240); ImagePanel.Width := ScaleX(177); ImagePanel.Height := ScaleX(151); ImagePanel.BevelInner := bvRaised; ImagePanel.BevelOuter := bvLowered; ExtractTemporaryFile('akm_1.bmp'); ExtractTemporaryFile('akm_2.bmp'); ExtractTemporaryFile('akm_3.bmp'); ExtractTemporaryFile('akm_4.bmp'); ExtractTemporaryFile('kar98k_1.bmp'); ExtractTemporaryFile('kar98k_2.bmp'); ExtractTemporaryFile('kar98k_3.bmp'); ExtractTemporaryFile('ump9_1.bmp'); ExtractTemporaryFile('ump9_2.bmp'); ExtractTemporaryFile('s1897_1.bmp'); ExtractTemporaryFile('s1897_2.bmp'); ExtractTemporaryFile('uzi_1.bmp'); ExtractTemporaryFile('uzi_2.bmp'); ExtractTemporaryFile('uzi_3.bmp'); ExtractTemporaryFile('uzi_4.bmp'); ExtractTemporaryFile('colt45_1.bmp'); ExtractTemporaryFile('colt45_2.bmp'); ExtractTemporaryFile('colt45_3.bmp'); ExtractTemporaryFile('colt45_4.bmp'); ExtractTemporaryFile('molotov_1.bmp'); ExtractTemporaryFile('molotov_2.bmp'); ExtractTemporaryFile('molotov_3.bmp'); ExtractTemporaryFile('grenade_1.bmp'); ExtractTemporaryFile('grenade_2.bmp'); WizardForm.ComponentsList.OnClickCheck:= @ComponentsListClickCheck; ComponentsInfoImage:= TBitmapImage.Create(WizardForm); ComponentsInfoImage.Parent:= ImagePanel; ComponentsInfoImage.Top:= ScaleY(4); ComponentsInfoImage.Left:= ScaleX(4); ComponentsInfoImage.Width:= ScaleX(168); ComponentsInfoImage.Height:= ScaleY(142); ComponentsInfoImage.Stretch:= True; ComponentsInfoImage.BringToFront; end; |
Последний раз редактировалось TheLeon, 06-12-2017 в 14:56. Отправлено: 13:18, 06-12-2017 | #2298 |
Ветеран Сообщения: 27449
|
Профиль | Отправить PM | Цитировать Цитата TheLeon:
|
|
Отправлено: 13:57, 06-12-2017 | #2299 |
Ветеран Сообщения: 1274
|
Профиль | Отправить PM | Цитировать Цитата TheLeon:
Скрытый текст
[Code] var ImagePanel: TPanel; ComponentsInfoImage: TBitmapImage; ComponentHelper: TStringList; function CompHelper(Param: string): string; var Image: TBitmap; Index: Integer; begin Result := ''; with TStringList.Create do try StringChangeEx(Param, '|', #13#10, True); Text := Param; if Count = 0 then Exit; if Count > 0 then // description Index := ComponentHelper.Add(Strings[0]); if Count > 1 then // image begin if not FileExists(ExpandConstant('{tmp}\') + Strings[1]) then ExtractTemporaryFile(Strings[1]); Image := TBitmap.Create; Image.LoadFromFile(ExpandConstant('{tmp}\') + Strings[1]); ComponentHelper.Objects[Index] := Image; end; Result := ComponentHelper[Index]; finally Free; end; end; procedure ComponentsListClickCheck(Sender: TObject); begin if not Assigned(Sender) or (TNewCheckListBox(Sender).ItemIndex = -1) then Exit; ComponentsInfoImage.Bitmap.Assign(TBitmap(ComponentHelper.Objects[TNewCheckListBox(Sender).ItemIndex])); end; function InitializeSetup(): Boolean; begin Result := True; ComponentHelper := TStringList.Create; ComponentHelper.Duplicates := dupIgnore; end; procedure InitializeWizard(); var i: Integer; begin WizardForm.TypesCombo.Visible := False; WizardForm.ComponentsList.Visible := True; WizardForm.ComponentsList.Height := ScaleX(150); WizardForm.ComponentsList.Top := ScaleX(47); WizardForm.ComponentsList.Width := ScaleX(232); for i := 0 to WizardForm.ComponentsList.ItemCount - 1 do if not WizardForm.ComponentsList.ItemEnabled[i] then WizardForm.ComponentsList.ItemSubItem[i] := ''; WizardForm.ComponentsDiskSpaceLabel.Visible := True; ImagePanel := TPanel.Create(WizardForm); ImagePanel.Parent := WizardForm.SelectComponentsPage; ImagePanel.Caption := ''; ImagePanel.Top := ScaleX(47); ImagePanel.Left := ScaleX(240); ImagePanel.Width := ScaleX(177); ImagePanel.Height := ScaleX(151); ImagePanel.BevelInner := bvRaised; ImagePanel.BevelOuter := bvLowered; WizardForm.ComponentsList.OnClickCheck:= @ComponentsListClickCheck; ComponentsInfoImage:= TBitmapImage.Create(WizardForm); ComponentsInfoImage.Parent:= ImagePanel; ComponentsInfoImage.Top:= ScaleY(4); ComponentsInfoImage.Left:= ScaleX(4); ComponentsInfoImage.Width:= ScaleX(168); ComponentsInfoImage.Height:= ScaleY(142); ComponentsInfoImage.Stretch:= True; ComponentsInfoImage.BringToFront; end; procedure CurPageChanged(CurPageID: Integer); begin case CurPageID of wpSelectComponents: ComponentsListClickCheck(nil); end; end; function NextButtonClick(CurPageID: Integer): Boolean; begin Result := True; case CurPageID of wpSelectDir: if not FileExists(ExpandConstant('{app}\gta_sa.exe')) then begin MsgBox('Ошибка! Вы должны указать путь к папке Grand Theft Auto - San Andreas', mbError, MB_OK); Result := False; end; end; end; |
|
Отправлено: 14:45, 06-12-2017 | #2300 |
![]() |
Участник сейчас на форуме |
![]() |
Участник вне форума |
![]() |
Автор темы |
![]() |
Сообщение прикреплено |
| |||||
Название темы | Автор | Информация о форуме | Ответов | Последнее сообщение | |
Скрипты Inno Setup. Помощь и советы [часть 7] | El Sanchez | Автоматическая установка приложений | 2499 | 02-02-2015 08:59 | |
Скрипты Inno Setup. Помощь и советы [часть 6] | El Sanchez | Автоматическая установка приложений | 2494 | 10-03-2014 11:51 | |
Скрипты Inno Setup. Помощь и советы [часть 5] | El Sanchez | Автоматическая установка приложений | 1999 | 28-03-2013 19:09 | |
Скрипты Inno Setup. Помощь и советы [часть 4] | El Sanchez | Автоматическая установка приложений | 2099 | 22-05-2012 23:16 | |
Скрипты Inno Setup. Помощь и советы [часть 3] | Serega | Автоматическая установка приложений | 3755 | 26-10-2011 17:58 |
|