Author: jackson
Date: 2007-03-30 09:45:03 -0500 (Fri, 30 Mar 2007)
New Revision: 75199

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

        * TextBox.cs: Only select all on initial focus if the user has
        * not
        specified a selection area.



Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2007-03-30 14:26:03 UTC (rev 75198)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2007-03-30 14:45:03 UTC (rev 75199)
@@ -1,3 +1,8 @@
+2007-03-30  Jackson Harper  <[EMAIL PROTECTED]>
+
+       * TextBox.cs: Only select all on initial focus if the user has not
+       specified a selection area.
+
 2007-03-30  Jonathan Pobst  <[EMAIL PROTECTED]>
 
        * UserControl.cs: Override CreateParams.

Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/TextBox.cs
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/TextBox.cs       
2007-03-30 14:26:03 UTC (rev 75198)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/TextBox.cs       
2007-03-30 14:45:03 UTC (rev 75199)
@@ -337,7 +337,7 @@
 
                protected override void OnGotFocus(EventArgs e) {
                        base.OnGotFocus (e);
-                       if (!has_been_focused)
+                       if (selection_length == -1 && !has_been_focused)
                                SelectAll ();
                        has_been_focused = true;
                }

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

Reply via email to