Commit f37bdd22 authored by eae@chromium.org's avatar eae@chromium.org

Remove unnecessary ifdefs from font code

Remove unnecessary precompiler conditional statements from the font
platform code that always evaluate to true or are no longer needed.

R=dglazkov@chromium.org
BUG=

Review URL: https://codereview.chromium.org/209083003

git-svn-id: svn://svn.chromium.org/blink/trunk@169785 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent 69243d0f
...@@ -37,6 +37,7 @@ ...@@ -37,6 +37,7 @@
#include "platform/fonts/FontWidthVariant.h" #include "platform/fonts/FontWidthVariant.h"
#include "wtf/Forward.h" #include "wtf/Forward.h"
#include "wtf/Noncopyable.h" #include "wtf/Noncopyable.h"
#include "wtf/RefPtr.h"
#include "wtf/text/WTFString.h" #include "wtf/text/WTFString.h"
#if OS(MACOSX) #if OS(MACOSX)
...@@ -45,10 +46,7 @@ ...@@ -45,10 +46,7 @@
typedef struct CGFont* CGFontRef; typedef struct CGFont* CGFontRef;
#endif #endif
#if OS(MACOSX) || OS(POSIX) || OS(WIN)
#include "wtf/RefPtr.h"
class SkTypeface; class SkTypeface;
#endif
namespace WebCore { namespace WebCore {
...@@ -69,11 +67,10 @@ private: ...@@ -69,11 +67,10 @@ private:
#if OS(MACOSX) #if OS(MACOSX)
explicit FontCustomPlatformData(CGFontRef, PassRefPtr<SkTypeface>); explicit FontCustomPlatformData(CGFontRef, PassRefPtr<SkTypeface>);
RetainPtr<CGFontRef> m_cgFont; RetainPtr<CGFontRef> m_cgFont;
RefPtr<SkTypeface> m_typeface; #else
#elif OS(POSIX) || OS(WIN)
explicit FontCustomPlatformData(PassRefPtr<SkTypeface>); explicit FontCustomPlatformData(PassRefPtr<SkTypeface>);
RefPtr<SkTypeface> m_typeface;
#endif #endif
RefPtr<SkTypeface> m_typeface;
}; };
} // namespace WebCore } // namespace WebCore
......
...@@ -165,9 +165,7 @@ public: ...@@ -165,9 +165,7 @@ public:
CFDictionaryRef getCFStringAttributes(TypesettingFeatures, FontOrientation) const; CFDictionaryRef getCFStringAttributes(TypesettingFeatures, FontOrientation) const;
#endif #endif
#if OS(MACOSX) || USE(HARFBUZZ)
bool canRenderCombiningCharacterSequence(const UChar*, size_t) const; bool canRenderCombiningCharacterSequence(const UChar*, size_t) const;
#endif
bool applyTransforms(GlyphBufferGlyph*, GlyphBufferAdvance*, size_t, TypesettingFeatures) const bool applyTransforms(GlyphBufferGlyph*, GlyphBufferAdvance*, size_t, TypesettingFeatures) const
{ {
...@@ -249,9 +247,7 @@ private: ...@@ -249,9 +247,7 @@ private:
mutable HashMap<unsigned, RetainPtr<CFDictionaryRef> > m_CFStringAttributes; mutable HashMap<unsigned, RetainPtr<CFDictionaryRef> > m_CFStringAttributes;
#endif #endif
#if OS(MACOSX) || USE(HARFBUZZ)
mutable OwnPtr<HashMap<String, bool> > m_combiningCharacterSequenceSupport; mutable OwnPtr<HashMap<String, bool> > m_combiningCharacterSequenceSupport;
#endif
}; };
ALWAYS_INLINE FloatRect SimpleFontData::boundsForGlyph(Glyph glyph) const ALWAYS_INLINE FloatRect SimpleFontData::boundsForGlyph(Glyph glyph) const
......
...@@ -41,10 +41,6 @@ ...@@ -41,10 +41,6 @@
#include "platform/geometry/FloatRect.h" #include "platform/geometry/FloatRect.h"
#include "wtf/unicode/Unicode.h" #include "wtf/unicode/Unicode.h"
#if OS(WIN)
#include "platform/win/HWndDC.h"
#endif
namespace WebCore { namespace WebCore {
// This is the largest VDMX table which we'll try to load and parse. // This is the largest VDMX table which we'll try to load and parse.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment