[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: How to get information about the current kdm session
From:       Oswald Buddenhagen <ossi () kde ! org>
Date:       2008-04-13 10:32:25
Message-ID: 20080413103225.GA29351 () ugly ! local
[Download RAW message or body]

On Sun, Apr 13, 2008 at 12:23:17PM +0200, Rene Landert wrote:
> All of these tools are shell commands. But how do I get the user / session 
> information when writing a daemon program in C++ which wants to know about 
> the user who is active on the console in this moment?
> 
you connect to ConsoleKit via d-bus and hope the user is using CK. :=)

workspace/libs/kworkspace/kdisplaymanager.h
getuid(), getpwuid(), etc.
getenv()
getutent(), etc.

-- 
Hi! I'm a .signature virus! Copy me into your ~/.signature, please!
--
Confusion, chaos, panic - my work here is done.
 
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic