Chromium Code Reviews| Index: Source/core/css/MediaQueryListEvent.h |
| diff --git a/Source/core/css/MediaQueryListEvent.h b/Source/core/css/MediaQueryListEvent.h |
| index f5786bf246142f13e0829633ac2c0f5f610d83cd..779813856f64e402203ffe4f2f68a2046ae847fc 100644 |
| --- a/Source/core/css/MediaQueryListEvent.h |
| +++ b/Source/core/css/MediaQueryListEvent.h |
| @@ -6,17 +6,11 @@ |
| #define MediaQueryListEvent_h |
| #include "core/css/MediaQueryList.h" |
| +#include "core/css/MediaQueryListEventInit.h" |
| #include "core/events/Event.h" |
| namespace blink { |
| -struct MediaQueryListEventInit : public EventInit { |
| - MediaQueryListEventInit() : matches(false) { } |
| - |
| - String media; |
| - bool matches; |
| -}; |
| - |
| class MediaQueryListEvent final : public Event { |
| DEFINE_WRAPPERTYPEINFO(); |
| public: |
| @@ -67,8 +61,8 @@ private: |
| MediaQueryListEvent(const AtomicString& eventType, const MediaQueryListEventInit& initializer) |
| : Event(eventType, initializer) |
| - , m_media(initializer.media) |
| - , m_matches(initializer.matches) { } |
| + , m_media(initializer.media()) |
| + , m_matches(initializer.matches()) { } |
|
haraken
2014/12/12 05:12:07
I'd prefer following the following pattern even if
|
| // We have m_media/m_matches for JS-created events; we use m_mediaQueryList |
| // for events that blink generates. |