Convert remaining files to file-scoped namespace
This commit is contained in:
@@ -4,16 +4,14 @@ using System.ComponentModel;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Text;
|
||||
|
||||
namespace MayShow.Helpers
|
||||
{
|
||||
namespace MayShow.Helpers;
|
||||
|
||||
// https://docs.microsoft.com/en-us/dotnet/api/system.componentmodel.inotifypropertychanged?view=netframework-4.7.2
|
||||
class ChangeNotifier : INotifyPropertyChanged
|
||||
{
|
||||
// https://docs.microsoft.com/en-us/dotnet/api/system.componentmodel.inotifypropertychanged?view=netframework-4.7.2
|
||||
class ChangeNotifier : INotifyPropertyChanged
|
||||
{
|
||||
public event PropertyChangedEventHandler? PropertyChanged;
|
||||
protected void NotifyPropertyChanged([CallerMemberName] string propertyName = "")
|
||||
{
|
||||
PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,10 +5,10 @@ using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace MayShow.ViewModels
|
||||
namespace MayShow.ViewModels;
|
||||
|
||||
class BaseViewModel : ChangeNotifier
|
||||
{
|
||||
class BaseViewModel : ChangeNotifier
|
||||
{
|
||||
IChangeViewModel _viewModelChanger;
|
||||
ITopLevelGrabber? _topLevelGrabber;
|
||||
|
||||
@@ -43,5 +43,4 @@ namespace MayShow.ViewModels
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,10 +4,10 @@ using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace MayShow.ViewModels
|
||||
namespace MayShow.ViewModels;
|
||||
|
||||
class MainWindowViewModel : ChangeNotifier, IChangeViewModel
|
||||
{
|
||||
class MainWindowViewModel : ChangeNotifier, IChangeViewModel
|
||||
{
|
||||
BaseViewModel _currentViewModel;
|
||||
Stack<BaseViewModel> _viewModels;
|
||||
|
||||
@@ -46,5 +46,4 @@ namespace MayShow.ViewModels
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,10 +2,10 @@
|
||||
using MayShow.Helpers;
|
||||
using MayShow.Models;
|
||||
|
||||
namespace MayShow.ViewModels
|
||||
namespace MayShow.ViewModels;
|
||||
|
||||
class WarningDeleteItemViewModel : ChangeNotifier
|
||||
{
|
||||
class WarningDeleteItemViewModel : ChangeNotifier
|
||||
{
|
||||
ReportFile _file;
|
||||
|
||||
public WarningDeleteItemViewModel(ReportFile file)
|
||||
@@ -27,5 +27,4 @@ namespace MayShow.ViewModels
|
||||
{
|
||||
DialogHost.Close("DialogHost", true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,10 +5,10 @@ using Avalonia;
|
||||
using Avalonia.Controls;
|
||||
using Avalonia.Markup.Xaml;
|
||||
|
||||
namespace MayShow.Views
|
||||
namespace MayShow.Views;
|
||||
|
||||
public partial class AboutView : UserControl
|
||||
{
|
||||
public partial class AboutView : UserControl
|
||||
{
|
||||
public AboutView()
|
||||
{
|
||||
this.InitializeComponent();
|
||||
@@ -35,5 +35,4 @@ namespace MayShow.Views
|
||||
}
|
||||
LicenseTextBlock.Text = licenseText.Trim();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,13 +3,12 @@ using Avalonia;
|
||||
using Avalonia.Controls;
|
||||
using Avalonia.Markup.Xaml;
|
||||
|
||||
namespace MayShow.Views
|
||||
namespace MayShow.Views;
|
||||
|
||||
public partial class EditFile : UserControl
|
||||
{
|
||||
public partial class EditFile : UserControl
|
||||
{
|
||||
public EditFile()
|
||||
{
|
||||
this.InitializeComponent();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,10 +5,10 @@ using Avalonia.Input;
|
||||
using Avalonia.Markup.Xaml;
|
||||
using MayShow.ViewModels;
|
||||
|
||||
namespace MayShow.Views
|
||||
namespace MayShow.Views;
|
||||
|
||||
public partial class MainView : UserControl
|
||||
{
|
||||
public partial class MainView : UserControl
|
||||
{
|
||||
public MainView()
|
||||
{
|
||||
this.InitializeComponent();
|
||||
@@ -41,5 +41,4 @@ namespace MayShow.Views
|
||||
mvm?.HasUnsavedWork = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,13 +3,12 @@ using Avalonia;
|
||||
using Avalonia.Controls;
|
||||
using Avalonia.Markup.Xaml;
|
||||
|
||||
namespace MayShow.Views
|
||||
namespace MayShow.Views;
|
||||
|
||||
public partial class WarningDeleteItem : UserControl
|
||||
{
|
||||
public partial class WarningDeleteItem : UserControl
|
||||
{
|
||||
public WarningDeleteItem()
|
||||
{
|
||||
this.InitializeComponent();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user