28 #ifndef DIGIKAM_ITEM_FILTER_MODEL_H
29 #define DIGIKAM_ITEM_FILTER_MODEL_H
44 class ItemFilterModel;
45 class ImageTagChangeset;
53 virtual void prepare(
const QVector<ItemInfo>& infos) = 0;
70 void setSourceItemModel(
ItemModel*
const model);
76 QModelIndex mapToSourceItemModel(
const QModelIndex& index)
const;
77 QModelIndex mapFromSourceItemModel(
const QModelIndex& imagemodel_index)
const;
78 QModelIndex mapFromDirectSourceToSourceItemModel(
const QModelIndex& sourceModel_index)
const;
87 ItemInfo imageInfo(
const QModelIndex& index)
const;
88 qlonglong imageId(
const QModelIndex& index)
const;
92 QModelIndex indexForPath(
const QString& filePath)
const;
93 QModelIndex indexForItemInfo(
const ItemInfo& info)
const;
94 QModelIndex indexForImageId(qlonglong
id)
const;
112 virtual void setDirectSourceItemModel(
ItemModel*
const model);
115 void setSourceModel(QAbstractItemModel*
const model)
override;
183 bool isGroupOpen(qlonglong group)
const;
184 bool isAllGroupsOpen()
const;
189 void setSendItemInfoSignals(
bool sendSignals);
191 QVariant data(
const QModelIndex& index,
int role = Qt::DisplayRole)
const override;
219 void setMimeTypeFilter(
int mimeTypeFilter);
227 void setStringTypeNatural(
bool natural);
228 void setUrlWhitelist(
const QList<QUrl>& urlList,
const QString&
id);
234 void setGroupOpen(qlonglong group,
bool open);
235 void toggleGroupOpen(qlonglong group);
236 void setAllGroupsOpen(
bool open);
277 class ItemFilterModelPrivate;
281 ItemFilterModelPrivate*
const d_ptr;
287 void setDirectSourceItemModel(
ItemModel*
const model)
override;
289 bool filterAcceptsRow(
int source_row,
const QModelIndex& source_parent)
const override;
291 int compareCategories(
const QModelIndex& left,
const QModelIndex& right)
const override;
292 bool subSortLessThan(
const QModelIndex& left,
const QModelIndex& right)
const override;
301 virtual int compareInfosCategories(
const ItemInfo& left,
const ItemInfo& right)
const;
308 virtual int compareInfosCategories(
const ItemInfo& left,
const ItemInfo& right,
315 virtual bool infosLessThan(
const ItemInfo& left,
const ItemInfo& right)
const;
324 void slotModelReset();
325 void slotUpdateFilter();
330 void slotRowsInserted(
const QModelIndex& parent,
int start,
int end);
331 void slotRowsAboutToBeRemoved(
const QModelIndex& parent,
int start,
int end);
350 bool filterAcceptsRow(
int source_row,
const QModelIndex& source_parent)
const override;
Definition: dcategorizedsortfilterproxymodel.h:53
Definition: coredbfields.h:389
Definition: itemfiltersettings.h:313
Definition: coredbchangesets.h:48
Definition: itemfiltermodel.h:63
ImageSortFilterModel * m_chainedModel
Definition: itemfiltermodel.h:119
Definition: coredbchangesets.h:80
Definition: itemfiltermodel.h:49
virtual ~ItemFilterModelPrepareHook()
Definition: itemfiltermodel.h:52
virtual void prepare(const QVector< ItemInfo > &infos)=0
Definition: itemfiltermodel.h:125
ItemFilterModelPrivate *const d_ptr
Definition: itemfiltermodel.h:277
void filterMatches(bool matches)
void filterSettingsChanged(const ItemFilterSettings &settings)
ItemFilterModelRoles
Definition: itemfiltermodel.h:131
void filterMatchesForText(bool matchesByText)
void imageInfosAboutToBeRemoved(const QList< ItemInfo > &infos)
void imageInfosAdded(const QList< ItemInfo > &infos)
Definition: itemfiltersettings.h:98
GeolocationCondition
Possible logical matching condition used to sort geolocation.
Definition: itemfiltersettings.h:118
RatingCondition
Possible conditions used to filter rating: >=, =, <=.
Definition: itemfiltersettings.h:110
MatchingCondition
Possible logical matching condition used to sort tags id.
Definition: itemfiltersettings.h:103
Definition: iteminfo.h:78
Definition: itemmodel.h:53
@ FilterModelRoles
Definition: itemmodel.h:106
Definition: itemsortsettings.h:49
SortRole
Definition: itemsortsettings.h:70
CategorizationMode
Definition: itemsortsettings.h:60
SortOrder
Definition: itemsortsettings.h:53
Definition: itemfiltermodel.h:341
Definition: itemfiltersettings.h:61
Definition: itemfiltersettings.h:269
Definition: versionmanagersettings.h:43
Definition: datefolderview.cpp:43