Exemplo n.º 1
0
 public AppModesCommands(IEventRoutingService eventRoutingService, IAppModeService appModeService)
 {
     this.appModeService = appModeService;
     StartPresentation   = GuiCommandsHelper.Create("Start Presentation", ExecStartPresentation, Keys.F5);
     StopPresentation    = GuiCommandsHelper.Create("Stop Presentation", ExecStopPresentation, Keys.Escape);
     eventRoutingService.Subscribe <IAppModeChangedEvent>(typeof(IAppModesCommands), nameof(OnModeChanged), OnModeChanged);
     OnModeChanged(new AppModeChangedEvent(appModeService.Mode));
 }
Exemplo n.º 2
0
 public DirtyHackService(IWorldTreeService worldTreeService, IAppModeService appModeService,
                         IReadOnlyList <IStoryLayout> storyLayouts, IEmbeddedResources embeddedResources)
 {
     this.worldTreeService  = worldTreeService;
     this.appModeService    = appModeService;
     this.storyLayouts      = storyLayouts;
     this.embeddedResources = embeddedResources;
 }
Exemplo n.º 3
0
 public NavigationService(IEventRoutingService eventRoutingService, IStoryService storyService, IAppModeService appMode)
 {
     current = -1;
     this.eventRoutingService = eventRoutingService;
     this.storyService        = storyService;
     this.appMode             = appMode;
     previousStack            = new Stack <int>();
     nextStack = new Stack <int>();
     storyService.GraphChanged += OnStoryGraphChanged;
 }
        public DebugVrPresentationView(INavigationService navigationService, IStoryService storyService,
                                       IUserQueryService userQueryService, ICommonNodeFactory commonNodeFactory,
                                       IAppModeService appModeService, IGlobalObjectService globalObjectService)
        {
            this.navigationService = navigationService;
            this.storyService      = storyService;
            this.userQueryService  = userQueryService;
            this.appModeService    = appModeService;
            uiCarrier = globalObjectService.UICarrier;
            uiCanvas  = uiCarrier.EnumerateChildren().Single();
            var canvasTransform = uiCanvas.GetComponent <RectTransform>();

            canvasTransform.sizeDelta = new Vector2(Screen.width, Screen.height);
            mainLayer = new ViewLayer();
            Layers    = new[] { mainLayer };
        }
Exemplo n.º 5
0
        protected PresentationView(INavigationService navigationService, IStoryService storyService,
                                   IUserQueryService userQueryService, ICommonNodeFactory commonNodeFactory,
                                   IAppModeService appModeService)
        {
            this.navigationService = navigationService;
            this.storyService      = storyService;
            this.userQueryService  = userQueryService;
            this.appModeService    = appModeService;

            mainLayer      = new ViewLayer();
            userQueryLayer = new ViewLayer();
            Layers         = new[] { mainLayer, userQueryLayer };

            querySceneComponent = AmFactory.Create <UserQuerySceneComponent>();
            var uqSceneRoot = commonNodeFactory.WorldRoot(false);

            uqSceneRoot.Components.Add(querySceneComponent);
            var uqScene  = Scene.Create(uqSceneRoot);
            var uqCamera = new PlaneOrthoBoundControlledCamera(uqSceneRoot, PlaneOrthoBoundControlledCamera.Props.Default, false);

            userQueryLayer.VisibleScene = uqScene;
            userQueryLayer.Camera       = uqCamera;
        }
Exemplo n.º 6
0
 protected ManipulateInPresentationComponent(IAppModeService appModeService, IViewService viewService, IPresentationGuiCommands commands)
 {
     this.appModeService = appModeService;
     this.viewService    = viewService;
     this.commands       = commands;
 }