Changeset 10019
- Timestamp:
- 07/25/08 00:13:37 (4 months ago)
- Files:
-
- 1 modified
-
trunk/src/chat_control.py (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/chat_control.py
r10016 r10019 1153 1153 1154 1154 # Enable encryption if needed 1155 self.no_autonegotiation = False 1155 1156 e2e_is_active = self.session and self.session.enable_encryption 1156 1157 self.gpg_is_active = False 1157 1158 gpg_pref = gajim.config.get_per('contacts', contact.jid, 1158 1159 'gpg_enabled') 1159 e2e_pref = gajim.config.get_per('accounts', self.account,1160 'autonegotiate_esessions') and \1161 gajim.config.get_per('contacts', contact.jid,1162 'autonegotiate_esessions')1163 1160 1164 1161 # try GPG first … … 1179 1176 self.gpg_is_active, 1180 1177 self.session and self.session.is_loggable(), True) 1181 # then try E2E1182 # XXX: Once we have fallback to disco, remove notexistant check1183 elif not e2e_is_active and gajim.HAVE_PYCRYPTO and e2e_pref \1184 and gajim.capscache.is_supported(contact, NS_ESESSION) \1185 and not gajim.capscache.is_supported(contact, 'notexistant'):1186 self.begin_e2e_negotiation()1187 1178 1188 1179 self.status_tooltip = gtk.Tooltips() … … 2261 2252 if textbuffer.get_char_count(): 2262 2253 self.send_chatstate('composing', self.contact) 2254 2255 e2e_is_active = self.session and \ 2256 self.session.enable_encryption 2257 e2e_pref = gajim.config.get_per('accounts', 2258 self.account, 'autonegotiate_esessions') and \ 2259 gajim.config.get_per('contacts', 2260 self.contact.jid, 'autonegotiate_esessions') 2261 # XXX: Once we have fallback to disco, remove 2262 # notexistant check 2263 if not e2e_is_active and e2e_pref and \ 2264 not self.no_autonegotiation and gajim.HAVE_PYCRYPTO \ 2265 and e2e_pref and gajim.capscache.is_supported( 2266 self.contact, NS_ESESSION) and not \ 2267 gajim.capscache.is_supported(self.contact, 2268 'notexistant'): 2269 self.no_autonegotiation = True 2270 self.begin_e2e_negotiation() 2263 2271 else: 2264 2272 self.send_chatstate('active', self.contact)
