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

Unified Diff: chrome/browser/gtk/bookmark_bar_gtk.cc

Issue 195046: Linux: avoid a NOTREACHED() by not reaching it. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/gtk/bookmark_bar_gtk.cc
===================================================================
--- chrome/browser/gtk/bookmark_bar_gtk.cc (revision 25770)
+++ chrome/browser/gtk/bookmark_bar_gtk.cc (working copy)
@@ -298,7 +298,8 @@
int old_index,
const BookmarkNode* new_parent,
int new_index) {
- BookmarkNodeRemoved(model, old_parent, old_index, NULL);
+ const BookmarkNode* node = new_parent->GetChild(new_index);
+ BookmarkNodeRemoved(model, old_parent, old_index, node);
BookmarkNodeAdded(model, new_parent, new_index);
}
@@ -334,7 +335,8 @@
GtkWidget* to_remove = GTK_WIDGET(gtk_toolbar_get_nth_item(
GTK_TOOLBAR(bookmark_toolbar_.get()), old_index));
- menu_bar_helper_.Remove(gtk_bin_get_child(GTK_BIN(to_remove)));
+ if (node->is_folder())
+ menu_bar_helper_.Remove(gtk_bin_get_child(GTK_BIN(to_remove)));
gtk_container_remove(GTK_CONTAINER(bookmark_toolbar_.get()),
to_remove);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698