IoC and NavigationService implementation

This commit is contained in:
2011-03-25 11:22:57 +02:00
parent 98c8cf3f94
commit f069ee7010
31 changed files with 1139 additions and 73 deletions
@@ -0,0 +1,43 @@
using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using MyFriendsAround.WP7.Helpers.Navigation;
namespace MyFriendsAround.WP7.ViewModel
{
public class ViewModelBase : GalaSoft.MvvmLight.ViewModelBase
{
private object context;
public object Context
{
get { return context; }
set
{
if (context == value)
return;
context = value;
RaisePropertyChanged("Context");
}
}
/// <summary>
/// Gets PageNavigation from Container
/// </summary>
public IPageNavigation PageNav
{
get
{
IPageNavigation pageNav =
(IPageNavigation)Container.Instance.Resolve(typeof(PageNavigation), "PageNavigation");
return pageNav;
}
}
}
}