[california] Remove "Show only days in current month" month view option



commit b575c47cfc43d5d53bc564a506c07727c5625f24
Author: Jim Nelson <jim yorba org>
Date:   Thu May 22 17:29:30 2014 -0700

    Remove "Show only days in current month" month view option
    
    This was intended to be hooked up to Preferences but with our
    current design it doesn't seem likely, in particular the way
    California displays all-day and day-spanning events in the month
    view.

 src/view/month/month-cell.vala       |    8 --------
 src/view/month/month-controller.vala |    6 ------
 src/view/month/month-grid.vala       |    2 --
 3 files changed, 0 insertions(+), 16 deletions(-)
---
diff --git a/src/view/month/month-cell.vala b/src/view/month/month-cell.vala
index cc21f3a..95fc710 100644
--- a/src/view/month/month-cell.vala
+++ b/src/view/month/month-cell.vala
@@ -27,14 +27,12 @@ internal class Cell : Common.EventsCell {
         notify[PROP_DATE].connect(update_top_line);
         
         owner.notify[Grid.PROP_FIRST_OF_WEEK].connect(on_first_of_week_changed);
-        owner.owner.notify[Controller.PROP_SHOW_OUTSIDE_MONTH].connect(update_top_line);
         
         update_top_line();
     }
     
     ~Cell() {
         owner.notify[Grid.PROP_FIRST_OF_WEEK].disconnect(on_first_of_week_changed);
-        owner.owner.notify[Controller.PROP_SHOW_OUTSIDE_MONTH].disconnect(update_top_line);
     }
     
     protected override Common.EventsCell? get_cell_for_date(Calendar.Date cell_date) {
@@ -74,12 +72,6 @@ internal class Cell : Common.EventsCell {
     }
     
     private void update_top_line() {
-         if (!owner.owner.show_outside_month && !(date in owner.month_of_year)) {
-            top_line_text = null;
-            
-            return;
-        }
-        
         top_line_text = date.day_of_month.informal_number;
         top_line_rgba = (date in owner.month_of_year)
             ? Palette.instance.day_in_range
diff --git a/src/view/month/month-controller.vala b/src/view/month/month-controller.vala
index f4e9fac..60ef605 100644
--- a/src/view/month/month-controller.vala
+++ b/src/view/month/month-controller.vala
@@ -15,7 +15,6 @@ namespace California.View.Month {
 
 public class Controller : BaseObject, View.Controllable {
     public const string PROP_MONTH_OF_YEAR = "month-of-year";
-    public const string PROP_SHOW_OUTSIDE_MONTH = "show-outside-month";
     
     // number of Grids to keep in GtkStack and cache (in terms of months) ... this should be an
     // even number, as it is halved to determine neighboring months depths
@@ -44,11 +43,6 @@ public class Controller : BaseObject, View.Controllable {
     public Calendar.FirstOfWeek first_of_week { get; set; }
     
     /**
-     * Show days outside the current month.
-     */
-    public bool show_outside_month { get; set; default = true; }
-    
-    /**
      * @inheritDoc
      */
     public string title { get { return _("Month"); } }
diff --git a/src/view/month/month-grid.vala b/src/view/month/month-grid.vala
index 6127986..80ec831 100644
--- a/src/view/month/month-grid.vala
+++ b/src/view/month/month-grid.vala
@@ -97,13 +97,11 @@ private class Grid : Gtk.Grid {
         
         owner.notify[Controller.PROP_MONTH_OF_YEAR].connect(on_controller_month_of_year_changed);
         owner.notify[View.Controllable.PROP_FIRST_OF_WEEK].connect(update_first_of_week);
-        owner.notify[Controller.PROP_SHOW_OUTSIDE_MONTH].connect(update_cells);
     }
     
     ~Grid() {
         owner.notify[Controller.PROP_MONTH_OF_YEAR].disconnect(on_controller_month_of_year_changed);
         owner.notify[View.Controllable.PROP_FIRST_OF_WEEK].disconnect(update_first_of_week);
-        owner.notify[Controller.PROP_SHOW_OUTSIDE_MONTH].disconnect(update_cells);
     }
     
     private Cell get_cell(int row, int col) {


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