示例#1
0
 private void CheckBox1_CheckedChanged(object sender, EventArgs e)
 {
     if (checkBox1.Checked)
     {
         ignoreDate = true;
         dateTimePicker1.Enabled = false;
         validState           = ValidState.INVALID;
         newsState            = NewsState.NOTHING;
         radioButton2.Checked = true;
         radioButton1.Enabled = false;
         radioButton3.Enabled = false;
         checkBox3.Checked    = true;
         checkBox3.Enabled    = true;
         checkBox2.Checked    = false;
         checkBox2.Enabled    = false;
         checkBox4.Checked    = false;
         checkBox4.Enabled    = false;
     }
     else
     {
         ignoreDate = false;
         dateTimePicker1.Enabled = true;
         radioButton1.Enabled    = true;
         radioButton3.Enabled    = true;
         checkBox2.Enabled       = true;
         checkBox3.Enabled       = false;
         checkBox3.Checked       = false;
         checkBox4.Enabled       = true;
     }
 }
示例#2
0
 private void CheckBox4_CheckedChanged(object sender, EventArgs e)
 {
     if (checkBox4.Checked)
     {
         isNewsSelected        = true;
         checkBox2.Checked     = false;
         checkBox3.Checked     = false;
         comboBox1.DroppedDown = true;
         newsState             = NewsState.NOT_ENTERED;
     }
 }
示例#3
0
 private void CheckBox3_CheckedChanged(object sender, EventArgs e)
 {
     if (checkBox3.Checked)
     {
         isNewsSelected    = true;
         checkBox2.Checked = false;
         checkBox4.Checked = false;
         comboBox1.Enabled = false;
         newsState         = NewsState.NOTHING;
     }
     else
     {
         comboBox1.Enabled = true;
     }
 }
示例#4
0
        public IntentExecutor(
            ILogger <IntentExecutor> logger,
            BringState bringState,
            RouteState routeState,
            SpotifyState spotifyState,
            HueState hueState,
            WeatherState weatherState,
            CalendarState calendarState,
            FuelState fuelState,
            ClockState clockState,
            VvsState vvsState,
            FitbitState fitbitState,
            GoogleFitState googleFitState,
            SoccerState bundesligaState,
            NewsState newsState)
        {
            _logger          = logger;
            _bringState      = bringState;
            _routeState      = routeState;
            _spotifyState    = spotifyState;
            _hueState        = hueState;
            _weatherState    = weatherState;
            _calendarState   = calendarState;
            _fuelState       = fuelState;
            _clockState      = clockState;
            _vvsState        = vvsState;
            _fitbitState     = fitbitState;
            _googleFitState  = googleFitState;
            _bundesligaState = bundesligaState;
            _newsState       = newsState;

            _displayableDictionary = new Dictionary <Type, Displayable>
            {
                { typeof(BringState), bringState },
                { typeof(RouteState), routeState },
                { typeof(SpotifyState), spotifyState },
                { typeof(HueState), hueState },
                { typeof(WeatherState), weatherState },
                { typeof(CalendarState), calendarState },
                { typeof(FuelState), fuelState },
                { typeof(ClockState), clockState },
                { typeof(VvsState), vvsState },
                { typeof(FitbitState), fitbitState },
                { typeof(GoogleFitState), googleFitState },
                { typeof(SoccerState), bundesligaState },
                { typeof(NewsState), newsState },
            };
        }