Closed Bug 593272 Opened 9 years ago Closed 9 years ago

mFramesWithLayers out of sync assert (and no drawing) opening options window with d3d9 layers

Categories

(Core :: Graphics, defect)

x86
Windows 7
defect
Not set

Tracking

()

RESOLVED FIXED
Tracking Status
blocking2.0 --- beta7+

People

(Reporter: joe, Assigned: roc)

References

Details

Attachments

(1 file)

Turn on D3D9 layers, and open the options dialog. You will get an assertion that mFramesWithLayers is out of sync, and the options dialog will not draw (it'll either be white or transparent).
blocking2.0: --- → beta6+
This also happens with d2d disabled.
This looks like it is caused by us getting confused about whether we should be
using an accelerated layer manager or not. The following fixes the problem but
may not be correct:

diff --git a/widget/src/windows/nsWindow.cpp b/widget/src/windows/nsWindow.cpp
--- a/widget/src/windows/nsWindow.cpp
+++ b/widget/src/windows/nsWindow.cpp
@@ -3164,17 +3164,17 @@ nsWindow::GetLayerManager()
 {
   nsWindow *topWindow = GetNSWindowPtr(GetTopLevelHWND(mWnd, PR_TRUE));

   if (!topWindow) {
     return nsBaseWidget::GetLayerManager();
   }

   if (topWindow->GetAcceleratedRendering() != mUseAcceleratedRendering) {
-    mLayerManager = NULL;
+    //mLayerManager = NULL;
     mUseAcceleratedRendering = topWindow->GetAcceleratedRendering();
   }

 #ifndef WINCE
   if (!mLayerManager) {
     nsCOMPtr<nsIPrefBranch2> prefs = do_GetService(NS_PREFSERVICE_CONTRACTID);

     PRBool accelerateByDefault = PR_TRUE;
It doesn't make a ton of sense to make child widgets have the same acceleration status as their parent now that we have (mostly - see bug 593440) only one widget per window. (It might never have made sense.)
Attachment #471954 - Flags: review?(vladimir)
Duplicate of this bug: 591734
http://hg.mozilla.org/mozilla-central/rev/6ba079f6ba64
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.