[gtk-css-engine] [style] Ensure stylesheet is set in the drawing functions.



commit 623dfe6451553ce6d34110a8635565c04b8b2001
Author: Robert Staudinger <robsta gnome org>
Date:   Wed Jun 17 19:15:58 2009 +0200

    [style] Ensure stylesheet is set in the drawing functions.

 src/gce-style.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/gce-style.c b/src/gce-style.c
index 8ceee5b..daa723a 100644
--- a/src/gce-style.c
+++ b/src/gce-style.c
@@ -44,6 +44,7 @@ rectangle (GceStyle		*self,
 	ccss_style_t	*style = NULL;
 
 	g_return_if_fail (self);
+	g_return_if_fail (self->stylesheet);
 
 	if (node) {
 		style = ccss_stylesheet_query (self->stylesheet, (ccss_node_t *) node);
@@ -96,6 +97,7 @@ gap (GceStyle		*self,
 	ccss_style_t	*style = NULL;
 
 	g_return_if_fail (self);
+	g_return_if_fail (self->stylesheet);
 
 	if (node) {
 		style = ccss_stylesheet_query (self->stylesheet, (ccss_node_t *) node);
@@ -143,6 +145,7 @@ line (GceStyle		*self,
 	ccss_style_t	*style = NULL;
 
 	g_return_if_fail (self);
+	g_return_if_fail (self->stylesheet);
 
 	if (node) {
 		style = ccss_stylesheet_query (self->stylesheet, (ccss_node_t *) node);



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