D11684: Show the KCM with the run commands open when a setup packet is received

Nicolas Fella noreply at phabricator.kde.org
Wed Apr 18 21:41:38 UTC 2018


nicolasfella requested changes to this revision.
nicolasfella added a comment.
This revision now requires changes to proceed.


  Please apply
  
    diff --git a/CMakeLists.txt b/CMakeLists.txt
    index 4d5d0229..6ad7b225 100644
    --- a/CMakeLists.txt
    +++ b/CMakeLists.txt
    @@ -8,7 +8,7 @@ set(KDECONNECT_VERSION_PATCH 1)
     set(KDECONNECT_VERSION "${KDECONNECT_VERSION_MAJOR}.${KDECONNECT_VERSION_MINOR}.${KDECONNECT_VERSION_PATCH}")
     
     set(QT_MIN_VERSION "5.7.0")
    -set(KF5_MIN_VERSION "5.42.0")
    +set(KF5_MIN_VERSION "5.45.0")
     
     find_package(ECM ${KF5_MIN_VERSION} REQUIRED NO_MODULE)
     set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH} ${ECM_KDE_MODULE_DIR} ${CMAKE_SOURCE_DIR}/cmake)
    diff --git a/plugins/runcommand/runcommandplugin.cpp b/plugins/runcommand/runcommandplugin.cpp
    index 41787a79..482501e4 100644
    --- a/plugins/runcommand/runcommandplugin.cpp
    +++ b/plugins/runcommand/runcommandplugin.cpp
    @@ -69,7 +69,7 @@ bool RunCommandPlugin::receivePacket(const NetworkPacket& np)
             QProcess::startDetached(QStringLiteral("/bin/sh"), QStringList()<< QStringLiteral("-c") << commandJson[QStringLiteral("command")].toString());
             return true;
         } else if (np.has("setup")) {
    -        QProcess::startDetached(QStringLiteral("kcmshell5"), {QStringLiteral("--args"), QString(device()->id() + QStringLiteral(":kdeconnect_runcommand")) });
    +        QProcess::startDetached(QStringLiteral("kcmshell5"), {QStringLiteral("kdeconnect"), QStringLiteral("--args"), QString(device()->id() + QStringLiteral(":kdeconnect_runcommand")) });
         }
     
         return false;
    @@ -85,6 +85,7 @@ void RunCommandPlugin::sendConfig()
     {
         QString commands = config()->get<QString>(QStringLiteral("commands"),QStringLiteral("{}"));
         NetworkPacket np(PACKET_TYPE_RUNCOMMAND, {{"commandList", commands}});
    +    np.set<bool>(QStringLiteral("canAddCommand"), true);
         sendPacket(np);
     }

REPOSITORY
  R224 KDE Connect

REVISION DETAIL
  https://phabricator.kde.org/D11684

To: apol, #kde_connect, nicolasfella
Cc: nicolasfella, yannux, Danial0_0, johnq, Pitel, adeen-s, SemperPeritus, ahmedbesbes, ndavis, daniel.z.tg, jeanv, seebauer, bugzy, MayeulC, menasshock, ach, apol
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdeconnect/attachments/20180418/41946aa8/attachment-0001.html>


More information about the KDEConnect mailing list