release: v2.13.1 — recurring-event open fix, 24h time picker, INSERT intent #60

Merged
makiolaj merged 6 commits from release/v2.13.1 into main 2026-07-06 15:36:43 +00:00
Owner

Patch release bundling two bug fixes and one small feature. All three on-device verified on a Pixel 10; full unit suite green.

Included

  • fix(detail): open events whose series starts before 1970 — a pre-1970 (negative epoch-millis) DTSTART was wrongly treated as invalid, so those events (yearly birthdays/anniversaries over CalDAV) showed "Something went wrong" and vanished from search. Now guarded on absent DTSTART only; the sibling backwards-DTEND case is clamped instead of dropped.
    Codeberg #34: https://codeberg.org/jlmakiola/calendula/issues/34
  • fix(edit): time-picker dial honours the app 24h/12h setting — the dial read the system/locale clock instead of the app's TimeFormatPref; now reads LocalUse24HourFormat.
    Codeberg #27: https://codeberg.org/jlmakiola/calendula/issues/27
  • feat(intent): create events from external ACTION_INSERT launches — registers the standard insert-event intent so other apps/widgets (e.g. Todo Agenda) can hand off to Calendula; opens the new-event form prefilled from CalendarContract extras.
    Codeberg #30: https://codeberg.org/jlmakiola/calendula/issues/30
Patch release bundling two bug fixes and one small feature. All three on-device verified on a Pixel 10; full unit suite green. ## Included - **fix(detail): open events whose series starts before 1970** — a pre-1970 (negative epoch-millis) DTSTART was wrongly treated as invalid, so those events (yearly birthdays/anniversaries over CalDAV) showed "Something went wrong" and vanished from search. Now guarded on absent DTSTART only; the sibling backwards-DTEND case is clamped instead of dropped. Codeberg #34: https://codeberg.org/jlmakiola/calendula/issues/34 - **fix(edit): time-picker dial honours the app 24h/12h setting** — the dial read the system/locale clock instead of the app's TimeFormatPref; now reads LocalUse24HourFormat. Codeberg #27: https://codeberg.org/jlmakiola/calendula/issues/27 - **feat(intent): create events from external ACTION_INSERT launches** — registers the standard insert-event intent so other apps/widgets (e.g. Todo Agenda) can hand off to Calendula; opens the new-event form prefilled from CalendarContract extras. Codeberg #30: https://codeberg.org/jlmakiola/calendula/issues/30
makiolaj added 6 commits 2026-07-06 15:28:06 +00:00
DTSTART is stored as UTC epoch millis, so a recurring series anchored
before 1970-01-01 (common for yearly birthdays/anniversaries synced over
CalDAV) has a legitimately negative DTSTART. The detail and search
mappers dropped any row with dtstart < 0, and since the detail query
reads the series-master DTSTART (the ancient anchor), every occurrence of
such a series became un-openable — surfacing as the generic
"Something went wrong." error screen — and the events vanished from
search too.

Relax the guard to reject only an *absent* DTSTART (isNull), which is the
malformed case it was meant to catch; negative epoch millis flow through
correctly (Instant/formatting and the all-day reminder decode are all
Long-based). Add regression tests for both mappers.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The event-form (and Settings) time picker seeded is24Hour from the
system TIME_12_24 override / device locale, ignoring the app's own
TimeFormatPref. So with the app set to 24h under an English locale the
dial still showed AM/PM, while every time label (which reads
LocalUse24HourFormat) showed 24h.

Seed the picker from LocalUse24HourFormat — the app-wide clock
convention already resolved once at the root from TimeFormatPref — so the
dial matches the labels. Drops the now-unused deviceUses24HourClock
helper.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Register an intent-filter for ACTION_INSERT on the events dir mime type
(vnd.android.cursor.dir/event), the way the AOSP calendar accepts one, so
other apps and widgets (e.g. the Todo Agenda widget) can launch Calendula
to create a new event.

MainActivity.insertFormOrNull parses the standard CalendarContract extras
(EXTRA_EVENT_BEGIN_TIME/END_TIME/ALL_DAY, Events.TITLE/DESCRIPTION/
EVENT_LOCATION/RRULE) into a prefilled EventForm via the pure, unit-tested
buildInsertEventForm — omitted fields fall back to the same defaults the
in-app "new event" uses (next full hour, +1h). The form is routed through
the existing single-event prefill channel (RootScreen → CalendarHost →
the create form for review), with calendarId left null so it resolves to
the last-used / first-writable calendar. No new permission is needed
(WRITE_CALENDAR is already held), and the user still explicitly saves.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
toEventDetailCore returned null when a present DTEND preceded DTSTART, the
only remaining false-drop that surfaces as the generic "Something went
wrong." error screen — the same un-openable trap as the pre-1970 DTSTART
bug, and worse because the user can't even open the malformed event to fix
it. Clamp the end to DTSTART (a zero-length event) instead, matching how
SearchMapper already coerces its end. After this the detail mapper drops a
row only when DTSTART is genuinely absent (unrenderable).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
release: v2.13.1 — recurring-event open fix, 24h time picker, INSERT intent
All checks were successful
CI / ci (pull_request) Successful in 8m32s
cf3b897305
Patch release bundling the fixes for #34 (pre-1970 recurring events could
not be opened) and #27 (time-picker dial ignored the 24h setting), plus
#30 (create events from external ACTION_INSERT launches). Bumps
versionName to 2.13.1 (versionCode 21301) and cuts the changelog.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
makiolaj scheduled this pull request to auto merge when all checks succeed 2026-07-06 15:30:18 +00:00
makiolaj merged commit d9f4239729 into main 2026-07-06 15:36:43 +00:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: makiolaj/calendula#60