BetrayalPlugin class
A singleton MethodChannel wrapper that communicates with the native plugin.
It will be lazily constructed once it's needed by TrayIcon for the first time.
- Annotations
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
addTray(
Id id) → Future< void> - Creates a new tray icon.
-
disposeTray(
Id id) → Future< void> - Removes and cleans up a single item.
-
hideIcon(
Id id) → Future< void> - Hides a tray icon.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
removeImage(
Id id) → Future< void> - Removes the current image.
-
removeTooltip(
Id id) → Future< void> - Removes the icon's tooltip.
-
reset(
) → Future< void> - Removes and cleans up any icon managed by the plugin.
-
setImageAsStockIcon(
Id id, int stockIconId) → Future< void> - Sets the icon's image, by loading a stock icon.
-
setImageAsWinIcon(
Id id, int resourceId) → Future< void> - Sets the icon's image, by loading a default icon.
-
setImageFromPath(
Id id, String path, { }) → Future< void> - Sets the icon's image, by loading an .ico file.
-
setImageFromPixels(
Id id, int width, int height, Int32List pixels) → Future< void> - Sets the icon's image, by loading a byte buffer.
-
setTooltip(
Id id, String tooltip) → Future< void> - Sets the icon's tooltip.
-
showIcon(
Id id) → Future< void> - Displays a tray icon.
-
subscribeTo(
Id id, WinEvent event) → Future< void> -
Asks the plugin to call
_handleMethod
wheneverid
+event
happens. -
toString(
) → String -
A string representation of this object.
inherited
-
unsubscribeFrom(
Id id, WinEvent event) → Future< void> -
Notifies the plugin that events that the pattern
id
+event
can be ignored.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- instance → BetrayalPlugin
-
Retrieves the singleton instance.
no setter
- preferredImageSize → Size
-
The standard icon size
no setter
- preferredLargeImageSize → Size
-
The standard icon size
no setter
- primaryAndSecondarySwapped → bool
-
If the user has inverted their mouse buttons.
no setter