コード例 #1
0
        private VMMainViewModel()
        {
            try
            {
                tskEndCycle = new Task(() =>
                {
                    Run();
                });
                tskEndCycle.Start();
                CreateHubConnection();

                strWMSGeoserverUrl          = ConfigurationManager.AppSettings["WMSGeoserver"];
                strRoadRoutingWebApiAddress = ConfigurationManager.AppSettings["RoadRoutingWebApiAddress"];
                clsRoadRoutingWebApi.SetBaseAddress(strRoadRoutingWebApiAddress);

                PlayScenarioCommand  = new DelegateCommand(x => PlayScenario(), Dispatcher.CurrentDispatcher);
                PauseScenarioCommand = new DelegateCommand(x => PauseScenario(), Dispatcher.CurrentDispatcher);
                StopScenarioCommand  = new DelegateCommand(x => StopScenario(), Dispatcher.CurrentDispatcher);

                MapHomeZoomCommand = new DelegateCommand(x => MapHomeZoom_Click(), Dispatcher.CurrentDispatcher);


                MapLayersCommand     = new DelegateCommand(x => MapLayers_Click(), Dispatcher.CurrentDispatcher);
                PlanningRouteCommand = new DelegateCommand(x => PlanningRoute(), Dispatcher.CurrentDispatcher);


                PlanningAgentsCommand = new DelegateCommand(x => PlanningAgents(), Dispatcher.CurrentDispatcher);


                SelectTools = new clsSelectTools();
            }
            catch (Exception ex)
            {
            }
        }
コード例 #2
0
ファイル: VMMainViewModel.cs プロジェクト: ohadmanor/TDS
        private  VMMainViewModel()
        {
            try
            {
                tskEndCycle = new Task(() =>
                {
                    Run();
                });
                tskEndCycle.Start();
                CreateHubConnection();
               
               strWMSGeoserverUrl = ConfigurationManager.AppSettings["WMSGeoserver"];
               strRoadRoutingWebApiAddress = ConfigurationManager.AppSettings["RoadRoutingWebApiAddress"];
               clsRoadRoutingWebApi.SetBaseAddress(strRoadRoutingWebApiAddress);

               PlayScenarioCommand = new DelegateCommand(x => PlayScenario(), Dispatcher.CurrentDispatcher);
               PauseScenarioCommand = new DelegateCommand(x => PauseScenario(), Dispatcher.CurrentDispatcher);
               StopScenarioCommand = new DelegateCommand(x => StopScenario(), Dispatcher.CurrentDispatcher);

               MapHomeZoomCommand = new DelegateCommand(x => MapHomeZoom_Click(), Dispatcher.CurrentDispatcher);


               MapLayersCommand = new DelegateCommand(x => MapLayers_Click(), Dispatcher.CurrentDispatcher);
               PlanningRouteCommand = new DelegateCommand(x => PlanningRoute(), Dispatcher.CurrentDispatcher);


               PlanningAgentsCommand = new DelegateCommand(x => PlanningAgents(), Dispatcher.CurrentDispatcher);


               SelectTools = new clsSelectTools(); 
            }
            catch(Exception ex)
            {

            }
        }