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

Side by Side Diff: chrome/browser/resources/md_history/history_toolbar.js

Issue 1572383006: MD History: Hook all elements into the page and add tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@patch
Patch Set: Address reviewer comments. Created 4 years, 11 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
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 Polymer({
6 is: 'history-toolbar',
7 properties: {
8 // Number of history items currently selected.
9 count: {
10 type: Number,
11 value: 0,
12 observer: 'changeToolbarView_'
13 },
14 // True if 1 or more history items are selected. When this value changes
15 // the background colour changes.
16 itemsSelected_: {
17 type: Boolean,
18 value: false,
19 reflectToAttribute: true
20 }
21 },
22
23 /**
24 * This function changes the toolbar background color depending on whether or
tsergeant 2016/01/22 02:37:11 Remove "this function" (it's implied): Change the
25 * not any history items are currently selected.
26 * @private
27 */
28 changeToolbarView_: function() {
29 this.itemsSelected_ = this.count != 0;
30 },
31
32 clearSelection: function() {
33 this.fire('unselect-all');
34 }
35 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698