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

Unified Diff: chrome/browser/ui/bookmarks/bookmark_context_menu_controller.cc

Issue 1105413002: Avoid conversion of index to BookmarkNode pointer unnacessarily. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Changes as per review comments. 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
Index: chrome/browser/ui/bookmarks/bookmark_context_menu_controller.cc
diff --git a/chrome/browser/ui/bookmarks/bookmark_context_menu_controller.cc b/chrome/browser/ui/bookmarks/bookmark_context_menu_controller.cc
index 85d0a2bd5507d0f15fcc8d6610d6f628225c6942..92ab0faed3654b5112ac632782f6e10250a2c579 100644
--- a/chrome/browser/ui/bookmarks/bookmark_context_menu_controller.cc
+++ b/chrome/browser/ui/bookmarks/bookmark_context_menu_controller.cc
@@ -200,7 +200,7 @@ void BookmarkContextMenuController::ExecuteCommand(int id, int event_flags) {
for (size_t i = 0; i < selection_.size(); ++i) {
int index = selection_[i]->parent()->GetIndexOf(selection_[i]);
if (index > -1)
- model_->Remove(selection_[i]->parent(), index);
+ model_->Remove(selection_[i]);
}
selection_.clear();
break;
« no previous file with comments | « chrome/browser/sync/test/integration/bookmarks_helper.cc ('k') | chrome/browser/ui/bookmarks/bookmark_ui_utils_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698