diff options
author | Cyrille Bagard <nocbos@gmail.com> | 2012-02-01 11:08:15 (GMT) |
---|---|---|
committer | Cyrille Bagard <nocbos@gmail.com> | 2012-02-01 11:08:15 (GMT) |
commit | 98a3c749a15349b874dcef0ce3a43ebff651d95a (patch) | |
tree | 1b905fd3e269ba3c0bbf815644f40719b887a430 /src/gtkext/gtkbufferview.c | |
parent | 0c847f961a99d8e8012beecad27cf4318df1ff88 (diff) |
Activated GTK_DISABLE_DEPRECATED again to avoid some warnings.
git-svn-id: svn://svn.gna.org/svn/chrysalide/trunk@233 abbe820e-26c8-41b2-8c08-b7b2b41f8b0a
Diffstat (limited to 'src/gtkext/gtkbufferview.c')
-rw-r--r-- | src/gtkext/gtkbufferview.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/gtkext/gtkbufferview.c b/src/gtkext/gtkbufferview.c index 3e58500..186b53f 100644 --- a/src/gtkext/gtkbufferview.c +++ b/src/gtkext/gtkbufferview.c @@ -213,7 +213,7 @@ static void gtk_buffer_view_size_allocate(GtkWidget *widget, GtkAllocation *allo widget->allocation = *allocation; - if (GTK_WIDGET_REALIZED(widget)) + if (gtk_widget_get_realized(widget)) gdk_window_move_resize(widget->window, allocation->x, allocation->y, allocation->width, allocation->height); @@ -284,6 +284,7 @@ static gboolean gtk_buffer_view_expose(GtkWidget *widget, GdkEventExpose *event) GdkDrawable *drawable; /* Surface de dessin */ gint fake_x; /* Abscisse virtuelle */ gint fake_y; /* Ordonnée virtuelle */ + GtkStateType state; /* Etat du composant */ GtkViewPanelClass *parent_class; /* Version pure du parent */ view = GTK_BUFFER_VIEW(widget); @@ -304,12 +305,14 @@ static gboolean gtk_buffer_view_expose(GtkWidget *widget, GdkEventExpose *event) /* Dessin de la marge gauche */ - gdk_gc_set_foreground(pview->gc, &style->mid[GTK_WIDGET_STATE(widget)]); + state = gtk_widget_get_state(widget); + + gdk_gc_set_foreground(pview->gc, &style->mid[state]); gdk_draw_rectangle(drawable, pview->gc, TRUE, fake_x, event->area.y, view->left_margin, event->area.y + event->area.height); - gdk_gc_set_foreground(pview->gc, &style->dark[GTK_WIDGET_STATE(widget)]); + gdk_gc_set_foreground(pview->gc, &style->dark[state]); gdk_draw_line(drawable, pview->gc, fake_x + view->left_margin, event->area.y, |