• Skip to content
  • Skip to link menu
KDE 4.4 API Reference
  • KDE API Reference
  • API Reference
  • Sitemap
  • Contact Us
 

digikam

Digikam::AlbumFilterModel

Digikam::AlbumFilterModel Class Reference

#include <albumfiltermodel.h>

Inheritance diagram for Digikam::AlbumFilterModel:
Inheritance graph
[legend]

List of all members.

Public Types

enum  MatchResult {
  NoMatch = 0, TitleMatch, ParentMatch, ChildMatch,
  SpecialMatch
}

Public Slots

void setSearchTextSettings (const SearchTextSettings &settings)

Signals

void filterChanged ()

Public Member Functions

 AlbumFilterModel (QObject *parent=0)
Album * albumForIndex (const QModelIndex &index) const
QModelIndex indexForAlbum (Album *album) const
bool isFiltering () const
MatchResult matches (const QModelIndex &index) const
MatchResult matches (Album *album) const
QModelIndex rootAlbumIndex () const
SearchTextSettings searchTextSettings () const
void setSourceAlbumModel (AbstractAlbumModel *source)
AbstractAlbumModel * sourceAlbumModel () const

Protected Member Functions

bool filterAcceptsRow (int source_row, const QModelIndex &source_parent) const
bool lessThan (const QModelIndex &left, const QModelIndex &right) const
virtual void setSourceModel (QAbstractItemModel *model)

Protected Attributes

SearchTextSettings m_settings

Detailed Description

Definition at line 39 of file albumfiltermodel.h.


Member Enumeration Documentation

enum Digikam::AlbumFilterModel::MatchResult

Returns if the filter matches this album (same logic as filterAcceptsRow).

An album matches if the search text settings are found in a parent album's title, in the album's title or in a child album's title, or if it is a special album (root) that is never filtered out.

Enumerator:
NoMatch 

Can use as bool value if match/no match only is needed.

TitleMatch 
ParentMatch 
ChildMatch 
SpecialMatch 

Definition at line 63 of file albumfiltermodel.h.


Constructor & Destructor Documentation

Digikam::AlbumFilterModel::AlbumFilterModel ( QObject *  parent = 0  ) 

Definition at line 41 of file albumfiltermodel.cpp.


Member Function Documentation

Album * Digikam::AlbumFilterModel::albumForIndex ( const QModelIndex &  index  )  const

Definition at line 80 of file albumfiltermodel.cpp.

bool Digikam::AlbumFilterModel::filterAcceptsRow ( int  source_row,
const QModelIndex &  source_parent 
) const [protected]

Definition at line 137 of file albumfiltermodel.cpp.

void Digikam::AlbumFilterModel::filterChanged (  )  [signal]
QModelIndex Digikam::AlbumFilterModel::indexForAlbum ( Album *  album  )  const

Definition at line 85 of file albumfiltermodel.cpp.

bool Digikam::AlbumFilterModel::isFiltering (  )  const

Returns if the set search text settings will result in any filtering.

Definition at line 54 of file albumfiltermodel.cpp.

bool Digikam::AlbumFilterModel::lessThan ( const QModelIndex &  left,
const QModelIndex &  right 
) const [protected]

Definition at line 147 of file albumfiltermodel.cpp.

AlbumFilterModel::MatchResult Digikam::AlbumFilterModel::matches ( const QModelIndex &  index  )  const

Definition at line 95 of file albumfiltermodel.cpp.

AlbumFilterModel::MatchResult Digikam::AlbumFilterModel::matches ( Album *  album  )  const

Definition at line 100 of file albumfiltermodel.cpp.

QModelIndex Digikam::AlbumFilterModel::rootAlbumIndex (  )  const

Definition at line 90 of file albumfiltermodel.cpp.

SearchTextSettings Digikam::AlbumFilterModel::searchTextSettings (  )  const

Definition at line 59 of file albumfiltermodel.cpp.

void Digikam::AlbumFilterModel::setSearchTextSettings ( const SearchTextSettings &  settings  )  [slot]

Definition at line 47 of file albumfiltermodel.cpp.

void Digikam::AlbumFilterModel::setSourceAlbumModel ( AbstractAlbumModel *  source  ) 

Definition at line 64 of file albumfiltermodel.cpp.

void Digikam::AlbumFilterModel::setSourceModel ( QAbstractItemModel *  model  )  [protected, virtual]

Definition at line 69 of file albumfiltermodel.cpp.

AbstractAlbumModel * Digikam::AlbumFilterModel::sourceAlbumModel (  )  const

Definition at line 75 of file albumfiltermodel.cpp.


Member Data Documentation

SearchTextSettings Digikam::AlbumFilterModel::m_settings [protected]

Definition at line 93 of file albumfiltermodel.h.


The documentation for this class was generated from the following files:
  • albumfiltermodel.h
  • albumfiltermodel.cpp

digikam

Skip menu "digikam"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members

API Reference

Skip menu "API Reference"
  • digikam
Generated for API Reference by doxygen 1.5.9-20090814
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal