[OpenLayers-Dev] Re: lib evaluation performance

Eric Lemoine eric.lemoine at camptocamp.com
Tue Nov 2 13:44:25 EDT 2010


> Hi,
>
> And more... 2.x code can be compatible with pure JavaScript. It is only
> necessary:
>
> var A = function () {...} / / constructor
> A.prototype = {
>     ...
>     initialize: function () { // * Deprecated *
>         A.apply(this, arguments);
>     }
> }, / / Prototype definition

That's correct. Yet, we already have a compatibility layer in the 2.x
branch (with OpenLayers.Class.inherit), so I'd prefer to not introduce
another one, especially given that we wouldn't gain much from it. It's
a different story for 3.x—with OpenLayers.inherit it doesn't make
sense to keep OpenLayers.Class in my opinion.

Thanks jorix,

-- 
Eric Lemoine

Camptocamp France SAS
Savoie Technolac, BP 352
73377 Le Bourget du Lac, Cedex

Tel : 00 33 4 79 44 44 96
Mail : eric.lemoine at camptocamp.com
http://www.camptocamp.com


More information about the Dev mailing list