Bug 1578378 - use 'false' instead of hidden static pref in non-nightly builds r=gw

Falls back to 'false' in non-nightly builds instead of using the gfx.webrender.start-debug-server pref, which is only available in nightly builds.

Differential Revision: https://phabricator.services.mozilla.com/D44743

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Kristen Wright 2019-09-05 08:00:21 +00:00
parent 91d8e311f7
commit 885b132251

View File

@ -75,21 +75,26 @@ class NewRenderer : public RendererEvent {
bool supportLowPriorityTransactions = isMainWindow;
bool supportPictureCaching = isMainWindow;
wr::Renderer* wrRenderer = nullptr;
if (!wr_window_new(
aWindowId, mSize.width, mSize.height,
supportLowPriorityTransactions, allow_texture_swizzling,
StaticPrefs::gfx_webrender_picture_caching() &&
supportPictureCaching,
StaticPrefs::gfx_webrender_start_debug_server(), compositor->gl(),
aRenderThread.GetProgramCache()
? aRenderThread.GetProgramCache()->Raw()
: nullptr,
aRenderThread.GetShaders()
? aRenderThread.GetShaders()->RawShaders()
: nullptr,
aRenderThread.ThreadPool().Raw(), &WebRenderMallocSizeOf,
&WebRenderMallocEnclosingSizeOf, (uint32_t)wr::RenderRoot::Default,
mDocHandle, &wrRenderer, mMaxTextureSize)) {
if (!wr_window_new(aWindowId, mSize.width, mSize.height,
supportLowPriorityTransactions, allow_texture_swizzling,
StaticPrefs::gfx_webrender_picture_caching() &&
supportPictureCaching,
#ifdef NIGHTLY_BUILD
StaticPrefs::gfx_webrender_start_debug_server(),
#else
false,
#endif
compositor->gl(),
aRenderThread.GetProgramCache()
? aRenderThread.GetProgramCache()->Raw()
: nullptr,
aRenderThread.GetShaders()
? aRenderThread.GetShaders()->RawShaders()
: nullptr,
aRenderThread.ThreadPool().Raw(), &WebRenderMallocSizeOf,
&WebRenderMallocEnclosingSizeOf,
(uint32_t)wr::RenderRoot::Default, mDocHandle,
&wrRenderer, mMaxTextureSize)) {
// wr_window_new puts a message into gfxCriticalNote if it returns false
return;
}