Ejemplo n.º 1
0
 private void AddToPanel(System.Type type, BaseView view)
 {
     view.set_Visible(false);
     view.set_Location(new System.Drawing.Point(8, 8));
     this.panel.Controls.Add(view);
     view.set_TabIndex(1);
     this.views.Add(type, view);
 }
Ejemplo n.º 2
0
 public void UnvisibleShowView()
 {
     if (this.showView != null)
     {
         this.showView.set_Visible(false);
         this.showView = null;
     }
     this.btnSave.set_Visible(false);
 }
Ejemplo n.º 3
0
 public CollectionForm(ObjectWithId owid, string title, BaseView view)
     : this()
 {
     this.SelectedObject = owid;
     this.set_Text(title);
     this.view = view;
     this.view.ClearView();
     this.view.ObjectWithId = owid;
     this.view.set_Location(new System.Drawing.Point(8, 8));
     base.Controls.Add(this.view);
     base.set_Size(new System.Drawing.Size((int) (this.view.get_Width() + 0x10), (int) (this.view.get_Height() + 90)));
     this.btnOk.set_Location(new System.Drawing.Point((int) (base.get_Width() - 200), (int) (this.view.get_Height() + 0x18)));
     this.btnCancel.set_Location(new System.Drawing.Point((int) (this.btnOk.get_Right() + 8), this.btnOk.get_Top()));
 }
Ejemplo n.º 4
0
 private void ShowView(BaseView view)
 {
     if ((this.showView != null) && !this.showView.Equals(view))
     {
         this.UnvisibleShowView();
     }
     view.set_Visible(true);
     view.set_TabIndex(1);
     this.showView = view;
     this.btnSave.set_Location(new System.Drawing.Point(0x10, (int) (view.get_Height() + 8)));
     this.btnSave.set_Visible(view.ShowSaveButton);
 }
 public CalcOperationGroupContentsForm(ObjectWithId owid, string title, BaseView view)
     : base(owid, title, view)
 {
 }
Ejemplo n.º 6
0
 private void AddViewToPanel(BaseView view)
 {
     this.panel.SuspendLayout();
     view.set_Visible(false);
     view.set_TabIndex(1);
     this.panel.Controls.Add(view);
     view.set_Location(new System.Drawing.Point());
     if (view.ExtendHorizontally && view.ExtendVertically)
     {
         view.set_Width(this.panel.ClientSize.get_Width());
         if (view.ShowSaveButton)
         {
             view.set_Height((int) ((this.panel.ClientSize.get_Height() - this.btnSave.get_Height()) - 0x10));
         }
         else
         {
             view.set_Height(this.panel.ClientSize.get_Height());
         }
         view.set_Anchor(System.Windows.Forms.AnchorStyles.Right | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Top);
     }
     else
     {
         if (view.ExtendHorizontally)
         {
             view.set_Width(this.panel.ClientSize.get_Width());
             view.set_Anchor(System.Windows.Forms.AnchorStyles.Right | System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Top);
         }
         if (view.ExtendVertically)
         {
             if (view.ShowSaveButton)
             {
                 view.set_Height((int) ((this.panel.ClientSize.get_Height() - this.btnSave.get_Height()) - 0x10));
             }
             else
             {
                 view.set_Height(this.panel.ClientSize.get_Height());
             }
             view.set_Anchor(System.Windows.Forms.AnchorStyles.Left | System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Top);
         }
     }
     this.panel.ResumeLayout(false);
 }
Ejemplo n.º 7
0
 private void AddView(System.Type parent, System.Type child, BaseView view)
 {
     this.AddViewToPanel(view);
     this.views.Add((long) (parent.GetHashCode() + child.GetHashCode()), view);
 }
Ejemplo n.º 8
0
 private void AddView(System.Type type, BaseView view)
 {
     this.AddViewToPanel(view);
     this.views.Add((long) type.GetHashCode(), view);
 }
Ejemplo n.º 9
0
 private void ShowView(BaseView view)
 {
     Manager.ChiefMainForm.SuspendLayout();
     if ((this.showView != null) && !this.showView.Equals(view))
     {
         this.UnvisibleShowView();
     }
     view.set_TabIndex(1);
     view.set_Visible(true);
     this.showView = view;
     this.btnSave.set_Location(new System.Drawing.Point(0x10, (int) (view.get_Height() + 8)));
     this.btnSave.set_Visible(view.ShowSaveButton);
     Manager.ChiefMainForm.ResumeLayout(false);
 }