Author: gnorton
Date: 2005-05-12 16:52:22 -0400 (Thu, 12 May 2005)
New Revision: 44467

Modified:
   trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
   trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUIOSX.cs
Log:
2005-05-11  Geoff Norton  <[EMAIL PROTECTED]>

        * XplatUIOSX.cs: Avoid painting into invisible views.  Fixes #74926




Modified: trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2005-05-12 20:40:47 UTC (rev 44466)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ChangeLog        
2005-05-12 20:52:22 UTC (rev 44467)
@@ -1,3 +1,7 @@
+2005-05-11  Geoff Norton  <[EMAIL PROTECTED]>
+
+       * XplatUIOSX.cs: Avoid painting into invisible views.  Fixes #74926
+
 2005-05-11  Peter Bartok  <[EMAIL PROTECTED]>
 
        * LinkArea.cs: Added and implemented LinkAreaTypeConverter class

Modified: 
trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUIOSX.cs
===================================================================
--- trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUIOSX.cs    
2005-05-12 20:40:47 UTC (rev 44466)
+++ trunk/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUIOSX.cs    
2005-05-12 20:52:22 UTC (rev 44467)
@@ -424,9 +424,9 @@
                        switch (eventKind) {
                                case OSXConstants.kEventControlDraw: {
                                        
-                                       if(!hwnd.visible)
+                                       if(!hwnd.visible || !HIViewIsVisible 
(handle))
                                                return 0;
-                                       
+
                                        /*
                                        IntPtr rgnhandle = IntPtr.Zero;
                                        GetEventParameter (inEvent, 
OSXConstants.EventParamName.kEventParamRgnHandle, 
OSXConstants.EventParamType.typeQDRgnHandle, IntPtr.Zero, (uint)Marshal.SizeOf 
(typeof (IntPtr)), IntPtr.Zero, ref rgnhandle);
@@ -1295,7 +1295,7 @@
                internal override void Invalidate (IntPtr handle, Rectangle rc, 
bool clear) {
                        Hwnd hwnd = Hwnd.ObjectFromHandle (handle);
                        
-                       if (hwnd.visible) {
+                       if (hwnd.visible && HIViewIsVisible (handle)) {
                                MSG msg = new MSG ();
                                msg.hwnd = hwnd.Handle;
                                msg.wParam = IntPtr.Zero;
@@ -1734,7 +1734,7 @@
                internal override void UpdateWindow(IntPtr handle) {
                        Hwnd hwnd = Hwnd.ObjectFromHandle (handle);
                        
-                       if (hwnd.visible && !hwnd.expose_pending) {
+                       if (hwnd.visible && HIViewIsVisible (handle) && 
!hwnd.expose_pending) {
                                MSG msg = new MSG ();
                                msg.message = Msg.WM_PAINT;
                                msg.hwnd = hwnd.Handle;

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

Reply via email to