[mutter/wip/cb2eb3: 39/55] frames: Remove reset_frames / unflicker_bg



commit 143436c37ce3e27a6d9bc81a078de32716790427
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Thu May 3 16:00:26 2012 -0400

    frames: Remove reset_frames / unflicker_bg

 src/core/frame.c |   13 -------------
 src/ui/frames.c  |   31 -------------------------------
 src/ui/frames.h  |    7 -------
 src/ui/ui.c      |   17 -----------------
 src/ui/ui.h      |    7 -------
 5 files changed, 0 insertions(+), 75 deletions(-)
---
diff --git a/src/core/frame.c b/src/core/frame.c
index 937169e..84ace36 100644
--- a/src/core/frame.c
+++ b/src/core/frame.c
@@ -156,7 +156,6 @@ meta_window_ensure_frame (MetaWindow *window)
    * style and background.
    */
   meta_ui_update_frame_style (window->screen->ui, frame->xwindow);
-  meta_ui_reset_frame_bg (window->screen->ui, frame->xwindow);
   
   if (window->title)
     meta_ui_set_frame_title (window->screen->ui,
@@ -349,15 +348,6 @@ meta_frame_sync_to_window (MetaFrame *frame,
               frame->rect.x + frame->rect.width,
               frame->rect.y + frame->rect.height);
 
-  /* set bg to none to avoid flicker */
-  if (need_resize)
-    {
-      meta_ui_unflicker_frame_bg (frame->window->screen->ui,
-                                  frame->xwindow,
-                                  frame->rect.width,
-                                  frame->rect.height);
-    }
-
   meta_ui_move_resize_frame (frame->window->screen->ui,
                             frame->xwindow,
                             frame->rect.x,
@@ -367,9 +357,6 @@ meta_frame_sync_to_window (MetaFrame *frame,
 
   if (need_resize)
     {
-      meta_ui_reset_frame_bg (frame->window->screen->ui,
-                              frame->xwindow);
-
       /* If we're interactively resizing the frame, repaint
        * it immediately so we don't start to lag.
        */
diff --git a/src/ui/frames.c b/src/ui/frames.c
index 548d5cc..ab565bb 100644
--- a/src/ui/frames.c
+++ b/src/ui/frames.c
@@ -619,37 +619,6 @@ meta_frames_render_background (MetaFrames *frames,
   meta_theme_render_background (frame->tv->style_context, cr, flags, &fgeom);
 }
 
-void
-meta_frames_reset_bg (MetaFrames *frames,
-                      Window  xwindow)
-{
-}
-
-static void
-set_background_none (Display *xdisplay,
-                     Window   xwindow)
-{
-  XSetWindowAttributes attrs;
-
-  attrs.background_pixmap = None;
-  XChangeWindowAttributes (xdisplay, xwindow,
-                           CWBackPixmap, &attrs);
-}
-
-void
-meta_frames_unflicker_bg (MetaFrames *frames,
-                          Window      xwindow,
-                          int         target_width,
-                          int         target_height)
-{
-  MetaUIFrame *frame;
-  
-  frame = meta_frames_lookup_window (frames, xwindow);
-  g_return_if_fail (frame != NULL);
-
-  set_background_none (GDK_DISPLAY_XDISPLAY (gdk_display_get_default ()), frame->xwindow);
-}
-
 /* The client rectangle surrounds client window; it subtracts both
  * the visible and invisible borders from the frame window's size.
  */
diff --git a/src/ui/frames.h b/src/ui/frames.h
index d1002c3..ca2ba81 100644
--- a/src/ui/frames.h
+++ b/src/ui/frames.h
@@ -127,13 +127,6 @@ void meta_frames_get_borders (MetaFrames *frames,
                               Window xwindow,
                               MetaFrameBorders *borders);
 
-void meta_frames_reset_bg     (MetaFrames *frames,
-                               Window      xwindow);
-void meta_frames_unflicker_bg (MetaFrames *frames,
-                               Window      xwindow,
-                               int         target_width,
-                               int         target_height);
-
 void meta_frames_render_background (MetaFrames *frames,
                                     Window      xwindow,
                                     cairo_t    *cr);
diff --git a/src/ui/ui.c b/src/ui/ui.c
index 6eb459d..12ce748 100644
--- a/src/ui/ui.c
+++ b/src/ui/ui.c
@@ -444,16 +444,6 @@ meta_ui_unmap_frame (MetaUI *ui,
 }
 
 void
-meta_ui_unflicker_frame_bg (MetaUI *ui,
-                            Window  xwindow,
-                            int     target_width,
-                            int     target_height)
-{
-  meta_frames_unflicker_bg (ui->frames, xwindow,
-                            target_width, target_height);
-}
-
-void
 meta_ui_update_frame_style (MetaUI  *ui,
                             Window   xwindow)
 {
@@ -468,13 +458,6 @@ meta_ui_repaint_frame (MetaUI *ui,
 }
 
 void
-meta_ui_reset_frame_bg (MetaUI *ui,
-                        Window xwindow)
-{
-  meta_frames_reset_bg (ui->frames, xwindow);
-}
-
-void
 meta_ui_queue_frame_draw (MetaUI *ui,
                           Window xwindow)
 {
diff --git a/src/ui/ui.h b/src/ui/ui.h
index fdba2e3..930e6eb 100644
--- a/src/ui/ui.h
+++ b/src/ui/ui.h
@@ -84,13 +84,6 @@ void meta_ui_map_frame   (MetaUI *ui,
 void meta_ui_unmap_frame (MetaUI *ui,
                           Window  xwindow);
 
-void meta_ui_unflicker_frame_bg (MetaUI *ui,
-                                 Window  xwindow,
-                                 int     target_width,
-                                 int     target_height);
-void meta_ui_reset_frame_bg     (MetaUI *ui,
-                                 Window  xwindow);
-
 void meta_ui_render_background (MetaUI  *ui,
                                 Window   xwindow,
                                 cairo_t *cr);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]