diff options
author | Philipp Hörist <philipp@hoerist.com> | 2018-10-06 21:14:38 +0300 |
---|---|---|
committer | Philipp Hörist <philipp@hoerist.com> | 2018-10-06 21:46:24 +0300 |
commit | 97c2bfbdd9cf4929cd27156b8210c1e71871a018 (patch) | |
tree | f9e826b9188ea7db90596dcf90b1e48f4f5383b4 | |
parent | db2c71b6a10cac18fbf9dd60b093cfe90360eb96 (diff) |
Add compatibility for Gajim 1.1
62 files changed, 275 insertions, 115 deletions
diff --git a/acronyms_expander/acronyms_expander.py b/acronyms_expander/acronyms_expander.py index 76b1f21..983a43c 100644 --- a/acronyms_expander/acronyms_expander.py +++ b/acronyms_expander/acronyms_expander.py @@ -24,15 +24,19 @@ Acronyms expander plugin. :license: GPL ''' -import sys import os -from gi.repository import Gtk from gi.repository import GObject from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log, log_calls +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + class AcronymsExpanderPlugin(GajimPlugin): @log_calls('AcronymsExpanderPlugin') diff --git a/acronyms_expander/manifest.ini b/acronyms_expander/manifest.ini index 10148ce..11c81f7 100644 --- a/acronyms_expander/manifest.ini +++ b/acronyms_expander/manifest.ini @@ -1,7 +1,7 @@ [info] name: Acronyms Expander short_name: acronyms_expander -version: 0.3 +version: 0.4 description: Replaces acronyms (or other strings) with given expansions/substitutes. authors: Mateusz Biliński <mateusz@bilinski.it> homepage: https://dev.gajim.org/gajim/gajim-plugins/wikis/AcronymsExpanderPlugin diff --git a/anti_spam/anti_spam.py b/anti_spam/anti_spam.py index 880c691..b585bf7 100644 --- a/anti_spam/anti_spam.py +++ b/anti_spam/anti_spam.py @@ -32,6 +32,12 @@ from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log, log_calls
from gajim.plugins.gui import GajimPluginConfigDialog
+# Since Gajim 1.1.0 _() has to be imported
+try:
+ from gajim.common.i18n import _
+except ImportError:
+ pass
+
class AntiSpamPlugin(GajimPlugin):
@log_calls('AntiSpamPlugin')
diff --git a/anti_spam/manifest.ini b/anti_spam/manifest.ini index 068fb1c..6856c84 100644 --- a/anti_spam/manifest.ini +++ b/anti_spam/manifest.ini @@ -1,7 +1,7 @@ [info]
name: Anti Spam
short_name: anti_spam
-version: 1.4.4
+version: 1.4.5
description: Block some incoming messages.
authors = Yann Leboulanger <asterix@lagaule.org>
Denis Fomin <fominde@gmail.com>
diff --git a/appindicator_integration/manifest.ini b/appindicator_integration/manifest.ini index 3b055e2..0d932d3 100644 --- a/appindicator_integration/manifest.ini +++ b/appindicator_integration/manifest.ini @@ -1,7 +1,7 @@ [info] name: Ayatana Appindicator integration short_name: appindicator_integration -version: 1.1.0 +version: 1.1.1 description: This plugin integrates Gajim with the Ayatana AppIndicator. You must have gir1.2-ayatanaappindicator3-0.1 installed to enable this plugin. homepage: https://dev.gajim.org/gajim/gajim-plugins/wikis/AppindicatorSupportPlugin authors: Denis Borenko <borenko@rambler.ru> diff --git a/appindicator_integration/plugin.py b/appindicator_integration/plugin.py index ade0db7..ed34be8 100644 --- a/appindicator_integration/plugin.py +++ b/appindicator_integration/plugin.py @@ -18,13 +18,19 @@ try: from gi.repository import AyatanaAppIndicator3 as appindicator ERRORMSG = None except (ValueError, ImportError): - ERRORMSG = _('Please install libappindicator3') + ERRORMSG = 'Please install libappindicator3' from gajim.common import app, ged from gajim.common import configpaths from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log_calls +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + class AppindicatorIntegrationPlugin(GajimPlugin): diff --git a/banner_tweaks/manifest.ini b/banner_tweaks/manifest.ini index 62310d0..85036bf 100644 --- a/banner_tweaks/manifest.ini +++ b/banner_tweaks/manifest.ini @@ -1,7 +1,7 @@ [info] name: Banner Tweaks short_name: banner_tweaks -version: 0.1.3 +version: 0.1.4 description: Allows user to tweak chat window banner appearance (eg. make it compact). authors = Mateusz Biliński <mateusz@bilinski.it> homepage = http://trac-plugins.gajim.org/wiki/BannerTweaksPlugin diff --git a/banner_tweaks/plugin.py b/banner_tweaks/plugin.py index 8a2f84c..5696923 100644 --- a/banner_tweaks/plugin.py +++ b/banner_tweaks/plugin.py @@ -29,8 +29,6 @@ http://trac.gajim.org/attachment/ticket/4133/gajim-chatbanneroptions-svn10008.pa :license: GPL ''' -import sys - from gi.repository import Gtk from gi.repository import GObject from gajim import message_control @@ -38,9 +36,16 @@ from gajim.common import app from gajim.common import helpers from gajim.plugins import GajimPlugin -from gajim.plugins.helpers import log, log_calls +from gajim.plugins.helpers import log_calls from gajim.plugins.gui import GajimPluginConfigDialog +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + + class BannerTweaksPlugin(GajimPlugin): @log_calls('BannerTweaksPlugin') diff --git a/birthday_reminder/manifest.ini b/birthday_reminder/manifest.ini index 454e744..b9d7ca5 100644 --- a/birthday_reminder/manifest.ini +++ b/birthday_reminder/manifest.ini @@ -1,7 +1,7 @@ [info] name: Birthday reminder short_name: birthday_reminder -version: 1.0.0 +version: 1.0.1 description: Reminds you if a contact of yours has birthday authors: Evgeniy Popov <evgeniypopov@gmail.com> Philipp Hörist <philipp@hoerist.com> diff --git a/birthday_reminder/plugin.py b/birthday_reminder/plugin.py index dcade36..f403f5b 100644 --- a/birthday_reminder/plugin.py +++ b/birthday_reminder/plugin.py @@ -11,6 +11,12 @@ from gajim.common import configpaths from gajim.common import app from gajim.common import ged +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + log = logging.getLogger('gajim.plugin_system.birthday') TITLE = _('%s has birthday today') diff --git a/chatstate/chatstate.py b/chatstate/chatstate.py index dc4d49a..a9da7a1 100644 --- a/chatstate/chatstate.py +++ b/chatstate/chatstate.py @@ -1,5 +1,4 @@ -# -*- coding: utf-8 -*- -## +import unicodedata from gi.repository import GObject @@ -9,7 +8,12 @@ from gajim.common import ged from gajim.common import app from gajim.common import helpers from gajim import gtkgui_helpers -import unicodedata + +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass def paragraph_direction_mark(text): """ diff --git a/chatstate/manifest.ini b/chatstate/manifest.ini index 7e10a82..c39181b 100644 --- a/chatstate/manifest.ini +++ b/chatstate/manifest.ini @@ -1,7 +1,7 @@ [info] name: Chatstate in roster short_name: chatstate -version: 0.5.5 +version: 0.5.6 description: Chat State Notifications in roster. Font color of the contact varies depending on the chat state. The plugin does not work if you use custom font color for contacts in roster. diff --git a/clickable_nicknames/clickable_nicknames.py b/clickable_nicknames/clickable_nicknames.py index ed117df..e2be333 100644 --- a/clickable_nicknames/clickable_nicknames.py +++ b/clickable_nicknames/clickable_nicknames.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - from gi.repository import Gtk from gi.repository import Gdk @@ -7,6 +5,12 @@ from gajim.common import app from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log_calls +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + class ClickableNicknames(GajimPlugin): diff --git a/clickable_nicknames/manifest.ini b/clickable_nicknames/manifest.ini index 02e5ec2..1973d44 100644 --- a/clickable_nicknames/manifest.ini +++ b/clickable_nicknames/manifest.ini @@ -1,9 +1,9 @@ [info] name: Clickable Nicknames short_name: clickable_nicknames -version: 0.6 +version: 0.7 description: Clickable nicknames in the conversation textview. authors: Andrey Musikhin <melomansegfault@gmail.com> Denis Fomin <fominde@gmail.com> homepage: http://trac-plugins.gajim.org/wiki/ClickableNicknamesPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/clients_icons/clients_icons.py b/clients_icons/clients_icons.py index b2fa754..ef33e4a 100644 --- a/clients_icons/clients_icons.py +++ b/clients_icons/clients_icons.py @@ -1,10 +1,8 @@ -# -*- coding: utf-8 -*- -## +import os +import logging from gi.repository import Gtk from gi.repository import GdkPixbuf -import os -import logging from clients_icons.clients import CLIENTS, LIBPURPLE_CLIENTS @@ -15,6 +13,12 @@ from gajim.common import ged from gajim.common import app from gajim.common import caps_cache +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + log = logging.getLogger('gajim.plugin_system.clients_icons') diff --git a/clients_icons/manifest.ini b/clients_icons/manifest.ini index 2878994..28d22c4 100644 --- a/clients_icons/manifest.ini +++ b/clients_icons/manifest.ini @@ -1,10 +1,10 @@ [info] name: Clients icons short_name: clients_icons -version: 7.2 +version: 7.3 description: Shows client icons in roster and in groupchats. authors: Denis Fomin <fominde@gmail.com> Artem Klyop <art.klyop@gmail.com> Thilo Molitor <thilo@eightysoft.de> homepage: https://dev.gajim.org/gajim/gajim-plugins/wikis/ClientsIconsPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/flashing_keyboard/flashing_keyboard.py b/flashing_keyboard/flashing_keyboard.py index 758bed1..16f084c 100644 --- a/flashing_keyboard/flashing_keyboard.py +++ b/flashing_keyboard/flashing_keyboard.py @@ -1,14 +1,18 @@ -# -*- coding: utf-8 -*- +import subprocess from gi.repository import Gtk from gi.repository import GObject -import subprocess from gajim.common import app from gajim.plugins import GajimPlugin -from gajim.plugins.helpers import log_calls, log +from gajim.plugins.helpers import log_calls from gajim.plugins.gui import GajimPluginConfigDialog +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass class FlashingKeyboard(GajimPlugin): @log_calls('FlashingKeyboard') diff --git a/flashing_keyboard/manifest.ini b/flashing_keyboard/manifest.ini index d03e91f..0c419c3 100644 --- a/flashing_keyboard/manifest.ini +++ b/flashing_keyboard/manifest.ini @@ -1,8 +1,8 @@ [info] name: Flashing Keyboard short_name: flashing_keyboard -version: 0.4 +version: 0.5 description: Flashing keyboard led when there are unread messages. authors: Denis Fomin <fominde@gmail.com> homepage: https://dev.gajim.org/gajim/gajim-plugins/wikis/flashingkeyboardplugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/gui_for_me/gui_for_me.py b/gui_for_me/gui_for_me.py index 494ff63..e6c7021 100644 --- a/gui_for_me/gui_for_me.py +++ b/gui_for_me/gui_for_me.py @@ -1,12 +1,15 @@ -# -*- coding: utf-8 -*- - from gi.repository import Gtk from gi.repository import GdkPixbuf from gajim.common import app from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log_calls -from gajim import gtkgui_helpers + +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass class GuiForMe(GajimPlugin): diff --git a/gui_for_me/manifest.ini b/gui_for_me/manifest.ini index 5e791ab..99256b1 100644 --- a/gui_for_me/manifest.ini +++ b/gui_for_me/manifest.ini @@ -1,10 +1,10 @@ [info] name: GUI For Me short_name: gui_for_me -version: 0.4 +version: 0.5 description: Adds a button for the '/me' command. authors: BomberMan copper Denis Fomin <fominde@gmail.com> homepage: http://trac-plugins.gajim.org/wiki/GUIForMePlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/hamster/hamster.py b/hamster/hamster.py index d4ff9a0..35c6c77 100644 --- a/hamster/hamster.py +++ b/hamster/hamster.py @@ -1,18 +1,23 @@ -# -*- coding: utf-8 -*- - +import os import dbus import datetime as dt + from gi.repository import GObject -import os from gajim.common import app from gajim.common import ged from gajim.common import dbus_support from gajim.plugins import GajimPlugin -from gajim.plugins.helpers import log_calls, log +from gajim.plugins.helpers import log_calls from gajim.common.pep import ACTIVITIES +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + HAMSTAER_INTERFACE = 'org.gnome.Hamster' SUBACTIVITIES = [] subactivity_ = [list(ACTIVITIES[x].keys()) for x in list(ACTIVITIES.keys())] diff --git a/hamster/manifest.ini b/hamster/manifest.ini index 851129a..40f5640 100644 --- a/hamster/manifest.ini +++ b/hamster/manifest.ini @@ -1,10 +1,10 @@ [info] name: Hamster integration short_name: hamster_integration -version: 0.1.4 +version: 0.1.5 description: Integration with project hamster see https://trac.gajim.org/ticket/6993 and http://projecthamster.wordpress.com/about/ authors: Denis Fomin <fominde@gmail.com> homepage: http://trac-plugins.gajim.org/wiki/ -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/image/image.py b/image/image.py index 654fd4e..9885e9f 100644 --- a/image/image.py +++ b/image/image.py @@ -10,6 +10,12 @@ from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log_calls from gajim.dialogs import ErrorDialog +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + try: from gajim.gtk.filechoosers import FileChooserDialog NEW_FILECHOOSER = True diff --git a/image/manifest.ini b/image/manifest.ini index 576fa83..73fdb58 100644 --- a/image/manifest.ini +++ b/image/manifest.ini @@ -1,7 +1,7 @@ [info] name: Image short_name: image -version: 1.0 +version: 1.1 description: This plugin is designed to send a small(0 - 40 kb) graphic image to your contact. Client on the other side must support XEP-0071: XHTML-IM and maintain the scheme data: URI. Psi+ and Jabbim supported this. diff --git a/juick/manifest.ini b/juick/manifest.ini index cc26245..19c2971 100644 --- a/juick/manifest.ini +++ b/juick/manifest.ini @@ -1,10 +1,10 @@ [info] name: Juick short_name: Juick -version: 0.9.8 +version: 0.9.9 description: Clickable Juick links , Juick nicks, preview Juick picturs. The key combination alt + up in the textbox allow insert the number of last message (comment or topic). authors: Denis Fomin <fominde@gmail.com> evgen <drujebober@gmail.com> homepage: http://trac-plugins.gajim.org/wiki/JuickPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/juick/plugin.py b/juick/plugin.py index 410b43b..5736cd0 100644 --- a/juick/plugin.py +++ b/juick/plugin.py @@ -1,25 +1,29 @@ -# -*- coding: utf-8 -*- +import re +import os +import time +import sqlite3 +import nbxmpp from gi.repository import Pango from gi.repository import Gtk from gi.repository import GdkPixbuf from gi.repository import Gdk -import re -import os -import time -import locale -import sqlite3 from gajim.common import helpers from gajim.common import app from gajim.common import configpaths from gajim.plugins import GajimPlugin -from gajim.plugins.helpers import log_calls, log +from gajim.plugins.helpers import log_calls from gajim.plugins.gui import GajimPluginConfigDialog from gajim.conversation_textview import TextViewImage from gajim import gtkgui_helpers -import nbxmpp + +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass class JuickPlugin(GajimPlugin): diff --git a/latex/latex.py b/latex/latex.py index 79dc666..465c9c9 100644 --- a/latex/latex.py +++ b/latex/latex.py @@ -21,22 +21,29 @@ ## -from threading import Thread + import os +import random +from tempfile import mkstemp, mkdtemp +from threading import Thread +from subprocess import Popen, PIPE + from gi.repository import Gtk from gi.repository import Gdk from gi.repository import GdkPixbuf from gi.repository import Pango from gi.repository import GObject -from tempfile import mkstemp, mkdtemp -import random -from subprocess import Popen, PIPE from gajim.common import app from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log, log_calls from gajim.plugins.gui import GajimPluginConfigDialog +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass def latex_template(code): return '''\\documentclass[12pt]{article} diff --git a/latex/manifest.ini b/latex/manifest.ini index 94f3bdc..126f8a2 100644 --- a/latex/manifest.ini +++ b/latex/manifest.ini @@ -7,3 +7,4 @@ authors: Yves Fischer <yvesf@xapek.org> Yann Leboulanger <asterix@lagaule.org> homepage: http://trac-plugins.gajim.org/wiki/LatexPlugin min_gajim_version: 1.0.0 +max_gajim_version: 1.0.3 diff --git a/length_notifier/length_notifier.py b/length_notifier/length_notifier.py index 3558039..20df647 100644 --- a/length_notifier/length_notifier.py +++ b/length_notifier/length_notifier.py @@ -24,15 +24,20 @@ Message length notifier plugin. :license: GPL ''' -import sys - from gi.repository import Gtk from gi.repository import Gdk from gajim.plugins import GajimPlugin -from gajim.plugins.helpers import log, log_calls +from gajim.plugins.helpers import log_calls from gajim.plugins.gui import GajimPluginConfigDialog +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + + class LengthNotifierPlugin(GajimPlugin): @log_calls('LengthNotifierPlugin') diff --git a/length_notifier/manifest.ini b/length_notifier/manifest.ini index 0f44e24..0259337 100644 --- a/length_notifier/manifest.ini +++ b/length_notifier/manifest.ini @@ -1,8 +1,8 @@ [info] name: Message Length Notifier short_name: length_notifier -version: 0.4 +version: 0.5 description: Highlights message entry field in chat window when given length of message is exceeded. authors = Mateusz Biliński <mateusz@bilinski.it> homepage = http://trac-plugins.gajim.org/wiki/LengthNotifierPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/message_box_size/manifest.ini b/message_box_size/manifest.ini index 9fcad00..8ea202d 100644 --- a/message_box_size/manifest.ini +++ b/message_box_size/manifest.ini @@ -1,8 +1,8 @@ [info] name: Message Box Size short_name: message_box_size -version: 0.4 +version: 0.5 description: Allows you to adjust the height of the new message input field. authors: Denis Fomin <fominde@gmail.com> homepage: http://trac-plugins.gajim.org/wiki/MessageBoxSizePlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/message_box_size/msg_box_size.py b/message_box_size/msg_box_size.py index c08d88b..cd9f7e6 100644 --- a/message_box_size/msg_box_size.py +++ b/message_box_size/msg_box_size.py @@ -1,12 +1,15 @@ -# -*- coding: utf-8 -*- - from gi.repository import Gtk -from gajim.common import app from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log_calls from gajim.plugins.gui import GajimPluginConfigDialog +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + class MsgBoxSizePlugin(GajimPlugin): @log_calls('MsgBoxSizePlugin') diff --git a/now_listen/manifest.ini b/now_listen/manifest.ini index 1c8270e..7b2b63c 100644 --- a/now_listen/manifest.ini +++ b/now_listen/manifest.ini @@ -1,7 +1,7 @@ [info] name: Now Listen short_name: now-listen -version: 0.3.2 +version: 0.3.3 description: Copy tune info of playing music to conversation input box at cursor position (Alt + N) authors = Denis Fomin <fominde@gmail.com> homepage = https://dev.gajim.org/gajim/gajim-plugins/wikis/NowListenPlugin diff --git a/now_listen/now_listen.py b/now_listen/now_listen.py index 68764e9..cbf85dd 100644 --- a/now_listen/now_listen.py +++ b/now_listen/now_listen.py @@ -1,9 +1,8 @@ -# -*- coding: utf-8 -*- +import os +import logging from gi.repository import Gtk from gi.repository import Gdk -import os -import logging from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log_calls @@ -11,6 +10,12 @@ from gajim.plugins.gui import GajimPluginConfigDialog from gajim.music_track_listener import MusicTrackListener +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + log = logging.getLogger('gajim.plugin_system.now_listen') diff --git a/omemo/ui.py b/omemo/ui.py index 2eeb6e8..18e0fec 100644 --- a/omemo/ui.py +++ b/omemo/ui.py @@ -43,6 +43,11 @@ from gajim.common import configpaths from gajim.dialogs import YesNoDialog
from gajim.plugins.gui import GajimPluginConfigDialog
+# Since Gajim 1.1.0 _() has to be imported
+try:
+ from gajim.common.i18n import _
+except ImportError:
+ pass
@unique
class State(IntEnum):
diff --git a/plugin_installer/manifest.ini b/plugin_installer/manifest.ini index 9cad22c..af30bd6 100644 --- a/plugin_installer/manifest.ini +++ b/plugin_installer/manifest.ini @@ -1,11 +1,11 @@ [info] name: Plugin Installer short_name: plugin_installer -version: 0.20.4 +version: 0.20.5 description: Install and upgrade plugins from ftp authors: Denis Fomin <fominde@gmail.com> Yann Leboulanger <asterix@lagaule.org> Thilo Molitor <thilo@eightysoft.de> Philipp Hörist <philipp@hoerist.com> homepage: https://dev.gajim.org/gajim/gajim-plugins/wikis/PluginInstallerPlugin -min_gajim_version: 0.16.10 +min_gajim_version: 1.0.0 diff --git a/plugin_installer/plugin_installer.py b/plugin_installer/plugin_installer.py index 36a7bf5..65b4643 100644 --- a/plugin_installer/plugin_installer.py +++ b/plugin_installer/plugin_installer.py @@ -55,6 +55,12 @@ except ImportError: from gajim.dialogs import WarningDialog, HigDialog, YesNoDialog from gajim.gtkgui_helpers import get_action +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + log = logging.getLogger('gajim.plugin_system.plugin_installer') PLUGINS_URL = 'https://ftp.gajim.org/plugins_1/' diff --git a/quick_replies/manifest.ini b/quick_replies/manifest.ini index 7d917e2..0dd8a81 100644 --- a/quick_replies/manifest.ini +++ b/quick_replies/manifest.ini @@ -1,8 +1,8 @@ [info] name: Quick replies short_name: quick_replies -version: 0.0.4 +version: 1.0.0 description: Plugin for quick insert template message and add your own template messages authors = Evgeniy Popov <evgeniypopov@gmail.com> homepage = https://dev.gajim.org/gajim/gajim-plugins/wikis/QuickRepliesPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/quick_replies/plugin.py b/quick_replies/plugin.py index 0ee6fcb..13cd594 100644 --- a/quick_replies/plugin.py +++ b/quick_replies/plugin.py @@ -1,13 +1,17 @@ from gi.repository import Gtk from gi.repository import GdkPixbuf -from gajim import gtkgui_helpers from gajim.common import app from gajim.plugins import GajimPlugin from gajim.plugins.gui import GajimPluginConfigDialog from gajim.plugins.helpers import log_calls +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass class QuickRepliesPlugin(GajimPlugin): diff --git a/regex_filter/manifest.ini b/regex_filter/manifest.ini index f8d1d3d..c829a01 100644 --- a/regex_filter/manifest.ini +++ b/regex_filter/manifest.ini @@ -1,8 +1,8 @@ [info] name: Regex Filter short_name: regex_filter -version: 0.4 +version: 0.5 description: Filter incoming messages using regex. authors: Yann Leboulanger <asterix@lagaule.org> homepage: http://trac-plugins.gajim.org/wiki/RegexFilterPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/regex_filter/regex_filter.py b/regex_filter/regex_filter.py index 6c53f6c..091b9d0 100644 --- a/regex_filter/regex_filter.py +++ b/regex_filter/regex_filter.py @@ -27,13 +27,20 @@ Regex Filter plugin. import re from gajim.plugins import GajimPlugin -from gajim.plugins.helpers import log, log_calls +from gajim.plugins.helpers import log_calls from gajim.common import app from gajim.common import ged from gajim.command_system.framework import CommandContainer, command, doc from gajim.command_system.implementation.hosts import * +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + + class RegexFilterPlugin(GajimPlugin): @log_calls('RegexFilterPlugin') diff --git a/roster_tweaks/manifest.ini b/roster_tweaks/manifest.ini index 62775d1..f01d4e5 100644 --- a/roster_tweaks/manifest.ini +++ b/roster_tweaks/manifest.ini @@ -1,9 +1,9 @@ [info] name: Roster Tweaks short_name: roster_tweaks -version: 1.0.0 +version: 1.0.1 description: Allows user to tweak roster window appearance (eg. make it compact). Added ability to quickly change the status message to all connected accounts. authors = Denis Fomin <fominde@gmail.com> homepage = http://trac-plugins.gajim.org/wiki/RosterTweaksPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/roster_tweaks/roster_tweaks.py b/roster_tweaks/roster_tweaks.py index f9e9e05..84167cc 100644 --- a/roster_tweaks/roster_tweaks.py +++ b/roster_tweaks/roster_tweaks.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - from gi.repository import Pango from gi.repository import Gtk from gi.repository import Gdk @@ -11,6 +9,12 @@ from gajim.plugins.gui import GajimPluginConfigDialog from gajim.dialogs import ChangeActivityDialog, ChangeMoodDialog from gajim import gtkgui_helpers +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + class RosterTweaksPlugin(GajimPlugin): def init(self): diff --git a/server_status_icons/manifest.ini b/server_status_icons/manifest.ini index 47d7bb4..baeab11 100644 --- a/server_status_icons/manifest.ini +++ b/server_status_icons/manifest.ini @@ -1,10 +1,10 @@ [info] name: Server Status Icons short_name: server_status_icons -version: 0.1.4 +version: 0.1.5 description: Replace standard Gajim status icons with server specific for known XMPP server accounts (vk.com, ...) authors = Denis Fomin <fominde@gmail.com> Pavel Suslov homepage = http://trac-plugins.gajim.org/wiki/ServerStatusIconsPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/server_status_icons/server_status_icons.py b/server_status_icons/server_status_icons.py index 1156900..50dd5db 100644 --- a/server_status_icons/server_status_icons.py +++ b/server_status_icons/server_status_icons.py @@ -1,8 +1,5 @@ -# -*- coding: utf-8 -*- -## import os -from gajim.plugins.gui import GajimPluginConfigDialog from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log_calls from gajim import gtkgui_helpers @@ -10,6 +7,11 @@ from gajim.common import app from gajim.common import helpers from gajim.common import ged +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass class ServerStatusIconsPlugin(GajimPlugin): diff --git a/set_location/manifest.ini b/set_location/manifest.ini index 743a93c..d6e928f 100644 --- a/set_location/manifest.ini +++ b/set_location/manifest.ini @@ -1,10 +1,10 @@ [info] name: Set Location short_name: set_location -version: 0.7.5 +version: 0.7.6 description: Set information about your current geographical or physical location. To be able to set your location on the built-in map, you must install gir1.2-gtkchamplain authors: Denis Fomin <fominde@gmail.com> Daniel Brötzmann <wurstsalat@posteo.de> homepage: https://dev.gajim.org/gajim/gajim-plugins/wikis/SetLocationPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/set_location/set_location.py b/set_location/set_location.py index 50d3f33..7dfddf6 100644 --- a/set_location/set_location.py +++ b/set_location/set_location.py @@ -1,13 +1,10 @@ -# -*- coding: utf-8 -*- -## - -from datetime import datetime -from gi.repository import Gtk -from gi.repository import GdkPixbuf -import gi import os import time import logging +from datetime import datetime + +import gi +from gi.repository import Gtk from gajim.plugins.gui import GajimPluginConfigDialog from gajim.plugins import GajimPlugin @@ -19,6 +16,12 @@ from gajim.common import configpaths from gajim import gtkgui_helpers from gajim.dialogs import InputDialog, WarningDialog +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + log = logging.getLogger('gajim.plugin_system.set_location') CHAMPLAIN_AVAILABLE = True diff --git a/tictactoe/manifest.ini b/tictactoe/manifest.ini index 401f8f5..d1350a5 100644 --- a/tictactoe/manifest.ini +++ b/tictactoe/manifest.ini @@ -1,7 +1,7 @@ [info] name: Tic tac toe short_name: Tic tac toe -version: 1.5 +version: 1.6 description: Play tic tac toe authors = Yann Leboulanger <asterix@lagaule.org> homepage = https://dev.gajim.org/gajim/gajim-plugins/wikis/TictactoePlugin diff --git a/tictactoe/plugin.py b/tictactoe/plugin.py index 5a04ee3..b0a9d90 100644 --- a/tictactoe/plugin.py +++ b/tictactoe/plugin.py @@ -49,6 +49,12 @@ from gajim.common import ged from gajim import dialogs from gajim.common.connection_handlers_events import InformationEvent +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + NS_GAMES = 'http://jabber.org/protocol/games' NS_GAMES_TICTACTOE = NS_GAMES + '/tictactoe' diff --git a/triggers/manifest.ini b/triggers/manifest.ini index 3d16b44..751aaf4 100644 --- a/triggers/manifest.ini +++ b/triggers/manifest.ini @@ -1,7 +1,7 @@ [info] name: Triggers short_name: triggers -version: 0.5 +version: 0.6 description: Configure Gajim's behaviour for each contact authors: Yann Leboulanger <asterix@lagaule.org> homepage: https://dev.gajim.org/gajim/gajim-plugins/wikis/TriggersPlugin diff --git a/triggers/triggers.py b/triggers/triggers.py index bef610c..1d96e90 100644 --- a/triggers/triggers.py +++ b/triggers/triggers.py @@ -31,6 +31,12 @@ from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log_calls from gajim.plugins.gui import GajimPluginConfigDialog +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + try: from gajim.gtk.filechoosers import NativeFileChooserDialog, Filter diff --git a/url_image_preview/config_dialog.py b/url_image_preview/config_dialog.py index d3d97d4..02faabb 100644 --- a/url_image_preview/config_dialog.py +++ b/url_image_preview/config_dialog.py @@ -23,6 +23,11 @@ from gi.repository import Gtk from gajim.options_dialog import OptionsDialog, GenericOption, SpinOption from gajim.common.const import Option, OptionType, OptionKind +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass class UrlImagePreviewConfigDialog(OptionsDialog): def __init__(self, plugin, parent): diff --git a/url_image_preview/http_functions.py b/url_image_preview/http_functions.py index d265078..fa4a88a 100644 --- a/url_image_preview/http_functions.py +++ b/url_image_preview/http_functions.py @@ -17,13 +17,19 @@ import urllib.request as urllib2 import socket -import re import ssl +import logging +import os from gajim.common import app -import logging -import os +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + + if os.name == 'nt': import certifi diff --git a/url_image_preview/manifest.ini b/url_image_preview/manifest.ini index 2889177..eebdbee 100644 --- a/url_image_preview/manifest.ini +++ b/url_image_preview/manifest.ini @@ -1,7 +1,7 @@ [info] name: Url image preview short_name: url_image_preview -version: 2.3.0 +version: 2.3.1 description: Displays a preview of links to images authors = Denis Fomin <fominde@gmail.com> Yann Leboulanger <asterix@lagaule.org> diff --git a/url_image_preview/url_image_preview.py b/url_image_preview/url_image_preview.py index e200400..073da1c 100644 --- a/url_image_preview/url_image_preview.py +++ b/url_image_preview/url_image_preview.py @@ -38,6 +38,12 @@ from url_image_preview.http_functions import get_http_head, get_http_file from url_image_preview.config_dialog import UrlImagePreviewConfigDialog from url_image_preview.resize_gif import resize_gif +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + try: from gajim.gtk.filechoosers import FileSaveDialog NEW_FILECHOOSER = True diff --git a/whiteboard/manifest.ini b/whiteboard/manifest.ini index ecb6310..24cad09 100644 --- a/whiteboard/manifest.ini +++ b/whiteboard/manifest.ini @@ -1,7 +1,7 @@ [info] name: Whiteboard short_name: whiteboard -version: 0.8 +version: 0.9 description: Shows a whiteboard in chat. python-pygoocanvas is required. authors = Yann Leboulanger <asterix@lagaule.org> homepage = https://dev.gajim.org/gajim/gajim-plugins/wikis/WhiteboardPlugin diff --git a/whiteboard/plugin.py b/whiteboard/plugin.py index 321baa7..bd7592a 100644 --- a/whiteboard/plugin.py +++ b/whiteboard/plugin.py @@ -34,7 +34,6 @@ from gajim.plugins import GajimPlugin from gajim.plugins.gajimplugin import GajimPluginException from gajim.plugins.helpers import log_calls, log from nbxmpp import Message -from gi.repository import Gtk from gi.repository import Gio from gi.repository import GLib from gajim import chat_control @@ -44,7 +43,12 @@ from gajim.common.jingle_content import JingleContent from gajim.common.jingle_transport import JingleTransport, TransportType from gajim import dialogs from .whiteboard_widget import Whiteboard, HAS_GOOCANVAS -from gajim.common import caps_cache + +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass NS_JINGLE_XHTML = 'urn:xmpp:tmp:jingle:apps:xhtml' NS_JINGLE_SXE = 'urn:xmpp:tmp:jingle:transports:sxe' diff --git a/whiteboard/whiteboard_widget.py b/whiteboard/whiteboard_widget.py index 0994963..49f3385 100644 --- a/whiteboard/whiteboard_widget.py +++ b/whiteboard/whiteboard_widget.py @@ -18,9 +18,17 @@ ## along with Gajim. If not, see <http://www.gnu.org/licenses/>. ## +from nbxmpp import Node from gi.repository import Gtk from gajim.common import app + +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass + try: import gi gi.require_version('GooCanvas', '2.0') @@ -28,7 +36,7 @@ try: HAS_GOOCANVAS = True except: HAS_GOOCANVAS = False -from nbxmpp import Node + try: from gajim.gtk.filechoosers import NativeFileChooserDialog, Filter diff --git a/wicd_support/manifest.ini b/wicd_support/manifest.ini index 4060fa9..4c9910c 100644 --- a/wicd_support/manifest.ini +++ b/wicd_support/manifest.ini @@ -1,9 +1,9 @@ [info] name: Wicd support short_name: wicd_support -version: 0.1.3 +version: 0.1.4 description: Support for autodetection of network status for Wicd Network Manager. Requires wicd and python-dbus. authors = Denis Fomin <fominde@gmail.com> homepage = http://trac-plugins.gajim.org/wiki/WicdSupportPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0 diff --git a/wicd_support/wicd_support.py b/wicd_support/wicd_support.py index e3d4dfd..f5440de 100644 --- a/wicd_support/wicd_support.py +++ b/wicd_support/wicd_support.py @@ -1,5 +1,3 @@ -# -*- coding: utf-8 -*- - import os from gajim.common import app @@ -7,6 +5,11 @@ from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log_calls from gajim.common import dbus_support +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass class WicdPlugin(GajimPlugin): @log_calls('WicdPlugin') diff --git a/wrong_layout/manifest.ini b/wrong_layout/manifest.ini index 2b3744b..b8c3416 100644 --- a/wrong_layout/manifest.ini +++ b/wrong_layout/manifest.ini @@ -1,8 +1,8 @@ [info] name: Wrong Layout short_name: Wrong Layout -version: 0.1.4 +version: 0.1.5 description: Press alt+r to convert chars typed in wrong layout Rus<>Eng authors: Denis Fomin <fominde@gmail.com> homepage: https://dev.gajim.org/gajim/gajim-plugins/wikis/WrongLayoutPlugin -min_gajim_version: 0.16.11 +min_gajim_version: 1.0.0
\ No newline at end of file diff --git a/wrong_layout/plugin.py b/wrong_layout/plugin.py index a5cf935..bf4530a 100644 --- a/wrong_layout/plugin.py +++ b/wrong_layout/plugin.py @@ -1,13 +1,16 @@ -# -*- coding: utf-8 -*- - from gi.repository import Gtk from gi.repository import Gdk -from gajim.common import helpers + from gajim.common import app from gajim.plugins import GajimPlugin from gajim.plugins.helpers import log_calls +# Since Gajim 1.1.0 _() has to be imported +try: + from gajim.common.i18n import _ +except ImportError: + pass class WrongLayoutPlugin(GajimPlugin): @log_calls('WrongLayoutPlugin') |