[Mono-bugs] [Bug 62533][Maj] Changed - Crashes when calling runModalForTypes(null); on NSOpenPanel

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Sun, 8 Aug 2004 15:23:17 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by grompf@sublimeintervention.com.

http://bugzilla.ximian.com/show_bug.cgi?id=62533

--- shadow/62533	2004-08-08 14:58:46.000000000 -0400
+++ shadow/62533.tmp.19147	2004-08-08 15:23:17.000000000 -0400
@@ -274,6 +274,34 @@
 _OR_
   NSOpenPanel op = new NSOpenPanel(new NSRect(200, 180, 300, 300),
                                         (uint)(NSWindowMask.NSMiniaturizableWindowMask | 
 NSWindowMask.NSClosableWindowMask | NSWindowMask.NSTitledWindowMask),
                                         NSBackingStoreType.NSBackingStoreBuffered,
                                         false);
+
+------- Additional Comments From grompf@sublimeintervention.com  2004-08-08 15:23 -------
+urs,
+
+  Please check this patch:
+
+Index: NSObject.addin
+=======================================================
+============
+RCS file: /cvs/public/cocoa-sharp/generator/custom/Foundation/NSObject.addin,v
+retrieving revision 1.27
+diff -u -r1.27 NSObject.addin
+--- NSObject.addin      24 Jul 2004 16:31:06 -0000      1.27
++++ NSObject.addin      8 Aug 2004 18:06:29 -0000
+@@ -139,7 +139,7 @@
+                        else
+                                cls = (IntPtr)NSClasses[myType];
+ 
+-                       SetRaw(NSObject__alloc0(cls),true);
++                       SetRaw(NSObject_init0(NSObject__alloc0(cls)),true);
+                        if (class_getInstanceMethod(cls, 
+NSString.NSSelector("initWithManagedDelegate:")) != IntPtr.Zero) {
+                                _delegate = new BridgeDelegate(this.MethodInvoker);
+                                
+SetRaw(DotNetForwarding_initWithManagedDelegate(Raw,_delegate),_release);
+
+It should resolve this issue going forward.
+