基于WPF系统框架设计(6)-整合MVVM框架(Prism)
应用场景 我们基础的框架已经搭建起来了,现在整合MVVM框架Prism,在ViewModel做一些逻辑处理,真正把界面设计分离出来。 这样方便我们系统开发分工合作,同时提高系统可维护性和灵活性。 具体的Prism安装和Microsoft.Practices.Prism.dll获取,在这个网址: http://compositewpf.codeplex.com/ 原始的模式(Winform) (1)现在看一下之前的设计的View: MainWindow.XAML源码: (2)MainWindow.xaml.cs源码: using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Windows; using System.Windows.Controls; using System.Windows.Data; using System.Windows.Documents; using System.Windows.Input; using System.Windows.Media; using System.Windows.Media.Imaging; using System.Windows.Navigation; using System