don't play sound when we receive the message we just sent in groupchat. Fixes #6938
This commit is contained in:
parent
6e24d6c04e
commit
96b1cc524d
|
@ -2004,11 +2004,15 @@ class NotificationEvent(nec.NetworkIncomingEvent):
|
||||||
def handle_incoming_gc_msg_event(self, msg_obj):
|
def handle_incoming_gc_msg_event(self, msg_obj):
|
||||||
sound = msg_obj.msg_obj.gc_control.highlighting_for_message(
|
sound = msg_obj.msg_obj.gc_control.highlighting_for_message(
|
||||||
msg_obj.msgtxt, msg_obj.timestamp)[1]
|
msg_obj.msgtxt, msg_obj.timestamp)[1]
|
||||||
self.do_sound = True
|
|
||||||
if sound == 'received':
|
if msg_obj.nickname != msg_obj.msg_obj.gc_control.nick:
|
||||||
self.sound_event = 'muc_message_received'
|
self.do_sound = True
|
||||||
elif sound == 'highlight':
|
if sound == 'received':
|
||||||
self.sound_event = 'muc_message_highlight'
|
self.sound_event = 'muc_message_received'
|
||||||
|
elif sound == 'highlight':
|
||||||
|
self.sound_event = 'muc_message_highlight'
|
||||||
|
else:
|
||||||
|
self.do_sound = False
|
||||||
else:
|
else:
|
||||||
self.do_sound = False
|
self.do_sound = False
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue