| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 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 CCHeadsUpDisplayLayerImpl_h | 5 #ifndef CCHeadsUpDisplayLayerImpl_h |
| 6 #define CCHeadsUpDisplayLayerImpl_h | 6 #define CCHeadsUpDisplayLayerImpl_h |
| 7 | 7 |
| 8 #include "CCFontAtlas.h" | 8 #include "CCFontAtlas.h" |
| 9 #include "CCLayerImpl.h" | 9 #include "CCLayerImpl.h" |
| 10 #include "CCScopedTexture.h" | 10 #include "CCScopedTexture.h" |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 | 27 |
| 28 void setFontAtlas(PassOwnPtr<CCFontAtlas>); | 28 void setFontAtlas(PassOwnPtr<CCFontAtlas>); |
| 29 | 29 |
| 30 virtual void willDraw(CCResourceProvider*) OVERRIDE; | 30 virtual void willDraw(CCResourceProvider*) OVERRIDE; |
| 31 virtual void appendQuads(CCQuadSink&, CCAppendQuadsData&) OVERRIDE; | 31 virtual void appendQuads(CCQuadSink&, CCAppendQuadsData&) OVERRIDE; |
| 32 void updateHudTexture(CCResourceProvider*); | 32 void updateHudTexture(CCResourceProvider*); |
| 33 virtual void didDraw(CCResourceProvider*) OVERRIDE; | 33 virtual void didDraw(CCResourceProvider*) OVERRIDE; |
| 34 | 34 |
| 35 virtual void didLoseContext() OVERRIDE; | 35 virtual void didLoseContext() OVERRIDE; |
| 36 | 36 |
| 37 virtual bool layerIsAlwaysDamaged() const OVERRIDE { return true; } | 37 virtual bool layerIsAlwaysDamaged() const OVERRIDE; |
| 38 | 38 |
| 39 private: | 39 private: |
| 40 explicit CCHeadsUpDisplayLayerImpl(int); | 40 explicit CCHeadsUpDisplayLayerImpl(int); |
| 41 | 41 |
| 42 virtual const char* layerTypeAsString() const OVERRIDE { return "HeadsUpDisp
layLayer"; } | 42 virtual const char* layerTypeAsString() const OVERRIDE; |
| 43 | 43 |
| 44 void drawHudContents(SkCanvas*); | 44 void drawHudContents(SkCanvas*); |
| 45 void drawFPSCounter(SkCanvas*, CCFrameRateCounter*, int top, int height); | 45 void drawFPSCounter(SkCanvas*, CCFrameRateCounter*, int top, int height); |
| 46 void drawFPSCounterText(SkCanvas*, CCFrameRateCounter*, int top, int width,
int height); | 46 void drawFPSCounterText(SkCanvas*, CCFrameRateCounter*, int top, int width,
int height); |
| 47 void drawDebugRects(SkCanvas*, CCDebugRectHistory*); | 47 void drawDebugRects(SkCanvas*, CCDebugRectHistory*); |
| 48 | 48 |
| 49 OwnPtr<CCFontAtlas> m_fontAtlas; | 49 OwnPtr<CCFontAtlas> m_fontAtlas; |
| 50 OwnPtr<CCScopedTexture> m_hudTexture; | 50 OwnPtr<CCScopedTexture> m_hudTexture; |
| 51 OwnPtr<SkCanvas> m_hudCanvas; | 51 OwnPtr<SkCanvas> m_hudCanvas; |
| 52 }; | 52 }; |
| 53 | 53 |
| 54 } | 54 } |
| 55 | 55 |
| 56 #endif // CCHeadsUpDisplayLayerImpl_h | 56 #endif // CCHeadsUpDisplayLayerImpl_h |
| OLD | NEW |