ed495ec667
Add UI to configure what information should be considered to compute overall status
...
* See https://github.com/Martchus/syncthingtray/issues/74
* See https://github.com/Martchus/syncthingtray/issues/76
2021-01-01 20:55:18 +01:00
b2ba8c01ea
Use header-only target of qtutilities
...
See the commit message of the corresponding commit in c++utilities
(9fb3bbe179698fb10339d4911b98531b0847cfa1) and also the related commit in
reflective-rapidjson (5c49a438ade5ae4253ae978e3a22cf88bd7cb2e2).
2021-01-01 18:50:46 +01:00
da911c6350
Refactor overall status compution
...
* Allow configuring the information to consider for computing the overall
status via SyncthingStatusComputionFlags
* Add flag to allow considering the status of remote devices for
https://github.com/Martchus/syncthingtray/issues/74
* Show only plain "idle" status when no flags are present for
https://github.com/Martchus/syncthingtray/issues/76
* Set the default flags to keep the default behavior as-is
2020-12-31 02:48:18 +01:00
392eb70b12
Remove uses of SyncthingStatus::OutOfSync which is never actually set
2020-12-31 02:33:20 +01:00
f7c3ceaece
Improve documentation of connector library
2020-12-31 02:30:05 +01:00
41e0934cd8
Don't call recalculateStatus() in emitNotifications()
...
because notifications have nothing to do with the status and it should not
make a difference since the status would not change. The UI is supposed to
rely only on newNotification().
2020-12-31 02:28:11 +01:00
b8f3b664e0
Use CPP_UTILITIES_MARK_FLAG_ENUM_CLASS for SyncthingHighLevelNotification
2020-12-31 02:17:25 +01:00
c827907ea6
Update SyncthingDirStatus enum to new states from syncthing/lib/model/folderstate.go
2020-12-31 02:13:32 +01:00
64686caee6
Avoid detaching Qt container in SyncthingConnection::abortAllRequests()
...
* See https://doc.qt.io/qt-5/qtglobal.html#qAsConst
* Using std::as_const() instead of qAsConst() to keep support for Qt 5.6
2020-12-31 02:11:35 +01:00
1bf58bf38d
Apply cmake-format and clang-format
2020-12-17 17:52:02 +01:00
a069fa954b
Apply clang-format
2020-11-03 18:28:31 +01:00
bacca0241a
Fix build with Qt 6 (beta1)
2020-10-23 17:04:35 +02:00
49bbebd1ad
Allow configuring package suffix for qtutilities individually
2020-10-23 17:03:57 +02:00
c9a56da42c
Fix compilation of mocked configuration
2020-10-07 21:42:50 +02:00
0b5fb14931
Remove overspecification of Qt version in documentation and comments
2020-09-04 01:13:46 +02:00
3b49e9e312
Support Qt 6 (commit 174154b)
2020-09-04 01:09:18 +02:00
1d0888a621
Reformat CMakeLists.txt with cmake-format 0.6.11
2020-08-11 23:15:41 +02:00
e44a523e3a
Update translations
2020-05-05 19:02:30 +02:00
364326ddf6
Add missing includes in some header files
...
See https://github.com/Martchus/syncthingtray/issues/64
2020-04-27 23:08:41 +02:00
f14a34b877
Apply clang-format
2020-03-17 18:56:59 +01:00
ccb2ac3144
Clear recent changes when re-connecting (to other instance)
2020-03-17 18:55:50 +01:00
395a3503d7
Apply clang-format
2020-03-05 19:17:55 +01:00
db65957154
Start a few queries before testing to disconnect
2020-03-05 19:17:42 +01:00
6010bf72c9
Stop auto-reconnect timer when disconnecting
2020-03-05 19:16:26 +01:00
c152152b67
Improve comments in build scripts
2020-03-05 19:04:55 +01:00
b8f19b5cc1
Improve code to avoid multiple completion requests
2020-03-02 18:20:48 +01:00
7ad623d660
Increase the timeout for disconnect in tests
2020-03-02 18:19:47 +01:00
c797850563
Fix missing QHash include required with older Qt versions
2020-03-02 16:00:16 +01:00
28dc0bb825
Fix duplicated 'eventType == '
2020-03-02 15:51:14 +01:00
cb0d414018
Use std::unordered_map consistently and support legacy Qt
2020-03-02 15:38:38 +01:00
5227a7961e
Use queued connection for "other replies"
...
so the handler is not called while looping through the
list of these replies to abort them. The handler must
not be called in that situation because it mutates the
list.
2020-03-01 23:40:27 +01:00
11834f89d4
Stop polling timers when reconnecting/disconnecting
2020-03-01 23:20:30 +01:00
fb86ee7bf9
Avoid unnecessary completion queries
...
* Ensure the completion for the same dev/dir is not requested
twice
* Prevent completion query if (no longer) polling for events
2020-03-01 23:06:02 +01:00
b8edea29f9
Update translations
2020-03-01 22:06:18 +01:00
bafdb22c47
Compute the sync state for remote devices
...
See https://github.com/Martchus/syncthingtray/issues/62
2020-03-01 22:04:30 +01:00
5a93e5e8dd
Update translations
2020-02-18 20:50:53 +01:00
94753de797
Fix start/stop button tooltip for system-wide systemd service
2020-02-02 19:51:16 +01:00
a9abeea8e3
Apply cmake-format 0.6.8
2020-02-02 19:50:35 +01:00
133dbacb5d
Use consistent order for visibility attribute
2020-01-29 18:51:10 +01:00
309ff054a0
Add option to connect automatically on startup
2020-01-23 19:09:51 +01:00
f9100bb0b4
Don't record file changes on dir level by default
2020-01-18 16:57:03 +01:00
dab3fd7e31
Update translations
2020-01-18 16:47:51 +01:00
7edaacc677
Apply clang-format
2020-01-18 16:43:13 +01:00
6026339c83
Show recent changes
2020-01-18 16:43:13 +01:00
2d704cf765
Fix missing export macros
2020-01-10 18:01:37 +01:00
04b6ff9bf1
Update translations
2019-12-18 00:31:53 +01:00
32f78b74fd
Overhaul systemd integration, support system-wide units
...
* Lazy initialize systemd interface and don't initialize it
at all if the unit name is empty
* Allow to supervise/control system-wide units in addition to
user units (see https://github.com/Martchus/syncthingtray/issues/61 )
* Avoid redundant code
2019-12-18 00:18:46 +01:00
131050b275
Don't use functions deprecated in Qt 5.14.0
2019-12-18 00:07:52 +01:00
4b5a8efa3e
Apply cmake-format v0.6.0
2019-11-30 18:24:19 +01:00
6497f74046
Use override in test fixtures
2019-10-13 18:28:32 +02:00
38987707bd
Update translations
2019-10-09 23:23:02 +02:00
1bb4d5fcbf
Document status enums
2019-09-27 16:48:58 +02:00
31e7e4e79e
Support "Waiting to scan"
...
This state has been introduced
with https://github.com/syncthing/syncthing/pull/4888
2019-09-27 16:41:24 +02:00
6243a4c2fd
Prepare for "Prepare to Sync"
...
See https://github.com/syncthing/syncthing/pull/6028
2019-09-27 16:32:54 +02:00
6724dfa89a
Handle new/unknown dir status better
...
* Show the raw directory status from the Syncthing API if
it is an unknown (maybe newly introduced) status value.
* Note that the same does not apply to the device status
because the device status is only deduced from other
information.
2019-09-21 16:28:08 +02:00
cf5faeca51
Apply cmake-format
2019-09-08 18:12:05 +02:00
p-bo
cd0e5fee74
Added Czech localization
2019-08-20 22:13:00 +02:00
p-bo
3d2ed26d19
Added Czech localization
...
Created syncthingconnector_cs_CZ.ts
2019-08-20 20:55:55 +02:00
bcb81e15b5
Apply clang-format
2019-07-26 22:02:11 +02:00
bb65a97889
Document SyncthingService
2019-07-25 19:54:37 +02:00
7e46096feb
Log directory/device list renewal when event logging enabled
...
This is useful for debugging to track (unnecessary) renewal of those
lists.
2019-07-25 18:27:38 +02:00
Chih-Hsuan Yen
a92ec9e546
Add the default config path on macOS
2019-07-18 11:07:37 +08:00
4b246d4b4d
Improve SyncthingProcess and SyncthingLauncher
...
* Add documentation
* Remove leftovers
* Ensure all members are initialized
* Improve coding style
2019-07-13 16:42:19 +02:00
b9e9d76594
Update translations
2019-07-13 13:38:51 +02:00
c521e2f808
Apply clang-format
2019-07-13 13:21:25 +02:00
335913c8ca
Fix build without systemd support
2019-07-13 13:21:02 +02:00
31bb92da89
Show notifications about launcher errors
2019-07-12 20:25:24 +02:00
56e1e98493
Apply cmake-format
2019-06-16 16:58:52 +02:00
dc7d9b815f
Adapt to changes in c++utilities
2019-06-14 19:15:26 +02:00
64473df5ba
Adapt to changes in c++utilities
2019-06-10 22:48:26 +02:00
657356fcbe
Clean syncthingconnectionmockhelpers.h
2019-05-04 22:23:08 +02:00
0049d96bca
Adapt to c++utilities API changes
2019-05-04 22:18:31 +02:00
a30853cfeb
Apply cmake-format and clang-format
2019-05-04 22:10:37 +02:00
d88df866d2
Adapt to c++utilities v5
2019-05-04 21:05:21 +02:00
107fad90f0
Allow to use SyncthingStatistics in QML
2019-02-27 20:38:37 +01:00
78d4553104
Update translations
2019-02-18 00:41:17 +01:00
e56c950100
Show overall statistics in plasmoid
2019-02-17 23:46:03 +01:00
326f03b604
Apply cmake-format
2019-02-06 17:36:14 +01:00
a1a9db30f9
Update translations
2019-02-06 17:35:49 +01:00
dc5f2d99e2
Fix SyncthingConnection::connectLater()
2019-02-06 17:35:21 +01:00
2370fe1ef5
Let CMake generate code for test application
2019-01-13 22:16:23 +01:00
f74dbe2799
Prevent enless connection attempts in connector test
...
Those are observable on misc OBS builds. This hopefully prevents
perpetual OBS builds and should also allow to actually investigate
what the problem is.
2019-01-13 17:48:39 +01:00
028a456c4e
Update translations
2018-12-29 20:40:40 +01:00
267cbd7dad
Document SyncthingConnection::readDevRejected()
2018-12-26 01:14:19 +01:00
1156721822
Ensure not to continue reconnecting while still aborting
2018-12-26 01:14:01 +01:00
67723bfa27
Set status to disconnected on error due to insufficient config
2018-12-25 02:31:18 +01:00
c83df582b6
Fix subtile bugs on reconnect
...
* Ensure previous long polling requests for events are aborted
before connecting again
* Ensure results from previous requests are always discarded
after aborting to reconnect
2018-12-25 02:30:13 +01:00
ad42c24c96
Prevent reading QNetworkReply in error case when not bytes available
2018-12-24 17:35:10 +01:00
1d5b90a693
Allow always to change config
2018-12-24 17:19:11 +01:00
35903fc996
Simulate flaky syncthing service
2018-12-23 21:28:43 +01:00
cdd78fb026
Fix typo in code for mocked service configuration
2018-12-23 19:42:17 +01:00
6dc521599f
Adapt tests to changes in dir error handling
2018-11-03 21:55:31 +01:00
d803f83d0f
Update translations
2018-11-03 21:41:44 +01:00
4a42a3f0c0
Fix and refactor directory error handling
...
* Rely not only on the FolderErrors event
* Request pull errors when opening the dialog
* Use "pullErrors" from FolderSummary
* Move code for directory error dialog into
its own class
This should fix that sometimes obsolete errors
were still displayed or actually present errors
missing.
2018-11-03 21:30:17 +01:00
dcbc19cf8c
Adapt mocking to latest changes
...
* Cover all required requests so the connection can be
established without errors
* Add more events to test error handling
* Fix definition of LIB_SYNCTHING_CONNECTOR_CONNECTION_MOCKED
after syncthingconnection.cpp split
2018-11-03 20:44:11 +01:00
c5d22d8984
Adapt tests to changed SyncthingDir::assignStatus()
2018-11-02 23:39:15 +01:00
ad57a0ac9f
Adapt tests to changed status initialization
2018-11-02 23:38:40 +01:00
0cc291ae85
Initialize status of SyncthingDev
2018-11-02 23:37:35 +01:00
0ef2bf919a
Remove duplicated status recalculation
2018-11-02 22:15:16 +01:00
9817be858d
Update stateChanged in readDirSummary()
2018-11-02 22:10:18 +01:00
038cb130b7
Don't emit notifications for folder errors
2018-11-02 21:49:24 +01:00
25ae9266a8
Discard obsolete folder errors
...
* Discard folder errors older than the last "sync" state
* Unfortunately we don't know the the time of the last
sync from the beginning. To prevent showing obsolete
errors in this state, discard all errors if the status
changes to something other than "out-of-syn".
2018-11-02 21:47:27 +01:00
dd5cf12b1c
Improve inserting address from config file
...
* Assume local connection if address is eg. 0.0.0.0
* Use isLocal() from utils which considers the hostname
and interfaces as well
2018-11-02 20:57:25 +01:00
2ee1bc0c63
Discard previous item errors also on connect()
...
Because errors might be gone now and should be repopulated
if not.
2018-10-28 16:03:18 +01:00
25ace0eb17
Fix condition to set status to disconnected
2018-10-28 15:39:15 +01:00
32b2907e67
Split syncthingconnection.cpp
...
* Move methods for specific requests to its own file
2018-10-28 15:37:25 +01:00
2862b6fd87
Re-enable all connection tests
2018-10-28 14:38:34 +01:00
4c4a1ebd47
Don't unset m_has... on disconnect
2018-10-25 18:25:59 +02:00
bb6825aa4c
Use timeout of 0 on first event call
2018-10-25 18:24:31 +02:00
b9a65ef113
Remove redundant poll interval defaults
2018-10-25 18:23:37 +02:00
a024e36ffd
Rework reply/connection handling in SyncthingConnection
...
* Improve consistency
* Ensure all relevant requests are have finished before
setting status to connected
2018-10-25 00:59:13 +02:00
ece582db04
Fix visibility of "Show errors" button in plasmoid
2018-10-24 21:35:08 +02:00
f380732068
Don't use std::function for handlers in testcode
...
Just use the lambdas directly and make if(handler) check
only if possible.
2018-10-21 21:07:43 +02:00
76f214adf1
Ignore test for config too
...
This test randomly fails as well
2018-10-21 00:11:30 +02:00
703225b410
Fix/improve CLI tests
...
* Adapt to interleaved output previously enabled in SyncthingTestInstance
* Make it work when verbose output for debugging is enabled
* Show which status line didn't match in case of an failure
* Disable flaky rescan tests in release mode
2018-10-20 23:48:24 +02:00
97dab2a959
Disable flaky tests for release
2018-10-20 22:12:26 +02:00
2e67e6b2de
Use signals for logAvailable() and qrCodeAvailable()
2018-10-20 22:08:25 +02:00
c7bccf023a
Fix tests, make them more stable and verbose
...
Tests still sometimes fail when
* requesting QR code
* requesting rescan
2018-10-18 23:37:29 +02:00
8a77cdf516
Pass callbacks for requestLog() and requestQrCode() by ref
2018-10-18 23:34:59 +02:00
407514289a
Fix typo infos -> info
2018-10-18 23:34:02 +02:00
8dde95fc82
Don't override defines when configuring optional behavior
2018-10-18 23:23:47 +02:00
d138c6d9d1
Change address of dev in testconfig to something not reachable
...
in my local network - otherwise Syncthing panics for whatever
reason :-/
2018-10-14 23:31:19 +02:00
dfff485fc4
Update testconfig to version 28
...
Not sure whether it actually works. Right now Syncthing crashes
under Arch Linux for me using the previous config and the updated
version.
2018-10-14 22:50:54 +02:00
e410991012
Allow logging all API calls
2018-10-14 22:48:52 +02:00
0ee25c1ae2
Fix warnings about QJsonValue ref
2018-10-12 00:21:05 +02:00
00e0b58c86
Allow logging POSTs
2018-10-12 00:20:15 +02:00
db6c8af414
Debug Syncthing crashes during testruns
2018-10-12 00:09:02 +02:00
c031440c05
Use isLocal() in SyncthingConfig::syncthingUrl()
2018-10-10 22:47:03 +02:00
99cb584249
Use non-standard port for tests
2018-10-10 22:45:49 +02:00
cf22f6b16a
Make all request...() methods consistently public
2018-10-10 22:15:12 +02:00
00e83e721d
Consider failure to request disk events fatal
...
Prevents endless polling for disk events in the error
case.
2018-10-10 22:05:48 +02:00
533a5d0939
Use override
2018-10-10 21:26:46 +02:00
87a10c5b33
Allow hiding Plasma applet in certain states
...
See https://github.com/Martchus/syncthingtray/issues/23
2018-10-10 17:48:48 +02:00
de9259e545
Show whether filesystem watcher active
2018-09-15 18:25:02 +02:00
7611ad1c8e
Propose use of SYNCTHING_TEST_TIMEOUT_FACTOR
2018-09-06 22:04:22 +02:00
9599dcee81
Increase timeout for applying config
2018-09-06 21:58:41 +02:00
791f1ccd33
Fix missing whitespace in German translation
2018-08-25 13:14:45 +02:00
af120f1ae1
Update translations
2018-08-05 15:21:12 +02:00
7e2eea8523
tests: Increase timeouts, use timeout factor everywhere
2018-08-05 15:20:21 +02:00
73c44591d5
Consume disk events in SyncthingConnection
...
First step to:
* Show history of most recent file changes
* Notify about file changes
(see https://github.com/Martchus/syncthingtray/issues/7 )
2018-08-04 22:06:31 +02:00
45ef2518e8
Apply clang-format
2018-08-04 15:47:43 +02:00
39dd98354a
Request Syncthing version
2018-07-30 23:00:40 +02:00
3549a4cdef
Compute overall statistics
2018-07-30 23:00:22 +02:00
7598fef709
Update translations
2018-07-22 22:17:48 +02:00
97e0253902
Fix some warnings, improve coding style
2018-07-22 22:09:59 +02:00
77e75f543c
Add some more directory properties
2018-07-22 22:09:18 +02:00
ad3c8b5240
Don't meld 'unshared' into the status
...
Just deal with it like with the paused flag. This will
hopefully solve the issue that dirs are wrongly shown as
unshared till the next status update.
2018-07-22 22:09:18 +02:00
5a80089cbd
Fix condition for outgoing traffic
2018-07-22 21:18:00 +02:00
0acfdd7002
Use "rescan disabled" instead of "0 s"
2018-07-05 17:40:36 +02:00
7166f6532a
Display overall status info in CLI
2018-07-05 17:39:35 +02:00