Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Define estilo rotate
- var symbolizerRotate = {
- "Point": {
- pointRadius: 20,
- externalGraphic: "http://200.19.215.119:8080/img/joao/bt-rotate.png",
- fillOpacity: 1,
- },
- };
- var styleRotate = new OpenLayers.Style();
- styleRotate.addRules([new OpenLayers.Rule({symbolizer: symbolizerRotate})]);
- var styleMapRotate = new OpenLayers.StyleMap({"default": styleRotate});
- //Define estilo resize
- var symbolizerResize = {
- "Point": {
- pointRadius: 20,
- externalGraphic: "http://200.19.215.119:8080/img/joao/bt-resize.png",
- fillOpacity: 1,
- },
- };
- var styleResize = new OpenLayers.Style();
- styleResize.addRules([new OpenLayers.Rule({symbolizer: symbolizerResize})]);
- var styleMapResize = new OpenLayers.StyleMap({"default": styleResize});
- function setPointOfControlSymbolizer(typeOfFeature, selectedControl, layer){
- var $map = $("#map");
- if(typeOfFeature != "POINT"){
- if (selectedControl == "rotate"){
- layer.styleMap = styleMapRotate;
- }
- if (selectedControl == "resize"){
- layer.styleMap = styleMapResize;
- }
- if (selectedControl == "move"){
- $map.css('cursor', 'url(http://200.19.215.119:8080/img/joao/bt-move.png), pointer;');
- }
- if (selectedControl == "delete"){
- $map.css('cursor', 'url(http://200.19.215.119:8080/img/joao/bt-delete.png), pointer;');
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement