Commit Graph

61 Commits

Author SHA1 Message Date
Martchus 4a3aa9c1c1 Fix warnings about implicit conversions when compiling against Qt 6 2023-07-23 22:17:47 +02:00
Martchus 9b143ffbef Avoid unqualified calls to `std::move` 2023-02-20 19:55:16 +01:00
Martchus 7ce566729b Avoid use of QString::front() as it is only available in Qt 5.10 and newer 2022-06-09 19:59:11 +02:00
Martchus 90d2d7bde4 Support all known fields in renaming utility
* Generalize and simplify code for populating tag object
2022-05-24 18:12:50 +02:00
Martchus b4d1df8592 Fix typos found via `codespell --skip .git -w` 2021-07-03 19:38:36 +02:00
Martchus d31fd79e87 Adapt to changes in tagparser library 2021-04-23 22:18:30 +02:00
Martchus 9fbb375924 Adapt to changes in tagparser (without making actually use of the new API) 2021-02-04 23:22:43 +01:00
Martchus 7ed99a5035 Adapt to changes in tagparser 2021-02-01 17:11:48 +01:00
Martchus 670a9a1c91 Adapt to changes in tagparser 2021-01-30 21:57:09 +01:00
Martchus 0a7d05256c Adapt to changes in tagparser v10 2020-12-14 21:19:49 +01:00
Martchus 4387e50202 Join all threads before destructing the renaming engine 2020-11-27 00:40:45 +01:00
Martchus 4951f5bdc3 Expose some more track information to the JavaScript for renaming 2020-10-01 20:56:37 +02:00
Martchus 72ed928667 Actually expose the track info to the JavaScript object 2020-10-01 20:55:42 +02:00
Martchus c06d1f5f53 Fix compilation with no JavaScript provider 2020-09-08 19:09:12 +02:00
Martchus 5eb5fa463c Fix support for Qt < 5.14 2020-06-11 21:33:06 +02:00
Martchus de70f62b24 Don't use deprecated QString::SkipEmptyParts 2020-06-04 20:51:22 +02:00
Martchus 7ed5723fd9 Use Q_SIGNALS instead of signals 2020-03-09 18:46:08 +01:00
Martchus 3e58d67c4c Don't use lower-case Qt macros 2020-03-08 14:04:29 +01:00
Martchus 865e461032 Avoid using QAtomicInteger functions deprecated in Qt 5.14.0 2019-12-15 19:31:34 +01:00
Martchus 72e918b154 Remove debugging leftover 2019-10-11 19:55:45 +02:00
Martchus 4531d10a81 Move QJSEngine into the thread which executes the JavaScript
This fixes https://github.com/Martchus/tageditor/issues/50.

When keeping the QJSEngine tied to the main thread the garbage
collector will run on the main thread's event loop. This leads to
crashes when trying to allocate memory within the engine from
another thread (`QV4::PersistentValueStorage::allocate()`).

The Qt documentation does not mention that the garbage collector
might run on the event loop of the thread tied to the JSEngine.
I expected it only to run after or before allocations/deletions
within the thread calling the engine's methods. There is already
an issue regarding the lack of documentation:
https://bugreports.qt.io/browse/QTBUG-57227

I found no way to obtain the QThread object for a thread started
with Qt Concurrent. The possibility I found was calling
`QThread::currentThread()` from the concurrent thread once it has
already been started. However, when the concurrent thread has
been started it might already be too late to move the engine.
Adding further synchronization to solve this is an overkill so
I resorted to using QThread directly.
2019-10-11 19:47:30 +02:00
Martchus bf4687d0b6 Remove leftovers from old notification system in JS code
This change was made when already investigating https://github.com/Martchus/tageditor/issues/50.
So that issue was there before this change.
2019-10-08 18:55:08 +02:00
Martchus 66c9250246 Adapt to changes in c++utilities 2019-06-10 22:49:46 +02:00
Martchus de558048ce Use override 2019-06-01 12:45:12 +02:00
Martchus 1dbb15dd1c Don't use deprecated Qt features 2019-05-04 22:17:28 +02:00
Martchus 1691b9daa2 Adapt to c++utilities v5 2019-05-04 16:05:20 +02:00
Martchus 8cbde0fdb5 renaming utility: Support album artist 2019-02-13 21:42:50 +01:00
Martchus e9ded173f1 renaming utility: Show better info for confliciting targets
Conflicts are handles well but so far the user just got "can not
be renamed". Now the conflicting item is returned.
2019-02-13 21:42:29 +01:00
Martchus 28860e1051 Improve renaming tool
* Allow to pass a note to the skip function
* Add useful properties to the file info object
* Extend example
2018-11-15 21:36:12 +01:00
Martchus 57f4307c16 Improve coding style 2018-11-15 21:33:01 +01:00
Martchus db2f178542 Refactor and improve coding style of renaming utility 2018-08-15 21:49:06 +02:00
Martchus adf78c6955 Add detection of audio and video files to renaming utility 2018-08-15 21:48:54 +02:00
Martchus 159d0a9739 Improve coding style in renaming utility
Those changings have been created when adding JavaScript
support to syncthingctl. Maybe implement this more like it
works now in syncthingctl?
2018-04-29 19:01:55 +02:00
Martchus f39abd56db Apply changes from jsincludes.h template 2018-04-29 18:59:41 +02:00
Martchus 4b7d7a9499 Apply clang-format 2018-03-07 01:18:01 +01:00
Martchus c1a3e53dc9 Move tagparser to namespace TagParser 2018-03-06 23:10:13 +01:00
Martchus c2b2e4ac44 Adapt to new notification handling 2018-03-06 22:43:51 +01:00
Martchus 3525588219 Expose basic track info to renaming scripts 2017-08-17 19:11:10 +02:00
Martchus b4a17edbc6 Prevent GCC warning preventing rpm build
control reaches end of non-void function
2017-06-10 21:55:07 +02:00
Martchus b34a0e635f Use JS provider defs provided by qtutilities 2017-03-21 10:01:18 +01:00
Martchus 59ab7e6181 Use std::make_unique provided by C++14 2017-02-05 21:04:27 +01:00
Martchus d5c2dd5f5b renaming utility: Improve coding style 2017-01-06 22:15:39 +01:00
Martchus 5472c560f3 renaming utility: Show note for all new dirs 2017-01-06 22:07:03 +01:00
Martchus 0531460df9 renaming utility: Get rid of useless mutex 2017-01-06 22:00:27 +01:00
Martchus 537d31289d Fix typo 2017-01-06 21:29:43 +01:00
Martchus 83e803fcec renaming utility: Handle string conversion errors 2016-12-27 20:23:16 +01:00
Martchus 7d464f496f Consider all strings from tagparser UTF-8 2016-12-20 23:53:33 +01:00
Martchus e75ea5526a Use _wopen under Windows to support unicode filenames 2016-12-19 23:53:12 +01:00
Martchus 2518309608 Use workaround for GCC Bug 66145 2016-06-14 22:54:49 +02:00
Martchus 9a9f7a16a9 fixed coding style 2016-05-07 00:00:59 +02:00