[feat:] max courses per semester changeable
This commit is contained in:
@@ -188,6 +188,11 @@
|
||||
</StackPanel>
|
||||
|
||||
</Grid>
|
||||
<Line />
|
||||
<Grid ColumnDefinitions="*,3*">
|
||||
<Label Content="Maximale Sportkursanzahl pro Semester"></Label>
|
||||
<NumericUpDown Grid.Column="1" x:Name="NudSportMaxPerSemester" ValueChanged="NudSportMaxPerSemester_OnValueChanged"></NumericUpDown>
|
||||
</Grid>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</TabItem>
|
||||
|
||||
@@ -17,6 +17,10 @@ public partial class MainWindow : Window
|
||||
Settings.ImportInitial();
|
||||
Instance = this;
|
||||
RefreshCoursesList();
|
||||
try
|
||||
{
|
||||
NudSportMaxPerSemester.Value = Settings.Instance.NumCoursesPerSemester;
|
||||
} catch {}
|
||||
}
|
||||
|
||||
private void MnuExpSettings_OnClick(object? sender, RoutedEventArgs e)
|
||||
@@ -384,4 +388,12 @@ public partial class MainWindow : Window
|
||||
{
|
||||
// Export as PDF
|
||||
}
|
||||
|
||||
private void NudSportMaxPerSemester_OnValueChanged(object? sender, NumericUpDownValueChangedEventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
Settings.Instance.NumCoursesPerSemester = Convert.ToInt32(NudSportMaxPerSemester.Value);
|
||||
} catch {}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user