ffenestri

package
v2.0.0-alpha.26 Latest Latest
Warning

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

Go to latest
Published: Feb 10, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

Index

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

func (c *Client) CallResult(message string)

CallResult contains the result of the call from JS

func (*Client) DarkModeEnabled

func (c *Client) DarkModeEnabled(callbackID string)

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

func (c *Client) NotifyEvent(message string)

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) Quit

func (c *Client) Quit()

Quit the application

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 (c *Client) SetApplicationMenu(applicationMenuJSON string)

func (*Client) SetTrayMenu

func (c *Client) SetTrayMenu(trayMenuJSON string)

func (*Client) UpdateContextMenu

func (c *Client) UpdateContextMenu(contextMenuJSON string)

func (*Client) UpdateTrayMenuLabel

func (c *Client) UpdateTrayMenuLabel(JSON string)

func (*Client) WindowCenter

func (c *Client) WindowCenter()

WindowCenter will hide the window

func (*Client) WindowFullscreen

func (c *Client) WindowFullscreen()

WindowFullscreen will set the window to be fullscreen

func (*Client) WindowHide

func (c *Client) WindowHide()

WindowHide will hide the window

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

func (c *Client) WindowPosition(x int, y int)

WindowPosition will position the window to x,y on the monitor that the window is mostly on

func (*Client) WindowSetColour

func (c *Client) WindowSetColour(colour int)

WindowSetColour sets the window colour

func (*Client) WindowSetMaxSize

func (c *Client) WindowSetMaxSize(width int, height int)

func (*Client) WindowSetMinSize

func (c *Client) WindowSetMinSize(width int, height int)

func (*Client) WindowSetTitle

func (c *Client) WindowSetTitle(title string)

WindowSetTitle sets the window title to the given string

func (*Client) WindowShow

func (c *Client) WindowShow()

WindowShow will show the window

func (*Client) WindowSize

func (c *Client) WindowSize(width int, height int)

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

Jump to

Keyboard shortcuts

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