From 2d102026a718118a9161c289bab88e75575bff35 Mon Sep 17 00:00:00 2001 From: Aleksei Kanash Date: Thu, 2 Feb 2012 15:27:44 +0200 Subject: [PATCH] Fix for SANKORE-490 and SANKORE-491. --- src/desktop/UBDesktopAnnotationController.cpp | 2 +- src/gui/UBLibraryWidget.cpp | 5 +---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/desktop/UBDesktopAnnotationController.cpp b/src/desktop/UBDesktopAnnotationController.cpp index a2a4eac0..70983bab 100644 --- a/src/desktop/UBDesktopAnnotationController.cpp +++ b/src/desktop/UBDesktopAnnotationController.cpp @@ -81,7 +81,7 @@ UBDesktopAnnotationController::UBDesktopAnnotationController(QObject *parent) mTransparentDrawingView->setMouseTracking(true); - mTransparentDrawingView->setAcceptDrops(false); + mTransparentDrawingView->setAcceptDrops(true); QString backgroundStyle = "QWidget {background-color: rgba(127, 127, 127, 0)}"; mTransparentDrawingView->setStyleSheet(backgroundStyle); diff --git a/src/gui/UBLibraryWidget.cpp b/src/gui/UBLibraryWidget.cpp index 31371a83..568b0c4d 100644 --- a/src/gui/UBLibraryWidget.cpp +++ b/src/gui/UBLibraryWidget.cpp @@ -361,15 +361,12 @@ void UBLibraryWidget::dropEvent(QDropEvent *event) QString filePath; QString crntPath = urlList.at(i).toString(); -#ifdef Q_WS_MACX - filePath = QUrl(urlList.at(i)).toString(); -#else if(crntPath.startsWith("file:") || crntPath.startsWith("/")){ filePath = QUrl(crntPath).toLocalFile(); }else{ filePath = crntPath; } -#endif + mLibraryController->importItemOnLibrary(filePath); bDropAccepted = true; }