优化更新
This commit is contained in:
@@ -3,7 +3,9 @@ using System.Collections.Generic;
|
||||
using System.Collections.ObjectModel;
|
||||
using System.ComponentModel;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Windows.Markup;
|
||||
|
||||
using CommunityToolkit.Mvvm.ComponentModel;
|
||||
using CommunityToolkit.Mvvm.Input;
|
||||
@@ -13,6 +15,7 @@ using Sai.RvKits;
|
||||
using Wpf.Ui;
|
||||
using Wpf.Ui.Controls;
|
||||
using Wpf.Ui.Extend.Controls;
|
||||
using Wpf.Ui.Violeta.Controls;
|
||||
|
||||
namespace WpfApp
|
||||
{
|
||||
@@ -28,15 +31,20 @@ namespace WpfApp
|
||||
[RelayCommand]
|
||||
private void ButtonClick()
|
||||
{
|
||||
snackbarService = new SnackbarService();
|
||||
snackbarService.SetSnackbarPresenter(SnackbarPresenter);
|
||||
snackbarService.Show(
|
||||
"消息",
|
||||
"Test",
|
||||
snackbarAppearance,
|
||||
new SymbolIcon(SymbolRegular.Fluent24),
|
||||
TimeSpan.FromSeconds(snackbarTimeout)
|
||||
);
|
||||
//snackbarService = new SnackbarService();
|
||||
//snackbarService.SetSnackbarPresenter(SnackbarPresenter);
|
||||
//snackbarService.Show(
|
||||
// "消息",
|
||||
// "Test",
|
||||
// snackbarAppearance,
|
||||
// new SymbolIcon(SymbolRegular.Fluent24),
|
||||
// TimeSpan.FromSeconds(snackbarTimeout)
|
||||
//);
|
||||
Toast.Information("I am information message");
|
||||
Toast.Error("I am error message");
|
||||
Toast.Success("I am success message");
|
||||
Toast.Warning("I am warning message");
|
||||
Toast.Show(owner: null!, "I am any message", new ToastConfig());
|
||||
}
|
||||
|
||||
[RelayCommand]
|
||||
@@ -176,6 +184,7 @@ namespace WpfApp
|
||||
public List<Student> Students { get; set; } = [];
|
||||
}
|
||||
|
||||
|
||||
class Student
|
||||
{
|
||||
public int ID { get; set; }
|
||||
|
||||
Reference in New Issue
Block a user