Commit Graph

16161 Commits

Author SHA1 Message Date
Charles Kerr eeea3c540f
fix: clang-tidy-19 warnings (#6597)
* fix: readability-redundant-casting warnings in libtransmission

* fix: readability-avoid-return-with-void-value warnings in libtransmission

* fix: readability-redundant-member-init warnings in libtransmission

* fix: readability-redundant-inline-specifier warnings in libtransmission

* fix: performance-avoid-endl warnings in libtransmission

* fix: bugprone-multi-level-implicit-pointer-conversion warnings in libtransmission

* fix: bugprone-switch-missing-default-case warnings in libtransmission

* fix: readability-redundant-string-cstr warnings in libtransmission

* fixup! fix: bugprone-multi-level-implicit-pointer-conversion warnings in libtransmission
2024-02-13 10:42:19 -06:00
Will Thompson 54d060cd8e
GTK: Add developer name (and screenshot caption) to metainfo (#6596)
* Add caption to screenshot in metainfo

This is used, for example, as the accessible description for the
screenshot in GNOME Software.

* Add developer_name and developer to metainfo

<developer_name> is deprecated in AppStream 1.0 but is more widely
supported by Flathub and software centres such as GNOME Software and (I
believe) KDE's Discover.
https://www.freedesktop.org/software/appstream/docs/chap-Metadata.html#tag-developer_name

<developer> is the newer tag, introduced in AppStream 1.0.
https://www.freedesktop.org/software/appstream/docs/chap-Metadata.html#tag-developer

Add both, with the same value.
2024-02-12 22:38:48 -06:00
Mrnikifabio f06cb37c06
feat: added `sleep-per-seconds-during-verify` to settings.json (#6572)
* feat: added `sleep-per-seconds-during-verify` to settings.json

* Ensuring `sleep_per_seconds_during_verify > 0` in `verify_torrent` for better performance

* `#include` list reordered alphabetically

* fix: `[readability-inconsistent-declaration-parameter-name]` warning
2024-02-12 09:30:40 -06:00
Yat Ho cf84afda8c
perf: followup improvements to `3.00` Wishlist (#6589)
* refactor: replace `small:set` with `small::vector`

* perf: faster `Wishlist::resort_piece()`

* refactor: PImpl idiom
2024-02-11 21:13:59 -06:00
Cœur 564d813b41
fix crash on empty filedescriptor after `accept` (#6585) 2024-02-11 20:40:41 -06:00
Cœur 3f71114691
feat: support multiple magnets on the same line (#6465) 2024-02-11 19:05:03 -06:00
Cœur ee1e762394
chore: crash report messages are now unsupported (#6583) 2024-02-10 21:15:31 -06:00
Cœur 9bc8ed8e46
fix: right const (#6588) 2024-02-08 23:54:59 -06:00
Charles Kerr 340d0d4966
refactor: add libtransmission::Settings (#6575)
* refactor: add libtransmission::Settings

* refactor: move RPC server's settings into tr_rpc_server::Settings

* build: update project.pbxproj

---------

Co-authored-by: Dzmitry Neviadomski <nevack.d@gmail.com>
2024-02-07 10:14:47 -06:00
Yat Ho 168d56cefc
perf: restore `3.00` wishlist with cached candidates (#6549)
* feat: rewrite Wishlist to cache candidates

* feat: implement mediator and observers

* feat: rewrite existing tests to work for current implementation

* fix: incorrect block spans for existing tests

* feat: add new tests for new features

* fix: clang shadow warning

* fix: heap-use-after-free in tests

* fixup! feat: rewrite Wishlist to cache candidates

* chore: update comment

* code review: reserve vector memory

---------

Co-authored-by: Charles Kerr <charles@charleskerr.com>
2024-02-05 00:14:34 -06:00
Yat Ho ca11c33d05
fix: various DHT bugs (#6569)
* fix: unconditionally send DHT Port msg if supported

* chore: add "maybe" to dht add_node functions

* feat: change `bind-address-ipv*` defaults to empty string

* chore: housekeeping

* fix: initialise DHT node id with random bytes

* chore: housekeeping
2024-02-04 12:18:01 -06:00
Cœur 1c71ba5c83
Fix clang-format const position (#6562) 2024-02-03 22:15:27 -06:00
Cœur 81008a1692
only use a single concurrent queue for timeMachineExclude instead of one queue per torrent (#6523)
* only use a single concurrent queue for timeMachineExclude instead of one queue per torrent

* moving to +initialize for now (will become a `static let` in Swift anyway)

* DISPATCH_QUEUE_SERIAL because DISPATCH_QUEUE_CONCURRENT is limited to 64 simultaneous torrent dispatch_async

* `static` is better than `global`, to make it private to a single compilation unit
2024-01-28 22:49:06 -06:00
Charles Kerr a51f08e532
perf: prefer small containers (#6542)
* perf: make pref_is_savable() constexpr

* refactor: use std::vector in tr_torrents::removedSince()

* chore: remove unused typedef in OptionsDialog

* perf: use std::vector in tr_num_parse_range()

* perf: use small::max_size_set in FileTreeItem::update()

* perf: use small:set in Wishlist::next()

* perf: use small:map in FilterBar

* perf: use small::map for counts in tr_logAddMessage()

* perf: use small::max_size_map in FileTreeModel::twiddleWanted()

perf: use small::max_size_map in FileTreeModel::twiddlePriority()

* perf: use a std::array instead of std::map in TorrentFilter::update()

* perf: use a std::array instead of std::map in TorrentSorter::set_mode()

* perf: use a std::array instead of std::map in TorrentSorter::update()

* perf: use small::set in Application::Impl::on_rpc_changed_idle()

* perf: use std::array for MessageLogColumnsModel::level_names_

* fixup! perf: use std::array for MessageLogColumnsModel::level_names_

* fixup! perf: use small::map for counts in tr_logAddMessage()
2024-01-27 09:33:12 -06:00
Mike Gelfand 9f77ef9c7a
Use native file chooser dialogs (GTK client) (#6545) 2024-01-22 00:24:28 +00:00
Yat Ho 32ef92e7a7
feat: do separate IPv4 and IPv6 port checks in Qt and GTK Client (#6525)
* fix: specify `port-test` ip protocol in response when possible

* feat: IPv4 and IPv6 port test in Qt Client

* feat: shorten timeout of `port-test`

* feat: IPv4 and IPv6 port test in Gtk Client

* chore: housekeeping

* refactor: remove IP protocol error message

* code review: mikedld gtk

* feat: return tag in qt rpc response

* code review: mikedld qt

* feat: move port test button up alongside spin button

* fixup! code review: mikedld gtk

* fixup! code review: mikedld qt

* code review: port status initial text

* feat: decouple ipv4 and ipv6 status updates (GTK)

* feat: decouple ipv4 and ipv6 status updates (Qt)

* code review: unknown protocols are non-pending

Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>

* code review: simplify status text when the statuses are the same

* Revert "feat: return tag in qt rpc response"

This reverts commit 2a022c2bb0ee7ddad81f8176839cf0d043422368.

* code review: add translation context for status text (GTK)

* code review: move `port_test_pending_` to `Impl` (GTK)

* fixup! code review: move `port_test_pending_` to `Impl` (GTK)

---------

Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>
2024-01-21 16:50:26 -06:00
Mike Gelfand 29a566664a
Use semi-transparent color for inactive torrents (#6544) 2024-01-21 16:13:51 -06:00
Yat Ho 08b2fa7e35
fix: restore `files-wanted` argument of `torrent-set` (#6534)
* chore: drop redundant if branch

* chore: housekeeping

* refactor: always keep error message as the second

* fix: restore `files-wanted` argument of `torrent-set`
2024-01-21 14:41:13 -06:00
Geoffrey Bonneville 7030b53e2e
android patches for ndk (#6024)
* android patches for ndk

* Update libtransmission/file-capacity.cc

Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>

* TrMacros: Move common & android vars

* Build android in CI

* Use vcpkg packages for curl & openssl

* Update CI for android

* Fix ndkVersion used with gradle

* Restore actions triggers events

* CMakeLists: Remove cond where curl is not found

* Use vcpkg tag instead of commit hash

Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>

* TrMacros.cmake: clean unused variables & add vcpkg cond

* Remove quotes around VcpkgAndroid inclusion

Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>

* actions: split steps to install vcpkg packages

* Build for android arm64

* actions: add make-android condition

* Revert "Use vcpkg tag instead of commit hash"

This reverts commit 65819026b1.

* build.gradle: use cmake version 3.22.1

* actions: use vcpkg 2024.01.12

* actions: Add ninja-build dependency

---------

Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>
2024-01-21 15:27:24 +00:00
Yat Ho a1160f1556
fix: keep peer io alive inside utp callback (#6507) 2024-01-20 18:09:28 -06:00
Charles Kerr 468de87076
refactor: fix cppcoreguidelines-avoid-do-while warnings (#6527)
* fix: avoid do-while in tr_sys_file_lock()

* fix: avoid do-while in BitfieldTest

* chore: set cppcoreguidelines-avoid-do-while.IgnoreMacros

* fix: avoid do-while in FileList::Impl::onRowActivated()

* fix: avoid do-while in tr_spawn_async_in_parent()

* fix: avoid do-while in handle_sigchld()

* fixup! fix: avoid do-while in tr_spawn_async_in_parent()

* fixup! fix: avoid do-while in FileList::Impl::onRowActivated()

* fixup! fix: avoid do-while in tr_spawn_async_in_parent()

fix fd leak regression

* fixup! fix: avoid do-while in tr_spawn_async_in_parent()
2024-01-20 16:56:42 -06:00
Yat Ho e408aa0741
Revert "feat: Only show .torrent files in the web UI (#6320)" (#6538)
This reverts commit c853ec3358.
2024-01-20 16:56:21 -06:00
Yat Ho 0ce4adf07c
fix: always schedule uTP ack after receiving a packet (#6508)
* fix: always schedule uTP ack after receiving a packet

* chore: add comment to explain change
2024-01-15 00:28:50 -06:00
Mike Gelfand 7ec7607bbc
Update pieces label on source change even if piece size doesn't change (#6516)
Label update is made when slider changes its value, and on source change
slider value is being set to a newly calculated, but not necessarily
different from the previous one, value. This means that the slider
change signal may not be emitted, in which case label continues to show
previous text, including "No source selected", which is misleading.
2024-01-14 11:12:26 -06:00
Mike Gelfand 1de6e93fec
Bump CodeQL to v3 (v2 is to be deprecated) (#6521) 2024-01-12 14:00:10 +00:00
Mike Gelfand 8e7fc76930
Make `SqueezeLabel` [more] accessible (#6520)
Expose label text as accessible value instead of accessible name, and
get accessible name from buddy label as any proper input widget does.
Don't expose label tooltip as accessible description unless it's
different from its text (which isn't the case when displayed text is
truncated). Notify on label text and selection changes.

Switch to `SqueezeLabel` for values in statistics dialog which has
similar layout to information tab of torrent properties dialog.
2024-01-12 03:35:40 +00:00
Ilkka Kallioniemi 35847b3e75
docs: Add Debian 12 instructions (#5866)
* Add Debian 12 installation instructions

* Rename QT to Qt

* Remove GTK4 packages

#5858 bumped minimum required GTK4 past what Bookworm can offer.

* Tr does not bring its own libsystemd-dev
2024-01-11 13:30:12 +00:00
Yat Ho 8b8e9f5c6d
fixup! fix: include daemon-specific options in app defaults (#6505)
* fixup! fix: include daemon-specific options in app defaults (#6499)

* fix: windows build failure

* Revert "fixup! fix: include daemon-specific options in app defaults (#6499)"

This reverts commit 92c2106cc607df36aca4ba28e8c20bd96fa87688.

* refactor: define daemon-specific quarks in libtransmission
2024-01-11 13:20:22 +00:00
Mike Gelfand 7e68cfc7e9
Pin ccache to 4.8.3 on AppVeyor (#6519)
Using ccache 4.9 leads to puzzling errors such as C1090 "PDB API call
failed, error code '23'" when building for x64.
2024-01-11 06:55:36 +00:00
Mike Gelfand 852fa6d169
Qt client accessibility improvements (part 1) (#6518)
* Details dialog Information tab a11y improvements

* Details dialog Options tab a11y improvements

* Make torrent dialog a11y improvements

* Relocate torrent data dialog a11y improvements

* Statistics dialog a11y improvements

* Session dialog a11y improvements

* Trackers dialog a11y improvements

* Preferences dialog Speed tab a11y improvements

* Preferences dialog Downloading tab a11y improvements

* Preferences dialog Seeding tab a11y improvements

* Preferences dialog Privacy tab a11y improvements

* Preferences dialog Network tab a11y improvements

* Preferences dialog Desktop tab a11y improvements

* Preferences dialog Remote tab a11y improvements

* Fix filterbar tab order (depends on construction order if not explicit)
2024-01-10 21:01:03 +00:00
Yat Ho 33f11f8679
fix: use one variable to store `TR_KEY_rpc_authentication_required` (#6514) 2024-01-09 23:12:53 -06:00
Charles Kerr 239478925f
fix: performance-enum-size warnings (#6504) 2024-01-08 08:32:58 -06:00
Charles Kerr 9d433ff8b4
fix: misc-include-cleaner clang-tidy warnings (#6502) 2024-01-07 14:21:05 -06:00
Mike Gelfand 8d4dcece89
Remove unused (but exported for translation) button title (Mac client) (#6503) 2024-01-07 19:11:31 +00:00
Mitch Livingston d0beae2f14
Remove dead pre-Lion code from the torrent table view (#6501)
With our current minimum version, all clients will be using the popover
2024-01-07 13:27:48 -05:00
Nick 632b7048fe
fix: parsing sitename info from 3.xx Servers (#6438) 2024-01-07 12:10:04 -06:00
Yat Ho 7fd29d2d46
fix: include daemon-specific options in app defaults (#6499) 2024-01-07 11:12:31 -06:00
Gary Elshaw ecb58e2966
feat: widen progressbar and increase font size in compact mode 2024-01-06 15:54:52 -06:00
Cœur f6f3ff6e29
fix: base62 conversion in peer-id generation (#6486) 2024-01-06 14:14:20 -06:00
Cœur ae96a2d4b1
fix missing quotes for language codes with a dash (#6489) 2024-01-06 14:13:55 -06:00
Charles Kerr 3f6969217c
chore: remove FMT_STRING macros (#6497) 2024-01-06 14:05:18 -06:00
Charles Kerr ea52e75476
fixup! chore: fix misc-use-anonymous-namespace warnings from clang-tidy (#6488) (#6498)
fix: tyop
2024-01-06 13:04:50 -06:00
Yat Ho 38aa28a831
fixup! chore: webui scss cleanup (#6471) (#6490) 2024-01-06 11:46:10 -06:00
Yat Ho 3b017dbd86
fix: WebUI render html entity in torrent ratio (#6491) 2024-01-06 11:02:10 -06:00
Yat Ho df1dc5812c
fix: restore the `tag` key in RPC response (#6492)
* fix: restore the `tag` key in RPC response

* chore: `tr_rpc_request_exec()` housekeeping

* feat: new tests for RPC tag
2024-01-06 10:40:23 -06:00
Yat Ho 4bb9eab0d0
fix: app defaults should override libtransmission defaults (#6495) 2024-01-06 10:10:14 -06:00
Charles Kerr 646883174b
chore: fix misc-use-anonymous-namespace warnings from clang-tidy (#6488) 2024-01-04 23:12:51 -06:00
Charles Kerr 23eb0ef92d
chore: fix reference to temporary (#6484) 2024-01-04 08:52:08 -06:00
Yat Ho 4cfd9f0c9e
fix: restore `alt-speed-enabled` config parameter (#6483) 2024-01-03 22:58:21 -06:00
github-actions[bot] 1c382cb97e
chore: update copyright years (#6470) 2024-01-03 21:33:30 -06:00