46 Commits

Author SHA1 Message Date
Michael J. Seiferling
b5d6c058aa Updated readme for stable release 2015-12-30 23:28:52 -06:00
Michael J. Seiferling
c847cf53d0 Fixed a few string typos 2015-12-30 21:35:42 -06:00
Michael J. Seiferling
92ad195510 Merge pull request #28 from MikeMaximus/v96
Merge current v96 changes into v95
2015-12-30 21:24:59 -06:00
Michael J. Seiferling
18686abced Reverted version for merge 2015-12-30 21:20:07 -06:00
Michael J. Seiferling
4f45239e90 Changed maximum size of session log 2015-12-29 22:35:56 -06:00
Michael J. Seiferling
88e0fa9afd Moved remaining strings to resource (managers) 2015-12-24 11:19:53 -06:00
Michael J. Seiferling
51ca315edd Moved strings to resource (frmStartupWizard, frmTags, frmCustomVariables) 2015-12-23 20:51:54 -06:00
Michael J. Seiferling
da9a1d8b53 Moved strings to resource (frmGameTags, frmIncludeExclude, frmSettings) 2015-12-23 19:54:45 -06:00
Michael J. Seiferling
0e93d284ea Moved strings to resource (frmAdvancedImport, frmChooseGame, frmFileFolderSearch, frmFilter) 2015-12-22 19:50:40 -06:00
Michael J. Seiferling
96ca94a3ac Moved strings to resource (frmAddWizard) 2015-12-22 13:31:15 -06:00
Michael J. Seiferling
83e14a20ad Renamed image resources 2015-12-22 10:09:37 -06:00
Michael J. Seiferling
3c941bae8d Reduced resource code usage 2015-12-22 09:57:46 -06:00
Michael J. Seiferling
4316a7c7be Moved strings to resource (frmGameManager) 2015-12-21 12:06:34 -06:00
Michael J. Seiferling
8778f2e1c0 Moved strings to resource (frmMain) 2015-12-19 16:53:47 -06:00
Michael J. Seiferling
8930f6d6cc Added common message box function 2015-12-18 12:16:09 -06:00
Michael J. Seiferling
50cb987e9a Updated readme for pre-release 2015-12-15 10:45:32 -06:00
Michael J. Seiferling
333d18f296 Minor UI changes to Settings and Game Manager 2015-12-14 23:42:50 -06:00
Michael J. Seiferling
f79c446adc Fixed issue #26 2015-12-14 12:08:45 -06:00
Michael J. Seiferling
022ef5d35c Minor UI and validation fixes 2015-12-12 22:22:20 -06:00
Michael J. Seiferling
3f35d442d5 Minor UI and Start Up Wizard changes 2015-12-11 14:33:02 -06:00
Michael J. Seiferling
3c64ef3320 Moved import / export features into Game Manager 2015-12-10 21:35:51 -06:00
Michael J. Seiferling
8a359e949a Minor UI changes 2015-12-09 18:25:47 -06:00
Michael J. Seiferling
19802a5883 Updated for issue 25 2015-12-09 12:00:10 -06:00
Michael J. Seiferling
87326981dd Updates for issues 20 and 24 2015-12-08 10:10:44 -06:00
Michael J. Seiferling
f22bcb91a9 Update for issues 23 and 24 2015-12-07 16:31:28 -06:00
Michael J. Seiferling
fa27c3c389 Fixed issue 23 2015-12-07 15:19:41 -06:00
Michael J. Seiferling
d42093c860 Minor UI fixes for issue 20 2015-12-06 23:50:29 -06:00
Michael J. Seiferling
7871b6e012 Updates for issue 20 and minor UI fixes 2015-12-06 20:41:24 -06:00
Michael J. Seiferling
d26c78c093 Usability updates for filters and wizards 2015-12-05 21:27:53 -06:00
Michael J. Seiferling
80badb577a Fixed import bug caused by issue 13 2015-12-05 17:24:50 -06:00
Michael J. Seiferling
b270ffeabe Fixes for backup threshold setting 2015-12-05 13:14:16 -06:00
Michael J. Seiferling
83135acb90 Added backup threshold setting (Issue 19) 2015-12-05 10:42:55 -06:00
Michael J. Seiferling
1e68728930 Changes for issue 20 and tooltip changes 2015-12-04 11:57:54 -06:00
Michael J. Seiferling
a27802fea7 Removed DOSBox update from DB upgrade 2015-12-04 10:42:22 -06:00
Michael J. Seiferling
7abdf9da7b Bug fixes for issues 13, 18, 21 2015-12-04 10:27:25 -06:00
Michael J. Seiferling
237f5e7fa4 UI fixes (sorting on listboxes) 2015-12-03 22:21:38 -06:00
Michael J. Seiferling
f8207683ad Various UI fixes 2015-12-02 20:40:40 -06:00
Michael J. Seiferling
b96f797bbf Removed unique DOSBox handling 2015-12-01 12:43:58 -06:00
Michael J. Seiferling
07a4981488 Fixed directory rename bug 2015-12-01 10:56:00 -06:00
Michael J. Seiferling
e0277ac0fa Merge branch 'v95' 2015-12-01 00:40:25 -06:00
Michael J. Seiferling
39bbafd731 Various tweaks and changes 2015-11-30 21:25:39 -06:00
Michael J. Seiferling
3062b20775 Second pass of include / exclude builder 2015-11-30 15:05:46 -06:00
Michael J. Seiferling
525c7d3ec3 Added context menu and game manager tweaks 2015-11-29 11:39:25 -06:00
Michael J. Seiferling
0339a09b08 Minor clean-up to various forms 2015-11-27 22:33:34 -06:00
Michael J. Seiferling
de5d1e062a First pass of include / exclude builder 2015-11-27 17:07:50 -06:00
Michael J. Seiferling
7e1302714d Started on include / exclude builder 2015-11-27 12:28:08 -06:00
50 changed files with 8492 additions and 1779 deletions
+1 -1
View File
@@ -32,7 +32,7 @@
ReadOnly Property CroppedName As String
Get
If Name.Length > 40 Then
Return sName.Substring(0, 41) & "..."
Return sName.Substring(0, 41).Trim & "..."
Else
Return sName
End If
+8 -20
View File
@@ -16,7 +16,6 @@
Private bEnabled As Boolean = True
Private bMonitorOnly As Boolean = False
Private bDuplicate As Boolean = False
Private sDOSBoxProcess As String = String.Empty
Private bTempGame As Boolean = False
Private oImportTags As New List(Of Tag)
@@ -29,10 +28,16 @@
End Get
End Property
ReadOnly Property CompoundKey As String
Get
Return ProcessName & ":" & Name
End Get
End Property
ReadOnly Property CroppedName As String
Get
If Name.Length > 40 Then
Return sGameName.Substring(0, 41) & "..."
Return sGameName.Substring(0, 41).Trim & "..."
Else
Return sGameName
End If
@@ -184,15 +189,6 @@
End Set
End Property
Property DOSBoxProcess As String
Get
Return sDOSBoxProcess
End Get
Set(value As String)
sDOSBoxProcess = value
End Set
End Property
ReadOnly Property TruePath As String
Get
Return sPath
@@ -300,15 +296,7 @@
'Handle Duplicates
sProcessName = Me.ProcessName
If Me.Duplicate Then
If Me.ProcessName.Contains("dosbox") Then
If Me.ProcessName.Split(":").Length = 3 Then
sProcessName = Me.ProcessName.Remove(Me.ProcessName.LastIndexOf(":"))
Else
sProcessName = Me.ProcessName
End If
Else
sProcessName = Me.ProcessName.Split(":")(0)
End If
sProcessName = Me.ProcessName.Split(":")(0)
End If
Return sProcessName
+108 -207
View File
@@ -22,7 +22,6 @@ Partial Class frmAddWizard
'Do not modify it using the code editor.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmAddWizard))
Me.tabWizard = New System.Windows.Forms.TabControl()
Me.tbPage1 = New System.Windows.Forms.TabPage()
Me.lblStep1Title = New System.Windows.Forms.Label()
@@ -31,9 +30,6 @@ Partial Class frmAddWizard
Me.txtName = New System.Windows.Forms.TextBox()
Me.lblStep1Intro = New System.Windows.Forms.Label()
Me.tbPage2 = New System.Windows.Forms.TabPage()
Me.lbldBox = New System.Windows.Forms.Label()
Me.btndBoxBrowse = New System.Windows.Forms.Button()
Me.txtdBoxProcess = New System.Windows.Forms.TextBox()
Me.lblStep2Title = New System.Windows.Forms.Label()
Me.lblStep2Instructions = New System.Windows.Forms.Label()
Me.lblDrag2 = New System.Windows.Forms.Label()
@@ -49,21 +45,18 @@ Partial Class frmAddWizard
Me.txtSavePath = New System.Windows.Forms.TextBox()
Me.lblStep3Intro = New System.Windows.Forms.Label()
Me.tbPage3a = New System.Windows.Forms.TabPage()
Me.grpFileTypes = New System.Windows.Forms.GroupBox()
Me.optSpecificFile = New System.Windows.Forms.RadioButton()
Me.btnFileTypeBrowse = New System.Windows.Forms.Button()
Me.optFileType = New System.Windows.Forms.RadioButton()
Me.btnStep3aClear = New System.Windows.Forms.Button()
Me.lblIncludePathTitle = New System.Windows.Forms.Label()
Me.lblIncludePath = New System.Windows.Forms.Label()
Me.lblFileTypes = New System.Windows.Forms.Label()
Me.btnInclude = New System.Windows.Forms.Button()
Me.lblStep3aTitle = New System.Windows.Forms.Label()
Me.lblStep3aInstructions = New System.Windows.Forms.Label()
Me.txtFileTypes = New System.Windows.Forms.TextBox()
Me.tbPage4 = New System.Windows.Forms.TabPage()
Me.grpExclude = New System.Windows.Forms.GroupBox()
Me.optExcludeSpecificFile = New System.Windows.Forms.RadioButton()
Me.btnExcludeBrowse = New System.Windows.Forms.Button()
Me.optExcludeFileType = New System.Windows.Forms.RadioButton()
Me.optExcludeFolder = New System.Windows.Forms.RadioButton()
Me.btnStep4Clear = New System.Windows.Forms.Button()
Me.lblExcludePathTitle = New System.Windows.Forms.Label()
Me.lblExcludePath = New System.Windows.Forms.Label()
Me.lblExclude = New System.Windows.Forms.Label()
Me.btnExclude = New System.Windows.Forms.Button()
Me.lblStep4Title = New System.Windows.Forms.Label()
Me.lblStep4Instructions = New System.Windows.Forms.Label()
Me.txtExcludeList = New System.Windows.Forms.TextBox()
@@ -74,15 +67,12 @@ Partial Class frmAddWizard
Me.btnCancel = New System.Windows.Forms.Button()
Me.btnNext = New System.Windows.Forms.Button()
Me.btnBack = New System.Windows.Forms.Button()
Me.optFileTypeFolder = New System.Windows.Forms.RadioButton()
Me.tabWizard.SuspendLayout()
Me.tbPage1.SuspendLayout()
Me.tbPage2.SuspendLayout()
Me.tbPage3.SuspendLayout()
Me.tbPage3a.SuspendLayout()
Me.grpFileTypes.SuspendLayout()
Me.tbPage4.SuspendLayout()
Me.grpExclude.SuspendLayout()
Me.tbPage5.SuspendLayout()
Me.SuspendLayout()
'
@@ -130,9 +120,9 @@ Partial Class frmAddWizard
'
Me.lblDrag1.AllowDrop = True
Me.lblDrag1.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblDrag1.Location = New System.Drawing.Point(14, 147)
Me.lblDrag1.Location = New System.Drawing.Point(14, 135)
Me.lblDrag1.Name = "lblDrag1"
Me.lblDrag1.Size = New System.Drawing.Size(303, 37)
Me.lblDrag1.Size = New System.Drawing.Size(303, 49)
Me.lblDrag1.TabIndex = 7
Me.lblDrag1.Text = "Drag a shortcut here to complete this step."
'
@@ -140,11 +130,9 @@ Partial Class frmAddWizard
'
Me.lblStep1Instructions.Location = New System.Drawing.Point(14, 93)
Me.lblStep1Instructions.Name = "lblStep1Instructions"
Me.lblStep1Instructions.Size = New System.Drawing.Size(303, 42)
Me.lblStep1Instructions.Size = New System.Drawing.Size(303, 30)
Me.lblStep1Instructions.TabIndex = 6
Me.lblStep1Instructions.Text = "The name of the game is used for the backup file and must conform to Windows file" &
" name standards. It will be automatically filtered for length and invalid chara" &
"cters. "
Me.lblStep1Instructions.Text = "The name will be automatically filtered for length and invalid characters. "
'
'txtName
'
@@ -166,9 +154,6 @@ Partial Class frmAddWizard
'tbPage2
'
Me.tbPage2.BackColor = System.Drawing.SystemColors.Control
Me.tbPage2.Controls.Add(Me.lbldBox)
Me.tbPage2.Controls.Add(Me.btndBoxBrowse)
Me.tbPage2.Controls.Add(Me.txtdBoxProcess)
Me.tbPage2.Controls.Add(Me.lblStep2Title)
Me.tbPage2.Controls.Add(Me.lblStep2Instructions)
Me.tbPage2.Controls.Add(Me.lblDrag2)
@@ -182,32 +167,6 @@ Partial Class frmAddWizard
Me.tbPage2.TabIndex = 1
Me.tbPage2.Text = "TabPage2"
'
'lbldBox
'
Me.lbldBox.AutoSize = True
Me.lbldBox.Location = New System.Drawing.Point(184, 18)
Me.lbldBox.Name = "lbldBox"
Me.lbldBox.Size = New System.Drawing.Size(52, 13)
Me.lbldBox.TabIndex = 14
Me.lbldBox.Text = "DOS File:"
'
'btndBoxBrowse
'
Me.btndBoxBrowse.Location = New System.Drawing.Point(322, 14)
Me.btndBoxBrowse.Name = "btndBoxBrowse"
Me.btndBoxBrowse.Size = New System.Drawing.Size(27, 20)
Me.btndBoxBrowse.TabIndex = 13
Me.btndBoxBrowse.Text = "..."
Me.btndBoxBrowse.UseVisualStyleBackColor = True
'
'txtdBoxProcess
'
Me.txtdBoxProcess.AllowDrop = True
Me.txtdBoxProcess.Location = New System.Drawing.Point(244, 14)
Me.txtdBoxProcess.Name = "txtdBoxProcess"
Me.txtdBoxProcess.Size = New System.Drawing.Size(72, 20)
Me.txtdBoxProcess.TabIndex = 12
'
'lblStep2Title
'
Me.lblStep2Title.AutoSize = True
@@ -222,16 +181,16 @@ Partial Class frmAddWizard
'
Me.lblStep2Instructions.Location = New System.Drawing.Point(14, 93)
Me.lblStep2Instructions.Name = "lblStep2Instructions"
Me.lblStep2Instructions.Size = New System.Drawing.Size(303, 41)
Me.lblStep2Instructions.Size = New System.Drawing.Size(303, 29)
Me.lblStep2Instructions.TabIndex = 10
Me.lblStep2Instructions.Text = "GBM needs to know what to look for when you run the application. Some games use " &
"launchers. Do not monitor launchers, choose the actual game exe file."
Me.lblStep2Instructions.Text = "Some games use launchers. Do not monitor launchers, be sure to choose the game'" & _
"s actual exe file."
'
'lblDrag2
'
Me.lblDrag2.AllowDrop = True
Me.lblDrag2.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblDrag2.Location = New System.Drawing.Point(14, 147)
Me.lblDrag2.Location = New System.Drawing.Point(14, 135)
Me.lblDrag2.Name = "lblDrag2"
Me.lblDrag2.Size = New System.Drawing.Size(336, 44)
Me.lblDrag2.TabIndex = 9
@@ -295,8 +254,8 @@ Partial Class frmAddWizard
Me.lblStep3Instructions.Name = "lblStep3Instructions"
Me.lblStep3Instructions.Size = New System.Drawing.Size(303, 42)
Me.lblStep3Instructions.TabIndex = 9
Me.lblStep3Instructions.Text = "If you're unsure of exactly which files to backup, make sure Save Entire Folder " &
"is checked. You can also time stamp your backup files to make incremental backu" &
Me.lblStep3Instructions.Text = "If you're unsure of exactly which files to backup, make sure Save Entire Folder " & _
"is checked. You can also time stamp your backup files to make incremental backu" & _
"ps."
'
'chkTimeStamp
@@ -347,8 +306,10 @@ Partial Class frmAddWizard
'tbPage3a
'
Me.tbPage3a.BackColor = System.Drawing.SystemColors.Control
Me.tbPage3a.Controls.Add(Me.grpFileTypes)
Me.tbPage3a.Controls.Add(Me.btnStep3aClear)
Me.tbPage3a.Controls.Add(Me.lblIncludePathTitle)
Me.tbPage3a.Controls.Add(Me.lblIncludePath)
Me.tbPage3a.Controls.Add(Me.lblFileTypes)
Me.tbPage3a.Controls.Add(Me.btnInclude)
Me.tbPage3a.Controls.Add(Me.lblStep3aTitle)
Me.tbPage3a.Controls.Add(Me.lblStep3aInstructions)
Me.tbPage3a.Controls.Add(Me.txtFileTypes)
@@ -358,58 +319,42 @@ Partial Class frmAddWizard
Me.tbPage3a.TabIndex = 3
Me.tbPage3a.Text = "TabPage4"
'
'grpFileTypes
'lblIncludePathTitle
'
Me.grpFileTypes.Controls.Add(Me.optFileTypeFolder)
Me.grpFileTypes.Controls.Add(Me.optSpecificFile)
Me.grpFileTypes.Controls.Add(Me.btnFileTypeBrowse)
Me.grpFileTypes.Controls.Add(Me.optFileType)
Me.grpFileTypes.Location = New System.Drawing.Point(17, 43)
Me.grpFileTypes.Name = "grpFileTypes"
Me.grpFileTypes.Size = New System.Drawing.Size(310, 47)
Me.grpFileTypes.TabIndex = 0
Me.grpFileTypes.TabStop = False
Me.grpFileTypes.Text = "Choose any files or folders to include in the backup"
Me.lblIncludePathTitle.AutoSize = True
Me.lblIncludePathTitle.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblIncludePathTitle.Location = New System.Drawing.Point(14, 45)
Me.lblIncludePathTitle.Name = "lblIncludePathTitle"
Me.lblIncludePathTitle.Size = New System.Drawing.Size(122, 13)
Me.lblIncludePathTitle.TabIndex = 6
Me.lblIncludePathTitle.Text = "Saved Game Folder:"
'
'optSpecificFile
'lblIncludePath
'
Me.optSpecificFile.AutoSize = True
Me.optSpecificFile.Location = New System.Drawing.Point(80, 19)
Me.optSpecificFile.Name = "optSpecificFile"
Me.optSpecificFile.Size = New System.Drawing.Size(82, 17)
Me.optSpecificFile.TabIndex = 2
Me.optSpecificFile.TabStop = True
Me.optSpecificFile.Text = "Specific File"
Me.optSpecificFile.UseVisualStyleBackColor = True
Me.lblIncludePath.AutoEllipsis = True
Me.lblIncludePath.Location = New System.Drawing.Point(14, 60)
Me.lblIncludePath.Name = "lblIncludePath"
Me.lblIncludePath.Size = New System.Drawing.Size(324, 13)
Me.lblIncludePath.TabIndex = 1
Me.lblIncludePath.Text = "Save Path"
'
'btnFileTypeBrowse
'lblFileTypes
'
Me.btnFileTypeBrowse.Location = New System.Drawing.Point(229, 16)
Me.btnFileTypeBrowse.Name = "btnFileTypeBrowse"
Me.btnFileTypeBrowse.Size = New System.Drawing.Size(75, 23)
Me.btnFileTypeBrowse.TabIndex = 3
Me.btnFileTypeBrowse.Text = "Browse..."
Me.btnFileTypeBrowse.UseVisualStyleBackColor = True
Me.lblFileTypes.AutoSize = True
Me.lblFileTypes.Location = New System.Drawing.Point(199, 91)
Me.lblFileTypes.Name = "lblFileTypes"
Me.lblFileTypes.Size = New System.Drawing.Size(89, 13)
Me.lblFileTypes.TabIndex = 3
Me.lblFileTypes.Text = "0 item(s) selected"
'
'optFileType
'btnInclude
'
Me.optFileType.AutoSize = True
Me.optFileType.Location = New System.Drawing.Point(6, 19)
Me.optFileType.Name = "optFileType"
Me.optFileType.Size = New System.Drawing.Size(68, 17)
Me.optFileType.TabIndex = 1
Me.optFileType.TabStop = True
Me.optFileType.Text = "File Type"
Me.optFileType.UseVisualStyleBackColor = True
'
'btnStep3aClear
'
Me.btnStep3aClear.Location = New System.Drawing.Point(253, 93)
Me.btnStep3aClear.Name = "btnStep3aClear"
Me.btnStep3aClear.Size = New System.Drawing.Size(75, 23)
Me.btnStep3aClear.TabIndex = 5
Me.btnStep3aClear.Text = "&Clear"
Me.btnStep3aClear.UseVisualStyleBackColor = True
Me.btnInclude.Location = New System.Drawing.Point(17, 86)
Me.btnInclude.Name = "btnInclude"
Me.btnInclude.Size = New System.Drawing.Size(176, 23)
Me.btnInclude.TabIndex = 2
Me.btnInclude.Text = "Choose items to in&clude..."
Me.btnInclude.UseVisualStyleBackColor = True
'
'lblStep3aTitle
'
@@ -418,7 +363,7 @@ Partial Class frmAddWizard
Me.lblStep3aTitle.Location = New System.Drawing.Point(13, 11)
Me.lblStep3aTitle.Name = "lblStep3aTitle"
Me.lblStep3aTitle.Size = New System.Drawing.Size(199, 20)
Me.lblStep3aTitle.TabIndex = 12
Me.lblStep3aTitle.TabIndex = 0
Me.lblStep3aTitle.Text = "Choose Files to Backup"
'
'lblStep3aInstructions
@@ -426,25 +371,27 @@ Partial Class frmAddWizard
Me.lblStep3aInstructions.Location = New System.Drawing.Point(14, 126)
Me.lblStep3aInstructions.Name = "lblStep3aInstructions"
Me.lblStep3aInstructions.Size = New System.Drawing.Size(303, 56)
Me.lblStep3aInstructions.TabIndex = 11
Me.lblStep3aInstructions.Text = "Choose any file types, specific files or folders you wish to include in the back" &
"up. You may choose multiple items to include. If you're unsure, go back a step" &
" and choose to save the entire folder. "
Me.lblStep3aInstructions.TabIndex = 5
Me.lblStep3aInstructions.Text = "Choose any file types, specific files or folders you wish to include in the back" & _
"up. If you're unsure, go back a step and choose to save the entire folder. "
'
'txtFileTypes
'
Me.txtFileTypes.Location = New System.Drawing.Point(18, 95)
Me.txtFileTypes.Location = New System.Drawing.Point(218, 14)
Me.txtFileTypes.Name = "txtFileTypes"
Me.txtFileTypes.ReadOnly = True
Me.txtFileTypes.Size = New System.Drawing.Size(229, 20)
Me.txtFileTypes.Size = New System.Drawing.Size(131, 20)
Me.txtFileTypes.TabIndex = 4
Me.txtFileTypes.TabStop = False
Me.txtFileTypes.Visible = False
'
'tbPage4
'
Me.tbPage4.BackColor = System.Drawing.SystemColors.Control
Me.tbPage4.Controls.Add(Me.grpExclude)
Me.tbPage4.Controls.Add(Me.btnStep4Clear)
Me.tbPage4.Controls.Add(Me.lblExcludePathTitle)
Me.tbPage4.Controls.Add(Me.lblExcludePath)
Me.tbPage4.Controls.Add(Me.lblExclude)
Me.tbPage4.Controls.Add(Me.btnExclude)
Me.tbPage4.Controls.Add(Me.lblStep4Title)
Me.tbPage4.Controls.Add(Me.lblStep4Instructions)
Me.tbPage4.Controls.Add(Me.txtExcludeList)
@@ -454,69 +401,42 @@ Partial Class frmAddWizard
Me.tbPage4.TabIndex = 4
Me.tbPage4.Text = "TabPage5"
'
'grpExclude
'lblExcludePathTitle
'
Me.grpExclude.Controls.Add(Me.optExcludeSpecificFile)
Me.grpExclude.Controls.Add(Me.btnExcludeBrowse)
Me.grpExclude.Controls.Add(Me.optExcludeFileType)
Me.grpExclude.Controls.Add(Me.optExcludeFolder)
Me.grpExclude.Location = New System.Drawing.Point(17, 43)
Me.grpExclude.Name = "grpExclude"
Me.grpExclude.Size = New System.Drawing.Size(310, 47)
Me.grpExclude.TabIndex = 0
Me.grpExclude.TabStop = False
Me.grpExclude.Text = "Choose any files or folders to exclude from the backup:"
Me.lblExcludePathTitle.AutoSize = True
Me.lblExcludePathTitle.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblExcludePathTitle.Location = New System.Drawing.Point(14, 45)
Me.lblExcludePathTitle.Name = "lblExcludePathTitle"
Me.lblExcludePathTitle.Size = New System.Drawing.Size(122, 13)
Me.lblExcludePathTitle.TabIndex = 7
Me.lblExcludePathTitle.Text = "Saved Game Folder:"
'
'optExcludeSpecificFile
'lblExcludePath
'
Me.optExcludeSpecificFile.AutoSize = True
Me.optExcludeSpecificFile.Location = New System.Drawing.Point(80, 19)
Me.optExcludeSpecificFile.Name = "optExcludeSpecificFile"
Me.optExcludeSpecificFile.Size = New System.Drawing.Size(82, 17)
Me.optExcludeSpecificFile.TabIndex = 2
Me.optExcludeSpecificFile.TabStop = True
Me.optExcludeSpecificFile.Text = "Specific File"
Me.optExcludeSpecificFile.UseVisualStyleBackColor = True
Me.lblExcludePath.AutoEllipsis = True
Me.lblExcludePath.Location = New System.Drawing.Point(14, 60)
Me.lblExcludePath.Name = "lblExcludePath"
Me.lblExcludePath.Size = New System.Drawing.Size(334, 13)
Me.lblExcludePath.TabIndex = 1
Me.lblExcludePath.Text = "Save Path"
'
'btnExcludeBrowse
'lblExclude
'
Me.btnExcludeBrowse.Location = New System.Drawing.Point(229, 16)
Me.btnExcludeBrowse.Name = "btnExcludeBrowse"
Me.btnExcludeBrowse.Size = New System.Drawing.Size(75, 23)
Me.btnExcludeBrowse.TabIndex = 4
Me.btnExcludeBrowse.Text = "&Browse..."
Me.btnExcludeBrowse.UseVisualStyleBackColor = True
Me.lblExclude.AutoSize = True
Me.lblExclude.Location = New System.Drawing.Point(199, 91)
Me.lblExclude.Name = "lblExclude"
Me.lblExclude.Size = New System.Drawing.Size(89, 13)
Me.lblExclude.TabIndex = 3
Me.lblExclude.Text = "0 item(s) selected"
'
'optExcludeFileType
'btnExclude
'
Me.optExcludeFileType.AutoSize = True
Me.optExcludeFileType.Location = New System.Drawing.Point(6, 19)
Me.optExcludeFileType.Name = "optExcludeFileType"
Me.optExcludeFileType.Size = New System.Drawing.Size(68, 17)
Me.optExcludeFileType.TabIndex = 1
Me.optExcludeFileType.TabStop = True
Me.optExcludeFileType.Text = "File Type"
Me.optExcludeFileType.UseVisualStyleBackColor = True
'
'optExcludeFolder
'
Me.optExcludeFolder.AutoSize = True
Me.optExcludeFolder.Location = New System.Drawing.Point(168, 19)
Me.optExcludeFolder.Name = "optExcludeFolder"
Me.optExcludeFolder.Size = New System.Drawing.Size(54, 17)
Me.optExcludeFolder.TabIndex = 3
Me.optExcludeFolder.TabStop = True
Me.optExcludeFolder.Text = "Folder"
Me.optExcludeFolder.UseVisualStyleBackColor = True
'
'btnStep4Clear
'
Me.btnStep4Clear.Location = New System.Drawing.Point(253, 93)
Me.btnStep4Clear.Name = "btnStep4Clear"
Me.btnStep4Clear.Size = New System.Drawing.Size(75, 23)
Me.btnStep4Clear.TabIndex = 6
Me.btnStep4Clear.Text = "&Clear"
Me.btnStep4Clear.UseVisualStyleBackColor = True
Me.btnExclude.Location = New System.Drawing.Point(17, 86)
Me.btnExclude.Name = "btnExclude"
Me.btnExclude.Size = New System.Drawing.Size(176, 23)
Me.btnExclude.TabIndex = 2
Me.btnExclude.Text = "Choose items to e&xclude..."
Me.btnExclude.UseVisualStyleBackColor = True
'
'lblStep4Title
'
@@ -525,7 +445,7 @@ Partial Class frmAddWizard
Me.lblStep4Title.Location = New System.Drawing.Point(14, 11)
Me.lblStep4Title.Name = "lblStep4Title"
Me.lblStep4Title.Size = New System.Drawing.Size(201, 20)
Me.lblStep4Title.TabIndex = 16
Me.lblStep4Title.TabIndex = 0
Me.lblStep4Title.Text = "Exclude Files or Folders"
'
'lblStep4Instructions
@@ -533,17 +453,19 @@ Partial Class frmAddWizard
Me.lblStep4Instructions.Location = New System.Drawing.Point(14, 126)
Me.lblStep4Instructions.Name = "lblStep4Instructions"
Me.lblStep4Instructions.Size = New System.Drawing.Size(303, 59)
Me.lblStep4Instructions.TabIndex = 12
Me.lblStep4Instructions.Text = resources.GetString("lblStep4Instructions.Text")
Me.lblStep4Instructions.TabIndex = 5
Me.lblStep4Instructions.Text = "Choose any file types, specific files or folders you wish to exclude from the ba" & _
"ckup. You may choose multiple items to exclude. This step can be skipped."
'
'txtExcludeList
'
Me.txtExcludeList.Location = New System.Drawing.Point(18, 95)
Me.txtExcludeList.Location = New System.Drawing.Point(221, 13)
Me.txtExcludeList.Name = "txtExcludeList"
Me.txtExcludeList.ReadOnly = True
Me.txtExcludeList.Size = New System.Drawing.Size(229, 20)
Me.txtExcludeList.TabIndex = 5
Me.txtExcludeList.Size = New System.Drawing.Size(128, 20)
Me.txtExcludeList.TabIndex = 4
Me.txtExcludeList.TabStop = False
Me.txtExcludeList.Visible = False
'
'tbPage5
'
@@ -581,6 +503,7 @@ Partial Class frmAddWizard
Me.lstSummary.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.Nonclickable
Me.lstSummary.Location = New System.Drawing.Point(14, 65)
Me.lstSummary.Name = "lstSummary"
Me.lstSummary.ShowItemToolTips = True
Me.lstSummary.Size = New System.Drawing.Size(335, 126)
Me.lstSummary.TabIndex = 1
Me.lstSummary.UseCompatibleStateImageBehavior = False
@@ -613,17 +536,6 @@ Partial Class frmAddWizard
Me.btnBack.Text = "&Back"
Me.btnBack.UseVisualStyleBackColor = True
'
'optFileTypeFolder
'
Me.optFileTypeFolder.AutoSize = True
Me.optFileTypeFolder.Location = New System.Drawing.Point(168, 19)
Me.optFileTypeFolder.Name = "optFileTypeFolder"
Me.optFileTypeFolder.Size = New System.Drawing.Size(54, 17)
Me.optFileTypeFolder.TabIndex = 4
Me.optFileTypeFolder.TabStop = True
Me.optFileTypeFolder.Text = "Folder"
Me.optFileTypeFolder.UseVisualStyleBackColor = True
'
'frmAddWizard
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
@@ -649,12 +561,8 @@ Partial Class frmAddWizard
Me.tbPage3.PerformLayout()
Me.tbPage3a.ResumeLayout(False)
Me.tbPage3a.PerformLayout()
Me.grpFileTypes.ResumeLayout(False)
Me.grpFileTypes.PerformLayout()
Me.tbPage4.ResumeLayout(False)
Me.tbPage4.PerformLayout()
Me.grpExclude.ResumeLayout(False)
Me.grpExclude.PerformLayout()
Me.tbPage5.ResumeLayout(False)
Me.tbPage5.PerformLayout()
Me.ResumeLayout(False)
@@ -684,17 +592,10 @@ Partial Class frmAddWizard
Friend WithEvents btnSaveBrowse As System.Windows.Forms.Button
Friend WithEvents txtSavePath As System.Windows.Forms.TextBox
Friend WithEvents lblStep3Intro As System.Windows.Forms.Label
Friend WithEvents btnFileTypeBrowse As System.Windows.Forms.Button
Friend WithEvents txtFileTypes As System.Windows.Forms.TextBox
Friend WithEvents btnExcludeBrowse As System.Windows.Forms.Button
Friend WithEvents txtExcludeList As System.Windows.Forms.TextBox
Friend WithEvents optSpecificFile As System.Windows.Forms.RadioButton
Friend WithEvents optFileType As System.Windows.Forms.RadioButton
Friend WithEvents lblStep3aInstructions As System.Windows.Forms.Label
Friend WithEvents optExcludeFolder As System.Windows.Forms.RadioButton
Friend WithEvents optExcludeFileType As System.Windows.Forms.RadioButton
Friend WithEvents lblStep4Instructions As System.Windows.Forms.Label
Friend WithEvents optExcludeSpecificFile As System.Windows.Forms.RadioButton
Friend WithEvents lblStep3Instructions As System.Windows.Forms.Label
Friend WithEvents lstSummary As System.Windows.Forms.ListView
Friend WithEvents lblStep1Title As System.Windows.Forms.Label
@@ -704,12 +605,12 @@ Partial Class frmAddWizard
Friend WithEvents lblStep3aTitle As System.Windows.Forms.Label
Friend WithEvents lblStep5Intro As System.Windows.Forms.Label
Friend WithEvents lblStep5Title As System.Windows.Forms.Label
Friend WithEvents btnStep3aClear As System.Windows.Forms.Button
Friend WithEvents btnStep4Clear As System.Windows.Forms.Button
Friend WithEvents grpExclude As System.Windows.Forms.GroupBox
Friend WithEvents grpFileTypes As System.Windows.Forms.GroupBox
Friend WithEvents lbldBox As System.Windows.Forms.Label
Friend WithEvents btndBoxBrowse As System.Windows.Forms.Button
Friend WithEvents txtdBoxProcess As System.Windows.Forms.TextBox
Friend WithEvents optFileTypeFolder As RadioButton
Friend WithEvents lblFileTypes As Label
Friend WithEvents btnInclude As Button
Friend WithEvents lblExclude As Label
Friend WithEvents btnExclude As Button
Friend WithEvents lblIncludePath As Label
Friend WithEvents lblExcludePath As Label
Friend WithEvents lblIncludePathTitle As Label
Friend WithEvents lblExcludePathTitle As Label
End Class
-3
View File
@@ -117,7 +117,4 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="lblStep4Instructions.Text" xml:space="preserve">
<value>Choose any file types, specific files or folders you wish to exclude from the backup. You may choose multiple items to exclude. A more advanced exclude list can be created manually via the Game Manager. This step can be skipped.</value>
</data>
</root>
+102 -237
View File
@@ -1,11 +1,11 @@
Imports System.IO
Imports GBM.My.Resources
Imports System.IO
Public Class frmAddWizard
Private oGameData As Hashtable
Private oGameToSave As clsGame
Private bDisableAdminWarning As Boolean = False
Private bIsDOSBoxGame As Boolean
Property GameData As Hashtable
Get
@@ -27,20 +27,52 @@ Public Class frmAddWizard
Private eCurrentStep As eSteps = eSteps.Step1
Private Sub FormInit()
btndBoxBrowse.Visible = False
txtdBoxProcess.Visible = False
lbldBox.Visible = False
Private Sub SetForm()
'Set Form Name
Me.Text = frmAddWizard_FormName
'Set Form Text
btnCancel.Text = frmAddWizard_btnCancel
btnNext.Text = frmAddWizard_btnNext
btnBack.Text = frmAddWizard_btnBack
lblStep1Title.Text = frmAddWizard_lblStep1Title
lblDrag1.Text = frmAddWizard_lblDrag1
lblStep1Instructions.Text = frmAddWizard_lblStep1Instructions
lblStep1Intro.Text = frmAddWizard_lblStep1Intro
lblStep2Title.Text = frmAddWizard_lblStep2Title
lblStep2Instructions.Text = frmAddWizard_lblStep2Instructions
lblDrag2.Text = frmAddWizard_lblDrag2
btnProcessBrowse.Text = frmAddWizard_btnProcessBrowse
lblStep2Intro.Text = frmAddWizard_lblStep2Intro
lblStep3Title.Text = frmAddWizard_lblStep3Title
lblStep3Instructions.Text = frmAddWizard_lblStep3Instructions
chkTimeStamp.Text = frmAddWizard_chkTimeStamp
chkFolderSave.Text = frmAddWizard_chkFolderSave
btnSaveBrowse.Text = frmAddWizard_btnSaveBrowse
lblStep3Intro.Text = frmAddWizard_lblStep3Intro
lblIncludePathTitle.Text = frmAddWizard_lblIncludePathTitle
lblIncludePath.Text = frmAddWizard_lblIncludePath
lblFileTypes.Text = frmAddWizard_ItemsSelectedNone
btnInclude.Text = frmAddWizard_btnInclude
lblStep3aTitle.Text = frmAddWizard_lblStep3aTitle
lblStep3aInstructions.Text = frmAddWizard_lblStep3aInstructions
lblExcludePathTitle.Text = frmAddWizard_lblExcludePathTitle
lblExcludePath.Text = frmAddWizard_lblExcludePath
lblExclude.Text = frmAddWizard_ItemsSelectedNone
btnExclude.Text = frmAddWizard_btnExclude
lblStep4Title.Text = frmAddWizard_lblStep4Title
lblStep4Instructions.Text = frmAddWizard_lblStep4Instructions
lblStep5Intro.Text = frmAddWizard_lblStep5Intro
lblStep5Title.Text = frmAddWizard_lblStep5Title
chkFolderSave.Checked = True
chkTimeStamp.Checked = False
optFileType.Checked = True
optExcludeFileType.Checked = True
StepHandler()
End Sub
Private Function StringEmptyText(ByVal sString As String) As String
If sString = String.Empty Then
Return "None"
Return frmAddWizard_None
Else
Return sString
End If
@@ -53,10 +85,6 @@ Public Class frmAddWizard
Dim sProcessPath As String = Path.GetDirectoryName(sProcessFullPath)
Dim sProcess As String = Path.GetFileNameWithoutExtension(sProcessFullPath)
Dim sProcessSummaryText As String = Path.GetFileName(sProcessFullPath) & " (" & sProcessPath & ")"
Dim sdBoxProcessFullPath As String = String.Empty
Dim sdBoxProcessPath As String = String.Empty
Dim sdBoxProcess As String = String.Empty
Dim sdBoxProcessSummaryText As String = String.Empty
Dim sSavePath As String = txtSavePath.Text
Dim bIsAbsolute As Boolean = mgrPath.IsAbsolute(sSavePath)
Dim bFolderBackup As Boolean = chkFolderSave.Checked
@@ -72,14 +100,6 @@ Public Class frmAddWizard
sSavePath = mgrPath.DetermineRelativePath(sProcessPath, sSavePath)
End If
If bIsDOSBoxGame Then
sdBoxProcessFullPath = txtdBoxProcess.Text
sdBoxProcessPath = Path.GetDirectoryName(sdBoxProcessFullPath)
sdBoxProcess = Path.GetFileNameWithoutExtension(sdBoxProcessFullPath)
sdBoxProcessSummaryText = Path.GetFileName(sdBoxProcessFullPath) & " (" & sdBoxProcessPath & ")"
sProcess = sProcess.ToLower & ":" & sdBoxProcess
End If
'Build Summary Listview
lstSummary.Clear()
lstSummary.Columns.Add("Item")
@@ -87,8 +107,8 @@ Public Class frmAddWizard
lstSummary.Columns(0).Width = 95
lstSummary.Columns(1).Width = 210
sItems = {"Name", "Process", "DOS Process", "Absolute Path", "Save Path", "Folder Backup", "Specific Files", "Time Stamp", "Exclude List"}
sValues = {sName, sProcessSummaryText, StringEmptyText(sdBoxProcessSummaryText), mgrCommon.BooleanYesNo(bIsAbsolute), sSavePath, mgrCommon.BooleanYesNo(bFolderBackup), StringEmptyText(sFileType), mgrCommon.BooleanYesNo(bTimeStamp), StringEmptyText(sExcludeList)}
sItems = {frmAddWizard_Summary_Name, frmAddWizard_Summary_Process, frmAddWizard_Summary_AbsolutePath, frmAddWizard_Summary_SavePath, frmAddWizard_Summary_FolderSave, frmAddWizard_Summary_Timestamp, frmAddWizard_Summary_Include, frmAddWizard_Summary_Exclude}
sValues = {sName, sProcessSummaryText, mgrCommon.BooleanYesNo(bIsAbsolute), sSavePath, mgrCommon.BooleanYesNo(bFolderBackup), mgrCommon.BooleanYesNo(bTimeStamp), StringEmptyText(sFileType), StringEmptyText(sExcludeList)}
For i = 0 To sItems.Length - 1
sItem = {sItems(i), sValues(i)}
@@ -130,11 +150,11 @@ Public Class frmAddWizard
Case eSteps.Step4
btnBack.Enabled = True
btnNext.Enabled = True
btnNext.Text = "&Next"
btnNext.Text = frmAddWizard_btnNext
tabWizard.SelectTab(4)
Case eSteps.Step5
btnBack.Enabled = True
btnNext.Text = "&Finish"
btnNext.Text = frmAddWizard_btnNext_Finish
tabWizard.SelectTab(5)
End Select
End Sub
@@ -144,84 +164,34 @@ Public Class frmAddWizard
txtName.Text = mgrPath.ValidateForFileSystem(txtName.Text)
Return True
Else
sErrorMessage = "You must enter a valid game name."
sErrorMessage = frmAddWizard_ErrorValidName
txtName.Focus()
Return False
End If
Return True
End Function
Private Function CheckforDOSBox(ByVal strpath As String) As Boolean
If strpath.ToLower.Contains("dosbox.exe") Then
bIsDOSBoxGame = True
lbldBox.Visible = True
txtdBoxProcess.Visible = True
btndBoxBrowse.Visible = True
If txtdBoxProcess.Text = String.Empty Then
If MsgBox("You have selected a DOSBox executable, to monitor DOS programs you need to also select the actual DOS executable file." & vbCrLf & vbCrLf & "Would you like to do this now?", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
DOSProcessBrowse()
End If
End If
Return True
Else
bIsDOSBoxGame = False
lbldBox.Visible = False
txtdBoxProcess.Text = String.Empty
txtdBoxProcess.Visible = False
btndBoxBrowse.Visible = False
Return False
End If
End Function
Private Function ValidateDOSProcessPath(ByVal strPath As String, ByRef sErrorMessage As String) As Boolean
If strPath = String.Empty Then
sErrorMessage = "You must select the DOS game's executable file (.exe or .com) to continue."
txtProcessPath.Focus()
Return False
End If
If Path.GetExtension(strPath.ToLower) <> ".exe" And Path.GetExtension(strPath.ToLower) <> ".com" Then
sErrorMessage = "The DOS file you selected is not an executable file. (.exe or .com)"
txtProcessPath.Focus()
Return False
End If
If Not Path.IsPathRooted(strPath) Then
sErrorMessage = "The path to the DOS executable must be a full path."
txtProcessPath.Focus()
Return False
End If
If Not File.Exists(strPath) Then
sErrorMessage = "The selected DOS executable file does not exist."
txtProcessPath.Focus()
Return False
End If
Return True
End Function
Private Function ValidateProcessPath(ByVal strPath As String, ByRef sErrorMessage As String) As Boolean
If strPath = String.Empty Then
sErrorMessage = "You must select the game's executable file (.exe) to continue."
sErrorMessage = frmAddWizard_ErrorValidProcess
txtProcessPath.Focus()
Return False
End If
If Path.GetExtension(strPath.ToLower) <> ".exe" Then
sErrorMessage = "The file you selected is not an executable file."
sErrorMessage = frmAddWizard_ErrorNotAProcess
txtProcessPath.Focus()
Return False
End If
If Not Path.IsPathRooted(strPath) Then
sErrorMessage = "The path to the executable must be a full path."
sErrorMessage = frmAddWizard_ErrorBadProcessPath
txtProcessPath.Focus()
Return False
End If
If Not File.Exists(strPath) Then
sErrorMessage = "The selected executable file does not exist."
sErrorMessage = frmAddWizard_ErrorProcessNotExist
txtProcessPath.Focus()
Return False
End If
@@ -231,19 +201,19 @@ Public Class frmAddWizard
Private Function ValidateSavePath(ByVal strPath As String, ByRef sErrorMessage As String) As Boolean
If strPath = String.Empty Then
sErrorMessage = "You must select the game's save file path to continue."
sErrorMessage = frmAddWizard_ErrorValidSavePath
txtSavePath.Focus()
Return False
End If
If Not Directory.Exists(strPath) Then
sErrorMessage = "The folder you selected does not exist or is not a valid folder."
sErrorMessage = frmAddWizard_ErrorSavePathNotExist
txtSavePath.Focus()
Return False
End If
If Not Path.IsPathRooted(strPath) Then
sErrorMessage = "The selected path must be a full path."
sErrorMessage = frmAddWizard_ErrorBadSavePath
txtSavePath.Focus()
Return False
End If
@@ -253,7 +223,7 @@ Public Class frmAddWizard
Private Function ValidateSaveType(ByVal strSaveType As String, ByRef sErrorMessage As String)
If strSaveType = String.Empty Then
sErrorMessage = "You must choose a file type or specific file to backup."
sErrorMessage = frmAddWizard_ErrorValidSaveType
txtFileTypes.Focus()
Return False
End If
@@ -262,22 +232,20 @@ Public Class frmAddWizard
End Function
Private Sub DoSave()
Dim oGames As New List(Of clsGame)
Dim hshDupeCheck As New Hashtable
Dim sExistingGame As String
Dim sNewGame As String = oGameToSave.Name & ":" & oGameToSave.ProcessName
Dim sNewGame As String = oGameToSave.ProcessName & ":" & oGameToSave.Name
For Each o As clsGame In GameData.Values
oGames.Add(o)
sExistingGame = o.Name & ":" & o.ProcessName
hshDupeCheck.Add(sExistingGame, String.Empty)
hshDupeCheck.Add(o.CompoundKey, String.Empty)
Next
If hshDupeCheck.Contains(sNewGame) Then
MsgBox("The monitor list already contains a game with this exact name and process.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmAddWizard_ErrorGameDupe, MsgBoxStyle.Exclamation)
Else
mgrMonitorList.DoListAdd(oGameToSave)
MsgBox(oGameToSave.Name & " has been added to the monitor list.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
If mgrCommon.ShowMessage(frmAddWizard_ConfirmSaveTags, New String() {oGameToSave.Name, oGameToSave.Name}, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
OpenTags(oGameToSave)
End If
Me.Close()
End If
End Sub
@@ -324,21 +292,15 @@ Public Class frmAddWizard
Case eSteps.Step2
If ValidateProcessPath(txtProcessPath.Text, sErrorMessage) Then
If CheckforDOSBox(txtProcessPath.Text) Then
If ValidateDOSProcessPath(txtdBoxProcess.Text, sErrorMessage) Then
eCurrentStep = eSteps.Step3
Else
bError = True
End If
Else
eCurrentStep = eSteps.Step3
End If
eCurrentStep = eSteps.Step3
Else
bError = True
End If
Case eSteps.Step3
If ValidateSavePath(txtSavePath.Text, sErrorMessage) Then
lblIncludePath.Text = txtSavePath.Text
lblExcludePath.Text = txtSavePath.Text
If chkFolderSave.Checked = False Then
eCurrentStep = eSteps.Step3a
Else
@@ -361,7 +323,7 @@ Public Class frmAddWizard
DoSave()
End Select
If bError Then MsgBox(sErrorMessage, MsgBoxStyle.Exclamation, "Game Backup Monitor")
If bError Then mgrCommon.ShowMessage(sErrorMessage, MsgBoxStyle.Exclamation)
StepHandler()
End Sub
@@ -405,35 +367,17 @@ Public Class frmAddWizard
ReadShortcut(sTemp)
File.Delete(sTemp)
Catch e2 As Exception
MsgBox("An error occured working with the shortcut file." & vbCrLf & vbCrLf & e2.Message, MsgBoxStyle.Critical, "Game Backup Monitor")
mgrCommon.ShowMessage(frmAddWizard_ErrorWithShortcut, e2.Message, MsgBoxStyle.Critical)
End Try
Else
MsgBox("An error occured reading the shortcut file." & vbCrLf & vbCrLf & e1.Message, MsgBoxStyle.Critical, "Game Backup Monitor")
mgrCommon.ShowMessage(frmAddWizard_ErrorWithShortcut, e1.Message, MsgBoxStyle.Critical)
End If
End Try
Else
MsgBox("This file is not a shorcut.")
mgrCommon.ShowMessage(frmAddWizard_ErrorNotAShortcut, MsgBoxStyle.Information)
End If
End Sub
Private Sub DOSProcessBrowse()
Dim sDefaultFolder As String = Environment.GetFolderPath(Environment.SpecialFolder.Desktop)
Dim sCurrentPath As String
Dim sNewPath As String
If txtProcessPath.Text <> String.Empty Then
sCurrentPath = Path.GetDirectoryName(txtProcessPath.Text)
If Directory.Exists(sCurrentPath) Then
sDefaultFolder = sCurrentPath
End If
End If
sNewPath = mgrCommon.OpenFileBrowser("Choose DOS executable file that starts the game", "*", _
"", sDefaultFolder, False)
If sNewPath <> String.Empty Then txtdBoxProcess.Text = sNewPath
End Sub
Private Sub ProcessBrowse()
Dim sDefaultFolder As String = Environment.GetFolderPath(Environment.SpecialFolder.Desktop)
Dim sCurrentPath As String
@@ -446,8 +390,8 @@ Public Class frmAddWizard
End If
End If
sNewPath = mgrCommon.OpenFileBrowser("Choose exe file that starts the game", "exe", _
"Executable", sDefaultFolder, False)
sNewPath = mgrCommon.OpenFileBrowser(frmAddWizard_ChooseProcess, "exe",
frmAddWizard_Executable, sDefaultFolder, False)
If sNewPath <> String.Empty Then txtProcessPath.Text = sNewPath
End Sub
@@ -463,117 +407,41 @@ Public Class frmAddWizard
End If
End If
sNewPath = mgrCommon.OpenFolderBrowser("Choose the game save folder:", sDefaultFolder, False)
sNewPath = mgrCommon.OpenFolderBrowser(frmAddWizard_ChooseSavePath, sDefaultFolder, False)
If sNewPath <> String.Empty Then txtSavePath.Text = sNewPath
End Sub
Private Sub SaveTypeBrowse()
Dim sDefaultFolder As String = txtSavePath.Text
Dim sCurrentSaveType As String = txtFileTypes.Text
Dim sSaveType As String
Dim sTitle As String = String.Empty
Dim sSaveTypeList As String()
Private Sub UpdateBuilderLabel(ByVal sBuilderString As String, ByVal lbl As Label)
Dim iCount As Integer = sBuilderString.Split(":").Length
If optFileType.Checked Then
sTitle = "Choose the type of file to backup"
ElseIf optSpecificFile.Checked Then
sTitle = "Choose a specific file to backup"
If sBuilderString <> String.Empty And iCount > 0 Then
lbl.Text = mgrCommon.FormatString(frmAddWizard_ItemsSelectedMulti, iCount)
Else
sTitle = "Choose a specific folder to backup"
lbl.Text = frmAddWizard_ItemsSelectedNone
End If
If optFileType.Checked Or optSpecificFile.Checked Then
sSaveType = mgrCommon.OpenFileBrowser(sTitle, "*", "All", sDefaultFolder, False)
If sSaveType <> String.Empty Then
sSaveTypeList = sSaveType.Split("|")
For Each s As String In sSaveTypeList
If optFileType.Checked Then
sSaveType = "*" & Path.GetExtension(s) & ":"
Else
sSaveType = Path.GetFileName(s) & ":"
End If
sSaveType = sSaveType.TrimEnd(":")
If sCurrentSaveType <> String.Empty Then
sCurrentSaveType &= ":" & sSaveType
Else
sCurrentSaveType = sSaveType
End If
Next
End If
Else
sSaveType = mgrCommon.OpenFolderBrowser(sTitle, sDefaultFolder, False)
If sSaveType <> String.Empty Then
Dim sPath As String() = sSaveType.Split("\")
If sCurrentSaveType <> String.Empty Then
sCurrentSaveType &= ":" & sPath(sPath.Length - 1)
Else
sCurrentSaveType = sPath(sPath.Length - 1)
End If
End If
End If
txtFileTypes.Text = sCurrentSaveType
End Sub
Private Sub ExcludeBrowse()
Dim sDefaultFolder As String = txtSavePath.Text
Dim sCurrentExclude As String = txtExcludeList.Text
Dim sExclude As String
Dim sExcludeList As String()
Dim sTitle As String = String.Empty
Private Sub OpenBuilder(ByVal sFormText As String, ByRef txtBox As TextBox)
Dim frm As New frmIncludeExclude
frm.FormName = sFormText
frm.BuilderString = txtBox.Text
frm.RootFolder = txtSavePath.Text
If optExcludeFileType.Checked Then
sTitle = "Choose the type of file(s) to exclude"
ElseIf optExcludeSpecificFile.Checked Then
sTitle = "Choose any file(s) to exclude"
Else
sTitle = "Choose a folder to exclude"
End If
If optExcludeFileType.Checked Or optExcludeSpecificFile.Checked Then
sExclude = mgrCommon.OpenFileBrowser(sTitle, "*", "All", sDefaultFolder, True)
If sExclude <> String.Empty Then
sExcludeList = sExclude.Split("|")
For Each s As String In sExcludeList
If optExcludeFileType.Checked Then
sExclude = "*" & Path.GetExtension(s) & ":"
Else
sExclude = Path.GetFileName(s) & ":"
End If
sExclude = sExclude.TrimEnd(":")
If sCurrentExclude <> String.Empty Then
sCurrentExclude &= ":" & sExclude
Else
sCurrentExclude = sExclude
End If
Next
End If
Else
sExclude = mgrCommon.OpenFolderBrowser(sTitle, sDefaultFolder, False)
If sExclude <> String.Empty Then
Dim sPath As String() = sExclude.Split("\")
If sCurrentExclude <> String.Empty Then
sCurrentExclude &= ":" & sPath(sPath.Length - 1)
Else
sCurrentExclude = sPath(sPath.Length - 1)
End If
End If
End If
If sCurrentExclude <> String.Empty Then
txtExcludeList.Text = sCurrentExclude
End If
frm.ShowDialog()
txtBox.Text = frm.BuilderString
End Sub
Private Sub OpenTags(ByVal oGame As clsGame)
Dim frm As New frmGameTags
Dim sMonitorIDs As New List(Of String)
sMonitorIDs.Add(oGame.ID)
frm.IDList = sMonitorIDs
frm.GameName = oGame.Name
frm.ShowDialog()
End Sub
Private Sub btnBack_Click(sender As Object, e As EventArgs) Handles btnBack.Click
ValidateBack()
@@ -588,7 +456,7 @@ Public Class frmAddWizard
End Sub
Private Sub frmAddWizard_Load(sender As Object, e As EventArgs) Handles MyBase.Load
FormInit()
SetForm()
End Sub
Private Sub DropTarget_DragEnter(sender As Object, e As DragEventArgs) Handles lblDrag1.DragEnter, lblDrag2.DragEnter, txtName.DragEnter, txtProcessPath.DragEnter
@@ -604,10 +472,6 @@ Public Class frmAddWizard
Next
End Sub
Private Sub btndBoxBrowse_Click(sender As Object, e As EventArgs) Handles btndBoxBrowse.Click
DOSProcessBrowse()
End Sub
Private Sub btnProcessBrowse_Click(sender As Object, e As EventArgs) Handles btnProcessBrowse.Click
ProcessBrowse()
End Sub
@@ -616,19 +480,11 @@ Public Class frmAddWizard
SavePathBrowse()
End Sub
Private Sub btnFileTypeBrowse_Click(sender As Object, e As EventArgs) Handles btnFileTypeBrowse.Click
SaveTypeBrowse()
End Sub
Private Sub btnExcludeBrowse_Click(sender As Object, e As EventArgs) Handles btnExcludeBrowse.Click
ExcludeBrowse()
End Sub
Private Sub btnStep4Clear_Click(sender As Object, e As EventArgs) Handles btnStep4Clear.Click
Private Sub btnStep4Clear_Click(sender As Object, e As EventArgs)
txtExcludeList.Clear()
End Sub
Private Sub btnStep3aClear_Click(sender As Object, e As EventArgs) Handles btnStep3aClear.Click
Private Sub btnStep3aClear_Click(sender As Object, e As EventArgs)
txtFileTypes.Clear()
End Sub
@@ -636,4 +492,13 @@ Public Class frmAddWizard
txtFileTypes.Clear()
End Sub
Private Sub btnInclude_Click(sender As Object, e As EventArgs) Handles btnInclude.Click
OpenBuilder(frmAddWizard_Include, txtFileTypes)
UpdateBuilderLabel(txtFileTypes.Text, lblFileTypes)
End Sub
Private Sub btnExclude_Click(sender As Object, e As EventArgs) Handles btnExclude.Click
OpenBuilder(frmAddWizard_Exclude, txtExcludeList)
UpdateBuilderLabel(txtExcludeList.Text, lblExclude)
End Sub
End Class
+13 -4
View File
@@ -1,4 +1,6 @@
Public Class frmAdvancedImport
Imports GBM.My.Resources
Public Class frmAdvancedImport
Private hshImportData As Hashtable
Private bSelectAll As Boolean = False
@@ -30,14 +32,21 @@
For Each de As DictionaryEntry In ImportData
oApp = DirectCast(de.Value, clsGame)
oData = New KeyValuePair(Of String, String)(oApp.ProcessName, oApp.Name & " (" & oApp.TrueProcess & ")")
oData = New KeyValuePair(Of String, String)(oApp.CompoundKey, oApp.Name & " (" & oApp.TrueProcess & ")")
lstGames.Items.Add(oData)
Next
End Sub
Private Sub SetForm()
'Set Form Name
Me.Text = frmAdvancedImport_FormName
'Set Form Text
btnCancel.Text = frmAdvancedImport_btnCancel
btnImport.Text = frmAdvancedImport_btnImport
chkSelectAll.Checked = True
lblGames.Text = ImportData.Count & " new configurations available."
lblGames.Text = mgrCommon.FormatString(frmAdvancedImport_NewConfigs, ImportData.Count)
End Sub
Private Sub BuildList()
@@ -52,7 +61,7 @@
End Sub
Private Sub UpdateSelected()
lblSelected.Text = lstGames.CheckedItems.Count & " Selected"
lblSelected.Text = mgrCommon.FormatString(frmAdvancedImport_Selected, lstGames.CheckedItems.Count)
End Sub
Private Sub frmAdvancedImport_Load(sender As Object, e As EventArgs) Handles MyBase.Load
+15 -2
View File
@@ -25,6 +25,7 @@ Partial Class frmChooseGame
Me.lblChoose = New System.Windows.Forms.Label()
Me.btnChoose = New System.Windows.Forms.Button()
Me.lstGameBox = New System.Windows.Forms.ListBox()
Me.btnCancel = New System.Windows.Forms.Button()
Me.SuspendLayout()
'
'lblChoose
@@ -38,9 +39,9 @@ Partial Class frmChooseGame
'
'btnChoose
'
Me.btnChoose.Location = New System.Drawing.Point(124, 135)
Me.btnChoose.Location = New System.Drawing.Point(72, 135)
Me.btnChoose.Name = "btnChoose"
Me.btnChoose.Size = New System.Drawing.Size(119, 23)
Me.btnChoose.Size = New System.Drawing.Size(90, 23)
Me.btnChoose.TabIndex = 2
Me.btnChoose.Text = "C&hoose Game"
Me.btnChoose.UseVisualStyleBackColor = True
@@ -51,13 +52,24 @@ Partial Class frmChooseGame
Me.lstGameBox.Location = New System.Drawing.Point(15, 34)
Me.lstGameBox.Name = "lstGameBox"
Me.lstGameBox.Size = New System.Drawing.Size(228, 95)
Me.lstGameBox.Sorted = True
Me.lstGameBox.TabIndex = 1
'
'btnCancel
'
Me.btnCancel.Location = New System.Drawing.Point(168, 135)
Me.btnCancel.Name = "btnCancel"
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
Me.btnCancel.TabIndex = 3
Me.btnCancel.Text = "&Cancel"
Me.btnCancel.UseVisualStyleBackColor = True
'
'frmChooseGame
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(255, 166)
Me.Controls.Add(Me.btnCancel)
Me.Controls.Add(Me.lstGameBox)
Me.Controls.Add(Me.btnChoose)
Me.Controls.Add(Me.lblChoose)
@@ -75,4 +87,5 @@ Partial Class frmChooseGame
Friend WithEvents lblChoose As System.Windows.Forms.Label
Friend WithEvents btnChoose As System.Windows.Forms.Button
Friend WithEvents lstGameBox As System.Windows.Forms.ListBox
Friend WithEvents btnCancel As Button
End Class
+31 -11
View File
@@ -1,8 +1,9 @@
Public Class frmChooseGame
Imports GBM.My.Resources
Public Class frmChooseGame
Private oProcess As mgrProcesses
Private oGame As clsGame
Private oGamesList As New List(Of KeyValuePair(Of String, String))
Private oGamesHash As New Hashtable
Private bGameSelected As Boolean = False
@@ -25,16 +26,15 @@
End Property
Private Sub FillComboBox()
lstGameBox.ValueMember = "Key"
lstGameBox.DisplayMember = "Value"
For Each o As clsGame In Process.DuplicateList
oGamesList.Add(New KeyValuePair(Of String, String)(o.ID, o.Name))
lstGameBox.Items.Add(New KeyValuePair(Of String, String)(o.ID, o.Name))
oGamesHash.Add(o.ID, o)
Next
lstGameBox.DataSource = oGamesList
lstGameBox.ValueMember = "key"
lstGameBox.DisplayMember = "value"
lstGameBox.SelectedIndex = 0
End Sub
Private Sub SaveSelection()
@@ -43,17 +43,33 @@
End Sub
Private Sub GetSelection()
Dim sSelectedGame As String
sSelectedGame = CStr(lstGameBox.SelectedValue)
oGame = DirectCast(oGamesHash.Item(sSelectedGame), clsGame)
Dim oSelected As KeyValuePair(Of String, String) = lstGameBox.SelectedItem
oGame = DirectCast(oGamesHash.Item(oSelected.Key), clsGame)
SaveSelection()
bGameSelected = True
Me.DialogResult = DialogResult.OK
Me.Close()
End Sub
Private Sub SetForm()
'Set Form Name
Me.Text = frmChooseGame_FormName
'Set Form Text
btnCancel.Text = frmChooseGame_btnCancel
btnChoose.Text = frmChooseGame_btnChoose
lblChoose.Text = frmChooseGame_lblChoose
End Sub
Private Sub frmChooseGame_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
SetForm()
FillComboBox()
Me.Focus()
Dim sResource As String = String.Empty
Dim sCode As String = String.Empty
mgrCommon.GetAllStrings(Me, sResource, sCode, "frmChooseGame")
Clipboard.SetText(sResource & vbCrLf & vbCrLf & sCode)
End Sub
Private Sub btnChoose_Click(sender As System.Object, e As System.EventArgs) Handles btnChoose.Click
@@ -62,7 +78,11 @@
Private Sub frmChooseGame_FormClosing(sender As System.Object, e As System.Windows.Forms.FormClosingEventArgs) Handles MyBase.FormClosing
If bGameSelected = False Then
e.Cancel = True
Me.DialogResult = DialogResult.Cancel
End If
End Sub
Private Sub btnCancel_Click(sender As Object, e As EventArgs) Handles btnCancel.Click
Me.Close()
End Sub
End Class
+12 -4
View File
@@ -1,4 +1,5 @@
Imports System.IO
Imports GBM.My.Resources
Imports System.IO
Public Class frmFileFolderSearch
Private sSearchItem As String
@@ -135,9 +136,7 @@ Public Class frmFileFolderSearch
If FoundItem = "Cancel" Then FoundItem = String.Empty
If oDrives.Count > iCurrentDrive And FoundItem = String.Empty Then
oResult = MsgBox("The location was not found on the " & oSearchDrive.Root.ToString & _
" drive. Do you wish to search the " & oDrives(iCurrentDrive).RootDirectory.ToString & _
" drive?", MsgBoxStyle.YesNo, "Game Backup Monitor")
oResult = mgrCommon.ShowMessage(frmFileFolderSearch_SwitchDrives, New String() {oSearchDrive.Root.ToString, oDrives(iCurrentDrive).RootDirectory.ToString}, MsgBoxStyle.YesNo)
If oResult = MsgBoxResult.Yes Then
Search(oDrives(iCurrentDrive))
Else
@@ -150,7 +149,16 @@ Public Class frmFileFolderSearch
End If
End Sub
Private Sub SetForm()
'Set Form Name
Me.Text = frmFileFolderSearch_FormName
'Set Form Text
btnCancel.Text = frmFileFolderSearch_btnCancel
End Sub
Private Sub frmFileFolderSearch_Load(sender As Object, e As EventArgs) Handles MyBase.Load
SetForm()
GetDrives()
Search(oDrives(iCurrentDrive))
End Sub
+252 -86
View File
@@ -22,92 +22,80 @@ Partial Class frmFilter
'Do not modify it using the code editor.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Me.btnOK = New System.Windows.Forms.Button()
Me.optGameInfo = New System.Windows.Forms.RadioButton()
Me.optTag = New System.Windows.Forms.RadioButton()
Me.grpTagFilter = New System.Windows.Forms.GroupBox()
Me.grpTagOptions = New System.Windows.Forms.GroupBox()
Me.optAll = New System.Windows.Forms.RadioButton()
Me.optAny = New System.Windows.Forms.RadioButton()
Me.lblGameTags = New System.Windows.Forms.Label()
Me.lblTags = New System.Windows.Forms.Label()
Me.btnRemove = New System.Windows.Forms.Button()
Me.btnAdd = New System.Windows.Forms.Button()
Me.lstFilter = New System.Windows.Forms.ListBox()
Me.lstTags = New System.Windows.Forms.ListBox()
Me.GroupBox1 = New System.Windows.Forms.GroupBox()
Me.optAll = New System.Windows.Forms.RadioButton()
Me.optAny = New System.Windows.Forms.RadioButton()
Me.GroupBox1.SuspendLayout()
Me.btnOK = New System.Windows.Forms.Button()
Me.grpGameFilter = New System.Windows.Forms.GroupBox()
Me.grpGameInfoOptions = New System.Windows.Forms.GroupBox()
Me.optOr = New System.Windows.Forms.RadioButton()
Me.optAnd = New System.Windows.Forms.RadioButton()
Me.txtCompany = New System.Windows.Forms.TextBox()
Me.lblCompany = New System.Windows.Forms.Label()
Me.txtProcess = New System.Windows.Forms.TextBox()
Me.lblProcess = New System.Windows.Forms.Label()
Me.lblName = New System.Windows.Forms.Label()
Me.txtName = New System.Windows.Forms.TextBox()
Me.grpTagFilter.SuspendLayout()
Me.grpTagOptions.SuspendLayout()
Me.grpGameFilter.SuspendLayout()
Me.grpGameInfoOptions.SuspendLayout()
Me.SuspendLayout()
'
'btnOK
'optGameInfo
'
Me.btnOK.Location = New System.Drawing.Point(297, 229)
Me.btnOK.Name = "btnOK"
Me.btnOK.Size = New System.Drawing.Size(75, 23)
Me.btnOK.TabIndex = 7
Me.btnOK.Text = "&OK"
Me.btnOK.UseVisualStyleBackColor = True
Me.optGameInfo.AutoSize = True
Me.optGameInfo.Location = New System.Drawing.Point(12, 12)
Me.optGameInfo.Name = "optGameInfo"
Me.optGameInfo.Size = New System.Drawing.Size(108, 17)
Me.optGameInfo.TabIndex = 0
Me.optGameInfo.Text = "Game Information"
Me.optGameInfo.UseVisualStyleBackColor = True
'
'lblGameTags
'optTag
'
Me.lblGameTags.AutoSize = True
Me.lblGameTags.Location = New System.Drawing.Point(263, 8)
Me.lblGameTags.Name = "lblGameTags"
Me.lblGameTags.Size = New System.Drawing.Size(66, 13)
Me.lblGameTags.TabIndex = 5
Me.lblGameTags.Text = "Current Filter"
Me.optTag.AutoSize = True
Me.optTag.Location = New System.Drawing.Point(12, 190)
Me.optTag.Name = "optTag"
Me.optTag.Size = New System.Drawing.Size(44, 17)
Me.optTag.TabIndex = 2
Me.optTag.Text = "Tag"
Me.optTag.UseVisualStyleBackColor = True
'
'lblTags
'grpTagFilter
'
Me.lblTags.AutoSize = True
Me.lblTags.Location = New System.Drawing.Point(49, 8)
Me.lblTags.Name = "lblTags"
Me.lblTags.Size = New System.Drawing.Size(77, 13)
Me.lblTags.TabIndex = 0
Me.lblTags.Text = "Available Tags"
Me.grpTagFilter.Controls.Add(Me.grpTagOptions)
Me.grpTagFilter.Controls.Add(Me.lblGameTags)
Me.grpTagFilter.Controls.Add(Me.lblTags)
Me.grpTagFilter.Controls.Add(Me.btnRemove)
Me.grpTagFilter.Controls.Add(Me.btnAdd)
Me.grpTagFilter.Controls.Add(Me.lstFilter)
Me.grpTagFilter.Controls.Add(Me.lstTags)
Me.grpTagFilter.Location = New System.Drawing.Point(12, 213)
Me.grpTagFilter.Name = "grpTagFilter"
Me.grpTagFilter.Size = New System.Drawing.Size(385, 265)
Me.grpTagFilter.TabIndex = 3
Me.grpTagFilter.TabStop = False
'
'btnRemove
'grpTagOptions
'
Me.btnRemove.Location = New System.Drawing.Point(168, 114)
Me.btnRemove.Name = "btnRemove"
Me.btnRemove.Size = New System.Drawing.Size(48, 23)
Me.btnRemove.TabIndex = 4
Me.btnRemove.Text = "< <"
Me.btnRemove.UseVisualStyleBackColor = True
'
'btnAdd
'
Me.btnAdd.Location = New System.Drawing.Point(168, 85)
Me.btnAdd.Name = "btnAdd"
Me.btnAdd.Size = New System.Drawing.Size(48, 23)
Me.btnAdd.TabIndex = 3
Me.btnAdd.Text = "> >"
Me.btnAdd.UseVisualStyleBackColor = True
'
'lstFilter
'
Me.lstFilter.FormattingEnabled = True
Me.lstFilter.Location = New System.Drawing.Point(222, 24)
Me.lstFilter.Name = "lstFilter"
Me.lstFilter.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
Me.lstFilter.Size = New System.Drawing.Size(150, 173)
Me.lstFilter.TabIndex = 6
'
'lstTags
'
Me.lstTags.FormattingEnabled = True
Me.lstTags.Location = New System.Drawing.Point(12, 24)
Me.lstTags.Name = "lstTags"
Me.lstTags.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
Me.lstTags.Size = New System.Drawing.Size(150, 173)
Me.lstTags.TabIndex = 1
'
'GroupBox1
'
Me.GroupBox1.Controls.Add(Me.optAll)
Me.GroupBox1.Controls.Add(Me.optAny)
Me.GroupBox1.Location = New System.Drawing.Point(12, 206)
Me.GroupBox1.Name = "GroupBox1"
Me.GroupBox1.Size = New System.Drawing.Size(150, 46)
Me.GroupBox1.TabIndex = 2
Me.GroupBox1.TabStop = False
Me.GroupBox1.Text = "Matching Options"
Me.grpTagOptions.Controls.Add(Me.optAll)
Me.grpTagOptions.Controls.Add(Me.optAny)
Me.grpTagOptions.Location = New System.Drawing.Point(6, 211)
Me.grpTagOptions.Name = "grpTagOptions"
Me.grpTagOptions.Size = New System.Drawing.Size(150, 46)
Me.grpTagOptions.TabIndex = 6
Me.grpTagOptions.TabStop = False
Me.grpTagOptions.Text = "Options"
'
'optAll
'
@@ -132,40 +120,218 @@ Partial Class frmFilter
Me.optAny.Text = "Any Tag"
Me.optAny.UseVisualStyleBackColor = True
'
'lblGameTags
'
Me.lblGameTags.AutoSize = True
Me.lblGameTags.Location = New System.Drawing.Point(271, 16)
Me.lblGameTags.Name = "lblGameTags"
Me.lblGameTags.Size = New System.Drawing.Size(66, 13)
Me.lblGameTags.TabIndex = 4
Me.lblGameTags.Text = "Current Filter"
'
'lblTags
'
Me.lblTags.AutoSize = True
Me.lblTags.Location = New System.Drawing.Point(43, 16)
Me.lblTags.Name = "lblTags"
Me.lblTags.Size = New System.Drawing.Size(77, 13)
Me.lblTags.TabIndex = 0
Me.lblTags.Text = "Available Tags"
'
'btnRemove
'
Me.btnRemove.Location = New System.Drawing.Point(162, 122)
Me.btnRemove.Name = "btnRemove"
Me.btnRemove.Size = New System.Drawing.Size(61, 23)
Me.btnRemove.TabIndex = 3
Me.btnRemove.Text = "<"
Me.btnRemove.UseVisualStyleBackColor = True
'
'btnAdd
'
Me.btnAdd.Location = New System.Drawing.Point(162, 93)
Me.btnAdd.Name = "btnAdd"
Me.btnAdd.Size = New System.Drawing.Size(61, 23)
Me.btnAdd.TabIndex = 2
Me.btnAdd.Text = ">"
Me.btnAdd.UseVisualStyleBackColor = True
'
'lstFilter
'
Me.lstFilter.FormattingEnabled = True
Me.lstFilter.Location = New System.Drawing.Point(229, 32)
Me.lstFilter.Name = "lstFilter"
Me.lstFilter.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
Me.lstFilter.Size = New System.Drawing.Size(150, 173)
Me.lstFilter.Sorted = True
Me.lstFilter.TabIndex = 5
'
'lstTags
'
Me.lstTags.FormattingEnabled = True
Me.lstTags.Location = New System.Drawing.Point(6, 32)
Me.lstTags.Name = "lstTags"
Me.lstTags.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
Me.lstTags.Size = New System.Drawing.Size(150, 173)
Me.lstTags.Sorted = True
Me.lstTags.TabIndex = 1
'
'btnOK
'
Me.btnOK.Location = New System.Drawing.Point(322, 484)
Me.btnOK.Name = "btnOK"
Me.btnOK.Size = New System.Drawing.Size(75, 23)
Me.btnOK.TabIndex = 4
Me.btnOK.Text = "&OK"
Me.btnOK.UseVisualStyleBackColor = True
'
'grpGameFilter
'
Me.grpGameFilter.Controls.Add(Me.grpGameInfoOptions)
Me.grpGameFilter.Controls.Add(Me.txtCompany)
Me.grpGameFilter.Controls.Add(Me.lblCompany)
Me.grpGameFilter.Controls.Add(Me.txtProcess)
Me.grpGameFilter.Controls.Add(Me.lblProcess)
Me.grpGameFilter.Controls.Add(Me.lblName)
Me.grpGameFilter.Controls.Add(Me.txtName)
Me.grpGameFilter.Location = New System.Drawing.Point(12, 35)
Me.grpGameFilter.Name = "grpGameFilter"
Me.grpGameFilter.Size = New System.Drawing.Size(385, 150)
Me.grpGameFilter.TabIndex = 1
Me.grpGameFilter.TabStop = False
'
'grpGameInfoOptions
'
Me.grpGameInfoOptions.Controls.Add(Me.optOr)
Me.grpGameInfoOptions.Controls.Add(Me.optAnd)
Me.grpGameInfoOptions.Location = New System.Drawing.Point(14, 97)
Me.grpGameInfoOptions.Name = "grpGameInfoOptions"
Me.grpGameInfoOptions.Size = New System.Drawing.Size(106, 46)
Me.grpGameInfoOptions.TabIndex = 6
Me.grpGameInfoOptions.TabStop = False
Me.grpGameInfoOptions.Text = "Options"
'
'optOr
'
Me.optOr.AutoSize = True
Me.optOr.Location = New System.Drawing.Point(56, 19)
Me.optOr.Name = "optOr"
Me.optOr.Size = New System.Drawing.Size(36, 17)
Me.optOr.TabIndex = 1
Me.optOr.TabStop = True
Me.optOr.Text = "Or"
Me.optOr.UseVisualStyleBackColor = True
'
'optAnd
'
Me.optAnd.AutoSize = True
Me.optAnd.Checked = True
Me.optAnd.Location = New System.Drawing.Point(6, 19)
Me.optAnd.Name = "optAnd"
Me.optAnd.Size = New System.Drawing.Size(44, 17)
Me.optAnd.TabIndex = 0
Me.optAnd.TabStop = True
Me.optAnd.Text = "And"
Me.optAnd.UseVisualStyleBackColor = True
'
'txtCompany
'
Me.txtCompany.Location = New System.Drawing.Point(70, 71)
Me.txtCompany.Name = "txtCompany"
Me.txtCompany.Size = New System.Drawing.Size(309, 20)
Me.txtCompany.TabIndex = 5
'
'lblCompany
'
Me.lblCompany.AutoSize = True
Me.lblCompany.Location = New System.Drawing.Point(11, 74)
Me.lblCompany.Name = "lblCompany"
Me.lblCompany.Size = New System.Drawing.Size(54, 13)
Me.lblCompany.TabIndex = 4
Me.lblCompany.Text = "Company:"
'
'txtProcess
'
Me.txtProcess.Location = New System.Drawing.Point(70, 45)
Me.txtProcess.Name = "txtProcess"
Me.txtProcess.Size = New System.Drawing.Size(309, 20)
Me.txtProcess.TabIndex = 3
'
'lblProcess
'
Me.lblProcess.AutoSize = True
Me.lblProcess.Location = New System.Drawing.Point(11, 48)
Me.lblProcess.Name = "lblProcess"
Me.lblProcess.Size = New System.Drawing.Size(48, 13)
Me.lblProcess.TabIndex = 2
Me.lblProcess.Text = "Process:"
'
'lblName
'
Me.lblName.AutoSize = True
Me.lblName.Location = New System.Drawing.Point(11, 22)
Me.lblName.Name = "lblName"
Me.lblName.Size = New System.Drawing.Size(38, 13)
Me.lblName.TabIndex = 0
Me.lblName.Text = "Name:"
'
'txtName
'
Me.txtName.Location = New System.Drawing.Point(70, 19)
Me.txtName.Name = "txtName"
Me.txtName.Size = New System.Drawing.Size(309, 20)
Me.txtName.TabIndex = 1
'
'frmFilter
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(384, 261)
Me.Controls.Add(Me.GroupBox1)
Me.ClientSize = New System.Drawing.Size(409, 516)
Me.Controls.Add(Me.grpGameFilter)
Me.Controls.Add(Me.grpTagFilter)
Me.Controls.Add(Me.btnOK)
Me.Controls.Add(Me.lblGameTags)
Me.Controls.Add(Me.lblTags)
Me.Controls.Add(Me.btnRemove)
Me.Controls.Add(Me.btnAdd)
Me.Controls.Add(Me.lstFilter)
Me.Controls.Add(Me.lstTags)
Me.Controls.Add(Me.optTag)
Me.Controls.Add(Me.optGameInfo)
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle
Me.MaximizeBox = False
Me.MinimizeBox = False
Me.Name = "frmFilter"
Me.ShowIcon = False
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
Me.Text = "Filter by Tags"
Me.GroupBox1.ResumeLayout(False)
Me.GroupBox1.PerformLayout()
Me.Text = "Custom Filter"
Me.grpTagFilter.ResumeLayout(False)
Me.grpTagFilter.PerformLayout()
Me.grpTagOptions.ResumeLayout(False)
Me.grpTagOptions.PerformLayout()
Me.grpGameFilter.ResumeLayout(False)
Me.grpGameFilter.PerformLayout()
Me.grpGameInfoOptions.ResumeLayout(False)
Me.grpGameInfoOptions.PerformLayout()
Me.ResumeLayout(False)
Me.PerformLayout()
End Sub
Friend WithEvents btnOK As System.Windows.Forms.Button
Friend WithEvents optGameInfo As System.Windows.Forms.RadioButton
Friend WithEvents optTag As System.Windows.Forms.RadioButton
Friend WithEvents grpTagFilter As System.Windows.Forms.GroupBox
Friend WithEvents grpTagOptions As System.Windows.Forms.GroupBox
Friend WithEvents optAll As System.Windows.Forms.RadioButton
Friend WithEvents optAny As System.Windows.Forms.RadioButton
Friend WithEvents lblGameTags As System.Windows.Forms.Label
Friend WithEvents lblTags As System.Windows.Forms.Label
Friend WithEvents btnRemove As System.Windows.Forms.Button
Friend WithEvents btnAdd As System.Windows.Forms.Button
Friend WithEvents lstFilter As System.Windows.Forms.ListBox
Friend WithEvents lstTags As System.Windows.Forms.ListBox
Friend WithEvents GroupBox1 As GroupBox
Friend WithEvents optAll As RadioButton
Friend WithEvents optAny As RadioButton
Friend WithEvents btnOK As System.Windows.Forms.Button
Friend WithEvents grpGameFilter As System.Windows.Forms.GroupBox
Friend WithEvents txtProcess As System.Windows.Forms.TextBox
Friend WithEvents lblProcess As System.Windows.Forms.Label
Friend WithEvents lblName As System.Windows.Forms.Label
Friend WithEvents txtName As System.Windows.Forms.TextBox
Friend WithEvents txtCompany As System.Windows.Forms.TextBox
Friend WithEvents lblCompany As System.Windows.Forms.Label
Friend WithEvents grpGameInfoOptions As System.Windows.Forms.GroupBox
Friend WithEvents optOr As System.Windows.Forms.RadioButton
Friend WithEvents optAnd As System.Windows.Forms.RadioButton
End Class
+88 -17
View File
@@ -1,18 +1,31 @@
Public Class frmFilter
Imports GBM.My.Resources
Public Class frmFilter
Public Enum eFilterType As Integer
Any = 1
All = 2
NoFilter = 1
AnyTag = 2
AllTags = 3
NoTags = 4
FieldAnd = 5
FieldOr = 6
End Enum
Dim oFilters As New List(Of clsTag)
Dim eCurrentFilterType As eFilterType = eFilterType.Any
Dim oTagFilters As New List(Of clsTag)
Dim hshStringFilters As New Hashtable
Dim eCurrentFilterType As eFilterType = eFilterType.AnyTag
Dim hshTags As New Hashtable
Dim bShutdown As Boolean = False
Public ReadOnly Property Filters As List(Of clsTag)
Public ReadOnly Property StringFilters As Hashtable
Get
Return oFilters
Return hshStringFilters
End Get
End Property
Public ReadOnly Property TagFilters As List(Of clsTag)
Get
Return oTagFilters
End Get
End Property
@@ -96,29 +109,77 @@
Dim oData As KeyValuePair(Of String, String)
Dim oTag As clsTag
'Set Tags
For Each oData In lstFilter.Items
oTag = DirectCast(hshTags(oData.Value), clsTag)
Filters.Add(oTag)
Next
'Set Filter Type
If optAll.Checked Then
eCurrentFilterType = eFilterType.All
If optGameInfo.Checked Then
'Set Filter Type
If optAnd.Checked Then
eCurrentFilterType = eFilterType.FieldAnd
Else
eCurrentFilterType = eFilterType.FieldOr
End If
'Set String Filter
If txtName.Text <> String.Empty Then
hshStringFilters.Add("Name", txtName.Text)
End If
If txtProcess.Text <> String.Empty Then
hshStringFilters.Add("Process", txtProcess.Text)
End If
If txtCompany.Text <> String.Empty Then
hshStringFilters.Add("Company", txtCompany.Text)
End If
Else
eCurrentFilterType = eFilterType.Any
'Set Tags
For Each oData In lstFilter.Items
oTag = DirectCast(hshTags(oData.Value), clsTag)
TagFilters.Add(oTag)
Next
'Set Filter Type
If TagFilters.Count = 0 Then
eCurrentFilterType = eFilterType.NoTags
ElseIf optAll.Checked Then
eCurrentFilterType = eFilterType.AllTags
Else
eCurrentFilterType = eFilterType.AnyTag
End If
End If
End Sub
Private Sub SetForm()
'Set Form Name
Me.Text = frmFilter_FormName
'Set Form Text
optOr.Text = frmFilter_optOr
optAnd.Text = frmFilter_optAnd
lblCompany.Text = frmFilter_lblCompany
lblProcess.Text = frmFilter_lblProcess
lblName.Text = frmFilter_lblName
grpGameInfoOptions.Text = frmFilter_grpGameInfoOptions
optAll.Text = frmFilter_optAll
optAny.Text = frmFilter_optAny
lblGameTags.Text = frmFilter_lblGameTags
lblTags.Text = frmFilter_lblTags
btnRemove.Text = frmFilter_btnRemove
btnAdd.Text = frmFilter_btnAdd
btnOK.Text = frmFilter_btnOK
grpTagOptions.Text = frmFilter_grpTagOptions
optTag.Text = frmFilter_optTag
optGameInfo.Text = frmFilter_optGameInfo
End Sub
Private Sub frmGameTags_Load(sender As Object, e As EventArgs) Handles MyBase.Load
SetForm()
optGameInfo.Checked = True
LoadData()
End Sub
Private Sub btnOK_Click(sender As Object, e As EventArgs) Handles btnOK.Click
GetFilters()
bShutdown = True
Me.close
Me.Close()
End Sub
Private Sub btnAdd_Click(sender As Object, e As EventArgs) Handles btnAdd.Click
@@ -134,4 +195,14 @@
e.Cancel = True
End If
End Sub
Private Sub optGameInfo_Click(sender As Object, e As EventArgs) Handles optGameInfo.Click, optTag.Click
If optGameInfo.Checked = True Then
grpGameFilter.Enabled = True
grpTagFilter.Enabled = False
Else
grpGameFilter.Enabled = False
grpTagFilter.Enabled = True
End If
End Sub
End Class
+220 -144
View File
@@ -22,14 +22,15 @@ Partial Class frmGameManager
'Do not modify it using the code editor.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Me.components = New System.ComponentModel.Container()
Me.btnAdd = New System.Windows.Forms.Button()
Me.btnDelete = New System.Windows.Forms.Button()
Me.btnBackup = New System.Windows.Forms.Button()
Me.btnClose = New System.Windows.Forms.Button()
Me.grpConfig = New System.Windows.Forms.GroupBox()
Me.btnExclude = New System.Windows.Forms.Button()
Me.btnInclude = New System.Windows.Forms.Button()
Me.txtID = New System.Windows.Forms.TextBox()
Me.lblExclude = New System.Windows.Forms.Label()
Me.lblFileType = New System.Windows.Forms.Label()
Me.btnSavePathBrowse = New System.Windows.Forms.Button()
Me.btnProcessBrowse = New System.Windows.Forms.Button()
Me.lblSavePath = New System.Windows.Forms.Label()
@@ -52,7 +53,7 @@ Partial Class frmGameManager
Me.txtCompany = New System.Windows.Forms.TextBox()
Me.lblCompany = New System.Windows.Forms.Label()
Me.pbIcon = New System.Windows.Forms.PictureBox()
Me.Label1 = New System.Windows.Forms.Label()
Me.lblIcon = New System.Windows.Forms.Label()
Me.btnAppPathBrowse = New System.Windows.Forms.Button()
Me.lblGamePath = New System.Windows.Forms.Label()
Me.txtAppPath = New System.Windows.Forms.TextBox()
@@ -60,6 +61,8 @@ Partial Class frmGameManager
Me.lblHours = New System.Windows.Forms.Label()
Me.btnTags = New System.Windows.Forms.Button()
Me.grpStats = New System.Windows.Forms.GroupBox()
Me.lblRestorePath = New System.Windows.Forms.Label()
Me.txtRestorePath = New System.Windows.Forms.TextBox()
Me.btnOpenRestorePath = New System.Windows.Forms.Button()
Me.btnOpenBackupFile = New System.Windows.Forms.Button()
Me.txtFileSize = New System.Windows.Forms.TextBox()
@@ -77,23 +80,29 @@ Partial Class frmGameManager
Me.btnCancel = New System.Windows.Forms.Button()
Me.chkEnabled = New System.Windows.Forms.CheckBox()
Me.grpFilter = New System.Windows.Forms.GroupBox()
Me.optTag = New System.Windows.Forms.RadioButton()
Me.optCustom = New System.Windows.Forms.RadioButton()
Me.optBackupData = New System.Windows.Forms.RadioButton()
Me.optPendingRestores = New System.Windows.Forms.RadioButton()
Me.optAllGames = New System.Windows.Forms.RadioButton()
Me.btnImport = New System.Windows.Forms.Button()
Me.btnExport = New System.Windows.Forms.Button()
Me.cmsImport = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.cmsOfficial = New System.Windows.Forms.ToolStripMenuItem()
Me.cmsFile = New System.Windows.Forms.ToolStripMenuItem()
Me.grpConfig.SuspendLayout()
Me.grpExtra.SuspendLayout()
CType(Me.pbIcon, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.nudHours, System.ComponentModel.ISupportInitialize).BeginInit()
Me.grpStats.SuspendLayout()
Me.grpFilter.SuspendLayout()
Me.cmsImport.SuspendLayout()
Me.SuspendLayout()
'
'btnAdd
'
Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
Me.btnAdd.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.btnAdd.Location = New System.Drawing.Point(12, 527)
Me.btnAdd.Location = New System.Drawing.Point(12, 526)
Me.btnAdd.Name = "btnAdd"
Me.btnAdd.Size = New System.Drawing.Size(30, 23)
Me.btnAdd.TabIndex = 2
@@ -104,7 +113,7 @@ Partial Class frmGameManager
'
Me.btnDelete.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
Me.btnDelete.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.btnDelete.Location = New System.Drawing.Point(48, 527)
Me.btnDelete.Location = New System.Drawing.Point(48, 526)
Me.btnDelete.Name = "btnDelete"
Me.btnDelete.Size = New System.Drawing.Size(30, 23)
Me.btnDelete.TabIndex = 3
@@ -114,29 +123,29 @@ Partial Class frmGameManager
'btnBackup
'
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, 526)
Me.btnBackup.Location = New System.Drawing.Point(616, 525)
Me.btnBackup.Name = "btnBackup"
Me.btnBackup.Size = New System.Drawing.Size(75, 23)
Me.btnBackup.TabIndex = 13
Me.btnBackup.TabIndex = 16
Me.btnBackup.Text = "&Backup"
Me.btnBackup.UseVisualStyleBackColor = True
'
'btnClose
'
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, 526)
Me.btnClose.Location = New System.Drawing.Point(697, 525)
Me.btnClose.Name = "btnClose"
Me.btnClose.Size = New System.Drawing.Size(75, 23)
Me.btnClose.TabIndex = 14
Me.btnClose.TabIndex = 17
Me.btnClose.Text = "C&lose"
Me.btnClose.UseVisualStyleBackColor = True
'
'grpConfig
'
Me.grpConfig.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.grpConfig.Controls.Add(Me.btnExclude)
Me.grpConfig.Controls.Add(Me.btnInclude)
Me.grpConfig.Controls.Add(Me.txtID)
Me.grpConfig.Controls.Add(Me.lblExclude)
Me.grpConfig.Controls.Add(Me.lblFileType)
Me.grpConfig.Controls.Add(Me.btnSavePathBrowse)
Me.grpConfig.Controls.Add(Me.btnProcessBrowse)
Me.grpConfig.Controls.Add(Me.lblSavePath)
@@ -150,56 +159,56 @@ Partial Class frmGameManager
Me.grpConfig.Controls.Add(Me.txtProcess)
Me.grpConfig.Controls.Add(Me.txtName)
Me.grpConfig.Enabled = False
Me.grpConfig.Location = New System.Drawing.Point(238, 12)
Me.grpConfig.Location = New System.Drawing.Point(247, 12)
Me.grpConfig.Name = "grpConfig"
Me.grpConfig.Size = New System.Drawing.Size(534, 182)
Me.grpConfig.TabIndex = 4
Me.grpConfig.Size = New System.Drawing.Size(525, 157)
Me.grpConfig.TabIndex = 6
Me.grpConfig.TabStop = False
Me.grpConfig.Text = "Configuration"
'
'btnExclude
'
Me.btnExclude.Location = New System.Drawing.Point(9, 125)
Me.btnExclude.Name = "btnExclude"
Me.btnExclude.Size = New System.Drawing.Size(175, 23)
Me.btnExclude.TabIndex = 13
Me.btnExclude.Text = "E&xclude Items..."
Me.btnExclude.UseVisualStyleBackColor = True
'
'btnInclude
'
Me.btnInclude.Location = New System.Drawing.Point(9, 97)
Me.btnInclude.Name = "btnInclude"
Me.btnInclude.Size = New System.Drawing.Size(175, 23)
Me.btnInclude.TabIndex = 10
Me.btnInclude.Text = "In&clude Items..."
Me.btnInclude.UseVisualStyleBackColor = True
'
'txtID
'
Me.txtID.Enabled = False
Me.txtID.Location = New System.Drawing.Point(495, 147)
Me.txtID.Location = New System.Drawing.Point(489, 19)
Me.txtID.Name = "txtID"
Me.txtID.Size = New System.Drawing.Size(33, 20)
Me.txtID.TabIndex = 0
Me.txtID.Size = New System.Drawing.Size(30, 20)
Me.txtID.TabIndex = 16
Me.txtID.TabStop = False
Me.txtID.Visible = False
'
'lblExclude
'
Me.lblExclude.AutoSize = True
Me.lblExclude.Location = New System.Drawing.Point(6, 126)
Me.lblExclude.Name = "lblExclude"
Me.lblExclude.Size = New System.Drawing.Size(48, 13)
Me.lblExclude.TabIndex = 13
Me.lblExclude.Text = "Exclude:"
'
'lblFileType
'
Me.lblFileType.AutoSize = True
Me.lblFileType.Location = New System.Drawing.Point(6, 100)
Me.lblFileType.Name = "lblFileType"
Me.lblFileType.Size = New System.Drawing.Size(45, 13)
Me.lblFileType.TabIndex = 12
Me.lblFileType.Text = "Include:"
'
'btnSavePathBrowse
'
Me.btnSavePathBrowse.Location = New System.Drawing.Point(498, 71)
Me.btnSavePathBrowse.Location = New System.Drawing.Point(489, 71)
Me.btnSavePathBrowse.Name = "btnSavePathBrowse"
Me.btnSavePathBrowse.Size = New System.Drawing.Size(30, 20)
Me.btnSavePathBrowse.TabIndex = 10
Me.btnSavePathBrowse.TabIndex = 9
Me.btnSavePathBrowse.Text = "..."
Me.btnSavePathBrowse.UseVisualStyleBackColor = True
'
'btnProcessBrowse
'
Me.btnProcessBrowse.Location = New System.Drawing.Point(498, 45)
Me.btnProcessBrowse.Location = New System.Drawing.Point(489, 45)
Me.btnProcessBrowse.Name = "btnProcessBrowse"
Me.btnProcessBrowse.Size = New System.Drawing.Size(30, 20)
Me.btnProcessBrowse.TabIndex = 8
Me.btnProcessBrowse.TabIndex = 7
Me.btnProcessBrowse.Text = "..."
Me.btnProcessBrowse.UseVisualStyleBackColor = True
'
@@ -209,7 +218,7 @@ Partial Class frmGameManager
Me.lblSavePath.Location = New System.Drawing.Point(6, 74)
Me.lblSavePath.Name = "lblSavePath"
Me.lblSavePath.Size = New System.Drawing.Size(60, 13)
Me.lblSavePath.TabIndex = 9
Me.lblSavePath.TabIndex = 2
Me.lblSavePath.Text = "Save Path:"
'
'lblProcess
@@ -218,7 +227,7 @@ Partial Class frmGameManager
Me.lblProcess.Location = New System.Drawing.Point(6, 48)
Me.lblProcess.Name = "lblProcess"
Me.lblProcess.Size = New System.Drawing.Size(48, 13)
Me.lblProcess.TabIndex = 8
Me.lblProcess.TabIndex = 1
Me.lblProcess.Text = "Process:"
'
'lblName
@@ -227,27 +236,31 @@ Partial Class frmGameManager
Me.lblName.Location = New System.Drawing.Point(6, 22)
Me.lblName.Name = "lblName"
Me.lblName.Size = New System.Drawing.Size(38, 13)
Me.lblName.TabIndex = 7
Me.lblName.TabIndex = 0
Me.lblName.Text = "Name:"
'
'txtExclude
'
Me.txtExclude.Location = New System.Drawing.Point(69, 123)
Me.txtExclude.Location = New System.Drawing.Point(363, 128)
Me.txtExclude.Name = "txtExclude"
Me.txtExclude.Size = New System.Drawing.Size(459, 20)
Me.txtExclude.TabIndex = 12
Me.txtExclude.Size = New System.Drawing.Size(156, 20)
Me.txtExclude.TabIndex = 0
Me.txtExclude.TabStop = False
Me.txtExclude.Visible = False
'
'txtFileType
'
Me.txtFileType.Location = New System.Drawing.Point(69, 97)
Me.txtFileType.Location = New System.Drawing.Point(363, 99)
Me.txtFileType.Name = "txtFileType"
Me.txtFileType.Size = New System.Drawing.Size(459, 20)
Me.txtFileType.TabIndex = 11
Me.txtFileType.Size = New System.Drawing.Size(156, 20)
Me.txtFileType.TabIndex = 0
Me.txtFileType.TabStop = False
Me.txtFileType.Visible = False
'
'chkTimeStamp
'
Me.chkTimeStamp.AutoSize = True
Me.chkTimeStamp.Location = New System.Drawing.Point(124, 149)
Me.chkTimeStamp.Location = New System.Drawing.Point(190, 129)
Me.chkTimeStamp.Name = "chkTimeStamp"
Me.chkTimeStamp.Size = New System.Drawing.Size(146, 17)
Me.chkTimeStamp.TabIndex = 14
@@ -257,10 +270,10 @@ Partial Class frmGameManager
'chkFolderSave
'
Me.chkFolderSave.AutoSize = True
Me.chkFolderSave.Location = New System.Drawing.Point(9, 149)
Me.chkFolderSave.Location = New System.Drawing.Point(190, 101)
Me.chkFolderSave.Name = "chkFolderSave"
Me.chkFolderSave.Size = New System.Drawing.Size(109, 17)
Me.chkFolderSave.TabIndex = 13
Me.chkFolderSave.TabIndex = 11
Me.chkFolderSave.Text = "Save entire folder"
Me.chkFolderSave.UseVisualStyleBackColor = True
'
@@ -268,30 +281,30 @@ Partial Class frmGameManager
'
Me.txtSavePath.Location = New System.Drawing.Point(69, 71)
Me.txtSavePath.Name = "txtSavePath"
Me.txtSavePath.Size = New System.Drawing.Size(423, 20)
Me.txtSavePath.TabIndex = 9
Me.txtSavePath.Size = New System.Drawing.Size(414, 20)
Me.txtSavePath.TabIndex = 8
'
'txtProcess
'
Me.txtProcess.Location = New System.Drawing.Point(69, 45)
Me.txtProcess.Name = "txtProcess"
Me.txtProcess.Size = New System.Drawing.Size(423, 20)
Me.txtProcess.TabIndex = 7
Me.txtProcess.Size = New System.Drawing.Size(414, 20)
Me.txtProcess.TabIndex = 6
'
'txtName
'
Me.txtName.Location = New System.Drawing.Point(69, 19)
Me.txtName.Name = "txtName"
Me.txtName.Size = New System.Drawing.Size(459, 20)
Me.txtName.TabIndex = 6
Me.txtName.Size = New System.Drawing.Size(414, 20)
Me.txtName.TabIndex = 5
'
'chkMonitorOnly
'
Me.chkMonitorOnly.AutoSize = True
Me.chkMonitorOnly.Location = New System.Drawing.Point(353, 365)
Me.chkMonitorOnly.Location = New System.Drawing.Point(362, 340)
Me.chkMonitorOnly.Name = "chkMonitorOnly"
Me.chkMonitorOnly.Size = New System.Drawing.Size(145, 17)
Me.chkMonitorOnly.TabIndex = 7
Me.chkMonitorOnly.TabIndex = 9
Me.chkMonitorOnly.Text = "Monitor only (No backup)"
Me.chkMonitorOnly.UseVisualStyleBackColor = True
'
@@ -306,16 +319,16 @@ Partial Class frmGameManager
Me.grpExtra.Controls.Add(Me.txtCompany)
Me.grpExtra.Controls.Add(Me.lblCompany)
Me.grpExtra.Controls.Add(Me.pbIcon)
Me.grpExtra.Controls.Add(Me.Label1)
Me.grpExtra.Controls.Add(Me.lblIcon)
Me.grpExtra.Controls.Add(Me.btnAppPathBrowse)
Me.grpExtra.Controls.Add(Me.lblGamePath)
Me.grpExtra.Controls.Add(Me.txtAppPath)
Me.grpExtra.Controls.Add(Me.nudHours)
Me.grpExtra.Controls.Add(Me.lblHours)
Me.grpExtra.Location = New System.Drawing.Point(238, 200)
Me.grpExtra.Location = New System.Drawing.Point(247, 175)
Me.grpExtra.Name = "grpExtra"
Me.grpExtra.Size = New System.Drawing.Size(534, 155)
Me.grpExtra.TabIndex = 5
Me.grpExtra.Size = New System.Drawing.Size(525, 155)
Me.grpExtra.TabIndex = 7
Me.grpExtra.TabStop = False
Me.grpExtra.Text = "Game Information"
'
@@ -323,19 +336,19 @@ Partial Class frmGameManager
'
Me.lblTags.AutoEllipsis = True
Me.lblTags.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblTags.Location = New System.Drawing.Point(163, 124)
Me.lblTags.Location = New System.Drawing.Point(161, 124)
Me.lblTags.Name = "lblTags"
Me.lblTags.Size = New System.Drawing.Size(311, 20)
Me.lblTags.Size = New System.Drawing.Size(304, 20)
Me.lblTags.TabIndex = 0
Me.lblTags.Text = "#Tags"
Me.lblTags.TextAlign = System.Drawing.ContentAlignment.MiddleRight
'
'btnIconBrowse
'
Me.btnIconBrowse.Location = New System.Drawing.Point(444, 96)
Me.btnIconBrowse.Location = New System.Drawing.Point(435, 97)
Me.btnIconBrowse.Name = "btnIconBrowse"
Me.btnIconBrowse.Size = New System.Drawing.Size(30, 20)
Me.btnIconBrowse.TabIndex = 20
Me.btnIconBrowse.TabIndex = 10
Me.btnIconBrowse.Text = "..."
Me.btnIconBrowse.UseVisualStyleBackColor = True
'
@@ -343,8 +356,8 @@ Partial Class frmGameManager
'
Me.txtIcon.Location = New System.Drawing.Point(69, 97)
Me.txtIcon.Name = "txtIcon"
Me.txtIcon.Size = New System.Drawing.Size(369, 20)
Me.txtIcon.TabIndex = 19
Me.txtIcon.Size = New System.Drawing.Size(360, 20)
Me.txtIcon.TabIndex = 9
'
'lblVersion
'
@@ -352,22 +365,22 @@ Partial Class frmGameManager
Me.lblVersion.Location = New System.Drawing.Point(6, 74)
Me.lblVersion.Name = "lblVersion"
Me.lblVersion.Size = New System.Drawing.Size(45, 13)
Me.lblVersion.TabIndex = 20
Me.lblVersion.TabIndex = 2
Me.lblVersion.Text = "Version:"
'
'txtVersion
'
Me.txtVersion.Location = New System.Drawing.Point(69, 71)
Me.txtVersion.Name = "txtVersion"
Me.txtVersion.Size = New System.Drawing.Size(459, 20)
Me.txtVersion.TabIndex = 18
Me.txtVersion.Size = New System.Drawing.Size(414, 20)
Me.txtVersion.TabIndex = 8
'
'txtCompany
'
Me.txtCompany.Location = New System.Drawing.Point(69, 45)
Me.txtCompany.Name = "txtCompany"
Me.txtCompany.Size = New System.Drawing.Size(459, 20)
Me.txtCompany.TabIndex = 17
Me.txtCompany.Size = New System.Drawing.Size(414, 20)
Me.txtCompany.TabIndex = 7
'
'lblCompany
'
@@ -375,34 +388,34 @@ Partial Class frmGameManager
Me.lblCompany.Location = New System.Drawing.Point(6, 48)
Me.lblCompany.Name = "lblCompany"
Me.lblCompany.Size = New System.Drawing.Size(54, 13)
Me.lblCompany.TabIndex = 17
Me.lblCompany.TabIndex = 1
Me.lblCompany.Text = "Company:"
'
'pbIcon
'
Me.pbIcon.InitialImage = Nothing
Me.pbIcon.Location = New System.Drawing.Point(480, 100)
Me.pbIcon.Location = New System.Drawing.Point(471, 97)
Me.pbIcon.Name = "pbIcon"
Me.pbIcon.Size = New System.Drawing.Size(48, 48)
Me.pbIcon.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom
Me.pbIcon.TabIndex = 15
Me.pbIcon.TabStop = False
'
'Label1
'lblIcon
'
Me.Label1.AutoSize = True
Me.Label1.Location = New System.Drawing.Point(6, 100)
Me.Label1.Name = "Label1"
Me.Label1.Size = New System.Drawing.Size(31, 13)
Me.Label1.TabIndex = 16
Me.Label1.Text = "Icon:"
Me.lblIcon.AutoSize = True
Me.lblIcon.Location = New System.Drawing.Point(6, 100)
Me.lblIcon.Name = "lblIcon"
Me.lblIcon.Size = New System.Drawing.Size(31, 13)
Me.lblIcon.TabIndex = 3
Me.lblIcon.Text = "Icon:"
'
'btnAppPathBrowse
'
Me.btnAppPathBrowse.Location = New System.Drawing.Point(498, 19)
Me.btnAppPathBrowse.Location = New System.Drawing.Point(489, 19)
Me.btnAppPathBrowse.Name = "btnAppPathBrowse"
Me.btnAppPathBrowse.Size = New System.Drawing.Size(30, 20)
Me.btnAppPathBrowse.TabIndex = 16
Me.btnAppPathBrowse.TabIndex = 6
Me.btnAppPathBrowse.Text = "..."
Me.btnAppPathBrowse.UseVisualStyleBackColor = True
'
@@ -412,15 +425,15 @@ Partial Class frmGameManager
Me.lblGamePath.Location = New System.Drawing.Point(6, 23)
Me.lblGamePath.Name = "lblGamePath"
Me.lblGamePath.Size = New System.Drawing.Size(63, 13)
Me.lblGamePath.TabIndex = 13
Me.lblGamePath.TabIndex = 0
Me.lblGamePath.Text = "Game Path:"
'
'txtAppPath
'
Me.txtAppPath.Location = New System.Drawing.Point(69, 19)
Me.txtAppPath.Name = "txtAppPath"
Me.txtAppPath.Size = New System.Drawing.Size(423, 20)
Me.txtAppPath.TabIndex = 15
Me.txtAppPath.Size = New System.Drawing.Size(414, 20)
Me.txtAppPath.TabIndex = 5
'
'nudHours
'
@@ -430,7 +443,7 @@ Partial Class frmGameManager
Me.nudHours.Maximum = New Decimal(New Integer() {10000, 0, 0, 0})
Me.nudHours.Name = "nudHours"
Me.nudHours.Size = New System.Drawing.Size(88, 20)
Me.nudHours.TabIndex = 21
Me.nudHours.TabIndex = 12
'
'lblHours
'
@@ -438,21 +451,23 @@ Partial Class frmGameManager
Me.lblHours.Location = New System.Drawing.Point(6, 126)
Me.lblHours.Name = "lblHours"
Me.lblHours.Size = New System.Drawing.Size(38, 13)
Me.lblHours.TabIndex = 0
Me.lblHours.TabIndex = 11
Me.lblHours.Text = "Hours:"
'
'btnTags
'
Me.btnTags.Location = New System.Drawing.Point(535, 360)
Me.btnTags.Location = New System.Drawing.Point(535, 336)
Me.btnTags.Name = "btnTags"
Me.btnTags.Size = New System.Drawing.Size(75, 23)
Me.btnTags.TabIndex = 22
Me.btnTags.TabIndex = 10
Me.btnTags.Text = "Tags..."
Me.btnTags.UseVisualStyleBackColor = True
'
'grpStats
'
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.txtRestorePath)
Me.grpStats.Controls.Add(Me.btnOpenRestorePath)
Me.grpStats.Controls.Add(Me.btnOpenBackupFile)
Me.grpStats.Controls.Add(Me.txtFileSize)
@@ -463,30 +478,45 @@ Partial Class frmGameManager
Me.grpStats.Controls.Add(Me.lblCurrentBackup)
Me.grpStats.Controls.Add(Me.txtLocalBackup)
Me.grpStats.Controls.Add(Me.lblLastBackup)
Me.grpStats.Location = New System.Drawing.Point(238, 390)
Me.grpStats.Location = New System.Drawing.Point(247, 365)
Me.grpStats.Name = "grpStats"
Me.grpStats.Size = New System.Drawing.Size(534, 129)
Me.grpStats.TabIndex = 10
Me.grpStats.Size = New System.Drawing.Size(525, 154)
Me.grpStats.TabIndex = 13
Me.grpStats.TabStop = False
Me.grpStats.Text = "Backup Information"
'
'lblRestorePath
'
Me.lblRestorePath.AutoSize = True
Me.lblRestorePath.Location = New System.Drawing.Point(6, 102)
Me.lblRestorePath.Name = "lblRestorePath"
Me.lblRestorePath.Size = New System.Drawing.Size(72, 13)
Me.lblRestorePath.TabIndex = 3
Me.lblRestorePath.Text = "Restore Path:"
'
'txtRestorePath
'
Me.txtRestorePath.Location = New System.Drawing.Point(96, 99)
Me.txtRestorePath.Name = "txtRestorePath"
Me.txtRestorePath.ReadOnly = True
Me.txtRestorePath.Size = New System.Drawing.Size(387, 20)
Me.txtRestorePath.TabIndex = 8
'
'btnOpenRestorePath
'
Me.btnOpenRestorePath.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnOpenRestorePath.Location = New System.Drawing.Point(336, 100)
Me.btnOpenRestorePath.Location = New System.Drawing.Point(339, 125)
Me.btnOpenRestorePath.Name = "btnOpenRestorePath"
Me.btnOpenRestorePath.Size = New System.Drawing.Size(114, 23)
Me.btnOpenRestorePath.TabIndex = 28
Me.btnOpenRestorePath.TabIndex = 12
Me.btnOpenRestorePath.Text = "O&pen Restore Path"
Me.btnOpenRestorePath.UseVisualStyleBackColor = True
'
'btnOpenBackupFile
'
Me.btnOpenBackupFile.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnOpenBackupFile.Location = New System.Drawing.Point(216, 100)
Me.btnOpenBackupFile.Location = New System.Drawing.Point(216, 125)
Me.btnOpenBackupFile.Name = "btnOpenBackupFile"
Me.btnOpenBackupFile.Size = New System.Drawing.Size(114, 23)
Me.btnOpenBackupFile.TabIndex = 27
Me.btnOpenBackupFile.TabIndex = 11
Me.btnOpenBackupFile.Text = "&Open Backup File"
Me.btnOpenBackupFile.UseVisualStyleBackColor = True
'
@@ -495,17 +525,16 @@ Partial Class frmGameManager
Me.txtFileSize.Location = New System.Drawing.Point(96, 74)
Me.txtFileSize.Name = "txtFileSize"
Me.txtFileSize.ReadOnly = True
Me.txtFileSize.Size = New System.Drawing.Size(275, 20)
Me.txtFileSize.TabIndex = 0
Me.txtFileSize.Size = New System.Drawing.Size(387, 20)
Me.txtFileSize.TabIndex = 7
Me.txtFileSize.TabStop = False
'
'btnDeleteBackup
'
Me.btnDeleteBackup.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnDeleteBackup.Location = New System.Drawing.Point(96, 100)
Me.btnDeleteBackup.Location = New System.Drawing.Point(96, 125)
Me.btnDeleteBackup.Name = "btnDeleteBackup"
Me.btnDeleteBackup.Size = New System.Drawing.Size(114, 23)
Me.btnDeleteBackup.TabIndex = 26
Me.btnDeleteBackup.TabIndex = 10
Me.btnDeleteBackup.Text = "&Delete Backup"
Me.btnDeleteBackup.UseVisualStyleBackColor = True
'
@@ -515,16 +544,16 @@ Partial Class frmGameManager
Me.lblFileSize.Location = New System.Drawing.Point(6, 77)
Me.lblFileSize.Name = "lblFileSize"
Me.lblFileSize.Size = New System.Drawing.Size(70, 13)
Me.lblFileSize.TabIndex = 108
Me.lblFileSize.TabIndex = 2
Me.lblFileSize.Text = "Backup Size:"
'
'lblSync
'
Me.lblSync.AutoSize = True
Me.lblSync.Location = New System.Drawing.Point(6, 105)
Me.lblSync.Location = New System.Drawing.Point(6, 130)
Me.lblSync.Name = "lblSync"
Me.lblSync.Size = New System.Drawing.Size(62, 13)
Me.lblSync.TabIndex = 24
Me.lblSync.TabIndex = 4
Me.lblSync.Text = "Up to Date!"
Me.lblSync.Visible = False
'
@@ -533,8 +562,8 @@ Partial Class frmGameManager
Me.txtCurrentBackup.Location = New System.Drawing.Point(96, 24)
Me.txtCurrentBackup.Name = "txtCurrentBackup"
Me.txtCurrentBackup.ReadOnly = True
Me.txtCurrentBackup.Size = New System.Drawing.Size(275, 20)
Me.txtCurrentBackup.TabIndex = 0
Me.txtCurrentBackup.Size = New System.Drawing.Size(387, 20)
Me.txtCurrentBackup.TabIndex = 5
Me.txtCurrentBackup.TabStop = False
'
'lblCurrentBackup
@@ -543,7 +572,7 @@ Partial Class frmGameManager
Me.lblCurrentBackup.Location = New System.Drawing.Point(6, 27)
Me.lblCurrentBackup.Name = "lblCurrentBackup"
Me.lblCurrentBackup.Size = New System.Drawing.Size(84, 13)
Me.lblCurrentBackup.TabIndex = 22
Me.lblCurrentBackup.TabIndex = 0
Me.lblCurrentBackup.Text = "Current Backup:"
'
'txtLocalBackup
@@ -551,8 +580,8 @@ Partial Class frmGameManager
Me.txtLocalBackup.Location = New System.Drawing.Point(96, 50)
Me.txtLocalBackup.Name = "txtLocalBackup"
Me.txtLocalBackup.ReadOnly = True
Me.txtLocalBackup.Size = New System.Drawing.Size(275, 20)
Me.txtLocalBackup.TabIndex = 0
Me.txtLocalBackup.Size = New System.Drawing.Size(387, 20)
Me.txtLocalBackup.TabIndex = 6
Me.txtLocalBackup.TabStop = False
'
'lblLastBackup
@@ -561,36 +590,36 @@ Partial Class frmGameManager
Me.lblLastBackup.Location = New System.Drawing.Point(6, 53)
Me.lblLastBackup.Name = "lblLastBackup"
Me.lblLastBackup.Size = New System.Drawing.Size(76, 13)
Me.lblLastBackup.TabIndex = 20
Me.lblLastBackup.TabIndex = 1
Me.lblLastBackup.Text = "Local Backup:"
'
'btnMarkAsRestored
'
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, 526)
Me.btnMarkAsRestored.Location = New System.Drawing.Point(429, 525)
Me.btnMarkAsRestored.Name = "btnMarkAsRestored"
Me.btnMarkAsRestored.Size = New System.Drawing.Size(100, 23)
Me.btnMarkAsRestored.TabIndex = 11
Me.btnMarkAsRestored.TabIndex = 14
Me.btnMarkAsRestored.Text = "&Mark as Restored"
Me.btnMarkAsRestored.UseVisualStyleBackColor = True
'
'btnRestore
'
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, 526)
Me.btnRestore.Location = New System.Drawing.Point(535, 525)
Me.btnRestore.Name = "btnRestore"
Me.btnRestore.Size = New System.Drawing.Size(75, 23)
Me.btnRestore.TabIndex = 12
Me.btnRestore.TabIndex = 15
Me.btnRestore.Text = "&Restore"
Me.btnRestore.UseVisualStyleBackColor = True
'
'btnSave
'
Me.btnSave.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnSave.Location = New System.Drawing.Point(616, 360)
Me.btnSave.Location = New System.Drawing.Point(616, 336)
Me.btnSave.Name = "btnSave"
Me.btnSave.Size = New System.Drawing.Size(75, 23)
Me.btnSave.TabIndex = 8
Me.btnSave.TabIndex = 11
Me.btnSave.Text = "&Save"
Me.btnSave.UseVisualStyleBackColor = True
'
@@ -600,53 +629,53 @@ Partial Class frmGameManager
Me.lstGames.Location = New System.Drawing.Point(12, 138)
Me.lstGames.Name = "lstGames"
Me.lstGames.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
Me.lstGames.Size = New System.Drawing.Size(220, 381)
Me.lstGames.Size = New System.Drawing.Size(228, 381)
Me.lstGames.Sorted = True
Me.lstGames.TabIndex = 1
'
'btnCancel
'
Me.btnCancel.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnCancel.Location = New System.Drawing.Point(697, 360)
Me.btnCancel.Location = New System.Drawing.Point(697, 336)
Me.btnCancel.Name = "btnCancel"
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
Me.btnCancel.TabIndex = 9
Me.btnCancel.TabIndex = 12
Me.btnCancel.Text = "&Cancel"
Me.btnCancel.UseVisualStyleBackColor = True
'
'chkEnabled
'
Me.chkEnabled.AutoSize = True
Me.chkEnabled.Location = New System.Drawing.Point(238, 365)
Me.chkEnabled.Location = New System.Drawing.Point(247, 340)
Me.chkEnabled.Name = "chkEnabled"
Me.chkEnabled.Size = New System.Drawing.Size(109, 17)
Me.chkEnabled.TabIndex = 6
Me.chkEnabled.TabIndex = 8
Me.chkEnabled.Text = "Monitor this game"
Me.chkEnabled.UseVisualStyleBackColor = True
'
'grpFilter
'
Me.grpFilter.Controls.Add(Me.optTag)
Me.grpFilter.Controls.Add(Me.optCustom)
Me.grpFilter.Controls.Add(Me.optBackupData)
Me.grpFilter.Controls.Add(Me.optPendingRestores)
Me.grpFilter.Controls.Add(Me.optAllGames)
Me.grpFilter.Location = New System.Drawing.Point(12, 12)
Me.grpFilter.Name = "grpFilter"
Me.grpFilter.Size = New System.Drawing.Size(220, 113)
Me.grpFilter.Size = New System.Drawing.Size(228, 113)
Me.grpFilter.TabIndex = 0
Me.grpFilter.TabStop = False
Me.grpFilter.Text = "Games Filter"
'
'optTag
'optCustom
'
Me.optTag.AutoSize = True
Me.optTag.Location = New System.Drawing.Point(6, 87)
Me.optTag.Name = "optTag"
Me.optTag.Size = New System.Drawing.Size(49, 17)
Me.optTag.TabIndex = 3
Me.optTag.TabStop = True
Me.optTag.Text = "Tags"
Me.optTag.UseVisualStyleBackColor = True
Me.optCustom.AutoSize = True
Me.optCustom.Location = New System.Drawing.Point(6, 87)
Me.optCustom.Name = "optCustom"
Me.optCustom.Size = New System.Drawing.Size(60, 17)
Me.optCustom.TabIndex = 3
Me.optCustom.TabStop = True
Me.optCustom.Text = "Custom"
Me.optCustom.UseVisualStyleBackColor = True
'
'optBackupData
'
@@ -664,10 +693,10 @@ Partial Class frmGameManager
Me.optPendingRestores.AutoSize = True
Me.optPendingRestores.Location = New System.Drawing.Point(6, 64)
Me.optPendingRestores.Name = "optPendingRestores"
Me.optPendingRestores.Size = New System.Drawing.Size(104, 17)
Me.optPendingRestores.Size = New System.Drawing.Size(122, 17)
Me.optPendingRestores.TabIndex = 2
Me.optPendingRestores.TabStop = True
Me.optPendingRestores.Text = "Pending Restore"
Me.optPendingRestores.Text = "New Saves Pending"
Me.optPendingRestores.UseVisualStyleBackColor = True
'
'optAllGames
@@ -681,11 +710,50 @@ Partial Class frmGameManager
Me.optAllGames.Text = "All"
Me.optAllGames.UseVisualStyleBackColor = True
'
'btnImport
'
Me.btnImport.Location = New System.Drawing.Point(84, 526)
Me.btnImport.Name = "btnImport"
Me.btnImport.Size = New System.Drawing.Size(75, 23)
Me.btnImport.TabIndex = 4
Me.btnImport.Text = "&Import"
Me.btnImport.UseVisualStyleBackColor = True
'
'btnExport
'
Me.btnExport.Location = New System.Drawing.Point(165, 526)
Me.btnExport.Name = "btnExport"
Me.btnExport.Size = New System.Drawing.Size(75, 23)
Me.btnExport.TabIndex = 5
Me.btnExport.Text = "&Export"
Me.btnExport.UseVisualStyleBackColor = True
'
'cmsImport
'
Me.cmsImport.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.cmsOfficial, Me.cmsFile})
Me.cmsImport.Name = "cmsImport"
Me.cmsImport.ShowImageMargin = False
Me.cmsImport.Size = New System.Drawing.Size(118, 48)
'
'cmsOfficial
'
Me.cmsOfficial.Name = "cmsOfficial"
Me.cmsOfficial.Size = New System.Drawing.Size(117, 22)
Me.cmsOfficial.Text = "&Official List..."
'
'cmsFile
'
Me.cmsFile.Name = "cmsFile"
Me.cmsFile.Size = New System.Drawing.Size(117, 22)
Me.cmsFile.Text = "&File..."
'
'frmGameManager
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(784, 561)
Me.Controls.Add(Me.btnExport)
Me.Controls.Add(Me.btnImport)
Me.Controls.Add(Me.grpFilter)
Me.Controls.Add(Me.btnTags)
Me.Controls.Add(Me.chkEnabled)
@@ -719,6 +787,7 @@ Partial Class frmGameManager
Me.grpStats.PerformLayout()
Me.grpFilter.ResumeLayout(False)
Me.grpFilter.PerformLayout()
Me.cmsImport.ResumeLayout(False)
Me.ResumeLayout(False)
Me.PerformLayout()
@@ -742,13 +811,11 @@ Partial Class frmGameManager
Friend WithEvents txtFileType As System.Windows.Forms.TextBox
Friend WithEvents btnSavePathBrowse As System.Windows.Forms.Button
Friend WithEvents btnProcessBrowse As System.Windows.Forms.Button
Friend WithEvents lblExclude As System.Windows.Forms.Label
Friend WithEvents lblFileType As System.Windows.Forms.Label
Friend WithEvents btnSave As System.Windows.Forms.Button
Friend WithEvents btnAppPathBrowse As System.Windows.Forms.Button
Friend WithEvents lblGamePath As System.Windows.Forms.Label
Friend WithEvents txtAppPath As System.Windows.Forms.TextBox
Friend WithEvents Label1 As System.Windows.Forms.Label
Friend WithEvents lblIcon As System.Windows.Forms.Label
Friend WithEvents pbIcon As System.Windows.Forms.PictureBox
Friend WithEvents lblVersion As System.Windows.Forms.Label
Friend WithEvents txtVersion As System.Windows.Forms.TextBox
@@ -781,5 +848,14 @@ Partial Class frmGameManager
Friend WithEvents btnOpenRestorePath As System.Windows.Forms.Button
Friend WithEvents btnTags As System.Windows.Forms.Button
Friend WithEvents lblTags As System.Windows.Forms.Label
Friend WithEvents optTag As System.Windows.Forms.RadioButton
Friend WithEvents optCustom As System.Windows.Forms.RadioButton
Friend WithEvents btnInclude As System.Windows.Forms.Button
Friend WithEvents btnExclude As System.Windows.Forms.Button
Friend WithEvents lblRestorePath As Label
Friend WithEvents txtRestorePath As TextBox
Friend WithEvents btnImport As System.Windows.Forms.Button
Friend WithEvents btnExport As System.Windows.Forms.Button
Friend WithEvents cmsImport As System.Windows.Forms.ContextMenuStrip
Friend WithEvents cmsOfficial As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents cmsFile As System.Windows.Forms.ToolStripMenuItem
End Class
+3
View File
@@ -117,4 +117,7 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="cmsImport.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
</root>
+292 -63
View File
@@ -1,4 +1,5 @@
Imports System.IO
Imports GBM.My.Resources
Imports System.IO
Public Class frmGameManager
@@ -16,6 +17,9 @@ Public Class frmGameManager
Private oRemoteBackupData As SortedList
Private bIsDirty As Boolean = False
Private bIsLoading As Boolean = False
Private oCurrentTagFilters As New List(Of clsTag)
Private oCurrentStringFilters As New Hashtable
Private eCurrentFilter As frmFilter.eFilterType = frmFilter.eFilterType.NoFilter
Private Enum eModes As Integer
View = 1
@@ -201,22 +205,27 @@ Public Class frmGameManager
End If
End Sub
Private Sub LoadData()
Private Sub LoadData(Optional ByVal bRetainFilter As Boolean = True)
Dim oRestoreData As New SortedList
Dim oGame As clsGame
Dim oBackup As clsBackup
Dim frm As frmFilter
Dim oFilters As New List(Of clsTag)
Dim eCurrentFilter As frmFilter.eFilterType = frmFilter.eFilterType.Any
If optTag.Checked Then
frm = New frmFilter
frm.ShowDialog()
oFilters = frm.Filters
eCurrentFilter = frm.FilterType
If optCustom.Checked Then
If Not bRetainFilter Then
frm = New frmFilter
frm.ShowDialog()
oCurrentTagFilters = frm.TagFilters
oCurrentStringFilters = frm.StringFilters
eCurrentFilter = frm.FilterType
End If
Else
oCurrentTagFilters.Clear()
oCurrentStringFilters.Clear()
eCurrentFilter = frmFilter.eFilterType.NoFilter
End If
AppData = mgrMonitorList.ReadFilteredList(oFilters, eCurrentFilter)
AppData = mgrMonitorList.ReadFilteredList(oCurrentTagFilters, oCurrentStringFilters, eCurrentFilter)
If optPendingRestores.Checked Then
oRestoreData = mgrRestore.CompareManifests
@@ -271,8 +280,8 @@ Public Class frmGameManager
End If
End If
sNewPath = mgrCommon.OpenFileBrowser("Choose exe file that starts the application", "exe", _
"Executable", sDefaultFolder, False)
sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseExe, "exe", _
frmGameManager_Executable, sDefaultFolder, False)
If sNewPath <> String.Empty Then
txtAppPath.Text = Path.GetDirectoryName(sNewPath)
@@ -292,7 +301,7 @@ Public Class frmGameManager
End If
End If
sNewPath = mgrCommon.OpenFolderBrowser("Choose the location of application's exe file:", sDefaultFolder, False)
sNewPath = mgrCommon.OpenFolderBrowser(frmGameManager_ChooseExePath, sDefaultFolder, False)
If sNewPath <> String.Empty Then txtAppPath.Text = sNewPath
End Sub
@@ -308,7 +317,7 @@ Public Class frmGameManager
End If
End If
sNewPath = mgrCommon.OpenFolderBrowser("Choose the application save folder:", sDefaultFolder, False)
sNewPath = mgrCommon.OpenFolderBrowser(frmGameManager_ChooseSaveFolder, sDefaultFolder, False)
If sNewPath <> String.Empty Then
txtSavePath.Text = sNewPath
@@ -327,8 +336,8 @@ Public Class frmGameManager
End If
End If
sNewPath = mgrCommon.OpenFileBrowser("Choose a custom icon for the application", "ico", _
"Icon", sDefaultFolder, False)
sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseCustomIcon, "ico", _
frmGameManager_Icon, sDefaultFolder, False)
If sNewPath <> String.Empty Then
txtIcon.Text = sNewPath
@@ -341,7 +350,7 @@ Public Class frmGameManager
Private Function HandleDirty() As MsgBoxResult
Dim oResult As MsgBoxResult
oResult = MsgBox("There are unsaved changes on this form. Do you want to save?", MsgBoxStyle.YesNoCancel, "Game Backup Monitor")
oResult = mgrCommon.ShowMessage(App_ConfirmDirty, MsgBoxStyle.YesNoCancel)
Select Case oResult
Case MsgBoxResult.Yes
@@ -365,12 +374,16 @@ Public Class frmGameManager
lstGames.ValueMember = "Key"
lstGames.DisplayMember = "Value"
lstGames.BeginUpdate()
For Each de As DictionaryEntry In AppData
oApp = DirectCast(de.Value, clsGame)
oData = New KeyValuePair(Of String, String)(oApp.ID, oApp.Name)
lstGames.Items.Add(oData)
Next
lstGames.EndUpdate()
IsLoading = False
End Sub
@@ -381,11 +394,56 @@ Public Class frmGameManager
If File.Exists(sFileName) Then
Process.Start("explorer.exe", "/select," & sFileName)
Else
MsgBox("The backup file does not exist.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmGameManager_ErrorNoBackupExists, MsgBoxStyle.Exclamation)
End If
End Sub
Private Sub UpdateBuilderButtonLabel(ByVal sBuilderString As String, ByVal sLabel As String, ByVal btn As Button, ByVal bDirty As Boolean)
Dim iCount As Integer = sBuilderString.Split(":").Length
If sBuilderString <> String.Empty And iCount > 0 Then
btn.Text = sLabel & " " & mgrCommon.FormatString(frmGameManager_ItemsExist, iCount)
Else
btn.Text = sLabel & " " & frmGameManager_Items
End If
If bDirty Then
btn.Font = New Font(FontFamily.GenericSansSerif, 8.25, FontStyle.Bold)
Else
btn.Font = New Font(FontFamily.GenericSansSerif, 8.25, FontStyle.Regular)
End If
End Sub
Private Function GetBuilderRoot() As String
Dim sRoot As String = String.Empty
If Path.IsPathRooted(txtSavePath.Text) Then
If Directory.Exists(txtSavePath.Text) Then
sRoot = txtSavePath.Text
End If
Else
If txtAppPath.Text <> String.Empty Then
If Directory.Exists(txtAppPath.Text & "\" & txtSavePath.Text) Then
sRoot = txtAppPath.Text & "\" & txtSavePath.Text
End If
End If
End If
Return sRoot
End Function
Private Sub OpenBuilder(ByVal sFormText As String, ByRef txtBox As TextBox)
Dim frm As New frmIncludeExclude
frm.FormName = sFormText
frm.BuilderString = txtBox.Text
frm.RootFolder = GetBuilderRoot()
frm.ShowDialog()
txtBox.Text = frm.BuilderString
End Sub
Private Function FindRestorePath() As Boolean
Dim sProcess As String
Dim sRestorePath As String
@@ -396,8 +454,8 @@ Public Class frmGameManager
CurrentBackupItem.RelativeRestorePath = CurrentGame.ProcessPath & "\" & CurrentBackupItem.RestorePath
Else
sProcess = CurrentGame.TrueProcess
If CurrentGame.Duplicate = True Or CurrentGame.ProcessName.Contains("dosbox") Then bNoAuto = True
sRestorePath = mgrPath.ProcessPathSearch(CurrentBackupItem.Name, sProcess, CurrentBackupItem.Name & " uses a relative path and the game path has not been set.", bNoAuto)
If mgrCommon.IsProcessNotSearchable(CurrentGame) Then bNoAuto = True
sRestorePath = mgrPath.ProcessPathSearch(CurrentBackupItem.Name, sProcess, mgrCommon.FormatString(frmGameManager_ErrorPathNotSet, CurrentBackupItem.Name), bNoAuto)
If sRestorePath <> String.Empty Then
CurrentBackupItem.RelativeRestorePath = sRestorePath & "\" & CurrentBackupItem.RestorePath
@@ -425,7 +483,7 @@ Public Class frmGameManager
If Directory.Exists(sPath) Then
Process.Start("explorer.exe", sPath)
Else
MsgBox("The restore path does not exist.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmGameManager_ErrorNoRestorePathExists, MsgBoxStyle.Exclamation)
End If
End Sub
@@ -443,7 +501,18 @@ Public Class frmGameManager
frm.IDList = sMonitorIDs
frm.GameName = CurrentGame.Name
frm.ShowDialog()
FillTags(CurrentGame.ID)
'Only update visible tags if one item is selected
If lstGames.SelectedItems.Count = 1 Then FillTags(CurrentGame.ID)
'If a tag filter is enabled, reload list to reflect changes
If optCustom.Checked Then
LoadData()
End If
'If the selected game(s) no longer match the filter, disable the form
If lstGames.SelectedIndex = -1 Then eCurrentMode = eModes.Disabled
ModeChange()
End Sub
Private Sub GetBackupInfo(ByVal oApp As clsGame)
@@ -454,7 +523,7 @@ Public Class frmGameManager
If oRemoteBackupData.Contains(oApp.Name) Then
CurrentBackupItem = DirectCast(oRemoteBackupData(oApp.Name), clsBackup)
txtCurrentBackup.Text = CurrentBackupItem.DateUpdated & " by " & CurrentBackupItem.UpdatedBy
txtCurrentBackup.Text = mgrCommon.FormatString(frmGameManager_BackupTimeAndName, New String() {CurrentBackupItem.DateUpdated, CurrentBackupItem.UpdatedBy})
sFileName = BackupFolder & CurrentBackupItem.FileName
btnOpenBackupFile.Enabled = True
@@ -466,16 +535,18 @@ Public Class frmGameManager
oFileInfo = New FileInfo(sFileName)
dFileSize = oFileInfo.Length
If dFileSize > 1048576 Then
txtFileSize.Text = Math.Round(dFileSize / 1048576, 2) & " MB"
txtFileSize.Text = mgrCommon.FormatString(App_MB, Math.Round(dFileSize / 1048576, 2).ToString)
Else
txtFileSize.Text = Math.Round(dFileSize / 1024, 2) & " KB"
txtFileSize.Text = mgrCommon.FormatString(App_KB, Math.Round(dFileSize / 1024, 2).ToString)
End If
Else
txtFileSize.Text = "Backup file was not found!"
txtFileSize.Text = frmGameManager_ErrorNoBackupExists
End If
txtRestorePath.Text = CurrentBackupItem.RestorePath
Else
txtCurrentBackup.Text = "Never"
txtCurrentBackup.Text = frmGameManager_Never
txtFileSize.Text = String.Empty
txtRestorePath.Text = String.Empty
btnOpenBackupFile.Enabled = False
btnOpenRestorePath.Enabled = False
btnRestore.Enabled = False
@@ -484,22 +555,25 @@ Public Class frmGameManager
If oLocalBackupData.Contains(oApp.Name) Then
oBackupInfo = DirectCast(oLocalBackupData(oApp.Name), clsBackup)
txtLocalBackup.Text = oBackupInfo.DateUpdated & " by " & oBackupInfo.UpdatedBy
txtLocalBackup.Text = mgrCommon.FormatString(frmGameManager_BackupTimeAndName, New String() {oBackupInfo.DateUpdated, oBackupInfo.UpdatedBy})
Else
txtLocalBackup.Text = "Never"
txtLocalBackup.Text = frmGameManager_Never
End If
If txtCurrentBackup.Text = "Never" And txtLocalBackup.Text = "Never" Then
If txtCurrentBackup.Text = frmGameManager_Never And txtLocalBackup.Text = frmGameManager_Never Then
lblSync.Visible = False
btnMarkAsRestored.Enabled = False
ElseIf txtCurrentBackup.Text = frmGameManager_Never And txtLocalBackup.Text <> frmGameManager_Never Then
lblSync.Visible = False
btnMarkAsRestored.Enabled = False
ElseIf txtCurrentBackup.Text <> txtLocalBackup.Text Then
lblSync.ForeColor = Color.Red
lblSync.Text = "Out of Sync!"
lblSync.Text = frmGameManager_OutofSync
lblSync.Visible = True
btnMarkAsRestored.Enabled = True
Else
lblSync.ForeColor = Color.Green
lblSync.Text = "Up to Date!"
lblSync.Text = frmGameManager_UpToDate
lblSync.Visible = True
btnMarkAsRestored.Enabled = False
End If
@@ -510,8 +584,7 @@ Public Class frmGameManager
Dim oDir As DirectoryInfo
Dim sSubDir As String
If MsgBox("This will delete the backup file and all records of this backup. This cannot be undone. " & vbCrLf & vbCrLf & "Do you want to remove the data for " _
& CurrentBackupItem.Name & "?", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(frmGameManager_ConfirmBackupDelete, CurrentBackupItem.Name, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
mgrManifest.DoManifestDelete(CurrentBackupItem, mgrSQLite.Database.Local)
mgrManifest.DoManifestDelete(CurrentBackupItem, mgrSQLite.Database.Remote)
@@ -528,9 +601,7 @@ Public Class frmGameManager
oDir = New DirectoryInfo(sSubDir)
If oDir.GetDirectories.Length > 0 Or oDir.GetFiles.Length > 0 Then
'Confirm
If MsgBox("The backup folder " & sSubDir & " still contains " & oDir.GetDirectories.Length & " directories and " & _
oDir.GetFiles.Length & " files." & vbCrLf & vbCrLf & "Do you want to delete the contents and remove the sub-folder for this game?", _
MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(frmGameManager_ConfirmBackupFolderDelete, New String() {sSubDir, oDir.GetDirectories.Length, oDir.GetFiles.Length}, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
If Directory.Exists(sSubDir) Then Directory.Delete(sSubDir, True)
End If
Else
@@ -570,6 +641,10 @@ Public Class frmGameManager
chkEnabled.Checked = oApp.Enabled
chkMonitorOnly.Checked = oApp.MonitorOnly
'Update Buttons
UpdateBuilderButtonLabel(oApp.FileType, frmGameManager_IncludeShortcut, btnInclude, False)
UpdateBuilderButtonLabel(oApp.ExcludeList, frmGameManager_ExcludeShortcut, btnExclude, False)
'Extra
txtAppPath.Text = oApp.ProcessPath
txtCompany.Text = oApp.Company
@@ -582,7 +657,7 @@ Public Class frmGameManager
If IO.File.Exists(oApp.Icon) Then
pbIcon.Image = Image.FromFile(oApp.Icon)
Else
pbIcon.Image = My.Resources.Unknown
pbIcon.Image = Icon_Unknown
End If
'Stats
@@ -634,6 +709,9 @@ Public Class frmGameManager
AddHandler DirectCast(ctl, NumericUpDown).ValueChanged, AddressOf DirtyCheck_ValueChanged
End If
Next
'Exemptions
RemoveHandler txtRestorePath.TextChanged, AddressOf DirtyCheck_ValueChanged
End Sub
Private Sub AssignDirtyHandlersMisc()
@@ -667,7 +745,7 @@ Public Class frmGameManager
WipeControls(grpConfig.Controls)
WipeControls(grpExtra.Controls)
WipeControls(grpStats.Controls)
pbIcon.Image = My.Resources.Unknown
pbIcon.Image = Icon_Unknown
chkEnabled.Enabled = True
chkMonitorOnly.Enabled = True
btnSave.Enabled = True
@@ -685,6 +763,10 @@ Public Class frmGameManager
chkMonitorOnly.Checked = False
btnTags.Enabled = False
lblTags.Visible = False
btnInclude.Text = frmGameManager_btnInclude
btnExclude.Text = frmGameManager_btnExclude
btnImport.Enabled = False
btnExport.Enabled = False
Case eModes.Edit
grpFilter.Enabled = False
lstGames.Enabled = False
@@ -705,6 +787,8 @@ Public Class frmGameManager
btnOpenRestorePath.Enabled = False
btnTags.Enabled = True
lblTags.Visible = True
btnImport.Enabled = False
btnExport.Enabled = False
Case eModes.View
grpFilter.Enabled = True
lstGames.Enabled = True
@@ -720,6 +804,8 @@ Public Class frmGameManager
btnBackup.Enabled = True
btnTags.Enabled = True
lblTags.Visible = True
btnImport.Enabled = True
btnExport.Enabled = True
Case eModes.ViewTemp
grpFilter.Enabled = True
lstGames.Enabled = True
@@ -735,14 +821,17 @@ Public Class frmGameManager
btnBackup.Enabled = False
btnTags.Enabled = False
lblTags.Visible = False
btnInclude.Text = frmGameManager_btnInclude
btnExclude.Text = frmGameManager_btnExclude
btnImport.Enabled = True
btnExport.Enabled = True
Case eModes.Disabled
grpFilter.Enabled = True
lstGames.Enabled = True
WipeControls(grpConfig.Controls)
WipeControls(grpExtra.Controls)
WipeControls(grpStats.Controls)
pbIcon.Image = My.Resources.Unknown
lblTags.Text = String.Empty
pbIcon.Image = Icon_Unknown
lblSync.Visible = False
btnSave.Enabled = False
btnCancel.Enabled = False
@@ -757,12 +846,17 @@ Public Class frmGameManager
btnRestore.Enabled = False
btnMarkAsRestored.Enabled = False
btnTags.Enabled = False
lblTags.Visible = False
btnInclude.Text = frmGameManager_btnInclude
btnExclude.Text = frmGameManager_btnExclude
btnImport.Enabled = True
btnExport.Enabled = True
Case eModes.MultiSelect
lstGames.Enabled = True
WipeControls(grpConfig.Controls)
WipeControls(grpExtra.Controls)
WipeControls(grpStats.Controls)
pbIcon.Image = My.Resources.Unknown
pbIcon.Image = Icon_Unknown
lblSync.Visible = False
btnSave.Enabled = True
btnCancel.Enabled = False
@@ -779,8 +873,13 @@ Public Class frmGameManager
btnRestore.Enabled = True
btnMarkAsRestored.Enabled = True
btnTags.Enabled = True
lblTags.Visible = False
btnImport.Enabled = True
btnExport.Enabled = True
End Select
lstGames.Focus()
IsLoading = False
End Sub
@@ -875,13 +974,11 @@ Public Class frmGameManager
End If
Case eModes.MultiSelect
Dim sMonitorIDs As New List(Of String)
Dim sChanges As String
For Each oData In lstGames.SelectedItems
sMonitorIDs.Add(AppData(oData.Key))
Next
sChanges = vbCrLf & vbCrLf & "Monitor this game: " & mgrCommon.BooleanYesNo(oApp.Enabled) & vbCrLf & "Monitor only (No backup): " & mgrCommon.BooleanYesNo(oApp.MonitorOnly)
If MsgBox("Are you sure you want to save the following changes to " & sMonitorIDs.Count & " selected games?" & sChanges, MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(frmGameManager_ConfirmMultiSave, New String() {sMonitorIDs.Count, mgrCommon.BooleanYesNo(oApp.Enabled), mgrCommon.BooleanYesNo(oApp.MonitorOnly)}, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
bSuccess = True
mgrMonitorList.DoListUpdateMulti(sMonitorIDs, oApp)
eCurrentMode = eModes.Disabled
@@ -907,7 +1004,7 @@ Public Class frmGameManager
oData = lstGames.SelectedItems(0)
oApp = DirectCast(AppData(oData.Key), clsGame)
If MsgBox("Are you sure you want to delete " & oApp.Name & "? This cannot be undone." & vbCrLf & vbCrLf & "This will not delete any backup files that already exist for this game.", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(frmGameManager_ConfirmGameDelete, oApp.Name, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
mgrMonitorList.DoListDelete(oApp.ID)
LoadData()
eCurrentMode = eModes.Disabled
@@ -921,7 +1018,7 @@ Public Class frmGameManager
sMonitorIDs.Add(oApp.ID)
Next
If MsgBox("Are you sure you want to delete the " & sMonitorIDs.Count & " selected games? This cannot be undone.", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(frmGameManager_ConfirmMultiGameDelete, sMonitorIDs.Count, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
mgrMonitorList.DoListDeleteMulti(sMonitorIDs)
LoadData()
eCurrentMode = eModes.Disabled
@@ -943,19 +1040,25 @@ Public Class frmGameManager
Private Function CoreValidatation(ByVal oApp As clsGame) As Boolean
If txtName.Text = String.Empty Then
MsgBox("You must enter a valid application name.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmGameManager_ErrorValidName, MsgBoxStyle.Exclamation)
txtName.Focus()
Return False
End If
If txtProcess.Text = String.Empty Then
MsgBox("You must enter a valid process name.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmGameManager_ErrorValidProcess, MsgBoxStyle.Exclamation)
txtProcess.Focus()
Return False
End If
If chkFolderSave.Checked = False And txtFileType.Text = String.Empty Then
mgrCommon.ShowMessage(frmGameManager_ErrorNoItems, MsgBoxStyle.Exclamation)
btnInclude.Focus()
Return False
End If
If mgrMonitorList.DoDuplicateListCheck(oApp.Name, oApp.ProcessName, , oApp.ID) Then
MsgBox("A game with this exact name and process already exists.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmGameManager_ErrorGameDupe, MsgBoxStyle.Exclamation)
txtName.Focus()
Return False
End If
@@ -978,7 +1081,7 @@ Public Class frmGameManager
Next
If oMarkList.Count = 1 Then
If MsgBox("Do you want to mark " & oMarkList(0).Name & " as restored? This cannot be undone.", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(frmGameManager_ConfirmMark, oMarkList(0).Name, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
bWasUpdated = True
If mgrManifest.DoManifestCheck(oMarkList(0).Name, mgrSQLite.Database.Local) Then
mgrManifest.DoManifestUpdate(oMarkList(0), mgrSQLite.Database.Local)
@@ -987,7 +1090,7 @@ Public Class frmGameManager
End If
End If
ElseIf oMarkList.Count > 1 Then
If MsgBox("Do you want to mark " & oMarkList.Count & " games as restored? This cannot be undone.", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(frmGameManager_ConfirmMultiMark, oMarkList.Count, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
bWasUpdated = True
For Each oGameBackup In oMarkList
If mgrManifest.DoManifestCheck(oGameBackup.Name, mgrSQLite.Database.Local) Then
@@ -998,7 +1101,7 @@ Public Class frmGameManager
Next
End If
Else
MsgBox("The selected game(s) have no backup data.", MsgBoxStyle.Information, "Game Backup Monitor")
mgrCommon.ShowMessage(frmGameManager_ErrorNoBackupData, MsgBoxStyle.Information)
End If
'Don't bother updating unless we actually did something
@@ -1032,12 +1135,12 @@ Public Class frmGameManager
Next
If BackupList.Count = 1 Then
sMsg = "Are you sure you want to run a backup for " & BackupList(0).Name & "? This will close the form."
sMsg = mgrCommon.FormatString(frmGameManager_ConfirmBackup, BackupList(0).Name)
ElseIf BackupList.Count > 1 Then
sMsg = "Are you sure you want to run a backup for " & BackupList.Count & " games? This will close the form."
sMsg = mgrCommon.FormatString(frmGameManager_ConfirmMultiBackup, BackupList.Count)
End If
If MsgBox(sMsg, MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(sMsg, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
TriggerBackup = True
Me.Close()
End If
@@ -1064,20 +1167,20 @@ Public Class frmGameManager
If RestoreList.Count = 1 Then
bDoRestore = True
If Not mgrRestore.CheckManifest(RestoreList(0).Name) Then
sMsg = RestoreList(0).Name & " is already up to date." & vbCrLf & vbCrLf & "Would you like to restore this backup anyway?"
sMsg = mgrCommon.FormatString(frmGameManager_ConfirmRestoreAnyway, RestoreList(0).Name)
Else
sMsg = "Are you sure you want to restore the backup for " & RestoreList(0).Name & "? This will close the form."
sMsg = mgrCommon.FormatString(frmGameManager_ConfirmRestore, RestoreList(0).Name)
End If
ElseIf RestoreList.Count > 1 Then
bDoRestore = True
sMsg = "Are you sure you want to restore the backups for " & RestoreList.Count & " games? This will close the form."
sMsg = mgrCommon.FormatString(frmGameManager_ConfirmMultiRestore, RestoreList.Count)
Else
MsgBox("The selected game(s) have no backup data.", MsgBoxStyle.Information, "Game Backup Monitor")
mgrCommon.ShowMessage(frmGameManager_ErrorNoBackupData, MsgBoxStyle.Information)
End If
'We need this check in case a bunch of games with no backups are multi-selected
If bDoRestore Then
If MsgBox(sMsg, MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(sMsg, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
TriggerRestore = True
Me.Close()
End If
@@ -1085,7 +1188,95 @@ Public Class frmGameManager
End If
End Sub
Private Sub ImportGameListFile()
Dim sLocation As String
sLocation = mgrCommon.OpenFileBrowser(frmGameManager_ChooseImportXML, "xml", frmGameManager_XML, Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments), False)
If sLocation <> String.Empty Then
If mgrMonitorList.DoImport(sLocation) Then
LoadData()
End If
End If
End Sub
Private Sub ExportGameList()
Dim sLocation As String
sLocation = mgrCommon.SaveFileBrowser(frmGameManager_ChooseExportXML, "xml", frmGameManager_XML, Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments), "Game Backup Monitor Export " & Date.Now.ToString("dd-MMM-yyyy"))
If sLocation <> String.Empty Then
mgrMonitorList.ExportMonitorList(sLocation)
End If
End Sub
Private Sub ImportOfficialGameList()
If mgrCommon.ShowMessage(frmGameManager_ConfirmOfficialImport, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
If mgrMonitorList.DoImport(App_URLImport) Then
LoadData()
End If
End If
End Sub
Private Sub SetForm()
'Set Form Name
Me.Name = frmGameManager_FormName
'Set Form text
grpFilter.Text = frmGameManager_grpFilter
grpConfig.Text = frmGameManager_grpConfig
grpExtra.Text = frmGameManager_grpExtra
grpStats.Text = frmGameManager_grpStats
btnExport.Text = frmGameManager_btnExport
btnImport.Text = frmGameManager_btnImport
optCustom.Text = frmGameManager_optCustom
optBackupData.Text = frmGameManager_optBackupData
optPendingRestores.Text = frmGameManager_optPendingRestores
optAllGames.Text = frmGameManager_optAllGames
btnTags.Text = frmGameManager_btnTags
chkEnabled.Text = frmGameManager_chkEnabled
btnCancel.Text = frmGameManager_btnCancel
chkMonitorOnly.Text = frmGameManager_chkMonitorOnly
btnMarkAsRestored.Text = frmGameManager_btnMarkAsRestored
btnRestore.Text = frmGameManager_btnRestore
btnSave.Text = frmGameManager_btnSave
lblRestorePath.Text = frmGameManager_lblRestorePath
btnOpenRestorePath.Text = frmGameManager_btnOpenRestorePath
btnOpenBackupFile.Text = frmGameManager_btnOpenBackupFile
btnDeleteBackup.Text = frmGameManager_btnDeleteBackup
lblFileSize.Text = frmGameManager_lblFileSize
lblCurrentBackup.Text = frmGameManager_lblCurrentBackup
lblLastBackup.Text = frmGameManager_lblLastBackup
btnIconBrowse.Text = frmGameManager_btnIconBrowse
lblVersion.Text = frmGameManager_lblVersion
lblCompany.Text = frmGameManager_lblCompany
lblIcon.Text = frmGameManager_lblIcon
btnAppPathBrowse.Text = frmGameManager_btnAppPathBrowse
lblGamePath.Text = frmGameManager_lblGamePath
lblHours.Text = frmGameManager_lblHours
btnExclude.Text = frmGameManager_btnExclude
btnInclude.Text = frmGameManager_btnInclude
btnSavePathBrowse.Text = frmGameManager_btnSavePathBrowse
btnProcessBrowse.Text = frmGameManager_btnProcessBrowse
lblSavePath.Text = frmGameManager_lblSavePath
lblProcess.Text = frmGameManager_lblProcess
lblName.Text = frmGameManager_lblName
chkTimeStamp.Text = frmGameManager_chkTimeStamp
chkFolderSave.Text = frmGameManager_chkFolderSave
btnBackup.Text = frmGameManager_btnBackup
btnClose.Text = frmGameManager_btnClose
btnDelete.Text = frmGameManager_btnDelete
btnAdd.Text = frmGameManager_btnAdd
cmsOfficial.Text = frmGameManager_cmsOfficial
cmsFile.Text = frmGameManager_cmsFile
End Sub
Private Sub frmGameManager_Load(sender As Object, e As EventArgs) Handles MyBase.Load
SetForm()
If DisableExternalFunctions Then
btnBackup.Visible = False
@@ -1192,12 +1383,50 @@ Public Class frmGameManager
TriggerSelectedRestore()
End Sub
Private Sub optGamesFilter_Click(sender As Object, e As EventArgs) Handles optPendingRestores.Click, optAllGames.Click, optBackupData.Click, optTag.Click
Private Sub optGamesFilter_Click(sender As Object, e As EventArgs) Handles optPendingRestores.Click, optAllGames.Click, optBackupData.Click, optCustom.Click
lstGames.ClearSelected()
eCurrentMode = eModes.Disabled
ModeChange()
LoadData()
LoadData(False)
End Sub
Private Sub btnInclude_Click(sender As Object, e As EventArgs) Handles btnInclude.Click
Dim sInclude As String = txtFileType.Text
OpenBuilder(frmGameManager_Include, txtFileType)
UpdateBuilderButtonLabel(txtFileType.Text, frmGameManager_IncludeShortcut, btnInclude, (sInclude <> txtFileType.Text))
End Sub
Private Sub btnExclude_Click(sender As Object, e As EventArgs) Handles btnExclude.Click
Dim sExclude As String = txtExclude.Text
OpenBuilder(frmGameManager_Exclude, txtExclude)
UpdateBuilderButtonLabel(txtExclude.Text, frmGameManager_ExcludeShortcut, btnExclude, (sExclude <> txtExclude.Text))
End Sub
Private Sub chkFolderSave_CheckedChanged(sender As Object, e As EventArgs) Handles chkFolderSave.CheckedChanged
If chkFolderSave.Checked Then
btnInclude.Enabled = False
If txtFileType.Text <> String.Empty Then
txtFileType.Text = String.Empty
UpdateBuilderButtonLabel(txtFileType.Text, frmGameManager_IncludeShortcut, btnInclude, False)
End If
Else
btnInclude.Enabled = True
End If
End Sub
Private Sub btnImport_Click(sender As Object, e As EventArgs) Handles btnImport.Click
cmsImport.Show(btnImport, New Drawing.Point(70, 11), ToolStripDropDownDirection.AboveRight)
End Sub
Private Sub cmsOfficial_Click(sender As Object, e As EventArgs) Handles cmsOfficial.Click
ImportOfficialGameList()
End Sub
Private Sub cmsFile_Click(sender As Object, e As EventArgs) Handles cmsFile.Click
ImportGameListFile()
End Sub
Private Sub btnExport_Click(sender As Object, e As EventArgs) Handles btnExport.Click
ExportGameList()
End Sub
End Class
+4 -2
View File
@@ -39,6 +39,7 @@ Partial Class frmGameTags
Me.lstTags.Name = "lstTags"
Me.lstTags.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
Me.lstTags.Size = New System.Drawing.Size(150, 199)
Me.lstTags.Sorted = True
Me.lstTags.TabIndex = 0
'
'lstGameTags
@@ -48,6 +49,7 @@ Partial Class frmGameTags
Me.lstGameTags.Name = "lstGameTags"
Me.lstGameTags.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
Me.lstGameTags.Size = New System.Drawing.Size(150, 199)
Me.lstGameTags.Sorted = True
Me.lstGameTags.TabIndex = 3
'
'btnAdd
@@ -56,7 +58,7 @@ Partial Class frmGameTags
Me.btnAdd.Name = "btnAdd"
Me.btnAdd.Size = New System.Drawing.Size(48, 23)
Me.btnAdd.TabIndex = 1
Me.btnAdd.Text = "> >"
Me.btnAdd.Text = ">"
Me.btnAdd.UseVisualStyleBackColor = True
'
'btnRemove
@@ -65,7 +67,7 @@ Partial Class frmGameTags
Me.btnRemove.Name = "btnRemove"
Me.btnRemove.Size = New System.Drawing.Size(48, 23)
Me.btnRemove.TabIndex = 2
Me.btnRemove.Text = "< <"
Me.btnRemove.Text = "<"
Me.btnRemove.UseVisualStyleBackColor = True
'
'lblTags
+15 -3
View File
@@ -1,4 +1,6 @@
Public Class frmGameTags
Imports GBM.My.Resources
Public Class frmGameTags
Dim sMonitorIDs As List(Of String)
Dim sGameName As String = String.Empty
@@ -160,11 +162,21 @@
End Sub
Private Sub SetForm()
'Set Form Name
If IDList.Count > 1 Then
Me.Text = "Edit Tags for Multiple Games"
Me.Text = frmGameTags_FormNameMulti
Else
Me.Text = "Edit Tags for " & GameName
Me.Text = mgrCommon.FormatString(frmGameTags_FormNameSingle, GameName)
End If
'Set Form Text
btnOpenTags.Text = frmGameTags_btnOpenTags
btnClose.Text = frmGameTags_btnClose
lblGameTags.Text = frmGameTags_lblGameTags
lblTags.Text = frmGameTags_lblTags
btnRemove.Text = frmGameTags_btnRemove
btnAdd.Text = frmGameTags_btnAdd
End Sub
Private Sub frmGameTags_Load(sender As Object, e As EventArgs) Handles MyBase.Load
+278
View File
@@ -0,0 +1,278 @@
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
Partial Class frmIncludeExclude
Inherits System.Windows.Forms.Form
'Form overrides dispose to clean up the component list.
<System.Diagnostics.DebuggerNonUserCode()> _
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
Try
If disposing AndAlso components IsNot Nothing Then
components.Dispose()
End If
Finally
MyBase.Dispose(disposing)
End Try
End Sub
'Required by the Windows Form Designer
Private components As System.ComponentModel.IContainer
'NOTE: The following procedure is required by the Windows Form Designer
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Me.components = New System.ComponentModel.Container()
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmIncludeExclude))
Me.treFiles = New System.Windows.Forms.TreeView()
Me.imgIcons = New System.Windows.Forms.ImageList(Me.components)
Me.btnSave = New System.Windows.Forms.Button()
Me.btnCancel = New System.Windows.Forms.Button()
Me.txtRootFolder = New System.Windows.Forms.TextBox()
Me.btnBrowse = New System.Windows.Forms.Button()
Me.lstBuilder = New System.Windows.Forms.ListView()
Me.cmsItems = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.cmsEdit = New System.Windows.Forms.ToolStripMenuItem()
Me.cmsRemove = New System.Windows.Forms.ToolStripMenuItem()
Me.cmsAdd = New System.Windows.Forms.ToolStripMenuItem()
Me.btnRemove = New System.Windows.Forms.Button()
Me.btnAdd = New System.Windows.Forms.Button()
Me.grpFileOptions = New System.Windows.Forms.GroupBox()
Me.optFileTypes = New System.Windows.Forms.RadioButton()
Me.optIndividualFiles = New System.Windows.Forms.RadioButton()
Me.lblItems = New System.Windows.Forms.Label()
Me.btnRawEdit = New System.Windows.Forms.Button()
Me.lblSaveFolder = New System.Windows.Forms.Label()
Me.ttWarning = New System.Windows.Forms.ToolTip(Me.components)
Me.cmsItems.SuspendLayout()
Me.grpFileOptions.SuspendLayout()
Me.SuspendLayout()
'
'treFiles
'
Me.treFiles.CheckBoxes = True
Me.treFiles.ImageIndex = 0
Me.treFiles.ImageList = Me.imgIcons
Me.treFiles.Location = New System.Drawing.Point(12, 64)
Me.treFiles.Name = "treFiles"
Me.treFiles.SelectedImageIndex = 0
Me.treFiles.Size = New System.Drawing.Size(250, 333)
Me.treFiles.TabIndex = 1
'
'imgIcons
'
Me.imgIcons.ImageStream = CType(resources.GetObject("imgIcons.ImageStream"), System.Windows.Forms.ImageListStreamer)
Me.imgIcons.TransparentColor = System.Drawing.Color.Transparent
Me.imgIcons.Images.SetKeyName(0, "folder.ico")
Me.imgIcons.Images.SetKeyName(1, "file.ico")
Me.imgIcons.Images.SetKeyName(2, "type.ico")
'
'btnSave
'
Me.btnSave.Location = New System.Drawing.Point(416, 426)
Me.btnSave.Name = "btnSave"
Me.btnSave.Size = New System.Drawing.Size(75, 23)
Me.btnSave.TabIndex = 7
Me.btnSave.Text = "&Save"
Me.btnSave.UseVisualStyleBackColor = True
'
'btnCancel
'
Me.btnCancel.Location = New System.Drawing.Point(497, 426)
Me.btnCancel.Name = "btnCancel"
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
Me.btnCancel.TabIndex = 8
Me.btnCancel.Text = "&Cancel"
Me.btnCancel.UseVisualStyleBackColor = True
'
'txtRootFolder
'
Me.txtRootFolder.Location = New System.Drawing.Point(12, 38)
Me.txtRootFolder.Name = "txtRootFolder"
Me.txtRootFolder.ReadOnly = True
Me.txtRootFolder.Size = New System.Drawing.Size(214, 20)
Me.txtRootFolder.TabIndex = 0
Me.txtRootFolder.TabStop = False
'
'btnBrowse
'
Me.btnBrowse.Location = New System.Drawing.Point(232, 37)
Me.btnBrowse.Name = "btnBrowse"
Me.btnBrowse.Size = New System.Drawing.Size(30, 20)
Me.btnBrowse.TabIndex = 0
Me.btnBrowse.Text = "..."
Me.btnBrowse.UseVisualStyleBackColor = True
'
'lstBuilder
'
Me.lstBuilder.ContextMenuStrip = Me.cmsItems
Me.lstBuilder.LabelEdit = True
Me.lstBuilder.Location = New System.Drawing.Point(322, 38)
Me.lstBuilder.Name = "lstBuilder"
Me.lstBuilder.Size = New System.Drawing.Size(250, 359)
Me.lstBuilder.SmallImageList = Me.imgIcons
Me.lstBuilder.TabIndex = 5
Me.lstBuilder.UseCompatibleStateImageBehavior = False
Me.lstBuilder.View = System.Windows.Forms.View.List
'
'cmsItems
'
Me.cmsItems.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.cmsEdit, Me.cmsRemove, Me.cmsAdd})
Me.cmsItems.Name = "cmsItems"
Me.cmsItems.Size = New System.Drawing.Size(169, 70)
'
'cmsEdit
'
Me.cmsEdit.Name = "cmsEdit"
Me.cmsEdit.Size = New System.Drawing.Size(168, 22)
Me.cmsEdit.Text = "Edit"
'
'cmsRemove
'
Me.cmsRemove.Name = "cmsRemove"
Me.cmsRemove.Size = New System.Drawing.Size(168, 22)
Me.cmsRemove.Text = "Remove"
'
'cmsAdd
'
Me.cmsAdd.Name = "cmsAdd"
Me.cmsAdd.Size = New System.Drawing.Size(168, 22)
Me.cmsAdd.Text = "Add Custom Item"
'
'btnRemove
'
Me.btnRemove.Location = New System.Drawing.Point(268, 201)
Me.btnRemove.Name = "btnRemove"
Me.btnRemove.Size = New System.Drawing.Size(48, 23)
Me.btnRemove.TabIndex = 4
Me.btnRemove.Text = "<"
Me.btnRemove.UseVisualStyleBackColor = True
'
'btnAdd
'
Me.btnAdd.Location = New System.Drawing.Point(268, 172)
Me.btnAdd.Name = "btnAdd"
Me.btnAdd.Size = New System.Drawing.Size(48, 23)
Me.btnAdd.TabIndex = 3
Me.btnAdd.Text = ">"
Me.btnAdd.UseVisualStyleBackColor = True
'
'grpFileOptions
'
Me.grpFileOptions.Controls.Add(Me.optFileTypes)
Me.grpFileOptions.Controls.Add(Me.optIndividualFiles)
Me.grpFileOptions.Location = New System.Drawing.Point(12, 403)
Me.grpFileOptions.Name = "grpFileOptions"
Me.grpFileOptions.Size = New System.Drawing.Size(194, 46)
Me.grpFileOptions.TabIndex = 2
Me.grpFileOptions.TabStop = False
Me.grpFileOptions.Text = "File Options"
'
'optFileTypes
'
Me.optFileTypes.AutoSize = True
Me.optFileTypes.Location = New System.Drawing.Point(6, 19)
Me.optFileTypes.Name = "optFileTypes"
Me.optFileTypes.Size = New System.Drawing.Size(73, 17)
Me.optFileTypes.TabIndex = 0
Me.optFileTypes.TabStop = True
Me.optFileTypes.Text = "File Types"
Me.optFileTypes.UseVisualStyleBackColor = True
'
'optIndividualFiles
'
Me.optIndividualFiles.AutoSize = True
Me.optIndividualFiles.Location = New System.Drawing.Point(85, 19)
Me.optIndividualFiles.Name = "optIndividualFiles"
Me.optIndividualFiles.Size = New System.Drawing.Size(94, 17)
Me.optIndividualFiles.TabIndex = 1
Me.optIndividualFiles.TabStop = True
Me.optIndividualFiles.Text = "Individual Files"
Me.optIndividualFiles.UseVisualStyleBackColor = True
'
'lblItems
'
Me.lblItems.Location = New System.Drawing.Point(322, 16)
Me.lblItems.Name = "lblItems"
Me.lblItems.Size = New System.Drawing.Size(250, 13)
Me.lblItems.TabIndex = 14
Me.lblItems.Text = "Items"
Me.lblItems.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'btnRawEdit
'
Me.btnRawEdit.Location = New System.Drawing.Point(335, 426)
Me.btnRawEdit.Name = "btnRawEdit"
Me.btnRawEdit.Size = New System.Drawing.Size(75, 23)
Me.btnRawEdit.TabIndex = 6
Me.btnRawEdit.Text = "Raw &Edit"
Me.btnRawEdit.UseVisualStyleBackColor = True
'
'lblSaveFolder
'
Me.lblSaveFolder.Location = New System.Drawing.Point(9, 16)
Me.lblSaveFolder.Name = "lblSaveFolder"
Me.lblSaveFolder.Size = New System.Drawing.Size(250, 13)
Me.lblSaveFolder.TabIndex = 15
Me.lblSaveFolder.Text = "Saved Game Explorer"
Me.lblSaveFolder.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'ttWarning
'
Me.ttWarning.AutoPopDelay = 5000
Me.ttWarning.InitialDelay = 200
Me.ttWarning.ReshowDelay = 50
Me.ttWarning.ToolTipIcon = System.Windows.Forms.ToolTipIcon.Warning
'
'frmIncludeExclude
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(584, 461)
Me.Controls.Add(Me.lblSaveFolder)
Me.Controls.Add(Me.btnRawEdit)
Me.Controls.Add(Me.lblItems)
Me.Controls.Add(Me.grpFileOptions)
Me.Controls.Add(Me.btnRemove)
Me.Controls.Add(Me.btnAdd)
Me.Controls.Add(Me.lstBuilder)
Me.Controls.Add(Me.btnBrowse)
Me.Controls.Add(Me.txtRootFolder)
Me.Controls.Add(Me.btnCancel)
Me.Controls.Add(Me.btnSave)
Me.Controls.Add(Me.treFiles)
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle
Me.MaximizeBox = False
Me.MinimizeBox = False
Me.Name = "frmIncludeExclude"
Me.ShowIcon = False
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
Me.Text = "Include / Exclude Builder"
Me.cmsItems.ResumeLayout(False)
Me.grpFileOptions.ResumeLayout(False)
Me.grpFileOptions.PerformLayout()
Me.ResumeLayout(False)
Me.PerformLayout()
End Sub
Friend WithEvents treFiles As System.Windows.Forms.TreeView
Friend WithEvents imgIcons As System.Windows.Forms.ImageList
Friend WithEvents btnSave As System.Windows.Forms.Button
Friend WithEvents btnCancel As System.Windows.Forms.Button
Friend WithEvents txtRootFolder As System.Windows.Forms.TextBox
Friend WithEvents btnBrowse As System.Windows.Forms.Button
Friend WithEvents lstBuilder As System.Windows.Forms.ListView
Friend WithEvents btnRemove As System.Windows.Forms.Button
Friend WithEvents btnAdd As System.Windows.Forms.Button
Friend WithEvents grpFileOptions As System.Windows.Forms.GroupBox
Friend WithEvents optFileTypes As System.Windows.Forms.RadioButton
Friend WithEvents optIndividualFiles As System.Windows.Forms.RadioButton
Friend WithEvents lblItems As System.Windows.Forms.Label
Friend WithEvents cmsItems As System.Windows.Forms.ContextMenuStrip
Friend WithEvents cmsEdit As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents cmsRemove As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents cmsAdd As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents btnRawEdit As Button
Friend WithEvents lblSaveFolder As Label
Friend WithEvents ttWarning As ToolTip
End Class
+177
View File
@@ -0,0 +1,177 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="imgIcons.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<data name="imgIcons.ImageStream" mimetype="application/x-microsoft.net.object.binary.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAB6
CQAAAk1TRnQBSQFMAgEBAwEAAbABAAGwAQABEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
AwABQAMAARADAAEBAQABCAYAAQQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
AWYDAAGZAwABzAIAATMDAAIzAgABMwFmAgABMwGZAgABMwHMAgABMwH/AgABZgMAAWYBMwIAAmYCAAFm
AZkCAAFmAcwCAAFmAf8CAAGZAwABmQEzAgABmQFmAgACmQIAAZkBzAIAAZkB/wIAAcwDAAHMATMCAAHM
AWYCAAHMAZkCAALMAgABzAH/AgAB/wFmAgAB/wGZAgAB/wHMAQABMwH/AgAB/wEAATMBAAEzAQABZgEA
ATMBAAGZAQABMwEAAcwBAAEzAQAB/wEAAf8BMwIAAzMBAAIzAWYBAAIzAZkBAAIzAcwBAAIzAf8BAAEz
AWYCAAEzAWYBMwEAATMCZgEAATMBZgGZAQABMwFmAcwBAAEzAWYB/wEAATMBmQIAATMBmQEzAQABMwGZ
AWYBAAEzApkBAAEzAZkBzAEAATMBmQH/AQABMwHMAgABMwHMATMBAAEzAcwBZgEAATMBzAGZAQABMwLM
AQABMwHMAf8BAAEzAf8BMwEAATMB/wFmAQABMwH/AZkBAAEzAf8BzAEAATMC/wEAAWYDAAFmAQABMwEA
AWYBAAFmAQABZgEAAZkBAAFmAQABzAEAAWYBAAH/AQABZgEzAgABZgIzAQABZgEzAWYBAAFmATMBmQEA
AWYBMwHMAQABZgEzAf8BAAJmAgACZgEzAQADZgEAAmYBmQEAAmYBzAEAAWYBmQIAAWYBmQEzAQABZgGZ
AWYBAAFmApkBAAFmAZkBzAEAAWYBmQH/AQABZgHMAgABZgHMATMBAAFmAcwBmQEAAWYCzAEAAWYBzAH/
AQABZgH/AgABZgH/ATMBAAFmAf8BmQEAAWYB/wHMAQABzAEAAf8BAAH/AQABzAEAApkCAAGZATMBmQEA
AZkBAAGZAQABmQEAAcwBAAGZAwABmQIzAQABmQEAAWYBAAGZATMBzAEAAZkBAAH/AQABmQFmAgABmQFm
ATMBAAGZATMBZgEAAZkBZgGZAQABmQFmAcwBAAGZATMB/wEAApkBMwEAApkBZgEAA5kBAAKZAcwBAAKZ
Af8BAAGZAcwCAAGZAcwBMwEAAWYBzAFmAQABmQHMAZkBAAGZAswBAAGZAcwB/wEAAZkB/wIAAZkB/wEz
AQABmQHMAWYBAAGZAf8BmQEAAZkB/wHMAQABmQL/AQABzAMAAZkBAAEzAQABzAEAAWYBAAHMAQABmQEA
AcwBAAHMAQABmQEzAgABzAIzAQABzAEzAWYBAAHMATMBmQEAAcwBMwHMAQABzAEzAf8BAAHMAWYCAAHM
AWYBMwEAAZkCZgEAAcwBZgGZAQABzAFmAcwBAAGZAWYB/wEAAcwBmQIAAcwBmQEzAQABzAGZAWYBAAHM
ApkBAAHMAZkBzAEAAcwBmQH/AQACzAIAAswBMwEAAswBZgEAAswBmQEAA8wBAALMAf8BAAHMAf8CAAHM
Af8BMwEAAZkB/wFmAQABzAH/AZkBAAHMAf8BzAEAAcwC/wEAAcwBAAEzAQAB/wEAAWYBAAH/AQABmQEA
AcwBMwIAAf8CMwEAAf8BMwFmAQAB/wEzAZkBAAH/ATMBzAEAAf8BMwH/AQAB/wFmAgAB/wFmATMBAAHM
AmYBAAH/AWYBmQEAAf8BZgHMAQABzAFmAf8BAAH/AZkCAAH/AZkBMwEAAf8BmQFmAQAB/wKZAQAB/wGZ
AcwBAAH/AZkB/wEAAf8BzAIAAf8BzAEzAQAB/wHMAWYBAAH/AcwBmQEAAf8CzAEAAf8BzAH/AQAC/wEz
AQABzAH/AWYBAAL/AZkBAAL/AcwBAAJmAf8BAAFmAf8BZgEAAWYC/wEAAf8CZgEAAf8BZgH/AQAC/wFm
AQABIQEAAaUBAANfAQADdwEAA4YBAAOWAQADywEAA7IBAAPXAQAD3QEAA+MBAAPqAQAD8QEAA/gBAAHw
AfsB/wEAAaQCoAEAA4ADAAH/AgAB/wMAAv8BAAH/AwAB/wEAAf8BAAL/AgAD/xMACf82AAH0CQcB/wsA
Af8ZAAHyDLsB8gIAAfMJvAH0A/8IAAH/AbMBuwH/FgABuwyzAQkCAAHzAvIB8QkHAfQHAAH/A7MBugH/
FQABCQyzAQkCAAHzAvIB8QnwAfMGAAH/ArQB8QG8AbQBCQH/FAABCQyzAQkCAAHzDPIB8wUAAf8CtALy
AfEBvAG0AbsB/xMAAQkMugEJAgAC8wvyAfMEAAH/AbQBugHzA/IB8QG8AbQBuxMAAfAMugHwAgAD8wry
AfMDAAH/AroD8wPyAfEBugG0EwAB8AzbAfACAATzAfIJ8wIAAf8CugbzAfICugL/EgABGQzcARkCAATz
AfIJ8wIAAfQCugEJBfMCuwH/FAAB8QwJAfECAA7zAgAB9AG6AdsB3AEJA/MBCQG7Af8VAAHwB9wFugHw
AgAB8wL0B/MB8gHvAbwB9AIAAfQB3AHzAf8B3AEJAfICCQH/FgABGQG7BO8BCQH/CAAB9AnzAe8B9wHx
AwAB9AHcARkB8wPcAQkB/xcAAfMB8AQZAfIJAAP/AfQB8wT0AQcBvAH/BAAB9AIJAdwB4QIJAf8rAAH/
BPMC8gYAAf8F9AH/LQAF/yYAAUIBTQE+BwABPgMAASgDAAFAAwABEAMAAQEBAAEBBQABgBcAA/8BAAL/
AcABHwL/AgAC/wGAAQ8B/gH/AgABgAEBAYABAQH+AR8CAAGAAQEBgAEBAfwBDwIAAYABAQGAAQEB+AEH
AgABgAEBAYABAQHwAQMCAAGAAQEBgAEBAeABAwIAAYABAQGAAQEBwAEDAgABgAEBAYABAQGAAQECAAGA
AQEBgAEBAYABBwIAAYABAQGAAQEBgAEPAgABgAEBAYABAQGAAR8CAAGAAX8BgAEDAYABPwIAAYAB/wGA
AQcBgAF/AgAC/wHwAR8BgAH/AgAC/wH4AT8C/wIACw==
</value>
</data>
<metadata name="cmsItems.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>118, 17</value>
</metadata>
<metadata name="ttWarning.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>221, 17</value>
</metadata>
</root>
+349
View File
@@ -0,0 +1,349 @@
Imports GBM.My.Resources
Imports System.IO
Public Class frmIncludeExclude
Dim sFormName As String = String.Empty
Dim sRootFolder As String = String.Empty
Dim sBuilderString As String
Public Property BuilderString As String
Get
Return sBuilderString
End Get
Set(value As String)
sBuilderString = value
End Set
End Property
Public Property FormName As String
Get
Return sFormName
End Get
Set(value As String)
sFormName = value
End Set
End Property
Public Property RootFolder As String
Get
Return sRootFolder
End Get
Set(value As String)
sRootFolder = value.TrimEnd("\")
End Set
End Property
Private Sub BuildBranch(ByVal sDirectory As String, ByVal oNode As TreeNode)
Dim sFolders As String()
Dim sFiles As String()
Dim oChild As TreeNode
Dim oPlaceHolder As TreeNode
If oNode.Nodes.ContainsKey("GBM_Tree_Placeholder") Then
Try
Cursor.Current = Cursors.WaitCursor
treFiles.BeginUpdate()
oNode.Nodes.RemoveByKey("GBM_Tree_Placeholder")
sFolders = Directory.GetDirectories(sDirectory)
sFiles = Directory.GetFiles(sDirectory)
If sFolders.Length <> 0 Then
For Each sFolder As String In sFolders
oChild = New TreeNode(sFolder.Replace(sDirectory, String.Empty).TrimStart("\"), 0, 0)
oChild.Name = sFolder
oChild.Tag = 0
oNode.Nodes.Add(oChild)
oPlaceHolder = New TreeNode("GBM_Tree_Placeholder")
oPlaceHolder.Name = "GBM_Tree_Placeholder"
oChild.Nodes.Add(oPlaceHolder)
Next
End If
If sFiles.Length <> 0 Then
For Each sFile As String In sFiles
oChild = New TreeNode(sFile.Replace(sDirectory, String.Empty).TrimStart("\"), 1, 1)
oChild.Tag = 1
oNode.Nodes.Add(oChild)
Next
End If
Catch uaex As UnauthorizedAccessException
'Do Nothing
Catch ex As Exception
mgrCommon.ShowMessage(frmIncludeExclude_ErrorFileSystemRead, ex.Message, MsgBoxStyle.Critical)
Finally
treFiles.EndUpdate()
Cursor.Current = Cursors.Default
End Try
End If
End Sub
Private Sub BuildTrunk()
Dim oRootNode As TreeNode
If Path.GetPathRoot(txtRootFolder.Text) = txtRootFolder.Text Then
oRootNode = New TreeNode(txtRootFolder.Text, 0, 0)
Else
oRootNode = New TreeNode(Path.GetFileName(txtRootFolder.Text), 0, 0)
End If
treFiles.Nodes.Clear()
oRootNode.Name = "Root"
oRootNode.Nodes.Add("GBM_Tree_Placeholder", "GBM_Tree_Placeholder")
treFiles.Nodes.Add(oRootNode)
BuildBranch(txtRootFolder.Text, oRootNode)
End Sub
Private Sub RootPathBrowse()
Dim sDefaultFolder As String = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
Dim sCurrentPath As String = txtRootFolder.Text
Dim sNewPath As String
If sCurrentPath <> String.Empty Then
If Directory.Exists(sCurrentPath) Then
sDefaultFolder = sCurrentPath
End If
End If
sNewPath = mgrCommon.OpenFolderBrowser(frmIncludeExclude_BrowseSaveFolder, sDefaultFolder, False)
If sNewPath <> String.Empty Then txtRootFolder.Text = sNewPath
End Sub
Private Sub GetAllCheckedNodes(ByVal oRootNode As TreeNodeCollection, ByRef oNodeList As List(Of TreeNode))
For Each oNode As TreeNode In oRootNode
If oNode.Checked Then
oNode.Checked = False
oNodeList.Add(oNode)
End If
If oNode.Nodes.Count > 0 Then
GetAllCheckedNodes(oNode.Nodes, oNodeList)
End If
Next
End Sub
Private Sub AddItem()
Dim oCheckedNodes As New List(Of TreeNode)
Dim oListViewItem As ListViewItem
Dim sItem As String
GetAllCheckedNodes(treFiles.Nodes, oCheckedNodes)
lstBuilder.BeginUpdate()
For Each oNode In oCheckedNodes
sItem = oNode.Text
If oNode.Tag = 1 And optFileTypes.Checked Then
sItem = Path.GetExtension(oNode.Text)
If sItem <> String.Empty Then
sItem = "*" & sItem
oListViewItem = New ListViewItem(sItem, 2)
oListViewItem.Name = sItem
Else
sItem = oNode.Text
oListViewItem = New ListViewItem(sItem, 1)
oListViewItem.Name = sItem
End If
Else
oListViewItem = New ListViewItem(sItem, CInt(oNode.Tag))
oListViewItem.Name = sItem
End If
If Not lstBuilder.Items.ContainsKey(sItem) Then
lstBuilder.Items.Add(oListViewItem)
End If
Next
lstBuilder.EndUpdate()
End Sub
Private Sub RemoveItem()
For Each oListViewItem As ListViewItem In lstBuilder.SelectedItems
oListViewItem.Remove()
Next
End Sub
Private Sub ParseBuilderString(ByVal sString As String)
Dim iType As Integer = 1
Dim oListViewItem As ListViewItem
Dim sItems As String() = sString.Split(":")
lstBuilder.BeginUpdate()
lstBuilder.Clear()
For Each sItem As String In sItems
oListViewItem = New ListViewItem(sItem)
oListViewItem.Name = sItem
IdentifyEntry(oListViewItem, sItem)
If Not lstBuilder.Items.ContainsKey(sItem) Then
lstBuilder.Items.Add(oListViewItem)
End If
Next
lstBuilder.EndUpdate()
End Sub
Private Sub IdentifyEntry(ByRef oListItem As ListViewItem, ByVal sNewLabel As String)
Dim iType As Integer = 1
Dim sFolderCheck As String
If sNewLabel.Contains("*") Or sNewLabel.Contains("?") Then
iType = 2
Else
If txtRootFolder.Text <> String.Empty Then
If Path.GetFileName(txtRootFolder.Text) = sNewLabel Then
sFolderCheck = txtRootFolder.Text
Else
sFolderCheck = txtRootFolder.Text & "\" & sNewLabel
End If
If Directory.Exists(sFolderCheck) Then
iType = 0
Else
iType = 1
End If
End If
End If
oListItem.ImageIndex = iType
End Sub
Private Function CreateNewBuilderString() As String
Dim sTempString As String = String.Empty
For Each oListViewItem As ListViewItem In lstBuilder.Items
sTempString &= oListViewItem.Text & ":"
Next
sTempString = sTempString.TrimEnd(":")
Return sTempString
End Function
Private Sub OpenRawEdit()
Dim sCurrentString As String = CreateNewBuilderString()
Dim sNewString As String
sNewString = InputBox(frmIncludeExclude_RawEditInfo, mgrCommon.FormatString(frmIncludeExclude_RawEditTitle, FormName), sCurrentString)
If sNewString <> String.Empty Then
ParseBuilderString(sNewString)
End If
End Sub
Private Sub SetForm()
'Set Form Name
Me.Text = mgrCommon.FormatString(frmIncludeExclude_FormName, FormName)
'Set Form Text
lblSaveFolder.Text = frmIncludeExclude_lblSaveFolder
btnRawEdit.Text = frmIncludeExclude_btnRawEdit
lblItems.Text = mgrCommon.FormatString(frmIncludeExclude_lblItems, FormName)
grpFileOptions.Text = mgrCommon.FormatString(frmIncludeExclude_grpFileOptions, FormName)
optFileTypes.Text = frmIncludeExclude_optFileTypes
optIndividualFiles.Text = frmIncludeExclude_optIndividualFiles
btnRemove.Text = frmIncludeExclude_btnRemove
btnAdd.Text = frmIncludeExclude_btnAdd
btnBrowse.Text = frmIncludeExclude_btnBrowse
btnCancel.Text = frmIncludeExclude_btnCancel
btnSave.Text = frmIncludeExclude_btnSave
cmsAdd.Text = frmIncludeExclude_cmsAdd
cmsEdit.Text = frmIncludeExclude_cmsEdit
cmsRemove.Text = frmIncludeExclude_cmsRemove
'Set Defaults
txtRootFolder.Text = RootFolder
optFileTypes.Checked = True
If BuilderString <> String.Empty Then ParseBuilderString(BuilderString)
If txtRootFolder.Text <> String.Empty Then BuildTrunk()
End Sub
Private Sub frmIncludeExclude_Load(sender As Object, e As EventArgs) Handles MyBase.Load
SetForm()
End Sub
Private Sub frmIncludeExclude_Shown(sender As Object, e As EventArgs) Handles MyBase.Shown
treFiles.Select()
If Not treFiles.SelectedNode Is Nothing Then treFiles.SelectedNode.Expand()
If txtRootFolder.Text = String.Empty Then
ttWarning.ToolTipTitle = frmIncludeExclude_ToolTipTitle
ttWarning.SetToolTip(treFiles, frmIncludeExclude_ToolTipFiles)
ttWarning.SetToolTip(txtRootFolder, frmIncludeExclude_ToolTipFolder)
ttWarning.SetToolTip(btnBrowse, frmIncludeExclude_ToolTipBrowse)
End If
End Sub
Private Sub btnBrowse_Click(sender As Object, e As EventArgs) Handles btnBrowse.Click
RootPathBrowse()
If txtRootFolder.Text <> String.Empty Then
BuildTrunk()
ttWarning.RemoveAll()
End If
treFiles.Select()
If Not treFiles.SelectedNode Is Nothing Then treFiles.SelectedNode.Expand()
End Sub
Private Sub btnSave_Click(sender As Object, e As EventArgs) Handles btnSave.Click
BuilderString = CreateNewBuilderString()
Me.Close()
End Sub
Private Sub btnCancel_Click(sender As Object, e As EventArgs) Handles btnCancel.Click
Me.Close()
End Sub
Private Sub treFiles_BeforeExpand(sender As Object, e As TreeViewCancelEventArgs) Handles treFiles.BeforeExpand
If Not e.Node.Name = "Root" Then
BuildBranch(e.Node.Name, e.Node)
End If
End Sub
Private Sub btnAdd_Click(sender As Object, e As EventArgs) Handles btnAdd.Click
AddItem()
End Sub
Private Sub btnRemove_Click(sender As Object, e As EventArgs) Handles btnRemove.Click
RemoveItem()
End Sub
Private Sub cmsItems_Opening(sender As Object, e As System.ComponentModel.CancelEventArgs) Handles cmsItems.Opening
If lstBuilder.SelectedItems.Count = 0 Then
cmsEdit.Visible = False
cmsRemove.Visible = False
cmsAdd.Visible = True
Else
cmsEdit.Visible = True
cmsRemove.Visible = True
cmsAdd.Visible = False
End If
End Sub
Private Sub cmsEdit_Click(sender As Object, e As EventArgs) Handles cmsEdit.Click
If lstBuilder.SelectedItems.Count > 0 Then
lstBuilder.SelectedItems(0).BeginEdit()
End If
End Sub
Private Sub cmsRemove_Click(sender As Object, e As EventArgs) Handles cmsRemove.Click
RemoveItem()
End Sub
Private Sub cmsAdd_Click(sender As Object, e As EventArgs) Handles cmsAdd.Click
Dim oNewItem As New ListViewItem(frmIncludeExclude_CustomItem, 1)
oNewItem.Selected = True
lstBuilder.Items.Add(oNewItem)
lstBuilder.SelectedItems(0).BeginEdit()
End Sub
Private Sub lstBuilder_AfterLabelEdit(sender As Object, e As LabelEditEventArgs) Handles lstBuilder.AfterLabelEdit
If Not e.Label Is Nothing Then
If lstBuilder.Items.ContainsKey(e.Label) Then
e.CancelEdit = True
Else
IdentifyEntry(lstBuilder.Items(e.Item), e.Label)
End If
End If
End Sub
Private Sub btnRawEdit_Click(sender As Object, e As EventArgs) Handles btnRawEdit.Click
OpenRawEdit()
End Sub
End Class
+131 -151
View File
@@ -26,6 +26,7 @@ Partial Class frmMain
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmMain))
Me.gMonTray = New System.Windows.Forms.NotifyIcon(Me.components)
Me.gMonTrayMenu = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.gMonTrayNotification = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTrayShow = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTraySep2 = New System.Windows.Forms.ToolStripSeparator()
Me.gMonTrayMon = New System.Windows.Forms.ToolStripMenuItem()
@@ -34,12 +35,9 @@ Partial Class frmMain
Me.gMonTraySetupAddWizard = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTraySetupGameManager = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTraySetupCustomVariables = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTraySetupTags = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTrayTools = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTrayToolsGameList = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTrayToolsGameImportOfficialList = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTrayToolsGameImportList = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTrayToolsGameExportList = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTrayToolsSyncMan = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTrayToolsCleanMan = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTrayToolsCompact = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTraySep1 = New System.Windows.Forms.ToolStripSeparator()
Me.gMonTrayExit = New System.Windows.Forms.ToolStripMenuItem()
@@ -60,32 +58,32 @@ Partial Class frmMain
Me.gMonSetupGameManager = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonSetupAddWizard = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonSetupCustomVariables = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonSetupTags = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTools = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonToolsGameList = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonToolsGameImportOfficialList = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonToolsGameImportList = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonToolsGameExportList = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonToolsSyncMan = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonToolsCleanMan = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonToolsCompact = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonHelp = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonHelpWebSite = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonHelpManual = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonHelpCheckforUpdates = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonHelpAbout = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonNotification = New System.Windows.Forms.ToolStripMenuItem()
Me.pbIcon = New System.Windows.Forms.PictureBox()
Me.btnLogToggle = New System.Windows.Forms.Button()
Me.lblGameTitle = New System.Windows.Forms.Label()
Me.lblLastAction = New System.Windows.Forms.Label()
Me.lblLastActionTitle = New System.Windows.Forms.Label()
Me.lblTimeTitle = New System.Windows.Forms.Label()
Me.lblTimeSpent = New System.Windows.Forms.Label()
Me.txtGameInfo = New System.Windows.Forms.TextBox()
Me.btnCancelOperation = New System.Windows.Forms.Button()
Me.gMonSetupTags = New System.Windows.Forms.ToolStripMenuItem()
Me.gMonTraySetupTags = New System.Windows.Forms.ToolStripMenuItem()
Me.lblStatus1 = New System.Windows.Forms.Label()
Me.lblStatus2 = New System.Windows.Forms.Label()
Me.lblStatus3 = New System.Windows.Forms.Label()
Me.pbTime = New System.Windows.Forms.PictureBox()
Me.gMonTrayMenu.SuspendLayout()
Me.gMonStatusStrip.SuspendLayout()
Me.gMonMainMenu.SuspendLayout()
CType(Me.pbIcon, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.pbTime, System.ComponentModel.ISupportInitialize).BeginInit()
Me.SuspendLayout()
'
'gMonTray
@@ -99,9 +97,16 @@ Partial Class frmMain
'
'gMonTrayMenu
'
Me.gMonTrayMenu.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonTrayShow, Me.gMonTraySep2, Me.gMonTrayMon, Me.gMonTraySettings, Me.gMonTraySetup, Me.gMonTrayTools, Me.gMonTraySep1, Me.gMonTrayExit})
Me.gMonTrayMenu.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonTrayNotification, Me.gMonTrayShow, Me.gMonTraySep2, Me.gMonTrayMon, Me.gMonTraySettings, Me.gMonTraySetup, Me.gMonTrayTools, Me.gMonTraySep1, Me.gMonTrayExit})
Me.gMonTrayMenu.Name = "gMonTrayMenu"
Me.gMonTrayMenu.Size = New System.Drawing.Size(162, 148)
Me.gMonTrayMenu.Size = New System.Drawing.Size(162, 170)
'
'gMonTrayNotification
'
Me.gMonTrayNotification.Name = "gMonTrayNotification"
Me.gMonTrayNotification.Size = New System.Drawing.Size(161, 22)
Me.gMonTrayNotification.Text = "Notification"
Me.gMonTrayNotification.Visible = False
'
'gMonTrayShow
'
@@ -151,48 +156,29 @@ Partial Class frmMain
Me.gMonTraySetupCustomVariables.Size = New System.Drawing.Size(201, 22)
Me.gMonTraySetupCustomVariables.Text = "Custom &Path Variables..."
'
'gMonTraySetupTags
'
Me.gMonTraySetupTags.Name = "gMonTraySetupTags"
Me.gMonTraySetupTags.Size = New System.Drawing.Size(201, 22)
Me.gMonTraySetupTags.Text = "&Tags..."
'
'gMonTrayTools
'
Me.gMonTrayTools.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonTrayToolsGameList, Me.gMonTrayToolsSyncMan, Me.gMonTrayToolsCompact})
Me.gMonTrayTools.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonTrayToolsCleanMan, Me.gMonTrayToolsCompact})
Me.gMonTrayTools.Name = "gMonTrayTools"
Me.gMonTrayTools.Size = New System.Drawing.Size(161, 22)
Me.gMonTrayTools.Text = "&Tools"
'
'gMonTrayToolsGameList
'gMonTrayToolsCleanMan
'
Me.gMonTrayToolsGameList.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonTrayToolsGameImportOfficialList, Me.gMonTrayToolsGameImportList, Me.gMonTrayToolsGameExportList})
Me.gMonTrayToolsGameList.Name = "gMonTrayToolsGameList"
Me.gMonTrayToolsGameList.Size = New System.Drawing.Size(179, 22)
Me.gMonTrayToolsGameList.Text = "&Game List"
'
'gMonTrayToolsGameImportOfficialList
'
Me.gMonTrayToolsGameImportOfficialList.Name = "gMonTrayToolsGameImportOfficialList"
Me.gMonTrayToolsGameImportOfficialList.Size = New System.Drawing.Size(201, 22)
Me.gMonTrayToolsGameImportOfficialList.Text = "Import from &Official List"
'
'gMonTrayToolsGameImportList
'
Me.gMonTrayToolsGameImportList.Name = "gMonTrayToolsGameImportList"
Me.gMonTrayToolsGameImportList.Size = New System.Drawing.Size(201, 22)
Me.gMonTrayToolsGameImportList.Text = "I&mport Game List"
'
'gMonTrayToolsGameExportList
'
Me.gMonTrayToolsGameExportList.Name = "gMonTrayToolsGameExportList"
Me.gMonTrayToolsGameExportList.Size = New System.Drawing.Size(201, 22)
Me.gMonTrayToolsGameExportList.Text = "E&xport Game List"
'
'gMonTrayToolsSyncMan
'
Me.gMonTrayToolsSyncMan.Name = "gMonTrayToolsSyncMan"
Me.gMonTrayToolsSyncMan.Size = New System.Drawing.Size(179, 22)
Me.gMonTrayToolsSyncMan.Text = "Sync Ma&nifests"
Me.gMonTrayToolsCleanMan.Name = "gMonTrayToolsCleanMan"
Me.gMonTrayToolsCleanMan.Size = New System.Drawing.Size(184, 22)
Me.gMonTrayToolsCleanMan.Text = "Clean Local Ma&nifest"
'
'gMonTrayToolsCompact
'
Me.gMonTrayToolsCompact.Name = "gMonTrayToolsCompact"
Me.gMonTrayToolsCompact.Size = New System.Drawing.Size(179, 22)
Me.gMonTrayToolsCompact.Size = New System.Drawing.Size(184, 22)
Me.gMonTrayToolsCompact.Text = "&Compact Databases"
'
'gMonTraySep1
@@ -213,20 +199,21 @@ Partial Class frmMain
'txtLog
'
Me.txtLog.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.txtLog.Location = New System.Drawing.Point(12, 161)
Me.txtLog.Location = New System.Drawing.Point(12, 184)
Me.txtLog.MaxLength = 16777216
Me.txtLog.Multiline = True
Me.txtLog.Name = "txtLog"
Me.txtLog.ReadOnly = True
Me.txtLog.ScrollBars = System.Windows.Forms.ScrollBars.Vertical
Me.txtLog.Size = New System.Drawing.Size(500, 177)
Me.txtLog.TabIndex = 2
Me.txtLog.TabIndex = 10
Me.txtLog.TabStop = False
'
'gMonStatusStrip
'
Me.gMonStatusStrip.Font = New System.Drawing.Font("Segoe UI", 9.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.gMonStatusStrip.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonStripAdminButton, Me.gMonStripTxtStatus, Me.gMonStripStatusButton})
Me.gMonStatusStrip.Location = New System.Drawing.Point(0, 350)
Me.gMonStatusStrip.Location = New System.Drawing.Point(0, 364)
Me.gMonStatusStrip.Name = "gMonStatusStrip"
Me.gMonStatusStrip.ShowItemToolTips = True
Me.gMonStatusStrip.Size = New System.Drawing.Size(524, 22)
@@ -237,7 +224,7 @@ Partial Class frmMain
'
Me.gMonStripAdminButton.DisplayStyle = System.Windows.Forms.ToolStripItemDisplayStyle.Image
Me.gMonStripAdminButton.DropDownButtonWidth = 0
Me.gMonStripAdminButton.Image = Global.GBM.My.Resources.Resources.User
Me.gMonStripAdminButton.Image = Global.GBM.My.Resources.Resources.Icon_User
Me.gMonStripAdminButton.ImageTransparentColor = System.Drawing.Color.Magenta
Me.gMonStripAdminButton.Name = "gMonStripAdminButton"
Me.gMonStripAdminButton.Size = New System.Drawing.Size(21, 20)
@@ -266,12 +253,12 @@ Partial Class frmMain
'
'gMonMainMenu
'
Me.gMonMainMenu.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonFile, Me.gMonSetup, Me.gMonTools, Me.gMonHelp})
Me.gMonMainMenu.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonFile, Me.gMonSetup, Me.gMonTools, Me.gMonHelp, Me.gMonNotification})
Me.gMonMainMenu.Location = New System.Drawing.Point(0, 0)
Me.gMonMainMenu.Name = "gMonMainMenu"
Me.gMonMainMenu.RenderMode = System.Windows.Forms.ToolStripRenderMode.System
Me.gMonMainMenu.Size = New System.Drawing.Size(524, 24)
Me.gMonMainMenu.TabIndex = 8
Me.gMonMainMenu.TabIndex = 0
Me.gMonMainMenu.Text = "MenuStrip1"
'
'gMonFile
@@ -334,75 +321,70 @@ Partial Class frmMain
Me.gMonSetupCustomVariables.Size = New System.Drawing.Size(201, 22)
Me.gMonSetupCustomVariables.Text = "Custom &Path Variables..."
'
'gMonSetupTags
'
Me.gMonSetupTags.Name = "gMonSetupTags"
Me.gMonSetupTags.Size = New System.Drawing.Size(201, 22)
Me.gMonSetupTags.Text = "&Tags..."
'
'gMonTools
'
Me.gMonTools.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonToolsGameList, Me.gMonToolsSyncMan, Me.gMonToolsCompact})
Me.gMonTools.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonToolsCleanMan, Me.gMonToolsCompact})
Me.gMonTools.Name = "gMonTools"
Me.gMonTools.Size = New System.Drawing.Size(47, 20)
Me.gMonTools.Text = "&Tools"
'
'gMonToolsGameList
'gMonToolsCleanMan
'
Me.gMonToolsGameList.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonToolsGameImportOfficialList, Me.gMonToolsGameImportList, Me.gMonToolsGameExportList})
Me.gMonToolsGameList.Name = "gMonToolsGameList"
Me.gMonToolsGameList.Size = New System.Drawing.Size(179, 22)
Me.gMonToolsGameList.Text = "&Game List"
'
'gMonToolsGameImportOfficialList
'
Me.gMonToolsGameImportOfficialList.Name = "gMonToolsGameImportOfficialList"
Me.gMonToolsGameImportOfficialList.Size = New System.Drawing.Size(201, 22)
Me.gMonToolsGameImportOfficialList.Text = "Import from &Official List"
'
'gMonToolsGameImportList
'
Me.gMonToolsGameImportList.Name = "gMonToolsGameImportList"
Me.gMonToolsGameImportList.Size = New System.Drawing.Size(201, 22)
Me.gMonToolsGameImportList.Text = "I&mport Game List"
'
'gMonToolsGameExportList
'
Me.gMonToolsGameExportList.Name = "gMonToolsGameExportList"
Me.gMonToolsGameExportList.Size = New System.Drawing.Size(201, 22)
Me.gMonToolsGameExportList.Text = "E&xport Game List"
'
'gMonToolsSyncMan
'
Me.gMonToolsSyncMan.Name = "gMonToolsSyncMan"
Me.gMonToolsSyncMan.Size = New System.Drawing.Size(179, 22)
Me.gMonToolsSyncMan.Text = "Sync Ma&nifests"
Me.gMonToolsCleanMan.Name = "gMonToolsCleanMan"
Me.gMonToolsCleanMan.Size = New System.Drawing.Size(184, 22)
Me.gMonToolsCleanMan.Text = "Clean Local Ma&nifest"
'
'gMonToolsCompact
'
Me.gMonToolsCompact.Name = "gMonToolsCompact"
Me.gMonToolsCompact.Size = New System.Drawing.Size(179, 22)
Me.gMonToolsCompact.Size = New System.Drawing.Size(184, 22)
Me.gMonToolsCompact.Text = "&Compact Databases"
'
'gMonHelp
'
Me.gMonHelp.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonHelpManual, Me.gMonHelpCheckforUpdates, Me.gMonHelpAbout})
Me.gMonHelp.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonHelpWebSite, Me.gMonHelpManual, Me.gMonHelpCheckforUpdates, Me.gMonHelpAbout})
Me.gMonHelp.Name = "gMonHelp"
Me.gMonHelp.Size = New System.Drawing.Size(44, 20)
Me.gMonHelp.Text = "&Help"
'
'gMonHelpWebSite
'
Me.gMonHelpWebSite.Name = "gMonHelpWebSite"
Me.gMonHelpWebSite.Size = New System.Drawing.Size(180, 22)
Me.gMonHelpWebSite.Text = "&Official Web Site..."
'
'gMonHelpManual
'
Me.gMonHelpManual.Name = "gMonHelpManual"
Me.gMonHelpManual.Size = New System.Drawing.Size(171, 22)
Me.gMonHelpManual.Text = "Online &Manual"
Me.gMonHelpManual.Size = New System.Drawing.Size(180, 22)
Me.gMonHelpManual.Text = "Online &Manual..."
'
'gMonHelpCheckforUpdates
'
Me.gMonHelpCheckforUpdates.Name = "gMonHelpCheckforUpdates"
Me.gMonHelpCheckforUpdates.Size = New System.Drawing.Size(171, 22)
Me.gMonHelpCheckforUpdates.Text = "Check for Updates"
Me.gMonHelpCheckforUpdates.Size = New System.Drawing.Size(180, 22)
Me.gMonHelpCheckforUpdates.Text = "&Check for Updates..."
'
'gMonHelpAbout
'
Me.gMonHelpAbout.Name = "gMonHelpAbout"
Me.gMonHelpAbout.Size = New System.Drawing.Size(171, 22)
Me.gMonHelpAbout.Size = New System.Drawing.Size(180, 22)
Me.gMonHelpAbout.Text = "&About"
'
'gMonNotification
'
Me.gMonNotification.Alignment = System.Windows.Forms.ToolStripItemAlignment.Right
Me.gMonNotification.Name = "gMonNotification"
Me.gMonNotification.Size = New System.Drawing.Size(82, 20)
Me.gMonNotification.Text = "Notification"
Me.gMonNotification.Visible = False
'
'pbIcon
'
Me.pbIcon.Location = New System.Drawing.Point(12, 36)
@@ -414,10 +396,10 @@ Partial Class frmMain
'
'btnLogToggle
'
Me.btnLogToggle.Location = New System.Drawing.Point(437, 132)
Me.btnLogToggle.Location = New System.Drawing.Point(437, 155)
Me.btnLogToggle.Name = "btnLogToggle"
Me.btnLogToggle.Size = New System.Drawing.Size(75, 23)
Me.btnLogToggle.TabIndex = 1
Me.btnLogToggle.TabIndex = 7
Me.btnLogToggle.Text = "Show &Log"
Me.btnLogToggle.UseVisualStyleBackColor = True
'
@@ -427,91 +409,91 @@ Partial Class frmMain
Me.lblGameTitle.Location = New System.Drawing.Point(66, 36)
Me.lblGameTitle.Name = "lblGameTitle"
Me.lblGameTitle.Size = New System.Drawing.Size(446, 16)
Me.lblGameTitle.TabIndex = 10
Me.lblGameTitle.TabIndex = 1
Me.lblGameTitle.Text = "Game Title"
'
'lblLastAction
'
Me.lblLastAction.AutoEllipsis = True
Me.lblLastAction.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblLastAction.Location = New System.Drawing.Point(12, 139)
Me.lblLastAction.Location = New System.Drawing.Point(12, 165)
Me.lblLastAction.Name = "lblLastAction"
Me.lblLastAction.Size = New System.Drawing.Size(419, 16)
Me.lblLastAction.TabIndex = 11
Me.lblLastAction.Size = New System.Drawing.Size(419, 13)
Me.lblLastAction.TabIndex = 9
Me.lblLastAction.Text = "Last Action"
'
'lblLastActionTitle
'
Me.lblLastActionTitle.AutoSize = True
Me.lblLastActionTitle.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblLastActionTitle.Location = New System.Drawing.Point(12, 126)
Me.lblLastActionTitle.Location = New System.Drawing.Point(12, 147)
Me.lblLastActionTitle.Name = "lblLastActionTitle"
Me.lblLastActionTitle.Size = New System.Drawing.Size(75, 13)
Me.lblLastActionTitle.TabIndex = 12
Me.lblLastActionTitle.TabIndex = 8
Me.lblLastActionTitle.Text = "Last Action:"
'
'lblTimeTitle
'
Me.lblTimeTitle.AutoSize = True
Me.lblTimeTitle.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblTimeTitle.Location = New System.Drawing.Point(66, 55)
Me.lblTimeTitle.Name = "lblTimeTitle"
Me.lblTimeTitle.Size = New System.Drawing.Size(75, 13)
Me.lblTimeTitle.TabIndex = 13
Me.lblTimeTitle.Text = "Time Spent:"
'
'lblTimeSpent
'
Me.lblTimeSpent.AutoSize = True
Me.lblTimeSpent.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblTimeSpent.Location = New System.Drawing.Point(139, 55)
Me.lblTimeSpent.AutoEllipsis = True
Me.lblTimeSpent.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblTimeSpent.Location = New System.Drawing.Point(66, 110)
Me.lblTimeSpent.Name = "lblTimeSpent"
Me.lblTimeSpent.Size = New System.Drawing.Size(44, 13)
Me.lblTimeSpent.TabIndex = 14
Me.lblTimeSpent.Size = New System.Drawing.Size(446, 16)
Me.lblTimeSpent.TabIndex = 5
Me.lblTimeSpent.Text = "0 Hours"
'
'txtGameInfo
'
Me.txtGameInfo.BorderStyle = System.Windows.Forms.BorderStyle.None
Me.txtGameInfo.Cursor = System.Windows.Forms.Cursors.Default
Me.txtGameInfo.Location = New System.Drawing.Point(69, 71)
Me.txtGameInfo.Multiline = True
Me.txtGameInfo.Name = "txtGameInfo"
Me.txtGameInfo.ReadOnly = True
Me.txtGameInfo.Size = New System.Drawing.Size(443, 52)
Me.txtGameInfo.TabIndex = 0
Me.txtGameInfo.TabStop = False
Me.txtGameInfo.WordWrap = False
'
'btnCancelOperation
'
Me.btnCancelOperation.Location = New System.Drawing.Point(437, 103)
Me.btnCancelOperation.Location = New System.Drawing.Point(437, 126)
Me.btnCancelOperation.Name = "btnCancelOperation"
Me.btnCancelOperation.Size = New System.Drawing.Size(75, 23)
Me.btnCancelOperation.TabIndex = 0
Me.btnCancelOperation.TabIndex = 6
Me.btnCancelOperation.Text = "&Cancel"
Me.btnCancelOperation.UseVisualStyleBackColor = True
'
'gMonSetupTags
'lblStatus1
'
Me.gMonSetupTags.Name = "gMonSetupTags"
Me.gMonSetupTags.Size = New System.Drawing.Size(201, 22)
Me.gMonSetupTags.Text = "&Tags..."
Me.lblStatus1.AutoEllipsis = True
Me.lblStatus1.Location = New System.Drawing.Point(66, 58)
Me.lblStatus1.Name = "lblStatus1"
Me.lblStatus1.Size = New System.Drawing.Size(446, 13)
Me.lblStatus1.TabIndex = 2
'
'gMonTraySetupTags
'lblStatus2
'
Me.gMonTraySetupTags.Name = "gMonTraySetupTags"
Me.gMonTraySetupTags.Size = New System.Drawing.Size(201, 22)
Me.gMonTraySetupTags.Text = "&Tags"
Me.lblStatus2.AutoEllipsis = True
Me.lblStatus2.Location = New System.Drawing.Point(66, 74)
Me.lblStatus2.Name = "lblStatus2"
Me.lblStatus2.Size = New System.Drawing.Size(446, 13)
Me.lblStatus2.TabIndex = 3
'
'lblStatus3
'
Me.lblStatus3.AutoEllipsis = True
Me.lblStatus3.Location = New System.Drawing.Point(66, 90)
Me.lblStatus3.Name = "lblStatus3"
Me.lblStatus3.Size = New System.Drawing.Size(446, 13)
Me.lblStatus3.TabIndex = 4
'
'pbTime
'
Me.pbTime.Location = New System.Drawing.Point(36, 106)
Me.pbTime.Name = "pbTime"
Me.pbTime.Size = New System.Drawing.Size(24, 24)
Me.pbTime.TabIndex = 18
Me.pbTime.TabStop = False
'
'frmMain
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(524, 372)
Me.ClientSize = New System.Drawing.Size(524, 386)
Me.Controls.Add(Me.pbTime)
Me.Controls.Add(Me.lblStatus3)
Me.Controls.Add(Me.lblStatus2)
Me.Controls.Add(Me.lblStatus1)
Me.Controls.Add(Me.btnCancelOperation)
Me.Controls.Add(Me.txtGameInfo)
Me.Controls.Add(Me.lblTimeSpent)
Me.Controls.Add(Me.lblTimeTitle)
Me.Controls.Add(Me.lblLastActionTitle)
Me.Controls.Add(Me.lblLastAction)
Me.Controls.Add(Me.lblGameTitle)
@@ -536,6 +518,7 @@ Partial Class frmMain
Me.gMonMainMenu.ResumeLayout(False)
Me.gMonMainMenu.PerformLayout()
CType(Me.pbIcon, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.pbTime, System.ComponentModel.ISupportInitialize).EndInit()
Me.ResumeLayout(False)
Me.PerformLayout()
@@ -572,22 +555,10 @@ Partial Class frmMain
Friend WithEvents lblLastAction As System.Windows.Forms.Label
Friend WithEvents lblLastActionTitle As System.Windows.Forms.Label
Friend WithEvents gMonTools As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonToolsSyncMan As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonTrayTools As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonTrayToolsSyncMan As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonSetupAddWizard As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonTraySetupAddWizard As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents lblTimeTitle As System.Windows.Forms.Label
Friend WithEvents lblTimeSpent As System.Windows.Forms.Label
Friend WithEvents txtGameInfo As System.Windows.Forms.TextBox
Friend WithEvents gMonToolsGameList As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonToolsGameImportOfficialList As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonToolsGameImportList As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonToolsGameExportList As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonTrayToolsGameList As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonTrayToolsGameImportList As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonTrayToolsGameExportList As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonTrayToolsGameImportOfficialList As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonSetupGameManager As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonSetupCustomVariables As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonToolsCompact As System.Windows.Forms.ToolStripMenuItem
@@ -598,4 +569,13 @@ Partial Class frmMain
Friend WithEvents gMonStripAdminButton As ToolStripSplitButton
Friend WithEvents gMonTraySetupTags As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonSetupTags As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents lblStatus1 As Label
Friend WithEvents lblStatus2 As Label
Friend WithEvents lblStatus3 As Label
Friend WithEvents gMonNotification As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonTrayNotification As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonHelpWebSite As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents pbTime As System.Windows.Forms.PictureBox
Friend WithEvents gMonTrayToolsCleanMan As System.Windows.Forms.ToolStripMenuItem
Friend WithEvents gMonToolsCleanMan As System.Windows.Forms.ToolStripMenuItem
End Class
+312 -253
View File
File diff suppressed because it is too large Load Diff
+60 -24
View File
@@ -34,10 +34,12 @@ Partial Class frmSettings
Me.btnBackupFolder = New System.Windows.Forms.Button()
Me.lblBackupFolder = New System.Windows.Forms.Label()
Me.txtBackupFolder = New System.Windows.Forms.TextBox()
Me.fbBrowser = New System.Windows.Forms.FolderBrowserDialog()
Me.btnSave = New System.Windows.Forms.Button()
Me.btnCancel = New System.Windows.Forms.Button()
Me.grpBackup = New System.Windows.Forms.GroupBox()
Me.lblMinutes = New System.Windows.Forms.Label()
Me.nudSupressBackupThreshold = New System.Windows.Forms.NumericUpDown()
Me.chkSupressBackup = New System.Windows.Forms.CheckBox()
Me.chkCheckSum = New System.Windows.Forms.CheckBox()
Me.chkRestoreOnLaunch = New System.Windows.Forms.CheckBox()
Me.chkOverwriteWarning = New System.Windows.Forms.CheckBox()
@@ -45,6 +47,7 @@ Partial Class frmSettings
Me.grpGeneral.SuspendLayout()
Me.grpPaths.SuspendLayout()
Me.grpBackup.SuspendLayout()
CType(Me.nudSupressBackupThreshold, System.ComponentModel.ISupportInitialize).BeginInit()
Me.SuspendLayout()
'
'chkMonitorOnStartup
@@ -60,10 +63,10 @@ Partial Class frmSettings
'chkBackupConfirm
'
Me.chkBackupConfirm.AutoSize = True
Me.chkBackupConfirm.Location = New System.Drawing.Point(6, 19)
Me.chkBackupConfirm.Location = New System.Drawing.Point(6, 42)
Me.chkBackupConfirm.Name = "chkBackupConfirm"
Me.chkBackupConfirm.Size = New System.Drawing.Size(160, 17)
Me.chkBackupConfirm.TabIndex = 0
Me.chkBackupConfirm.TabIndex = 1
Me.chkBackupConfirm.Text = "Disable backup confirmation"
Me.chkBackupConfirm.UseVisualStyleBackColor = True
'
@@ -88,7 +91,7 @@ Partial Class frmSettings
Me.chkTimeTracking.Location = New System.Drawing.Point(6, 111)
Me.chkTimeTracking.Name = "chkTimeTracking"
Me.chkTimeTracking.Size = New System.Drawing.Size(122, 17)
Me.chkTimeTracking.TabIndex = 5
Me.chkTimeTracking.TabIndex = 4
Me.chkTimeTracking.Text = "Enable time tracking"
Me.chkTimeTracking.UseVisualStyleBackColor = True
'
@@ -108,7 +111,7 @@ Partial Class frmSettings
Me.chkSync.Location = New System.Drawing.Point(6, 134)
Me.chkSync.Name = "chkSync"
Me.chkSync.Size = New System.Drawing.Size(208, 17)
Me.chkSync.TabIndex = 4
Me.chkSync.TabIndex = 5
Me.chkSync.Text = "Sync game list data with backup folder"
Me.chkSync.UseVisualStyleBackColor = True
'
@@ -117,9 +120,9 @@ Partial Class frmSettings
Me.chkShowDetectionTips.AutoSize = True
Me.chkShowDetectionTips.Location = New System.Drawing.Point(6, 88)
Me.chkShowDetectionTips.Name = "chkShowDetectionTips"
Me.chkShowDetectionTips.Size = New System.Drawing.Size(136, 17)
Me.chkShowDetectionTips.Size = New System.Drawing.Size(159, 17)
Me.chkShowDetectionTips.TabIndex = 3
Me.chkShowDetectionTips.Text = "Show detection tooltips"
Me.chkShowDetectionTips.Text = "Show detection notifications"
Me.chkShowDetectionTips.UseVisualStyleBackColor = True
'
'chkStartToTray
@@ -137,7 +140,7 @@ Partial Class frmSettings
Me.grpPaths.Controls.Add(Me.btnBackupFolder)
Me.grpPaths.Controls.Add(Me.lblBackupFolder)
Me.grpPaths.Controls.Add(Me.txtBackupFolder)
Me.grpPaths.Location = New System.Drawing.Point(12, 331)
Me.grpPaths.Location = New System.Drawing.Point(12, 360)
Me.grpPaths.Name = "grpPaths"
Me.grpPaths.Size = New System.Drawing.Size(360, 60)
Me.grpPaths.TabIndex = 2
@@ -172,7 +175,7 @@ Partial Class frmSettings
'btnSave
'
Me.btnSave.DialogResult = System.Windows.Forms.DialogResult.OK
Me.btnSave.Location = New System.Drawing.Point(216, 397)
Me.btnSave.Location = New System.Drawing.Point(216, 426)
Me.btnSave.Name = "btnSave"
Me.btnSave.Size = New System.Drawing.Size(75, 23)
Me.btnSave.TabIndex = 3
@@ -182,7 +185,7 @@ Partial Class frmSettings
'btnCancel
'
Me.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel
Me.btnCancel.Location = New System.Drawing.Point(297, 397)
Me.btnCancel.Location = New System.Drawing.Point(297, 426)
Me.btnCancel.Name = "btnCancel"
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
Me.btnCancel.TabIndex = 4
@@ -191,6 +194,9 @@ Partial Class frmSettings
'
'grpBackup
'
Me.grpBackup.Controls.Add(Me.lblMinutes)
Me.grpBackup.Controls.Add(Me.nudSupressBackupThreshold)
Me.grpBackup.Controls.Add(Me.chkSupressBackup)
Me.grpBackup.Controls.Add(Me.chkCheckSum)
Me.grpBackup.Controls.Add(Me.chkRestoreOnLaunch)
Me.grpBackup.Controls.Add(Me.chkOverwriteWarning)
@@ -198,29 +204,56 @@ Partial Class frmSettings
Me.grpBackup.Controls.Add(Me.chkBackupConfirm)
Me.grpBackup.Location = New System.Drawing.Point(12, 183)
Me.grpBackup.Name = "grpBackup"
Me.grpBackup.Size = New System.Drawing.Size(360, 142)
Me.grpBackup.Size = New System.Drawing.Size(360, 171)
Me.grpBackup.TabIndex = 1
Me.grpBackup.TabStop = False
Me.grpBackup.Text = "Backup and Restore Options"
Me.grpBackup.Text = "Backup and Restore"
'
'lblMinutes
'
Me.lblMinutes.AutoSize = True
Me.lblMinutes.Location = New System.Drawing.Point(286, 135)
Me.lblMinutes.Name = "lblMinutes"
Me.lblMinutes.Size = New System.Drawing.Size(43, 13)
Me.lblMinutes.TabIndex = 7
Me.lblMinutes.Text = "minutes"
'
'nudSupressBackupThreshold
'
Me.nudSupressBackupThreshold.Location = New System.Drawing.Point(229, 133)
Me.nudSupressBackupThreshold.Maximum = New Decimal(New Integer() {999, 0, 0, 0})
Me.nudSupressBackupThreshold.Name = "nudSupressBackupThreshold"
Me.nudSupressBackupThreshold.Size = New System.Drawing.Size(51, 20)
Me.nudSupressBackupThreshold.TabIndex = 6
'
'chkSupressBackup
'
Me.chkSupressBackup.AutoSize = True
Me.chkSupressBackup.Location = New System.Drawing.Point(6, 134)
Me.chkSupressBackup.Name = "chkSupressBackup"
Me.chkSupressBackup.Size = New System.Drawing.Size(217, 17)
Me.chkSupressBackup.TabIndex = 5
Me.chkSupressBackup.Text = "Backup only when session time exceeds"
Me.chkSupressBackup.UseVisualStyleBackColor = True
'
'chkCheckSum
'
Me.chkCheckSum.AutoSize = True
Me.chkCheckSum.Location = New System.Drawing.Point(6, 111)
Me.chkCheckSum.Location = New System.Drawing.Point(6, 88)
Me.chkCheckSum.Name = "chkCheckSum"
Me.chkCheckSum.Size = New System.Drawing.Size(195, 17)
Me.chkCheckSum.TabIndex = 4
Me.chkCheckSum.TabIndex = 3
Me.chkCheckSum.Text = "Verify backup files with a checksum"
Me.chkCheckSum.UseVisualStyleBackColor = True
'
'chkRestoreOnLaunch
'
Me.chkRestoreOnLaunch.AutoSize = True
Me.chkRestoreOnLaunch.Location = New System.Drawing.Point(6, 88)
Me.chkRestoreOnLaunch.Location = New System.Drawing.Point(6, 111)
Me.chkRestoreOnLaunch.Name = "chkRestoreOnLaunch"
Me.chkRestoreOnLaunch.Size = New System.Drawing.Size(249, 17)
Me.chkRestoreOnLaunch.TabIndex = 3
Me.chkRestoreOnLaunch.Text = "Check for new backup files to restore at launch"
Me.chkRestoreOnLaunch.Size = New System.Drawing.Size(257, 17)
Me.chkRestoreOnLaunch.TabIndex = 4
Me.chkRestoreOnLaunch.Text = "Notify when there are new backup files to restore"
Me.chkRestoreOnLaunch.UseVisualStyleBackColor = True
'
'chkOverwriteWarning
@@ -236,18 +269,18 @@ Partial Class frmSettings
'chkCreateFolder
'
Me.chkCreateFolder.AutoSize = True
Me.chkCreateFolder.Location = New System.Drawing.Point(6, 42)
Me.chkCreateFolder.Location = New System.Drawing.Point(6, 19)
Me.chkCreateFolder.Name = "chkCreateFolder"
Me.chkCreateFolder.Size = New System.Drawing.Size(211, 17)
Me.chkCreateFolder.TabIndex = 1
Me.chkCreateFolder.Text = "Create a sub-folder for each application"
Me.chkCreateFolder.Size = New System.Drawing.Size(186, 17)
Me.chkCreateFolder.TabIndex = 0
Me.chkCreateFolder.Text = "Create a sub-folder for each game"
Me.chkCreateFolder.UseVisualStyleBackColor = True
'
'frmSettings
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(384, 431)
Me.ClientSize = New System.Drawing.Size(384, 461)
Me.Controls.Add(Me.grpBackup)
Me.Controls.Add(Me.btnCancel)
Me.Controls.Add(Me.btnSave)
@@ -267,6 +300,7 @@ Partial Class frmSettings
Me.grpPaths.PerformLayout()
Me.grpBackup.ResumeLayout(False)
Me.grpBackup.PerformLayout()
CType(Me.nudSupressBackupThreshold, System.ComponentModel.ISupportInitialize).EndInit()
Me.ResumeLayout(False)
End Sub
@@ -275,7 +309,6 @@ Partial Class frmSettings
Friend WithEvents grpGeneral As System.Windows.Forms.GroupBox
Friend WithEvents grpPaths As System.Windows.Forms.GroupBox
Friend WithEvents txtBackupFolder As System.Windows.Forms.TextBox
Friend WithEvents fbBrowser As System.Windows.Forms.FolderBrowserDialog
Friend WithEvents btnSave As System.Windows.Forms.Button
Friend WithEvents btnCancel As System.Windows.Forms.Button
Friend WithEvents lblBackupFolder As System.Windows.Forms.Label
@@ -290,4 +323,7 @@ Partial Class frmSettings
Friend WithEvents chkCheckSum As System.Windows.Forms.CheckBox
Friend WithEvents chkStartWindows As System.Windows.Forms.CheckBox
Friend WithEvents chkTimeTracking As System.Windows.Forms.CheckBox
Friend WithEvents lblMinutes As Label
Friend WithEvents nudSupressBackupThreshold As NumericUpDown
Friend WithEvents chkSupressBackup As CheckBox
End Class
-3
View File
@@ -117,9 +117,6 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="fbBrowser.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>32</value>
</metadata>
+43 -6
View File
@@ -1,4 +1,6 @@
Public Class frmSettings
Imports GBM.My.Resources
Public Class frmSettings
Dim bShutdown As Boolean = False
Dim bBackupLocationChanged As Boolean = False
Dim bCheckSumDisabled As Boolean = False
@@ -54,6 +56,8 @@
oSettings.ShowOverwriteWarning = chkOverwriteWarning.Checked
oSettings.RestoreOnLaunch = chkRestoreOnLaunch.Checked
oSettings.TimeTracking = chkTimeTracking.Checked
oSettings.SupressBackup = chkSupressBackup.Checked
oSettings.SupressBackupThreshold = nudSupressBackupThreshold.Value
'We need to clear all checksums its turned off
If chkCheckSum.Checked = False And oSettings.CheckSum = True Then
@@ -73,7 +77,7 @@
End If
oSettings.BackupFolder = txtBackupFolder.Text
Else
MsgBox("The backup folder does not exist. Please choose a valid backup folder.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmSettings_ErrorBackupFolder, MsgBoxStyle.Exclamation)
Return False
End If
@@ -104,6 +108,9 @@
chkSync.Checked = oSettings.Sync
chkCheckSum.Checked = oSettings.CheckSum
chkTimeTracking.Checked = oSettings.TimeTracking
chkSupressBackup.Checked = oSettings.SupressBackup
nudSupressBackupThreshold.Value = oSettings.SupressBackupThreshold
nudSupressBackupThreshold.Enabled = chkSupressBackup.Checked
End Sub
Private Sub btnSave_Click(sender As System.Object, e As System.EventArgs) Handles btnSave.Click
@@ -124,15 +131,45 @@
End If
End Sub
Private Sub SetForm()
'Set Form Name
Me.Text = frmSettings_FormName
'Set Form Text
grpBackup.Text = frmSettings_grpBackup
lblMinutes.Text = frmSettings_lblMinutes
chkSupressBackup.Text = frmSettings_chkSupressBackup
chkCheckSum.Text = frmSettings_chkCheckSum
chkRestoreOnLaunch.Text = frmSettings_chkRestoreOnLaunch
chkOverwriteWarning.Text = frmSettings_chkOverwriteWarning
chkCreateFolder.Text = frmSettings_chkCreateFolder
chkBackupConfirm.Text = frmSettings_chkBackupConfirm
btnCancel.Text = frmSettings_btnCancel
btnSave.Text = frmSettings_btnSave
grpPaths.Text = frmSettings_grpPaths
btnBackupFolder.Text = frmSettings_btnBackupFolder
lblBackupFolder.Text = frmSettings_lblBackupFolder
grpGeneral.Text = frmSettings_grpGeneral
chkTimeTracking.Text = frmSettings_chkTimeTracking
chkStartWindows.Text = frmSettings_chkStartWindows
chkSync.Text = frmSettings_chkSync
chkShowDetectionTips.Text = frmSettings_chkShowDetectionTips
chkStartToTray.Text = frmSettings_chkStartToTray
chkMonitorOnStartup.Text = frmSettings_chkMonitorOnStartup
End Sub
Private Sub frmSettings_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
SetForm()
LoadSettings()
End Sub
Private Sub btnBackupFolder_Click(sender As System.Object, e As System.EventArgs) Handles btnBackupFolder.Click
fbBrowser.SelectedPath = oSettings.BackupFolder
If fbBrowser.ShowDialog() = Windows.Forms.DialogResult.OK Then
txtBackupFolder.Text = fbBrowser.SelectedPath
End If
Dim sNewFolder As String
sNewFolder = mgrCommon.OpenFolderBrowser(frmSettings_BrowseFolder, oSettings.BackupFolder, True)
If sNewFolder <> String.Empty Then txtBackupFolder.Text = sNewFolder
End Sub
Private Sub chkSupressBackup_CheckedChanged(sender As Object, e As EventArgs) Handles chkSupressBackup.CheckedChanged
nudSupressBackupThreshold.Enabled = chkSupressBackup.Checked
End Sub
End Class
+48 -57
View File
@@ -25,11 +25,10 @@ Partial Class frmStartUpWizard
Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmStartUpWizard))
Me.tabWizard = New System.Windows.Forms.TabControl()
Me.tbPage1 = New System.Windows.Forms.TabPage()
Me.lblStep1Instructions3 = New System.Windows.Forms.Label()
Me.lblStep1Instructions2 = New System.Windows.Forms.Label()
Me.llbManual = New System.Windows.Forms.LinkLabel()
Me.lblStep1Title = New System.Windows.Forms.Label()
Me.lblStep1Instructions = New System.Windows.Forms.Label()
Me.lblStep1Intro = New System.Windows.Forms.Label()
Me.tbPage2 = New System.Windows.Forms.TabPage()
Me.chkSync = New System.Windows.Forms.CheckBox()
Me.chkCreateFolder = New System.Windows.Forms.CheckBox()
@@ -74,11 +73,10 @@ Partial Class frmStartUpWizard
'tbPage1
'
Me.tbPage1.BackColor = System.Drawing.SystemColors.Control
Me.tbPage1.Controls.Add(Me.lblStep1Instructions3)
Me.tbPage1.Controls.Add(Me.lblStep1Instructions2)
Me.tbPage1.Controls.Add(Me.llbManual)
Me.tbPage1.Controls.Add(Me.lblStep1Title)
Me.tbPage1.Controls.Add(Me.lblStep1Instructions)
Me.tbPage1.Controls.Add(Me.lblStep1Intro)
Me.tbPage1.Location = New System.Drawing.Point(4, 22)
Me.tbPage1.Name = "tbPage1"
Me.tbPage1.Padding = New System.Windows.Forms.Padding(3)
@@ -86,24 +84,26 @@ Partial Class frmStartUpWizard
Me.tbPage1.TabIndex = 0
Me.tbPage1.Text = "TabPage1"
'
'lblStep1Instructions3
'
Me.lblStep1Instructions3.AutoSize = True
Me.lblStep1Instructions3.Location = New System.Drawing.Point(14, 160)
Me.lblStep1Instructions3.Name = "lblStep1Instructions3"
Me.lblStep1Instructions3.Size = New System.Drawing.Size(310, 13)
Me.lblStep1Instructions3.TabIndex = 10
Me.lblStep1Instructions3.Text = "GBM was designed and tested using the Dropbox cloud service."
'
'lblStep1Instructions2
'
Me.lblStep1Instructions2.Location = New System.Drawing.Point(14, 106)
Me.lblStep1Instructions2.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!)
Me.lblStep1Instructions2.Location = New System.Drawing.Point(14, 91)
Me.lblStep1Instructions2.Name = "lblStep1Instructions2"
Me.lblStep1Instructions2.Size = New System.Drawing.Size(303, 42)
Me.lblStep1Instructions2.TabIndex = 9
Me.lblStep1Instructions2.Text = "Before proceeding you may want to sign up for a cloud service and install their c" & _
"lient software. GBM works best when paired with a cloud service and client but " & _
"is not required!"
Me.lblStep1Instructions2.Size = New System.Drawing.Size(303, 53)
Me.lblStep1Instructions2.TabIndex = 2
Me.lblStep1Instructions2.Text = "If you'd like to learn about advanced features or have any other questions before" & _
" you get started, there is a detailed online manual available."
'
'llbManual
'
Me.llbManual.AutoSize = True
Me.llbManual.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!)
Me.llbManual.Location = New System.Drawing.Point(14, 158)
Me.llbManual.Name = "llbManual"
Me.llbManual.Size = New System.Drawing.Size(151, 13)
Me.llbManual.TabIndex = 3
Me.llbManual.TabStop = True
Me.llbManual.Text = "Game Backup Monitor Manual"
'
'lblStep1Title
'
@@ -112,25 +112,17 @@ Partial Class frmStartUpWizard
Me.lblStep1Title.Location = New System.Drawing.Point(13, 11)
Me.lblStep1Title.Name = "lblStep1Title"
Me.lblStep1Title.Size = New System.Drawing.Size(148, 20)
Me.lblStep1Title.TabIndex = 8
Me.lblStep1Title.TabIndex = 0
Me.lblStep1Title.Text = "Welcome to GBM"
'
'lblStep1Instructions
'
Me.lblStep1Instructions.Location = New System.Drawing.Point(14, 64)
Me.lblStep1Instructions.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!)
Me.lblStep1Instructions.Location = New System.Drawing.Point(14, 41)
Me.lblStep1Instructions.Name = "lblStep1Instructions"
Me.lblStep1Instructions.Size = New System.Drawing.Size(303, 42)
Me.lblStep1Instructions.TabIndex = 6
Me.lblStep1Instructions.Text = "This wizard will guide you through some easy setup steps to get started."
'
'lblStep1Intro
'
Me.lblStep1Intro.AutoSize = True
Me.lblStep1Intro.Location = New System.Drawing.Point(14, 41)
Me.lblStep1Intro.Name = "lblStep1Intro"
Me.lblStep1Intro.Size = New System.Drawing.Size(213, 13)
Me.lblStep1Intro.TabIndex = 5
Me.lblStep1Intro.Text = "Thank you for trying Game Backup Monitor!"
Me.lblStep1Instructions.Size = New System.Drawing.Size(303, 36)
Me.lblStep1Instructions.TabIndex = 1
Me.lblStep1Instructions.Text = "This guide will help you through some quick and easy steps to get started."
'
'tbPage2
'
@@ -154,9 +146,9 @@ Partial Class frmStartUpWizard
Me.chkSync.AutoSize = True
Me.chkSync.Location = New System.Drawing.Point(17, 105)
Me.chkSync.Name = "chkSync"
Me.chkSync.Size = New System.Drawing.Size(258, 17)
Me.chkSync.TabIndex = 13
Me.chkSync.Text = "Sync with existing GBM data in the backup folder"
Me.chkSync.Size = New System.Drawing.Size(261, 17)
Me.chkSync.TabIndex = 5
Me.chkSync.Text = "Import any existing GBM data in the backup folder"
Me.chkSync.UseVisualStyleBackColor = True
'
'chkCreateFolder
@@ -164,9 +156,9 @@ Partial Class frmStartUpWizard
Me.chkCreateFolder.AutoSize = True
Me.chkCreateFolder.Location = New System.Drawing.Point(17, 83)
Me.chkCreateFolder.Name = "chkCreateFolder"
Me.chkCreateFolder.Size = New System.Drawing.Size(211, 17)
Me.chkCreateFolder.TabIndex = 12
Me.chkCreateFolder.Text = "Create a sub-folder for each application"
Me.chkCreateFolder.Size = New System.Drawing.Size(186, 17)
Me.chkCreateFolder.TabIndex = 4
Me.chkCreateFolder.Text = "Create a sub-folder for each game"
Me.chkCreateFolder.UseVisualStyleBackColor = True
'
'lblStep2Title
@@ -176,23 +168,24 @@ Partial Class frmStartUpWizard
Me.lblStep2Title.Location = New System.Drawing.Point(13, 11)
Me.lblStep2Title.Name = "lblStep2Title"
Me.lblStep2Title.Size = New System.Drawing.Size(143, 20)
Me.lblStep2Title.TabIndex = 11
Me.lblStep2Title.TabIndex = 0
Me.lblStep2Title.Text = "Backup Location"
'
'lblStep2Instructions
'
Me.lblStep2Instructions.Location = New System.Drawing.Point(14, 125)
Me.lblStep2Instructions.Location = New System.Drawing.Point(14, 151)
Me.lblStep2Instructions.Name = "lblStep2Instructions"
Me.lblStep2Instructions.Size = New System.Drawing.Size(335, 57)
Me.lblStep2Instructions.TabIndex = 10
Me.lblStep2Instructions.Text = resources.GetString("lblStep2Instructions.Text")
Me.lblStep2Instructions.Size = New System.Drawing.Size(335, 31)
Me.lblStep2Instructions.TabIndex = 6
Me.lblStep2Instructions.Text = "GBM will store all your backup files along with a manifest database (gbm.s3db) in" & _
" this location. "
'
'btnFolderBrowse
'
Me.btnFolderBrowse.Location = New System.Drawing.Point(322, 56)
Me.btnFolderBrowse.Name = "btnFolderBrowse"
Me.btnFolderBrowse.Size = New System.Drawing.Size(27, 20)
Me.btnFolderBrowse.TabIndex = 8
Me.btnFolderBrowse.TabIndex = 3
Me.btnFolderBrowse.Text = "..."
Me.btnFolderBrowse.UseVisualStyleBackColor = True
'
@@ -202,7 +195,7 @@ Partial Class frmStartUpWizard
Me.txtBackupPath.Location = New System.Drawing.Point(17, 57)
Me.txtBackupPath.Name = "txtBackupPath"
Me.txtBackupPath.Size = New System.Drawing.Size(300, 20)
Me.txtBackupPath.TabIndex = 6
Me.txtBackupPath.TabIndex = 2
'
'lblStep2Intro
'
@@ -210,7 +203,7 @@ Partial Class frmStartUpWizard
Me.lblStep2Intro.Location = New System.Drawing.Point(14, 41)
Me.lblStep2Intro.Name = "lblStep2Intro"
Me.lblStep2Intro.Size = New System.Drawing.Size(219, 13)
Me.lblStep2Intro.TabIndex = 7
Me.lblStep2Intro.TabIndex = 1
Me.lblStep2Intro.Text = "Choose where GBM saves your backup files:"
'
'tbPage3
@@ -291,8 +284,8 @@ Partial Class frmStartUpWizard
Me.lblStep4Instructions3.Name = "lblStep4Instructions3"
Me.lblStep4Instructions3.Size = New System.Drawing.Size(303, 33)
Me.lblStep4Instructions3.TabIndex = 18
Me.lblStep4Instructions3.Text = "To change anything you've setup in this wizard and see more settings and features" & _
", explore the menus in the application,"
Me.lblStep4Instructions3.Text = "You can change anything you've setup in this wizard and find more settings and fe" & _
"atures by exploring the menus. Thanks!"
'
'lblStep4Instructions2
'
@@ -318,15 +311,14 @@ Partial Class frmStartUpWizard
Me.lblStep4Instructions.Name = "lblStep4Instructions"
Me.lblStep4Instructions.Size = New System.Drawing.Size(303, 31)
Me.lblStep4Instructions.TabIndex = 12
Me.lblStep4Instructions.Text = "That's all there is to it! GBM will automatically monitor and backup your applic" & _
"ations each time they are closed."
Me.lblStep4Instructions.Text = "GBM will automatically monitor and backup your games each time they are closed."
'
'btnNext
'
Me.btnNext.Location = New System.Drawing.Point(272, 202)
Me.btnNext.Name = "btnNext"
Me.btnNext.Size = New System.Drawing.Size(75, 23)
Me.btnNext.TabIndex = 11
Me.btnNext.TabIndex = 2
Me.btnNext.Text = "&Next"
Me.btnNext.UseVisualStyleBackColor = True
'
@@ -335,7 +327,7 @@ Partial Class frmStartUpWizard
Me.btnBack.Location = New System.Drawing.Point(191, 202)
Me.btnBack.Name = "btnBack"
Me.btnBack.Size = New System.Drawing.Size(75, 23)
Me.btnBack.TabIndex = 10
Me.btnBack.TabIndex = 1
Me.btnBack.Text = "&Back"
Me.btnBack.UseVisualStyleBackColor = True
'
@@ -353,7 +345,7 @@ Partial Class frmStartUpWizard
Me.Name = "frmStartUpWizard"
Me.ShowIcon = False
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent
Me.Text = "GBM Setup Wizard"
Me.Text = "GBM Setup"
Me.tabWizard.ResumeLayout(False)
Me.tbPage1.ResumeLayout(False)
Me.tbPage1.PerformLayout()
@@ -374,7 +366,6 @@ Partial Class frmStartUpWizard
Friend WithEvents tbPage3 As System.Windows.Forms.TabPage
Friend WithEvents tbPage4 As System.Windows.Forms.TabPage
Friend WithEvents lblStep1Instructions As System.Windows.Forms.Label
Friend WithEvents lblStep1Intro As System.Windows.Forms.Label
Friend WithEvents lblStep2Instructions As System.Windows.Forms.Label
Friend WithEvents btnFolderBrowse As System.Windows.Forms.Button
Friend WithEvents txtBackupPath As System.Windows.Forms.TextBox
@@ -385,8 +376,6 @@ Partial Class frmStartUpWizard
Friend WithEvents lblStep2Title As System.Windows.Forms.Label
Friend WithEvents lblStep3Title As System.Windows.Forms.Label
Friend WithEvents lblStep4Title As System.Windows.Forms.Label
Friend WithEvents lblStep1Instructions2 As System.Windows.Forms.Label
Friend WithEvents lblStep1Instructions3 As System.Windows.Forms.Label
Friend WithEvents chkCreateFolder As System.Windows.Forms.CheckBox
Friend WithEvents btnDownloadList As System.Windows.Forms.Button
Friend WithEvents btnOpenWizard As System.Windows.Forms.Button
@@ -394,4 +383,6 @@ Partial Class frmStartUpWizard
Friend WithEvents lblStep4Instructions3 As System.Windows.Forms.Label
Friend WithEvents lblStep4Instructions2 As System.Windows.Forms.Label
Friend WithEvents chkSync As System.Windows.Forms.CheckBox
Friend WithEvents lblStep1Instructions2 As System.Windows.Forms.Label
Friend WithEvents llbManual As System.Windows.Forms.LinkLabel
End Class
+1 -4
View File
@@ -117,10 +117,7 @@
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="lblStep2Instructions.Text" xml:space="preserve">
<value>GBM will store all your backup files in this location. It's best to use a cloud folder so your backups are automatically uploaded as soon as they are completed. GBM also stores a file called gbm.s3db in this location, this is how your backups are tracked so don't delete it!</value>
</data>
<data name="lblStep3Intro.Text" xml:space="preserve">
<value>Before you can start monitoring for games, they need to be configured so GBM knows what to look for and how to handle them. You can download configurations from the official pre-configured list or add them all yourself.</value>
<value>Before you can start monitoring for games, they need to be configured so GBM knows what to look for and how to handle them. You can download pre-made configurations from the official list or add them all yourself using the tools below. You can also skip this step for now!</value>
</data>
</root>
+47 -15
View File
@@ -1,4 +1,5 @@
Imports System.IO
Imports GBM.My.Resources
Imports System.IO
Public Class frmStartUpWizard
@@ -26,7 +27,34 @@ Public Class frmStartUpWizard
Private eCurrentStep As eSteps = eSteps.Step1
Private Sub FormInit()
Private Sub SetForm()
'Set Form Name
Me.Text = frmStartUpWizard_FormName
'Set Form Text
btnNext.Text = frmStartUpWizard_btnNext
btnBack.Text = frmStartUpWizard_btnBack
lblStep1Instructions2.Text = frmStartUpWizard_lblStep1Instructions2
llbManual.Text = frmStartUpWizard_llbManual
lblStep1Title.Text = frmStartUpWizard_lblStep1Title
lblStep1Instructions.Text = frmStartUpWizard_lblStep1Instructions
chkSync.Text = frmStartUpWizard_chkSync
chkCreateFolder.Text = frmStartUpWizard_chkCreateFolder
lblStep2Title.Text = frmStartUpWizard_lblStep2Title
lblStep2Instructions.Text = frmStartUpWizard_lblStep2Instructions
btnFolderBrowse.Text = frmStartUpWizard_btnFolderBrowse
lblStep2Intro.Text = frmStartUpWizard_lblStep2Intro
btnOpenWizard.Text = frmStartUpWizard_btnOpenWizard
btnOpenMonitorList.Text = frmStartUpWizard_btnOpenMonitorList
btnDownloadList.Text = frmStartUpWizard_btnDownloadList
lblStep3Title.Text = frmStartUpWizard_lblStep3Title
lblStep3Intro.Text = frmStartUpWizard_lblStep3Intro
lblStep4Instructions3.Text = frmStartUpWizard_lblStep4Instructions3
lblStep4Instructions2.Text = frmStartUpWizard_lblStep4Instructions2
lblStep4Title.Text = frmStartUpWizard_lblStep4Title
lblStep4Instructions.Text = frmStartUpWizard_lblStep4Instructions
llbManual.Links.Add(0, 26, App_URLManual)
LoadGameSettings()
StepHandler()
End Sub
@@ -39,7 +67,7 @@ Public Class frmStartUpWizard
'Make sure database is the latest version
oDatabase.DatabaseUpgrade()
mgrMonitorList.SyncMonitorLists(False)
MsgBox("Existing data was detected in the backup folder and has been imported.", MsgBoxStyle.Information, "Game Backup Monitor")
mgrCommon.ShowMessage(frmStartUpWizard_ExistingData, MsgBoxStyle.Information)
End If
End Sub
@@ -59,20 +87,20 @@ Public Class frmStartUpWizard
Case eSteps.Step3
btnBack.Enabled = False
btnNext.Enabled = True
btnNext.Text = "&Next"
btnNext.Text = frmStartUpWizard_btnNext
tabWizard.SelectTab(2)
Case eSteps.Step4
btnBack.Enabled = True
btnNext.Enabled = True
btnNext.Text = "&Finish"
btnNext.Text = frmStartUpWizard_btnNext_Finish
tabWizard.SelectTab(3)
End Select
End Sub
Private Sub DownloadSettings()
If MsgBox("Would you like to import from the latest pre-configured game list?", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrMonitorList.DoImport(mgrPath.OfficialImportURL) Then
oGameData = mgrMonitorList.ReadList(mgrMonitorList.eListTypes.ScanList)
If mgrCommon.ShowMessage(frmStartUpWizard_ConfirmOfficialImport, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
If mgrMonitorList.DoImport(App_URLImport) Then
oGameData = mgrMonitorList.ReadList(mgrMonitorList.eListTypes.FullList)
If oSettings.Sync Then mgrMonitorList.SyncMonitorLists()
End If
End If
@@ -80,7 +108,7 @@ Public Class frmStartUpWizard
Private Sub LoadGameSettings()
'Load Game XML
oGameData = mgrMonitorList.ReadList(mgrMonitorList.eListTypes.ScanList)
oGameData = mgrMonitorList.ReadList(mgrMonitorList.eListTypes.FullList)
End Sub
Private Sub OpenGameWizard()
@@ -102,19 +130,19 @@ Public Class frmStartUpWizard
Private Function ValidateBackupPath(ByVal strPath As String, ByRef sErrorMessage As String) As Boolean
If strPath = String.Empty Then
sErrorMessage = "You must select a backup path to continue."
sErrorMessage = frmStartUpWizard_ErrorNoFolder
txtBackupPath.Focus()
Return False
End If
If Not Directory.Exists(strPath) Then
sErrorMessage = "The folder you selected does not exist or is not a valid folder."
sErrorMessage = frmStartUpWizard_ErrorNoFolderExists
txtBackupPath.Focus()
Return False
End If
If Not Path.IsPathRooted(strPath) Then
sErrorMessage = "The selected path must be a full path."
sErrorMessage = frmStartUpWizard_ErrorBadFolder
txtBackupPath.Focus()
Return False
End If
@@ -164,7 +192,7 @@ Public Class frmStartUpWizard
Me.Close()
End Select
If bError Then MsgBox(sErrorMessage, MsgBoxStyle.Exclamation, "Game Backup Monitor")
If bError Then mgrCommon.ShowMessage(sErrorMessage, MsgBoxStyle.Exclamation)
StepHandler()
End Sub
@@ -179,7 +207,7 @@ Public Class frmStartUpWizard
End If
End If
sNewPath = mgrCommon.OpenFolderBrowser("Choose GBM backup folder:", sDefaultFolder, False)
sNewPath = mgrCommon.OpenFolderBrowser(frmStartUpWizard_BrowseFolder, sDefaultFolder, True)
If sNewPath <> String.Empty Then txtBackupPath.Text = sNewPath
End Sub
@@ -193,7 +221,7 @@ Public Class frmStartUpWizard
End Sub
Private Sub frmStartUpWizard_Load(sender As Object, e As EventArgs) Handles MyBase.Load
FormInit()
SetForm()
End Sub
Private Sub btnFolderBrowse_Click(sender As Object, e As EventArgs) Handles btnFolderBrowse.Click
@@ -217,4 +245,8 @@ Public Class frmStartUpWizard
e.Cancel = True
End If
End Sub
Private Sub llbManual_LinkClicked(sender As Object, e As LinkLabelLinkClickedEventArgs) Handles llbManual.LinkClicked
Process.Start(e.Link.LinkData.ToString)
End Sub
End Class
+22 -5
View File
@@ -1,4 +1,6 @@
Public Class frmTags
Imports GBM.My.Resources
Public Class frmTags
Dim hshTagData As Hashtable
Private bIsDirty As Boolean = False
@@ -50,7 +52,7 @@
Private Function HandleDirty() As MsgBoxResult
Dim oResult As MsgBoxResult
oResult = MsgBox("There are unsaved changes on this form. Do you want to save?", MsgBoxStyle.YesNoCancel, "Game Backup Monitor")
oResult = mgrCommon.ShowMessage(App_ConfirmDirty, MsgBoxStyle.YesNoCancel)
Select Case oResult
Case MsgBoxResult.Yes
@@ -229,7 +231,7 @@
If lstTags.SelectedItems.Count > 0 Then
oTag = DirectCast(TagData(lstTags.SelectedItems(0).ToString), clsTag)
If MsgBox("Are you sure you want to delete " & oTag.Name & "? This cannot be undone." & vbCrLf & vbCrLf & "All games using this tag will have it removed.", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(frmTags_ConfirmDelete, oTag.Name, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
mgrTags.DoTagDelete(oTag.ID)
LoadData()
eCurrentMode = eModes.Disabled
@@ -248,13 +250,13 @@
Private Function CoreValidatation(ByVal oTag As clsTag) As Boolean
If txtName.Text = String.Empty Then
MsgBox("You must enter a valid tag name.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmTags_ErrorValidName, MsgBoxStyle.Exclamation)
txtName.Focus()
Return False
End If
If mgrTags.DoCheckDuplicate(oTag.Name, oTag.ID) Then
MsgBox("A tag with this name already exists.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmTags_ErrorTagDupe, MsgBoxStyle.Exclamation)
txtName.Focus()
Return False
End If
@@ -262,7 +264,22 @@
Return True
End Function
Private Sub SetForm()
'Set Form Name
Me.Text = frmTags_FormName
'Set Form Text
grpTag.Text = frmTags_grpTag
lblName.Text = frmTags_lblName
btnClose.Text = frmTags_btnClose
btnDelete.Text = frmTags_btnDelete
btnAdd.Text = frmTags_btnAdd
btnCancel.Text = frmTags_btnCancel
btnSave.Text = frmTags_btnSave
End Sub
Private Sub frmTags_Load(sender As Object, e As EventArgs) Handles MyBase.Load
SetForm()
LoadData()
ModeChange()
AssignDirtyHandlers(grpTag.Controls)
+25 -7
View File
@@ -1,4 +1,5 @@
Imports System.IO
Imports GBM.My.Resources
Imports System.IO
Public Class frmVariableManager
Dim hshVariableData As Hashtable
@@ -53,7 +54,7 @@ Public Class frmVariableManager
End If
End If
sNewPath = mgrCommon.OpenFolderBrowser("Choose the path the variable represents:", sDefaultFolder, False)
sNewPath = mgrCommon.OpenFolderBrowser(frmVariableManager_PathBrowse, sDefaultFolder, False)
If sNewPath <> String.Empty Then txtPath.Text = sNewPath
End Sub
@@ -67,7 +68,7 @@ Public Class frmVariableManager
Private Function HandleDirty() As MsgBoxResult
Dim oResult As MsgBoxResult
oResult = MsgBox("There are unsaved changes on this form. Do you want to save?", MsgBoxStyle.YesNoCancel, "Game Backup Monitor")
oResult = mgrCommon.ShowMessage(App_ConfirmDirty, MsgBoxStyle.YesNoCancel)
Select Case oResult
Case MsgBoxResult.Yes
@@ -251,7 +252,7 @@ Public Class frmVariableManager
If lstVariables.SelectedItems.Count > 0 Then
oCustomVariable = DirectCast(VariableData(lstVariables.SelectedItems(0).ToString), clsPathVariable)
If MsgBox("Are you sure you want to delete " & oCustomVariable.Name & "? This cannot be undone.", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(frmVariableManager_ConfirmDelete, oCustomVariable.Name, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
mgrVariables.DoVariableDelete(oCustomVariable.ID)
mgrVariables.DoPathUpdate(oCurrentVariable.FormattedName, oCurrentVariable.Path)
LoadData()
@@ -271,19 +272,19 @@ Public Class frmVariableManager
Private Function CoreValidatation(ByVal oCustomVariable As clsPathVariable) As Boolean
If txtName.Text = String.Empty Then
MsgBox("You must enter a valid path name.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmVariableManager_ErrorValidName, MsgBoxStyle.Exclamation)
txtName.Focus()
Return False
End If
If txtPath.Text = String.Empty Then
MsgBox("You must enter a valid path.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmVariableManager_ErrorValidPath, MsgBoxStyle.Exclamation)
txtPath.Focus()
Return False
End If
If mgrVariables.DoCheckDuplicate(oCustomVariable.Name, oCustomVariable.ID) Then
MsgBox("An custom variable with this name already exists.", MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(frmVariableManager_ErrorVariableDupe, MsgBoxStyle.Exclamation)
txtName.Focus()
Return False
End If
@@ -291,7 +292,24 @@ Public Class frmVariableManager
Return True
End Function
Private Sub SetForm()
'Set Form Name
Me.Text = frmVariableManager_FormName
'Set Form Text
btnCancel.Text = frmVariableManager_btnCancel
btnSave.Text = frmVariableManager_btnSave
grpVariable.Text = frmVariableManager_grpVariable
btnPathBrowse.Text = frmVariableManager_btnPathBrowse
lblPath.Text = frmVariableManager_lblPath
lblName.Text = frmVariableManager_lblName
btnClose.Text = frmVariableManager_btnClose
btnDelete.Text = frmVariableManager_btnDelete
btnAdd.Text = frmVariableManager_btnAdd
End Sub
Private Sub frmVariableManager_Load(sender As Object, e As EventArgs) Handles MyBase.Load
SetForm()
LoadData()
ModeChange()
AssignDirtyHandlers(grpVariable.Controls)
+18 -2
View File
@@ -150,6 +150,12 @@
<Compile Include="Forms\frmGameTags.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="Forms\frmIncludeExclude.Designer.vb">
<DependentUpon>frmIncludeExclude.vb</DependentUpon>
</Compile>
<Compile Include="Forms\frmIncludeExclude.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="Forms\frmStartUpWizard.Designer.vb">
<DependentUpon>frmStartUpWizard.vb</DependentUpon>
</Compile>
@@ -239,6 +245,9 @@
<EmbeddedResource Include="Forms\frmGameTags.resx">
<DependentUpon>frmGameTags.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Forms\frmIncludeExclude.resx">
<DependentUpon>frmIncludeExclude.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Forms\frmStartUpWizard.resx">
<DependentUpon>frmStartUpWizard.vb</DependentUpon>
<SubType>Designer</SubType>
@@ -264,9 +273,9 @@
</EmbeddedResource>
<EmbeddedResource Include="My Project\Resources.resx">
<Generator>VbMyResourcesResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
<CustomToolNamespace>My.Resources</CustomToolNamespace>
<SubType>Designer</SubType>
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
</EmbeddedResource>
</ItemGroup>
<ItemGroup>
@@ -305,16 +314,23 @@
</BootstrapperPackage>
</ItemGroup>
<ItemGroup>
<Content Include="gbm.ico" />
<Content Include="gbm.ico">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="License\credits.txt">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</Content>
<Content Include="References\System.Data.SQLite.dll" />
<None Include="Resources\gbm.ico" />
<Content Include="Resources\Admin.png" />
<Content Include="Resources\Clock.png" />
<Content Include="Resources\file.ico" />
<Content Include="Resources\folder.ico" />
<Content Include="Resources\GBM_Tray_Detected.ico" />
<Content Include="Resources\GBM_Tray_Ready.ico" />
<Content Include="Resources\GBM_Tray_Stopped.ico" />
<Content Include="Resources\Inbox.png" />
<Content Include="Resources\type.ico" />
<Content Include="Resources\User.png" />
<Content Include="Utilities\x64\7za.dll">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
+19 -18
View File
@@ -1,4 +1,5 @@
Imports System.IO
Imports GBM.My.Resources
Imports System.IO
Public Class mgrBackup
@@ -80,7 +81,7 @@ Public Class mgrBackup
oStream.Flush()
End Using
Catch ex As Exception
RaiseEvent UpdateLog("An error occured creating a file list: " & ex.Message, False, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorFileList, ex.Message), False, ToolTipIcon.Error, True)
End Try
End Sub
@@ -109,8 +110,8 @@ Public Class mgrBackup
RaiseEvent UpdateBackupInfo(oGame)
If mgrRestore.CheckManifest(oGame.Name) Then
If MsgBox("The manifest shows the backup folder contains a backup for " & oGame.Name & " that has not been restored on this computer." & vbCrLf & vbCrLf & "Do you want to overwrite this file anyway?", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.No Then
RaiseEvent UpdateLog("Backup aborted by user due to manifest conflict.", False, ToolTipIcon.Error, True)
If mgrCommon.ShowMessage(mgrBackup_ConfirmManifestConflict, oGame.Name, MsgBoxStyle.YesNo) = MsgBoxResult.No Then
RaiseEvent UpdateLog(mgrBackup_ErrorManifestConflict, False, ToolTipIcon.Error, True)
bDoBackup = False
End If
End If
@@ -122,7 +123,7 @@ Public Class mgrBackup
Directory.CreateDirectory(sBackupFile)
End If
Catch ex As Exception
RaiseEvent UpdateLog("Backup Aborted. A failure occured while creating backup sub-folder for " & oGame.Name & vbCrLf & ex.Message, False, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorSubFolderCreate, New String() {oGame.Name, ex.Message}), False, ToolTipIcon.Error, True)
bDoBackup = False
End Try
End If
@@ -134,8 +135,8 @@ Public Class mgrBackup
End If
If oSettings.ShowOverwriteWarning And File.Exists(sBackupFile) Then
If MsgBox("A file with the same name already exists in the backup folder." & vbCrLf & vbCrLf & "Do you want to overwrite this file?", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.No Then
RaiseEvent UpdateLog(oGame.Name & " backup aborted by user due to overwrite.", False, ToolTipIcon.Error, True)
If mgrCommon.ShowMessage(mgrBackup_ConfirmOverwrite, MsgBoxStyle.YesNo) = MsgBoxResult.No Then
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorOverwriteAbort, oGame.Name), False, ToolTipIcon.Error, True)
bDoBackup = False
End If
End If
@@ -152,7 +153,7 @@ Public Class mgrBackup
End If
If oGame.FolderSave = True Then
BuildFileList(sSavePath, "*.*", mgrPath.IncludeFileLocation)
BuildFileList(sSavePath, "*", mgrPath.IncludeFileLocation)
Else
BuildFileList(sSavePath, oGame.FileType, mgrPath.IncludeFileLocation)
End If
@@ -173,11 +174,11 @@ Public Class mgrBackup
prs7z.StartInfo.RedirectStandardOutput = True
prs7z.StartInfo.CreateNoWindow = True
prs7z.Start()
RaiseEvent UpdateLog("Backup of " & sSavePath & " in progress...", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_BackupInProgress, sSavePath), False, ToolTipIcon.Info, True)
While Not prs7z.StandardOutput.EndOfStream
If CancelOperation Then
prs7z.Kill()
RaiseEvent UpdateLog("Backup Aborted. The backup file for " & oGame.Name & " will be unusable.", True, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorFullAbort, oGame.Name), True, ToolTipIcon.Error, True)
Exit While
End If
RaiseEvent UpdateLog(prs7z.StandardOutput.ReadLine, False, ToolTipIcon.Info, False)
@@ -185,28 +186,28 @@ Public Class mgrBackup
prs7z.WaitForExit()
If Not CancelOperation Then
If prs7z.ExitCode = 0 Then
RaiseEvent UpdateLog(oGame.Name & " backup completed.", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_BackupComplete, oGame.Name), False, ToolTipIcon.Info, True)
bBackupCompleted = True
Else
RaiseEvent UpdateLog(oGame.Name & " backup finished with warnings or errors.", True, ToolTipIcon.Warning, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_BackupWarnings, oGame.Name), True, ToolTipIcon.Warning, True)
bBackupCompleted = False
End If
End If
prs7z.Dispose()
Else
RaiseEvent UpdateLog("Backup Aborted. The saved game path for " & oGame.Name & " does not exist.", True, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorNoSavePath, oGame.Name), True, ToolTipIcon.Error, True)
bBackupCompleted = False
End If
'Write Main Manifest
If bBackupCompleted Then
If oSettings.CheckSum Then
RaiseEvent UpdateLog("Generating SHA-256 hash for " & oGame.Name & " backup file.", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_GenerateHash, oGame.Name), False, ToolTipIcon.Info, True)
sHash = mgrHash.Generate_SHA256_Hash(sBackupFile)
End If
If Not DoManifestUpdate(oGame, sBackupFile, dTimeStamp, sHash) Then
RaiseEvent UpdateLog("The manifest update for " & oGame.Name & " failed.", True, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorManifestFailure, oGame.Name), True, ToolTipIcon.Error, True)
End If
'Write the process path if we have it
@@ -215,14 +216,14 @@ Public Class mgrBackup
End If
End If
Catch ex As Exception
RaiseEvent UpdateLog("An unexpected error occured during the backup of " & oGame.Name & vbCrLf & ex.Message, False, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrBackup_ErrorOtherFailure, New String() {oGame.Name, ex.Message}), False, ToolTipIcon.Error, True)
End Try
End If
If bBackupCompleted Then
RaiseEvent SetLastAction(oGame.CroppedName & " backup completed")
RaiseEvent SetLastAction(mgrCommon.FormatString(mgrBackup_ActionComplete, oGame.CroppedName))
Else
RaiseEvent SetLastAction(oGame.CroppedName & " backup failed")
RaiseEvent SetLastAction(mgrCommon.FormatString(mgrBackup_ActionFailed, oGame.CroppedName))
End If
Next
End Sub
+100 -5
View File
@@ -1,4 +1,5 @@
Imports System.Net
Imports GBM.My.Resources
Imports System.Net
Public Class mgrCommon
@@ -34,9 +35,9 @@ Public Class mgrCommon
Public Shared Function BooleanYesNo(ByVal bBool As Boolean) As String
If bBool Then
Return "Yes"
Return mgrCommon_Yes
Else
Return "No"
Return mgrCommon_No
End If
End Function
@@ -44,7 +45,7 @@ Public Class mgrCommon
Dim fbBrowser As New SaveFileDialog
fbBrowser.Title = sTitle
fbBrowser.DefaultExt = sExtension
fbBrowser.Filter = sFileType & " files (*." & sExtension & ")|*." & sExtension
fbBrowser.Filter = FormatString(mgrCommon_FilesFilter, New String() {sFileType, sExtension, sExtension})
fbBrowser.InitialDirectory = sDefaultFolder
fbBrowser.FileName = sDefaultFile
@@ -59,7 +60,7 @@ Public Class mgrCommon
Dim fbBrowser As New OpenFileDialog
fbBrowser.Title = sTitle
fbBrowser.DefaultExt = sExtension
fbBrowser.Filter = sFileType & " files (*." & sExtension & ")|*." & sExtension
fbBrowser.Filter = FormatString(mgrCommon_FilesFilter, New String() {sFileType, sExtension, sExtension})
fbBrowser.InitialDirectory = sDefaultFolder
fbBrowser.Multiselect = bMulti
@@ -91,6 +92,21 @@ Public Class mgrCommon
Return String.Empty
End Function
Public Shared Function IsProcessNotSearchable(ByVal oGame As clsGame) As Boolean
Dim sExemptList As String() = {"dosbox", "scummvm"}
Dim bFound As Boolean = False
For Each s As String In sExemptList
If oGame.ProcessName.ToLower.Contains(s) Then bFound = True
Next
If bFound Or oGame.Duplicate = True Then
Return True
Else
Return False
End If
End Function
Public Shared Function IsElevated() As Boolean
If My.User.IsInRole(ApplicationServices.BuiltInRole.Administrator) Then
Return True
@@ -110,4 +126,83 @@ Public Class mgrCommon
oProcess.Start()
End Sub
'Handles no extra parameters
Public Shared Function ShowMessage(ByVal sMsg As String, ByVal oType As MsgBoxStyle) As MsgBoxResult
Dim oResult As MsgBoxResult
oResult = MsgBox(FormatString(sMsg), oType, My.Resources.App_NameLong)
Return oResult
End Function
'Handles single parameter stings
Public Shared Function ShowMessage(ByVal sMsg As String, ByVal sParam As String, ByVal oType As MsgBoxStyle) As MsgBoxResult
Dim oResult As MsgBoxResult
oResult = MsgBox(FormatString(sMsg, sParam), oType, My.Resources.App_NameLong)
Return oResult
End Function
'Handles multi-parameter strings
Public Shared Function ShowMessage(ByVal sMsg As String, ByVal sParams As String(), ByVal oType As MsgBoxStyle) As MsgBoxResult
Dim oResult As MsgBoxResult
oResult = MsgBox(FormatString(sMsg, sParams), oType, My.Resources.App_NameLong)
Return oResult
End Function
'Handles no extra parameters
Public Shared Function FormatString(ByVal sString As String) As String
sString = sString.Replace("[BR]", vbCrLf)
Return sString
End Function
'Handles single parameter stings
Public Shared Function FormatString(ByVal sString As String, ByVal sParam As String) As String
sString = sString.Replace("[BR]", vbCrLf)
sString = sString.Replace("[PARAM]", sParam)
Return sString
End Function
'Handles multi-parameter strings
Public Shared Function FormatString(ByVal sString As String, ByVal sParams As String()) As String
Dim iParam As Integer
sString = sString.Replace("[BR]", vbCrLf)
For Each s As String In sParams
iParam = sString.IndexOf("[PARAM]")
sString = sString.Remove(iParam, 7)
sString = sString.Insert(iParam, s)
Next
Return sString
End Function
'Maintenance Only - Function for string management
Public Shared Sub GetAllStrings(ByVal ctlParent As Control, ByRef sResource As String, ByRef sCode As String, ByVal sFormName As String)
For Each ctl As Control In ctlParent.Controls
If TypeOf ctl Is GroupBox Then
sResource &= sFormName & "_" & ctl.Name & vbTab & ctl.Text & vbCrLf
sCode &= ctl.Name & ".Text = " & sFormName & "_" & ctl.Name & vbCrLf
GetAllStrings(ctl, sResource, sCode, sFormName)
ElseIf TypeOf ctl Is TabControl Then
For Each tb As TabPage In ctl.Controls
GetAllStrings(tb, sResource, sCode, sFormName)
Next
ElseIf TypeOf ctl Is Label Then
sResource &= sFormName & "_" & ctl.Name & vbTab & ctl.Text & vbCrLf
sCode &= ctl.Name & ".Text = " & sFormName & "_" & ctl.Name & vbCrLf
ElseIf TypeOf ctl Is Button Then
sResource &= sFormName & "_" & ctl.Name & vbTab & ctl.Text & vbCrLf
sCode &= ctl.Name & ".Text = " & sFormName & "_" & ctl.Name & vbCrLf
ElseIf TypeOf ctl Is RadioButton Then
sResource &= sFormName & "_" & ctl.Name & vbTab & ctl.Text & vbCrLf
sCode &= ctl.Name & ".Text = " & sFormName & "_" & ctl.Name & vbCrLf
ElseIf TypeOf ctl Is CheckBox Then
sResource &= sFormName & "_" & ctl.Name & vbTab & ctl.Text & vbCrLf
sCode &= ctl.Name & ".Text = " & sFormName & "_" & ctl.Name & vbCrLf
End If
Next
End Sub
End Class
-1
View File
@@ -1,5 +1,4 @@
Imports System.IO
Imports System.Security
Imports System.Security.Cryptography
Public Class mgrHash
+1 -3
View File
@@ -1,6 +1,4 @@
Imports System.IO
Public Class mgrManifest
Public Class mgrManifest
Public Shared Function ReadManifest(ByVal iSelectDB As mgrSQLite.Database) As SortedList
Dim oDatabase As New mgrSQLite(iSelectDB)
+131 -139
View File
@@ -1,4 +1,5 @@
Imports System.IO
Imports GBM.My.Resources
Imports System.IO
Public Class mgrMonitorList
@@ -23,9 +24,7 @@ Public Class mgrMonitorList
'If the remote database actually contains a list, then ask what to do
If iGameCount > 0 Then
If MsgBox("GBM data already exists in the backup folder." & vbCrLf & vbCrLf & _
"Do you want to make your local game list the new master game list in this folder? (Recommended)" & vbCrLf & vbCrLf & _
"Choosing No will sync your local game list to the current master game list in this folder.", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(mgrMonitorList_ConfirmExistingData, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
mgrMonitorList.SyncMonitorLists()
Else
mgrMonitorList.SyncMonitorLists(False)
@@ -39,17 +38,26 @@ Public Class mgrMonitorList
End Sub
Public Shared Sub ExportMonitorList(ByVal sLocation As String)
Dim frm As New frmFilter
Dim oList As List(Of Game)
Dim bSuccess As Boolean = False
Dim oTagFilters As New List(Of clsTag)
Dim oStringFilters As New Hashtable
Dim eCurrentFilter As frmFilter.eFilterType = frmFilter.eFilterType.NoFilter
frm.ShowDialog()
oList = ReadListForExport(frm.Filters, frm.FilterType)
If mgrCommon.ShowMessage(mgrMonitorList_ConfirmApplyFilter, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
Dim frm As New frmFilter
frm.ShowDialog()
oTagFilters = frm.TagFilters
oStringFilters = frm.StringFilters
eCurrentFilter = frm.FilterType
End If
oList = ReadListForExport(oTagFilters, oStringFilters, eCurrentFilter)
bSuccess = mgrXML.SerializeAndExport(oList, sLocation)
If bSuccess Then
MsgBox("Export Complete. " & oList.Count & " item(s) have been exported.", MsgBoxStyle.Information, "Game Backup Monitor")
mgrCommon.ShowMessage(mgrMonitorList_ExportComplete, oList.Count, MsgBoxStyle.Information)
End If
End Sub
@@ -59,9 +67,11 @@ Public Class mgrMonitorList
Dim hshParams As Hashtable
Dim oParamList As New List(Of Hashtable)
sSQL = "INSERT OR REPLACE INTO monitorlist (MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, Hours, Enabled, MonitorOnly) "
sSQL = "INSERT OR REPLACE INTO monitorlist (MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly) "
sSQL &= "VALUES (@ID, @Name, @Process, @Path, @AbsolutePath, @FolderSave, @FileType, "
sSQL &= "@TimeStamp, @ExcludeList, @Hours, @Enabled, @MonitorOnly);"
sSQL &= "@TimeStamp, @ExcludeList, (SELECT ProcessPath FROM monitorlist WHERE MonitorID=@ID), "
sSQL &= "(SELECT Icon FROM monitorlist WHERE MonitorID=@ID), @Hours, (SELECT Version FROM monitorlist WHERE MonitorID=@ID), "
sSQL &= "(SELECT Company FROM monitorlist WHERE MonitorID=@ID), COALESCE((SELECT Enabled FROM monitorlist WHERE MonitorID=@ID),1), COALESCE((SELECT MonitorOnly FROM monitorlist WHERE MonitorID=@ID),0));"
For Each oGame As clsGame In hshGames.Values
hshParams = New Hashtable
@@ -78,10 +88,6 @@ Public Class mgrMonitorList
hshParams.Add("ExcludeList", oGame.ExcludeList)
hshParams.Add("Hours", oGame.Hours)
'Required Defaults
hshParams.Add("Enabled", True)
hshParams.Add("MonitorOnly", False)
oParamList.Add(hshParams)
Next
@@ -123,9 +129,9 @@ Public Class mgrMonitorList
Cursor.Current = Cursors.WaitCursor
If bToRemote Then
RaiseEvent UpdateLog("A sync to the master game list has been triggered.", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrMonitorList_SyncToMaster, False, ToolTipIcon.Info, True)
Else
RaiseEvent UpdateLog("A sync from the master game list has been triggered.", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrMonitorList_SyncFromMaster, False, ToolTipIcon.Info, True)
End If
'Add / Update Sync
@@ -140,10 +146,10 @@ Public Class mgrMonitorList
hshSyncItems = hshCompareFrom.Clone
For Each oFromItem In hshCompareFrom.Values
If hshCompareTo.Contains(oFromItem.ProcessName) Then
oToItem = DirectCast(hshCompareTo(oFromItem.ProcessName), clsGame)
If hshCompareTo.Contains(oFromItem.CompoundKey) Then
oToItem = DirectCast(hshCompareTo(oFromItem.CompoundKey), clsGame)
If oFromItem.SyncEquals(oToItem) Then
hshSyncItems.Remove(oFromItem.ProcessName)
hshSyncItems.Remove(oFromItem.CompoundKey)
End If
End If
Next
@@ -171,10 +177,10 @@ Public Class mgrMonitorList
hshDeleteItems = hshCompareTo.Clone
For Each oToItem In hshCompareTo.Values
If hshCompareFrom.Contains(oToItem.ProcessName) Then
oFromItem = DirectCast(hshCompareFrom(oToItem.ProcessName), clsGame)
If hshCompareFrom.Contains(oToItem.CompoundKey) Then
oFromItem = DirectCast(hshCompareFrom(oToItem.CompoundKey), clsGame)
If oToItem.MinimalEquals(oFromItem) Then
hshDeleteItems.Remove(oToItem.ProcessName)
hshDeleteItems.Remove(oToItem.CompoundKey)
End If
End If
Next
@@ -185,7 +191,7 @@ Public Class mgrMonitorList
DoListDeleteSync(hshDeleteItems, mgrSQLite.Database.Local)
End If
RaiseEvent UpdateLog(hshDeleteItems.Count + hshSyncItems.Count + iChanges & " change(s) synced.", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrMonitorList_SyncChanges, (hshDeleteItems.Count + hshSyncItems.Count + iChanges).ToString), False, ToolTipIcon.Info, True)
Cursor.Current = Cursors.Default
Application.DoEvents()
End Sub
@@ -206,10 +212,10 @@ Public Class mgrMonitorList
hshSyncItems = hshCompareFrom.Clone
For Each oFromItem In hshCompareFrom.Values
If hshCompareTo.Contains(oFromItem.ProcessName) Then
oToItem = DirectCast(hshCompareTo(oFromItem.ProcessName), clsGame)
If hshCompareTo.Contains(oFromItem.CompoundKey) Then
oToItem = DirectCast(hshCompareTo(oFromItem.CompoundKey), clsGame)
If oFromItem.CoreEquals(oToItem) Then
hshSyncItems.Remove(oFromItem.ProcessName)
hshSyncItems.Remove(oFromItem.CompoundKey)
End If
End If
Next
@@ -226,10 +232,10 @@ Public Class mgrMonitorList
mgrTags.DoTagAddImport(frm.ImportData)
Cursor.Current = Cursors.Default
MsgBox("Import Complete.", MsgBoxStyle.Information, "Game Backup Monitor")
mgrCommon.ShowMessage(mgrMonitorList_ImportComplete, MsgBoxStyle.Information)
End If
Else
MsgBox("This list does not contain any new games to import.", MsgBoxStyle.Information, "Game Backup Monitor")
mgrCommon.ShowMessage(mgrMonitorList_ImportNothing, MsgBoxStyle.Information)
End If
Application.DoEvents()
@@ -242,7 +248,7 @@ Public Class mgrMonitorList
ImportMonitorList(sPath, True)
Return True
Else
MsgBox("There's no response from:" & vbCrLf & vbCrLf & sPath & vbCrLf & vbCrLf & "Either the server is not responding or the URL is invalid.")
mgrCommon.ShowMessage(mgrMonitorList_WebNoReponse, sPath, MsgBoxStyle.Exclamation)
Return False
End If
Else
@@ -250,15 +256,76 @@ Public Class mgrMonitorList
ImportMonitorList(sPath)
Return True
Else
MsgBox("The file:" & vbCrLf & sPath & vbCrLf & "cannot be found.")
mgrCommon.ShowMessage(mgrMonitorList_FileNotFound, sPath, MsgBoxStyle.Exclamation)
Return False
End If
End If
Return True
End Function
Private Shared Function BuildFilterQuery(ByVal oTagFilters As List(Of clsTag), ByVal hshStringFilters As Hashtable, eFilterType As frmFilter.eFilterType, ByRef hshParams As Hashtable) As String
Dim sSQL As String = String.Empty
Dim iCounter As Integer = 0
Public Shared Function ReadFilteredList(ByVal oFilters As List(Of clsTag), ByVal eFilterType As frmFilter.eFilterType, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local) As Hashtable
Select Case eFilterType
Case frmFilter.eFilterType.NoFilter
sSQL = "SELECT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist ORDER BY Name Asc"
Case frmFilter.eFilterType.FieldAnd, frmFilter.eFilterType.FieldOr
sSQL = "SELECT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist"
If hshStringFilters.Count > 0 Then
sSQL &= " WHERE ("
For Each de As DictionaryEntry In hshStringFilters
sSQL &= de.Key & " LIKE @" & de.Key
hshParams.Add(de.Key, "%" & de.Value.ToString & "%")
iCounter += 1
If iCounter <> hshStringFilters.Count Then
Select Case eFilterType
Case frmFilter.eFilterType.FieldAnd
sSQL &= " AND "
Case frmFilter.eFilterType.FieldOr
sSQL &= " OR "
End Select
End If
Next
sSQL &= ")"
End If
sSQL &= " ORDER BY Name Asc"
Case frmFilter.eFilterType.AnyTag
sSQL = "SELECT DISTINCT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist "
sSQL &= "NATURAL JOIN gametags WHERE gametags.TagID IN ("
For Each oTag As clsTag In oTagFilters
sSQL &= "@TagID" & iCounter & ","
hshParams.Add("TagID" & iCounter, oTag.ID)
iCounter += 1
Next
sSQL = sSQL.TrimEnd(",")
sSQL &= ") ORDER BY Name Asc"
Case frmFilter.eFilterType.AllTags
sSQL = "SELECT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist WHERE MonitorID IN "
For Each oTag As clsTag In oTagFilters
sSQL &= "(SELECT MonitorID FROM gametags WHERE monitorlist.MonitorID = gametags.MonitorID And TagID = @TagID" & iCounter & ")"
If iCounter <> oTagFilters.Count - 1 Then
sSQL &= " AND MonitorID IN "
End If
hshParams.Add("TagID" & iCounter, oTag.ID)
iCounter += 1
Next
sSQL &= " ORDER BY Name Asc"
Case frmFilter.eFilterType.NoTags
sSQL = "SELECT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist WHERE MonitorID NOT IN (SELECT MonitorID FROM gametags) ORDER BY Name Asc"
End Select
Return sSQL
End Function
Public Shared Function ReadFilteredList(ByVal oTagFilters As List(Of clsTag), ByVal hshStringFilters As Hashtable, eFilterType As frmFilter.eFilterType, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local) As Hashtable
Dim oDatabase As New mgrSQLite(iSelectDB)
Dim oData As DataSet
Dim sSQL As String = String.Empty
@@ -267,37 +334,7 @@ Public Class mgrMonitorList
Dim hshParams As New Hashtable
Dim iCounter As Integer = 0
If oFilters.Count > 0 Then
Select Case eFilterType
Case frmFilter.eFilterType.Any
sSQL = "SELECT DISTINCT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist "
sSQL &= "NATURAL JOIN gametags WHERE gametags.TagID IN ("
For Each oTag As clsTag In oFilters
sSQL &= "@TagID" & iCounter & ","
hshParams.Add("TagID" & iCounter, oTag.ID)
iCounter += 1
Next
sSQL = sSQL.TrimEnd(",")
sSQL &= ") ORDER BY Name Asc"
Case frmFilter.eFilterType.All
sSQL = "SELECT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist WHERE MonitorID IN "
For Each oTag As clsTag In oFilters
sSQL &= "(SELECT MonitorID FROM gametags WHERE monitorlist.MonitorID = gametags.MonitorID And TagID = @TagID" & iCounter & ")"
If iCounter <> oFilters.Count - 1 Then
sSQL &= " AND MonitorID IN "
End If
hshParams.Add("TagID" & iCounter, oTag.ID)
iCounter += 1
Next
sSQL &= " ORDER BY Name Asc"
End Select
Else
sSQL = "SELECT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist ORDER BY Name Asc"
End If
sSQL = BuildFilterQuery(oTagFilters, hshStringFilters, eFilterType, hshParams)
oData = oDatabase.ReadParamData(sSQL, hshParams)
@@ -326,6 +363,36 @@ Public Class mgrMonitorList
Return hshList
End Function
Public Shared Function ReadListForExport(ByVal oTagFilters As List(Of clsTag), ByVal hshStringFilters As Hashtable, ByVal eFilterType As frmFilter.eFilterType, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local) As List(Of Game)
Dim oDatabase As New mgrSQLite(iSelectDB)
Dim oData As DataSet
Dim sSQL As String = String.Empty
Dim sID As String
Dim oList As New List(Of Game)
Dim oGame As Game
Dim hshParams As New Hashtable
sSQL = BuildFilterQuery(oTagFilters, hshStringFilters, eFilterType, hshParams)
oData = oDatabase.ReadParamData(sSQL, hshParams)
For Each dr As DataRow In oData.Tables(0).Rows
oGame = New Game
sID = CStr(dr("MonitorID"))
oGame.Name = CStr(dr("Name"))
oGame.ProcessName = CStr(dr("Process"))
If Not IsDBNull(dr("Path")) Then oGame.Path = CStr(dr("Path"))
oGame.AbsolutePath = CBool(dr("AbsolutePath"))
oGame.FolderSave = CBool(dr("FolderSave"))
If Not IsDBNull(dr("FileType")) Then oGame.FileType = CStr(dr("FileType"))
If Not IsDBNull(dr("ExcludeList")) Then oGame.ExcludeList = CStr(dr("ExcludeList"))
oGame.Tags = mgrGameTags.GetTagsByGameForExport(sID)
oList.Add(oGame)
Next
Return oList
End Function
Public Shared Function ReadList(ByVal eListType As eListTypes, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local) As Hashtable
Dim oDatabase As New mgrSQLite(iSelectDB)
Dim oData As DataSet
@@ -333,7 +400,6 @@ Public Class mgrMonitorList
Dim hshList As New Hashtable
Dim hshDupeList As New Hashtable
Dim oGame As clsGame
Dim oDupeGame As clsGame
sSQL = "Select * from monitorlist ORDER BY Name Asc"
oData = oDatabase.ReadParamData(sSQL, New Hashtable)
@@ -359,27 +425,14 @@ Public Class mgrMonitorList
Select Case eListType
Case eListTypes.FullList
If hshList.Contains(oGame.ProcessName) Or hshDupeList.Contains(oGame.ProcessName) Then
oDupeGame = DirectCast(hshList.Item(oGame.ProcessName), clsGame)
If Not hshDupeList.Contains(oGame.ProcessName) Then
hshDupeList.Add(oGame.ProcessName, oDupeGame)
hshList.Remove(oDupeGame.ProcessName)
oDupeGame.Duplicate = True
oDupeGame.ProcessName = oDupeGame.ProcessName & ":" & oDupeGame.Name
hshList.Add(oDupeGame.ProcessName, oDupeGame)
End If
oGame.ProcessName = oGame.ProcessName & ":" & oGame.Name
oGame.Duplicate = True
End If
hshList.Add(oGame.ProcessName, oGame)
'Don't wrap this, if it fails there's a problem with the database
hshList.Add(oGame.ProcessName & ":" & oGame.Name, oGame)
Case eListTypes.ScanList
If hshList.Contains(oGame.ProcessName) Then
DirectCast(hshList.Item(oGame.ProcessName), clsGame).Duplicate = True
oGame.ProcessName = oGame.ProcessName & ":" & oGame.Name
oGame.Duplicate = True
End If
If oGame.Enabled Then hshList.Add(oGame.ProcessName, oGame)
End Select
Next
@@ -387,67 +440,6 @@ Public Class mgrMonitorList
Return hshList
End Function
Public Shared Function ReadListForExport(ByVal oFilters As List(Of clsTag), ByVal eFilterType As frmFilter.eFilterType, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local) As List(Of Game)
Dim oDatabase As New mgrSQLite(iSelectDB)
Dim oData As DataSet
Dim sSQL As String = String.Empty
Dim sID As String
Dim oList As New List(Of Game)
Dim oGame As Game
Dim hshParams As New Hashtable
Dim iCounter As Integer = 0
If oFilters.Count > 0 Then
Select Case eFilterType
Case frmFilter.eFilterType.Any
sSQL = "SELECT DISTINCT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist "
sSQL &= "NATURAL JOIN gametags WHERE gametags.TagID IN ("
For Each oTag As clsTag In oFilters
sSQL &= "@TagID" & iCounter & ","
hshParams.Add("TagID" & iCounter, oTag.ID)
iCounter += 1
Next
sSQL = sSQL.TrimEnd(",")
sSQL &= ") ORDER BY Name Asc"
Case frmFilter.eFilterType.All
sSQL = "SELECT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist WHERE MonitorID IN "
For Each oTag As clsTag In oFilters
sSQL &= "(SELECT MonitorID FROM gametags WHERE monitorlist.MonitorID = gametags.MonitorID And TagID = @TagID" & iCounter & ")"
If iCounter <> oFilters.Count - 1 Then
sSQL &= " AND MonitorID IN "
End If
hshParams.Add("TagID" & iCounter, oTag.ID)
iCounter += 1
Next
sSQL &= " ORDER BY Name Asc"
End Select
Else
sSQL = "SELECT MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly FROM monitorlist ORDER BY Name Asc"
End If
oData = oDatabase.ReadParamData(sSQL, hshParams)
For Each dr As DataRow In oData.Tables(0).Rows
oGame = New Game
sID = CStr(dr("MonitorID"))
oGame.Name = CStr(dr("Name"))
oGame.ProcessName = CStr(dr("Process"))
If Not IsDBNull(dr("Path")) Then oGame.Path = CStr(dr("Path"))
oGame.AbsolutePath = CBool(dr("AbsolutePath"))
oGame.FolderSave = CBool(dr("FolderSave"))
If Not IsDBNull(dr("FileType")) Then oGame.FileType = CStr(dr("FileType"))
If Not IsDBNull(dr("ExcludeList")) Then oGame.ExcludeList = CStr(dr("ExcludeList"))
oGame.Tags = mgrGameTags.GetTagsByGameForExport(sID)
oList.Add(oGame)
Next
Return oList
End Function
Public Shared Sub DoListAdd(ByVal oGame As clsGame, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
Dim oDatabase As New mgrSQLite(iSelectDB)
Dim sSQL As String
+17 -42
View File
@@ -1,4 +1,5 @@
Imports System.IO
Imports GBM.My.Resources
Imports System.IO
Imports System.Text.RegularExpressions
Imports System.Reflection
@@ -8,9 +9,6 @@ Public Class mgrPath
Private Shared sDBLocation As String = sSettingsRoot & "\gbm.s3db"
Private Shared sIncludeFile As String = sSettingsRoot & "\gbm_include.txt"
Private Shared sExcludeFile As String = sSettingsRoot & "\gbm_exclude.txt"
Private Shared sOfficialImportURL As String = "http://mikemaximus.github.io/gbm-web/GBM_Official.xml"
Private Shared sOfficialManualURL As String = "http://mikemaximus.github.io/gbm-web/manual.html"
Private Shared sOfficialUpdatesURL As String = "https://github.com/MikeMaximus/gbm/releases"
Private Shared sRemoteDatabaseLocation As String
Private Shared hshCustomVariables As Hashtable
Private Shared oReleaseType As ProcessorArchitecture = AssemblyName.GetAssemblyName(Application.ExecutablePath()).ProcessorArchitecture
@@ -75,24 +73,6 @@ Public Class mgrPath
End Get
End Property
Shared ReadOnly Property OfficialManualURL As String
Get
Return sOfficialManualURL
End Get
End Property
Shared ReadOnly Property OfficialUpdatesURL As String
Get
Return sOfficialUpdatesURL
End Get
End Property
Shared ReadOnly Property OfficialImportURL As String
Get
Return sOfficialImportURL
End Get
End Property
Shared ReadOnly Property SettingsRoot As String
Get
Return sSettingsRoot
@@ -108,10 +88,8 @@ Public Class mgrPath
End Set
End Property
Public Shared Function ValidateForFileSystem(ByVal sCheckString As String) As String
Dim cInvalidCharacters As Char() = {"\", "/", ":", "*", "?", """", "<", ">", "|"}
Dim cInvalidCharacters As Char() = {"\", "/", ":", "*", "?", """", "<", ">", "|", "."}
For Each c As Char In cInvalidCharacters
sCheckString = sCheckString.Replace(c, "")
@@ -121,8 +99,9 @@ Public Class mgrPath
sCheckString = sCheckString.Substring(0, 257)
End If
Return sCheckString
Return sCheckString.Trim
End Function
Public Shared Function DetermineRelativePath(ByVal sProcessPath As String, ByVal sSavePath As String) As String
Dim sPath1Array As String()
Dim sPath2Array As String()
@@ -319,11 +298,11 @@ Public Class mgrPath
hshCustomVariables = mgrVariables.ReadVariables
End Sub
Public Shared Function SetManualgamePath() As String
Public Shared Function SetManualGamePath() As String
Dim sDefaultFolder As String = Environment.GetFolderPath(Environment.SpecialFolder.Desktop)
Dim sNewPath As String
sNewPath = mgrCommon.OpenFolderBrowser("Choose the game folder containing the executable.", sDefaultFolder, False)
sNewPath = mgrCommon.OpenFolderBrowser(mgrPath_ChoosePath, sDefaultFolder, False)
Return sNewPath
End Function
@@ -339,25 +318,24 @@ Public Class mgrPath
'We can't automatically search for certain game types
If bNoAuto Then
sMessage = sSearchReason & vbCrLf & vbCrLf & "Do you wish to manually set the game path? (Path will be saved)"
sMessage = mgrCommon.FormatString(mgrPath_ConfirmManualPath, sSearchReason)
If MsgBox(sMessage, MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(sMessage, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
sFolder = SetManualgamePath()
End If
Return sFolder
End If
sMessage = sSearchReason & vbCrLf & vbCrLf & "Do you wish to automatically search for the game path? (Path will be saved)"
sMessage = mgrCommon.FormatString(mgrPath_ConfirmAutoPath, sSearchReason)
If MsgBox(sMessage, MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(sMessage, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
frmFind.ShowDialog()
If frmFind.FoundItem <> String.Empty Then
sFolder = IO.Path.GetDirectoryName(frmFind.FoundItem)
sMessage = sGameName & " was located in the following folder:" & vbCrLf & vbCrLf & _
sFolder & vbCrLf & vbCrLf & "Is this correct?"
If MsgBox(sMessage, MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
sMessage = mgrCommon.FormatString(mgrPath_ConfirmPathCorrect, New String() {sGameName, sFolder})
If mgrCommon.ShowMessage(sMessage, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
Return sFolder
Else
sFolder = String.Empty
@@ -367,13 +345,12 @@ Public Class mgrPath
End If
If bSearchFailed Then
sMessage = "The search failed to locate the path for " & sGameName & "." & vbCrLf & vbCrLf & _
"Do you wish to manually set the game path? (Path will be saved)"
sMessage = mgrCommon.FormatString(mgrPath_ConfirmAutoFailure, sGameName)
Else
sMessage = "Do you wish to manually set the game path? (Path will be saved)"
sMessage = mgPath_ConfirmManualPathNoParam
End If
If MsgBox(sMessage, MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(sMessage, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
sFolder = SetManualgamePath()
End If
End If
@@ -385,9 +362,7 @@ Public Class mgrPath
Dim dBrowser As FolderBrowserDialog
If Not Directory.Exists(sBackupPath) Then
If MsgBox("The backup location " & sBackupPath & " is not available." & vbCrLf & _
"It may be on an external or network drive that isn't connected." & vbCrLf & vbCrLf & _
"Do you want to select another backup location and continue?", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(mgrPath_ConfirmBackupLocation, sBackupPath, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
dBrowser = New FolderBrowserDialog
dBrowser.SelectedPath = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
If dBrowser.ShowDialog = DialogResult.OK Then
+2 -23
View File
@@ -77,15 +77,7 @@ Public Class mgrProcesses
bDuplicates = True
oDuplicateGames.Clear()
For Each o As clsGame In hshScanList.Values
If o.ProcessName.Contains("dosbox") Then
If o.ProcessName.Split(":").Length = 3 Then
sProcess = o.ProcessName.Remove(o.ProcessName.LastIndexOf(":"))
Else
sProcess = o.ProcessName
End If
Else
sProcess = o.ProcessName.Split(":")(0)
End If
sProcess = o.ProcessName.Split(":")(0)
If o.Duplicate = True And sProcess = oGame.TrueProcess Then
oDuplicateGames.Add(o.ShallowCopy)
@@ -95,23 +87,10 @@ Public Class mgrProcesses
Public Function SearchRunningProcesses(ByVal hshScanList As Hashtable, ByRef bNeedsPath As Boolean, ByRef iErrorCode As Integer) As Boolean
Dim prsList() As Process = Process.GetProcesses
Dim sDBoxProcess As String()
Dim sProcessCheck As String = String.Empty
For Each prsCurrent As Process In prsList
'Handle DOSBox Processes
If prsCurrent.ProcessName.ToLower = "dosbox" Then
sDBoxProcess = prsCurrent.MainWindowTitle.Split(":")
'If the dosbox process title doesn't have 3 elements it's not ready yet.
If sDBoxProcess.Length = 3 Then
sProcessCheck = "dosbox:" & sDBoxProcess(2).Trim
Else
'Drop out for now
Return False
End If
Else
sProcessCheck = prsCurrent.ProcessName
End If
sProcessCheck = prsCurrent.ProcessName
If hshScanList.ContainsKey(sProcessCheck) Then
prsFoundProcess = prsCurrent
+52 -22
View File
@@ -1,4 +1,5 @@
Imports System.IO
Imports GBM.My.Resources
Imports System.IO
Public Class mgrRestore
@@ -27,20 +28,51 @@ Public Class mgrRestore
Public Event UpdateRestoreInfo(oRestoreInfo As clsBackup)
Public Event SetLastAction(sMessage As String)
Public Shared Function CheckPath(ByRef oRestoreInfo As clsBackup, ByVal oGame As clsGame) As Boolean
Private Shared Function CheckForPathOverride(ByRef oCheckBackup As clsBackup, ByVal oCheckGame As clsGame) As Boolean
Dim oResult As MsgBoxResult
If oCheckBackup.RestorePath <> oCheckGame.Path Then
oResult = mgrCommon.ShowMessage(mgrRestore_ConfirmPathMismatch, oCheckBackup.CroppedName, MsgBoxStyle.YesNoCancel)
If oResult = MsgBoxResult.Yes Then
If Path.IsPathRooted(oCheckGame.Path) Then
oCheckBackup.AbsolutePath = True
oCheckBackup.RestorePath = oCheckGame.Path
Else
oCheckBackup.RestorePath = oCheckGame.Path
End If
ElseIf oResult = MsgBoxResult.Cancel Then
Return False
End If
End If
Return True
End Function
Public Shared Function CheckPath(ByRef oRestoreInfo As clsBackup, ByVal oGame As clsGame, ByRef bTriggerReload As Boolean) As Boolean
Dim sProcess As String
Dim sRestorePath As String
Dim bNoAuto As Boolean
'Before we do anything check if we need to override the current path
If Not CheckForPathOverride(oRestoreInfo, oGame) Then
Return False
End If
If Not oRestoreInfo.AbsolutePath Then
If oGame.ProcessPath <> String.Empty Then
oRestoreInfo.RelativeRestorePath = oGame.ProcessPath & "\" & oRestoreInfo.RestorePath
Else
sProcess = oGame.TrueProcess
If oGame.Duplicate = True Or oGame.ProcessName.Contains("dosbox") Then bNoAuto = True
sRestorePath = mgrPath.ProcessPathSearch(oRestoreInfo.Name, sProcess, oRestoreInfo.Name & " uses a relative path and has never been detected on this computer.", bNoAuto)
If mgrCommon.IsProcessNotSearchable(oGame) Then bNoAuto = True
sRestorePath = mgrPath.ProcessPathSearch(oRestoreInfo.Name, sProcess, mgrCommon.FormatString(mgrRestore_RelativeNeedPath, oRestoreInfo.Name), bNoAuto)
If sRestorePath <> String.Empty Then
'Update the process path in game object, save it, and make sure a monitor list reload is triggered
oGame.ProcessPath = sRestorePath
mgrMonitorList.DoListUpdate(oGame)
bTriggerReload = True
'Set path for restore
oRestoreInfo.RelativeRestorePath = sRestorePath & "\" & oRestoreInfo.RestorePath
Else
Return False
@@ -166,16 +198,15 @@ Public Class mgrRestore
'Check if restore location exists, prompt to create if it doesn't.
If Not Directory.Exists(sExtractPath) Then
If MsgBox("The restore path " & sExtractPath & " does not exist." & vbCrLf & vbCrLf & _
"Do you want to create the folder and continue?", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.Yes Then
If mgrCommon.ShowMessage(mgrRestore_ConfirmCreatePath, sExtractPath, MsgBoxStyle.YesNo) = MsgBoxResult.Yes Then
Try
Directory.CreateDirectory(sExtractPath)
Catch ex As Exception
RaiseEvent UpdateLog("The restore path could not be created due to an unexpected error." & vbCrLf & ex.Message, False, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorCreatePath, ex.Message), False, ToolTipIcon.Error, True)
bDoRestore = False
End Try
Else
RaiseEvent UpdateLog("Restored Aborted. The path " & sExtractPath & " does not exist.", False, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorNoPath, sExtractPath), False, ToolTipIcon.Error, True)
bDoRestore = False
End If
End If
@@ -185,17 +216,16 @@ Public Class mgrRestore
If oBackupInfo.CheckSum <> String.Empty Then
sHash = mgrHash.Generate_SHA256_Hash(sBackupFile)
If sHash <> oBackupInfo.CheckSum Then
RaiseEvent UpdateLog("The backup file for " & oBackupInfo.Name & " has failed the file integrity check.", False, ToolTipIcon.Info, True)
If MsgBox("The backup file for " & oBackupInfo.Name & " has failed the file intergity check. It may be corrupted, not exist or been modified by another application." & vbCrLf & vbCrLf & _
"Do you still want to restore this backup? (Not Recommended)", MsgBoxStyle.YesNo, "Game Backup Monitor") = MsgBoxResult.No Then
RaiseEvent UpdateLog("Restored Aborted by user due to a failed file integrity check.", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorFailedCheck, oBackupInfo.Name), False, ToolTipIcon.Info, True)
If mgrCommon.ShowMessage(mgrRestore_ConfirmFailedCheck, oBackupInfo.Name, MsgBoxStyle.YesNo) = MsgBoxResult.No Then
RaiseEvent UpdateLog(mgrRestore_ErrorCheckAbort, False, ToolTipIcon.Info, True)
bDoRestore = False
End If
Else
RaiseEvent UpdateLog(oBackupInfo.Name & " backup has been verified.", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_Verified, oBackupInfo.Name), False, ToolTipIcon.Info, True)
End If
Else
RaiseEvent UpdateLog(oBackupInfo.Name & " has no stored checksum, verification has been skipped.", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_NoVerify, oBackupInfo.Name), False, ToolTipIcon.Info, True)
End If
End If
@@ -208,11 +238,11 @@ Public Class mgrRestore
prs7z.StartInfo.RedirectStandardOutput = True
prs7z.StartInfo.CreateNoWindow = True
prs7z.Start()
RaiseEvent UpdateLog("Restore to " & sExtractPath & " in progress...", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_RestoreInProgress, sExtractPath), False, ToolTipIcon.Info, True)
While Not prs7z.StandardOutput.EndOfStream
If CancelOperation Then
prs7z.Kill()
RaiseEvent UpdateLog("Restored Aborted. The saved games for " & oBackupInfo.Name & " may now be invalid.", True, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorFullAbort, oBackupInfo.Name), True, ToolTipIcon.Error, True)
Exit While
End If
RaiseEvent UpdateLog(prs7z.StandardOutput.ReadLine, False, ToolTipIcon.Info, False)
@@ -220,16 +250,16 @@ Public Class mgrRestore
prs7z.WaitForExit()
If Not CancelOperation Then
If prs7z.ExitCode = 0 Then
RaiseEvent UpdateLog(oBackupInfo.Name & " backup restored.", False, ToolTipIcon.Info, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_RestoreComplete, oBackupInfo.Name), False, ToolTipIcon.Info, True)
bRestoreCompleted = True
Else
RaiseEvent UpdateLog(oBackupInfo.Name & " restore finished with warnings or errors.", True, ToolTipIcon.Warning, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_RestoreWarnings, oBackupInfo.Name), True, ToolTipIcon.Warning, True)
bRestoreCompleted = False
End If
End If
prs7z.Dispose()
Else
RaiseEvent UpdateLog("Restore Aborted. The backup file could not be found.", True, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrRestore_ErrorNoBackup, True, ToolTipIcon.Error, True)
End If
If bRestoreCompleted Then
@@ -241,13 +271,13 @@ Public Class mgrRestore
End If
End If
Catch ex As Exception
RaiseEvent UpdateLog("An unexpected error occured during the restore process." & vbCrLf & ex.Message, False, ToolTipIcon.Error, True)
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrRestore_ErrorOtherFailure, ex.Message), False, ToolTipIcon.Error, True)
End Try
If bRestoreCompleted Then
RaiseEvent SetLastAction(oBackupInfo.CroppedName & " backup restored")
RaiseEvent SetLastAction(mgrCommon.FormatString(mgrRestore_ActionComplete, oBackupInfo.CroppedName))
Else
RaiseEvent SetLastAction(oBackupInfo.CroppedName & " restore failed")
RaiseEvent SetLastAction(mgrCommon.FormatString(mgrRestore_ActionFailed, oBackupInfo.CroppedName))
End If
End If
Next
+51 -25
View File
@@ -1,4 +1,5 @@
Imports System.IO
Imports GBM.My.Resources
Imports System.IO
Imports System.Data.SQLite
Public Class mgrSQLite
@@ -39,7 +40,7 @@ Public Class mgrSQLite
File.Copy(mgrPath.RemoteDatabaseLocation, sNewFile, False)
End Select
Catch ex As Exception
MsgBox("An error occured creating a backup of the database file at " & sNewFile & vbCrLf & vbCrLf & ex.Message)
mgrCommon.ShowMessage(mgrSQLite_ErrorBackupFailure, New String() {sNewFile, ex.Message}, MsgBoxStyle.Exclamation)
End Try
End Sub
@@ -69,14 +70,15 @@ Public Class mgrSQLite
SQLiteConnection.CreateFile(sDatabaseLocation)
'Add Tables (Settings)
sSql = "CREATE TABLE settings (SettingsID INTEGER NOT NULL PRIMARY KEY, MonitorOnStartup BOOLEAN NOT NULL, StartToTray BOOLEAN NOT NULL, ShowDetectionToolTips BOOLEAN NOT NULL, " & _
"DisableConfirmation BOOLEAN NOT NULL, CreateSubFolder BOOLEAN NOT NULL, ShowOverwriteWarning BOOLEAN NOT NULL, RestoreOnLaunch BOOLEAN NOT NULL, " & _
"BackupFolder TEXT NOT NULL, Sync BOOLEAN NOT NULL, CheckSum BOOLEAN NOT NULL, StartWithWindows BOOLEAN NOT NULL, TimeTracking BOOLEAN NOT NULL);"
sSql = "CREATE TABLE settings (SettingsID INTEGER NOT NULL PRIMARY KEY, MonitorOnStartup BOOLEAN NOT NULL, StartToTray BOOLEAN NOT NULL, ShowDetectionToolTips BOOLEAN NOT NULL, " &
"DisableConfirmation BOOLEAN NOT NULL, CreateSubFolder BOOLEAN NOT NULL, ShowOverwriteWarning BOOLEAN NOT NULL, RestoreOnLaunch BOOLEAN NOT NULL, " &
"BackupFolder TEXT NOT NULL, Sync BOOLEAN NOT NULL, CheckSum BOOLEAN NOT NULL, StartWithWindows BOOLEAN NOT NULL, TimeTracking BOOLEAN NOT NULL, " &
"SupressBackup BOOLEAN NOT NULL, SupressBackupThreshold INTEGER NOT NULL);"
'Add Tables (Monitor List)
sSql &= "CREATE TABLE monitorlist (MonitorID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL, Process TEXT NOT NULL, Path TEXT, " & _
"AbsolutePath BOOLEAN NOT NULL, FolderSave BOOLEAN NOT NULL, FileType TEXT, TimeStamp BOOLEAN NOT NULL, ExcludeList TEXT NOT NULL, " & _
"ProcessPath TEXT, Icon TEXT, Hours REAL, Version TEXT, Company TEXT, Enabled BOOLEAN NOT NULL, MonitorOnly BOOLEAN NOT NULL, " & _
sSql &= "CREATE TABLE monitorlist (MonitorID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL, Process TEXT NOT NULL, Path TEXT, " &
"AbsolutePath BOOLEAN NOT NULL, FolderSave BOOLEAN NOT NULL, FileType TEXT, TimeStamp BOOLEAN NOT NULL, ExcludeList TEXT NOT NULL, " &
"ProcessPath TEXT, Icon TEXT, Hours REAL, Version TEXT, Company TEXT, Enabled BOOLEAN NOT NULL, MonitorOnly BOOLEAN NOT NULL, " &
"PRIMARY KEY(Name, Process));"
'Add Tables (Tags)
@@ -89,7 +91,7 @@ Public Class mgrSQLite
sSql &= "CREATE TABLE variables (VariableID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY, Path TEXT NOT NULL);"
'Add Tables (Local Manifest)
sSql &= "CREATE TABLE manifest (ManifestID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY, FileName TEXT NOT NULL, RestorePath TEXT NOT NULL, " & _
sSql &= "CREATE TABLE manifest (ManifestID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY, FileName TEXT NOT NULL, RestorePath TEXT NOT NULL, " &
"AbsolutePath BOOLEAN NOT NULL, DateUpdated TEXT NOT NULL, UpdatedBy TEXT NOT NULL, CheckSum TEXT);"
'Set Version
@@ -97,8 +99,8 @@ Public Class mgrSQLite
RunParamQuery(sSql, New Hashtable)
Return True
Catch e As Exception
MsgBox("An error has occured attempting to create the local application database: " & vbCrLf & vbCrLf & e.Message)
Catch ex As Exception
mgrCommon.ShowMessage(mgrSQLite_ErrorCreatingLocalDB, ex.Message, MsgBoxStyle.Critical)
Return False
End Try
End Function
@@ -111,13 +113,13 @@ Public Class mgrSQLite
SQLiteConnection.CreateFile(sDatabaseLocation)
'Add Tables (Remote Monitor List)
sSql = "CREATE TABLE monitorlist (MonitorID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL, Process TEXT NOT NULL, Path TEXT, " & _
"AbsolutePath BOOLEAN NOT NULL, FolderSave BOOLEAN NOT NULL, FileType TEXT, TimeStamp BOOLEAN NOT NULL, ExcludeList TEXT NOT NULL, " & _
"ProcessPath TEXT, Icon TEXT, Hours REAL, Version TEXT, Company TEXT, Enabled BOOLEAN NOT NULL, MonitorOnly BOOLEAN NOT NULL, " & _
sSql = "CREATE TABLE monitorlist (MonitorID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL, Process TEXT NOT NULL, Path TEXT, " &
"AbsolutePath BOOLEAN NOT NULL, FolderSave BOOLEAN NOT NULL, FileType TEXT, TimeStamp BOOLEAN NOT NULL, ExcludeList TEXT NOT NULL, " &
"ProcessPath TEXT, Icon TEXT, Hours REAL, Version TEXT, Company TEXT, Enabled BOOLEAN NOT NULL, MonitorOnly BOOLEAN NOT NULL, " &
"PRIMARY KEY(Name, Process));"
'Add Tables (Remote Manifest)
sSql &= "CREATE TABLE manifest (ManifestID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY, FileName TEXT NOT NULL, RestorePath TEXT NOT NULL, " & _
sSql &= "CREATE TABLE manifest (ManifestID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY, FileName TEXT NOT NULL, RestorePath TEXT NOT NULL, " &
"AbsolutePath BOOLEAN NOT NULL, DateUpdated TEXT NOT NULL, UpdatedBy TEXT NOT NULL, CheckSum TEXT);"
'Add Tables (Remote Tags)
@@ -131,8 +133,8 @@ Public Class mgrSQLite
RunParamQuery(sSql, New Hashtable)
Return True
Catch e As Exception
MsgBox("An error has occured attempting to create the remote application database: " & vbCrLf & vbCrLf & e.Message)
Catch ex As Exception
mgrCommon.ShowMessage(mgrSQLite_ErrorCreatingRemoteDB, ex.Message, MsgBoxStyle.Critical)
Return False
End Try
End Function
@@ -182,9 +184,9 @@ Public Class mgrSQLite
Try
command.ExecuteNonQuery()
trans.Commit()
Catch e As Exception
Catch ex As Exception
trans.Rollback()
MsgBox("An error has occured attempting run the query." & vbCrLf & vbCrLf & sSQL & vbCrLf & vbCrLf & e.Message)
mgrCommon.ShowMessage(mgrSQLite_ErrorQueryFailure, New String() {sSQL, ex.Message}, MsgBoxStyle.Exclamation)
Return False
Finally
command.Dispose()
@@ -208,9 +210,9 @@ Public Class mgrSQLite
command.ExecuteNonQuery()
Next
trans.Commit()
Catch e As Exception
Catch ex As Exception
trans.Rollback()
MsgBox("An error has occured attempting run the query." & vbCrLf & vbCrLf & sSQL & vbCrLf & vbCrLf & e.Message)
mgrCommon.ShowMessage(mgrSQLite_ErrorQueryFailure, New String() {sSQL, ex.Message}, MsgBoxStyle.Exclamation)
Return False
Finally
command.Dispose()
@@ -232,8 +234,8 @@ Public Class mgrSQLite
Try
adapter = New SQLiteDataAdapter(command)
adapter.Fill(oData)
Catch e As Exception
MsgBox("An error has occured attempting run the query." & vbCrLf & vbCrLf & sSQL & vbCrLf & vbCrLf & e.Message)
Catch ex As Exception
mgrCommon.ShowMessage(mgrSQLite_ErrorQueryFailure, New String() {sSQL, ex.Message}, MsgBoxStyle.Exclamation)
Finally
command.Dispose()
Disconnect()
@@ -480,6 +482,30 @@ Public Class mgrSQLite
End If
End If
'0.95 Upgrade
If GetDatabaseVersion() < 95 Then
If eDatabase = Database.Local Then
'Backup DB before starting
BackupDB("v94")
'Add new setting
sSQL = "ALTER TABLE settings ADD COLUMN SupressBackup BOOLEAN NOT NULL DEFAULT 0;"
sSQL &= "ALTER TABLE settings ADD COLUMN SupressBackupThreshold INTEGER NOT NULL DEFAULT 10;"
sSQL &= "PRAGMA user_version=95"
RunParamQuery(sSQL, New Hashtable)
End If
If eDatabase = Database.Remote Then
'Backup DB before starting
BackupDB("v94")
sSQL = "PRAGMA user_version=95"
RunParamQuery(sSQL, New Hashtable)
End If
End If
End Sub
Public Function GetDBSize() As Long
@@ -498,8 +524,8 @@ Public Class mgrSQLite
Try
command.ExecuteNonQuery()
Catch e As Exception
MsgBox("An error has occured attempting run the query." & vbCrLf & vbCrLf & sSQL & vbCrLf & vbCrLf & e.Message)
Catch ex As Exception
mgrCommon.ShowMessage(mgrSQLite_ErrorQueryFailure, New String() {sSQL, ex.Message}, MsgBoxStyle.Exclamation)
Finally
command.Dispose()
Disconnect()
+26 -1
View File
@@ -12,6 +12,8 @@ Public Class mgrSettings
Private bSync As Boolean = True
Private bCheckSum As Boolean = True
Private bTimeTracking As Boolean = True
Private bSupressBackup As Boolean = False
Private iSupressBackupThreshold As Integer = 10
Private sBackupFolder As String = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments).TrimEnd(New Char() {"\", "/"})
Property StartWithWindows As Boolean
@@ -113,6 +115,24 @@ Public Class mgrSettings
End Set
End Property
Property SupressBackup As Boolean
Get
Return bSupressBackup
End Get
Set(value As Boolean)
bSupressBackup = value
End Set
End Property
Property SupressBackupThreshold As Integer
Get
Return iSupressBackupThreshold
End Get
Set(value As Integer)
iSupressBackupThreshold = value
End Set
End Property
Property BackupFolder As String
Get
Return sBackupFolder
@@ -131,7 +151,8 @@ Public Class mgrSettings
oDatabase.RunParamQuery(sSQL, New Hashtable)
sSQL = "INSERT INTO settings VALUES (1, @MonitorOnStartup, @StartToTray, @ShowDetectionToolTips, @DisableConfirmation, "
sSQL &= "@CreateSubFolder, @ShowOverwriteWarning, @RestoreOnLaunch, @BackupFolder, @Sync, @CheckSum, @StartWithWindows, @TimeTracking)"
sSQL &= "@CreateSubFolder, @ShowOverwriteWarning, @RestoreOnLaunch, @BackupFolder, @Sync, @CheckSum, @StartWithWindows, "
sSQL &= "@TimeTracking, @SupressBackup, @SupressBackupThreshold)"
hshParams.Add("MonitorOnStartup", MonitorOnStartup)
hshParams.Add("StartToTray", StartToTray)
@@ -145,6 +166,8 @@ Public Class mgrSettings
hshParams.Add("CheckSum", CheckSum)
hshParams.Add("StartWithWindows", StartWithWindows)
hshParams.Add("TimeTracking", TimeTracking)
hshParams.Add("SupressBackup", SupressBackup)
hshParams.Add("SupressBackupThreshold", SupressBackupThreshold)
oDatabase.RunParamQuery(sSQL, hshParams)
End Sub
@@ -172,6 +195,8 @@ Public Class mgrSettings
CheckSum = CBool(dr("CheckSum"))
StartWithWindows = CBool(dr("StartWithWindows"))
TimeTracking = CBool(dr("TimeTracking"))
SupressBackup = CBool(dr("SupressBackup"))
SupressBackupThreshold = CInt(dr("SupressBackupThreshold"))
Next
oDatabase.Disconnect()
+10 -18
View File
@@ -1,4 +1,5 @@
Imports System.Xml.Serialization
Imports GBM.My.Resources
Imports System.Xml.Serialization
Imports System.IO
Imports System.Net
@@ -10,7 +11,6 @@ Public Class mgrXML
Dim hshList As New Hashtable
Dim hshDupeList As New Hashtable
Dim oGame As clsGame
Dim oDupeGame As clsGame
'If the file doesn't exist return an empty list
If Not File.Exists(sLocation) And Not bWebRead Then
@@ -32,20 +32,12 @@ Public Class mgrXML
oGame.ImportTags.Add(t)
Next
If hshList.Contains(oGame.ProcessName) Or hshDupeList.Contains(oGame.ProcessName) Then
oDupeGame = DirectCast(hshList.Item(oGame.ProcessName), clsGame)
If Not hshDupeList.Contains(oGame.ProcessName) Then
hshDupeList.Add(oGame.ProcessName, oDupeGame)
hshList.Remove(oDupeGame.ProcessName)
oDupeGame.Duplicate = True
oDupeGame.ProcessName = oDupeGame.ProcessName & ":" & oDupeGame.Name
hshList.Add(oDupeGame.ProcessName, oDupeGame)
End If
oGame.ProcessName = oGame.ProcessName & ":" & oGame.Name
oGame.Duplicate = True
End If
hshList.Add(oGame.ProcessName, oGame)
'This should be wrapped just in case we get some bad data
Try
hshList.Add(oGame.ProcessName & ":" & oGame.Name, oGame)
Catch e As Exception
'Do Nothing
End Try
Next
Return hshList
@@ -69,7 +61,7 @@ Public Class mgrXML
oList = oSerializer.Deserialize(oReader)
oReader.Close()
Catch ex As Exception
MsgBox("The XML file cannot be read, it may be an invalid format or corrupted." & vbCrLf & vbCrLf & ex.Message, MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(mgrXML_ErrorImportFailure, ex.Message, MsgBoxStyle.Exclamation)
End Try
Return oList
@@ -87,7 +79,7 @@ Public Class mgrXML
oWriter.Close()
Return True
Catch ex As Exception
MsgBox("An error occured exporting the XML data." & vbCrLf & vbCrLf & ex.Message, MsgBoxStyle.Exclamation, "Game Backup Monitor")
mgrCommon.ShowMessage(mgrXML_ErrorExportFailure, ex.Message, MsgBoxStyle.Exclamation)
Return False
End Try
End Function
+6 -2
View File
@@ -1,3 +1,5 @@
Imports System.Resources
Imports System
Imports System.Reflection
Imports System.Runtime.InteropServices
@@ -31,5 +33,7 @@ Imports System.Runtime.InteropServices
' by using the '*' as shown below:
' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("0.94.*")>
<Assembly: AssemblyFileVersion("0.94.0.0")>
<Assembly: AssemblyVersion("0.95.*")>
<Assembly: AssemblyFileVersion("0.95.0.0")>
<Assembly: NeutralResourcesLanguageAttribute("en")>
+4018 -20
View File
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

+25 -102
View File
@@ -1,113 +1,36 @@
Game Backup Monitor v0.94 Readme
Game Backup Monitor v0.95 Readme
http://mikemaximus.github.io/gbm-web/
gamebackupmonitor@gmail.com
November 17, 2015
January 1, 2016
Disclaimer:
This is beta release software. You may still encounter some bugs.
Introduction:
Important Upgrade Notice:
This application is designed to run in the system tray and monitor for games you play. When you exit a game your save files will be automatically compressed (7z compression), saved to a folder you specify. This may be a cloud folder or external backup drive that other computers will be accessing. GBM can also take care of restoring the save data to other computers that have access to the main backup folder.
- v0.95 changes how DOSBox games are detected and will break DOSBox configurations from prior versions. Sorry for the inconvenience.
- To repair a configuration, you'll need to delete the DOS executable part of the process field and make sure the case matches the DOSBox executable being used by the game.
- For example, Capitalism Plus using a process of "dosbox:CAPPLUS" and DOSBox.exe would become just "DOSBox".
- You can use the new "Custom" filter to easily find and update all your DOSBox games in the Game Manager.
- Due to this change GBM can only detect DOS games that are using their own copy of DOSBox in a unique location. Most users will be unaffected, classic games sold online are already packaged in this format.
- Official configurations for DOSBox games are updated for this change.
GBM has been designed with mostly classic gaming in mind, but it can be used for any application!
New in 0.95
New in 0.94
- Fixed a regression that caused non-critical fields (Game Path, Company, Version, Icon, Enabled, Monitor Only) to be wiped or reset on sync.
- The "Check for new backups" feature has been renamed and redesigned. Instead of an annoying pop-up, it now shows a simple notification in the main menu or tray menu.
- Added the ability to trigger backups only after a certain session time has elapsed (Global Setting), this setting will be disabled by default.
- You can now cancel out of the "Choose Game" window when GBM detects multiple games may be running.
- Added the ability to filter by game information such as name, process and company.
- Many UI improvements and fixes with filtering. The "Tag" filter is now called "Custom" filter, due to the new options available.
- Added a new, more intuitive way of including and excluding items in a backup. See the Game Manager section of the GBM manual for details.
- Updated the "Add Game Wizard" to use the new include / exclude and tagging features.
- Removed the special handling of DOSBox games for future proofing, DOSBox games will now be handled like all other games.
- Moved the import and export game list features from the Tools menu into the Game Manager.
- Made some visual improvements to the main app window.
- Made changes that will allow GBM to be easily translated to other languages.
- Many minor UI improvements and bug fixes.
- Added the ability to organize your games with Tags. Users can create and customize their own list of Tags.
- Added the ability to filter by Tag in the Game Manager.
- Added the ability to filter by Tag when doing an XML export.
- Added the ability to disable Time Tracking. Enabling or disabling this setting has no effect on data already recorded.
- Added the ability to restart GBM as Administrator from the status bar.
- Redesigned notifications, GBM is now silent unless a problem occurs.
- Enhanced the sync logic and performance.
- The backup "Timestamp" setting is no longer included in XML imports or exports.
- Redesigned the XML import and export core. Sorry, this invalidates all prior XML exports files, but it will ensure future backwards compatability.
- Various bug fixes.
New in 0.93
- GBM now handles date/time fields in an efficient manner, this will solve all issues with regional date formats.
- GBM will now gracefully exit with an error message if it detects a database version is newer than the program version itself.
- "Access Denied" errors should no longer occur when dragging shortcuts into the Add Game Wizard.
- Redesigned how the backup includes and excludes files. The changes allow for more complex backup configurations.
- Added an "Open Restore Path" button to the Game Manager, this will automatically open the current backup's restore location in Windows Explorer.
- Game names are now cropped in many places to prevent errors when messages and/or notifications exceed control limits.
New in 0.92
- GBM now properly handles detecting games in DOSBox that share the same DOS executable name.
- "Start with Windows" toggle is now available in settings. Defaults to off and applies to Current User only.
- Added "Backups Only" filter option to the Game Manager, this lets you view only games that have backups.
- "Backups Only" and "Pending Restore" filters will now list existing backup data for games have been deleted from the game list.
- The game list sync is now more verbose in the log.
- GBM now triggers a master to local sync when the master data is changed by another application, such as your cloud client downloading an updated version of the master data after GBM is already running.
- When importing game configurations, you can now choose exactly which game configurations to import. This applies to the official list or importing an xml file.
- Added a Sync toggle to Settings. Disabling sync will speed up the application for users that use GBM on a single computer.
- GBM should now properly display a wait cursor in instances that the UI is unavailable.
- Added a "Compact Databases" tool, this is used to rebuild GBM's databases to use an optimal amount of disk space. It shouldn't be needed often.
- Game detection has been changed. It will take slightly longer for GBM detect a game but this should fix a few long outstanding issues.
- Backup & Restore has been optimized to handle everything more efficiently.
- GBM will now use the 2015 build of 7-Zip for compression, as well use the 64-bit version of 7z when using the 64-bit version of GBM. 64-bit users will see a huge speed improvement when backing up games with large complex saves, such as Divinity: Original Sin.
- GBM now allows you to cancel monitoring via the File menu, system tray menu and monitor status button. You can also now exit the application while a game is being monitored.
- The GBM system tray icon tooltip will now display it's current task.
- Replaced the icons in GBM with some better looking ones, the system tray icon will now visually represent GBM's current action.
- You can now cancel a backup or restore operation in progress. Intended for emergency situations only, cancelling will not undo any actions completed before the operation terminated.
- GBM now uses SHA-256 to verify your backup files before restoring them. This is optional, but will be enabled by default.
- Overhauled the backend, GBM will use more space to store records, but the improved database design will prevent future bugs.
- GBM will now back up your configuration data automatically on a version upgrade.
- Another ton of minor fixes and tweaks too various to list.
New in 0.84
- Tons of bug fixes and tweaks. GBM is stable enough to move to Beta!
- Removed Backup Manager and Restore Manager. All backup & restore functionality is now integrated into the Game Manager.
- You can now backup and restore mutliple games at the same time.
- You can now edit multiple games at the same time, only on toggle fields for now.
- Added a "Monitor Only" option. GBM can only monitor the time you've played a game and not trigger a backup when it's closed.
- Deleting a backup will now delete the sub-folder for the game, if it's not empty a confirmation will be displayed first.
- Since it can't reliably find them, GBM will no longer attempt to automatically search for dosbox games or games that share a process name.
- You can now multi-select on the Game Manager screen to delete multiple games.
- When changing your backup folder, if the newly selected backup folder already contains GBM data you now have a choice on how you want to handle the initial game list sync.
New in 0.81
- Fixed a critical bug with the Game Manager which allowed you to add duplicate entries. This resulted in a crash and the inability start the app again. 0.81 fixes this bug and will repair any database broken by this issue so the app will function again. (Thanks Nirth from GOG.com)
- Fixed an annoying bug where extra game data was being lost when syncing hours spent between computers.
- Fixed a potential issue with changing the backup folder.
- The Add Game Wizard will now properly handle entries with spaces while working with the Exclude and File Type helper.
New in 0.8
- Since it's all about the games anyway, re-branded ABM to GBM - Game Backup Manager.
- Removed confusing utilities and screens and replaced them with a user friendly Game Manager.
- Rebuilt the Custom Path Variable screen with the new Game Manager look.
- 64-bit build available, this will allow GBM to fully detect 64 bit and 32 bit applications. (32-bit will be default download)
- Switched back-end from XML to SQLite 3. Old configurations will be imported and upgraded.
- Automatic syncing of game list and applicable extra data (such as Hours played) between computers sharing the same backup folder. See "Notes on Automatic Syncing" in this readme for details.
- All import features redesigned to work more consistently. Added export feature.
- In the rare instance the user is asked to manually find a path, GBM will now search for the location automatically.
New in 0.7.1.2:
- Better Monitoring: You no longer need to run ABM as Administrator to monitor certain applications in 99% of situations. See "Current Limitations" for details.
- Time Tracking: ABM now tracks the amount of time spent in each application, similar to Steam.
- Search: You can now search for a specific application using the new search feature on all applicable forms.
- Application Data: You can now add or override application details by using the new "Edit Application Cache" feature.
New in 0.7.0.7:
- Fixed some monitor list saving and validation issues.
- Fixed the manual backup feature, required application data wasn't being cached.
- Fixed possible issue with official import.
- Minor Tweaks.
New in 0.7.0.5:
- Start-up Wizard: A simple guide to setup the basics when first starting the program.
- Add Application Wizard: A more user friendly way to add applications to monitor and backup. The classic monitor list is still available for more advanced configurations and management.
- Custom Path Variables: An advanced feature to allow the configuration for more applications to be shared between computers.
- Manual Backups: Execute a backup for any monitored application on demand (some applications will be need to be detected by ABM at least once to use this feature)
- Various tweaks to make things look and run a little better.
- Many bug fixes
The entire version history of GBM releases is available at http://mikemaximus.github.io/gbm-web/versionhistory.html