Тёмный
No video :(

Building Outlook: Prism Navigation 

Brian Lagunas
Подписаться 18 тыс.
Просмотров 16 тыс.
50% 1

Опубликовано:

 

26 авг 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 36   
@mgregory22
@mgregory22 4 года назад
4:40 Removing region manager registration of ViewA 9:05 Added PrismOutlook repository to GitHub 9:38 Deleting the template-generated view 10:05 Adding MailList view and view model 13:15 Navigation plan for PrismOutlook 14:13 Centralizing navigation in the MainWindowViewModel 17:25 Creating PrismOutlook.Business class library project 18:57 Creating NavigationItem class 19:30 On INotifyPropertyChanged 19:50 Creating Caption, NavigationPath, and Items properties 21:00 Creating tree control in the Outlook bar 21:15 Creating the MailGroupViewModel class 22:22 On ViewModelLocator.AutoWireViewModel 22:50 ViewModelLocator looks in Views and ViewModels namespaces by convention 25:36 Manually specifying which view model to associate with a view in the ViewModelLocator 27:42 Creating the tree of mail folders with NavigationItem objects 32:40 Installing Infragistics.WPF.DataTree 33:35 Adding a XamDataTree to the Outlook bar 37:11 Setting the main content view upon program start and when the Outlook bar group changes 39:12 Navigating to the default view in the XamOutlookBar.SelectedGroupChanged event 41:36 Adding the IOutlookBarGroup interface for holding the default navigation path 43:00 Setting the default navigation path for the Mail group 44:00 Setting the default navigation path for the Contacts group 44:37 Implementing navigation (preliminary) 46:04 Registering views for navigation in the modules 47:52 Testing the navigation 48:13 Refactoring the navigation implementation 49:24 Alternative 1: Grab MainWindowViewModel from MainWindow and call its navigation method directly 50:06 Alternative 2: Create a CompositeCommand for globally centralized navigation 51:45 Creating the ApplicationCommands class and interface containing the CompositeCommand for navigation 52:35 Installing Prism.Core 53:54 Creating the NavigateCommand CompositeCommand 55:14 Registering the command with Prism 55:58 Refactoring MainWindow: replacing IRegionManager with IApplicationCommands 56:50 Adding MainWindowViewModel's NavigateCommand to the ApplicationCommands.NavigateCommand list 58:22 On using commands vs using the view model directly 58:38 Testing the command infrastructure 59:13 Setting up navigation to change the list of emails when each different mail folder is selected 1:00:04 Setting up a folder-selected event to execute the navigation command 1:03:16 Setting up an event trigger for the XamDataTree.ActiveNodeChanged event to execute prism:InvokeCommandAction 1:04:40 Creating the SelectedCommand DelegateCommand in MailGroupViewModel for the folder-selected event 1:06:30 Testing SelectedCommand 1:07:00 Refactoring SelectedCommand to explicitly use a NavigationItem as its parameter type 1:07:42 Executing the global navigation command with the local command 1:08:50 Setting up navigation paths to test the mail folders 1:09:30 Implementing INavigationAware on the MailListViewModel 1:10:57 Displaying the navigation path parameter value in the view 1:11:15 Testing the folder navigation 1:12:12 A problem: the main content view doesn't load when switching from Contacts to the Mail group 1:12:42 Updating the default logic to load the view when the group changes 1:18:04 Testing loading the view when changing the group 1:19:04 Creating ViewModelBase class 1:22:05 Adding Prism.Regions.IConfirmNavigationRequest to ViewModelBase 1:22:44 On IConfirmNavigationRequest 1:22:58 Inheriting from Prism.Mvvm.BindableBase 1:23:16 Inheriting all view models from ViewModelBase 1:24:46 Making the ribbon tabs and controls dynamic 1:27:45 Using class attributes on the views to specify the ribbon tabs 1:29:30 Creating the RibbonTabAttribute class 1:31:00 Generalizing the attribute to any dependent view 1:31:38 Changing RibbonTabAttribute to DependentViewAttribute 1:33:44 Adding the DependViewAttribute to the MailList view 1:34:25 Changing the RegionNames to constants so they can be used in the attribute application 1:35:28 Adding a HomeTab UserControl class to the Contacts module to represent the ribbon home tab 1:36:23 On making the attribute more generic 1:37:12 Changing the UserControl to Prism.WPF.RibbonTabItem 1:38:58 Adding DependendViewRegionBehavior class to PrismOutlook
@BrianLagunas
@BrianLagunas 4 года назад
You rock!
@GAGANDEEP901
@GAGANDEEP901 Год назад
thanks a lot brother !!
@draqula004
@draqula004 5 лет назад
Please continue to stream both twitch and RU-vid. You stream while I’m at work and I come home and watch and learn. It’s great.
@BrianLagunas
@BrianLagunas 5 лет назад
I think I have Restream working again for RU-vid. I will test it out on Thursday when I stream again.
@kangyonggu7930
@kangyonggu7930 3 года назад
I watched all of your great courses on Pluralsight. Today, I have watched the first two videos here and it is amazing, too. I am very happy to be able to get the opportunity to see how to build the entire solution with Prism. You are a legend. Thanks a lot. P.s) I also want to thank Matt Gregory.
@BrianLagunas
@BrianLagunas 3 года назад
Great to hear! Thank you for watching.
@rballz
@rballz 3 года назад
This series has been great. Inspired me to go sponsor Brian on the Prism Github repo. Great work!
@BrianLagunas
@BrianLagunas 3 года назад
Very cool! I am so grateful for your support. It really means a lot
@FranciscoTChavez
@FranciscoTChavez Месяц назад
That thing with the bad namespace assigned to "igWPF" stopped all my intellisense from working. Don't you just LOVE how Microsoft keeps improving Visual Studio.
@longuinni
@longuinni 5 лет назад
It's awaesome to see how you structure an application and how you think how to solve a problem. And you know what is best? That I can follow everything with my Infragistics licence =] Thanks Brian!
@BrianLagunas
@BrianLagunas 5 лет назад
As you can see, I try to keep everything as simple as possible. Having an Infragistics licenses definitely makes it easier 😁
@karelkral6812
@karelkral6812 5 лет назад
I am using Prism long time, thanks anyway!
@BrianLagunas
@BrianLagunas 5 лет назад
Thank you for watching
@svend1562
@svend1562 3 года назад
a bit late, but gz for 18 years ;)
@madmuppet2k
@madmuppet2k 4 года назад
What is the advantage of using a composite command for navigation instead of the event aggregator? These videos are very timely as I'm currently trying to figure out how best to use Prism in our current application.
@BrianLagunas
@BrianLagunas 4 года назад
You can bind buttons directly to the CompositeCommand vs having to have a separate command to fire an event.
@nicolaschausse3719
@nicolaschausse3719 3 года назад
Thanks so much Brain! It's very helpful. I'm just wondering why "NavigationItem" class is inside the Business project and not in Core project. It's not related to business for my concern. I'm gonna watch the next videos.
@BrianLagunas
@BrianLagunas 3 года назад
Feel free to put your classes wherever you want and where they make the most sense for your project.
@kasozivincent107
@kasozivincent107 4 года назад
But Brian, I am somehow confused... The OnInitialized and RegisterTypes methods of IModule interface take in parameters tht we don't even use, so why are you selective on where to register views with regions and where to locate View Models from? What if i switch there places? Thanks
@BrianLagunas
@BrianLagunas 4 года назад
You will use them depending on the scenario. You will especially use them when registering types in your module.
@emko8037
@emko8037 4 года назад
Are there any reasons to not bind to 'xamDataTree::SelectedDataItems' and handle the properties setter?
@BrianLagunas
@BrianLagunas 4 года назад
I prefer to avoid placing code in property setters if I can help it. Also, I have no reason to keep the state of that property in the VM for any other reason. So why add the overhead of that collection and create a dirty setter just to navigate. This is a cleaner solution.
@ukaszopata1797
@ukaszopata1797 Год назад
Hi, I tried this approach, seems fine: var item = _dataTree.SelectedDataItems?.FirstOrDefault() as NavigationItem; if (item != null) return item.NavigationPath;
@hussainaot193
@hussainaot193 4 года назад
hi, i am using prism 6.3 in my application but after updating prism 6.3 to prism 7 i got error in bootstrapper whose base class is mefBootstrapper (Method not found, Prism.Modularity.IModuleCatalog,Prsim.Bootstrapper.CreateModuleCatalog()), please guide me how i can remove this error
@BrianLagunas
@BrianLagunas 4 года назад
MEF is no longer supported. Also, you only need to ask for help in 1 place, not 3 different places.
@DonovanBrown
@DonovanBrown 3 года назад
Where did you get the propp snippet?
@BrianLagunas
@BrianLagunas 3 года назад
It is part of the Prism Template Pack Visual Studio extension. You can download it from the marketplace.
@svend1562
@svend1562 3 года назад
public string DefaultNavigationPath => (dataTree?.ActiveDataItem as NavigationItem)?.NavigationPath ?? nameof(MailEnumeration);
@BrianLagunas
@BrianLagunas 3 года назад
Thanks for sharing
@wiseduho
@wiseduho 4 года назад
if (_dataTree.SelectedDataItems != null && _dataTree.SelectedDataItems[0] is NavigationItem item) { return item.NavigationPath; }
Далее
Building Outlook: Changing Ribbon Tabs
1:47:36
Просмотров 7 тыс.
MVVM Made Simple with Prism - Webinar
1:20:01
Просмотров 115 тыс.
Prism for Xamarin.Forms - Navigation Basics
15:09
Просмотров 22 тыс.
Prism Region Not Found Exception in WPF
11:24
Просмотров 2,2 тыс.
Adding Dependency Injection to WPF applications
22:42
C# Yield Return: What is it and how does it work?
15:09
Prism - Using Delegate Commands
11:31
Просмотров 36 тыс.