deactivate on clear. r=bartvde (closes #2471)
git-svn-id: http://svn.openlayers.org/trunk/openlayers@10114 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -129,8 +129,6 @@ OpenLayers.Control.NavigationHistory = OpenLayers.Class(OpenLayers.Control, {
|
||||
"moveend": this.getState
|
||||
}, this.registry);
|
||||
|
||||
this.clear();
|
||||
|
||||
var previousOptions = {
|
||||
trigger: OpenLayers.Function.bind(this.previousTrigger, this),
|
||||
displayClass: this.displayClass + " " + this.displayClass + "Previous"
|
||||
@@ -145,6 +143,7 @@ OpenLayers.Control.NavigationHistory = OpenLayers.Class(OpenLayers.Control, {
|
||||
OpenLayers.Util.extend(nextOptions, this.nextOptions);
|
||||
this.next = new OpenLayers.Control.Button(nextOptions);
|
||||
|
||||
this.clear();
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -280,7 +279,9 @@ OpenLayers.Control.NavigationHistory = OpenLayers.Class(OpenLayers.Control, {
|
||||
*/
|
||||
clear: function() {
|
||||
this.previousStack = [];
|
||||
this.previous.deactivate();
|
||||
this.nextStack = [];
|
||||
this.next.deactivate();
|
||||
},
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user