diff src/audacious/ui_main.c @ 3077:4b076ad636e6

use GdkPixmaps for doublesizing
author Tomasz Mon <desowin@gmail.com>
date Sat, 14 Jul 2007 12:45:03 +0200
parents 081a24e2cafb
children 20830a69b5f5
line wrap: on
line diff
--- a/src/audacious/ui_main.c	Sat Jul 14 00:01:14 2007 +0200
+++ b/src/audacious/ui_main.c	Sat Jul 14 12:45:03 2007 +0200
@@ -549,8 +549,6 @@
 void
 draw_main_window(gboolean force)
 {
-    GdkImage *img, *img2x;
-
     if (!cfg.player_visible)
         return;
 
@@ -568,17 +566,13 @@
 
     if (force) {
         if (cfg.doublesize) {
-            img = gdk_drawable_get_image(mainwin_bg, 0, 0, bmp_active_skin->properties.mainwin_width,
-                                         cfg.player_shaded ?
-                                         MAINWIN_SHADED_HEIGHT :
-                                         bmp_active_skin->properties.mainwin_height);
-            img2x = create_dblsize_image(img);
-            gdk_draw_image(mainwin_bg_x2, SKINNED_WINDOW(mainwin)->gc, img2x, 0, 0,
+            GdkPixmap *img2x = NULL;
+            img2x = create_dblsize_pixmap(mainwin_bg);
+            gdk_draw_drawable(mainwin_bg_x2, SKINNED_WINDOW(mainwin)->gc, img2x, 0, 0,
                            0, 0, bmp_active_skin->properties.mainwin_width * 2,
                            cfg.player_shaded ? MAINWIN_SHADED_HEIGHT *
                            2 : bmp_active_skin->properties.mainwin_height * 2);
             g_object_unref(img2x);
-            g_object_unref(img);
         }
         GList *iter;
         for (iter = GTK_FIXED (SKINNED_WINDOW(mainwin)->fixed)->children; iter; iter = g_list_next (iter)) {