com.squareup.picasso.Picasso.invalidate()方法的使用及代码示例

x33g5p2x  于2022-01-25 转载在 其他  
字(4.3k)|赞(0)|评价(0)|浏览(87)

本文整理了Java中com.squareup.picasso.Picasso.invalidate()方法的一些代码示例,展示了Picasso.invalidate()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Picasso.invalidate()方法的具体详情如下:
包路径:com.squareup.picasso.Picasso
类名称:Picasso
方法名:invalidate

Picasso.invalidate介绍

暂无

代码示例

代码示例来源:origin: stackoverflow.com

View v = inflater.inflate(R.layout.places_layout, null);
placeImage = (ImageView) v.findViewById(R.id.place_badge);
...
Picasso picasso = Picasso.with(getApplicationContext());
picasso.invalidate(market.getId());
picasso.load(markerPlaces.get(marker.getId()))
  .placeholder(R.drawable.bus)
  .into(placeImage);

代码示例来源:origin: stackoverflow.com

File file = new File(fileName);
Picasso picasso = Picasso.with(context);
picasso.invalidate(file);
picasso.load(file).into(imageView);

代码示例来源:origin: zhouruikevin/ImageLoadPK

@Override
  public void clear() {
    for (int i = 0; i < getItemCount(); i++) {
      mPicasso.invalidate(getItem(i));
    }
  }
}

代码示例来源:origin: SachinVin/citra_android

public void exitWithAnimation()
{
 runOnUiThread(() ->
 {
  Picasso.with(EmulationActivity.this)
      .invalidate(mScreenPath);
  Picasso.with(EmulationActivity.this)
      .load(mScreenPath)
      .noFade()
      .noPlaceholder()
      .into(mImageView, new Callback()
      {
       @Override
       public void onSuccess()
       {
        showScreenshot();
       }
       @Override
       public void onError()
       {
        finish();
       }
      });
 });
}

代码示例来源:origin: safetysystemtechnology/progress-image-view-android

private void progressImageViewAutoHide() {
  progressImageViewAutoHide = (ProgressImageView) findViewById(R.id.progress_image_view);
  progressImageViewAutoHide.showLoading();
  Picasso picasso = Picasso.with(MainActivity.this);
  picasso.invalidate("http://blog.alura.com.br/wp-content/uploads/2016/06/java_capa.jpg");
  picasso.load("http://blog.alura.com.br/wp-content/uploads/2016/06/java_capa.jpg")
      .transform(new CircleTransform())
      .memoryPolicy(MemoryPolicy.NO_CACHE)
      .networkPolicy(NetworkPolicy.NO_CACHE)
      .into(progressImageViewAutoHide);
}

代码示例来源:origin: safetysystemtechnology/progress-image-view-android

private void progressImageViewFromAEvent() {
  hideFromAEvent = (ProgressImageView) findViewById(R.id.progress_image_view_hide);
  hideFromAEvent.showLoading().withAutoHide(false).withBorderColor(Color.BLUE);
  Picasso picasso = Picasso.with(MainActivity.this);
  picasso.invalidate("https://randomuser.me/api/portraits/men/83.jpg");
  picasso.load("https://randomuser.me/api/portraits/men/83.jpg")
      .transform(new CircleTransform())
      .memoryPolicy(MemoryPolicy.NO_CACHE)
      .networkPolicy(NetworkPolicy.NO_CACHE)
      .into(hideFromAEvent);
  new Timer().schedule(new TimerTask() {
    @Override
    public void run() {
      hideFromAEvent.hideLoading();
    }
  }, 5000);
}

代码示例来源:origin: safetysystemtechnology/progress-image-view-android

private void progressImageColorAndSize() {
  progressImageColorAndSize = (ProgressImageView) findViewById(R.id.progress_image_view_color_and_size);
  progressImageColorAndSize.showLoading().withAutoHide(false).withBorderColor(Color.RED).withBorderSize(10);
  Picasso picasso = Picasso.with(MainActivity.this);
  picasso.invalidate("https://randomuser.me/api/portraits/men/83.jpg");
  picasso.load("https://randomuser.me/api/portraits/men/83.jpg")
      .transform(new CircleTransform())
      .memoryPolicy(MemoryPolicy.NO_CACHE)
      .networkPolicy(NetworkPolicy.NO_CACHE)
      .into(progressImageColorAndSize);
  new Timer().schedule(new TimerTask() {
    @Override
    public void run() {
      progressImageColorAndSize.hideLoading();
    }
  }, 5000);
}

代码示例来源:origin: safetysystemtechnology/progress-image-view-android

private void progressImageViewOffSet() {
  progressImageOffSet = (ProgressImageView) findViewById(R.id.progress_image_view_offset);
  progressImageOffSet.showLoading().withAutoHide(false).withBorderColor(Color.BLUE).withOffset(10);
  Picasso picasso = Picasso.with(MainActivity.this);
  picasso.invalidate("https://randomuser.me/api/portraits/men/83.jpg");
  picasso.load("https://randomuser.me/api/portraits/men/83.jpg")
      .transform(new CircleTransform())
      .memoryPolicy(MemoryPolicy.NO_CACHE)
      .networkPolicy(NetworkPolicy.NO_CACHE)
      .into(progressImageOffSet);
  new Timer().schedule(new TimerTask() {
    @Override
    public void run() {
      progressImageOffSet.hideLoading();
    }
  }, 5000);
}

代码示例来源:origin: leelit/STUer-client

Picasso.with(this).invalidate(mUploadImageUri);
Picasso.with(this).load(mUploadImageUri).resize(ScreenUtils.dp2px(200f), ScreenUtils.dp2px(200f)).centerCrop().into(mImageView);
hasImage = true;

代码示例来源:origin: rsiebert/TVHClient

Picasso.get().invalidate(UIUtils.getIconUrl(getActivity(), channel.getIcon()));

相关文章