using Philisense.Congress.ViewModel;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
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.Shapes;

namespace Philisense.Congress
{
    /// <summary>
    /// MainWindow.xaml 的交互逻辑
    /// </summary>
    public partial class MainWindow : Window
    {
        public MainWindow(MainWindowViewModel viewmodel)
        {
            DataContext = viewmodel;
            InitializeComponent();
            FullScreenManager.RepairWpfWindowFullScreenBehavior(this);
            //this.Border_Title.MouseDown += new MouseButtonEventHandler(Border_Title_MouseDown);
            //Loaded += MainWindow_Loaded;
            CongressItem.IsSelected = true;
        }

        #region 窗体基础事件

        void Border_Title_MouseDown(object sender, MouseButtonEventArgs e)
        {
            this.DragMove();
        }
        private void closeButton_Click(object sender, RoutedEventArgs e)
        {
            this.Close();
            //System.Threading.Thread.CurrentThread.Abort();
            Process.GetCurrentProcess().Kill();

        }

        private void maxButton_Click(object sender, RoutedEventArgs e)
        {
            if (WindowState == WindowState.Normal)
                WindowState = WindowState.Maximized;
            else
                WindowState = WindowState.Normal;
        }

        private void mniButton_Click(object sender, RoutedEventArgs e)
        {
            this.WindowState = WindowState.Minimized;
        }

        //private void menuButton_Click(object sender, RoutedEventArgs e)
        //{
        //    Menu.IsOpen = true;
        //} 


        #endregion

        #region 注释
        ////会议管理
        //private void MeetingManageBtn_Click(object sender, RoutedEventArgs e)
        //{
        //    for (int i = 0; i < MeetingCBGrid.Children.Count; i++)
        //    {
        //        MeetingCBGrid.Children.RemoveAt(i);
        //    }

        //    CongressList con = new CongressList();
        //    MeetingCBGrid.Children.Add(con);
        //}
        ////议题管理
        //private void TopicManageBtn_Click(object sender, RoutedEventArgs e)
        //{
        //    for (int i = 0; i < MeetingCBGrid.Children.Count; i++)
        //    {
        //        MeetingCBGrid.Children.RemoveAt(i);
        //    }

        //}
        ////参会人员
        //private void JoinStaffBtn_Click(object sender, RoutedEventArgs e)
        //{
        //    for (int i = 0; i < MeetingCBGrid.Children.Count; i++)
        //    {
        //        MeetingCBGrid.Children.RemoveAt(i);
        //    }


        //}
        ////坐席分配
        //private void AllotSeatBtn_Click(object sender, RoutedEventArgs e)
        //{
        //    for (int i = 0; i < MeetingCBGrid.Children.Count; i++)
        //    {
        //        MeetingCBGrid.Children.RemoveAt(i);
        //    }


        //}
        ////文件管理
        //private void FileManageBtn_Click(object sender, RoutedEventArgs e)
        //{
        //    for (int i = 0; i < MeetingCBGrid.Children.Count; i++)
        //    {
        //        MeetingCBGrid.Children.RemoveAt(i);
        //    }


        //}
        ////证卡管理
        //private void CardManageBtn_Click(object sender, RoutedEventArgs e)
        //{
        //    for (int i = 0; i < MeetingCBGrid.Children.Count; i++)
        //    {
        //        MeetingCBGrid.Children.RemoveAt(i);
        //    }


        //}
        ////字典表管理
        //private void DictionBtn_Click(object sender, RoutedEventArgs e)
        //{
        //    for (int i = 0; i < SystemSetGrid.Children.Count; i++)
        //    {
        //        SystemSetGrid.Children.RemoveAt(i);
        //    }
        //    Controls.Dictionary.DictionaryList dic = new Controls.Dictionary.DictionaryList();
        //    SystemSetGrid.Children.Add(dic);
        //}

        //private void RoomBtn_Click(object sender, RoutedEventArgs e)
        //{
        //    for (int i = 0; i < BaseGrid.Children.Count; i++)
        //    {
        //        BaseGrid.Children.RemoveAt(i);
        //    }
        //    ViewModel.UCControl.Room.RoomListModel roomListModel = new ViewModel.UCControl.Room.RoomListModel();
        //    Controls.Room.RoomList room = new Controls.Room.RoomList(roomListModel);
        //    BaseGrid.Children.Add(room);
        //}

        //private void SeatBtn_Click(object sender, RoutedEventArgs e)
        //{
        //    for (int i = 0; i < BaseGrid.Children.Count; i++)
        //    {
        //        BaseGrid.Children.RemoveAt(i);
        //    }

        //} 
        #endregion

    }
}
