]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/frame.cpp
reformatted to fit in the page width
[wxWidgets.git] / src / msw / frame.cpp
index c4ab391cd81bbc8be94c6ffe94cf9feacc86c5d3..effd343a88674f207384790913bc6a4f8a5cb651 100644 (file)
 // globals
 // ----------------------------------------------------------------------------
 
-extern const wxChar *wxFrameClassName;
-
 #if wxUSE_MENUS_NATIVE
-extern wxMenu *wxCurrentPopupMenu;
+    extern wxMenu *wxCurrentPopupMenu;
 #endif // wxUSE_MENUS_NATIVE
 
 // ----------------------------------------------------------------------------
@@ -495,6 +493,8 @@ void wxFrame::PositionToolBar()
         else
         {
             tw = width;
+            if ( toolbar->GetWindowStyleFlag() & wxTB_FLAT )
+                th -= 3;
         }
 
         // use the 'real' MSW position here, don't offset relativly to the
@@ -602,8 +602,9 @@ bool wxFrame::HandlePaint()
 #ifndef __WXMICROWIN__
         if ( m_iconized )
         {
-            HICON hIcon = m_icon.Ok() ? GetHiconOf(m_icon)
-                                      : (HICON)GetDefaultIcon();
+            const wxIcon& icon = GetIcon();
+            HICON hIcon = icon.Ok() ? GetHiconOf(icon)
+                                    : (HICON)GetDefaultIcon();
 
             // Hold a pointer to the dc so long as the OnPaint() message
             // is being processed
@@ -837,8 +838,9 @@ long wxFrame::MSWWindowProc(WXUINT message, WXWPARAM wParam, WXLPARAM lParam)
 
         case WM_QUERYDRAGICON:
             {
-                HICON hIcon = m_icon.Ok() ? GetHiconOf(m_icon)
-                                          : (HICON)GetDefaultIcon();
+                const wxIcon& icon = GetIcon();
+                HICON hIcon = icon.Ok() ? GetHiconOf(icon)
+                                        : (HICON)GetDefaultIcon();
                 rc = (long)hIcon;
                 processed = rc != 0;
             }