[Title] Fixed untranslate issue.
[Issue#] P130905-02813
[Problem] Text selection popup is untranslate when change the language
[Cause] Do not set locale when change the language
[Solution] Set information of locale when change the languge
Change-Id: I5b82dd48a9affaa1a5a853a8db5eed25a27ddaee
return;
}
-#if ENABLE(TIZEN_WEBKIT2_TEXT_TRANSLATION)
- bindtextdomain("WebKit", WEBKIT_TEXT_DIR);
-#endif
-
// make Error Page Source
String errorPageFile = WEBKIT_HTML_DIR"/errorPage.html";
long long fileSize = 0;
evas_object_show(picker->popupList);
elm_object_part_content_set(picker->container, "elm.swallow.content", picker->popupList);
- bindtextdomain("WebKit", WEBKIT_TEXT_DIR);
edje_object_part_text_set(elm_layout_edje_get(picker->container), "elm.text.done", dgettext("WebKit","IDS_WEBVIEW_BUTTON_DONE"));
}
#include <wtf/text/CString.h>
#include <wtf/text/WTFString.h>
+#if ENABLE(TIZEN_WEBKIT2_TEXT_TRANSLATION)
+#include <libintl.h>
+#include <locale.h>
+#include <vconf/vconf.h>
+#endif
+
using namespace WebCore;
using namespace std;
}
#endif
+#if ENABLE(TIZEN_WEBKIT2_TEXT_TRANSLATION)
+void WebProcessProxy::platformLanguageChanged()
+{
+ setlocale(LC_ALL, vconf_get_str(VCONFKEY_LANGSET));
+ bindtextdomain("WebKit", WEBKIT_TEXT_DIR);
+}
+#endif
+
#if ENABLE(TIZEN_WEBKIT2_MEMORY_SAVING_MODE)
void WebProcessProxy::setMemorySavingMode(bool mode)
{
RefPtr<PlatformSurfaceTexturePool> platformSurfaceTexturePool() { return m_platformSurfaceTexturePool.get(); }
void removePlatformSurfaceTextureFromPool(int platformSurfaceId);
#endif
+#if ENABLE(TIZEN_WEBKIT2_TEXT_TRANSLATION)
+ void platformLanguageChanged();
+#endif
#if ENABLE(TIZEN_WEBKIT2_MEMORY_SAVING_MODE)
void setMemorySavingMode(bool);
bool memorySavingModeEnabled() { return m_memorySavingModeEnabled; }
#if ENABLE(TIZEN_WEBKIT2_TILED_AC_SHARED_PLATFORM_SURFACE)
RemovePlatformSurfaceTextureFromPool(int platformSurfaceId)
#endif
+#if ENABLE(TIZEN_WEBKIT2_TEXT_TRANSLATION)
+ PlatformLanguageChanged()
+#endif
}
#include <WebCore/TizenExtensibleAPI.h>
#endif
+#if ENABLE(TIZEN_WEBKIT2_TEXT_TRANSLATION)
+#include <libintl.h>
+#include <locale.h>
+#include <vconf/vconf.h>
+#endif
+
using namespace JSC;
using namespace WebCore;
}
#endif
+#if ENABLE(TIZEN_WEBKIT2_TEXT_TRANSLATION)
+void platformLanguageChanged(keynode_t* keynode, void* data)
+{
+ setlocale(LC_ALL, vconf_get_str(VCONFKEY_LANGSET));
+ bindtextdomain("WebKit", WEBKIT_TEXT_DIR);
+
+ static_cast<WebProcess*>(data)->connection()->send(Messages::WebProcessProxy::PlatformLanguageChanged(), 0);
+}
+#endif
+
static void randomCrashThread(void*) NO_RETURN_DUE_TO_CRASH;
void randomCrashThread(void*)
{
WebCore::AsyncImageDecoder::sharedAsyncImageDecoder();
#endif
+#if ENABLE(TIZEN_WEBKIT2_TEXT_TRANSLATION)
+ setlocale(LC_ALL, vconf_get_str(VCONFKEY_LANGSET));
+ bindtextdomain("WebKit", WEBKIT_TEXT_DIR);
+ connection()->send(Messages::WebProcessProxy::PlatformLanguageChanged(), 0);
+ vconf_notify_key_changed(VCONFKEY_LANGSET, platformLanguageChanged, this);
+#endif
+
startRandomCrashThreadIfRequested();
}
#include "WebProcessCreationParameters.h"
#include <WebCore/NotImplemented.h>
-#if ENABLE(TIZEN_WEBKIT2_TEXT_TRANSLATION)
-#include <locale.h>
-#include <libintl.h>
-#endif
#if ENABLE(TIZEN_SOUP_COOKIE_CACHE_FOR_WEBKIT2)
#include <WebCore/MemoryCache.h>
#include <WebCore/PageCache.h>
void WebProcess::platformInitializeWebProcess(const WebProcessCreationParameters& parameters, CoreIPC::ArgumentDecoder*)
{
-#if ENABLE(TIZEN_WEBKIT2_TEXT_TRANSLATION)
- setlocale(LC_ALL, "");
- bindtextdomain("WebKit", WEBKIT_TEXT_DIR);
-#endif
-
#if ENABLE(TIZEN_WEBKIT2_PROXY)
setProxy(parameters.proxyAddress);
#endif