Examples of JSObject


Examples of org.gwtopenmaps.openlayers.client.util.JSObject

  public StyleOptions(){
    this(JSObject.createJSObject());
  }
   
    public void addContextStyleCallback(String id, ContextStyler styler) {
        JSObject context = getJSObject().getProperty("context");
        if (context == null) {
            getJSObject().setProperty("context", JSObject.createJSObject());
            context = getJSObject().getProperty("context");
        }
        context.setProperty(id, StyleOptionsImpl.createContextStylerCallback(styler));
    }
View Full Code Here

Examples of org.gwtopenmaps.openlayers.client.util.JSObject

public class DrawFeatureOptions extends ControlOptions
{

    public void onFeatureAdded(FeatureAddedListener listener)
    {
        JSObject callback = DrawFeatureImpl.createFeatureAddedCallback(listener);
        getJSObject().setProperty("featureAdded", callback);
    }
View Full Code Here

Examples of org.gwtopenmaps.openlayers.client.util.JSObject

        getJSObject().setProperty("standalone", standalone);
    }

    public void onModificationStart(OnModificationStartListener listener)
    {
        JSObject callback = ModifyFeatureImpl.createOnModificationStartCallback(listener);
        getJSObject().setProperty("onModificationStart", callback);
    }
View Full Code Here

Examples of org.gwtopenmaps.openlayers.client.util.JSObject

        getJSObject().setProperty("onModificationStart", callback);
    }

    public void onModification(OnModificationListener listener)
    {
        JSObject callback = ModifyFeatureImpl.createOnModificationCallback(listener);
        getJSObject().setProperty("onModification", callback);
    }
View Full Code Here

Examples of org.gwtopenmaps.openlayers.client.util.JSObject

        getJSObject().setProperty("onModification", callback);
    }

    public void onModificationEnd(OnModificationEndListener listener)
    {
        JSObject callback = ModifyFeatureImpl.createOnModificationEndCallback(listener);
        getJSObject().setProperty("onModificationEnd", callback);
    }
View Full Code Here

Examples of org.gwtopenmaps.openlayers.client.util.JSObject

    }

    /** Creates a JS callback for a event type */
    private void createAndSetCallback(DragFeatureListener listener, String name)
    {
        JSObject callback = DragFeatureImpl.createDragCallback(listener);
        getJSObject().setProperty(name, callback);
    }
View Full Code Here

Examples of org.gwtopenmaps.openlayers.client.util.JSObject

    /**
     *
     */
    public void setScales(float[] scales) {
        // does this work?
        JSObject scaleArray = JSObject.createJSArray().cast();
        for (int i = 0, max = scales.length; i < max; i++) {
            scaleArray.setProperty(Integer.toString(i), scales[i]);
        }
        getJSObject().setProperty("scales", scaleArray);
    }
View Full Code Here

Examples of org.gwtopenmaps.openlayers.client.util.JSObject

    public Bounds() {
        this(BoundsImpl.create());
    }

    public double[] toArray() {
        JSObject boundsOpaque = BoundsImpl.toArray(getJSObject());
        JDoubleArray bounds = JDoubleArray.narrowToJDoubleArray(boundsOpaque);
        int boundsLength = bounds.length();
        double[] boundsCoordinates = new double[4];
        if (boundsLength == 4) {
            for (int i = 0; i < boundsLength; i++) {
View Full Code Here

Examples of org.gwtopenmaps.openlayers.client.util.JSObject

     * @param origin default is center
     * @return a new bounds that is scaled by ratio from origin
     */
    public Bounds scale(float ratio,
            Pixel origin) {
        JSObject originJsObj = (origin == null) ? null : origin.getJSObject();
        return Bounds.narrowToBounds(BoundsImpl.scale(this.getJSObject(), ratio,
                                                      originJsObj));
    }
View Full Code Here

Examples of org.gwtopenmaps.openlayers.client.util.JSObject

     * @param origin default is center
     * @return a new bounds that is scaled by ratio from origin
     */
    public Bounds scale(float ratio,
            LonLat origin) {
        JSObject originJsObj = (origin == null) ? null : origin.getJSObject();
        return Bounds.narrowToBounds(BoundsImpl.scale(this.getJSObject(), ratio,
                                                      originJsObj));
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.