Author: jackson
Date: 2005-06-13 10:40:52 -0400 (Mon, 13 Jun 2005)
New Revision: 45875

Added:
   trunk/winforms/mdi/
   trunk/winforms/mdi/Makefile
   trunk/winforms/mdi/swf-mdi.cs
Log:

        Add a very simple mdi test.



Added: trunk/winforms/mdi/Makefile
===================================================================
--- trunk/winforms/mdi/Makefile 2005-06-13 14:33:08 UTC (rev 45874)
+++ trunk/winforms/mdi/Makefile 2005-06-13 14:40:52 UTC (rev 45875)
@@ -0,0 +1,10 @@
+all: mono
+
+mono: swf-mdi.cs
+       mcs -g swf-mdi.cs /r:System.Windows.Forms.dll /r:System.Drawing.dll
+
+dotnet: swf-treeview.cs
+       csc swf-mdi.cs /r:System.Windows.Forms.dll /r:System.Drawing.dll
+
+clean:
+       rm swf-mdi.exe -r -f

Added: trunk/winforms/mdi/swf-mdi.cs
===================================================================
--- trunk/winforms/mdi/swf-mdi.cs       2005-06-13 14:33:08 UTC (rev 45874)
+++ trunk/winforms/mdi/swf-mdi.cs       2005-06-13 14:40:52 UTC (rev 45875)
@@ -0,0 +1,46 @@
+//
+// swf-mdi.cs
+//
+// Author(s):
+//      Jackson Harper ([EMAIL PROTECTED])
+//
+// Copyright (c) 2005 Novell, Inc. (http://www.novell.com)
+//
+
+using System;
+using System.Drawing;
+using System.Windows.Forms;
+
+public class MainForm : Form {
+
+        private Form form_one;
+        private Form form_two;
+               
+        public MainForm()
+        {
+                IsMdiContainer = true;
+                       
+                form_one = new Form();
+                form_one.MdiParent = this;
+                form_one.Name = "One";
+                form_one.Text = "One";
+                form_one.BackColor = Color.Red;
+                form_one.Show ();
+
+                form_two = new System.Windows.Forms.Form();
+                form_two.Left = form_one.Right + 10;
+                form_two.MdiParent = this;
+                form_two.Name = "Two";
+                form_two.Text = "Two";
+                form_two.BackColor = Color.Black;
+                form_two.Show ();
+
+                Width = form_one.Width * 2;
+                Height = form_one.Height * 2;
+        }
+
+        public static void Main (string [] args)
+        {
+                Application.Run (new MainForm ());
+        }
+}


Property changes on: trunk/winforms/mdi/swf-mdi.cs
___________________________________________________________________
Name: svn:executable
   + *

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to