Compare commits
27 Commits
v0.93-beta
...
v0.94-beta
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b86206a7a2 | ||
|
|
1b47b6aa15 | ||
|
|
27f03cbd35 | ||
|
|
254bcbbab5 | ||
|
|
2617852d77 | ||
|
|
ca7cc7824a | ||
|
|
91f423d7ae | ||
|
|
2744aa7cbc | ||
|
|
aba6ed1462 | ||
|
|
0ba1323fb2 | ||
|
|
c05ef0f32f | ||
|
|
a8cda1d5f8 | ||
|
|
049878202a | ||
|
|
0a3bb9a58f | ||
|
|
040d6c4bf3 | ||
|
|
e13b6cd58b | ||
|
|
7c1698388a | ||
|
|
ebf5fb5f4d | ||
|
|
5357fb214d | ||
|
|
5e5da3c068 | ||
|
|
3743e71288 | ||
|
|
0c3f3fd5f4 | ||
|
|
2e63862493 | ||
|
|
c7a279e11a | ||
|
|
90b1194cc5 | ||
|
|
d489738d08 | ||
|
|
0fc6ce772b |
@@ -0,0 +1,83 @@
|
|||||||
|
Public Class Game
|
||||||
|
Private sGameName As String
|
||||||
|
Private sProcessName As String
|
||||||
|
Private sPath As String
|
||||||
|
Private bAbsolutePath As Boolean
|
||||||
|
Private bFolderSave As Boolean
|
||||||
|
Private sFileType As String
|
||||||
|
Private sExcludeList As String
|
||||||
|
Private oTags As List(Of Tag)
|
||||||
|
|
||||||
|
Property Name As String
|
||||||
|
Set(value As String)
|
||||||
|
sGameName = value
|
||||||
|
End Set
|
||||||
|
Get
|
||||||
|
Return sGameName
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Property ProcessName As String
|
||||||
|
Set(value As String)
|
||||||
|
sProcessName = value
|
||||||
|
End Set
|
||||||
|
Get
|
||||||
|
Return sProcessName
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Property Path As String
|
||||||
|
Set(value As String)
|
||||||
|
sPath = value
|
||||||
|
End Set
|
||||||
|
Get
|
||||||
|
Return sPath
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Property AbsolutePath As Boolean
|
||||||
|
Set(value As Boolean)
|
||||||
|
bAbsolutePath = value
|
||||||
|
End Set
|
||||||
|
Get
|
||||||
|
Return bAbsolutePath
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Property FolderSave As Boolean
|
||||||
|
Set(value As Boolean)
|
||||||
|
bFolderSave = value
|
||||||
|
End Set
|
||||||
|
Get
|
||||||
|
Return bFolderSave
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Property FileType As String
|
||||||
|
Set(value As String)
|
||||||
|
sFileType = value
|
||||||
|
End Set
|
||||||
|
Get
|
||||||
|
Return sFileType
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Property ExcludeList As String
|
||||||
|
Set(value As String)
|
||||||
|
sExcludeList = value
|
||||||
|
End Set
|
||||||
|
Get
|
||||||
|
Return sExcludeList
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Property Tags As List(Of Tag)
|
||||||
|
Get
|
||||||
|
Return oTags
|
||||||
|
End Get
|
||||||
|
Set(value As List(Of Tag))
|
||||||
|
oTags = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
End Class
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
Public Class Tag
|
||||||
|
Private sTagName As String
|
||||||
|
|
||||||
|
Property Name As String
|
||||||
|
Get
|
||||||
|
Return sTagName
|
||||||
|
End Get
|
||||||
|
Set(value As String)
|
||||||
|
sTagName = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
End Class
|
||||||
+41
-15
@@ -18,6 +18,7 @@
|
|||||||
Private bDuplicate As Boolean = False
|
Private bDuplicate As Boolean = False
|
||||||
Private sDOSBoxProcess As String = String.Empty
|
Private sDOSBoxProcess As String = String.Empty
|
||||||
Private bTempGame As Boolean = False
|
Private bTempGame As Boolean = False
|
||||||
|
Private oImportTags As New List(Of Tag)
|
||||||
|
|
||||||
Property ID As String
|
Property ID As String
|
||||||
Set(value As String)
|
Set(value As String)
|
||||||
@@ -156,40 +157,40 @@
|
|||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Property Enabled As Boolean
|
Property Enabled As Boolean
|
||||||
Set(value As Boolean)
|
|
||||||
bEnabled = value
|
|
||||||
End Set
|
|
||||||
Get
|
Get
|
||||||
Return bEnabled
|
Return bEnabled
|
||||||
End Get
|
End Get
|
||||||
|
Set(value As Boolean)
|
||||||
|
bEnabled = value
|
||||||
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Property MonitorOnly As Boolean
|
Property MonitorOnly As Boolean
|
||||||
Set(value As Boolean)
|
|
||||||
bMonitorOnly = value
|
|
||||||
End Set
|
|
||||||
Get
|
Get
|
||||||
Return bMonitorOnly
|
Return bMonitorOnly
|
||||||
End Get
|
End Get
|
||||||
|
Set(value As Boolean)
|
||||||
|
bMonitorOnly = value
|
||||||
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Property Duplicate As Boolean
|
Property Duplicate As Boolean
|
||||||
Set(value As Boolean)
|
|
||||||
bDuplicate = value
|
|
||||||
End Set
|
|
||||||
Get
|
Get
|
||||||
Return bDuplicate
|
Return bDuplicate
|
||||||
End Get
|
End Get
|
||||||
|
Set(value As Boolean)
|
||||||
|
bDuplicate = value
|
||||||
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
Property DOSBoxProcess As String
|
Property DOSBoxProcess As String
|
||||||
Set(value As String)
|
|
||||||
sDOSBoxProcess = value
|
|
||||||
End Set
|
|
||||||
Get
|
Get
|
||||||
Return sDOSBoxProcess
|
Return sDOSBoxProcess
|
||||||
End Get
|
End Get
|
||||||
|
Set(value As String)
|
||||||
|
sDOSBoxProcess = value
|
||||||
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
ReadOnly Property TruePath As String
|
ReadOnly Property TruePath As String
|
||||||
@@ -213,11 +214,24 @@
|
|||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Property ImportTags As List(Of Tag)
|
||||||
|
Get
|
||||||
|
Return oImportTags
|
||||||
|
End Get
|
||||||
|
Set(value As List(Of Tag))
|
||||||
|
oImportTags = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
Public Function SyncEquals(obj As Object) As Boolean
|
Public Function SyncEquals(obj As Object) As Boolean
|
||||||
Dim oGame As clsGame = TryCast(obj, clsGame)
|
Dim oGame As clsGame = TryCast(obj, clsGame)
|
||||||
If oGame Is Nothing Then
|
If oGame Is Nothing Then
|
||||||
Return False
|
Return False
|
||||||
Else
|
Else
|
||||||
|
If ID <> oGame.ID Then
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
|
||||||
If Name <> oGame.Name Then
|
If Name <> oGame.Name Then
|
||||||
Return False
|
Return False
|
||||||
End If
|
End If
|
||||||
@@ -264,6 +278,18 @@
|
|||||||
End If
|
End If
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
|
Public Function MinimalEquals(obj As Object) As Boolean
|
||||||
|
Dim oGame As clsGame = TryCast(obj, clsGame)
|
||||||
|
If oGame Is Nothing Then
|
||||||
|
Return False
|
||||||
|
Else
|
||||||
|
If ID <> oGame.ID Then
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
Return True
|
||||||
|
End If
|
||||||
|
End Function
|
||||||
|
|
||||||
Public Function ShallowCopy() As clsGame
|
Public Function ShallowCopy() As clsGame
|
||||||
Return DirectCast(Me.MemberwiseClone(), clsGame)
|
Return DirectCast(Me.MemberwiseClone(), clsGame)
|
||||||
End Function
|
End Function
|
||||||
|
|||||||
@@ -0,0 +1,38 @@
|
|||||||
|
Public Class clsGameTag
|
||||||
|
Private sTagID As String = String.Empty
|
||||||
|
Private sMonitorID As String = String.Empty
|
||||||
|
|
||||||
|
Property TagID As String
|
||||||
|
Get
|
||||||
|
Return sTagID
|
||||||
|
End Get
|
||||||
|
Set(value As String)
|
||||||
|
sTagID = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Property MonitorID As String
|
||||||
|
Get
|
||||||
|
Return sMonitorID
|
||||||
|
End Get
|
||||||
|
Set(value As String)
|
||||||
|
sMonitorID = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public Function CoreEquals(obj As Object) As Boolean
|
||||||
|
Dim oGameTag As clsGameTag = TryCast(obj, clsGameTag)
|
||||||
|
If oGameTag Is Nothing Then
|
||||||
|
Return False
|
||||||
|
Else
|
||||||
|
If TagID <> oGameTag.TagID Then
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
If MonitorID <> oGameTag.MonitorID Then
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
Return True
|
||||||
|
End If
|
||||||
|
End Function
|
||||||
|
|
||||||
|
End Class
|
||||||
@@ -0,0 +1,50 @@
|
|||||||
|
Public Class clsTag
|
||||||
|
Private sTagID As String = Guid.NewGuid.ToString
|
||||||
|
Private sTagName As String = String.Empty
|
||||||
|
|
||||||
|
Property ID As String
|
||||||
|
Get
|
||||||
|
Return sTagID
|
||||||
|
End Get
|
||||||
|
Set(value As String)
|
||||||
|
sTagID = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Property Name As String
|
||||||
|
Get
|
||||||
|
Return sTagName
|
||||||
|
End Get
|
||||||
|
Set(value As String)
|
||||||
|
sTagName = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public Function CoreEquals(obj As Object) As Boolean
|
||||||
|
Dim oTag As clsTag = TryCast(obj, clsTag)
|
||||||
|
If oTag Is Nothing Then
|
||||||
|
Return False
|
||||||
|
Else
|
||||||
|
If ID <> oTag.ID Then
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
If Name <> oTag.Name Then
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
Return True
|
||||||
|
End If
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Function MinimalEquals(obj As Object) As Boolean
|
||||||
|
Dim oTag As clsTag = TryCast(obj, clsTag)
|
||||||
|
If oTag Is Nothing Then
|
||||||
|
Return False
|
||||||
|
Else
|
||||||
|
If ID <> oTag.ID Then
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
Return True
|
||||||
|
End If
|
||||||
|
End Function
|
||||||
|
|
||||||
|
End Class
|
||||||
Generated
+1
@@ -96,6 +96,7 @@ Partial Class frmAdvancedImport
|
|||||||
Me.Controls.Add(Me.btnImport)
|
Me.Controls.Add(Me.btnImport)
|
||||||
Me.Controls.Add(Me.lstGames)
|
Me.Controls.Add(Me.lstGames)
|
||||||
Me.Controls.Add(Me.lblGames)
|
Me.Controls.Add(Me.lblGames)
|
||||||
|
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle
|
||||||
Me.MaximizeBox = False
|
Me.MaximizeBox = False
|
||||||
Me.MinimizeBox = False
|
Me.MinimizeBox = False
|
||||||
Me.Name = "frmAdvancedImport"
|
Me.Name = "frmAdvancedImport"
|
||||||
|
|||||||
Generated
+171
@@ -0,0 +1,171 @@
|
|||||||
|
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
|
||||||
|
Partial Class frmFilter
|
||||||
|
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.btnOK = New System.Windows.Forms.Button()
|
||||||
|
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.SuspendLayout()
|
||||||
|
'
|
||||||
|
'btnOK
|
||||||
|
'
|
||||||
|
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
|
||||||
|
'
|
||||||
|
'lblGameTags
|
||||||
|
'
|
||||||
|
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"
|
||||||
|
'
|
||||||
|
'lblTags
|
||||||
|
'
|
||||||
|
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"
|
||||||
|
'
|
||||||
|
'btnRemove
|
||||||
|
'
|
||||||
|
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"
|
||||||
|
'
|
||||||
|
'optAll
|
||||||
|
'
|
||||||
|
Me.optAll.AutoSize = True
|
||||||
|
Me.optAll.Location = New System.Drawing.Point(77, 19)
|
||||||
|
Me.optAll.Name = "optAll"
|
||||||
|
Me.optAll.Size = New System.Drawing.Size(63, 17)
|
||||||
|
Me.optAll.TabIndex = 1
|
||||||
|
Me.optAll.TabStop = True
|
||||||
|
Me.optAll.Text = "All Tags"
|
||||||
|
Me.optAll.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'optAny
|
||||||
|
'
|
||||||
|
Me.optAny.AutoSize = True
|
||||||
|
Me.optAny.Checked = True
|
||||||
|
Me.optAny.Location = New System.Drawing.Point(6, 19)
|
||||||
|
Me.optAny.Name = "optAny"
|
||||||
|
Me.optAny.Size = New System.Drawing.Size(65, 17)
|
||||||
|
Me.optAny.TabIndex = 0
|
||||||
|
Me.optAny.TabStop = True
|
||||||
|
Me.optAny.Text = "Any Tag"
|
||||||
|
Me.optAny.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'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.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.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.ResumeLayout(False)
|
||||||
|
Me.PerformLayout()
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
Friend WithEvents btnOK As System.Windows.Forms.Button
|
||||||
|
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
|
||||||
|
End Class
|
||||||
@@ -0,0 +1,120 @@
|
|||||||
|
<?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>
|
||||||
|
</root>
|
||||||
@@ -0,0 +1,137 @@
|
|||||||
|
Public Class frmFilter
|
||||||
|
|
||||||
|
Public Enum eFilterType As Integer
|
||||||
|
Any = 1
|
||||||
|
All = 2
|
||||||
|
End Enum
|
||||||
|
|
||||||
|
Dim oFilters As New List(Of clsTag)
|
||||||
|
Dim eCurrentFilterType As eFilterType = eFilterType.Any
|
||||||
|
Dim hshTags As New Hashtable
|
||||||
|
Dim bShutdown As Boolean = False
|
||||||
|
|
||||||
|
Public ReadOnly Property Filters As List(Of clsTag)
|
||||||
|
Get
|
||||||
|
Return oFilters
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public ReadOnly Property FilterType As eFilterType
|
||||||
|
Get
|
||||||
|
Return eCurrentFilterType
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Private Sub AddTag()
|
||||||
|
Dim oData As KeyValuePair(Of String, String)
|
||||||
|
Dim oTags As List(Of KeyValuePair(Of String, String))
|
||||||
|
|
||||||
|
If lstTags.SelectedItems.Count = 1 Then
|
||||||
|
oData = lstTags.SelectedItems(0)
|
||||||
|
lstFilter.Items.Add(oData)
|
||||||
|
lstTags.Items.Remove(oData)
|
||||||
|
ElseIf lstTags.SelectedItems.Count > 1 Then
|
||||||
|
oTags = New List(Of KeyValuePair(Of String, String))
|
||||||
|
|
||||||
|
For Each oData In lstTags.SelectedItems
|
||||||
|
oTags.Add(oData)
|
||||||
|
Next
|
||||||
|
|
||||||
|
For Each kp As KeyValuePair(Of String, String) In oTags
|
||||||
|
lstFilter.Items.Add(kp)
|
||||||
|
lstTags.Items.Remove(kp)
|
||||||
|
Next
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub RemoveTag()
|
||||||
|
Dim oData As KeyValuePair(Of String, String)
|
||||||
|
Dim oTags As List(Of KeyValuePair(Of String, String))
|
||||||
|
|
||||||
|
If lstFilter.SelectedItems.Count = 1 Then
|
||||||
|
oData = lstFilter.SelectedItems(0)
|
||||||
|
lstFilter.Items.Remove(oData)
|
||||||
|
lstTags.Items.Add(oData)
|
||||||
|
ElseIf lstFilter.SelectedItems.Count > 1 Then
|
||||||
|
oTags = New List(Of KeyValuePair(Of String, String))
|
||||||
|
|
||||||
|
For Each oData In lstFilter.SelectedItems
|
||||||
|
oTags.Add(oData)
|
||||||
|
Next
|
||||||
|
|
||||||
|
For Each kp As KeyValuePair(Of String, String) In oTags
|
||||||
|
lstFilter.Items.Remove(kp)
|
||||||
|
lstTags.Items.Add(kp)
|
||||||
|
Next
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub LoadData()
|
||||||
|
Dim oTag As clsTag
|
||||||
|
Dim oData As KeyValuePair(Of String, String)
|
||||||
|
|
||||||
|
'Handle Data
|
||||||
|
hshTags = mgrTags.ReadTags()
|
||||||
|
|
||||||
|
'Handle Lists
|
||||||
|
lstTags.Items.Clear()
|
||||||
|
lstFilter.Items.Clear()
|
||||||
|
|
||||||
|
lstTags.ValueMember = "Key"
|
||||||
|
lstTags.DisplayMember = "Value"
|
||||||
|
lstFilter.ValueMember = "Key"
|
||||||
|
lstFilter.DisplayMember = "Value"
|
||||||
|
|
||||||
|
For Each de As DictionaryEntry In hshTags
|
||||||
|
oTag = DirectCast(de.Value, clsTag)
|
||||||
|
oData = New KeyValuePair(Of String, String)(oTag.ID, oTag.Name)
|
||||||
|
lstTags.Items.Add(oData)
|
||||||
|
Next
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub GetFilters()
|
||||||
|
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
|
||||||
|
Else
|
||||||
|
eCurrentFilterType = eFilterType.Any
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub frmGameTags_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||||
|
LoadData()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnOK_Click(sender As Object, e As EventArgs) Handles btnOK.Click
|
||||||
|
GetFilters()
|
||||||
|
bShutdown = True
|
||||||
|
Me.close
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnAdd_Click(sender As Object, e As EventArgs) Handles btnAdd.Click
|
||||||
|
AddTag()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnRemove_Click(sender As Object, e As EventArgs) Handles btnRemove.Click
|
||||||
|
RemoveTag()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub frmFilter_FormClosing(sender As Object, e As FormClosingEventArgs) Handles MyBase.FormClosing
|
||||||
|
If Not bShutdown Then
|
||||||
|
e.Cancel = True
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
End Class
|
||||||
Generated
+53
-13
@@ -44,6 +44,7 @@ Partial Class frmGameManager
|
|||||||
Me.txtName = New System.Windows.Forms.TextBox()
|
Me.txtName = New System.Windows.Forms.TextBox()
|
||||||
Me.chkMonitorOnly = New System.Windows.Forms.CheckBox()
|
Me.chkMonitorOnly = New System.Windows.Forms.CheckBox()
|
||||||
Me.grpExtra = New System.Windows.Forms.GroupBox()
|
Me.grpExtra = New System.Windows.Forms.GroupBox()
|
||||||
|
Me.lblTags = New System.Windows.Forms.Label()
|
||||||
Me.btnIconBrowse = New System.Windows.Forms.Button()
|
Me.btnIconBrowse = New System.Windows.Forms.Button()
|
||||||
Me.txtIcon = New System.Windows.Forms.TextBox()
|
Me.txtIcon = New System.Windows.Forms.TextBox()
|
||||||
Me.lblVersion = New System.Windows.Forms.Label()
|
Me.lblVersion = New System.Windows.Forms.Label()
|
||||||
@@ -57,6 +58,7 @@ Partial Class frmGameManager
|
|||||||
Me.txtAppPath = New System.Windows.Forms.TextBox()
|
Me.txtAppPath = New System.Windows.Forms.TextBox()
|
||||||
Me.nudHours = New System.Windows.Forms.NumericUpDown()
|
Me.nudHours = New System.Windows.Forms.NumericUpDown()
|
||||||
Me.lblHours = New System.Windows.Forms.Label()
|
Me.lblHours = New System.Windows.Forms.Label()
|
||||||
|
Me.btnTags = New System.Windows.Forms.Button()
|
||||||
Me.grpStats = New System.Windows.Forms.GroupBox()
|
Me.grpStats = New System.Windows.Forms.GroupBox()
|
||||||
Me.btnOpenRestorePath = New System.Windows.Forms.Button()
|
Me.btnOpenRestorePath = New System.Windows.Forms.Button()
|
||||||
Me.btnOpenBackupFile = New System.Windows.Forms.Button()
|
Me.btnOpenBackupFile = New System.Windows.Forms.Button()
|
||||||
@@ -75,6 +77,7 @@ Partial Class frmGameManager
|
|||||||
Me.btnCancel = New System.Windows.Forms.Button()
|
Me.btnCancel = New System.Windows.Forms.Button()
|
||||||
Me.chkEnabled = New System.Windows.Forms.CheckBox()
|
Me.chkEnabled = New System.Windows.Forms.CheckBox()
|
||||||
Me.grpFilter = New System.Windows.Forms.GroupBox()
|
Me.grpFilter = New System.Windows.Forms.GroupBox()
|
||||||
|
Me.optTag = New System.Windows.Forms.RadioButton()
|
||||||
Me.optBackupData = New System.Windows.Forms.RadioButton()
|
Me.optBackupData = New System.Windows.Forms.RadioButton()
|
||||||
Me.optPendingRestores = New System.Windows.Forms.RadioButton()
|
Me.optPendingRestores = New System.Windows.Forms.RadioButton()
|
||||||
Me.optAllGames = New System.Windows.Forms.RadioButton()
|
Me.optAllGames = New System.Windows.Forms.RadioButton()
|
||||||
@@ -90,7 +93,7 @@ Partial Class frmGameManager
|
|||||||
'
|
'
|
||||||
Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
|
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.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, 528)
|
Me.btnAdd.Location = New System.Drawing.Point(12, 527)
|
||||||
Me.btnAdd.Name = "btnAdd"
|
Me.btnAdd.Name = "btnAdd"
|
||||||
Me.btnAdd.Size = New System.Drawing.Size(30, 23)
|
Me.btnAdd.Size = New System.Drawing.Size(30, 23)
|
||||||
Me.btnAdd.TabIndex = 2
|
Me.btnAdd.TabIndex = 2
|
||||||
@@ -101,7 +104,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.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.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, 528)
|
Me.btnDelete.Location = New System.Drawing.Point(48, 527)
|
||||||
Me.btnDelete.Name = "btnDelete"
|
Me.btnDelete.Name = "btnDelete"
|
||||||
Me.btnDelete.Size = New System.Drawing.Size(30, 23)
|
Me.btnDelete.Size = New System.Drawing.Size(30, 23)
|
||||||
Me.btnDelete.TabIndex = 3
|
Me.btnDelete.TabIndex = 3
|
||||||
@@ -111,7 +114,7 @@ Partial Class frmGameManager
|
|||||||
'btnBackup
|
'btnBackup
|
||||||
'
|
'
|
||||||
Me.btnBackup.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
Me.btnBackup.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||||
Me.btnBackup.Location = New System.Drawing.Point(616, 527)
|
Me.btnBackup.Location = New System.Drawing.Point(616, 526)
|
||||||
Me.btnBackup.Name = "btnBackup"
|
Me.btnBackup.Name = "btnBackup"
|
||||||
Me.btnBackup.Size = New System.Drawing.Size(75, 23)
|
Me.btnBackup.Size = New System.Drawing.Size(75, 23)
|
||||||
Me.btnBackup.TabIndex = 13
|
Me.btnBackup.TabIndex = 13
|
||||||
@@ -121,7 +124,7 @@ Partial Class frmGameManager
|
|||||||
'btnClose
|
'btnClose
|
||||||
'
|
'
|
||||||
Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||||
Me.btnClose.Location = New System.Drawing.Point(697, 527)
|
Me.btnClose.Location = New System.Drawing.Point(697, 526)
|
||||||
Me.btnClose.Name = "btnClose"
|
Me.btnClose.Name = "btnClose"
|
||||||
Me.btnClose.Size = New System.Drawing.Size(75, 23)
|
Me.btnClose.Size = New System.Drawing.Size(75, 23)
|
||||||
Me.btnClose.TabIndex = 14
|
Me.btnClose.TabIndex = 14
|
||||||
@@ -295,6 +298,7 @@ Partial Class frmGameManager
|
|||||||
'grpExtra
|
'grpExtra
|
||||||
'
|
'
|
||||||
Me.grpExtra.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
Me.grpExtra.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||||
|
Me.grpExtra.Controls.Add(Me.lblTags)
|
||||||
Me.grpExtra.Controls.Add(Me.btnIconBrowse)
|
Me.grpExtra.Controls.Add(Me.btnIconBrowse)
|
||||||
Me.grpExtra.Controls.Add(Me.txtIcon)
|
Me.grpExtra.Controls.Add(Me.txtIcon)
|
||||||
Me.grpExtra.Controls.Add(Me.lblVersion)
|
Me.grpExtra.Controls.Add(Me.lblVersion)
|
||||||
@@ -313,7 +317,18 @@ Partial Class frmGameManager
|
|||||||
Me.grpExtra.Size = New System.Drawing.Size(534, 155)
|
Me.grpExtra.Size = New System.Drawing.Size(534, 155)
|
||||||
Me.grpExtra.TabIndex = 5
|
Me.grpExtra.TabIndex = 5
|
||||||
Me.grpExtra.TabStop = False
|
Me.grpExtra.TabStop = False
|
||||||
Me.grpExtra.Text = "Extra Information"
|
Me.grpExtra.Text = "Game Information"
|
||||||
|
'
|
||||||
|
'lblTags
|
||||||
|
'
|
||||||
|
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.Name = "lblTags"
|
||||||
|
Me.lblTags.Size = New System.Drawing.Size(311, 20)
|
||||||
|
Me.lblTags.TabIndex = 0
|
||||||
|
Me.lblTags.Text = "#Tags"
|
||||||
|
Me.lblTags.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||||
'
|
'
|
||||||
'btnIconBrowse
|
'btnIconBrowse
|
||||||
'
|
'
|
||||||
@@ -426,6 +441,15 @@ Partial Class frmGameManager
|
|||||||
Me.lblHours.TabIndex = 0
|
Me.lblHours.TabIndex = 0
|
||||||
Me.lblHours.Text = "Hours:"
|
Me.lblHours.Text = "Hours:"
|
||||||
'
|
'
|
||||||
|
'btnTags
|
||||||
|
'
|
||||||
|
Me.btnTags.Location = New System.Drawing.Point(535, 360)
|
||||||
|
Me.btnTags.Name = "btnTags"
|
||||||
|
Me.btnTags.Size = New System.Drawing.Size(75, 23)
|
||||||
|
Me.btnTags.TabIndex = 22
|
||||||
|
Me.btnTags.Text = "Tags..."
|
||||||
|
Me.btnTags.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
'grpStats
|
'grpStats
|
||||||
'
|
'
|
||||||
Me.grpStats.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
Me.grpStats.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||||
@@ -543,7 +567,7 @@ Partial Class frmGameManager
|
|||||||
'btnMarkAsRestored
|
'btnMarkAsRestored
|
||||||
'
|
'
|
||||||
Me.btnMarkAsRestored.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
Me.btnMarkAsRestored.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||||
Me.btnMarkAsRestored.Location = New System.Drawing.Point(429, 527)
|
Me.btnMarkAsRestored.Location = New System.Drawing.Point(429, 526)
|
||||||
Me.btnMarkAsRestored.Name = "btnMarkAsRestored"
|
Me.btnMarkAsRestored.Name = "btnMarkAsRestored"
|
||||||
Me.btnMarkAsRestored.Size = New System.Drawing.Size(100, 23)
|
Me.btnMarkAsRestored.Size = New System.Drawing.Size(100, 23)
|
||||||
Me.btnMarkAsRestored.TabIndex = 11
|
Me.btnMarkAsRestored.TabIndex = 11
|
||||||
@@ -553,7 +577,7 @@ Partial Class frmGameManager
|
|||||||
'btnRestore
|
'btnRestore
|
||||||
'
|
'
|
||||||
Me.btnRestore.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
Me.btnRestore.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||||
Me.btnRestore.Location = New System.Drawing.Point(535, 527)
|
Me.btnRestore.Location = New System.Drawing.Point(535, 526)
|
||||||
Me.btnRestore.Name = "btnRestore"
|
Me.btnRestore.Name = "btnRestore"
|
||||||
Me.btnRestore.Size = New System.Drawing.Size(75, 23)
|
Me.btnRestore.Size = New System.Drawing.Size(75, 23)
|
||||||
Me.btnRestore.TabIndex = 12
|
Me.btnRestore.TabIndex = 12
|
||||||
@@ -563,7 +587,7 @@ Partial Class frmGameManager
|
|||||||
'btnSave
|
'btnSave
|
||||||
'
|
'
|
||||||
Me.btnSave.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
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, 361)
|
Me.btnSave.Location = New System.Drawing.Point(616, 360)
|
||||||
Me.btnSave.Name = "btnSave"
|
Me.btnSave.Name = "btnSave"
|
||||||
Me.btnSave.Size = New System.Drawing.Size(75, 23)
|
Me.btnSave.Size = New System.Drawing.Size(75, 23)
|
||||||
Me.btnSave.TabIndex = 8
|
Me.btnSave.TabIndex = 8
|
||||||
@@ -573,17 +597,17 @@ Partial Class frmGameManager
|
|||||||
'lstGames
|
'lstGames
|
||||||
'
|
'
|
||||||
Me.lstGames.FormattingEnabled = True
|
Me.lstGames.FormattingEnabled = True
|
||||||
Me.lstGames.Location = New System.Drawing.Point(12, 112)
|
Me.lstGames.Location = New System.Drawing.Point(12, 138)
|
||||||
Me.lstGames.Name = "lstGames"
|
Me.lstGames.Name = "lstGames"
|
||||||
Me.lstGames.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
|
Me.lstGames.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
|
||||||
Me.lstGames.Size = New System.Drawing.Size(220, 407)
|
Me.lstGames.Size = New System.Drawing.Size(220, 381)
|
||||||
Me.lstGames.Sorted = True
|
Me.lstGames.Sorted = True
|
||||||
Me.lstGames.TabIndex = 1
|
Me.lstGames.TabIndex = 1
|
||||||
'
|
'
|
||||||
'btnCancel
|
'btnCancel
|
||||||
'
|
'
|
||||||
Me.btnCancel.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
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, 361)
|
Me.btnCancel.Location = New System.Drawing.Point(697, 360)
|
||||||
Me.btnCancel.Name = "btnCancel"
|
Me.btnCancel.Name = "btnCancel"
|
||||||
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
|
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
|
||||||
Me.btnCancel.TabIndex = 9
|
Me.btnCancel.TabIndex = 9
|
||||||
@@ -602,16 +626,28 @@ Partial Class frmGameManager
|
|||||||
'
|
'
|
||||||
'grpFilter
|
'grpFilter
|
||||||
'
|
'
|
||||||
|
Me.grpFilter.Controls.Add(Me.optTag)
|
||||||
Me.grpFilter.Controls.Add(Me.optBackupData)
|
Me.grpFilter.Controls.Add(Me.optBackupData)
|
||||||
Me.grpFilter.Controls.Add(Me.optPendingRestores)
|
Me.grpFilter.Controls.Add(Me.optPendingRestores)
|
||||||
Me.grpFilter.Controls.Add(Me.optAllGames)
|
Me.grpFilter.Controls.Add(Me.optAllGames)
|
||||||
Me.grpFilter.Location = New System.Drawing.Point(12, 12)
|
Me.grpFilter.Location = New System.Drawing.Point(12, 12)
|
||||||
Me.grpFilter.Name = "grpFilter"
|
Me.grpFilter.Name = "grpFilter"
|
||||||
Me.grpFilter.Size = New System.Drawing.Size(220, 91)
|
Me.grpFilter.Size = New System.Drawing.Size(220, 113)
|
||||||
Me.grpFilter.TabIndex = 0
|
Me.grpFilter.TabIndex = 0
|
||||||
Me.grpFilter.TabStop = False
|
Me.grpFilter.TabStop = False
|
||||||
Me.grpFilter.Text = "Games Filter"
|
Me.grpFilter.Text = "Games Filter"
|
||||||
'
|
'
|
||||||
|
'optTag
|
||||||
|
'
|
||||||
|
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
|
||||||
|
'
|
||||||
'optBackupData
|
'optBackupData
|
||||||
'
|
'
|
||||||
Me.optBackupData.AutoSize = True
|
Me.optBackupData.AutoSize = True
|
||||||
@@ -649,8 +685,9 @@ Partial Class frmGameManager
|
|||||||
'
|
'
|
||||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||||
Me.ClientSize = New System.Drawing.Size(784, 562)
|
Me.ClientSize = New System.Drawing.Size(784, 561)
|
||||||
Me.Controls.Add(Me.grpFilter)
|
Me.Controls.Add(Me.grpFilter)
|
||||||
|
Me.Controls.Add(Me.btnTags)
|
||||||
Me.Controls.Add(Me.chkEnabled)
|
Me.Controls.Add(Me.chkEnabled)
|
||||||
Me.Controls.Add(Me.btnCancel)
|
Me.Controls.Add(Me.btnCancel)
|
||||||
Me.Controls.Add(Me.chkMonitorOnly)
|
Me.Controls.Add(Me.chkMonitorOnly)
|
||||||
@@ -742,4 +779,7 @@ Partial Class frmGameManager
|
|||||||
Friend WithEvents optAllGames As System.Windows.Forms.RadioButton
|
Friend WithEvents optAllGames As System.Windows.Forms.RadioButton
|
||||||
Friend WithEvents optBackupData As System.Windows.Forms.RadioButton
|
Friend WithEvents optBackupData As System.Windows.Forms.RadioButton
|
||||||
Friend WithEvents btnOpenRestorePath As System.Windows.Forms.Button
|
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
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -205,8 +205,18 @@ Public Class frmGameManager
|
|||||||
Dim oRestoreData As New SortedList
|
Dim oRestoreData As New SortedList
|
||||||
Dim oGame As clsGame
|
Dim oGame As clsGame
|
||||||
Dim oBackup As clsBackup
|
Dim oBackup As clsBackup
|
||||||
|
Dim frm As frmFilter
|
||||||
|
Dim oFilters As New List(Of clsTag)
|
||||||
|
Dim eCurrentFilter As frmFilter.eFilterType = frmFilter.eFilterType.Any
|
||||||
|
|
||||||
AppData = mgrMonitorList.ReadList(mgrMonitorList.eListTypes.ListByKey)
|
If optTag.Checked Then
|
||||||
|
frm = New frmFilter
|
||||||
|
frm.ShowDialog()
|
||||||
|
oFilters = frm.Filters
|
||||||
|
eCurrentFilter = frm.FilterType
|
||||||
|
End If
|
||||||
|
|
||||||
|
AppData = mgrMonitorList.ReadFilteredList(oFilters, eCurrentFilter)
|
||||||
|
|
||||||
If optPendingRestores.Checked Then
|
If optPendingRestores.Checked Then
|
||||||
oRestoreData = mgrRestore.CompareManifests
|
oRestoreData = mgrRestore.CompareManifests
|
||||||
@@ -420,6 +430,22 @@ Public Class frmGameManager
|
|||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub OpenTags()
|
||||||
|
Dim frm As New frmGameTags
|
||||||
|
Dim oApp As clsGame
|
||||||
|
Dim sMonitorIDs As New List(Of String)
|
||||||
|
|
||||||
|
For Each oData In lstGames.SelectedItems
|
||||||
|
oApp = DirectCast(AppData(oData.Key), clsGame)
|
||||||
|
sMonitorIDs.Add(oApp.ID)
|
||||||
|
Next
|
||||||
|
|
||||||
|
frm.IDList = sMonitorIDs
|
||||||
|
frm.GameName = CurrentGame.Name
|
||||||
|
frm.ShowDialog()
|
||||||
|
FillTags(CurrentGame.ID)
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub GetBackupInfo(ByVal oApp As clsGame)
|
Private Sub GetBackupInfo(ByVal oApp As clsGame)
|
||||||
Dim oBackupInfo As clsBackup
|
Dim oBackupInfo As clsBackup
|
||||||
Dim sFileName As String
|
Dim sFileName As String
|
||||||
@@ -550,6 +576,8 @@ Public Class frmGameManager
|
|||||||
txtVersion.Text = oApp.Version
|
txtVersion.Text = oApp.Version
|
||||||
txtIcon.Text = oApp.Icon
|
txtIcon.Text = oApp.Icon
|
||||||
|
|
||||||
|
FillTags(oData.Key)
|
||||||
|
|
||||||
'Icon
|
'Icon
|
||||||
If IO.File.Exists(oApp.Icon) Then
|
If IO.File.Exists(oApp.Icon) Then
|
||||||
pbIcon.Image = Image.FromFile(oApp.Icon)
|
pbIcon.Image = Image.FromFile(oApp.Icon)
|
||||||
@@ -573,6 +601,22 @@ Public Class frmGameManager
|
|||||||
IsLoading = False
|
IsLoading = False
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub FillTags(ByVal sID As String)
|
||||||
|
Dim hshTags As Hashtable
|
||||||
|
Dim oTag As clsTag
|
||||||
|
Dim sTags As String = String.Empty
|
||||||
|
Dim cTrim() As Char = {",", " "}
|
||||||
|
|
||||||
|
hshTags = mgrGameTags.GetTagsByGame(sID)
|
||||||
|
|
||||||
|
For Each de As DictionaryEntry In hshTags
|
||||||
|
oTag = DirectCast(de.Value, clsTag)
|
||||||
|
sTags &= "#" & oTag.Name & ", "
|
||||||
|
Next
|
||||||
|
|
||||||
|
lblTags.Text = sTags.TrimEnd(cTrim)
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub DirtyCheck_ValueChanged(sender As Object, e As EventArgs)
|
Private Sub DirtyCheck_ValueChanged(sender As Object, e As EventArgs)
|
||||||
If Not IsLoading And Not eCurrentMode = eModes.MultiSelect Then
|
If Not IsLoading And Not eCurrentMode = eModes.MultiSelect Then
|
||||||
IsDirty = True
|
IsDirty = True
|
||||||
@@ -639,6 +683,8 @@ Public Class frmGameManager
|
|||||||
lblSync.Visible = False
|
lblSync.Visible = False
|
||||||
chkEnabled.Checked = True
|
chkEnabled.Checked = True
|
||||||
chkMonitorOnly.Checked = False
|
chkMonitorOnly.Checked = False
|
||||||
|
btnTags.Enabled = False
|
||||||
|
lblTags.Visible = False
|
||||||
Case eModes.Edit
|
Case eModes.Edit
|
||||||
grpFilter.Enabled = False
|
grpFilter.Enabled = False
|
||||||
lstGames.Enabled = False
|
lstGames.Enabled = False
|
||||||
@@ -657,6 +703,8 @@ Public Class frmGameManager
|
|||||||
btnDeleteBackup.Enabled = False
|
btnDeleteBackup.Enabled = False
|
||||||
btnOpenBackupFile.Enabled = False
|
btnOpenBackupFile.Enabled = False
|
||||||
btnOpenRestorePath.Enabled = False
|
btnOpenRestorePath.Enabled = False
|
||||||
|
btnTags.Enabled = True
|
||||||
|
lblTags.Visible = True
|
||||||
Case eModes.View
|
Case eModes.View
|
||||||
grpFilter.Enabled = True
|
grpFilter.Enabled = True
|
||||||
lstGames.Enabled = True
|
lstGames.Enabled = True
|
||||||
@@ -670,6 +718,8 @@ Public Class frmGameManager
|
|||||||
btnAdd.Enabled = True
|
btnAdd.Enabled = True
|
||||||
btnDelete.Enabled = True
|
btnDelete.Enabled = True
|
||||||
btnBackup.Enabled = True
|
btnBackup.Enabled = True
|
||||||
|
btnTags.Enabled = True
|
||||||
|
lblTags.Visible = True
|
||||||
Case eModes.ViewTemp
|
Case eModes.ViewTemp
|
||||||
grpFilter.Enabled = True
|
grpFilter.Enabled = True
|
||||||
lstGames.Enabled = True
|
lstGames.Enabled = True
|
||||||
@@ -683,6 +733,8 @@ Public Class frmGameManager
|
|||||||
btnAdd.Enabled = True
|
btnAdd.Enabled = True
|
||||||
btnDelete.Enabled = False
|
btnDelete.Enabled = False
|
||||||
btnBackup.Enabled = False
|
btnBackup.Enabled = False
|
||||||
|
btnTags.Enabled = False
|
||||||
|
lblTags.Visible = False
|
||||||
Case eModes.Disabled
|
Case eModes.Disabled
|
||||||
grpFilter.Enabled = True
|
grpFilter.Enabled = True
|
||||||
lstGames.Enabled = True
|
lstGames.Enabled = True
|
||||||
@@ -690,6 +742,7 @@ Public Class frmGameManager
|
|||||||
WipeControls(grpExtra.Controls)
|
WipeControls(grpExtra.Controls)
|
||||||
WipeControls(grpStats.Controls)
|
WipeControls(grpStats.Controls)
|
||||||
pbIcon.Image = My.Resources.Unknown
|
pbIcon.Image = My.Resources.Unknown
|
||||||
|
lblTags.Text = String.Empty
|
||||||
lblSync.Visible = False
|
lblSync.Visible = False
|
||||||
btnSave.Enabled = False
|
btnSave.Enabled = False
|
||||||
btnCancel.Enabled = False
|
btnCancel.Enabled = False
|
||||||
@@ -703,6 +756,7 @@ Public Class frmGameManager
|
|||||||
btnBackup.Enabled = False
|
btnBackup.Enabled = False
|
||||||
btnRestore.Enabled = False
|
btnRestore.Enabled = False
|
||||||
btnMarkAsRestored.Enabled = False
|
btnMarkAsRestored.Enabled = False
|
||||||
|
btnTags.Enabled = False
|
||||||
Case eModes.MultiSelect
|
Case eModes.MultiSelect
|
||||||
lstGames.Enabled = True
|
lstGames.Enabled = True
|
||||||
WipeControls(grpConfig.Controls)
|
WipeControls(grpConfig.Controls)
|
||||||
@@ -724,6 +778,7 @@ Public Class frmGameManager
|
|||||||
btnBackup.Enabled = True
|
btnBackup.Enabled = True
|
||||||
btnRestore.Enabled = True
|
btnRestore.Enabled = True
|
||||||
btnMarkAsRestored.Enabled = True
|
btnMarkAsRestored.Enabled = True
|
||||||
|
btnTags.Enabled = True
|
||||||
End Select
|
End Select
|
||||||
|
|
||||||
IsLoading = False
|
IsLoading = False
|
||||||
@@ -1121,6 +1176,10 @@ Public Class frmGameManager
|
|||||||
OpenRestorePath()
|
OpenRestorePath()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnTags_Click(sender As Object, e As EventArgs) Handles btnTags.Click
|
||||||
|
OpenTags()
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub btnDeleteBackup_Click(sender As Object, e As EventArgs) Handles btnDeleteBackup.Click
|
Private Sub btnDeleteBackup_Click(sender As Object, e As EventArgs) Handles btnDeleteBackup.Click
|
||||||
DeleteBackup()
|
DeleteBackup()
|
||||||
End Sub
|
End Sub
|
||||||
@@ -1133,11 +1192,12 @@ Public Class frmGameManager
|
|||||||
TriggerSelectedRestore()
|
TriggerSelectedRestore()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub optGamesFilter_CheckedChanged(sender As Object, e As EventArgs) Handles optPendingRestores.CheckedChanged, optAllGames.CheckedChanged
|
Private Sub optGamesFilter_Click(sender As Object, e As EventArgs) Handles optPendingRestores.Click, optAllGames.Click, optBackupData.Click, optTag.Click
|
||||||
lstGames.ClearSelected()
|
lstGames.ClearSelected()
|
||||||
eCurrentMode = eModes.Disabled
|
eCurrentMode = eModes.Disabled
|
||||||
ModeChange()
|
ModeChange()
|
||||||
LoadData()
|
LoadData()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
Generated
+139
@@ -0,0 +1,139 @@
|
|||||||
|
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
|
||||||
|
Partial Class frmGameTags
|
||||||
|
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.lstTags = New System.Windows.Forms.ListBox()
|
||||||
|
Me.lstGameTags = New System.Windows.Forms.ListBox()
|
||||||
|
Me.btnAdd = New System.Windows.Forms.Button()
|
||||||
|
Me.btnRemove = New System.Windows.Forms.Button()
|
||||||
|
Me.lblTags = New System.Windows.Forms.Label()
|
||||||
|
Me.lblGameTags = New System.Windows.Forms.Label()
|
||||||
|
Me.btnClose = New System.Windows.Forms.Button()
|
||||||
|
Me.btnOpenTags = New System.Windows.Forms.Button()
|
||||||
|
Me.SuspendLayout()
|
||||||
|
'
|
||||||
|
'lstTags
|
||||||
|
'
|
||||||
|
Me.lstTags.FormattingEnabled = True
|
||||||
|
Me.lstTags.Location = New System.Drawing.Point(12, 25)
|
||||||
|
Me.lstTags.Name = "lstTags"
|
||||||
|
Me.lstTags.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
|
||||||
|
Me.lstTags.Size = New System.Drawing.Size(150, 199)
|
||||||
|
Me.lstTags.TabIndex = 0
|
||||||
|
'
|
||||||
|
'lstGameTags
|
||||||
|
'
|
||||||
|
Me.lstGameTags.FormattingEnabled = True
|
||||||
|
Me.lstGameTags.Location = New System.Drawing.Point(222, 25)
|
||||||
|
Me.lstGameTags.Name = "lstGameTags"
|
||||||
|
Me.lstGameTags.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended
|
||||||
|
Me.lstGameTags.Size = New System.Drawing.Size(150, 199)
|
||||||
|
Me.lstGameTags.TabIndex = 3
|
||||||
|
'
|
||||||
|
'btnAdd
|
||||||
|
'
|
||||||
|
Me.btnAdd.Location = New System.Drawing.Point(168, 86)
|
||||||
|
Me.btnAdd.Name = "btnAdd"
|
||||||
|
Me.btnAdd.Size = New System.Drawing.Size(48, 23)
|
||||||
|
Me.btnAdd.TabIndex = 1
|
||||||
|
Me.btnAdd.Text = "> >"
|
||||||
|
Me.btnAdd.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'btnRemove
|
||||||
|
'
|
||||||
|
Me.btnRemove.Location = New System.Drawing.Point(168, 115)
|
||||||
|
Me.btnRemove.Name = "btnRemove"
|
||||||
|
Me.btnRemove.Size = New System.Drawing.Size(48, 23)
|
||||||
|
Me.btnRemove.TabIndex = 2
|
||||||
|
Me.btnRemove.Text = "< <"
|
||||||
|
Me.btnRemove.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'lblTags
|
||||||
|
'
|
||||||
|
Me.lblTags.AutoSize = True
|
||||||
|
Me.lblTags.Location = New System.Drawing.Point(49, 9)
|
||||||
|
Me.lblTags.Name = "lblTags"
|
||||||
|
Me.lblTags.Size = New System.Drawing.Size(77, 13)
|
||||||
|
Me.lblTags.TabIndex = 0
|
||||||
|
Me.lblTags.Text = "Available Tags"
|
||||||
|
'
|
||||||
|
'lblGameTags
|
||||||
|
'
|
||||||
|
Me.lblGameTags.AutoSize = True
|
||||||
|
Me.lblGameTags.Location = New System.Drawing.Point(263, 9)
|
||||||
|
Me.lblGameTags.Name = "lblGameTags"
|
||||||
|
Me.lblGameTags.Size = New System.Drawing.Size(68, 13)
|
||||||
|
Me.lblGameTags.TabIndex = 0
|
||||||
|
Me.lblGameTags.Text = "Current Tags"
|
||||||
|
'
|
||||||
|
'btnClose
|
||||||
|
'
|
||||||
|
Me.btnClose.Location = New System.Drawing.Point(297, 230)
|
||||||
|
Me.btnClose.Name = "btnClose"
|
||||||
|
Me.btnClose.Size = New System.Drawing.Size(75, 23)
|
||||||
|
Me.btnClose.TabIndex = 5
|
||||||
|
Me.btnClose.Text = "&Close"
|
||||||
|
Me.btnClose.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'btnOpenTags
|
||||||
|
'
|
||||||
|
Me.btnOpenTags.Location = New System.Drawing.Point(12, 230)
|
||||||
|
Me.btnOpenTags.Name = "btnOpenTags"
|
||||||
|
Me.btnOpenTags.Size = New System.Drawing.Size(90, 23)
|
||||||
|
Me.btnOpenTags.TabIndex = 4
|
||||||
|
Me.btnOpenTags.Text = "Setup &Tags..."
|
||||||
|
Me.btnOpenTags.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'frmGameTags
|
||||||
|
'
|
||||||
|
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.btnOpenTags)
|
||||||
|
Me.Controls.Add(Me.btnClose)
|
||||||
|
Me.Controls.Add(Me.lblGameTags)
|
||||||
|
Me.Controls.Add(Me.lblTags)
|
||||||
|
Me.Controls.Add(Me.btnRemove)
|
||||||
|
Me.Controls.Add(Me.btnAdd)
|
||||||
|
Me.Controls.Add(Me.lstGameTags)
|
||||||
|
Me.Controls.Add(Me.lstTags)
|
||||||
|
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle
|
||||||
|
Me.MaximizeBox = False
|
||||||
|
Me.MinimizeBox = False
|
||||||
|
Me.Name = "frmGameTags"
|
||||||
|
Me.ShowIcon = False
|
||||||
|
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
|
||||||
|
Me.Text = "Edit Tags"
|
||||||
|
Me.ResumeLayout(False)
|
||||||
|
Me.PerformLayout()
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
Friend WithEvents lstTags As System.Windows.Forms.ListBox
|
||||||
|
Friend WithEvents lstGameTags As System.Windows.Forms.ListBox
|
||||||
|
Friend WithEvents btnAdd As System.Windows.Forms.Button
|
||||||
|
Friend WithEvents btnRemove As System.Windows.Forms.Button
|
||||||
|
Friend WithEvents lblTags As System.Windows.Forms.Label
|
||||||
|
Friend WithEvents lblGameTags As System.Windows.Forms.Label
|
||||||
|
Friend WithEvents btnClose As System.Windows.Forms.Button
|
||||||
|
Friend WithEvents btnOpenTags As System.Windows.Forms.Button
|
||||||
|
End Class
|
||||||
@@ -0,0 +1,120 @@
|
|||||||
|
<?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>
|
||||||
|
</root>
|
||||||
@@ -0,0 +1,190 @@
|
|||||||
|
Public Class frmGameTags
|
||||||
|
|
||||||
|
Dim sMonitorIDs As List(Of String)
|
||||||
|
Dim sGameName As String = String.Empty
|
||||||
|
|
||||||
|
Public Property IDList As List(Of String)
|
||||||
|
Get
|
||||||
|
Return sMonitorIDs
|
||||||
|
End Get
|
||||||
|
Set(value As List(Of String))
|
||||||
|
sMonitorIDs = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public Property GameName As String
|
||||||
|
Get
|
||||||
|
Return sGameName
|
||||||
|
End Get
|
||||||
|
Set(value As String)
|
||||||
|
sGameName = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Private Sub AddTag()
|
||||||
|
Dim oData As KeyValuePair(Of String, String)
|
||||||
|
Dim oTags As List(Of KeyValuePair(Of String, String))
|
||||||
|
Dim oGameTag As clsGameTag
|
||||||
|
Dim oGameTags As List(Of clsGameTag)
|
||||||
|
|
||||||
|
If lstTags.SelectedItems.Count = 1 Then
|
||||||
|
oData = lstTags.SelectedItems(0)
|
||||||
|
|
||||||
|
oGameTags = New List(Of clsGameTag)
|
||||||
|
For Each sID As String In IDList
|
||||||
|
oGameTag = New clsGameTag
|
||||||
|
oGameTag.MonitorID = sID
|
||||||
|
oGameTag.TagID = oData.Key
|
||||||
|
oGameTags.Add(oGameTag)
|
||||||
|
Next
|
||||||
|
|
||||||
|
mgrGameTags.DoGameTagAddBatch(oGameTags)
|
||||||
|
|
||||||
|
lstGameTags.Items.Add(oData)
|
||||||
|
lstTags.Items.Remove(oData)
|
||||||
|
ElseIf lstTags.SelectedItems.Count > 1 Then
|
||||||
|
oTags = New List(Of KeyValuePair(Of String, String))
|
||||||
|
|
||||||
|
For Each oData In lstTags.SelectedItems
|
||||||
|
oTags.Add(oData)
|
||||||
|
Next
|
||||||
|
|
||||||
|
For Each kp As KeyValuePair(Of String, String) In oTags
|
||||||
|
oGameTags = New List(Of clsGameTag)
|
||||||
|
For Each sID As String In IDList
|
||||||
|
oGameTag = New clsGameTag
|
||||||
|
oGameTag.MonitorID = sID
|
||||||
|
oGameTag.TagID = kp.Key
|
||||||
|
oGameTags.Add(oGameTag)
|
||||||
|
Next
|
||||||
|
|
||||||
|
mgrGameTags.DoGameTagAddBatch(oGameTags)
|
||||||
|
|
||||||
|
lstGameTags.Items.Add(kp)
|
||||||
|
lstTags.Items.Remove(kp)
|
||||||
|
Next
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub RemoveTag()
|
||||||
|
Dim oData As KeyValuePair(Of String, String)
|
||||||
|
Dim oTags As List(Of KeyValuePair(Of String, String))
|
||||||
|
Dim oGameTag As clsGameTag
|
||||||
|
Dim oGameTags As List(Of clsGameTag)
|
||||||
|
|
||||||
|
If lstGameTags.SelectedItems.Count = 1 Then
|
||||||
|
oData = lstGameTags.SelectedItems(0)
|
||||||
|
|
||||||
|
oGameTags = New List(Of clsGameTag)
|
||||||
|
For Each sID As String In IDList
|
||||||
|
oGameTag = New clsGameTag
|
||||||
|
oGameTag.MonitorID = sID
|
||||||
|
oGameTag.TagID = oData.Key
|
||||||
|
oGameTags.Add(oGameTag)
|
||||||
|
Next
|
||||||
|
|
||||||
|
mgrGameTags.DoGameTagDelete(oGameTags)
|
||||||
|
|
||||||
|
lstGameTags.Items.Remove(oData)
|
||||||
|
lstTags.Items.Add(oData)
|
||||||
|
ElseIf lstGameTags.SelectedItems.Count > 1 Then
|
||||||
|
oTags = New List(Of KeyValuePair(Of String, String))
|
||||||
|
|
||||||
|
For Each oData In lstGameTags.SelectedItems
|
||||||
|
oTags.Add(oData)
|
||||||
|
Next
|
||||||
|
|
||||||
|
For Each kp As KeyValuePair(Of String, String) In oTags
|
||||||
|
oGameTags = New List(Of clsGameTag)
|
||||||
|
For Each sID As String In IDList
|
||||||
|
oGameTag = New clsGameTag
|
||||||
|
oGameTag.MonitorID = sID
|
||||||
|
oGameTag.TagID = kp.Key
|
||||||
|
oGameTags.Add(oGameTag)
|
||||||
|
Next
|
||||||
|
|
||||||
|
mgrGameTags.DoGameTagDelete(oGameTags)
|
||||||
|
|
||||||
|
lstGameTags.Items.Remove(kp)
|
||||||
|
lstTags.Items.Add(kp)
|
||||||
|
Next
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub LoadData()
|
||||||
|
Dim hshTags As Hashtable
|
||||||
|
Dim hshGameTags As Hashtable
|
||||||
|
Dim oTag As clsTag
|
||||||
|
Dim oData As KeyValuePair(Of String, String)
|
||||||
|
|
||||||
|
'Handle Data
|
||||||
|
hshTags = mgrTags.ReadTags()
|
||||||
|
hshGameTags = mgrGameTags.GetTagsByGameMulti(IDList)
|
||||||
|
|
||||||
|
For Each de As DictionaryEntry In hshGameTags
|
||||||
|
oTag = DirectCast(de.Value, clsTag)
|
||||||
|
If hshTags.ContainsKey(oTag.Name) Then
|
||||||
|
hshTags.Remove(oTag.Name)
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
'Handle Lists
|
||||||
|
lstTags.Items.Clear()
|
||||||
|
lstGameTags.Items.Clear()
|
||||||
|
|
||||||
|
lstTags.ValueMember = "Key"
|
||||||
|
lstTags.DisplayMember = "Value"
|
||||||
|
lstGameTags.ValueMember = "Key"
|
||||||
|
lstGameTags.DisplayMember = "Value"
|
||||||
|
|
||||||
|
For Each de As DictionaryEntry In hshGameTags
|
||||||
|
oTag = DirectCast(de.Value, clsTag)
|
||||||
|
oData = New KeyValuePair(Of String, String)(oTag.ID, oTag.Name)
|
||||||
|
lstGameTags.Items.Add(oData)
|
||||||
|
Next
|
||||||
|
|
||||||
|
For Each de As DictionaryEntry In hshTags
|
||||||
|
oTag = DirectCast(de.Value, clsTag)
|
||||||
|
oData = New KeyValuePair(Of String, String)(oTag.ID, oTag.Name)
|
||||||
|
lstTags.Items.Add(oData)
|
||||||
|
Next
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub OpenTags()
|
||||||
|
Dim frm As New frmTags
|
||||||
|
frm.ShowDialog()
|
||||||
|
LoadData()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub SetForm()
|
||||||
|
If IDList.Count > 1 Then
|
||||||
|
Me.Text = "Edit Tags for Multiple Games"
|
||||||
|
Else
|
||||||
|
Me.Text = "Edit Tags for " & GameName
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub frmGameTags_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||||
|
LoadData()
|
||||||
|
SetForm()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnClose_Click(sender As Object, e As EventArgs) Handles btnClose.Click
|
||||||
|
Me.Close()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnAdd_Click(sender As Object, e As EventArgs) Handles btnAdd.Click
|
||||||
|
AddTag()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnRemove_Click(sender As Object, e As EventArgs) Handles btnRemove.Click
|
||||||
|
RemoveTag()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnOpenTags_Click(sender As Object, e As EventArgs) Handles btnOpenTags.Click
|
||||||
|
OpenTags()
|
||||||
|
End Sub
|
||||||
|
End Class
|
||||||
Generated
+18
-2
@@ -80,6 +80,8 @@ Partial Class frmMain
|
|||||||
Me.lblTimeSpent = New System.Windows.Forms.Label()
|
Me.lblTimeSpent = New System.Windows.Forms.Label()
|
||||||
Me.txtGameInfo = New System.Windows.Forms.TextBox()
|
Me.txtGameInfo = New System.Windows.Forms.TextBox()
|
||||||
Me.btnCancelOperation = New System.Windows.Forms.Button()
|
Me.btnCancelOperation = New System.Windows.Forms.Button()
|
||||||
|
Me.gMonSetupTags = New System.Windows.Forms.ToolStripMenuItem()
|
||||||
|
Me.gMonTraySetupTags = New System.Windows.Forms.ToolStripMenuItem()
|
||||||
Me.gMonTrayMenu.SuspendLayout()
|
Me.gMonTrayMenu.SuspendLayout()
|
||||||
Me.gMonStatusStrip.SuspendLayout()
|
Me.gMonStatusStrip.SuspendLayout()
|
||||||
Me.gMonMainMenu.SuspendLayout()
|
Me.gMonMainMenu.SuspendLayout()
|
||||||
@@ -126,7 +128,7 @@ Partial Class frmMain
|
|||||||
'
|
'
|
||||||
'gMonTraySetup
|
'gMonTraySetup
|
||||||
'
|
'
|
||||||
Me.gMonTraySetup.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonTraySetupAddWizard, Me.gMonTraySetupGameManager, Me.gMonTraySetupCustomVariables})
|
Me.gMonTraySetup.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonTraySetupAddWizard, Me.gMonTraySetupGameManager, Me.gMonTraySetupCustomVariables, Me.gMonTraySetupTags})
|
||||||
Me.gMonTraySetup.Name = "gMonTraySetup"
|
Me.gMonTraySetup.Name = "gMonTraySetup"
|
||||||
Me.gMonTraySetup.Size = New System.Drawing.Size(161, 22)
|
Me.gMonTraySetup.Size = New System.Drawing.Size(161, 22)
|
||||||
Me.gMonTraySetup.Text = "&Setup"
|
Me.gMonTraySetup.Text = "&Setup"
|
||||||
@@ -309,7 +311,7 @@ Partial Class frmMain
|
|||||||
'
|
'
|
||||||
'gMonSetup
|
'gMonSetup
|
||||||
'
|
'
|
||||||
Me.gMonSetup.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonSetupGameManager, Me.gMonSetupAddWizard, Me.gMonSetupCustomVariables})
|
Me.gMonSetup.DropDownItems.AddRange(New System.Windows.Forms.ToolStripItem() {Me.gMonSetupGameManager, Me.gMonSetupAddWizard, Me.gMonSetupCustomVariables, Me.gMonSetupTags})
|
||||||
Me.gMonSetup.Name = "gMonSetup"
|
Me.gMonSetup.Name = "gMonSetup"
|
||||||
Me.gMonSetup.Size = New System.Drawing.Size(49, 20)
|
Me.gMonSetup.Size = New System.Drawing.Size(49, 20)
|
||||||
Me.gMonSetup.Text = "&Setup"
|
Me.gMonSetup.Text = "&Setup"
|
||||||
@@ -489,6 +491,18 @@ Partial Class frmMain
|
|||||||
Me.btnCancelOperation.Text = "&Cancel"
|
Me.btnCancelOperation.Text = "&Cancel"
|
||||||
Me.btnCancelOperation.UseVisualStyleBackColor = True
|
Me.btnCancelOperation.UseVisualStyleBackColor = True
|
||||||
'
|
'
|
||||||
|
'gMonSetupTags
|
||||||
|
'
|
||||||
|
Me.gMonSetupTags.Name = "gMonSetupTags"
|
||||||
|
Me.gMonSetupTags.Size = New System.Drawing.Size(201, 22)
|
||||||
|
Me.gMonSetupTags.Text = "&Tags..."
|
||||||
|
'
|
||||||
|
'gMonTraySetupTags
|
||||||
|
'
|
||||||
|
Me.gMonTraySetupTags.Name = "gMonTraySetupTags"
|
||||||
|
Me.gMonTraySetupTags.Size = New System.Drawing.Size(201, 22)
|
||||||
|
Me.gMonTraySetupTags.Text = "&Tags"
|
||||||
|
'
|
||||||
'frmMain
|
'frmMain
|
||||||
'
|
'
|
||||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||||
@@ -582,4 +596,6 @@ Partial Class frmMain
|
|||||||
Friend WithEvents gMonHelpCheckforUpdates As System.Windows.Forms.ToolStripMenuItem
|
Friend WithEvents gMonHelpCheckforUpdates As System.Windows.Forms.ToolStripMenuItem
|
||||||
Friend WithEvents btnCancelOperation As System.Windows.Forms.Button
|
Friend WithEvents btnCancelOperation As System.Windows.Forms.Button
|
||||||
Friend WithEvents gMonStripAdminButton As ToolStripSplitButton
|
Friend WithEvents gMonStripAdminButton As ToolStripSplitButton
|
||||||
|
Friend WithEvents gMonTraySetupTags As System.Windows.Forms.ToolStripMenuItem
|
||||||
|
Friend WithEvents gMonSetupTags As System.Windows.Forms.ToolStripMenuItem
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
+62
-13
@@ -367,8 +367,10 @@ Public Class frmMain
|
|||||||
lblGameTitle.Text = "Last Game: " & oProcess.GameInfo.CroppedName
|
lblGameTitle.Text = "Last Game: " & oProcess.GameInfo.CroppedName
|
||||||
pbIcon.Image = oPriorImage
|
pbIcon.Image = oPriorImage
|
||||||
txtGameInfo.Text = sPriorDetails
|
txtGameInfo.Text = sPriorDetails
|
||||||
lblTimeTitle.Visible = True
|
If oSettings.TimeTracking Then
|
||||||
lblTimeSpent.Visible = True
|
lblTimeTitle.Visible = True
|
||||||
|
lblTimeSpent.Visible = True
|
||||||
|
End If
|
||||||
Else
|
Else
|
||||||
pbIcon.Image = My.Resources.Searching
|
pbIcon.Image = My.Resources.Searching
|
||||||
lblGameTitle.Text = "No Game Detected"
|
lblGameTitle.Text = "No Game Detected"
|
||||||
@@ -451,7 +453,12 @@ Public Class frmMain
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
'Do Time Update
|
'Do Time Update
|
||||||
UpdateTimeSpent(oProcess.GameInfo.Hours, 0)
|
If oSettings.TimeTracking Then
|
||||||
|
UpdateTimeSpent(oProcess.GameInfo.Hours, 0)
|
||||||
|
Else
|
||||||
|
lblTimeTitle.Visible = False
|
||||||
|
lblTimeSpent.Visible = False
|
||||||
|
End If
|
||||||
|
|
||||||
'Set Details
|
'Set Details
|
||||||
If sFileName = String.Empty Then
|
If sFileName = String.Empty Then
|
||||||
@@ -538,6 +545,14 @@ Public Class frmMain
|
|||||||
"See gpl-3.0.html in the program folder for details.", MsgBoxStyle.Information, "Game Backup Monitor")
|
"See gpl-3.0.html in the program folder for details.", MsgBoxStyle.Information, "Game Backup Monitor")
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub OpenTags()
|
||||||
|
Dim frm As New frmTags
|
||||||
|
PauseScan()
|
||||||
|
frm.ShowDialog()
|
||||||
|
If oSettings.Sync Then mgrMonitorList.SyncMonitorLists()
|
||||||
|
ResumeScan()
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub OpenGameManager(Optional ByVal bPendingRestores As Boolean = False)
|
Private Sub OpenGameManager(Optional ByVal bPendingRestores As Boolean = False)
|
||||||
Dim frm As New frmGameManager
|
Dim frm As New frmGameManager
|
||||||
PauseScan()
|
PauseScan()
|
||||||
@@ -548,7 +563,7 @@ Public Class frmMain
|
|||||||
If oSettings.Sync Then mgrMonitorList.SyncMonitorLists()
|
If oSettings.Sync Then mgrMonitorList.SyncMonitorLists()
|
||||||
ResumeScan()
|
ResumeScan()
|
||||||
|
|
||||||
'Handle manual backup trigger
|
'Handle backup trigger
|
||||||
If frm.TriggerBackup Then
|
If frm.TriggerBackup Then
|
||||||
RunManualBackup(frm.BackupList)
|
RunManualBackup(frm.BackupList)
|
||||||
End If
|
End If
|
||||||
@@ -597,7 +612,7 @@ Public Class frmMain
|
|||||||
frm.Settings = oSettings
|
frm.Settings = oSettings
|
||||||
PauseScan()
|
PauseScan()
|
||||||
frm.ShowDialog()
|
frm.ShowDialog()
|
||||||
LoadSettings()
|
LoadAndVerify()
|
||||||
bFirstRun = False
|
bFirstRun = False
|
||||||
ResumeScan()
|
ResumeScan()
|
||||||
End Sub
|
End Sub
|
||||||
@@ -668,7 +683,14 @@ Public Class frmMain
|
|||||||
oRemoteDatabase.DatabaseUpgrade()
|
oRemoteDatabase.DatabaseUpgrade()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub LoadSettings()
|
Private Sub LoadAndVerify()
|
||||||
|
|
||||||
|
'The application cannot continue if this fails
|
||||||
|
If Not oBackup.CheckForUtilities(mgrPath.Utility7zLocation) Then
|
||||||
|
MsgBox("7-Zip was not found in the Game Backup Monitor utilities folder. The application cannot continue.", MsgBoxStyle.Critical, "Game Backup Monitor")
|
||||||
|
bShutdown = True
|
||||||
|
Me.Close()
|
||||||
|
End If
|
||||||
|
|
||||||
'Local Database Check
|
'Local Database Check
|
||||||
VerifyDBVersion(mgrSQLite.Database.Local)
|
VerifyDBVersion(mgrSQLite.Database.Local)
|
||||||
@@ -698,9 +720,11 @@ Public Class frmMain
|
|||||||
'Load Game Settings
|
'Load Game Settings
|
||||||
LoadGameSettings()
|
LoadGameSettings()
|
||||||
|
|
||||||
'Check for utilities
|
'Verify the "Start with Windows" setting
|
||||||
If Not oBackup.CheckForUtilities(mgrPath.Utility7zLocation) Then
|
If oSettings.StartWithWindows Then
|
||||||
UpdateLog("The correct version of 7-Zip was not found! Please re-install GBM, you may experience an application crash if a backup or restore is performed.", True, ToolTipIcon.Error)
|
If Not VerifyStartWithWindows() Then
|
||||||
|
UpdateLog("GBM is running from a new location, the Windows startup entry has been updated.", False, ToolTipIcon.Info)
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
@@ -904,7 +928,7 @@ Public Class frmMain
|
|||||||
txtLog.ScrollToCaret()
|
txtLog.ScrollToCaret()
|
||||||
gMonTray.BalloonTipText = sLogUpdate
|
gMonTray.BalloonTipText = sLogUpdate
|
||||||
gMonTray.BalloonTipIcon = objIcon
|
gMonTray.BalloonTipIcon = objIcon
|
||||||
If bTrayUpdate Then gMonTray.ShowBalloonTip(2000)
|
If bTrayUpdate Then gMonTray.ShowBalloonTip(5000)
|
||||||
End If
|
End If
|
||||||
Application.DoEvents()
|
Application.DoEvents()
|
||||||
End Sub
|
End Sub
|
||||||
@@ -1047,6 +1071,27 @@ Public Class frmMain
|
|||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Function VerifyStartWithWindows() As Boolean
|
||||||
|
Dim oKey As Microsoft.Win32.RegistryKey
|
||||||
|
Dim sAppName As String = Application.ProductName
|
||||||
|
Dim sAppPath As String = Application.ExecutablePath
|
||||||
|
Dim sRegPath As String
|
||||||
|
|
||||||
|
oKey = Microsoft.Win32.Registry.CurrentUser.OpenSubKey("SOFTWARE\Microsoft\Windows\CurrentVersion\Run", True)
|
||||||
|
sRegPath = oKey.GetValue(sAppName, String.Empty).ToString.Replace("""", "")
|
||||||
|
oKey.Close()
|
||||||
|
|
||||||
|
If sAppPath.ToLower <> sRegPath.ToLower Then
|
||||||
|
oKey = Microsoft.Win32.Registry.CurrentUser.OpenSubKey("SOFTWARE\Microsoft\Windows\CurrentVersion\Run", True)
|
||||||
|
oKey.SetValue(sAppName, """" & sAppPath & """")
|
||||||
|
oKey.Close()
|
||||||
|
Return False
|
||||||
|
Else
|
||||||
|
Return True
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Function
|
||||||
|
|
||||||
Private Sub CheckForSavedDuplicate()
|
Private Sub CheckForSavedDuplicate()
|
||||||
For Each o As clsGame In oProcess.DuplicateList
|
For Each o As clsGame In oProcess.DuplicateList
|
||||||
If o.ProcessPath.ToLower = oProcess.GameInfo.ProcessPath.ToLower Then
|
If o.ProcessPath.ToLower = oProcess.GameInfo.ProcessPath.ToLower Then
|
||||||
@@ -1091,7 +1136,7 @@ Public Class frmMain
|
|||||||
|
|
||||||
If slItems.Count > 0 Then
|
If slItems.Count > 0 Then
|
||||||
For Each oItem As clsBackup In slItems.Values
|
For Each oItem As clsBackup In slItems.Values
|
||||||
UpdateLog("[Sync Notifier] " & oItem.Name & " entry removed from local manfiest.", False)
|
UpdateLog(oItem.Name & " entry removed from local manfiest.", False)
|
||||||
Next
|
Next
|
||||||
MsgBox(slItems.Count & " entries removed from the local manifest.")
|
MsgBox(slItems.Count & " entries removed from the local manifest.")
|
||||||
Else
|
Else
|
||||||
@@ -1185,6 +1230,10 @@ Public Class frmMain
|
|||||||
OpenCustomVariables()
|
OpenCustomVariables()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub gMonSetupTags_Click(sender As Object, e As EventArgs) Handles gMonSetupTags.Click, gMonTraySetupTags.Click
|
||||||
|
OpenTags()
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub gMonHelpAbout_Click(sender As Object, e As EventArgs) Handles gMonHelpAbout.Click
|
Private Sub gMonHelpAbout_Click(sender As Object, e As EventArgs) Handles gMonHelpAbout.Click
|
||||||
OpenAbout()
|
OpenAbout()
|
||||||
End Sub
|
End Sub
|
||||||
@@ -1337,7 +1386,7 @@ Public Class frmMain
|
|||||||
If Not bCancelledByUser Then
|
If Not bCancelledByUser Then
|
||||||
DoMultiGameCheck()
|
DoMultiGameCheck()
|
||||||
UpdateLog(oProcess.GameInfo.Name & " has ended.", False)
|
UpdateLog(oProcess.GameInfo.Name & " has ended.", False)
|
||||||
HandleTimeSpent()
|
If oSettings.TimeTracking Then HandleTimeSpent()
|
||||||
RunBackup()
|
RunBackup()
|
||||||
End If
|
End If
|
||||||
bCancelledByUser = False
|
bCancelledByUser = False
|
||||||
@@ -1346,7 +1395,7 @@ Public Class frmMain
|
|||||||
Private Sub Main_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
|
Private Sub Main_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
|
||||||
SetForm()
|
SetForm()
|
||||||
VerifyGameDataPath()
|
VerifyGameDataPath()
|
||||||
LoadSettings()
|
LoadAndVerify()
|
||||||
VerifyCustomPathVariables()
|
VerifyCustomPathVariables()
|
||||||
|
|
||||||
If oSettings.StartToTray Then
|
If oSettings.StartToTray Then
|
||||||
|
|||||||
Generated
+20
-7
@@ -25,6 +25,7 @@ Partial Class frmSettings
|
|||||||
Me.chkMonitorOnStartup = New System.Windows.Forms.CheckBox()
|
Me.chkMonitorOnStartup = New System.Windows.Forms.CheckBox()
|
||||||
Me.chkBackupConfirm = New System.Windows.Forms.CheckBox()
|
Me.chkBackupConfirm = New System.Windows.Forms.CheckBox()
|
||||||
Me.grpGeneral = New System.Windows.Forms.GroupBox()
|
Me.grpGeneral = New System.Windows.Forms.GroupBox()
|
||||||
|
Me.chkTimeTracking = New System.Windows.Forms.CheckBox()
|
||||||
Me.chkStartWindows = New System.Windows.Forms.CheckBox()
|
Me.chkStartWindows = New System.Windows.Forms.CheckBox()
|
||||||
Me.chkSync = New System.Windows.Forms.CheckBox()
|
Me.chkSync = New System.Windows.Forms.CheckBox()
|
||||||
Me.chkShowDetectionTips = New System.Windows.Forms.CheckBox()
|
Me.chkShowDetectionTips = New System.Windows.Forms.CheckBox()
|
||||||
@@ -68,6 +69,7 @@ Partial Class frmSettings
|
|||||||
'
|
'
|
||||||
'grpGeneral
|
'grpGeneral
|
||||||
'
|
'
|
||||||
|
Me.grpGeneral.Controls.Add(Me.chkTimeTracking)
|
||||||
Me.grpGeneral.Controls.Add(Me.chkStartWindows)
|
Me.grpGeneral.Controls.Add(Me.chkStartWindows)
|
||||||
Me.grpGeneral.Controls.Add(Me.chkSync)
|
Me.grpGeneral.Controls.Add(Me.chkSync)
|
||||||
Me.grpGeneral.Controls.Add(Me.chkShowDetectionTips)
|
Me.grpGeneral.Controls.Add(Me.chkShowDetectionTips)
|
||||||
@@ -75,11 +77,21 @@ Partial Class frmSettings
|
|||||||
Me.grpGeneral.Controls.Add(Me.chkMonitorOnStartup)
|
Me.grpGeneral.Controls.Add(Me.chkMonitorOnStartup)
|
||||||
Me.grpGeneral.Location = New System.Drawing.Point(12, 12)
|
Me.grpGeneral.Location = New System.Drawing.Point(12, 12)
|
||||||
Me.grpGeneral.Name = "grpGeneral"
|
Me.grpGeneral.Name = "grpGeneral"
|
||||||
Me.grpGeneral.Size = New System.Drawing.Size(360, 145)
|
Me.grpGeneral.Size = New System.Drawing.Size(360, 165)
|
||||||
Me.grpGeneral.TabIndex = 0
|
Me.grpGeneral.TabIndex = 0
|
||||||
Me.grpGeneral.TabStop = False
|
Me.grpGeneral.TabStop = False
|
||||||
Me.grpGeneral.Text = "General"
|
Me.grpGeneral.Text = "General"
|
||||||
'
|
'
|
||||||
|
'chkTimeTracking
|
||||||
|
'
|
||||||
|
Me.chkTimeTracking.AutoSize = True
|
||||||
|
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.Text = "Enable time tracking"
|
||||||
|
Me.chkTimeTracking.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
'chkStartWindows
|
'chkStartWindows
|
||||||
'
|
'
|
||||||
Me.chkStartWindows.AutoSize = True
|
Me.chkStartWindows.AutoSize = True
|
||||||
@@ -93,7 +105,7 @@ Partial Class frmSettings
|
|||||||
'chkSync
|
'chkSync
|
||||||
'
|
'
|
||||||
Me.chkSync.AutoSize = True
|
Me.chkSync.AutoSize = True
|
||||||
Me.chkSync.Location = New System.Drawing.Point(6, 111)
|
Me.chkSync.Location = New System.Drawing.Point(6, 134)
|
||||||
Me.chkSync.Name = "chkSync"
|
Me.chkSync.Name = "chkSync"
|
||||||
Me.chkSync.Size = New System.Drawing.Size(208, 17)
|
Me.chkSync.Size = New System.Drawing.Size(208, 17)
|
||||||
Me.chkSync.TabIndex = 4
|
Me.chkSync.TabIndex = 4
|
||||||
@@ -125,7 +137,7 @@ Partial Class frmSettings
|
|||||||
Me.grpPaths.Controls.Add(Me.btnBackupFolder)
|
Me.grpPaths.Controls.Add(Me.btnBackupFolder)
|
||||||
Me.grpPaths.Controls.Add(Me.lblBackupFolder)
|
Me.grpPaths.Controls.Add(Me.lblBackupFolder)
|
||||||
Me.grpPaths.Controls.Add(Me.txtBackupFolder)
|
Me.grpPaths.Controls.Add(Me.txtBackupFolder)
|
||||||
Me.grpPaths.Location = New System.Drawing.Point(12, 311)
|
Me.grpPaths.Location = New System.Drawing.Point(12, 331)
|
||||||
Me.grpPaths.Name = "grpPaths"
|
Me.grpPaths.Name = "grpPaths"
|
||||||
Me.grpPaths.Size = New System.Drawing.Size(360, 60)
|
Me.grpPaths.Size = New System.Drawing.Size(360, 60)
|
||||||
Me.grpPaths.TabIndex = 2
|
Me.grpPaths.TabIndex = 2
|
||||||
@@ -160,7 +172,7 @@ Partial Class frmSettings
|
|||||||
'btnSave
|
'btnSave
|
||||||
'
|
'
|
||||||
Me.btnSave.DialogResult = System.Windows.Forms.DialogResult.OK
|
Me.btnSave.DialogResult = System.Windows.Forms.DialogResult.OK
|
||||||
Me.btnSave.Location = New System.Drawing.Point(216, 377)
|
Me.btnSave.Location = New System.Drawing.Point(216, 397)
|
||||||
Me.btnSave.Name = "btnSave"
|
Me.btnSave.Name = "btnSave"
|
||||||
Me.btnSave.Size = New System.Drawing.Size(75, 23)
|
Me.btnSave.Size = New System.Drawing.Size(75, 23)
|
||||||
Me.btnSave.TabIndex = 3
|
Me.btnSave.TabIndex = 3
|
||||||
@@ -170,7 +182,7 @@ Partial Class frmSettings
|
|||||||
'btnCancel
|
'btnCancel
|
||||||
'
|
'
|
||||||
Me.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel
|
Me.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel
|
||||||
Me.btnCancel.Location = New System.Drawing.Point(297, 377)
|
Me.btnCancel.Location = New System.Drawing.Point(297, 397)
|
||||||
Me.btnCancel.Name = "btnCancel"
|
Me.btnCancel.Name = "btnCancel"
|
||||||
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
|
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
|
||||||
Me.btnCancel.TabIndex = 4
|
Me.btnCancel.TabIndex = 4
|
||||||
@@ -184,7 +196,7 @@ Partial Class frmSettings
|
|||||||
Me.grpBackup.Controls.Add(Me.chkOverwriteWarning)
|
Me.grpBackup.Controls.Add(Me.chkOverwriteWarning)
|
||||||
Me.grpBackup.Controls.Add(Me.chkCreateFolder)
|
Me.grpBackup.Controls.Add(Me.chkCreateFolder)
|
||||||
Me.grpBackup.Controls.Add(Me.chkBackupConfirm)
|
Me.grpBackup.Controls.Add(Me.chkBackupConfirm)
|
||||||
Me.grpBackup.Location = New System.Drawing.Point(12, 163)
|
Me.grpBackup.Location = New System.Drawing.Point(12, 183)
|
||||||
Me.grpBackup.Name = "grpBackup"
|
Me.grpBackup.Name = "grpBackup"
|
||||||
Me.grpBackup.Size = New System.Drawing.Size(360, 142)
|
Me.grpBackup.Size = New System.Drawing.Size(360, 142)
|
||||||
Me.grpBackup.TabIndex = 1
|
Me.grpBackup.TabIndex = 1
|
||||||
@@ -235,7 +247,7 @@ Partial Class frmSettings
|
|||||||
'
|
'
|
||||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||||
Me.ClientSize = New System.Drawing.Size(384, 412)
|
Me.ClientSize = New System.Drawing.Size(384, 431)
|
||||||
Me.Controls.Add(Me.grpBackup)
|
Me.Controls.Add(Me.grpBackup)
|
||||||
Me.Controls.Add(Me.btnCancel)
|
Me.Controls.Add(Me.btnCancel)
|
||||||
Me.Controls.Add(Me.btnSave)
|
Me.Controls.Add(Me.btnSave)
|
||||||
@@ -277,4 +289,5 @@ Partial Class frmSettings
|
|||||||
Friend WithEvents chkSync As System.Windows.Forms.CheckBox
|
Friend WithEvents chkSync As System.Windows.Forms.CheckBox
|
||||||
Friend WithEvents chkCheckSum As System.Windows.Forms.CheckBox
|
Friend WithEvents chkCheckSum As System.Windows.Forms.CheckBox
|
||||||
Friend WithEvents chkStartWindows As System.Windows.Forms.CheckBox
|
Friend WithEvents chkStartWindows As System.Windows.Forms.CheckBox
|
||||||
|
Friend WithEvents chkTimeTracking As System.Windows.Forms.CheckBox
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -53,6 +53,7 @@
|
|||||||
oSettings.CreateSubFolder = chkCreateFolder.Checked
|
oSettings.CreateSubFolder = chkCreateFolder.Checked
|
||||||
oSettings.ShowOverwriteWarning = chkOverwriteWarning.Checked
|
oSettings.ShowOverwriteWarning = chkOverwriteWarning.Checked
|
||||||
oSettings.RestoreOnLaunch = chkRestoreOnLaunch.Checked
|
oSettings.RestoreOnLaunch = chkRestoreOnLaunch.Checked
|
||||||
|
oSettings.TimeTracking = chkTimeTracking.Checked
|
||||||
|
|
||||||
'We need to clear all checksums its turned off
|
'We need to clear all checksums its turned off
|
||||||
If chkCheckSum.Checked = False And oSettings.CheckSum = True Then
|
If chkCheckSum.Checked = False And oSettings.CheckSum = True Then
|
||||||
@@ -102,6 +103,7 @@
|
|||||||
txtBackupFolder.Text = oSettings.BackupFolder
|
txtBackupFolder.Text = oSettings.BackupFolder
|
||||||
chkSync.Checked = oSettings.Sync
|
chkSync.Checked = oSettings.Sync
|
||||||
chkCheckSum.Checked = oSettings.CheckSum
|
chkCheckSum.Checked = oSettings.CheckSum
|
||||||
|
chkTimeTracking.Checked = oSettings.TimeTracking
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub btnSave_Click(sender As System.Object, e As System.EventArgs) Handles btnSave.Click
|
Private Sub btnSave_Click(sender As System.Object, e As System.EventArgs) Handles btnSave.Click
|
||||||
|
|||||||
Generated
+172
@@ -0,0 +1,172 @@
|
|||||||
|
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()> _
|
||||||
|
Partial Class frmTags
|
||||||
|
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.grpTag = New System.Windows.Forms.GroupBox()
|
||||||
|
Me.txtName = New System.Windows.Forms.TextBox()
|
||||||
|
Me.lblName = New System.Windows.Forms.Label()
|
||||||
|
Me.btnClose = New System.Windows.Forms.Button()
|
||||||
|
Me.btnDelete = New System.Windows.Forms.Button()
|
||||||
|
Me.btnAdd = New System.Windows.Forms.Button()
|
||||||
|
Me.lstTags = New System.Windows.Forms.ListBox()
|
||||||
|
Me.txtID = New System.Windows.Forms.TextBox()
|
||||||
|
Me.btnCancel = New System.Windows.Forms.Button()
|
||||||
|
Me.btnSave = New System.Windows.Forms.Button()
|
||||||
|
Me.grpTag.SuspendLayout()
|
||||||
|
Me.SuspendLayout()
|
||||||
|
'
|
||||||
|
'grpTag
|
||||||
|
'
|
||||||
|
Me.grpTag.Controls.Add(Me.txtName)
|
||||||
|
Me.grpTag.Controls.Add(Me.lblName)
|
||||||
|
Me.grpTag.Location = New System.Drawing.Point(238, 12)
|
||||||
|
Me.grpTag.Name = "grpTag"
|
||||||
|
Me.grpTag.Size = New System.Drawing.Size(334, 50)
|
||||||
|
Me.grpTag.TabIndex = 3
|
||||||
|
Me.grpTag.TabStop = False
|
||||||
|
Me.grpTag.Text = "Configuration"
|
||||||
|
'
|
||||||
|
'txtName
|
||||||
|
'
|
||||||
|
Me.txtName.Location = New System.Drawing.Point(50, 19)
|
||||||
|
Me.txtName.Name = "txtName"
|
||||||
|
Me.txtName.Size = New System.Drawing.Size(278, 20)
|
||||||
|
Me.txtName.TabIndex = 1
|
||||||
|
'
|
||||||
|
'lblName
|
||||||
|
'
|
||||||
|
Me.lblName.AutoSize = True
|
||||||
|
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 = 0
|
||||||
|
Me.lblName.Text = "Name:"
|
||||||
|
'
|
||||||
|
'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(497, 226)
|
||||||
|
Me.btnClose.Name = "btnClose"
|
||||||
|
Me.btnClose.Size = New System.Drawing.Size(75, 23)
|
||||||
|
Me.btnClose.TabIndex = 7
|
||||||
|
Me.btnClose.Text = "C&lose"
|
||||||
|
Me.btnClose.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'btnDelete
|
||||||
|
'
|
||||||
|
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, 226)
|
||||||
|
Me.btnDelete.Name = "btnDelete"
|
||||||
|
Me.btnDelete.Size = New System.Drawing.Size(30, 23)
|
||||||
|
Me.btnDelete.TabIndex = 2
|
||||||
|
Me.btnDelete.Text = "-"
|
||||||
|
Me.btnDelete.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'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, 226)
|
||||||
|
Me.btnAdd.Name = "btnAdd"
|
||||||
|
Me.btnAdd.Size = New System.Drawing.Size(30, 23)
|
||||||
|
Me.btnAdd.TabIndex = 1
|
||||||
|
Me.btnAdd.Text = "+"
|
||||||
|
Me.btnAdd.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'lstTags
|
||||||
|
'
|
||||||
|
Me.lstTags.FormattingEnabled = True
|
||||||
|
Me.lstTags.Location = New System.Drawing.Point(12, 12)
|
||||||
|
Me.lstTags.Name = "lstTags"
|
||||||
|
Me.lstTags.Size = New System.Drawing.Size(220, 212)
|
||||||
|
Me.lstTags.Sorted = True
|
||||||
|
Me.lstTags.TabIndex = 0
|
||||||
|
'
|
||||||
|
'txtID
|
||||||
|
'
|
||||||
|
Me.txtID.Enabled = False
|
||||||
|
Me.txtID.Location = New System.Drawing.Point(377, 67)
|
||||||
|
Me.txtID.Name = "txtID"
|
||||||
|
Me.txtID.Size = New System.Drawing.Size(33, 20)
|
||||||
|
Me.txtID.TabIndex = 4
|
||||||
|
Me.txtID.TabStop = False
|
||||||
|
Me.txtID.Visible = False
|
||||||
|
'
|
||||||
|
'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(497, 67)
|
||||||
|
Me.btnCancel.Name = "btnCancel"
|
||||||
|
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
|
||||||
|
Me.btnCancel.TabIndex = 6
|
||||||
|
Me.btnCancel.Text = "&Cancel"
|
||||||
|
Me.btnCancel.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(416, 67)
|
||||||
|
Me.btnSave.Name = "btnSave"
|
||||||
|
Me.btnSave.Size = New System.Drawing.Size(75, 23)
|
||||||
|
Me.btnSave.TabIndex = 5
|
||||||
|
Me.btnSave.Text = "&Save"
|
||||||
|
Me.btnSave.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'frmTags
|
||||||
|
'
|
||||||
|
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||||
|
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||||
|
Me.ClientSize = New System.Drawing.Size(584, 261)
|
||||||
|
Me.Controls.Add(Me.grpTag)
|
||||||
|
Me.Controls.Add(Me.btnClose)
|
||||||
|
Me.Controls.Add(Me.btnDelete)
|
||||||
|
Me.Controls.Add(Me.btnAdd)
|
||||||
|
Me.Controls.Add(Me.lstTags)
|
||||||
|
Me.Controls.Add(Me.txtID)
|
||||||
|
Me.Controls.Add(Me.btnCancel)
|
||||||
|
Me.Controls.Add(Me.btnSave)
|
||||||
|
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle
|
||||||
|
Me.MaximizeBox = False
|
||||||
|
Me.MinimizeBox = False
|
||||||
|
Me.Name = "frmTags"
|
||||||
|
Me.ShowIcon = False
|
||||||
|
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
|
||||||
|
Me.Text = "Tags"
|
||||||
|
Me.grpTag.ResumeLayout(False)
|
||||||
|
Me.grpTag.PerformLayout()
|
||||||
|
Me.ResumeLayout(False)
|
||||||
|
Me.PerformLayout()
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
Friend WithEvents grpTag As System.Windows.Forms.GroupBox
|
||||||
|
Friend WithEvents txtName As System.Windows.Forms.TextBox
|
||||||
|
Friend WithEvents lblName As System.Windows.Forms.Label
|
||||||
|
Friend WithEvents btnClose As System.Windows.Forms.Button
|
||||||
|
Friend WithEvents btnDelete As System.Windows.Forms.Button
|
||||||
|
Friend WithEvents btnAdd As System.Windows.Forms.Button
|
||||||
|
Friend WithEvents lstTags As System.Windows.Forms.ListBox
|
||||||
|
Friend WithEvents txtID As System.Windows.Forms.TextBox
|
||||||
|
Friend WithEvents btnCancel As System.Windows.Forms.Button
|
||||||
|
Friend WithEvents btnSave As System.Windows.Forms.Button
|
||||||
|
End Class
|
||||||
@@ -0,0 +1,120 @@
|
|||||||
|
<?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>
|
||||||
|
</root>
|
||||||
@@ -0,0 +1,307 @@
|
|||||||
|
Public Class frmTags
|
||||||
|
|
||||||
|
Dim hshTagData As Hashtable
|
||||||
|
Private bIsDirty As Boolean = False
|
||||||
|
Private bIsLoading As Boolean = False
|
||||||
|
Private oCurrentTag As clsTag
|
||||||
|
|
||||||
|
Private Property IsDirty As Boolean
|
||||||
|
Get
|
||||||
|
Return bIsDirty
|
||||||
|
End Get
|
||||||
|
Set(value As Boolean)
|
||||||
|
bIsDirty = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Private Property IsLoading As Boolean
|
||||||
|
Get
|
||||||
|
Return bIsLoading
|
||||||
|
End Get
|
||||||
|
Set(value As Boolean)
|
||||||
|
bIsLoading = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Private Enum eModes As Integer
|
||||||
|
View = 1
|
||||||
|
Edit = 2
|
||||||
|
Add = 3
|
||||||
|
Disabled = 4
|
||||||
|
End Enum
|
||||||
|
|
||||||
|
Private eCurrentMode As eModes = eModes.Disabled
|
||||||
|
|
||||||
|
Private Property TagData As Hashtable
|
||||||
|
Get
|
||||||
|
Return hshTagData
|
||||||
|
End Get
|
||||||
|
Set(value As Hashtable)
|
||||||
|
hshTagData = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Private Sub LoadData()
|
||||||
|
TagData = mgrTags.ReadTags
|
||||||
|
lstTags.Items.Clear()
|
||||||
|
FormatAndFillList()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
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")
|
||||||
|
|
||||||
|
Select Case oResult
|
||||||
|
Case MsgBoxResult.Yes
|
||||||
|
IsDirty = False
|
||||||
|
Case MsgBoxResult.No
|
||||||
|
IsDirty = False
|
||||||
|
Case MsgBoxResult.Cancel
|
||||||
|
'No Change
|
||||||
|
End Select
|
||||||
|
|
||||||
|
Return oResult
|
||||||
|
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Sub FormatAndFillList()
|
||||||
|
IsLoading = True
|
||||||
|
|
||||||
|
For Each oTag As clsTag In TagData.Values
|
||||||
|
lstTags.Items.Add(oTag.Name)
|
||||||
|
Next
|
||||||
|
|
||||||
|
IsLoading = False
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub FillData()
|
||||||
|
IsLoading = True
|
||||||
|
|
||||||
|
oCurrentTag = DirectCast(TagData(lstTags.SelectedItems(0).ToString), clsTag)
|
||||||
|
|
||||||
|
txtID.Text = oCurrentTag.ID
|
||||||
|
txtName.Text = oCurrentTag.Name
|
||||||
|
|
||||||
|
IsLoading = False
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub DirtyCheck_ValueChanged(sender As Object, e As EventArgs)
|
||||||
|
If Not IsLoading Then
|
||||||
|
IsDirty = True
|
||||||
|
If Not eCurrentMode = eModes.Add Then EditTag()
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub AssignDirtyHandlers(ByVal oCtls As GroupBox.ControlCollection)
|
||||||
|
For Each ctl As Control In oCtls
|
||||||
|
If TypeOf ctl Is TextBox Then
|
||||||
|
AddHandler DirectCast(ctl, TextBox).TextChanged, AddressOf DirtyCheck_ValueChanged
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub WipeControls(ByVal oCtls As GroupBox.ControlCollection)
|
||||||
|
For Each ctl As Control In oCtls
|
||||||
|
If TypeOf ctl Is TextBox Then
|
||||||
|
DirectCast(ctl, TextBox).Text = String.Empty
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
txtID.Text = String.Empty
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub ModeChange()
|
||||||
|
IsLoading = True
|
||||||
|
|
||||||
|
Select Case eCurrentMode
|
||||||
|
Case eModes.Add
|
||||||
|
grpTag.Enabled = True
|
||||||
|
WipeControls(grpTag.Controls)
|
||||||
|
btnSave.Enabled = True
|
||||||
|
btnCancel.Enabled = True
|
||||||
|
btnAdd.Enabled = False
|
||||||
|
btnDelete.Enabled = False
|
||||||
|
lstTags.Enabled = False
|
||||||
|
Case eModes.Edit
|
||||||
|
lstTags.Enabled = False
|
||||||
|
grpTag.Enabled = True
|
||||||
|
btnSave.Enabled = True
|
||||||
|
btnCancel.Enabled = True
|
||||||
|
btnAdd.Enabled = False
|
||||||
|
btnDelete.Enabled = False
|
||||||
|
Case eModes.View
|
||||||
|
lstTags.Enabled = True
|
||||||
|
grpTag.Enabled = True
|
||||||
|
btnSave.Enabled = False
|
||||||
|
btnCancel.Enabled = False
|
||||||
|
btnAdd.Enabled = True
|
||||||
|
btnDelete.Enabled = True
|
||||||
|
Case eModes.Disabled
|
||||||
|
lstTags.Enabled = True
|
||||||
|
WipeControls(grpTag.Controls)
|
||||||
|
grpTag.Enabled = False
|
||||||
|
btnSave.Enabled = False
|
||||||
|
btnCancel.Enabled = False
|
||||||
|
btnAdd.Enabled = True
|
||||||
|
btnDelete.Enabled = True
|
||||||
|
End Select
|
||||||
|
|
||||||
|
IsLoading = False
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub EditTag()
|
||||||
|
eCurrentMode = eModes.Edit
|
||||||
|
ModeChange()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub AddTag()
|
||||||
|
eCurrentMode = eModes.Add
|
||||||
|
ModeChange()
|
||||||
|
txtName.Focus()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub CancelEdit()
|
||||||
|
If bIsDirty Then
|
||||||
|
Select Case HandleDirty()
|
||||||
|
Case MsgBoxResult.Yes
|
||||||
|
SaveTag()
|
||||||
|
Case MsgBoxResult.No
|
||||||
|
If lstTags.SelectedItems.Count > 0 Then
|
||||||
|
eCurrentMode = eModes.View
|
||||||
|
ModeChange()
|
||||||
|
FillData()
|
||||||
|
lstTags.Focus()
|
||||||
|
Else
|
||||||
|
eCurrentMode = eModes.Disabled
|
||||||
|
ModeChange()
|
||||||
|
End If
|
||||||
|
Case MsgBoxResult.Cancel
|
||||||
|
'Do Nothing
|
||||||
|
End Select
|
||||||
|
Else
|
||||||
|
If lstTags.SelectedItems.Count > 0 Then
|
||||||
|
eCurrentMode = eModes.View
|
||||||
|
ModeChange()
|
||||||
|
FillData()
|
||||||
|
lstTags.Focus()
|
||||||
|
Else
|
||||||
|
eCurrentMode = eModes.Disabled
|
||||||
|
ModeChange()
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub SaveTag()
|
||||||
|
Dim oTag As New clsTag
|
||||||
|
Dim bSuccess As Boolean = False
|
||||||
|
|
||||||
|
If txtID.Text <> String.Empty Then
|
||||||
|
oTag.ID = txtID.Text
|
||||||
|
End If
|
||||||
|
oTag.Name = txtName.Text
|
||||||
|
|
||||||
|
Select Case eCurrentMode
|
||||||
|
Case eModes.Add
|
||||||
|
If CoreValidatation(oTag) Then
|
||||||
|
bSuccess = True
|
||||||
|
mgrTags.DoTagAdd(oTag)
|
||||||
|
eCurrentMode = eModes.View
|
||||||
|
End If
|
||||||
|
Case eModes.Edit
|
||||||
|
If CoreValidatation(oTag) Then
|
||||||
|
bSuccess = True
|
||||||
|
mgrTags.DoTagUpdate(oTag)
|
||||||
|
eCurrentMode = eModes.View
|
||||||
|
End If
|
||||||
|
End Select
|
||||||
|
|
||||||
|
If bSuccess Then
|
||||||
|
IsDirty = False
|
||||||
|
LoadData()
|
||||||
|
ModeChange()
|
||||||
|
If eCurrentMode = eModes.View Then lstTags.SelectedIndex = lstTags.Items.IndexOf(oTag.Name)
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub DeleteTag()
|
||||||
|
Dim oTag As clsTag
|
||||||
|
|
||||||
|
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
|
||||||
|
mgrTags.DoTagDelete(oTag.ID)
|
||||||
|
LoadData()
|
||||||
|
eCurrentMode = eModes.Disabled
|
||||||
|
ModeChange()
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub SwitchTag()
|
||||||
|
If lstTags.SelectedItems.Count > 0 Then
|
||||||
|
eCurrentMode = eModes.View
|
||||||
|
FillData()
|
||||||
|
ModeChange()
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
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")
|
||||||
|
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")
|
||||||
|
txtName.Focus()
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return True
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Sub frmTags_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||||
|
LoadData()
|
||||||
|
ModeChange()
|
||||||
|
AssignDirtyHandlers(grpTag.Controls)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub lstTags_SelectedIndexChanged(sender As Object, e As EventArgs) Handles lstTags.SelectedIndexChanged
|
||||||
|
SwitchTag()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnAdd_Click(sender As Object, e As EventArgs) Handles btnAdd.Click
|
||||||
|
AddTag()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnDelete_Click(sender As Object, e As EventArgs) Handles btnDelete.Click
|
||||||
|
DeleteTag()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnSave_Click(sender As Object, e As EventArgs) Handles btnSave.Click
|
||||||
|
SaveTag()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnCancel_Click(sender As Object, e As EventArgs) Handles btnCancel.Click
|
||||||
|
CancelEdit()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub btnClose_Click(sender As Object, e As EventArgs) Handles btnClose.Click
|
||||||
|
Me.Close()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub frmTags_FormClosing(sender As Object, e As FormClosingEventArgs) Handles MyBase.FormClosing
|
||||||
|
If bIsDirty Then
|
||||||
|
Select Case HandleDirty()
|
||||||
|
Case MsgBoxResult.Yes
|
||||||
|
SaveTag()
|
||||||
|
Case MsgBoxResult.No
|
||||||
|
'Do Nothing
|
||||||
|
Case MsgBoxResult.Cancel
|
||||||
|
e.Cancel = True
|
||||||
|
End Select
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
End Class
|
||||||
Generated
+6
-6
@@ -51,7 +51,7 @@ Partial Class frmVariableManager
|
|||||||
'
|
'
|
||||||
Me.btnDelete.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
|
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.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, 227)
|
Me.btnDelete.Location = New System.Drawing.Point(48, 226)
|
||||||
Me.btnDelete.Name = "btnDelete"
|
Me.btnDelete.Name = "btnDelete"
|
||||||
Me.btnDelete.Size = New System.Drawing.Size(30, 23)
|
Me.btnDelete.Size = New System.Drawing.Size(30, 23)
|
||||||
Me.btnDelete.TabIndex = 2
|
Me.btnDelete.TabIndex = 2
|
||||||
@@ -62,7 +62,7 @@ Partial Class frmVariableManager
|
|||||||
'
|
'
|
||||||
Me.btnAdd.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
|
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.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, 227)
|
Me.btnAdd.Location = New System.Drawing.Point(12, 226)
|
||||||
Me.btnAdd.Name = "btnAdd"
|
Me.btnAdd.Name = "btnAdd"
|
||||||
Me.btnAdd.Size = New System.Drawing.Size(30, 23)
|
Me.btnAdd.Size = New System.Drawing.Size(30, 23)
|
||||||
Me.btnAdd.TabIndex = 1
|
Me.btnAdd.TabIndex = 1
|
||||||
@@ -72,7 +72,7 @@ Partial Class frmVariableManager
|
|||||||
'btnClose
|
'btnClose
|
||||||
'
|
'
|
||||||
Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
||||||
Me.btnClose.Location = New System.Drawing.Point(497, 227)
|
Me.btnClose.Location = New System.Drawing.Point(497, 226)
|
||||||
Me.btnClose.Name = "btnClose"
|
Me.btnClose.Name = "btnClose"
|
||||||
Me.btnClose.Size = New System.Drawing.Size(75, 23)
|
Me.btnClose.Size = New System.Drawing.Size(75, 23)
|
||||||
Me.btnClose.TabIndex = 6
|
Me.btnClose.TabIndex = 6
|
||||||
@@ -137,7 +137,7 @@ Partial Class frmVariableManager
|
|||||||
'btnCancel
|
'btnCancel
|
||||||
'
|
'
|
||||||
Me.btnCancel.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
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(497, 95)
|
Me.btnCancel.Location = New System.Drawing.Point(497, 94)
|
||||||
Me.btnCancel.Name = "btnCancel"
|
Me.btnCancel.Name = "btnCancel"
|
||||||
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
|
Me.btnCancel.Size = New System.Drawing.Size(75, 23)
|
||||||
Me.btnCancel.TabIndex = 5
|
Me.btnCancel.TabIndex = 5
|
||||||
@@ -147,7 +147,7 @@ Partial Class frmVariableManager
|
|||||||
'btnSave
|
'btnSave
|
||||||
'
|
'
|
||||||
Me.btnSave.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
|
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(416, 95)
|
Me.btnSave.Location = New System.Drawing.Point(416, 94)
|
||||||
Me.btnSave.Name = "btnSave"
|
Me.btnSave.Name = "btnSave"
|
||||||
Me.btnSave.Size = New System.Drawing.Size(75, 23)
|
Me.btnSave.Size = New System.Drawing.Size(75, 23)
|
||||||
Me.btnSave.TabIndex = 4
|
Me.btnSave.TabIndex = 4
|
||||||
@@ -168,7 +168,7 @@ Partial Class frmVariableManager
|
|||||||
'
|
'
|
||||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||||
Me.ClientSize = New System.Drawing.Size(584, 262)
|
Me.ClientSize = New System.Drawing.Size(584, 261)
|
||||||
Me.Controls.Add(Me.txtID)
|
Me.Controls.Add(Me.txtID)
|
||||||
Me.Controls.Add(Me.btnCancel)
|
Me.Controls.Add(Me.btnCancel)
|
||||||
Me.Controls.Add(Me.btnSave)
|
Me.Controls.Add(Me.btnSave)
|
||||||
|
|||||||
@@ -113,15 +113,25 @@
|
|||||||
<Import Include="System.Windows.Forms" />
|
<Import Include="System.Windows.Forms" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<Compile Include="Classes\XML Serialize Classes\Tag.vb" />
|
||||||
|
<Compile Include="Classes\XML Serialize Classes\Game.vb" />
|
||||||
|
<Compile Include="Classes\clsGameTag.vb" />
|
||||||
<Compile Include="Classes\clsPathVariable.vb" />
|
<Compile Include="Classes\clsPathVariable.vb" />
|
||||||
<Compile Include="Classes\clsBackup.vb" />
|
<Compile Include="Classes\clsBackup.vb" />
|
||||||
<Compile Include="Classes\clsGame.vb" />
|
<Compile Include="Classes\clsGame.vb" />
|
||||||
|
<Compile Include="Classes\clsTag.vb" />
|
||||||
<Compile Include="Forms\frmAdvancedImport.Designer.vb">
|
<Compile Include="Forms\frmAdvancedImport.Designer.vb">
|
||||||
<DependentUpon>frmAdvancedImport.vb</DependentUpon>
|
<DependentUpon>frmAdvancedImport.vb</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="Forms\frmAdvancedImport.vb">
|
<Compile Include="Forms\frmAdvancedImport.vb">
|
||||||
<SubType>Form</SubType>
|
<SubType>Form</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="Forms\frmFilter.Designer.vb">
|
||||||
|
<DependentUpon>frmFilter.vb</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Forms\frmFilter.vb">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
<Compile Include="Forms\frmGameManager.Designer.vb">
|
<Compile Include="Forms\frmGameManager.Designer.vb">
|
||||||
<DependentUpon>frmGameManager.vb</DependentUpon>
|
<DependentUpon>frmGameManager.vb</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -134,6 +144,12 @@
|
|||||||
<Compile Include="Forms\frmFileFolderSearch.vb">
|
<Compile Include="Forms\frmFileFolderSearch.vb">
|
||||||
<SubType>Form</SubType>
|
<SubType>Form</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="Forms\frmGameTags.Designer.vb">
|
||||||
|
<DependentUpon>frmGameTags.vb</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Forms\frmGameTags.vb">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
<Compile Include="Forms\frmStartUpWizard.Designer.vb">
|
<Compile Include="Forms\frmStartUpWizard.Designer.vb">
|
||||||
<DependentUpon>frmStartUpWizard.vb</DependentUpon>
|
<DependentUpon>frmStartUpWizard.vb</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -165,6 +181,12 @@
|
|||||||
<DependentUpon>frmMain.vb</DependentUpon>
|
<DependentUpon>frmMain.vb</DependentUpon>
|
||||||
<SubType>Form</SubType>
|
<SubType>Form</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="Forms\frmTags.Designer.vb">
|
||||||
|
<DependentUpon>frmTags.vb</DependentUpon>
|
||||||
|
</Compile>
|
||||||
|
<Compile Include="Forms\frmTags.vb">
|
||||||
|
<SubType>Form</SubType>
|
||||||
|
</Compile>
|
||||||
<Compile Include="Forms\frmVariableManager.Designer.vb">
|
<Compile Include="Forms\frmVariableManager.Designer.vb">
|
||||||
<DependentUpon>frmVariableManager.vb</DependentUpon>
|
<DependentUpon>frmVariableManager.vb</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -172,6 +194,7 @@
|
|||||||
<SubType>Form</SubType>
|
<SubType>Form</SubType>
|
||||||
</Compile>
|
</Compile>
|
||||||
<Compile Include="Managers\mgrCommon.vb" />
|
<Compile Include="Managers\mgrCommon.vb" />
|
||||||
|
<Compile Include="Managers\mgrGameTags.vb" />
|
||||||
<Compile Include="Managers\mgrHash.vb" />
|
<Compile Include="Managers\mgrHash.vb" />
|
||||||
<Compile Include="Managers\mgrManifest.vb" />
|
<Compile Include="Managers\mgrManifest.vb" />
|
||||||
<Compile Include="Managers\mgrMonitorList.vb" />
|
<Compile Include="Managers\mgrMonitorList.vb" />
|
||||||
@@ -180,6 +203,7 @@
|
|||||||
<Compile Include="Managers\mgrSettings.vb" />
|
<Compile Include="Managers\mgrSettings.vb" />
|
||||||
<Compile Include="Managers\mgrBackup.vb" />
|
<Compile Include="Managers\mgrBackup.vb" />
|
||||||
<Compile Include="Managers\mgrSQLite.vb" />
|
<Compile Include="Managers\mgrSQLite.vb" />
|
||||||
|
<Compile Include="Managers\mgrTags.vb" />
|
||||||
<Compile Include="Managers\mgrVariables.vb" />
|
<Compile Include="Managers\mgrVariables.vb" />
|
||||||
<Compile Include="Managers\mgrXML.vb" />
|
<Compile Include="Managers\mgrXML.vb" />
|
||||||
<Compile Include="Managers\mgrProcesses.vb" />
|
<Compile Include="Managers\mgrProcesses.vb" />
|
||||||
@@ -203,12 +227,18 @@
|
|||||||
<EmbeddedResource Include="Forms\frmAdvancedImport.resx">
|
<EmbeddedResource Include="Forms\frmAdvancedImport.resx">
|
||||||
<DependentUpon>frmAdvancedImport.vb</DependentUpon>
|
<DependentUpon>frmAdvancedImport.vb</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="Forms\frmFilter.resx">
|
||||||
|
<DependentUpon>frmFilter.vb</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="Forms\frmGameManager.resx">
|
<EmbeddedResource Include="Forms\frmGameManager.resx">
|
||||||
<DependentUpon>frmGameManager.vb</DependentUpon>
|
<DependentUpon>frmGameManager.vb</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="Forms\frmFileFolderSearch.resx">
|
<EmbeddedResource Include="Forms\frmFileFolderSearch.resx">
|
||||||
<DependentUpon>frmFileFolderSearch.vb</DependentUpon>
|
<DependentUpon>frmFileFolderSearch.vb</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="Forms\frmGameTags.resx">
|
||||||
|
<DependentUpon>frmGameTags.vb</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="Forms\frmStartUpWizard.resx">
|
<EmbeddedResource Include="Forms\frmStartUpWizard.resx">
|
||||||
<DependentUpon>frmStartUpWizard.vb</DependentUpon>
|
<DependentUpon>frmStartUpWizard.vb</DependentUpon>
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
@@ -226,6 +256,9 @@
|
|||||||
<DependentUpon>frmMain.vb</DependentUpon>
|
<DependentUpon>frmMain.vb</DependentUpon>
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
|
<EmbeddedResource Include="Forms\frmTags.resx">
|
||||||
|
<DependentUpon>frmTags.vb</DependentUpon>
|
||||||
|
</EmbeddedResource>
|
||||||
<EmbeddedResource Include="Forms\frmVariableManager.resx">
|
<EmbeddedResource Include="Forms\frmVariableManager.resx">
|
||||||
<DependentUpon>frmVariableManager.vb</DependentUpon>
|
<DependentUpon>frmVariableManager.vb</DependentUpon>
|
||||||
</EmbeddedResource>
|
</EmbeddedResource>
|
||||||
|
|||||||
@@ -173,11 +173,11 @@ Public Class mgrBackup
|
|||||||
prs7z.StartInfo.RedirectStandardOutput = True
|
prs7z.StartInfo.RedirectStandardOutput = True
|
||||||
prs7z.StartInfo.CreateNoWindow = True
|
prs7z.StartInfo.CreateNoWindow = True
|
||||||
prs7z.Start()
|
prs7z.Start()
|
||||||
RaiseEvent UpdateLog("Backup of " & sSavePath & " in progress...", True, ToolTipIcon.Info, True)
|
RaiseEvent UpdateLog("Backup of " & sSavePath & " in progress...", False, ToolTipIcon.Info, True)
|
||||||
While Not prs7z.StandardOutput.EndOfStream
|
While Not prs7z.StandardOutput.EndOfStream
|
||||||
If CancelOperation Then
|
If CancelOperation Then
|
||||||
prs7z.Kill()
|
prs7z.Kill()
|
||||||
RaiseEvent UpdateLog("Backup Aborted by user. The backup file for " & oGame.Name & " will be unusable.", False, ToolTipIcon.Error, True)
|
RaiseEvent UpdateLog("Backup Aborted. The backup file for " & oGame.Name & " will be unusable.", True, ToolTipIcon.Error, True)
|
||||||
Exit While
|
Exit While
|
||||||
End If
|
End If
|
||||||
RaiseEvent UpdateLog(prs7z.StandardOutput.ReadLine, False, ToolTipIcon.Info, False)
|
RaiseEvent UpdateLog(prs7z.StandardOutput.ReadLine, False, ToolTipIcon.Info, False)
|
||||||
@@ -188,13 +188,13 @@ Public Class mgrBackup
|
|||||||
RaiseEvent UpdateLog(oGame.Name & " backup completed.", False, ToolTipIcon.Info, True)
|
RaiseEvent UpdateLog(oGame.Name & " backup completed.", False, ToolTipIcon.Info, True)
|
||||||
bBackupCompleted = True
|
bBackupCompleted = True
|
||||||
Else
|
Else
|
||||||
RaiseEvent UpdateLog(oGame.Name & " backup operation finished with warnings or errors.", False, ToolTipIcon.Error, True)
|
RaiseEvent UpdateLog(oGame.Name & " backup finished with warnings or errors.", True, ToolTipIcon.Warning, True)
|
||||||
bBackupCompleted = False
|
bBackupCompleted = False
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
prs7z.Dispose()
|
prs7z.Dispose()
|
||||||
Else
|
Else
|
||||||
RaiseEvent UpdateLog("Backup Aborted. The path " & sSavePath & " for " & oGame.Name & " does not exist.", False, ToolTipIcon.Error, True)
|
RaiseEvent UpdateLog("Backup Aborted. The saved game path for " & oGame.Name & " does not exist.", True, ToolTipIcon.Error, True)
|
||||||
bBackupCompleted = False
|
bBackupCompleted = False
|
||||||
End If
|
End If
|
||||||
|
|
||||||
@@ -206,7 +206,7 @@ Public Class mgrBackup
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
If Not DoManifestUpdate(oGame, sBackupFile, dTimeStamp, sHash) Then
|
If Not DoManifestUpdate(oGame, sBackupFile, dTimeStamp, sHash) Then
|
||||||
RaiseEvent UpdateLog("The manifest update for " & oGame.Name & " failed.", False, ToolTipIcon.Error, True)
|
RaiseEvent UpdateLog("The manifest update for " & oGame.Name & " failed.", True, ToolTipIcon.Error, True)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
'Write the process path if we have it
|
'Write the process path if we have it
|
||||||
@@ -215,7 +215,7 @@ Public Class mgrBackup
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
RaiseEvent UpdateLog("An unexpected error occured during the backup process of " & oGame.Name & vbCrLf & ex.Message, False, ToolTipIcon.Error, True)
|
RaiseEvent UpdateLog("An unexpected error occured during the backup of " & oGame.Name & vbCrLf & ex.Message, False, ToolTipIcon.Error, True)
|
||||||
End Try
|
End Try
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,284 @@
|
|||||||
|
Public Class mgrGameTags
|
||||||
|
|
||||||
|
Public Shared Sub DoGameTagAdd(ByVal oGameTag As clsGameTag, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
|
||||||
|
sSQL = "INSERT INTO gametags VALUES (@TagID, @MonitorID)"
|
||||||
|
hshParams.Add("TagID", oGameTag.TagID)
|
||||||
|
hshParams.Add("MonitorID", oGameTag.MonitorID)
|
||||||
|
oDatabase.RunParamQuery(sSQL, hshParams)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Sub DoGameTagAddBatch(ByVal oGameTags As List(Of clsGameTag))
|
||||||
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As Hashtable
|
||||||
|
Dim oParamList As New List(Of Hashtable)
|
||||||
|
|
||||||
|
sSQL = "INSERT INTO gametags VALUES (@TagID, @MonitorID);"
|
||||||
|
|
||||||
|
For Each oGameTag As clsGameTag In oGameTags
|
||||||
|
hshParams = New Hashtable
|
||||||
|
hshParams.Add("TagID", oGameTag.TagID)
|
||||||
|
hshParams.Add("MonitorID", oGameTag.MonitorID)
|
||||||
|
oParamList.Add(hshParams)
|
||||||
|
Next
|
||||||
|
|
||||||
|
oDatabase.RunMassParamQuery(sSQL, oParamList)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Sub DoGameTagDelete(ByVal oGameTags As List(Of clsGameTag))
|
||||||
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As Hashtable
|
||||||
|
Dim oParamList As New List(Of Hashtable)
|
||||||
|
|
||||||
|
sSQL = "DELETE FROM gametags "
|
||||||
|
sSQL &= "WHERE TagID = @TagID AND MonitorID = @MonitorID;"
|
||||||
|
|
||||||
|
For Each oGameTag As clsGameTag In oGameTags
|
||||||
|
hshParams = New Hashtable
|
||||||
|
hshParams.Add("TagID", oGameTag.TagID)
|
||||||
|
hshParams.Add("MonitorID", oGameTag.MonitorID)
|
||||||
|
oParamList.Add(hshParams)
|
||||||
|
Next
|
||||||
|
|
||||||
|
oDatabase.RunMassParamQuery(sSQL, oParamList)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Sub DoGameTagDeleteByGame(ByVal sMonitorID As String)
|
||||||
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
|
||||||
|
sSQL = "DELETE FROM gametags "
|
||||||
|
sSQL &= "WHERE MonitorID = @ID;"
|
||||||
|
|
||||||
|
hshParams.Add("ID", sMonitorID)
|
||||||
|
|
||||||
|
oDatabase.RunParamQuery(sSQL, hshParams)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
|
Public Shared Sub DoGameTagDeleteByTag(ByVal sTagID As String)
|
||||||
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
|
||||||
|
sSQL = "DELETE FROM gametags "
|
||||||
|
sSQL &= "WHERE TagID = @ID;"
|
||||||
|
|
||||||
|
hshParams.Add("ID", sTagID)
|
||||||
|
|
||||||
|
oDatabase.RunParamQuery(sSQL, hshParams)
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Function GetTagsByGame(ByVal sMonitorID As String) As Hashtable
|
||||||
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
|
Dim oData As DataSet
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshList As New Hashtable
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
Dim oTag As clsTag
|
||||||
|
|
||||||
|
sSQL = "SELECT TagID, tags.Name FROM gametags NATURAL JOIN tags WHERE MonitorID = @ID"
|
||||||
|
|
||||||
|
hshParams.Add("ID", sMonitorID)
|
||||||
|
|
||||||
|
oData = oDatabase.ReadParamData(sSQL, hshParams)
|
||||||
|
|
||||||
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
|
oTag = New clsTag
|
||||||
|
oTag.ID = CStr(dr("TagID"))
|
||||||
|
oTag.Name = CStr(dr("Name"))
|
||||||
|
hshList.Add(oTag.Name, oTag)
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return hshList
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Shared Function GetTagsByGameForExport(ByVal sMonitorID As String) As List(Of Tag)
|
||||||
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
|
Dim oData As DataSet
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim oList As New List(Of Tag)
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
Dim oTag As Tag
|
||||||
|
|
||||||
|
sSQL = "SELECT TagID, tags.Name FROM gametags NATURAL JOIN tags WHERE MonitorID = @ID"
|
||||||
|
|
||||||
|
hshParams.Add("ID", sMonitorID)
|
||||||
|
|
||||||
|
oData = oDatabase.ReadParamData(sSQL, hshParams)
|
||||||
|
|
||||||
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
|
oTag = New Tag
|
||||||
|
oTag.Name = CStr(dr("Name"))
|
||||||
|
oList.Add(oTag)
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return oList
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Shared Function GetTagsByGameMulti(ByVal sMonitorIDs As List(Of String)) As Hashtable
|
||||||
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
|
Dim oData As DataSet
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshList As New Hashtable
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
Dim oTag As clsTag
|
||||||
|
Dim iCounter As Integer
|
||||||
|
|
||||||
|
sSQL = "SELECT DISTINCT TagID, tags.Name FROM gametags NATURAL JOIN tags WHERE MonitorID IN ("
|
||||||
|
|
||||||
|
For Each s As String In sMonitorIDs
|
||||||
|
sSQL &= "@MonitorID" & iCounter & ","
|
||||||
|
hshParams.Add("MonitorID" & iCounter, s)
|
||||||
|
iCounter += 1
|
||||||
|
Next
|
||||||
|
|
||||||
|
sSQL = sSQL.TrimEnd(",")
|
||||||
|
sSQL &= ")"
|
||||||
|
|
||||||
|
oData = oDatabase.ReadParamData(sSQL, hshParams)
|
||||||
|
|
||||||
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
|
oTag = New clsTag
|
||||||
|
oTag.ID = CStr(dr(0))
|
||||||
|
oTag.Name = CStr(dr(1))
|
||||||
|
hshList.Add(oTag.Name, oTag)
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return hshList
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Shared Function ReadGameTags(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
|
||||||
|
Dim sCompoundKey As String
|
||||||
|
Dim hshList As New Hashtable
|
||||||
|
Dim oGameTag As clsGameTag
|
||||||
|
|
||||||
|
sSQL = "SELECT * from gametags"
|
||||||
|
oData = oDatabase.ReadParamData(sSQL, New Hashtable)
|
||||||
|
|
||||||
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
|
oGameTag = New clsGameTag
|
||||||
|
oGameTag.TagID = CStr(dr("TagID"))
|
||||||
|
oGameTag.MonitorID = CStr(dr("MonitorID"))
|
||||||
|
sCompoundKey = oGameTag.TagID & ":" & oGameTag.MonitorID
|
||||||
|
hshList.Add(sCompoundKey, oGameTag)
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return hshList
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Shared Sub DoGameTagAddSync(ByVal hshTags As Hashtable, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As Hashtable
|
||||||
|
Dim oParamList As New List(Of Hashtable)
|
||||||
|
|
||||||
|
sSQL = "INSERT INTO gametags VALUES (@TagID, @MonitorID);"
|
||||||
|
|
||||||
|
For Each oGameTag As clsGameTag In hshTags.Values
|
||||||
|
hshParams = New Hashtable
|
||||||
|
hshParams.Add("TagID", oGameTag.TagID)
|
||||||
|
hshParams.Add("MonitorID", oGameTag.MonitorID)
|
||||||
|
oParamList.Add(hshParams)
|
||||||
|
Next
|
||||||
|
|
||||||
|
oDatabase.RunMassParamQuery(sSQL, oParamList)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Sub DoGameTagDeleteSync(ByVal hshTags As Hashtable, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As Hashtable
|
||||||
|
Dim oParamList As New List(Of Hashtable)
|
||||||
|
|
||||||
|
sSQL = "DELETE FROM gametags "
|
||||||
|
sSQL &= "WHERE TagID = @TagID AND MonitorID = @MonitorID;"
|
||||||
|
|
||||||
|
For Each oGameTag As clsGameTag In hshTags.Values
|
||||||
|
hshParams = New Hashtable
|
||||||
|
hshParams.Add("TagID", oGameTag.TagID)
|
||||||
|
hshParams.Add("MonitorID", oGameTag.MonitorID)
|
||||||
|
oParamList.Add(hshParams)
|
||||||
|
Next
|
||||||
|
|
||||||
|
oDatabase.RunMassParamQuery(sSQL, oParamList)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Function SyncGameTags(Optional ByVal bToRemote As Boolean = True) As Integer
|
||||||
|
Dim hshCompareFrom As Hashtable
|
||||||
|
Dim hshCompareTo As Hashtable
|
||||||
|
Dim hshSyncItems As Hashtable
|
||||||
|
Dim hshDeleteItems As Hashtable
|
||||||
|
Dim oFromItem As clsGameTag
|
||||||
|
Dim oToItem As clsGameTag
|
||||||
|
Dim sCompoundKey As String
|
||||||
|
|
||||||
|
'Add / Update Sync
|
||||||
|
If bToRemote Then
|
||||||
|
hshCompareFrom = ReadGameTags(mgrSQLite.Database.Local)
|
||||||
|
hshCompareTo = ReadGameTags(mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
hshCompareFrom = ReadGameTags(mgrSQLite.Database.Remote)
|
||||||
|
hshCompareTo = ReadGameTags(mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
hshSyncItems = hshCompareFrom.Clone
|
||||||
|
|
||||||
|
For Each oFromItem In hshCompareFrom.Values
|
||||||
|
sCompoundKey = oFromItem.TagID & ":" & oFromItem.MonitorID
|
||||||
|
If hshCompareTo.Contains(sCompoundKey) Then
|
||||||
|
oToItem = DirectCast(hshCompareTo(sCompoundKey), clsGameTag)
|
||||||
|
If oFromItem.CoreEquals(oToItem) Then
|
||||||
|
hshSyncItems.Remove(sCompoundKey)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
If bToRemote Then
|
||||||
|
DoGameTagAddSync(hshSyncItems, mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
DoGameTagAddSync(hshSyncItems, mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
'Delete Sync
|
||||||
|
If bToRemote Then
|
||||||
|
hshCompareFrom = ReadGameTags(mgrSQLite.Database.Local)
|
||||||
|
hshCompareTo = ReadGameTags(mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
hshCompareFrom = ReadGameTags(mgrSQLite.Database.Remote)
|
||||||
|
hshCompareTo = ReadGameTags(mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
hshDeleteItems = hshCompareTo.Clone
|
||||||
|
|
||||||
|
For Each oToItem In hshCompareTo.Values
|
||||||
|
sCompoundKey = oToItem.TagID & ":" & oToItem.MonitorID
|
||||||
|
If hshCompareFrom.Contains(sCompoundKey) Then
|
||||||
|
oFromItem = DirectCast(hshCompareFrom(sCompoundKey), clsGameTag)
|
||||||
|
If oToItem.CoreEquals(oFromItem) Then
|
||||||
|
hshDeleteItems.Remove(sCompoundKey)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
If bToRemote Then
|
||||||
|
DoGameTagDeleteSync(hshDeleteItems, mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
DoGameTagDeleteSync(hshDeleteItems, mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return hshDeleteItems.Count + hshSyncItems.Count
|
||||||
|
|
||||||
|
End Function
|
||||||
|
|
||||||
|
End Class
|
||||||
+16
-16
@@ -14,14 +14,14 @@ Public Class mgrManifest
|
|||||||
|
|
||||||
For Each dr As DataRow In oData.Tables(0).Rows
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
oBackupItem = New clsBackup
|
oBackupItem = New clsBackup
|
||||||
oBackupItem.ID = CStr(dr(0))
|
oBackupItem.ID = CStr(dr("ManifestID"))
|
||||||
oBackupItem.Name = CStr(dr(1))
|
oBackupItem.Name = CStr(dr("Name"))
|
||||||
oBackupItem.FileName = CStr(dr(2))
|
oBackupItem.FileName = CStr(dr("FileName"))
|
||||||
oBackupItem.RestorePath = CStr(dr(3))
|
oBackupItem.RestorePath = CStr(dr("RestorePath"))
|
||||||
oBackupItem.AbsolutePath = CBool(dr(4))
|
oBackupItem.AbsolutePath = CBool(dr("AbsolutePath"))
|
||||||
oBackupItem.DateUpdated = mgrCommon.UnixToDate(dr(5))
|
oBackupItem.DateUpdated = mgrCommon.UnixToDate(dr("DateUpdated"))
|
||||||
oBackupItem.UpdatedBy = CStr(dr(6))
|
oBackupItem.UpdatedBy = CStr(dr("UpdatedBy"))
|
||||||
If Not IsDBNull(dr(7)) Then oBackupItem.CheckSum = CStr(dr(7))
|
If Not IsDBNull(dr("CheckSum")) Then oBackupItem.CheckSum = CStr(dr("CheckSum"))
|
||||||
slList.Add(oBackupItem.Name, oBackupItem)
|
slList.Add(oBackupItem.Name, oBackupItem)
|
||||||
Next
|
Next
|
||||||
|
|
||||||
@@ -66,14 +66,14 @@ Public Class mgrManifest
|
|||||||
|
|
||||||
For Each dr As DataRow In oData.Tables(0).Rows
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
oBackupItem = New clsBackup
|
oBackupItem = New clsBackup
|
||||||
oBackupItem.ID = CStr(dr(0))
|
oBackupItem.ID = CStr(dr("ManifestID"))
|
||||||
oBackupItem.Name = CStr(dr(1))
|
oBackupItem.Name = CStr(dr("Name"))
|
||||||
oBackupItem.FileName = CStr(dr(2))
|
oBackupItem.FileName = CStr(dr("FileName"))
|
||||||
oBackupItem.RestorePath = CStr(dr(3))
|
oBackupItem.RestorePath = CStr(dr("RestorePath"))
|
||||||
oBackupItem.AbsolutePath = CBool(dr(4))
|
oBackupItem.AbsolutePath = CBool(dr("AbsolutePath"))
|
||||||
oBackupItem.DateUpdated = mgrCommon.UnixToDate(dr(5))
|
oBackupItem.DateUpdated = mgrCommon.UnixToDate(dr("DateUpdated"))
|
||||||
oBackupItem.UpdatedBy = CStr(dr(6))
|
oBackupItem.UpdatedBy = CStr(dr("UpdatedBy"))
|
||||||
If Not IsDBNull(dr(7)) Then oBackupItem.CheckSum = CStr(dr(7))
|
If Not IsDBNull(dr("CheckSum")) Then oBackupItem.CheckSum = CStr(dr("CheckSum"))
|
||||||
Next
|
Next
|
||||||
|
|
||||||
Return oBackupItem
|
Return oBackupItem
|
||||||
|
|||||||
+355
-205
@@ -5,7 +5,6 @@ Public Class mgrMonitorList
|
|||||||
Public Enum eListTypes As Integer
|
Public Enum eListTypes As Integer
|
||||||
FullList = 1
|
FullList = 1
|
||||||
ScanList = 2
|
ScanList = 2
|
||||||
ListByKey = 3
|
|
||||||
End Enum
|
End Enum
|
||||||
|
|
||||||
Public Shared Event UpdateLog(sLogUpdate As String, bTrayUpdate As Boolean, objIcon As System.Windows.Forms.ToolTipIcon, bTimeStamp As Boolean)
|
Public Shared Event UpdateLog(sLogUpdate As String, bTrayUpdate As Boolean, objIcon As System.Windows.Forms.ToolTipIcon, bTimeStamp As Boolean)
|
||||||
@@ -39,13 +38,164 @@ Public Class mgrMonitorList
|
|||||||
End If
|
End If
|
||||||
End Sub
|
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
|
||||||
|
|
||||||
|
frm.ShowDialog()
|
||||||
|
oList = ReadListForExport(frm.Filters, frm.FilterType)
|
||||||
|
|
||||||
|
bSuccess = mgrXML.SerializeAndExport(oList, sLocation)
|
||||||
|
|
||||||
|
If bSuccess Then
|
||||||
|
MsgBox("Export Complete. " & oList.Count & " item(s) have been exported.", MsgBoxStyle.Information, "Game Backup Monitor")
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Sub DoListAddUpdateSync(ByVal hshGames As Hashtable, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
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 &= "VALUES (@ID, @Name, @Process, @Path, @AbsolutePath, @FolderSave, @FileType, "
|
||||||
|
sSQL &= "@TimeStamp, @ExcludeList, @Hours, @Enabled, @MonitorOnly);"
|
||||||
|
|
||||||
|
For Each oGame As clsGame In hshGames.Values
|
||||||
|
hshParams = New Hashtable
|
||||||
|
|
||||||
|
'Parameters
|
||||||
|
hshParams.Add("ID", oGame.ID)
|
||||||
|
hshParams.Add("Name", oGame.Name)
|
||||||
|
hshParams.Add("Process", oGame.TrueProcess)
|
||||||
|
hshParams.Add("Path", oGame.TruePath)
|
||||||
|
hshParams.Add("AbsolutePath", oGame.AbsolutePath)
|
||||||
|
hshParams.Add("FolderSave", oGame.FolderSave)
|
||||||
|
hshParams.Add("FileType", oGame.FileType)
|
||||||
|
hshParams.Add("TimeStamp", oGame.AppendTimeStamp)
|
||||||
|
hshParams.Add("ExcludeList", oGame.ExcludeList)
|
||||||
|
hshParams.Add("Hours", oGame.Hours)
|
||||||
|
|
||||||
|
'Required Defaults
|
||||||
|
hshParams.Add("Enabled", True)
|
||||||
|
hshParams.Add("MonitorOnly", False)
|
||||||
|
|
||||||
|
oParamList.Add(hshParams)
|
||||||
|
Next
|
||||||
|
|
||||||
|
oDatabase.RunMassParamQuery(sSQL, oParamList)
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Sub DoListDeleteSync(ByVal hshGames As Hashtable, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As Hashtable
|
||||||
|
Dim oParamList As New List(Of Hashtable)
|
||||||
|
|
||||||
|
sSQL = "DELETE FROM gametags "
|
||||||
|
sSQL &= "WHERE MonitorID = @MonitorID;"
|
||||||
|
sSQL &= "DELETE FROM monitorlist "
|
||||||
|
sSQL &= "WHERE Name = @Name AND Process= @Process;"
|
||||||
|
|
||||||
|
For Each oGame As clsGame In hshGames.Values
|
||||||
|
hshParams = New Hashtable
|
||||||
|
hshParams.Add("MonitorID", oGame.ID)
|
||||||
|
hshParams.Add("Name", oGame.Name)
|
||||||
|
hshParams.Add("Process", oGame.TrueProcess)
|
||||||
|
oParamList.Add(hshParams)
|
||||||
|
Next
|
||||||
|
|
||||||
|
oDatabase.RunMassParamQuery(sSQL, oParamList)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Sub SyncMonitorLists(Optional ByVal bToRemote As Boolean = True)
|
||||||
|
Dim hshCompareFrom As Hashtable
|
||||||
|
Dim hshCompareTo As Hashtable
|
||||||
|
Dim hshSyncItems As Hashtable
|
||||||
|
Dim hshDeleteItems As Hashtable
|
||||||
|
Dim oFromItem As clsGame
|
||||||
|
Dim oToItem As clsGame
|
||||||
|
Dim iChanges As Integer
|
||||||
|
|
||||||
|
Cursor.Current = Cursors.WaitCursor
|
||||||
|
|
||||||
|
If bToRemote Then
|
||||||
|
RaiseEvent UpdateLog("A sync to the master game list has been triggered.", False, ToolTipIcon.Info, True)
|
||||||
|
Else
|
||||||
|
RaiseEvent UpdateLog("A sync from the master game list has been triggered.", False, ToolTipIcon.Info, True)
|
||||||
|
End If
|
||||||
|
|
||||||
|
'Add / Update Sync
|
||||||
|
If bToRemote Then
|
||||||
|
hshCompareFrom = ReadList(eListTypes.FullList, mgrSQLite.Database.Local)
|
||||||
|
hshCompareTo = ReadList(eListTypes.FullList, mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
hshCompareFrom = ReadList(eListTypes.FullList, mgrSQLite.Database.Remote)
|
||||||
|
hshCompareTo = ReadList(eListTypes.FullList, mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
hshSyncItems = hshCompareFrom.Clone
|
||||||
|
|
||||||
|
For Each oFromItem In hshCompareFrom.Values
|
||||||
|
If hshCompareTo.Contains(oFromItem.ProcessName) Then
|
||||||
|
oToItem = DirectCast(hshCompareTo(oFromItem.ProcessName), clsGame)
|
||||||
|
If oFromItem.SyncEquals(oToItem) Then
|
||||||
|
hshSyncItems.Remove(oFromItem.ProcessName)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
If bToRemote Then
|
||||||
|
DoListAddUpdateSync(hshSyncItems, mgrSQLite.Database.Remote)
|
||||||
|
|
||||||
|
Else
|
||||||
|
DoListAddUpdateSync(hshSyncItems, mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
'Sync Tags
|
||||||
|
iChanges = mgrTags.SyncTags(bToRemote)
|
||||||
|
iChanges += mgrGameTags.SyncGameTags(bToRemote)
|
||||||
|
|
||||||
|
'Delete Sync
|
||||||
|
If bToRemote Then
|
||||||
|
hshCompareFrom = ReadList(eListTypes.FullList, mgrSQLite.Database.Local)
|
||||||
|
hshCompareTo = ReadList(eListTypes.FullList, mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
hshCompareFrom = ReadList(eListTypes.FullList, mgrSQLite.Database.Remote)
|
||||||
|
hshCompareTo = ReadList(eListTypes.FullList, mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
hshDeleteItems = hshCompareTo.Clone
|
||||||
|
|
||||||
|
For Each oToItem In hshCompareTo.Values
|
||||||
|
If hshCompareFrom.Contains(oToItem.ProcessName) Then
|
||||||
|
oFromItem = DirectCast(hshCompareFrom(oToItem.ProcessName), clsGame)
|
||||||
|
If oToItem.MinimalEquals(oFromItem) Then
|
||||||
|
hshDeleteItems.Remove(oToItem.ProcessName)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
If bToRemote Then
|
||||||
|
DoListDeleteSync(hshDeleteItems, mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
DoListDeleteSync(hshDeleteItems, mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
RaiseEvent UpdateLog(hshDeleteItems.Count + hshSyncItems.Count + iChanges & " change(s) synced.", False, ToolTipIcon.Info, True)
|
||||||
|
Cursor.Current = Cursors.Default
|
||||||
|
Application.DoEvents()
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Shared Sub ImportMonitorList(ByVal sLocation As String, Optional ByVal bWebRead As Boolean = False)
|
Private Shared Sub ImportMonitorList(ByVal sLocation As String, Optional ByVal bWebRead As Boolean = False)
|
||||||
Dim hshCompareFrom As Hashtable
|
Dim hshCompareFrom As Hashtable
|
||||||
Dim hshCompareTo As Hashtable
|
Dim hshCompareTo As Hashtable
|
||||||
Dim hshSyncItems As Hashtable
|
Dim hshSyncItems As Hashtable
|
||||||
Dim oFromItem As clsGame
|
Dim oFromItem As clsGame
|
||||||
Dim oToItem As clsGame
|
Dim oToItem As clsGame
|
||||||
Dim iItems As Integer = 0
|
|
||||||
|
|
||||||
Cursor.Current = Cursors.WaitCursor
|
Cursor.Current = Cursors.WaitCursor
|
||||||
|
|
||||||
@@ -71,14 +221,12 @@ Public Class mgrMonitorList
|
|||||||
frm.ImportData = hshSyncItems
|
frm.ImportData = hshSyncItems
|
||||||
If frm.ShowDialog() = DialogResult.OK Then
|
If frm.ShowDialog() = DialogResult.OK Then
|
||||||
Cursor.Current = Cursors.WaitCursor
|
Cursor.Current = Cursors.WaitCursor
|
||||||
For Each oGame As clsGame In frm.ImportData.Values
|
|
||||||
If Not DoDuplicateListCheck(oGame.Name, oGame.TrueProcess) Then
|
DoListAddUpdateSync(frm.ImportData)
|
||||||
DoListAdd(oGame, mgrSQLite.Database.Local)
|
mgrTags.DoTagAddImport(frm.ImportData)
|
||||||
iItems += 1
|
|
||||||
End If
|
|
||||||
Next
|
|
||||||
Cursor.Current = Cursors.Default
|
Cursor.Current = Cursors.Default
|
||||||
MsgBox("Import Complete. " & iItems & " entries have been imported.", MsgBoxStyle.Information, "Game Backup Monitor")
|
MsgBox("Import Complete.", MsgBoxStyle.Information, "Game Backup Monitor")
|
||||||
End If
|
End If
|
||||||
Else
|
Else
|
||||||
MsgBox("This list does not contain any new games to import.", MsgBoxStyle.Information, "Game Backup Monitor")
|
MsgBox("This list does not contain any new games to import.", MsgBoxStyle.Information, "Game Backup Monitor")
|
||||||
@@ -87,107 +235,6 @@ Public Class mgrMonitorList
|
|||||||
Application.DoEvents()
|
Application.DoEvents()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Shared Sub ExportMonitorList(ByVal sLocation As String)
|
|
||||||
Dim hshList As Hashtable = ReadList(eListTypes.FullList, mgrSQLite.Database.Local)
|
|
||||||
Dim bSuccess As Boolean
|
|
||||||
bSuccess = mgrXML.ExportMonitorList(hshList, sLocation)
|
|
||||||
|
|
||||||
If bSuccess Then
|
|
||||||
MsgBox("Export Complete. " & hshList.Count & " entries have been exported.", MsgBoxStyle.Information, "Game Backup Monitor")
|
|
||||||
End If
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Public Shared Sub SyncMonitorLists(Optional ByVal bToRemote As Boolean = True)
|
|
||||||
Dim hshCompareFrom As Hashtable
|
|
||||||
Dim hshCompareTo As Hashtable
|
|
||||||
Dim hshSyncItems As Hashtable
|
|
||||||
Dim hshDeleteItems As Hashtable
|
|
||||||
Dim oFromItem As clsGame
|
|
||||||
Dim oToItem As clsGame
|
|
||||||
|
|
||||||
Cursor.Current = Cursors.WaitCursor
|
|
||||||
|
|
||||||
If bToRemote Then
|
|
||||||
RaiseEvent UpdateLog("A sync to the master game list has been triggered.", False, ToolTipIcon.Info, True)
|
|
||||||
Else
|
|
||||||
RaiseEvent UpdateLog("A sync from the master game list has been triggered.", False, ToolTipIcon.Info, True)
|
|
||||||
End If
|
|
||||||
|
|
||||||
'Delete Sync
|
|
||||||
If bToRemote Then
|
|
||||||
hshCompareFrom = ReadList(eListTypes.FullList, mgrSQLite.Database.Local)
|
|
||||||
hshCompareTo = ReadList(eListTypes.FullList, mgrSQLite.Database.Remote)
|
|
||||||
Else
|
|
||||||
hshCompareFrom = ReadList(eListTypes.FullList, mgrSQLite.Database.Remote)
|
|
||||||
hshCompareTo = ReadList(eListTypes.FullList, mgrSQLite.Database.Local)
|
|
||||||
End If
|
|
||||||
|
|
||||||
hshDeleteItems = hshCompareTo.Clone
|
|
||||||
|
|
||||||
For Each oToItem In hshCompareTo.Values
|
|
||||||
If hshCompareFrom.Contains(oToItem.ProcessName) Then
|
|
||||||
oFromItem = DirectCast(hshCompareFrom(oToItem.ProcessName), clsGame)
|
|
||||||
If oToItem.CoreEquals(oFromItem) Then
|
|
||||||
hshDeleteItems.Remove(oToItem.ProcessName)
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
Next
|
|
||||||
|
|
||||||
For Each oGame As clsGame In hshDeleteItems.Values
|
|
||||||
If bToRemote Then
|
|
||||||
DoListDeleteSync(oGame, mgrSQLite.Database.Remote)
|
|
||||||
Else
|
|
||||||
DoListDeleteSync(oGame, mgrSQLite.Database.Local)
|
|
||||||
End If
|
|
||||||
Next
|
|
||||||
|
|
||||||
'Add / Update Sync
|
|
||||||
If bToRemote Then
|
|
||||||
hshCompareFrom = ReadList(eListTypes.FullList, mgrSQLite.Database.Local)
|
|
||||||
hshCompareTo = ReadList(eListTypes.FullList, mgrSQLite.Database.Remote)
|
|
||||||
Else
|
|
||||||
hshCompareFrom = ReadList(eListTypes.FullList, mgrSQLite.Database.Remote)
|
|
||||||
hshCompareTo = ReadList(eListTypes.FullList, mgrSQLite.Database.Local)
|
|
||||||
End If
|
|
||||||
|
|
||||||
hshSyncItems = hshCompareFrom.Clone
|
|
||||||
|
|
||||||
For Each oFromItem In hshCompareFrom.Values
|
|
||||||
If hshCompareTo.Contains(oFromItem.ProcessName) Then
|
|
||||||
oToItem = DirectCast(hshCompareTo(oFromItem.ProcessName), clsGame)
|
|
||||||
If oFromItem.SyncEquals(oToItem) Then
|
|
||||||
hshSyncItems.Remove(oFromItem.ProcessName)
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
Next
|
|
||||||
|
|
||||||
For Each oGame As clsGame In hshSyncItems.Values
|
|
||||||
'Clear Extra Data
|
|
||||||
oGame.Version = String.Empty
|
|
||||||
oGame.Company = String.Empty
|
|
||||||
oGame.ProcessPath = String.Empty
|
|
||||||
oGame.Icon = String.Empty
|
|
||||||
|
|
||||||
If bToRemote Then
|
|
||||||
If DoDuplicateListCheck(oGame.Name, oGame.TrueProcess, mgrSQLite.Database.Remote) Then
|
|
||||||
DoListUpdateSync(oGame, mgrSQLite.Database.Remote)
|
|
||||||
Else
|
|
||||||
DoListAdd(oGame, mgrSQLite.Database.Remote)
|
|
||||||
End If
|
|
||||||
Else
|
|
||||||
If DoDuplicateListCheck(oGame.Name, oGame.TrueProcess, mgrSQLite.Database.Local) Then
|
|
||||||
DoListUpdateSync(oGame, mgrSQLite.Database.Local)
|
|
||||||
Else
|
|
||||||
DoListAdd(oGame, mgrSQLite.Database.Local)
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
Next
|
|
||||||
|
|
||||||
RaiseEvent UpdateLog(hshDeleteItems.Count + hshSyncItems.Count & " change(s) synced.", False, ToolTipIcon.Info, True)
|
|
||||||
Cursor.Current = Cursors.Default
|
|
||||||
Application.DoEvents()
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Public Shared Function DoImport(ByVal sPath As String) As Boolean
|
Public Shared Function DoImport(ByVal sPath As String) As Boolean
|
||||||
If (sPath.IndexOf("http://", 0, StringComparison.CurrentCultureIgnoreCase) > -1) Or _
|
If (sPath.IndexOf("http://", 0, StringComparison.CurrentCultureIgnoreCase) > -1) Or _
|
||||||
(sPath.IndexOf("https://", 0, StringComparison.CurrentCultureIgnoreCase) > -1) Then
|
(sPath.IndexOf("https://", 0, StringComparison.CurrentCultureIgnoreCase) > -1) Then
|
||||||
@@ -207,6 +254,76 @@ Public Class mgrMonitorList
|
|||||||
Return False
|
Return False
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
Return True
|
||||||
|
End Function
|
||||||
|
|
||||||
|
|
||||||
|
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
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim oData As DataSet
|
||||||
|
Dim sSQL As String = String.Empty
|
||||||
|
Dim hshList As New Hashtable
|
||||||
|
Dim oGame As clsGame
|
||||||
|
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 clsGame
|
||||||
|
oGame.ID = 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"))
|
||||||
|
oGame.AppendTimeStamp = CBool(dr("TimeStamp"))
|
||||||
|
If Not IsDBNull(dr("ExcludeList")) Then oGame.ExcludeList = CStr(dr("ExcludeList"))
|
||||||
|
If Not IsDBNull(dr("ProcessPath")) Then oGame.ProcessPath = CStr(dr("ProcessPath"))
|
||||||
|
If Not IsDBNull(dr("Icon")) Then oGame.Icon = CStr(dr("Icon"))
|
||||||
|
oGame.Hours = CDbl(dr("Hours"))
|
||||||
|
If Not IsDBNull(dr("Version")) Then oGame.Version = CStr(dr("Version"))
|
||||||
|
If Not IsDBNull(dr("Company")) Then oGame.Company = CStr(dr("Company"))
|
||||||
|
oGame.Enabled = CBool(dr("Enabled"))
|
||||||
|
oGame.MonitorOnly = CBool(dr("MonitorOnly"))
|
||||||
|
|
||||||
|
hshList.Add(oGame.ID, oGame)
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return hshList
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Public Shared Function ReadList(ByVal eListType As eListTypes, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local) As Hashtable
|
Public Shared Function ReadList(ByVal eListType As eListTypes, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local) As Hashtable
|
||||||
@@ -218,27 +335,27 @@ Public Class mgrMonitorList
|
|||||||
Dim oGame As clsGame
|
Dim oGame As clsGame
|
||||||
Dim oDupeGame As clsGame
|
Dim oDupeGame As clsGame
|
||||||
|
|
||||||
sSQL = "SELECT * from monitorlist ORDER BY Name Asc"
|
sSQL = "Select * from monitorlist ORDER BY Name Asc"
|
||||||
oData = oDatabase.ReadParamData(sSQL, New Hashtable)
|
oData = oDatabase.ReadParamData(sSQL, New Hashtable)
|
||||||
|
|
||||||
For Each dr As DataRow In oData.Tables(0).Rows
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
oGame = New clsGame
|
oGame = New clsGame
|
||||||
oGame.ID = CStr(dr(0))
|
oGame.ID = CStr(dr("MonitorID"))
|
||||||
oGame.Name = CStr(dr(1))
|
oGame.Name = CStr(dr("Name"))
|
||||||
oGame.ProcessName = CStr(dr(2))
|
oGame.ProcessName = CStr(dr("Process"))
|
||||||
If Not IsDBNull(dr(3)) Then oGame.Path = CStr(dr(3))
|
If Not IsDBNull(dr("Path")) Then oGame.Path = CStr(dr("Path"))
|
||||||
oGame.AbsolutePath = CBool(dr(4))
|
oGame.AbsolutePath = CBool(dr("AbsolutePath"))
|
||||||
oGame.FolderSave = CBool(dr(5))
|
oGame.FolderSave = CBool(dr("FolderSave"))
|
||||||
If Not IsDBNull(dr(6)) Then oGame.FileType = CStr(dr(6))
|
If Not IsDBNull(dr("FileType")) Then oGame.FileType = CStr(dr("FileType"))
|
||||||
oGame.AppendTimeStamp = CBool(dr(7))
|
oGame.AppendTimeStamp = CBool(dr("TimeStamp"))
|
||||||
If Not IsDBNull(dr(8)) Then oGame.ExcludeList = CStr(dr(8))
|
If Not IsDBNull(dr("ExcludeList")) Then oGame.ExcludeList = CStr(dr("ExcludeList"))
|
||||||
If Not IsDBNull(dr(9)) Then oGame.ProcessPath = CStr(dr(9))
|
If Not IsDBNull(dr("ProcessPath")) Then oGame.ProcessPath = CStr(dr("ProcessPath"))
|
||||||
If Not IsDBNull(dr(10)) Then oGame.Icon = CStr(dr(10))
|
If Not IsDBNull(dr("Icon")) Then oGame.Icon = CStr(dr("Icon"))
|
||||||
oGame.Hours = CDbl(dr(11))
|
oGame.Hours = CDbl(dr("Hours"))
|
||||||
If Not IsDBNull(dr(12)) Then oGame.Version = CStr(dr(12))
|
If Not IsDBNull(dr("Version")) Then oGame.Version = CStr(dr("Version"))
|
||||||
If Not IsDBNull(dr(13)) Then oGame.Company = CStr(dr(13))
|
If Not IsDBNull(dr("Company")) Then oGame.Company = CStr(dr("Company"))
|
||||||
oGame.Enabled = CBool(dr(14))
|
oGame.Enabled = CBool(dr("Enabled"))
|
||||||
oGame.MonitorOnly = CBool(dr(15))
|
oGame.MonitorOnly = CBool(dr("MonitorOnly"))
|
||||||
|
|
||||||
Select Case eListType
|
Select Case eListType
|
||||||
Case eListTypes.FullList
|
Case eListTypes.FullList
|
||||||
@@ -264,14 +381,73 @@ Public Class mgrMonitorList
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
If oGame.Enabled Then hshList.Add(oGame.ProcessName, oGame)
|
If oGame.Enabled Then hshList.Add(oGame.ProcessName, oGame)
|
||||||
Case eListTypes.ListByKey
|
|
||||||
hshList.Add(oGame.ID, oGame)
|
|
||||||
End Select
|
End Select
|
||||||
Next
|
Next
|
||||||
|
|
||||||
Return hshList
|
Return hshList
|
||||||
End Function
|
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)
|
Public Shared Sub DoListAdd(ByVal oGame As clsGame, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
Dim oDatabase As New mgrSQLite(iSelectDB)
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
Dim sSQL As String
|
Dim sSQL As String
|
||||||
@@ -358,53 +534,15 @@ Public Class mgrMonitorList
|
|||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Shared Sub DoListUpdateSync(ByVal oGame As clsGame, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
|
||||||
Dim oDatabase As New mgrSQLite(iSelectDB)
|
|
||||||
Dim sSQL As String
|
|
||||||
Dim hshParams As New Hashtable
|
|
||||||
|
|
||||||
sSQL = "UPDATE monitorlist SET Name=@Name, Process=@Process, Path=@Path, AbsolutePath=@AbsolutePath, FolderSave=@FolderSave, "
|
|
||||||
sSQL &= "FileType=@FileType, TimeStamp=@TimeStamp, ExcludeList=@ExcludeList, Hours=@Hours "
|
|
||||||
sSQL &= "WHERE Name=@QueryName AND Process=@QueryProcess"
|
|
||||||
|
|
||||||
'Parameters
|
|
||||||
hshParams.Add("Name", oGame.Name)
|
|
||||||
hshParams.Add("Process", oGame.TrueProcess)
|
|
||||||
hshParams.Add("Path", oGame.TruePath)
|
|
||||||
hshParams.Add("AbsolutePath", oGame.AbsolutePath)
|
|
||||||
hshParams.Add("FolderSave", oGame.FolderSave)
|
|
||||||
hshParams.Add("FileType", oGame.FileType)
|
|
||||||
hshParams.Add("TimeStamp", oGame.AppendTimeStamp)
|
|
||||||
hshParams.Add("ExcludeList", oGame.ExcludeList)
|
|
||||||
hshParams.Add("Hours", oGame.Hours)
|
|
||||||
hshParams.Add("QueryName", oGame.Name)
|
|
||||||
hshParams.Add("QueryProcess", oGame.TrueProcess)
|
|
||||||
|
|
||||||
oDatabase.RunParamQuery(sSQL, hshParams)
|
|
||||||
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Public Shared Sub DoListDeleteSync(ByVal oGame As clsGame, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
|
||||||
Dim oDatabase As New mgrSQLite(iSelectDB)
|
|
||||||
Dim sSQL As String
|
|
||||||
Dim hshParams As New Hashtable
|
|
||||||
|
|
||||||
sSQL = "DELETE FROM monitorlist "
|
|
||||||
sSQL &= "WHERE Name = @Name AND Process= @Process"
|
|
||||||
|
|
||||||
hshParams.Add("Name", oGame.Name)
|
|
||||||
hshParams.Add("Process", oGame.TrueProcess)
|
|
||||||
|
|
||||||
oDatabase.RunParamQuery(sSQL, hshParams)
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Public Shared Sub DoListDelete(ByVal sMonitorID As String, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
Public Shared Sub DoListDelete(ByVal sMonitorID As String, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
Dim oDatabase As New mgrSQLite(iSelectDB)
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
Dim sSQL As String
|
Dim sSQL As String
|
||||||
Dim hshParams As New Hashtable
|
Dim hshParams As New Hashtable
|
||||||
|
|
||||||
sSQL = "DELETE FROM monitorlist "
|
sSQL = "DELETE FROM gametags "
|
||||||
sSQL &= "WHERE MonitorID = @MonitorID"
|
sSQL &= "WHERE MonitorID = @MonitorID;"
|
||||||
|
sSQL &= "DELETE FROM monitorlist "
|
||||||
|
sSQL &= "WHERE MonitorID = @MonitorID;"
|
||||||
|
|
||||||
hshParams.Add("MonitorID", sMonitorID)
|
hshParams.Add("MonitorID", sMonitorID)
|
||||||
|
|
||||||
@@ -418,7 +556,7 @@ Public Class mgrMonitorList
|
|||||||
Dim hshParams As New Hashtable
|
Dim hshParams As New Hashtable
|
||||||
Dim iCounter As Integer
|
Dim iCounter As Integer
|
||||||
|
|
||||||
sSQL = "DELETE FROM monitorlist "
|
sSQL = "DELETE FROM gametags "
|
||||||
sSQL &= "WHERE MonitorID IN ("
|
sSQL &= "WHERE MonitorID IN ("
|
||||||
|
|
||||||
For Each s As String In sMonitorIDs
|
For Each s As String In sMonitorIDs
|
||||||
@@ -428,7 +566,19 @@ Public Class mgrMonitorList
|
|||||||
Next
|
Next
|
||||||
|
|
||||||
sSQL = sSQL.TrimEnd(",")
|
sSQL = sSQL.TrimEnd(",")
|
||||||
sSQL &= ")"
|
sSQL &= ");"
|
||||||
|
|
||||||
|
sSQL &= "DELETE FROM monitorlist "
|
||||||
|
sSQL &= "WHERE MonitorID IN ("
|
||||||
|
|
||||||
|
For Each s As String In sMonitorIDs
|
||||||
|
sSQL &= "@MonitorID" & iCounter & ","
|
||||||
|
hshParams.Add("MonitorID" & iCounter, s)
|
||||||
|
iCounter += 1
|
||||||
|
Next
|
||||||
|
|
||||||
|
sSQL = sSQL.TrimEnd(",")
|
||||||
|
sSQL &= ");"
|
||||||
|
|
||||||
oDatabase.RunParamQuery(sSQL, hshParams)
|
oDatabase.RunParamQuery(sSQL, hshParams)
|
||||||
End Sub
|
End Sub
|
||||||
@@ -449,22 +599,22 @@ Public Class mgrMonitorList
|
|||||||
|
|
||||||
For Each dr As DataRow In oData.Tables(0).Rows
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
oGame = New clsGame
|
oGame = New clsGame
|
||||||
oGame.ID = CStr(dr(0))
|
oGame.ID = CStr(dr("MonitorID"))
|
||||||
oGame.Name = CStr(dr(1))
|
oGame.Name = CStr(dr("Name"))
|
||||||
oGame.ProcessName = CStr(dr(2))
|
oGame.ProcessName = CStr(dr("Process"))
|
||||||
If Not IsDBNull(dr(3)) Then oGame.Path = CStr(dr(3))
|
If Not IsDBNull(dr("Path")) Then oGame.Path = CStr(dr("Path"))
|
||||||
oGame.AbsolutePath = CBool(dr(4))
|
oGame.AbsolutePath = CBool(dr("AbsolutePath"))
|
||||||
oGame.FolderSave = CBool(dr(5))
|
oGame.FolderSave = CBool(dr("FolderSave"))
|
||||||
If Not IsDBNull(dr(6)) Then oGame.FileType = CStr(dr(6))
|
If Not IsDBNull(dr("FileType")) Then oGame.FileType = CStr(dr("FileType"))
|
||||||
oGame.AppendTimeStamp = CBool(dr(7))
|
oGame.AppendTimeStamp = CBool(dr("TimeStamp"))
|
||||||
If Not IsDBNull(dr(8)) Then oGame.ExcludeList = CStr(dr(8))
|
If Not IsDBNull(dr("ExcludeList")) Then oGame.ExcludeList = CStr(dr("ExcludeList"))
|
||||||
If Not IsDBNull(dr(9)) Then oGame.ProcessPath = CStr(dr(9))
|
If Not IsDBNull(dr("ProcessPath")) Then oGame.ProcessPath = CStr(dr("ProcessPath"))
|
||||||
If Not IsDBNull(dr(10)) Then oGame.Icon = CStr(dr(10))
|
If Not IsDBNull(dr("Icon")) Then oGame.Icon = CStr(dr("Icon"))
|
||||||
oGame.Hours = CDbl(dr(11))
|
oGame.Hours = CDbl(dr("Hours"))
|
||||||
If Not IsDBNull(dr(12)) Then oGame.Version = CStr(dr(12))
|
If Not IsDBNull(dr("Version")) Then oGame.Version = CStr(dr("Version"))
|
||||||
If Not IsDBNull(dr(13)) Then oGame.Company = CStr(dr(13))
|
If Not IsDBNull(dr("Company")) Then oGame.Company = CStr(dr("Company"))
|
||||||
oGame.Enabled = CBool(dr(14))
|
oGame.Enabled = CBool(dr("Enabled"))
|
||||||
oGame.MonitorOnly = CBool(dr(15))
|
oGame.MonitorOnly = CBool(dr("MonitorOnly"))
|
||||||
Next
|
Next
|
||||||
|
|
||||||
Return oGame
|
Return oGame
|
||||||
@@ -488,22 +638,22 @@ Public Class mgrMonitorList
|
|||||||
|
|
||||||
For Each dr As DataRow In oData.Tables(0).Rows
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
oGame = New clsGame
|
oGame = New clsGame
|
||||||
oGame.ID = CStr(dr(0))
|
oGame.ID = CStr(dr("MonitorID"))
|
||||||
oGame.Name = CStr(dr(1))
|
oGame.Name = CStr(dr("Name"))
|
||||||
oGame.ProcessName = CStr(dr(2))
|
oGame.ProcessName = CStr(dr("Process"))
|
||||||
If Not IsDBNull(dr(3)) Then oGame.Path = CStr(dr(3))
|
If Not IsDBNull(dr("Path")) Then oGame.Path = CStr(dr("Path"))
|
||||||
oGame.AbsolutePath = CBool(dr(4))
|
oGame.AbsolutePath = CBool(dr("AbsolutePath"))
|
||||||
oGame.FolderSave = CBool(dr(5))
|
oGame.FolderSave = CBool(dr("FolderSave"))
|
||||||
If Not IsDBNull(dr(6)) Then oGame.FileType = CStr(dr(6))
|
If Not IsDBNull(dr("FileType")) Then oGame.FileType = CStr(dr("FileType"))
|
||||||
oGame.AppendTimeStamp = CBool(dr(7))
|
oGame.AppendTimeStamp = CBool(dr("TimeStamp"))
|
||||||
If Not IsDBNull(dr(8)) Then oGame.ExcludeList = CStr(dr(8))
|
If Not IsDBNull(dr("ExcludeList")) Then oGame.ExcludeList = CStr(dr("ExcludeList"))
|
||||||
If Not IsDBNull(dr(9)) Then oGame.ProcessPath = CStr(dr(9))
|
If Not IsDBNull(dr("ProcessPath")) Then oGame.ProcessPath = CStr(dr("ProcessPath"))
|
||||||
If Not IsDBNull(dr(10)) Then oGame.Icon = CStr(dr(10))
|
If Not IsDBNull(dr("Icon")) Then oGame.Icon = CStr(dr("Icon"))
|
||||||
oGame.Hours = CDbl(dr(11))
|
oGame.Hours = CDbl(dr("Hours"))
|
||||||
If Not IsDBNull(dr(12)) Then oGame.Version = CStr(dr(12))
|
If Not IsDBNull(dr("Version")) Then oGame.Version = CStr(dr("Version"))
|
||||||
If Not IsDBNull(dr(13)) Then oGame.Company = CStr(dr(13))
|
If Not IsDBNull(dr("Company")) Then oGame.Company = CStr(dr("Company"))
|
||||||
oGame.Enabled = CBool(dr(14))
|
oGame.Enabled = CBool(dr("Enabled"))
|
||||||
oGame.MonitorOnly = CBool(dr(15))
|
oGame.MonitorOnly = CBool(dr("MonitorOnly"))
|
||||||
hshGames.Add(iCounter, oGame)
|
hshGames.Add(iCounter, oGame)
|
||||||
iCounter += 1
|
iCounter += 1
|
||||||
Next
|
Next
|
||||||
|
|||||||
@@ -8,9 +8,9 @@ Public Class mgrPath
|
|||||||
Private Shared sDBLocation As String = sSettingsRoot & "\gbm.s3db"
|
Private Shared sDBLocation As String = sSettingsRoot & "\gbm.s3db"
|
||||||
Private Shared sIncludeFile As String = sSettingsRoot & "\gbm_include.txt"
|
Private Shared sIncludeFile As String = sSettingsRoot & "\gbm_include.txt"
|
||||||
Private Shared sExcludeFile As String = sSettingsRoot & "\gbm_exclude.txt"
|
Private Shared sExcludeFile As String = sSettingsRoot & "\gbm_exclude.txt"
|
||||||
Private Shared sOfficialImportURL As String = "http://backupmonitor.sourceforge.net/GBM_Official.xml"
|
Private Shared sOfficialImportURL As String = "http://mikemaximus.github.io/gbm-web/GBM_Official.xml"
|
||||||
Private Shared sOfficialManualURL As String = "http://backupmonitor.sourceforge.net/manual.php"
|
Private Shared sOfficialManualURL As String = "http://mikemaximus.github.io/gbm-web/manual.html"
|
||||||
Private Shared sOfficialUpdatesURL As String = "http://backupmonitor.sourceforge.net/"
|
Private Shared sOfficialUpdatesURL As String = "https://github.com/MikeMaximus/gbm/releases"
|
||||||
Private Shared sRemoteDatabaseLocation As String
|
Private Shared sRemoteDatabaseLocation As String
|
||||||
Private Shared hshCustomVariables As Hashtable
|
Private Shared hshCustomVariables As Hashtable
|
||||||
Private Shared oReleaseType As ProcessorArchitecture = AssemblyName.GetAssemblyName(Application.ExecutablePath()).ProcessorArchitecture
|
Private Shared oReleaseType As ProcessorArchitecture = AssemblyName.GetAssemblyName(Application.ExecutablePath()).ProcessorArchitecture
|
||||||
|
|||||||
@@ -208,11 +208,11 @@ Public Class mgrRestore
|
|||||||
prs7z.StartInfo.RedirectStandardOutput = True
|
prs7z.StartInfo.RedirectStandardOutput = True
|
||||||
prs7z.StartInfo.CreateNoWindow = True
|
prs7z.StartInfo.CreateNoWindow = True
|
||||||
prs7z.Start()
|
prs7z.Start()
|
||||||
RaiseEvent UpdateLog("Restore to " & sExtractPath & " in progress...", True, ToolTipIcon.Info, True)
|
RaiseEvent UpdateLog("Restore to " & sExtractPath & " in progress...", False, ToolTipIcon.Info, True)
|
||||||
While Not prs7z.StandardOutput.EndOfStream
|
While Not prs7z.StandardOutput.EndOfStream
|
||||||
If CancelOperation Then
|
If CancelOperation Then
|
||||||
prs7z.Kill()
|
prs7z.Kill()
|
||||||
RaiseEvent UpdateLog("Restored Aborted by user. The save games for " & oBackupInfo.Name & " will be damaged or invalid.", False, ToolTipIcon.Error, True)
|
RaiseEvent UpdateLog("Restored Aborted. The saved games for " & oBackupInfo.Name & " may now be invalid.", True, ToolTipIcon.Error, True)
|
||||||
Exit While
|
Exit While
|
||||||
End If
|
End If
|
||||||
RaiseEvent UpdateLog(prs7z.StandardOutput.ReadLine, False, ToolTipIcon.Info, False)
|
RaiseEvent UpdateLog(prs7z.StandardOutput.ReadLine, False, ToolTipIcon.Info, False)
|
||||||
@@ -220,16 +220,16 @@ Public Class mgrRestore
|
|||||||
prs7z.WaitForExit()
|
prs7z.WaitForExit()
|
||||||
If Not CancelOperation Then
|
If Not CancelOperation Then
|
||||||
If prs7z.ExitCode = 0 Then
|
If prs7z.ExitCode = 0 Then
|
||||||
RaiseEvent UpdateLog(oBackupInfo.Name & " backup restored.", True, ToolTipIcon.Info, True)
|
RaiseEvent UpdateLog(oBackupInfo.Name & " backup restored.", False, ToolTipIcon.Info, True)
|
||||||
bRestoreCompleted = True
|
bRestoreCompleted = True
|
||||||
Else
|
Else
|
||||||
RaiseEvent UpdateLog(oBackupInfo.Name & " restore operation finished with warnings or errors.", False, ToolTipIcon.Info, True)
|
RaiseEvent UpdateLog(oBackupInfo.Name & " restore finished with warnings or errors.", True, ToolTipIcon.Warning, True)
|
||||||
bRestoreCompleted = False
|
bRestoreCompleted = False
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
prs7z.Dispose()
|
prs7z.Dispose()
|
||||||
Else
|
Else
|
||||||
RaiseEvent UpdateLog("Restore Aborted. The backup file could not be found. Ensure the backup location is available.", False, ToolTipIcon.Error, True)
|
RaiseEvent UpdateLog("Restore Aborted. The backup file could not be found.", True, ToolTipIcon.Error, True)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If bRestoreCompleted Then
|
If bRestoreCompleted Then
|
||||||
|
|||||||
@@ -71,7 +71,7 @@ Public Class mgrSQLite
|
|||||||
'Add Tables (Settings)
|
'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, " & _
|
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, " & _
|
"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);"
|
"BackupFolder TEXT NOT NULL, Sync BOOLEAN NOT NULL, CheckSum BOOLEAN NOT NULL, StartWithWindows BOOLEAN NOT NULL, TimeTracking BOOLEAN NOT NULL);"
|
||||||
|
|
||||||
'Add Tables (Monitor List)
|
'Add Tables (Monitor List)
|
||||||
sSql &= "CREATE TABLE monitorlist (MonitorID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL, Process TEXT NOT NULL, Path TEXT, " & _
|
sSql &= "CREATE TABLE monitorlist (MonitorID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL, Process TEXT NOT NULL, Path TEXT, " & _
|
||||||
@@ -79,6 +79,12 @@ Public Class mgrSQLite
|
|||||||
"ProcessPath TEXT, Icon TEXT, Hours REAL, Version TEXT, Company TEXT, Enabled BOOLEAN NOT NULL, MonitorOnly BOOLEAN NOT NULL, " & _
|
"ProcessPath TEXT, Icon TEXT, Hours REAL, Version TEXT, Company TEXT, Enabled BOOLEAN NOT NULL, MonitorOnly BOOLEAN NOT NULL, " & _
|
||||||
"PRIMARY KEY(Name, Process));"
|
"PRIMARY KEY(Name, Process));"
|
||||||
|
|
||||||
|
'Add Tables (Tags)
|
||||||
|
sSql &= "CREATE TABLE tags (TagID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY); "
|
||||||
|
|
||||||
|
'Add Tables (Game Tags)
|
||||||
|
sSql &= "CREATE TABLE gametags (TagID TEXT NOT NULL, MonitorID TEXT NOT NULL, PRIMARY KEY(TagID, MonitorID)); "
|
||||||
|
|
||||||
'Add Tables (Variables)
|
'Add Tables (Variables)
|
||||||
sSql &= "CREATE TABLE variables (VariableID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY, Path TEXT NOT NULL);"
|
sSql &= "CREATE TABLE variables (VariableID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY, Path TEXT NOT NULL);"
|
||||||
|
|
||||||
@@ -114,6 +120,12 @@ Public Class mgrSQLite
|
|||||||
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);"
|
"AbsolutePath BOOLEAN NOT NULL, DateUpdated TEXT NOT NULL, UpdatedBy TEXT NOT NULL, CheckSum TEXT);"
|
||||||
|
|
||||||
|
'Add Tables (Remote Tags)
|
||||||
|
sSql &= "CREATE TABLE tags (TagID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY); "
|
||||||
|
|
||||||
|
'Add Tables (Remote Game Tags)
|
||||||
|
sSql &= "CREATE TABLE gametags (TagID TEXT NOT NULL, MonitorID TEXT NOT NULL, PRIMARY KEY(TagID, MonitorID)); "
|
||||||
|
|
||||||
'Set Version
|
'Set Version
|
||||||
sSql &= "PRAGMA user_version=" & mgrCommon.AppVersion
|
sSql &= "PRAGMA user_version=" & mgrCommon.AppVersion
|
||||||
|
|
||||||
@@ -182,6 +194,32 @@ Public Class mgrSQLite
|
|||||||
Return True
|
Return True
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
|
Public Function RunMassParamQuery(ByVal sSQL As String, ByVal oParamList As List(Of Hashtable)) As Boolean
|
||||||
|
Dim trans As SQLiteTransaction
|
||||||
|
Dim command As SQLiteCommand
|
||||||
|
|
||||||
|
Connect()
|
||||||
|
command = New SQLiteCommand(sSQL, db)
|
||||||
|
trans = db.BeginTransaction()
|
||||||
|
|
||||||
|
Try
|
||||||
|
For Each hshParams In oParamList
|
||||||
|
BuildParams(command, hshParams)
|
||||||
|
command.ExecuteNonQuery()
|
||||||
|
Next
|
||||||
|
trans.Commit()
|
||||||
|
Catch e As Exception
|
||||||
|
trans.Rollback()
|
||||||
|
MsgBox("An error has occured attempting run the query." & vbCrLf & vbCrLf & sSQL & vbCrLf & vbCrLf & e.Message)
|
||||||
|
Return False
|
||||||
|
Finally
|
||||||
|
command.Dispose()
|
||||||
|
Disconnect()
|
||||||
|
End Try
|
||||||
|
|
||||||
|
Return True
|
||||||
|
End Function
|
||||||
|
|
||||||
Public Function ReadParamData(ByVal sSQL As String, ByVal hshParams As Hashtable) As DataSet
|
Public Function ReadParamData(ByVal sSQL As String, ByVal hshParams As Hashtable) As DataSet
|
||||||
Dim adapter As SQLiteDataAdapter
|
Dim adapter As SQLiteDataAdapter
|
||||||
Dim command As SQLiteCommand
|
Dim command As SQLiteCommand
|
||||||
@@ -411,6 +449,37 @@ Public Class mgrSQLite
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
'0.94 Upgrade
|
||||||
|
If GetDatabaseVersion() < 94 Then
|
||||||
|
If eDatabase = Database.Local Then
|
||||||
|
'Backup DB before starting
|
||||||
|
BackupDB("v93")
|
||||||
|
|
||||||
|
'Add Tags Tables
|
||||||
|
sSQL = "CREATE TABLE tags (TagID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY); "
|
||||||
|
sSQL &= "CREATE TABLE gametags (TagID TEXT NOT NULL, MonitorID TEXT NOT NULL, PRIMARY KEY(TagID, MonitorID)); "
|
||||||
|
|
||||||
|
'Add new setting
|
||||||
|
sSQL &= "ALTER TABLE settings ADD COLUMN TimeTracking BOOLEAN NOT NULL DEFAULT 1;"
|
||||||
|
|
||||||
|
sSQL &= "PRAGMA user_version=94"
|
||||||
|
|
||||||
|
RunParamQuery(sSQL, New Hashtable)
|
||||||
|
End If
|
||||||
|
If eDatabase = Database.Remote Then
|
||||||
|
'Backup DB before starting
|
||||||
|
BackupDB("v93")
|
||||||
|
|
||||||
|
'Add Tags Tables
|
||||||
|
sSQL = "CREATE TABLE tags (TagID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY); "
|
||||||
|
sSQL &= "CREATE TABLE gametags (TagID TEXT NOT NULL, MonitorID TEXT NOT NULL, PRIMARY KEY(TagID, MonitorID)); "
|
||||||
|
|
||||||
|
sSQL &= "PRAGMA user_version=94"
|
||||||
|
|
||||||
|
RunParamQuery(sSQL, New Hashtable)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Function GetDBSize() As Long
|
Public Function GetDBSize() As Long
|
||||||
|
|||||||
+24
-12
@@ -11,6 +11,7 @@ Public Class mgrSettings
|
|||||||
Private bRestoreOnLaunch As Boolean = False
|
Private bRestoreOnLaunch As Boolean = False
|
||||||
Private bSync As Boolean = True
|
Private bSync As Boolean = True
|
||||||
Private bCheckSum As Boolean = True
|
Private bCheckSum As Boolean = True
|
||||||
|
Private bTimeTracking As Boolean = True
|
||||||
Private sBackupFolder As String = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments).TrimEnd(New Char() {"\", "/"})
|
Private sBackupFolder As String = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments).TrimEnd(New Char() {"\", "/"})
|
||||||
|
|
||||||
Property StartWithWindows As Boolean
|
Property StartWithWindows As Boolean
|
||||||
@@ -103,6 +104,15 @@ Public Class mgrSettings
|
|||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Property TimeTracking As Boolean
|
||||||
|
Get
|
||||||
|
Return bTimeTracking
|
||||||
|
End Get
|
||||||
|
Set(value As Boolean)
|
||||||
|
bTimeTracking = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
Property BackupFolder As String
|
Property BackupFolder As String
|
||||||
Get
|
Get
|
||||||
Return sBackupFolder
|
Return sBackupFolder
|
||||||
@@ -121,7 +131,7 @@ Public Class mgrSettings
|
|||||||
oDatabase.RunParamQuery(sSQL, New Hashtable)
|
oDatabase.RunParamQuery(sSQL, New Hashtable)
|
||||||
|
|
||||||
sSQL = "INSERT INTO settings VALUES (1, @MonitorOnStartup, @StartToTray, @ShowDetectionToolTips, @DisableConfirmation, "
|
sSQL = "INSERT INTO settings VALUES (1, @MonitorOnStartup, @StartToTray, @ShowDetectionToolTips, @DisableConfirmation, "
|
||||||
sSQL &= "@CreateSubFolder, @ShowOverwriteWarning, @RestoreOnLaunch, @BackupFolder, @Sync, @CheckSum, @StartWithWindows)"
|
sSQL &= "@CreateSubFolder, @ShowOverwriteWarning, @RestoreOnLaunch, @BackupFolder, @Sync, @CheckSum, @StartWithWindows, @TimeTracking)"
|
||||||
|
|
||||||
hshParams.Add("MonitorOnStartup", MonitorOnStartup)
|
hshParams.Add("MonitorOnStartup", MonitorOnStartup)
|
||||||
hshParams.Add("StartToTray", StartToTray)
|
hshParams.Add("StartToTray", StartToTray)
|
||||||
@@ -134,6 +144,7 @@ Public Class mgrSettings
|
|||||||
hshParams.Add("Sync", Sync)
|
hshParams.Add("Sync", Sync)
|
||||||
hshParams.Add("CheckSum", CheckSum)
|
hshParams.Add("CheckSum", CheckSum)
|
||||||
hshParams.Add("StartWithWindows", StartWithWindows)
|
hshParams.Add("StartWithWindows", StartWithWindows)
|
||||||
|
hshParams.Add("TimeTracking", TimeTracking)
|
||||||
|
|
||||||
oDatabase.RunParamQuery(sSQL, hshParams)
|
oDatabase.RunParamQuery(sSQL, hshParams)
|
||||||
End Sub
|
End Sub
|
||||||
@@ -149,17 +160,18 @@ Public Class mgrSettings
|
|||||||
oData = oDatabase.ReadParamData(sSQL, New Hashtable)
|
oData = oDatabase.ReadParamData(sSQL, New Hashtable)
|
||||||
|
|
||||||
For Each dr As DataRow In oData.Tables(0).Rows
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
MonitorOnStartup = CBool(dr(1))
|
MonitorOnStartup = CBool(dr("MonitorOnStartup"))
|
||||||
StartToTray = CBool(dr(2))
|
StartToTray = CBool(dr("StartToTray"))
|
||||||
ShowDetectionToolTips = CBool(dr(3))
|
ShowDetectionToolTips = CBool(dr("ShowDetectionToolTips"))
|
||||||
DisableConfirmation = CBool(dr(4))
|
DisableConfirmation = CBool(dr("DisableConfirmation"))
|
||||||
CreateSubFolder = CBool(dr(5))
|
CreateSubFolder = CBool(dr("CreateSubFolder"))
|
||||||
ShowOverwriteWarning = CBool(dr(6))
|
ShowOverwriteWarning = CBool(dr("ShowOverwriteWarning"))
|
||||||
RestoreOnLaunch = CBool(dr(7))
|
RestoreOnLaunch = CBool(dr("RestoreOnLaunch"))
|
||||||
BackupFolder = CStr(dr(8))
|
BackupFolder = CStr(dr("BackupFolder"))
|
||||||
Sync = CBool(dr(9))
|
Sync = CBool(dr("Sync"))
|
||||||
CheckSum = CBool(dr(10))
|
CheckSum = CBool(dr("CheckSum"))
|
||||||
StartWithWindows = CBool(dr(11))
|
StartWithWindows = CBool(dr("StartWithWindows"))
|
||||||
|
TimeTracking = CBool(dr("TimeTracking"))
|
||||||
Next
|
Next
|
||||||
|
|
||||||
oDatabase.Disconnect()
|
oDatabase.Disconnect()
|
||||||
|
|||||||
@@ -0,0 +1,264 @@
|
|||||||
|
Public Class mgrTags
|
||||||
|
|
||||||
|
Public Shared Sub DoTagAdd(ByVal oTag As clsTag, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
|
||||||
|
sSQL = "INSERT INTO tags VALUES (@ID, @Name)"
|
||||||
|
hshParams.Add("ID", oTag.ID)
|
||||||
|
hshParams.Add("Name", oTag.Name)
|
||||||
|
oDatabase.RunParamQuery(sSQL, hshParams)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Sub DoTagUpdate(ByVal oTag As clsTag, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
|
||||||
|
sSQL = "UPDATE tags SET Name=@Name "
|
||||||
|
sSQL &= "WHERE TagID = @ID"
|
||||||
|
|
||||||
|
hshParams.Add("Name", oTag.Name)
|
||||||
|
hshParams.Add("ID", oTag.ID)
|
||||||
|
|
||||||
|
oDatabase.RunParamQuery(sSQL, hshParams)
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Sub DoTagDelete(ByVal sTagID As String)
|
||||||
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
|
||||||
|
sSQL = "DELETE FROM gametags "
|
||||||
|
sSQL &= "WHERE TagID = @ID;"
|
||||||
|
sSQL = "DELETE FROM tags "
|
||||||
|
sSQL &= "WHERE TagID = @ID;"
|
||||||
|
|
||||||
|
hshParams.Add("ID", sTagID)
|
||||||
|
|
||||||
|
oDatabase.RunParamQuery(sSQL, hshParams)
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Function DoTagGetbyID(ByVal sTagID As String) As clsTag
|
||||||
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim oData As DataSet
|
||||||
|
Dim oTag As New clsTag
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
|
||||||
|
sSQL = "SELECT * FROM tags "
|
||||||
|
sSQL &= "WHERE TagID = @ID"
|
||||||
|
|
||||||
|
hshParams.Add("ID", sTagID)
|
||||||
|
|
||||||
|
oData = oDatabase.ReadParamData(sSQL, hshParams)
|
||||||
|
|
||||||
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
|
oTag = New clsTag
|
||||||
|
oTag.ID = CStr(dr("TagID"))
|
||||||
|
oTag.Name = CStr(dr("Name"))
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return oTag
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Shared Function DoTagGetbyName(ByVal sTagName As String) As clsTag
|
||||||
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim oData As DataSet
|
||||||
|
Dim oTag As New clsTag
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
|
||||||
|
sSQL = "SELECT * FROM tags "
|
||||||
|
sSQL &= "WHERE Name = @Name"
|
||||||
|
|
||||||
|
hshParams.Add("Name", sTagName)
|
||||||
|
|
||||||
|
oData = oDatabase.ReadParamData(sSQL, hshParams)
|
||||||
|
|
||||||
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
|
oTag = New clsTag
|
||||||
|
oTag.ID = CStr(dr("TagID"))
|
||||||
|
oTag.Name = CStr(dr("Name"))
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return oTag
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Shared Function DoCheckDuplicate(ByVal sTagName As String, Optional ByVal sExcludeID As String = "", Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local) As Boolean
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim oData As DataSet
|
||||||
|
Dim hshParams As New Hashtable
|
||||||
|
|
||||||
|
sSQL = "SELECT * FROM tags "
|
||||||
|
sSQL &= "WHERE Name = @Name"
|
||||||
|
|
||||||
|
hshParams.Add("Name", sTagName)
|
||||||
|
|
||||||
|
If sExcludeID <> String.Empty Then
|
||||||
|
sSQL &= " AND TagID <> @TagID"
|
||||||
|
hshParams.Add("TagID", sExcludeID)
|
||||||
|
End If
|
||||||
|
|
||||||
|
oData = oDatabase.ReadParamData(sSQL, hshParams)
|
||||||
|
|
||||||
|
If oData.Tables(0).Rows.Count > 0 Then
|
||||||
|
Return True
|
||||||
|
Else
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Shared Function ReadTags(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
|
||||||
|
Dim hshList As New Hashtable
|
||||||
|
Dim oTag As clsTag
|
||||||
|
|
||||||
|
sSQL = "SELECT * from tags"
|
||||||
|
oData = oDatabase.ReadParamData(sSQL, New Hashtable)
|
||||||
|
|
||||||
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
|
oTag = New clsTag
|
||||||
|
oTag.ID = CStr(dr("TagID"))
|
||||||
|
oTag.Name = CStr(dr("Name"))
|
||||||
|
hshList.Add(oTag.Name, oTag)
|
||||||
|
Next
|
||||||
|
|
||||||
|
Return hshList
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Public Shared Sub DoTagAddImport(ByVal hshTags As Hashtable, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim sMonitorID As String
|
||||||
|
Dim oTag As clsTag
|
||||||
|
Dim hshParams As Hashtable
|
||||||
|
Dim oParamList As New List(Of Hashtable)
|
||||||
|
|
||||||
|
sSQL = "INSERT OR REPLACE INTO tags VALUES (COALESCE((SELECT TagID FROM tags WHERE Name = @Name), @ID), @Name); INSERT INTO gametags VALUES ((SELECT TagID from tags WHERE Name=@Name), @MonitorID);"
|
||||||
|
For Each oGame As clsGame In hshTags.Values
|
||||||
|
sMonitorID = oGame.ID
|
||||||
|
For Each t As Tag In oGame.ImportTags
|
||||||
|
hshParams = New Hashtable
|
||||||
|
oTag = New clsTag
|
||||||
|
oTag.Name = t.Name
|
||||||
|
hshParams.Add("ID", oTag.ID)
|
||||||
|
hshParams.Add("Name", oTag.Name)
|
||||||
|
hshParams.Add("MonitorID", sMonitorID)
|
||||||
|
oParamList.Add(hshParams)
|
||||||
|
Next
|
||||||
|
Next
|
||||||
|
|
||||||
|
oDatabase.RunMassParamQuery(sSQL, oParamList)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Sub DoTagAddUpdateSync(ByVal hshTags As Hashtable, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As Hashtable
|
||||||
|
Dim oParamList As New List(Of Hashtable)
|
||||||
|
|
||||||
|
sSQL = "INSERT OR REPLACE INTO tags VALUES (@ID, @Name);"
|
||||||
|
|
||||||
|
For Each oTag As clsTag In hshTags.Values
|
||||||
|
hshParams = New Hashtable
|
||||||
|
hshParams.Add("ID", oTag.ID)
|
||||||
|
hshParams.Add("Name", oTag.Name)
|
||||||
|
oParamList.Add(hshParams)
|
||||||
|
Next
|
||||||
|
|
||||||
|
oDatabase.RunMassParamQuery(sSQL, oParamList)
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Shared Sub DoTagDeleteSync(ByVal hshTags As Hashtable, Optional ByVal iSelectDB As mgrSQLite.Database = mgrSQLite.Database.Local)
|
||||||
|
Dim oDatabase As New mgrSQLite(iSelectDB)
|
||||||
|
Dim sSQL As String
|
||||||
|
Dim hshParams As Hashtable
|
||||||
|
Dim oParamList As New List(Of Hashtable)
|
||||||
|
|
||||||
|
sSQL = "DELETE FROM gametags "
|
||||||
|
sSQL &= "WHERE TagID = @ID;"
|
||||||
|
sSQL = "DELETE FROM tags "
|
||||||
|
sSQL &= "WHERE TagID = @ID;"
|
||||||
|
|
||||||
|
For Each oTag As clsTag In hshTags.Values
|
||||||
|
hshParams = New Hashtable
|
||||||
|
hshParams.Add("ID", oTag.ID)
|
||||||
|
oParamList.Add(hshParams)
|
||||||
|
Next
|
||||||
|
|
||||||
|
oDatabase.RunMassParamQuery(sSQL, oParamList)
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Public Shared Function SyncTags(Optional ByVal bToRemote As Boolean = True) As Integer
|
||||||
|
Dim hshCompareFrom As Hashtable
|
||||||
|
Dim hshCompareTo As Hashtable
|
||||||
|
Dim hshSyncItems As Hashtable
|
||||||
|
Dim hshDeleteItems As Hashtable
|
||||||
|
Dim oFromItem As clsTag
|
||||||
|
Dim oToItem As clsTag
|
||||||
|
|
||||||
|
'Add / Update Sync
|
||||||
|
If bToRemote Then
|
||||||
|
hshCompareFrom = ReadTags(mgrSQLite.Database.Local)
|
||||||
|
hshCompareTo = ReadTags(mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
hshCompareFrom = ReadTags(mgrSQLite.Database.Remote)
|
||||||
|
hshCompareTo = ReadTags(mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
hshSyncItems = hshCompareFrom.Clone
|
||||||
|
|
||||||
|
For Each oFromItem In hshCompareFrom.Values
|
||||||
|
If hshCompareTo.Contains(oFromItem.Name) Then
|
||||||
|
oToItem = DirectCast(hshCompareTo(oFromItem.Name), clsTag)
|
||||||
|
If oFromItem.CoreEquals(oToItem) Then
|
||||||
|
hshSyncItems.Remove(oFromItem.Name)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
If bToRemote Then
|
||||||
|
DoTagAddUpdateSync(hshSyncItems, mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
DoTagAddUpdateSync(hshSyncItems, mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
'Delete Sync
|
||||||
|
If bToRemote Then
|
||||||
|
hshCompareFrom = ReadTags(mgrSQLite.Database.Local)
|
||||||
|
hshCompareTo = ReadTags(mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
hshCompareFrom = ReadTags(mgrSQLite.Database.Remote)
|
||||||
|
hshCompareTo = ReadTags(mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
hshDeleteItems = hshCompareTo.Clone
|
||||||
|
|
||||||
|
For Each oToItem In hshCompareTo.Values
|
||||||
|
If hshCompareFrom.Contains(oToItem.Name) Then
|
||||||
|
oFromItem = DirectCast(hshCompareFrom(oToItem.Name), clsTag)
|
||||||
|
If oToItem.MinimalEquals(oFromItem) Then
|
||||||
|
hshDeleteItems.Remove(oToItem.Name)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
|
||||||
|
If bToRemote Then
|
||||||
|
DoTagDeleteSync(hshDeleteItems, mgrSQLite.Database.Remote)
|
||||||
|
Else
|
||||||
|
DoTagDeleteSync(hshDeleteItems, mgrSQLite.Database.Local)
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return hshDeleteItems.Count + hshSyncItems.Count
|
||||||
|
|
||||||
|
End Function
|
||||||
|
|
||||||
|
End Class
|
||||||
@@ -1,6 +1,4 @@
|
|||||||
Imports System.IO
|
Public Class mgrVariables
|
||||||
|
|
||||||
Public Class mgrVariables
|
|
||||||
|
|
||||||
Public Shared Sub DoPathUpdate(ByVal sOld As String, ByVal sNew As String)
|
Public Shared Sub DoPathUpdate(ByVal sOld As String, ByVal sNew As String)
|
||||||
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
Dim oDatabase As New mgrSQLite(mgrSQLite.Database.Local)
|
||||||
@@ -72,9 +70,9 @@ Public Class mgrVariables
|
|||||||
|
|
||||||
For Each dr As DataRow In oData.Tables(0).Rows
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
oCustomVariable = New clsPathVariable
|
oCustomVariable = New clsPathVariable
|
||||||
oCustomVariable.ID = CStr(dr(0))
|
oCustomVariable.ID = CStr(dr("VariableID"))
|
||||||
oCustomVariable.Name = CStr(dr(1))
|
oCustomVariable.Name = CStr(dr("Name"))
|
||||||
oCustomVariable.Path = CStr(dr(2))
|
oCustomVariable.Path = CStr(dr("Path"))
|
||||||
Next
|
Next
|
||||||
|
|
||||||
Return oCustomVariable
|
Return oCustomVariable
|
||||||
@@ -96,9 +94,9 @@ Public Class mgrVariables
|
|||||||
|
|
||||||
For Each dr As DataRow In oData.Tables(0).Rows
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
oCustomVariable = New clsPathVariable
|
oCustomVariable = New clsPathVariable
|
||||||
oCustomVariable.ID = CStr(dr(0))
|
oCustomVariable.ID = CStr(dr("VariableID"))
|
||||||
oCustomVariable.Name = CStr(dr(1))
|
oCustomVariable.Name = CStr(dr("Name"))
|
||||||
oCustomVariable.Path = CStr(dr(2))
|
oCustomVariable.Path = CStr(dr("Path"))
|
||||||
Next
|
Next
|
||||||
|
|
||||||
Return oCustomVariable
|
Return oCustomVariable
|
||||||
@@ -141,9 +139,9 @@ Public Class mgrVariables
|
|||||||
|
|
||||||
For Each dr As DataRow In oData.Tables(0).Rows
|
For Each dr As DataRow In oData.Tables(0).Rows
|
||||||
oCustomVariable = New clsPathVariable
|
oCustomVariable = New clsPathVariable
|
||||||
oCustomVariable.ID = CStr(dr(0))
|
oCustomVariable.ID = CStr(dr("VariableID"))
|
||||||
oCustomVariable.Name = CStr(dr(1))
|
oCustomVariable.Name = CStr(dr("Name"))
|
||||||
oCustomVariable.Path = CStr(dr(2))
|
oCustomVariable.Path = CStr(dr("Path"))
|
||||||
hshList.Add(oCustomVariable.Name, oCustomVariable)
|
hshList.Add(oCustomVariable.Name, oCustomVariable)
|
||||||
Next
|
Next
|
||||||
|
|
||||||
|
|||||||
+64
-67
@@ -1,11 +1,12 @@
|
|||||||
Imports System.Xml
|
Imports System.Xml.Serialization
|
||||||
Imports System.IO
|
Imports System.IO
|
||||||
Imports System.Text
|
Imports System.Net
|
||||||
|
|
||||||
|
|
||||||
Public Class mgrXML
|
Public Class mgrXML
|
||||||
|
|
||||||
Public Shared Function ReadMonitorList(ByVal sLocation As String, Optional ByVal bWebRead As Boolean = False) As Hashtable
|
Public Shared Function ReadMonitorList(ByVal sLocation As String, Optional ByVal bWebRead As Boolean = False) As Hashtable
|
||||||
Dim xFileReader As XmlTextReader
|
Dim oList As List(Of Game)
|
||||||
Dim hshList As New Hashtable
|
Dim hshList As New Hashtable
|
||||||
Dim hshDupeList As New Hashtable
|
Dim hshDupeList As New Hashtable
|
||||||
Dim oGame As clsGame
|
Dim oGame As clsGame
|
||||||
@@ -16,84 +17,80 @@ Public Class mgrXML
|
|||||||
Return hshList
|
Return hshList
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Try
|
oList = ImportandDeserialize(sLocation, bWebRead)
|
||||||
xFileReader = New XmlTextReader(sLocation)
|
|
||||||
xFileReader.WhitespaceHandling = WhitespaceHandling.None
|
|
||||||
|
|
||||||
While (xFileReader.Read())
|
For Each g As Game In oList
|
||||||
If xFileReader.Name = "app" Then
|
oGame = New clsGame
|
||||||
oGame = New clsGame
|
oGame.Name = g.Name
|
||||||
oGame.Name = xFileReader.GetAttribute("name")
|
oGame.ProcessName = g.ProcessName
|
||||||
xFileReader.Read()
|
oGame.AbsolutePath = g.AbsolutePath
|
||||||
oGame.ProcessName = xFileReader.ReadElementString("process")
|
oGame.Path = g.Path
|
||||||
oGame.AbsolutePath = xFileReader.ReadElementString("absolutepath")
|
oGame.FolderSave = g.FolderSave
|
||||||
oGame.Path = xFileReader.ReadElementString("savelocation")
|
oGame.FileType = g.FileType
|
||||||
oGame.FolderSave = xFileReader.ReadElementString("foldersave")
|
oGame.ExcludeList = g.ExcludeList
|
||||||
oGame.FileType = xFileReader.ReadElementString("filetype")
|
For Each t As Tag In g.Tags
|
||||||
oGame.AppendTimeStamp = xFileReader.ReadElementString("appendtimestamp")
|
oGame.ImportTags.Add(t)
|
||||||
oGame.ExcludeList = xFileReader.ReadElementString("excludelist")
|
Next
|
||||||
|
|
||||||
If hshList.Contains(oGame.ProcessName) Or hshDupeList.Contains(oGame.ProcessName) Then
|
If hshList.Contains(oGame.ProcessName) Or hshDupeList.Contains(oGame.ProcessName) Then
|
||||||
oDupeGame = DirectCast(hshList.Item(oGame.ProcessName), clsGame)
|
oDupeGame = DirectCast(hshList.Item(oGame.ProcessName), clsGame)
|
||||||
If Not hshDupeList.Contains(oGame.ProcessName) Then
|
If Not hshDupeList.Contains(oGame.ProcessName) Then
|
||||||
hshDupeList.Add(oGame.ProcessName, oDupeGame)
|
hshDupeList.Add(oGame.ProcessName, oDupeGame)
|
||||||
hshList.Remove(oDupeGame.ProcessName)
|
hshList.Remove(oDupeGame.ProcessName)
|
||||||
oDupeGame.Duplicate = True
|
oDupeGame.Duplicate = True
|
||||||
oDupeGame.ProcessName = oDupeGame.ProcessName & ":" & oDupeGame.Name
|
oDupeGame.ProcessName = oDupeGame.ProcessName & ":" & oDupeGame.Name
|
||||||
hshList.Add(oDupeGame.ProcessName, oDupeGame)
|
hshList.Add(oDupeGame.ProcessName, oDupeGame)
|
||||||
End If
|
|
||||||
oGame.ProcessName = oGame.ProcessName & ":" & oGame.Name
|
|
||||||
oGame.Duplicate = True
|
|
||||||
End If
|
|
||||||
|
|
||||||
hshList.Add(oGame.ProcessName, oGame)
|
|
||||||
End If
|
End If
|
||||||
End While
|
oGame.ProcessName = oGame.ProcessName & ":" & oGame.Name
|
||||||
|
oGame.Duplicate = True
|
||||||
|
End If
|
||||||
|
|
||||||
xFileReader.Close()
|
hshList.Add(oGame.ProcessName, oGame)
|
||||||
|
Next
|
||||||
'We need to trigger a manual garbage collection here to prevent issues with the reader freezing up with multiple uses.
|
|
||||||
'There's no way to properly dispose a xml text reader in .NET 4, that's only fixed in 4.5+.
|
|
||||||
GC.Collect()
|
|
||||||
|
|
||||||
Catch ex As Exception
|
|
||||||
MsgBox("An error occured reading the monitor list import file." & vbCrLf & ex.Message, MsgBoxStyle.Exclamation, "Game Backup Monitor")
|
|
||||||
End Try
|
|
||||||
|
|
||||||
Return hshList
|
Return hshList
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Public Shared Function ExportMonitorList(ByVal hshList As Hashtable, ByVal sLocation As String) As Boolean
|
Public Shared Function ImportandDeserialize(ByVal sLocation As String, Optional ByVal bWebRead As Boolean = False) As List(Of Game)
|
||||||
Dim xFileWriter As XmlTextWriter
|
Dim oReader As StreamReader
|
||||||
|
Dim oWebClient As WebClient
|
||||||
|
Dim oSerializer As XmlSerializer
|
||||||
|
Dim oList As New List(Of Game)
|
||||||
|
|
||||||
Try
|
Try
|
||||||
xFileWriter = New XmlTextWriter(sLocation, System.Text.Encoding.Unicode)
|
If bWebRead Then
|
||||||
xFileWriter.Formatting = Formatting.Indented
|
oWebClient = New WebClient
|
||||||
xFileWriter.WriteStartDocument()
|
oReader = New StreamReader(oWebClient.OpenRead(sLocation))
|
||||||
xFileWriter.WriteComment("GBM Export: " & Date.Now)
|
Else
|
||||||
xFileWriter.WriteComment("Entries: " & hshList.Count)
|
oReader = New StreamReader(sLocation)
|
||||||
xFileWriter.WriteStartElement("aMon")
|
End If
|
||||||
For Each o As clsGame In hshList.Values
|
|
||||||
xFileWriter.WriteStartElement("app")
|
oSerializer = New XmlSerializer(oList.GetType(), New XmlRootAttribute("gbm"))
|
||||||
xFileWriter.WriteAttributeString("name", o.Name)
|
oList = oSerializer.Deserialize(oReader)
|
||||||
xFileWriter.WriteElementString("process", o.TrueProcess)
|
oReader.Close()
|
||||||
xFileWriter.WriteElementString("absolutepath", o.AbsolutePath)
|
Catch ex As Exception
|
||||||
xFileWriter.WriteElementString("savelocation", o.TruePath)
|
MsgBox("The XML file cannot be read, it may be an invalid format or corrupted." & vbCrLf & vbCrLf & ex.Message, MsgBoxStyle.Exclamation, "Game Backup Monitor")
|
||||||
xFileWriter.WriteElementString("foldersave", o.FolderSave)
|
End Try
|
||||||
xFileWriter.WriteElementString("filetype", o.FileType)
|
|
||||||
xFileWriter.WriteElementString("appendtimestamp", o.AppendTimeStamp)
|
Return oList
|
||||||
xFileWriter.WriteElementString("excludelist", o.ExcludeList)
|
End Function
|
||||||
xFileWriter.WriteEndElement()
|
|
||||||
Next
|
Public Shared Function SerializeAndExport(ByVal oList As List(Of Game), ByVal sLocation As String) As Boolean
|
||||||
xFileWriter.WriteEndElement()
|
Dim oSerializer As XmlSerializer
|
||||||
xFileWriter.WriteEndDocument()
|
Dim oWriter As StreamWriter
|
||||||
xFileWriter.Flush()
|
|
||||||
xFileWriter.Close()
|
Try
|
||||||
|
oSerializer = New XmlSerializer(oList.GetType(), New XmlRootAttribute("gbm"))
|
||||||
|
oWriter = New StreamWriter(sLocation)
|
||||||
|
oSerializer.Serialize(oWriter.BaseStream, oList)
|
||||||
|
oWriter.Flush()
|
||||||
|
oWriter.Close()
|
||||||
Return True
|
Return True
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
MsgBox("An error occured exporting the monitor list. " & ex.Message, MsgBoxStyle.Exclamation, "Game Backup Monitor")
|
MsgBox("An error occured exporting the XML data." & vbCrLf & vbCrLf & ex.Message, MsgBoxStyle.Exclamation, "Game Backup Monitor")
|
||||||
Return False
|
Return False
|
||||||
End Try
|
End Try
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
+14
-22
@@ -1,7 +1,7 @@
|
|||||||
Game Backup Monitor v0.93 Readme
|
Game Backup Monitor v0.94 Readme
|
||||||
http://backupmonitor.sourceforge.net/
|
http://mikemaximus.github.io/gbm-web/
|
||||||
|
|
||||||
October 13, 2015
|
November 17, 2015
|
||||||
|
|
||||||
Disclaimer:
|
Disclaimer:
|
||||||
|
|
||||||
@@ -13,26 +13,18 @@ This application is designed to run in the system tray and monitor for games you
|
|||||||
|
|
||||||
GBM has been designed with mostly classic gaming in mind, but it can be used for any application!
|
GBM has been designed with mostly classic gaming in mind, but it can be used for any application!
|
||||||
|
|
||||||
Important Upgrade Information:
|
New in 0.94
|
||||||
|
|
||||||
1. You may notice one or more backup dates are incorrect after upgrading to v0.93. This is due to fallback behavior during the upgrade process when a date cannot be converted correctly.
|
- 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.
|
||||||
2. Due to core changes to how GBM handles backups, some game configurations that exclude sub-folders may break in v0.93, including official configurations.
|
- 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.
|
||||||
If you have any issues with the following game backups after upgrading to v0.93, delete them from the Game Manager and re-import them from the official list.
|
- Added the ability to restart GBM as Administrator from the status bar.
|
||||||
|
- Redesigned notifications, GBM is now silent unless a problem occurs.
|
||||||
Call of Cthulhu - Dark Corners of The Earth
|
- Enhanced the sync logic and performance.
|
||||||
Dead State
|
- The backup "Timestamp" setting is no longer included in XML imports or exports.
|
||||||
Democracy 3
|
- Redesigned the XML import and export core. Sorry, this invalidates all prior XML exports files, but it will ensure future backwards compatability.
|
||||||
Grand Theft Auto - San Andreas
|
- Various bug fixes.
|
||||||
Kerbal Space Program
|
|
||||||
POD Gold
|
|
||||||
Simcity 4 Deluxe
|
|
||||||
The Settlers: Rise of an Empire
|
|
||||||
Tropico 4
|
|
||||||
Victor Vran
|
|
||||||
|
|
||||||
Please check the Game Manager section of the manual if you're having problems with your custom game entries.
|
|
||||||
|
|
||||||
New in 0.93
|
New in 0.93
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,14 @@
|
|||||||
# Game Backup Monitor
|
# [Game Backup Monitor] (http://mikemaximus.github.io/gbm-web/)
|
||||||
|
|
||||||
<b>Important Notice:</b> This project is currently in the process of being transferred from Sourceforge. Releases and documentation will be available soon, for now the latest release and documentation for this project are available at http://backupmonitor.sourceforge.net.
|
![Screenshot] (http://mikemaximus.github.io/gbm-web/images/manual/manual_01.jpg)
|
||||||
|
|
||||||
Game Backup Monitor is a Windows system tray application that automatically detects games as you play them. When you're finished playing, a compressed backup of the save data will be automatically created in a location you've specified, such as a cloud folder, network folder or external drive.
|
Game Backup Monitor is a simple, but flexible application that detects games as you play them. Once you finish playing a game, a backup of the saved games will be made automatically using 7-Zip compression. GBM can be used on a single computer, or on multiple computers to effectively add cloud support to any Windows game or application.
|
||||||
|
|
||||||
If you use Game Backup Monitor on multiple computers and share the same backup folder, you can effectively add cloud support to any game or application. GBM can notify you of new files to be restored when you move to each computer.
|
**License**: GNU General Public License version 3.0 (GPLv3)<br />
|
||||||
|
**Language**: English Only<br />
|
||||||
Game Backup Monitor was designed with classic DRM-free gaming in mind, but it can be used to monitor any application on your PC!
|
**Platform**: Windows Only (.NET 4)
|
||||||
|
|
||||||
Game Backup Monitor is currently only available in English.
|
|
||||||
|
|
||||||
|
[Game Backup Monitor FAQ] (http://mikemaximus.github.io/gbm-web/faq.html) <br />
|
||||||
|
[Game Backup Monitor Manual] (http://mikemaximus.github.io/gbm-web/manual.html) <br />
|
||||||
|
[List of Preconfigured Games] (http://mikemaximus.github.io/gbm-web/GBM_Official.xml) <br /> <br />
|
||||||
|
Updates regarding this project are available via the [Game Backup Monitor web site] (http://mikemaximus.github.io/gbm-web/).
|
||||||
|
|||||||
Reference in New Issue
Block a user