Documentation ¶
Index ¶
- Constants
- func BrowserOpenURL(ctx context.Context, url string)
- func EventsEmit(ctx context.Context, eventName string, optionalData ...interface{})
- func EventsOff(ctx context.Context, eventName string)
- func EventsOn(ctx context.Context, eventName string, ...)
- func EventsOnMultiple(ctx context.Context, eventName string, ...)
- func EventsOnce(ctx context.Context, eventName string, ...)
- func LogDebug(ctx context.Context, message string)
- func LogError(ctx context.Context, message string)
- func LogFatal(ctx context.Context, message string)
- func LogInfo(ctx context.Context, message string)
- func LogPrint(ctx context.Context, message string)
- func LogSetLogLevel(ctx context.Context, level logger.LogLevel)
- func LogTrace(ctx context.Context, message string)
- func LogWarning(ctx context.Context, message string)
- func MenuSetApplicationMenu(ctx context.Context, menu *menu.Menu)
- func MenuUpdateApplicationMenu(ctx context.Context)
- func MessageDialog(ctx context.Context, dialogOptions MessageDialogOptions) (string, error)
- func OpenDirectoryDialog(ctx context.Context, dialogOptions OpenDialogOptions) (string, error)
- func OpenFileDialog(ctx context.Context, dialogOptions OpenDialogOptions) (string, error)
- func OpenMultipleFilesDialog(ctx context.Context, dialogOptions OpenDialogOptions) ([]string, error)
- func Quit(ctx context.Context)
- func SaveFileDialog(ctx context.Context, dialogOptions SaveDialogOptions) (string, error)
- func WindowCenter(ctx context.Context)
- func WindowFullscreen(ctx context.Context)
- func WindowGetPosition(ctx context.Context) (int, int)
- func WindowGetSize(ctx context.Context) (int, int)
- func WindowHide(ctx context.Context)
- func WindowMaximise(ctx context.Context)
- func WindowMinimise(ctx context.Context)
- func WindowReload(ctx context.Context)
- func WindowSetMaxSize(ctx context.Context, width int, height int)
- func WindowSetMinSize(ctx context.Context, width int, height int)
- func WindowSetPosition(ctx context.Context, x int, y int)
- func WindowSetRGBA(ctx context.Context, R, G, B, A uint8)
- func WindowSetSize(ctx context.Context, width int, height int)
- func WindowSetTitle(ctx context.Context, title string)
- func WindowShow(ctx context.Context)
- func WindowToggleMaximise(ctx context.Context)
- func WindowUnfullscreen(ctx context.Context)
- func WindowUnmaximise(ctx context.Context)
- func WindowUnminimise(ctx context.Context)
- type DialogType
- type EnvironmentInfo
- type FileFilter
- type MessageDialogOptions
- type OpenDialogOptions
- type SaveDialogOptions
Constants ¶
const ( InfoDialog = frontend.InfoDialog WarningDialog = frontend.WarningDialog ErrorDialog = frontend.ErrorDialog QuestionDialog = frontend.QuestionDialog )
Variables ¶
This section is empty.
Functions ¶
func BrowserOpenURL ¶
BrowserOpenURL uses the system default browser to open the url
func EventsEmit ¶
EventsEmit pass through
func EventsOnMultiple ¶
func EventsOnMultiple(ctx context.Context, eventName string, callback func(optionalData ...interface{}), counter int)
EventsOnMultiple registers a listener for the given event name, that may be called a maximum of 'counter' times
func EventsOnce ¶
EventsOnce registers a listener for the given event name. After the first callback, the listener is deleted.
func LogSetLogLevel ¶
LogSetLogLevel sets the log level
func LogWarning ¶
LogWarning prints a Warning level message
func MessageDialog ¶
func MessageDialog(ctx context.Context, dialogOptions MessageDialogOptions) (string, error)
MessageDialog show a message dialog to the user
func OpenDirectoryDialog ¶
func OpenDirectoryDialog(ctx context.Context, dialogOptions OpenDialogOptions) (string, error)
OpenDirectoryDialog prompts the user to select a directory
func OpenFileDialog ¶
func OpenFileDialog(ctx context.Context, dialogOptions OpenDialogOptions) (string, error)
OpenFileDialog prompts the user to select a file
func OpenMultipleFilesDialog ¶
func OpenMultipleFilesDialog(ctx context.Context, dialogOptions OpenDialogOptions) ([]string, error)
OpenMultipleFilesDialog prompts the user to select a file
func SaveFileDialog ¶
func SaveFileDialog(ctx context.Context, dialogOptions SaveDialogOptions) (string, error)
SaveFileDialog prompts the user to select a file
func WindowCenter ¶
WindowCenter the window on the current screen
func WindowFullscreen ¶
WindowFullscreen makes the window fullscreen
func WindowReload ¶
WindowReload will reload the window contents
func WindowSetMaxSize ¶
WindowSetMaxSize sets the maximum size of the window
func WindowSetMinSize ¶
WindowSetMinSize sets the minimum size of the window
func WindowSetPosition ¶
WindowSetPosition sets the position of the window
func WindowSetRGBA ¶
func WindowSetSize ¶
WindowSetSize sets the size of the window
func WindowSetTitle ¶
WindowSetTitle sets the title of the window
func WindowToggleMaximise ¶
WindowToggleMaximise the window
func WindowUnfullscreen ¶
WindowUnfullscreen makes the window UnFullscreen
Types ¶
type DialogType ¶
type DialogType = frontend.DialogType
type EnvironmentInfo ¶
type EnvironmentInfo struct {
BuildType string `json:"buildtype"`
}
func Environment ¶
func Environment(ctx context.Context) EnvironmentInfo
type FileFilter ¶
type FileFilter = frontend.FileFilter
FileFilter defines a filter for dialog boxes
type MessageDialogOptions ¶
type MessageDialogOptions = frontend.MessageDialogOptions
MessageDialogOptions contains the options for the Message dialogs, EG Info, Warning, etc runtime methods
type OpenDialogOptions ¶
type OpenDialogOptions = frontend.OpenDialogOptions
OpenDialogOptions contains the options for the OpenDialogOptions runtime method
type SaveDialogOptions ¶
type SaveDialogOptions = frontend.SaveDialogOptions
SaveDialogOptions contains the options for the SaveDialog runtime method