Pass a callback function into the fetchLogins method and call that function
once the call has returned from the server:

fetchLogins : function(username, password, callback, context) { 
this.__callback = callback;
this.__context = context;
[...] 
}, 
Response : function(response){ 
var  myData = JSON.parse(response.getContent()); 
this.__callback.call( this.__context, myData);
} 

Application.js: 

  loginWindow.addListener("changeLoginData", function(ev) { 
      
      var loginData = ev.getData(); 
      service.fetchLogins(loginData.username, loginData.password,
function(data){
        // handle data
      }, this); 


-- 
View this message in context: 
http://qooxdoo.678.n2.nabble.com/json-response-convert-into-a-variable-tp5687679p5689404.html
Sent from the qooxdoo mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel

Reply via email to