Exemple #1
0
    	public void LoadAdminWidgets(DockBar dockBarViewModel)
        {
			Guard.Requires<ArgumentNullException>(dockBarViewModel != null);

            this.dockBarViewModel = dockBarViewModel;

            dockBarViewModel.Items.Add(new FullScreen());

			widgetMetadataRepo.BeginGet(All.ItemsOf<WidgetMetadata>());
        }
Exemple #2
0
 public DockBarService(DockBar dockBar)
 {
     this.dockBar = dockBar;
 }
Exemple #3
0
 partial void OnInitialize()
 {
     Traybar = new Traybar();
     Slideshow = new Slideshow();
     DockBar = new DockBar();
 }
Exemple #4
0
			public void Setup()
			{
				ViewModelBootstrapperForTests.Initialize();

				slideConfigRepoMock = new Mock<IAsyncRepository<SlideConfiguration>>();
				loggerMock = new Mock<ILog>();

				widgetMetadataRepoMock = new Mock<IAsyncRepository<WidgetMetadata>>();
				WidgetsExists();

				slideConfig = new SlideConfiguration
				{
					Duration = 100,
					Title = "Holidays provider widget",
					WidgetType = typeof(HolidayProviderTestWidget).FullName,
					WidgetConfigurationId = Guid.NewGuid()
				};
				slideConfigs = new List<SlideConfiguration> { slideConfig };
				slideConfigRepoMock.Setup(t => t.BeginGet(It.IsAny<Specification<SlideConfiguration>>())).Raises(
					t => t.GetCompleted += null, new GetCompletedEventArgs<SlideConfiguration>(slideConfigs, new AllSpecification<SlideConfiguration>()));

				moduleLoader = new ModuleLoader(slideConfigRepoMock.Object, widgetMetadataRepoMock.Object, loggerMock.Object);

				slideshowViewModel = new Slideshow();
				dockBarViewModel = new DockBar();

				Before();
			}
Exemple #5
0
		partial void OnSetDockBar(ref DockBar value);