Author: toshok
Date: 2006-11-06 21:34:01 -0500 (Mon, 06 Nov 2006)
New Revision: 67428

Modified:
   trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
   trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/TabControl.cs
Log:
2006-11-06  Chris Toshok  <[EMAIL PROTECTED]>

        * TabControl.cs: in OnGotFocusInternal/OnLostFocusInternal don't
        call GetTabRect with a -1 index.  Fixes #79847.



Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2006-11-07 01:58:46 UTC (rev 67427)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2006-11-07 02:34:01 UTC (rev 67428)
@@ -1,3 +1,8 @@
+2006-11-06  Chris Toshok  <[EMAIL PROTECTED]>
+
+       * TabControl.cs: in OnGotFocusInternal/OnLostFocusInternal don't
+       call GetTabRect with a -1 index.  Fixes #79847.
+
 2006-11-06  Jackson Harper  <[EMAIL PROTECTED]>
 
        * TreeNodeCollection.cs: Update scrollbars after clearing.

Modified: 
trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/TabControl.cs
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/TabControl.cs    
2006-11-07 01:58:46 UTC (rev 67427)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/TabControl.cs    
2006-11-07 02:34:01 UTC (rev 67428)
@@ -556,14 +556,16 @@
 
                internal override void OnGotFocusInternal(EventArgs e) {
                        has_focus = true;
-                       Invalidate(GetTabRect(selected_index));
+                       if (selected_index != -1)
+                               Invalidate(GetTabRect(selected_index));
                        base.OnGotFocusInternal (e);
                }
 
 
                internal override void OnLostFocusInternal(EventArgs e) {
                        has_focus = false;
-                       Invalidate(GetTabRect(selected_index));
+                       if (selected_index != -1)
+                               Invalidate(GetTabRect(selected_index));
                        base.OnLostFocusInternal (e);
                }
 

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

Reply via email to