Author: calberto
Date: 2007-09-07 17:25:29 -0400 (Fri, 07 Sep 2007)
New Revision: 85510
Modified:
trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Control.cs
Log:
2007-09-07 Carlos Alberto Cortez <[EMAIL PROTECTED]>
* Control.cs: When updating ZOrder for a child control,
take into account the implicit ones (we need it in our controls
using them). Fixes #82642.
Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
2007-09-07 20:56:18 UTC (rev 85509)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
2007-09-07 21:25:29 UTC (rev 85510)
@@ -1,3 +1,9 @@
+2007-09-07 Carlos Alberto Cortez <[EMAIL PROTECTED]>
+
+ * Control.cs: When updating ZOrder for a child control,
+ take into account the implicit ones (we need it in our controls
+ using them). Fixes #82642.
+
2007-09-07 Jonathan Pobst <[EMAIL PROTECTED]>
* ToolStripItem.cs: Add support for animated images.
Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Control.cs
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Control.cs
2007-09-07 20:56:18 UTC (rev 85509)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Control.cs
2007-09-07 21:25:29 UTC (rev 85510)
@@ -4873,12 +4873,14 @@
private void UpdateZOrderOfChild(Control child) {
if (IsHandleCreated && child.IsHandleCreated &&
(child.parent == this)) {
+ // Need to take into account all controls
int index;
+ Control [] all_controls =
child_controls.GetAllControls ();
- index = child_controls.IndexOf(child);
+ index = Array.IndexOf (all_controls, child);
if (index > 0) {
- XplatUI.SetZOrder(child.Handle,
child_controls[index - 1].Handle, false, false);
+ XplatUI.SetZOrder(child.Handle,
all_controls [index - 1].Handle, false, false);
} else {
IntPtr after = AfterTopMostControl ();
if (after != IntPtr.Zero)
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches