Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(313)

Side by Side Diff: chrome/renderer/resources/extensions/automation/automation_tree.js

Issue 273323002: Convert snakecase enum names to camelcase when stringified. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: final changes Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/renderer/resources/extensions/automation_custom_bindings.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 var Event = require('event_bindings').Event; 5 var Event = require('event_bindings').Event;
6 var AutomationNode = require('automationNode').AutomationNode; 6 var AutomationNode = require('automationNode').AutomationNode;
7 var utils = require('utils'); 7 var utils = require('utils');
8 8
9 // Maps an attribute to its default value in an invalidated node. 9 // Maps an attribute to its default value in an invalidated node.
10 // These attributes are taken directly from the Automation idl. 10 // These attributes are taken directly from the Automation idl.
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 } 129 }
130 130
131 for (var k = 0, oldId; oldId = oldChildIDs[k]; k++) { 131 for (var k = 0, oldId; oldId = oldChildIDs[k]; k++) {
132 // However, we must invalidate all old child ids that are no longer 132 // However, we must invalidate all old child ids that are no longer
133 // children. 133 // children.
134 if (!newChildIDsHash[oldId]) { 134 if (!newChildIDsHash[oldId]) {
135 this.invalidate(this.get(oldId)); 135 this.invalidate(this.get(oldId));
136 } 136 }
137 } 137 }
138 138
139 if (nodeData.role == 'root_web_area' || nodeData.role == 'desktop') { 139 if (nodeData.role == 'rootWebArea' || nodeData.role == 'desktop') {
140 this.root = node; 140 this.root = node;
141 didUpdateRoot = true; 141 didUpdateRoot = true;
142 } 142 }
143 for (var key in AutomationAttributeDefaults) { 143 for (var key in AutomationAttributeDefaults) {
144 if (key in nodeData) 144 if (key in nodeData)
145 privates(node).impl[key] = nodeData[key]; 145 privates(node).impl[key] = nodeData[key];
146 else 146 else
147 privates(node).impl[key] = AutomationAttributeDefaults[key]; 147 privates(node).impl[key] = AutomationAttributeDefaults[key];
148 } 148 }
149 for (var attributeTypeIndex = 0; 149 for (var attributeTypeIndex = 0;
(...skipping 28 matching lines...) Expand all
178 } 178 }
179 return toStringInternal(this.root, 0); 179 return toStringInternal(this.root, 0);
180 } 180 }
181 }; 181 };
182 182
183 exports.AutomationTree = utils.expose('AutomationTree', 183 exports.AutomationTree = utils.expose('AutomationTree',
184 AutomationTreeImpl, 184 AutomationTreeImpl,
185 { functions: ['addEventListener', 185 { functions: ['addEventListener',
186 'removeEventListener'], 186 'removeEventListener'],
187 readonly: ['root'] }); 187 readonly: ['root'] });
OLDNEW
« no previous file with comments | « no previous file | chrome/renderer/resources/extensions/automation_custom_bindings.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698