Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Changeset 3302

Show
Ignore:
Timestamp:
12/13/05 18:43:00 (3 years ago)
Author:
madrobby
Message:

script.aculo.us: V1.5.0 final, includes Prototype 1.4.0 final

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • spinoffs/scriptaculous/CHANGELOG

    r3286 r3302  
     1*V1.5.0* 
     2 
     3* Prepared for V1.5.0 final 
     4 
     5* Update lib/prototype.js to Prototype 1.4.0 final 
     6 
    17*V1.5.0_rc6* 
    28 
  • spinoffs/scriptaculous/lib/prototype.js

    r3286 r3302  
    1 /*  Prototype JavaScript framework, version 1.4.0_rc4 
     1/*  Prototype JavaScript framework, version 1.4.0 
    22 *  (c) 2005 Sam Stephenson <sam@conio.net> 
    33 * 
     
    1212 
    1313var Prototype = { 
    14   Version: '1.4.0_rc4', 
     14  Version: '1.4.0', 
    1515  ScriptFragment: '(?:<script.*?>)((\n|\r|.)*?)(?:<\/script>)', 
    1616 
     
    4747} 
    4848 
    49 Function.prototype.bind = function(object) { 
    50   var __method = this
     49Function.prototype.bind = function() { 
     50  var __method = this, args = $A(arguments), object = args.shift()
    5151  return function() { 
    52     return __method.apply(object, arguments); 
     52    return __method.apply(object, args.concat($A(arguments))); 
    5353  } 
    5454} 
     
    394394}); 
    395395var $A = Array.from = function(iterable) { 
     396  if (!iterable) return []; 
    396397  if (iterable.toArray) { 
    397398    return iterable.toArray(); 
     
    455456  reverse: function(inline) { 
    456457    return (inline !== false ? this : this.toArray())._reverse(); 
     458  }, 
     459 
     460  shift: function() { 
     461    var result = this[0]; 
     462    for (var i = 0; i < this.length - 1; i++) 
     463      this[i] = this[i + 1]; 
     464    this.length--; 
     465    return result; 
    457466  }, 
    458467 
     
    12541263    var parameter = Form.Element.Serializers[method](element); 
    12551264 
    1256     if (parameter) 
    1257       return encodeURIComponent(parameter[0]) + '=' + 
    1258         encodeURIComponent(parameter[1]); 
     1265    if (parameter) { 
     1266      var key = encodeURIComponent(parameter[0]); 
     1267      if (key.length == 0) return; 
     1268 
     1269      if (parameter[1].constructor != Array) 
     1270        parameter[1] = [parameter[1]]; 
     1271 
     1272      return parameter[1].map(function(value) { 
     1273        return key + '=' + encodeURIComponent(value); 
     1274      }).join('&'); 
     1275    } 
    12591276  }, 
    12601277 
  • spinoffs/scriptaculous/Rakefile

    r3286 r3302  
    55PKG_NAME        = 'scriptaculous-js' 
    66PKG_BUILD       = ENV['PKG_BUILD'] ? '.' + ENV['PKG_BUILD'] : '' 
    7 PKG_VERSION     = '1.5_rc6' + PKG_BUILD 
     7PKG_VERSION     = '1.5.0' + PKG_BUILD 
    88PKG_FILE_NAME   = "#{PKG_NAME}-#{PKG_VERSION}" 
    99PKG_DESTINATION = ENV["RAILS_PKG_DESTINATION"] || "dist" 
  • spinoffs/scriptaculous/src/scriptaculous.js

    r3286 r3302  
    2121 
    2222var Scriptaculous = { 
    23   Version: '1.5_rc6', 
     23  Version: '1.5.0', 
    2424  require: function(libraryName) { 
    2525    // inserting via DOM fails in Safari 2.0, so brute force approach