| Index: third_party/WebKit/Source/web/WebDocument.cpp
|
| diff --git a/third_party/WebKit/Source/web/WebDocument.cpp b/third_party/WebKit/Source/web/WebDocument.cpp
|
| index e10b756e4cdbd1c624d7b2d4aa3bbeab185553f1..be3d67d2f0b322dc8240c937a18c5318883433e2 100644
|
| --- a/third_party/WebKit/Source/web/WebDocument.cpp
|
| +++ b/third_party/WebKit/Source/web/WebDocument.cpp
|
| @@ -38,11 +38,13 @@
|
| #include "core/css/StyleSheetContents.h"
|
| #include "core/dom/CSSSelectorWatch.h"
|
| #include "core/dom/Document.h"
|
| +#include "core/dom/DocumentStatisticsCollector.h"
|
| #include "core/dom/DocumentType.h"
|
| #include "core/dom/Element.h"
|
| #include "core/dom/Fullscreen.h"
|
| #include "core/dom/StyleEngine.h"
|
| #include "core/events/Event.h"
|
| +#include "core/frame/FrameHost.h"
|
| #include "core/html/HTMLAllCollection.h"
|
| #include "core/html/HTMLBodyElement.h"
|
| #include "core/html/HTMLCollection.h"
|
| @@ -56,6 +58,7 @@
|
| #include "modules/accessibility/AXObject.h"
|
| #include "modules/accessibility/AXObjectCacheImpl.h"
|
| #include "platform/weborigin/SecurityOrigin.h"
|
| +#include "public/platform/WebDistillability.h"
|
| #include "public/platform/WebURL.h"
|
| #include "public/web/WebAXObject.h"
|
| #include "public/web/WebDOMEvent.h"
|
| @@ -322,6 +325,19 @@ bool WebDocument::manifestUseCredentials() const
|
| return equalIgnoringCase(linkElement->fastGetAttribute(HTMLNames::crossoriginAttr), "use-credentials");
|
| }
|
|
|
| +WebDistillabilityFeatures WebDocument::distillabilityFeatures()
|
| +{
|
| + return DocumentStatisticsCollector::collectStatistics(*unwrap<Document>());
|
| +}
|
| +
|
| +bool WebDocument::isMobileFriendly()
|
| +{
|
| + FrameHost* frameHost = unwrap<Document>()->frameHost();
|
| + if (!frameHost)
|
| + return false;
|
| + return frameHost->visualViewport().shouldDisableDesktopWorkarounds();
|
| +}
|
| +
|
| WebDocument::WebDocument(const PassRefPtrWillBeRawPtr<Document>& elem)
|
| : WebNode(elem)
|
| {
|
|
|