From 6496dd5403ecd03705d8d7f0d6bca1aacc0d8e3f Mon Sep 17 00:00:00 2001 From: Christian Dywan Date: Mon, 22 Mar 2010 22:01:59 +0100 Subject: [PATCH] Update tab panel colours in icon callback Since Colorful Tabs now updates colors in the icon callback, we also need to update in the icon callback. --- extensions/tab-panel.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/extensions/tab-panel.c b/extensions/tab-panel.c index 6fb1fc8f..2d182d5e 100644 --- a/extensions/tab-panel.c +++ b/extensions/tab-panel.c @@ -329,8 +329,13 @@ tab_panel_view_notify_icon_cb (GtkWidget* view, { GtkTreeModel* model = tab_panel_get_model_for_browser (browser); GtkTreeIter iter; + GtkWidget* label = midori_view_get_proxy_tab_label (MIDORI_VIEW (view)); + GtkStyle* style = gtk_widget_get_style (label); if (tab_panel_get_iter_for_view (model, &iter, view)) - gtk_tree_store_set (GTK_TREE_STORE (model), &iter, 3, icon, -1); + gtk_tree_store_set (GTK_TREE_STORE (model), &iter, + 3, icon, + 6, &style->bg[GTK_STATE_NORMAL], + -1); } } @@ -354,12 +359,10 @@ tab_panel_view_notify_title_cb (GtkWidget* view, GtkTreeIter iter; if (tab_panel_get_iter_for_view (model, &iter, view)) { - GtkWidget* label = midori_view_get_proxy_tab_label (MIDORI_VIEW (view)); - GtkStyle* style = gtk_widget_get_style (label); gtk_tree_store_set (GTK_TREE_STORE (model), &iter, 4, title, 5, midori_view_get_label_ellipsize (MIDORI_VIEW (view)), - 6, &style->bg[GTK_STATE_NORMAL], -1); + -1); } } } -- 2.39.5