Hello,
I've read some threads about .Bing tile zoom level mismatch issue, but
looks like it's already been fixed for OL 2.11 RC3 version?
We have the latest .Bing layer class in our repo, but zoom level seems
to be still mis-matching.
Our code to load the provider is this:
bbc.mtk.provider.Bing = OpenLayers.Class( bbc.mtk.Provider, {
/**
* Property: apiKeys
* Bing Maps API keys we have
*/
apiKeys: {
'localhost': 'KeyHere',
'www.bbc.co.uk': 'KeyHere ',
},
/**
* Method: load
* Loads the Bing Maps API and executes the callback when done
*
* Parameters:
* callback {Function}
*
*/
load: function( callback ) {
var self = this;
this.apiKey = this.getApiKey( location.href, this.apiKeys );
// nothing to load here
// the bing layer uses the BING rest api
setTimeout(function(){
self.isLoaded = true;
callback();
}, 10);
},
/**
* Method: getMapTypes
* Returns the supported map types and their values
*
* Returns:
* {Object}
*
*/
getMapTypes: function() {
return {
normal: 'Road',
satellite: 'Aerial',
hybrid: 'AerialWithLabels'
};
},
/**
* Method: getLayer
* Returns a new Bing Maps layer
*
* Parameters:
* mapType {String} - The map type to return (from getMapTypes())
*
* Returns:
* {<bbc.mtk.OpenLayers.Layer.Bing>}
*
*/
getLayer: function( mapType ) {
//mapType = mapType || Road;
mapType = mapType || 'Road';
return new OpenLayers.Layer.Bing({
key: this.apiKey,
type: mapType
});
},
/**
* Method: getMapObject
* Returns the Bing Maps object
*
* Returns:
* {BingMap}
*
*/
getMapObject: function( map ) {
return map.baseLayer.mapObject;
}
});
Am I missing anything here at all?
Any advice would be much appreciated.
Thanks
Takako
http://www.bbc.co.uk/
This e-mail (and any attachments) is confidential and may contain personal
views which are not the views of the BBC unless specifically stated.
If you have received it in error, please delete it from your system.
Do not use, copy or disclose the information in any way nor act in reliance on
it and notify the sender immediately.
Please note that the BBC monitors e-mails sent or received.
Further communication will signify your consent to this.
_______________________________________________
Users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users