7 var initializing = false, fnTest = /xyz/.test(function(){xyz;}) ? /\b_super\b/ : /.*/;
8 this.Class = function(){};
9 Class.extend = function(prop) {
10 var _super = this.prototype;
12 var prototype = new this();
14 for (var name in prop) {
15 prototype[name] = typeof prop[name] == "function" &&
16 typeof _super[name] == "function" && fnTest.test(prop[name]) ?
19 var tmp = this._super;
20 this._super = _super[name];
21 var ret = fn.apply(this, arguments);
25 })(name, prop[name]) :
29 if ( !initializing && this.init )
30 this.init.apply(this, arguments);
32 Class.prototype = prototype;
33 Class.constructor = Class;
34 Class.extend = arguments.callee;
40 var slice = Array.prototype.slice;
42 function update(array, args) {
43 var arrayLength = array.length, length = args.length;
44 while (length--) array[arrayLength + length] = args[length];
48 function merge(array, args) {
49 array = slice.call(array, 0);
50 return update(array, args);
53 Function.prototype.bind = function(context) {
54 if (arguments.length < 2 && typeof arguments[0] === 'undefined') {
58 var args = slice.call(arguments, 1);
60 var a = merge(args, arguments);
61 return __method.apply(context, a);
69 var splitView = new SplitView('#panels');