Pman.GoogleTranslate.js
[Pman.Core] / Pman.GoogleTranslate.js
index 98834e1..d6a153a 100644 (file)
@@ -140,10 +140,13 @@ Pman.GoogleTranslate = function(str, src, dest, cb, force) {
                 src  : src,
                 dest : dest,
             },
-            success: function()
+            success: function(o)
             {
-                Roo.MessageBox.alert("Success", "We logged in OK")
-
+                if (!o.data) {
+                        return o;
+                    }
+//                Roo.MessageBox.alert("Success", "We logged in OK")
+                return o.data.translations[0].translatedText;
             },
             failure: function (res) {
                 Roo.log(res);