Answer for the old version, see below for jQuery Mobile 1.1.0 +
I do not know the variable that you can set in the mobileinit event mobileinit , but you can change the theme'd class when the document is ready:
//run the code on `document.ready` jQuery(function ($) { //find the loader div and change its theme from `a` to `e` $('.ui-loader').removeClass('ui-body-a').addClass('ui-body-e'); });
Here is the jsfiddle from the above solution (you can change the theme for the download dialog from the list of buttons): http://jsfiddle.net/jasper/eqxN9/1/ >
Update
jQuery Mobile 1.1.0 adds some support for this, you can set some default values:
loadingMessage string, default: "loading". Set the text that appears. when loading the page. If set to false, the message will not appear at all.
loadingMessageTextVisible boolean, default: false Whether the text should be displayed when a loading message is displayed. Text is always visible for loading errors.
loadingMessageTheme string, default: "a" The subject of the loading message box is used when the text is visible.
Source: http://jquerymobile.com/demos/1.1.0/docs/api/globalconfig.html
Note that you must set loadingMessageTextVisible to true order to override the loader theme to work due to the new loader design. If you do not set the message, then there is no background to change the color ...
Here is a demo: http://jsfiddle.net/vHJnd/
A quick look through the documentation shows that you can do this on the fly, and now:
$.mobile.showPageLoadingMsg("a", 'loading message');
You can add these arguments to the showPageLoadingMsg() function to display the subject and message. This is an alternative to setting the default value.
Here is a demo: http://jsfiddle.net/vHJnd/1/