Commit graph

242 commits

Author SHA1 Message Date
Teemu Ikonen f15dd098e3 More GLib.SOURCE_REMOVE usage in return values 2022-11-17 21:04:47 +02:00
Teemu Ikonen 2ed6f27786 Release 0.3.1 2022-11-17 18:58:42 +02:00
Teemu Ikonen f71906723c appdata: Fix screenshot links to point to flathub 2022-11-17 18:55:19 +02:00
Teemu Ikonen a1431c8785 Release 0.3.0 2022-11-17 18:38:29 +02:00
Teemu Ikonen ef089aa991 README.md: Move screenshots to the flathub repo 2022-11-17 18:27:25 +02:00
Teemu Ikonen 21857aa3f4 Merge pull request 'misc-cleanups' (#8) from devrtz/satellite:misc-cleanups into main
Reviewed-on: https://codeberg.org/tpikonen/satellite/pulls/8
2022-11-16 15:19:30 +01:00
Evangelos Ribeiro Tzaras 9d6d5d5322 application: Remove unnecessary return values
Most of these are handlers for signals which according to the C
documentation don't expect any return values, see below:

"activate" from GApplication:
void
user_function (GApplication *application,
               gpointer      user_data)

"clicked" from GtkButton:
void
user_function (GtkButton *button,
               gpointer   user_data)

"released" from GtkGestureMultiPress:
void
user_function (GtkGestureMultiPress *gesture,
               int                   n_press,
               double                x,
               double                y,
               gpointer              user_data)
2022-11-08 14:53:08 +01:00
Evangelos Ribeiro Tzaras 6abb6297c6 application: Prefer named constants in GSourceFunc
As opposed to True and False, this makes the purpose immediately clear
and is a recommended practice.
2022-11-08 14:51:45 +01:00
Evangelos Ribeiro Tzaras 326164cc97 application: Remove unused return values from update()
The return value was never used, so it should be removed.
2022-11-08 14:50:40 +01:00
Teemu Ikonen 4d5a9cc46e nmeasource: Rename NmeaSource.restore() method to close() 2022-11-06 22:37:29 +02:00
Teemu Ikonen 0644484db0 nmeasource: Disconnect from MM updates when quitting 2022-11-06 22:36:26 +02:00
Teemu Ikonen 1092aa3a31 Remove unused arg from SatelliteApp.update() 2022-11-06 21:55:19 +02:00
Teemu Ikonen 966633133a Set main_box sensitive to False if updates timeout 2022-11-06 21:55:19 +02:00
Teemu Ikonen 53a71b7fb8 widgets: Remove unused LabelBarChart widget 2022-11-06 21:55:19 +02:00
Teemu Ikonen 0374b9e7f7 Remove prints, add string arg to ModemError and log it 2022-11-06 21:55:19 +02:00
Teemu Ikonen 4717c146e4 Replace is_on_mobile_screen() with have_touchscreen() 2022-11-06 21:55:19 +02:00
Teemu Ikonen cb6a018cf4 setup.cfg: Set flake8 max-line-length=88 2022-11-06 21:55:19 +02:00
Teemu Ikonen 447ed22f56 nmeasource: Raise ModemError when modem is in a bad state (e.g. no SIM) 2022-11-06 21:55:19 +02:00
Teemu Ikonen ad381023ca nmea: Get the 'valid' key also from GSA (mode > 1) 2022-11-06 21:55:19 +02:00
Teemu Ikonen 247b7a5683 Define appname and app_id only once 2022-11-06 21:55:19 +02:00
Teemu Ikonen 1f1435ee2a Use Gio.Application signal handlers for startup, shutdown etc. 2022-11-06 21:55:19 +02:00
Teemu Ikonen 19db5edc9a Return to mainloop after calling Gtk.Application.quit()
The quit() function does not exit immediately.
2022-11-06 21:55:19 +02:00
Teemu Ikonen 940208e7a3 Make GErrors during init fatal 2022-11-06 21:55:19 +02:00
Teemu Ikonen e3290957c7 nmea: Prefilter NMEA sentences to please pynmea2 2022-11-06 21:55:19 +02:00
Teemu Ikonen 9b8f991e49 nmea: Remove dead code 2022-11-06 21:55:19 +02:00
Teemu Ikonen 28978d0906 README.md: Update with gnss-share info, add links 2022-11-06 21:55:19 +02:00
Teemu Ikonen 63f1dd652d Merge pull request 'Introduce NmeaSource based on gnss-share' (#5) from devrtz/satellite:gnss-share into main
Reviewed-on: https://codeberg.org/tpikonen/satellite/pulls/5
2022-11-06 20:54:27 +01:00
Evangelos Ribeiro Tzaras c32f7be5db application: Log exceptions when using the GnssShareNmeaSource 2022-11-04 09:02:06 +01:00
Evangelos Ribeiro Tzaras 78554c1afd Add plumbing enabling use of GnssShareNmeaSource 2022-11-04 09:02:06 +01:00
Evangelos Ribeiro Tzaras b76c8850c0 Add UnixNmeaSource and GnssShareNmeaSource
gnss-share is used to share a /dev/gnssX GPS character device and
provide access to the data over a unix socket.

gnss-share currently works with sensors from STM and is used on the
Librem5.
2022-11-04 09:02:06 +01:00
Evangelos Ribeiro Tzaras 7701e998e1 Allow specifying NmeaSource on application startup
This adds another startup option '-s' to select the source
and runs the source specific initialization routines.

This patch moves source specific bits into a init_X_Y_source() function
leaving the common bits in init_source()
2022-11-04 09:00:30 +01:00
tpikonen 58f3849108 Merge pull request 'Update to Gnome runtime 43' (#7) from ferenc/satellite:feat/flatpak-runtime-update into main
Reviewed-on: https://codeberg.org/tpikonen/satellite/pulls/7
2022-10-25 20:04:00 +02:00
Ferenc Géczi f7c85c2dd1 Update to Gnome runtime 43
Signed-off-by: Ferenc Géczi <ferenc.gm@gmail.com>
2022-10-25 00:00:00 +00:00
Teemu Ikonen c108403b89 Only connect edge-overshot signal when on mobile screen
Add function is_on_mobile_screen(widget) which determines the size of
the monitor on which the widget (or it's parent) is realized.

Use this function to determine whether to show a pulley menu on top edge
overshot or not.
2022-09-07 17:27:14 +03:00
Teemu Ikonen 10b992dcb7 Do not request new data when updating barchart with gestures 2022-09-07 16:05:40 +03:00
Teemu Ikonen b121db5477 ReplayNmeaSource._really_get(): Return None if NMEA file could not be read 2022-09-07 15:34:43 +03:00
Teemu Ikonen 914015cd33 update(): Return if we get() empty list or None as nmeas 2022-09-07 15:33:16 +03:00
Teemu Ikonen 9f93eb7b1a Display exception messages correctly 2022-09-07 15:28:31 +03:00
Teemu Ikonen ba2c884d68 Release 0.2.8 2022-09-07 10:28:28 +03:00
Teemu Ikonen ed16495fe9 Add SPDX-License-Identifier headers everywhere
Fixes #6.
2022-09-06 19:01:25 +03:00
Teemu Ikonen f717473b2a README.md: Add 'License' section 2022-09-06 18:00:26 +03:00
Teemu Ikonen e59179ed34 data/appdata.xml: Fix license to to GPL-3.0-only 2022-09-06 18:00:26 +03:00
Teemu Ikonen 5ac3b9471f Adapt ReplayNmeaSource to NmeaSource changes 2022-09-06 18:00:26 +03:00
Teemu Ikonen fd3289932d Refactor NmeaSource class
Make update_callback a mandatory argument to NmeaSource.__init__().

Adapt ModemManagerNmeaSource to changes in the superclass.
2022-09-06 18:00:26 +03:00
Teemu Ikonen 62724f6194 Keep timeout_cb running
Return True from the fallback timeout callback in order to keep it
running. This makes the 'Age of update' field work as it should.
2022-09-06 17:13:54 +03:00
Teemu Ikonen a31bdd7ddf flake8 2022-08-29 10:46:44 +03:00
Teemu Ikonen 6519e08b24 quectel.py: Handle exceptions on modem.Command() calls
Fixes #4.
2022-08-29 10:37:00 +03:00
Teemu Ikonen cbc11f3b14 Release 0.2.7 2022-08-10 11:10:45 +03:00
Teemu Ikonen f1c7f10f10 Fix menu popup by edge-overshot 2022-08-10 11:10:39 +03:00
Teemu Ikonen 6d8087f839 Add a CSS file with larger padding on menubutton labels 2022-08-09 15:48:48 +03:00