Clean wheelEvent in diagramview and add the same system to element Editor

git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@2115 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
cfdev
2013-04-16 12:00:41 +00:00
parent e7ac7c9c40
commit 5dc829569e
3 changed files with 49 additions and 23 deletions

View File

@@ -293,7 +293,7 @@ void DiagramView::handleTitleBlockDrop(QDropEvent *e) {
}
/**
Passe le Diagram en mode visualisation
Set the Diagram in visualisation mode
*/
void DiagramView::setVisualisationMode() {
setDragMode(ScrollHandDrag);
@@ -303,7 +303,7 @@ void DiagramView::setVisualisationMode() {
}
/**
Passe le Diagram en mode Selection
Set the Diagram in Selection mode
*/
void DiagramView::setSelectionMode() {
setDragMode(RubberBandDrag);
@@ -457,17 +457,6 @@ void DiagramView::wheelEvent(QWheelEvent *e) {
QAbstractScrollArea::wheelEvent(e);
}
}
// Or select visualisation or selection mode
else{
if (!is_moving_view_) {
setVisualisationMode();
is_moving_view_ = true;
}
else{
setSelectionMode();
is_moving_view_ = false;
}
}
}
/**