module WebkitRemote::Client::Page
API for the Page
domain.
Attributes
page_events[R]
@return [Boolean] true if the debugger generates Page.* events
Public Instance Methods
initialize_page()
click to toggle source
page_events=(new_page_events)
click to toggle source
Enables or disables the generation of events in the Page
domain.
@param [Boolean] new_page_events if true, the browser debugger will
generate Page.* events
# File lib/webkit_remote/client/page.rb, line 36 def page_events=(new_page_events) new_page_events = !!new_page_events if new_page_events != page_events @rpc.call(new_page_events ? 'Page.enable' : 'Page.disable') @page_events = new_page_events end new_page_events end
reload(opts = {})
click to toggle source
Reloads the current page.
@param [Hash] opts quirky behavior bits @option opts [Boolean] skip_cache if true, the cache is not used; this is
what happens when the user presses Shift + the refresh combo
@option opts [String] onload a JavaScript that will be injected in all the
page's frames after reloading
@return [WebkitRemote::Client] self
# File lib/webkit_remote/client/page.rb, line 24 def reload(opts = {}) options = {} options[:ignoreCache] = true if opts[:skip_cache] options[:scriptToEvaluateOnLoad] = opts[:onload] if opts[:onload] @rpc.call 'Page.reload', options self end