Changeset 7823
- Timestamp:
- 08/22/08 05:23:14 (5 months ago)
- Files:
-
- sandbox/camptocamp/unhcr/lib/OpenLayers.js (modified) (1 diff)
- sandbox/camptocamp/unhcr/lib/OpenLayers/Layer.js (modified) (1 diff)
- sandbox/camptocamp/unhcr/lib/OpenLayers/Map.js (modified) (1 diff)
- sandbox/camptocamp/unhcr/lib/OpenLayers/Protocol (deleted)
- sandbox/camptocamp/unhcr/lib/OpenLayers/Protocol.js (modified) (8 diffs)
- sandbox/camptocamp/unhcr/tests/Control/DrawFeature.html (copied) (copied from trunk/openlayers/tests/Control/DrawFeature.html)
- sandbox/camptocamp/unhcr/tests/Format/GPX.html (copied) (copied from trunk/openlayers/tests/Format/GPX.html)
- sandbox/camptocamp/unhcr/tests/Protocol (deleted)
- sandbox/camptocamp/unhcr/tests/Strategy (copied) (copied from trunk/openlayers/tests/Strategy)
- sandbox/camptocamp/unhcr/tests/Strategy/Fixed.html (copied) (copied from trunk/openlayers/tests/Strategy/Fixed.html)
- sandbox/camptocamp/unhcr/tests/list-tests.html (modified) (1 diff)
- sandbox/camptocamp/unhcr/tools/update_dev_dir.sh (copied) (copied from trunk/openlayers/tools/update_dev_dir.sh)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
sandbox/camptocamp/unhcr/lib/OpenLayers.js
r7787 r7823 184 184 "OpenLayers/Strategy/Fixed.js", 185 185 "OpenLayers/Protocol.js", 186 "OpenLayers/Protocol/HTTP.js",187 186 "OpenLayers/Layer/PointTrack.js", 188 187 "OpenLayers/Layer/GML.js", sandbox/camptocamp/unhcr/lib/OpenLayers/Layer.js
r7822 r7823 58 58 * - *loadcancel* Triggered when layer loading is canceled. 59 59 * - *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"], 66 62 67 63 /** sandbox/camptocamp/unhcr/lib/OpenLayers/Map.js
r7788 r7823 1568 1568 if (inRange && layer.visibility) { 1569 1569 layer.moveTo(bounds, zoomChanged, dragging); 1570 layer.events.triggerEvent("moveend",1571 {"zoomChanged": zoomChanged}1572 );1573 1570 } 1574 1571 } sandbox/camptocamp/unhcr/lib/OpenLayers/Protocol.js
r7786 r7823 58 58 * Parameters: 59 59 * 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 passed64 * if one exists in the options object.65 60 */ 66 61 read: function() { … … 76 71 * {<OpenLayers.Feature.Vector>} 77 72 * 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 passed82 * if one exists in the options object.83 73 */ 84 74 create: function() { … … 93 83 * {<OpenLayers.Feature.Vector>} 94 84 * 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 passed99 * if one exists in the options object.100 85 */ 101 86 update: function() { … … 109 94 * feature - {<OpenLayers.Feature.Vector>} 110 95 * 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 passed115 * if one exists in the options object.116 96 */ 117 97 "delete": function() { … … 126 106 * Parameters: 127 107 * 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' 137 110 */ 138 111 commit: function() { … … 146 119 * Protocols return Response objects to their users. 147 120 */ 148 OpenLayers.Protocol.Response = OpenLayers.Class({121 OpenLayers.Protocol.Response = new OpenLayers.Class({ 149 122 /** 150 123 * Property: code 151 * { Number} - OpenLayers.Protocol.Response.SUCCESS or152 * OpenLayers.Protocol.Response.FAILURE124 * {Integer} - OpenLayers.Protocol.Response.SUCCESS or 125 * OpenLayers.Protocol.Response.FAILURE 153 126 */ 154 127 code: null, 155 156 /**157 * Property: requestType158 * {String} The type of request this response corresponds to. Either159 * "create", "read", "update" or "delete".160 */161 requestType: null,162 163 /**164 * Property: last165 * {Boolean} - true if this is the last response expected in a commit,166 * false otherwise, defaults to true.167 */168 last: true,169 128 170 129 /** … … 206 165 */ 207 166 success: function() { 208 return this.code > 0;167 return !!(this.code & OpenLayers.Protocol.Response.SUCCESS_MASK); 209 168 }, 210 169 … … 212 171 }); 213 172 214 OpenLayers.Protocol.Response.SUCCESS = 1; 215 OpenLayers.Protocol.Response.FAILURE = 0; 173 OpenLayers.Protocol.Response.SUCCESS_MASK = 0x000000ff; 174 OpenLayers.Protocol.Response.SUCCESS = 0x00000001; 175 176 OpenLayers.Protocol.Response.FAILURE_MASK = 0x0000ff00; 177 OpenLayers.Protocol.Response.FAILURE = 0x00000100; sandbox/camptocamp/unhcr/tests/list-tests.html
r7787 r7823 114 114 <li>Projection.html</li> 115 115 <li>Protocol.html</li> 116 <li>Protocol/HTTP.html</li>117 116 <li>Renderer.html</li> 118 117 <li>Renderer/Elements.html</li>
