This commit is contained in:
2024-11-05 10:47:20 -07:00
parent c801b1ff51
commit 5315c47fcd
276 changed files with 2990 additions and 6370 deletions

View File

@@ -110,7 +110,7 @@ Sys.Extended.UI._CommonToolkitScripts.prototype = {
// "element" - DOM element
// "point" - Point object (of the form {x,y})
Sys.UI.DomElement.setLocation(element, point.x, point.y);
Sys.UI.DomElement.setLocation(element, Math.round(point.x), Math.round(point.y));
},
getContentSize: function(element) {
@@ -1008,6 +1008,28 @@ Sys.Extended.UI._CommonToolkitScripts.prototype = {
element.innerText = text;
else
element.textContent = text;
},
isMsBrowser: function () {
var edge = /edge/i.test(navigator.userAgent);
return Sys.Browser.agent === Sys.Browser.InternetExplorer
|| Sys.Browser.agent === null
|| edge;
},
isAppleBrowser: function () {
var ios = /iphone|ipad/i.test(navigator.userAgent);
var desktopSafari = window.safari && /Safari/.test(safari.pushNotification);
return ios || desktopSafari;
},
isInternetExplorer: function () {
if (Sys.Browser.agent == Sys.Browser.InternetExplorer //pre IE 11
||
(Sys.Browser.agent == null && Sys.Browser.name == "Netscape" && Sys.Browser.version == 5)) // IE 11
return true;
return false;
}
}
@@ -1231,16 +1253,6 @@ Sys.Extended.UI.ScrollBars.prototype = {
}
Sys.Extended.UI.ScrollBars.registerEnum("Sys.Extended.UI.ScrollBars", false);
var isUnminified = /param/.test(function(param) {});
Sys.Extended.Deprecated = function (oldMethodName, properMethodName) {
if (isUnminified && console && console.warn)
if(arguments.length == 1)
console.warn(oldMethodName + " is deprecated.");
else
console.warn(oldMethodName + " is deprecated. Use " + properMethodName + " instead.");
}
Sys.Extended.UI.zIndex = function() {};
Sys.Extended.UI.zIndex.BubbleChartTooltip = 10000;
Sys.Extended.UI.zIndex.ComboBoxList = 10000;
@@ -1251,4 +1263,13 @@ Sys.Extended.UI.zIndex.ModalPopupBackground = 10000;
Sys.Extended.UI.zIndex.PasswordStrengthTextDisplay = 10001;
Sys.Extended.UI.zIndex.Popup = 1000;
Sys.Extended.UI.zIndex.SeadragonContainer = 99999999;
Sys.Extended.UI.zIndex.SliderDragHandle = 999;
Sys.Extended.UI.zIndex.SliderDragHandle = 999;
Sys.Extended.UI.htmlEncode = function(text) {
return String(text)
.replace(/&/g, '&')
.replace(/"/g, '"')
.replace(/'/g, ''')
.replace(/</g, '&lt;')
.replace(/>/g, '&gt;');
};