[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdepimlibs/akonadi
From: Volker Krause <vkrause () kde ! org>
Date: 2010-12-20 17:56:15
Message-ID: 20101220175615.785E6AC8AA () svn ! kde ! org
[Download RAW message or body]
SVN commit 1208114 by vkrause:
Very ugly hack to bypass the normal drag&drop manager when using the
favorites model. This finally makes dropping on the favorite view work.
M +3 -2 entitylistview.cpp
--- trunk/KDE/kdepimlibs/akonadi/entitylistview.cpp #1208113:1208114
@@ -22,6 +22,7 @@
#include "entitylistview.h"
#include "dragdropmanager_p.h"
+#include "favoritecollectionsmodel.h"
#include <QtCore/QDebug>
#include <QtCore/QTimer>
@@ -171,7 +172,7 @@
void EntityListView::dragMoveEvent( QDragMoveEvent * event )
{
- if ( d->mDragDropManager->dropAllowed( event ) ) {
+ if ( d->mDragDropManager->dropAllowed( event ) || \
qobject_cast<Akonadi::FavoriteCollectionsModel*>( model() ) ) { // All urls are \
supported. process the event. QListView::dragMoveEvent( event );
return;
@@ -182,7 +183,7 @@
void EntityListView::dropEvent( QDropEvent * event )
{
- if ( d->mDragDropManager->processDropEvent( event ) ) {
+ if ( qobject_cast<Akonadi::FavoriteCollectionsModel*>( model() ) || \
d->mDragDropManager->processDropEvent( event ) ) { QListView::dropEvent( event );
}
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic