|
libfuoten 0.8.2
Qt based library to access the Nextcloud News App API.
|
Proxy filter model for FeedListModel. More...
#include <Fuoten/Models/FeedListFilterModel>
Properties | |
| bool | respectPinned |
| Set this to true, to respect the pinned status in sorting. | |
| bool | sortByFolder |
| Set to true to sort the feeds by the name of their folder. | |
| Properties inherited from Fuoten::BaseFilterModel | |
| double | doubleParentId |
| Stores the parent ID as double to make it accesseable from QML. | |
| bool | hideRead |
When true, items with no unread items will be hidden. | |
| bool | inOperation |
| Returns true while the underlying BaseModel is initially loading data. | |
| bool | loaded |
This property holds true after the source model has initially loaded its data. | |
| qint64 | parentId |
| Sets the parentId property of the underlying BaseModel. | |
| QString | search |
| Search string to filter the model for. | |
| Fuoten::FuotenEnums::SortingRole | sortingRole |
| The property the model items should be sorted by. | |
| Qt::SortOrder | sortOrder |
| Defines the sort order. | |
| Fuoten::AbstractStorage * | storage |
| Pointer to the AbstractStorage object of the underlying BaseModel. | |
Public Member Functions | |
| FeedListFilterModel (QObject *parent=nullptr) | |
| Constructs a new feed list filter model with the given parent. | |
| ~FeedListFilterModel () override | |
| Deconstructs the FeedListFilterModel object. | |
| bool | inOperation () const override |
| Returns true while the underlying FeedListModel is loading. | |
| Q_INVOKABLE void | load (const QString &locale=QString()) override |
| Loads the data in the underlying FeedListModel. | |
| bool | loaded () const override |
Returns true if the source model has initially loaded its data. | |
| qint64 | parentId () const override |
| Returns the parent ID that is currently set in the underlying FeedListModel. | |
| Q_INVOKABLE void | reload (const QString &locale=QString()) override |
| Reloads the complete underlying FeedListModel. | |
| bool | respectPinned () const |
| Returns true if the pinned status should be respected on sorting. | |
| void | setParentId (qint64 nParentId) override |
| Sets the parent ID in the underlying FeedListModel. | |
| void | setRespectPinned (bool nRespectPinned) |
| Set this to true if the pinned status should be respected on sorting. | |
| void | setSortByFolder (bool nSortByFolder) |
| Set this to true to sort the feeds by their folder. | |
| void | setStorage (AbstractStorage *nStorage) override |
| Sets the pointer to a local storage object in the underlying FeedListModel. | |
| bool | sortByFolder () const |
| Returns true if the feeds should be sorted by their folder. | |
| AbstractStorage * | storage () const override |
| Returns the pointer to the local storage handler set in the underlying FeedListModel. | |
| Public Member Functions inherited from Fuoten::BaseFilterModel | |
| BaseFilterModel (QObject *parent=nullptr) | |
| Constructs a new base filter model with the given parent. | |
| ~BaseFilterModel () override | |
| Deconstructs the BaseFilterModel object. | |
| double | doubleParentId () const |
| Getter function for the doubleParentId property. | |
| bool | hideRead () const |
| Returns true if model items with no unread items or unread articles should be hidden. | |
| QString | search () const |
| Returns the currently set serach string. | |
| void | setDoubleParentId (double nDoubleParentId) |
| Setter function for the doubleParentId property. | |
| void | setHideRead (bool nHideRead) |
| Set this to true to hide items with no unread content or read articles. | |
| void | setSearch (const QString &nSearch) |
| Sets the search string. | |
| virtual void | setSortingRole (FuotenEnums::SortingRole nSortingRole) |
| Sets the sorting role. | |
| virtual void | setSortOrder (Qt::SortOrder nSortOrder) |
| Sets the sort order. | |
| virtual FuotenEnums::SortingRole | sortingRole () const |
| Returns the currently set sorting role. | |
| virtual Qt::SortOrder | sortOrder () const |
| Returns the currently set sort order. | |
Signals | |
| void | respectPinnedChanged (bool respectPinned) |
| This is emitted if the FeedListFilterModel::respectPinned property changes. | |
| void | sortByFolderChanged (bool sortByFolder) |
| This is emitted if the sortByFolder property changes. | |
| Signals inherited from Fuoten::BaseFilterModel | |
| void | doubleParentIdChanged (double doubleParentId) |
| This signal is emitted if the doubleParentId property changes. | |
| void | hideReadChanged (bool hideRead) |
| This signal is emitted if the hideRead property changes. | |
| void | inOperationChanged (bool inOperation) |
| This signal is emitted when the operational state of the underlying model changes. | |
| void | loadedChanged (bool loaded) |
| This signal is emitted if the loaded property changes. | |
| void | parentIdChanged (qint64 parentId) |
| This signal is emitted when the parent ID property changed in the underlying model. | |
| void | searchChanged (const QString &search) |
| This signal is emitted if the search string changes. | |
| void | sortingRoleChanged (FuotenEnums::SortingRole sortingRole) |
| This signal is emitted if the sorting role changes. | |
| void | sortOrderChanged (Qt::SortOrder sortOrder) |
| This signal is emitted if the sort order changes. | |
| void | storageChanged (Fuoten::AbstractStorage *storage) |
| This signal is emitted when the pointer to the local storage handler changes in the underlying model. | |
Additional Inherited Members | |
| Protected Member Functions inherited from Fuoten::BaseFilterModel | |
| bool | find (const QString &str) const |
Returns true if the string set by setSearch() is part of str. | |
Proxy filter model for FeedListModel.
This proxy model filters and sorts the data of a FeedListModel that is internally created.
|
readwrite |
Set this to true, to respect the pinned status in sorting.
| bool | respectPinned() const |
| void | setRespectPinned(bool nRespectPinned) |
| void | respectPinnedChanged(bool respectPinned) |
|
readwrite |
Set to true to sort the feeds by the name of their folder.
| bool | sortByFolder() const |
| void | setSortByFolder(bool nSortByFolder) |
| void | sortByFolderChanged(bool sortByFolder) |
|
explicit |
Constructs a new feed list filter model with the given parent.
|
override |
Deconstructs the FeedListFilterModel object.
|
overridevirtual |
Returns true while the underlying FeedListModel is loading.
Implements Fuoten::BaseFilterModel.
Loads the data in the underlying FeedListModel.
Implements Fuoten::BaseFilterModel.
|
overridevirtual |
Returns true if the source model has initially loaded its data.
Implements Fuoten::BaseFilterModel.
|
overridevirtual |
Returns the parent ID that is currently set in the underlying FeedListModel.
Implements Fuoten::BaseFilterModel.
Reloads the complete underlying FeedListModel.
Implements Fuoten::BaseFilterModel.
| bool FeedListFilterModel::respectPinned | ( | ) | const |
Returns true if the pinned status should be respected on sorting.
|
signal |
This is emitted if the FeedListFilterModel::respectPinned property changes.
|
overridevirtual |
Sets the parent ID in the underlying FeedListModel.
| nParentId | ID of the parent folder, -1 (default) to show all feeds |
Implements Fuoten::BaseFilterModel.
| void FeedListFilterModel::setRespectPinned | ( | bool | nRespectPinned | ) |
Set this to true if the pinned status should be respected on sorting.
| void FeedListFilterModel::setSortByFolder | ( | bool | nSortByFolder | ) |
Set this to true to sort the feeds by their folder.
|
overridevirtual |
Sets the pointer to a local storage object in the underlying FeedListModel.
| nStorage | reimplemented local storage |
Implements Fuoten::BaseFilterModel.
| bool FeedListFilterModel::sortByFolder | ( | ) | const |
Returns true if the feeds should be sorted by their folder.
|
signal |
This is emitted if the sortByFolder property changes.
|
overridevirtual |
Returns the pointer to the local storage handler set in the underlying FeedListModel.
Implements Fuoten::BaseFilterModel.