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

Side by Side Diff: third_party/WebKit/Source/core/frame/FrameView.cpp

Issue 2528633003: Move MediaQueryResults to RuleFeatureSet. (Closed)
Patch Set: Removed members. Created 4 years 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 | « third_party/WebKit/Source/core/dom/StyleEngineTest.cpp ('k') | no next file » | 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) 1998, 1999 Torben Weis <weis@kde.org> 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org>
3 * 1999 Lars Knoll <knoll@kde.org> 3 * 1999 Lars Knoll <knoll@kde.org>
4 * 1999 Antti Koivisto <koivisto@kde.org> 4 * 1999 Antti Koivisto <koivisto@kde.org>
5 * 2000 Dirk Mueller <mueller@kde.org> 5 * 2000 Dirk Mueller <mueller@kde.org>
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved.
7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) 7 * (C) 2006 Graham Dennis (graham.dennis@gmail.com)
8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) 8 * (C) 2006 Alexey Proskuryakov (ap@nypop.com)
9 * Copyright (C) 2009 Google Inc. All rights reserved. 9 * Copyright (C) 2009 Google Inc. All rights reserved.
10 * 10 *
(...skipping 928 matching lines...) Expand 10 before | Expand all | Expand 10 after
939 bool wasResized = wasViewportResized(); 939 bool wasResized = wasViewportResized();
940 Document* document = m_frame->document(); 940 Document* document = m_frame->document();
941 if (wasResized) 941 if (wasResized)
942 document->notifyResizeForViewportUnits(); 942 document->notifyResizeForViewportUnits();
943 943
944 // Viewport-dependent or device-dependent media queries may cause us to need 944 // Viewport-dependent or device-dependent media queries may cause us to need
945 // completely different style information. 945 // completely different style information.
946 bool mainFrameRotation = 946 bool mainFrameRotation =
947 m_frame->isMainFrame() && m_frame->settings() && 947 m_frame->isMainFrame() && m_frame->settings() &&
948 m_frame->settings()->mainFrameResizesAreOrientationChanges(); 948 m_frame->settings()->mainFrameResizesAreOrientationChanges();
949 if (!document->styleResolver() || 949 if ((wasResized &&
950 (wasResized && 950 document->styleEngine().mediaQueryAffectedByViewportChange()) ||
951 document->styleResolver()->mediaQueryAffectedByViewportChange()) ||
952 (wasResized && mainFrameRotation && 951 (wasResized && mainFrameRotation &&
953 document->styleResolver()->mediaQueryAffectedByDeviceChange())) { 952 document->styleEngine().mediaQueryAffectedByDeviceChange())) {
954 document->mediaQueryAffectingValueChanged(); 953 document->mediaQueryAffectingValueChanged();
955 } else if (wasResized) { 954 } else if (wasResized) {
956 document->evaluateMediaQueryList(); 955 document->evaluateMediaQueryList();
957 } 956 }
958 957
959 document->updateStyleAndLayoutTree(); 958 document->updateStyleAndLayoutTree();
960 lifecycle().advanceTo(DocumentLifecycle::StyleClean); 959 lifecycle().advanceTo(DocumentLifecycle::StyleClean);
961 960
962 if (shouldPerformScrollAnchoring()) 961 if (shouldPerformScrollAnchoring())
963 m_scrollAnchor.notifyBeforeLayout(); 962 m_scrollAnchor.notifyBeforeLayout();
(...skipping 3683 matching lines...) Expand 10 before | Expand all | Expand 10 after
4647 DCHECK(m_frame->isMainFrame()); 4646 DCHECK(m_frame->isMainFrame());
4648 return m_initialViewportSize.width(); 4647 return m_initialViewportSize.width();
4649 } 4648 }
4650 4649
4651 int FrameView::initialViewportHeight() const { 4650 int FrameView::initialViewportHeight() const {
4652 DCHECK(m_frame->isMainFrame()); 4651 DCHECK(m_frame->isMainFrame());
4653 return m_initialViewportSize.height(); 4652 return m_initialViewportSize.height();
4654 } 4653 }
4655 4654
4656 } // namespace blink 4655 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/StyleEngineTest.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698