41
main.go
41
main.go
@@ -1,26 +1,23 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"turtlesilicon/pkg/debug"
|
||||
"turtlesilicon/pkg/service"
|
||||
"turtlesilicon/pkg/ui"
|
||||
"turtlesilicon/pkg/utils"
|
||||
|
||||
"strings"
|
||||
|
||||
"epochsilicon/pkg/debug"
|
||||
"epochsilicon/pkg/service"
|
||||
"epochsilicon/pkg/ui"
|
||||
"fyne.io/fyne/v2"
|
||||
"fyne.io/fyne/v2/app"
|
||||
)
|
||||
|
||||
const appVersion = "1.2.4"
|
||||
const appVersion = "0.1.0"
|
||||
|
||||
func main() {
|
||||
TSApp := app.NewWithID("com.tairasu.turtlesilicon")
|
||||
TSWindow := TSApp.NewWindow("TurtleSilicon v" + appVersion)
|
||||
TSWindow.Resize(fyne.NewSize(650, 500))
|
||||
TSWindow.SetFixedSize(true)
|
||||
PEApp := app.NewWithID("com.burkey.epochsilicon")
|
||||
PEWindow := PEApp.NewWindow("EpochSilicon v" + appVersion)
|
||||
PEWindow.Resize(fyne.NewSize(650, 500))
|
||||
PEWindow.SetFixedSize(true)
|
||||
|
||||
// Check for updates
|
||||
/* Check for updates
|
||||
// TODO: Fix updating
|
||||
go func() {
|
||||
prefs, _ := utils.LoadPrefs()
|
||||
updateInfo, updateAvailable, err := utils.CheckForUpdateWithAssets(appVersion)
|
||||
@@ -43,19 +40,21 @@ func main() {
|
||||
return
|
||||
}
|
||||
|
||||
// Show enhanced update dialog
|
||||
ui.ShowUpdateDialog(updateInfo, appVersion, TSWindow)
|
||||
}()
|
||||
|
||||
content := ui.CreateUI(TSWindow)
|
||||
TSWindow.SetContent(content)
|
||||
// Show enhanced update dialog
|
||||
ui.ShowUpdateDialog(updateInfo, appVersion, PEWindow)
|
||||
}()
|
||||
*/
|
||||
|
||||
content := ui.CreateUI(PEWindow)
|
||||
PEWindow.SetContent(content)
|
||||
|
||||
// Set up cleanup when window closes
|
||||
TSWindow.SetCloseIntercept(func() {
|
||||
PEWindow.SetCloseIntercept(func() {
|
||||
debug.Println("Application closing, cleaning up RosettaX87 service...")
|
||||
service.CleanupService()
|
||||
TSApp.Quit()
|
||||
PEApp.Quit()
|
||||
})
|
||||
|
||||
TSWindow.ShowAndRun()
|
||||
PEWindow.ShowAndRun()
|
||||
}
|
||||
|
Reference in New Issue
Block a user