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

Unified Diff: third_party/polymer/components/iron-behaviors/iron-button-state.html

Issue 3010683002: Update Polymer components. (Closed)
Patch Set: Rebase Created 3 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: third_party/polymer/components/iron-behaviors/iron-button-state.html
diff --git a/third_party/polymer/components/iron-behaviors/iron-button-state.html b/third_party/polymer/components/iron-behaviors/iron-button-state.html
index 8114e2ddea8de7bfbe069304e56e7aef6640d425..c5221b8e1dd3b24ab281b8054c2d7c41e2943594 100644
--- a/third_party/polymer/components/iron-behaviors/iron-button-state.html
+++ b/third_party/polymer/components/iron-behaviors/iron-button-state.html
@@ -91,7 +91,7 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
},
observers: [
- '_detectKeyboardFocus(focused)',
+ '_focusChanged(focused)',
'_activeChanged(active, ariaActiveAttribute)'
],
@@ -112,6 +112,14 @@ subject to an additional IP rights grant found at http://polymer.github.io/PATEN
}
},
+ _focusChanged: function(focused) {
+ this._detectKeyboardFocus(focused);
+
+ if (!focused) {
+ this._setPressed(false);
+ }
+ },
+
_detectKeyboardFocus: function(focused) {
this._setReceivedFocusFromKeyboard(!this.pointerDown && focused);
},

Powered by Google App Engine
This is Rietveld 408576698