Skip the empty dates in the next30
authorEnrico Zini <enrico@enricozini.org>
Sat, 7 Nov 2009 00:04:50 +0000 (00:04 +0000)
committerEnrico Zini <enrico@enricozini.org>
Sat, 7 Nov 2009 00:04:50 +0000 (00:04 +0000)
README
src/widgets/calendar.vala

diff --git a/README b/README
index 1adfde0da2bf3d2f742ccacfbbbc8a92cd449129..a0b44903320ce575d95fd344e714a7471f4483dc 100644 (file)
--- a/README
+++ b/README
@@ -153,6 +153,7 @@ TODO list / wish list
 
  * Features to add:
  - calendar: show preview of next 30 days
+   (not among the notes: it replaces the calendar view; unless we skip the empty dates, which is a good idea)
  - contacts: show as a fancy focus+context list (see prefuse)
  - GSM power and network
     - link to open SHR-dialer
index cf8a7fc3b6ad5cd6d5b113d81a39245dff6d552c..8f2c662717a8ecb00479b6f88346a3474ce2b0a5 100644 (file)
@@ -234,8 +234,11 @@ public class Calendar : Gtk.VBox
                                        text = "";
                                }
                        }
-                       date.strftime(buffer, "%d %a");
-                       next_30.add_day((string)buffer, text);
+                       if (text != "")
+                       {
+                               date.strftime(buffer, "%d %a");
+                               next_30.add_day((string)buffer, text);
+                       }
                        date.add_days(1);
                }
        }