private void radRadioButtonDay_ToggleStateChanged(object sender, StateChangedEventArgs args) { if (isUpdating) { return; } SchedulerTimelineView schedulerTimelineView = this.radScheduler1.GetTimelineView(); Timescales timescales = (Timescales)((RadRadioButton)sender).Tag; schedulerTimelineView.ShowTimescale(timescales); AdjustSpintEditorValues(timescales); }
private void AdjustSpintEditorValues(Timescales timescales) { switch (timescales) { case Timescales.Months: case Timescales.Hours: this.radSpinEditorTimeSlots.Maximum = 12; this.radSpinEditorTimeSlots.Value = 12; break; case Timescales.Days: this.radSpinEditorTimeSlots.Maximum = 7; this.radSpinEditorTimeSlots.Value = 7; break; case Timescales.Weeks: this.radSpinEditorTimeSlots.Maximum = 4; this.radSpinEditorTimeSlots.Value = 4; break; } }
private NavigationStepTypes StepsByScalling(Timescales timescale, ref int navigationStep) { NavigationStepTypes navigationStepType = NavigationStepTypes.Day; switch (timescale) { case Timescales.Minutes: navigationStepType = NavigationStepTypes.Minute; navigationStep = 15; break; case Timescales.HalfHour: navigationStepType = NavigationStepTypes.Minute; navigationStep = 30; break; case Timescales.Hours: navigationStepType = NavigationStepTypes.Hour; break; case Timescales.Days: navigationStepType = NavigationStepTypes.Day; break; case Timescales.Weeks: navigationStepType = NavigationStepTypes.Week; break; case Timescales.Months: navigationStepType = NavigationStepTypes.Month; break; case Timescales.Years: navigationStepType = NavigationStepTypes.Year; break; } return(navigationStepType); }