Improve navigation
This commit is contained in:
@@ -9,16 +9,16 @@ public class NavigateBackAction :
|
||||
AvaloniaObject,
|
||||
IAction
|
||||
{
|
||||
public static readonly StyledProperty<string> ContextProperty =
|
||||
AvaloniaProperty.Register<NavigateBackAction, string>(nameof(Context));
|
||||
public static readonly StyledProperty<string> RegionProperty =
|
||||
AvaloniaProperty.Register<NavigateBackAction, string>(nameof(Region));
|
||||
|
||||
public static readonly StyledProperty<string> ScopeProperty =
|
||||
AvaloniaProperty.Register<NavigateBackAction, string>(nameof(Scope));
|
||||
|
||||
public string Context
|
||||
public string Region
|
||||
{
|
||||
get => GetValue(ContextProperty);
|
||||
set => SetValue(ContextProperty, value);
|
||||
get => GetValue(RegionProperty);
|
||||
set => SetValue(RegionProperty, value);
|
||||
}
|
||||
|
||||
public string Scope
|
||||
@@ -34,7 +34,7 @@ public class NavigateBackAction :
|
||||
{
|
||||
if (control.DataContext is IObservableViewModel observableViewModel)
|
||||
{
|
||||
observableViewModel.Publisher.Publish(new NavigateBackEventArgs(Context
|
||||
observableViewModel.Publisher.Publish(new NavigateBackEventArgs(Region
|
||||
?? null, Scope ?? null));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user