Remove getApp and getSettings calls from Message-Rendering (#4535)

* refactor: remove singletons from message rendering

* chore: add changelog entry

* Disable the `cppcoreguidelines-avoid-const-or-ref-data-members` clang-tidy check

* auto *app

* Selection is a struct, not a class

* Use ChannelView's `signalHolder_` instead of `channelConnections_`

* Remove `applySettings` step, instead just connect & set each setting individually

* rename & constify some context values

* Handle empty "last message color" setting value better (as it was
        originally in this pr before I removed that change :-)

* unrelated mini refactor cleanup

* let painSelection handle size_t instead of int

* Add some more comments to the MessageLayoutContext structs

---------

Co-authored-by: Rasmus Karlsson <rasmus.karlsson@pajlada.com>
This commit is contained in:
nerix
2023-07-30 14:52:39 +02:00
committed by GitHub
parent 95aee044e2
commit 71594ad0d8
14 changed files with 312 additions and 131 deletions
+2
View File
@@ -209,6 +209,8 @@ set(SOURCE_FILES
messages/layouts/MessageLayout.hpp
messages/layouts/MessageLayoutContainer.cpp
messages/layouts/MessageLayoutContainer.hpp
messages/layouts/MessageLayoutContext.cpp
messages/layouts/MessageLayoutContext.hpp
messages/layouts/MessageLayoutElement.cpp
messages/layouts/MessageLayoutElement.hpp
messages/search/AuthorPredicate.cpp