digiKam
Digikam::TagDragDropHandler Class Reference
+ Inheritance diagram for Digikam::TagDragDropHandler:

Signals

void assignTags (const QList< qlonglong > &imageIDs, const QList< int > &tagIDs)
 

Public Member Functions

Qt::DropAction accepts (const QDropEvent *e, const QModelIndex &dropIndex) override
 
virtual bool acceptsMimeData (const QMimeData *data)
 
QMimeData * createMimeData (const QList< Album * > &) override
 
bool dropEvent (QAbstractItemView *view, const QDropEvent *e, const QModelIndex &droppedOn) override
 
QStringList mimeTypes () const override
 
TagModelmodel () const
 
 TagDragDropHandler (TagModel *const model)
 

Protected Attributes

AbstractAlbumModelm_model
 

Constructor & Destructor Documentation

◆ TagDragDropHandler()

Digikam::TagDragDropHandler::TagDragDropHandler ( TagModel *const  model)
explicit

Member Function Documentation

◆ accepts()

Qt::DropAction Digikam::TagDragDropHandler::accepts ( const QDropEvent *  e,
const QModelIndex &  dropIndex 
)
overridevirtual

◆ acceptsMimeData()

bool Digikam::AlbumModelDragDropHandler::acceptsMimeData ( const QMimeData *  data)
virtualinherited

Returns if the given mime data can be handled. acceptsMimeData shall return true if a drop of the given mime data will be accepted on any index or place at all. If this returns false, the more specific method accepts() will not be called for this drag. The default implementation uses mimeTypes() to check for supported mime types. There is usually no need to reimplement this.

References Digikam::AlbumModelDragDropHandler::mimeTypes().

Referenced by Digikam::AbstractAlbumTreeView::dragEnterEvent().

◆ assignTags

void Digikam::TagDragDropHandler::assignTags ( const QList< qlonglong > &  imageIDs,
const QList< int > &  tagIDs 
)
signal

Referenced by dropEvent().

◆ createMimeData()

QMimeData * Digikam::TagDragDropHandler::createMimeData ( const QList< Album * > &  )
overridevirtual

Create a mime data object for starting a drag from the given Albums

Reimplemented from Digikam::AlbumModelDragDropHandler.

References Digikam::Album::id().

◆ dropEvent()

◆ mimeTypes()

QStringList Digikam::TagDragDropHandler::mimeTypes ( ) const
overridevirtual

Returns the supported mime types. Called by the default implementation of model's mimeTypes().

Reimplemented from Digikam::AlbumModelDragDropHandler.

References Digikam::DItemDrag::mimeTypes(), and Digikam::DTagListDrag::mimeTypes().

◆ model()

TagModel * Digikam::TagDragDropHandler::model ( ) const

Member Data Documentation

◆ m_model

AbstractAlbumModel* Digikam::AlbumModelDragDropHandler::m_model
protectedinherited

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