OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef MediaValues_h | 5 #ifndef MediaValues_h |
6 #define MediaValues_h | 6 #define MediaValues_h |
7 | 7 |
8 #include "core/css/MediaQueryEvaluator.h" | 8 #include "core/css/MediaQueryEvaluator.h" |
9 #include "core/css/resolver/StyleResolverState.h" | 9 #include "core/css/resolver/StyleResolverState.h" |
10 #include "core/rendering/style/RenderStyle.h" | 10 #include "core/rendering/style/RenderStyle.h" |
11 #include "wtf/RefCounted.h" | 11 #include "wtf/RefCounted.h" |
12 #include "wtf/RefPtr.h" | 12 #include "wtf/RefPtr.h" |
13 #include "wtf/text/WTFString.h" | 13 #include "wtf/text/WTFString.h" |
14 | 14 |
15 namespace WebCore { | 15 namespace WebCore { |
16 | 16 |
17 class Document; | 17 class Document; |
18 | 18 |
19 class MediaValues : public RefCounted<MediaValues> { | 19 class MediaValues : public RefCounted<MediaValues> { |
20 public: | 20 public: |
21 enum MediaValuesMode { CachingMode, | 21 enum MediaValuesMode { CachingMode, |
22 DynamicMode }; | 22 DynamicMode }; |
23 | 23 |
24 enum PointerDeviceType { TouchPointer, | 24 enum PointerDeviceType { TouchPointer, |
25 MousePointer, | 25 MousePointer, |
26 NoPointer, | 26 NoPointer, |
27 UnknownPointer }; | 27 UnknownPointer }; |
28 | 28 |
29 | 29 |
30 static PassRefPtr<MediaValues> create(Document*, MediaValuesMode); | 30 static PassRefPtr<MediaValues> create(const Document&, MediaValuesMode); |
31 static PassRefPtr<MediaValues> create(LocalFrame*, RenderStyle*, MediaValues
Mode); | 31 static PassRefPtr<MediaValues> create(LocalFrame*, RenderStyle*, MediaValues
Mode); |
32 static PassRefPtr<MediaValues> create(MediaValuesMode, | 32 static PassRefPtr<MediaValues> create(MediaValuesMode, |
33 int viewportWidth, | 33 int viewportWidth, |
34 int viewportHeight, | 34 int viewportHeight, |
35 int deviceWidth, | 35 int deviceWidth, |
36 int deviceHeight, | 36 int deviceHeight, |
37 float devicePixelRatio, | 37 float devicePixelRatio, |
38 int colorBitsPerComponent, | 38 int colorBitsPerComponent, |
39 int monochromeBitsPerComponent, | 39 int monochromeBitsPerComponent, |
40 PointerDeviceType, | 40 PointerDeviceType, |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
102 int m_defaultFontSize; | 102 int m_defaultFontSize; |
103 bool m_threeDEnabled; | 103 bool m_threeDEnabled; |
104 bool m_scanMediaType; | 104 bool m_scanMediaType; |
105 bool m_screenMediaType; | 105 bool m_screenMediaType; |
106 bool m_printMediaType; | 106 bool m_printMediaType; |
107 bool m_strictMode; | 107 bool m_strictMode; |
108 }; | 108 }; |
109 | 109 |
110 } // namespace | 110 } // namespace |
111 #endif | 111 #endif |
OLD | NEW |