| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- using Muchinfo.MTPClient.Account.ViewModels;
- using Muchinfo.MTPClient.Data.Model;
- using Muchinfo.MTPClient.Infrastructure.Windows;
- 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.Windows.Shapes;
- using Muchinfo.WPF.Controls.Windows;
- namespace Muchinfo.MTPClient.Account.Views
- {
- /// <summary>
- /// SystemAnnouncement.xaml 的交互逻辑
- /// </summary>
- public partial class SystemAnnouncementView : WindowBase
- {
- public SystemAnnouncementView(System.Collections.ObjectModel.ObservableCollection<Announcement> announcementList )
- {
- InitializeComponent();
- this.DataContext = new SystemAnnouncementViewModel(announcementList);
- this.Closing+=SystemAnnouncementView_Closing;
- }
- public SystemAnnouncementView()
- {
- InitializeComponent();
- this.DataContext = new SystemAnnouncementViewModel();
- this.Closing+=SystemAnnouncementView_Closing;
- }
- void SystemAnnouncementView_Closing(object sender, System.ComponentModel.CancelEventArgs e)
- {
- e.Cancel = false;
- this.WindowState = WindowState.Minimized;
- this.Opacity = 0;
- }
- public void Shows()
- {
- this.WindowState = WindowState.Normal;
- this.Opacity = 1;
- }
- new public bool? ShowDialog()
- {
- Shows();
- return true;
- }
- }
- }
|