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

Unified Diff: chrome/browser/resources/md_bookmarks/toolbar.js

Issue 2780223004: MD Bookmarks: Implement dialog to add new folders/bookmarks (Closed)
Patch Set: Split out creation Created 3 years, 9 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: chrome/browser/resources/md_bookmarks/toolbar.js
diff --git a/chrome/browser/resources/md_bookmarks/toolbar.js b/chrome/browser/resources/md_bookmarks/toolbar.js
index 1a37133b9d04ef9f51e5a84ee5a3bd3be110a5fb..5cb5aedb658d02cb5d603fa8ab2c0754db5166a6 100644
--- a/chrome/browser/resources/md_bookmarks/toolbar.js
+++ b/chrome/browser/resources/md_bookmarks/toolbar.js
@@ -44,17 +44,22 @@ Polymer({
},
/** @private */
- onBulkEditTap_: function() {
+ onSortTap_: function() {
this.closeDropdownMenu_();
},
/** @private */
- onSortTap_: function() {
+ onAddBookmarkTap_: function() {
+ var dialog =
+ /** @type {BookmarksEditDialogElement} */ (this.$.addDialog.get());
+ dialog.showAddDialog(false, assert(this.getState().selectedFolder));
this.closeDropdownMenu_();
},
- /** @private */
- onAddBookmarkTap_: function() {
+ onAddFolderTap_: function() {
+ var dialog =
+ /** @type {BookmarksEditDialogElement} */ (this.$.addDialog.get());
+ dialog.showAddDialog(true, assert(this.getState().selectedFolder));
this.closeDropdownMenu_();
},
@@ -94,4 +99,12 @@ Polymer({
onSearchTermChanged_: function() {
this.searchField.setValue(this.searchTerm_ || '');
},
+
+ /**
+ * @return {boolean}
+ * @private
+ */
+ isSearchActive_: function() {
calamity 2017/04/03 07:20:48 nit: hasSearchTerm_ perhaps? 'Active' search is a
tsergeant 2017/04/04 01:21:08 Renamed. The util function didn't exist when I fi
+ return !!this.searchTerm_;
+ },
});

Powered by Google App Engine
This is Rietveld 408576698