Updated inno installer configuration for RM handling to include gpant commits.
Added logging for RM registration (fails silently on anything before VISTA)
Signed-off-by: George Pantazis <gpant@noc.grnet.gr>
///DLL Import to add restart manager support
[DllImport("kernel32.dll", CharSet = CharSet.Auto)]
- static extern uint RegisterApplicationRestart(string pwzCommandLine, RestartFlags dwFlags);
+ public static extern Int32 RegisterApplicationRestart(String commandLineArgs, UInt32 flags);
public App()
{
InitializeLogging();
///Register Application in the Restartmanager service
- RegisterApplicationRestart("Upgrade", RestartFlags.NONE);
-
+ Int32 result = RegisterApplicationRestart(null, 0);
+ Log.ErrorFormat("RM Result:", result);
DispatcherUnhandledException += OnDispatcherUnhandledException;
AppDomain.CurrentDomain.UnhandledException += OnUnhandledException;
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
-[assembly: AssemblyVersion("0.7.20619.3")]
-[assembly: AssemblyFileVersionAttribute("0.7.20619.3")]
+[assembly: AssemblyVersion("0.7.20621.2")]
+[assembly: AssemblyFileVersionAttribute("0.7.20621.2")]
}\r
catch (Exception ex)\r
{\r
- Log.ErrorFormat("[FAIL] ListObjects for{0} in ProcessRemoteFiles with {1}", accountInfo.UserName, ex);\r
+ Log.ErrorFormat("[FAIL] ListObjects for {0} in ProcessRemoteFiles with {1}", accountInfo.UserName, ex);\r
return nextSince;\r
}\r
\r
VersionInfoCompany=GRNET\r
VersionInfoDescription=Pithos Plus\r
VersionInfoCopyright=(c) 2011-2012 GRNET\r
-VersionInfoProductName=Pitho Plus\r
+VersionInfoProductName=Pithos Plus\r
VersionInfoProductVersion=1\r
AppModifyPath="{app}\UninsHs.exe" /m0=AppId\r
+CloseApplications=yes\r
+RestartApplications=yes\r
\r
[Languages]\r
Name: "english"; MessagesFile: "compiler:Default.isl"\r
Source: "..\Pithos.Client.WPF\bin\Debug\PithosPlus.exe"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek\r
Source: "..\Pithos.Client.WPF\bin\Debug\PithosPlus.exe.config"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek\r
; Appearance\r
-Source: "Skin\ISSkin.dll"; DestDir: {app}; Flags: dontcopy\r
-Source: "Skin\GRNETWhite.cjstyles"; DestDir: {tmp}; Flags: dontcopy\r
+;Source: "Skin\ISSkin.dll"; DestDir: {app}; Flags: dontcopy\r
+;Source: "Skin\GRNETWhite.cjstyles"; DestDir: {tmp}; Flags: dontcopy\r
; Repair/Modify\r
Source: "Tools\UninsHs.exe"; DestDir: {app}; Flags: restartreplace\r
; Running Processes\r
-Source: "Tools\IssProc.dll"; DestDir: {app}; Flags: restartreplace\r
+;Source: "Tools\IssProc.dll"; DestDir: {app}; Flags: restartreplace\r
; DLL\r
Source: "..\Pithos.ShellExtensions\bin\x86\Debug\Pithos.ShellExtensions.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek; Check: not Is64BitInstallMode\r
Source: "..\Pithos.ShellExtensions\bin\x64\Debug\Pithos.ShellExtensions.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek; Check: Is64BitInstallMode\r
LicenseID: Integer; \r
\r
// IssFindModule called on in/uninstall\r
-function IssFindModule(hWnd: Integer; Modulename: String; Language: PAnsiChar; Silent: Boolean; CanIgnore: Boolean ): Integer;\r
-external 'IssFindModuleW@files:IssProc.dll stdcall setuponly';\r
+///function IssFindModule(hWnd: Integer; Modulename: String; Language: PAnsiChar; Silent: Boolean; CanIgnore: Boolean ): Integer;\r
+///external 'IssFindModuleW@files:IssProc.dll stdcall setuponly';\r
\r
-function IssFindModuleU(hWnd: Integer; Modulename: String; Language: PAnsiChar; Silent: Boolean; CanIgnore: Boolean ): Integer;\r
-external 'IssFindModuleW@{app}\IssProc.dll stdcall uninstallonly';\r
+///function IssFindModuleU(hWnd: Integer; Modulename: String; Language: PAnsiChar; Silent: Boolean; CanIgnore: Boolean ): Integer;\r
+///external 'IssFindModuleW@{app}\IssProc.dll stdcall uninstallonly';\r
\r
//Call this to enable search for any in use file type\r
-function IssEnableAnyFileInUseCheck(Folder: String): Integer;\r
-external 'IssEnableAnyFileInUseCheckW@files:IssProc.dll stdcall setuponly';\r
+///function IssEnableAnyFileInUseCheck(Folder: String): Integer;\r
+///external 'IssEnableAnyFileInUseCheckW@files:IssProc.dll stdcall setuponly';\r
\r
//IssEnableAnyFileInUseCheck called on uninstall\r
-function IssEnableAnyFileInUseCheckU(Folder: String): Integer;\r
-external 'IssEnableAnyFileInUseCheckW@{app}\IssProc.dll stdcall uninstallonly';\r
+///function IssEnableAnyFileInUseCheckU(Folder: String): Integer;\r
+///external 'IssEnableAnyFileInUseCheckW@{app}\IssProc.dll stdcall uninstallonly';\r
\r
//Register for commercial use on install\r
-function IssRegister(rName: PAnsiChar; rKey: PAnsiChar): Integer;\r
-external 'IssRegister@files:IssProc.dll stdcall setuponly';\r
+///function IssRegister(rName: PAnsiChar; rKey: PAnsiChar): Integer;\r
+///external 'IssRegister@files:IssProc.dll stdcall setuponly';\r
\r
//Register for commercial use on uninstall\r
-function IssRegisterU(rName: PAnsiChar; rKey: PAnsiChar): Integer;\r
-external 'IssRegister@{app}\IssProc.dll stdcall uninstallonly';\r
+///function IssRegisterU(rName: PAnsiChar; rKey: PAnsiChar): Integer;\r
+///external 'IssRegister@{app}\IssProc.dll stdcall uninstallonly';\r
\r
// Importing LoadSkin API from ISSkin.DLL\r
-procedure LoadSkin(lpszPath: String; lpszIniFileName: String);\r
-external 'LoadSkin@files:isskin.dll stdcall';\r
+//procedure LoadSkin(lpszPath: String; lpszIniFileName: String);\r
+//external 'LoadSkin@files:isskin.dll stdcall';\r
\r
-procedure UnloadSkin();\r
-external 'UnloadSkin@files:isskin.dll stdcall';\r
+//procedure UnloadSkin();\r
+//external 'UnloadSkin@files:isskin.dll stdcall';\r
\r
// Importing ShowWindow Windows API from User32.DLL\r
function ShowWindow(hWnd: Integer; uType: Integer): Integer;\r
Result := false;\r
\r
hWnd := StrToInt(ExpandConstant('{wizardhwnd}')); { get main wizard handle }\r
- IssEnableAnyFileInUseCheck(ExpandConstant('{app}'));\r
- sModuleName :=ExpandConstant('pithos*.dll;PithosPlus.exe'); \r
- nCode:=IssFindModule(hWnd,sModuleName,'en',false,true); { search for module and display files-in-use window if found }\r
+/// IssEnableAnyFileInUseCheck(ExpandConstant('{app}'));\r
+/// sModuleName :=ExpandConstant('pithos*.dll;PithosPlus.exe'); \r
+/// nCode:=IssFindModule(hWnd,sModuleName,'en',false,true); { search for module and display files-in-use window if found }\r
if nCode=1 then begin { cancel pressed or files-in-use window closed }\r
PostMessage (WizardForm.Handle, $0010, 0, 0); { quit setup, $0010=WM_CLOSE }\r
end else if (nCode=0) or (nCode=2) then begin { no module found or ignored pressed}\r
function InitializeSetup(): Boolean;\r
begin\r
//Unpack The Skin\r
- ExtractTemporaryFile('GRNETWhite.cjstyles');\r
- LoadSkin(ExpandConstant('{tmp}\GRNETWhite.cjstyles'), '');\r
+ //ExtractTemporaryFile('GRNETWhite.cjstyles');\r
+ //LoadSkin(ExpandConstant('{tmp}\GRNETWhite.cjstyles'), '');\r
\r
// Test the presence of .NET 4.0\r
if (not(RegKeyExists(HKLM, 'SOFTWARE\Microsoft\NET Framework Setup\NDP\v4'))) then\r
procedure DeinitializeSetup();\r
begin\r
//Hide Window widget\r
- ShowWindow(StrToInt(ExpandConstant('{wizardhwnd}')), 0);\r
- UnloadSkin();\r
+ //ShowWindow(StrToInt(ExpandConstant('{wizardhwnd}')), 0);\r
+ //UnloadSkin();\r
end;\r
\r
function ShouldInstalldotNET40(): Boolean;\r
VersionInfoCompany=GRNET
VersionInfoDescription=Pithos Plus
VersionInfoCopyright=(c) 2011-2012 GRNET
-VersionInfoProductName=Pitho Plus
+VersionInfoProductName=Pithos Plus
VersionInfoProductVersion=1
AppModifyPath="{app}\UninsHs.exe" /m0=AppId
+;CloseApplications=yes
+RestartApplications=yes
[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
Source: "..\Pithos.Client.WPF\bin\Debug\PithosPlus.exe"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek
Source: "..\Pithos.Client.WPF\bin\Debug\PithosPlus.exe.config"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek
; Appearance
-Source: "Skin\ISSkin.dll"; DestDir: {app}; Flags: dontcopy
-Source: "Skin\GRNETWhite.cjstyles"; DestDir: {tmp}; Flags: dontcopy
+;Source: "Skin\ISSkin.dll"; DestDir: {app}; Flags: dontcopy
+;Source: "Skin\GRNETWhite.cjstyles"; DestDir: {tmp}; Flags: dontcopy
; Repair/Modify
Source: "Tools\UninsHs.exe"; DestDir: {app}; Flags: restartreplace
; Running Processes
-Source: "Tools\IssProc.dll"; DestDir: {app}; Flags: restartreplace
+;Source: "Tools\IssProc.dll"; DestDir: {app}; Flags: restartreplace
; DLL
Source: "..\Pithos.ShellExtensions\bin\x86\Debug\Pithos.ShellExtensions.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek; Check: not Is64BitInstallMode
Source: "..\Pithos.ShellExtensions\bin\x64\Debug\Pithos.ShellExtensions.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek; Check: Is64BitInstallMode
Source: "..\Pithos.Client.WPF\bin\Debug\Newtonsoft.Json.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek
Source: "..\Pithos.Client.WPF\bin\Debug\NHibernate.ByteCode.Castle.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek
Source: "..\Pithos.Client.WPF\bin\Debug\NHibernate.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek
-Source: "..\Pithos.Client.WPF\bin\Debug\NHibernate.Search.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek
Source: "..\Pithos.Client.WPF\bin\Debug\ParallelExtensionsExtras.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek
Source: "..\Pithos.Client.WPF\bin\Debug\Pithos.Core.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek
Source: "..\Pithos.Client.WPF\bin\Debug\Pithos.Interfaces.dll"; DestDir: {app}; Flags: restartreplace ignoreversion; Components: RequiredFiles; Languages: english french german spanish greek
LicenseID: Integer;
// IssFindModule called on in/uninstall
-function IssFindModule(hWnd: Integer; Modulename: String; Language: PAnsiChar; Silent: Boolean; CanIgnore: Boolean ): Integer;
-external 'IssFindModuleW@files:IssProc.dll stdcall setuponly';
+///function IssFindModule(hWnd: Integer; Modulename: String; Language: PAnsiChar; Silent: Boolean; CanIgnore: Boolean ): Integer;
+///external 'IssFindModuleW@files:IssProc.dll stdcall setuponly';
-function IssFindModuleU(hWnd: Integer; Modulename: String; Language: PAnsiChar; Silent: Boolean; CanIgnore: Boolean ): Integer;
-external 'IssFindModuleW@{app}\IssProc.dll stdcall uninstallonly';
+///function IssFindModuleU(hWnd: Integer; Modulename: String; Language: PAnsiChar; Silent: Boolean; CanIgnore: Boolean ): Integer;
+///external 'IssFindModuleW@{app}\IssProc.dll stdcall uninstallonly';
//Call this to enable search for any in use file type
-function IssEnableAnyFileInUseCheck(Folder: String): Integer;
-external 'IssEnableAnyFileInUseCheckW@files:IssProc.dll stdcall setuponly';
+///function IssEnableAnyFileInUseCheck(Folder: String): Integer;
+///external 'IssEnableAnyFileInUseCheckW@files:IssProc.dll stdcall setuponly';
//IssEnableAnyFileInUseCheck called on uninstall
-function IssEnableAnyFileInUseCheckU(Folder: String): Integer;
-external 'IssEnableAnyFileInUseCheckW@{app}\IssProc.dll stdcall uninstallonly';
+///function IssEnableAnyFileInUseCheckU(Folder: String): Integer;
+///external 'IssEnableAnyFileInUseCheckW@{app}\IssProc.dll stdcall uninstallonly';
//Register for commercial use on install
-function IssRegister(rName: PAnsiChar; rKey: PAnsiChar): Integer;
-external 'IssRegister@files:IssProc.dll stdcall setuponly';
+///function IssRegister(rName: PAnsiChar; rKey: PAnsiChar): Integer;
+///external 'IssRegister@files:IssProc.dll stdcall setuponly';
//Register for commercial use on uninstall
-function IssRegisterU(rName: PAnsiChar; rKey: PAnsiChar): Integer;
-external 'IssRegister@{app}\IssProc.dll stdcall uninstallonly';
+///function IssRegisterU(rName: PAnsiChar; rKey: PAnsiChar): Integer;
+///external 'IssRegister@{app}\IssProc.dll stdcall uninstallonly';
// Importing LoadSkin API from ISSkin.DLL
-procedure LoadSkin(lpszPath: String; lpszIniFileName: String);
-external 'LoadSkin@files:isskin.dll stdcall';
+//procedure LoadSkin(lpszPath: String; lpszIniFileName: String);
+//external 'LoadSkin@files:isskin.dll stdcall';
-procedure UnloadSkin();
-external 'UnloadSkin@files:isskin.dll stdcall';
+//procedure UnloadSkin();
+//external 'UnloadSkin@files:isskin.dll stdcall';
// Importing ShowWindow Windows API from User32.DLL
function ShowWindow(hWnd: Integer; uType: Integer): Integer;
Result := false;
hWnd := StrToInt(ExpandConstant('{wizardhwnd}')); { get main wizard handle }
- IssEnableAnyFileInUseCheck(ExpandConstant('{app}'));
- sModuleName :=ExpandConstant('pithos*.dll;PithosPlus.exe');
- nCode:=IssFindModule(hWnd,sModuleName,'en',false,true); { search for module and display files-in-use window if found }
+/// IssEnableAnyFileInUseCheck(ExpandConstant('{app}'));
+/// sModuleName :=ExpandConstant('pithos*.dll;PithosPlus.exe');
+/// nCode:=IssFindModule(hWnd,sModuleName,'en',false,true); { search for module and display files-in-use window if found }
if nCode=1 then begin { cancel pressed or files-in-use window closed }
PostMessage (WizardForm.Handle, $0010, 0, 0); { quit setup, $0010=WM_CLOSE }
end else if (nCode=0) or (nCode=2) then begin { no module found or ignored pressed}
function InitializeSetup(): Boolean;
begin
//Unpack The Skin
- ExtractTemporaryFile('GRNETWhite.cjstyles');
- LoadSkin(ExpandConstant('{tmp}\GRNETWhite.cjstyles'), '');
+ //ExtractTemporaryFile('GRNETWhite.cjstyles');
+ //LoadSkin(ExpandConstant('{tmp}\GRNETWhite.cjstyles'), '');
// Test the presence of .NET 4.0
if (not(RegKeyExists(HKLM, 'SOFTWARE\Microsoft\NET Framework Setup\NDP\v4'))) then
procedure DeinitializeSetup();
begin
//Hide Window widget
- ShowWindow(StrToInt(ExpandConstant('{wizardhwnd}')), 0);
- UnloadSkin();
+ //ShowWindow(StrToInt(ExpandConstant('{wizardhwnd}')), 0);
+ //UnloadSkin();
end;
function ShouldInstalldotNET40(): Boolean;
BitmapImage1.width := Page.SurfaceWidth;
BitmapImage1.height := Page.SurfaceHeight;
BitmapImage1.Bitmap.LoadFromFile(BitmapFileName);
- BitmapImage1.Left := 0
+ BitmapImage1.Left := 0;
BitmapImage1.Top := Page.Surface.Top + LabelWz.Height;
BitmapImage1.Parent := Page.Surface;
-
end;
procedure InitializeWizard;