KViewStateMaintainer Class
template <typename StateSaver> class KViewStateMaintainerEncapsulates the maintenance of state between resets of QAbstractItemModel. More...
Header: | #include <KViewStateMaintainer> |
CMake: | find_package(KF6 REQUIRED COMPONENTS ConfigWidgets) target_link_libraries(mytarget PRIVATE KF6::ConfigWidgets) |
Inherits: | KViewStateMaintainerBase |
Public Functions
KViewStateMaintainer(const KConfigGroup &configGroup, QObject *parent = nullptr) |
Detailed Description
m_collectionViewStateMaintainer = new KViewStateMaintainer<Akonadi::ETMViewStateSaver>(KSharedConfig::openConfig()->group("collectionView")); m_collectionViewStateMaintainer->setView(m_collectionView); m_collectionCheckStateMaintainer = new KViewStateMaintainer<Akonadi::ETMViewStateSaver>(KSharedConfig::openConfig()->group("collectionCheckState")); m_collectionCheckStateMaintainer->setSelectionModel(m_checkableProxy->selectionModel());
See also KConfigViewStateSaver.