aboutsummaryrefslogtreecommitdiff
path: root/engine/js/lib/languages.js
diff options
context:
space:
mode:
authorewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-11-02 04:23:04 +0000
committerewinslow <ewinslow@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-11-02 04:23:04 +0000
commitf7ae28ea45656d2821262998e9a71c351dcced8c (patch)
treec0bed93d6a879ca0ee3c2c35a58c8290c10afbe0 /engine/js/lib/languages.js
parentaf335c48fc3f4a741e7b5650db46aac48183c244 (diff)
downloadelgg-f7ae28ea45656d2821262998e9a71c351dcced8c.tar.gz
elgg-f7ae28ea45656d2821262998e9a71c351dcced8c.tar.bz2
Refs #2538: Added Elggy event system. Javascript boot sequence mimics PHP.
git-svn-id: http://code.elgg.org/elgg/trunk@7186 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/js/lib/languages.js')
-rw-r--r--engine/js/lib/languages.js17
1 files changed, 5 insertions, 12 deletions
diff --git a/engine/js/lib/languages.js b/engine/js/lib/languages.js
index 6ac83f350..3231cf77d 100644
--- a/engine/js/lib/languages.js
+++ b/engine/js/lib/languages.js
@@ -5,10 +5,6 @@ elgg.provide('elgg.config.translations');
elgg.config.language = 'en';
-elgg.config.translations.init = function() {
- elgg.reload_all_translations();
-};
-
elgg.add_translation = function(lang, translations) {
elgg.provide('elgg.config.translations.' + lang);
@@ -37,11 +33,6 @@ elgg.reload_all_translations = function(language) {
};
/**
- * @deprecated Use elgg.reload_all_translations
- */
-elgg.config.translations.load = elgg.reload_all_translations;
-
-/**
* Get the current language
* @return {String}
*/
@@ -85,6 +76,8 @@ elgg.echo = function(key, language) {
return undefined;
};
-$(function() {
- elgg.config.translations.init();
-}); \ No newline at end of file
+elgg.config.translations.init = function() {
+ elgg.reload_all_translations();
+};
+
+elgg.register_event_handler('boot', 'system', elgg.config.translations.init); \ No newline at end of file