Subversion Repositories fastphp

Rev

Rev 49 | Rev 53 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 49 Rev 50
Line 40... Line 40...
40
; xphp = executable PHP (only for PHP browser)
40
; xphp = executable PHP (only for PHP browser)
41
Name: fileassocEditor;  Description: "{cm:AssocFileExtension,'FastPHP Editor','.php(s)'}"; GroupDescription: "{cm:Assoc}"; Components: editor
41
Name: fileassocEditor;  Description: "{cm:AssocFileExtension,'FastPHP Editor','.php(s)'}"; GroupDescription: "{cm:Assoc}"; Components: editor
42
Name: fileassocBrowser; Description: "{cm:AssocFileExtension,'FastPHP Browser','.xphp'}";  GroupDescription: "{cm:Assoc}"; Components: browser
42
Name: fileassocBrowser; Description: "{cm:AssocFileExtension,'FastPHP Browser','.xphp'}";  GroupDescription: "{cm:Assoc}"; Components: browser
43
 
43
 
44
[Files]
44
[Files]
-
 
45
Source: "Icons\Icons.dll";          DestDir: "{app}"; Flags: ignoreversion
-
 
46
 
45
Source: "FastPHPEditor.exe";        DestDir: "{app}"; Flags: ignoreversion; Components: editor
47
Source: "FastPHPEditor.exe";        DestDir: "{app}"; Flags: ignoreversion; Components: editor
46
Source: "codeexplorer.bmp";         DestDir: "{app}"; Flags: ignoreversion; Components: editor
48
Source: "codeexplorer.bmp";         DestDir: "{app}"; Flags: ignoreversion; Components: editor
47
Source: "codeexplorer.php";         DestDir: "{app}"; Flags: ignoreversion; Components: editor
49
Source: "codeexplorer.php";         DestDir: "{app}"; Flags: ignoreversion; Components: editor
48
Source: "codeexplorer_api.inc.php"; DestDir: "{app}"; Flags: ignoreversion; Components: editor
50
Source: "codeexplorer_api.inc.php"; DestDir: "{app}"; Flags: ignoreversion; Components: editor
49
 
51
 
Line 62... Line 64...
62
 
64
 
63
[Registry]
65
[Registry]
64
Root: HKCR; Subkey: ".php";                                       ValueData: "FastPHPScript";                       ValueType: string; ValueName: ""; Flags: uninsdeletevalue; Components: editor;  Tasks: fileassocEditor
66
Root: HKCR; Subkey: ".php";                                       ValueData: "FastPHPScript";                       ValueType: string; ValueName: ""; Flags: uninsdeletevalue; Components: editor;  Tasks: fileassocEditor
65
Root: HKCR; Subkey: ".phps";                                      ValueData: "FastPHPScript";                       ValueType: string; ValueName: ""; Flags: uninsdeletevalue; Components: editor;  Tasks: fileassocEditor
67
Root: HKCR; Subkey: ".phps";                                      ValueData: "FastPHPScript";                       ValueType: string; ValueName: ""; Flags: uninsdeletevalue; Components: editor;  Tasks: fileassocEditor
66
Root: HKCR; Subkey: "FastPHPScript";                              ValueData: "PHP script";                          ValueType: string; ValueName: ""; Flags: uninsdeletekey;   Components: editor;  Tasks: fileassocEditor
68
Root: HKCR; Subkey: "FastPHPScript";                              ValueData: "PHP script";                          ValueType: string; ValueName: ""; Flags: uninsdeletekey;   Components: editor;  Tasks: fileassocEditor
67
Root: HKCR; Subkey: "FastPHPScript\DefaultIcon";                  ValueData: "{app}\FastPHPEditor.exe";             ValueType: string; ValueName: "";                          Components: editor;  Tasks: fileassocEditor
69
Root: HKCR; Subkey: "FastPHPScript\DefaultIcon";                  ValueData: "{app}\Icons.dll,0";                   ValueType: string; ValueName: "";                          Components: editor;  Tasks: fileassocEditor
68
Root: HKCR; Subkey: "FastPHPScript\shell\open\command";           ValueData: """{app}\FastPHPEditor.exe"" ""%1""";  ValueType: string; ValueName: "";                          Components: editor;  Tasks: fileassocEditor
70
Root: HKCR; Subkey: "FastPHPScript\shell\open\command";           ValueData: """{app}\FastPHPEditor.exe"" ""%1""";  ValueType: string; ValueName: "";                          Components: editor;  Tasks: fileassocEditor
69
           
71
           
