public LayoutPresenter(IAppContext context, ILayoutView view, TileLoadingService loadingService) : base(view) { _context = context; _loadingService = loadingService; if (context == null) { throw new ArgumentNullException("context"); } if (loadingService == null) { throw new ArgumentNullException("loadingService"); } View.LayoutControl.NewElement += OnNewElement; View.LayoutControl.ElementDoubleClicked += OnElementDoubleClicked; _loadingService.Start += OnLoadingServiceStart; _loadingService.End += OnLoadingServiceEnd; }
public void Initialize(IPrintableMap map, TileLoadingService loadingService) { // TODO: assign page settings explicitly if (map == null) { throw new ArgumentNullException("map"); } if (loadingService == null) { throw new ArgumentNullException("loadingService"); } _map = map; _loadingService = loadingService; _loadingService.Initialize(_map, this); _initialized = true; ZoomFitToScreen(); UpdateScrollBars(); }