Title: [194489] trunk/Source/WebCore
Revision
194489
Author
[email protected]
Date
2016-01-01 21:50:48 -0800 (Fri, 01 Jan 2016)

Log Message

Simple line layout: Add support for toggling simple line layout from command line.
https://bugs.webkit.org/show_bug.cgi?id=152636

Reviewed by Simon Fraser.

No change in functionality.

* rendering/SimpleLineLayout.cpp:
(WebCore::SimpleLineLayout::canUseForWithReason):
(WebCore::SimpleLineLayout::toggleSimpleLineLayout):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (194488 => 194489)


--- trunk/Source/WebCore/ChangeLog	2016-01-02 05:48:58 UTC (rev 194488)
+++ trunk/Source/WebCore/ChangeLog	2016-01-02 05:50:48 UTC (rev 194489)
@@ -1,3 +1,16 @@
+2016-01-01  Zalan Bujtas  <[email protected]>
+
+        Simple line layout: Add support for toggling simple line layout from command line.
+        https://bugs.webkit.org/show_bug.cgi?id=152636
+
+        Reviewed by Simon Fraser.
+
+        No change in functionality.
+
+        * rendering/SimpleLineLayout.cpp:
+        (WebCore::SimpleLineLayout::canUseForWithReason):
+        (WebCore::SimpleLineLayout::toggleSimpleLineLayout):
+
 2016-01-01  Brady Eidson  <[email protected]>
 
         Modern IDB: storage/indexeddb/database-deletepending-flag.html fails.

Modified: trunk/Source/WebCore/rendering/SimpleLineLayout.cpp (194488 => 194489)


--- trunk/Source/WebCore/rendering/SimpleLineLayout.cpp	2016-01-02 05:48:58 UTC (rev 194488)
+++ trunk/Source/WebCore/rendering/SimpleLineLayout.cpp	2016-01-02 05:50:48 UTC (rev 194489)
@@ -58,6 +58,7 @@
 #ifndef NDEBUG
 void printSimpleLineLayoutCoverage();
 void printSimpleLineLayoutBlockList();
+void toggleSimpleLineLayout();
 #endif
 
 enum AvoidanceReason_ : uint64_t {
@@ -267,6 +268,7 @@
     std::call_once(onceFlag, [] {
         registerNotifyCallback("com.apple.WebKit.showSimpleLineLayoutCoverage", printSimpleLineLayoutCoverage);
         registerNotifyCallback("com.apple.WebKit.showSimpleLineLayoutReasons", printSimpleLineLayoutBlockList);
+        registerNotifyCallback("com.apple.WebKit.toggleSimpleLineLayout", toggleSimpleLineLayout);
     });
 #endif
     AvoidanceReasonFlags reasons = { };
@@ -1005,6 +1007,16 @@
     }
 }
 
+void toggleSimpleLineLayout()
+{
+    for (const auto* document : Document::allDocuments()) {
+        auto* settings = document->settings();
+        if (!settings)
+            continue;
+        settings->setSimpleLineLayoutEnabled(!settings->simpleLineLayoutEnabled());
+    }
+}
+
 void printSimpleLineLayoutBlockList()
 {
     HashSet<const RenderBlockFlow*> leafRenderers;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to