public void Save__SavesToBackingStore() { ShellPresenter test = BuildDefaultShellPresenter(); test.Save(); _fakeBackingStore.Verify(x => x.Save()); }
public void Initialize__InitializesBackingStore() { ShellPresenter test = BuildDefaultShellPresenter(); test.Initialize(); _fakeBackingStore.Verify(x => x.Initialize()); }
static void Main() { IShellView someView = new View(); //calling code ShellPresenter sp = new ShellPresenter(); //Why is this allowed? sp.View = someView; //because now its within the class }
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); var context = new ApplicationContext(); var presenter = new ShellPresenter(); context.MainForm = presenter.View; Application.Run(context); }
//Here to implement //IEnumerable<DefaultView> _defaultViews; //AccessRightsService _accessRightsService; protected override DependencyObject CreateShell() { /* Container.RegisterInstance<IAccessRightsService>(_accessRightsService); * Container.RegisterInstance<IPermissionChecker>(_accessRightsService); * Container.RegisterInstance<IUser>(_accessRightsService.CurrentUser);*/ _shellPresenter = Container.Resolve <ShellPresenter>(); Container.RegisterInstance <IShell>(_shellPresenter); Container.RegisterInstance <IShellInteraction>(_shellPresenter); _shellPresenter.Execute(); return(_shellPresenter.View); }
protected override void Before_each_spec() { _shellPresenter = Create<ShellPresenter>(); }
public void ShowModal() { ensureVisible(true); ShellPresenter.DimBackgroundWhile(() => ShowDialog()); }