QmlDesigner: remove delayed drag and drop call

Change-Id: I6d2c1c2f25ba88f3c6f0af9b52968a9bd005cd85
Reviewed-by: Marco Bubke <marco.bubke@digia.com>
This commit is contained in:
Tim Jenssen
2014-06-30 13:32:13 +02:00
parent 6bb5903c13
commit b013637f22
3 changed files with 3 additions and 8 deletions

View File

@@ -78,7 +78,7 @@ Rectangle {
property int pressedY
onPressed: {
rootView.startDragAndDropDelayed(itemLibraryEntry)
rootView.startDragAndDrop(itemLibraryEntry)
}
}
}

View File

@@ -369,14 +369,10 @@ void ItemLibraryWidget::setResourcePath(const QString &resourcePath)
updateSearch();
}
void ItemLibraryWidget::startDragAndDropDelayed(QVariant itemLibraryId)
void ItemLibraryWidget::startDragAndDrop(QVariant itemLibraryId)
{
m_currentitemLibraryEntry = itemLibraryId.value<ItemLibraryEntry>();
QTimer::singleShot(0, this, SLOT(startDragAndDrop()));
}
void ItemLibraryWidget::startDragAndDrop()
{
QMimeData *mimeData = m_itemLibraryModel->getMimeData(m_currentitemLibraryEntry);
QDrag *drag = new QDrag(this);

View File

@@ -96,8 +96,7 @@ public slots:
void setResourcePath(const QString &resourcePath);
void startDragAndDropDelayed(QVariant itemLibId);
void startDragAndDrop();
void startDragAndDrop(QVariant itemLibId);
void setModel(Model *model);