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

Issue 335313003: MediaQueryEvaluator getting mediaType from MediaValues (Closed)

Created:
6 years, 5 months ago by Yoav Weiss
Modified:
6 years, 5 months ago
CC:
darktears, apavlov+blink_chromium.org, blink-reviews, blink-reviews-css, blink-reviews-html_chromium.org, dglazkov+blink, ed+blinkwatch_opera.com, gavinp+prerender_chromium.org, kenneth.christiansen, rwlbuis, rune+blink
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Project:
blink
Visibility:
Public.

Description

MediaQueryEvaluator getting mediaType from MediaValues Current MediaQueryEvaluator takes the media type on top of the LocalFrame upon its creation. That means that media type changes are not taken into account, and users such as MediaQueryMatcher have to create a new instance whenever the media type may have changed. This CL fixes that. BUG=389462 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=177087

Patch Set 1 #

Patch Set 2 : Fix build issue #

Patch Set 3 : Fixed a bug and added tests #

Total comments: 2

Patch Set 4 : rebase #

Total comments: 1

Patch Set 5 : Review nits #

Patch Set 6 : Added a comment #

Unified diffs Side-by-side diffs Delta from patch set Stats (+133 lines, -167 lines) Patch
M Source/core/css/MediaQueryEvaluator.h View 1 2 2 chunks +4 lines, -3 lines 0 comments Download
M Source/core/css/MediaQueryEvaluator.cpp View 1 2 3 4 5 5 chunks +21 lines, -17 lines 0 comments Download
M Source/core/css/MediaQueryEvaluatorTest.cpp View 1 2 3 chunks +82 lines, -62 lines 0 comments Download
M Source/core/css/MediaQueryMatcher.h View 1 2 3 1 chunk +0 lines, -2 lines 0 comments Download
M Source/core/css/MediaQueryMatcher.cpp View 1 2 3 1 chunk +1 line, -9 lines 0 comments Download
M Source/core/css/MediaValues.h View 1 2 2 chunks +2 lines, -6 lines 0 comments Download
M Source/core/css/MediaValues.cpp View 1 2 1 chunk +2 lines, -15 lines 0 comments Download
M Source/core/css/MediaValuesCached.h View 1 2 3 chunks +2 lines, -9 lines 0 comments Download
M Source/core/css/MediaValuesCached.cpp View 1 2 2 chunks +7 lines, -18 lines 0 comments Download
M Source/core/css/MediaValuesDynamic.h View 1 2 1 chunk +1 line, -3 lines 0 comments Download
M Source/core/css/MediaValuesDynamic.cpp View 1 2 1 chunk +2 lines, -12 lines 0 comments Download
M Source/core/css/StyleMedia.cpp View 1 chunk +1 line, -1 line 0 comments Download
M Source/core/css/parser/SizesAttributeParser.cpp View 1 chunk +1 line, -1 line 0 comments Download
M Source/core/css/parser/SizesAttributeParserTest.cpp View 1 2 chunks +2 lines, -3 lines 0 comments Download
M Source/core/css/parser/SizesCalcParserTest.cpp View 1 2 3 2 chunks +2 lines, -3 lines 0 comments Download
M Source/core/css/resolver/StyleResolver.cpp View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M Source/core/html/HTMLLinkElement.cpp View 1 chunk +1 line, -1 line 0 comments Download
M Source/core/html/parser/HTMLPreloadScanner.cpp View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 7 (0 generated)
esprehn
This looks good, but I don't think your patch applies. https://codereview.chromium.org/335313003/diff/40001/Source/core/css/MediaQueryEvaluator.cpp File Source/core/css/MediaQueryEvaluator.cpp (right): https://codereview.chromium.org/335313003/diff/40001/Source/core/css/MediaQueryEvaluator.cpp#newcode100 ...
6 years, 5 months ago (2014-06-27 08:10:32 UTC) #1
Yoav Weiss
On 2014/06/27 08:10:32, esprehn wrote: > This looks good, but I don't think your patch ...
6 years, 5 months ago (2014-06-27 08:16:36 UTC) #2
kenneth.christiansen
lgtm https://codereview.chromium.org/335313003/diff/60001/Source/core/css/MediaQueryEvaluator.cpp File Source/core/css/MediaQueryEvaluator.cpp (right): https://codereview.chromium.org/335313003/diff/60001/Source/core/css/MediaQueryEvaluator.cpp#newcode100 Source/core/css/MediaQueryEvaluator.cpp:100: if (m_mediaValues.get()) Maybe a comment to why you ...
6 years, 5 months ago (2014-06-27 09:09:32 UTC) #3
esprehn
Lgtm, makes sense re the string.
6 years, 5 months ago (2014-06-27 10:01:31 UTC) #4
Yoav Weiss
The CQ bit was checked by yoav@yoav.ws
6 years, 5 months ago (2014-06-27 10:07:25 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/yoav@yoav.ws/335313003/100001
6 years, 5 months ago (2014-06-27 10:07:42 UTC) #6
commit-bot: I haz the power
6 years, 5 months ago (2014-06-27 10:34:41 UTC) #7
Message was sent while issue was closed.
Change committed as 177087

Powered by Google App Engine
This is Rietveld 408576698