OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Inc. All | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Inc. All |
7 * rights reserved. | 7 * rights reserved. |
8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. | 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. |
9 * (http://www.torchmobile.com/) | 9 * (http://www.torchmobile.com/) |
10 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) | 10 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) |
(...skipping 548 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
559 // document of the entry settings object. | 559 // document of the entry settings object. |
560 void open(Document* entered_document, ExceptionState&); | 560 void open(Document* entered_document, ExceptionState&); |
561 // This is used internally and does not handle exceptions. | 561 // This is used internally and does not handle exceptions. |
562 void open(); | 562 void open(); |
563 DocumentParser* ImplicitOpen(ParserSynchronizationPolicy); | 563 DocumentParser* ImplicitOpen(ParserSynchronizationPolicy); |
564 | 564 |
565 // This is the DOM API document.close() | 565 // This is the DOM API document.close() |
566 void close(ExceptionState&); | 566 void close(ExceptionState&); |
567 // This is used internally and does not handle exceptions. | 567 // This is used internally and does not handle exceptions. |
568 void close(); | 568 void close(); |
569 // implicitClose() actually does the work of closing the input stream. | 569 |
570 void ImplicitClose(); | 570 void CheckCompleted(); |
571 | 571 |
572 bool DispatchBeforeUnloadEvent(ChromeClient&, | 572 bool DispatchBeforeUnloadEvent(ChromeClient&, |
573 bool is_reload, | 573 bool is_reload, |
574 bool& did_allow_navigation); | 574 bool& did_allow_navigation); |
575 void DispatchUnloadEvents(); | 575 void DispatchUnloadEvents(); |
576 | 576 |
577 enum PageDismissalType { | 577 enum PageDismissalType { |
578 kNoDismissal, | 578 kNoDismissal, |
579 kBeforeUnloadDismissal, | 579 kBeforeUnloadDismissal, |
580 kPageHideDismissal, | 580 kPageHideDismissal, |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
673 | 673 |
674 // https://html.spec.whatwg.org/multipage/dom.html#documentreadystate | 674 // https://html.spec.whatwg.org/multipage/dom.html#documentreadystate |
675 enum DocumentReadyState { kLoading, kInteractive, kComplete }; | 675 enum DocumentReadyState { kLoading, kInteractive, kComplete }; |
676 | 676 |
677 void SetReadyState(DocumentReadyState); | 677 void SetReadyState(DocumentReadyState); |
678 bool IsLoadCompleted(); | 678 bool IsLoadCompleted(); |
679 | 679 |
680 enum ParsingState { kParsing, kInDOMContentLoaded, kFinishedParsing }; | 680 enum ParsingState { kParsing, kInDOMContentLoaded, kFinishedParsing }; |
681 void SetParsingState(ParsingState); | 681 void SetParsingState(ParsingState); |
682 bool Parsing() const { return parsing_state_ == kParsing; } | 682 bool Parsing() const { return parsing_state_ == kParsing; } |
683 bool IsInDOMContentLoaded() const { | |
684 return parsing_state_ == kInDOMContentLoaded; | |
685 } | |
686 bool HasFinishedParsing() const { return parsing_state_ == kFinishedParsing; } | 683 bool HasFinishedParsing() const { return parsing_state_ == kFinishedParsing; } |
687 | 684 |
688 bool ShouldScheduleLayout() const; | 685 bool ShouldScheduleLayout() const; |
689 int ElapsedTime() const; | 686 int ElapsedTime() const; |
690 | 687 |
691 bool CanCreateHistoryEntry() const; | 688 bool CanCreateHistoryEntry() const; |
692 | 689 |
693 TextLinkColors& GetTextLinkColors() { return text_link_colors_; } | 690 TextLinkColors& GetTextLinkColors() { return text_link_colors_; } |
694 VisitedLinkState& GetVisitedLinkState() const { return *visited_link_state_; } | 691 VisitedLinkState& GetVisitedLinkState() const { return *visited_link_state_; } |
695 | 692 |
(...skipping 347 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1043 kBeforeUnloadEventInProgress, | 1040 kBeforeUnloadEventInProgress, |
1044 kBeforeUnloadEventCompleted, | 1041 kBeforeUnloadEventCompleted, |
1045 kPageHideInProgress, | 1042 kPageHideInProgress, |
1046 kUnloadVisibilityChangeInProgress, | 1043 kUnloadVisibilityChangeInProgress, |
1047 kUnloadEventInProgress, | 1044 kUnloadEventInProgress, |
1048 kUnloadEventHandled | 1045 kUnloadEventHandled |
1049 }; | 1046 }; |
1050 bool LoadEventStillNeeded() const { | 1047 bool LoadEventStillNeeded() const { |
1051 return load_event_progress_ == kLoadEventNotRun; | 1048 return load_event_progress_ == kLoadEventNotRun; |
1052 } | 1049 } |
1053 bool ProcessingLoadEvent() const { | |
1054 return load_event_progress_ == kLoadEventInProgress; | |
1055 } | |
1056 bool LoadEventFinished() const { | 1050 bool LoadEventFinished() const { |
1057 return load_event_progress_ >= kLoadEventCompleted; | 1051 return load_event_progress_ >= kLoadEventCompleted; |
1058 } | 1052 } |
1059 bool UnloadStarted() const { | 1053 bool UnloadStarted() const { |
1060 return load_event_progress_ >= kPageHideInProgress; | 1054 return load_event_progress_ >= kPageHideInProgress; |
1061 } | 1055 } |
1062 bool ProcessingBeforeUnload() const { | 1056 bool ProcessingBeforeUnload() const { |
1063 return load_event_progress_ == kBeforeUnloadEventInProgress; | 1057 return load_event_progress_ == kBeforeUnloadEventInProgress; |
1064 } | 1058 } |
1065 void SuppressLoadEvent(); | 1059 void SuppressLoadEvent(); |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1156 } | 1150 } |
1157 V0CustomElementMicrotaskRunQueue* CustomElementMicrotaskRunQueue(); | 1151 V0CustomElementMicrotaskRunQueue* CustomElementMicrotaskRunQueue(); |
1158 | 1152 |
1159 void ClearImportsController(); | 1153 void ClearImportsController(); |
1160 void CreateImportsController(); | 1154 void CreateImportsController(); |
1161 HTMLImportsController* ImportsController() const { | 1155 HTMLImportsController* ImportsController() const { |
1162 return imports_controller_; | 1156 return imports_controller_; |
1163 } | 1157 } |
1164 HTMLImportLoader* ImportLoader() const; | 1158 HTMLImportLoader* ImportLoader() const; |
1165 | 1159 |
1166 bool HaveImportsLoaded() const; | |
1167 void DidLoadAllImports(); | 1160 void DidLoadAllImports(); |
1168 | 1161 |
1169 void AdjustFloatQuadsForScrollAndAbsoluteZoom(Vector<FloatQuad>&, | 1162 void AdjustFloatQuadsForScrollAndAbsoluteZoom(Vector<FloatQuad>&, |
1170 LayoutObject&); | 1163 LayoutObject&); |
1171 void AdjustFloatRectForScrollAndAbsoluteZoom(FloatRect&, LayoutObject&); | 1164 void AdjustFloatRectForScrollAndAbsoluteZoom(FloatRect&, LayoutObject&); |
1172 | 1165 |
1173 void SetContextFeatures(ContextFeatures&); | 1166 void SetContextFeatures(ContextFeatures&); |
1174 ContextFeatures& GetContextFeatures() const { return *context_features_; } | 1167 ContextFeatures& GetContextFeatures() const { return *context_features_; } |
1175 | 1168 |
1176 ElementDataCache* GetElementDataCache() { return element_data_cache_.Get(); } | 1169 ElementDataCache* GetElementDataCache() { return element_data_cache_.Get(); } |
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1366 | 1359 |
1367 void InheritHtmlAndBodyElementStyles(StyleRecalcChange); | 1360 void InheritHtmlAndBodyElementStyles(StyleRecalcChange); |
1368 | 1361 |
1369 void UpdateUseShadowTreesIfNeeded(); | 1362 void UpdateUseShadowTreesIfNeeded(); |
1370 void EvaluateMediaQueryListIfNeeded(); | 1363 void EvaluateMediaQueryListIfNeeded(); |
1371 | 1364 |
1372 void UpdateStyleInvalidationIfNeeded(); | 1365 void UpdateStyleInvalidationIfNeeded(); |
1373 void UpdateStyle(); | 1366 void UpdateStyle(); |
1374 void NotifyLayoutTreeOfSubtreeChanges(); | 1367 void NotifyLayoutTreeOfSubtreeChanges(); |
1375 | 1368 |
| 1369 // ImplicitClose() actually does the work of closing the input stream. |
| 1370 void ImplicitClose(); |
| 1371 bool ShouldComplete(); |
| 1372 |
1376 void DetachParser(); | 1373 void DetachParser(); |
1377 | 1374 |
1378 void BeginLifecycleUpdatesIfRenderingReady(); | 1375 void BeginLifecycleUpdatesIfRenderingReady(); |
1379 | 1376 |
1380 bool IsDocument() const final { return true; } | 1377 bool IsDocument() const final { return true; } |
1381 | 1378 |
1382 void ChildrenChanged(const ChildrenChange&) override; | 1379 void ChildrenChanged(const ChildrenChange&) override; |
1383 | 1380 |
1384 String nodeName() const final; | 1381 String nodeName() const final; |
1385 NodeType getNodeType() const final; | 1382 NodeType getNodeType() const final; |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1431 } | 1428 } |
1432 | 1429 |
1433 const OriginAccessEntry& AccessEntryFromURL(); | 1430 const OriginAccessEntry& AccessEntryFromURL(); |
1434 | 1431 |
1435 void SendSensitiveInputVisibility(); | 1432 void SendSensitiveInputVisibility(); |
1436 void SendSensitiveInputVisibilityInternal(); | 1433 void SendSensitiveInputVisibilityInternal(); |
1437 | 1434 |
1438 void RunExecutionContextTask(std::unique_ptr<ExecutionContextTask>, | 1435 void RunExecutionContextTask(std::unique_ptr<ExecutionContextTask>, |
1439 bool instrumenting); | 1436 bool instrumenting); |
1440 | 1437 |
| 1438 bool HaveImportsLoaded() const; |
| 1439 |
1441 DocumentLifecycle lifecycle_; | 1440 DocumentLifecycle lifecycle_; |
1442 | 1441 |
1443 bool has_nodes_with_placeholder_style_; | 1442 bool has_nodes_with_placeholder_style_; |
1444 bool evaluate_media_queries_on_style_recalc_; | 1443 bool evaluate_media_queries_on_style_recalc_; |
1445 | 1444 |
1446 // If we do ignore the pending stylesheet count, then we need to add a boolean | 1445 // If we do ignore the pending stylesheet count, then we need to add a boolean |
1447 // to track that this happened so that we can do a full repaint when the | 1446 // to track that this happened so that we can do a full repaint when the |
1448 // stylesheets do eventually load. | 1447 // stylesheets do eventually load. |
1449 PendingSheetLayout pending_sheet_layout_; | 1448 PendingSheetLayout pending_sheet_layout_; |
1450 | 1449 |
(...skipping 281 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1732 DEFINE_TYPE_CASTS(TreeScope, Document, document, true, true); | 1731 DEFINE_TYPE_CASTS(TreeScope, Document, document, true, true); |
1733 | 1732 |
1734 } // namespace blink | 1733 } // namespace blink |
1735 | 1734 |
1736 #ifndef NDEBUG | 1735 #ifndef NDEBUG |
1737 // Outside the WebCore namespace for ease of invocation from gdb. | 1736 // Outside the WebCore namespace for ease of invocation from gdb. |
1738 CORE_EXPORT void showLiveDocumentInstances(); | 1737 CORE_EXPORT void showLiveDocumentInstances(); |
1739 #endif | 1738 #endif |
1740 | 1739 |
1741 #endif // Document_h | 1740 #endif // Document_h |
OLD | NEW |