* @param object options
*/
WCF.Action.Proxy = Class.extend({
+ /**
+ * shows loading overlay for a single request
+ * @var boolean
+ */
+ _showLoadingOverlayOnce: false,
+
/**
* suppresses errors
* @var boolean
this.confirmationDialog = null;
this.loading = null;
+ this._showLoadingOverlayOnce = false;
this._suppressErrors = false;
// send request immediately after initialization
});
},
+ /**
+ * Shows loading overlay for a single request.
+ */
+ showLoadingOverlayOnce: function() {
+ this._showLoadingOverlayOnce = true;
+ },
+
/**
* Fires before request is send, displays global loading status.
*/
this.options.init(this);
}
- if (this.options.showLoadingOverlay) {
+ if (this.options.showLoadingOverlay || this._showLoadingOverlayOnce) {
WCF.LoadingOverlayHandler.show();
}
},
this.options.after();
}
- if (this.options.showLoadingOverlay) {
+ if (this.options.showLoadingOverlay || this._showLoadingOverlayOnce) {
WCF.LoadingOverlayHandler.hide();
+
+ if (this._showLoadingOverlayOnce) {
+ this._showLoadingOverlayOnce = false;
+ }
}
// disable DOMNodeInserted event