From a1ce2d3f0aff6dcb7149f2d7327a10079e5c78f8 Mon Sep 17 00:00:00 2001 From: jhilden Date: Sat, 29 Aug 2009 19:19:04 -0400 Subject: you can close the l10n client directly from its interface now, without going back to the languages admin page --- modules/gallery/js/l10n_client.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'modules/gallery/js') diff --git a/modules/gallery/js/l10n_client.js b/modules/gallery/js/l10n_client.js index 80fe166b..35986e5a 100644 --- a/modules/gallery/js/l10n_client.js +++ b/modules/gallery/js/l10n_client.js @@ -205,6 +205,19 @@ Gallery.behaviors.l10nClient = function(context) { Gallery.l10nClient.toggle(0); } }); + + // Close the l10n client using an AJAX call and refreshing the page + $('#gCloseL10n').click(function(event) { + $.ajax({ + type: "GET", + url: toggle_l10n_mode_url, + data: "csrf=" + csrf, + success: function() { + window.location.reload(true); + } + }); + event.preventDefault(); + }); // Register keybindings using jQuery hotkeys // TODO: Either remove hotkeys code or add query.hotkeys.js. -- cgit v1.2.3