Ticket #1013: clone.2.patch
| File clone.2.patch, 3.5 kB (added by euzuro, 1 year ago) |
|---|
-
tests/Layer/test_MapServer.html
old new 399 399 t.eq(parseFloat(tLayer.div.firstChild.firstChild.style.opacity), 0.6, "Opacity on tile is changed correctly"); 400 400 401 401 } 402 403 // DEPRECATED -- REMOVE IN 3.0 404 function test_Layer_Untiled_MapServer(t) { 405 t.plan(1); 406 407 var layer = new OpenLayers.Layer.MapServer.Untiled(); 408 409 var clone = layer.clone(); 410 411 t.ok(clone.singleTile, "regression test: clone works. this is for #1013"); 412 } 402 413 403 414 function test_99_Layer_MapServer_Untiled_destroy (t) { 404 415 -
tests/Layer/test_WMS.html
old new 352 352 map.destroy(); 353 353 354 354 } 355 356 // DEPRECATED -- REMOVE IN 3.0 357 function test_Layer_Untiled_WMS(t) { 358 t.plan(1); 359 360 var layer = new OpenLayers.Layer.WMS.Untiled(); 361 362 var clone = layer.clone(); 363 364 t.ok(clone.singleTile, "regression test: clone works. this is for #1013"); 365 } 355 366 356 367 function test_99_Layer_WMS_destroy (t) { 357 368 -
lib/OpenLayers/Layer/MapServer/Untiled.js
old new 40 40 OpenLayers.Console.warn(msg); 41 41 }, 42 42 43 /** 44 * Method: clone 45 * Create a clone of this layer 46 * 47 * Returns: 48 * {<OpenLayers.Layer.MapServer.Untiled>} An exact clone of this layer 49 */ 50 clone: function (obj) { 51 52 if (obj == null) { 53 obj = new OpenLayers.Layer.MapServer.Untiled(this.name, 54 this.url, 55 this.params, 56 this.options); 57 } 58 59 //get all additions from superclasses 60 obj = OpenLayers.Layer.MapServer.prototype.clone.apply(this, [obj]); 61 62 // copy/set any non-init, non-simple values here 63 64 return obj; 65 }, 66 43 67 CLASS_NAME: "OpenLayers.Layer.MapServer.Untiled" 44 68 }); -
lib/OpenLayers/Layer/WMS/Untiled.js
old new 40 40 OpenLayers.Console.warn(msg); 41 41 }, 42 42 43 /** 44 * Method: clone 45 * Create a clone of this layer 46 * 47 * Returns: 48 * {<OpenLayers.Layer.WMS.Untiled>} An exact clone of this layer 49 */ 50 clone: function (obj) { 51 52 if (obj == null) { 53 obj = new OpenLayers.Layer.WMS.Untiled(this.name, 54 this.url, 55 this.params, 56 this.options); 57 } 58 59 //get all additions from superclasses 60 obj = OpenLayers.Layer.WMS.prototype.clone.apply(this, [obj]); 61 62 // copy/set any non-init, non-simple values here 63 64 return obj; 65 }, 66 43 67 CLASS_NAME: "OpenLayers.Layer.WMS.Untiled" 44 68 });
