summaryrefslogtreecommitdiff
path: root/src/static
diff options
context:
space:
mode:
authorMarcel Klehr <mklehr@gmx.net>2012-11-12 16:49:15 +0100
committerMarcel Klehr <mklehr@gmx.net>2012-11-12 16:49:15 +0100
commit7021a8b8859958a12c6f7d1747d59816b29af169 (patch)
tree55fd1226d4b83f9ff62ce609dbfdcff145f2dcb5 /src/static
parentfb340793da2a9f5d58ef868b7750ca1841a29bf3 (diff)
downloadetherpad-lite-7021a8b8859958a12c6f7d1747d59816b29af169.zip
Add pad setting for UI lang
Diffstat (limited to 'src/static')
-rw-r--r--src/static/js/pad.js1
-rw-r--r--src/static/js/pad_editor.js5
2 files changed, 6 insertions, 0 deletions
diff --git a/src/static/js/pad.js b/src/static/js/pad.js
index c55f8dfe..a07b29b5 100644
--- a/src/static/js/pad.js
+++ b/src/static/js/pad.js
@@ -447,6 +447,7 @@ var pad = {
{
pad.collabClient.sendClientMessage(msg);
},
+ createCookie: createCookie,
init: function()
{
diff --git a/src/static/js/pad_editor.js b/src/static/js/pad_editor.js
index 5a9e7b9b..690dde37 100644
--- a/src/static/js/pad_editor.js
+++ b/src/static/js/pad_editor.js
@@ -75,6 +75,11 @@ var padeditor = (function()
{
pad.changeViewOption('useMonospaceFont', $("#viewfontmenu").val() == 'monospace');
});
+ $("#languagemenu").val(document.webL10n.getLanguage());
+ $("#languagemenu").change(function() {
+ pad.createCookie("language",$("#languagemenu").val(),null,'/');
+ document.webL10n.setLanguage($("#languagemenu").val());
+ });
},
setViewOptions: function(newOptions)
{