Ejemplo n.º 1
0
        private FrwDocContent CreateDocContentByIContent(IContent c)
        {
            FrwDocContent cc = new FrwDocContent(c);

            c.ContentContainer = this;
            cc.FormClosed     += Content_FormClosed;
            OnDocContentCreated(cc.ContentControl);
            return(cc);
        }
Ejemplo n.º 2
0
        public void SetNewCaption(string caption)
        {
            Text = caption;
            FrwDocContent c = FindDocContentContainer(this);

            if (c != null)
            {
                c.Text = caption;
            }
        }
Ejemplo n.º 3
0
        private FrwDocContent FindJustDocContentByIContent(IContent c)
        {
            FrwDocContent cc = null;

            foreach (var v in dockPanel.Contents)
            {
                if (v is FrwDocContent && (v as FrwDocContent).ContentControl == c)
                {
                    cc = (v as FrwDocContent);
                }
            }
            return(cc);
        }
Ejemplo n.º 4
0
 protected void AppManager_OnDocContentShowEvent(object sender, DocContentShowEventArgs e)
 {
     if (e.Content.ContentContainer == null)
     {
         throw new Exception("");
     }
     if (e.Content.ContentContainer == this)
     {
         FrwDocContent cc = FindJustDocContentByIContent(e.Content);
         if (cc != null)
         {
             cc.Show(dockPanel);//, DockState.Document);
         }
     }
 }