summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2010-12-18 16:35:52 +0000
committerMichael Drake <tlsa@netsurf-browser.org>2010-12-18 16:35:52 +0000
commit75c82c33e6f5c2cdf8f13d213bcd96223a0839af (patch)
treec3e910dbb8b116a71f596edcbf47d1a97d0bd8c2
parent00a18370e09c10b2dc7f5241dee4a7c46111e0b9 (diff)
downloadnetsurf-75c82c33e6f5c2cdf8f13d213bcd96223a0839af.tar.gz
netsurf-75c82c33e6f5c2cdf8f13d213bcd96223a0839af.tar.bz2
Draw tree background when there are no nodes.
svn path=/trunk/netsurf/; revision=11092
-rw-r--r--desktop/tree.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/desktop/tree.c b/desktop/tree.c
index b0fe2c6e3..748e7b952 100644
--- a/desktop/tree.c
+++ b/desktop/tree.c
@@ -1802,10 +1802,6 @@ void tree_draw(struct tree *tree, int x, int y,
assert(tree != NULL);
assert(tree->root != NULL);
- /* don't draw empty trees or trees with redraw flag set to false */
- if (tree->root->child == NULL || !tree->redraw)
- return;
-
/* Set up clip rectangle */
clip.x0 = x + clip_x;
clip.y0 = y + clip_y;
@@ -1817,6 +1813,10 @@ void tree_draw(struct tree *tree, int x, int y,
plot.rectangle(clip.x0, clip.y0, clip.x1, clip.y1,
&plot_style_fill_tree_background);
+ /* don't draw empty trees or trees with redraw flag set to false */
+ if (tree->root->child == NULL || !tree->redraw)
+ return;
+
/* Draw the tree */
tree_draw_tree(tree, tree->root, x, y, clip);