temporarily store the original initialize instead of tacking anything extra on to the handler's prototype - thanks for the catch Erik - I'm trashing the oldInit just so we don't end up with any more unexpected prototype modifications elsewhere in the test
git-svn-id: http://svn.openlayers.org/trunk/openlayers@3701 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -9,8 +9,7 @@
|
||||
var callbacks = {foo: "bar"};
|
||||
var options = {bar: "foo"};
|
||||
|
||||
OpenLayers.Handler.prototype._initialize =
|
||||
OpenLayers.Handler.prototype.initialize;
|
||||
var oldInit = OpenLayers.Handler.prototype.initialize;
|
||||
|
||||
OpenLayers.Handler.prototype.initialize = function(con, call, opt) {
|
||||
t.eq(con.id, control.id,
|
||||
@@ -22,9 +21,7 @@
|
||||
}
|
||||
var drag = new OpenLayers.Handler.Drag(control, callbacks, options);
|
||||
|
||||
OpenLayers.Handler.prototype.initialize =
|
||||
OpenLayers.Handler.prototype._initialize;
|
||||
|
||||
OpenLayers.Handler.prototype.initialize = oldInit;
|
||||
}
|
||||
|
||||
function test_Handler_Drag_activate(t) {
|
||||
|
||||
Reference in New Issue
Block a user