Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(630)

Side by Side Diff: third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp

Issue 2613733003: Need to clear viewport dependent units switching print mode. (Closed)
Patch Set: Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/web/tests/WebViewTest.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com)
4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com)
5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc.
6 * All rights reserved. 6 * All rights reserved.
7 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> 7 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org>
8 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> 8 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org>
9 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. 9 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved.
10 * (http://www.torchmobile.com/) 10 * (http://www.torchmobile.com/)
(...skipping 1899 matching lines...) Expand 10 before | Expand all | Expand 10 after
1910 for (CSSPropertyID property : properties) { 1910 for (CSSPropertyID property : properties) {
1911 if (property == CSSPropertyLineHeight) 1911 if (property == CSSPropertyLineHeight)
1912 updateFont(state); 1912 updateFont(state);
1913 StyleBuilder::applyProperty(property, state, 1913 StyleBuilder::applyProperty(property, state,
1914 *propertySet.getPropertyCSSValue(property)); 1914 *propertySet.getPropertyCSSValue(property));
1915 } 1915 }
1916 } 1916 }
1917 1917
1918 void StyleResolver::updateMediaType() { 1918 void StyleResolver::updateMediaType() {
1919 if (FrameView* view = document().view()) { 1919 if (FrameView* view = document().view()) {
1920 bool wasPrint = m_printMediaType;
1920 m_printMediaType = 1921 m_printMediaType =
1921 equalIgnoringCase(view->mediaType(), MediaTypeNames::print); 1922 equalIgnoringCase(view->mediaType(), MediaTypeNames::print);
1923 if (wasPrint != m_printMediaType)
1924 m_matchedPropertiesCache.clearViewportDependent();
1922 } 1925 }
1923 } 1926 }
1924 1927
1925 DEFINE_TRACE(StyleResolver) { 1928 DEFINE_TRACE(StyleResolver) {
1926 visitor->trace(m_matchedPropertiesCache); 1929 visitor->trace(m_matchedPropertiesCache);
1927 visitor->trace(m_selectorFilter); 1930 visitor->trace(m_selectorFilter);
1928 visitor->trace(m_styleSharingLists); 1931 visitor->trace(m_styleSharingLists);
1929 visitor->trace(m_document); 1932 visitor->trace(m_document);
1930 visitor->trace(m_tracker); 1933 visitor->trace(m_tracker);
1931 } 1934 }
1932 1935
1933 } // namespace blink 1936 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/web/tests/WebViewTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698