Ejemplo n.º 1
0
        /// <summary>
        /// Initializes the Settings module.
        /// </summary>
        public void Initialize()
        {
            this.RegisterViewsAndServices();

            ISettingsViewPresentationModel presentationModel = this.container.Resolve <ISettingsViewPresentationModel>();

            this.regionManager.RegisterViewWithRegionInIndex(RegionNames.ToolsRegion, presentationModel.View, 6);
        }
        public void ShouldNotThrowExceptionAndSetSelectedStartTimeCodeStIfTimeCodeIsValid()
        {
            ISettingsViewPresentationModel presentationModel = this.CreatePresentationModel();

            presentationModel.SelectedStartTimeCode = "00:01:01;00";

            Assert.IsTrue(presentationModel.SelectedStartTimeCode == "00:01:01;00");
        }
        /// <summary>
        /// Initializes the Settings module.
        /// </summary>
        public void Initialize()
        {
            this.RegisterViewsAndServices();

            ISettingsViewPresentationModel presentationModel = this.container.Resolve <ISettingsViewPresentationModel>();

            this.container.Resolve <IIncreasePersistenceQuotaViewModel>();

            bool shouldSettingsWindow = this.windowManager.ShouldDisplayWindow(presentationModel.View.GetType().ToString(), false);

            if (shouldSettingsWindow)
            {
                this.regionManager.Regions[RegionNames.MainRegion].Add(presentationModel.View);
            }

            IMenuButtonViewModel menuViewModel = this.container.Resolve <IMenuButtonViewModel>();

            menuViewModel.IsViewActive  = shouldSettingsWindow;
            menuViewModel.Text          = "Settings";
            menuViewModel.ViewToDisplay = presentationModel.View;
            this.regionManager.Regions[RegionNames.MenuRegion].Add(menuViewModel.View);
        }
        public void ShouldThrowExceptionIfTimeCodeIsNotValid()
        {
            ISettingsViewPresentationModel presentationModel = this.CreatePresentationModel();

            presentationModel.SelectedStartTimeCode = "ab:34;34";
        }
        public void ShouldThrowExceptionIfStartTimeCodeIsGreaterThanDefaultTimelineDuration()
        {
            ISettingsViewPresentationModel presentationModel = this.CreatePresentationModel();

            presentationModel.SelectedStartTimeCode = "02:59:32;25";
        }
        public void ShouldThrowExceptionIfSecondPartOfTimeCodeIsNotValid()
        {
            ISettingsViewPresentationModel presentationModel = this.CreatePresentationModel();

            presentationModel.SelectedStartTimeCode = "12:23:80;23";
        }