Skip to content

Commit

Permalink
Merge r242042 - [WPE][GTK] Clean up handling of WEBKIT_FORCE_COMPLEX_…
Browse files Browse the repository at this point in the history
…TEXT

https://bugs.webkit.org/show_bug.cgi?id=194614

Reviewed by Carlos Garcia Campos.

This environment variable is now enabled for WPE, not just for GTK.

It is now possible to use this environment variable to enable complex text, not just to
disable it.

WebProcessPool::setAlwaysUsesComplexTextCodePath is fixed to be respected even when this
environment variable is set, although WPE and GTK will never do so.

* UIProcess/glib/WebProcessPoolGLib.cpp:
(WebKit::WebProcessPool::platformInitialize):
(WebKit::WebProcessPool::platformInitializeWebProcess):
  • Loading branch information
mcatanzaro authored and carlosgcampos committed Mar 5, 2019
1 parent 72815ee commit 17f735c
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 8 deletions.
19 changes: 19 additions & 0 deletions Source/WebKit/ChangeLog
@@ -1,3 +1,22 @@
2019-02-25 Michael Catanzaro <mcatanzaro@igalia.com>

[WPE][GTK] Clean up handling of WEBKIT_FORCE_COMPLEX_TEXT
https://bugs.webkit.org/show_bug.cgi?id=194614

Reviewed by Carlos Garcia Campos.

This environment variable is now enabled for WPE, not just for GTK.

It is now possible to use this environment variable to enable complex text, not just to
disable it.

WebProcessPool::setAlwaysUsesComplexTextCodePath is fixed to be respected even when this
environment variable is set, although WPE and GTK will never do so.

* UIProcess/glib/WebProcessPoolGLib.cpp:
(WebKit::WebProcessPool::platformInitialize):
(WebKit::WebProcessPool::platformInitializeWebProcess):

2019-02-24 Michael Catanzaro <mcatanzaro@igalia.com>

[WPE] Install MemoryPressureHandler in UIProcess
Expand Down
14 changes: 6 additions & 8 deletions Source/WebKit/UIProcess/glib/WebProcessPoolGLib.cpp
Expand Up @@ -73,6 +73,12 @@ static bool memoryPressureMonitorDisabled()

void WebProcessPool::platformInitialize()
{
#if PLATFORM(GTK)
m_alwaysUsesComplexTextCodePath = true;
#endif
if (const char* forceComplexText = getenv("WEBKIT_FORCE_COMPLEX_TEXT"))
m_alwaysUsesComplexTextCodePath = !strcmp(forceComplexText, "1");

#if ENABLE(REMOTE_INSPECTOR)
if (const char* address = g_getenv("WEBKIT_INSPECTOR_SERVER"))
initializeRemoteInspectorServer(address);
Expand All @@ -94,14 +100,6 @@ void WebProcessPool::platformInitializeWebProcess(WebProcessCreationParameters&
parameters.memoryCacheDisabled = m_memoryCacheDisabled || cacheModel() == CacheModel::DocumentViewer;
parameters.proxySettings = m_networkProxySettings;

#if PLATFORM(GTK)
// This is misnamed. It can only be used to disable complex text.
parameters.shouldAlwaysUseComplexTextCodePath = true;
const char* forceComplexText = getenv("WEBKIT_FORCE_COMPLEX_TEXT");
if (forceComplexText && !strcmp(forceComplexText, "0"))
parameters.shouldAlwaysUseComplexTextCodePath = m_alwaysUsesComplexTextCodePath;
#endif

if (memoryPressureMonitorDisabled())
parameters.shouldSuppressMemoryPressureHandler = true;

Expand Down

0 comments on commit 17f735c

Please sign in to comment.