init a NSWindow in monomac
===

This is driving me nuts, I've tried everything for about a week. Hope some kind sole can help. I'm trying to create a new modal popup color picker. However, StopModal() keeps creating a new window.

I created a new NS window programatically a little like this:

class ColorPicker:NSWindow{

	void ColorPicker(IntPtr Value):base(Value){
	}

	void ColorPicker(Color StartColor){
	//Set up window here.
	}

	public void ShowModal(NSWindow NewParent){
		this.ParentWindow = NewParent;
		NSApplication.SharedApplication.RunModalForWindow(this);	
		return DialogResult;
	}
}

I create like this:

ColorPicker CP=new ColorPicker(Color.Red);

Then show it

CP.ShowDialog(MyMainWindow);

I have a button on the form that closes it and calls

NSApplication.SharedApplication.StopModal();

But for some reason this creates a second window by calling:

void ColorPicker(IntPtr Value):base(Value){
}

Then I get leak errors and soon it crashes:

NativeRelease ERROR]: type: ColorPicker handle: 137041376 count: 2 gchandle: 0

objc[350]: Object 0x103070 of class NSConcreteMapTable autoreleased with no pool in place - just leaking - break on objc_autoreleaseNoPool() to debug
