blob: 26bdab9d4df7fd794c5488a5353ab7458a12d694 [file] [log] [blame]
/*
* weinre is available under *either* the terms of the modified BSD license *or* the
* MIT License (2008). See http://opensource.org/licenses/alphabetical for full text.
*
* Copyright (c) 2011 IBM Corporation
*/
requireClass ../common/Weinre
//-----------------------------------------------------------------------------
class WiInspectorImpl
//-----------------------------------------------------------------------------
method reloadPage(callback)
if (callback) {
Weinre.WeinreTargetCommands.sendClientCallback(callback)
}
window.location.reload()
//-----------------------------------------------------------------------------
method highlightDOMNode(/*int*/ nodeId, callback)
var node = Weinre.nodeStore.getNode(nodeId)
if (!node) {
console.log(arguments.callee.signature + " passed an invalid nodeId: " + nodeId)
return
}
Weinre.elementHighlighter.on(node)
if (callback) {
Weinre.WeinreTargetCommands.sendClientCallback(callback)
}
//-----------------------------------------------------------------------------
method hideDOMNodeHighlight(callback)
Weinre.elementHighlighter.off()
if (callback) {
Weinre.WeinreTargetCommands.sendClientCallback(callback)
}