OpenLayers OpenLayers

Changeset 7823

Show
Ignore:
Timestamp:
08/22/08 05:23:14 (5 months ago)
Author:
elemoine
Message:

camptocamp/unhcr sandbox = trunk (previous attempt was unsuccessful)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • sandbox/camptocamp/unhcr/lib/OpenLayers.js

    r7787 r7823  
    184184            "OpenLayers/Strategy/Fixed.js", 
    185185            "OpenLayers/Protocol.js", 
    186             "OpenLayers/Protocol/HTTP.js", 
    187186            "OpenLayers/Layer/PointTrack.js", 
    188187            "OpenLayers/Layer/GML.js", 
  • sandbox/camptocamp/unhcr/lib/OpenLayers/Layer.js

    r7822 r7823  
    5858     *  - *loadcancel* Triggered when layer loading is canceled. 
    5959     *  - *visibilitychanged* Triggered when layer visibility is changed. 
    60      *  - *moveend* Triggered when layer is moved, object passed as 
    61      *      argument has a zoomChanged boolean property which tells that the 
    62      *      zoom has changed. 
    63      */ 
    64     EVENT_TYPES: ["loadstart", "loadend", "loadcancel", "visibilitychanged", 
    65                   "moveend"], 
     60     */ 
     61    EVENT_TYPES: ["loadstart", "loadend", "loadcancel", "visibilitychanged"], 
    6662         
    6763    /** 
  • sandbox/camptocamp/unhcr/lib/OpenLayers/Map.js

    r7788 r7823  
    15681568                    if (inRange && layer.visibility) { 
    15691569                        layer.moveTo(bounds, zoomChanged, dragging); 
    1570                         layer.events.triggerEvent("moveend", 
    1571                             {"zoomChanged": zoomChanged} 
    1572                         ); 
    15731570                    } 
    15741571                }                 
  • sandbox/camptocamp/unhcr/lib/OpenLayers/Protocol.js

    r7786 r7823  
    5858     * Parameters: 
    5959     * options - {Object} Optional object for configuring the request. 
    60      * 
    61      * Returns: 
    62      * {<OpenLayers.Protocol.Response>} An <OpenLayers.Protocol.Response> 
    63      * object, the same object will be passed to the callback function passed 
    64      * if one exists in the options object. 
    6560     */ 
    6661    read: function() { 
     
    7671     *            {<OpenLayers.Feature.Vector>} 
    7772     * options - {Object} Optional object for configuring the request. 
    78      * 
    79      * Returns: 
    80      * {<OpenLayers.Protocol.Response>} An <OpenLayers.Protocol.Response> 
    81      * object, the same object will be passed to the callback function passed 
    82      * if one exists in the options object. 
    8373     */ 
    8474    create: function() { 
     
    9383     *            {<OpenLayers.Feature.Vector>} 
    9484     * options - {Object} Optional object for configuring the request. 
    95      * 
    96      * Returns: 
    97      * {<OpenLayers.Protocol.Response>} An <OpenLayers.Protocol.Response> 
    98      * object, the same object will be passed to the callback function passed 
    99      * if one exists in the options object. 
    10085     */ 
    10186    update: function() { 
     
    10994     * feature - {<OpenLayers.Feature.Vector>} 
    11095     * options - {Object} Optional object for configuring the request. 
    111      * 
    112      * Returns: 
    113      * {<OpenLayers.Protocol.Response>} An <OpenLayers.Protocol.Response> 
    114      * object, the same object will be passed to the callback function passed 
    115      * if one exists in the options object. 
    11696     */ 
    11797    "delete": function() { 
     
    126106     * Parameters: 
    127107     * features - {Array({<OpenLayers.Feature.Vector>})} 
    128      * optionsMap - {Object} Map of options, the keys of the map are 
    129      *              "create", "update", and "delete", the map itself 
    130      *              may also include a callback and a scope, which will 
    131      *              be used if none is provided in the "create", "update" 
    132      *              and "delete" options. 
    133      * 
    134      * Returns: 
    135      * {Array({<OpenLayers.Protocol.Response>})} An array of 
    136      * <OpenLayers.Protocol.Response> objects. 
     108     * options - {Object} Map of options, the keys of the map are 
     109     *           'create', 'update', and 'delete' 
    137110     */ 
    138111    commit: function() { 
     
    146119 * Protocols return Response objects to their users. 
    147120 */ 
    148 OpenLayers.Protocol.Response = OpenLayers.Class({ 
     121OpenLayers.Protocol.Response = new OpenLayers.Class({ 
    149122    /** 
    150123     * Property: code 
    151      * {Number} - OpenLayers.Protocol.Response.SUCCESS or 
    152      *            OpenLayers.Protocol.Response.FAILURE 
     124     * {Integer} - OpenLayers.Protocol.Response.SUCCESS or 
     125     *            OpenLayers.Protocol.Response.FAILURE 
    153126     */ 
    154127    code: null, 
    155  
    156     /** 
    157      * Property: requestType 
    158      * {String} The type of request this response corresponds to. Either 
    159      *      "create", "read", "update" or "delete". 
    160      */ 
    161     requestType: null, 
    162  
    163     /** 
    164      * Property: last 
    165      * {Boolean} - true if this is the last response expected in a commit, 
    166      * false otherwise, defaults to true. 
    167      */ 
    168     last: true, 
    169128 
    170129    /** 
     
    206165     */ 
    207166    success: function() { 
    208         return this.code > 0
     167        return !!(this.code & OpenLayers.Protocol.Response.SUCCESS_MASK)
    209168    }, 
    210169 
     
    212171}); 
    213172 
    214 OpenLayers.Protocol.Response.SUCCESS = 1; 
    215 OpenLayers.Protocol.Response.FAILURE = 0; 
     173OpenLayers.Protocol.Response.SUCCESS_MASK    = 0x000000ff; 
     174OpenLayers.Protocol.Response.SUCCESS         = 0x00000001; 
     175 
     176OpenLayers.Protocol.Response.FAILURE_MASK    = 0x0000ff00; 
     177OpenLayers.Protocol.Response.FAILURE         = 0x00000100; 
  • sandbox/camptocamp/unhcr/tests/list-tests.html

    r7787 r7823  
    114114    <li>Projection.html</li> 
    115115    <li>Protocol.html</li> 
    116     <li>Protocol/HTTP.html</li> 
    117116    <li>Renderer.html</li> 
    118117    <li>Renderer/Elements.html</li>