This commit is contained in:
MikeMaximus
2018-10-12 09:18:15 -06:00
parent 4b201fb60e
commit ffe34d29e7
3 changed files with 11 additions and 3 deletions
+2
View File
@@ -1941,6 +1941,8 @@ Public Class frmMain
End If 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
+7 -1
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)
+2 -2
View File
@@ -267,8 +267,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