Bug 994541 - Don't require GL layers for OMTC on linux. r=Bas

This commit is contained in:
Chris Lord 2014-08-29 15:24:00 +02:00
parent 39a63a8ef6
commit 4e92b4719a

View File

@ -872,20 +872,6 @@ nsBaseWidget::GetPreferredCompositorBackends(nsTArray<LayersBackend>& aHints)
aHints.AppendElement(LayersBackend::LAYERS_BASIC);
}
static void
CheckForBasicBackends(nsTArray<LayersBackend>& aHints)
{
#ifndef XP_WIN
for (size_t i = 0; i < aHints.Length(); ++i) {
if (aHints[i] == LayersBackend::LAYERS_BASIC &&
!Preferences::GetBool("layers.offmainthreadcomposition.force-basic", false)) {
// basic compositor is not stable enough for regular use
aHints[i] = LayersBackend::LAYERS_NONE;
}
}
#endif
}
void nsBaseWidget::CreateCompositor(int aWidth, int aHeight)
{
MOZ_ASSERT(gfxPlatform::UsesOffMainThreadCompositing(),
@ -915,10 +901,6 @@ void nsBaseWidget::CreateCompositor(int aWidth, int aHeight)
nsTArray<LayersBackend> backendHints;
GetPreferredCompositorBackends(backendHints);
if (!mRequireOffMainThreadCompositing) {
CheckForBasicBackends(backendHints);
}
bool success = false;
if (!backendHints.IsEmpty()) {
shadowManager = mCompositorChild->SendPLayerTransactionConstructor(