PDA

View Full Version : LoadMask in loading image to Img component



Allan Stark
3 Oct 2012, 5:32 AM
ExtJS 4.1.1a
I need to show "Loading image..." mask during update src property of Img component.

This code not show load mask:

certImg.setLoading('Loading image...');
certImg.setSrc('load_image.php?file_name=' + record.get('invoice_item_file'));
certImg.setLoading(false);

And this code show, but don't hide load mask:

certImg.setLoading('Loading image...');
certImg.setSrc('load_image.php?file_name=' + record.get('invoice_item_file'));

I try to increase image size up to 1-2 Mb, this made load it 3-4 sec, but load mask still hide...
I also tried put certImg.setLoading(false) to afterrender Img event, the result was the same.

mitchellsimoens
10 Oct 2012, 8:54 AM
Does it show if you don't do the setSrc?

Allan Stark
7 Dec 2012, 3:30 AM
Does it show if you don't do the setSrc?
Yes. And when commented "certImg.setLoading(false);" - img is updated, but loadmask still shown over img...

Allan Stark
11 Dec 2012, 11:25 PM
Do not they come across?
Showing masking windos/progress bar is a like a standard situation...