QGIS API Documentation 3.34.0-Prizren (ffbdd678812)
Loading...
Searching...
No Matches
Public Types | Public Slots | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
QgsCptCityBrowserModel Class Reference

#include <qgscptcityarchive.h>

Inheritance diagram for QgsCptCityBrowserModel:
Inheritance graph
[legend]

Public Types

enum  ViewType { Authors = 0 , Selections = 1 , List = 2 }
 

Public Slots

void beginInsertItems (QgsCptCityDataItem *parent, int first, int last)
 
void beginRemoveItems (QgsCptCityDataItem *parent, int first, int last)
 
void endInsertItems ()
 
void endRemoveItems ()
 

Public Member Functions

 QgsCptCityBrowserModel (QObject *parent=nullptr, QgsCptCityArchive *archive=QgsCptCityArchive::defaultArchive(), ViewType Type=Authors)
 
 ~QgsCptCityBrowserModel () override
 
bool canFetchMore (const QModelIndex &parent) const override
 
int columnCount (const QModelIndex &parent=QModelIndex()) const override
 
void connectItem (QgsCptCityDataItem *item)
 
QVariant data (const QModelIndex &index, int role=Qt::DisplayRole) const override
 
QgsCptCityDataItemdataItem (const QModelIndex &idx) const
 Returns a list of mime that can describe model indexes.
 
void fetchMore (const QModelIndex &parent) override
 
QModelIndex findItem (QgsCptCityDataItem *item, QgsCptCityDataItem *parent=nullptr) const
 
QModelIndex findPath (const QString &path)
 Returns index of a path.
 
Qt::ItemFlags flags (const QModelIndex &index) const override
 
bool hasChildren (const QModelIndex &parent=QModelIndex()) const override
 
