Class KioskWindowManagerPolicy¶
Defined in File kiosk_window_manager.h
Inheritance Relationships¶
Base Type¶
public miral::CanonicalWindowManagerPolicy(Class CanonicalWindowManagerPolicy)
Class Documentation¶
-
class KioskWindowManagerPolicy : public miral::CanonicalWindowManagerPolicy¶
Base class for kiosk-style window managers with common input handling Subclasses pass the target window state (fullscreen or maximized) to the constructor.
Public Functions
-
KioskWindowManagerPolicy(WindowManagerTools const &tools)¶
- Parameters:
tools – window manager tools The normal target window state for kiosk is mir_window_state_fullscreen
-
KioskWindowManagerPolicy(WindowManagerTools const &tools, MirWindowState target_state)¶
- Parameters:
tools – window manager tools
target_state – the target window state for kiosk mode (e.g., mir_window_state_fullscreen or mir_window_state_maximized)
-
virtual WindowSpecification place_new_window(ApplicationInfo const &app_info, WindowSpecification const &request) override¶
Given the
app_infoandrequested_specification, this method returns a new miral::WindowSpecification that defines how the new window should be placed.This method is called before advise_new_window.
- Parameters:
app_info – the application requesting a new window
requested_specification – the requested specification with a default position and size
- Returns:
the customized placement
-
virtual bool handle_keyboard_event(MirKeyboardEvent const *event) override¶
Handle a keyboard event originating from the user.
- Parameters:
event – the keyboard event
- Returns:
trueif the policy consumed the event, otherwisefalse
-
virtual bool handle_touch_event(MirTouchEvent const *event) override¶
Handle a touch event originating from the user.
- Parameters:
event – the touch event
- Returns:
trueif the policy consumed the event, otherwisefalse
-
virtual bool handle_pointer_event(MirPointerEvent const *event) override¶
Handle a pointer event originating from the user.
- Parameters:
event – the pointer event
- Returns:
trueif the policy consumed the event, otherwisefalse
-
virtual void handle_modify_window(WindowInfo &window_info, WindowSpecification const &modifications) override¶
Applies the requested modifications.
-
virtual void handle_request_move(WindowInfo &window_info, MirInputEvent const *input_event) override¶
Request from the client to initiate a move.
- Parameters:
window_info – the window
input_event – the input event causing the movement request
-
virtual void handle_request_resize(WindowInfo &window_info, MirInputEvent const *input_event, MirResizeEdge edge) override¶
Request from a client to initiate a resize.
See also
MirResizeEdge - edge resize options
- Parameters:
window_info – the window
input_event – the input event causing the resize request
edge – the edge being resized
Protected Attributes
-
MirWindowState const target_state¶
-
KioskWindowManagerPolicy(WindowManagerTools const &tools)¶