diff --git a/modules/juce_graphics/native/juce_RenderingHelpers.h b/modules/juce_graphics/native/juce_RenderingHelpers.h index 885cebd002..ad08e9f933 100644 --- a/modules/juce_graphics/native/juce_RenderingHelpers.h +++ b/modules/juce_graphics/native/juce_RenderingHelpers.h @@ -162,15 +162,6 @@ public: } //============================================================================== - void drawGlyph (RenderTargetType& target, const Font& font, const int glyphNumber, Point pos) - { - if (ReferenceCountedObjectPtr glyph = findOrCreateGlyph (font, glyphNumber)) - { - glyph->lastAccessCount = ++accessCounter; - glyph->draw (target, pos); - } - } - void reset() { const ScopedLock sl (lock); @@ -180,11 +171,14 @@ public: misses.set (0); } -private: - friend struct ContainerDeletePolicy; - ReferenceCountedArray glyphs; - Atomic accessCounter, hits, misses; - CriticalSection lock; + void drawGlyph (RenderTargetType& target, const Font& font, const int glyphNumber, Point pos) + { + if (ReferenceCountedObjectPtr glyph = findOrCreateGlyph (font, glyphNumber)) + { + glyph->lastAccessCount = ++accessCounter; + glyph->draw (target, pos); + } + } ReferenceCountedObjectPtr findOrCreateGlyph (const Font& font, int glyphNumber) { @@ -203,6 +197,12 @@ private: return g; } +private: + friend struct ContainerDeletePolicy; + ReferenceCountedArray glyphs; + Atomic accessCounter, hits, misses; + CriticalSection lock; + CachedGlyphType* findExistingGlyph (const Font& font, int glyphNumber) const { for (int i = 0; i < glyphs.size(); ++i) @@ -302,12 +302,10 @@ public: } Font font; + ScopedPointer edgeTable; int glyph, lastAccessCount; bool snapToIntegerCoordinate; -private: - ScopedPointer edgeTable; - JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (CachedGlyphEdgeTable) };