On Thursday, 2012-08-16, Milian Wolff wrote:
> Hey there,
> 
> see for context: http://git.reviewboard.kde.org/r/105917/#review17551
> 
> tl;dr; I need to construct the DBus identifier of the currently running
> app, e.g. "org.kdevelop.kdevelop-$pid" - from inside a library.
> 
> I found KAboutData, which could be obtained via KCmdLineArgs::aboutData().
> There, I have organizationDomain() and appName(), which I could concatenate
> to the DBUS identifier like:
> 
> id = "%1.%2-%3".arg(orgDomain, appName, pid)
> 
> Does that sound OK or is there a better, more direct approach, to find the
> DBus identifier for the currently running app?

A D-Bus connection, which means also the Default connection to the session 
bus, can have any number of "nice" names (it will always have a unique name, 
e.g. :1.90).

What do you want to achieve, i.e. what do you need that KDE application name 
for?

Cheers,
Kevin

-- 
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring

Attachment: signature.asc
Description: This is a digitally signed message part.

>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<

Reply via email to