PDA

View Full Version : Is there something that causes the loading mask to show for AjaxProxy?



profunctional
28 Jul 2011, 7:40 PM
I am loading a store using an AjaxProxy. I have not set anything to show/hide a loading mask, yet one always shows up. What could be causing this behavior?

Ty.

mitchellsimoens
29 Jul 2011, 5:17 AM
On what widget?

profunctional
29 Jul 2011, 9:17 PM
The proxy is loading a store for a list. I know it is not my loading gif because the position is higher and the transparency is lighter.

mitchellsimoens
30 Jul 2011, 12:14 PM
The proxy is loading a store for a list. I know it is not my loading gif because the position is higher and the transparency is lighter.

DataView which is the superclass to List actually by defaults will show the LoadMask. If you want to stop this, set the loadingText config to false. Docs only say it accepts String but looking at the source if loadingText is false (or undefined) it will not be created.


new Ext.List({
...
loadText: false
});

Now the default LoadMask will not be created.

profunctional
1 Aug 2011, 7:56 AM
Thanks Mitchell!

mitchellsimoens
1 Aug 2011, 7:59 AM
Thanks Mitchell!

I accept beers as payment :))

Glad it could be solved!

Shranes
1 Aug 2011, 8:42 AM
my issue is quite the contrary.. i'm using an ajax request to populate my custom defined grid.. i cant seem to make the load mask appear.
i used the traditional
var myMask = new Ext.LoadMask(Ext.getBody(), { msg: "Please wait..." });
myMask.show();
which just makes the mask appear for 3 secs..and the grid takes long time to load.
i want the mask to be persistent there til the grid has finished loading.
any suggestions?

mitchellsimoens
1 Aug 2011, 8:50 AM
What grid?

profunctional
1 Aug 2011, 10:45 AM
I have taken note :)

mitchellsimoens
1 Aug 2011, 11:12 AM
The underlaying DataView has a refresh event that you may be able to tie into.

Shranes
1 Aug 2011, 8:22 PM
[CODE]this is my grid code

[CODE]MyGrid = new Ext.ux.MyGridPanel({
id: 'MyGrid',
title: 'Grid',
layout: 'fit',
store: MyStore,
colModel: [...
...]
listeners: {..
.........
...
}

and this is my request code


function GetMyGrid() {

var myMask = new Ext.LoadMask(Ext.getBody(), { msg: "Please wait..." });
myMask.show();


var GetMyGridUrl= baseServiceUrl + "GetMyGrid";

Ext.Ajax.request({
url:GetMyGridUrl,
method: "GET",
params: { id,name },
success: function(result, request) {

//some rendering
myMask.hide();

},
failure: function(error) {

myMask.hide();
}
});
}

so i cant figure out how to make load mask appear til the data is fetched n loaded

Zackdvd
4 Sep 2011, 4:41 AM
new Ext.List({
...
loadText: false
});




For me it was

someList.setLoading(false, true);