parent
98b18a74a1
commit
4abd0a9d42
|
@ -207,7 +207,7 @@ class ChatControlBase(MessageControl):
|
||||||
return True
|
return True
|
||||||
elif event.keyval == gtk.keysyms.m and \
|
elif event.keyval == gtk.keysyms.m and \
|
||||||
(event.state & gtk.gdk.MOD1_MASK): # alt + m opens emoticons menu
|
(event.state & gtk.gdk.MOD1_MASK): # alt + m opens emoticons menu
|
||||||
if gajim.config.get('useemoticons'):
|
if gajim.config.get('emoticons_theme'):
|
||||||
msg_tv = self.msg_textview
|
msg_tv = self.msg_textview
|
||||||
def set_emoticons_menu_position(w, msg_tv = self.msg_textview):
|
def set_emoticons_menu_position(w, msg_tv = self.msg_textview):
|
||||||
window = msg_tv.get_window(gtk.TEXT_WINDOW_WIDGET)
|
window = msg_tv.get_window(gtk.TEXT_WINDOW_WIDGET)
|
||||||
|
@ -412,7 +412,7 @@ class ChatControlBase(MessageControl):
|
||||||
'''hide show emoticons_button and make sure emoticons_menu is always there
|
'''hide show emoticons_button and make sure emoticons_menu is always there
|
||||||
when needed'''
|
when needed'''
|
||||||
emoticons_button = self.xml.get_widget('emoticons_button')
|
emoticons_button = self.xml.get_widget('emoticons_button')
|
||||||
if gajim.config.get('useemoticons'):
|
if gajim.config.get('emoticons_theme'):
|
||||||
self.emoticons_menu = self.prepare_emoticons_menu()
|
self.emoticons_menu = self.prepare_emoticons_menu()
|
||||||
emoticons_button.show()
|
emoticons_button.show()
|
||||||
emoticons_button.set_no_show_all(False)
|
emoticons_button.set_no_show_all(False)
|
||||||
|
|
|
@ -418,7 +418,7 @@ class ConversationTextview(gtk.TextView):
|
||||||
index = 0
|
index = 0
|
||||||
|
|
||||||
# basic: links + mail + formatting is always checked (we like that)
|
# basic: links + mail + formatting is always checked (we like that)
|
||||||
if gajim.config.get('useemoticons'): # search for emoticons & urls
|
if gajim.config.get('emoticons_theme'): # search for emoticons & urls
|
||||||
iterator = gajim.interface.emot_and_basic_re.finditer(otext)
|
iterator = gajim.interface.emot_and_basic_re.finditer(otext)
|
||||||
else: # search for just urls + mail + formatting
|
else: # search for just urls + mail + formatting
|
||||||
iterator = gajim.interface.basic_pattern_re.finditer(otext)
|
iterator = gajim.interface.basic_pattern_re.finditer(otext)
|
||||||
|
@ -448,7 +448,7 @@ class ConversationTextview(gtk.TextView):
|
||||||
buffer = self.get_buffer()
|
buffer = self.get_buffer()
|
||||||
|
|
||||||
possible_emot_ascii_caps = special_text.upper() # emoticons keys are CAPS
|
possible_emot_ascii_caps = special_text.upper() # emoticons keys are CAPS
|
||||||
if gajim.config.get('useemoticons') and \
|
if gajim.config.get('emoticons_theme') and \
|
||||||
possible_emot_ascii_caps in gajim.interface.emoticons.keys():
|
possible_emot_ascii_caps in gajim.interface.emoticons.keys():
|
||||||
#it's an emoticon
|
#it's an emoticon
|
||||||
emot_ascii = possible_emot_ascii_caps
|
emot_ascii = possible_emot_ascii_caps
|
||||||
|
|
|
@ -1357,7 +1357,7 @@ class Interface:
|
||||||
self.basic_pattern_re = sre.compile(basic_pattern, sre.IGNORECASE)
|
self.basic_pattern_re = sre.compile(basic_pattern, sre.IGNORECASE)
|
||||||
|
|
||||||
emoticons_pattern = ''
|
emoticons_pattern = ''
|
||||||
if gajim.config.get('useemoticons'):
|
if gajim.config.get('emoticons_theme'):
|
||||||
# When an emoticon is bordered by an alpha-numeric character it is NOT
|
# When an emoticon is bordered by an alpha-numeric character it is NOT
|
||||||
# expanded. e.g., foo:) NO, foo :) YES, (brb) NO, (:)) YES, etc.
|
# expanded. e.g., foo:) NO, foo :) YES, (brb) NO, (:)) YES, etc.
|
||||||
# We still allow multiple emoticons side-by-side like :P:P:P
|
# We still allow multiple emoticons side-by-side like :P:P:P
|
||||||
|
@ -1408,7 +1408,7 @@ class Interface:
|
||||||
helpers.launch_browser_mailer(kind, url)
|
helpers.launch_browser_mailer(kind, url)
|
||||||
|
|
||||||
def init_emoticons(self):
|
def init_emoticons(self):
|
||||||
if not gajim.config.get('useemoticons'):
|
if not gajim.config.get('emoticons_theme'):
|
||||||
return
|
return
|
||||||
|
|
||||||
#initialize emoticons dictionary and unique images list
|
#initialize emoticons dictionary and unique images list
|
||||||
|
|
Loading…
Reference in New Issue