fix: add button, upgrade version individually.
This commit is contained in:
parent
98785417b2
commit
8ff8057f07
@ -167,6 +167,7 @@
|
||||
Grid.Row="2"
|
||||
Margin="12,0,12,12"
|
||||
HorizontalAlignment="Right"
|
||||
Command="{Binding AddCommand}"
|
||||
Content="Add" />
|
||||
</Grid>
|
||||
</TabItem>
|
||||
|
@ -4,6 +4,7 @@ using System.Collections.ObjectModel;
|
||||
using System.Linq;
|
||||
using Avalonia.Collections;
|
||||
using CommunityToolkit.Mvvm.ComponentModel;
|
||||
using CommunityToolkit.Mvvm.Input;
|
||||
|
||||
namespace Semi.Avalonia.Demo.ViewModels;
|
||||
|
||||
@ -15,6 +16,8 @@ public class DataGridDemoViewModel: ObservableObject
|
||||
|
||||
public ObservableCollection<SongViewModel> GridData3 { get; set; }
|
||||
|
||||
public RelayCommand AddCommand { get; set; }
|
||||
|
||||
public DataGridDemoViewModel()
|
||||
{
|
||||
GridData1 = new ObservableCollection<Song>(Song.Songs);
|
||||
@ -28,6 +31,12 @@ public class DataGridDemoViewModel: ObservableObject
|
||||
CountOfComment = a.CountOfComment,
|
||||
IsSelected = false
|
||||
}));
|
||||
AddCommand = new RelayCommand(Add);
|
||||
}
|
||||
|
||||
private void Add()
|
||||
{
|
||||
GridData3.Add(new SongViewModel());
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -5,6 +5,7 @@
|
||||
<PropertyGroup>
|
||||
<Title>Semi.Avalonia.DataGrid</Title>
|
||||
<PackageReleaseNotes>Update to 11.0.1</PackageReleaseNotes>
|
||||
<Version>11.0.1.1</Version>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
Loading…
x
Reference in New Issue
Block a user