Changes for issue #56

This commit is contained in:
Michael J. Seiferling
2016-08-18 16:09:25 -06:00
parent 58ec4564ae
commit 77eb164a62
5 changed files with 229 additions and 64 deletions
+49 -34
View File
@@ -62,12 +62,13 @@ Partial Class frmGameManager
Me.btnTags = New System.Windows.Forms.Button() Me.btnTags = New System.Windows.Forms.Button()
Me.grpStats = New System.Windows.Forms.GroupBox() Me.grpStats = New System.Windows.Forms.GroupBox()
Me.lblRestorePath = New System.Windows.Forms.Label() Me.lblRestorePath = New System.Windows.Forms.Label()
Me.btnChangeBackup = New System.Windows.Forms.Button()
Me.txtRestorePath = New System.Windows.Forms.TextBox() Me.txtRestorePath = New System.Windows.Forms.TextBox()
Me.btnOpenRestorePath = New System.Windows.Forms.Button() Me.btnOpenRestorePath = New System.Windows.Forms.Button()
Me.btnOpenBackupFile = New System.Windows.Forms.Button() Me.btnOpenBackupFile = New System.Windows.Forms.Button()
Me.txtFileSize = New System.Windows.Forms.TextBox() Me.txtFileInfo = New System.Windows.Forms.TextBox()
Me.btnDeleteBackup = New System.Windows.Forms.Button() Me.btnDeleteBackup = New System.Windows.Forms.Button()
Me.lblFileSize = New System.Windows.Forms.Label() Me.lblBackupFile = New System.Windows.Forms.Label()
Me.lblSync = New System.Windows.Forms.Label() Me.lblSync = New System.Windows.Forms.Label()
Me.txtCurrentBackup = New System.Windows.Forms.TextBox() Me.txtCurrentBackup = New System.Windows.Forms.TextBox()
Me.lblCurrentBackup = New System.Windows.Forms.Label() Me.lblCurrentBackup = New System.Windows.Forms.Label()
@@ -125,20 +126,20 @@ Partial Class frmGameManager
'btnBackup 'btnBackup
' '
Me.btnBackup.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Me.btnBackup.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnBackup.Location = New System.Drawing.Point(616, 525) Me.btnBackup.Location = New System.Drawing.Point(616, 526)
Me.btnBackup.Name = "btnBackup" Me.btnBackup.Name = "btnBackup"
Me.btnBackup.Size = New System.Drawing.Size(75, 23) Me.btnBackup.Size = New System.Drawing.Size(75, 23)
Me.btnBackup.TabIndex = 18 Me.btnBackup.TabIndex = 19
Me.btnBackup.Text = "&Backup" Me.btnBackup.Text = "&Backup"
Me.btnBackup.UseVisualStyleBackColor = True Me.btnBackup.UseVisualStyleBackColor = True
' '
'btnClose 'btnClose
' '
Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnClose.Location = New System.Drawing.Point(697, 525) Me.btnClose.Location = New System.Drawing.Point(697, 526)
Me.btnClose.Name = "btnClose" Me.btnClose.Name = "btnClose"
Me.btnClose.Size = New System.Drawing.Size(75, 23) Me.btnClose.Size = New System.Drawing.Size(75, 23)
Me.btnClose.TabIndex = 19 Me.btnClose.TabIndex = 20
Me.btnClose.Text = "C&lose" Me.btnClose.Text = "C&lose"
Me.btnClose.UseVisualStyleBackColor = True Me.btnClose.UseVisualStyleBackColor = True
' '
@@ -469,12 +470,13 @@ Partial Class frmGameManager
' '
Me.grpStats.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Me.grpStats.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.grpStats.Controls.Add(Me.lblRestorePath) Me.grpStats.Controls.Add(Me.lblRestorePath)
Me.grpStats.Controls.Add(Me.btnChangeBackup)
Me.grpStats.Controls.Add(Me.txtRestorePath) Me.grpStats.Controls.Add(Me.txtRestorePath)
Me.grpStats.Controls.Add(Me.btnOpenRestorePath) Me.grpStats.Controls.Add(Me.btnOpenRestorePath)
Me.grpStats.Controls.Add(Me.btnOpenBackupFile) Me.grpStats.Controls.Add(Me.btnOpenBackupFile)
Me.grpStats.Controls.Add(Me.txtFileSize) Me.grpStats.Controls.Add(Me.txtFileInfo)
Me.grpStats.Controls.Add(Me.btnDeleteBackup) Me.grpStats.Controls.Add(Me.btnDeleteBackup)
Me.grpStats.Controls.Add(Me.lblFileSize) Me.grpStats.Controls.Add(Me.lblBackupFile)
Me.grpStats.Controls.Add(Me.lblSync) Me.grpStats.Controls.Add(Me.lblSync)
Me.grpStats.Controls.Add(Me.txtCurrentBackup) Me.grpStats.Controls.Add(Me.txtCurrentBackup)
Me.grpStats.Controls.Add(Me.lblCurrentBackup) Me.grpStats.Controls.Add(Me.lblCurrentBackup)
@@ -496,6 +498,16 @@ Partial Class frmGameManager
Me.lblRestorePath.TabIndex = 3 Me.lblRestorePath.TabIndex = 3
Me.lblRestorePath.Text = "Restore Path:" Me.lblRestorePath.Text = "Restore Path:"
' '
'btnChangeBackup
'
Me.btnChangeBackup.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnChangeBackup.Location = New System.Drawing.Point(129, 125)
Me.btnChangeBackup.Name = "btnChangeBackup"
Me.btnChangeBackup.Size = New System.Drawing.Size(114, 23)
Me.btnChangeBackup.TabIndex = 11
Me.btnChangeBackup.Text = "&Change Backup File"
Me.btnChangeBackup.UseVisualStyleBackColor = True
'
'txtRestorePath 'txtRestorePath
' '
Me.txtRestorePath.Location = New System.Drawing.Point(96, 99) Me.txtRestorePath.Location = New System.Drawing.Point(96, 99)
@@ -503,60 +515,62 @@ Partial Class frmGameManager
Me.txtRestorePath.ReadOnly = True Me.txtRestorePath.ReadOnly = True
Me.txtRestorePath.Size = New System.Drawing.Size(387, 20) Me.txtRestorePath.Size = New System.Drawing.Size(387, 20)
Me.txtRestorePath.TabIndex = 8 Me.txtRestorePath.TabIndex = 8
Me.txtRestorePath.TabStop = False
' '
'btnOpenRestorePath 'btnOpenRestorePath
' '
Me.btnOpenRestorePath.Location = New System.Drawing.Point(339, 125) Me.btnOpenRestorePath.Location = New System.Drawing.Point(369, 125)
Me.btnOpenRestorePath.Name = "btnOpenRestorePath" Me.btnOpenRestorePath.Name = "btnOpenRestorePath"
Me.btnOpenRestorePath.Size = New System.Drawing.Size(114, 23) Me.btnOpenRestorePath.Size = New System.Drawing.Size(114, 23)
Me.btnOpenRestorePath.TabIndex = 12 Me.btnOpenRestorePath.TabIndex = 13
Me.btnOpenRestorePath.Text = "O&pen Restore Path" Me.btnOpenRestorePath.Text = "O&pen Restore Path"
Me.btnOpenRestorePath.UseVisualStyleBackColor = True Me.btnOpenRestorePath.UseVisualStyleBackColor = True
' '
'btnOpenBackupFile 'btnOpenBackupFile
' '
Me.btnOpenBackupFile.Location = New System.Drawing.Point(216, 125) Me.btnOpenBackupFile.Location = New System.Drawing.Point(249, 125)
Me.btnOpenBackupFile.Name = "btnOpenBackupFile" Me.btnOpenBackupFile.Name = "btnOpenBackupFile"
Me.btnOpenBackupFile.Size = New System.Drawing.Size(114, 23) Me.btnOpenBackupFile.Size = New System.Drawing.Size(114, 23)
Me.btnOpenBackupFile.TabIndex = 11 Me.btnOpenBackupFile.TabIndex = 12
Me.btnOpenBackupFile.Text = "&Open Backup File" Me.btnOpenBackupFile.Text = "&Open Backup File"
Me.btnOpenBackupFile.UseVisualStyleBackColor = True Me.btnOpenBackupFile.UseVisualStyleBackColor = True
' '
'txtFileSize 'txtFileInfo
' '
Me.txtFileSize.Location = New System.Drawing.Point(96, 74) Me.txtFileInfo.Location = New System.Drawing.Point(96, 74)
Me.txtFileSize.Name = "txtFileSize" Me.txtFileInfo.Name = "txtFileInfo"
Me.txtFileSize.ReadOnly = True Me.txtFileInfo.ReadOnly = True
Me.txtFileSize.Size = New System.Drawing.Size(387, 20) Me.txtFileInfo.Size = New System.Drawing.Size(387, 20)
Me.txtFileSize.TabIndex = 7 Me.txtFileInfo.TabIndex = 7
Me.txtFileSize.TabStop = False Me.txtFileInfo.TabStop = False
' '
'btnDeleteBackup 'btnDeleteBackup
' '
Me.btnDeleteBackup.Location = New System.Drawing.Point(96, 125) Me.btnDeleteBackup.Location = New System.Drawing.Point(9, 125)
Me.btnDeleteBackup.Name = "btnDeleteBackup" Me.btnDeleteBackup.Name = "btnDeleteBackup"
Me.btnDeleteBackup.Size = New System.Drawing.Size(114, 23) Me.btnDeleteBackup.Size = New System.Drawing.Size(114, 23)
Me.btnDeleteBackup.TabIndex = 10 Me.btnDeleteBackup.TabIndex = 10
Me.btnDeleteBackup.Text = "&Delete Backup" Me.btnDeleteBackup.Text = "&Delete Backup"
Me.btnDeleteBackup.UseVisualStyleBackColor = True Me.btnDeleteBackup.UseVisualStyleBackColor = True
' '
'lblFileSize 'lblBackupFile
' '
Me.lblFileSize.AutoSize = True Me.lblBackupFile.AutoSize = True
Me.lblFileSize.Location = New System.Drawing.Point(6, 77) Me.lblBackupFile.Location = New System.Drawing.Point(6, 77)
Me.lblFileSize.Name = "lblFileSize" Me.lblBackupFile.Name = "lblBackupFile"
Me.lblFileSize.Size = New System.Drawing.Size(70, 13) Me.lblBackupFile.Size = New System.Drawing.Size(66, 13)
Me.lblFileSize.TabIndex = 2 Me.lblBackupFile.TabIndex = 2
Me.lblFileSize.Text = "Backup Size:" Me.lblBackupFile.Text = "Backup File:"
' '
'lblSync 'lblSync
' '
Me.lblSync.AutoSize = True Me.lblSync.AutoSize = True
Me.lblSync.Location = New System.Drawing.Point(6, 130) Me.lblSync.Location = New System.Drawing.Point(457, 0)
Me.lblSync.Name = "lblSync" Me.lblSync.Name = "lblSync"
Me.lblSync.Size = New System.Drawing.Size(62, 13) Me.lblSync.Size = New System.Drawing.Size(62, 13)
Me.lblSync.TabIndex = 4 Me.lblSync.TabIndex = 4
Me.lblSync.Text = "Up to Date!" Me.lblSync.Text = "Up to Date!"
Me.lblSync.TextAlign = System.Drawing.ContentAlignment.TopRight
Me.lblSync.Visible = False Me.lblSync.Visible = False
' '
'txtCurrentBackup 'txtCurrentBackup
@@ -598,20 +612,20 @@ Partial Class frmGameManager
'btnMarkAsRestored 'btnMarkAsRestored
' '
Me.btnMarkAsRestored.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Me.btnMarkAsRestored.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnMarkAsRestored.Location = New System.Drawing.Point(429, 525) Me.btnMarkAsRestored.Location = New System.Drawing.Point(429, 526)
Me.btnMarkAsRestored.Name = "btnMarkAsRestored" Me.btnMarkAsRestored.Name = "btnMarkAsRestored"
Me.btnMarkAsRestored.Size = New System.Drawing.Size(100, 23) Me.btnMarkAsRestored.Size = New System.Drawing.Size(100, 23)
Me.btnMarkAsRestored.TabIndex = 16 Me.btnMarkAsRestored.TabIndex = 17
Me.btnMarkAsRestored.Text = "&Mark as Restored" Me.btnMarkAsRestored.Text = "&Mark as Restored"
Me.btnMarkAsRestored.UseVisualStyleBackColor = True Me.btnMarkAsRestored.UseVisualStyleBackColor = True
' '
'btnRestore 'btnRestore
' '
Me.btnRestore.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Me.btnRestore.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnRestore.Location = New System.Drawing.Point(535, 525) Me.btnRestore.Location = New System.Drawing.Point(535, 526)
Me.btnRestore.Name = "btnRestore" Me.btnRestore.Name = "btnRestore"
Me.btnRestore.Size = New System.Drawing.Size(75, 23) Me.btnRestore.Size = New System.Drawing.Size(75, 23)
Me.btnRestore.TabIndex = 17 Me.btnRestore.TabIndex = 18
Me.btnRestore.Text = "&Restore" Me.btnRestore.Text = "&Restore"
Me.btnRestore.UseVisualStyleBackColor = True Me.btnRestore.UseVisualStyleBackColor = True
' '
@@ -854,8 +868,8 @@ Partial Class frmGameManager
Friend WithEvents lblLastBackup As System.Windows.Forms.Label Friend WithEvents lblLastBackup As System.Windows.Forms.Label
Friend WithEvents lblSync As System.Windows.Forms.Label Friend WithEvents lblSync As System.Windows.Forms.Label
Friend WithEvents chkEnabled As System.Windows.Forms.CheckBox Friend WithEvents chkEnabled As System.Windows.Forms.CheckBox
Friend WithEvents txtFileSize As System.Windows.Forms.TextBox Friend WithEvents txtFileInfo As System.Windows.Forms.TextBox
Friend WithEvents lblFileSize As System.Windows.Forms.Label Friend WithEvents lblBackupFile As System.Windows.Forms.Label
Friend WithEvents btnMarkAsRestored As System.Windows.Forms.Button Friend WithEvents btnMarkAsRestored As System.Windows.Forms.Button
Friend WithEvents btnRestore As System.Windows.Forms.Button Friend WithEvents btnRestore As System.Windows.Forms.Button
Friend WithEvents btnDeleteBackup As System.Windows.Forms.Button Friend WithEvents btnDeleteBackup As System.Windows.Forms.Button
@@ -879,4 +893,5 @@ Partial Class frmGameManager
Friend WithEvents cmsFile As System.Windows.Forms.ToolStripMenuItem Friend WithEvents cmsFile As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents txtQuickFilter As TextBox Friend WithEvents txtQuickFilter As TextBox
Friend WithEvents lblQuickFilter As Label Friend WithEvents lblQuickFilter As Label
Friend WithEvents btnChangeBackup As Button
End Class End Class
+75 -9
View File
@@ -281,7 +281,7 @@ Public Class frmGameManager
End If End If
End If End If
sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseExe, "exe", _ sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseExe, "exe",
frmGameManager_Executable, sDefaultFolder, False) frmGameManager_Executable, sDefaultFolder, False)
If sNewPath <> String.Empty Then If sNewPath <> String.Empty Then
@@ -339,10 +339,10 @@ Public Class frmGameManager
'Unix Handler 'Unix Handler
If Not mgrCommon.IsUnix Then If Not mgrCommon.IsUnix Then
sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseCustomIcon, "ico", _ sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseCustomIcon, "ico",
frmGameManager_Icon, sDefaultFolder, False) frmGameManager_Icon, sDefaultFolder, False)
Else Else
sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseCustomIcon, "png", _ sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseCustomIcon, "png",
"PNG", sDefaultFolder, False) "PNG", sDefaultFolder, False)
End If End If
@@ -553,23 +553,25 @@ Public Class frmGameManager
btnOpenBackupFile.Enabled = True btnOpenBackupFile.Enabled = True
btnOpenRestorePath.Enabled = True btnOpenRestorePath.Enabled = True
btnRestore.Enabled = True btnRestore.Enabled = True
btnChangeBackup.Enabled = True
btnDeleteBackup.Enabled = True btnDeleteBackup.Enabled = True
If File.Exists(sFileName) Then If File.Exists(sFileName) Then
txtFileSize.Text = mgrCommon.GetFileSize(sFileName) txtFileInfo.Text = Path.GetFileName(CurrentBackupItem.FileName) & " (" & mgrCommon.GetFileSize(sFileName) & ")"
Else Else
txtFileSize.Text = frmGameManager_ErrorNoBackupExists txtFileInfo.Text = frmGameManager_ErrorNoBackupExists
End If End If
mgrRestore.DoPathOverride(CurrentBackupItem, oApp) mgrRestore.DoPathOverride(CurrentBackupItem, oApp)
txtRestorePath.Text = CurrentBackupItem.RestorePath txtRestorePath.Text = CurrentBackupItem.RestorePath
Else Else
txtCurrentBackup.Text = frmGameManager_Never txtCurrentBackup.Text = frmGameManager_Never
txtFileSize.Text = String.Empty txtFileInfo.Text = String.Empty
txtRestorePath.Text = String.Empty txtRestorePath.Text = String.Empty
btnOpenBackupFile.Enabled = False btnOpenBackupFile.Enabled = False
btnOpenRestorePath.Enabled = False btnOpenRestorePath.Enabled = False
btnRestore.Enabled = False btnRestore.Enabled = False
btnChangeBackup.Enabled = False
btnDeleteBackup.Enabled = False btnDeleteBackup.Enabled = False
End If End If
@@ -777,6 +779,7 @@ Public Class frmGameManager
btnBackup.Enabled = False btnBackup.Enabled = False
btnMarkAsRestored.Enabled = False btnMarkAsRestored.Enabled = False
btnRestore.Enabled = False btnRestore.Enabled = False
btnChangeBackup.Enabled = False
btnDeleteBackup.Enabled = False btnDeleteBackup.Enabled = False
btnOpenBackupFile.Enabled = False btnOpenBackupFile.Enabled = False
btnOpenRestorePath.Enabled = False btnOpenRestorePath.Enabled = False
@@ -806,6 +809,7 @@ Public Class frmGameManager
btnBackup.Enabled = False btnBackup.Enabled = False
btnMarkAsRestored.Enabled = False btnMarkAsRestored.Enabled = False
btnRestore.Enabled = False btnRestore.Enabled = False
btnChangeBackup.Enabled = False
btnDeleteBackup.Enabled = False btnDeleteBackup.Enabled = False
btnOpenBackupFile.Enabled = False btnOpenBackupFile.Enabled = False
btnOpenRestorePath.Enabled = False btnOpenRestorePath.Enabled = False
@@ -1143,6 +1147,52 @@ Public Class frmGameManager
Return True Return True
End Function End Function
Private Sub ChangeBackup()
Dim sNewBackup As String
Dim sNewBackupFile As String
Dim sNewBackupPath As String
Dim sBackupPath As String = Path.GetDirectoryName(BackupFolder & CurrentBackupItem.FileName)
Dim sBackupFile As String = Path.GetFileName(BackupFolder & CurrentBackupItem.FileName)
Dim oBackup As clsBackup = oCurrentBackupItem
sNewBackup = mgrCommon.OpenFileBrowser(mgrCommon.FormatString(frmGameManager_BrowseBackup, CurrentGame.CroppedName), "7z", frmGameManager_BrowseBackupType, sBackupPath, False)
'Check that a selection was made and that it's not already the current file
If sNewBackup <> String.Empty Then
sNewBackupFile = Path.GetFileName(sNewBackup)
sNewBackupPath = Path.GetDirectoryName(sNewBackup)
'The new file must be located in the current backup folder for the selected game
If sNewBackupPath <> sBackupPath Then
mgrCommon.ShowMessage(frmGameManager_ErrorBackupChangePath, CurrentGame.CroppedName, MsgBoxStyle.Exclamation)
ElseIf sNewBackupFile = sBackupFile Then
mgrCommon.ShowMessage(frmGameManager_ErrorBackupChangeFileName, New String() {sNewBackupFile, CurrentGame.CroppedName}, MsgBoxStyle.Exclamation)
Else
'Verify that the user still wants to continue
If mgrCommon.ShowMessage(frmGameManager_ConfirmBackupChange, New String() {sNewBackupFile, CurrentGame.CroppedName}, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
'Set the new file
oBackup.FileName = oBackup.FileName.Replace(Path.GetFileName(oBackup.FileName), sNewBackupFile)
'Clear the checksum (old checksums aren't stored)
oBackup.CheckSum = String.Empty
'Reset date
oBackup.DateUpdated = Date.Now
mgrManifest.DoManifestUpdate(oBackup, mgrSQLite.Database.Remote)
'Refresh backup data and GUI
bIsLoading = True
LoadBackupData()
GetBackupInfo(CurrentGame)
bIsLoading = False
'Check if we want to restore immediately after changing
If mgrCommon.ShowMessage(frmGameManager_ConfirmBackupChangeRestore, sNewBackupFile, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
TriggerSelectedRestore(False)
End If
End If
End If
End If
End Sub
Private Sub MarkAsRestored() Private Sub MarkAsRestored()
Dim oData As KeyValuePair(Of String, String) Dim oData As KeyValuePair(Of String, String)
Dim oGameBackup As clsBackup Dim oGameBackup As clsBackup
@@ -1198,7 +1248,7 @@ Public Class frmGameManager
End If End If
End Sub End Sub
Private Sub TriggerSelectedBackup() Private Sub TriggerSelectedBackup(Optional ByVal bPrompt As Boolean = True)
Dim oData As KeyValuePair(Of String, String) Dim oData As KeyValuePair(Of String, String)
Dim sMsg As String = String.Empty Dim sMsg As String = String.Empty
Dim oGame As clsGame Dim oGame As clsGame
@@ -1224,15 +1274,20 @@ Public Class frmGameManager
End If End If
If bDoBackup Then If bDoBackup Then
If bPrompt Then
If mgrCommon.ShowMessage(sMsg, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then If mgrCommon.ShowMessage(sMsg, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
TriggerBackup = True TriggerBackup = True
Me.Close() Me.Close()
End If End If
Else
TriggerBackup = True
Me.Close()
End If
End If End If
End If End If
End Sub End Sub
Private Sub TriggerSelectedRestore() Private Sub TriggerSelectedRestore(Optional ByVal bPrompt As Boolean = True)
Dim oData As KeyValuePair(Of String, String) Dim oData As KeyValuePair(Of String, String)
Dim sMsg As String = String.Empty Dim sMsg As String = String.Empty
Dim oGame As clsGame Dim oGame As clsGame
@@ -1264,10 +1319,15 @@ Public Class frmGameManager
End If End If
If bDoRestore Then If bDoRestore Then
If bPrompt Then
If mgrCommon.ShowMessage(sMsg, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then If mgrCommon.ShowMessage(sMsg, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
TriggerRestore = True TriggerRestore = True
Me.Close() Me.Close()
End If End If
Else
TriggerRestore = True
Me.Close()
End If
End If End If
End If End If
End Sub End Sub
@@ -1337,8 +1397,9 @@ Public Class frmGameManager
lblRestorePath.Text = frmGameManager_lblRestorePath lblRestorePath.Text = frmGameManager_lblRestorePath
btnOpenRestorePath.Text = frmGameManager_btnOpenRestorePath btnOpenRestorePath.Text = frmGameManager_btnOpenRestorePath
btnOpenBackupFile.Text = frmGameManager_btnOpenBackupFile btnOpenBackupFile.Text = frmGameManager_btnOpenBackupFile
btnChangeBackup.Text = frmGameManager_btnChangeBackup
btnDeleteBackup.Text = frmGameManager_btnDeleteBackup btnDeleteBackup.Text = frmGameManager_btnDeleteBackup
lblFileSize.Text = frmGameManager_lblFileSize lblBackupFile.Text = frmGameManager_lblBackupFile
lblCurrentBackup.Text = frmGameManager_lblCurrentBackup lblCurrentBackup.Text = frmGameManager_lblCurrentBackup
lblLastBackup.Text = frmGameManager_lblLastBackup lblLastBackup.Text = frmGameManager_lblLastBackup
btnIconBrowse.Text = frmGameManager_btnIconBrowse btnIconBrowse.Text = frmGameManager_btnIconBrowse
@@ -1474,6 +1535,10 @@ Public Class frmGameManager
DeleteBackup() DeleteBackup()
End Sub End Sub
Private Sub btnChangeBackup_Click(sender As Object, e As EventArgs) Handles btnChangeBackup.Click
ChangeBackup()
End Sub
Private Sub btnMarkAsRestored_Click(sender As Object, e As EventArgs) Handles btnMarkAsRestored.Click Private Sub btnMarkAsRestored_Click(sender As Object, e As EventArgs) Handles btnMarkAsRestored.Click
MarkAsRestored() MarkAsRestored()
End Sub End Sub
@@ -1542,4 +1607,5 @@ Public Class frmGameManager
Private Sub frmGameManager_Shown(sender As Object, e As EventArgs) Handles MyBase.Shown Private Sub frmGameManager_Shown(sender As Object, e As EventArgs) Handles MyBase.Shown
txtQuickFilter.Focus() txtQuickFilter.Focus()
End Sub End Sub
End Class End Class
+2 -2
View File
@@ -33,7 +33,7 @@ Imports System.Runtime.InteropServices
' by using the '*' as shown below: ' by using the '*' as shown below:
' <Assembly: AssemblyVersion("1.0.*")> ' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("0.97.*")> <Assembly: AssemblyVersion("0.98.*")>
<Assembly: AssemblyFileVersion("0.97.0.0")> <Assembly: AssemblyFileVersion("0.98.0.0")>
<Assembly: NeutralResourcesLanguageAttribute("en")> <Assembly: NeutralResourcesLanguageAttribute("en")>
+72 -9
View File
@@ -1077,6 +1077,24 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Looks up a localized string similar to Choose a [PARAM] backup file.
'''</summary>
Friend ReadOnly Property frmGameManager_BrowseBackup() As String
Get
Return ResourceManager.GetString("frmGameManager_BrowseBackup", resourceCulture)
End Get
End Property
'''<summary>
''' Looks up a localized string similar to 7-Zip.
'''</summary>
Friend ReadOnly Property frmGameManager_BrowseBackupType() As String
Get
Return ResourceManager.GetString("frmGameManager_BrowseBackupType", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Looks up a localized string similar to +. ''' Looks up a localized string similar to +.
'''</summary> '''</summary>
@@ -1113,6 +1131,15 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Looks up a localized string similar to &amp;Change Backup File.
'''</summary>
Friend ReadOnly Property frmGameManager_btnChangeBackup() As String
Get
Return ResourceManager.GetString("frmGameManager_btnChangeBackup", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Looks up a localized string similar to C&amp;lose. ''' Looks up a localized string similar to C&amp;lose.
'''</summary> '''</summary>
@@ -1374,6 +1401,24 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Looks up a localized string similar to [PARAM] will be the new backup file for [PARAM].[BR][BR]Is this correct?.
'''</summary>
Friend ReadOnly Property frmGameManager_ConfirmBackupChange() As String
Get
Return ResourceManager.GetString("frmGameManager_ConfirmBackupChange", resourceCulture)
End Get
End Property
'''<summary>
''' Looks up a localized string similar to Do you want to restore [PARAM] now?.
'''</summary>
Friend ReadOnly Property frmGameManager_ConfirmBackupChangeRestore() As String
Get
Return ResourceManager.GetString("frmGameManager_ConfirmBackupChangeRestore", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Looks up a localized string similar to This will delete the backup file and all records of this backup. This cannot be undone. [BR][BR]Do you want to remove the data for [PARAM]?. ''' Looks up a localized string similar to This will delete the backup file and all records of this backup. This cannot be undone. [BR][BR]Do you want to remove the data for [PARAM]?.
'''</summary> '''</summary>
@@ -1491,6 +1536,24 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Looks up a localized string similar to [PARAM] is already the current backup file for [PARAM]..
'''</summary>
Friend ReadOnly Property frmGameManager_ErrorBackupChangeFileName() As String
Get
Return ResourceManager.GetString("frmGameManager_ErrorBackupChangeFileName", resourceCulture)
End Get
End Property
'''<summary>
''' Looks up a localized string similar to You cannot choose a file located outside the current [PARAM] backup folder..
'''</summary>
Friend ReadOnly Property frmGameManager_ErrorBackupChangePath() As String
Get
Return ResourceManager.GetString("frmGameManager_ErrorBackupChangePath", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Looks up a localized string similar to A game with this exact name and process already exists.. ''' Looks up a localized string similar to A game with this exact name and process already exists..
'''</summary> '''</summary>
@@ -1689,6 +1752,15 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Looks up a localized string similar to Backup File:.
'''</summary>
Friend ReadOnly Property frmGameManager_lblBackupFile() As String
Get
Return ResourceManager.GetString("frmGameManager_lblBackupFile", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Looks up a localized string similar to Company:. ''' Looks up a localized string similar to Company:.
'''</summary> '''</summary>
@@ -1707,15 +1779,6 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Looks up a localized string similar to Backup Size:.
'''</summary>
Friend ReadOnly Property frmGameManager_lblFileSize() As String
Get
Return ResourceManager.GetString("frmGameManager_lblFileSize", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Looks up a localized string similar to Game Path:. ''' Looks up a localized string similar to Game Path:.
'''</summary> '''</summary>
+23 -2
View File
@@ -619,8 +619,8 @@
<data name="frmGameManager_lblCurrentBackup" xml:space="preserve"> <data name="frmGameManager_lblCurrentBackup" xml:space="preserve">
<value>Current Backup:</value> <value>Current Backup:</value>
</data> </data>
<data name="frmGameManager_lblFileSize" xml:space="preserve"> <data name="frmGameManager_lblBackupFile" xml:space="preserve">
<value>Backup Size:</value> <value>Backup File:</value>
</data> </data>
<data name="frmGameManager_lblGamePath" xml:space="preserve"> <data name="frmGameManager_lblGamePath" xml:space="preserve">
<value>Game Path:</value> <value>Game Path:</value>
@@ -1693,4 +1693,25 @@
<data name="App_URLImportLinux" xml:space="preserve"> <data name="App_URLImportLinux" xml:space="preserve">
<value>http://mikemaximus.github.io/gbm-web/GBM_Official_Linux.xml</value> <value>http://mikemaximus.github.io/gbm-web/GBM_Official_Linux.xml</value>
</data> </data>
<data name="frmGameManager_BrowseBackup" xml:space="preserve">
<value>Choose a [PARAM] backup file</value>
</data>
<data name="frmGameManager_BrowseBackupType" xml:space="preserve">
<value>7-Zip</value>
</data>
<data name="frmGameManager_btnChangeBackup" xml:space="preserve">
<value>&amp;Change Backup File</value>
</data>
<data name="frmGameManager_ConfirmBackupChange" xml:space="preserve">
<value>[PARAM] will be the new backup file for [PARAM].[BR][BR]Is this correct?</value>
</data>
<data name="frmGameManager_ConfirmBackupChangeRestore" xml:space="preserve">
<value>Do you want to restore [PARAM] now?</value>
</data>
<data name="frmGameManager_ErrorBackupChangeFileName" xml:space="preserve">
<value>[PARAM] is already the current backup file for [PARAM].</value>
</data>
<data name="frmGameManager_ErrorBackupChangePath" xml:space="preserve">
<value>You cannot choose a file located outside the current [PARAM] backup folder.</value>
</data>
</root> </root>