Commit Graph
4143 Commits
Author SHA1 Message Date
Georges Basile Stavracas Neto 2f1fe2b49b core/event: Fix transfer annotation 2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto cc696bc365 window: Properly hide start headerbar buttons
Fixes https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/859
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 23dedc0fc8 event-editor/schedule: Trivial autoptr cleanup 2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 185490e272 event-editor/dialog: Don't ask mod type if event wasn't recurrent 2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 966411843a event-editor/dialog: Don't show MOD_ALL if schedule changed
We get into seriously tricky situations if we try and change the
date & time of an event with recurrency, and pass MOD_ALL. That's
because it is ambioguous *where* the change must be applied.

Don't allow selecting MOD_ALL when the scheduling of the recurrent
event changes.

Fixes https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/882
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto df5b9e7821 event-editor/dialog: Don't apply changes if nothing changed
This saves some cycles by not doing anything when nothing needs to
be done.
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 82d8ec31ca event-editor/sections: Add vfunc to check for changes
This will be useful for next commits where we will need to check
if the schedule section actually changed something.
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto dbd2f0df58 event-editor/dialog: Don't apply changes to readonly events
In practice this never does anything relevant, because widgets are
insensitive, but it's better not to nonetheless.
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 5329c2297b views: Don't show MOD_ALL
The only field that views may change using DnD is the start date
field (and, consequently, the end date), and that's exactly what
we must not show the MOD_ALL option for.

Don't show it.

Related: https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/882
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 6a5c0229b9 utils: Add boolean flag for showing MOD_ALL
This will be used by next commit to more finely control editing
of recurrent events.
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 1beb3c9cf3 manager: Remove unnecessary comment 2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 1bb834e110 event-widget: Properly dispose template children 2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto db43bcd096 event: Trivial style fix 2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto a0963c0d36 calendar-monitor: Properly update and delete recurrent events
When we receive the 'objects-modified' signal, we get components
that may represent main events. We also may receive components
that have no recurrency because they were just changed from being
recurrent to non-recurrent.

We need to handle all these cases properly.

If the event has no recurrency set, remove any potential old
recurrence instance lingering around. If we're changing an event
with recurrency, make sure the recurrency instances are in sync
with the new recurrency.

Fixes https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/881
(or so I hope.)
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 16b9337e3f calendar-monitor: Move events hash table to shared section
We'll start accessing the hash table from multiple threads, so
it must be in the shared section of the structure, and it must
be encapsulated by locking.
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 791d443c54 calendar-monitor: Simplify locking code a bit
Use GRWLock*Locker to simplify the locking code in a couple of
places.
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto 5f67c55304 calendar-monitor: Replace mutex by a rw-lock
This will be more appropriate once we start accessing the events
hash table from the monitor thread.
2022-10-17 23:37:13 -03:00
Georges Basile Stavracas Neto baacf696a6 calendar-monitor: Shuffle some variables around
Move them to where they're used.
2022-10-17 23:37:13 -03:00
Sveinn í Felli 8ead52472c Update Icelandic translation 2022-10-17 10:22:54 +00:00
Ray Strode 184d77ef4d window: Fix crash in toast animation
Every once in a while when I'm deleting an event gnome-calendar crashes.

I dug in a bit, and it seems the reason is
adw_toast_overlay_add_toast takes ownership of the passed in reference.

This is a little idiosyncratic for something that's not GInitiallyUnowned,
but it appears to be the API nonetheless.

GCalWindow assumes it owns the reference.

This commit makes both users of the toast happy by adding a ref call.
2022-10-14 13:38:03 -04:00
Yosef Or Boczko 92c14f8bea Update Hebrew translation 2022-10-12 19:02:22 +00:00
Yosef Or Boczko 17bb795846 gcal-week-grid: Fix wrong x postion for events in RTL
Every event in RTL languages is drawn in the
wrong place. As a result the week view is totally unusable.

Fix this.

#817

