1. // File: adb-popup.js
  2. loader([{
  3. type: "$",
  4. value: "#abPopup"
  5. }, {
  6. type: "component",
  7. value: "GeneralOverlay"
  8. }, {
  9. type: "$",
  10. value: window
  11. }]).ready(function (a, b, c) {
  12. function d() {
  13. c.off(), window.refresher_stream = function () {}
  14. }
  15. function e() {
  16. b.show({
  17. closeEnabled: !1,
  18. $popup: a,
  19. center: !0
  20. }).getEl().before('<div class="topBarOverlay"></div>'), h.find("#topAlertBarContainer").remove()
  21. }
  22. function f() {
  23. function a() {
  24. var a = window.navigator.userAgent,
  25. b = a.indexOf("Trident/"),
  26. c = a.indexOf("Edge/"),
  27. d = a.indexOf("MSIE ");
  28. return Math.max(d, c, b) > 0
  29. }
  30. var a = a(),
  31. b = /Chrome/.test(navigator.userAgent) && /Google Inc/.test(navigator.vendor) && !a,
  32. c = /Firefox/.test(navigator.userAgent),
  33. d = /Safari/.test(navigator.userAgent) && /Apple Computer/.test(navigator.vendor),
  34. e = {
  35. isIE: a,
  36. isChrome: b,
  37. isFireFox: c,
  38. isSafari: d,
  39. isOneOfThoseBrowsers: [a, b, c, d].indexOf(!0) > -1
  40. },
  41. f = window.CDN_URL + "/",
  42. g = window.LANGUAGE_SUFFIX,
  43. h = [f + "header_logo.png"];
  44. switch ([a, b, c, d].indexOf(!0)) {
  45. case 0:
  46. h.push(f + "ab-ie.png");
  47. break;
  48. case 1:
  49. h.push(f + "ab-ch-" + g + "-step1_v3.1.png"), h.push(f + "ab-ch-" + g + "-step2_v3.1.png");
  50. break;
  51. case 2:
  52. h.push(f + "ab-ff-" + g + "_v2.png");
  53. break;
  54. case 3:
  55. h.push(f + "ab-saf-" + g + "_v2.png")
  56. }
  57. return e.refs = h, e
  58. }
  59. function g(a) {
  60. n.each(function (c) {
  61. var d = n.eq(c);
  62. d.hasClass(a) ? (d.addClass("active"), k.attr("src", i.refs[c + 1]).one("load", b.centerPopup)) : d.removeClass("active")
  63. })
  64. }
  65. var h = this,
  66. i = f();
  67. if (i.isOneOfThoseBrowsers && 1 != window.google_ad_status) {
  68. var j = $("#ab-how-pop"),
  69. k = $("#ab-content-src");
  70. i.refs && i.refs[0] && $("#ab-header-src").attr("src", i.refs[0]), i.refs && i.refs[1] && k.attr("src", i.refs[1]);
  71. var l = a.find(".js-intro"),
  72. m = a.find(".headerLinks"),
  73. n = a.find(".js-toggle-btn");
  74. a.find(".js-chrome-ext").click(function () {
  75. l.addClass("displayNone"), i.isChrome ? g("js-chrome-ext") : m.addClass("displayNone"), a.addClass("howTo"), j.removeClass("displayNone"), b.centerPopup()
  76. }), a.find(".js-adbp").click(function () {
  77. l.addClass("displayNone"), g("js-adbp"), a.addClass("howTo"), b.centerPopup()
  78. }), e(), d(), c.resize(b.centerPopup)
  79. }
  80. });

https://forums.lanik.us/viewtopic.php?p=99835#p99835