| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 /** | 5 /** |
| 6 * @constructor | 6 * @constructor |
| 7 * @extends {WebInspector.AccessibilitySubPane} | 7 * @extends {WebInspector.AccessibilitySubPane} |
| 8 */ | 8 */ |
| 9 WebInspector.AXNodeSubPane = function() | 9 WebInspector.AXNodeSubPane = function() |
| 10 { | 10 { |
| (...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 117 __proto__: WebInspector.AccessibilitySubPane.prototype | 117 __proto__: WebInspector.AccessibilitySubPane.prototype |
| 118 }; | 118 }; |
| 119 | 119 |
| 120 /** | 120 /** |
| 121 * @constructor | 121 * @constructor |
| 122 * @param {!WebInspector.AccessibilityNode} axNode | 122 * @param {!WebInspector.AccessibilityNode} axNode |
| 123 * @extends {TreeElement} | 123 * @extends {TreeElement} |
| 124 */ | 124 */ |
| 125 WebInspector.AXNodePropertyTreeElement = function(axNode) | 125 WebInspector.AXNodePropertyTreeElement = function(axNode) |
| 126 { | 126 { |
| 127 this._axNode = axNode; | |
| 128 | |
| 129 // Pass an empty title, the title gets made later in onattach. | 127 // Pass an empty title, the title gets made later in onattach. |
| 130 TreeElement.call(this, ""); | 128 TreeElement.call(this, ""); |
| 129 this._axNode = axNode; |
| 131 }; | 130 }; |
| 132 | 131 |
| 133 /** | 132 /** |
| 134 * @param {?AccessibilityAgent.AXValueType} type | 133 * @param {?AccessibilityAgent.AXValueType} type |
| 135 * @param {string} value | 134 * @param {string} value |
| 136 * @return {!Element} | 135 * @return {!Element} |
| 137 */ | 136 */ |
| 138 WebInspector.AXNodePropertyTreeElement.createSimpleValueElement = function(type,
value) | 137 WebInspector.AXNodePropertyTreeElement.createSimpleValueElement = function(type,
value) |
| 139 { | 138 { |
| 140 var valueElement; | 139 var valueElement; |
| (...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 288 }; | 287 }; |
| 289 | 288 |
| 290 /** | 289 /** |
| 291 * @constructor | 290 * @constructor |
| 292 * @extends {WebInspector.AXNodePropertyTreeElement} | 291 * @extends {WebInspector.AXNodePropertyTreeElement} |
| 293 * @param {!AccessibilityAgent.AXProperty} property | 292 * @param {!AccessibilityAgent.AXProperty} property |
| 294 * @param {!WebInspector.AccessibilityNode} axNode | 293 * @param {!WebInspector.AccessibilityNode} axNode |
| 295 */ | 294 */ |
| 296 WebInspector.AXNodePropertyTreePropertyElement = function(property, axNode) | 295 WebInspector.AXNodePropertyTreePropertyElement = function(property, axNode) |
| 297 { | 296 { |
| 297 WebInspector.AXNodePropertyTreeElement.call(this, axNode); |
| 298 |
| 298 this._property = property; | 299 this._property = property; |
| 299 this.toggleOnClick = true; | 300 this.toggleOnClick = true; |
| 300 this.selectable = false; | 301 this.selectable = false; |
| 301 | 302 |
| 302 WebInspector.AXNodePropertyTreeElement.call(this, axNode); | |
| 303 this.listItemElement.classList.add("property"); | 303 this.listItemElement.classList.add("property"); |
| 304 }; | 304 }; |
| 305 | 305 |
| 306 WebInspector.AXNodePropertyTreePropertyElement.prototype = { | 306 WebInspector.AXNodePropertyTreePropertyElement.prototype = { |
| 307 /** | 307 /** |
| 308 * @override | 308 * @override |
| 309 */ | 309 */ |
| 310 onattach: function() | 310 onattach: function() |
| 311 { | 311 { |
| 312 this._update(); | 312 this._update(); |
| (...skipping 16 matching lines...) Expand all Loading... |
| 329 }; | 329 }; |
| 330 | 330 |
| 331 /** | 331 /** |
| 332 * @constructor | 332 * @constructor |
| 333 * @extends {WebInspector.AXNodePropertyTreeElement} | 333 * @extends {WebInspector.AXNodePropertyTreeElement} |
| 334 * @param {!AccessibilityAgent.AXValueSource} source | 334 * @param {!AccessibilityAgent.AXValueSource} source |
| 335 * @param {!WebInspector.AccessibilityNode} axNode | 335 * @param {!WebInspector.AccessibilityNode} axNode |
| 336 */ | 336 */ |
| 337 WebInspector.AXValueSourceTreeElement = function(source, axNode) | 337 WebInspector.AXValueSourceTreeElement = function(source, axNode) |
| 338 { | 338 { |
| 339 WebInspector.AXNodePropertyTreeElement.call(this, axNode); |
| 339 this._source = source; | 340 this._source = source; |
| 340 WebInspector.AXNodePropertyTreeElement.call(this, axNode); | |
| 341 this.selectable = false; | 341 this.selectable = false; |
| 342 }; | 342 }; |
| 343 | 343 |
| 344 WebInspector.AXValueSourceTreeElement.prototype = { | 344 WebInspector.AXValueSourceTreeElement.prototype = { |
| 345 /** | 345 /** |
| 346 * @override | 346 * @override |
| 347 */ | 347 */ |
| 348 onattach: function() | 348 onattach: function() |
| 349 { | 349 { |
| 350 this._update(); | 350 this._update(); |
| (...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 508 }; | 508 }; |
| 509 | 509 |
| 510 /** | 510 /** |
| 511 * @constructor | 511 * @constructor |
| 512 * @param {{deferredNode: (!WebInspector.DeferredDOMNode|undefined), idref: (str
ing|undefined)}} node | 512 * @param {{deferredNode: (!WebInspector.DeferredDOMNode|undefined), idref: (str
ing|undefined)}} node |
| 513 * @param {!AccessibilityAgent.AXRelatedNode=} value | 513 * @param {!AccessibilityAgent.AXRelatedNode=} value |
| 514 * @extends {TreeElement} | 514 * @extends {TreeElement} |
| 515 */ | 515 */ |
| 516 WebInspector.AXRelatedNodeSourceTreeElement = function(node, value) | 516 WebInspector.AXRelatedNodeSourceTreeElement = function(node, value) |
| 517 { | 517 { |
| 518 TreeElement.call(this, ""); |
| 519 |
| 518 this._value = value; | 520 this._value = value; |
| 519 this._axRelatedNodeElement = new WebInspector.AXRelatedNodeElement(node, val
ue); | 521 this._axRelatedNodeElement = new WebInspector.AXRelatedNodeElement(node, val
ue); |
| 520 | |
| 521 TreeElement.call(this, ""); | |
| 522 | |
| 523 this.selectable = false; | 522 this.selectable = false; |
| 524 }; | 523 }; |
| 525 | 524 |
| 526 WebInspector.AXRelatedNodeSourceTreeElement.prototype = { | 525 WebInspector.AXRelatedNodeSourceTreeElement.prototype = { |
| 527 /** | 526 /** |
| 528 * @override | 527 * @override |
| 529 */ | 528 */ |
| 530 onattach: function() | 529 onattach: function() |
| 531 { | 530 { |
| 532 this.listItemElement.appendChild(this._axRelatedNodeElement.render()); | 531 this.listItemElement.appendChild(this._axRelatedNodeElement.render()); |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 587 }; | 586 }; |
| 588 | 587 |
| 589 /** | 588 /** |
| 590 * @constructor | 589 * @constructor |
| 591 * @extends {WebInspector.AXNodePropertyTreeElement} | 590 * @extends {WebInspector.AXNodePropertyTreeElement} |
| 592 * @param {!AccessibilityAgent.AXProperty} property | 591 * @param {!AccessibilityAgent.AXProperty} property |
| 593 * @param {!WebInspector.AccessibilityNode} axNode | 592 * @param {!WebInspector.AccessibilityNode} axNode |
| 594 */ | 593 */ |
| 595 WebInspector.AXNodeIgnoredReasonTreeElement = function(property, axNode) | 594 WebInspector.AXNodeIgnoredReasonTreeElement = function(property, axNode) |
| 596 { | 595 { |
| 596 WebInspector.AXNodePropertyTreeElement.call(this, axNode); |
| 597 this._property = property; | 597 this._property = property; |
| 598 this._axNode = axNode; | 598 this._axNode = axNode; |
| 599 | |
| 600 WebInspector.AXNodePropertyTreeElement.call(this, axNode); | |
| 601 this.toggleOnClick = true; | 599 this.toggleOnClick = true; |
| 602 this.selectable = false; | 600 this.selectable = false; |
| 603 }; | 601 }; |
| 604 | 602 |
| 605 WebInspector.AXNodeIgnoredReasonTreeElement.prototype = { | 603 WebInspector.AXNodeIgnoredReasonTreeElement.prototype = { |
| 606 /** | 604 /** |
| 607 * @override | 605 * @override |
| 608 */ | 606 */ |
| 609 onattach: function() | 607 onattach: function() |
| 610 { | 608 { |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 684 reasonElement = WebInspector.formatLocalized("Static text node is used a
s name for\u00a0", []); | 682 reasonElement = WebInspector.formatLocalized("Static text node is used a
s name for\u00a0", []); |
| 685 break; | 683 break; |
| 686 case "uninteresting": | 684 case "uninteresting": |
| 687 reasonElement = WebInspector.formatLocalized("Element not interesting fo
r accessibility.", []); | 685 reasonElement = WebInspector.formatLocalized("Element not interesting fo
r accessibility.", []); |
| 688 break; | 686 break; |
| 689 } | 687 } |
| 690 if (reasonElement) | 688 if (reasonElement) |
| 691 reasonElement.classList.add("ax-reason"); | 689 reasonElement.classList.add("ax-reason"); |
| 692 return reasonElement; | 690 return reasonElement; |
| 693 }; | 691 }; |
| OLD | NEW |