Commit Graph

57 Commits (master)

Author SHA1 Message Date
Randy Heydon 2ae961ee56 calendar: properly display synced all-day events.
Discovered that, in the events synchronized from Gadgetbridge, all-day events
have timestamps that disregard local timezones.  Specifically, all-day events
always start at midnight UTC, which caused calendar to display them starting at
a different time depending on time zone offset (e.g. for my offset of -5, I see
all-day events start at 19:00 the day before).  Borrowed logic from the agenda
app to correct this.  This logic shifts an all-day event's start time to start
at midnight in the current time zone.

Also specify all-day events as type "o" (other) so the full day is highlighted
and the start time is not displayed.

Note that this does nothing to handle all-day events that span more than one
day (only the first day is highlighted in the calendar).  Also note that I'm
not sure how this will handle time zone changes, like shifting to/from daylight
savings time.
2025-02-06 20:58:48 -05:00
Randy Heydon 00cd02bcb8 Fix lint warnings.
Loop variables had warnings for being undefinied.  Added the "let" keyword
where they are initialized.
2025-01-29 19:30:43 -05:00
Randy Heydon e007d05e97 calendar: read events synchronized from Gadgetbridge
This is a partial fix for feature request #3707.  This allows synchronized
events (stored in android.calendar.json) to be shown in the app, alongside
the manually entered events and alarm events that are already shown.  Note
only date/time and event title are currently used; other information
available in the synchronized events (e.g. duration, description) are ignored.
2025-01-28 20:37:58 -05:00
Anton 2a10df7f45 Bump app versions 2024-03-04 22:32:06 +01:00
Anton 2e4cb8eb11 Fix no-unused-vars in existing apps 2024-03-04 21:34:50 +01:00
Anton f1d3438d1c Require switch blocks when declaring variables 2024-02-10 16:51:46 +01:00
Erik Andresen ef7695bc76 calendar: remove duplicate settings call 2024-01-15 07:15:30 +01:00
Erik Andresen ae25c46690 calendar: remove debug statement 2024-01-15 07:06:34 +01:00
Erik Andresen 8b7ee2390d calendar: Load holidays before events
Previously events were loaded and as result painted first and a
following draw on a holiday would overwrite the event indicator
2024-01-13 09:11:54 +01:00
Erik Andresen c815168bda sched/calendar interface: fix null timezone 2023-12-10 19:49:37 +01:00
Gordon Williams fcebbf3ef4 Added Utils.readStorageJSON and relaxed JSON parser, and swap all interface.html over
to using it.

This allows Bangle.js 2v20 (or cutting edge) and later to store a relaxed
'JSON' on internal storage which (while still normal JS) is smaller and faster
(and preserves unicode better)

