MapButtonBar
Map button bar class
Example:
var button0 = new KQ.Control.MapButton('fa fa-globe fa-lg', function (btn, map) {
console.log('button 0 clicked!');
}, 'Press Button 0');
var button1 = new KQ.Control.MapButton('fa fa-bug fa-lg', function (btn, map) {
console.log('button 1 clicked!');
}, 'Press Button 1');
let bar = new KQ.Control.MapButtonBar([ button0, button1 ], { position: 'topright' });
bar.addTo(map);
Constructor Summary
Public Constructor | ||
public |
constructor(buttons: Array, options: Object) Constructor |
Method Summary
Public Methods | ||
public |
addToMapView(mapview: Object): Null Add bar to mapview |
|
public |
hide(): MapButtonBar Hide bar |
|
public |
remove(): Null Remove bar |
|
public |
setPosition(position: String): Null Set position of bar |
|
public |
show(): MapButtonBar Show bar |
Public Constructors
Public Methods
public addToMapView(mapview: Object): Null source
Add bar to mapview
Params:
Name | Type | Attribute | Description |
mapview | Object | mapview object |
Return:
Null |