Bug 593577 - Get rid of nsContentType. r=roc a=a
authorMasatoshi Kimura <VYV03354@nifty.ne.jp>
Mon, 20 Sep 2010 15:40:13 +0200
changeset 54355 cec73417efafd7e7c6a47229ebf2aa1f328f489e
parent 54354 b439e73f33b78b5494430d701f7286eecbc4a9ed
child 54356 ac0f0d30e66a80990450925cf0f0ef39529a3ab7
push id15863
push userdgottwald@mozilla.com
push dateMon, 20 Sep 2010 13:40:45 +0000
treeherdermozilla-central@cec73417efaf [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersroc, a
bugs593577
milestone2.0b7pre
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 593577 - Get rid of nsContentType. r=roc a=a
content/base/src/nsFrameLoader.cpp
embedding/browser/webBrowser/nsWebBrowser.cpp
layout/base/nsDocumentViewer.cpp
layout/xul/base/src/nsMenuPopupFrame.cpp
view/public/nsIView.h
view/src/nsView.cpp
view/src/nsView.h
widget/public/nsWidgetInitData.h
widget/src/os2/nsWindow.cpp
widget/src/windows/nsWindow.cpp
widget/src/windows/nsWindow.h
widget/src/windows/nsWindowDefs.h
xpfe/appshell/src/nsAppShellService.cpp
--- a/content/base/src/nsFrameLoader.cpp
+++ b/content/base/src/nsFrameLoader.cpp
@@ -608,28 +608,23 @@ nsFrameLoader::Show(PRInt32 marginWidth,
 {
   if (mInShow) {
     return PR_FALSE;
   }
   // Reset mInShow if we exit early.
   AutoResetInShow resetInShow(this);
   mInShow = PR_TRUE;
 
-  nsContentType contentType;
-
   nsresult rv = MaybeCreateDocShell();
   if (NS_FAILED(rv)) {
     return PR_FALSE;
   }
 
 #ifdef MOZ_IPC
-  if (mRemoteFrame) {
-    contentType = eContentTypeContent;
-  }
-  else
+  if (!mRemoteFrame)
 #endif
   {
     if (!mDocShell)
       return false;
     nsCOMPtr<nsIPresShell> presShell;
     mDocShell->GetPresShell(getter_AddRefs(presShell));
     if (presShell)
       return true;
@@ -639,32 +634,16 @@ nsFrameLoader::Show(PRInt32 marginWidth,
 
     nsCOMPtr<nsIScrollable> sc = do_QueryInterface(mDocShell);
     if (sc) {
       sc->SetDefaultScrollbarPreferences(nsIScrollable::ScrollOrientation_X,
                                          scrollbarPrefX);
       sc->SetDefaultScrollbarPreferences(nsIScrollable::ScrollOrientation_Y,
                                          scrollbarPrefY);
     }
-
-
-    nsCOMPtr<nsIDocShellTreeItem> treeItem = do_QueryInterface(mDocShell);
-    NS_ASSERTION(treeItem,
-                 "Found a nsIDocShell that isn't a nsIDocShellTreeItem.");
-
-    PRInt32 itemType;
-    treeItem->GetItemType(&itemType);
-
-    if (itemType == nsIDocShellTreeItem::typeChrome)
-      contentType = eContentTypeUI;
-    else {
-      nsCOMPtr<nsIDocShellTreeItem> sameTypeParent;
-      treeItem->GetSameTypeParent(getter_AddRefs(sameTypeParent));
-      contentType = sameTypeParent ? eContentTypeContentFrame : eContentTypeContent;
-    }
   }
 
   nsIView* view = frame->EnsureInnerView();
   if (!view)
     return PR_FALSE;
 
 #ifdef MOZ_IPC
   if (mRemoteFrame) {
--- a/embedding/browser/webBrowser/nsWebBrowser.cpp
+++ b/embedding/browser/webBrowser/nsWebBrowser.cpp
@@ -1148,18 +1148,16 @@ NS_IMETHODIMP nsWebBrowser::Create()
       // Create the widget
         mInternalWidget = do_CreateInstance(kChildCID, &rv);
         NS_ENSURE_SUCCESS(rv, rv);
 
       docShellParentWidget = mInternalWidget;
       nsWidgetInitData  widgetInit;
 
       widgetInit.clipChildren = PR_TRUE;
-      widgetInit.mContentType = (mContentType == typeChrome || 
-        mContentType == typeChromeWrapper)? eContentTypeUI: eContentTypeContent;
 
       widgetInit.mWindowType = eWindowType_child;
       nsIntRect bounds(mInitInfo->x, mInitInfo->y, mInitInfo->cx, mInitInfo->cy);
       
       mInternalWidget->SetClientData(static_cast<nsWebBrowser *>(this));
       mInternalWidget->Create(nsnull, mParentNativeWindow, bounds, nsWebBrowser::HandleEvent,
                               nsnull, nsnull, nsnull, &widgetInit);  
       }
--- a/layout/base/nsDocumentViewer.cpp
+++ b/layout/base/nsDocumentViewer.cpp
@@ -2324,20 +2324,16 @@ DocumentViewerImpl::MakeWindow(const nsS
     // pass in a native widget to be the parent widget ONLY if the view hierarchy will stand alone.
     // otherwise the view will find its own parent widget and "do the right thing" to
     // establish a parent/child widget relationship
     nsWidgetInitData initData;
     nsWidgetInitData* initDataPtr;
     if (!mParentWidget) {
       initDataPtr = &initData;
       initData.mWindowType = eWindowType_invisible;
-
-      initData.mContentType =
-        nsContentUtils::IsInChromeDocshell(mDocument) ?
-          eContentTypeUI : eContentTypeContent;
     } else {
       initDataPtr = nsnull;
     }
 
     if (mAttachedToParent) {
       // Reuse the top level parent widget.
       rv = view->AttachToTopLevelWidget(mParentWidget);
     }
--- a/layout/xul/base/src/nsMenuPopupFrame.cpp
+++ b/layout/xul/base/src/nsMenuPopupFrame.cpp
@@ -315,17 +315,17 @@ nsMenuPopupFrame::CreateWidgetForView(ns
     if (!treeOwner) return NS_ERROR_FAILURE;
 
     nsCOMPtr<nsIBaseWindow> baseWindow(do_QueryInterface(treeOwner));
     if (baseWindow)
       baseWindow->GetMainWidget(getter_AddRefs(parentWidget));
   }
 
   aView->CreateWidgetForPopup(&widgetData, parentWidget,
-                              PR_TRUE, PR_TRUE, eContentTypeUI);
+                              PR_TRUE, PR_TRUE);
 
   nsIWidget* widget = aView->GetWidget();
   widget->SetTransparencyMode(mode);
   widget->SetWindowShadowStyle(GetShadowStyle());
 
   // most popups don't have a title so avoid setting the title if there isn't one
   if (!title.IsEmpty()) {
     widget->SetTitle(title);
--- a/view/public/nsIView.h
+++ b/view/public/nsIView.h
@@ -57,18 +57,18 @@ class nsIWidget;
 // show - the layer is shown irrespective of the visibility of 
 //        the layer's parent.
 enum nsViewVisibility {
   nsViewVisibility_kHide = 0,
   nsViewVisibility_kShow = 1
 };
 
 #define NS_IVIEW_IID    \
-  { 0xba00349c, 0xe58a, 0x436a, \
-    { 0x9f, 0x1f, 0x05, 0xb3, 0xdd, 0x9d, 0x9d, 0x36 } }
+  { 0xd0c2cf54, 0xb527, 0x4d8e, \
+    { 0xba, 0x87, 0x39, 0x03, 0xa7, 0xc4, 0x13, 0xe1 } }
 
 // Public view flags are defined in this file
 #define NS_VIEW_FLAGS_PUBLIC              0x00FF
 // Private view flags are private to the view module,
 // and are defined in nsView.h
 #define NS_VIEW_FLAGS_PRIVATE             0xFF00
 
 // Public view flags
@@ -279,49 +279,43 @@ public:
 
   /**
    * Create a widget to associate with this view.  This variant of
    * CreateWidget*() will look around in the view hierarchy for an
    * appropriate parent widget for the view.
    *
    * @param aWidgetInitData data used to initialize this view's widget before
    *        its create is called.
-   * @param aContentType is either content, UI or inherit from parent window.
-   *        This is used to expose what type of window this is to 
-   *        assistive technology like screen readers.
    * @return error status
    */
   nsresult CreateWidget(nsWidgetInitData *aWidgetInitData = nsnull,
                         PRBool aEnableDragDrop = PR_TRUE,
-                        PRBool aResetVisibility = PR_TRUE,
-                        nsContentType aContentType = eContentTypeInherit);
+                        PRBool aResetVisibility = PR_TRUE);
 
   /**
    * Create a widget for this view with an explicit parent widget.
    * |aParentWidget| must be nonnull.  The other params are the same
    * as for |CreateWidget()|.
    */
   nsresult CreateWidgetForParent(nsIWidget* aParentWidget,
                                  nsWidgetInitData *aWidgetInitData = nsnull,
                                  PRBool aEnableDragDrop = PR_TRUE,
-                                 PRBool aResetVisibility = PR_TRUE,
-                                 nsContentType aContentType = eContentTypeInherit);
+                                 PRBool aResetVisibility = PR_TRUE);
 
   /**
    * Create a popup widget for this view.  Pass |aParentWidget| to
    * explicitly set the popup's parent.  If it's not passed, the view
    * hierarchy will be searched for an appropriate parent widget.  The
    * other params are the same as for |CreateWidget()|, except that
    * |aWidgetInitData| must be nonnull.
    */
   nsresult CreateWidgetForPopup(nsWidgetInitData *aWidgetInitData,
                                 nsIWidget* aParentWidget = nsnull,
                                 PRBool aEnableDragDrop = PR_TRUE,
-                                PRBool aResetVisibility = PR_TRUE,
-                                nsContentType aContentType = eContentTypeInherit);
+                                PRBool aResetVisibility = PR_TRUE);
 
   /**
    * Attach/detach a top level widget from this view. When attached, the view
    * updates the widget's device context and allows the view to begin receiving
    * gecko events. The underlying base window associated with the widget will
    * continues to receive events it expects.
    *
    * An attached widget will not be destroyed when the view is destroyed,
--- a/view/src/nsView.cpp
+++ b/view/src/nsView.cpp
@@ -656,69 +656,61 @@ static PRInt32 FindNonAutoZIndex(nsView*
     }
     aView = aView->GetParent();
   }
   return 0;
 }
 
 nsresult nsIView::CreateWidget(nsWidgetInitData *aWidgetInitData,
                                PRBool aEnableDragDrop,
-                               PRBool aResetVisibility,
-                               nsContentType aContentType)
+                               PRBool aResetVisibility)
 {
   return Impl()->CreateWidget(aWidgetInitData,
-                              aEnableDragDrop, aResetVisibility,
-                              aContentType);
+                              aEnableDragDrop, aResetVisibility);
 }
 
 nsresult nsIView::CreateWidgetForParent(nsIWidget* aParentWidget,
                                         nsWidgetInitData *aWidgetInitData,
                                         PRBool aEnableDragDrop,
-                                        PRBool aResetVisibility,
-                                        nsContentType aContentType)
+                                        PRBool aResetVisibility)
 {
   return Impl()->CreateWidgetForParent(aParentWidget, aWidgetInitData,
-                                       aEnableDragDrop, aResetVisibility,
-                                       aContentType);
+                                       aEnableDragDrop, aResetVisibility);
 }
 
 nsresult nsIView::CreateWidgetForPopup(nsWidgetInitData *aWidgetInitData,
                                        nsIWidget* aParentWidget,
                                        PRBool aEnableDragDrop,
-                                       PRBool aResetVisibility,
-                                       nsContentType aContentType)
+                                       PRBool aResetVisibility)
 {
   return Impl()->CreateWidgetForPopup(aWidgetInitData, aParentWidget,
-                                      aEnableDragDrop, aResetVisibility,
-                                      aContentType);
+                                      aEnableDragDrop, aResetVisibility);
 }
 
 struct DefaultWidgetInitData : public nsWidgetInitData {
   DefaultWidgetInitData() : nsWidgetInitData()
   {
     mWindowType = eWindowType_child;
     clipChildren = PR_TRUE;
     clipSiblings = PR_TRUE;
   }
 };
 
 nsresult nsView::CreateWidget(nsWidgetInitData *aWidgetInitData,
                               PRBool aEnableDragDrop,
-                              PRBool aResetVisibility,
-                              nsContentType aContentType)
+                              PRBool aResetVisibility)
 {
   AssertNoWindow();
   NS_ABORT_IF_FALSE(!aWidgetInitData ||
                     aWidgetInitData->mWindowType != eWindowType_popup,
                     "Use CreateWidgetForPopup");
 
   DefaultWidgetInitData defaultInitData;
   PRBool initDataPassedIn = !!aWidgetInitData;
   aWidgetInitData = aWidgetInitData ? aWidgetInitData : &defaultInitData;
-  aWidgetInitData->mContentType = aContentType;
   defaultInitData.mListenForResizes =
     (!initDataPassedIn && GetParent() &&
      GetParent()->GetViewManager() != mViewManager);
 
   nsIntRect trect = CalcWidgetBounds(aWidgetInitData->mWindowType);
 
   nsCOMPtr<nsIDeviceContext> dx;
   mViewManager->GetDeviceContext(*getter_AddRefs(dx));
@@ -742,28 +734,26 @@ nsresult nsView::CreateWidget(nsWidgetIn
   InitializeWindow(aEnableDragDrop, aResetVisibility);
 
   return NS_OK;
 }
 
 nsresult nsView::CreateWidgetForParent(nsIWidget* aParentWidget,
                                        nsWidgetInitData *aWidgetInitData,
                                        PRBool aEnableDragDrop,
-                                       PRBool aResetVisibility,
-                                       nsContentType aContentType)
+                                       PRBool aResetVisibility)
 {
   AssertNoWindow();
   NS_ABORT_IF_FALSE(!aWidgetInitData ||
                     aWidgetInitData->mWindowType != eWindowType_popup,
                     "Use CreateWidgetForPopup");
   NS_ABORT_IF_FALSE(aParentWidget, "Parent widget required");
 
   DefaultWidgetInitData defaultInitData;
   aWidgetInitData = aWidgetInitData ? aWidgetInitData : &defaultInitData;
-  aWidgetInitData->mContentType = aContentType;
 
   nsIntRect trect = CalcWidgetBounds(aWidgetInitData->mWindowType);
 
   nsCOMPtr<nsIDeviceContext> dx;
   mViewManager->GetDeviceContext(*getter_AddRefs(dx));
 
   mWindow =
     aParentWidget->CreateChild(trect, ::HandleEvent,
@@ -775,18 +765,17 @@ nsresult nsView::CreateWidgetForParent(n
   InitializeWindow(aEnableDragDrop, aResetVisibility);
 
   return NS_OK;
 }
 
 nsresult nsView::CreateWidgetForPopup(nsWidgetInitData *aWidgetInitData,
                                       nsIWidget* aParentWidget,
                                       PRBool aEnableDragDrop,
-                                      PRBool aResetVisibility,
-                                      nsContentType aWindowType)
+                                      PRBool aResetVisibility)
 {
   AssertNoWindow();
   NS_ABORT_IF_FALSE(aWidgetInitData, "Widget init data required");
   NS_ABORT_IF_FALSE(aWidgetInitData->mWindowType == eWindowType_popup,
                     "Use one of the other CreateWidget methods");
 
   nsIntRect trect = CalcWidgetBounds(aWidgetInitData->mWindowType);
 
--- a/view/src/nsView.h
+++ b/view/src/nsView.h
@@ -115,32 +115,29 @@ public:
   // Helper function to get mouse grabbing off this view (by moving it to the
   // parent, if we can)
   void DropMouseGrabbing();
 
 public:
   // See nsIView::CreateWidget.
   nsresult CreateWidget(nsWidgetInitData *aWidgetInitData,
                         PRBool aEnableDragDrop,
-                        PRBool aResetVisibility,
-                        nsContentType aContentType);
+                        PRBool aResetVisibility);
 
   // See nsIView::CreateWidgetForParent.
   nsresult CreateWidgetForParent(nsIWidget* aParentWidget,
                                  nsWidgetInitData *aWidgetInitData,
                                  PRBool aEnableDragDrop,
-                                 PRBool aResetVisibility,
-                                 nsContentType aContentType);
+                                 PRBool aResetVisibility);
 
   // See nsIView::CreateWidgetForPopup.
   nsresult CreateWidgetForPopup(nsWidgetInitData *aWidgetInitData,
                                 nsIWidget* aParentWidget,
                                 PRBool aEnableDragDrop,
-                                PRBool aResetVisibility,
-                                nsContentType aContentType);
+                                PRBool aResetVisibility);
 
   // NOT in nsIView, so only available in view module
   // These are also present in nsIView, but these versions return nsView and nsViewManager
   // instead of nsIView and nsIViewManager.
   nsView* GetFirstChild() const { return mFirstChild; }
   nsView* GetNextSibling() const { return mNextSibling; }
   nsView* GetParent() const { return mParent; }
   nsViewManager* GetViewManager() const { return mViewManager; }
--- a/widget/public/nsWidgetInitData.h
+++ b/widget/public/nsWidgetInitData.h
@@ -111,52 +111,38 @@ enum nsBorderStyle {
   eBorderStyle_maximize = 1 << 6, // enables the maxmize button so the user
                                   // can maximize the window
   eBorderStyle_close    = 1 << 7, // show the close button
   eBorderStyle_default  = -1      // whatever the OS wants... i.e. don't do
                                   // anything
 };
 
 /**
- * Content types
- *
- * Exposed so screen readers know what's UI
- */
-enum nsContentType {
-  eContentTypeInherit      = -1,
-  eContentTypeUI           = 0,
-  eContentTypeContent      = 1,
-  eContentTypeContentFrame = 2
-};
-
-/**
  * Basic struct for widget initialization data.
  * @see Create member function of nsIWidget
  */
 
 struct nsWidgetInitData {
   nsWidgetInitData() :
       mWindowType(eWindowType_child),
       mBorderStyle(eBorderStyle_default),
-      mContentType(eContentTypeInherit),
       mPopupHint(ePopupTypePanel),
       mPopupLevel(ePopupLevelTop),
       clipChildren(PR_FALSE), 
       clipSiblings(PR_FALSE), 
       mDropShadow(PR_FALSE),
       mListenForResizes(PR_FALSE),
       mUnicode(PR_TRUE),
       mRTL(PR_FALSE),
       mNoAutoHide(PR_FALSE)
   {
   }
 
   nsWindowType  mWindowType;
   nsBorderStyle mBorderStyle;
-  nsContentType mContentType;  // Exposed so screen readers know what's UI
   nsPopupType   mPopupHint;
   nsPopupLevel  mPopupLevel;
   // when painting exclude area occupied by child windows and sibling windows
   PRPackedBool  clipChildren, clipSiblings, mDropShadow;
   PRPackedBool  mListenForResizes;
   PRPackedBool  mUnicode;
   PRPackedBool  mRTL;
   PRPackedBool  mNoAutoHide; // true for noautohide panels
--- a/widget/src/os2/nsWindow.cpp
+++ b/widget/src/os2/nsWindow.cpp
@@ -399,19 +399,17 @@ NS_METHOD nsWindow::Create(nsIWidget* aP
   // Some basic initialization.
   if (aInitData) {
     mWindowType = aInitData->mWindowType;
     mBorderStyle = aInitData->mBorderStyle;
 
     // Suppress creation of a Thebes surface for windows that will never
     // be painted because they're always covered by another window.
     if (mWindowType == eWindowType_toplevel ||
-        mWindowType == eWindowType_invisible ||
-        (mWindowType == eWindowType_child &&
-         aInitData->mContentType == eContentTypeContent)) {
+        mWindowType == eWindowType_invisible) {
       mNoPaint = PR_TRUE;
     }
   }
 
   // For toplevel windows, create an instance of our helper class,
   // then have it create a frame & client window;  otherwise,
   // call our own CreateWindow() method to create a child window.
   if (mWindowType == eWindowType_toplevel ||
--- a/widget/src/windows/nsWindow.cpp
+++ b/widget/src/windows/nsWindow.cpp
@@ -548,17 +548,16 @@ nsWindow::Create(nsIWidget *aParent,
     parent = aParent ? (HWND)aParent->GetNativeData(NS_NATIVE_WINDOW) : NULL;
     mParent = aParent;
   } else { // has a nsNative parent
     parent = (HWND)aNativeParent;
     mParent = aNativeParent ? GetNSWindowPtr((HWND)aNativeParent) : nsnull;
   }
 
   mPopupType = aInitData->mPopupHint;
-  mContentType = aInitData->mContentType;
   mIsRTL = aInitData->mRTL;
 
   DWORD style = WindowStyle();
   DWORD extendedStyle = WindowExStyle();
 
   if (mWindowType == eWindowType_popup) {
     if (!aParent)
       parent = NULL;
@@ -730,28 +729,16 @@ LPCWSTR nsWindow::WindowClass()
     wc.hbrBackground = mBrush;
     wc.lpszMenuName  = NULL;
     wc.lpszClassName = kClassNameHidden;
 
     BOOL succeeded = ::RegisterClassW(&wc) != 0 && 
       ERROR_CLASS_ALREADY_EXISTS != GetLastError();
     nsWindow::sIsRegistered = succeeded;
 
-    wc.lpszClassName = kClassNameContentFrame;
-    if (!::RegisterClassW(&wc) && 
-      ERROR_CLASS_ALREADY_EXISTS != GetLastError()) {
-      nsWindow::sIsRegistered = FALSE;
-    }
-
-    wc.lpszClassName = kClassNameContent;
-    if (!::RegisterClassW(&wc) && 
-      ERROR_CLASS_ALREADY_EXISTS != GetLastError()) {
-      nsWindow::sIsRegistered = FALSE;
-    }
-
     wc.lpszClassName = kClassNameGeneral;
     ATOM generalClassAtom = ::RegisterClassW(&wc);
     if (!generalClassAtom && 
       ERROR_CLASS_ALREADY_EXISTS != GetLastError()) {
       nsWindow::sIsRegistered = FALSE;
     }
 
     wc.lpszClassName = kClassNameDialog;
@@ -763,22 +750,16 @@ LPCWSTR nsWindow::WindowClass()
   }
 
   if (mWindowType == eWindowType_invisible) {
     return kClassNameHidden;
   }
   if (mWindowType == eWindowType_dialog) {
     return kClassNameDialog;
   }
-  if (mContentType == eContentTypeContent) {
-    return kClassNameContent;
-  }
-  if (mContentType == eContentTypeContentFrame) {
-    return kClassNameContentFrame;
-  }
   return kClassNameGeneral;
 }
 
 // Return the proper popup window class
 LPCWSTR nsWindow::WindowPopupClass()
 {
   if (!nsWindow::sIsPopupClassRegistered) {
     WNDCLASSW wc;
@@ -7558,18 +7539,18 @@ nsWindow::OnIMESelectionChange(void)
     void *hwnd = nsnull;                                                       \
     doc->GetWindowHandle(&hwnd);                                               \
     printf(", acc hwnd: %d", hwnd);                                            \
   }
 
 #define NS_LOG_WMGETOBJECT_THISWND                                             \
 {                                                                              \
   printf("\n*******Get Doc Accessible*******\nOrig Window: ");                 \
-  printf("\n  {\n     HWND: %d, parent HWND: %d, wndobj: %p, content type: %d,\n",\
-         mWnd, ::GetParent(mWnd), this, mContentType);                         \
+  printf("\n  {\n     HWND: %d, parent HWND: %d, wndobj: %p,\n",               \
+         mWnd, ::GetParent(mWnd), this);                                       \
   NS_LOG_WMGETOBJECT_WNDACC(this)                                              \
   printf("\n  }\n");                                                           \
 }
 
 #define NS_LOG_WMGETOBJECT_WND(aMsg, aHwnd)                                    \
 {                                                                              \
   nsWindow* wnd = GetNSWindowPtr(aHwnd);                                       \
   printf("Get " aMsg ":\n  {\n     HWND: %d, parent HWND: %d, wndobj: %p,\n",  \
--- a/widget/src/windows/nsWindow.h
+++ b/widget/src/windows/nsWindow.h
@@ -474,17 +474,16 @@ protected:
   PRPackedBool          mPainting;
   PRPackedBool          mExitToNonClientArea;
   PRPackedBool          mTouchWindow;
   PRPackedBool          mDisplayPanFeedback;
   PRPackedBool          mHideChrome;
   PRPackedBool          mIsRTL;
   PRPackedBool          mFullscreenMode;
   PRUint32              mBlurSuppressLevel;
-  nsContentType         mContentType;
   DWORD_PTR             mOldStyle;
   DWORD_PTR             mOldExStyle;
   HIMC                  mOldIMC;
   PRUint32              mIMEEnabled;
   nsNativeDragTarget*   mNativeDragTarget;
   HKL                   mLastKeyboardLayout;
   nsPopupType           mPopupType;
   nsSizeMode            mOldSizeMode;
--- a/widget/src/windows/nsWindowDefs.h
+++ b/widget/src/windows/nsWindowDefs.h
@@ -206,19 +206,16 @@ typedef enum
  * ::: IMPORTANT :::
  *
  * External apps and drivers depend on window class names.
  * For example, changing the window classes could break
  * touchpad scrolling or screen readers.
  */
 const PRUint32 kMaxClassNameLength   = 40;
 const LPCWSTR kClassNameHidden       = L"MozillaHiddenWindowClass";
-const LPCWSTR kClassNameUI           = L"MozillaUIWindowClass";
-const LPCWSTR kClassNameContent      = L"MozillaContentWindowClass";
-const LPCWSTR kClassNameContentFrame = L"MozillaContentFrameWindowClass";
 const LPCWSTR kClassNameGeneral      = L"MozillaWindowClass";
 const LPCWSTR kClassNameDialog       = L"MozillaDialogClass";
 const LPCWSTR kClassNameDropShadow   = L"MozillaDropShadowWindowClass";
 const LPCWSTR kClassNameTemp         = L"MozillaTempWindowClass";
 
 static const PRUint32 sModifierKeyMap[][3] = {
   { nsIWidget::CAPS_LOCK, VK_CAPITAL, 0 },
   { nsIWidget::NUM_LOCK,  VK_NUMLOCK, 0 },
--- a/xpfe/appshell/src/nsAppShellService.cpp
+++ b/xpfe/appshell/src/nsAppShellService.cpp
@@ -381,18 +381,16 @@ nsAppShellService::JustCreateTopWindow(n
 #endif
 
 #if defined(XP_WIN)
   if (widgetInitData.mWindowType == eWindowType_toplevel ||
       widgetInitData.mWindowType == eWindowType_dialog)
     widgetInitData.clipChildren = PR_TRUE;
 #endif
 
-  widgetInitData.mContentType = eContentTypeUI;                
-
   // note default chrome overrides other OS chrome settings, but
   // not internal chrome
   if (aChromeMask & nsIWebBrowserChrome::CHROME_DEFAULT)
     widgetInitData.mBorderStyle = eBorderStyle_default;
   else if ((aChromeMask & nsIWebBrowserChrome::CHROME_ALL) == nsIWebBrowserChrome::CHROME_ALL)
     widgetInitData.mBorderStyle = eBorderStyle_all;
   else {
     widgetInitData.mBorderStyle = eBorderStyle_none; // assumes none == 0x00