Advertisement
Guest User

Untitled

a guest
Feb 6th, 2016
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. var features = new ol.Collection(),
  2. layer = new ol.layer.Vector({
  3. source: new ol.source.Vector({features: features}),
  4. style: function(feature, resolution){
  5. console.log("called it"); // <-- called twice for each feature
  6. return getStyle(feature);
  7. }
  8. });
  9. map.addLayer(layer);
  10. var draw = new ol.interaction.Draw({
  11. features: features,
  12. type: (geomType)
  13. });
  14. map.addInteraction(draw);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement