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 1607 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1618 documentElementStyle = styleResolver()->styleForElement(documentElement(
)); | 1618 documentElementStyle = styleResolver()->styleForElement(documentElement(
)); |
1619 | 1619 |
1620 RefPtr<RenderStyle> bodyStyle = 0; | 1620 RefPtr<RenderStyle> bodyStyle = 0; |
1621 if (body()) { | 1621 if (body()) { |
1622 bodyStyle = body()->renderStyle(); | 1622 bodyStyle = body()->renderStyle(); |
1623 if (!bodyStyle || body()->needsStyleRecalc() || documentElement()->needs
StyleRecalc() || change == Force) | 1623 if (!bodyStyle || body()->needsStyleRecalc() || documentElement()->needs
StyleRecalc() || change == Force) |
1624 bodyStyle = styleResolver()->styleForElement(body(), documentElement
Style.get()); | 1624 bodyStyle = styleResolver()->styleForElement(body(), documentElement
Style.get()); |
1625 } | 1625 } |
1626 | 1626 |
1627 WritingMode rootWritingMode = documentElementStyle->writingMode(); | 1627 WritingMode rootWritingMode = documentElementStyle->writingMode(); |
1628 bool isHorizontalWritingMode = documentElementStyle->isHorizontalWritingMode
(); | |
1629 TextDirection rootDirection = documentElementStyle->direction(); | 1628 TextDirection rootDirection = documentElementStyle->direction(); |
1630 | 1629 |
1631 if (!writingModeSetOnDocumentElement() && body()) { | 1630 if (!writingModeSetOnDocumentElement() && body()) { |
1632 rootWritingMode = bodyStyle->writingMode(); | 1631 rootWritingMode = bodyStyle->writingMode(); |
1633 isHorizontalWritingMode = bodyStyle->isHorizontalWritingMode(); | |
1634 } | 1632 } |
1635 | 1633 |
1636 if (!directionSetOnDocumentElement() && body()) | 1634 if (!directionSetOnDocumentElement() && body()) |
1637 rootDirection = bodyStyle->direction(); | 1635 rootDirection = bodyStyle->direction(); |
1638 | 1636 |
1639 RefPtr<RenderStyle> documentStyle = renderView->style(); | 1637 RefPtr<RenderStyle> documentStyle = renderView->style(); |
1640 if (documentStyle->writingMode() != rootWritingMode || documentStyle->direct
ion() != rootDirection) { | 1638 if (documentStyle->writingMode() != rootWritingMode || documentStyle->direct
ion() != rootDirection) { |
1641 RefPtr<RenderStyle> newStyle = RenderStyle::clone(documentStyle.get()); | 1639 RefPtr<RenderStyle> newStyle = RenderStyle::clone(documentStyle.get()); |
1642 newStyle->setWritingMode(rootWritingMode); | 1640 newStyle->setWritingMode(rootWritingMode); |
1643 newStyle->setDirection(rootDirection); | 1641 newStyle->setDirection(rootDirection); |
(...skipping 3696 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5340 void Document::modifiedStyleSheet(StyleSheet* sheet, RecalcStyleTime when, Style
ResolverUpdateMode updateMode) | 5338 void Document::modifiedStyleSheet(StyleSheet* sheet, RecalcStyleTime when, Style
ResolverUpdateMode updateMode) |
5341 { | 5339 { |
5342 if (!isActive()) | 5340 if (!isActive()) |
5343 return; | 5341 return; |
5344 | 5342 |
5345 styleEngine()->modifiedStyleSheet(sheet); | 5343 styleEngine()->modifiedStyleSheet(sheet); |
5346 styleResolverChanged(when, updateMode); | 5344 styleResolverChanged(when, updateMode); |
5347 } | 5345 } |
5348 | 5346 |
5349 } // namespace WebCore | 5347 } // namespace WebCore |
OLD | NEW |