public MapControlFactoryOSMOffline()
            : base()
        {
            _mapFilesHandler = new OSMBinMap.MapFilesHandler(this);
            _bitmapStore = new BitmapStoreOSMOffline(_mapFilesHandler);
            _searchProvider = new SearchProviderOSM();
            _tileGenerator = new TileGeneratorOSM(this);
            _tilePanel = new TilePanel(this);

            OSMBinFilesVisibility = Visibility.Visible;
        }
Ejemplo n.º 2
0
 public MapCanvas()
 {
     _mapControlFactory = UIControls.Maps.Control.MapControlFactoryToUse;
     if (_mapControlFactory != null)
     {
         _offsetX = _mapControlFactory.GetMapOffset(_translate.GetType().GetProperty("X"), this.OnOffsetChanged);
         _offsetY = _mapControlFactory.GetMapOffset(_translate.GetType().GetProperty("Y"), this.OnOffsetChanged);
         _tilePanel = _mapControlFactory.TilePanel;
         _tilePanel.RenderTransform = _translate;
     }
     this.Background = Brushes.Transparent; // Register all mouse clicks
     this.Children.Add(_cache);
     if (_mapControlFactory != null)
     {
         this.Children.Add(_tilePanel);
     }
     this.ClipToBounds = true;
     this.Focusable = true;
     this.FocusVisualStyle = null;
     this.SnapsToDevicePixels = true;
 }