Update to scriptaculous 1.7.1_beta3. Props Nazgul. fixes #4512

git-svn-id: https://develop.svn.wordpress.org/trunk@5792 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2007-07-09 20:14:28 +00:00
parent bd75df9d1e
commit e99c75ddf5
11 changed files with 1165 additions and 380 deletions

View File

@ -1,4 +1,4 @@
Copyright (c) 2005, 2006 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
Permission is hereby granted, free of charge, to any person obtaining Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the a copy of this software and associated documentation files (the

View File

@ -1,4 +1,4 @@
// script.aculo.us builder.js v1.7.1_beta2, Sat Apr 28 15:20:12 CEST 2007 // script.aculo.us builder.js v1.7.1_beta3, Fri May 25 17:19:41 +0200 2007
// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) // Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
// //
@ -89,7 +89,7 @@ var Builder = {
var attrs = []; var attrs = [];
for(attribute in attributes) for(attribute in attributes)
attrs.push((attribute in this.ATTR_MAP ? this.ATTR_MAP[attribute] : attribute) + attrs.push((attribute in this.ATTR_MAP ? this.ATTR_MAP[attribute] : attribute) +
'="' + attributes[attribute].toString().escapeHTML() + '"'); '="' + attributes[attribute].toString().escapeHTML().gsub(/"/,'"') + '"');
return attrs.join(" "); return attrs.join(" ");
}, },
_children: function(element, children) { _children: function(element, children) {

View File

@ -1,4 +1,4 @@
// script.aculo.us controls.js v1.7.1_beta2, Sat Apr 28 15:20:12 CEST 2007 // script.aculo.us controls.js v1.7.1_beta3, Fri May 25 17:19:41 +0200 2007
// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) // Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
// (c) 2005-2007 Ivan Krstic (http://blogs.law.harvard.edu/ivan) // (c) 2005-2007 Ivan Krstic (http://blogs.law.harvard.edu/ivan)

View File

@ -1,4 +1,4 @@
// script.aculo.us dragdrop.js v1.7.1_beta2, Sat Apr 28 15:20:12 CEST 2007 // script.aculo.us dragdrop.js v1.7.1_beta3, Fri May 25 17:19:41 +0200 2007
// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) // Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
// (c) 2005-2007 Sammi Williams (http://www.oriontransfer.co.nz, sammi@oriontransfer.co.nz) // (c) 2005-2007 Sammi Williams (http://www.oriontransfer.co.nz, sammi@oriontransfer.co.nz)
@ -638,6 +638,12 @@ var Sortable = {
scrollSensitivity: 20, scrollSensitivity: 20,
scrollSpeed: 15, scrollSpeed: 15,
format: this.SERIALIZE_RULE, format: this.SERIALIZE_RULE,
// these take arrays of elements or ids and can be
// used for better initialization performance
elements: false,
handles: false,
onChange: Prototype.emptyFunction, onChange: Prototype.emptyFunction,
onUpdate: Prototype.emptyFunction onUpdate: Prototype.emptyFunction
}, arguments[1] || {}); }, arguments[1] || {});
@ -702,10 +708,9 @@ var Sortable = {
options.droppables.push(element); options.droppables.push(element);
} }
(this.findElements(element, options) || []).each( function(e) { (options.elements || this.findElements(element, options) || []).each( function(e,i) {
// handles are per-draggable var handle = options.handles ? $(options.handles[i]) :
var handle = options.handle ? (options.handle ? $(e).getElementsByClassName(options.handle)[0] : e);
$(e).down('.'+options.handle,0) : e;
options.draggables.push( options.draggables.push(
new Draggable(e, Object.extend(options_for_draggable, { handle: handle }))); new Draggable(e, Object.extend(options_for_draggable, { handle: handle })));
Droppables.add(e, options_for_droppable); Droppables.add(e, options_for_droppable);

View File

@ -1,4 +1,4 @@
// script.aculo.us effects.js v1.7.1_beta2, Sat Apr 28 15:20:12 CEST 2007 // script.aculo.us effects.js v1.7.1_beta3, Fri May 25 17:19:41 +0200 2007
// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) // Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
// Contributors: // Contributors:

File diff suppressed because it is too large Load Diff

View File

@ -1,4 +1,4 @@
// script.aculo.us scriptaculous.js v1.7.1_beta2, Sat Apr 28 15:20:12 CEST 2007 // script.aculo.us scriptaculous.js v1.7.1_beta3, Fri May 25 17:19:41 +0200 2007
// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) // Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
// //
@ -24,7 +24,7 @@
// For details, see the script.aculo.us web site: http://script.aculo.us/ // For details, see the script.aculo.us web site: http://script.aculo.us/
var Scriptaculous = { var Scriptaculous = {
Version: '1.7.1_beta2', Version: '1.7.1_beta3',
require: function(libraryName) { require: function(libraryName) {
// inserting via DOM fails in Safari 2.0, so brute force approach // inserting via DOM fails in Safari 2.0, so brute force approach
document.write('<script type="text/javascript" src="'+libraryName+'"></script>'); document.write('<script type="text/javascript" src="'+libraryName+'"></script>');

View File

@ -1,4 +1,4 @@
// script.aculo.us slider.js v1.7.1_beta2, Sat Apr 28 15:20:12 CEST 2007 // script.aculo.us slider.js v1.7.1_beta3, Fri May 25 17:19:41 +0200 2007
// Copyright (c) 2005-2007 Marty Haught, Thomas Fuchs // Copyright (c) 2005-2007 Marty Haught, Thomas Fuchs
// //

View File

@ -1,4 +1,4 @@
// script.aculo.us sound.js v1.7.1_beta2, Sat Apr 28 15:20:12 CEST 2007 // script.aculo.us sound.js v1.7.1_beta3, Fri May 25 17:19:41 +0200 2007
// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) // Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
// //

View File

@ -1,4 +1,4 @@
// script.aculo.us unittest.js v1.7.1_beta2, Sat Apr 28 15:20:12 CEST 2007 // script.aculo.us unittest.js v1.7.1_beta3, Fri May 25 17:19:41 +0200 2007
// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) // Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
// (c) 2005-2007 Jon Tirsen (http://www.tirsen.com) // (c) 2005-2007 Jon Tirsen (http://www.tirsen.com)

View File

@ -1,4 +1,6 @@
// Copyright (c) 2005 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) // script.aculo.us scriptaculous.js v1.7.1_beta3, Fri May 25 17:19:41 +0200 2007
// Copyright (c) 2005-2007 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us)
// //
// Permission is hereby granted, free of charge, to any person obtaining // Permission is hereby granted, free of charge, to any person obtaining
// a copy of this software and associated documentation files (the // a copy of this software and associated documentation files (the
@ -10,28 +12,44 @@
// //
// The above copyright notice and this permission notice shall be // The above copyright notice and this permission notice shall be
// included in all copies or substantial portions of the Software. // included in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
// For details, see the script.aculo.us web site: http://script.aculo.us/
var Scriptaculous = { var Scriptaculous = {
Version: '1.7.0', Version: '1.7.1_beta3',
require: function(libraryName) { require: function(libraryName) {
// inserting via DOM fails in Safari 2.0, so brute force approach // inserting via DOM fails in Safari 2.0, so brute force approach
document.write('<script type="text/javascript" src="'+libraryName+'"></script>'); document.write('<script type="text/javascript" src="'+libraryName+'"></script>');
}, },
REQUIRED_PROTOTYPE: '1.5.1',
load: function() { load: function() {
function convertVersionString(versionString){
var r = versionString.split('.');
return parseInt(r[0])*100000 + parseInt(r[1])*1000 + parseInt(r[2]);
}
if((typeof Prototype=='undefined') || if((typeof Prototype=='undefined') ||
(typeof Element == 'undefined') || (typeof Element == 'undefined') ||
(typeof Element.Methods=='undefined') || (typeof Element.Methods=='undefined') ||
parseFloat(Prototype.Version.split(".")[0] + "." + (convertVersionString(Prototype.Version) <
Prototype.Version.split(".")[1]) < 1.5) convertVersionString(Scriptaculous.REQUIRED_PROTOTYPE)))
throw("script.aculo.us requires the Prototype JavaScript framework >= 1.5.0"); throw("script.aculo.us requires the Prototype JavaScript framework >= " +
Scriptaculous.REQUIRED_PROTOTYPE);
$A(document.getElementsByTagName("script")).findAll( function(s) { $A(document.getElementsByTagName("script")).findAll( function(s) {
return (s.src && s.src.match(/scriptaculous\.js(\?.*)?$/)) return (s.src && s.src.match(/scriptaculous\.js(\?.*)?$/))
}).each( function(s) { }).each( function(s) {
var path = s.src.replace(/scriptaculous\.js(\?.*)?$/,''); var path = s.src.replace(/scriptaculous\.js(\?.*)?$/,'');
var includes = s.src.match(/\?.*load=([a-z,]*)/); var includes = s.src.match(/\?.*load=([a-z,]*)/);
if ( includes ) (includes ? includes[1] : 'builder,effects,dragdrop,controls,slider,sound').split(',').each(
includes[1].split(',').each(
function(include) { Scriptaculous.require(path+include+'.js') }); function(include) { Scriptaculous.require(path+include+'.js') });
}); });
} }