OLD | NEW |
---|---|
(Empty) | |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef MediaValuesCached_h | |
6 #define MediaValuesCached_h | |
7 | |
8 #include "core/css/MediaValues.h" | |
9 | |
10 namespace WebCore { | |
11 | |
12 class MediaValuesCached : public MediaValues { | |
eseidel
2014/04/14 23:10:13
Please mark the class as FINAL.
| |
13 public: | |
14 static PassRefPtr<MediaValues> create(LocalFrame*, RenderStyle*); | |
15 static PassRefPtr<MediaValues> create(MediaValuesInitializer&); | |
16 virtual PassRefPtr<MediaValues> copy() const; | |
17 virtual bool isSafeToSendToAnotherThread() const; | |
eseidel
2014/04/14 23:10:13
These are all OVERRIDE.
| |
18 virtual bool computeLength(CSSPrimitiveValue&, int& result) const; | |
19 | |
20 virtual int viewportWidth() const; | |
21 virtual int viewportHeight() const; | |
22 virtual int deviceWidth() const; | |
23 virtual int deviceHeight() const; | |
24 virtual float devicePixelRatio() const; | |
25 virtual int colorBitsPerComponent() const; | |
26 virtual int monochromeBitsPerComponent() const; | |
27 virtual PointerDeviceType pointer() const; | |
28 virtual bool threeDEnabled() const; | |
29 virtual bool scanMediaType() const; | |
30 virtual bool screenMediaType() const; | |
31 virtual bool printMediaType() const; | |
32 virtual bool strictMode() const; | |
33 virtual Document* document() const; | |
34 virtual bool hasValues() const; | |
35 | |
36 protected: | |
37 MediaValuesCached(LocalFrame*, RenderStyle*); | |
38 MediaValuesCached(MediaValuesInitializer&); | |
39 | |
40 // Members variables beyond this point must be thread safe, since they're co pied to the parser thread | |
41 int m_viewportWidth; | |
42 int m_viewportHeight; | |
43 int m_deviceWidth; | |
44 int m_deviceHeight; | |
45 float m_devicePixelRatio; | |
46 int m_colorBitsPerComponent; | |
47 int m_monochromeBitsPerComponent; | |
48 PointerDeviceType m_pointer; | |
49 int m_defaultFontSize; | |
50 int m_computedFontSize; | |
51 bool m_hasXHeight; | |
52 double m_xHeight; | |
53 double m_zeroWidth; | |
54 bool m_threeDEnabled; | |
55 bool m_scanMediaType; | |
56 bool m_screenMediaType; | |
57 bool m_printMediaType; | |
58 bool m_strictMode; | |
59 }; | |
60 | |
61 } // namespace | |
62 | |
63 #endif // MediaValuesCached_h | |
OLD | NEW |