introduce play_sound_file function in helpers
This commit is contained in:
parent
335870646d
commit
a54ee0229d
|
@ -418,6 +418,9 @@ def play_sound(event):
|
||||||
if not gajim.config.get('sounds_on'):
|
if not gajim.config.get('sounds_on'):
|
||||||
return
|
return
|
||||||
path_to_soundfile = gajim.config.get_per('soundevents', event, 'path')
|
path_to_soundfile = gajim.config.get_per('soundevents', event, 'path')
|
||||||
|
play_sound_file(path_to_soundfile)
|
||||||
|
|
||||||
|
def play_sound_file(path_to_soundfile):
|
||||||
if path_to_soundfile == 'beep':
|
if path_to_soundfile == 'beep':
|
||||||
print '\a' # make a speaker beep
|
print '\a' # make a speaker beep
|
||||||
return
|
return
|
||||||
|
|
Loading…
Reference in New Issue