Commit Graph

17 Commits

Author SHA1 Message Date
Martchus 93b5d66875 Allow browsing remote/global files 2024-04-05 01:30:00 +02:00
Martchus f2210a5691 Avoid warnings of network information backend showing in CLI
Lazy-initialize the network information backend so warnings it possibly
shows don't disturb the output of the CLI (which does not need the network
information backend anyway).
2024-02-29 13:46:42 +01:00
Martchus 572e82cec0 Fix resuming devs when network not metered anymore after 57d47de7 2024-02-18 00:53:28 +01:00
Martchus 106f1d5f92 Fix clazy warning about mismarked slots 2024-02-15 22:06:00 +01:00
Martchus 30fa37f048 Allow to pause automatically on metered network connections
* Allow to pause all devices on metered network connections (devices will
  be automatically resumed when network is no longer metered)
* Allow to stop Syncthing when it was started via the built-in launcher
  on metered network connections (it will be automatically started again
  when the network connection is no longer metered)
* See https://github.com/Martchus/syncthingtray/issues/231
2024-02-15 21:02:18 +01:00
Martchus 76b406f4e1 Adapt tests to recent changes in certificate handling 2024-01-28 21:35:54 +01:00
Martchus 07ff8a5c1b Avoid TLS errors on Syncthing's automatic certificate renewal
* Reload the certificate when running into TLS errors an it looks like the
  certificate was renewed
* See https://github.com/Martchus/syncthingtray/issues/226
2024-01-15 21:29:24 +01:00
Martchus c1284331be Handle redirections more nicely
* Log redirections in accordance with logging settings
* Load self-signed certificate as needed
2023-12-30 20:11:34 +01:00
Martchus fada3c98dd Allow configuring long-polling timeout 2023-11-06 15:06:40 +01:00
Martchus aa524aa8b7 Make event handling of `syncthingctl wait-for-idle` more efficient
Don't go though the list of dirs/devs for every dir/dev change event. Just
go though the list once after receiving new events. This makes also the
code a little bit easier to follow.
2023-09-20 18:12:55 +02:00
Martchus 7e651be694 Fix compilation against Qt < 5.15 for Leap 15.3 builds 2023-07-11 11:55:39 +02:00
Martchus faeefba03f Do not apply transfer timeout to long-polling requests
This leads to "disconnects" from Syncthing otherwise.
2023-07-04 19:26:48 +02:00
Martchus ac07982596 Allow setting transfer timeout for network requests of SyncthingConnection 2023-07-04 18:39:14 +02:00
Martchus dd936b4a81 Workaround lupdate not understanding "enum class" in some cases
Apparently this is still problematic leading to errors like
`Qualifying with unknown namespace/class`. It seems that moving the enum to
a different header file works. The trick to use a macro to define
`enum class` ceased to work on the other hand.

Specifying a function with the namespace like
`void QtGui::FinalWizardPage::showResults()` leads to the same problem and
also needs to be avoided.
2023-06-07 23:14:48 +02:00
Martchus c6a5b40a1d Re-connect when event ID is decreasing 2023-04-15 22:25:12 +02:00
Martchus 843f164df1 Avoid potentially losing events
I have observed that Syncthing Tray can get stuck thinking a remote device
still needs data. Likely the update got lost. The code contains certain
conditions in which folder completion events and requesting completion are
supressed. Those conditions are based on timestamps. That is not ideal as
the accuracy is only one second (so different timestamps might be
considered equal as they are rounded to be the same). Additionally, it
makes no sense to assume a timestamp upon receiving a response as the
information might be older than the time it was received.

This change avoids those conditions. It rather uses the event ID to
decide what event/reply is newer.

This change also uses quint64 instead of int for event IDs to avoid running
into an overflow (or rather conversion error) when deserializing the ID
which might be bigger than int. (Not sure how big the ID can become; this
is to be on the safe side.)
2023-04-15 16:18:23 +02:00
Martchus 96e92f13a3 Avoid relying on symlink for include directories
Symlinks aren't working very well with Git under Windows so better avoid
them.
2023-02-27 18:27:33 +01:00