Don't try to make an icon with a data: URI - Icon can't handle them.

BUG: 164120


svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=844088
This commit is contained in:
Alex Merry 2008-08-08 17:14:35 +00:00
parent a3fe56c7b1
commit ba285be2ff

View File

@ -800,10 +800,7 @@ void Containment::dropEvent(QGraphicsSceneDragDropEvent *event)
// kDebug() << mimeName;
KPluginInfo::List appletList = Applet::listAppletInfoForMimetype(mimeName);
if (appletList.isEmpty()) {
// no special applet associated with this mimetype, let's
addApplet("icon", args, geom);
} else {
if (!appletList.isEmpty()) {
//TODO: should we show a dialog here to choose which plasmoid load if
//!appletList.isEmpty()
QMenu choices;
@ -824,6 +821,10 @@ void Containment::dropEvent(QGraphicsSceneDragDropEvent *event)
if (choice) {
addApplet(actionsToPlugins[choice], args, geom);
}
} else if (url.protocol() != "data") {
// We don't try to do anything with data: URIs
// no special applet associated with this mimetype, let's
addApplet("icon", args, geom);
}
}
event->acceptProposedAction();