KInit
klauncher.cpp
Go to the documentation of this file.
208 QDBusConnection::sessionBus().registerObject(QLatin1String("/KLauncher"), this); // same as ktoolinvocation.cpp
238 qWarning("Klauncher running in slave-debug mode for slaves of protocol '%s'", qPrintable(mSlaveDebug));
244 qWarning("Klauncher running slaves through valgrind for slaves of protocol '%s'", qPrintable(mSlaveValgrind));
452 const QString newAppId = appId.left(appId.lastIndexOf(QLatin1Char('-'))); // strip out the -12345 if present.
483 kDebug(7016) << "had pending request" << request->name << s_DBusStartupTypeToString[request->dbus_startup_type] << "dbus_name" << request->dbus_name << request->tolerant_dbus_name;
488 QDBusConnection::sessionBus().interface()->isServiceRegistered(request->dbus_name)) { // was already running
502 const QString rAppId = !request->tolerant_dbus_name.isEmpty() ? request->tolerant_dbus_name : request->dbus_name;
619 QDBusConnection::sessionBus().send(request->transaction.createReply(QVariantList() << requestResult.result
649 connect(process ,SIGNAL(finished(int,QProcess::ExitStatus)),this, SLOT(slotFinished(int,QProcess::ExitStatus)) );
726 void KLauncher::exec_blind(const QString &name, const QStringList &arg_list, const QStringList &envs, const QString &startup_id)
737 KService::Ptr service = KService::serviceByDesktopName( name.mid( name.lastIndexOf(QLatin1Char('/')) + 1 ));
786 // service = KService::serviceByStorageId(serviceName); // This method should be named start_service_by_storage_id ideally...
850 startup_id2 = "0"; // can't use the same startup_id several times // krazy:exclude=doublequote_chars
915 KLauncher::send_service_startup_info( KLaunchRequest *request, KService::Ptr service, const QByteArray& startup_id,
QString i18n(const char *text)
void clear()
bool start_service_by_desktop_path(const QString &serviceName, const QStringList &urls, const QStringList &envs, const QString &startup_id, bool blind, const QDBusMessage &msg)
Start a service by desktop path.
Definition: klauncher.cpp:770
Definition: klauncher.h:81
void cancel_service_startup_info(KLaunchRequest *request, const QByteArray &startup_id, const QStringList &envs)
Definition: klauncher.cpp:967
void setDelayedReply(bool enable) const
void reserve(int size)
static Ptr serviceByDesktopName(const QString &_name)
bool isAbsolute() const
QObject * sender() const
int timeout
bool checkForHeldSlave(const QString &url)
Return true of there is a slave held for url.
Definition: klauncher.cpp:1233
QDBusConnectionInterface * interface() const
static QString locate(const char *type, const QString &filename, const KComponentData &cData=KGlobal::mainComponent())
pid_t requestHoldSlave(const KUrl &url, const QString &app_socket)
Definition: klauncher.cpp:1093
void exec_blind(const QString &name, const QStringList &arg_list, const QStringList &envs, const QString &startup_id)
Starts a program.
Definition: klauncher.cpp:726
bool isNull() const
QVariant property(const QString &_name, QVariant::Type t) const
bool kdeinit_exec(const QString &app, const QStringList &args, const QString &workdir, const QStringList &envs, const QString &startup_id, bool wait, const QDBusMessage &msg)
Definition: klauncher.cpp:999
bool registerObject(const QString &path, QObject *object, QFlags< QDBusConnection::RegisterOption > options)
bool isEmpty() const
QDebug & nospace()
static QDebug kError(bool cond, int area=KDE_DEFAULT_DEBUG_AREA)
MessageType type() const
QDBusConnection sessionBus()
void setOutputChannelMode(OutputChannelMode mode)
Definition: klauncher.h:88
int length() const
Definition: klauncher.h:123
QDBusReply< bool > isServiceRegistered(const QString &serviceName) const
Definition: klauncher.h:95
static QDebug kDebug(bool cond, int area=KDE_DEFAULT_DEBUG_AREA)
Definition: klauncher.h:95
void send_service_startup_info(KLaunchRequest *request, KService::Ptr service, const QByteArray &startup_id, const QStringList &envs)
Definition: klauncher.cpp:915
QList< SlaveWaitRequest * > mSlaveWaitRequest
Definition: klauncher.h:275
int lastIndexOf(QChar ch, int from, Qt::CaseSensitivity cs) const
bool isNull() const
QString exec() const
static bool isAuthorizedDesktopFile(const QString &path)
void slotFinished(int exitCode, QProcess::ExitStatus exitStatus)
Definition: klauncher.cpp:1336
QString path() const
void clear()
void resize(int size)
KService::DBusStartupType dbus_startup_type
Definition: klauncher.h:99
const char * name() const
DBusStartupType dbusStartupType() const
int count(const T &value) const
QString fromLocal8Bit(const char *str, int size)
void append(const T &value)
QDBusMessage createReply(const QList< QVariant > &arguments) const
QString fromUtf8(const char *str, int size)
bool start_service_by_desktop_name(const QString &serviceName, const QStringList &urls, const QStringList &envs, const QString &startup_id, bool blind, const QDBusMessage &msg)
Start a service by desktop name.
Definition: klauncher.cpp:799
pid_t requestSlave(const QString &protocol, const QString &host, const QString &app_socket, QString &error)
Definition: klauncher.cpp:1114
bool isEmpty() const
bool send(const QDBusMessage &message) const
bool isEmpty() const
int removeAll(const T &value)
const char * constData() const
bool start_service_by_name(const QString &serviceName, const QStringList &urls, const QStringList &envs, const QString &startup_id, bool blind, const QDBusMessage &msg)
Start a service by (translated) name - deprecated.
Definition: klauncher.cpp:751
bool startsWith(const QString &s, Qt::CaseSensitivity cs) const
void statusUpdate(IdleSlave *)
Definition: klauncher.h:50
bool endsWith(const QString &s, Qt::CaseSensitivity cs) const
static bool matchesPendingRequest(const QString &appId, const QString &pendingAppId)
Definition: klauncher.cpp:447
void remove()
void deleteLater()
QString fileName
T & first()
static const char *const s_DBusStartupTypeToString[]
Definition: klauncher.cpp:65
bool atEnd() const
static Ptr serviceByDesktopPath(const QString &_path)
void start()
bool allowMultipleFiles() const
QByteArray & append(char ch)
Definition: klauncher.h:95
iterator end()
QByteArray toLocal8Bit() const
void setLaunchEnv(const QString &name, const QString &value)
Definition: klauncher.cpp:282
bool exists() const
QString icon() const
bool match(const QString &protocol, const QString &host, bool connected) const
Definition: klauncher.cpp:149
bool waitForStarted(int msecs)
bool hasNext() const
void stop()
static QString exec(const QString &protocol)
void waitForSlave(int pid, const QDBusMessage &msg)
Definition: klauncher.cpp:1244
QByteArray toLatin1() const
QString mid(int position, int n) const
void autoStart0Done()
static Ptr serviceByName(const QString &_name)
T takeFirst()
void autoStart1Done()
Definition: klauncher.h:95
T & next()
void autoStart2Done()
static QString findExe(const QString &appname, const QString &pathstr=QString(), SearchOptions options=NoSearchOptions)
typedef ConstIterator
const KComponentData & mainComponent()
void processRequestReturn(int status, const QByteArray &requestData)
Definition: klauncher.cpp:365
char * data()
static QDebug kWarning(bool cond, int area=KDE_DEFAULT_DEBUG_AREA)
QString left(int n) const
QString fromLatin1(const char *str, int size)
void start(int msec)
bool isValid() const
void prepend(const T &value)
int pid() const
const_iterator constEnd() const
const_iterator constBegin() const
int size() const
bool isActive() const
bool connect(const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
bool start_service(KService::Ptr service, const QStringList &urls, const QStringList &envs, const QByteArray &startup_id, bool blind, bool autoStart, const QDBusMessage &msg)
Definition: klauncher.cpp:814
Definition: klauncher_adaptor.h:36
void createArgs(KLaunchRequest *request, const KService::Ptr service, const QStringList &url)
Definition: klauncher.cpp:1068
QString toString() const
QByteArray readAllStandardOutput()
iterator begin()
void destroyed(QObject *obj)
QByteArray encodeName(const QString &fileName)
Definition: klauncher_cmds.h:25
void slotNameOwnerChanged(const QString &name, const QString &oldOnwer, const QString &newOwner)
Definition: klauncher.cpp:467
singleShot
void setProgram(const QString &exe, const QStringList &args=QStringList())
ssize_t kde_safe_write(int fd, const void *buf, size_t count)
Definition: klauncher.cpp:182
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:23:53 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:23:53 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.