Blender V5.0
GWL_Seat Struct Reference

Public Attributes

struct { 
   wl_seat *   seat = nullptr 
   wl_pointer *   pointer = nullptr 
   wl_touch *   touch = nullptr 
   wl_keyboard *   keyboard = nullptr 
   wl_surface *   surface_window_focus_dnd = nullptr 
   wl_data_device *   data_device = nullptr 
wl
struct { 
   zwp_tablet_seat_v2 *   tablet_seat = nullptr 
   zwp_relative_pointer_v1 *   relative_pointer = nullptr 
   zwp_locked_pointer_v1 *   locked_pointer = nullptr 
   zwp_confined_pointer_v1 *   confined_pointer = nullptr 
   zwp_primary_selection_device_v1 *   primary_selection_device = nullptr 
   std::unordered_set< zwp_tablet_tool_v2 * >   tablet_tools 
wp
struct { 
   xkb_context *   context = nullptr 
   xkb_compose_table *   compose_table = nullptr 
   xkb_compose_state *   compose_state = nullptr 
   xkb_state *   state = nullptr 
   xkb_state *   state_empty = nullptr 
   xkb_state *   state_empty_with_shift = nullptr 
   xkb_state *   state_empty_with_numlock = nullptr 
   xkb_layout_index_t   layout_active = 0 
xkb
GHOST_SystemWaylandsystem = nullptr
std::string name
uint32_t cursor_source_serial = 0
GWL_SeatStatePointer pointer
GWL_SeatStatePointer_Events pointer_events
GWL_SeatStatePointerScroll pointer_scroll
GWL_SeatStatePointerGesture_Pinch pointer_gesture_pinch
bool use_pointer_scroll_smooth_as_discrete = false
GWL_SeatStatePointer tablet
GWL_SeatStatePointer touch
GWL_SeatStateKeyboard keyboard
struct { 
   bool   is_touching = false 
   uint32_t   down_id = 0 
   bool   down_pending = false 
   uint64_t   down_event_time_ms = 0 
   bool   up_pending = false 
   uint64_t   up_event_time_ms = 0 
   bool   motion_pending = false 
   uint64_t   motion_event_time_ms = 0 
touch_state
bool use_pointer_software_confine = false
wl_fixed_t grab_lock_xy [2] = {0, 0}
GWL_Cursor cursor
bool xkb_use_non_latin_workaround = false
GWL_KeyboardDepressedState key_depressed
xkb_mod_index_t xkb_keymap_mod_index [MOD_INDEX_NUM] = {XKB_MOD_INVALID}
xkb_mod_index_t xkb_keymap_mod_index_mod2 = XKB_MOD_INVALID
xkb_mod_index_t xkb_keymap_mod_index_numlock = XKB_MOD_INVALID
struct { 
   int32_t   rate = 0 
   int32_t   delay = 0 
   GHOST_ITimerTask *   timer = nullptr 
key_repeat
GWL_DataOfferdata_offer_dnd = nullptr
std::mutex data_offer_dnd_mutex
GWL_DataOfferdata_offer_copy_paste = nullptr
std::mutex data_offer_copy_paste_mutex
std::optional< GHOST_TSuccessdata_offer_copy_paste_has_image = std::nullopt
GWL_DataSourcedata_source = nullptr
std::mutex data_source_mutex
GWL_PrimarySelection primary_selection
uint32_t data_source_serial = 0

Detailed Description

Definition at line 1060 of file GHOST_SystemWayland.cc.

Member Data Documentation

◆ compose_state

xkb_compose_state* GWL_Seat::compose_state = nullptr

The compose state is expected to use the keyboard state (check for null before use).

Definition at line 1109 of file GHOST_SystemWayland.cc.

Referenced by gwl_registry_wl_seat_remove(), gwl_seat_key_repeat_timer_fn(), keyboard_handle_key(), and keyboard_handle_keymap().

◆ compose_table

xkb_compose_table* GWL_Seat::compose_table = nullptr

The compose key table (check for null before use).

Definition at line 1106 of file GHOST_SystemWayland.cc.

Referenced by gwl_registry_wl_seat_add(), gwl_registry_wl_seat_remove(), and keyboard_handle_keymap().

◆ confined_pointer

zwp_confined_pointer_v1* GWL_Seat::confined_pointer = nullptr

◆ context

xkb_context* GWL_Seat::context = nullptr

◆ cursor

◆ cursor_source_serial

uint32_t GWL_Seat::cursor_source_serial = 0

Use to check if the last cursor input was tablet or pointer.

Definition at line 1143 of file GHOST_SystemWayland.cc.

Referenced by gwl_seat_state_pointer_active(), pointer_handle_enter(), tablet_tool_handle_proximity_in(), and touch_seat_handle_down().

◆ data_device

◆ data_offer_copy_paste

◆ data_offer_copy_paste_has_image

std::optional<GHOST_TSuccess> GWL_Seat::data_offer_copy_paste_has_image = std::nullopt

Cache the result of GHOST_SystemWayland::hasClipboardImage as checking the file header every time will be expensive, especially if this happens on redraw. Reset whenever the data offer changes.

Definition at line 1241 of file GHOST_SystemWayland.cc.

Referenced by data_device_handle_selection(), and GHOST_SystemWayland::hasClipboardImage().

◆ data_offer_copy_paste_mutex

std::mutex GWL_Seat::data_offer_copy_paste_mutex

◆ data_offer_dnd

◆ data_offer_dnd_mutex

◆ data_source

◆ data_source_mutex

std::mutex GWL_Seat::data_source_mutex

◆ data_source_serial

uint32_t GWL_Seat::data_source_serial = 0

Last input device that was active (pointer/tablet/keyboard).

Note
Multi-touch gestures don't set this value, if there is some use-case where this is needed - assignments can be added.

Definition at line 1254 of file GHOST_SystemWayland.cc.

Referenced by keyboard_handle_key(), keyboard_handle_modifiers(), pointer_handle_button(), GHOST_SystemWayland::putClipboardImage(), system_clipboard_put(), system_clipboard_put_primary_selection(), tablet_tool_handle_button(), tablet_tool_handle_down(), tablet_tool_handle_proximity_in(), and GHOST_SystemWayland::wl_seat_active_get_with_input_serial().

◆ delay

int32_t GWL_Seat::delay = 0

Time (milliseconds) after which to start repeating keys.

Definition at line 1218 of file GHOST_SystemWayland.cc.

Referenced by gwl_seat_key_repeat_timer_add(), and keyboard_handle_repeat_info().

◆ down_event_time_ms

uint64_t GWL_Seat::down_event_time_ms = 0

Definition at line 1177 of file GHOST_SystemWayland.cc.

Referenced by touch_seat_handle_down(), and touch_seat_handle_frame().

◆ down_id

uint32_t GWL_Seat::down_id = 0

◆ down_pending

bool GWL_Seat::down_pending = false

Definition at line 1176 of file GHOST_SystemWayland.cc.

Referenced by touch_seat_handle_down(), and touch_seat_handle_frame().

◆ grab_lock_xy

wl_fixed_t GWL_Seat::grab_lock_xy[2] = {0, 0}

The cursor location (in pixel-space) when hidden grab started (GHOST_kGrabHide).

Definition at line 1188 of file GHOST_SystemWayland.cc.

Referenced by GHOST_SystemWayland::window_cursor_grab_set().

◆ is_touching

bool GWL_Seat::is_touching = false

◆ key_depressed

◆ [struct]

◆ keyboard [1/2]

GWL_SeatStateKeyboard GWL_Seat::keyboard

Definition at line 1164 of file GHOST_SystemWayland.cc.

◆ keyboard [2/2]

◆ layout_active

xkb_layout_index_t GWL_Seat::layout_active = 0

The active layout, where a single #xkb_keymap may have multiple layouts.

Definition at line 1131 of file GHOST_SystemWayland.cc.

Referenced by gwl_seat_key_layout_active_state_update_mask(), keyboard_handle_keymap(), and keyboard_handle_modifiers().

◆ locked_pointer

zwp_locked_pointer_v1* GWL_Seat::locked_pointer = nullptr

◆ motion_event_time_ms

uint64_t GWL_Seat::motion_event_time_ms = 0

◆ motion_pending

bool GWL_Seat::motion_pending = false

◆ name

std::string GWL_Seat::name

Definition at line 1140 of file GHOST_SystemWayland.cc.

◆ pointer [1/2]

GWL_SeatStatePointer GWL_Seat::pointer

Definition at line 1145 of file GHOST_SystemWayland.cc.

◆ pointer [2/2]

◆ pointer_events

◆ pointer_gesture_pinch

◆ pointer_scroll

◆ primary_selection

◆ primary_selection_device

zwp_primary_selection_device_v1* GWL_Seat::primary_selection_device = nullptr

◆ rate

int32_t GWL_Seat::rate = 0

Key repetition in character per second.

Definition at line 1216 of file GHOST_SystemWayland.cc.

Referenced by gwl_seat_key_repeat_timer_add(), keyboard_handle_enter(), keyboard_handle_key(), and keyboard_handle_repeat_info().

◆ relative_pointer

zwp_relative_pointer_v1* GWL_Seat::relative_pointer = nullptr

◆ seat

◆ state

◆ state_empty

xkb_state* GWL_Seat::state_empty = nullptr

Keep a state with no modifiers active, use for symbol lookups.

Definition at line 1115 of file GHOST_SystemWayland.cc.

Referenced by gwl_registry_wl_seat_remove(), gwl_seat_key_layout_active_state_update_mask(), keyboard_handle_key(), and keyboard_handle_keymap().

◆ state_empty_with_numlock

xkb_state* GWL_Seat::state_empty_with_numlock = nullptr

Keep a state with number-lock enabled, use to access predictable key-pad symbols. If number-lock is not supported by the key-map, this is set to nullptr.

Definition at line 1126 of file GHOST_SystemWayland.cc.

Referenced by gwl_registry_wl_seat_remove(), gwl_seat_key_layout_active_state_update_mask(), keyboard_handle_key(), and keyboard_handle_keymap().

◆ state_empty_with_shift

xkb_state* GWL_Seat::state_empty_with_shift = nullptr

Keep a state with shift enabled, use to access predictable number access for AZERTY keymaps. If shift is not supported by the key-map, this is set to nullptr.

Definition at line 1121 of file GHOST_SystemWayland.cc.

Referenced by gwl_registry_wl_seat_remove(), gwl_seat_key_layout_active_state_update_mask(), keyboard_handle_key(), and keyboard_handle_keymap().

◆ surface_window_focus_dnd

◆ system

◆ tablet

◆ tablet_seat

zwp_tablet_seat_v2* GWL_Seat::tablet_seat = nullptr

◆ tablet_tools

std::unordered_set<zwp_tablet_tool_v2 *> GWL_Seat::tablet_tools

◆ timer

◆ touch [1/2]

GWL_SeatStatePointer GWL_Seat::touch

Mostly this can be interchanged with pointer key differences are:

Definition at line 1162 of file GHOST_SystemWayland.cc.

◆ touch [2/2]

◆ [struct]

struct { ... } GWL_Seat::touch_state

This structure accumulates touch input that will be applied on the next frame event.

Currently only track one active contact point on the screen and map it to pointer motion and left-clicks. Multi-touch, pinching & swiping are not yet supported.

Referenced by touch_seat_handle_down(), touch_seat_handle_frame(), touch_seat_handle_motion(), and touch_seat_handle_up().

◆ up_event_time_ms

uint64_t GWL_Seat::up_event_time_ms = 0

Definition at line 1179 of file GHOST_SystemWayland.cc.

Referenced by touch_seat_handle_frame(), and touch_seat_handle_up().

◆ up_pending

bool GWL_Seat::up_pending = false

Definition at line 1178 of file GHOST_SystemWayland.cc.

Referenced by touch_seat_handle_frame(), and touch_seat_handle_up().

◆ use_pointer_scroll_smooth_as_discrete

◆ use_pointer_software_confine

◆ [struct]

◆ [struct]

◆ [struct]

◆ xkb_keymap_mod_index

xkb_mod_index_t GWL_Seat::xkb_keymap_mod_index[MOD_INDEX_NUM] = {XKB_MOD_INVALID}

Cache result of xkb_keymap_mod_get_index so every time a modifier is accessed a string lookup isn't required. Be sure to check for #XKB_MOD_INVALID before using.

Definition at line 1204 of file GHOST_SystemWayland.cc.

Referenced by GHOST_SystemWayland::getModifierKeys(), gwl_seat_key_layout_active_state_update_mask(), and keyboard_handle_keymap().

◆ xkb_keymap_mod_index_mod2

xkb_mod_index_t GWL_Seat::xkb_keymap_mod_index_mod2 = XKB_MOD_INVALID

Cache result of xkb_keymap_mod_get_index(keymap, XKB_MOD_NAME_NUM).

Definition at line 1210 of file GHOST_SystemWayland.cc.

Referenced by gwl_seat_key_layout_active_state_update_mask(), and keyboard_handle_keymap().

◆ xkb_keymap_mod_index_numlock

xkb_mod_index_t GWL_Seat::xkb_keymap_mod_index_numlock = XKB_MOD_INVALID

Cache result of xkb_keymap_mod_get_index(keymap, "NumLock").

Definition at line 1212 of file GHOST_SystemWayland.cc.

Referenced by gwl_seat_key_layout_active_state_update_mask(), and keyboard_handle_keymap().

◆ xkb_use_non_latin_workaround

bool GWL_Seat::xkb_use_non_latin_workaround = false

Definition at line 1193 of file GHOST_SystemWayland.cc.

Referenced by keyboard_handle_key(), and keyboard_handle_keymap().


The documentation for this struct was generated from the following file: