Revert "Allow for using a different set of default behaviors."

This reverts commit 3cc069186c.
This commit is contained in:
Éric Lemoine
2012-07-13 15:38:06 +02:00
parent f34aa03109
commit 2b9df6442b
8 changed files with 40 additions and 141 deletions
+2 -22
View File
@@ -88,12 +88,6 @@ ol.Map = function() {
* @type {Array}
*/
this.controls_ = null;
/**
* @private
* @type {ol.control.DefaultControl}
*/
this.defaultControl_ = null;
/**
* @private
@@ -163,7 +157,7 @@ ol.Map.DEFAULT_TILE_SIZE = 256;
@const
@type {Array.<string>}
*/
ol.Map.CONTROLS = ["navigation", "attribution", "zoom"];
ol.Map.DEFAULT_CONTROLS = ["attribution", "zoom"];
/**
* @return {ol.Loc} Map center in map projection.
@@ -449,20 +443,6 @@ ol.Map.prototype.addLayers = function(layers) {
};
/**
* @returns {ol.control.DefaultControl}
*/
ol.Map.prototype.getDefaultControl = function() {
return this.defaultControl_;
};
/**
* @param {ol.control.DefaultControl} control
*/
ol.Map.prototype.setDefaultControl = function(control) {
this.defaultControl_ = control;
};
/**
* @param {Array.<ol.control.Control>|undefined} opt_controls
*/
@@ -503,7 +483,7 @@ ol.Map.prototype.setContainer = function(container) {
this.createRenderer();
//TODO Controls could be set earlier, but we need to deal with content that
// controls place on overlays.
this.setControls(ol.Map.CONTROLS);
this.setControls(ol.Map.DEFAULT_CONTROLS);
// conditionally render
this.conditionallyRender();
};