Commit 3aacb79a authored by David Faure's avatar David Faure

Launch qdbusviewer with CommandLauncherJob. Tested, works.

parent 8e1961be
......@@ -4,7 +4,7 @@ set(PROJECT_VERSION_MAJOR 5)
cmake_minimum_required(VERSION 2.8.12 FATAL_ERROR)
set(QT_MIN_VERSION "5.14.0")
set(KF5_MIN_VERSION "5.66.0")
set(KF5_MIN_VERSION "5.70.0")
......
......@@ -18,8 +18,8 @@
#include "dbus_action_widget.h"
#include <KMessageBox>
#include <KRun>
#include <KDialogJobUiDelegate>
#include <KIO/CommandLauncherJob>
DbusActionWidget::DbusActionWidget(
KHotKeys::DBusAction *action,
......@@ -94,7 +94,7 @@ void DbusActionWidget::doCopyToObject()
void DbusActionWidget::execCommand() const
{
KHotKeys::DBusAction action(
0,
nullptr,
ui.application->text(),
ui.object->text(),
ui.function->text(),
......@@ -117,10 +117,9 @@ bool DbusActionWidget::isChanged() const
void DbusActionWidget::launchDbusBrowser() const
{
if( KRun::runCommand( "qdbusviewer", window()) == 0 )
{
KMessageBox::sorry( window(), i18n( "Failed to run qdbusviewer" ));
}
auto *job = new KIO::CommandLauncherJob("qdbusviewer");
job->setUiDelegate(new KDialogJobUiDelegate(KJobUiDelegate::AutoHandlingEnabled, window()));
job->start();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment