LeechCraft  0.6.70-13729-g7046a9d2a7
Modular cross-platform feature rich live environment.
LC::Util::FlatToFoldersProxyModel Class Reference

#include "flattofoldersproxymodel.h"

+ Inheritance diagram for LC::Util::FlatToFoldersProxyModel:
+ Collaboration diagram for LC::Util::FlatToFoldersProxyModel:

Public Member Functions

 FlatToFoldersProxyModel (const ITagsManager *, QObject *=nullptr)
 
int columnCount (const QModelIndex &={}) const override
 
QVariant data (const QModelIndex &, int=Qt::DisplayRole) const override
 
QVariant headerData (int, Qt::Orientation, int) const override
 
Qt::ItemFlags flags (const QModelIndex &) const override
 
QModelIndex index (int, int, const QModelIndex &={}) const override
 
QModelIndex parent (const QModelIndex &) const override
 
int rowCount (const QModelIndex &={}) const override
 
Qt::DropActions supportedDropActions () const override
 
QStringList mimeTypes () const override
 
QMimeData * mimeData (const QModelIndexList &indexes) const override
 
bool dropMimeData (const QMimeData *data, Qt::DropAction action, int row, int column, const QModelIndex &parent) override
 
void SetSourceModel (QAbstractItemModel *)
 
QAbstractItemModel * GetSourceModel () const
 
QModelIndex MapToSource (const QModelIndex &) const
 
QList< QModelIndex > MapFromSource (const QModelIndex &) const
 

Detailed Description

Definition at line 47 of file flattofoldersproxymodel.h.

Constructor & Destructor Documentation

◆ FlatToFoldersProxyModel()

LC::Util::FlatToFoldersProxyModel::FlatToFoldersProxyModel ( const ITagsManager itm,
QObject *  parent = nullptr 
)
explicit

Definition at line 78 of file flattofoldersproxymodel.cpp.

References parent().

+ Here is the call graph for this function:

Member Function Documentation

◆ columnCount()

int LC::Util::FlatToFoldersProxyModel::columnCount ( const QModelIndex &  = {}) const
override

Definition at line 86 of file flattofoldersproxymodel.cpp.

◆ data()

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

Definition at line 93 of file flattofoldersproxymodel.cpp.

References LC::FlatTreeItem::Folder, ITagsManager::GetTag(), index(), LC::FlatTreeItem::Index_, LC::FlatTreeItem::Item, LC::RoleTags, LC::FlatTreeItem::Tag_, LC::ToFlat(), and LC::FlatTreeItem::Type_.

Referenced by dropMimeData().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ dropMimeData()

bool LC::Util::FlatToFoldersProxyModel::dropMimeData ( const QMimeData *  data,
Qt::DropAction  action,
int  row,
int  column,
const QModelIndex &  parent 
)
override

Definition at line 229 of file flattofoldersproxymodel.cpp.

References data(), LC::FlatTreeItem::Folder, LC::FlatTreeItem::Item, and parent().

+ Here is the call graph for this function:

◆ flags()

Qt::ItemFlags LC::Util::FlatToFoldersProxyModel::flags ( const QModelIndex &  index) const
override

Definition at line 133 of file flattofoldersproxymodel.cpp.

References index(), LC::FlatTreeItem::Item, and LC::ToFlat().

+ Here is the call graph for this function:

◆ GetSourceModel()

QAbstractItemModel * LC::Util::FlatToFoldersProxyModel::GetSourceModel ( ) const

Definition at line 305 of file flattofoldersproxymodel.cpp.

Referenced by MapFromSource(), and MapToSource().

+ Here is the caller graph for this function:

◆ headerData()

QVariant LC::Util::FlatToFoldersProxyModel::headerData ( int  section,
Qt::Orientation  orient,
int  role 
) const
override

Definition at line 124 of file flattofoldersproxymodel.cpp.

◆ index()

QModelIndex LC::Util::FlatToFoldersProxyModel::index ( int  row,
int  column,
const QModelIndex &  parent = {} 
) const
override

Definition at line 145 of file flattofoldersproxymodel.cpp.

References LC::FlatTreeItem::C_, LC::FlatTreeItem::Item, parent(), LC::ToFlat(), and LC::FlatTreeItem::Type_.

Referenced by data(), flags(), MapFromSource(), mimeData(), parent(), and rowCount().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ MapFromSource()

QList< QModelIndex > LC::Util::FlatToFoldersProxyModel::MapFromSource ( const QModelIndex &  source) const

Definition at line 326 of file flattofoldersproxymodel.cpp.

References GetSourceModel(), index(), and LC::RoleTags.

+ Here is the call graph for this function:

◆ MapToSource()

QModelIndex LC::Util::FlatToFoldersProxyModel::MapToSource ( const QModelIndex &  proxy) const

Definition at line 310 of file flattofoldersproxymodel.cpp.

References GetSourceModel(), LC::FlatTreeItem::Item, and LC::ToFlat().

Referenced by mimeData().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ mimeData()

QMimeData * LC::Util::FlatToFoldersProxyModel::mimeData ( const QModelIndexList &  indexes) const
override

Definition at line 203 of file flattofoldersproxymodel.cpp.

References LC::FlatTreeItem::Folder, index(), LC::FlatTreeItem::Item, and MapToSource().

+ Here is the call graph for this function:

◆ mimeTypes()

QStringList LC::Util::FlatToFoldersProxyModel::mimeTypes ( ) const
override

Definition at line 196 of file flattofoldersproxymodel.cpp.

◆ parent()

QModelIndex LC::Util::FlatToFoldersProxyModel::parent ( const QModelIndex &  index) const
override

Definition at line 163 of file flattofoldersproxymodel.cpp.

References index(), LC::FlatTreeItem::Parent_, LC::FlatTreeItem::Root, and LC::ToFlat().

Referenced by dropMimeData(), FlatToFoldersProxyModel(), and index().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ rowCount()

int LC::Util::FlatToFoldersProxyModel::rowCount ( const QModelIndex &  index = {}) const
override

Definition at line 181 of file flattofoldersproxymodel.cpp.

References LC::FlatTreeItem::C_, index(), and LC::ToFlat().

+ Here is the call graph for this function:

◆ SetSourceModel()

void LC::Util::FlatToFoldersProxyModel::SetSourceModel ( QAbstractItemModel *  model)

Definition at line 254 of file flattofoldersproxymodel.cpp.

◆ supportedDropActions()

Qt::DropActions LC::Util::FlatToFoldersProxyModel::supportedDropActions ( ) const
override

Definition at line 189 of file flattofoldersproxymodel.cpp.


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