diff --git a/src/dialogs.py b/src/dialogs.py index e117e3406..2ec740c0f 100644 --- a/src/dialogs.py +++ b/src/dialogs.py @@ -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) diff --git a/src/gajim.py b/src/gajim.py index 36bfba87e..8ba21f467 100755 --- a/src/gajim.py +++ b/src/gajim.py @@ -1121,9 +1121,8 @@ 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') + 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':{}} for a in gajim.connections: diff --git a/src/groupchat_window.py b/src/groupchat_window.py index 8a8c73b8b..2350e1d7f 100644 --- a/src/groupchat_window.py +++ b/src/groupchat_window.py @@ -392,17 +392,12 @@ 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.reduce_chars_newlines(subject, 0, 2) subject = gtkgui_helpers.escape_for_pango_markup(subject) name_label.set_markup( '%s\n%s' % (room_jid, subject)) diff --git a/src/tooltips.py b/src/tooltips.py index 3a23d71b0..b24b5c770 100644 --- a/src/tooltips.py +++ b/src/tooltips.py @@ -139,12 +139,9 @@ 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) + status = gtkgui_helpers.reduce_chars_newlines(status, 0, 1) str_status += ' - ' + status return gtkgui_helpers.escape_for_pango_markup(str_status)