Skip to content
This repository has been archived by the owner on Aug 21, 2024. It is now read-only.

Commit

Permalink
修复命名问题
Browse files Browse the repository at this point in the history
  • Loading branch information
ricky8955555 committed Mar 14, 2021
1 parent b9cd292 commit a722908
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/Configurations.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ namespace SeewoHelper
public static class Configurations
{
/// <summary>
/// <see cref="SeewoHelper.CoursewareSortingInfo"/> 配置
/// <see cref="SeewoHelper.FileSorterConfig"/> 配置
/// </summary>
public static readonly Configuration<FileSorterConfig> FileSortingInfos = new(Path.Combine(Constants.ConfigurationPath, "CoursewareSortingInfo.json"), new(ExtraFileSortingWay.None, Array.Empty<FileSortingInfo>()));
public static readonly Configuration<FileSorterConfig> FileSorterConfig = new(Path.Combine(Constants.ConfigurationPath, "FileSorterConfig.json"), new(ExtraFileSortingWay.None, Array.Empty<FileSortingInfo>()));

/// <summary>
/// <see cref="SeewoHelper.UISettings"/> 配置
Expand Down
2 changes: 1 addition & 1 deletion src/Forms/WindowMain.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions src/Forms/WindowMain.cs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ private void ListViewSubjectStorageInfos_ColumnWidthChanging(object sender, Colu
e.NewWidth = listViewFileSortingInfos.Columns[e.ColumnIndex].Width;
}

private async void ButtonStartCoursewareSorting_Click(object sender, EventArgs e)
private async void ButtonStartFileSorting_Click(object sender, EventArgs e)
{
var infos = listViewFileSortingInfos.Items.Cast<ListViewItem>().Select(x => (FileSortingInfo)x.Tag);

Expand Down Expand Up @@ -85,7 +85,7 @@ private void WindowMain_Load(object sender, EventArgs e)
private void LoadComboBoxExtraFileSortingWay()
{
comboBoxExtraFileSortingWay.Items.AddRange(_extraFileSortingWayDictionary.Values.ToArray());
comboBoxExtraFileSortingWay.SelectedItem = _extraFileSortingWayDictionary[Configurations.FileSortingInfos.Content.ExtraFileSortingWay];
comboBoxExtraFileSortingWay.SelectedItem = _extraFileSortingWayDictionary[Configurations.FileSorterConfig.Content.ExtraFileSortingWay];
}

private void CreateServiceCheckBox()
Expand Down Expand Up @@ -144,13 +144,13 @@ private void WindowMain_FormClosing(object sender, FormClosingEventArgs e)
private void UpdateSubjectStorageInfoConfig()
{
var infos = listViewFileSortingInfos.Items.Cast<ListViewItem>().Select(x => (FileSortingInfo)x.Tag);
Configurations.FileSortingInfos.Content = Configurations.FileSortingInfos.Content with { FileSortingInfos = infos.ToArray() };
Configurations.FileSortingInfos.Save();
Configurations.FileSorterConfig.Content = Configurations.FileSorterConfig.Content with { FileSortingInfos = infos.ToArray() };
Configurations.FileSorterConfig.Save();
}

private void LoadSubjectStorageInfoConfig()
{
var info = Configurations.FileSortingInfos.Content;
var info = Configurations.FileSorterConfig.Content;

foreach (var subject in info.FileSortingInfos)
{
Expand Down

0 comments on commit a722908

Please sign in to comment.