use krun instead of qprocess and make sure that we don't block our own process. you can see this happen in the second screencast, actually, and it's really lame ;)
svn path=/trunk/KDE/kdebase/workspace/lib/plasma/; revision=671108
This commit is contained in:
parent
452816cec8
commit
80fae8f7a3
@ -23,10 +23,10 @@
|
|||||||
#include <QDesktopWidget>
|
#include <QDesktopWidget>
|
||||||
#include <QGraphicsSceneDragDropEvent>
|
#include <QGraphicsSceneDragDropEvent>
|
||||||
#include <QMimeData>
|
#include <QMimeData>
|
||||||
#include <QProcess>
|
|
||||||
|
|
||||||
#include <KLocale>
|
#include <KLocale>
|
||||||
#include <KMenu>
|
#include <KMenu>
|
||||||
|
#include <KRun>
|
||||||
#include <KWindowSystem>
|
#include <KWindowSystem>
|
||||||
|
|
||||||
#include "applet.h"
|
#include "applet.h"
|
||||||
@ -255,6 +255,7 @@ void Corona::contextMenuEvent(QGraphicsSceneContextMenuEvent *contextMenuEvent)
|
|||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
contextMenuEvent->accept();
|
||||||
Applet* applet = qgraphicsitem_cast<Applet*>(itemAt(point));
|
Applet* applet = qgraphicsitem_cast<Applet*>(itemAt(point));
|
||||||
KMenu desktopMenu;
|
KMenu desktopMenu;
|
||||||
if(!applet) {
|
if(!applet) {
|
||||||
@ -280,12 +281,11 @@ void Corona::contextMenuEvent(QGraphicsSceneContextMenuEvent *contextMenuEvent)
|
|||||||
desktopMenu.addAction(closeApplet);
|
desktopMenu.addAction(closeApplet);
|
||||||
}
|
}
|
||||||
desktopMenu.exec(point.toPoint());
|
desktopMenu.exec(point.toPoint());
|
||||||
contextMenuEvent->accept();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Corona::launchExplorer()
|
void Corona::launchExplorer()
|
||||||
{
|
{
|
||||||
QProcess::execute("plasmaengineexplorer");
|
KRun::run("plasmaengineexplorer", KUrl::List(), 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Corona::appletDestroyed(QObject* object)
|
void Corona::appletDestroyed(QObject* object)
|
||||||
|
Loading…
Reference in New Issue
Block a user