Do not migrate files from Local to Roaming folder in portable version.

This commit is contained in:
Riley McArdle
2011-05-12 19:15:59 -05:00
parent 944906a594
commit 99f3638fbf
2 changed files with 9 additions and 3 deletions

View File

@@ -786,10 +786,12 @@ Namespace App
If My.Settings.LoadConsFromCustomLocation = False Then
Dim oldPath As String = GetFolderPath(SpecialFolder.LocalApplicationData) & "\" & My.Application.Info.ProductName & "\" & App.Info.Connections.DefaultConnectionsFile
Dim newPath As String = App.Info.Connections.DefaultConnectionsPath & "\" & App.Info.Connections.DefaultConnectionsFile
If Not File.Exists(newPath) And File.Exists(oldPath) Then
conL.ConnectionFileName = oldPath
Else
If File.Exists(newPath) Then
conL.ConnectionFileName = newPath
#If Not PORTABLE Then
Else If File.Exists(oldPath) Then
conL.ConnectionFileName = oldPath
#End If
End If
Else
conL.ConnectionFileName = My.Settings.CustomConsPath

View File

@@ -165,8 +165,10 @@ Namespace Config
Dim newPath As String = App.Info.Settings.SettingsPath & "\" & App.Info.Settings.LayoutFileName
If File.Exists(newPath) Then
.pnlDock.LoadFromXml(newPath, AddressOf GetContentFromPersistString)
#If Not PORTABLE Then
ElseIf File.Exists(oldPath) Then
.pnlDock.LoadFromXml(oldPath, AddressOf GetContentFromPersistString)
#End If
Else
Startup.SetDefaultLayout()
End If
@@ -183,8 +185,10 @@ Namespace Config
Dim xDom As New XmlDocument()
If File.Exists(newPath) Then
xDom.Load(newPath)
#If Not PORTABLE Then
ElseIf File.Exists(oldPath) Then
xDom.Load(oldPath)
#End If
Else
Exit Sub
End If