Index: chrome/browser/bookmarks/bookmark_context_menu_controller.cc |
diff --git a/chrome/browser/bookmarks/bookmark_context_menu_controller.cc b/chrome/browser/bookmarks/bookmark_context_menu_controller.cc |
index 0e92c12804ec3812cf259c29a76b84f9c33271c3..97cfb922bd33144ead1ae535d5d19ea27fcf0927 100644 |
--- a/chrome/browser/bookmarks/bookmark_context_menu_controller.cc |
+++ b/chrome/browser/bookmarks/bookmark_context_menu_controller.cc |
@@ -139,15 +139,9 @@ void BookmarkContextMenuController::ExecuteCommand(int id) { |
} |
if (selection_[0]->is_url()) { |
-#if defined(WEBUI_DIALOGS) |
- Browser* browser = BrowserList::GetLastActiveWithProfile(profile_); |
- DCHECK(browser); |
- browser->OpenBookmarkManagerEditNode(selection_[0]->id()); |
-#else |
- BookmarkEditor::Show(parent_window_, profile_, parent_, |
- BookmarkEditor::EditDetails(selection_[0]), |
- BookmarkEditor::SHOW_TREE); |
-#endif |
+ BookmarkEditor::Show(parent_window_, profile_, |
+ BookmarkEditor::EditDetails::EditNode(selection_[0]), |
+ BookmarkEditor::SHOW_TREE); |
} else { |
BookmarkFolderEditorController::Show(profile_, parent_window_, |
selection_[0], -1, |
@@ -172,17 +166,12 @@ void BookmarkContextMenuController::ExecuteCommand(int id) { |
UserMetrics::RecordAction( |
UserMetricsAction("BookmarkBar_ContextMenu_Add")); |
-#if defined(WEBUI_DIALOGS) |
- Browser* browser = BrowserList::GetLastActiveWithProfile(profile_); |
- DCHECK(browser); |
- browser->OpenBookmarkManagerAddNodeIn(selection_[0]->id()); |
-#else |
// TODO: this should honor the index from GetParentForNewNodes. |
BookmarkEditor::Show( |
parent_window_, profile_, |
- bookmark_utils::GetParentForNewNodes(parent_, selection_, NULL), |
- BookmarkEditor::EditDetails(), BookmarkEditor::SHOW_TREE); |
-#endif |
+ BookmarkEditor::EditDetails::AddNodeInFolder( |
+ bookmark_utils::GetParentForNewNodes(parent_, selection_, NULL)), |
+ BookmarkEditor::SHOW_TREE); |
break; |
} |