Fix /dtmf command
This commit is contained in:
parent
23ab28d76f
commit
845d310c9b
|
@ -123,14 +123,14 @@ class JingleRTPContent(JingleContent):
|
|||
if self._dtmf_running:
|
||||
raise Exception # TODO: Proper exception
|
||||
self._dtmf_running = True
|
||||
self._start_dtmf(events.pop(0))
|
||||
gobject.timeout_add(500, self._next_dtmf, events)
|
||||
self._start_dtmf(events[-1])
|
||||
gobject.timeout_add(500, self._next_dtmf, events[:-1])
|
||||
|
||||
def _next_dtmf(self, events):
|
||||
self._stop_dtmf()
|
||||
if events:
|
||||
self._start_dtmf(events.pop(0))
|
||||
gobject.timeout_add(500, self._next_dtmf, events)
|
||||
self._start_dtmf(events[-1])
|
||||
gobject.timeout_add(500, self._next_dtmf, events[:-1])
|
||||
else:
|
||||
self._dtmf_running = False
|
||||
|
||||
|
|
Loading…
Reference in New Issue