コード例 #1
0
        public ContentApp(Window window)

        {
            HOME = new Command(() => {
                page = new welcomme();
                prev = null;
            });
            clients = new Command(() => {
                page = new ViewClient();
                prev = null;
            });
            processes = new Command(() => {
                page = new PCrad();
                prev = null;
            });
            this.btnmenu = new Command(() => {
                this.vismenu = Visibility.Visible;
                contentWidth = window.Width - 250;
                this.visbtn  = Visibility.Hidden;
                MessageBox.Show("" + menuWidth);
            });
            this.btnclose = new Command(() => {
                this.vismenu = Visibility.Hidden;
                contentWidth = window.Width;
                this.visbtn  = Visibility.Visible;
                MessageBox.Show("" + menuWidth);
            });
            this.window         = window;
            contentHeigth       = window.Height;
            contentWidth        = window.Width - 250;
            window.SizeChanged += SizeChanged;
            this.vismenu        = Visibility.Collapsed;
            this.visbtn         = Visibility.Visible;
        }
コード例 #2
0
ファイル: ContentApp.cs プロジェクト: dr-elhabib/Univpp
        public ContentApp(Window window)

        {
            HOME = new Command(() => {
                page = new welcomme();
                prev = null;
            });
            account = new Command(() => {
                page = new ViewAcount();
                prev = null;
            });
            settings = new Command(() => {
                page = new Settings();
                prev = null;
            });
            logout = new Command(() => {
                login login = new login();
                login.Show();
                App.Current.MainWindow.Close();
                App.Current.MainWindow = login;
                Ico.getValue <db>().GetUnivdb().users.ToList().Where(c => c.id == Ico.getValue <user>().id).ToList().FirstOrDefault().date_gust = DateTime.Now;
                Ico.getValue <db>().savedb();
                ;
            });
            clients = new Command(() => {
                page = new ViewClient();
                prev = null;
            });
            processes = new Command(() => {
                page = new PCrad();
                prev = null;
            });
            this.btnmenu = new Command(() => {
                this.vismenu = Visibility.Visible;
                contentWidth = window.Width - 250;
                this.visbtn  = Visibility.Hidden;
            });
            this.btnclose = new Command(() => {
                this.vismenu = Visibility.Hidden;
                contentWidth = window.Width;
                this.visbtn  = Visibility.Visible;
            });
            this.window         = window;
            contentHeigth       = window.Height;
            contentWidth        = window.Width - 250;
            window.SizeChanged += SizeChanged;
            this.vismenu        = Visibility.Collapsed;
            this.visbtn         = Visibility.Visible;
        }
コード例 #3
0
        public ContentApp(Window window)

        {
            HOME = new Command(() => {
                page = new welcomme();
                prev = null;
            });
            account = new Command(() => {
                page = new ViewAcount();
                prev = null;
            });
            logout = new Command(() => {
                login login = new login();
                login.Show();
                App.Current.MainWindow.Close();
                App.Current.MainWindow = login;
                Ico.Delete <user>();
                ;
            });
            clients = new Command(() => {
                page = new ViewClient();
                prev = null;
            });
            processes = new Command(() => {
                page = new PCrad();
                prev = null;
            });
            this.btnmenu = new Command(() => {
                this.vismenu = Visibility.Visible;
                contentWidth = window.Width - 250;
                this.visbtn  = Visibility.Hidden;
            });
            this.btnclose = new Command(() => {
                this.vismenu = Visibility.Hidden;
                contentWidth = window.Width;
                this.visbtn  = Visibility.Visible;
            });
            this.window         = window;
            contentHeigth       = window.Height;
            contentWidth        = window.Width - 250;
            window.SizeChanged += SizeChanged;
            this.vismenu        = Visibility.Collapsed;
            this.visbtn         = Visibility.Visible;
        }