Signed-off-by: Yosef Or Boczko <yoseforb@gmail.com>
2022-10-12 20:35:52 +03:00
Milan Crha 11a34a1d28 Misc: Fix GObject property types for GLabel::xalign/yalign properties
When running under valgrind, it claims that there's used uninitialized
memory, which is set as GObject property in the code. It's for
GtkLabel::xalign. The problem was that the value in the code is
an integer, but the property itself expects float type. This fixes
the place and where a floating point is already used it annotates
the value to be float, not a double.
2022-10-06 13:36:10 +02:00
Milan Crha 8138619419 gcal-window: Event deletion aborts unfinished previous delete attempt
Cannot use g_clear_pointer() here, because it unsets the pointer first and
only then calls the free function, which means the test on self->delete_event_toast
NULL-ness would be satisfied in the on_toast_dismissed_cb(), thus the previous
event delete attempt would be "cancelled" internally.

Closes https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/858
2022-10-05 18:44:25 +02:00
Milan Crha 5e72aa53f2 gcal-event-editor-dialog: Use user-chosen mode in on_ask_recurrence_response_save_cb()
...to do what the user asked for.

Closes https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/871
2022-10-05 15:39:57 +00:00
Milan Crha df3587752d gcal-month-view: Use gcal_view_set_date() to update date on scroll
This way the content of the view is updated properly, otherwise only
internal GDateTime structure had been updated, but not the view itself.

Closes https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/868
2022-10-05 15:10:47 +00:00
Milan Crha 15ce841a6c gcal-date-chooser: Update also combined_choice in set_date()
Thus it's in sync with the rest of the date chooser.

Also use a common function to replace `self->date` value.

Related to https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/868
2022-10-05 15:10:47 +00:00
Milan Crha d273b4304f gcal_set_date_time: Avoid possible use-after-free
When the `*dest` and `src` are the same, doing g_date_time_unref()
can free the instance before it's assigned back to the `*dest`.
2022-10-05 15:10:47 +00:00
Florian Müllner 80d803d125 date-chooser: Update combined-choice on date changes
Otherwise the header will not reflect the active date.

https://gitlab.gnome.org/GNOME/gnome-calendar/-/issues/876
2022-10-05 14:59:22 +00:00
Dimitrios Christidis 363918dd38 flatpak: Remove gtk3 from gcr options
Refer to https://gitlab.gnome.org/GNOME/gcr/-/issues/100
2022-10-05 14:33:44 +00:00
Alexander Shopov 2cf58a75d4 Update Bulgarian translation 2022-10-02 16:31:04 +00:00
Zurab Kargareteli 639dc5dba5 Update Georgian translation 2022-10-01 10:13:05 +00:00
Nart Tlisha 0951a23bc2 Update Abkhazian translation 2022-09-29 15:38:50 +00:00
Zurab Kargareteli ae3a2db137 Update Georgian translation 2022-09-28 18:25:33 +00:00
Dušan Kazik 002cb3c219 Update Slovak translation 2022-09-27 11:05:18 +00:00
Fabio Tomat ef5c90d17f Update Friulian translation 2022-09-25 19:33:55 +00:00
Daniel Mustieles 760e8b4571 Updated Spanish translation 2022-09-21 08:14:17 +02:00
Rafael Fontenelle 329ba0cecd Update Brazilian Portuguese translation 2022-09-20 18:40:37 +00:00
Marek Černocký fac55b8ccb Updated Czech translation 2022-09-18 22:23:58 +02:00
Sabri Ünal 62f45e053d Update Turkish translation 2022-09-18 08:26:57 +00:00
Balázs Úr b821f90c4a Update Hungarian translation 2022-09-18 05:38:56 +00:00
Baurzhan Muftakhidinov 6b38291d6d Update Kazakh translation 2022-09-18 03:27:15 +00:00
Aleksandr Melman 3b385317f8 Update Russian translation 2022-09-17 16:21:06 +00:00
Anders Jonsson e348e8c13c Update Swedish translation 2022-09-17 12:27:05 +00:00
Jordi Mas 4ad6902be8 Update Catalan translation 2022-09-17 09:56:02 +02:00
Goran Vidović 93d3af68bb Update Croatian translation 2022-09-16 21:03:21 +00:00
Piotr Drąg 3619aaeffd Update Polish translation 2022-09-16 20:50:35 +02:00
Piotr Drąg 21bfc4e151 Update POTFILES.in 2022-09-16 20:47:30 +02:00
Georges Basile Stavracas Neto 6eaa00ffca Post-release version bump 2022-09-15 12:38:39 -03:00
Georges Basile Stavracas Neto 66f93e1fd0 43.0 2022-09-15 12:33:34 -03:00