-  m_defaultIcon = (WXHICON) (wxSTD_FRAME_ICON ? wxSTD_FRAME_ICON : wxDEFAULT_FRAME_ICON);
-
-  // If child windows aren't properly drawn initially, WS_CLIPCHILDREN
-  // could be the culprit. But without it, you can get a lot of flicker.
-
-// TODO:
-/*
-  DWORD msflags = 0;
-  if ((style & wxCAPTION) == wxCAPTION)
-    msflags = WS_OVERLAPPED;
-  else
-    msflags = WS_POPUP;
-
-  if (style & wxMINIMIZE_BOX)
-    msflags |= WS_MINIMIZEBOX;
-  if (style & wxMAXIMIZE_BOX)
-    msflags |= WS_MAXIMIZEBOX;
-  if (style & wxTHICK_FRAME)
-    msflags |= WS_THICKFRAME;
-  if (style & wxSYSTEM_MENU)
-    msflags |= WS_SYSMENU;
-  if ((style & wxMINIMIZE) || (style & wxICONIZE))
-    msflags |= WS_MINIMIZE;
-  if (style & wxMAXIMIZE)
-    msflags |= WS_MAXIMIZE;
-  if (style & wxCAPTION)
-    msflags |= WS_CAPTION;
-  if (style & wxCLIP_CHILDREN)
-    msflags |= WS_CLIPCHILDREN;
-
-  // Keep this in wxFrame because it saves recoding this function
-  // in wxTinyFrame
-#if wxUSE_ITSY_BITSY
-  if (style & wxTINY_CAPTION_VERT)
-    msflags |= IBS_VERTCAPTION;
-  if (style & wxTINY_CAPTION_HORIZ)
-    msflags |= IBS_HORZCAPTION;
-#else
-  if (style & wxTINY_CAPTION_VERT)
-    msflags |= WS_CAPTION;
-  if (style & wxTINY_CAPTION_HORIZ)
-    msflags |= WS_CAPTION;
-#endif
-  if ((style & wxTHICK_FRAME) == 0)
-    msflags |= WS_BORDER;
-
-  WXDWORD extendedStyle = MakeExtendedStyle(style);
-
-#if !defined(__WIN16__) && !defined(__SC__)
-  if (style & wxFRAME_TOOL_WINDOW)
-    extendedStyle |= WS_EX_TOOLWINDOW;
-#endif
-
-  if (style & wxSTAY_ON_TOP)
-    extendedStyle |= WS_EX_TOPMOST;
-
-  m_iconized = FALSE;
-  if ( !wxWindow::MSWCreate(id, parent, wclass, wx_win, title, x, y, width, height,
-         msflags, NULL, extendedStyle) )
-         return FALSE;
-
-  // Seems to be necessary if we use WS_POPUP
-  // style instead of WS_OVERLAPPED
-  if (width > -1 && height > -1)
-    ::PostMessage(GetHwnd(), WM_SIZE, SIZE_RESTORED, MAKELPARAM(width, height));
-
-  return TRUE;
-*/
-  return FALSE;
-}
-
-// Default resizing behaviour - if only ONE subwindow, resize to client
-// rectangle size
-void wxFrame::OnSize(wxSizeEvent& event)
-{
-    // if we're using constraints - do use them
-#if wxUSE_CONSTRAINTS
-    if ( GetAutoLayout() )
+    ULONG                           ulPmFlags = 0;
+    ULONG                           ulExtraFlags = 0;
+    ULONG                           ulTempFlags = FCF_TITLEBAR |
+                                                  FCF_SYSMENU |
+                                                  FCF_MINBUTTON |
+                                                  FCF_MAXBUTTON |
+                                                  FCF_SIZEBORDER |
+                                                  FCF_ICON |
+                                                  FCF_MENU |
+                                                  FCF_ACCELTABLE |
+                                                  FCF_SHELLPOSITION |
+                                                  FCF_TASKLIST;
+
+    m_hDefaultIcon = (WXHICON) (wxSTD_FRAME_ICON ? wxSTD_FRAME_ICON : wxDEFAULT_FRAME_ICON);
+
+    if ((ulStyle & wxCAPTION) == wxCAPTION)
+        ulPmFlags = FCF_TASKLIST;
+    else
+        ulPmFlags = FCF_NOMOVEWITHOWNER;
+
+    if (ulStyle & wxMINIMIZE_BOX)
+        ulPmFlags |= FCF_MINBUTTON;
+    if (ulStyle & wxMAXIMIZE_BOX)
+        ulPmFlags |= FCF_MAXBUTTON;
+    if (ulStyle & wxTHICK_FRAME)
+        ulPmFlags |= FCF_DLGBORDER;
+    if (ulStyle & wxSYSTEM_MENU)
+        ulPmFlags |= FCF_SYSMENU;
+    if ((ulStyle & wxMINIMIZE) || (ulStyle & wxICONIZE))
+        ulPmFlags |= WS_MINIMIZED;
+    if (ulStyle & wxMAXIMIZE)
+        ulPmFlags |= WS_MAXIMIZED;
+    if (ulStyle & wxCAPTION)
+        ulPmFlags |= FCF_TASKLIST;
+    if (ulStyle & wxCLIP_CHILDREN)