summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorYorhel <git@yorhel.nl>2009-10-07 18:49:31 +0200
committerYorhel <git@yorhel.nl>2009-10-07 18:49:31 +0200
commitbbc03376d61e2e557d473368611dbba5eead6338 (patch)
treeb22400cf38f1d18c130647f0236ccdf4dd84257e /util
parent46a046e88c0059770fcffcf64d43ddbdbeb4fcc6 (diff)
Changed language selector into a Javascript dropdown
Diffstat (limited to 'util')
-rwxr-xr-xutil/jsgen.pl4
1 files changed, 3 insertions, 1 deletions
diff --git a/util/jsgen.pl b/util/jsgen.pl
index c7cca2c2..56897679 100755
--- a/util/jsgen.pl
+++ b/util/jsgen.pl
@@ -22,7 +22,9 @@ use LangFile;
use VNDB::L10N;
+my $jskeys_lang = join '|', VNDB::L10N::languages();
my $jskeys = qr{^(?:
+ _lang_(?:$jskeys_lang)|
_js_.+|
_menu_emptysearch|
_vnpage_uopt_(?:10?vote|rel.+)|
@@ -64,7 +66,7 @@ sub l10n {
$val =~ s/"/\\"/g;
$val =~ s/\n/\\n/g;
$r[$#r] .= ',' if $cur == 2;
- $lang = q{"$l->[0]"} if $lang =~ /^(?:as|do|if|in|is)$/; # reserved two-char words
+ $lang = qq{"$l->[0]"} if $lang =~ /^(?:as|do|if|in|is)$/; # reserved two-char words
push @r, qq| $lang: "$val"|;
$cur = 2;
}