mirror of
https://github.com/clockworkpi/LauncherGoDev.git
synced 2026-03-19 10:22:41 +01:00
add gateway switch
This commit is contained in:
39
Menu/GameShell/10_Settings/GateWay/plugin_init.go
Normal file
39
Menu/GameShell/10_Settings/GateWay/plugin_init.go
Normal file
@@ -0,0 +1,39 @@
|
||||
package GateWay
|
||||
|
||||
import (
|
||||
/*
|
||||
"github.com/veandco/go-sdl2/ttf"
|
||||
|
||||
"github.com/cuu/gogame/surface"
|
||||
"github.com/cuu/gogame/event"
|
||||
"github.com/cuu/gogame/rect"
|
||||
"github.com/cuu/gogame/color"
|
||||
*/
|
||||
"github.com/clockworkpi/LauncherGoDev/sysgo/UI"
|
||||
//"github.com/clockworkpi/LauncherGoDev/sysgo/DBUS"
|
||||
)
|
||||
|
||||
/******************************************************************************/
|
||||
type GatewayPlugin struct {
|
||||
UI.Plugin
|
||||
Page1st *GateWayPage
|
||||
}
|
||||
|
||||
|
||||
func (self *GatewayPlugin) Init( main_screen *UI.MainScreen ) {
|
||||
self.Page1st = NewGateWayPage()
|
||||
self.Page1st.SetScreen( main_screen)
|
||||
self.Page1st.SetName("Gateway switch")
|
||||
self.Page1st.Init()
|
||||
}
|
||||
|
||||
func (self *GatewayPlugin) Run( main_screen *UI.MainScreen ) {
|
||||
if main_screen != nil {
|
||||
main_screen.PushCurPage()
|
||||
main_screen.SetCurPage(self.Page1st)
|
||||
main_screen.Draw()
|
||||
main_screen.SwapAndShow()
|
||||
}
|
||||
}
|
||||
|
||||
var APIOBJ GatewayPlugin
|
||||
Reference in New Issue
Block a user