android开发小技巧


一般来说,APP的启动方式主要分为两种:冷启动和热启动。

冷启动:启动应用时,后台没有该应用的进程,系统会重新创建一个新的进程分配给该应用,即冷启动;
热启动:启动应用时,后台已有该应用的进程(例如:点击Back键或Home键退出,此时应用的进程依然在后台存活),这时会在已有的进程中启动该应用,即热启动;

0. Glide设置圆形图片(两种方法)

implementation 'com.github.bumptech.glide:glide:4.6.1'

Glide.with(context).load(list.get(position).getImgsrc())
                .apply(RequestOptions.bitmapTransform(new CircleCrop()))
                .into(holder.img);

compile 'com.github.bumptech.glide:glide:3.7.0'

 Glide.with(getContext()).load("http://www.qqzhi.com/uploadpic/2014-09-12/094013726.jpg").asBitmap().centerCrop().into(new BitmapImageViewTarget(iv_user_head) {
        @Override
        protected void setReso

猜你喜欢

转载自blog.csdn.net/weixin_37438128/article/details/116605394