• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java HoloCircularProgressBar类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: onCreate

import de.passsy.holocircularprogressbar.HoloCircularProgressBar; //导入依赖的package包/类
@Override
protected void onCreate(final Bundle savedInstanceState) {
	super.onCreate(savedInstanceState);
	setContentView(R.layout.activity_alarm_countdown);
	getActionBar().setTitle(getString(R.string.fall_down_alarm)
			+ " (" + getString(R.string.counting_down) + ")");

	mTextView = (TextView) super.findViewById(R.id.holoTimeText);
	//Animation实例化
	progress = (HoloCircularProgressBar) findViewById(R.id.holoCircularProgressBar1);
	animate(progress, null);

	mAudioFocusHelper = new AudioFocusHelper(this) {
		@Override
		public void onAudioFocusChange(int focusChange) {
		}
	};
	mMediaPlayer = MediaPlayer.create(this, R.raw.alarm);
	mMediaPlayer.setLooping(true);
}
 
开发者ID:chenbocong,项目名称:FamilyLink,代码行数:21,代码来源:AlarmCountdownActivity.java


示例2: findViews

import de.passsy.holocircularprogressbar.HoloCircularProgressBar; //导入依赖的package包/类
private void findViews() {
	tvDrumometer = (TextView) findViewById(R.id.tvDrumometer);
	rlProgressBar = (RelativeLayout) findViewById(R.id.rlProgressBar);
	holoCircularProgressBar1 = (HoloCircularProgressBar) findViewById(R.id.holoCircularProgressBar1);
	bSubstract = (Button) findViewById(R.id.bSubstract);
	bAdd = (Button) findViewById(R.id.bAdd);
	etSeconds = (EditText) findViewById(R.id.etSeconds);
	llCountingLayout = (LinearLayout) findViewById(R.id.llCountingLayout);
	tvCount = (TextView) findViewById(R.id.tvCount);
	tvBeatsCounted = (TextView) findViewById(R.id.tvBeatsCounted);
	bStartCounting = (Button) findViewById(R.id.bStartCounting);
	tvKeepGoing = (TextView) findViewById(R.id.tvKeepGoing);

	bSubstract.setOnClickListener(this);
	bAdd.setOnClickListener(this);
	bStartCounting.setOnClickListener(this);
}
 
开发者ID:xklakoux,项目名称:drumometer,代码行数:18,代码来源:MainActivity.java


示例3: initView

import de.passsy.holocircularprogressbar.HoloCircularProgressBar; //导入依赖的package包/类
private void initView(String msg){
	setContentView(R.layout.dialog_progress_loading);
	
	progressBar = (HoloCircularProgressBar) findViewById(R.id.holoCircularProgressBar);
	tvProgress = (TextView) findViewById(R.id.tvProgress);
	tvMsg = (TextView) findViewById(R.id.tvMsg);
	
	tvProgress.setText("");
	tvMsg.setText(msg);
}
 
开发者ID:jp1017,项目名称:TheSceneryAlong,代码行数:11,代码来源:ProgressLoadingDialog.java


示例4: animate

import de.passsy.holocircularprogressbar.HoloCircularProgressBar; //导入依赖的package包/类
/**
 * Animate.
 * @param progressBar the progress bar
 * @param listener the listener
 */
private void animate(final HoloCircularProgressBar progressBar, final AnimatorListener listener) {
	//设置animation的起,止点位置
	final float[] progresses = POSTION_TIME ;
	final float markerProgress = 1f;
	final ObjectAnimator progressBarAnimator = ObjectAnimator.ofFloat(progressBar, "progress", progresses);

	setObjectAnimation(progressBarAnimator);		  //set ObjectAnimation对象
	progressBarAnimator.setDuration(NUM_SHOW_TIME);   //设置Animation的时间
	if(listener != null)
		progressBarAnimator.addListener(listener);

	//当animation更新时回调
	progressBarAnimator.addUpdateListener(new AnimatorUpdateListener() {
		/**
		 * 上次更新倒计时器的时间。单位:秒
		 */
		private int mLastPlayTimeSecond = -1;
		@Override
		public void onAnimationUpdate(final ValueAnimator animation) {
			progressBar.setProgress((Float) animation.getAnimatedValue());
			// 每过一秒,更新一次倒计时器
			int currentPlayTimeSecond = (int) (animation.getCurrentPlayTime() / 1000);
			if(currentPlayTimeSecond != mLastPlayTimeSecond) {
				mLastPlayTimeSecond = currentPlayTimeSecond;
				int countDownTime = NUM_SHOW_TIME / 1000 - currentPlayTimeSecond;
				mTextView.setText(String.valueOf(countDownTime));
				if(countDownTime == NUM_SHOW_TIME / 2000) {
					startAlarm();
				} else if(countDownTime == 0) {
					getActionBar().setTitle(R.string.fall_down_alarm);
					sendAlarmMessage();
				}
			}
		}
	});
	progressBar.setMarkerProgress(markerProgress);
	progressBarAnimator.start();
}
 
开发者ID:chenbocong,项目名称:FamilyLink,代码行数:44,代码来源:AlarmCountdownActivity.java


示例5: initViews

import de.passsy.holocircularprogressbar.HoloCircularProgressBar; //导入依赖的package包/类
/**
 * Instantiate all views
 */
private void initViews() {
	progress = (HoloCircularProgressBar) findViewById(R.id.progress);
	progress.setMarkerEnabled(false);
	progress.setProgress(0f);
	progress_loading = (ProgressBar) findViewById(R.id.progress_loading);
	imgbtn_pick_file = (ImageButton) findViewById(R.id.imgbtn_pick_file);
	imgbtn_record = (ImageButton) findViewById(R.id.imgbtn_record);
}
 
开发者ID:SH4DY,项目名称:swazam,代码行数:12,代码来源:RecognitionActivity.java


示例6: onCreateView

import de.passsy.holocircularprogressbar.HoloCircularProgressBar; //导入依赖的package包/类
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
    Log.w(TAG, "onCreateView()");
    rootView = inflater.inflate(layout, container, false);

    pBar = (HoloCircularProgressBar) rootView.findViewById(R.id.progressBar);

    sBar = (SeekBar) rootView.findViewById(R.id.seekBar);

    tBut = (ToggleButton) rootView.findViewById(R.id.toggleButton);

    sBarText = (TextView) rootView.findViewById(R.id.textView2);

    return rootView;
}
 
开发者ID:wuyingren,项目名称:WhatsAnnoyProject,代码行数:16,代码来源:RandomFragment.java


示例7: animate

import de.passsy.holocircularprogressbar.HoloCircularProgressBar; //导入依赖的package包/类
/**
 * Animate.
 * 
 * @param progressBar
 *            the progress bar
 * @param listener
 *            the listener
 */
private void animate(final HoloCircularProgressBar progressBar, final AnimatorListener listener) {
	final float progress = (float) (Math.random() * 2);
	int duration = 3000;
	animate(progressBar, listener, progress, duration);
}
 
开发者ID:jp1017,项目名称:TheSceneryAlong,代码行数:14,代码来源:ProgressLoadingDialog.java



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java StatusResource类代码示例发布时间:2022-05-22
下一篇:
Java Plugin类代码示例发布时间:2022-05-22
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap