DittoSetup.iss 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. ; Script generated by the Inno Setup Script Wizard.
  2. ; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
  3. [Setup]
  4. AppName=Ditto
  5. AppVerName=Ditto 3.10.0.0
  6. OutputBaseFilename=DittoSetup_3_10_0_0
  7. AppPublisher=Scott Brogden
  8. AppPublisherURL=ditto-cp.sourceforge.net
  9. AppSupportURL=ditto-cp.sourceforge.net
  10. AppUpdatesURL=ditto-cp.sourceforge.net
  11. DefaultDirName={pf}\Ditto
  12. DefaultGroupName=Ditto
  13. AppMutex=Ditto Is Now Running
  14. UsePreviousTasks=no
  15. DisableDirPage=yes
  16. DisableProgramGroupPage=yes
  17. DisableReadyPage=yes
  18. DirExistsWarning=no
  19. UninstallLogMode=overwrite
  20. ChangesAssociations=yes
  21. [Languages]
  22. Name: "English"; MessagesFile: "compiler:Default.isl"
  23. Name: "German"; MessagesFile: "German.isl"
  24. Name: "Italiano"; MessagesFile: "Italian.isl"
  25. Name: "French"; MessagesFile: "French.isl"
  26. Name: "Portuguese"; MessagesFile: "Portuguese.isl"
  27. Name: "Spanish"; MessagesFile: "Spanish.isl"
  28. Name: "Polski"; MessagesFile: "Polish.isl"
  29. Name: "Dutch"; MessagesFile: "Dutch.isl"
  30. [Tasks]
  31. Name: RunAtStartup; Description: "Run Ditto on Windows Startup";
  32. [Files]
  33. ;Unicode for 2000 and later
  34. Source: "..\Release\DittoU.exe"; DestDir: "{app}"; DestName: "Ditto.exe"; Flags: ignoreversion; MinVersion: 0, 4.0
  35. ;Non unicode for pre 2000
  36. Source: "..\Release\Ditto.exe"; DestDir: "{app}"; DestName: "Ditto.exe"; Flags: ignoreversion; MinVersion: 4.0, 0
  37. Source: "..\Release\focus.dll"; DestDir: "{app}"; BeforeInstall: BeforeFocusInstall(); Flags: ignoreversion restartreplace
  38. Source: "..\Release\sqlite3.dll"; DestDir: "{app}"; Flags: ignoreversion
  39. Source: "..\Release\AccessToSqlite.dll"; DestDir: "{app}"; Flags: ignoreversion
  40. Source: "..\zlib\zlib1.dll"; DestDir: "{app}"; Flags: ignoreversion
  41. Source: "Changes.txt"; DestDir: "{app}"
  42. Source: "..\Debug\Language\*"; DestDir: "{app}\Language"; BeforeInstall: BeforeLanguageInstall();
  43. Source: "mfc-crt\*"; DestDir: "{app}"
  44. ;Add help files
  45. Source: "..\Help\*.htm"; DestDir: "{app}\Help"; Flags: ignoreversion
  46. [Icons]
  47. Name: "{group}\Ditto"; Filename: "{app}\Ditto.exe";
  48. Name: "{group}\Ditto Help"; Filename: "{app}\Help\DittoGettingStarted.htm";
  49. Name: "{group}\Uninstall"; Filename: "{uninstallexe}"
  50. [Run]
  51. Filename: "{app}\Ditto.exe"; Description: "Launch Ditto"; Flags: nowait postinstall skipifsilent
  52. Filename: "{app}\Help\DittoGettingStarted.htm"; Description: "View Help"; Flags: nowait postinstall skipifsilent shellexec
  53. Filename: "{app}\Changes.txt"; Description: "View Change History"; Flags: nowait postinstall skipifsilent shellexec unchecked
  54. [Registry]
  55. Root: HKCU; Subkey: "Software\Ditto"; Flags: uninsdeletekey
  56. Root: HKCU; Subkey: "SOFTWARE\Microsoft\Windows\CurrentVersion\Run"; ValueType: string; ValueName: "Ditto"; flags: uninsdeletevalue; ValueData: "{app}\Ditto.exe"; Tasks: RunAtStartup
  57. Root: HKCU; Subkey: "Software\Ditto"; ValueType: string; ValueName: "LanguageFile"; ValueData: {language}
  58. ;associate .dto with Ditto
  59. Root: HKCR; Subkey: ".dto"; ValueType: string; ValueName: ""; ValueData: "Ditto"; Flags: uninsdeletevalue
  60. Root: HKCR; Subkey: "Ditto"; ValueType: string; ValueName: ""; ValueData: "Ditto"; Flags: uninsdeletekey
  61. Root: HKCR; Subkey: "Ditto\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\Ditto.exe,0"
  62. Root: HKCR; Subkey: "Ditto\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\Ditto.exe"" ""%1"""
  63. [Code]
  64. procedure BeforeFocusInstall();
  65. var
  66. sDir: String;
  67. begin
  68. sDir := ExpandConstant('{app}');
  69. DeleteFile(sDir+'\focus.dll')
  70. DeleteFile(sDir+'\focus.dll.old')
  71. DeleteFile(sDir+'\focus.dll.old.old')
  72. DeleteFile(sDir+'\focus.dll.old.old.old')
  73. RenameFile(sDir+'\focus.dll', sDir+'\focus.dll.old')
  74. RenameFile(sDir+'\focus.dll', sDir+'\focus.dll.old.old')
  75. RenameFile(sDir+'\focus.dll', sDir+'\focus.dll.old.old.old')
  76. end;
  77. procedure BeforeLanguageInstall();
  78. var
  79. sDir: String;
  80. begin
  81. sDir := ExpandConstant('{app}');
  82. RenameFile(sDir+'\Language\Italian.xml', sDir+'\Language\Italian.xml.old')
  83. end;