Commit 87db6b3f authored by Dan Pascu's avatar Dan Pascu

Adapted to SIP simple stream API changes

parent ab19744e
...@@ -1785,8 +1785,8 @@ class SessionManager(object): ...@@ -1785,8 +1785,8 @@ class SessionManager(object):
break break
else: else:
contact = None contact = None
audio_stream = self.create_stream(account, 'audio') if audio else None audio_stream = self.create_stream('audio') if audio else None
video_stream = self.create_stream(account, 'video') if video else None video_stream = self.create_stream('video') if video else None
session_item = SessionItem(name, remote_uri, session, contact, audio_stream=audio_stream, video_stream=video_stream) session_item = SessionItem(name, remote_uri, session, contact, audio_stream=audio_stream, video_stream=video_stream)
session_item.activated.connect(partial(self._SH_SessionActivated, session_item)) session_item.activated.connect(partial(self._SH_SessionActivated, session_item))
session_item.deactivated.connect(partial(self._SH_SessionDeactivated, session_item)) session_item.deactivated.connect(partial(self._SH_SessionDeactivated, session_item))
...@@ -1835,10 +1835,10 @@ class SessionManager(object): ...@@ -1835,10 +1835,10 @@ class SessionManager(object):
del _get_current_ringtone, _set_current_ringtone del _get_current_ringtone, _set_current_ringtone
@staticmethod @staticmethod
def create_stream(account, type): def create_stream(type):
for cls in MediaStreamRegistry(): for cls in MediaStreamRegistry():
if cls.type == type: if cls.type == type:
return cls(account) return cls()
else: else:
raise ValueError('unknown stream type: %s' % type) raise ValueError('unknown stream type: %s' % type)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment