Module: TwitchPlays::OS::X11

Defined in:
lib/twitch_plays/os/x11.rb

Class Method Summary collapse

Class Method Details

.press(key) ⇒ Object



4
5
6
# File 'lib/twitch_plays/os/x11.rb', line 4

def self.press(key)
  `xdotool key #{key}`
end

.touch_move(dx, dy) ⇒ Object



8
9
10
# File 'lib/twitch_plays/os/x11.rb', line 8

def self.touch_move(dx, dy)
  `xdotool mousemove_relative --sync -- #{dx} #{dy}`
end

.touch_pressObject



12
13
14
# File 'lib/twitch_plays/os/x11.rb', line 12

def self.touch_press
  `xdotool mousedown 1`
end

.touch_releaseObject



16
17
18
# File 'lib/twitch_plays/os/x11.rb', line 16

def self.touch_release
  `xdotool mouseup 1`
end