当前位置: 首页>>代码示例>>Java>>正文


Java BitmapProcessor类代码示例

本文整理汇总了Java中com.mob.tools.gui.BitmapProcessor的典型用法代码示例。如果您正苦于以下问题:Java BitmapProcessor类的具体用法?Java BitmapProcessor怎么用?Java BitmapProcessor使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


BitmapProcessor类属于com.mob.tools.gui包,在下文中一共展示了BitmapProcessor类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: update

import com.mob.tools.gui.BitmapProcessor; //导入依赖的package包/类
public void update(Following following, boolean fling) {
	tvName.setText(following.screenName);
	ivCheck.setImageBitmap(following.checked ? bmChd : bmUnch);
	if (aivIcon != null) {
		if (fling) {
			Bitmap bm = BitmapProcessor.getBitmapFromCache(following.icon);
			if (bm != null && !bm.isRecycled()) {
				aivIcon.setImageBitmap(bm);
			} else {
				aivIcon.execute(null, 0);
			}
		} else {
			aivIcon.execute(following.icon, 0);
		}
	}
}
 
开发者ID:gaolhjy,项目名称:cniao5,代码行数:17,代码来源:FriendListItem.java

示例2: update

import com.mob.tools.gui.BitmapProcessor; //导入依赖的package包/类
public void update(FriendAdapter.Following following, boolean fling) {
	tvName.setText(following.screenName);
	ivCheck.setImageBitmap(following.checked ? bmChd : bmUnch);
	if (aivIcon != null) {
		if (fling) {
			Bitmap bm = BitmapProcessor.getBitmapFromCache(following.icon);
			if (bm != null && !bm.isRecycled()) {
				aivIcon.setImageBitmap(bm);
			} else {
				aivIcon.execute(null, 0);
			}
		} else {
			aivIcon.execute(following.icon, 0);
		}
	}
}
 
开发者ID:wuyinlei,项目名称:MyHearts,代码行数:17,代码来源:FriendListItem.java

示例3: update

import com.mob.tools.gui.BitmapProcessor; //导入依赖的package包/类
public void update(Following following, boolean fling) {
  tvName.setText(following.screenName);
  ivCheck.setImageBitmap(following.checked ? bmChd : bmUnch);
  if (aivIcon != null) {
    if (fling) {
      Bitmap bm = BitmapProcessor.getBitmapFromCache(following.icon);
      if (bm != null && !bm.isRecycled()) {
        aivIcon.setImageBitmap(bm);
      } else {
        aivIcon.execute(null, 0);
      }
    } else {
      aivIcon.execute(following.icon, 0);
    }
  }
}
 
开发者ID:zfdang,项目名称:zSMTH-Android,代码行数:17,代码来源:FriendListItem.java

示例4: getView

import com.mob.tools.gui.BitmapProcessor; //导入依赖的package包/类
public View getView(int position, View convertView, ViewGroup parent) {
    FollowListItem item;
    boolean simpleMode = "FacebookMessenger".equals(this.platform.getName());
    if (convertView == null) {
        View llItem = new LinearLayout(parent.getContext());
        item = new FollowListItem();
        llItem.setTag(item);
        convertView = llItem;
        int dp_52 = R.dipToPx(getContext(), 52);
        int dp_10 = R.dipToPx(parent.getContext(), 10);
        int dp_5 = R.dipToPx(parent.getContext(), 5);
        if (!simpleMode) {
            item.aivIcon = new AsyncImageView(getContext());
            LayoutParams lpIcon = new LayoutParams(dp_52, dp_52);
            lpIcon.gravity = 16;
            lpIcon.setMargins(dp_10, dp_5, dp_10, dp_5);
            item.aivIcon.setLayoutParams(lpIcon);
            llItem.addView(item.aivIcon);
        }
        LinearLayout llText = new LinearLayout(parent.getContext());
        llText.setPadding(0, dp_10, dp_10, dp_10);
        llText.setOrientation(1);
        LayoutParams lpText = new LayoutParams(-2, -2);
        lpText.gravity = 16;
        lpText.weight = 1.0f;
        llText.setLayoutParams(lpText);
        llItem.addView(llText);
        item.tvName = new TextView(parent.getContext());
        item.tvName.setTextColor(-16777216);
        item.tvName.setTextSize(1, 18.0f);
        item.tvName.setSingleLine();
        if (simpleMode) {
            item.tvName.setPadding(dp_10, 0, 0, 0);
        }
        llText.addView(item.tvName);
        if (!simpleMode) {
            item.tvSign = new TextView(parent.getContext());
            item.tvSign.setTextColor(2130706432);
            item.tvSign.setTextSize(1, 14.0f);
            item.tvSign.setSingleLine();
            llText.addView(item.tvSign);
        }
        item.ivCheck = new ImageView(parent.getContext());
        item.ivCheck.setPadding(0, 0, dp_10, 0);
        LayoutParams lpCheck = new LayoutParams(-2, -2);
        lpCheck.gravity = 16;
        item.ivCheck.setLayoutParams(lpCheck);
        llItem.addView(item.ivCheck);
    } else {
        item = (FollowListItem) convertView.getTag();
    }
    Following following = getItem(position);
    item.tvName.setText(following.screenName);
    if (!simpleMode) {
        item.tvSign.setText(following.description);
    }
    item.ivCheck.setImageBitmap(following.checked ? this.bmChd : this.bmUnch);
    if (!simpleMode) {
        if (isFling()) {
            Bitmap bm = BitmapProcessor.getBitmapFromCache(following.icon);
            if (bm == null || bm.isRecycled()) {
                item.aivIcon.execute(null, 0);
            } else {
                item.aivIcon.setImageBitmap(bm);
            }
        } else {
            item.aivIcon.execute(following.icon, 0);
        }
    }
    if (position == getCount() - 1) {
        next();
    }
    return convertView;
}
 
开发者ID:JackChan1999,项目名称:boohee_v5.6,代码行数:75,代码来源:FollowListPage.java


注:本文中的com.mob.tools.gui.BitmapProcessor类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。