Module: WebkitRemote::Client::Dom

Defined in:
lib/webkit_remote_unstable/dom.rb

Overview

Unstable API for the DOM domain.

Instance Method Summary collapse

Instance Method Details

#dom_node_at(x, y) ⇒ Object

Retrieves the node at a given location.

Parameters:

  • x (Integer)

    the X coordinate, in window coordinates

  • y (Integer)

    the Y coordinate, in window coordinates



11
12
13
14
# File 'lib/webkit_remote_unstable/dom.rb', line 11

def dom_node_at(x, y)
  result = @rpc.call 'DOM.getNodeForLocation', x: x.to_i, y: y.to_i
  dom_node result['nodeId']
end

#initialize_dom_unstableObject



17
18
# File 'lib/webkit_remote_unstable/dom.rb', line 17

def initialize_dom_unstable
end