Commit Graph

14976 Commits

Author SHA1 Message Date
A Cœur
bde1359d5d Adopt localizedStringWithFormat for displayed quantities (#4109)
* Adopt localizedStringWithFormat for displayed quantities

* xib internationalization support is done
2022-11-14 18:30:03 +00:00
Mike Gelfand
1d9159fffc Fix incorrect selection behavior when building against GTK 4 (#4168)
View-relative coordinates were treated as bin window-relative, leading to
incorrect selected item calculation.

Broken since the introduction of GTK 4 support in #3916.
2022-11-14 18:27:15 +00:00
Mike Gelfand
f8d981349e Fix issues reported by clang-tidy misc checks (GTK client) (#4167)
* Fix `misc-const-correctness` clang-tidy issues

* Fix `misc-no-recursion` clang-tidy issues

* Extend clang-tidy configuration
2022-11-14 16:22:38 +00:00
A Cœur
caefebd102 remove duplicate Portuguese (#4141) 2022-11-14 15:53:57 +00:00
Mike Gelfand
c9debcfd48 Sync translations (#4161)
* Sync translations with code

* Sync translations with Transifex
2022-11-14 09:48:42 +00:00
Charles Kerr
f9a6df6f41 refactor: use a condition_variable when removing a torrent from the verifier thread (#4166) 2022-11-13 23:11:48 -06:00
A Cœur
855b782604 Accessibility description for images (#4149) 2022-11-13 21:39:34 -06:00
Charles Kerr
67e992ddf0 refactor: better TR_CURL_SSL_NO_VERIFY (#4159)
clear CURLOPT_CAINFO, CURLOPT_CAPATH iff verification is disabled
2022-11-13 17:17:16 -06:00
Mike Gelfand
fd9c454c45 Fix issues reported by clang-tidy performance checks (GTK client) (#4160)
* Fix `performance-move-const-arg` clang-tidy issues

* Fix `performance-no-automatic-move` clang-tidy issues

* Extend clang-tidy configuration
2022-11-13 20:50:07 +00:00
A Cœur
b322971f6a Fix create torrent out-of-range piece size (#4145) 2022-11-13 13:53:25 -06:00
A Cœur
ff2e544a6b Fix "Block implicitly retains 'self'" (#4132) 2022-11-13 13:10:58 -06:00
A Cœur
d8e7664f2b Fix "terminating with uncaught exception of type std::out_of_range: vector" (#4138) 2022-11-13 12:00:04 -06:00
Mike Gelfand
49ce12ce38 Fix issues reported by clang-tidy cppcoreguidelines checks (GTK client) (#4158)
* Fix `cppcoreguidelines-pro-type-cstyle-cast` clang-tidy issues

* Fix `cppcoreguidelines-pro-type-member-init` clang-tidy issues

* Fix `cppcoreguidelines-prefer-member-initializer` clang-tidy issues

* Introduce `PageBase` for `PrefsDialog` pages

This is in preparation for next PR fixing `Glib::Timer` memory
management.

* Fix `cppcoreguidelines-owning-memory` clang-tidy issues

* Fix `cppcoreguidelines-pro-bounds-array-to-pointer-decay` clang-tidy issues

* Fix `cppcoreguidelines-special-member-functions` clang-tidy issues

* Fix `cppcoreguidelines-init-variables` clang-tidy issues

* Fix `cppcoreguidelines-macro-usage` clang-tidy issues

* Fix `cppcoreguidelines-pro-bounds-constant-array-index` clang-tidy issues

* Fix `cppcoreguidelines-non-private-member-variables-in-classes` clang-tidy issues

* Fix `cppcoreguidelines-pro-type-vararg` clang-tidy issues

* Fix `cppcoreguidelines-pro-bounds-pointer-arithmetic` clang-tidy issue

* Fix `cppcoreguidelines-pro-type-reinterpret-cast` clang-tidy issues

* Fix `cppcoreguidelines-pro-type-static-cast-downcast` clang-tidy issues

* Extend clang-tidy configuration

Enable all `cppcoreguidelines` checks except for three (`avoid-magic-
numbers`, `avoid-non-const-global-variables`, `narrowing-conversions`)
which require [more] extensive refactoring and were left for later.
2022-11-13 17:36:16 +00:00
A Cœur
0ecf084e0f ignoring deprecation warning on NSUnarchiver (#4113) 2022-11-13 10:54:22 -06:00
Mike Gelfand
9e185a17f2 Fix default/minimum CMAKE_OSX_DEPLOYMENT_TARGET handling (#4156)
* Fix default/minimum `CMAKE_OSX_DEPLOYMENT_TARGET` handling

* Drop explicit `CMAKE_OSX_DEPLOYMENT_TARGET` in GHA CI

Rely on minimum set in top-level CMakeLists.txt instead.
2022-11-13 12:02:07 +00:00
Mike Gelfand
095f094dd5 Only run AppVeyor builds on main and versioned branches/tags (#4150) 2022-11-12 20:27:15 +00:00
Mike Gelfand
43acd7e3e4 Remove Xcode project in favor of CMake (#4147)
* Compile images into an assets catalog

* Optionally sign resulting Mac bundle

* Move 3rd-party/utility/test targets to their own folders

* Enable ARC via compile options unconditionally

* Install base and localized resources into correct directory

This seems like a Xcode quirk: if subdirectory containing the resource file
matches the destination directory name (and probably if there's more than one
resource file being installed there), the resulting folder structure then
contains an extra subdirectory, i.e. Resources/dirname/dirname/resname.

* Group source files for better structure in IDEs (Xcode, VS)

* Remove Xcode project

Using Xcode is still possible via "Xcode" CMake generator.

* Use ad-hoc signature if one is not specified

* Always use ad-hoc signature on link, leave proper signing to CPack

* Install localized resources into correct directory (QL plugin)

* Don't include CTest (we don't use additional targets it provides)

* Revert "Remove Xcode project"

This reverts commit dc069f654f.
2022-11-12 20:01:57 +00:00
Kevin Stubbings
55be67b2e6 Add CodeQL workflow (#4125)
* Add CodeQL workflow

* Improve CodeQL setup

Install proper packages to enable GTK and Qt client builds.
Exclude 3rd-party dependencies from analysis (they should be analyzed
separately in their own repositories).
Speed C++ analysis up by building with Ninja.
Speed JavaScript analysis up by skipping CMake configuration and build,
which is not required for interpreted languages.

* Revert unintentional branch specification change

* Exclude generated JavaScript files from CodeQL analysis

Co-authored-by: Mike Gelfand <mikedld@mikedld.com>
Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>
2022-11-12 19:26:06 +00:00
Charles Kerr
250e055c1d fix: warnings from clang tidy sonarcloud coverity (#4143) 2022-11-12 09:53:09 -06:00
A Cœur
48e42ac71e Fix NSURLConnection is deprecated - Use NSURLSession (#4112) 2022-11-11 21:29:48 -06:00
A Cœur
2aa46f840c Remove std::enable_if<std::is_member_function_pointer> (#4139) 2022-11-11 11:18:17 -06:00
Charles Kerr
9e06cf8f2e refactor: make DHT unblocking (#4122) 2022-11-11 10:09:24 -06:00
Mike Gelfand
92b74fee74 Fix issues reported by clang-tidy modernize checks (GTK client) (#4137)
* Fix `modernize-avoid-c-arrays` clang-tidy issues

* Fix `modernize-raw-string-literal` clang-tidy issues

* Fix `modernize-use-nodiscard` clang-tidy issues

* Fix `modernize-deprecated-headers` clang-tidy issues

* Fix `modernize-pass-by-value` clang-tidy issues

* Extend clang-tidy configuration

Enable all `modernize` checks except for one (use-trailing-return-type)
which is an extensive stylistic change for later.
2022-11-10 20:35:31 +01:00
Charles Kerr
d61e31c419 fix: more thread safety updates (#4136)
* fix: thread safety in tr_sessionLoadTorrents()

* refactor: use std::future in tr_sessionSet()

* refactor: use std::future in tr_sessionClose()
2022-11-10 12:04:49 -06:00
Ilkka Kallioniemi
6f43883d8b Update building docs for Debian (#4101) 2022-11-10 08:28:50 -06:00
Charles Kerr
2d2270c7d9 fix: thread-sanitizer warnings in SandboxedTests (#4131) 2022-11-09 23:56:08 -06:00
Charles Kerr
7e817b5a43 refactor: fix thread sanitizer warnings in tr_sessionClose() (#4130) 2022-11-09 20:30:34 -06:00
Mike Gelfand
1e32e44f60 Bind sensitivity properties in .ui files (#4128) 2022-11-09 20:46:23 +00:00
Charles Kerr
8b3fea9adf build: bump libb64 (#4129)
this fixes a libb64 FTBFS in clang-15 due to -Werror
2022-11-09 14:04:06 -06:00
Mike Gelfand
eec93de5ca Fix issues reported by clang-tidy readability checks (GTK client) (#4127)
* Fix `readability-container-data-pointer` clang-tidy issues

* Fix `readability-container-size-empty` clang-tidy issues

* Fix `readability-isolate-declaration` clang-tidy issues

* Fix `readability-convert-member-functions-to-static` clang-tidy issues

* Fix `readability-else-after-return` clang-tidy issues

* Fix `readability-redundant-member-init` clang-tidy issues

* Fix `readability-uppercase-literal-suffix` clang-tidy issues

* Fix `readability-make-member-function-const` clang-tidy issues

* Fix `readability-simplify-boolean-expr` clang-tidy issues

* Fix `readability-qualified-auto` clang-tidy issues

* Fix `readability-avoid-const-params-in-decls` clang-tidy issues

* Fix `readability-implicit-bool-conversion` clang-tidy issues

* Fix `readability-inconsistent-declaration-parameter-name` clang-tidy issues

* Add initial .clang-tidy configuration

Currently enabling readability checks only, others to follow. Of the
four disabled readability checks, three (function-cognitive-complexity,
identifier-length, magic-numbers) require extensive refactoring and were
left for later, and one (redundant-access-specifiers) is not planned to
be fixed due to the current coding style - using extra sections to
separate methods from variables of the same visibility.
2022-11-09 16:58:36 +00:00
A Cœur
69fda72a8b refactor: remove superfluous interface declarations (#4110) 2022-11-08 23:36:53 -06:00
A Cœur
3e0ca88f7d Fix "Forwarding reference passed to std::move" (#4114)
* Fix "Forwarding reference passed to std::move"

* Missing quotes in file references
2022-11-08 22:33:28 -06:00
Charles Kerr
ab78759233 test: add libtransmission::Timer tests (#4121) 2022-11-08 16:20:21 -06:00
Charles Kerr
00cc28cf0b perf: reuse existing evtimers instead of creating new ones (#4116) 2022-11-07 22:42:42 -06:00
Hakjoon Sim
e44a08278b fix: inspector icon should be disabled as default (#4093) 2022-11-07 17:31:30 -06:00
Gary Elshaw
c32161f7ca feat: place upload above download in macOS badge (#4055) 2022-11-07 13:21:49 -06:00
A Cœur
cb932ddf8d Fix "(arm64) could not find object file symbol for symbol" (#4031) 2022-11-07 13:04:26 -06:00
Charles Kerr
162035a653 fix: minor recent clang warnings (#4111)
* refactor: fix modernize-use-default-member-init warning in session-thread.cc

* refactor: fix readability-named-parameter warning in session-thread.cc

* refactor: fix clang-diagnostic-unused-function warning for isSupportedSocket()

* refactor: fix clang-analyzer-deadcode.DeadStores warning in buildHandshakeMessage()

* chore: fix readability-identifier-naming warning for tr_session::session_mutex_

* chore: fix readability-identifier-naming warning for Watchdir::generic_rescan_interval_

* chore: fix readability-identifier-naming warning for __tr_current_time
2022-11-07 11:48:26 -06:00
A Cœur
d2ee0d2d08 feat: Align active filter macOS (#3944) 2022-11-07 11:20:15 -06:00
A Cœur
91e5cf31f6 Fix "nil passed to a callee that requires a non-null 1st parameter" (#4084) 2022-11-07 09:57:35 -06:00
A Cœur
69ee92113f Fix: values above INT_MAX (68 years) are interpreted as negative values (#4085) 2022-11-07 08:27:51 -06:00
A Cœur
fd7bb4a287 Fix "upload/download connectivity is broken" (#4107) 2022-11-07 00:15:35 -06:00
Charles Kerr
4d8509c180 refactor: add libtransmission::evhelpers (#4104) 2022-11-06 15:11:30 -06:00
Charles Kerr
36edd516aa refactor: replace tr_boundinfo with tr_session::BoundSocket (#4103) 2022-11-06 10:35:48 -06:00
Mike Gelfand
bf17a3baf1 Fix web client directory name on Windows (#4099) 2022-11-05 08:45:34 +00:00
Hakjoon Sim
d0ab112622 fix: some style edited for chrome (#4095)
Thanks!
2022-11-05 00:05:23 -05:00
Charles Kerr
7f1a8bafe3 build: bump fast_float from v3.5.0 to v3.6.0 (#4098) 2022-11-04 18:46:13 -05:00
Charles Kerr
831eb8d40f refactor: make tr_session_thread a unique_ptr owned by tr_session (#4069) 2022-11-04 16:20:27 -05:00
Mike Gelfand
d5cc43355c Bump deps versions used for Windows release builds (#4092) 2022-11-04 18:38:28 +00:00
Charles Kerr
e065565cd4 reafctor: use getaddrinfo() instead of evdns (#4094) 2022-11-04 13:29:56 -05:00