OSDN Git Service

8cbc019ecaed567118cf7365474994e24d7a3f8a
[gikonavigoeson/gikonavi.git] / readme / gikoSetup.iss
1 [Setup]
2 AppName=\83M\83R\83i\83r
3 AppVerName=\83M\83R\83i\83r
4 AppId=gikoNavi
5 AppMutex=http://gikonavi.sourceforge.jp/gikonavi/mutex
6 AppPublisherURL=http://gikonavi.sourceforge.jp/
7 AppendDefaultDirName = no
8 DefaultDirName={pf}\gikonavi
9 VersionInfoDescription=\83M\83R\83i\83r\83Z\83b\83g\83A\83b\83v\83v\83\8d\83O\83\89\83\80
10 DefaultGroupName=\83M\83R\83i\83r
11\8e©\95ª\82Ì\8aÂ\8b«\82É\8d\87\82í\82¹\82Ä\82­\82¾\82³\82¢
12 SourceDir=G:\Release
13 OutputDir=G:\InnoSetup\Output
14 SetupIconFile="G:\gikoNaviSFX_102\MainIcon.ico"
15\83M\83R\83i\83r\82Ì\83o\81[\83W\83\87\83\93\82É\82 \82í\82¹\82Ä\82­\82¾\82³\82¢
16 VersionInfoVersion=1.59.1.778
17 OutputBaseFilename=gikoNavi_b59_setup
18
19
20 [Tasks]
21 Name: "startmenuicon"; Description: "\83X\83^\81[\83g\83\81\83j\83\85\81[\82É\93o\98^\82·\82é"; GroupDescription: "\83V\83\87\81[\83g\83J\83b\83g"; Flags:
22 Name: "desktopicon"; Description: "\83f\83X\83N\83g\83b\83v\82É\83V\83\87\81[\83g\83J\83b\83g\82ð\8dì\90¬"; GroupDescription: "\83V\83\87\81[\83g\83J\83b\83g"; Flags:
23
24 [Dirs]
25 Name: "{app}\Log"
26 Name: "{app}\Sound"
27 Name: "{app}\config\Board"
28 Name: "{app}\config\BoardPlugin"
29 Name: "{app}\config\NGwords"
30
31
32 [Files]
33 Source: * ; Destdir: {app} ;Excludes: "gikoNavi.exe" ;
34 Source: "gikoNavi.exe" ; Destdir: {app} ;Permissions: everyone-full; Flags: ignoreversion
35 Source: "Sound\*" ; Destdir: {app}\Sound ;Flags: createallsubdirs recursesubdirs ;
36 Source: "config\*" ; Destdir: {app}\config ;Excludes: "*.dll";Flags: createallsubdirs recursesubdirs ;
37 Source: "config\BoardPlugin\*.dll" ; Destdir: {app}\config\BoardPlugin ;Flags: ignoreversion;
38
39 [Icons]
40 Name: "{group}\Readme"; Filename: "{app}\readme.txt"; Tasks: startmenuicon
41 Name: "{group}\\83M\83R\83i\83r"; Filename: "{app}\gikoNavi.exe"; Tasks: startmenuicon
42 Name: "{commondesktop}\\83M\83R\83i\83r"; Filename: "{app}\gikoNavi.exe"; Tasks: desktopicon
43
44 [Run]
45 Filename: "{app}\readme.txt"; Description: "README\82ð\95\\8e¦\82·\82é"; Flags: postinstall shellexec skipifsilent unchecked
46 Filename: "{app}\gikoNavi.exe"; Description: "\83A\83v\83\8a\83P\81[\83V\83\87\83\93\82ð\8bN\93®\82·\82é"; Flags: postinstall shellexec skipifsilent
47
48 [UninstallDelete]
49 Type: files; Name: "{app}\sent.ini"
50 Type: files; Name: "{app}\url.ini"
51 Type: files; Name: "{app}\Samba.ini"
52 Type: files; Name: "{app}\gikoNavi.ini"
53
54 [Languages]
55 Name: japanese; MessagesFile: compiler:Languages\Japanese.isl
56
57 [Code]
58 procedure CurStepChanged(CurStep: TSetupStep);
59 var
60   path :String;
61   srcpath: String;
62 begin
63   case CurStep of
64     ssInstall:
65       begin
66         if (RegKeyExists(HKEY_LOCAL_MACHINE,
67             'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\gikoNavi')) then
68           begin
69             if MsgBox('\88È\91O\82Ì\83o\81[\83W\83\87\83\93\82Ì\83A\83\93\83C\83\93\83X\83g\81[\83\8b\8fî\95ñ\82ð\8dí\8f\9c\82µ\82Ä\82æ\82ë\82µ\82¢\82Å\82µ\82å\82¤\82©\81H'
70               + #10#13 + '(\83o\83^56\88È\91O\82©\82ç\82Ì\83A\83b\83v\83f\81[\83g\82Ì\8fê\8d\87\81u\82Í\82¢\81v\90\84\8f§)',
71                mbConfirmation, MB_YESNO) = IDYES then
72               begin
73                   if not RegDeleteKeyIncludingSubkeys(HKEY_LOCAL_MACHINE,
74                     'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\gikoNavi') then
75                     begin
76                       MsgBox('\83A\83\93\83C\83\93\83X\83g\81[\83\8b\8fî\95ñ\82Ì\8dí\8f\9c\82É\8e¸\94s\82µ\82Ü\82µ\82½\81B', mbError, MB_OK);
77                     end;
78               end;
79           end;
80       end;
81     ssPostInstall:
82       begin
83         path := ExpandConstant('{app}') + '\gikoNavi.ini';
84         srcpath := ExpandConstant('{srcexe}');
85         if (FileExists(path)) then
86         begin
87           SetIniString('Update', 'Remove0', srcpath, path);
88         end;
89       end;
90   end;
91
92 end;
93 procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
94 var
95   path :String;
96 begin
97   case CurUninstallStep of
98     usUninstall:
99       begin
100         path := ExpandConstant('{app}') + '\Log';
101         if MsgBox(path + '\83t\83H\83\8b\83_\88È\89º\82ð\8a®\91S\82É\8fÁ\8b\8e\82µ\82Ä\82æ\82ë\82µ\82¢\82Å\82µ\82å\82¤\82©\81H', mbConfirmation, MB_YESNO) = IDYES then
102         begin
103           DelTree(path, True, True, True);
104         end;
105
106         path := ExpandConstant('{app}') + '\config';
107         if MsgBox(path + '\83t\83H\83\8b\83_\88È\89º\82ð\8a®\91S\82É\8fÁ\8b\8e\82µ\82Ä\82æ\82ë\82µ\82¢\82Å\82µ\82å\82¤\82©\81H', mbConfirmation, MB_YESNO) = IDYES then
108         begin
109           DelTree(path, True, True, True);
110         end;
111
112       end;
113     usPostUninstall:
114       begin
115         path := ExpandConstant('{app}');
116
117         MsgBox(path + '\83t\83H\83\8b\83_\88È\89º\82É\81A\8dí\8f\9c\82µ\82«\82ê\82È\82¢\83t\83@\83C\83\8b\82ª\8ec\82Á\82Ä\82¢\82é\8fê\8d\87\82ª\82 \82è\82Ü\82·\81B' #10#13 '\8am\94F\82Ì\82¤\82¦\8eè\93®\82Å\8dí\8f\9c\82µ\82Ä\82­\82¾\82³\82¢\81B',
118           mbInformation, MB_OK);
119       end;
120   end;
121 end;
122