I need to access this from my setInterval handler
this
setInterval
prefs: null, startup : function() { // init prefs ...
That's not a beauty solution but it's in common usage:
var self = this; var ajax = null; //... ajax.onload = function() { self.prefs....; }