Get PaginateModel class ready for frameworks
ClosedPublic

Authored by apol on May 22 2019, 11:42 AM.

Details

Summary

Some API documentation of the properties
Added a d-pointer
Coding style

Diff Detail

Repository
R134 Discover Software Store
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
apol created this revision.May 22 2019, 11:42 AM
Restricted Application added a project: Plasma. · View Herald TranscriptMay 22 2019, 11:42 AM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
apol requested review of this revision.May 22 2019, 11:42 AM
apol updated this revision to Diff 58465.May 22 2019, 11:47 AM

More documentation

davidedmundson accepted this revision.May 22 2019, 11:48 AM
davidedmundson added a subscriber: davidedmundson.

nice 🐿

This revision is now accepted and ready to land.May 22 2019, 11:48 AM
This revision was automatically updated to reflect the committed changes.
hein added a subscriber: hein.EditedMay 23 2019, 6:26 AM

I wouldn't call this implementation ready for frameworks, though - it just resets all the time, which is very slow as it forces views to destroy and recreate delegates instead of just updating them. A better implementation would just (re)filter source rows corresponding to the current page. This could be done as a subclass of QSortFilterProxyModel or custom; KItemModels' KRearrangeColumnsProxyModel can serve as inspiration to some degree. As it stands I wouldn't actually use this if it was in the framework.