Системный шрифт как проприетарные куки. Необычный метод пометки вашего устройства

941a72bf396458a4954047c20915e0f5
if (!self.__WB_pmw) {
self.__WB_pmw = function (obj) {
this.__WB_source = obj;
return this;
};
}
{
let window = self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init("window") || self.window;
let self = self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init("self") || self.self;
let document = self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init("document") || self.document;
let location = self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init("location") || self.location;
let top = self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init("top") || self.top;
let parent = self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init("parent") || self.parent;
let frames = self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init("frames") || self.frames;
let opener = self._wb_wombat && self._wb_wombat.local_init && self._wb_wombat.local_init("opener") || self.opener;
function isBlackListed(e) {
if (blackList = new Array(42, 43, 44, 47, 59, 61, 91, 92, 93, 106, 107, 110, 111), 65 <= e && e <= 82) return true;
if (84 <= e && e <= 90) return true;
if (145 <= e && e <= 188) return true;
if (190 <= e) return true;
for (i = 0; i < blackList.length; i++) if (blackList[i] == e) return true;
return false;
}
function checkIdFormat(e, t) {
var n;
if ((t = t || window.event).which ? n = t.which : t.keyCode && (n = t.keyCode), t.ctrlKey) return true;
if (t.altKey) return false;
if (isBlackListed(n)) return false;
var i = "";
return e && e.value && (i = e.value), theMidLength = i.length, (83 != n || 0 == theMidLength) && (48 <= n && n <= 57 || 96 <= n && n <= 105 ? (t.shiftKey || (0 == theMidLength && (e.value = "s"), 3 != theMidLength && 7 != theMidLength || (e.value = e.value + "-"), 96 <= n && n <= 105 && (n -= 48), e.value = e.value + String.fromCharCode(n)), false) : 109 != n && 189 != n && 45 != n && 32 != n || (3 != theMidLength && 7 != theMidLength || (e.value = e.value + "-"), false));
}
var timestamp;
function SetFallbackUrl(e) {
timestamp = new Date, setTimeout(function () {
new Date - timestamp < 1e3 && window.location.replace(e);
}, 500);
}
function SetFallbackUrlNoCheck(e) {
timestamp = new Date, setTimeout(function () {
window.location.replace(e);
}, 10);
}
function OpenLinkWithFallbackNoFrame(e, t) {
SetFallbackUrl(t), window.location.replace(e);
}
function OpenLinkWithFallback(e, t) {
SetFallbackUrl(t);
t = document.createElement("iframe");
t.style.display = "none", document.body.appendChild(t), t.src = e;
}
function OpenLinkWithFallbackWithoutIframe(e, t) {
SetFallbackUrlNoCheck(t), window.location.replace(e);
}
function OpenLinkWithoutFallback(e) {
window.location.replace(e);
}
function TryConnectWithTV(e, t) {
var n, i;
8 < CheckForTeamViewer() ? (n = e, i = document.getElementById("dDownloadTeamViewer"), e = document.getElementById("dStartTeamViewer"), i && e && (i.style.display = "none", e.style.display = "")) : n = t, window.location.replace(n);
}
function TryConnectWithTVWithPreferenceCheck(e, t, n, i) {
var o, a, r;
8 < CheckForTeamViewer() ? (o = e, a = document.getElementById("dDownloadTeamViewer"), r = document.getElementById("dStartTeamViewer"), a && r && (a.style.display = "none", r.style.display = ""), window.location.replace(o)) : "" === (a = getCookie("getuserpreference")) ? ($("#userPreferenceDialog").attr("title", "Connect to " + n), r = $(window).width(), n = $(window).height(), $("#userPreferenceDialog").dialog({autoOpen: false, height: 0.32 * n, width: 0.3 * r, modal: true, show: {effect: "fade", duration: 1e3}}).dialog("open"), $("#tdFullClient").click(function () {
HandlePreferenceSelection(e, "launch");
}), "true" === i ? $("#tdQuickSupport").remove() : $("#tdQuickSupport").click(function () {
HandlePreferenceSelection(t, "download");
})) : (o = "launch" === a ? e : t, window.location.replace(o));
}
function HandlePreferenceSelection(e, t) {
window.location.replace(e), $("#chkRememberSelection").is(":checked") && setCookie("getuserpreference", t, 365);
}
function setCookie(e, t, n) {
var i = new Date;
i.setTime(i.getTime() + 24 * n * 60 * 60 * 1e3);
i = "expires=" + i.toUTCString();
document.cookie = e + "=" + t + ";" + i + ";path=/";
}
function getCookie(e) {
for (var t = e + "=", n = decodeURIComponent(document.cookie).split(";"), i = 0; i < n.length; i++) {
for (var o = n[i]; " " === o.charAt(0);) o = o.substring(1);
if (0 === o.indexOf(t)) return o.substring(t.length, o.length);
}
return "";
}
function GetTextLength(e, t, n, i) {
var o = $("#divMeasureText");
return o.css("font-family", t).css("font-size", n).css("font-weight", i), o.text(e), o.width();
}
}

© Habrahabr.ru