void SetMapType (int type)
		{
			if (type == 0) {
				RemoveTile ();
				_map.MapType = GoogleMap.MapTypeNormal;
			}
			if (type == 1) {
				RemoveTile ();
				_map.MapType = GoogleMap.MapTypeSatellite;
			}
			if (type == 2) {
				RemoveTile ();
				_map.MapType = GoogleMap.MapTypeTerrain;
			}
			if (type == 3) {
				RemoveTile ();
				_map.MapType = GoogleMap.MapTypeHybrid;
			}
			if (type == 4) {
				RemoveTile ();
				var tileOptions = new TileOverlayOptions ();
				_tileOverlay = _map.AddTileOverlay (tileOptions.InvokeTileProvider (_osmTileLayer));
				_map.MapType = GoogleMap.MapTypeNone;
			}
			if (type == 5) {
				RemoveTile ();
				var tileOptions = new TileOverlayOptions ();
				_tileOverlay = _map.AddTileOverlay (tileOptions.InvokeTileProvider (_ocmTileLayer));
				_map.MapType = GoogleMap.MapTypeNone;
			}
			if (type == 6) {
				RemoveTile ();
				_map.MapType = GoogleMap.MapTypeNone;
			}
		}
        private void UpdateOverlay(bool programatic = false)
        {
            if (!programatic)
            {
                if (_selectedTile == null)
                {
                    _selectedTile = StaticResources.TilesList.First;
                }
                _selectedTile = _selectedTile.Next;
                if (_selectedTile == null)
                {
                    _selectedTile = StaticResources.TilesList.First;
                }
            }

            // if google map, just remove the previous overlay 
            if (_selectedTile.Value.NativeMapLayer)
            {
                if (_selectedTile.Value.Name == StaticResources.TilesHybridName)
                {
                    _map.MapType = GoogleMap.MapTypeHybrid;
                }
                else
                {
                    _map.MapType = GoogleMap.MapTypeNormal;
                }
                if (_selectedTileOverlay != null)
                {
                    _selectedTileOverlay.Remove();
                }
                _maxZoom = (int)_map.MaxZoomLevel;
            }
            else
            {
                _maxZoom = _selectedTile.Value.MaxZoom;
                if (_maxZoom == 0)
                {
                    _maxZoom = (int)_map.MaxZoomLevel;
                }
                if (_map.CameraPosition.Zoom > _maxZoom)
                {
                    _map.MoveCamera(CameraUpdateFactory.ZoomTo(_maxZoom));
                }

                CustomUrlTileProvider mTileProvider = new CustomUrlTileProvider(
                            _selectedTile.Value.TileSize,
                            _selectedTile.Value.TileSize, _selectedTile.Value.TilesUrl);
                var options = new TileOverlayOptions();
                options.InvokeTileProvider(mTileProvider);
                options.InvokeZIndex(-1);
                if (_selectedTileOverlay != null)
                {
                    _selectedTileOverlay.Remove();
                }
                _map.MapType = GoogleMap.MapTypeNone;
                _selectedTileOverlay = _map.AddTileOverlay(options);

            }

            _selectedTileName = _selectedTile.Value.Name;
            if (!programatic)
            {
                _currentTileName.Text = _selectedTile.Value.Name;
                _currentTileName.StartAnimation(_currentTileNameAnimation);
                _currentTileName.Visibility = Android.Views.ViewStates.Visible;
            }
        }