* Optimization to floor layout in box view
authorArt Cancro <ajc@citadel.org>
Fri, 20 Jun 2003 03:39:27 +0000 (03:39 +0000)
committerArt Cancro <ajc@citadel.org>
Fri, 20 Jun 2003 03:39:27 +0000 (03:39 +0000)
webcit/ChangeLog
webcit/roomops.c

index ac273fbf0eafa03a2f8f8c561bac320db068d21e..310b013a640a1feca591cddd1f48709247a647ef 100644 (file)
@@ -1,4 +1,7 @@
 $Log$
+Revision 500.2  2003/06/20 03:39:27  ajc
+* Optimization to floor layout in box view
+
 Revision 500.1  2003/06/20 03:04:26  ajc
 * "Reply" button on messages now handles IGnet recipients correctly
 
@@ -1489,4 +1492,3 @@ Sun Dec  6 19:50:55 EST 1998 Art Cancro <ajc@uncnsrd.mt-kisco.ny.us>
 
 1998-12-03 Nathan Bryant <bryant@cs.usm.maine.edu>
        * webserver.c: warning fix
-
index f7640d76f0f84a975a3fb1b62689e5f8bff5c600..aaac83ae69380bfc01df194204ba459bf38a7b55 100644 (file)
@@ -1881,8 +1881,11 @@ void do_rooms_view(struct folder *fold, int max_folders, int num_floors) {
        static int columns = 3;
        int boxes_per_column = 0;
        int current_column = 0;
+       int nf;
 
-       boxes_per_column = (num_floors / columns);
+       nf = num_floors;
+       while (nf % columns != 0) ++nf;
+       boxes_per_column = (nf / columns);
        if (boxes_per_column < 1) boxes_per_column = 1;
 
        /* Outer table (for columnization) */