info.bukova.isspst.ui.Mapa = zk.$extends(zk.Widget, {
    address : '', // default value
 
    getAddress : function() {
        return this.address;
    },
 
    setAddress : function(value) {
        if (this.address != value) {
            this.address = value;
            if (this.desktop) {
            	var myOptions = {
            		      zoom: 12,
            		      center: new google.maps.LatLng(-34.397, 150.644),
            		      mapTypeId: google.maps.MapTypeId.ROADMAP
            		    };

            		    var map = new google.maps.Map(this.$n(), myOptions);
            		    var geocoder = new google.maps.Geocoder();

            		    var request = {
            		      address: this.address
            		    };
            		    geocoder.geocode(request, function(results, status) {
            		      if (status == google.maps.GeocoderStatus.OK) {
            		        var marker = new google.maps.Marker({
            		          map: map,
            		          position: results[0].geometry.location
            		        });
            		        map.panTo(marker.getPosition());
            		      } else {
            		        window.console.log('failed to geocode address: '  + status);
            		      }
            		    });
            }
        }
    },
    
    redraw: function (out) {
    	 out.push('<div', this.domAttrs_(), '><div id="map_canvas">', this.getAddress(), '</div></span>');
    }
 
});