Author: everaldo
Date: 2006-11-27 05:34:27 -0500 (Mon, 27 Nov 2006)
New Revision: 68498

Modified:
   trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
   trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ToolBar.cs
Log:
Fixe size of ToolBar when AutoSize is false

Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2006-11-27 10:09:11 UTC (rev 68497)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2006-11-27 10:34:27 UTC (rev 68498)
@@ -1,5 +1,10 @@
 2006-11-26  Everaldo Canuto  <[EMAIL PROTECTED]>
 
+       * ToolBar.cs: Fixe size of ToolBar when AutoSize is false,
+       it fixes #80015
+
+2006-11-26  Everaldo Canuto  <[EMAIL PROTECTED]>
+
        * ThemeWin32Classic.cs: 
        - Fix toolbar drop down arrow position.
        - Fix drop down appearance when ToolBar.Appearance is normal,

Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ToolBar.cs
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ToolBar.cs       
2006-11-27 10:09:11 UTC (rev 68497)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ToolBar.cs       
2006-11-27 10:34:27 UTC (rev 68498)
@@ -489,15 +489,13 @@
                        Redraw (true, background_image != null);
                }
 
-               bool height_specified = false;
                int requested_height = -1;
 
                protected override void SetBoundsCore (int x, int y, int width, 
int height, BoundsSpecified specified)
                {
-                       if ((specified & BoundsSpecified.Height) != 0) {
+                       if ((specified & BoundsSpecified.Height) != 0)
                                requested_height = height;
-                               height_specified = true;
-                       }
+                       
                        base.SetBoundsCore (x, y, width, height, specified);
                }
 
@@ -932,7 +930,7 @@
                        } else {
                                if (AutoSize)
                                        Height = ht;
-                               else if (!height_specified)
+                               else
                                        Height = DefaultSize.Height;
                                foreach (ToolBarButton button in buttons) {
                                        if (size_specified) {

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

Reply via email to