Beispiel #1
0
        public void changeCurrentContent(IContentPage content, bool recordOnHistory = true)
        {
            IContentPage lastContent = currentContent as IContentPage;

            if (lastContent != null)
            {
                lastContent.finalizePage();
            }

            if (lastContent is MyUserControl)
            {
                if (recordOnHistory)
                {
                    history.Push(lastContent as MyUserControl);
                }
            }

            if (content is MyUserControl)
            {
                currentContent = content as MyUserControl;
                currentContent.appear(DockStyle.Fill, mainPanel);

                ContentArgs e = new ContentArgs(content);
                OnContentChange(e);
            }
            content.initializePage();
        }
Beispiel #2
0
 void masterController_ContentChange(object sender, ContentArgs e)
 {
     if (e.currentContent is IContentPage)
     {
         IContentPage foo = e.currentContent as IContentPage;
         updateTitle(foo.accessMenuName, foo.accessImage);
     }
 }
Beispiel #3
0
        /* Event Trigger */
        protected void OnContentChange(ContentArgs e)
        {
            EventHandler <ContentArgs> onContentChange = ContentChange;

            if (onContentChange != null)
            {
                onContentChange(this, e);
            }
        }
Beispiel #4
0
 // This will be call upon content change
 void masterController_ContentChange(object sender, ContentArgs e)
 {
     keyFunction = null;
     if (e.currentContent is IKeyController)
     {
         IKeyController keyController = e.currentContent as IKeyController;
         keyFunction = keyController.getKeyController;
     }
 }
Beispiel #5
0
        /* Event Trigger */
        protected void OnContentChange(ContentArgs e)
        {
            EventHandler <ContentArgs> onContentChange = ContentChanged;

            if (onContentChange != null)
            {
                onContentChange(this, e);
            }
            setFormReturnkey = null;
        }
Beispiel #6
0
 void masterController_ContentChanged(object sender, ContentArgs e)
 {
     if (masterController.history.Count == 0)
     {
         this.Enabled = false;
     }
     else
     {
         this.Enabled = true;
     }
 }
Beispiel #7
0
 void masterController_ContentChanged(object sender, ContentArgs e)
 {
     if (masterController.history.Count == 0)
     {
         this.Enabled = false;
     }
     else
     {
         this.Enabled = true;
     }
 }
Beispiel #8
0
        // This will be call upon content change
        void masterController_ContentChange(object sender, ContentArgs e)
        {
            keyFunction = null;
            if (e.currentContent is IKeyController)
            {
                IKeyController keyController = e.currentContent as IKeyController;
                keyFunction = keyController.getKeyController;
            }

            if (masterController.history.Count == 0)
            {
                back1.enable(false);
            }
            else
            {
                back1.enable(true);
            }
        }
Beispiel #9
0
        public void changeCurrentContent(IContentPage content)
        {
            IContentPage lastContent = currentContent as IContentPage;

            if (lastContent != null)
            {
                lastContent.finalizePage();
            }

            if (content is MyUserControl)
            {
                currentContent = content as MyUserControl;
                currentContent.appear(DockStyle.Fill, mainPanel);

                ContentArgs e = new ContentArgs(content);
                OnContentChange(e);
            }
            content.initializePage();
        }
 /* Event Trigger */
 protected void OnContentChange(ContentArgs e)
 {
     EventHandler<ContentArgs> onContentChange = ContentChange;
     if (onContentChange != null)
         onContentChange(this, e);
 }
        public void changeCurrentContent(IContentPage content)
        {
            IContentPage lastContent = currentContent as IContentPage;
            if (lastContent != null)
                lastContent.finalizePage();

            if (content is MyUserControl)
            {
                currentContent = content as MyUserControl;
                currentContent.appear(DockStyle.Fill, mainPanel);

                ContentArgs e = new ContentArgs(content);
                OnContentChange(e);
            }
            content.initializePage();
        }
Beispiel #12
0
 // This will be call upon content change
 void masterController_ContentChange(object sender, ContentArgs e)
 {
     keyFunction = null;
     if (e.currentContent is IKeyController)
     {
         IKeyController keyController = e.currentContent as IKeyController;
         keyFunction = keyController.getKeyController;
     }
 }
Beispiel #13
0
 void masterController_ContentChange(object sender, ContentArgs e)
 {
     if (e.currentContent is IContentPage)
     {
       IContentPage foo =  e.currentContent as IContentPage;
       updateTitle(foo.accessMenuName, foo.accessImage);
     }
 }
 /* Event Trigger */
 protected void OnContentChange(ContentArgs e)
 {
     EventHandler<ContentArgs> onContentChange = ContentChanged;
     if (onContentChange != null)
         onContentChange(this, e);
     setFormReturnkey = null;
 }
Beispiel #15
0
        // This will be call upon content change
        void masterController_ContentChange(object sender, ContentArgs e)
        {
            keyFunction = null;
            if (e.currentContent is IKeyController)
            {
                IKeyController keyController = e.currentContent as IKeyController;
                keyFunction = keyController.getKeyController;
            }

            if (masterController.history.Count == 0)
                back1.enable(false);
            else
                back1.enable(true);
        }