Commit 134406bd authored by rbpotter's avatar rbpotter Committed by Commit Bot

Fix PDF viewer console errors for Polymer2 migration

Cq-Include-Trybots: master.tryserver.chromium.linux:closure_compilation
Change-Id: I09abc82ecd2ab71850a70c65a9a2decfcc011fe3
Bug: 849476
Reviewed-on: https://chromium-review.googlesource.com/1086236Reviewed-by: default avatarDemetrios Papadopoulos <dpapad@chromium.org>
Commit-Queue: Rebekah Potter <rbpotter@chromium.org>
Cr-Commit-Position: refs/heads/master@{#564787}
parent f5b25454
......@@ -40,18 +40,19 @@ Polymer({
childrenShown: {type: Boolean, reflectToAttribute: true, value: false},
keyEventTarget: {
type: Object,
value: function() {
return this.$.item;
}
}
/** @type {?HTMLElement} The target for the key bindings below. */
keyEventTarget: Object,
},
behaviors: [Polymer.IronA11yKeysBehavior],
keyBindings: {'enter': 'onEnter_', 'space': 'onSpace_'},
/** @override */
attached: function() {
this.keyEventTarget = this.$.item;
},
bookmarkChanged_: function() {
this.$.expand.style.visibility =
this.bookmark.children.length > 0 ? 'visible' : 'hidden';
......
......@@ -42,17 +42,18 @@ Polymer({
/** Lowest vertical point that the dropdown should occupy (px). */
lowerBound: {type: Number, observer: 'lowerBoundChanged_'},
/**
* True if the max-height CSS property for the dropdown scroll container
* is valid. If false, the height will be updated the next time the
* dropdown is visible.
*/
maxHeightValid_: false,
/** Current animation being played, or null if there is none. */
animation_: Object
},
/**
* True if the max-height CSS property for the dropdown scroll container
* is valid. If false, the height will be updated the next time the
* dropdown is visible.
* @private {boolean}
*/
maxHeightValid_: false,
computeIcon_: function(dropdownOpen, closedIcon, openIcon) {
return dropdownOpen ? openIcon : closedIcon;
},
......
......@@ -53,7 +53,7 @@ Polymer({
},
computeVisibleTooltip_: function(tooltips, activeIndex) {
return tooltips[activeIndex];
return tooltips === undefined ? '' : tooltips[activeIndex];
},
delayChanged_: function() {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment