Commit Graph

6 Commits

Author SHA1 Message Date
Julien 8ac323d5d6
chore: removed copyright timespans in headers (#4850) 2023-11-01 16:11:11 -05:00
Julien 4b8cfa2e57
chore: update copyrights to 2023 (#4834) 2023-02-11 14:49:42 -06:00
Mike Gelfand fbb98ada4a
Fix issues reported by `hicpp` clang-tidy checks (GTK client) (#4711)
* Fix `hicpp-vararg` clang-tidy issues

* Fix `hicpp-explicit-conversions` clang-tidy issues

* Fix `hicpp-signed-bitwise` clang-tidy issues

* Enable the rest of `hicpp` clang-tidy checks
2023-02-03 16:12:48 +00:00
Mike Gelfand c4f4d3d45d
Fix torrents count label update (#4694) 2023-01-30 23:25:23 +00:00
Mike Gelfand bd72b8c3fc
Fix clang-tidy issues stemming from header files (GTK client) (#4623)
* Fix `readability-avoid-const-params-in-decls` clang-tidy issues

* Fix `bugprone-macro-parentheses` clang-tidy issues

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

* Fix `readability-named-parameter` clang-tidy issues

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

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

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

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

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

* Add headers filter for /gtk/ subdirectory
2023-01-21 12:06:20 +00:00
Mike Gelfand 32531fe5ef
Use `Gio::List{Model,Store}` for torrents (#4430)
* Use `Gio::List{Model,Store}` for torrents

Switch from `Gtk::{TreeModel,ListStore}` in preparation for cell
renderers deprecation in GTK 4.10. That will require switching to the
new view classes (`Gtk::{Column,List}View`) which only work with `Gio`
models. Implement an adapter to support GTK+ 3 where the old view class
(`Gtk::TreeView`) only works with `Gtk` models; it is effective enough
but requires a signal connection per item to notify on row changes.

Refactor filtering and sorting (which now happen over the new model) to
use compatible `Gtk::Filter` and `Gtk::Sorter` classes. Although these
classes are only present in GTK 4, the abstraction is suitable for GTK+
3 as well so make our subclasses work for both versions.

Since items (of `Torrent` class) of the new model provide only a very
limited (by design) layer of compatibility with GTK+ 3 way of doing
things, refactor selection handling to do it the new way. Move selection
helpers into `MainWindow` to abstract them away since new view classes
handle it differently.

* Improve session load performance based on profiling results
2022-12-21 21:26:25 +00:00