OverlayWindow
OverlayButton
Events:
Methods:
- Add
Adds this button to the screen.
- BindTo (Window As OverlayWindow)
Associates this button with the given overlay window so the button is automatically added or removed when the window is opened or closed, and automatically shown or hidden according to the window visibility.
- Initialize (X As Int, Y As Int, Width As Int, Height As Int, EventPrefix As String)
Creates a button at the specified position. The button is displayed after calling Add.
Width: Width of the button.
Height: Height of the button.
EventPrefix: Prefix of the Click and LongClick events.
- IsAdded As Boolean
Returns True if the button was added by a call to Add (or a call to Open if bound).
- IsInitialized As Boolean
- Remove
Removes this button from the screen.
- SetPosition (X As Int, Y As Int)
- SetSize (Width As Int, Height As Int)
- SetStateImages (Up As Drawable, Down As Drawable, Disabled As Drawable)
Sets the images for the Up, Down and Disabled states. Pass Null if you do not want to set an image.
- UnbindFrom (Window As OverlayWindow)
Breaks the association between this button and the given overlay window.
Properties:
- Button As Button [read only]
Returns the wrapped button.
- Height As Int
- Width As Int
- X As Int
- Y As Int
OverlayWindow
Events:
- Click
- LongClick
- Touch (Action As Int, X As Float, Y As Float, ScreenX As Float, ScreenY As Float)
Fields:
- TOUCH_ALL As Int
The window receives all touch events.
- TOUCH_INSIDE As Int
The window receives touch events inside the window.
- TOUCH_NONE As Int
The window does not receive touch events.
Methods:
- Close
Closes this window. The bound buttons are removed, if any.
- Initialize (X As Int, Y As Int, Width As Int, Height As Int, EventPrefix As String)
Creates an empty overlay window at the specified position. The window is displayed after calling Open.
The window has a panel which can contain child views. Note that these views cannot acquire the focus.
Width: Width of the window.
Height: Height of the window.
EventPrefix: Prefix of the Touch, Click and LongClick events.
- IsInitialized As Boolean
- IsOpen As Boolean
Returns True if the window was opened by a call to Open.
- Open
Opens this window. The bound buttons are added, if any.
- SetPosition (X As Int, Y As Int)
- SetSize (Width As Int, Height As Int)
Permissions:
- android.permission.SYSTEM_ALERT_WINDOW
Properties:
- Height As Int
- Panel As Panel [read only]
Returns the window panel.
- TouchMode As Int
Gets or sets the touch mode (one of the TOUCH_ constants). Default = TOUCH_INSIDE.
- Visible As Boolean
Gets or sets the window visibility. The bound buttons, if any, are shown or hidden accordingly.
- Width As Int
- X As Int
- Y As Int
Author: F.Leneuf-Magaud/Informatix