view src/djol/declare-style.js @ 20:9718e8de0cb2

Слияние
author nickolay
date Fri, 06 Oct 2017 09:17:41 +0300
parents f0035923ff3e
children 1d72fddc319a
line wrap: on
line source

define(["dojo/_base/declare","implab/safe"],function(declare, safe){
    return function(base, proto){
        var cls = declare(base,proto);
        
        var factory = function() {
            var me = this;
            cls.apply(me,arguments);
            var fn = function() {
                return me.getFeatureStyle.apply(me,arguments);
            };
            fn.style = me;
            fn.styleFunction = fn;
            return fn;
        };
        
        factory.styleClass = cls; 
        factory.prototype = cls.prototype;
        return factory;
    };
});