From a80d2785c5a5a4017d02af430a0cfd910421cd05 Mon Sep 17 00:00:00 2001 From: Guillaume Burel Date: Mon, 30 Jul 2012 13:41:08 +0200 Subject: [PATCH] Item drop on board fixed. Item is now selected. --- src/domain/UBGraphicsWebView.cpp | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/src/domain/UBGraphicsWebView.cpp b/src/domain/UBGraphicsWebView.cpp index 0071882e..ecd9788f 100644 --- a/src/domain/UBGraphicsWebView.cpp +++ b/src/domain/UBGraphicsWebView.cpp @@ -48,29 +48,17 @@ UBGraphicsWebView::~UBGraphicsWebView() QVariant UBGraphicsWebView::itemChange(GraphicsItemChange change, const QVariant &value) { - /*if (change == QGraphicsItem::ItemCursorHasChanged && scene()) - { - unsetCursor(); - } - if ((change == QGraphicsItem::ItemSelectedHasChanged) - && scene()) - { + if ((change == QGraphicsItem::ItemSelectedHasChanged) && scene()) { if (isSelected()) - { scene()->setActiveWindow(this); - } - else - { + else { if(scene()->activeWindow() == this) - { scene()->setActiveWindow(0); - } } - }*/ + } QVariant newValue = mDelegate->itemChange(change, value); return QGraphicsWebView::itemChange(change, newValue); - //return QGraphicsWebView::itemChange(change, value); } void UBGraphicsWebView::setUuid(const QUuid &pUuid)