Move stylesheet change logic from Document to AuthorStyleSheets
authorantti@apple.com <antti@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 24 Sep 2016 13:10:39 +0000 (13:10 +0000)
committerantti@apple.com <antti@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 24 Sep 2016 13:10:39 +0000 (13:10 +0000)
https://bugs.webkit.org/show_bug.cgi?id=162488

Reviewed by Andreas Kling.

* WebView/WebHTMLView.mm:
(-[WebHTMLView reapplyStyles]):
(-[WebHTMLView _setPrinting:minimumPageLogicalWidth:logicalHeight:originalPageWidth:originalPageHeight:maximumShrinkRatio:adjustViewSize:paginateScreenContent:]):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@206352 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebKit/mac/ChangeLog
Source/WebKit/mac/WebView/WebHTMLView.mm

index d05a69e..da43bf3 100644 (file)
@@ -1,3 +1,14 @@
+2016-09-24  Antti Koivisto  <antti@apple.com>
+
+        Move stylesheet change logic from Document to AuthorStyleSheets
+        https://bugs.webkit.org/show_bug.cgi?id=162488
+
+        Reviewed by Andreas Kling.
+
+        * WebView/WebHTMLView.mm:
+        (-[WebHTMLView reapplyStyles]):
+        (-[WebHTMLView _setPrinting:minimumPageLogicalWidth:logicalHeight:originalPageWidth:originalPageHeight:maximumShrinkRatio:adjustViewSize:paginateScreenContent:]):
+
 2016-09-23  Caitlin Potter  <caitp@igalia.com>
 
         [JSC] Implement parsing of Async Functions
index 43a612f..fc98768 100644 (file)
@@ -72,6 +72,7 @@
 #import "WebTypesInternal.h"
 #import "WebUIDelegatePrivate.h"
 #import "WebViewInternal.h"
+#import <WebCore/AuthorStyleSheets.h>
 #import <WebCore/CSSStyleDeclaration.h>
 #import <WebCore/CachedImage.h>
 #import <WebCore/CachedResourceClient.h>
@@ -3611,7 +3612,7 @@ WEBCORE_COMMAND(toggleUnderline)
 #endif
 
     if (Frame* coreFrame = core([self _frame]))
-        coreFrame->document()->styleResolverChanged(RecalcStyleImmediately);
+        coreFrame->document()->authorStyleSheets().didChange(RecalcStyleImmediately);
     
 #ifdef LOG_TIMES        
     double thisTime = CFAbsoluteTimeGetCurrent() - start;
@@ -5004,7 +5005,7 @@ static PassRefPtr<KeyboardEvent> currentKeyboardEvent(Frame* coreFrame)
 
             document->setPaginatedForScreen(_private->paginateScreenContent);
             document->setPrinting(_private->printing);
-            document->styleResolverChanged(RecalcStyleImmediately);
+            document->authorStyleSheets().didChange(RecalcStyleImmediately);
         }
     }