Author: jackson
Date: 2006-07-10 06:48:44 -0400 (Mon, 10 Jul 2006)
New Revision: 62389

Modified:
   trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
   trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Control.cs
Log:

        * Control.cs (SelectNextControl): When checking the control's
        parent use this instead of ctrl.parent so that null can be
passed
        to SelectNextControl. (I have unit tests for this).
        - Remove unused var.



Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2006-07-10 10:46:49 UTC (rev 62388)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2006-07-10 10:48:44 UTC (rev 62389)
@@ -1,3 +1,10 @@
+2006-07-10  Jackson Harper  <[EMAIL PROTECTED]>
+
+       * Control.cs (SelectNextControl): When checking the control's
+       parent use this instead of ctrl.parent so that null can be passed
+       to SelectNextControl. (I have unit tests for this).
+       - Remove unused var.
+
 2006-07-07  Alexander Olk  <[EMAIL PROTECTED]>
 
        * FileDialog.cs: Don't use brackets for new folders if they exist

Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Control.cs
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Control.cs       
2006-07-10 10:46:49 UTC (rev 62388)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Control.cs       
2006-07-10 10:48:44 UTC (rev 62389)
@@ -939,15 +939,12 @@
                }
 
                internal bool Select(Control control) {
-                       Control                 parent;
                        IContainerControl       container;
 
                        if (control == null) {
                                return false;
                        }
 
-                       parent = control.parent;
-
                        control.is_selected = true;
 
                        container = GetContainerControl();
@@ -3124,7 +3121,7 @@
                                        break;
                                }
 
-                               if (c.CanSelect && ((c.parent == ctl.parent) || 
nested) && (c.tab_stop || !tabStopOnly)) {
+                               if (c.CanSelect && ((c.parent == this) || 
nested) && (c.tab_stop || !tabStopOnly)) {
                                        Select(c);
                                        return true;
                                }

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

Reply via email to