summaryrefslogtreecommitdiffstats
path: root/src/gui/text/qtextcontrol.cpp
diff options
context:
space:
mode:
authorBea Lam <bea.lam@nokia.com>2009-10-21 00:43:19 (GMT)
committerBea Lam <bea.lam@nokia.com>2009-10-21 00:43:19 (GMT)
commitf6b1582d726f97d8be4b30f0f6da2350220f27c5 (patch)
tree64bcea1b8b3cc8f94073a9e83b36b2b40ad990e8 /src/gui/text/qtextcontrol.cpp
parent110c58a20f3158143d83ebea4f2ece4f7925f913 (diff)
parent7bd7f5ec6eb520b7d9940a24817b17132d9ed6a2 (diff)
downloadQt-f6b1582d726f97d8be4b30f0f6da2350220f27c5.zip
Qt-f6b1582d726f97d8be4b30f0f6da2350220f27c5.tar.gz
Qt-f6b1582d726f97d8be4b30f0f6da2350220f27c5.tar.bz2
Merge branch 'kinetic-declarativeui' of git@scm.dev.nokia.troll.no:qt/kinetic into kinetic-declarativeui
Diffstat (limited to 'src/gui/text/qtextcontrol.cpp')
-rw-r--r--src/gui/text/qtextcontrol.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/gui/text/qtextcontrol.cpp b/src/gui/text/qtextcontrol.cpp
index db4c07c..ee8b751 100644
--- a/src/gui/text/qtextcontrol.cpp
+++ b/src/gui/text/qtextcontrol.cpp
@@ -505,9 +505,13 @@ void QTextControlPrivate::startDrag()
drag->setMimeData(data);
Qt::DropActions actions = Qt::CopyAction;
- if (interactionFlags & Qt::TextEditable)
+ Qt::DropAction action;
+ if (interactionFlags & Qt::TextEditable) {
actions |= Qt::MoveAction;
- Qt::DropAction action = drag->exec(actions, Qt::MoveAction);
+ action = drag->exec(actions, Qt::MoveAction);
+ } else {
+ action = drag->exec(actions, Qt::CopyAction);
+ }
if (action == Qt::MoveAction && drag->target() != contextWidget)
cursor.removeSelectedText();