Re: How to logout an Online Desktop session



Hello,

On Tue, 2008-04-08 at 12:30 -0400, Colin Walters wrote:
> On Tue, 2008-04-08 at 10:18 +0200, Manuel Rego Casasnovas wrote:
> 
> > I don't know what is the problem. I've tried to find how Big Board knows
> > when I'm logged (when I have an Online Desktop session started), but I
> > don't know where Big Board checks it.
> 
> Basically, the signed in state depends on a browser cookie, which is set
> when you log in via the website, and deleted when you log out.  The
> desktop-data-engine scans for that cookie to initially sign in to the
> server.  However, it doesn't notice when it goes away after you've
> logged out of the website.

Ok, now I understand why Big Board doesn't detect that I've closed my
Online Desktop session.

> 
> > Could you tell me where (in source code) this checking is doing?
> > For example, how can an application know if an Online Desktop session
> > is started or no?
> 
> Yep, you can connect to the data model and wait for the ready signal.
> See the file "online-desktop/pyddm/test-session.py" for an example in
> Python.  For C there is "desktop-data-model/ddm/test-ddm.c".

I've tried to execute "online-desktop/pyddm/test-session.py" with:
python online-desktop/pyddm/test-session.py, and I have the next error:
DBusException: org.freedesktop.DBus.Error.ServiceUnknown: The name
org.freedesktop.od.Engine.localinstance_2Emugshot_2Eorg_3A8080 was not
provided by any .service files
Ready
DEBUG:mugshot.DataModel:doing query: ('http://mugshot.org/p/system',
'getResource') fetch=onlineBuddies +, single_result=True
No connection to data model engine
Online:  False

Thank you very much,
   Rego

-- 
Manuel Rego Casasnovas
Computer Science Engineer
mailto:mrego igalia com
Tel: +34 986 10 76 10
Fax: +34 981 91 39 49
Igalia - http://www.igalia.com



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]