See https://github.com/espruino/Espruino/issues/2429
2023-11-23 12:52:48 +00:00
Erik Andresen 7a6aa80f30 calendar: cleanup 2023-10-20 07:02:35 +02:00
Erik Andresen 4fcd9dba40 calendar: reload settings after change 2023-10-19 22:08:28 +02:00
Erik Andresen 2dec53ae2f calendar: test 2023-10-19 21:45:28 +02:00
Erik Andresen 2bd209f0a1 calendar: tweaks 2023-10-19 21:40:54 +02:00
Erik Andresen f78818ae00 calendar: re-add ndColors setting 2023-10-19 20:00:54 +02:00
Erik Andresen aac031489c Merge remote-tracking branch 'upstream/master' into calendar 2023-10-19 19:47:16 +02:00
Gordon Williams 503516e42a fix settings not loading if no calendar.days.json file exists 2023-10-19 14:06:53 +01:00
Erik Andresen 107468bcdc calendar: drop settings.ndColors, fixes widgets 2023-10-16 19:08:35 +02:00
Erik Andresen 404ceca0b2 calendar: prefix functions with const 2023-10-15 10:42:07 +02:00
Erik Andresen abdbe1767e calendar: Update version 2023-10-15 10:30:41 +02:00
Erik Andresen 5b20af90da Merge branch 'master' of github.com:nxdefiant/BangleApps into widbaroalarm 2023-10-15 10:23:47 +02:00
Erik Andresen eb90dfa89a calendar: Add menu 2023-10-15 10:17:03 +02:00
Erik Andresen 2d7fdd88c2 sched/calendar: Fix timezone handling on ical 2023-08-18 20:40:24 +02:00
Erik Andresen 34e667b615 calendar: adjust strings in front of functions 2023-07-24 19:05:24 +02:00
Erik Andresen 1a932b0618 Calendar: Edit holidays on device in settings
app: Only refactoring, no changed functionality
2023-07-24 18:24:14 +02:00
Erik Andresen d4116f80d5 calendar: Change color for holidays 2023-05-04 21:27:20 +02:00
Erik Andresen 044fc173c5 calendar: Add type other+repeat 2023-05-03 22:09:14 +02:00
Erik Andresen 5da64a5f83 calendar/interface: Add check for existing file 2023-05-02 22:55:58 +02:00
Erik Andresen 8650595ca4 calendar: Add interface.html for holidays 2023-05-02 22:30:47 +02:00
Erik Andresen aa6d7cdbe1 calendar: Display holidays 2023-05-02 20:03:58 +02:00
Erik Andresen 3f1ded53ed calendar: Read day names from locale 2023-05-02 19:33:29 +02:00
Erik Andresen 5d6f14cd21 calendar: Add tag "tool" 2023-02-11 21:37:06 +01:00
Erik Andresen fc4a944da5 calendar: remove event in loop 2023-02-10 17:45:14 +01:00
Erik Andresen ed53150afe calendar event pre calculation to month+2weeks 2023-02-10 17:25:35 +01:00
Erik Andresen 6e81af5db5 calendar cleanup 2023-02-10 17:20:00 +01:00
Erik Andresen 584b25b97c calendar cleanup 2023-02-10 17:15:35 +01:00
Erik Andresen 09f2b655ff calendar 0.13
- Change usage to swipe left/right for next/previous month
- Add up/down swipe for next/previous year
- Display scheduler events for current month on touch
2023-02-10 17:10:37 +01:00
Erik Andresen e836b25e16 calendar: Mark dated events on a day 2023-01-19 21:33:14 +01:00
James Taylor c5f5efff26 calendar - fix off-by-one-error on next year
The calendar jumps from 2022 to 2024 between December and January,
and this seems to fix it

Signed-off-by: James Taylor <jt-git@nti.me.uk>
2022-10-17 08:56:14 +01:00
Alessandro Cocco 42c2b5c8a2 Use default Bangle formatter for booleans 2022-06-18 22:08:51 +02:00
Erik Andresen 602ffee601 calendar: Fix scope of let variables 2022-06-02 19:39:42 +02:00
Erik Andresen 6fafba454d calendar
- Do not register as watch, manually start clock on button
  (Compatibility with Quick Launch)
- Read start of week from new system settings instead of own
  configuration
2022-05-04 23:49:59 +02:00
Erik Andresen 5e5ba0cc69 calendar:
Add one to previous month
2022-03-25 19:01:34 +01:00
Adam Schmalhofer cec31972b5 Merge remote-tracking branch 'upstream/master' into jekyll-apps.json
Ported all of apps.json to metadata.json
2022-01-06 12:47:26 +01:00
Alexander Minges 9a1543c171 calendar: Update screenshot 2022-01-05 17:26:32 +01:00
Alexander Minges af187929ea calendar: Use larger font for dates 2022-01-05 17:25:07 +01:00
Gordon Williams cde46c2cf5 version 2022-01-04 11:03:47 +00:00
Craig Millett 48da0cbacf
Update calendar.js
If week is set to start on Sunday, make Saturday (last row) and Sunday (first row) have weekend colors.
2021-12-21 12:11:30 -07:00
Minges, Alexander Ralph Michael (almin100) 22c5f2281c calendar: compress app icon 2021-12-17 14:51:12 +01:00