/// <summary> /// Attach the specified Model and View. /// </summary> /// <param name="model">The model to use</param> /// <param name="view">The view for this presenter</param> /// <param name="explorerPresenter">The explorer presenter used</param> public void Attach(object model, object view, ExplorerPresenter explorerPresenter) { this.graph = model as Graph; this.view = view as ITitleView; this.explorerPresenter = explorerPresenter; // Trap change event from the model. this.explorerPresenter.CommandHistory.ModelChanged += this.OnModelChanged; // Trap events from the view. this.view.OnTitleChanged += this.OnTitleChanged; // Tell the view to populate the axis. this.PopulateView(); }
public TitlePresenter(ShowTitleUseCase useCase, ITitleView view) { this.useCase = useCase; this.view = view; Bind(); }