-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
opt: dictionarygroup refactor in articleview #1625
Conversation
src/ui/articleview.hh
Outdated
@@ -35,8 +36,7 @@ class ArticleView: public QWidget | |||
|
|||
ArticleNetworkAccessManager & articleNetMgr; | |||
AudioPlayerPtr const & audioPlayer; | |||
std::vector< sptr< Dictionary::Class > > const & allDictionaries; | |||
Instances::Groups const & groups; | |||
DictionaryGroup dictionaryGroup; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
std::unique_ptr / QScopedPointer
seems better than "QObject
with this
as parent" in here. They manage the lifetime equally, but the former don't have bloats.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
two different ways to the same goal.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For objects with no complex deleter, the cost of unique_ptr is zero.
ddc5ebb
to
96bd752
Compare
a4234f4
to
a3dd7ca
Compare
Quality Gate failedFailed conditions |
No description provided.