| 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, 2011, 2012 Apple Inc. All r
ights reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r
ights reserved. |
| 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
| 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. | 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. |
| 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) | 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) |
| 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. | 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. |
| (...skipping 2082 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2093 StyleResolver* Document::styleResolver() const | 2093 StyleResolver* Document::styleResolver() const |
| 2094 { | 2094 { |
| 2095 return m_styleEngine->resolver(); | 2095 return m_styleEngine->resolver(); |
| 2096 } | 2096 } |
| 2097 | 2097 |
| 2098 StyleResolver& Document::ensureStyleResolver() const | 2098 StyleResolver& Document::ensureStyleResolver() const |
| 2099 { | 2099 { |
| 2100 return m_styleEngine->ensureResolver(); | 2100 return m_styleEngine->ensureResolver(); |
| 2101 } | 2101 } |
| 2102 | 2102 |
| 2103 void Document::attach(const AttachContext& context) | 2103 void Document::attachLayoutTree(const AttachContext& context) |
| 2104 { | 2104 { |
| 2105 DCHECK_EQ(m_lifecycle.state(), DocumentLifecycle::Inactive); | 2105 DCHECK_EQ(m_lifecycle.state(), DocumentLifecycle::Inactive); |
| 2106 DCHECK(!m_axObjectCache || this != &axObjectCacheOwner()); | 2106 DCHECK(!m_axObjectCache || this != &axObjectCacheOwner()); |
| 2107 | 2107 |
| 2108 m_layoutView = new LayoutView(this); | 2108 m_layoutView = new LayoutView(this); |
| 2109 setLayoutObject(m_layoutView); | 2109 setLayoutObject(m_layoutView); |
| 2110 | 2110 |
| 2111 m_layoutView->setIsInWindow(true); | 2111 m_layoutView->setIsInWindow(true); |
| 2112 m_layoutView->setStyle(StyleResolver::styleForDocument(*this)); | 2112 m_layoutView->setStyle(StyleResolver::styleForDocument(*this)); |
| 2113 m_layoutView->compositor()->setNeedsCompositingUpdate(CompositingUpdateAfter
CompositingInputChange); | 2113 m_layoutView->compositor()->setNeedsCompositingUpdate(CompositingUpdateAfter
CompositingInputChange); |
| 2114 | 2114 |
| 2115 ContainerNode::attach(context); | 2115 ContainerNode::attachLayoutTree(context); |
| 2116 | 2116 |
| 2117 // The TextAutosizer can't update layout view info while the Document is det
ached, so update now in case anything changed. | 2117 // The TextAutosizer can't update layout view info while the Document is det
ached, so update now in case anything changed. |
| 2118 if (TextAutosizer* autosizer = textAutosizer()) | 2118 if (TextAutosizer* autosizer = textAutosizer()) |
| 2119 autosizer->updatePageInfo(); | 2119 autosizer->updatePageInfo(); |
| 2120 | 2120 |
| 2121 m_frame->selection().documentAttached(this); | 2121 m_frame->selection().documentAttached(this); |
| 2122 m_lifecycle.advanceTo(DocumentLifecycle::StyleClean); | 2122 m_lifecycle.advanceTo(DocumentLifecycle::StyleClean); |
| 2123 | 2123 |
| 2124 if (view()) | 2124 if (view()) |
| 2125 view()->didAttachDocument(); | 2125 view()->didAttachDocument(); |
| (...skipping 3893 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6019 } | 6019 } |
| 6020 | 6020 |
| 6021 void showLiveDocumentInstances() | 6021 void showLiveDocumentInstances() |
| 6022 { | 6022 { |
| 6023 WeakDocumentSet& set = liveDocumentSet(); | 6023 WeakDocumentSet& set = liveDocumentSet(); |
| 6024 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); | 6024 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); |
| 6025 for (Document* document : set) | 6025 for (Document* document : set) |
| 6026 fprintf(stderr, "- Document %p URL: %s\n", document, document->url().get
String().utf8().data()); | 6026 fprintf(stderr, "- Document %p URL: %s\n", document, document->url().get
String().utf8().data()); |
| 6027 } | 6027 } |
| 6028 #endif | 6028 #endif |
| OLD | NEW |