Zooflow: Make PM Path configurable
This commit is contained in:
@@ -9,7 +9,10 @@ Public Class frmConfigBasic
|
||||
|
||||
Private Sub frmConfigBasic_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
||||
LoadScreens()
|
||||
|
||||
Logger = My.LogConfig.GetLogger()
|
||||
ToggleSwitchDebug.IsOn = My.LogConfig.Debug
|
||||
|
||||
For Each orow As DataRow In My.Tables.DTIDB_CATALOG_USER.Rows
|
||||
Select Case orow.Item("CAT_TITLE")
|
||||
Case ClassConstants.USER_CATALOG_QUICKSEARCH1_TITLE
|
||||
@@ -28,11 +31,13 @@ Public Class frmConfigBasic
|
||||
SkinPaletteRibbonGalleryBarItem1.Gallery.SetItemCheck(oItem, True)
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
End Select
|
||||
Next
|
||||
|
||||
If My.SystemConfig.ProductPaths.ProcessManagerPath IsNot Nothing Then
|
||||
ProcessManagerPathTextbox.EditValue = My.SystemConfig.ProductPaths.ProcessManagerPath
|
||||
End If
|
||||
|
||||
oFormLoaded = True
|
||||
End Sub
|
||||
|
||||
@@ -53,7 +58,7 @@ Public Class frmConfigBasic
|
||||
End Sub
|
||||
|
||||
Private Sub BarButtonItem1_ItemClick(sender As Object, e As DevExpress.XtraBars.ItemClickEventArgs) Handles BarButtonItem1.ItemClick
|
||||
Process.Start(System.Windows.Forms.Application.LocalUserAppDataPath)
|
||||
Process.Start(Application.LocalUserAppDataPath)
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -153,4 +158,27 @@ Public Class frmConfigBasic
|
||||
My.UIConfigManager.Save()
|
||||
bsiInfo.Caption = "DEBUG saved!"
|
||||
End Sub
|
||||
|
||||
Private Sub ProcessManagerPathTextbox_Leave(sender As Object, e As EventArgs) Handles ProcessManagerPathTextbox.Leave
|
||||
Dim oProcessManagerPath As String = Utils.NotNull(ProcessManagerPathTextbox.EditValue, String.Empty)
|
||||
|
||||
If oProcessManagerPath.Length = 0 Then
|
||||
My.SystemConfig.ProductPaths.ProcessManagerPath = Nothing
|
||||
My.SystemConfigManager.Save()
|
||||
|
||||
bsiInfo.Caption = "Process Manager path cleared!"
|
||||
Else
|
||||
If Not IO.File.Exists(oProcessManagerPath) Then
|
||||
Logger.Warn($"ProcessManager application path [{oProcessManagerPath}] does not exist!")
|
||||
|
||||
End If
|
||||
|
||||
My.SystemConfig.ProductPaths.ProcessManagerPath = oProcessManagerPath
|
||||
My.SystemConfigManager.Save()
|
||||
|
||||
bsiInfo.Caption = "Process Manager path saved!"
|
||||
End If
|
||||
|
||||
|
||||
End Sub
|
||||
End Class
|
||||
Reference in New Issue
Block a user