SniffCore.Navigation 2.0.0

Suggested Alternatives

Chapter.WPF.Navigation

The owner has unlisted this package. This could mean that the package is deprecated, has security vulnerabilities or shouldn't be used anymore.
dotnet add package SniffCore.Navigation --version 2.0.0
                    
NuGet\Install-Package SniffCore.Navigation -Version 2.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SniffCore.Navigation" Version="2.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="SniffCore.Navigation" Version="2.0.0" />
                    
Directory.Packages.props
<PackageReference Include="SniffCore.Navigation" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add SniffCore.Navigation --version 2.0.0
                    
#r "nuget: SniffCore.Navigation, 2.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package SniffCore.Navigation@2.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=SniffCore.Navigation&version=2.0.0
                    
Install as a Cake Addin
#tool nuget:?package=SniffCore.Navigation&version=2.0.0
                    
Install as a Cake Tool

SniffCore.Navigation

SniffCore.Navigation follows the idea of "It shall be async".
It brings the possibility to show windows, user controls and dialogs in an MVVM environment.
Each VM can have an async ctor, cancel window opening, show loading progress and many more.

Overview

The SniffCore.Navigation repository consists of multiple modules The Navigation depends on all of them.

Object Description
IDialogProvider This assembly provides ways how to show system dialogs for files or folders.
IMessageBoxProvider This assembly provides ways how to show message boxes.
INavigationService This is the main assembly to show windows, user controls, dialogs and work with them.
IPleaseWaitProvider This assembly provides ways how to show please wait overlays.
IWindowProvider This assembly provides ways how to create and show windows.

Getting Started

First you register all needed assemblies in your IOC container like Unity

_unityContainer.RegisterSingleton<IWindowProvider, WindowProvider>();
_unityContainer.RegisterType<IDialogProvider, DialogProvider>();
_unityContainer.RegisterType<IMessageBoxProvider, MessageBoxProvider>();
_unityContainer.RegisterType<IPleaseWaitProvider, PleaseWaitProvider>();
_unityContainer.RegisterType<INavigationService, NavigationService>();

Then register window and user controls with pairs in the WindowProvider

var windowProvider = (WindowProvider) _unityContainer.Resolve<IWindowProvider>();

windowProvider.RegisterWindow<MainView>("MainView");
windowProvider.RegisterWindow<SubView>("SubView");

windowProvider.RegisterControl<DialogsView>("DialogsView");
windowProvider.RegisterControl<DisplayControlView>("DisplayControlView");

then you can show windows or user controls or more using the INavigationService

var navigationService = _unityContainer.Resolve<INavigationService>();
var vm = _unityContainer.Resolve<MainViewModel>();
navigationService.ShowWindowAsync("MainView", vm);

License

Copyright (c) David Wendland. All rights reserved.
Licensed under the MIT License. See LICENSE file in the project root for full license information.

Product Compatible and additional computed target framework versions.
.NET net6.0-windows7.0 is compatible.  net7.0-windows was computed.  net8.0-windows was computed.  net9.0-windows was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net6.0-windows7.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated