将progressDialog设置的所有属性显示出来,
progressDialog.show(); 类似JFrame中的setVisible(true);
progressDialog.show(); 类似JFrame中的setVisible(true);
2016-11-28
case R.id.reduce:
if (progressBar.getProgress()> 0) {
progressBar.incrementProgressBy(-10);
}
if (progressBar.getSecondaryProgress()>0) {
progressBar.incrementSecondaryProgressBy(-10);
}
break;
if (progressBar.getProgress()> 0) {
progressBar.incrementProgressBy(-10);
}
if (progressBar.getSecondaryProgress()>0) {
progressBar.incrementSecondaryProgressBy(-10);
}
break;
2016-11-28
加了一点逻辑判断,欢迎指正
case R.id.add:
if (progressBar.getSecondaryProgress()< 100) {
progressBar.incrementSecondaryProgressBy(10);
}
if (progressBar.getProgress()< 100) {
progressBar.incrementProgressBy(10);
}
break;
case R.id.add:
if (progressBar.getSecondaryProgress()< 100) {
progressBar.incrementSecondaryProgressBy(10);
}
if (progressBar.getProgress()< 100) {
progressBar.incrementProgressBy(10);
}
break;
2016-11-28
AS 2.2.2: 下面方法全部中间有线,提示deprecated(虽然可以运行并且效果和老师一样),并且感谢@"丶眼已望穿"
requestWindowFeature(Window.FEATURE_PROGRESS);
requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
setProgressBarVisibility(true);
setProgressBarIndeterminateVisibility(true);
setProgress(600);
requestWindowFeature(Window.FEATURE_PROGRESS);
requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
setProgressBarVisibility(true);
setProgressBarIndeterminateVisibility(true);
setProgress(600);
2016-11-28
看到评论就受不了这些吐槽的,你想学知识还免费教你屁话那么多。自学是一种很重要的能力,有人带你就应该很感激了,别自己学不下来怪老师教的不好。如果看不懂,自己去看document的去研究!做软件的静不下心 你还能干啥?恩?
2016-11-28
private String[] iconName = {
"通讯录",
"日历",
"照相机",
"时钟",
"游戏",
"启动",
"短信",
"铃声",
"设置",
"语音",
"天气",
"浏览器",
"视频",
};
"通讯录",
"日历",
"照相机",
"时钟",
"游戏",
"启动",
"短信",
"铃声",
"设置",
"语音",
"天气",
"浏览器",
"视频",
};
2016-11-27
R.drawable.address_book,
R.drawable.calendar,
R.drawable.camera,
R.drawable.clock,
R.drawable.games_control,
R.drawable.ic_launcher,
R.drawable.messenger,
R.drawable.ringtone,
R.drawable.settings,
R.drawable.speech_balloon,
R.drawable.weather,
R.drawable.world,
R.drawable.youtube
R.drawable.calendar,
R.drawable.camera,
R.drawable.clock,
R.drawable.games_control,
R.drawable.ic_launcher,
R.drawable.messenger,
R.drawable.ringtone,
R.drawable.settings,
R.drawable.speech_balloon,
R.drawable.weather,
R.drawable.world,
R.drawable.youtube
2016-11-27
时间日期同步:
public void onTimeChanged(TimePicker timePicker, int newhour, int newminute) {
setTitle(year+"-"+month+"-"+day+" " +newhour+":"+newminute);
hour = newhour;
minute = newminute;
}
public void onTimeChanged(TimePicker timePicker, int newhour, int newminute) {
setTitle(year+"-"+month+"-"+day+" " +newhour+":"+newminute);
hour = newhour;
minute = newminute;
}
2016-11-27