Changeset 9893

Show
Ignore:
Timestamp:
07/07/08 00:24:19 (7 weeks ago)
Author:
jim++
Message:

Make nick completion work fine with an empty refer_to_nick_char
Make nick completion sorted case-insensitive. Fixes #4063. (was already IMO)
Restore #2975 way. Last nick that highlighted us are first. Fixes #2975.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/src/groupchat_control.py

    r9880 r9893  
    18681868                        gc_refer_to_nick_char = gajim.config.get('gc_refer_to_nick_char') 
    18691869                        with_refer_to_nick_char = False 
    1870                         if begin.endswith(gc_refer_to_nick_char): 
     1870 
     1871                        # first part of this if : works fine even if refer_to_nick_char 
     1872                        if gc_refer_to_nick_char and begin.endswith(gc_refer_to_nick_char): 
    18711873                                with_refer_to_nick_char = True 
    18721874                        if len(self.nick_hits) and self.last_key_tabs and \ 
     
    18811883                                list_nick = gajim.contacts.get_nick_list(self.account, 
    18821884                                                                        self.room_jid) 
     1885                                list_nick.sort(key=unicode.lower) # case-insensitive sort 
    18831886                                if begin == '':  
    18841887                                        # empty message, show lasts nicks that highlighted us first 
     
    18891892 
    18901893                                list_nick.remove(self.nick) # Skip self 
    1891                                 list_nick.sort() 
    18921894                                for nick in list_nick: 
    18931895                                        if nick.lower().startswith(begin.lower()):