[Patch][WinGUI] AppData for Queue recovery; GUI Version
Posted: Wed Dec 09, 2009 8:41 pm
1. If Queue recovery is meant to be reliable over time, then using the user's temp folder is risky. The Temp folder can be emptied at any time, and it should not contain data needed over time/reboots.
I've created a patch that moves the Queue recovery file from the user's Temp folder to the ApplicationData\HandBrake folder when a queue file is found in the Temp folder, and continues to write the queue file to the AppData folder. If there are files in both the Temp and AppData locations, then the newer of the two files is used.
When a temp file is found, it is first copied to a backup file in the Temp folder. If no file is found in AppData, the temp file is moved to AppData. If a file is found in AppData, then the file is backed up, then the temp file is moved, replacing the original AppData file.
Pastebin: http://handbrake.fr/pastebin/pastebin.php?show=1060 (Edit: Added backup of Queue recovery file if user elects not to restore the queue.)
2. Since we are changing the GUI more frequently than builds are available for the CLI (at least for me, since I'm not setup to compile the CLI), it would be helpful to show both the CLI and GUI versions in the About dialog.
I added a patch to show both versions, taking the GUI version from the assembly info of the HandBrake.exe exectuable.
Pastebin: http://handbrake.fr/pastebin/pastebin.php?show=1058
I've created a patch that moves the Queue recovery file from the user's Temp folder to the ApplicationData\HandBrake folder when a queue file is found in the Temp folder, and continues to write the queue file to the AppData folder. If there are files in both the Temp and AppData locations, then the newer of the two files is used.
When a temp file is found, it is first copied to a backup file in the Temp folder. If no file is found in AppData, the temp file is moved to AppData. If a file is found in AppData, then the file is backed up, then the temp file is moved, replacing the original AppData file.
Pastebin: http://handbrake.fr/pastebin/pastebin.php?show=1060 (Edit: Added backup of Queue recovery file if user elects not to restore the queue.)
2. Since we are changing the GUI more frequently than builds are available for the CLI (at least for me, since I'm not setup to compile the CLI), it would be helpful to show both the CLI and GUI versions in the About dialog.
I added a patch to show both versions, taking the GUI version from the assembly info of the HandBrake.exe exectuable.
Pastebin: http://handbrake.fr/pastebin/pastebin.php?show=1058