fix drag handler test for IE. for whatever reason, ie and ff handle the tests in different order. because IE runs through the functions numerically, the constructor test is run first, and so the changes to the handler's initialize are maintained throughout the rest of the tests. thus, we need to make sure to set it back before exiting.
git-svn-id: http://svn.openlayers.org/trunk/openlayers@3698 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -8,6 +8,10 @@
|
||||
control.id = Math.random();
|
||||
var callbacks = {foo: "bar"};
|
||||
var options = {bar: "foo"};
|
||||
|
||||
OpenLayers.Handler.prototype._initialize =
|
||||
OpenLayers.Handler.prototype.initialize;
|
||||
|
||||
OpenLayers.Handler.prototype.initialize = function(con, call, opt) {
|
||||
t.eq(con.id, control.id,
|
||||
"constructor calls parent with the correct control");
|
||||
@@ -17,6 +21,10 @@
|
||||
"constructor calls parent with the correct options");
|
||||
}
|
||||
var drag = new OpenLayers.Handler.Drag(control, callbacks, options);
|
||||
|
||||
OpenLayers.Handler.prototype.initialize =
|
||||
OpenLayers.Handler.prototype._initialize;
|
||||
|
||||
}
|
||||
|
||||
function test_Handler_Drag_activate(t) {
|
||||
|
||||
Reference in New Issue
Block a user