Esempio n. 1
0
        public PortalModel(WidgetStatusHost widgetStatusHost, Dispatcher dispatcher)
        {
            InitializeComponent();

            CultureResources.registerDataProvider(this);

            _viewModel = new PortalViewModel();

            createStatusObjects();

            this.VehicleStatus = VehicleType.Small_Vehicle;

            _Dispatcher = dispatcher;
            _WidgetStatusHost = widgetStatusHost;
            _WidgetStatusHost.WidgetUpdateEvent += new WidgetUpdateHandler(WidgetUpdate);
            _WidgetStatusHost.ErrorMessageUpdate += new UpdateErrorMessageHandler(_WidgetStatusHost_ErrorMessageUpdate);
        }
Esempio n. 2
0
        public PortalModel(WidgetStatusHost widgetStatusHost, Dispatcher dispatcher)
        {
            InitializeComponent();
            
            Map(updateInterlockDoor, "INTERLOCK_DOOR");
            Map(updateEStops, "ESTOP");
            Map(updateMDSSensor, "MDS");
            Map(updateLightCurtainEmitters, "INTERLOCK_LC");
            Map(updateTrafficLight, "TRAFFIC_LIGHT_STATUS");
            Map(updateVehicleSensor, "VEHICLE_SENSOR");
            
            CultureResources.registerDataProvider(this);

            _viewModel = new PortalViewModel();

            this.VehicleStatus = VehicleType.Small_Vehicle;

            _Dispatcher = dispatcher;
            _WidgetStatusHost = widgetStatusHost;
            _WidgetStatusHost.WidgetUpdateEvent += new WidgetUpdateHandler(WidgetUpdate);
            _WidgetStatusHost.ErrorMessageUpdate += new UpdateErrorMessageHandler(_WidgetStatusHost_ErrorMessageUpdate);
        }