Index: chrome/renderer/resources/extensions/automation/automation_node.js |
diff --git a/chrome/renderer/resources/extensions/automation/automation_node.js b/chrome/renderer/resources/extensions/automation/automation_node.js |
index b743b3c40fa06d8330d3fd0c59c1a5b674d58922..85ea0472803097061abb555c52dcc32a70b7b95d 100644 |
--- a/chrome/renderer/resources/extensions/automation/automation_node.js |
+++ b/chrome/renderer/resources/extensions/automation/automation_node.js |
@@ -114,6 +114,7 @@ AutomationNodeImpl.prototype = { |
}, |
dispatchEvent: function(eventType) { |
+ console.log('dispatching ' + eventType + ' on ' + this.id); |
not at google - send to devlin
2014/08/19 14:47:48
Safer to use logging.Log(...) from:
https://code.
aboxhall
2014/08/19 15:04:23
Done.
|
var path = []; |
var parent = this.parent(); |
while (parent) { |
@@ -282,6 +283,8 @@ var ATTRIBUTE_BLACKLIST = {'activedescendantId': true, |
*/ |
function AutomationRootNodeImpl(processID, routingID) { |
AutomationNodeImpl.call(this, this); |
+ console.log('AutomationRootNodeImpl constructor: processID=' + processID + |
+ '; routingID=' + routingID + '; this.id=' + this.id); |
this.processID = processID; |
this.routingID = routingID; |
this.axNodeDataCache_ = {}; |
@@ -301,7 +304,6 @@ AutomationRootNodeImpl.prototype = { |
unserialize: function(update) { |
var updateState = { pendingNodes: {}, newNodes: {} }; |
- var oldRootId = this.id; |
if (update.nodeIdToClear < 0) { |
logging.WARNING('Bad nodeIdToClear: ' + update.nodeIdToClear); |
@@ -492,10 +494,15 @@ AutomationRootNodeImpl.prototype = { |
setData_: function(node, nodeData) { |
var nodeImpl = privates(node).impl; |
for (var key in AutomationAttributeDefaults) { |
- if (key in nodeData) |
+ if (key in nodeData) { |
+ if (key == 'id' && nodeImpl[key] != nodeData[key]) { |
+ console.log('Changing ID of node from ' + nodeImpl[key] + ' to ' + |
+ nodeData[key]); |
+ } |
nodeImpl[key] = nodeData[key]; |
- else |
+ } else { |
nodeImpl[key] = AutomationAttributeDefaults[key]; |
+ } |
} |
for (var i = 0; i < AutomationAttributeTypes.length; i++) { |
var attributeType = AutomationAttributeTypes[i]; |