| 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 | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 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) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. | 10 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. |
| (...skipping 2034 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2045 StyleResolver& resolver = ensureStyleResolver(); | 2045 StyleResolver& resolver = ensureStyleResolver(); |
| 2046 | 2046 |
| 2047 bool shouldRecordStats; | 2047 bool shouldRecordStats; |
| 2048 TRACE_EVENT_CATEGORY_GROUP_ENABLED("blink,blink_style", &shouldRecordStats); | 2048 TRACE_EVENT_CATEGORY_GROUP_ENABLED("blink,blink_style", &shouldRecordStats); |
| 2049 styleEngine().setStatsEnabled(shouldRecordStats); | 2049 styleEngine().setStatsEnabled(shouldRecordStats); |
| 2050 | 2050 |
| 2051 if (Element* documentElement = this->documentElement()) { | 2051 if (Element* documentElement = this->documentElement()) { |
| 2052 inheritHtmlAndBodyElementStyles(change); | 2052 inheritHtmlAndBodyElementStyles(change); |
| 2053 if (documentElement->shouldCallRecalcStyle(change)) | 2053 if (documentElement->shouldCallRecalcStyle(change)) |
| 2054 documentElement->recalcStyle(change); | 2054 documentElement->recalcStyle(change); |
| 2055 DCHECK(!documentElement->needsStyleRecalc()); |
| 2056 if (documentElement->needsReattachLayoutTree() || |
| 2057 documentElement->childNeedsReattachLayoutTree()) |
| 2058 documentElement->rebuildLayoutTree(); |
| 2055 } | 2059 } |
| 2056 | 2060 |
| 2057 view()->recalcOverflowAfterStyleChange(); | 2061 view()->recalcOverflowAfterStyleChange(); |
| 2058 | 2062 |
| 2059 // Only retain the HashMap for the duration of StyleRecalc and | 2063 // Only retain the HashMap for the duration of StyleRecalc and |
| 2060 // LayoutTreeConstruction. | 2064 // LayoutTreeConstruction. |
| 2061 m_styleReattachDataMap.clear(); | 2065 m_styleReattachDataMap.clear(); |
| 2062 clearChildNeedsStyleRecalc(); | 2066 clearChildNeedsStyleRecalc(); |
| 2063 clearChildNeedsReattachLayoutTree(); | 2067 clearChildNeedsReattachLayoutTree(); |
| 2064 | 2068 |
| (...skipping 4505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6570 } | 6574 } |
| 6571 | 6575 |
| 6572 void showLiveDocumentInstances() { | 6576 void showLiveDocumentInstances() { |
| 6573 WeakDocumentSet& set = liveDocumentSet(); | 6577 WeakDocumentSet& set = liveDocumentSet(); |
| 6574 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); | 6578 fprintf(stderr, "There are %u documents currently alive:\n", set.size()); |
| 6575 for (Document* document : set) | 6579 for (Document* document : set) |
| 6576 fprintf(stderr, "- Document %p URL: %s\n", document, | 6580 fprintf(stderr, "- Document %p URL: %s\n", document, |
| 6577 document->url().getString().utf8().data()); | 6581 document->url().getString().utf8().data()); |
| 6578 } | 6582 } |
| 6579 #endif | 6583 #endif |
| OLD | NEW |