Update Bootstrap to not fail when overriding existing beans or getter / setters.

This commit is contained in:
Jürg Lehni 2011-02-16 00:18:08 +00:00
parent b0b9594f1e
commit 00ee00d6ac

View file

@ -16,7 +16,6 @@
* where deemeded necessary.
* See http://www.bootstrap-js.net/wiki/MootoolsDifferences
*/
new function() {
var fix = !this.__proto__ && [Function, Number, Boolean, String, Array, Date, RegExp];
if (fix)
@ -53,13 +52,11 @@ new function() {
}
function inject(dest, src, enumerable, base, preserve, generics) {
var beans;
var beans, bean;
function field(name, val, dontCheck, generics) {
if (!val)
val = (val = describe(src, name)) && (val.get ? val : val.value);
var type = typeof val, func = type == 'function', res = val,
prev = dest[name], bean, part;
var val = val || (val = describe(src, name)) && (val.get ? val : val.value),
func = typeof val == 'function', res = val, prev = val && val.get ? null : dest[name];
if (generics && func && (!preserve || !generics[name])) generics[name] = function(bind) {
return bind && dest[name].apply(bind,
Array.prototype.slice.call(arguments, 1));