Class: Rubydraw::MouseState
Overview
An instance of this class is returned every time you call Rubydraw.mouse_state.
Instance Attribute Summary collapse
-
#button ⇒ Object
readonly
Returns the value of attribute button.
-
#position ⇒ Object
readonly
Returns the value of attribute position.
Instance Method Summary collapse
-
#initialize(button, position) ⇒ MouseState
constructor
A new instance of MouseState.
- #to_ary ⇒ Object
- #x ⇒ Object
- #y ⇒ Object
Constructor Details
#initialize(button, position) ⇒ MouseState
Returns a new instance of MouseState.
7 8 9 |
# File 'lib/rubydraw/mouse_state.rb', line 7 def initialize(, position) , @position = , position end |
Instance Attribute Details
#button ⇒ Object (readonly)
Returns the value of attribute button.
5 6 7 |
# File 'lib/rubydraw/mouse_state.rb', line 5 def end |
#position ⇒ Object (readonly)
Returns the value of attribute position.
5 6 7 |
# File 'lib/rubydraw/mouse_state.rb', line 5 def position @position end |