Skip to content
This repository has been archived by the owner on Nov 8, 2022. It is now read-only.

Linux, no output from interface method #59

Open
jurijr opened this issue Jan 6, 2017 · 0 comments
Open

Linux, no output from interface method #59

jurijr opened this issue Jan 6, 2017 · 0 comments

Comments

@jurijr
Copy link

jurijr commented Jan 6, 2017

Pretty much new to using dbus and I have following sample, that wouldn't work for me.

I use "org.freedesktop.ScreenSaver" interface with method int GetIdleTime() to retrieve idle duration,
and "com.canonical.Unity.Session" interface to provide Locked event.

I retrieve instances of both interfaces using T GetObject
Everything works fine so far, untill,
if, for example I call GetIdleTime() inside Locked event delegate.

Once locked event occur, and tries to read idle time, it never completes reading it. No exceptions, just hangs.
I tried looping idle time every 200ms for example, even while passing into Locked state, and out, no problems there.

Could someone please clarify if I am misusing the dbus or deadlock like this happens by design??

Edit
Tried to bubble event with reactive extensions and schedule subscription on new thread and it seemed to work now.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant