week-view: Add a zoom gesture

This will help the week view work well on small touchscreens and it also
works with touchpads.
This commit is contained in:
Adrien Plazas
2022-06-22 12:04:21 +00:00
committed by Georges Basile Stavracas Neto
parent 0bd11799dc
commit f0021fcffb
2 changed files with 66 additions and 2 deletions
+10 -2
View File
@@ -14,14 +14,22 @@
<object class="GtkScrolledWindow" id="scrolled_window">
<property name="hexpand">True</property>
<property name="vexpand">True</property>
<!-- Zoom Gesture -->
<child>
<object class="GtkGestureZoom">
<signal name="scale-changed" handler="on_zoom_gesture_scale_changed_cb" object="GcalWeekView" swapped="yes" />
<signal name="begin" handler="on_zoom_gesture_begin_cb" object="GcalWeekView" swapped="yes" />
</object>
</child>
<child>
<object class="GtkViewport">
<child>
<object class="GtkBox">
<object class="GtkBox" id="content">
<property name="orientation">horizontal</property>
<child>
<object class="GcalWeekHourBar" id="hours_bar">
<property name="height-request">2568</property>
</object>
</child>
<child>