Class: Selenium::WebDriver::Interactions::PointerPress Private
- Inherits:
-
Interaction
- Object
- Interaction
- Selenium::WebDriver::Interactions::PointerPress
- Includes:
- PointerEventProperties
- Defined in:
- rb/lib/selenium/webdriver/common/interactions/pointer_press.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Actions related to clicking, tapping or pressing the pointer.
Constant Summary collapse
- BUTTONS =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
{left: 0, touch: 0, pen_contact: 0, middle: 1, right: 2, pen_barrel: 2, x1: 3, back: 3, x2: 4, forward: 4}.freeze
- DIRECTIONS =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
{down: :pointerDown, up: :pointerUp}.freeze
Constants included from PointerEventProperties
Selenium::WebDriver::Interactions::PointerEventProperties::VALID
Instance Attribute Summary
Attributes inherited from Interaction
Instance Method Summary collapse
- #encode ⇒ Object private
-
#initialize(source, direction, button, **opts) ⇒ PointerPress
constructor
private
A new instance of PointerPress.
Methods included from PointerEventProperties
Constructor Details
#initialize(source, direction, button, **opts) ⇒ PointerPress
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of PointerPress.
44 45 46 47 48 49 50 |
# File 'rb/lib/selenium/webdriver/common/interactions/pointer_press.rb', line 44 def initialize(source, direction, , **opts) super(source) @direction = assert_direction(direction) @button = () @type = @direction @opts = opts end |
Instance Method Details
#encode ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
52 53 54 |
# File 'rb/lib/selenium/webdriver/common/interactions/pointer_press.rb', line 52 def encode process_opts.merge('type' => type.to_s, 'button' => @button) end |