Date: Fri, 26 Jun 2009 15:22:17 -0400 From: Joe Marcus Clarke <marcus@freebsd.org> To: vova@fbsd.ru Cc: gnome <gnome@freebsd.org>, mobile <mobile@freebsd.org> Subject: Re: dbus and system events - howto Message-ID: <4A451FE9.60002@freebsd.org> In-Reply-To: <1245773234.11855.22.camel@localhost> References: <1245773234.11855.22.camel@localhost>
next in thread | previous in thread | raw e-mail | index | archive | help
Vladimir Grebenschikov wrote: > Hi > > I am wandering is there "right" way to pass "system" events, like > brightness buttons, volume buttons reported with devd to gnome desktop > to: > 1. do appropriate changes (change volume, brightness, etc) > 2. show nice informational popup (with volume bar and so on) > ? > > Before I had simple script, called from devd, it configures system with > xbacklight, mixer and sysctl's, and shows something with onscreend > daemon. > > After Xorg update oscreend starts to freeze by some reason. So now I am > thinking about more "sane" way to link system events to gnome desktop. > > Also xbacklight now does not works with radeonhd again. > > So far I've dig for following dbus calls to manage brihgtness: > /usr/local/bin/dbus-send --system --type=method_call --print-reply=1 \ > --dest=org.freedesktop.PowerManagement \ > --session /org/freedesktop/PowerManagement/Backlight \ > org.freedesktop.PowerManagement.Backlight.GetBrightness > > /usr/local/bin/dbus-send --system --type=method_call --print-reply=1 \ > --dest=org.freedesktop.PowerManagement \ > --session /org/freedesktop/PowerManagement/Backlight \ > org.freedesktop.PowerManagement.Backlight.SetBrightness uint32:$1 > > But, looks like they are not shows popup. > And I've not found simple solution about volume yet. I haven't done much with power management in a long time as I don't have a laptop with good working PM. However, the volume support is easy. Just go to your Keyboard Shortcuts capplet, and add a new hotkey for the volume up and volume down actions. I actually used the Dell buttons on my laptop for this, and it works very well in GNOME. Joe > > Hints will be appreciated. > > PS: > Side question, can dbus work without DISPLAY and XAUTHORITY initialized ? > (system bus ?, but above calls requires them) > > PPS: > 8-CURRENT, Gnome, IBM T60. > -- Joe Marcus Clarke FreeBSD GNOME Team :: gnome@FreeBSD.org FreeNode / #freebsd-gnome http://www.FreeBSD.org/gnome
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4A451FE9.60002>