diff --git a/GBM/Forms/frmFilter.Designer.vb b/GBM/Forms/frmFilter.Designer.vb index 3794e82..833d5b8 100644 --- a/GBM/Forms/frmFilter.Designer.vb +++ b/GBM/Forms/frmFilter.Designer.vb @@ -99,7 +99,6 @@ Partial Class frmFilter ' '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) @@ -110,7 +109,6 @@ Partial Class frmFilter ' 'optAny ' - Me.optAny.AutoSize = True Me.optAny.Checked = True Me.optAny.Location = New System.Drawing.Point(6, 19) Me.optAny.Name = "optAny" @@ -213,7 +211,6 @@ Partial Class frmFilter ' 'optOr ' - Me.optOr.AutoSize = True Me.optOr.Location = New System.Drawing.Point(56, 19) Me.optOr.Name = "optOr" Me.optOr.Size = New System.Drawing.Size(36, 17) @@ -224,7 +221,6 @@ Partial Class frmFilter ' 'optAnd ' - Me.optAnd.AutoSize = True Me.optAnd.Checked = True Me.optAnd.Location = New System.Drawing.Point(6, 19) Me.optAnd.Name = "optAnd" @@ -302,11 +298,9 @@ Partial Class frmFilter Me.grpTagFilter.ResumeLayout(False) Me.grpTagFilter.PerformLayout() Me.grpTagOptions.ResumeLayout(False) - Me.grpTagOptions.PerformLayout() Me.grpGameFilter.ResumeLayout(False) Me.grpGameFilter.PerformLayout() Me.grpGameInfoOptions.ResumeLayout(False) - Me.grpGameInfoOptions.PerformLayout() Me.ResumeLayout(False) Me.PerformLayout() diff --git a/GBM/Forms/frmGameManager.vb b/GBM/Forms/frmGameManager.vb index df020ab..5264195 100644 --- a/GBM/Forms/frmGameManager.vb +++ b/GBM/Forms/frmGameManager.vb @@ -336,8 +336,14 @@ Public Class frmGameManager End If End If - sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseCustomIcon, "ico", _ - frmGameManager_Icon, sDefaultFolder, False) + 'Unix Handler + If Not mgrCommon.IsUnix Then + sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseCustomIcon, "ico", _ + frmGameManager_Icon, sDefaultFolder, False) + Else + sNewPath = mgrCommon.OpenFileBrowser(frmGameManager_ChooseCustomIcon, "png", _ + "PNG", sDefaultFolder, False) + End If If sNewPath <> String.Empty Then txtIcon.Text = sNewPath diff --git a/GBM/Forms/frmMain.vb b/GBM/Forms/frmMain.vb index be77db4..ce80ddd 100644 --- a/GBM/Forms/frmMain.vb +++ b/GBM/Forms/frmMain.vb @@ -333,8 +333,16 @@ Public Class frmMain Dim fbBrowser As New OpenFileDialog fbBrowser.Title = mgrCommon.FormatString(frmMain_ChooseIcon, oProcess.GameInfo.CroppedName) - fbBrowser.DefaultExt = "ico" - fbBrowser.Filter = frmMain_IconFilter + + 'Unix Handler + If Not mgrCommon.IsUnix Then + fbBrowser.DefaultExt = "ico" + fbBrowser.Filter = frmMain_IconFilter + Else + fbBrowser.DefaultExt = "png" + fbBrowser.Filter = frmMain_PNGFilter + End If + Try fbBrowser.InitialDirectory = IO.Path.GetDirectoryName(oProcess.FoundProcess.MainModule.FileName) Catch ex As Exception diff --git a/GBM/Managers/mgrPath.vb b/GBM/Managers/mgrPath.vb index 3d46477..a55693a 100644 --- a/GBM/Managers/mgrPath.vb +++ b/GBM/Managers/mgrPath.vb @@ -201,6 +201,12 @@ Public Class mgrPath Dim oCustomVariable As clsPathVariable + For Each oCustomVariable In hshCustomVariables.Values + If sValue.Contains(oCustomVariable.FormattedName) Then + Return sValue.Replace(oCustomVariable.FormattedName, oCustomVariable.Path) + End If + Next + If sValue.Contains("*appdatalocal*") Then Return sValue.Replace("*appdatalocal*", sAppDataLocal) End If @@ -209,12 +215,13 @@ Public Class mgrPath Return sValue.Replace("*appdataroaming*", sAppDataRoaming) End If + 'This needs to be tested last for Unix compatability + If sValue.Contains("*mydocs*") Then + Return sValue.Replace("*mydocs*", sMyDocs) + End If + 'Don't use these in Unix If Not mgrCommon.IsUnix Then - If sValue.Contains("*mydocs*") Then - Return sValue.Replace("*mydocs*", sMyDocs) - End If - If sValue.Contains("*publicdocs*") Then Return sValue.Replace("*publicdocs*", sPublicDocs) End If @@ -224,12 +231,6 @@ Public Class mgrPath End If End If - For Each oCustomVariable In hshCustomVariables.Values - If sValue.Contains(oCustomVariable.FormattedName) Then - Return sValue.Replace(oCustomVariable.FormattedName, oCustomVariable.Path) - End If - Next - Return sValue End Function @@ -241,7 +242,12 @@ Public Class mgrPath Dim sCurrentUser As String = "*currentuser*" Dim oCustomVariable As clsPathVariable - + For Each oCustomVariable In hshCustomVariables.Values + If sValue.Contains(oCustomVariable.Path) Then + Return sValue.Replace(oCustomVariable.Path, oCustomVariable.FormattedName) + End If + Next + If sValue.Contains(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)) Then Return sValue.Replace(Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData), sAppDataLocal) End If @@ -250,12 +256,13 @@ Public Class mgrPath Return sValue.Replace(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), sAppDataRoaming) End If + 'This needs to be tested last for Unix compatability + If sValue.Contains(Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)) Then + Return sValue.Replace(Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments), sMyDocs) + End If + 'Don't use these in Unix If Not mgrCommon.IsUnix Then - If sValue.Contains(Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)) Then - Return sValue.Replace(Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments), sMyDocs) - End If - If sValue.Contains(Environment.GetFolderPath(Environment.SpecialFolder.CommonDocuments)) Then Return sValue.Replace(Environment.GetFolderPath(Environment.SpecialFolder.CommonDocuments), sPublicDocs) End If @@ -265,12 +272,6 @@ Public Class mgrPath End If End If - For Each oCustomVariable In hshCustomVariables.Values - If sValue.Contains(oCustomVariable.Path) Then - Return sValue.Replace(oCustomVariable.Path, oCustomVariable.FormattedName) - End If - Next - Return sValue End Function diff --git a/GBM/My Project/Resources.Designer.vb b/GBM/My Project/Resources.Designer.vb index 5ac6629..b8c1d52 100644 --- a/GBM/My Project/Resources.Designer.vb +++ b/GBM/My Project/Resources.Designer.vb @@ -2868,6 +2868,15 @@ Namespace My.Resources End Get End Property + ''' + ''' Looks up a localized string similar to PNG files (*.png)|*.png. + ''' + Friend ReadOnly Property frmMain_PNGFilter() As String + Get + Return ResourceManager.GetString("frmMain_PNGFilter", resourceCulture) + End Get + End Property + ''' ''' Looks up a localized string similar to Remote Database Vacuum Completed: [PARAM] KB. ''' diff --git a/GBM/My Project/Resources.resx b/GBM/My Project/Resources.resx index 0229203..bdf0f9d 100644 --- a/GBM/My Project/Resources.resx +++ b/GBM/My Project/Resources.resx @@ -1567,4 +1567,7 @@ You appear to be using a Unix based operating system. The official list currently contains only Microsoft Windows game configurations.[BR][BR]Do you wish to continue? + + PNG files (*.png)|*.png + \ No newline at end of file