Java 类com.nostra13.universalimageloader.core.assist.LoadedFrom 实例源码

项目:EveryXDay    文件:AnimatioinAndCornerBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware,
        LoadedFrom loadedFrom) {

    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }

    imageAware.setImageDrawable(new RoundedDrawable(bitmap, cornerRadius, margin));

    if ((animateFromNetwork && loadedFrom == LoadedFrom.NETWORK) ||
            (animateFromDisk && loadedFrom == LoadedFrom.DISC_CACHE) ||
            (animateFromMemory && loadedFrom == LoadedFrom.MEMORY_CACHE)) {
        animate(imageAware.getWrappedView(), durationMillis);
    }
}
项目:MiBandDecompiled    文件:l.java   
public l(i i1, k k1, Handler handler)
{
    K = LoadedFrom.NETWORK;
    z = i1;
    A = k1;
    B = handler;
    C = i1.a;
    D = C.p;
    E = C.s;
    F = C.t;
    G = C.q;
    a = k1.a;
    H = k1.b;
    b = k1.c;
    I = k1.d;
    c = k1.e;
    d = k1.f;
    e = k1.g;
    J = c.a();
}
项目:MiBandDecompiled    文件:BraceletImageLoader$RoundBitmapDisplayer.java   
public void display(Bitmap bitmap, ImageAware imageaware, LoadedFrom loadedfrom)
{
    if (!(imageaware instanceof ImageViewAware))
    {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }
    Bitmap bitmap1 = Util.clipToRoundBitmap(bitmap);
    ImageView imageview = (ImageView)imageaware.getWrappedView();
    if (bitmap1 == null || imageview == null)
    {
        return;
    } else
    {
        imageview.setBackground(new BitmapDrawable(imageview.getResources(), bitmap1));
        return;
    }
}
项目:scissors    文件:UILFillViewportDisplayer.java   
@Override
public void display(Bitmap source, ImageAware imageAware, LoadedFrom loadedFrom) {
    int sourceWidth = source.getWidth();
    int sourceHeight = source.getHeight();

    Rect target = CropViewExtensions.computeTargetSize(sourceWidth, sourceHeight, viewportWidth, viewportHeight);
    final Bitmap result = Bitmap.createScaledBitmap(
            source,
            target.width(),
            target.height(),
            true);

    if (result != source) {
        source.recycle();
    }

    imageAware.setImageBitmap(result);
}
项目:GitHub    文件:OldRoundedBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }
    Bitmap roundedBitmap = roundCorners(bitmap, (ImageViewAware) imageAware, roundPixels);
    imageAware.setImageBitmap(roundedBitmap);
}
项目:GitHub    文件:RoundedBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }

    imageAware.setImageDrawable(new RoundedDrawable(bitmap, cornerRadius, margin));
}
项目:GitHub    文件:RoundedVignetteBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }

    imageAware.setImageDrawable(new RoundedVignetteDrawable(bitmap, cornerRadius, margin));
}
项目:GitHub    文件:FadeInBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    imageAware.setImageBitmap(bitmap);

    if ((animateFromNetwork && loadedFrom == LoadedFrom.NETWORK) ||
            (animateFromDisk && loadedFrom == LoadedFrom.DISC_CACHE) ||
            (animateFromMemory && loadedFrom == LoadedFrom.MEMORY_CACHE)) {
        animate(imageAware.getWrappedView(), durationMillis);
    }
}
项目:GitHub    文件:CircleBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }

    imageAware.setImageDrawable(new CircleDrawable(bitmap, strokeColor, strokeWidth));
}
项目:GitHub    文件:ProcessAndDisplayImageTask.java   
@Override
public void run() {
    L.d(LOG_POSTPROCESS_IMAGE, imageLoadingInfo.memoryCacheKey);

    BitmapProcessor processor = imageLoadingInfo.options.getPostProcessor();
    Bitmap processedBitmap = processor.process(bitmap);
    DisplayBitmapTask displayBitmapTask = new DisplayBitmapTask(processedBitmap, imageLoadingInfo, engine,
            LoadedFrom.MEMORY_CACHE);
    LoadAndDisplayImageTask.runTask(displayBitmapTask, imageLoadingInfo.options.isSyncLoading(), handler, engine);
}
项目:GitHub    文件:DisplayBitmapTask.java   
public DisplayBitmapTask(Bitmap bitmap, ImageLoadingInfo imageLoadingInfo, ImageLoaderEngine engine,
        LoadedFrom loadedFrom) {
    this.bitmap = bitmap;
    imageUri = imageLoadingInfo.uri;
    imageAware = imageLoadingInfo.imageAware;
    memoryCacheKey = imageLoadingInfo.memoryCacheKey;
    displayer = imageLoadingInfo.options.getDisplayer();
    listener = imageLoadingInfo.listener;
    this.engine = engine;
    this.loadedFrom = loadedFrom;
}
项目:letv    文件:RoundedBitmapDisplayer.java   
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (imageAware instanceof ImageViewAware) {
        imageAware.setImageDrawable(new RoundedDrawable(bitmap, this.cornerRadius, this.margin));
        return;
    }
    throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
}
项目:letv    文件:RoundedVignetteBitmapDisplayer.java   
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (imageAware instanceof ImageViewAware) {
        imageAware.setImageDrawable(new RoundedVignetteDrawable(bitmap, this.cornerRadius, this.margin));
        return;
    }
    throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
}
项目:letv    文件:DisplayBitmapTask.java   
public DisplayBitmapTask(Bitmap bitmap, ImageLoadingInfo imageLoadingInfo, ImageLoaderEngine engine, LoadedFrom loadedFrom) {
    this.bitmap = bitmap;
    this.imageUri = imageLoadingInfo.uri;
    this.imageAware = imageLoadingInfo.imageAware;
    this.memoryCacheKey = imageLoadingInfo.memoryCacheKey;
    this.displayer = imageLoadingInfo.options.getDisplayer();
    this.listener = imageLoadingInfo.listener;
    this.engine = engine;
    this.loadedFrom = loadedFrom;
}
项目:ShortcutMenu    文件:RoundBorderBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }
    imageAware.setImageDrawable(getImageDrawable(imageAware,bitmap));
}
项目:ShortcutMenu    文件:CircleBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }

    imageAware.setImageDrawable(new CircleDrawable(bitmap, margin));
}
项目:GifImageLoader    文件:OldRoundedBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom, int fileTypeStatus, String filepath) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }
    Bitmap roundedBitmap = roundCorners(bitmap, (ImageViewAware) imageAware, roundPixels);
    imageAware.setImageBitmap(roundedBitmap);
}
项目:GifImageLoader    文件:RoundedBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom, int fileTypeStatus, String filepath) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }
    imageAware.setImageDrawable(new RoundedDrawable(bitmap, cornerRadius, margin));
}
项目:GifImageLoader    文件:RoundedVignetteBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom, int fileTypeStatus, String filepath) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }
    imageAware.setImageDrawable(new RoundedVignetteDrawable(bitmap, cornerRadius, margin));
}
项目:GifImageLoader    文件:FadeInBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom, int fileTypeStatus, String filepath) {
    imageAware.setImageBitmap(bitmap);
    if ((animateFromNetwork && loadedFrom == LoadedFrom.NETWORK) ||
            (animateFromDisk && loadedFrom == LoadedFrom.DISC_CACHE) ||
            (animateFromMemory && loadedFrom == LoadedFrom.MEMORY_CACHE)) {
        animate(imageAware.getWrappedView(), durationMillis);
    }
}
项目:GifImageLoader    文件:SimpleBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom, int fileTypeStatus, String filepath) {
    if (fileTypeStatus == BitmapDisplayer.FILE_TYPE_GIF_IMAGE && !TextUtils.isEmpty(filepath)) {
        try {
            imageAware.setImageDrawable(new GifDrawable(filepath));
        } catch (IOException e) {
            imageAware.setImageBitmap(bitmap);
        }
    } else {
        imageAware.setImageBitmap(bitmap);
    }
}
项目:GifImageLoader    文件:CircleBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom, int fileTypeStatus, String filepath) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }

    imageAware.setImageDrawable(new CircleDrawable(bitmap, strokeColor, strokeWidth));
}
项目:GifImageLoader    文件:ProcessAndDisplayImageTask.java   
@Override
public void run() {
    L.d(LOG_POSTPROCESS_IMAGE, imageLoadingInfo.memoryCacheKey);

    BitmapProcessor processor = imageLoadingInfo.options.getPostProcessor();
    Bitmap processedBitmap = processor.process(bitmap);
    DisplayBitmapTask displayBitmapTask = new DisplayBitmapTask(processedBitmap, imageLoadingInfo, engine,
            LoadedFrom.MEMORY_CACHE);
    LoadAndDisplayImageTask.runTask(displayBitmapTask, imageLoadingInfo.options.isSyncLoading(), handler, engine);
}
项目:GifImageLoader    文件:DisplayBitmapTask.java   
public DisplayBitmapTask(Bitmap bitmap, ImageLoadingInfo imageLoadingInfo, ImageLoaderEngine engine,
        LoadedFrom loadedFrom) {
    this.bitmap = bitmap;
    imageUri = imageLoadingInfo.uri;
    imageAware = imageLoadingInfo.imageAware;
    memoryCacheKey = imageLoadingInfo.memoryCacheKey;
    displayer = imageLoadingInfo.options.getDisplayer();
    listener = imageLoadingInfo.listener;
    this.engine = engine;
    this.loadedFrom = loadedFrom;

       mFileStatusType = imageLoadingInfo.mFileTypeStatus;
       mFilePath = imageLoadingInfo.mFilePath;
}
项目:boohee_v5.6    文件:RoundedBitmapDisplayer.java   
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (imageAware instanceof ImageViewAware) {
        imageAware.setImageDrawable(new RoundedDrawable(bitmap, this.cornerRadius, this
                .margin));
        return;
    }
    throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
}
项目:boohee_v5.6    文件:RoundedVignetteBitmapDisplayer.java   
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (imageAware instanceof ImageViewAware) {
        imageAware.setImageDrawable(new RoundedVignetteDrawable(bitmap, this.cornerRadius,
                this.margin));
        return;
    }
    throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is " +
            "expected.");
}
项目:boohee_v5.6    文件:FadeInBitmapDisplayer.java   
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    imageAware.setImageBitmap(bitmap);
    if ((this.animateFromNetwork && loadedFrom == LoadedFrom.NETWORK) || ((this
            .animateFromDisk && loadedFrom == LoadedFrom.DISC_CACHE) || (this
            .animateFromMemory && loadedFrom == LoadedFrom.MEMORY_CACHE))) {
        animate(imageAware.getWrappedView(), this.durationMillis);
    }
}
项目:boohee_v5.6    文件:CircleBitmapDisplayer.java   
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (imageAware instanceof ImageViewAware) {
        imageAware.setImageDrawable(new CircleDrawable(bitmap, this.strokeColor, this
                .strokeWidth));
        return;
    }
    throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
}
项目:boohee_v5.6    文件:ProcessAndDisplayImageTask.java   
public void run() {
    L.d(LOG_POSTPROCESS_IMAGE, this.imageLoadingInfo.memoryCacheKey);
    LoadAndDisplayImageTask.runTask(new DisplayBitmapTask(this.imageLoadingInfo.options
            .getPostProcessor().process(this.bitmap), this.imageLoadingInfo, this.engine,
            LoadedFrom.MEMORY_CACHE), this.imageLoadingInfo.options.isSyncLoading(), this
            .handler, this.engine);
}
项目:boohee_v5.6    文件:DisplayBitmapTask.java   
public DisplayBitmapTask(Bitmap bitmap, ImageLoadingInfo imageLoadingInfo, ImageLoaderEngine
        engine, LoadedFrom loadedFrom) {
    this.bitmap = bitmap;
    this.imageUri = imageLoadingInfo.uri;
    this.imageAware = imageLoadingInfo.imageAware;
    this.memoryCacheKey = imageLoadingInfo.memoryCacheKey;
    this.displayer = imageLoadingInfo.options.getDisplayer();
    this.listener = imageLoadingInfo.listener;
    this.engine = engine;
    this.loadedFrom = loadedFrom;
}
项目:sctalk    文件:CircleBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    Bitmap output = Bitmap.createBitmap(bitmap.getWidth(), bitmap.getHeight(), Bitmap.Config.ARGB_4444);

    Canvas canvas = new Canvas(output);

    final int color = 0xff424242;
    final Paint paint = new Paint();
    final Rect rect = new Rect(0, 0, bitmap.getWidth(), bitmap.getHeight());

    paint.setAntiAlias(true);
    canvas.drawARGB(0, 0, 0, 0);
    paint.setColor(color);

    //--CROP THE IMAGE
    canvas.drawCircle(bitmap.getWidth() / 2, bitmap.getHeight() / 2, bitmap.getWidth() / 2 - 1, paint);
    paint.setXfermode(new PorterDuffXfermode(PorterDuff.Mode.SRC_IN));
    canvas.drawBitmap(bitmap, rect, rect, paint);

    //--ADD BORDER IF NEEDED
    if(this.borderWidth > 0){
        final Paint paint2 = new Paint();
        paint2.setAntiAlias(true);
        paint2.setColor(this.borderColor);
        paint2.setStrokeWidth(this.borderWidth);
        paint2.setStyle(Paint.Style.STROKE);
        canvas.drawCircle(bitmap.getWidth() / 2, bitmap.getHeight() / 2, (float) (bitmap.getWidth() / 2 - Math.ceil(this.borderWidth / 2)), paint2);
    }
    imageAware.setImageBitmap(output);
}
项目:ImageLoaderSupportGif    文件:OldRoundedBitmapDisplayer.java   
@Override
   public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom, int fileTypeStatus, String filepath) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }
    Bitmap roundedBitmap = roundCorners(bitmap, (ImageViewAware) imageAware, roundPixels);
    imageAware.setImageBitmap(roundedBitmap);
}
项目:ImageLoaderSupportGif    文件:SimpleBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom, int fileTypeStatus, String filepath) {
    if (fileTypeStatus == BitmapDisplayer.FILE_TYPE_GIF_IMAGE && !TextUtils.isEmpty(filepath)) {
        try {
            imageAware.setImageDrawable(new GifDrawable(filepath));
        } catch (IOException e) {
            imageAware.setImageBitmap(bitmap);
        }
    } else {
        imageAware.setImageBitmap(bitmap);
    }
}
项目:ImageLoaderSupportGif    文件:ProcessAndDisplayImageTask.java   
@Override
public void run() {
    L.d(LOG_POSTPROCESS_IMAGE, imageLoadingInfo.memoryCacheKey);

    BitmapProcessor processor = imageLoadingInfo.options.getPostProcessor();
    Bitmap processedBitmap = processor.process(bitmap);
    DisplayBitmapTask displayBitmapTask = new DisplayBitmapTask(processedBitmap, imageLoadingInfo, engine,
            LoadedFrom.MEMORY_CACHE);
    LoadAndDisplayImageTask.runTask(displayBitmapTask, imageLoadingInfo.options.isSyncLoading(), handler, engine);
}
项目:ImageLoaderSupportGif    文件:DisplayBitmapTask.java   
public DisplayBitmapTask(Bitmap bitmap, ImageLoadingInfo imageLoadingInfo, ImageLoaderEngine engine,
        LoadedFrom loadedFrom) {
    this.bitmap = bitmap;
    imageUri = imageLoadingInfo.uri;
    imageAware = imageLoadingInfo.imageAware;
    memoryCacheKey = imageLoadingInfo.memoryCacheKey;
    displayer = imageLoadingInfo.options.getDisplayer();
    listener = imageLoadingInfo.listener;
    this.engine = engine;
    this.loadedFrom = loadedFrom;

       mFileStatusType = imageLoadingInfo.mFileTypeStatus;
       mFilePath = imageLoadingInfo.mFilePath;
}
项目:yun2win-sdk-android    文件:RoundedBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }

    imageAware.setImageDrawable(new RoundedDrawable(bitmap, cornerRadius, margin));
}
项目:yun2win-sdk-android    文件:RoundedVignetteBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    if (!(imageAware instanceof ImageViewAware)) {
        throw new IllegalArgumentException("ImageAware should wrap ImageView. ImageViewAware is expected.");
    }

    imageAware.setImageDrawable(new RoundedVignetteDrawable(bitmap, cornerRadius, margin));
}
项目:yun2win-sdk-android    文件:FadeInBitmapDisplayer.java   
@Override
public void display(Bitmap bitmap, ImageAware imageAware, LoadedFrom loadedFrom) {
    imageAware.setImageBitmap(bitmap);

    if ((animateFromNetwork && loadedFrom == LoadedFrom.NETWORK) ||
            (animateFromDisk && loadedFrom == LoadedFrom.DISC_CACHE) ||
            (animateFromMemory && loadedFrom == LoadedFrom.MEMORY_CACHE)) {
        animate(imageAware.getWrappedView(), durationMillis);
    }
}
项目:yun2win-sdk-android    文件:ProcessAndDisplayImageTask.java   
@Override
public void run() {
    L.d(LOG_POSTPROCESS_IMAGE, imageLoadingInfo.memoryCacheKey);

    BitmapProcessor processor = imageLoadingInfo.options.getPostProcessor();
    Bitmap processedBitmap = processor.process(bitmap);
    DisplayBitmapTask displayBitmapTask = new DisplayBitmapTask(processedBitmap, imageLoadingInfo, engine,
            LoadedFrom.MEMORY_CACHE);
    LoadAndDisplayImageTask.runTask(displayBitmapTask, imageLoadingInfo.options.isSyncLoading(), handler, engine);
}
项目:yun2win-sdk-android    文件:DisplayBitmapTask.java   
public DisplayBitmapTask(Bitmap bitmap, ImageLoadingInfo imageLoadingInfo, ImageLoaderEngine engine,
        LoadedFrom loadedFrom) {
    this.bitmap = bitmap;
    imageUri = imageLoadingInfo.uri;
    imageAware = imageLoadingInfo.imageAware;
    memoryCacheKey = imageLoadingInfo.memoryCacheKey;
    displayer = imageLoadingInfo.options.getDisplayer();
    listener = imageLoadingInfo.listener;
    this.engine = engine;
    this.loadedFrom = loadedFrom;
}