aboutsummaryrefslogtreecommitdiffstats
path: root/executive-summary/component
diff options
context:
space:
mode:
authorIain Holmes <iain@src.gnome.org>2000-12-13 09:46:19 +0800
committerIain Holmes <iain@src.gnome.org>2000-12-13 09:46:19 +0800
commit616052c0a7fa403b42cc2ced7dca7b9d79d6357f (patch)
tree87afd15eded34a64ff7382bd8e5ada600622b434 /executive-summary/component
parent2fc0744447411e015e1ed3180bbe160acbcb57f5 (diff)
downloadgsoc2013-evolution-616052c0a7fa403b42cc2ced7dca7b9d79d6357f.tar
gsoc2013-evolution-616052c0a7fa403b42cc2ced7dca7b9d79d6357f.tar.gz
gsoc2013-evolution-616052c0a7fa403b42cc2ced7dca7b9d79d6357f.tar.bz2
gsoc2013-evolution-616052c0a7fa403b42cc2ced7dca7b9d79d6357f.tar.lz
gsoc2013-evolution-616052c0a7fa403b42cc2ced7dca7b9d79d6357f.tar.xz
gsoc2013-evolution-616052c0a7fa403b42cc2ced7dca7b9d79d6357f.tar.zst
gsoc2013-evolution-616052c0a7fa403b42cc2ced7dca7b9d79d6357f.zip
Count the number of rows correctly
svn path=/trunk/; revision=6961
Diffstat (limited to 'executive-summary/component')
-rw-r--r--executive-summary/component/e-summary.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/executive-summary/component/e-summary.c b/executive-summary/component/e-summary.c
index f2281e4b06..c55d6887f7 100644
--- a/executive-summary/component/e-summary.c
+++ b/executive-summary/component/e-summary.c
@@ -358,7 +358,7 @@ make_control_html (ESummaryWindow *window,
html = g_strdup_printf ("<table><tr><td><a href=\"close://%d\">"
"<img src=\"service-close.png\" border=\"0\">"
- "</a></td><td>", id);
+ "</a></td></tr><tr><td>", id);
tmp = html;
if (!config) {
@@ -506,7 +506,7 @@ e_summary_rebuild_page (ESummary *esummary)
ESummaryPrivate *priv;
GList *windows;
char *service_table = "<table numcols=\"3\" cellspacing=\"0\" cellpadding=\"0\" border=\"0\" height=\"100%\">";
- int numwindows;
+ int numwindows, numrows;
int i, j, k;
g_return_val_if_fail (esummary != NULL, FALSE);
@@ -545,10 +545,15 @@ e_summary_rebuild_page (ESummary *esummary)
numwindows = g_list_length (priv->window_list) - 1;
windows = priv->window_list;
- for (i = 0; i < numwindows / 3; i++) {
+ if ( (numwindows % 3) == 0)
+ numrows = numwindows / 3;
+ else
+ numrows = (numwindows / 3) + 1;
+
+ for (i = 0; i < numrows; i++) {
GList *window = windows;
- g_print ("i: %d/%d\n", i, numwindows);
+ g_print ("i: %d/%d\n", i, numrows);
/* Do the same row twice:
Once for the title, once for the contents */
for (j = 0; j < 2; j++) {