Merge branch 'master' of https://github.com/MikeMaximus/gbm
This commit is contained in:
@@ -1558,6 +1558,7 @@ Public Class frmGameManager
|
|||||||
Private Sub TriggerSelectedImportBackup()
|
Private Sub TriggerSelectedImportBackup()
|
||||||
Dim sDefaultFolder As String = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
|
Dim sDefaultFolder As String = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
|
||||||
Dim oBackup As New mgrBackup
|
Dim oBackup As New mgrBackup
|
||||||
|
Dim sConfirm As String = frmGameManager_ConfirmBackupImport
|
||||||
Dim sFile As String
|
Dim sFile As String
|
||||||
Dim sFiles As String()
|
Dim sFiles As String()
|
||||||
|
|
||||||
@@ -1580,7 +1581,16 @@ Public Class frmGameManager
|
|||||||
End If
|
End If
|
||||||
Next
|
Next
|
||||||
|
|
||||||
If mgrCommon.ShowMessage(frmGameManager_ConfirmBackupImport, oCurrentGame.CroppedName, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
|
If sFiles.Length > 1 And Not CurrentGame.AppendTimeStamp Then
|
||||||
|
mgrCommon.ShowMessage(frmGameManager_WarningImportBackupSaveMulti, MsgBoxStyle.Exclamation)
|
||||||
|
Exit Sub
|
||||||
|
End If
|
||||||
|
|
||||||
|
If sFiles.Length = 1 And Not CurrentGame.AppendTimeStamp And mgrManifest.DoManifestCheck(CurrentGame.ID, mgrSQLite.Database.Remote) Then
|
||||||
|
sConfirm = frmGameManager_ConfirmBackupImportOverwriteSingle
|
||||||
|
End If
|
||||||
|
|
||||||
|
If mgrCommon.ShowMessage(sConfirm, oCurrentGame.CroppedName, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
|
||||||
Me.TriggerImportBackup = True
|
Me.TriggerImportBackup = True
|
||||||
Me.Close()
|
Me.Close()
|
||||||
End If
|
End If
|
||||||
@@ -1944,11 +1954,7 @@ Public Class frmGameManager
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub btnImportBackup_Click(sender As Object, e As EventArgs) Handles btnImportBackup.Click
|
Private Sub btnImportBackup_Click(sender As Object, e As EventArgs) Handles btnImportBackup.Click
|
||||||
If CurrentGame.AppendTimeStamp Then
|
TriggerSelectedImportBackup()
|
||||||
TriggerSelectedImportBackup()
|
|
||||||
Else
|
|
||||||
mgrCommon.ShowMessage(frmGameManager_WarningImportBackupSaveMulti, MsgBoxStyle.Information)
|
|
||||||
End If
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub chkFolderSave_CheckedChanged(sender As Object, e As EventArgs) Handles chkFolderSave.CheckedChanged
|
Private Sub chkFolderSave_CheckedChanged(sender As Object, e As EventArgs) Handles chkFolderSave.CheckedChanged
|
||||||
|
|||||||
Generated
+2
-2
@@ -517,9 +517,9 @@ Partial Class frmSettings
|
|||||||
Me.chkShowResolvedPaths.AutoSize = True
|
Me.chkShowResolvedPaths.AutoSize = True
|
||||||
Me.chkShowResolvedPaths.Location = New System.Drawing.Point(6, 65)
|
Me.chkShowResolvedPaths.Location = New System.Drawing.Point(6, 65)
|
||||||
Me.chkShowResolvedPaths.Name = "chkShowResolvedPaths"
|
Me.chkShowResolvedPaths.Name = "chkShowResolvedPaths"
|
||||||
Me.chkShowResolvedPaths.Size = New System.Drawing.Size(154, 17)
|
Me.chkShowResolvedPaths.Size = New System.Drawing.Size(238, 17)
|
||||||
Me.chkShowResolvedPaths.TabIndex = 2
|
Me.chkShowResolvedPaths.TabIndex = 2
|
||||||
Me.chkShowResolvedPaths.Text = "Show resolved save paths "
|
Me.chkShowResolvedPaths.Text = "Show resolved save paths in Game Manager"
|
||||||
Me.chkShowResolvedPaths.UseVisualStyleBackColor = True
|
Me.chkShowResolvedPaths.UseVisualStyleBackColor = True
|
||||||
'
|
'
|
||||||
'chkSessionTracking
|
'chkSessionTracking
|
||||||
|
|||||||
@@ -215,6 +215,7 @@ Public Class mgrBackup
|
|||||||
|
|
||||||
Public Sub ImportBackupFiles(ByVal hshImportList As Hashtable)
|
Public Sub ImportBackupFiles(ByVal hshImportList As Hashtable)
|
||||||
Dim oGame As clsGame
|
Dim oGame As clsGame
|
||||||
|
Dim bOverwriteCurrent As Boolean = False
|
||||||
Dim bContinue As Boolean = True
|
Dim bContinue As Boolean = True
|
||||||
Dim sFileToImport As String
|
Dim sFileToImport As String
|
||||||
Dim sBackupFile As String
|
Dim sBackupFile As String
|
||||||
@@ -223,9 +224,13 @@ Public Class mgrBackup
|
|||||||
For Each de As DictionaryEntry In hshImportList
|
For Each de As DictionaryEntry In hshImportList
|
||||||
sFileToImport = CStr(de.Key)
|
sFileToImport = CStr(de.Key)
|
||||||
oGame = DirectCast(de.Value, clsGame)
|
oGame = DirectCast(de.Value, clsGame)
|
||||||
If File.Exists(sFileToImport) Then
|
|
||||||
|
|
||||||
|
'Enter overwite mode if we are importing a single backup and "Save Multiple Backups" is not enabled.
|
||||||
|
If hshImportList.Count = 1 And Not oGame.AppendTimeStamp Then bOverwriteCurrent = True
|
||||||
|
|
||||||
|
If File.Exists(sFileToImport) Then
|
||||||
sBackupFile = oSettings.BackupFolder
|
sBackupFile = oSettings.BackupFolder
|
||||||
|
|
||||||
If oSettings.CreateSubFolder Then
|
If oSettings.CreateSubFolder Then
|
||||||
sBackupFile = sBackupFile & Path.DirectorySeparatorChar & GetFileName(oGame)
|
sBackupFile = sBackupFile & Path.DirectorySeparatorChar & GetFileName(oGame)
|
||||||
bContinue = HandleSubFolder(oGame, sBackupFile)
|
bContinue = HandleSubFolder(oGame, sBackupFile)
|
||||||
@@ -236,14 +241,32 @@ Public Class mgrBackup
|
|||||||
oBackup.MonitorID = oGame.ID
|
oBackup.MonitorID = oGame.ID
|
||||||
oBackup.DateUpdated = File.GetLastWriteTime(sFileToImport)
|
oBackup.DateUpdated = File.GetLastWriteTime(sFileToImport)
|
||||||
oBackup.UpdatedBy = mgrBackup_ImportedFile
|
oBackup.UpdatedBy = mgrBackup_ImportedFile
|
||||||
sBackupFile = sBackupFile & Path.DirectorySeparatorChar & GetFileName(oGame) & BuildFileTimeStamp(oBackup.DateUpdated) & ".7z"
|
If bOverwriteCurrent Then
|
||||||
oBackup.FileName = sBackupFile.Replace(Settings.BackupFolder & Path.DirectorySeparatorChar, String.Empty)
|
sBackupFile = sBackupFile & Path.DirectorySeparatorChar & GetFileName(oGame) & ".7z"
|
||||||
If mgrCommon.CopyFile(sFileToImport, sBackupFile, False) Then
|
|
||||||
oBackup.CheckSum = mgrHash.Generate_SHA256_Hash(sBackupFile)
|
|
||||||
mgrManifest.DoManifestAdd(oBackup, mgrSQLite.Database.Remote)
|
|
||||||
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ImportSuccess, New String() {sFileToImport, oGame.Name}), False, ToolTipIcon.Error, True)
|
|
||||||
Else
|
Else
|
||||||
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorImportBackupCopy, sFileToImport), False, ToolTipIcon.Error, True)
|
sBackupFile = sBackupFile & Path.DirectorySeparatorChar & GetFileName(oGame) & BuildFileTimeStamp(oBackup.DateUpdated) & ".7z"
|
||||||
|
End If
|
||||||
|
|
||||||
|
oBackup.FileName = sBackupFile.Replace(Settings.BackupFolder & Path.DirectorySeparatorChar, String.Empty)
|
||||||
|
|
||||||
|
If bOverwriteCurrent Then
|
||||||
|
If mgrCommon.CopyFile(sFileToImport, sBackupFile, True) Then
|
||||||
|
oBackup.CheckSum = mgrHash.Generate_SHA256_Hash(sBackupFile)
|
||||||
|
If Not mgrManifest.DoUpdateLatestManifest(oBackup, mgrSQLite.Database.Remote) Then
|
||||||
|
mgrManifest.DoManifestAdd(oBackup, mgrSQLite.Database.Remote)
|
||||||
|
End If
|
||||||
|
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ImportSuccess, New String() {sFileToImport, oGame.Name}), False, ToolTipIcon.Info, True)
|
||||||
|
Else
|
||||||
|
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorImportBackupCopy, sFileToImport), False, ToolTipIcon.Error, True)
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
If mgrCommon.CopyFile(sFileToImport, sBackupFile, False) Then
|
||||||
|
oBackup.CheckSum = mgrHash.Generate_SHA256_Hash(sBackupFile)
|
||||||
|
mgrManifest.DoManifestAdd(oBackup, mgrSQLite.Database.Remote)
|
||||||
|
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ImportSuccess, New String() {sFileToImport, oGame.Name}), False, ToolTipIcon.Info, True)
|
||||||
|
Else
|
||||||
|
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorImportBackupCopy, sFileToImport), False, ToolTipIcon.Error, True)
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|||||||
Generated
+11
-2
@@ -1887,6 +1887,15 @@ Namespace My.Resources
|
|||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
'''<summary>
|
||||||
|
''' Looks up a localized string similar to Importing this backup file will overwrite the current backup file for [PARAM].[BR][BR]Do you want to continue? This will close the form..
|
||||||
|
'''</summary>
|
||||||
|
Friend ReadOnly Property frmGameManager_ConfirmBackupImportOverwriteSingle() As String
|
||||||
|
Get
|
||||||
|
Return ResourceManager.GetString("frmGameManager_ConfirmBackupImportOverwriteSingle", resourceCulture)
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
'''<summary>
|
'''<summary>
|
||||||
''' Looks up a localized string similar to Are you sure you want to delete [PARAM]? This cannot be undone.[BR][BR]This will not delete any backup files that already exist for this game..
|
''' Looks up a localized string similar to Are you sure you want to delete [PARAM]? This cannot be undone.[BR][BR]This will not delete any backup files that already exist for this game..
|
||||||
'''</summary>
|
'''</summary>
|
||||||
@@ -2473,7 +2482,7 @@ Namespace My.Resources
|
|||||||
End Property
|
End Property
|
||||||
|
|
||||||
'''<summary>
|
'''<summary>
|
||||||
''' Looks up a localized string similar to The "Save multiple backups" option must be enabled on this configuration to import backup files..
|
''' Looks up a localized string similar to The "Save multiple backups" option must be enabled on this configuration to import multiple backup files..
|
||||||
'''</summary>
|
'''</summary>
|
||||||
Friend ReadOnly Property frmGameManager_WarningImportBackupSaveMulti() As String
|
Friend ReadOnly Property frmGameManager_WarningImportBackupSaveMulti() As String
|
||||||
Get
|
Get
|
||||||
@@ -4651,7 +4660,7 @@ Namespace My.Resources
|
|||||||
End Property
|
End Property
|
||||||
|
|
||||||
'''<summary>
|
'''<summary>
|
||||||
''' Looks up a localized string similar to Show resolved save paths.
|
''' Looks up a localized string similar to Show resolved save paths in Game Manager.
|
||||||
'''</summary>
|
'''</summary>
|
||||||
Friend ReadOnly Property frmSettings_chkShowResolvedPaths() As String
|
Friend ReadOnly Property frmSettings_chkShowResolvedPaths() As String
|
||||||
Get
|
Get
|
||||||
|
|||||||
@@ -2222,7 +2222,7 @@
|
|||||||
<value>An error occured while building a list of environment variables.[BR][BR][PARAM]</value>
|
<value>An error occured while building a list of environment variables.[BR][BR][PARAM]</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="frmSettings_chkShowResolvedPaths" xml:space="preserve">
|
<data name="frmSettings_chkShowResolvedPaths" xml:space="preserve">
|
||||||
<value>Show resolved save paths</value>
|
<value>Show resolved save paths in Game Manager</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="frmGameManager_7zBackup" xml:space="preserve">
|
<data name="frmGameManager_7zBackup" xml:space="preserve">
|
||||||
<value>7-Zip</value>
|
<value>7-Zip</value>
|
||||||
@@ -2255,7 +2255,7 @@
|
|||||||
<value>[PARAM] is a reserved variable, you must enter a different name.</value>
|
<value>[PARAM] is a reserved variable, you must enter a different name.</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="frmGameManager_WarningImportBackupSaveMulti" xml:space="preserve">
|
<data name="frmGameManager_WarningImportBackupSaveMulti" xml:space="preserve">
|
||||||
<value>The "Save multiple backups" option must be enabled on this configuration to import backup files.</value>
|
<value>The "Save multiple backups" option must be enabled on this configuration to import multiple backup files.</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="frmGameManager_cmsOfficialLinux" xml:space="preserve">
|
<data name="frmGameManager_cmsOfficialLinux" xml:space="preserve">
|
||||||
<value>&Linux...</value>
|
<value>&Linux...</value>
|
||||||
@@ -2266,4 +2266,7 @@
|
|||||||
<data name="frmGameManager_WarningWinConfigsInLinux" xml:space="preserve">
|
<data name="frmGameManager_WarningWinConfigsInLinux" xml:space="preserve">
|
||||||
<value>Official Windows configurations can be used in Linux for games running in Wine or Proton.[BR][BR]You do not need to modify these configurations, GBM will automatically do any required path conversions the first time the game is detected.[BR][BR]This message will only be shown once.</value>
|
<value>Official Windows configurations can be used in Linux for games running in Wine or Proton.[BR][BR]You do not need to modify these configurations, GBM will automatically do any required path conversions the first time the game is detected.[BR][BR]This message will only be shown once.</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="frmGameManager_ConfirmBackupImportOverwriteSingle" xml:space="preserve">
|
||||||
|
<value>Importing this backup file will overwrite the current backup file for [PARAM].[BR][BR]Do you want to continue? This will close the form.</value>
|
||||||
|
</data>
|
||||||
</root>
|
</root>
|
||||||
+4
-4
@@ -2,7 +2,7 @@ Game Backup Monitor v1.1.5 Readme
|
|||||||
http://mikemaximus.github.io/gbm-web/
|
http://mikemaximus.github.io/gbm-web/
|
||||||
gamebackupmonitor@gmail.com
|
gamebackupmonitor@gmail.com
|
||||||
|
|
||||||
October 1st, 2018
|
October 4th, 2018
|
||||||
|
|
||||||
New in 1.1.5
|
New in 1.1.5
|
||||||
|
|
||||||
@@ -24,14 +24,14 @@ All Platforms:
|
|||||||
- GBM will no longer allow the creation of variables using reserved names, such as APPDATA.
|
- GBM will no longer allow the creation of variables using reserved names, such as APPDATA.
|
||||||
- Your configurations will be automatically updated to these new formats when upgrading to v1.1.5.
|
- Your configurations will be automatically updated to these new formats when upgrading to v1.1.5.
|
||||||
- These changes will break game list compatability with other versions of GBM. Archived lists are available at http://mikemaximus.github.io/gbm-web/archive.html for those that wish to stay on an older version.
|
- These changes will break game list compatability with other versions of GBM. Archived lists are available at http://mikemaximus.github.io/gbm-web/archive.html for those that wish to stay on an older version.
|
||||||
- Added a new setting, "Show resolved save paths".
|
- Added a new setting, "Show resolved save paths in Game Manager".
|
||||||
- This new setting is enabled by default.
|
- This new setting is enabled by default.
|
||||||
- When enabled, GBM will display resolved save paths on the Game Manager. This is how GBM displayed paths prior to v1.1.5.
|
- When enabled, GBM will display resolved save paths in the Game Manager. This is how GBM displayed paths prior to v1.1.5.
|
||||||
- When disabled, GBM will display save paths with their variables when applicable.
|
- When disabled, GBM will display save paths with their variables when applicable.
|
||||||
- Added a tooltip to applicable "Path" fields on the Game Manager.
|
- Added a tooltip to applicable "Path" fields on the Game Manager.
|
||||||
- This tooltip either displays either a resolved or unresolved path.
|
- This tooltip either displays either a resolved or unresolved path.
|
||||||
- The behaviour is toggled by the "Show resolved save paths" setting.
|
- The behaviour is toggled by the "Show resolved save paths" setting.
|
||||||
-Added "Import Backup Files" feature to the Game Manager.
|
- Added "Import Backup Files" feature to the Game Manager.
|
||||||
- This feature allows you to import one or more backup files for a specific game configuration.
|
- This feature allows you to import one or more backup files for a specific game configuration.
|
||||||
- This is useful if you lost your GBM database(s), but not the backup files. It also can be used to easily move compatible saved game backups between Windows and Linux.
|
- This is useful if you lost your GBM database(s), but not the backup files. It also can be used to easily move compatible saved game backups between Windows and Linux.
|
||||||
- GBM cannot verify that the backups being imported are compatible with the current configuration. This is up to the user!
|
- GBM cannot verify that the backups being imported are compatible with the current configuration. This is up to the user!
|
||||||
|
|||||||
Reference in New Issue
Block a user