1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2024-12-21 23:32:35 +00:00
Commit graph

1049 commits

Author SHA1 Message Date
H5117
59c1c1e83b
qt: refactor Application (#7092) 2024-12-18 21:47:37 +00:00
Charles Kerr
d8adecbfb5
fix: clang-tidy-20 warnings in transmission-qt (#7192)
* fix: modernize-min-max-use-initializer-list warning

* fix: readability-container-contains warning

* fix: readability-avoid-return-with-void-value warning

* fix: readability-math-missing-parentheses warnings

* chore: clang-format

* fixup! fix: readability-math-missing-parentheses warnings

* fix: bugprone-suspicious-stringview-data-usage warning
2024-10-23 20:48:01 -05:00
Julia
97abf15050
correct "Queue for download" last activity (#6872)
* simple fix

* apply suggestion
2024-10-21 20:56:37 -05:00
Cœur
a8bf44eeb1
fix: code should be clang-formatted (#7184) 2024-10-20 20:37:06 -05:00
Yat Ho
8b92f6d011
chore: remove unused TR_KEY_show_extra_peer_details app default (#7117) 2024-09-13 22:14:24 +01:00
Yat Ho
d29d1fce5b
fix: use correct quark for Prefs::SHOW_TRACKER_SCRAPES (#7116) 2024-09-13 22:14:02 +01:00
Mike Gelfand
d8413493d0
Move Qt client's tr_main() into a separate file (#7076)
Support special (optional) `--` argument to explicitly separate options
from filenames. Support special `---` argument to separate client
arguments from Qt arguments.
2024-08-24 18:15:19 +01:00
Jason Beck
3e9f5f614a
fix: Qt build missing an icon (#6683)
* Create a new shared location for icons and update qt scripts to package public icons

* Move the Faenza.qrc back to original location

* Revert "Move the Faenza.qrc back to original location"

This reverts commit 963e099d65.

* Replace Faenza to its original location

* Remove attribution for an image that does not exist
2024-07-18 02:12:18 +01:00
Charles Kerr
6132706565
chore: iwyu (#6864)
* chore: do not include <set> unless we use it

* chore: do not include <map> unless we use it

* chore: do not include <string> unless we use it

* chore: do not include <list> unless we use it

* chore: do not include <memory> unless we use it

* chore: do not include <optional> unless we use it

* chore: do not include <functional> unless we use it
2024-05-27 17:36:02 -05:00
Nick
fb79a2d399
qt: add dynamic RPC keys (#6599)
* add dynamic main stat keys

* make dynamic rpc calls more generic
2024-04-01 09:02:17 -05:00
Cœur
edc59ba5d8
fix compatibility with clang-format 18 (#6690)
* fix clang-format

* compatibility with clang-format 17-18
2024-03-15 00:17:10 -05:00
Charles Kerr
a90d0fce2b
refactor: inline simple getters in qt client (#6621)
* refactor: make RpcClient::url() constexpr

* refactor: make Session::getRemoteUrl() constexpr

* refactor: make RpcQueue::setTolerateErrors() constexpr

* refactor: make RpcClient::isLocal() constexpr

* refactor: make Session::isLocal() constexpr

* refactor: make Session::isServer() constexpr

* refactor: make PathButton::label() constexpr

* chore: remove accidentally-committed makelog file
2024-02-18 18:48:27 -06:00
Charles Kerr
d11cddc39a
fix: sonarcloud warnings (#6615)
* fix: cpp:S3358 conditional-operators-should-not-be-nested warning in gtk client

* fix: cpp:S1659 define-each-identifier-in-a-dedicated-statement warning in peer-mgr-wishlist

* Revert "fix; cpp:S3642 replace-enum-with-enum-class warning in gtk client"

* fix: cpp:S3576 remove-virtual-specifier-or-replace-it-by-override warning in rpc-server::Settings

* fix: cpp:S3576 remove-virtual-specifier-or-replace-it-by-override warning in tr_session_alt_speeds::Settings

* fix: remove unnecessary Settings subclass declarations

* fix: cpp:S1117 shadow warning in qt client

* fix: cpp:S6004 use init-statement to limit scope of local

* fix: cpp:S5997 replace-std-lock-guard-with-std-sccoped-lock in favicon-cache.h

* fix: cpp:S1659 define-each-identifier-in-a-dedicated-statement warning in announcer

* fix: cpp:S5817 function-should-be-declared-const warning in cache.h

* fix: cpp:S1186 explain-why-method-is-empty warning in favicon-cache

* fix: cpp:S5408 constexpr-variables-should-not-be-declared-inline warning in favicon-cache

* fix: cpp:S3624 explicitly delete copy assignment, ctor of InFlightData

* fix: cpp:S5997 use std-scoped-lock-instead-of-std-lock-guard

* fix: cpp:S5997 use std-scoped-lock-instead-of-std-lock-guard

* fix: cpp:S5817 function-should-be-declared-const warning in favicon-cache.h

* fix: cpp:S5817 function-should-be-declared-const warning in lru-cache

* fix: cpp:S1709 add-the-explicit-keyword-to-this-constructor
2024-02-17 22:43:24 -06:00
Cœur
c3667fa5a7
fix clang-format (#6616) 2024-02-17 22:41:52 -06:00
Charles Kerr
7c11809672
fix: more clang-tidy warnings (#6608)
* fix: readability-redundant-casting warnings in gtk

* fix: bugprone-move-forwarding-reference warnings in gtk

* fix: readability-redundant-casting warnings in qt

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

* fix: readability-use-std-min-max warning in qt client

* fix: readability-static-accessed-through-instance warning in qt client

* fix: cppcoreguidelines-avoid-const-or-ref-data-members warning in qt client

* fix: readability-avoid-nested-conditional-operator warning in qt client

* fixup! fix: readability-use-std-min-max warning in qt client

* fix: readability-redundant-member-init warnings in gtk client

* fix: performance-avoid-endl warnings in gtk client

* chore: disable readability-qualified-auto

too many false warnings

* chore: disable cppcoreguidelines-avoid-const-or-ref-data-members

* chore: fix readability-duplicate-include warning in gtk client

* chore: fix modernize-use-nodiscard warning in gtk client

* chore: fix readability-convert-member-functions-to-static warning in gtk client

* fixup! fix: bugprone-move-forwarding-reference warnings in gtk

* chore: fix performance-enum-size warning in gtk client

* fix: cppcoreguidelines-prefer-member-initializer warning in gtk client

* fix: readability-identifier-naming warning in qt client

* Revert "chore: fix performance-enum-size warning in gtk client"

This reverts commit 5ce6b562f8.

* fix: readability-redundant-member-init warning in move tests

* fix: readability-redundant-casting warnings in tests

* fixup! fix: readability-identifier-naming warning in qt client

* fixup! fix: readability-avoid-nested-conditional-operator warning in qt client

* fix: readability-static-accessed-through-instance warning in qt client

* fix: readability-redundant-casting warning in watchdir tests
2024-02-17 13:31:49 -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
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
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
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
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
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
Charles Kerr
9d433ff8b4
fix: misc-include-cleaner clang-tidy warnings (#6502) 2024-01-07 14:21:05 -06:00
Nick
632b7048fe
fix: parsing sitename info from 3.xx Servers (#6438) 2024-01-07 12:10:04 -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
github-actions[bot]
1c382cb97e
chore: update copyright years (#6470) 2024-01-03 21:33:30 -06:00
Charles Kerr
22cde5d4b9
refactor: use new tr_variant API in rpcimpl (#6456)
* refactor: tr_rpc_request_exec_json takes a std::function callback

* refactor: tr_rpc_request_exec_json callback takes a tr_variant&&

* refactor: use new tr_variant API in rpcimpl.cc

* refactor: tr_rpc_request_exec_json() now takes a const& to the request

* fixup! refactor: use new tr_variant API in rpcimpl.cc

* chore: rename function to tr_rpc_request_exec()

* chore: remove unused DetailsDialog::Impl::build_torrent_ids_variant_list()

* refactor: minor copyediting in rpcimpl.cc getTorrents()

* refactor: split handler methods between sync, async

* refactor: remove unused args_out param from AsyncHandlers

* chore: fix new readability-inconsistent-declaration-parameter-name warning
2024-01-02 22:14:43 -06:00
Mike Gelfand
f544399183
Sync translations (#6453)
* Sync translations with code

* Move Qt client's it_IT to it

"it_IT" was merged into pre-existing "it", so no (huge) loss of translations
should occur; "it" was chosen as a base since it contains more up-to-date
translations while "it_IT" hasn't changed much in years (I think, because most
phrases were marked as reviewed and so impossible to change by most translators
based on their assigned role).

* Sync translations with Transifex

* Add new languages (90+% complete)

Mac client:
* Basque (eu)
* Hebrew (he)
* Hungarian (hu)
* Japanese (ja)
* Polish (pl)
* Portuguese (Brazil) (pt_BR)
* Swedish (sv)
* Ukrainian (uk)
* Chinese (China) (zh_CN)
* Chinese (Taiwan) (zh_TW)

Qt client:
* Icelandic (is)

Also, fix Qt client languages list to include those already in
translations/ subdirectory and 90+% complete:
* Hebrew (he)
* Chinese (Taiwan) (zh_TW)

* Fix Xcode language mapping for pt_PT/pt-PT

* Fix Xcode language mapping for pt_BR/pt-BR

* Fix Xcode language mapping for zh_CN/zh-CN

* Fix Xcode language mapping for zh_TW/zh-TW

* Sync translations with Transifex (again)

Primarily to fixup "Port: $@" translation, but there were other updates in the
meantime.

* Update list of QuickLookPlugin languages

* Fixup local pt-BR language name in tx config
2023-12-29 15:16:07 +00:00
Nick
e80ec7b7a4
feat: add labels to DetailsDialog of Qt client 2023-12-25 16:09:20 -06:00
Charles Kerr
2dea0b5fa2
fix: gcc 13 warnings, pt. 1 (#6400)
* fix: nullptr dereference warnings

* fix: mixed enumerated and non-enumerated warning

* fix: -Wnull-dereference warning in qt/MainWindow.cc

* fix: -Wnull-dereference warning in TorrentFilter::countTorrentsPerMode()

* fix: -Wnull-dereference warning in VariantHelpers::change(TrackerStat&, tr_variant*)

* build: bump google-test from 1.12.1 to 1.14.0

* Revert "build: bump google-test from 1.12.1 to 1.14.0"

This reverts commit 6fdcffa5de.
2023-12-17 12:49:39 -06:00
Federico Scodelaro
33c4cd1c44
feat(qt): Add ETA to compact view (#3926)
* feat(qt): Add ETA to compcat view

* style: Apply codestyle guides

* fix: Remove whitespaces from translatable string

* chore: fix FTBFS from 76521a1 code shear

---------

Co-authored-by: Charles Kerr <charles@charleskerr.com>
2023-12-16 10:32:07 -06:00
Charles Kerr
15af2ff5be
refactor: show 1.0 progress for zero-byte files (#6307) 2023-12-06 11:23:47 -06:00
Charles Kerr
64d9d57363
chore: fix minor clang-tidy warnings (#6275) 2023-11-21 09:02:03 -06:00
Charles Kerr
76521a1751
refactor: Values pt. 7 - remove tr_formatter_init methods (#6258)
* refactor: initialize libtransmission::Values units in Application::initUnits()

* refactor: use libtransmission::Values instead of Formatter::unitStr()

* refactor: remove Formatter::Size, Formatter:Type

* refactor: use Values::Config to init units in transmission-qt

* refactor: use Values::Config to init units in transmission-mac

* chore: remove unused tr_formatter_foo_init() functions

* chore: make Value::operator+() const

* use Values::Speed, Values::Storage in GTK client

* chore: use snake_case for Formatter methods

* refactor: use Values::Speed in GTK client details dialog

* feat: add Values::Value::is_zero()

* refactor: remove unnecessary UTF8String calls
2023-11-15 22:15:40 -06:00
Charles Kerr
07d96036d9
refactor: Values pt. 6 - remove deprecated API (#6250) 2023-11-14 17:23:51 -06:00
Charles Kerr
4be0dca5ac
refactor: Values pt. 5 - use Values::Speed in Qt client (#6248) 2023-11-13 11:13:17 -06:00
Charles Kerr
37f01fac4c
refactor: migrate variant api (#6238) 2023-11-10 15:41:32 -06:00
Cœur
65755dca33
Fix Qt6 CMAKE_OSX_DEPLOYMENT_TARGET (#6214) 2023-11-05 20:49:26 -06:00
Ilkka Kallioniemi
d49b4a9997
feat: update piece size slider values in Qt 'new torrent' dialog (#6211) 2023-11-05 10:54:12 -06:00
Charles Kerr
2c9768bc12
fix: only append '.added' suffix to watchdir files (#5705) 2023-11-04 13:14:08 -05:00
Charles Kerr
a952a0731f
refactor: remove the tr_error** idiom (#6198)
* refactor: remove the tr_error** idiom

* fix: tr_error::message() is only constexpr in c++20 and up

* chore: silence a couple of g++-12 Wshadow warnings
2023-11-04 11:39:41 -05:00
Julien
2df67c1a73
chore: updated some leftover front-facing copyright years (#6196) 2023-11-03 00:21:35 -05:00
Julien
8ac323d5d6
chore: removed copyright timespans in headers (#4850) 2023-11-01 16:11:11 -05:00
Charles Kerr
237223aeaf
refactor: prefer std::set over QSet (#5703)
* refactor: use std::set instead of QSet in WatchDir.cc

* refactor: use std::set instead of QSet in FileTreeView.cc

* refactor: use std::set instead of QSet in ColumnResizer.cc

* refactor: use std::set instead of QSet in Prefs.cc

* chore: fix rebase error that changed libsmall snapshot

* refactor: more replace QSet with std::set
2023-10-24 21:14:37 -04:00
Cœur
1722f00777
chore: apply clang-format version 17.0.1 (#6054) 2023-10-01 18:45:52 -05:00
Charles Kerr
6ead147620
refactor: use new tr_variant API in tr_session (#6006) 2023-09-16 08:23:35 -05:00
Charles Kerr
ebb1b775af
refactor: public tr_session settings API now returns tr_variants (#5983) 2023-09-07 19:05:16 -05:00
Charles Kerr
59c638c63d
refactor: replace tr_variant::is_*() with tr_variant::holds_alternative() (#5930) 2023-08-21 16:16:54 -05:00
Charles Kerr
5837603b6f
refactor: make tr_variant follow RAII (#5923) 2023-08-20 23:15:23 -05:00