/**************************************************************************************
* [Project]
* MyProgressDialog
* [Package]
* com.lxd.widgets
* [FileName]
* CustomProgressDialog.java
* [Copyright]
* Copyright 2012 LXD All Rights Reserved.
* [History]
* Version Date Author Record
*--------------------------------------------------------------------------------------
* 1.0.0 2012-4-27 lxd (rohsuton@gmail.com) Create
**************************************************************************************/
package com.lxd.widgets;
import com.lxd.activity.R;
import android.app.Dialog;
import android.content.Context;
import android.graphics.drawable.AnimationDrawable;
import android.view.Gravity;
import android.widget.ImageView;
import android.widget.TextView;
/********************************************************************
* [Summary]
* TODO 请在此处简要描述此类所实现的功能。因为这项注释主要是为了在IDE环境中生成tip帮助,务必简明扼要
* [Remarks]
* TODO 请在此处详细描述类的功能、调用方法、注意事项、以及与其它类的关系.
*******************************************************************/
public class CustomProgressDialog extends Dialog {
private Context context = null;
private static CustomProgressDialog customProgressDialog = null;
public CustomProgressDialog(Context context){
super(context);
this.context = context;
}
public CustomProgressDialog(Context context, int theme) {
super(context, theme);
}
public static CustomProgressDialog createDialog(Context context){
customProgressDialog = new CustomProgressDialog(context,R.style.CustomProgressDialog);
customProgressDialog.setContentView(R.layout.customprogressdialog);
customProgressDialog.getWindow().getAttributes().gravity = Gravity.CENTER;
return customProgressDialog;
}
public void onWindowFocusChanged(boolean hasFocus){
if (customProgressDialog == null){
return;
}
ImageView imageView = (ImageView) customProgressDialog.findViewById(R.id.loadingImageView);
AnimationDrawable animationDrawable = (AnimationDrawable) imageView.getBackground();
animationDrawable.start();
}
/**
*
* [Summary]
* setTitile 标题
* @param strTitle
* @return
*
*/
public CustomProgressDialog setTitile(String strTitle){
return customProgressDialog;
}
/**
*
* [Summary]
* setMessage 提示内容
* @param strMessage
* @return
*
*/
public CustomProgressDialog setMessage(String strMessage){
TextView tvMsg = (TextView)customProgressDialog.findViewById(R.id.id_tv_loadingmsg);
if (tvMsg != null){
tvMsg.setText(strMessage);
}
return customProgressDialog;
}
}
没有合适的资源?快使用搜索试试~ 我知道了~
android ProgressDialog加载中动画提示
共50个文件
png:24个
class:11个
xml:5个
4星 · 超过85%的资源 需积分: 1 36 下载量 172 浏览量
2015-07-14
13:14:23
上传
评论
收藏 3.65MB ZIP 举报
温馨提示
ProgressDialog访问网络Activity加载中动画提示的Dialog。
资源推荐
资源详情
资源评论
收起资源包目录
MyProgressDialog加载中动画提示.zip (50个子文件)
MyProgressDialog
bin
classes.dex 7KB
res
drawable-ldpi
ic_launcher.png 2KB
drawable-hdpi
ic_launcher.png 4KB
drawable-mdpi
progress_4.png 1KB
progress_5.png 1KB
background.png 889KB
progress_1.png 1KB
ic_launcher.png 2KB
progress_7.png 1KB
progress_8.png 1KB
progress_2.png 1KB
progress_6.png 1KB
progress_3.png 1KB
MyProgressDialog.apk 919KB
classes
com
lxd
activity
MainFrame.class 2KB
R$layout.class 432B
MainFrame$MainFrameTask.class 2KB
R$id.class 428B
R$drawable.class 707B
R$attr.class 334B
R.class 607B
R$string.class 421B
R$anim.class 392B
R$style.class 437B
widgets
CustomProgressDialog.class 2KB
resources.ap_ 913KB
res
drawable-ldpi
ic_launcher.png 2KB
drawable-hdpi
ic_launcher.png 4KB
values
strings.xml 799B
drawable-mdpi
progress_4.png 4KB
progress_5.png 4KB
background.png 954KB
progress_1.png 4KB
ic_launcher.png 3KB
progress_7.png 4KB
progress_8.png 4KB
progress_2.png 4KB
progress_6.png 4KB
progress_3.png 4KB
anim
progress_round.xml 773B
layout
customprogressdialog.xml 685B
main.xml 327B
assets
gen
com
lxd
activity
R.java 2KB
proguard.cfg 1KB
src
com
lxd
activity
MainFrame.java 2KB
widgets
CustomProgressDialog.java 3KB
.project 852B
.classpath 364B
project.properties 361B
AndroidManifest.xml 730B
共 50 条
- 1
资源评论
- qq_222038472015-11-16可以看看,但是对我帮助不大
- Evangelion_2015-10-09样式做的有点浮夸,代码可以参考一下
吴(Android、Flutter)
- 粉丝: 2
- 资源: 43
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功