[Mono-bugs] [Bug 79667][Nor] Changed - MessageBox focus issues

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Fri Oct 20 15:36:18 EDT 2006


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 shana.ufie at gmail.com.

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

--- shadow/79667	2006-10-16 12:26:04.000000000 -0400
+++ shadow/79667.tmp.11801	2006-10-20 15:36:18.000000000 -0400
@@ -12,12 +12,13 @@
 ReportedBy: kuba.brecka at gmail.com               
 QAContact: mono-bugs at ximian.com
 TargetMilestone: 1_2
 URL: 
 Cc: 
 Summary: MessageBox focus issues
+BugsThisDependsOn: 79384
 
 1. bug: You cannot click the messagebox with a [SPACE] key. Obviously the
 OK button in the messagebox doesn't have focus.
 2. bug: You cannot close the messagebox by hitting the [ESCAPE] key.
 3. bug: After clicking the OK button (either with the mouse or the Enter
 key) or closing the messagebox by clicking the X symbol in the top right
@@ -54,6 +55,39 @@
 All that happens on Windows XP SP1 using Mono 1.1.18. Don't know if it
 is a Linux issue too.
 
 
 ------- Additional Comments From toshok at ximian.com  2006-10-16 12:25 -------
 On linux #1 and #3 work.  #2 doesn't.
+
+------- Additional Comments From shana.ufie at gmail.com  2006-10-20 15:36 -------
+A few notes on this so I won't forget...
+
+#1 is a problem related to the default focus of a control inside a
+container, see bug #79384.
+
+#3 is a few things:
+
+ - the messagebox form is getting created and added to the
+Controlcontrols list and queued to the toplevels list, but when the
+user clicks Ok, the MessageBox is getting hidden and dequeued, but not
+getting removed from the Control.controls list. This causes
+MessageBoxes to pile up on the Control.controls list, so when the
+activation messages are sent, these get the last activate messages
+after the main app form
+
+- the Application.MWFThread.Current.Context.MainForm is getting
+changed when the MessageBox is shown, but it's not getting reset back
+to the main app form when the MessageBox is closed, so that messes the
+focus stuff
+
+- The MessageBox is not really getting destroyed, it's just getting
+hidden, though it's never recovered back
+
+- According to the msdn docs for EnableWindow:
+"if an application is displaying a modeless dialog box and has
+disabled its main window, the application must enable the main window
+before destroying the dialog box. Otherwise, another window will
+receive the keyboard focus and be activated"
+
+This last point is the main problem once the others are solved.
+


More information about the mono-bugs mailing list