summaryrefslogtreecommitdiffstats
path: root/kicker/taskbar/taskbarcontainer.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-04-13 15:00:04 -0500
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-04-13 15:00:04 -0500
commit3df12cd87674fdfbc2afa21584e1f3e558fa873b (patch)
tree43a2c84807185d598b3ed3b74b13c58e94aa7b81 /kicker/taskbar/taskbarcontainer.cpp
parenta733ce41cb3edc37426e00708e49fb59eea6acd8 (diff)
downloadtdebase-3df12cd87674fdfbc2afa21584e1f3e558fa873b.tar.gz
tdebase-3df12cd87674fdfbc2afa21584e1f3e558fa873b.zip
Add menu items to rearrange taskbar entries
Make taskbar drag and drop moving more robust This resolves Bug 1103
Diffstat (limited to 'kicker/taskbar/taskbarcontainer.cpp')
-rw-r--r--kicker/taskbar/taskbarcontainer.cpp14
1 files changed, 5 insertions, 9 deletions
diff --git a/kicker/taskbar/taskbarcontainer.cpp b/kicker/taskbar/taskbarcontainer.cpp
index 030a565dc..fa105de15 100644
--- a/kicker/taskbar/taskbarcontainer.cpp
+++ b/kicker/taskbar/taskbarcontainer.cpp
@@ -338,11 +338,9 @@ void TaskBarContainer::dragEnterEvent( TQDragEnterEvent* e )
return;
}
- if (TaskDrag::canDecode(e) && READ_MERGED_TASBKAR_SETTING(allowDragAndDropReArrange))
+ if ((e->source()->parent() == taskBar->viewport()) && TaskDrag::canDecode(e) && READ_MERGED_TASBKAR_SETTING(allowDragAndDropReArrange) && (!READ_MERGED_TASBKAR_SETTING(sortByApp)))
{
- if (!READ_MERGED_TASBKAR_SETTING(sortByApp)) {
- e->accept();
- }
+ e->accept();
}
}
@@ -359,12 +357,10 @@ void TaskBarContainer::dropEvent( TQDropEvent* e )
return;
}
- if (TaskDrag::canDecode(e) && READ_MERGED_TASBKAR_SETTING(allowDragAndDropReArrange))
+ if ((e->source()->parent() == taskBar->viewport()) && TaskDrag::canDecode(e) && READ_MERGED_TASBKAR_SETTING(allowDragAndDropReArrange) && (!READ_MERGED_TASBKAR_SETTING(sortByApp)))
{
- if (!READ_MERGED_TASBKAR_SETTING(sortByApp)) {
- if (taskBar->taskMoveHandler(taskBar->mapFrom(this, e->pos()), TaskDrag::decode(e))) {
- e->accept();
- }
+ if (taskBar->taskMoveHandler(TaskMoveDestination::Position, TaskDrag::decode(e), taskBar->mapFrom(this, e->pos()))) {
+ e->accept();
}
}
} \ No newline at end of file