Class: Hokusai::Automation::DriverCommands::TriggerMouseMove

Inherits:
Base
  • Object
show all
Defined in:
ui/src/hokusai/automation/driver_commands/trigger_mouse.rb

Instance Attribute Summary

Attributes inherited from Base

#last_parent, #request_id, #state, #status

Instance Method Summary collapse

Methods inherited from Base

#initialize, #matches_block, #matches_blocks, #mouse_center, #mouse_move

Constructor Details

This class inherits a constructor from Hokusai::Automation::DriverCommands::Base

Instance Method Details

#execute(blocks, canvas, input) ⇒ Object



126
127
128
129
130
# File 'ui/src/hokusai/automation/driver_commands/trigger_mouse.rb', line 126

def execute(blocks, canvas, input)
  mouse_move(x, y, input) unless done?

  done!
end

#on_completeObject



122
123
124
# File 'ui/src/hokusai/automation/driver_commands/trigger_mouse.rb', line 122

def on_complete
  return true
end

#xObject



114
115
116
# File 'ui/src/hokusai/automation/driver_commands/trigger_mouse.rb', line 114

def x
  state[:x]
end

#yObject



118
119
120
# File 'ui/src/hokusai/automation/driver_commands/trigger_mouse.rb', line 118

def y
  state[:y]
end