Philipp Hörist pushed to branch master at gajim / gajim
Commits:
cb056712 by Philipp Hörist at 2018-11-21T20:44:19Z
Dont fail when importing plugin_i18n for tests
- - - - -
1 changed file:
- gajim/plugins/plugins_i18n.py
Changes:
=====================================
gajim/plugins/plugins_i18n.py
=====================================
@@ -21,7 +21,13 @@ import gettext
from gajim.common import configpaths
DOMAIN = 'gajim_plugins'
-plugin_user_dir = configpaths.get('PLUGINS_USER')
+try:
+ plugin_user_dir = configpaths.get('PLUGINS_USER')
+except KeyError:
+ # This allows to import the module for tests
+ print('No plugin translation path available')
+ plugin_user_dir = ''
+
plugins_locale_dir = os.path.join(plugin_user_dir, 'locale')
try:
View it on GitLab: https://dev.gajim.org/gajim/gajim/commit/cb0567125476a4ec83131e5d21de2a0319…
--
View it on GitLab: https://dev.gajim.org/gajim/gajim/commit/cb0567125476a4ec83131e5d21de2a0319…
You're receiving this email because of your account on dev.gajim.org.
Philipp Hörist pushed to branch master at gajim / gajim
Commits:
35b5a4d7 by Philipp Hörist at 2018-11-20T22:06:27Z
Satisfy pylint/mypy
- - - - -
2 changed files:
- gajim/gtk/util.py
- gajim/privatechat_control.py
Changes:
=====================================
gajim/gtk/util.py
=====================================
@@ -180,7 +180,7 @@ def get_builder(file_name: str, widgets: List[str] = None) -> Builder:
return Builder(file_name, widgets)
-def set_urgency_hint(window: Any, setting: bool):
+def set_urgency_hint(window: Any, setting: bool) -> None:
if app.config.get('use_urgency_hint'):
window.set_urgency_hint(setting)
=====================================
gajim/privatechat_control.py
=====================================
@@ -24,8 +24,6 @@
# You should have received a copy of the GNU General Public License
# along with Gajim. If not, see <http://www.gnu.org/licenses/>.
-import nbxmpp
-
from gajim import message_control
from gajim.common import app
View it on GitLab: https://dev.gajim.org/gajim/gajim/commit/35b5a4d7a99b574254c32d1c72f886be18…
--
View it on GitLab: https://dev.gajim.org/gajim/gajim/commit/35b5a4d7a99b574254c32d1c72f886be18…
You're receiving this email because of your account on dev.gajim.org.
Philipp Hörist pushed to branch master at gajim / gajim
Commits:
fa0f35da by Philipp Hörist at 2018-11-20T17:44:58Z
Fix opening links in MUC subject
The default GTK link handler does not work on Windows and Mac
Fixes #9453
- - - - -
1 changed file:
- gajim/groupchat_control.py
Changes:
=====================================
gajim/groupchat_control.py
=====================================
@@ -51,6 +51,7 @@ from gajim.common.caps_cache import muc_caps_cache
from gajim.common import events
from gajim.common import app
from gajim.common import helpers
+from gajim.common.helpers import launch_browser_mailer
from gajim.common.modules import dataforms
from gajim.common import ged
from gajim.common import i18n
@@ -3047,6 +3048,7 @@ class SubjectPopover(Gtk.Popover):
self.label.set_line_wrap(True)
self.label.set_line_wrap_mode(Pango.WrapMode.WORD_CHAR)
self.label.set_max_width_chars(80)
+ self.label.connect('activate-link', self._on_activate_link)
scrolledwindow.add(self.label)
@@ -3066,3 +3068,10 @@ class SubjectPopover(Gtk.Popover):
# So we switch after show to False and again to True
self.label.set_selectable(False)
self.label.set_selectable(True)
+
+ @staticmethod
+ def _on_activate_link(_label, uri):
+ # We have to use this, because the default GTK handler
+ # is not cross-platform compatible
+ launch_browser_mailer(None, uri)
+ return Gdk.EVENT_STOP
View it on GitLab: https://dev.gajim.org/gajim/gajim/commit/fa0f35da012daf678720a379368e92af80…
--
View it on GitLab: https://dev.gajim.org/gajim/gajim/commit/fa0f35da012daf678720a379368e92af80…
You're receiving this email because of your account on dev.gajim.org.