view: rework active-date

The current implementation is deficient in many ways, the
worst one being the it relying on GObject semi-synchronous
property emission.

This issue was exposed by the Week view code, where the active
date was updated, but delayed to reach the Week header and some
events were being added ~before~ the active date changed.

With this work, I was also able to figure out a bunch of code
that relied on this (i.e. luck) to work.
This commit is contained in:
Georges Basile Stavracas Neto
2017-04-12 20:51:23 -03:00
parent 2e84c00233
commit aa5b963412
11 changed files with 295 additions and 259 deletions
-2
View File
@@ -9,7 +9,6 @@
<child>
<object class="GcalWeekHeader" id="header">
<property name="visible">True</property>
<property name="active-date" bind-source="GcalWeekView" bind-property="active-date" bind-flags="default" />
<signal name="event-activated" handler="on_event_activated" object="GcalWeekView" swapped="yes" />
</object>
</child>
@@ -37,7 +36,6 @@
<property name="visible">True</property>
<property name="hexpand">True</property>
<property name="vexpand">True</property>
<property name="active-date" bind-source="GcalWeekView" bind-property="active-date" bind-flags="default" />
<signal name="event-activated" handler="on_event_activated" object="GcalWeekView" swapped="yes" />
</object>
</child>