Changeset View
Changeset View
Standalone View
Standalone View
libinput/device.h
Context not available. | |||||
203 | bool naturalScrollEnabledByDefault() const { | 203 | bool naturalScrollEnabledByDefault() const { | ||
---|---|---|---|---|---|
204 | return m_naturalScrollEnabledByDefault; | 204 | return m_naturalScrollEnabledByDefault; | ||
205 | } | 205 | } | ||
206 | enum libinput_config_scroll_method defaultScrollMethod() const { | ||||
207 | return m_defaultScrollMethod; | ||||
208 | } | ||||
209 | quint32 defaultScrollMethodToInt() const { | ||||
210 | return (quint32) m_defaultScrollMethod; | ||||
211 | } | ||||
206 | bool scrollTwoFingerEnabledByDefault() const { | 212 | bool scrollTwoFingerEnabledByDefault() const { | ||
207 | return m_defaultScrollMethod == LIBINPUT_CONFIG_SCROLL_2FG; | 213 | return m_defaultScrollMethod == LIBINPUT_CONFIG_SCROLL_2FG; | ||
208 | } | 214 | } | ||
Context not available. | |||||
223 | return m_naturalScroll; | 229 | return m_naturalScroll; | ||
224 | } | 230 | } | ||
225 | void setNaturalScroll(bool set); | 231 | void setNaturalScroll(bool set); | ||
226 | bool setScrollMethod(bool set, enum libinput_config_scroll_method method); | 232 | void setScrollMethod(bool set, enum libinput_config_scroll_method method); | ||
227 | bool isScrollTwoFinger() const { | 233 | bool isScrollTwoFinger() const { | ||
228 | return m_scrollMethod & LIBINPUT_CONFIG_SCROLL_2FG; | 234 | return m_scrollMethod & LIBINPUT_CONFIG_SCROLL_2FG; | ||
229 | } | 235 | } | ||
230 | void setScrollTwoFinger(bool set); | 236 | void setScrollTwoFinger(bool set) { | ||
237 | setScrollMethod(set, LIBINPUT_CONFIG_SCROLL_2FG); | ||||
238 | } | ||||
231 | bool isScrollEdge() const { | 239 | bool isScrollEdge() const { | ||
232 | return m_scrollMethod & LIBINPUT_CONFIG_SCROLL_EDGE; | 240 | return m_scrollMethod & LIBINPUT_CONFIG_SCROLL_EDGE; | ||
233 | } | 241 | } | ||
234 | void setScrollEdge(bool set); | 242 | void setScrollEdge(bool set) { | ||
243 | setScrollMethod(set, LIBINPUT_CONFIG_SCROLL_EDGE); | ||||
244 | } | ||||
235 | bool isScrollOnButtonDown() const { | 245 | bool isScrollOnButtonDown() const { | ||
236 | return m_scrollMethod & LIBINPUT_CONFIG_SCROLL_ON_BUTTON_DOWN; | 246 | return m_scrollMethod & LIBINPUT_CONFIG_SCROLL_ON_BUTTON_DOWN; | ||
237 | } | 247 | } | ||
238 | void setScrollOnButtonDown(bool set); | 248 | void setScrollOnButtonDown(bool set) { | ||
249 | setScrollMethod(set, LIBINPUT_CONFIG_SCROLL_ON_BUTTON_DOWN); | ||||
250 | } | ||||
251 | void activateScrollMethodFromInt(quint32 method) { | ||||
252 | setScrollMethod(true, (libinput_config_scroll_method) method); | ||||
253 | } | ||||
239 | quint32 scrollButton() const { | 254 | quint32 scrollButton() const { | ||
240 | return m_scrollButton; | 255 | return m_scrollButton; | ||
241 | } | 256 | } | ||
Context not available. |