state

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 24, 2022 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	CurrentGame *config.Game
	App         fyne.App
	Window      fyne.Window
)

Functions

func ClosePopupWindow

func ClosePopupWindow()

func GetBaseDir

func GetBaseDir() string

func GetBaseDirBinding

func GetBaseDirBinding() binding.String

func RefreshMenu

func RefreshMenu()

func RegisterMainMenu

func RegisterMainMenu(m Screen)

func RegisterScreen

func RegisterScreen(gui GUI, screen Screen)

func SetBaseDir

func SetBaseDir(dir string)

func SetCurrentGameFromString

func SetCurrentGameFromString(s string) bool

func ShowPreviousScreen

func ShowPreviousScreen()

func ShowScreen

func ShowScreen(gui GUI, args ...interface{})

func UpdateCurrentScreen

func UpdateCurrentScreen()

Types

type GUI

type GUI byte
const (
	None GUI = iota
	LocalMods
	DiscoverMods
	ModAuthor
	ConfigInstaller
)

func GetCurrentGUI

func GetCurrentGUI() GUI

type Screen

type Screen interface {
	PreDraw(w fyne.Window, args ...interface{}) error
	Draw(w fyne.Window)
	DrawAsDialog(window fyne.Window)
	OnClose()
}

func GetScreen

func GetScreen(gui GUI) Screen

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL