Author: joncham
Date: 2006-09-11 07:31:10 -0400 (Mon, 11 Sep 2006)
New Revision: 65225

Modified:
   trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
   trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUI.cs
Log:
2006-09-10  Jonathan Chambers  <[EMAIL PROTECTED]>

        * XplatUI.cs: Set default_class_name to be composed
        of current domain id. This allows MWF to be loaded in multiple
        domains on Win32.


Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2006-09-11 11:23:47 UTC (rev 65224)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2006-09-11 11:31:10 UTC (rev 65225)
@@ -1,3 +1,9 @@
+2006-09-10  Jonathan Chambers  <[EMAIL PROTECTED]>
+
+       * XplatUI.cs: Set default_class_name to be composed
+       of current domain id. This allows MWF to be loaded in multiple
+       domains on Win32.
+
 2006-09-09  Miguel de Icaza  <[EMAIL PROTECTED]>
 
        * X11Keyboard.cs: If we are unable to obtain the input method, do

Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUI.cs
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUI.cs       
2006-09-11 11:23:47 UTC (rev 65224)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUI.cs       
2006-09-11 11:31:10 UTC (rev 65225)
@@ -79,7 +79,10 @@
                static XplatUI() {
                        Console.WriteLine("Mono System.Windows.Forms Assembly 
[$auto_build_revision$]");
 
-                       default_class_name="SWFClass";
+                       // Compose name with current domain id because on Win32 
we register class name
+                       // and name must be unique to process. If we load MWF 
into multiple appdomains
+                       // and try to register same class name we fail.
+                       default_class_name = "SWFClass" + 
System.Threading.Thread.GetDomainID().ToString();
 
                        // check for Unix platforms - see FAQ for more details
                        // 
http://www.mono-project.com/FAQ:_Technical#How_to_detect_the_execution_platform_.3F

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

Reply via email to