2007-01-18 22:24:27 +00:00
|
|
|
<%= include 'HEADER' %>
|
|
|
|
|
|
|
|
var Prototype = {
|
|
|
|
Version: '<%= PROTOTYPE_VERSION %>',
|
2007-02-19 22:23:10 +00:00
|
|
|
|
|
|
|
Browser: {
|
2008-07-17 20:22:18 +00:00
|
|
|
IE: !!(window.attachEvent &&
|
|
|
|
navigator.userAgent.indexOf('Opera') === -1),
|
|
|
|
Opera: navigator.userAgent.indexOf('Opera') > -1,
|
2007-02-19 22:23:10 +00:00
|
|
|
WebKit: navigator.userAgent.indexOf('AppleWebKit/') > -1,
|
2008-07-17 20:22:18 +00:00
|
|
|
Gecko: navigator.userAgent.indexOf('Gecko') > -1 &&
|
|
|
|
navigator.userAgent.indexOf('KHTML') === -1,
|
2007-10-08 17:30:40 +00:00
|
|
|
MobileSafari: !!navigator.userAgent.match(/Apple.*Mobile.*Safari/)
|
2007-02-19 22:23:10 +00:00
|
|
|
},
|
2007-04-24 03:31:14 +00:00
|
|
|
|
2007-01-18 22:24:27 +00:00
|
|
|
BrowserFeatures: {
|
2007-01-27 19:45:34 +00:00
|
|
|
XPath: !!document.evaluate,
|
2008-03-30 03:21:58 +00:00
|
|
|
SelectorsAPI: !!document.querySelector,
|
2007-01-27 19:45:34 +00:00
|
|
|
ElementExtensions: !!window.HTMLElement,
|
|
|
|
SpecificElementExtensions:
|
2008-05-05 07:37:43 +00:00
|
|
|
document.createElement('div')['__proto__'] &&
|
|
|
|
document.createElement('div')['__proto__'] !==
|
|
|
|
document.createElement('form')['__proto__']
|
2007-01-18 22:24:27 +00:00
|
|
|
},
|
2007-04-24 03:31:14 +00:00
|
|
|
|
2007-06-13 20:57:19 +00:00
|
|
|
ScriptFragment: '<script[^>]*>([\\S\\s]*?)<\/script>',
|
|
|
|
JSONFilter: /^\/\*-secure-([\s\S]*)\*\/\s*$/,
|
2007-04-24 03:31:14 +00:00
|
|
|
|
|
|
|
emptyFunction: function() { },
|
2007-01-18 22:24:27 +00:00
|
|
|
K: function(x) { return x }
|
2007-07-26 02:03:40 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
if (Prototype.Browser.MobileSafari)
|
|
|
|
Prototype.BrowserFeatures.SpecificElementExtensions = false;
|
2007-10-16 03:08:31 +00:00
|
|
|
|
2008-12-11 10:42:15 +00:00
|
|
|
var Abstract = { };
|
|
|
|
|
|
|
|
var Try = {
|
|
|
|
these: function() {
|
|
|
|
var returnValue;
|
|
|
|
|
|
|
|
for (var i = 0, length = arguments.length; i < length; i++) {
|
|
|
|
var lambda = arguments[i];
|
|
|
|
try {
|
|
|
|
returnValue = lambda();
|
|
|
|
break;
|
|
|
|
} catch (e) { }
|
|
|
|
}
|
|
|
|
|
|
|
|
return returnValue;
|
|
|
|
}
|
|
|
|
};
|
|
|
|
|
|
|
|
<%= include 'class.js', 'object.js', 'function.js', 'date.js', 'regexp.js', 'periodical_executer.js' %>
|
2007-01-18 22:24:27 +00:00
|
|
|
|
2008-12-11 10:42:15 +00:00
|
|
|
<%= include 'string.js', 'template.js' %>
|
2007-01-18 22:24:27 +00:00
|
|
|
|
2007-06-06 16:10:16 +00:00
|
|
|
<%= include 'enumerable.js', 'array.js', 'number.js', 'hash.js', 'range.js' %>
|
2007-01-18 22:24:27 +00:00
|
|
|
|
Merge -r6634:HEAD from ../branches/dom.
* Make Element#update and Element#insert work for SELECT tags in IE and Opera. [Tobie Langel]
* Make Element#insert and Element#update better handle TABLE related elements in IE and Opera. Closes #7776, #8040, #7550, #7776, #7938. [Tobie Langel]
* Make Element#readAttribute('title') work in Opera. [Tobie Langel]
* Make Element#replace work with form elements in Firefox and Safari. Closes #8010, #7989. [dsl239, Tobie Langel]
* Add Element#wrap which wraps the element inside a new one. Closes #5732. [P. Vande, Tobie Langel]
* Make Element into a constructor: new Element(tagName, attributes). Add Element#writeAttribute which accepts a hash of attributes or a name/value pair. Closes #7476. [Mislav Marohnić, haraldmartin, Tobie Langel]
* Insertion overhaul: Add Element.insert(content[, position = 'Bottom']). Deprecate Insertion (kept for backwards compatibility). Make Ajax.Updater option.insertion accept both Insertion.Top or the now preferred 'Top'. Closes #7907. [Tobie Langel]
2007-05-12 05:01:56 +00:00
|
|
|
<%= include 'ajax.js', 'dom.js', 'selector.js', 'form.js', 'event.js', 'deprecated.js' %>
|
2007-01-18 22:24:27 +00:00
|
|
|
|
|
|
|
Element.addMethods();
|