20 Commits

Author SHA1 Message Date
MikeMaximus
fe6e0d9d37 Updated readme.txt for v116 2018-11-17 12:54:28 -06:00
MikeMaximus
783bf89241 Fix #171 2018-11-16 09:52:48 -06:00
MikeMaximus
21cce19c92 Added field to Add Game Wizard for #160 2018-11-15 20:19:39 -06:00
Michael J. Seiferling
c93af8821f Added memory debug, removed GC call for #170 2018-11-13 10:13:07 -06:00
Michael J. Seiferling
7dc61e76ab Store compiled regular expressions for #170 2018-11-12 11:59:07 -06:00
Michael J. Seiferling
54b624a1cb Do not force GC on Windows for #170 2018-11-09 12:17:13 -06:00
MikeMaximus
1b0f26cea1 Changes for #170 2018-11-08 11:45:22 -06:00
MikeMaximus
2e7189f047 Merge pull request #169 from MikeMaximus/v116
V116
2018-10-30 09:50:43 -06:00
Michael J. Seiferling
5a6b7fe2c5 Fix #168 2018-10-24 09:14:37 -06:00
Michael J. Seiferling
f204f6ccc6 Some fixes for backup size calculations 2018-10-17 10:32:52 -06:00
Michael J. Seiferling
9fdc35c43d Fix #166, also includes a minor form load bug fix 2018-10-15 11:11:16 -06:00
MikeMaximus
9dc409415f Changes for #160 - Pass 1 2018-10-14 11:06:14 -06:00
MikeMaximus
4e1dc101e5 Stop detection after Wine prefix detection/path conversion failures 2018-10-12 10:27:18 -06:00
MikeMaximus
87f8840b72 Handle default wine prefix for path conversions 2018-10-12 10:18:17 -06:00
MikeMaximus
c7565f5487 Fixed folder size calculations when using sub-folders and wildcards 2018-10-12 09:35:50 -06:00
MikeMaximus
ffe34d29e7 Fix #162 2018-10-12 09:18:15 -06:00
MikeMaximus
4b201fb60e Merge pull request #165 from basxto/v116
The codes changes look fine.  I'll merge and give it some testing.
2018-10-11 14:36:43 -06:00
Sebastian Riedel
02a4a72409 Fix #164, allow paths in include list 2018-10-11 20:57:41 +02:00
MikeMaximus
376c1ad418 Added PROGRAMDATA to reserved list for #163 2018-10-11 08:44:41 -06:00
MikeMaximus
b7ebc41ba9 Added %PROGRAMDATA% support for #163 2018-10-10 23:34:05 -06:00
23 changed files with 382 additions and 124 deletions
+10
View File
@@ -13,6 +13,7 @@
Private bMonitorOnly As Boolean Private bMonitorOnly As Boolean
Private sComments As String Private sComments As String
Private bIsRegEx As Boolean Private bIsRegEx As Boolean
Private bRecurseSubFolders As Boolean
Private oTags As List(Of Tag) Private oTags As List(Of Tag)
Property ID As String Property ID As String
@@ -141,6 +142,15 @@
End Get End Get
End Property End Property
Property RecurseSubFolders As Boolean
Set(value As Boolean)
bRecurseSubFolders = value
End Set
Get
Return bRecurseSubFolders
End Get
End Property
Property Tags As List(Of Tag) Property Tags As List(Of Tag)
Get Get
Return oTags Return oTags
+29 -1
View File
@@ -1,4 +1,6 @@
<Serializable()> Imports System.Text.RegularExpressions
<Serializable()>
Public Class clsGame Public Class clsGame
Private sGameID As String = Guid.NewGuid.ToString Private sGameID As String = Guid.NewGuid.ToString
Private sGameName As String = String.Empty Private sGameName As String = String.Empty
@@ -21,8 +23,10 @@ Public Class clsGame
Private bMonitorOnly As Boolean = False Private bMonitorOnly As Boolean = False
Private sComments As String = String.Empty Private sComments As String = String.Empty
Private bIsRegEx As Boolean = False Private bIsRegEx As Boolean = False
Private bRecurseSubFolders As Boolean = True
Private oImportTags As New List(Of Tag) Private oImportTags As New List(Of Tag)
Private bImportUpdate As Boolean = False Private bImportUpdate As Boolean = False
Private oCompiledRegEx As Regex
<Flags()> Public Enum eOptionalSyncFields <Flags()> Public Enum eOptionalSyncFields
None = 0 None = 0
@@ -241,6 +245,15 @@ Public Class clsGame
End Set End Set
End Property End Property
Property RecurseSubFolders As Boolean
Get
Return bRecurseSubFolders
End Get
Set(value As Boolean)
bRecurseSubFolders = value
End Set
End Property
Property TruePath As String Property TruePath As String
Set(value As String) Set(value As String)
sPath = value sPath = value
@@ -268,6 +281,15 @@ Public Class clsGame
End Set End Set
End Property End Property
Property CompiledRegEx As Regex
Get
Return oCompiledRegEx
End Get
Set(value As Regex)
oCompiledRegEx = value
End Set
End Property
ReadOnly Property IncludeArray As String() ReadOnly Property IncludeArray As String()
Get Get
If FileType = String.Empty Then If FileType = String.Empty Then
@@ -342,6 +364,9 @@ Public Class clsGame
If IsRegEx <> oGame.IsRegEx Then If IsRegEx <> oGame.IsRegEx Then
Return False Return False
End If End If
If RecurseSubFolders <> oGame.RecurseSubFolders Then
Return False
End If
'Optional Sync Fields 'Optional Sync Fields
If (eSyncFields And eOptionalSyncFields.Company) = eOptionalSyncFields.Company Then If (eSyncFields And eOptionalSyncFields.Company) = eOptionalSyncFields.Company Then
@@ -418,6 +443,9 @@ Public Class clsGame
If IsRegEx <> oGame.IsRegEx Then If IsRegEx <> oGame.IsRegEx Then
Return False Return False
End If End If
If RecurseSubFolders <> oGame.RecurseSubFolders Then
Return False
End If
Return True Return True
End If End If
End Function End Function
+14
View File
@@ -68,6 +68,7 @@ Partial Class frmAddWizard
Me.btnCancel = New System.Windows.Forms.Button() Me.btnCancel = New System.Windows.Forms.Button()
Me.btnNext = New System.Windows.Forms.Button() Me.btnNext = New System.Windows.Forms.Button()
Me.btnBack = New System.Windows.Forms.Button() Me.btnBack = New System.Windows.Forms.Button()
Me.chkRecurseSubFolders = New System.Windows.Forms.CheckBox()
Me.tabWizard.SuspendLayout() Me.tabWizard.SuspendLayout()
Me.tbPage1.SuspendLayout() Me.tbPage1.SuspendLayout()
Me.tbPage2.SuspendLayout() Me.tbPage2.SuspendLayout()
@@ -310,6 +311,7 @@ Partial Class frmAddWizard
'tbPage3a 'tbPage3a
' '
Me.tbPage3a.BackColor = System.Drawing.SystemColors.Control Me.tbPage3a.BackColor = System.Drawing.SystemColors.Control
Me.tbPage3a.Controls.Add(Me.chkRecurseSubFolders)
Me.tbPage3a.Controls.Add(Me.lblIncludePathTitle) Me.tbPage3a.Controls.Add(Me.lblIncludePathTitle)
Me.tbPage3a.Controls.Add(Me.lblIncludePath) Me.tbPage3a.Controls.Add(Me.lblIncludePath)
Me.tbPage3a.Controls.Add(Me.lblFileTypes) Me.tbPage3a.Controls.Add(Me.lblFileTypes)
@@ -540,6 +542,17 @@ Partial Class frmAddWizard
Me.btnBack.Text = "&Back" Me.btnBack.Text = "&Back"
Me.btnBack.UseVisualStyleBackColor = True Me.btnBack.UseVisualStyleBackColor = True
' '
'chkRecurseSubFolders
'
Me.chkRecurseSubFolders.AutoSize = True
Me.chkRecurseSubFolders.Location = New System.Drawing.Point(218, 40)
Me.chkRecurseSubFolders.Name = "chkRecurseSubFolders"
Me.chkRecurseSubFolders.Size = New System.Drawing.Size(15, 14)
Me.chkRecurseSubFolders.TabIndex = 0
Me.chkRecurseSubFolders.TabStop = False
Me.chkRecurseSubFolders.UseVisualStyleBackColor = True
Me.chkRecurseSubFolders.Visible = False
'
'frmAddWizard 'frmAddWizard
' '
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
@@ -618,4 +631,5 @@ Partial Class frmAddWizard
Friend WithEvents lblExcludePathTitle As Label Friend WithEvents lblExcludePathTitle As Label
Friend WithEvents lblLimit As Label Friend WithEvents lblLimit As Label
Friend WithEvents nudLimit As NumericUpDown Friend WithEvents nudLimit As NumericUpDown
Friend WithEvents chkRecurseSubFolders As CheckBox
End Class End Class
+5 -2
View File
@@ -66,6 +66,7 @@ Public Class frmAddWizard
chkFolderSave.Checked = True chkFolderSave.Checked = True
chkTimeStamp.Checked = False chkTimeStamp.Checked = False
chkRecurseSubFolders.Checked = True
StepHandler() StepHandler()
End Sub End Sub
@@ -112,6 +113,7 @@ Public Class frmAddWizard
Dim iLimit As Integer = nudLimit.Value Dim iLimit As Integer = nudLimit.Value
Dim sFileType As String = txtFileTypes.Text Dim sFileType As String = txtFileTypes.Text
Dim sExcludeList As String = txtExcludeList.Text Dim sExcludeList As String = txtExcludeList.Text
Dim bRecurseSubFolders As Boolean = chkRecurseSubFolders.Checked
Dim sProcess As String Dim sProcess As String
Dim sItem As String() Dim sItem As String()
Dim sItems As String() Dim sItems As String()
@@ -160,6 +162,7 @@ Public Class frmAddWizard
oGame.BackupLimit = iLimit oGame.BackupLimit = iLimit
oGame.ExcludeList = sExcludeList oGame.ExcludeList = sExcludeList
oGame.ProcessPath = sProcessPath oGame.ProcessPath = sProcessPath
oGame.RecurseSubFolders = bRecurseSubFolders
Return oGame Return oGame
End Function End Function
@@ -452,9 +455,9 @@ Public Class frmAddWizard
frm.FormName = sFormText frm.FormName = sFormText
frm.BuilderString = txtBox.Text frm.BuilderString = txtBox.Text
frm.RootFolder = txtSavePath.Text frm.RootFolder = txtSavePath.Text
frm.RecurseSubFolders = chkRecurseSubFolders.Checked
frm.ShowDialog() frm.ShowDialog()
chkRecurseSubFolders.Checked = frm.RecurseSubFolders
txtBox.Text = frm.BuilderString txtBox.Text = frm.BuilderString
End Sub End Sub
+8
View File
@@ -202,6 +202,14 @@ Public Class frmFilter
oField.Status = clsGameFilterField.eFieldStatus.ValidFilter oField.Status = clsGameFilterField.eFieldStatus.ValidFilter
oValidFields.Add(oField) oValidFields.Add(oField)
'Include Sub Folders
oField = New clsGameFilterField
oField.FieldName = "RecurseSubFolders"
oField.FriendlyFieldName = frmFilter_FieldRecurseSubFolders
oField.Type = clsGameFilterField.eDataType.fBool
oField.Status = clsGameFilterField.eFieldStatus.ValidFilter
oValidFields.Add(oField)
'Delete Folder on Restore 'Delete Folder on Restore
oField = New clsGameFilterField oField = New clsGameFilterField
oField.FieldName = "CleanFolder" oField.FieldName = "CleanFolder"
+16 -2
View File
@@ -107,6 +107,7 @@ Partial Class frmGameManager
Me.cmsDeleteAll = New System.Windows.Forms.ToolStripMenuItem() Me.cmsDeleteAll = New System.Windows.Forms.ToolStripMenuItem()
Me.btnProcesses = New System.Windows.Forms.Button() Me.btnProcesses = New System.Windows.Forms.Button()
Me.ttFullPath = New System.Windows.Forms.ToolTip(Me.components) Me.ttFullPath = New System.Windows.Forms.ToolTip(Me.components)
Me.chkRecurseSubFolders = New System.Windows.Forms.CheckBox()
Me.grpConfig.SuspendLayout() Me.grpConfig.SuspendLayout()
CType(Me.nudLimit, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.nudLimit, System.ComponentModel.ISupportInitialize).BeginInit()
Me.grpExtra.SuspendLayout() Me.grpExtra.SuspendLayout()
@@ -163,6 +164,7 @@ Partial Class frmGameManager
'grpConfig 'grpConfig
' '
Me.grpConfig.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles) Me.grpConfig.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.grpConfig.Controls.Add(Me.chkRecurseSubFolders)
Me.grpConfig.Controls.Add(Me.btnGameID) Me.grpConfig.Controls.Add(Me.btnGameID)
Me.grpConfig.Controls.Add(Me.chkRegEx) Me.grpConfig.Controls.Add(Me.chkRegEx)
Me.grpConfig.Controls.Add(Me.lblComments) Me.grpConfig.Controls.Add(Me.lblComments)
@@ -860,13 +862,13 @@ Partial Class frmGameManager
'cmsOfficialWindows 'cmsOfficialWindows
' '
Me.cmsOfficialWindows.Name = "cmsOfficialWindows" Me.cmsOfficialWindows.Name = "cmsOfficialWindows"
Me.cmsOfficialWindows.Size = New System.Drawing.Size(180, 22) Me.cmsOfficialWindows.Size = New System.Drawing.Size(132, 22)
Me.cmsOfficialWindows.Text = "&Windows..." Me.cmsOfficialWindows.Text = "&Windows..."
' '
'cmsOfficialLinux 'cmsOfficialLinux
' '
Me.cmsOfficialLinux.Name = "cmsOfficialLinux" Me.cmsOfficialLinux.Name = "cmsOfficialLinux"
Me.cmsOfficialLinux.Size = New System.Drawing.Size(180, 22) Me.cmsOfficialLinux.Size = New System.Drawing.Size(132, 22)
Me.cmsOfficialLinux.Text = "&Linux..." Me.cmsOfficialLinux.Text = "&Linux..."
' '
'cmsFile 'cmsFile
@@ -925,6 +927,17 @@ Partial Class frmGameManager
Me.ttFullPath.InitialDelay = 300 Me.ttFullPath.InitialDelay = 300
Me.ttFullPath.ReshowDelay = 60 Me.ttFullPath.ReshowDelay = 60
' '
'chkRecurseSubFolders
'
Me.chkRecurseSubFolders.AutoSize = True
Me.chkRecurseSubFolders.Location = New System.Drawing.Point(489, 206)
Me.chkRecurseSubFolders.Name = "chkRecurseSubFolders"
Me.chkRecurseSubFolders.Size = New System.Drawing.Size(15, 14)
Me.chkRecurseSubFolders.TabIndex = 0
Me.chkRecurseSubFolders.TabStop = False
Me.chkRecurseSubFolders.UseVisualStyleBackColor = True
Me.chkRecurseSubFolders.Visible = False
'
'frmGameManager 'frmGameManager
' '
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
@@ -1059,4 +1072,5 @@ Partial Class frmGameManager
Friend WithEvents btnImportBackup As Button Friend WithEvents btnImportBackup As Button
Friend WithEvents cmsOfficialWindows As ToolStripMenuItem Friend WithEvents cmsOfficialWindows As ToolStripMenuItem
Friend WithEvents cmsOfficialLinux As ToolStripMenuItem Friend WithEvents cmsOfficialLinux As ToolStripMenuItem
Friend WithEvents chkRecurseSubFolders As CheckBox
End Class End Class
+36 -3
View File
@@ -8,6 +8,7 @@ Public Class frmGameManager
Private sBackupFolder As String Private sBackupFolder As String
Private bPendingRestores As Boolean = False Private bPendingRestores As Boolean = False
Private oCurrentBackupItem As clsBackup Private oCurrentBackupItem As clsBackup
Private oLastPlayedGame As clsGame
Private oCurrentGame As clsGame Private oCurrentGame As clsGame
Private oTagsToSave As New List(Of KeyValuePair(Of String, String)) Private oTagsToSave As New List(Of KeyValuePair(Of String, String))
Private oProcessesToSave As New List(Of KeyValuePair(Of String, String)) Private oProcessesToSave As New List(Of KeyValuePair(Of String, String))
@@ -69,6 +70,15 @@ Public Class frmGameManager
End Set End Set
End Property End Property
Property LastPlayedGame As clsGame
Get
Return oLastPlayedGame
End Get
Set(value As clsGame)
oLastPlayedGame = value
End Set
End Property
Property CurrentGame As clsGame Property CurrentGame As clsGame
Get Get
Return oCurrentGame Return oCurrentGame
@@ -585,10 +595,11 @@ Public Class frmGameManager
frm.FormName = sFormText frm.FormName = sFormText
frm.BuilderString = txtBox.Text frm.BuilderString = txtBox.Text
frm.RootFolder = GetBuilderRoot() frm.RootFolder = GetBuilderRoot()
frm.RecurseSubFolders = chkRecurseSubFolders.Checked
frm.ShowDialog() frm.ShowDialog()
txtBox.Text = frm.BuilderString txtBox.Text = frm.BuilderString
chkRecurseSubFolders.Checked = frm.RecurseSubFolders
VerifyCleanFolder() VerifyCleanFolder()
End Sub End Sub
@@ -923,6 +934,7 @@ Public Class frmGameManager
txtFileType.Text = oApp.FileType txtFileType.Text = oApp.FileType
txtExclude.Text = oApp.ExcludeList txtExclude.Text = oApp.ExcludeList
chkFolderSave.Checked = oApp.FolderSave chkFolderSave.Checked = oApp.FolderSave
chkRecurseSubFolders.Checked = oApp.RecurseSubFolders
chkCleanFolder.Checked = oApp.CleanFolder chkCleanFolder.Checked = oApp.CleanFolder
chkTimeStamp.Checked = oApp.AppendTimeStamp chkTimeStamp.Checked = oApp.AppendTimeStamp
nudLimit.Value = oApp.BackupLimit nudLimit.Value = oApp.BackupLimit
@@ -1062,6 +1074,7 @@ Public Class frmGameManager
btnOpenRestorePath.Enabled = False btnOpenRestorePath.Enabled = False
chkEnabled.Checked = True chkEnabled.Checked = True
chkMonitorOnly.Checked = False chkMonitorOnly.Checked = False
chkRecurseSubFolders.Checked = True
btnTags.Enabled = True btnTags.Enabled = True
btnProcesses.Enabled = True btnProcesses.Enabled = True
lblTags.Text = String.Empty lblTags.Text = String.Empty
@@ -1218,7 +1231,6 @@ Public Class frmGameManager
btnInclude.Enabled = True btnInclude.Enabled = True
btnExclude.Enabled = True btnExclude.Enabled = True
FolderSaveModeChange() FolderSaveModeChange()
VerifyCleanFolder()
End If End If
End Sub End Sub
@@ -1234,6 +1246,16 @@ Public Class frmGameManager
End If End If
End Sub End Sub
Private Sub VerifyImportBackup()
If Not bIsLoading Then
If chkMonitorOnly.Checked Then
btnImportBackup.Enabled = False
Else
btnImportBackup.Enabled = True
End If
End If
End Sub
Private Sub VerifyCleanFolder() Private Sub VerifyCleanFolder()
If Not bIsLoading Then If Not bIsLoading Then
If (chkFolderSave.Checked = True And txtExclude.Text = String.Empty And txtSavePath.Text <> String.Empty) And Not chkMonitorOnly.Checked Then If (chkFolderSave.Checked = True And txtExclude.Text = String.Empty And txtSavePath.Text <> String.Empty) And Not chkMonitorOnly.Checked Then
@@ -1348,6 +1370,7 @@ Public Class frmGameManager
oApp.FileType = txtFileType.Text oApp.FileType = txtFileType.Text
oApp.ExcludeList = txtExclude.Text oApp.ExcludeList = txtExclude.Text
oApp.FolderSave = chkFolderSave.Checked oApp.FolderSave = chkFolderSave.Checked
oApp.RecurseSubFolders = chkRecurseSubFolders.Checked
oApp.CleanFolder = chkCleanFolder.Checked oApp.CleanFolder = chkCleanFolder.Checked
oApp.AppendTimeStamp = chkTimeStamp.Checked oApp.AppendTimeStamp = chkTimeStamp.Checked
oApp.BackupLimit = nudLimit.Value oApp.BackupLimit = nudLimit.Value
@@ -1448,6 +1471,7 @@ Public Class frmGameManager
FillData() FillData()
ModeChange() ModeChange()
VerifyCleanFolder() VerifyCleanFolder()
VerifyImportBackup()
ElseIf lstGames.SelectedItems.Count > 1 Then ElseIf lstGames.SelectedItems.Count > 1 Then
eCurrentMode = eModes.MultiSelect eCurrentMode = eModes.MultiSelect
ModeChange() ModeChange()
@@ -1805,6 +1829,7 @@ Public Class frmGameManager
tmFilterTimer = New Timer() tmFilterTimer = New Timer()
tmFilterTimer.Interval = 1000 tmFilterTimer.Interval = 1000
tmFilterTimer.Enabled = False tmFilterTimer.Enabled = False
End Sub End Sub
Private Sub frmGameManager_Load(sender As Object, e As EventArgs) Handles MyBase.Load Private Sub frmGameManager_Load(sender As Object, e As EventArgs) Handles MyBase.Load
@@ -1821,7 +1846,7 @@ Public Class frmGameManager
LoadBackupData() LoadBackupData()
'Event will take care of initial load 'Event will take care of initial load (on Windows)
If PendingRestores Then If PendingRestores Then
optPendingRestores.Checked = True optPendingRestores.Checked = True
Else Else
@@ -1833,8 +1858,11 @@ Public Class frmGameManager
AssignDirtyHandlers(grpStats.Controls) AssignDirtyHandlers(grpStats.Controls)
AssignDirtyHandlersMisc() AssignDirtyHandlersMisc()
'Mono doesn't fire events in the same way as .NET, so we'll to do this to get an initial load on Linux and prevent multiple loads in Windows.
If mgrCommon.IsUnix Then
LoadData(False) LoadData(False)
ModeChange() ModeChange()
End If
End Sub End Sub
Private Sub lstGames_SelectedIndexChanged(sender As Object, e As EventArgs) Handles lstGames.SelectedIndexChanged Private Sub lstGames_SelectedIndexChanged(sender As Object, e As EventArgs) Handles lstGames.SelectedIndexChanged
@@ -2038,6 +2066,11 @@ Public Class frmGameManager
End Sub End Sub
Private Sub frmGameManager_Shown(sender As Object, e As EventArgs) Handles MyBase.Shown Private Sub frmGameManager_Shown(sender As Object, e As EventArgs) Handles MyBase.Shown
'Load Last Played Game
If Not LastPlayedGame Is Nothing Then
lstGames.SelectedItem = New KeyValuePair(Of String, String)(LastPlayedGame.ID, LastPlayedGame.Name)
End If
txtQuickFilter.Focus() txtQuickFilter.Focus()
End Sub End Sub
+28 -14
View File
@@ -37,15 +37,16 @@ Partial Class frmIncludeExclude
Me.cmsAdd = New System.Windows.Forms.ToolStripMenuItem() Me.cmsAdd = New System.Windows.Forms.ToolStripMenuItem()
Me.btnRemove = New System.Windows.Forms.Button() Me.btnRemove = New System.Windows.Forms.Button()
Me.btnAdd = New System.Windows.Forms.Button() Me.btnAdd = New System.Windows.Forms.Button()
Me.grpFileOptions = New System.Windows.Forms.GroupBox() Me.grpOptions = New System.Windows.Forms.GroupBox()
Me.optFileTypes = New System.Windows.Forms.RadioButton() Me.optFileTypes = New System.Windows.Forms.RadioButton()
Me.optIndividualFiles = New System.Windows.Forms.RadioButton() Me.optIndividualFiles = New System.Windows.Forms.RadioButton()
Me.lblItems = New System.Windows.Forms.Label() Me.lblItems = New System.Windows.Forms.Label()
Me.btnRawEdit = New System.Windows.Forms.Button() Me.btnRawEdit = New System.Windows.Forms.Button()
Me.lblSaveFolder = New System.Windows.Forms.Label() Me.lblSaveFolder = New System.Windows.Forms.Label()
Me.ttWarning = New System.Windows.Forms.ToolTip(Me.components) Me.ttWarning = New System.Windows.Forms.ToolTip(Me.components)
Me.chkRecurseSubFolders = New System.Windows.Forms.CheckBox()
Me.cmsItems.SuspendLayout() Me.cmsItems.SuspendLayout()
Me.grpFileOptions.SuspendLayout() Me.grpOptions.SuspendLayout()
Me.SuspendLayout() Me.SuspendLayout()
' '
'treFiles 'treFiles
@@ -157,16 +158,17 @@ Partial Class frmIncludeExclude
Me.btnAdd.Text = ">" Me.btnAdd.Text = ">"
Me.btnAdd.UseVisualStyleBackColor = True Me.btnAdd.UseVisualStyleBackColor = True
' '
'grpFileOptions 'grpOptions
' '
Me.grpFileOptions.Controls.Add(Me.optFileTypes) Me.grpOptions.Controls.Add(Me.chkRecurseSubFolders)
Me.grpFileOptions.Controls.Add(Me.optIndividualFiles) Me.grpOptions.Controls.Add(Me.optFileTypes)
Me.grpFileOptions.Location = New System.Drawing.Point(12, 403) Me.grpOptions.Controls.Add(Me.optIndividualFiles)
Me.grpFileOptions.Name = "grpFileOptions" Me.grpOptions.Location = New System.Drawing.Point(12, 403)
Me.grpFileOptions.Size = New System.Drawing.Size(194, 46) Me.grpOptions.Name = "grpOptions"
Me.grpFileOptions.TabIndex = 2 Me.grpOptions.Size = New System.Drawing.Size(317, 46)
Me.grpFileOptions.TabStop = False Me.grpOptions.TabIndex = 2
Me.grpFileOptions.Text = "File Options" Me.grpOptions.TabStop = False
Me.grpOptions.Text = "Options"
' '
'optFileTypes 'optFileTypes
' '
@@ -222,6 +224,16 @@ Partial Class frmIncludeExclude
Me.ttWarning.ReshowDelay = 50 Me.ttWarning.ReshowDelay = 50
Me.ttWarning.ToolTipIcon = System.Windows.Forms.ToolTipIcon.Warning Me.ttWarning.ToolTipIcon = System.Windows.Forms.ToolTipIcon.Warning
' '
'chkRecurseSubFolders
'
Me.chkRecurseSubFolders.AutoSize = True
Me.chkRecurseSubFolders.Location = New System.Drawing.Point(185, 20)
Me.chkRecurseSubFolders.Name = "chkRecurseSubFolders"
Me.chkRecurseSubFolders.Size = New System.Drawing.Size(120, 17)
Me.chkRecurseSubFolders.TabIndex = 2
Me.chkRecurseSubFolders.Text = "Recurse sub-folders"
Me.chkRecurseSubFolders.UseVisualStyleBackColor = True
'
'frmIncludeExclude 'frmIncludeExclude
' '
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
@@ -230,7 +242,7 @@ Partial Class frmIncludeExclude
Me.Controls.Add(Me.lblSaveFolder) Me.Controls.Add(Me.lblSaveFolder)
Me.Controls.Add(Me.btnRawEdit) Me.Controls.Add(Me.btnRawEdit)
Me.Controls.Add(Me.lblItems) Me.Controls.Add(Me.lblItems)
Me.Controls.Add(Me.grpFileOptions) Me.Controls.Add(Me.grpOptions)
Me.Controls.Add(Me.btnRemove) Me.Controls.Add(Me.btnRemove)
Me.Controls.Add(Me.btnAdd) Me.Controls.Add(Me.btnAdd)
Me.Controls.Add(Me.lstBuilder) Me.Controls.Add(Me.lstBuilder)
@@ -247,7 +259,8 @@ Partial Class frmIncludeExclude
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
Me.Text = "Include / Exclude Builder" Me.Text = "Include / Exclude Builder"
Me.cmsItems.ResumeLayout(False) Me.cmsItems.ResumeLayout(False)
Me.grpFileOptions.ResumeLayout(False) Me.grpOptions.ResumeLayout(False)
Me.grpOptions.PerformLayout()
Me.ResumeLayout(False) Me.ResumeLayout(False)
Me.PerformLayout() Me.PerformLayout()
@@ -261,7 +274,7 @@ Partial Class frmIncludeExclude
Friend WithEvents lstBuilder As System.Windows.Forms.ListView Friend WithEvents lstBuilder As System.Windows.Forms.ListView
Friend WithEvents btnRemove As System.Windows.Forms.Button Friend WithEvents btnRemove As System.Windows.Forms.Button
Friend WithEvents btnAdd As System.Windows.Forms.Button Friend WithEvents btnAdd As System.Windows.Forms.Button
Friend WithEvents grpFileOptions As System.Windows.Forms.GroupBox Friend WithEvents grpOptions As System.Windows.Forms.GroupBox
Friend WithEvents optFileTypes As System.Windows.Forms.RadioButton Friend WithEvents optFileTypes As System.Windows.Forms.RadioButton
Friend WithEvents optIndividualFiles As System.Windows.Forms.RadioButton Friend WithEvents optIndividualFiles As System.Windows.Forms.RadioButton
Friend WithEvents lblItems As System.Windows.Forms.Label Friend WithEvents lblItems As System.Windows.Forms.Label
@@ -272,4 +285,5 @@ Partial Class frmIncludeExclude
Friend WithEvents btnRawEdit As Button Friend WithEvents btnRawEdit As Button
Friend WithEvents lblSaveFolder As Label Friend WithEvents lblSaveFolder As Label
Friend WithEvents ttWarning As ToolTip Friend WithEvents ttWarning As ToolTip
Friend WithEvents chkRecurseSubFolders As CheckBox
End Class End Class
+1 -1
View File
@@ -125,7 +125,7 @@
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0 LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAB6 ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAB6
CQAAAk1TRnQBSQFMAgEBAwEAAbgBAAG4AQABEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo CQAAAk1TRnQBSQFMAgEBAwEAAcABAAHAAQABEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
AwABQAMAARADAAEBAQABCAYAAQQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA AwABQAMAARADAAEBAQABCAYAAQQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5 AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
+14 -1
View File
@@ -6,6 +6,7 @@ Public Class frmIncludeExclude
Dim sFormName As String = String.Empty Dim sFormName As String = String.Empty
Dim sRootFolder As String = String.Empty Dim sRootFolder As String = String.Empty
Dim sBuilderString As String Dim sBuilderString As String
Dim bRecurseSubFolders As Boolean
Public Property BuilderString As String Public Property BuilderString As String
Get Get
@@ -34,6 +35,15 @@ Public Class frmIncludeExclude
End Set End Set
End Property End Property
Public Property RecurseSubFolders As Boolean
Get
Return bRecurseSubFolders
End Get
Set(value As Boolean)
bRecurseSubFolders = value
End Set
End Property
Private Sub BuildBranch(ByVal sDirectory As String, ByVal oNode As TreeNode) Private Sub BuildBranch(ByVal sDirectory As String, ByVal oNode As TreeNode)
Dim sFolders As String() Dim sFolders As String()
Dim sFiles As String() Dim sFiles As String()
@@ -239,9 +249,10 @@ Public Class frmIncludeExclude
lblSaveFolder.Text = frmIncludeExclude_lblSaveFolder lblSaveFolder.Text = frmIncludeExclude_lblSaveFolder
btnRawEdit.Text = frmIncludeExclude_btnRawEdit btnRawEdit.Text = frmIncludeExclude_btnRawEdit
lblItems.Text = mgrCommon.FormatString(frmIncludeExclude_lblItems, FormName) lblItems.Text = mgrCommon.FormatString(frmIncludeExclude_lblItems, FormName)
grpFileOptions.Text = mgrCommon.FormatString(frmIncludeExclude_grpFileOptions, FormName) grpOptions.Text = mgrCommon.FormatString(frmIncludeExclude_grpOptions, FormName)
optFileTypes.Text = frmIncludeExclude_optFileTypes optFileTypes.Text = frmIncludeExclude_optFileTypes
optIndividualFiles.Text = frmIncludeExclude_optIndividualFiles optIndividualFiles.Text = frmIncludeExclude_optIndividualFiles
chkRecurseSubFolders.Text = frmIncludeExclude_chkRecurseSubFolders
btnRemove.Text = frmIncludeExclude_btnRemove btnRemove.Text = frmIncludeExclude_btnRemove
btnAdd.Text = frmIncludeExclude_btnAdd btnAdd.Text = frmIncludeExclude_btnAdd
btnBrowse.Text = frmIncludeExclude_btnBrowse btnBrowse.Text = frmIncludeExclude_btnBrowse
@@ -254,6 +265,7 @@ Public Class frmIncludeExclude
'Set Defaults 'Set Defaults
txtRootFolder.Text = RootFolder txtRootFolder.Text = RootFolder
optFileTypes.Checked = True optFileTypes.Checked = True
chkRecurseSubFolders.Checked = bRecurseSubFolders
If BuilderString <> String.Empty Then ParseBuilderString(BuilderString) If BuilderString <> String.Empty Then ParseBuilderString(BuilderString)
If txtRootFolder.Text <> String.Empty Then BuildTrunk() If txtRootFolder.Text <> String.Empty Then BuildTrunk()
End Sub End Sub
@@ -285,6 +297,7 @@ Public Class frmIncludeExclude
Private Sub btnSave_Click(sender As Object, e As EventArgs) Handles btnSave.Click Private Sub btnSave_Click(sender As Object, e As EventArgs) Handles btnSave.Click
BuilderString = CreateNewBuilderString() BuilderString = CreateNewBuilderString()
RecurseSubFolders = chkRecurseSubFolders.Checked
Me.Close() Me.Close()
End Sub End Sub
+18 -1
View File
@@ -45,6 +45,7 @@ Public Class frmMain
'Developer Debug Flags 'Developer Debug Flags
Private bProcessDebugMode As Boolean = False Private bProcessDebugMode As Boolean = False
Private bMemoryDebugMode As Boolean = False
WithEvents oFileWatcher As New FileSystemWatcher WithEvents oFileWatcher As New FileSystemWatcher
@@ -842,6 +843,11 @@ Public Class frmMain
Case "process" Case "process"
bProcessDebugMode = bDebugEnable bProcessDebugMode = bDebugEnable
mgrCommon.ShowMessage(frmMain_CommandSucess, MsgBoxStyle.Exclamation) mgrCommon.ShowMessage(frmMain_CommandSucess, MsgBoxStyle.Exclamation)
Case "memory"
bMemoryDebugMode = bDebugEnable
mgrCommon.ShowMessage(frmMain_CommandSucess, MsgBoxStyle.Exclamation)
Case Else
mgrCommon.ShowMessage(frmMain_ErrorInvalidMode, New String() {sCommand(1), sCommand(0)}, MsgBoxStyle.Exclamation)
End Select End Select
Case Else Case Else
@@ -882,6 +888,7 @@ Public Class frmMain
PauseScan() PauseScan()
frm.Settings = oSettings frm.Settings = oSettings
frm.PendingRestores = bPendingRestores frm.PendingRestores = bPendingRestores
frm.LastPlayedGame = oProcess.GameInfo
frm.ShowDialog() frm.ShowDialog()
LoadGameSettings() LoadGameSettings()
ResumeScan() ResumeScan()
@@ -1938,9 +1945,15 @@ Public Class frmMain
oProcess.GameInfo.TruePath = sWineSavePath oProcess.GameInfo.TruePath = sWineSavePath
oProcess.GameInfo.AbsolutePath = True oProcess.GameInfo.AbsolutePath = True
UpdateLog(mgrCommon.FormatString(frmMain_WineSavePath, New String() {oProcess.GameInfo.Name, sWineSavePath}), False) UpdateLog(mgrCommon.FormatString(frmMain_WineSavePath, New String() {oProcess.GameInfo.Name, sWineSavePath}), False)
Else
bContinue = False
End If
Else
bContinue = False
End If End If
End If End If
End If 'This does required mods to include/exclude data and relative paths (if required)
mgrPath.ModWinePathData(oProcess.GameInfo)
End If End If
If bContinue = True Then If bContinue = True Then
@@ -1964,6 +1977,10 @@ Public Class frmMain
StopScan() StopScan()
End If End If
End If End If
If bMemoryDebugMode Then
UpdateLog(mgrCommon.FormatString(frmMain_DebugMemoryAllocation, Math.Round(GC.GetTotalMemory(False) / 1000000, 2)), False, ToolTipIcon.Info, True)
End If
End Sub End Sub
Private Sub bwMonitor_DoWork(sender As System.Object, e As System.ComponentModel.DoWorkEventArgs) Handles bwMonitor.DoWork Private Sub bwMonitor_DoWork(sender As System.Object, e As System.ComponentModel.DoWorkEventArgs) Handles bwMonitor.DoWork
+26 -8
View File
@@ -66,7 +66,7 @@ Public Class mgrBackup
Return True Return True
End Function End Function
Private Sub BuildFileList(ByVal sBackupPath As String, ByVal sList As String, ByVal sPath As String) Private Sub BuildFileList(ByVal sList As String, ByVal sPath As String)
Dim oStream As StreamWriter Dim oStream As StreamWriter
Try Try
@@ -75,7 +75,7 @@ Public Class mgrBackup
Using oStream Using oStream
If sList <> String.Empty Then If sList <> String.Empty Then
For Each sTypeItem As String In sList.Split(":") For Each sTypeItem As String In sList.Split(":")
oStream.WriteLine("""" & sBackupPath & Path.DirectorySeparatorChar & sTypeItem & """") oStream.WriteLine("""" & sTypeItem & """")
Next Next
End If End If
oStream.Flush() oStream.Flush()
@@ -118,7 +118,8 @@ Public Class mgrBackup
Dim sSavePath As String Dim sSavePath As String
Dim sOverwriteMessage As String Dim sOverwriteMessage As String
Dim lAvailableSpace As Long Dim lAvailableSpace As Long
Dim lFolderSize As Long Dim lFolderSize As Long = 0
Dim sDeepFolder As String
If oSettings.CreateSubFolder Then sBackupFile = sBackupFile & Path.DirectorySeparatorChar & GetFileName(oGame) If oSettings.CreateSubFolder Then sBackupFile = sBackupFile & Path.DirectorySeparatorChar & GetFileName(oGame)
sBackupFile = sBackupFile & Path.DirectorySeparatorChar & GetFileName(oGame) & ".7z" sBackupFile = sBackupFile & Path.DirectorySeparatorChar & GetFileName(oGame) & ".7z"
@@ -128,7 +129,18 @@ Public Class mgrBackup
'Calculate space 'Calculate space
lAvailableSpace = mgrCommon.GetAvailableDiskSpace(oSettings.BackupFolder) lAvailableSpace = mgrCommon.GetAvailableDiskSpace(oSettings.BackupFolder)
lFolderSize = mgrCommon.GetFolderSize(sSavePath, oGame.IncludeArray, oGame.ExcludeArray) 'If any includes are using a deep path and we aren't using recursion, we need to go directly to folders to do file size calculations or they will be missed.
If Not oGame.RecurseSubFolders Then
For Each s As String In oGame.IncludeArray
If s.Contains(Path.DirectorySeparatorChar) Then
sDeepFolder = Path.GetDirectoryName(sSavePath & Path.DirectorySeparatorChar & s)
If Directory.Exists(sDeepFolder) Then
lFolderSize += mgrCommon.GetFolderSize(sDeepFolder, oGame.IncludeArray, oGame.ExcludeArray, oGame.RecurseSubFolders)
End If
End If
Next
End If
lFolderSize += mgrCommon.GetFolderSize(sSavePath, oGame.IncludeArray, oGame.ExcludeArray, oGame.RecurseSubFolders)
'Show Available Space 'Show Available Space
RaiseEvent UpdateLog(mgrCommon.FormatString(mgrCommon_AvailableDiskSpace, mgrCommon.FormatDiskSpace(lAvailableSpace)), False, ToolTipIcon.Info, True) RaiseEvent UpdateLog(mgrCommon.FormatString(mgrCommon_AvailableDiskSpace, mgrCommon.FormatDiskSpace(lAvailableSpace)), False, ToolTipIcon.Info, True)
@@ -283,6 +295,7 @@ Public Class mgrBackup
Dim dTimeStamp As DateTime Dim dTimeStamp As DateTime
Dim sTimeStamp As String Dim sTimeStamp As String
Dim sHash As String Dim sHash As String
Dim sArguments As String
For Each oGame In oBackupList For Each oGame In oBackupList
'Init 'Init
@@ -314,12 +327,16 @@ Public Class mgrBackup
sSavePath = VerifySavePath(oGame) sSavePath = VerifySavePath(oGame)
If oGame.FolderSave = True Then If oGame.FolderSave = True Then
BuildFileList(sSavePath, "*", mgrPath.IncludeFileLocation) BuildFileList("*", mgrPath.IncludeFileLocation)
Else Else
BuildFileList(sSavePath, oGame.FileType, mgrPath.IncludeFileLocation) BuildFileList(oGame.FileType, mgrPath.IncludeFileLocation)
End If End If
BuildFileList(sSavePath, oGame.ExcludeList, mgrPath.ExcludeFileLocation) BuildFileList(oGame.ExcludeList, mgrPath.ExcludeFileLocation)
sArguments = "a" & oSettings.Prepared7zArguments & "-t7z -mx" & oSettings.CompressionLevel & " -i@""" & mgrPath.IncludeFileLocation & """ -x@""" & mgrPath.ExcludeFileLocation & """ """ & sBackupFile & """"
If oGame.RecurseSubFolders Then sArguments &= " -r"
Try Try
If Directory.Exists(sSavePath) Then If Directory.Exists(sSavePath) Then
@@ -330,8 +347,9 @@ Public Class mgrBackup
File.Delete(sBackupFile) File.Delete(sBackupFile)
End If End If
prs7z.StartInfo.Arguments = "a" & oSettings.Prepared7zArguments & "-t7z -mx" & oSettings.CompressionLevel & " -i@""" & mgrPath.IncludeFileLocation & """ -x@""" & mgrPath.ExcludeFileLocation & """ """ & sBackupFile & """ -r" prs7z.StartInfo.Arguments = sArguments
prs7z.StartInfo.FileName = oSettings.Utility7zLocation prs7z.StartInfo.FileName = oSettings.Utility7zLocation
prs7z.StartInfo.WorkingDirectory = sSavePath
prs7z.StartInfo.UseShellExecute = False prs7z.StartInfo.UseShellExecute = False
prs7z.StartInfo.RedirectStandardOutput = True prs7z.StartInfo.RedirectStandardOutput = True
prs7z.StartInfo.CreateNoWindow = True prs7z.StartInfo.CreateNoWindow = True
+28 -6
View File
@@ -293,8 +293,9 @@ Public Class mgrCommon
Public Shared Function WildcardToRegex(ByVal sPattern As String) As String Public Shared Function WildcardToRegex(ByVal sPattern As String) As String
Dim sRegEx As String Dim sRegEx As String
sRegEx = sPattern.Replace("*", ".*") sPattern = Regex.Escape(sPattern)
sRegEx = sRegEx.Replace("?", ".") sRegEx = sPattern.Replace("\*", ".*")
sRegEx = sRegEx.Replace("\?", ".")
Return sRegEx Return sRegEx
End Function End Function
@@ -318,7 +319,7 @@ Public Class mgrCommon
End Function End Function
'Calculate the current size of a folder 'Calculate the current size of a folder
Public Shared Function GetFolderSize(ByVal sPath As String, ByVal sInclude As String(), ByVal sExclude As String()) As Long Public Shared Function GetFolderSize(ByVal sPath As String, ByVal sInclude As String(), ByVal sExclude As String(), Optional ByVal b7zStyleRecurse As Boolean = True) As Long
Dim oFolder As DirectoryInfo Dim oFolder As DirectoryInfo
Dim bInclude As Boolean Dim bInclude As Boolean
Dim bExclude As Boolean Dim bExclude As Boolean
@@ -331,14 +332,15 @@ Public Class mgrCommon
'Files 'Files
For Each fi As FileInfo In oFolder.EnumerateFiles() For Each fi As FileInfo In oFolder.EnumerateFiles()
If sInclude.Length > 0 Then If sInclude.Length > 0 Then
bInclude = CompareValueToArrayRegEx(fi.Name, sInclude) Or CompareValueToArrayRegEx(fi.DirectoryName, sInclude) bInclude = CompareValueToArrayRegEx(fi.FullName, sInclude)
Else Else
bInclude = True bInclude = True
End If End If
If sExclude.Length > 0 Then If sExclude.Length > 0 Then
bExclude = CompareValueToArrayRegEx(fi.Name, sExclude) Or CompareValueToArrayRegEx(fi.DirectoryName, sExclude) bExclude = CompareValueToArrayRegEx(fi.FullName, sExclude)
Else Else
bExclude = False bExclude = False
End If End If
@@ -351,16 +353,36 @@ Public Class mgrCommon
'Sub Folders 'Sub Folders
For Each di As DirectoryInfo In oFolder.EnumerateDirectories() For Each di As DirectoryInfo In oFolder.EnumerateDirectories()
If Not ((di.Attributes And FileAttributes.ReparsePoint) = FileAttributes.ReparsePoint) Then If Not ((di.Attributes And FileAttributes.ReparsePoint) = FileAttributes.ReparsePoint) Then
If b7zStyleRecurse Then
If sExclude.Length > 0 Then If sExclude.Length > 0 Then
bExclude = CompareValueToArrayRegEx(di.Name, sExclude) bExclude = CompareValueToArrayRegEx(di.FullName, sExclude)
Else Else
bExclude = False bExclude = False
End If End If
If Not bExclude Then If Not bExclude Then
lSize += GetFolderSize(di.FullName, sInclude, sExclude) lSize += GetFolderSize(di.FullName, sInclude, sExclude)
End If End If
Else
If sInclude.Length > 0 Then
bInclude = CompareValueToArrayRegEx(di.FullName, sInclude)
Else
bInclude = True
End If
If sExclude.Length > 0 Then
bExclude = CompareValueToArrayRegEx(di.FullName, sExclude)
Else
bExclude = False
End If
If bInclude And Not bExclude Then
lSize += GetFolderSize(di.FullName, sInclude, sExclude)
End If
End If
End If End If
Next Next
Catch Catch
'Do Nothing 'Do Nothing
End Try End Try
+14 -5
View File
@@ -36,6 +36,12 @@ Public Class mgrMonitorList
If Not IsDBNull(dr("Parameter")) Then oGame.Parameter = CStr(dr("Parameter")) If Not IsDBNull(dr("Parameter")) Then oGame.Parameter = CStr(dr("Parameter"))
If Not IsDBNull(dr("Comments")) Then oGame.Comments = CStr(dr("Comments")) If Not IsDBNull(dr("Comments")) Then oGame.Comments = CStr(dr("Comments"))
oGame.IsRegEx = CBool(dr("IsRegEx")) oGame.IsRegEx = CBool(dr("IsRegEx"))
oGame.RecurseSubFolders = CBool(dr("RecurseSubFolders"))
'Compile RegEx
If oGame.IsRegEx Then
oGame.CompiledRegEx = New Regex(oGame.ProcessName, RegexOptions.Compiled)
End If
Return oGame Return oGame
End Function End Function
@@ -64,6 +70,7 @@ Public Class mgrMonitorList
hshParams.Add("Parameter", oGame.Parameter) hshParams.Add("Parameter", oGame.Parameter)
hshParams.Add("Comments", oGame.Comments) hshParams.Add("Comments", oGame.Comments)
hshParams.Add("IsRegEx", oGame.IsRegEx) hshParams.Add("IsRegEx", oGame.IsRegEx)
hshParams.Add("RecurseSubFolders", oGame.RecurseSubFolders)
Return hshParams Return hshParams
End Function End Function
@@ -99,7 +106,7 @@ Public Class mgrMonitorList
sSQL = "INSERT INTO monitorlist VALUES (@ID, @Name, @Process, @Path, @AbsolutePath, @FolderSave, @FileType, @TimeStamp, " sSQL = "INSERT INTO monitorlist VALUES (@ID, @Name, @Process, @Path, @AbsolutePath, @FolderSave, @FileType, @TimeStamp, "
sSQL &= "@ExcludeList, @ProcessPath, @Icon, @Hours, @Version, @Company, @Enabled, @MonitorOnly, @BackupLimit, @CleanFolder, " sSQL &= "@ExcludeList, @ProcessPath, @Icon, @Hours, @Version, @Company, @Enabled, @MonitorOnly, @BackupLimit, @CleanFolder, "
sSQL &= "@Parameter, @Comments, @IsRegEx)" sSQL &= "@Parameter, @Comments, @IsRegEx, @RecurseSubFolders)"
'Parameters 'Parameters
hshParams = SetCoreParameters(oGame) hshParams = SetCoreParameters(oGame)
@@ -116,7 +123,7 @@ Public Class mgrMonitorList
sSQL = "UPDATE monitorlist SET MonitorID=@ID, Name=@Name, Process=@Process, Path=@Path, AbsolutePath=@AbsolutePath, FolderSave=@FolderSave, " sSQL = "UPDATE monitorlist SET MonitorID=@ID, Name=@Name, Process=@Process, Path=@Path, AbsolutePath=@AbsolutePath, FolderSave=@FolderSave, "
sSQL &= "FileType=@FileType, TimeStamp=@TimeStamp, ExcludeList=@ExcludeList, ProcessPath=@ProcessPath, Icon=@Icon, " sSQL &= "FileType=@FileType, TimeStamp=@TimeStamp, ExcludeList=@ExcludeList, ProcessPath=@ProcessPath, Icon=@Icon, "
sSQL &= "Hours=@Hours, Version=@Version, Company=@Company, Enabled=@Enabled, MonitorOnly=@MonitorOnly, BackupLimit=@BackupLimit, " sSQL &= "Hours=@Hours, Version=@Version, Company=@Company, Enabled=@Enabled, MonitorOnly=@MonitorOnly, BackupLimit=@BackupLimit, "
sSQL &= "CleanFolder=@CleanFolder, Parameter=@Parameter, Comments=@Comments, IsRegEx=@IsRegEx WHERE MonitorID=@QueryID;" sSQL &= "CleanFolder=@CleanFolder, Parameter=@Parameter, Comments=@Comments, IsRegEx=@IsRegEx, RecurseSubFolders=@RecurseSubFolders WHERE MonitorID=@QueryID;"
sSQL &= "UPDATE gametags SET MonitorID=@ID WHERE MonitorID=@QueryID;" sSQL &= "UPDATE gametags SET MonitorID=@ID WHERE MonitorID=@QueryID;"
If iSelectDB = mgrSQLite.Database.Local Then If iSelectDB = mgrSQLite.Database.Local Then
@@ -367,11 +374,11 @@ Public Class mgrMonitorList
sVersion = "(SELECT Version FROM monitorlist WHERE MonitorID=@ID)" sVersion = "(SELECT Version FROM monitorlist WHERE MonitorID=@ID)"
End If End If
sSQL = "INSERT OR REPLACE INTO monitorlist (MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly, BackupLimit, CleanFolder, Parameter, Comments, IsRegEx) " sSQL = "INSERT OR REPLACE INTO monitorlist (MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly, BackupLimit, CleanFolder, Parameter, Comments, IsRegEx, RecurseSubFolders) "
sSQL &= "VALUES (@ID, @Name, @Process, @Path, @AbsolutePath, @FolderSave, @FileType, " sSQL &= "VALUES (@ID, @Name, @Process, @Path, @AbsolutePath, @FolderSave, @FileType, "
sSQL &= "@TimeStamp, @ExcludeList, " & sGamePath & ", " sSQL &= "@TimeStamp, @ExcludeList, " & sGamePath & ", "
sSQL &= sIcon & ", @Hours, " & sVersion & ", " sSQL &= sIcon & ", @Hours, " & sVersion & ", "
sSQL &= sCompany & ", " & sMonitorGame & ", @MonitorOnly, @BackupLimit, @CleanFolder, @Parameter, @Comments, @IsRegEx);" sSQL &= sCompany & ", " & sMonitorGame & ", @MonitorOnly, @BackupLimit, @CleanFolder, @Parameter, @Comments, @IsRegEx, @RecurseSubFolders);"
For Each oGame As clsGame In hshGames.Values For Each oGame As clsGame In hshGames.Values
hshParams = New Hashtable hshParams = New Hashtable
@@ -393,6 +400,7 @@ Public Class mgrMonitorList
hshParams.Add("Parameter", oGame.Parameter) hshParams.Add("Parameter", oGame.Parameter)
hshParams.Add("Comments", oGame.Comments) hshParams.Add("Comments", oGame.Comments)
hshParams.Add("IsRegEx", oGame.IsRegEx) hshParams.Add("IsRegEx", oGame.IsRegEx)
hshParams.Add("RecurseSubFolders", oGame.RecurseSubFolders)
'Optional Parameters 'Optional Parameters
If (eSyncFields And clsGame.eOptionalSyncFields.Company) = clsGame.eOptionalSyncFields.Company Then If (eSyncFields And clsGame.eOptionalSyncFields.Company) = clsGame.eOptionalSyncFields.Company Then
@@ -548,7 +556,7 @@ Public Class mgrMonitorList
ByRef hshParams As Hashtable) As String ByRef hshParams As Hashtable) As String
Dim sSQL As String = String.Empty Dim sSQL As String = String.Empty
Dim iCounter As Integer = 0 Dim iCounter As Integer = 0
Dim sBaseSelect As String = "MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly, BackupLimit, CleanFolder, Parameter, Comments, IsRegEx FROM monitorlist" Dim sBaseSelect As String = "MonitorID, Name, Process, Path, AbsolutePath, FolderSave, FileType, TimeStamp, ExcludeList, ProcessPath, Icon, Hours, Version, Company, Enabled, MonitorOnly, BackupLimit, CleanFolder, Parameter, Comments, IsRegEx, RecurseSubFolders FROM monitorlist"
Dim sSort As String = " ORDER BY " & sSortField Dim sSort As String = " ORDER BY " & sSortField
If bSortAsc Then If bSortAsc Then
@@ -745,6 +753,7 @@ Public Class mgrMonitorList
If Not IsDBNull(dr("Parameter")) Then oGame.Parameter = CStr(dr("Parameter")) If Not IsDBNull(dr("Parameter")) Then oGame.Parameter = CStr(dr("Parameter"))
If Not IsDBNull(dr("Comments")) Then oGame.Comments = CStr(dr("Comments")) If Not IsDBNull(dr("Comments")) Then oGame.Comments = CStr(dr("Comments"))
oGame.IsRegEx = CBool(dr("IsRegEx")) oGame.IsRegEx = CBool(dr("IsRegEx"))
oGame.RecurseSubFolders = CBool(dr("RecurseSubFolders"))
oGame.Tags = mgrGameTags.GetTagsByGameForExport(oGame.ID) oGame.Tags = mgrGameTags.GetTagsByGameForExport(oGame.ID)
oList.Add(oGame) oList.Add(oGame)
Next Next
+26 -15
View File
@@ -203,6 +203,12 @@ Public Class mgrPath
Return sResult Return sResult
End Function End Function
Public Shared Sub ModWinePathData(ByRef oGame As clsGame)
If Not oGame.AbsolutePath Then oGame.Path = oGame.Path.Replace("\", Path.DirectorySeparatorChar)
oGame.FileType = oGame.FileType.Replace("\", Path.DirectorySeparatorChar)
oGame.ExcludeList = oGame.ExcludeList.Replace("\", Path.DirectorySeparatorChar)
End Sub
Private Shared Function BuildWinePath(ByVal sPath As String, ByVal sWinePrefix As String) As String Private Shared Function BuildWinePath(ByVal sPath As String, ByVal sWinePrefix As String) As String
Dim sRealPath As String Dim sRealPath As String
Dim cDriveLetter As Char Dim cDriveLetter As Char
@@ -217,7 +223,7 @@ Public Class mgrPath
sRealPath = sRealPath.TrimEnd("""") sRealPath = sRealPath.TrimEnd("""")
'Flip Seperators 'Flip Seperators
sRealPath = sRealPath.Replace("\\", "/") sRealPath = sRealPath.Replace("\\", Path.DirectorySeparatorChar)
'Change Wine Drive 'Change Wine Drive
cDriveLetter = sRealPath.Chars(sRealPath.IndexOf(":") - 1) cDriveLetter = sRealPath.Chars(sRealPath.IndexOf(":") - 1)
@@ -259,6 +265,10 @@ Public Class mgrPath
sReplace = "%COMMONDOCUMENTS%" sReplace = "%COMMONDOCUMENTS%"
sRegistry = File.ReadAllText(sPrefix & Path.DirectorySeparatorChar & "system.reg") sRegistry = File.ReadAllText(sPrefix & Path.DirectorySeparatorChar & "system.reg")
oParse = New Regex("""Common Documents""="".+?(?=\n)") oParse = New Regex("""Common Documents""="".+?(?=\n)")
ElseIf sPath.Contains("%PROGRAMDATA%") Then
sReplace = "%PROGRAMDATA%"
sRegistry = File.ReadAllText(sPrefix & Path.DirectorySeparatorChar & "system.reg")
oParse = New Regex("""Common AppData""="".+?(?=\n)")
ElseIf sPath.Contains("%USERPROFILE%") Then ElseIf sPath.Contains("%USERPROFILE%") Then
sReplace = "%USERPROFILE%" sReplace = "%USERPROFILE%"
sRegistry = File.ReadAllText(sPrefix & Path.DirectorySeparatorChar & "user.reg") sRegistry = File.ReadAllText(sPrefix & Path.DirectorySeparatorChar & "user.reg")
@@ -282,25 +292,18 @@ Public Class mgrPath
End Function End Function
Public Shared Function GetWinePrefix(ByVal prs As Process) As String Public Shared Function GetWinePrefix(ByVal prs As Process) As String
Dim prps As Process Dim sEnv As String
Dim sPsinfo As String Dim oParse As New Regex("WINEPREFIX=.+?(?=\x00)")
Dim oParse As New Regex("WINEPREFIX=.+?(?= )")
Dim oMatch As Match Dim oMatch As Match
Try Try
prps = New Process sEnv = File.ReadAllText("/proc/" & prs.Id.ToString() & "/environ")
prps.StartInfo.FileName = "/bin/ps" If oParse.IsMatch(sEnv) Then
prps.StartInfo.Arguments = "e " & prs.Id.ToString oMatch = oParse.Match(sEnv)
prps.StartInfo.UseShellExecute = False
prps.StartInfo.RedirectStandardOutput = True
prps.StartInfo.CreateNoWindow = True
prps.Start()
sPsinfo = prps.StandardOutput.ReadToEnd()
If oParse.IsMatch(sPsinfo) Then
oMatch = oParse.Match(sPsinfo)
Return oMatch.Value.Trim("/").Split("=")(1) Return oMatch.Value.Trim("/").Split("=")(1)
Else Else
Return String.Empty 'When WINEPREFIX is not part of the command, we will assume the default prefix.
Return Environment.GetFolderPath(Environment.SpecialFolder.Personal) & "/.wine"
End If End If
Catch ex As Exception Catch ex As Exception
mgrCommon.ShowMessage(mgrPath_ErrorWinePrefix, ex.Message, MsgBoxStyle.Exclamation) mgrCommon.ShowMessage(mgrPath_ErrorWinePrefix, ex.Message, MsgBoxStyle.Exclamation)
@@ -315,6 +318,8 @@ Public Class mgrPath
hshEnvs.Add("Documents", Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)) hshEnvs.Add("Documents", Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments))
hshEnvs.Add("AppDataRoaming", Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)) hshEnvs.Add("AppDataRoaming", Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData))
hshEnvs.Add("AppDataLocal", Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData)) hshEnvs.Add("AppDataLocal", Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData))
hshEnvs.Add("ProgramData", Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData))
If Not mgrCommon.IsUnix Then If Not mgrCommon.IsUnix Then
hshEnvs.Add("UserData", Environment.GetFolderPath(Environment.SpecialFolder.UserProfile)) hshEnvs.Add("UserData", Environment.GetFolderPath(Environment.SpecialFolder.UserProfile))
hshEnvs.Add("PublicDocuments", Environment.GetFolderPath(Environment.SpecialFolder.CommonDocuments)) hshEnvs.Add("PublicDocuments", Environment.GetFolderPath(Environment.SpecialFolder.CommonDocuments))
@@ -416,6 +421,8 @@ Public Class mgrPath
Dim sCurrentUser As String = "%USERPROFILE%" Dim sCurrentUser As String = "%USERPROFILE%"
Dim sHomeDir As String = "~" Dim sHomeDir As String = "~"
Dim sEnvCurrentUser As String = Environment.GetFolderPath(Environment.SpecialFolder.UserProfile) Dim sEnvCurrentUser As String = Environment.GetFolderPath(Environment.SpecialFolder.UserProfile)
Dim sProgramData As String = "%PROGRAMDATA%"
Dim sEnvProgramData As String = Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData)
Dim oCustomVariable As clsPathVariable Dim oCustomVariable As clsPathVariable
For Each oCustomVariable In hshCustomVariables.Values For Each oCustomVariable In hshCustomVariables.Values
@@ -433,6 +440,10 @@ Public Class mgrPath
Return sValue.Replace(sEnvAppDataLocal, sAppDataLocal) Return sValue.Replace(sEnvAppDataLocal, sAppDataLocal)
End If End If
If sValue.Contains(sEnvProgramData) Then
Return sValue.Replace(sEnvProgramData, sProgramData)
End If
'This needs to be tested last for Unix compatability 'This needs to be tested last for Unix compatability
If sValue.Contains(sEnvMyDocs) Then If sValue.Contains(sEnvMyDocs) Then
Return sValue.Replace(sEnvMyDocs, sMyDocs) Return sValue.Replace(sEnvMyDocs, sMyDocs)
+3 -4
View File
@@ -1,6 +1,5 @@
Imports System.IO Imports System.IO
Imports System.Management Imports System.Management
Imports System.Text.RegularExpressions
Public Class mgrProcessDetection Public Class mgrProcessDetection
@@ -143,7 +142,7 @@ Public Class mgrProcessDetection
Private Function IsMatch(ByRef oGame As clsGame, ByRef sProcessCheck As String) As Boolean Private Function IsMatch(ByRef oGame As clsGame, ByRef sProcessCheck As String) As Boolean
If oGame.IsRegEx Then If oGame.IsRegEx Then
Try Try
If Regex.IsMatch(sProcessCheck, oGame.ProcessName) Then If oGame.CompiledRegEx.IsMatch(sProcessCheck) Then
Return True Return True
End If End If
Catch Catch
@@ -267,8 +266,8 @@ Public Class mgrProcessDetection
Dim sParameter As String Dim sParameter As String
Dim sWinePath As String() Dim sWinePath As String()
'The wine-preloader parameters can refer to a path on the host system, windows based path within in the prefix, or mixed notation. 'The wine-preloader parameters can refer to a path on the host system, windows based path within in the prefix, or mixed notation.
sParameter = sArgs(0).Replace("\", "/") sParameter = sArgs(0).Replace("\", Path.DirectorySeparatorChar)
sWinePath = sParameter.Split("/") sWinePath = sParameter.Split(Path.DirectorySeparatorChar)
sProcessCheck = Path.GetFileNameWithoutExtension(sWinePath(sWinePath.Length - 1)) sProcessCheck = Path.GetFileNameWithoutExtension(sWinePath(sWinePath.Length - 1))
bWineProcess = True bWineProcess = True
Else Else
+26 -2
View File
@@ -84,7 +84,7 @@ Public Class mgrSQLite
sSql &= "CREATE TABLE monitorlist (MonitorID TEXT NOT NULL PRIMARY KEY, Name TEXT NOT NULL, Process TEXT NOT NULL, Path TEXT, " & sSql &= "CREATE TABLE monitorlist (MonitorID TEXT NOT NULL PRIMARY KEY, Name TEXT NOT NULL, Process TEXT NOT NULL, Path TEXT, " &
"AbsolutePath BOOLEAN NOT NULL, FolderSave BOOLEAN NOT NULL, FileType TEXT, TimeStamp BOOLEAN NOT NULL, ExcludeList TEXT NOT NULL, " & "AbsolutePath BOOLEAN NOT NULL, FolderSave BOOLEAN NOT NULL, FileType TEXT, TimeStamp BOOLEAN NOT NULL, ExcludeList TEXT NOT NULL, " &
"ProcessPath TEXT, Icon TEXT, Hours REAL, Version TEXT, Company TEXT, Enabled BOOLEAN NOT NULL, MonitorOnly BOOLEAN NOT NULL, " & "ProcessPath TEXT, Icon TEXT, Hours REAL, Version TEXT, Company TEXT, Enabled BOOLEAN NOT NULL, MonitorOnly BOOLEAN NOT NULL, " &
"BackupLimit INTEGER NOT NULL, CleanFolder BOOLEAN NOT NULL, Parameter TEXT, Comments TEXT, IsRegEx BOOLEAN NOT NULL);" "BackupLimit INTEGER NOT NULL, CleanFolder BOOLEAN NOT NULL, Parameter TEXT, Comments TEXT, IsRegEx BOOLEAN NOT NULL, RecurseSubFolders NOT NULL);"
'Add Tables (Tags) 'Add Tables (Tags)
sSql &= "CREATE TABLE tags (TagID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY); " sSql &= "CREATE TABLE tags (TagID TEXT NOT NULL UNIQUE, Name TEXT NOT NULL PRIMARY KEY); "
@@ -130,7 +130,7 @@ Public Class mgrSQLite
sSql = "CREATE TABLE monitorlist (MonitorID TEXT NOT NULL PRIMARY KEY, Name TEXT NOT NULL, Process TEXT NOT NULL, Path TEXT, " & sSql = "CREATE TABLE monitorlist (MonitorID TEXT NOT NULL PRIMARY KEY, Name TEXT NOT NULL, Process TEXT NOT NULL, Path TEXT, " &
"AbsolutePath BOOLEAN NOT NULL, FolderSave BOOLEAN NOT NULL, FileType TEXT, TimeStamp BOOLEAN NOT NULL, ExcludeList TEXT NOT NULL, " & "AbsolutePath BOOLEAN NOT NULL, FolderSave BOOLEAN NOT NULL, FileType TEXT, TimeStamp BOOLEAN NOT NULL, ExcludeList TEXT NOT NULL, " &
"ProcessPath TEXT, Icon TEXT, Hours REAL, Version TEXT, Company TEXT, Enabled BOOLEAN NOT NULL, MonitorOnly BOOLEAN NOT NULL, " & "ProcessPath TEXT, Icon TEXT, Hours REAL, Version TEXT, Company TEXT, Enabled BOOLEAN NOT NULL, MonitorOnly BOOLEAN NOT NULL, " &
"BackupLimit INTEGER NOT NULL, CleanFolder BOOLEAN NOT NULL, Parameter TEXT, Comments TEXT, IsRegEx BOOLEAN NOT NULL);" "BackupLimit INTEGER NOT NULL, CleanFolder BOOLEAN NOT NULL, Parameter TEXT, Comments TEXT, IsRegEx BOOLEAN NOT NULL, RecurseSubFolders NOT NULL);"
'Add Tables (Remote Manifest) 'Add Tables (Remote Manifest)
sSql &= "CREATE TABLE manifest (ManifestID TEXT NOT NULL PRIMARY KEY, MonitorID TEXT NOT NULL, FileName TEXT NOT NULL, " & sSql &= "CREATE TABLE manifest (ManifestID TEXT NOT NULL PRIMARY KEY, MonitorID TEXT NOT NULL, FileName TEXT NOT NULL, " &
@@ -892,6 +892,30 @@ Public Class mgrSQLite
RunParamQuery(sSQL, New Hashtable) RunParamQuery(sSQL, New Hashtable)
End If End If
End If End If
'1.16 Upgrade
If GetDatabaseVersion() < 116 Then
If eDatabase = Database.Local Then
'Backup DB before starting
BackupDB("v115")
'Add new field(s)
sSQL = "ALTER TABLE monitorlist ADD COLUMN RecurseSubFolders BOOLEAN NOT NULL DEFAULT 1;"
sSQL &= "PRAGMA user_version=116"
RunParamQuery(sSQL, New Hashtable)
End If
If eDatabase = Database.Remote Then
'Backup DB before starting
BackupDB("v115")
'Add new field(s)
sSQL = "ALTER TABLE monitorlist ADD COLUMN RecurseSubFolders BOOLEAN NOT NULL DEFAULT 1;"
sSQL &= "PRAGMA user_version=116"
RunParamQuery(sSQL, New Hashtable)
End If
End If
End Sub End Sub
Public Function GetDBSize() As Long Public Function GetDBSize() As Long
+1
View File
@@ -163,6 +163,7 @@
oList.Add("USERDOCUMENTS") oList.Add("USERDOCUMENTS")
oList.Add("COMMONDOCUMENTS") oList.Add("COMMONDOCUMENTS")
oList.Add("USERPROFILE") oList.Add("USERPROFILE")
oList.Add("PROGRAMDATA")
Return oList Return oList
End Function End Function
+1
View File
@@ -41,6 +41,7 @@ Public Class mgrXML
oGame.Parameter = g.Parameter oGame.Parameter = g.Parameter
oGame.Comments = g.Comments oGame.Comments = g.Comments
oGame.IsRegEx = g.IsRegEx oGame.IsRegEx = g.IsRegEx
oGame.RecurseSubFolders = g.RecurseSubFolders
For Each t As Tag In g.Tags For Each t As Tag In g.Tags
oGame.ImportTags.Add(t) oGame.ImportTags.Add(t)
Next Next
+2 -2
View File
@@ -33,7 +33,7 @@ Imports System.Runtime.InteropServices
' by using the '*' as shown below: ' by using the '*' as shown below:
' <Assembly: AssemblyVersion("1.0.*")> ' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("1.1.5.*")> <Assembly: AssemblyVersion("1.1.6.*")>
<Assembly: AssemblyFileVersion("1.1.5.0")> <Assembly: AssemblyFileVersion("1.1.6.0")>
<Assembly: NeutralResourcesLanguageAttribute("en")> <Assembly: NeutralResourcesLanguageAttribute("en")>
+38 -2
View File
@@ -1203,6 +1203,15 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Looks up a localized string similar to Recurse Sub-Folders.
'''</summary>
Friend ReadOnly Property frmFilter_FieldRecurseSubFolders() As String
Get
Return ResourceManager.GetString("frmFilter_FieldRecurseSubFolders", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Looks up a localized string similar to Save Multiple Backups. ''' Looks up a localized string similar to Save Multiple Backups.
'''</summary> '''</summary>
@@ -2715,6 +2724,15 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Looks up a localized string similar to Recurse sub-folders.
'''</summary>
Friend ReadOnly Property frmIncludeExclude_chkRecurseSubFolders() As String
Get
Return ResourceManager.GetString("frmIncludeExclude_chkRecurseSubFolders", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Looks up a localized string similar to Add Custom Item. ''' Looks up a localized string similar to Add Custom Item.
'''</summary> '''</summary>
@@ -2772,9 +2790,9 @@ Namespace My.Resources
'''<summary> '''<summary>
''' Looks up a localized string similar to [PARAM] Options. ''' Looks up a localized string similar to [PARAM] Options.
'''</summary> '''</summary>
Friend ReadOnly Property frmIncludeExclude_grpFileOptions() As String Friend ReadOnly Property frmIncludeExclude_grpOptions() As String
Get Get
Return ResourceManager.GetString("frmIncludeExclude_grpFileOptions", resourceCulture) Return ResourceManager.GetString("frmIncludeExclude_grpOptions", resourceCulture)
End Get End Get
End Property End Property
@@ -3021,6 +3039,15 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Looks up a localized string similar to Memory Allocation: [PARAM] MB.
'''</summary>
Friend ReadOnly Property frmMain_DebugMemoryAllocation() As String
Get
Return ResourceManager.GetString("frmMain_DebugMemoryAllocation", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Looks up a localized string similar to Game Backup Monitor Log. ''' Looks up a localized string similar to Game Backup Monitor Log.
'''</summary> '''</summary>
@@ -3219,6 +3246,15 @@ Namespace My.Resources
End Get End Get
End Property End Property
'''<summary>
''' Looks up a localized string similar to Invalid mode([PARAM]) for command [PARAM]..
'''</summary>
Friend ReadOnly Property frmMain_ErrorInvalidMode() As String
Get
Return ResourceManager.GetString("frmMain_ErrorInvalidMode", resourceCulture)
End Get
End Property
'''<summary> '''<summary>
''' Looks up a localized string similar to The command [PARAM] requires more parameters.. ''' Looks up a localized string similar to The command [PARAM] requires more parameters..
'''</summary> '''</summary>
+13 -1
View File
@@ -967,7 +967,7 @@
<data name="frmIncludeExclude_FormName" xml:space="preserve"> <data name="frmIncludeExclude_FormName" xml:space="preserve">
<value>[PARAM] Builder</value> <value>[PARAM] Builder</value>
</data> </data>
<data name="frmIncludeExclude_grpFileOptions" xml:space="preserve"> <data name="frmIncludeExclude_grpOptions" xml:space="preserve">
<value>[PARAM] Options</value> <value>[PARAM] Options</value>
</data> </data>
<data name="frmIncludeExclude_lblItems" xml:space="preserve"> <data name="frmIncludeExclude_lblItems" xml:space="preserve">
@@ -2269,4 +2269,16 @@
<data name="frmGameManager_ConfirmBackupImportOverwriteSingle" xml:space="preserve"> <data name="frmGameManager_ConfirmBackupImportOverwriteSingle" xml:space="preserve">
<value>Importing this backup file will overwrite the current backup file for [PARAM].[BR][BR]Do you want to continue? This will close the form.</value> <value>Importing this backup file will overwrite the current backup file for [PARAM].[BR][BR]Do you want to continue? This will close the form.</value>
</data> </data>
<data name="frmFilter_FieldRecurseSubFolders" xml:space="preserve">
<value>Recurse Sub-Folders</value>
</data>
<data name="frmIncludeExclude_chkRecurseSubFolders" xml:space="preserve">
<value>Recurse sub-folders</value>
</data>
<data name="frmMain_DebugMemoryAllocation" xml:space="preserve">
<value>Memory Allocation: [PARAM] MB</value>
</data>
<data name="frmMain_ErrorInvalidMode" xml:space="preserve">
<value>Invalid mode([PARAM]) for command [PARAM].</value>
</data>
</root> </root>
+17 -46
View File
@@ -1,58 +1,29 @@
Game Backup Monitor v1.1.5 Readme Game Backup Monitor v1.1.6 Readme
http://mikemaximus.github.io/gbm-web/ http://mikemaximus.github.io/gbm-web/
gamebackupmonitor@gmail.com gamebackupmonitor@gmail.com
October 10th, 2018 November 17, 2018
New in 1.1.5 New in 1.1.6
All Platforms: All Platforms:
- Fixed a crash that could occur when renaming a game configuration. - Added support for games that save to the Windows %PROGRAMDATA% location.
- Rewrote portions of game detection: - The Game Manager now automatically selects the last detected game when opened.
- The handling of duplicate game configurations has been flawed since regular expression support was added in v1.1. This has been fixed. - Backup files can no longer be imported into a "Monitor Only" configuration.
- GBM is now more efficient when detecting games by parameter and/or process path. - Optimized the memory and cpu usage of Regular Expressions when monitoring for games.
- Changed how save path variables are handled: - Added a "Recurse sub-folders" option
- GBM no longer uses it's own format and naming scheme for path variables. - This option is set per game configuration, it is available on Include/Exclude window of the Game Manager and Add Game Wizard.
- GBM now uses Windows environment variables in game configurations. - It is enabled by default on all current and new configurations.
- For example, *appdatalocal* is now %LOCALAPPDATA% in a Windows configuration. - Disabling this option prevents 7-Zip and GBM from scanning every sub-folder and file of a save path. This useful when backing up specific files inside an extremely large folder.
- GBM also uses some custom environment variables, such as %USERDOCUMENTS% and %COMMONDOCUMENTS%. These are needed for compatability and to handle some limitations with how GBM interacts with 7-Zip. - Fixed a possible issue with backups when the configuration uses folder path includes.
- GBM now uses the XDG specification for game configurations in Linux. (Thanks basxto!)
- For example, *appdatalocal* is now ${XDG_DATA_HOME:-~/.local/share} in a Linux configuration.
- Custom Path Variables have changed. For example, *Steam User Data* will now be %Steam User Data%.
- They will appear this way in Windows and Linux.
- GBM will no longer allow the creation of variables using reserved names, such as APPDATA.
- Your configurations will be automatically updated to these new formats when upgrading to v1.1.5.
- These changes will break game list compatability with other versions of GBM. Archived lists are available at http://mikemaximus.github.io/gbm-web/archive.html for those that wish to stay on an older version.
- Added a new setting, "Show resolved save paths in Game Manager".
- This new setting is enabled by default.
- When enabled, GBM will display resolved save paths in the Game Manager. This is how GBM displayed paths prior to v1.1.5.
- When disabled, GBM will display save paths with their variables when applicable.
- Added a tooltip to applicable "Path" fields on the Game Manager.
- This tooltip either displays either a resolved or unresolved path.
- The behaviour is toggled by the "Show resolved save paths" setting.
- Added "Import Backup Files" feature to the Game Manager.
- This feature allows you to import one or more backup files for a specific game configuration.
- This is useful if you lost your GBM database(s), but not the backup files. It also can be used to easily move compatible saved game backups between Windows and Linux.
- GBM cannot verify that the backups being imported are compatible with the current configuration. This is up to the user!
- This feature will be expanded and refined in future releases.
Linux: Linux:
- Fixed an issue that prevented Wine / Proton games from being detected in some cases. - Fixed a memory leak issue with Mono and Regular Expressions.
- GBM can now use any Windows configuration to detect and backup games running in Wine / Proton. - Fixed some issues when detecting the prefix of Wine/Proton games.
- An absolute Windows save path, such "%APPDATA%\Game\Saved Games" will be automatically converted to the proper path within the detected Wine prefix. - The default prefix (~/.wine) will be assumed when a detected game does not have the WINEPREFIX variable set.
- The converted path will be saved to the configuration once game has been detected at least once. - A prefix can now be fully detected when it contains spaces.
- You cannot restore a backup using an absolute Windows path. The game needs to be detected at least once so the correct save path can be determined. - Windows configurations that use a relative save path are now properly converted when detected in Wine/Proton.
- This feature should be considered "Beta" and may not work in all scenarios. Please report any issues you may encounter!
Website:
- Search features have been added to the Official Game Lists (Thanks basxto!)
- Includes advanced features such as searching by tag and excludes.
- Tags are now clickable for automatic searching of similar games.
- Searches are linkable.
- You can now link directly to a single configuration using the new link icon.
- Configurations intelligently collapse or uncollapse based on search results.
The entire version history of GBM releases is available at http://mikemaximus.github.io/gbm-web/versionhistory.html The entire version history of GBM releases is available at http://mikemaximus.github.io/gbm-web/versionhistory.html