70
Root: HKCR; Subkey: ".php\ShellNew";                              ValueData: "PHP script";                          ValueType: string; ValueName: "ItemName";                  Components: editor;  Tasks: fileassocEditor
72
Root: HKCR; Subkey: ".php\ShellNew";                              ValueData: "PHP script";                          ValueType: string; ValueName: "ItemName";                  Components: editor;  Tasks: fileassocEditor
71
Root: HKCR; Subkey: ".php\ShellNew";                              ValueData: "";                                    ValueType: string; ValueName: "NullFile";                  Components: editor;  Tasks: fileassocEditor
73
Root: HKCR; Subkey: ".php\ShellNew";                              ValueData: "";                                    ValueType: string; ValueName: "NullFile";                  Components: editor;  Tasks: fileassocEditor
72
 
74
 
73
Root: HKCR; Subkey: ".xphp";                                      ValueData: "FastPHPExecutableScript";             ValueType: string; ValueName: ""; Flags: uninsdeletevalue; Components: browser; Tasks: fileassocBrowser
75
Root: HKCR; Subkey: ".xphp";                                      ValueData: "FastPHPExecutableScript";             ValueType: string; ValueName: ""; Flags: uninsdeletevalue; Components: browser; Tasks: fileassocBrowser
74
Root: HKCR; Subkey: "FastPHPExecutableScript";                    ValueData: "Executable PHP application";          ValueType: string; ValueName: ""; Flags: uninsdeletekey;   Components: browser; Tasks: fileassocBrowser
76
Root: HKCR; Subkey: "FastPHPExecutableScript";                    ValueData: "Executable PHP application";          ValueType: string; ValueName: ""; Flags: uninsdeletekey;   Components: browser; Tasks: fileassocBrowser
75
Root: HKCR; Subkey: "FastPHPExecutableScript\DefaultIcon";        ValueData: "{app}\FastPHPEditor.exe";             ValueType: string; ValueName: "";                          Components: browser; Tasks: fileassocBrowser
77
Root: HKCR; Subkey: "FastPHPExecutableScript\DefaultIcon";        ValueData: "{app}\Icons.exe,1";                   ValueType: string; ValueName: "";                          Components: browser; Tasks: fileassocBrowser
76
Root: HKCR; Subkey: "FastPHPExecutableScript\shell\open\command"; ValueData: """{app}\FastPHPBrowser.exe"" ""%1"""; ValueType: string; ValueName: "";                          Components: browser; Tasks: fileassocBrowser
78
Root: HKCR; Subkey: "FastPHPExecutableScript\shell\open\command"; ValueData: """{app}\FastPHPBrowser.exe"" ""%1"""; ValueType: string; ValueName: "";                          Components: browser; Tasks: fileassocBrowser
77
Root: HKCR; Subkey: "FastPHPExecutableScript\shell\edit\command"; ValueData: """{app}\FastPHPEditor.exe"" ""%1""";  ValueType: string; ValueName: "";                          Components: browser; Tasks: fileassocBrowser
79
Root: HKCR; Subkey: "FastPHPExecutableScript\shell\edit\command"; ValueData: """{app}\FastPHPEditor.exe"" ""%1""";  ValueType: string; ValueName: "";                          Components: browser; Tasks: fileassocBrowser
78
 
80
 
79
[Code]
81
[Code]
80
function InitializeSetup(): Boolean;
82
function InitializeSetup(): Boolean;
Line 87... Line 89...
87
  else
89
  else
88
  begin
90
  begin
89
    Result := False;
91
    Result := False;
90
  end;
92
  end;
91
end;
93
end;
-
 
94
function IsAnyComponentSelected: Boolean;
-
 
95
var
-
 
96
  I: Integer;
-
 
97
begin
-
 
98
  // Source: https://stackoverflow.com/questions/20691583/innosetup-if-no-components-are-selected-go-back-to-components-page
-
 
99
  Result := False;
-
 
100
  for I := 0 to WizardForm.ComponentsList.Items.Count - 1 do
-
 
101
    if WizardForm.ComponentsList.Checked[I] then
-
 
102
    begin
-
 
103
      Result := True;
-
 
104
      Exit;
-
 
105
    end;
-
 
106
end;
-
 
107
function NextButtonClick(PageID: Integer): Boolean;
-
 
108
begin
-
 
109
  Result:= True;
-
 
110
  if PageID = wpSelectComponents then
-
 
111
  begin
-
 
112
    if not IsAnyComponentSelected then
-
 
113
    begin
-
 
114
      MsgBox('No items selected, please select at least one item', mbError, MB_OK);
-
 
115
      Result := False;
-
 
116
    end;
-
 
117
  end;
-
 
118
end;