Changeset 1647
- Timestamp:
- 10/06/06 11:32:38 (2 years ago)
- Files:
-
- trunk/openlayers/lib/OpenLayers/BaseTypes.js (modified) (1 diff)
- trunk/openlayers/tests/list-tests.html (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/openlayers/lib/OpenLayers/BaseTypes.js
r1607 r1647 5 5 /* OpenLayers.Class metaclass */ 6 6 OpenLayers.Class = { 7 create: function() { 8 return function() { 9 this.initialize.apply(this, arguments); 7 isPrototype: function () {}, // magic anonymous value 8 9 create: function() { 10 return function() { 11 if (arguments && arguments[0] != OpenLayers.Class.isPrototype) 12 this.initialize.apply(this, arguments); 13 } 14 }, 15 16 inherit: function () { 17 var super = arguments[0]; 18 var proto = new super(OpenLayers.Class.isPrototype); 19 for (var i = 1; i < arguments.length; i++) { 20 if (typeof arguments[i] == "function") { 21 var mixin = arguments[i]; 22 arguments[i] = new mixin(OpenLayers.Class.isPrototype); 23 } 24 OpenLayers.Util.extend(proto, arguments[i]); 25 } 26 return proto; 10 27 } 11 } 12 }; 28 }; 29 30 /* 31 OpenLayers.Class.inherit( OpenLayers.Layer.Grid, OpenLayers.Layer.HTTPRequest, { 32 some stuff 33 }); 34 */ 13 35 14 36 /********************* trunk/openlayers/tests/list-tests.html
r1424 r1647 1 1 <ul id="testlist"> 2 <li>test_Class.html</li> 2 3 <li>test_Pixel.html</li> 3 4 <li>test_Size.html</li>
