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

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

Issue 2780223004: MD Bookmarks: Implement dialog to add new folders/bookmarks (Closed)
Patch Set: Rebase Created 3 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
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..379079c8f4a35fa55e4e98a9e435c5e0303401bf 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
+ */
+ hasSearchTerm_: function() {
+ return !!this.searchTerm_;
+ },
});
« no previous file with comments | « chrome/browser/resources/md_bookmarks/toolbar.html ('k') | chrome/browser/ui/webui/md_bookmarks/md_bookmarks_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698