diff --git a/app/js/services.js b/app/js/services.js index 3c3c3e32..8a34e783 100755 --- a/app/js/services.js +++ b/app/js/services.js @@ -4737,11 +4737,6 @@ angular.module('myApp.services', ['myApp.i18n', 'izhukov.utils']) !target.onclick && !target.onmousedown) { var href = $(target).attr('href') || target.href || '' - if (Config.Modes.chrome_packed && - href.length && - $(target).attr('target') == '_blank') { - $(target).attr('rel', '') - } var match = href.match(tgAddrRegExp) if (match) { if (handleTgProtoAddr(match[3], true)) { @@ -4751,6 +4746,19 @@ angular.module('myApp.services', ['myApp.i18n', 'izhukov.utils']) } }) + $(document).on('mousedown', function (event) { + var target = event.target + if (target && + target.tagName == 'A') { + var href = $(target).attr('href') || target.href || '' + if (Config.Modes.chrome_packed && + href.length && + $(target).attr('target') == '_blank') { + $(target).attr('rel', '') + } + } + }) + $rootScope.$on('$routeUpdate', checkLocationTgAddr) checkLocationTgAddr() }