]> git.saurik.com Git - wxWidgets.git/commitdiff
refresh during window delete (if root window deleted) removed
authorStefan Csomor <csomor@advancedconcepts.ch>
Sun, 1 Jul 2001 20:57:09 +0000 (20:57 +0000)
committerStefan Csomor <csomor@advancedconcepts.ch>
Sun, 1 Jul 2001 20:57:09 +0000 (20:57 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@10749 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/generic/listctrl.cpp
src/mac/carbon/window.cpp
src/mac/window.cpp

index 38985b43ff88f0e94900428509e362ce118c11b2..6d25185ea9bb4e52fdeecaee9910d7aaae07bd0d 100644 (file)
@@ -1719,7 +1719,7 @@ void wxListMainWindow::OnPaint( wxPaintEvent &WXUNUSED(event) )
         {
             m_lines[i].Draw( &dc );
             // Draw horizontal rule if required
-            if (GetWindowStyle() & wxLC_HRULES)
+            if (m_mode & wxLC_HRULES)
             {
                 dc.SetPen(pen);
                 dc.SetBrush(* wxTRANSPARENT_BRUSH);
@@ -1728,7 +1728,7 @@ void wxListMainWindow::OnPaint( wxPaintEvent &WXUNUSED(event) )
         }
 
         // Draw last horizontal rule
-        if ((i > (size_t) (y_s / lineSpacing)) && (GetWindowStyle() & wxLC_HRULES))
+        if ((i > (size_t) (y_s / lineSpacing)) && (m_mode & wxLC_HRULES))
         {
             dc.SetPen(pen);
             dc.SetBrush(* wxTRANSPARENT_BRUSH);
@@ -1736,7 +1736,7 @@ void wxListMainWindow::OnPaint( wxPaintEvent &WXUNUSED(event) )
        }
 
         // Draw vertical rules if required
-        if ((GetWindowStyle() & wxLC_VRULES) && (GetItemCount() > 0))
+        if ((m_mode & wxLC_VRULES) && (GetItemCount() > 0))
         {
             int col = 0;
             wxRect firstItemRect;
index 62f65318ea5e38ce450fa140d9805abe153bafbc..edc7d866a8004aeafd795eb68bb2dced560eb4c8 100644 (file)
@@ -775,7 +775,17 @@ bool wxWindow::Show(bool show)
          }
        }
        MacSuperShown( show ) ;
-       Refresh() ;
+       if ( !show )
+       {
+           WindowRef window = GetMacRootWindow() ;
+           wxWindow* win = wxFindWinFromMacWindow( window ) ;
+           if ( !win->m_isBeingDeleted )
+               Refresh() ;     
+       }
+       else
+       {
+       Refresh() ;     
+       }
 
     return TRUE;
 }
index 62f65318ea5e38ce450fa140d9805abe153bafbc..edc7d866a8004aeafd795eb68bb2dced560eb4c8 100644 (file)
@@ -775,7 +775,17 @@ bool wxWindow::Show(bool show)
          }
        }
        MacSuperShown( show ) ;
-       Refresh() ;
+       if ( !show )
+       {
+           WindowRef window = GetMacRootWindow() ;
+           wxWindow* win = wxFindWinFromMacWindow( window ) ;
+           if ( !win->m_isBeingDeleted )
+               Refresh() ;     
+       }
+       else
+       {
+       Refresh() ;     
+       }
 
     return TRUE;
 }