remove checks and code for < 2.6
This commit is contained in:
parent
fcc4a6a0ce
commit
788a4dc7a1
|
@ -401,11 +401,6 @@ _('Contact names must be of the form "user@servername".')).get_response()
|
|||
class AboutDialog:
|
||||
'''Class for about dialog'''
|
||||
def __init__(self):
|
||||
if gtk.pygtk_version < (2, 6, 0) or gtk.gtk_version < (2, 6, 0):
|
||||
InformationDialog(_('Gajim - a GTK+ Jabber client'),
|
||||
_('Version %s') % gajim.version)
|
||||
return
|
||||
|
||||
dlg = gtk.AboutDialog()
|
||||
dlg.set_name('Gajim')
|
||||
dlg.set_version(gajim.version)
|
||||
|
|
|
@ -1121,7 +1121,6 @@ class Interface:
|
|||
for account in gajim.config.get_per('accounts'):
|
||||
gajim.connections[account] = common.connection.Connection(account)
|
||||
|
||||
if gtk.pygtk_version >= (2, 6, 0):
|
||||
gtk.about_dialog_set_email_hook(self.on_launch_browser_mailer, 'mail')
|
||||
gtk.about_dialog_set_url_hook(self.on_launch_browser_mailer, 'url')
|
||||
self.windows = {'logs':{}}
|
||||
|
|
|
@ -392,16 +392,11 @@ class GroupchatWindow(chat.Chat):
|
|||
st += ' (' + status + ')'
|
||||
self.print_conversation(st, room_jid)
|
||||
|
||||
|
||||
|
||||
def set_subject(self, room_jid, subject):
|
||||
self.subjects[room_jid] = subject
|
||||
name_label = self.name_labels[room_jid]
|
||||
full_subject = None
|
||||
|
||||
if gtk.gtk_version < (2, 6, 0) or gtk.pygtk_version < (2, 6, 0):
|
||||
subject = gtkgui_helpers.reduce_chars_newlines(subject, 80, 2)
|
||||
else:
|
||||
subject = gtkgui_helpers.reduce_chars_newlines(subject, 0, 2)
|
||||
subject = gtkgui_helpers.escape_for_pango_markup(subject)
|
||||
name_label.set_markup(
|
||||
|
|
|
@ -139,11 +139,8 @@ class StatusTable:
|
|||
status = status.strip()
|
||||
if status != '':
|
||||
# make sure 'status' is unicode before we send to to reduce_chars...
|
||||
if type(status) == str:
|
||||
if isinstance(status, str):
|
||||
status = unicode(status, encoding='utf-8')
|
||||
if gtk.gtk_version < (2, 6, 0) or gtk.pygtk_version < (2, 6, 0):
|
||||
status = gtkgui_helpers.reduce_chars_newlines(status, 50, 1)
|
||||
else:
|
||||
status = gtkgui_helpers.reduce_chars_newlines(status, 0, 1)
|
||||
str_status += ' - ' + status
|
||||
return gtkgui_helpers.escape_for_pango_markup(str_status)
|
||||
|
|
Loading…
Reference in New Issue