[gimp/gtk3-port: 43/236] app: no need to alloc colors any longer, GdkColormap is gone
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/gtk3-port: 43/236] app: no need to alloc colors any longer, GdkColormap is gone
- Date: Sat, 24 Sep 2011 21:39:15 +0000 (UTC)
commit d406df8fdafc1ac5e7ffdf9f30850b6dedb2014e
Author: Michael Natterer <mitch gimp org>
Date: Fri Oct 15 16:15:09 2010 +0200
app: no need to alloc colors any longer, GdkColormap is gone
app/display/gimpcanvas.c | 10 ++--------
1 files changed, 2 insertions(+), 8 deletions(-)
---
diff --git a/app/display/gimpcanvas.c b/app/display/gimpcanvas.c
index 0c89bb8..bce3d2e 100644
--- a/app/display/gimpcanvas.c
+++ b/app/display/gimpcanvas.c
@@ -286,19 +286,13 @@ void
gimp_canvas_set_bg_color (GimpCanvas *canvas,
GimpRGB *color)
{
- GtkWidget *widget = GTK_WIDGET (canvas);
- GdkColormap *colormap;
- GdkColor gdk_color;
+ GtkWidget *widget = GTK_WIDGET (canvas);
+ GdkColor gdk_color;
if (! gtk_widget_get_realized (widget))
return;
gimp_rgb_get_gdk_color (color, &gdk_color);
-
- colormap = gdk_drawable_get_colormap (gtk_widget_get_window (widget));
- g_return_if_fail (colormap != NULL);
- gdk_colormap_alloc_color (colormap, &gdk_color, FALSE, TRUE);
-
gdk_window_set_background (gtk_widget_get_window (widget), &gdk_color);
gtk_widget_queue_draw (GTK_WIDGET (canvas));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]