diff --git a/toxygen/mainscreen.py b/toxygen/mainscreen.py
index 92733fd..f1648d3 100644
--- a/toxygen/mainscreen.py
+++ b/toxygen/mainscreen.py
@@ -65,6 +65,7 @@ class MainWindow(QtGui.QMainWindow, Singleton):
self.audioSettings = QtGui.QAction(Form)
self.pluginData = QtGui.QAction(Form)
self.importPlugin = QtGui.QAction(Form)
+ self.reloadPlugins = QtGui.QAction(Form)
self.lockApp = QtGui.QAction(Form)
self.menuProfile.addAction(self.actionAdd_friend)
self.menuProfile.addAction(self.actionSettings)
@@ -77,6 +78,7 @@ class MainWindow(QtGui.QMainWindow, Singleton):
self.menuSettings.addAction(self.updateSettings)
self.menuPlugins.addAction(self.pluginData)
self.menuPlugins.addAction(self.importPlugin)
+ self.menuPlugins.addAction(self.reloadPlugins)
self.menuAbout.addAction(self.actionAbout_program)
self.profile_button.setMenu(self.menuProfile)
@@ -96,6 +98,7 @@ class MainWindow(QtGui.QMainWindow, Singleton):
self.pluginData.triggered.connect(self.plugins_menu)
self.lockApp.triggered.connect(self.lock_app)
self.importPlugin.triggered.connect(self.import_plugin)
+ self.reloadPlugins.triggered.connect(self.reload_plugins)
Form.setLayout(box)
QtCore.QMetaObject.connectSlotsByName(Form)
@@ -140,6 +143,7 @@ class MainWindow(QtGui.QMainWindow, Singleton):
d = {0: 0, 1: 1, 2: 2, 3: 4, 1 | 4: 4, 2 | 4: 5}
self.online_contacts.setCurrentIndex(d[ind])
self.importPlugin.setText(QtGui.QApplication.translate("MainWindow", "Import plugin", None, QtGui.QApplication.UnicodeUTF8))
+ self.reloadPlugins.setText(QtGui.QApplication.translate("MainWindow", "Reload plugins", None, QtGui.QApplication.UnicodeUTF8))
def setup_right_bottom(self, Form):
Form.resize(650, 60)
@@ -460,6 +464,13 @@ class MainWindow(QtGui.QMainWindow, Singleton):
self.update_s = UpdateSettings()
self.update_s.show()
+ def reload_plugins(self):
+ plugin_loader = plugin_support.PluginLoader.get_instance()
+ if plugin_loader is None:
+ return
+ plugin_loader.stop()
+ plugin_loader.load()
+
def import_plugin(self):
import util
directory = QtGui.QFileDialog.getExistingDirectory(self,
@@ -599,10 +610,12 @@ class MainWindow(QtGui.QMainWindow, Singleton):
block_item = self.listMenu.addAction(QtGui.QApplication.translate("MainWindow", 'Block friend', None, QtGui.QApplication.UnicodeUTF8))
notes_item = self.listMenu.addAction(QtGui.QApplication.translate("MainWindow", 'Notes', None, QtGui.QApplication.UnicodeUTF8))
- submenu = plugin_support.PluginLoader.get_instance().get_menu(self.listMenu, num)
- if len(submenu):
- plug = self.listMenu.addMenu(QtGui.QApplication.translate("MainWindow", 'Plugins', None, QtGui.QApplication.UnicodeUTF8))
- plug.addActions(submenu)
+ plugins_loader = plugin_support.PluginLoader.get_instance()
+ if plugins_loader is not None:
+ submenu = plugins_loader.get_menu(self.listMenu, num)
+ if len(submenu):
+ plug = self.listMenu.addMenu(QtGui.QApplication.translate("MainWindow", 'Plugins', None, QtGui.QApplication.UnicodeUTF8))
+ plug.addActions(submenu)
self.connect(set_alias_item, QtCore.SIGNAL("triggered()"), lambda: self.set_alias(num))
self.connect(remove_item, QtCore.SIGNAL("triggered()"), lambda: self.remove_friend(num))
self.connect(block_item, QtCore.SIGNAL("triggered()"), lambda: self.block_friend(num))
diff --git a/toxygen/translations/en_GB.ts b/toxygen/translations/en_GB.ts
index 6036f81..0a9871d 100644
--- a/toxygen/translations/en_GB.ts
+++ b/toxygen/translations/en_GB.ts
@@ -84,47 +84,47 @@ can produce IP leak
MainWindow
-
+ Profile
-
+ Settings
-
+ About
-
+ Add contact
-
+ Privacy
-
+ Interface
-
+ Notifications
-
+ Network
-
+ About program
@@ -140,32 +140,32 @@ can produce IP leak
-
+ Choose fileChoose file
-
+ Disallow auto accept
-
+ Allow auto accept
-
+ Set alias
-
+ Clear history
-
+ Remove friend
@@ -175,7 +175,7 @@ can produce IP leak
Enter new alias for friend {} or leave empty to use friend's name:
-
+ AudioAudio
@@ -190,7 +190,7 @@ can produce IP leak
Friend added
-
+ Toxygen is Tox client written on Python.
Version: Toxygen is Tox client written on Python.
@@ -202,7 +202,7 @@ Version:Friend added without sending friend request
-
+ Choose folderChoose folder
@@ -217,22 +217,22 @@ Version:
Send file
-
+ Send messageSend message
-
+ Start audio call with friendStart audio call with friend
-
+ Plugins
-
+ List of plugins
@@ -242,22 +242,22 @@ Version:
-
+ All
-
+ Online
-
+ Notes
-
+ Notes about user
@@ -317,32 +317,32 @@ Version:
-
+ Lock
-
+ Cannot lock app
-
+ Error. Profile password is not set.
-
+ Name
-
+ Status message
-
+ Public key
@@ -367,22 +367,22 @@ Version:
-
+ Import plugin
-
+ Choose folder with plugin
-
+ Restart Toxygen
-
+ Plugin will be loaded after restart
@@ -392,42 +392,42 @@ Version:
-
+ Chat history
-
+ Export as text
-
+ Export as HTML
-
+ Updates
-
+ Online first
-
+ Online and by name
-
+ Online first and by name
-
+ Block friend
@@ -441,6 +441,11 @@ Version:
Text "{}" was not found
+
+
+ Reload plugins
+
+ MenuWindow
diff --git a/toxygen/translations/fr_FR.ts b/toxygen/translations/fr_FR.ts
index 0e87b51..16f37e7 100644
--- a/toxygen/translations/fr_FR.ts
+++ b/toxygen/translations/fr_FR.ts
@@ -84,47 +84,47 @@ can produce IP leak
MainWindow
-
+ ProfileProfile
-
+ SettingsParamêtres
-
+ AboutÀ Propos
-
+ Add contactRajouter un contact
-
+ PrivacyConfidentialité
-
+ InterfaceInterface
-
+ NotificationsNotifications
-
+ NetworkRéseau
-
+ About programÀ propos du programme
@@ -145,27 +145,27 @@ can produce IP leak
Toxygen est un client Tox écris en Python 2.7. Version :
-
+ Choose fileChoisir un fichier
-
+ Disallow auto acceptDésactiver l'auto-réception
-
+ Allow auto acceptActiver l'auto-réception
-
+ Set aliasDéfinir un alias
-
+ Clear historyVider l'historique
@@ -175,7 +175,7 @@ can produce IP leak
Copier la clé publique
-
+ Remove friendRetirer un ami
@@ -185,7 +185,7 @@ can produce IP leak
Entrez un nouvel alias pour l'ami {} ou laissez vide pour garder son nom de base :
-
+ AudioAudio
@@ -200,7 +200,7 @@ can produce IP leak
Ami rajouté
-
+ Toxygen is Tox client written on Python.
Version: Toxygen est un client Tox écrit en Python.
@@ -212,7 +212,7 @@ Version :Ami rajouté sans avoir envoyé de demande
-
+ Choose folderChoisir le dossier
@@ -227,22 +227,22 @@ Version :
Envoyer le fichier
-
+ Send messageEnvoyer le message
-
+ Start audio call with friendLancer un appel audio avec un ami
-
+ Plugins
-
+ List of plugins
@@ -252,22 +252,22 @@ Version :
-
+ All
-
+ Online
-
+ Notes
-
+ Notes about user
@@ -327,32 +327,32 @@ Version :
-
+ Lock
-
+ Cannot lock app
-
+ Error. Profile password is not set.
-
+ Name
-
+ Status message
-
+ Public key
@@ -377,22 +377,22 @@ Version :
-
+ Import plugin
-
+ Choose folder with plugin
-
+ Restart Toxygen
-
+ Plugin will be loaded after restart
@@ -402,42 +402,42 @@ Version :
-
+ Chat historyHistorique de chat
-
+ Export as text
-
+ Export as HTML
-
+ Updates
-
+ Online first
-
+ Online and by name
-
+ Online first and by name
-
+ Block friend
@@ -451,6 +451,11 @@ Version :
Text "{}" was not found
+
+
+ Reload plugins
+
+ MenuWindow
diff --git a/toxygen/translations/ru_RU.qm b/toxygen/translations/ru_RU.qm
index ae4bf08..25507b2 100644
Binary files a/toxygen/translations/ru_RU.qm and b/toxygen/translations/ru_RU.qm differ
diff --git a/toxygen/translations/ru_RU.ts b/toxygen/translations/ru_RU.ts
index edb79d5..52bffa4 100644
--- a/toxygen/translations/ru_RU.ts
+++ b/toxygen/translations/ru_RU.ts
@@ -87,47 +87,47 @@ can produce IP leak
MainWindow
-
+ ProfileПрофиль
-
+ SettingsНастройки
-
+ AboutО программе
-
+ Add contactДобавить контакт
-
+ PrivacyПриватность
-
+ InterfaceИнтерфейс
-
+ NotificationsУведомления
-
+ NetworkСеть
-
+ About programО программе
@@ -144,27 +144,27 @@ can produce IP leak
Запрос на добавление в друзья
-
+ Choose fileВыберите файл
-
+ Disallow auto acceptЗапретить автоматическое получение файлов
-
+ Allow auto acceptРазрешить автоматическое получение файлов
-
+ Set aliasИзменить псевдоним
-
+ Clear historyОчистить историю
@@ -174,7 +174,7 @@ can produce IP leak
Копировать публичный ключ
-
+ Remove friendУдалить друга
@@ -184,7 +184,7 @@ can produce IP leak
Введите новый псевдоним для друга {} или оставьте пустым для использования его имени:
-
+ AudioАудио
@@ -199,7 +199,7 @@ can produce IP leak
Друг добавлен
-
+ Toxygen is Tox client written on Python.
Version: Toxygen - клиент для мессенджера Tox, написанный на Python. Версия:
@@ -210,7 +210,7 @@ Version:
Друг добавлен без отправки запроса на добавление в друзья
-
+ Choose folderВыбрать папку
@@ -225,22 +225,22 @@ Version:
Отправить файл
-
+ Send messageОтправить сообщение
-
+ Start audio call with friendНачать аудиозвонок с другом
-
+ PluginsПлагины
-
+ List of pluginsСписок плагинов
@@ -250,22 +250,22 @@ Version:
Поиск
-
+ AllВсе
-
+ OnlineОнлайн
-
+ NotesЗаметки
-
+ Notes about userЗаметки о пользователе
@@ -325,32 +325,32 @@ Version:
Удалить сообщение
-
+ LockЗаблокировать
-
+ Cannot lock appНевозможно заблокировать приложение
-
+ Error. Profile password is not set.Ошибка. Пароль профиля не установлен.
-
+ NameИмя
-
+ Status messageСтатус
-
+ Public keyПубличный ключ
@@ -375,22 +375,22 @@ Version:
Выберите папку с паком смайлов
-
+ Import pluginИмпортировать плагин
-
+ Choose folder with pluginВыберите папку с плагином
-
+ Restart ToxygenПерезапустите Toxygen
-
+ Plugin will be loaded after restartПлагин будет загружен после перезапуска
@@ -400,42 +400,42 @@ Version:
Цитировать выбранный текст
-
+ Chat historyИстория чата
-
+ Export as textЭкспортировать как текст
-
+ Export as HTMLЭкспортировать как HTML
-
+ UpdatesОбновления
-
+ Online firstСначала онлайн
-
+ Online and by nameОнлайн и по имени
-
+ Online first and by nameСначала онлайн и по имени
-
+ Block friendЗаблокировать друга
@@ -449,6 +449,11 @@ Version:
Text "{}" was not foundТекст "{}" не был найден
+
+
+ Reload plugins
+ Перезагрузить плагины
+ MenuWindow