Cleaned up GBM initilization
This commit is contained in:
+39
-41
@@ -1974,17 +1974,6 @@ Public Class frmMain
|
|||||||
RestartAsAdmin()
|
RestartAsAdmin()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub frmMain_Activated(sender As System.Object, e As System.EventArgs) Handles MyBase.Activated
|
|
||||||
If bInitialLoad Then
|
|
||||||
If oSettings.StartToTray And mgrCommon.IsUnix Then
|
|
||||||
Me.WindowState = FormWindowState.Minimized
|
|
||||||
End If
|
|
||||||
bInitialLoad = False
|
|
||||||
End If
|
|
||||||
txtLog.Select(txtLog.TextLength, 0)
|
|
||||||
txtLog.ScrollToCaret()
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Private Sub Main_FormClosing(sender As System.Object, e As System.Windows.Forms.FormClosingEventArgs) Handles MyBase.FormClosing
|
Private Sub Main_FormClosing(sender As System.Object, e As System.Windows.Forms.FormClosingEventArgs) Handles MyBase.FormClosing
|
||||||
'Unix Handler
|
'Unix Handler
|
||||||
If mgrCommon.IsUnix And Not bShutdown Then
|
If mgrCommon.IsUnix And Not bShutdown Then
|
||||||
@@ -2171,19 +2160,41 @@ Public Class frmMain
|
|||||||
oProcess.StartTime = Now : oProcess.EndTime = Now
|
oProcess.StartTime = Now : oProcess.EndTime = Now
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub Main_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
|
Private Sub frmMain_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
|
||||||
|
SetForm()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub frmMain_Activated(sender As System.Object, e As System.EventArgs) Handles MyBase.Activated
|
||||||
'Init
|
'Init
|
||||||
Try
|
If bInitialLoad Then
|
||||||
SetForm()
|
Try
|
||||||
VerifyGameDataPath()
|
VerifyGameDataPath()
|
||||||
LoadAndVerify()
|
LoadAndVerify()
|
||||||
If Not bInitFail Then
|
Catch ex As Exception
|
||||||
|
If mgrCommon.ShowMessage(frmMain_ErrorInitFailure, ex.Message & vbCrLf & ex.StackTrace, MsgBoxStyle.YesNo) = MsgBoxResult.No Then
|
||||||
|
bInitFail = True
|
||||||
|
End If
|
||||||
|
End Try
|
||||||
|
|
||||||
|
If bInitFail Then
|
||||||
|
bShutdown = True
|
||||||
|
Me.Close()
|
||||||
|
Else
|
||||||
VerifyCustomPathVariables()
|
VerifyCustomPathVariables()
|
||||||
|
|
||||||
If oSettings.StartToTray And Not mgrCommon.IsUnix Then
|
'Windows and Linux require different settings for the system tray
|
||||||
bShowToggle = False
|
If mgrCommon.IsUnix Then
|
||||||
Me.Visible = False
|
Me.MinimizeBox = True
|
||||||
Me.ShowInTaskbar = False
|
If oSettings.StartToTray Then
|
||||||
|
Me.WindowState = FormWindowState.Minimized
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
Me.gMonTray.Visible = True
|
||||||
|
If oSettings.StartToTray Then
|
||||||
|
bShowToggle = False
|
||||||
|
Me.Visible = False
|
||||||
|
Me.ShowInTaskbar = False
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If oSettings.MonitorOnStartup Then
|
If oSettings.MonitorOnStartup Then
|
||||||
@@ -2194,29 +2205,16 @@ Public Class frmMain
|
|||||||
|
|
||||||
HandleScan()
|
HandleScan()
|
||||||
CheckForNewBackups()
|
CheckForNewBackups()
|
||||||
|
|
||||||
'Unix Handler
|
|
||||||
If mgrCommon.IsUnix Then
|
|
||||||
Me.MinimizeBox = True
|
|
||||||
Else
|
|
||||||
Me.gMonTray.Visible = True
|
|
||||||
End If
|
|
||||||
End If
|
End If
|
||||||
Catch ex As Exception
|
|
||||||
If mgrCommon.ShowMessage(frmMain_ErrorInitFailure, ex.Message & vbCrLf & ex.StackTrace, MsgBoxStyle.YesNo) = MsgBoxResult.No Then
|
If bFirstRun And Not bShutdown Then
|
||||||
bInitFail = True
|
OpenStartupWizard()
|
||||||
End If
|
End If
|
||||||
End Try
|
|
||||||
End Sub
|
|
||||||
|
|
||||||
Private Sub frmMain_Shown(sender As Object, e As EventArgs) Handles MyBase.Shown
|
bInitialLoad = False
|
||||||
If bInitFail Then
|
Else
|
||||||
bShutdown = True
|
txtLog.Select(txtLog.TextLength, 0)
|
||||||
Me.Close()
|
txtLog.ScrollToCaret()
|
||||||
End If
|
|
||||||
|
|
||||||
If bFirstRun And Not bShutdown Then
|
|
||||||
OpenStartupWizard()
|
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|||||||
@@ -632,7 +632,7 @@ Public Class mgrPath
|
|||||||
Sleep(5000)
|
Sleep(5000)
|
||||||
iTotalWait += 5000
|
iTotalWait += 5000
|
||||||
If iTotalWait >= iTimeOut Then
|
If iTotalWait >= iTimeOut Then
|
||||||
oDialogResult = mgrCommon.ShowMessage(mgrPath_ConfirmBackupLocation, sBackupPath, MsgBoxStyle.YesNoCancel)
|
oDialogResult = mgrCommon.ShowPriorityMessage(mgrPath_ConfirmBackupLocation, sBackupPath, MsgBoxStyle.YesNoCancel)
|
||||||
If oDialogResult = MsgBoxResult.Yes Then
|
If oDialogResult = MsgBoxResult.Yes Then
|
||||||
dBrowser = New FolderBrowserDialog
|
dBrowser = New FolderBrowserDialog
|
||||||
dBrowser.SelectedPath = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
|
dBrowser.SelectedPath = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
|
||||||
|
|||||||
+3
-1
@@ -23,7 +23,8 @@ All Platforms:
|
|||||||
- The disk space check prior to backups can now be disabled in the "Backup and Restore" settings.
|
- The disk space check prior to backups can now be disabled in the "Backup and Restore" settings.
|
||||||
- Added "Operating System" field to game configurations:
|
- Added "Operating System" field to game configurations:
|
||||||
- "Windows" and "Linux" are the only valid choices at this time and only Linux users are allowed to change this field.
|
- "Windows" and "Linux" are the only valid choices at this time and only Linux users are allowed to change this field.
|
||||||
|
- Re-designed how GBM initilizes on startup.
|
||||||
|
|
||||||
Windows:
|
Windows:
|
||||||
|
|
||||||
- Updated SQLite to 3.27.2
|
- Updated SQLite to 3.27.2
|
||||||
@@ -40,5 +41,6 @@ Linux:
|
|||||||
- This data can be viewed and manually modified on the Game Manager.
|
- This data can be viewed and manually modified on the Game Manager.
|
||||||
- Fixed the handling of Wine/Proton games when multiple configurations are detected.
|
- Fixed the handling of Wine/Proton games when multiple configurations are detected.
|
||||||
- Fixed a crash when using "Backup Only" and "New Backups Pending" filters on the Game Manager.
|
- Fixed a crash when using "Backup Only" and "New Backups Pending" filters on the Game Manager.
|
||||||
|
- The Mono and GBM process will now exit cleanly if a critical failure occurs during startup.
|
||||||
|
|
||||||
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
|
||||||
Reference in New Issue
Block a user