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

Unified Diff: chrome/browser/resources/media_router/elements/drop_down_button/drop_down_button.js

Issue 1032533002: Add Media Router drop-down-button. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 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
« no previous file with comments | « chrome/browser/resources/media_router/elements/drop_down_button/drop_down_button.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/media_router/elements/drop_down_button/drop_down_button.js
diff --git a/chrome/browser/resources/media_router/elements/drop_down_button/drop_down_button.js b/chrome/browser/resources/media_router/elements/drop_down_button/drop_down_button.js
new file mode 100644
index 0000000000000000000000000000000000000000..e56caead82c1c7f4c125c810567a97caa14a8027
--- /dev/null
+++ b/chrome/browser/resources/media_router/elements/drop_down_button/drop_down_button.js
@@ -0,0 +1,19 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+Polymer('drop-down-button', {
+ created: function() {
+ /** @type {boolean} */
+ this.iconShown = false;
+ },
+
+ /**
+ * Fires a drop-down-button-click event. This is called when the element is
+ * clicked. Switches the value of |iconShown|.
+ */
+ onButtonClick: function() {
+ this.iconShown = !this.iconShown;
+ this.fire('drop-down-button-click');
+ }
+});
« no previous file with comments | « chrome/browser/resources/media_router/elements/drop_down_button/drop_down_button.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698