public static Pixel narrowToPixel(JSObject element) { return (element == null)? null: new Pixel(element); }
public int y() { return PixelImpl.getY(this.getJSObject()); }
public Pixel getPixel() { return Pixel.narrowToPixel(getJSObject().getProperty("xy")); } }
/** * @return the center of the bounds in pixel space */ public Pixel getCenterPixel() { return Pixel.narrowToPixel(BoundsImpl.getCenterPixel(this.getJSObject())); }
public int y() { return PixelImpl.getY(this.getJSObject()); }
public static Pixel narrowToPixel(JSObject element) { return (element == null)? null: new Pixel(element); }
public Pixel getMousePosition(Event event) { return Pixel.narrowToPixel(EventsImpl.getMousePosition(getJSObject(), event.getJSObject())); }
public String toString() { return PixelImpl.toString(getJSObject()); } }
public Pixel getPixelFromLonLat(LonLat lonlat) { return new Pixel(MapImpl.getPixelFromLonLat(getJSObject(), lonlat.getJSObject())); }
public LonLat getLonLat(){ Map map = Map.narrowToMap(this.getSourceJSObject()); Pixel pixel = Pixel.narrowToPixel(getJSObject().getProperty("xy")); return (pixel != null)? map.getLonLatFromPixel(pixel):null; } }
public String toString() { return PixelImpl.toString(getJSObject()); } }
public Pixel getPixelFromLonLat (LonLat lonlat) { return new Pixel(MapImpl.getPixelFromLonLat(getJSObject(), lonlat.getJSObject())); }
public LonLat getLonLat() { Map map = Map.narrowToMap(this.getSourceJSObject()); Pixel pixel = Pixel.narrowToPixel(getJSObject().getProperty("xy")); return (pixel != null) ? map.getLonLatFromPixel(pixel) : null; }
public int x() { return PixelImpl.getX(this.getJSObject()); }
/** * APIMethod: getLayerPxFromLonLat * * Parameters: * * @param lonlat {<OpenLayers.LonLat>} lonlat * * @return {<OpenLayers.Pixel>} An OpenLayers.Pixel which is the passed-in * <OpenLayers.LonLat>, translated into layer pixels by the current base * layer */ public Pixel getLayerPxFromLonLat(LonLat lonlat) { return new Pixel(MapImpl.getLayerPxFromLonLat(getJSObject(), lonlat.getJSObject())); }
public int x() { return PixelImpl.getX(this.getJSObject()); }
public Pixel getScreenPixel() { return new Pixel(MouseEventImpl.clientX(getJSObject()), MouseEventImpl.clientY(getJSObject())); }
/** * Method: moveTo * * @param px - {<OpenLayers.Pixel>} the top and left position of the popup * div. */ public void moveTo(Pixel px) { PopupImpl.moveTo(getJSObject(), px.getJSObject()); }
@Override public void onHandle(EventObject eventObject) { if (OpenlayersMarker.this.popup != null) { map.removePopup(OpenlayersMarker.this.popup); } Pixel pixel = new Pixel(0, 0); Size size = new Size(300, 200); FramedCloud frame = new FramedCloud("marker-info", OpenlayersMarker.this.coords, size, OpenlayersMarker.this.infoTxt, new Icon("", new Size(0, 0), pixel), true); OpenlayersMarker.this.setPopup(frame); map.addPopup(OpenlayersMarker.this.popup); } };
public void moveTo(Pixel where) { MarkerImpl.moveTo(getJSObject(), where.getJSObject()); } }