|
|
@ -27,6 +27,8 @@ |
|
|
|
|
|
|
|
|
|
|
|
#include <QDomDocument> |
|
|
|
#include <QDomDocument> |
|
|
|
#include <QWebView> |
|
|
|
#include <QWebView> |
|
|
|
|
|
|
|
#include <QWebFrame> |
|
|
|
|
|
|
|
#include <QWidget> |
|
|
|
|
|
|
|
|
|
|
|
#include "UBFeaturesWidget.h" |
|
|
|
#include "UBFeaturesWidget.h" |
|
|
|
#include "gui/UBThumbnailWidget.h" |
|
|
|
#include "gui/UBThumbnailWidget.h" |
|
|
@ -267,8 +269,8 @@ void UBFeaturesWidget::onDisplayMetadata( QMap<QString,QString> metadata ) |
|
|
|
{ |
|
|
|
{ |
|
|
|
QString previewImageUrl = ":images/libpalette/notFound.png"; |
|
|
|
QString previewImageUrl = ":images/libpalette/notFound.png"; |
|
|
|
|
|
|
|
|
|
|
|
QString widgetsUrl = QUrl::fromEncoded(metadata["Url"].toAscii()).toString()/*metadata.value("Url", QString())*/; |
|
|
|
QString widgetsUrl = QUrl::fromEncoded(metadata["Url"].toLatin1()).toString()/*metadata.value("Url", QString())*/; |
|
|
|
QString widgetsThumbsUrl = QUrl::fromEncoded(metadata["thumbnailUrl"].toAscii()).toString(); |
|
|
|
QString widgetsThumbsUrl = QUrl::fromEncoded(metadata["thumbnailUrl"].toLatin1()).toString(); |
|
|
|
|
|
|
|
|
|
|
|
QString strType = UBFileSystemUtils::mimeTypeFromFileName(widgetsUrl); |
|
|
|
QString strType = UBFileSystemUtils::mimeTypeFromFileName(widgetsUrl); |
|
|
|
UBMimeType::Enum thumbType = UBFileSystemUtils::mimeTypeFromString(strType); |
|
|
|
UBMimeType::Enum thumbType = UBFileSystemUtils::mimeTypeFromString(strType); |
|
|
@ -440,7 +442,7 @@ void UBFeaturesListView::dragMoveEvent( QDragMoveEvent *event ) |
|
|
|
|
|
|
|
|
|
|
|
void UBFeaturesListView::dropEvent( QDropEvent *event ) |
|
|
|
void UBFeaturesListView::dropEvent( QDropEvent *event ) |
|
|
|
{ |
|
|
|
{ |
|
|
|
QWidget *eventSource = event->source(); |
|
|
|
QObject *eventSource = event->source(); |
|
|
|
if (eventSource && eventSource->objectName() == UBFeaturesWidget::objNameFeatureList) { |
|
|
|
if (eventSource && eventSource->objectName() == UBFeaturesWidget::objNameFeatureList) { |
|
|
|
event->setDropAction( Qt::MoveAction ); |
|
|
|
event->setDropAction( Qt::MoveAction ); |
|
|
|
} |
|
|
|
} |
|
|
@ -1172,7 +1174,7 @@ QMimeData* UBFeaturesModel::mimeData(const QModelIndexList &indexes) const |
|
|
|
if (!typeData.isNull()) { |
|
|
|
if (!typeData.isNull()) { |
|
|
|
typeData += UBFeaturesController::featureTypeSplitter(); |
|
|
|
typeData += UBFeaturesController::featureTypeSplitter(); |
|
|
|
} |
|
|
|
} |
|
|
|
typeData += QString::number(element.getType()).toAscii(); |
|
|
|
typeData += QString::number(element.getType()).toLatin1(); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|