mooedang1 / android-query

Automatically exported from code.google.com/p/android-query
0 stars 0 forks source link

Image Placeholder + BitmapAjaxCallback #168

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
I need to load a image with url, using a placeholder before load the image and 
the BitmapAjaxCallback to add more ui views above the image. So i use the 
method:

aq.id(R.id.v_image_back).image(myPlaceHolder)
aq.id(R.id.v_image_back).image(url, true, true, photoSize, 0, new 
BitmapAjaxCallback() {
            @Override
            public void callback(String url, ImageView iv, Bitmap bm, AjaxStatus status) {
                if (status.getCode() > 199  && status.getCode() <= 299) {
                    // My Additional Code (if success)
                }
            }
        });

The problem is that my placeholder is replaced before the URL call. Also, the 
status returns 200 even if i close the network data or wi-fi.

Is any way to keep the placeholder until the image is loaded and parse 
correctly the status code?

Original issue reported on code.google.com by mspap...@gmail.com on 28 Nov 2013 at 8:48

GoogleCodeExporter commented 8 years ago
Hi, did you solve this issue?

Original comment by paxa...@gmail.com on 22 Mar 2014 at 8:56

GoogleCodeExporter commented 8 years ago
Did anyone solve this?

Original comment by mygreymatter on 24 Oct 2014 at 5:21

GoogleCodeExporter commented 8 years ago
Unfortunately, i haven't managed to find a solution

Original comment by mspap...@gmail.com on 24 Oct 2014 at 7:17