本文整理汇总了Java中in.srain.cube.image.ImageLoaderFactory类的典型用法代码示例。如果您正苦于以下问题:Java ImageLoaderFactory类的具体用法?Java ImageLoaderFactory怎么用?Java ImageLoaderFactory使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ImageLoaderFactory类属于in.srain.cube.image包,在下文中一共展示了ImageLoaderFactory类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: initImage
import in.srain.cube.image.ImageLoaderFactory; //导入依赖的package包/类
private void initImage() {
Cube.onCreate(instance);
initImageLoader();
//普通图片加载
imageLoadHandler = new DefaultImageLoadHandler(getApplicationContext());
//加载中图片显示替换
// imageLoadHandler.setLoadingResources(R.drawable.none_gonggao);
//加载失败图片显示替换
imageLoadHandler.setErrorResources(R.color.transparent);
imageLoader = ImageLoaderFactory.create(getApplicationContext(), imageLoadHandler);
//圆形图片加载
imageLoadHandler_round = new DefaultImageLoadHandler(getApplicationContext());
imageLoadHandler_round.setImageRounded(true, 180);
// imageLoadHandler_round.setLoadingResources(R.drawable.user_head);
// imageLoadHandler_round.setErrorResources(R.drawable.user_head);
imageLoader_round = ImageLoaderFactory.create(getApplicationContext(), imageLoadHandler_round);
}
开发者ID:fengdongfei,项目名称:CXJPadProject,代码行数:18,代码来源:BApplication.java
示例2: onCreate
import in.srain.cube.image.ImageLoaderFactory; //导入依赖的package包/类
@Override
public void onCreate() {
super.onCreate();
instance = this;
String environment = "";
if (environment.equals("production")) {
CLog.setLogLevel(CLog.LEVEL_ERROR);
} else if (environment.equals("beta")) {
CLog.setLogLevel(CLog.LEVEL_WARNING);
} else {
// development
CLog.setLogLevel(CLog.LEVEL_VERBOSE);
}
CubeDebug.DEBUG_IMAGE = true;
PtrFrameLayout.DEBUG = true;
PtrFrameLayout.DEBUG = false;
ImageLoaderFactory.setDefaultImageReSizer(DemoDuiTangImageReSizer.getInstance());
ImageLoaderFactory.setDefaultImageLoadHandler(new PtrImageLoadHandler());
String dir = "request-cache";
// ImageLoaderFactory.init(this);
RequestCacheManager.init(this, dir, 1024 * 10, 1024 * 10);
Cube.onCreate(this);
}
开发者ID:weiwenqiang,项目名称:GitHub,代码行数:28,代码来源:PtrDemoApplication.java
示例3: initImageLoader
import in.srain.cube.image.ImageLoaderFactory; //导入依赖的package包/类
private void initImageLoader() {
ImageLoaderFactory.customizeCache(
this,
1024 * 10,
null,
ImageLoaderFactory.DEFAULT_FILE_CACHE_SIZE_IN_KB
);
DefaultImageLoadHandler handler = new DefaultImageLoadHandler(this);
ImageLoaderFactory.setDefaultImageLoadHandler(handler);
ImageLoaderFactory.setDefaultImageReSizer(DemoDuiTangImageReSizer.getInstance());
}
开发者ID:fengdongfei,项目名称:CXJPadProject,代码行数:13,代码来源:BApplication.java
示例4: onCreate
import in.srain.cube.image.ImageLoaderFactory; //导入依赖的package包/类
@Override
public void onCreate() {
super.onCreate();
instance = this;
String environment = "";
if (environment.equals("production")) {
CLog.setLogLevel(CLog.LEVEL_ERROR);
} else if (environment.equals("beta")) {
CLog.setLogLevel(CLog.LEVEL_WARNING);
} else {
// development
CLog.setLogLevel(CLog.LEVEL_VERBOSE);
}
CubeDebug.DEBUG_IMAGE = true;
PtrFrameLayout.DEBUG = true;
//PtrFrameLayout.DEBUG = false;
ImageLoaderFactory.setDefaultImageReSizer(DemoDuiTangImageReSizer.getInstance());
ImageLoaderFactory.setDefaultImageLoadHandler(new PtrImageLoadHandler());
String dir = "request-cache";
// ImageLoaderFactory.init(this);
RequestCacheManager.init(this, dir, 1024 * 10, 1024 * 10);
Cube.onCreate(this);
}
开发者ID:tangnuo,项目名称:android-Ultra-Pull-To-Refresh-With-Load-More-master,代码行数:28,代码来源:PtrDemoApplication.java
示例5: onCreate
import in.srain.cube.image.ImageLoaderFactory; //导入依赖的package包/类
@Override
public void onCreate() {
super.onCreate();
instance = this;
String environment = "";
if (environment.equals("production")) {
CLog.setLogLevel(CLog.LEVEL_ERROR);
} else if (environment.equals("beta")) {
CLog.setLogLevel(CLog.LEVEL_WARNING);
} else {
// development
CLog.setLogLevel(CLog.LEVEL_VERBOSE);
}
CubeDebug.DEBUG_IMAGE = true;
PtrFrameLayout.DEBUG = true;
PtrFrameLayout.DEBUG = false;
ImageLoaderFactory.setDefaultImageReSizer(ImageReSizer.getInstance());
ImageLoaderFactory.setDefaultImageLoadHandler(new PtrImageLoadHandler());
String dir = "request-cache";
RequestCacheManager.init(this, dir, 1024 * 10, 1024 * 10);
Cube.onCreate(this);
}
开发者ID:cnlinrong,项目名称:MyAndroidFramework,代码行数:28,代码来源:App.java
注:本文中的in.srain.cube.image.ImageLoaderFactory类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论