https://bugs.webkit.org/show_bug.cgi?id=78996
Patch by Kalev Lember <kalevlember@gmail.com> on 2012-02-19
Reviewed by Martin Robinson.
The ICU backend defines UChar as wchar_t for platforms where wchar_t is
16 bits wide, e.g. win32.
* platform/graphics/pango/FontPango.cpp:
(WebCore::utf16ToUtf8): Use reinterpret_cast instead of static_cast.
* platform/gtk/GtkPopupMenu.cpp:
(WebCore::GtkPopupMenu::typeAheadFind): Ditto.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@108191
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2012-02-19 Kalev Lember <kalevlember@gmail.com>
+
+ [GTK] Fix build on platforms where UChar is wchar_t
+ https://bugs.webkit.org/show_bug.cgi?id=78996
+
+ Reviewed by Martin Robinson.
+
+ The ICU backend defines UChar as wchar_t for platforms where wchar_t is
+ 16 bits wide, e.g. win32.
+
+ * platform/graphics/pango/FontPango.cpp:
+ (WebCore::utf16ToUtf8): Use reinterpret_cast instead of static_cast.
+ * platform/gtk/GtkPopupMenu.cpp:
+ (WebCore::GtkPopupMenu::typeAheadFind): Ditto.
+
2012-02-19 Carlos Garcia Campos <cgarcia@igalia.com>
Unreviewed. Fix make distcheck issues.
gchar* utf8Text;
glong itemsWritten;
- utf8Text = g_utf16_to_utf8(static_cast<const gunichar2*>(aText), aLength, 0, &itemsWritten, 0);
+ utf8Text = g_utf16_to_utf8(reinterpret_cast<const gunichar2*>(aText), aLength, 0, &itemsWritten, 0);
length = itemsWritten;
return utf8Text;
// menulists.
bool repeatingCharacter = unicodeCharacter != m_previousKeyEventCharacter;
if (event->time - m_previousKeyEventTimestamp > gSearchTimeoutMs)
- m_currentSearchString = String(static_cast<UChar*>(utf16String.get()), charactersWritten);
+ m_currentSearchString = String(reinterpret_cast<UChar*>(utf16String.get()), charactersWritten);
else if (repeatingCharacter)
- m_currentSearchString.append(String(static_cast<UChar*>(utf16String.get()), charactersWritten));
+ m_currentSearchString.append(String(reinterpret_cast<UChar*>(utf16String.get()), charactersWritten));
m_previousKeyEventTimestamp = event->time;
m_previousKeyEventCharacter = unicodeCharacter;