QVariant headerData (int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const override
 
QModelIndex index (int row, int column, const QModelIndex &parent=QModelIndex()) const override
 
QModelIndex parent (const QModelIndex &index) const override
 
void refresh (const QModelIndex &index=QModelIndex())
 
void refresh (const QString &path)
 
void reload ()
 
int rowCount (const QModelIndex &parent=QModelIndex()) const override
 

Protected Member Functions

void addRootItems ()
 
void removeRootItems ()
 

Protected Attributes

QgsCptCityArchivemArchive = nullptr
 
QSize mIconSize
 
QVector< QgsCptCityDataItem * > mRootItems
 
ViewType mViewType
 

Detailed Description

Definition at line 322 of file qgscptcityarchive.h.

Member Enumeration Documentation

◆ ViewType

Enumerator
Authors 
Selections 
List 

Definition at line 328 of file qgscptcityarchive.h.

Constructor & Destructor Documentation

◆ QgsCptCityBrowserModel()

QgsCptCityBrowserModel::QgsCptCityBrowserModel ( QObject *  parent = nullptr,
QgsCptCityArchive archive = QgsCptCityArchive::defaultArchive(),
ViewType  Type = Authors 
)

Definition at line 1325 of file qgscptcityarchive.cpp.

◆ ~QgsCptCityBrowserModel()

QgsCptCityBrowserModel::~QgsCptCityBrowserModel ( )
override

Definition at line 1338 of file qgscptcityarchive.cpp.

Member Function Documentation

◆ addRootItems()

void QgsCptCityBrowserModel::addRootItems ( )
protected

Definition at line 1343 of file qgscptcityarchive.cpp.

◆ beginInsertItems

void QgsCptCityBrowserModel::beginInsertItems ( QgsCptCityDataItem parent,
int  first,
int  last 
)
slot

Definition at line 1632 of file qgscptcityarchive.cpp.

◆ beginRemoveItems

void QgsCptCityBrowserModel::beginRemoveItems ( QgsCptCityDataItem parent,
int  first,
int  last 
)
slot

Definition at line 1646 of file qgscptcityarchive.cpp.

◆ canFetchMore()

bool QgsCptCityBrowserModel::canFetchMore ( const QModelIndex &  parent) const
override

Definition at line 1666 of file qgscptcityarchive.cpp.

◆ columnCount()

int QgsCptCityBrowserModel::columnCount ( const QModelIndex &  parent = QModelIndex()) const
override

Definition at line 1461 of file qgscptcityarchive.cpp.

◆ connectItem()

void QgsCptCityBrowserModel::connectItem ( QgsCptCityDataItem item)

Definition at line 1658 of file qgscptcityarchive.cpp.

◆ data()

QVariant QgsCptCityBrowserModel::data ( const QModelIndex &  index,
int  role = Qt::DisplayRole 
) const
override

Definition at line 1371 of file qgscptcityarchive.cpp.

◆ dataItem()

QgsCptCityDataItem * QgsCptCityBrowserModel::dataItem ( const QModelIndex &  idx) const

Returns a list of mime that can describe model indexes.

Returns an object that contains serialized items of data corresponding to the list of indexes specified Handles the data supplied by a drag and drop operation that ended with the given action

Definition at line 1738 of file qgscptcityarchive.cpp.

◆ endInsertItems

void QgsCptCityBrowserModel::endInsertItems ( )
slot

Definition at line 1642 of file qgscptcityarchive.cpp.

◆ endRemoveItems

void QgsCptCityBrowserModel::endRemoveItems ( )
slot

Definition at line 1654 of file qgscptcityarchive.cpp.

◆ fetchMore()

void QgsCptCityBrowserModel::fetchMore ( const QModelIndex &  parent)
override

Definition at line 1684 of file qgscptcityarchive.cpp.

◆ findItem()

QModelIndex QgsCptCityBrowserModel::findItem ( QgsCptCityDataItem item,
QgsCptCityDataItem parent = nullptr 
) const

Definition at line 1604 of file qgscptcityarchive.cpp.

◆ findPath()

QModelIndex QgsCptCityBrowserModel::findPath ( const QString &  path)

Returns index of a path.

Definition at line 1467 of file qgscptcityarchive.cpp.

◆ flags()

Qt::ItemFlags QgsCptCityBrowserModel::flags ( const QModelIndex &  index) const
override

Definition at line 1361 of file qgscptcityarchive.cpp.

◆ hasChildren()

bool QgsCptCityBrowserModel::hasChildren ( const QModelIndex &  parent = QModelIndex()) const
override

Definition at line 1451 of file qgscptcityarchive.cpp.

◆ headerData()

QVariant QgsCptCityBrowserModel::headerData ( int  section,
Qt::Orientation  orientation,
int  role = Qt::DisplayRole 
) const
override

Definition at line 1421 of file qgscptcityarchive.cpp.

◆ index()

QModelIndex QgsCptCityBrowserModel::index ( int  row,
int  column,
const QModelIndex &  parent = QModelIndex() 
) const
override

Definition at line 1587 of file qgscptcityarchive.cpp.

◆ parent()

QModelIndex QgsCptCityBrowserModel::parent ( const QModelIndex &  index) const
override

Definition at line 1595 of file qgscptcityarchive.cpp.

◆ refresh() [1/2]

void QgsCptCityBrowserModel::refresh ( const QModelIndex &  index = QModelIndex())

Definition at line 1622 of file qgscptcityarchive.cpp.

◆ refresh() [2/2]

void QgsCptCityBrowserModel::refresh ( const QString &  path)

Definition at line 1576 of file qgscptcityarchive.cpp.

◆ reload()

void QgsCptCityBrowserModel::reload ( )

Definition at line 1567 of file qgscptcityarchive.cpp.

◆ removeRootItems()

void QgsCptCityBrowserModel::removeRootItems ( )
protected

Definition at line 1356 of file qgscptcityarchive.cpp.

◆ rowCount()

int QgsCptCityBrowserModel::rowCount ( const QModelIndex &  parent = QModelIndex()) const
override

Definition at line 1434 of file qgscptcityarchive.cpp.

Member Data Documentation

◆ mArchive

QgsCptCityArchive* QgsCptCityBrowserModel::mArchive = nullptr
protected

Definition at line 401 of file qgscptcityarchive.h.

◆ mIconSize

QSize QgsCptCityBrowserModel::mIconSize
protected

Definition at line 403 of file qgscptcityarchive.h.

◆ mRootItems

QVector<QgsCptCityDataItem *> QgsCptCityBrowserModel::mRootItems
protected

Definition at line 400 of file qgscptcityarchive.h.

◆ mViewType

ViewType QgsCptCityBrowserModel::mViewType
protected

Definition at line 402 of file qgscptcityarchive.h.


The documentation for this class was generated from the following files: