70 struct wrong_type : std::logic_error {
wrong_type() : std::logic_error(
"neogfx::mouse_cursor::wrong_type") {} };
78 return std::holds_alternative<mouse_system_cursor>(
iType);
83 return std::get<mouse_system_cursor>(
iType);
92 return static_cast<mouse_button>(
static_cast<uint32_t
>(aLhs) |
static_cast<uint32_t
>(aRhs));
97 return static_cast<mouse_button>(
static_cast<uint32_t
>(aLhs)&
static_cast<uint32_t
>(aRhs));
102 return static_cast<mouse_button>(~static_cast<uint32_t>(aLhs));
119 return static_cast<mouse_wheel>(
static_cast<uint32_t
>(aLhs) |
static_cast<uint32_t
>(aRhs));
124 return static_cast<mouse_wheel>(
static_cast<uint32_t
>(aLhs)&
static_cast<uint32_t
>(aRhs));
129 return static_cast<mouse_wheel>(~static_cast<uint32_t>(aLhs));
158 struct no_grab : std::logic_error {
no_grab() : std::logic_error(
"neogfx::i_mouse::no_grab") {} };
183 static uuid const&
iid() {
static uuid const sIid{ 0xe974988, 0xcfe0, 0x46e8, 0xaad0, { 0xaf, 0xaa, 0x7a, 0x92, 0x7a, 0xf6 } };
return sIid; }
virtual bool mouse_wheel_scrolled(mouse_wheel aWheel, const point &aPosition, delta aDelta, key_modifiers_e aKeyModifiers)=0
virtual bool is_mouse_grabbed_by(i_mouse_handler &aMouseHandler) const =0
virtual void release_capture()=0
virtual bool capturing() const =0
static uuid const & iid()
bool is_button_pressed(mouse_button aButton) const
virtual mouse_capture_type capture_type() const =0
virtual i_mouse_handler & grabber() const =0
virtual mouse_button button_state() const =0
virtual point position() const =0
virtual void capture(i_surface &aTarget)=0
declare_event(button_pressed, mouse_button) declare_event(button_released
virtual void capture_raw(i_surface &aTarget)=0
virtual void grab_mouse(i_mouse_handler &aMouseHandler)=0
virtual void ungrab_mouse(i_mouse_handler &aMouseHandler)=0
virtual bool is_mouse_grabbed() const =0
virtual bool is_front_grabber(i_mouse_handler &aMouseHandler) const =0
virtual i_surface & capture_target() const =0
bool is_system_cursor() const
mouse_cursor(mouse_system_cursor aSystemCursor)
neolib::variant< mouse_system_cursor > cursor_type
mouse_system_cursor system_cursor() const
constexpr font_style & operator&=(font_style &aLhs, font_style aRhs)
constexpr style_aspect operator&(style_aspect aLhs, style_aspect aRhs)
audio_channel operator~(audio_channel lhs)
constexpr font_style & operator|=(font_style &aLhs, font_style aRhs)
constexpr style_aspect operator|(style_aspect aLhs, style_aspect aRhs)
#define declare_event(declName,...)