Xfce Forum

Sub domains
 

You are not logged in.

#1 2013-09-26 15:29:33

Sergei_Alekseev
Member
Registered: 2013-09-26
Posts: 5

[Solved] System sounds for root applications

Hello.
I added

"if [ -z "$GTK_MODULES" ] ; then
    GTK_MODULES="canberra-gtk-module"
else
    GTK_MODULES="$GTK_MODULES:canberra-gtk-module"
fi
export GTK_MODULES"

to /etc/xdg/xfce4/xinitrc and now properly named sounds in /usr/share/sounds are working good in gtk programs.
But only for apps started as user.
How to make sys sounds available for apps started as root?
Sorry about bad English.
Have a nice day.

Offline

#2 2013-09-26 16:03:30

ToZ
Member
From: Toronto, Canada
Registered: 2011-06-02
Posts: 936

Re: [Solved] System sounds for root applications

Try starting your root apps like this (setting env in command):

gksu env GTK_MODULES="canberra-gtk-module" <command>

Offline

#3 2013-09-26 16:18:30

Sergei_Alekseev
Member
Registered: 2013-09-26
Posts: 5

Re: [Solved] System sounds for root applications

Thank you for the answer.
Sounds are playing now.
Can i add that env somewhere for all root apps?

Offline

#4 2013-09-26 16:22:12

ToZ
Member
From: Toronto, Canada
Registered: 2011-06-02
Posts: 936

Re: [Solved] System sounds for root applications

If you start your root apps with gksu, then just create an alias:

alias gksu='gksu env GTK_MODULES="canberra-gtk-module"'

If you're using bash. put it in ~/.bashrc.

Then simply:

gksu <command>

Last edited by ToZ (2013-09-26 16:23:00)

Offline

#5 2013-09-26 18:38:46

Sergei_Alekseev
Member
Registered: 2013-09-26
Posts: 5

Re: [Solved] System sounds for root applications

Thank you, i am happy now)

Offline

Board footer

Powered by FluxBB