@@ -72,8 +72,8 @@ AppId=HackWindowsInstaller
72
72
SetupMutex= HackWindowsInstaller_SetupMutex
73
73
74
74
AppName = Hack Windows Installer
75
- AppVersion = 1.2 .0
76
- VersionInfoVersion = 1.2 .0
75
+ AppVersion = 1.2 .1
76
+ VersionInfoVersion = 1.2 .1
77
77
78
78
AppPublisher = Michael Hex / Source Foundry
79
79
AppContact = Michael Hex / Source Foundry
@@ -125,7 +125,7 @@ AllowCancelDuringInstall=False
125
125
;SetupAppTitle is displayed in the taskbar
126
126
SetupAppTitle= Hack Windows Installer
127
127
;SetupWindowsTitle is displayed in the setup window itself so better include the version
128
- SetupWindowTitle= Hack Windows Installer 1.2 .0
128
+ SetupWindowTitle= Hack Windows Installer 1.2 .1
129
129
130
130
;Message for the "Read to install" wizard page
131
131
;NOT USED - "Ready To Install" - below title bar
@@ -191,7 +191,7 @@ Root: HKLM; Subkey: "SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts"; ValueN
191
191
192
192
[INI]
193
193
;Create an ini to make detection for enterprise deployment tools easy
194
- Filename : " {app} \InstallInfo.ini" ; Section: " Main" ; Key: " Version" ; String : " 1.2.0 "
194
+ Filename : " {app} \InstallInfo.ini" ; Section: " Main" ; Key: " Version" ; String : " 1.2.1 "
195
195
Filename : " {app} \InstallInfo.ini" ; Section: " Main" ; Key: " Name" ; String : " Hack Windows Installer"
196
196
197
197
[UninstallDelete]
@@ -204,6 +204,9 @@ Type: files; Name: "{app}\Log*.txt"
204
204
205
205
206
206
[Code]
207
+
208
+ // --- START incl_ServiceControlManager-definition.iss ---
209
+
207
210
type
208
211
SERVICE_STATUS = record
209
212
dwServiceType : cardinal;
@@ -216,14 +219,15 @@ type
216
219
end ;
217
220
HANDLE = cardinal;
218
221
222
+
219
223
const
224
+ SC_MANAGER_ALL_ACCESS = $f003f;
220
225
SERVICE_QUERY_CONFIG = $1 ;
221
226
SERVICE_CHANGE_CONFIG = $2 ;
222
227
SERVICE_QUERY_STATUS = $4 ;
223
228
SERVICE_START = $10 ;
224
229
SERVICE_STOP = $20 ;
225
230
SERVICE_ALL_ACCESS = $f01ff;
226
- SC_MANAGER_ALL_ACCESS = $f003f;
227
231
SERVICE_WIN32_OWN_PROCESS = $10 ;
228
232
SERVICE_WIN32_SHARE_PROCESS = $20 ;
229
233
SERVICE_WIN32 = $30 ;
@@ -245,6 +249,10 @@ const
245
249
SERVICE_CONTINUE_PENDING = $5 ;
246
250
SERVICE_PAUSE_PENDING = $6 ;
247
251
SERVICE_PAUSED = $7 ;
252
+
253
+ // --- END incl_ServiceControlManager-definition.iss ---
254
+
255
+
248
256
249
257
250
258
var
266
274
FontStateBuffer: array of string;
267
275
268
276
277
+ // --- START incl_ServiceControlManager-functions.iss ---
278
+
269
279
function OpenSCManager (lpMachineName, lpDatabaseName: string; dwDesiredAccess :cardinal): HANDLE;
270
280
external ' OpenSCManagerA@advapi32.dll stdcall' ;
271
281
@@ -284,6 +294,7 @@ external 'ControlService@advapi32.dll stdcall';
284
294
function QueryServiceStatus (hService :HANDLE;var ServiceStatus :SERVICE_STATUS) : boolean;
285
295
external ' QueryServiceStatus@advapi32.dll stdcall' ;
286
296
297
+
287
298
function OpenServiceManager () : HANDLE;
288
299
begin
289
300
if UsingWinNT() = true then begin
@@ -314,8 +325,6 @@ begin
314
325
end
315
326
end ;
316
327
317
-
318
-
319
328
function StartService (ServiceName: string) : boolean;
320
329
var
321
330
hSCM : HANDLE;
@@ -371,8 +380,35 @@ begin
371
380
end
372
381
end ;
373
382
383
+ function StartNTService2 (serviceName:string):boolean;
384
+ begin
385
+ if IsServiceInstalled(serviceName) then begin
386
+ if IsServiceRunning(serviceName)=false then begin
387
+ log(' Starting service ' + serviceName);
388
+ StartService(serviceName);
389
+ sleep(1500 ); // give the service some seconds
390
+ result:=true;
391
+ end ;
392
+ end ;
393
+ end ;
394
+
395
+ function StopNTService2 (serviceName:string):boolean;
396
+ begin
397
+ if IsServiceInstalled(serviceName) then begin
398
+ if IsServiceRunning(serviceName) then begin
399
+ log(' Stopping service ' + serviceName);
400
+ StopService(serviceName);
401
+ sleep(1500 );
402
+ result:=true;
403
+ end ;
404
+ end ;
405
+ end ;
406
+
374
407
375
408
409
+ // --- END incl_ServiceControlManager-functions.iss ---
410
+
411
+
376
412
377
413
378
414
procedure AddFontData (fontFile, fontName, fontHash :string);
@@ -549,29 +585,6 @@ end;
549
585
550
586
551
587
552
- function StartNTService2 (serviceName:string):boolean;
553
- begin
554
- if IsServiceInstalled(serviceName) then begin
555
- if IsServiceRunning(serviceName)=false then begin
556
- log(' Starting service ' + serviceName);
557
- StartService(serviceName);
558
- sleep(1500 ); // give the service some seconds
559
- result:=true;
560
- end ;
561
- end ;
562
- end ;
563
-
564
- function StopNTService2 (serviceName:string):boolean;
565
- begin
566
- if IsServiceInstalled(serviceName) then begin
567
- if IsServiceRunning(serviceName) then begin
568
- log(' Stopping service ' + serviceName);
569
- StopService(serviceName);
570
- sleep(1500 );
571
- result:=true;
572
- end ;
573
- end ;
574
- end ;
575
588
576
589
577
590
procedure BeforeInstallAction ();
583
596
begin
584
597
LogAsImportant(' ---BeforeInstallAction START---' );
585
598
586
- LogAsImportant(' Setup version: 1.2.0 ' );
599
+ LogAsImportant(' Setup version: 1.2.1 ' );
587
600
LogAsImportant(' Font version.: 2.020' );
588
601
LogAsImportant(' Local time...: ' + GetDateTimeString(' yyyy-dd-mm hh:nn' , ' -' , ' :' ));
589
602
LogAsImportant(' Fonts folder.: ' + ExpandConstant(' {fonts}' ));
0 commit comments