Esempio n. 1
0
 static Context()
 {
     Context.Parent = new FormMVC();
     Context.Parent.Show();
     Context.Current = Context.Parent;
     NetLibrary.Forms.Animations.OnAnimationEnd += Animations_OnAnimationEnd;
 }
Esempio n. 2
0
 private static void ClearViews(FormMVC form, Control exclude)
 {
     foreach (Control c in form.Controls)
     {
         if (c is View && !c.Equals(exclude))
         {
             NetLibrary.Forms.Animations.Animate(c, Animations.Effect.Center, 250, 0);
         }
     }
 }
Esempio n. 3
0
        internal static void ShowView(View view, ShowType show)
        {
            switch (show)
            {
            case ShowType.Dialog:
                Context.Current = new FormMVC();
                break;

            default:
                if (Context.Current.IsDisposed)
                {
                    Context.Parent = new FormMVC();
                }
                Context.Current      = Context.Parent;
                view.Dock            = DockStyle.Fill;
                Context.Current.View = view;
                break;
            }

            Context.Current.Controls.Add(view);
            Context.ClearViews(Context.Current, view);

            Context.Current.Show();
        }