Documentation ¶
Index ¶
- type Application
- type Client
- func (c *Client) CallResult(message string)
- func (c *Client) DarkModeEnabled(callbackID string)
- func (c *Client) DeleteTrayMenuByID(id string)
- func (c *Client) MessageDialog(dialogOptions *dialog.MessageDialog, callbackID string)
- func (c *Client) NotifyEvent(message string)
- func (c *Client) OpenDialog(dialogOptions *dialog.OpenDialog, callbackID string)
- func (c *Client) Quit()
- func (c *Client) SaveDialog(dialogOptions *dialog.SaveDialog, callbackID string)
- func (c *Client) SetApplicationMenu(applicationMenuJSON string)
- func (c *Client) SetTrayMenu(trayMenuJSON string)
- func (c *Client) UpdateContextMenu(contextMenuJSON string)
- func (c *Client) UpdateTrayMenuLabel(JSON string)
- func (c *Client) WindowCenter()
- func (c *Client) WindowFullscreen()
- func (c *Client) WindowHide()
- func (c *Client) WindowMaximise()
- func (c *Client) WindowMinimise()
- func (c *Client) WindowPosition(x int, y int)
- func (c *Client) WindowSetColour(colour int)
- func (c *Client) WindowSetMaxSize(width int, height int)
- func (c *Client) WindowSetMinSize(width int, height int)
- func (c *Client) WindowSetTitle(title string)
- func (c *Client) WindowShow()
- func (c *Client) WindowSize(width int, height int)
- func (c *Client) WindowUnFullscreen()
- func (c *Client) WindowUnmaximise()
- func (c *Client) WindowUnminimise()
- type DispatchClient
- type Dispatcher
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Application ¶
type Application struct {
// contains filtered or unexported fields
}
Application is our main application object
func NewApplication ¶
func NewApplication(logger *logger.Logger) *Application
NewApplication creates a new Application with the default config
func NewApplicationWithConfig ¶
func NewApplicationWithConfig(config *options.App, logger *logger.Logger, menuManager *menumanager.Manager) *Application
NewApplicationWithConfig creates a new application based on the given config
func (*Application) Run ¶
func (a *Application) Run(incomingDispatcher Dispatcher, bindings string, debug bool) error
Run the application
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is our implentation of messageDispatcher.Client
func (*Client) CallResult ¶
CallResult contains the result of the call from JS
func (*Client) DarkModeEnabled ¶
func (*Client) DeleteTrayMenuByID ¶
func (*Client) MessageDialog ¶
func (c *Client) MessageDialog(dialogOptions *dialog.MessageDialog, callbackID string)
MessageDialog will open a message dialog with the given options
func (*Client) NotifyEvent ¶
NotifyEvent will pass on the event message to the frontend
func (*Client) OpenDialog ¶
func (c *Client) OpenDialog(dialogOptions *dialog.OpenDialog, callbackID string)
OpenDialog will open a dialog with the given title and filter
func (*Client) SaveDialog ¶
func (c *Client) SaveDialog(dialogOptions *dialog.SaveDialog, callbackID string)
SaveDialog will open a dialog with the given title and filter
func (*Client) SetApplicationMenu ¶
func (*Client) SetTrayMenu ¶
func (*Client) UpdateContextMenu ¶
func (*Client) UpdateTrayMenuLabel ¶
func (*Client) WindowFullscreen ¶
func (c *Client) WindowFullscreen()
WindowFullscreen will set the window to be fullscreen
func (*Client) WindowMaximise ¶
func (c *Client) WindowMaximise()
WindowMaximise will maximise the window
func (*Client) WindowMinimise ¶
func (c *Client) WindowMinimise()
WindowMinimise will minimise the window
func (*Client) WindowPosition ¶
WindowPosition will position the window to x,y on the monitor that the window is mostly on
func (*Client) WindowSetColour ¶
WindowSetColour sets the window colour
func (*Client) WindowSetMaxSize ¶
func (*Client) WindowSetMinSize ¶
func (*Client) WindowSetTitle ¶
WindowSetTitle sets the window title to the given string
func (*Client) WindowSize ¶
WindowSize will resize the window to the given width and height
func (*Client) WindowUnFullscreen ¶
func (c *Client) WindowUnFullscreen()
WindowUnFullscreen will unfullscreen the window
func (*Client) WindowUnmaximise ¶
func (c *Client) WindowUnmaximise()
WindowUnmaximise will unmaximise the window
func (*Client) WindowUnminimise ¶
func (c *Client) WindowUnminimise()
WindowUnminimise will unminimise the window
type DispatchClient ¶
type DispatchClient interface {
SendMessage(string)
}
DispatchClient is the means for passing messages to the backend
type Dispatcher ¶
type Dispatcher interface {
RegisterClient(client messagedispatcher.Client) *messagedispatcher.DispatchClient
}
Dispatcher is what we register out client with