[gtk+] levelbar: Remove unneeded checks



commit fd527691a880876601346d65c40a3557e2b0e5b0
Author: Benjamin Otte <otte redhat com>
Date:   Wed Apr 30 09:22:29 2014 +0200

    levelbar: Remove unneeded checks
    
    Size vfuncs always get non-null out variables passed, so no need to
    check for NULL.

 gtk/gtklevelbar.c |   12 ++++--------
 1 files changed, 4 insertions(+), 8 deletions(-)
---
diff --git a/gtk/gtklevelbar.c b/gtk/gtklevelbar.c
index 1af260b..755002b 100644
--- a/gtk/gtklevelbar.c
+++ b/gtk/gtklevelbar.c
@@ -545,10 +545,8 @@ gtk_level_bar_get_preferred_width (GtkWidget *widget,
   else
     width += block_width;
 
-  if (minimum)
-    *minimum = width;
-  if (natural)
-    *natural = width;
+  *minimum = width;
+  *natural = width;
 }
 
 static void
@@ -572,10 +570,8 @@ gtk_level_bar_get_preferred_height (GtkWidget *widget,
   else
     height += block_height;
 
-  if (minimum)
-    *minimum = height;
-  if (natural)
-    *natural = height;
+  *minimum = height;
+  *natural = height;
 }
 
 static void


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