[gnome-control-center] sound: Simplify check_rectangle() macro



commit 968d4210831ebecda8bb64ed0423d95550d38dc6
Author: Bastien Nocera <hadess hadess net>
Date:   Thu Nov 18 16:06:53 2010 +0000

    sound: Simplify check_rectangle() macro
    
    As the x and y never change.

 panels/sound/gvc-level-bar.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
---
diff --git a/panels/sound/gvc-level-bar.c b/panels/sound/gvc-level-bar.c
index 75c7cb0..00a85c9 100644
--- a/panels/sound/gvc-level-bar.c
+++ b/panels/sound/gvc-level-bar.c
@@ -90,8 +90,7 @@ G_DEFINE_TYPE (GvcLevelBar, gvc_level_bar, GTK_TYPE_HBOX)
 
 #define check_rectangle(rectangle1, rectangle2)                          \
         {                                                                \
-                if (rectangle1.x != rectangle2.x) return TRUE;           \
-                if (rectangle1.y != rectangle2.y) return TRUE;           \
+                /* .x and .y are always 0 */                             \
                 if (rectangle1.width  != rectangle2.width)  return TRUE; \
                 if (rectangle1.height != rectangle2.height) return TRUE; \
         }



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