摘要:
1 import android.view.animation.Animation; 2 import android.view.animation.Transformation; 3 4 public class CustomAnim extends Animation { 5 6 ... 阅读全文
posted @ 2014-08-31 21:06
大米稀饭
阅读(477)
评论(0)
推荐(0)
摘要:
1 // sa = new ScaleAnimation(0, 1, 0, 1,100,50); 2 // sa = new ScaleAnimation(0, 1, 0, 1, Animation.RELATIVE_TO_SELF, 0.5f, Animation.R... 阅读全文
posted @ 2014-08-31 21:01
大米稀饭
阅读(267)
评论(0)
推荐(0)
摘要:
1 findViewById(R.id.btnTranslateMe).setOnClickListener(new View.OnClickListener() {2 @Override3 public void onClick(View arg0)... 阅读全文
posted @ 2014-08-31 20:58
大米稀饭
阅读(243)
评论(0)
推荐(0)
摘要:
1 findViewById(R.id.btnRotateMe).setOnClickListener(new View.OnClickListener() {2 @Override3 public void onClick(View arg0) {4 arg0.s... 阅读全文
posted @ 2014-08-31 20:52
大米稀饭
阅读(552)
评论(0)
推荐(0)
摘要:
1 @Override 2 public View onCreateView(LayoutInflater inflater, ViewGroup container, 3 Bundle savedInstanceState) { 4 View rootView = inf... 阅读全文
posted @ 2014-08-31 20:43
大米稀饭
阅读(160)
评论(0)
推荐(0)
摘要:
1 import android.app.ListActivity; 2 import android.os.Bundle; 3 import android.widget.ArrayAdapter; 4 5 public class MainActivity extends ListActiv... 阅读全文
posted @ 2014-08-31 20:20
大米稀饭
阅读(392)
评论(0)
推荐(0)
摘要:
1 import android.app.Activity; 2 import android.os.Bundle; 3 import android.view.Menu; 4 import android.view.MenuItem; 5 import android.view.View; 6 ... 阅读全文
posted @ 2014-08-31 19:56
大米稀饭
阅读(323)
评论(0)
推荐(0)
摘要:
1 import android.app.Activity; 2 import android.app.Fragment; 3 import android.os.Bundle; 4 import android.view.LayoutInflater; 5 import android.view... 阅读全文
posted @ 2014-08-31 19:39
大米稀饭
阅读(517)
评论(0)
推荐(0)
摘要:
Android中音频和视频的播放我们最先想到的就是MediaPlayer类了,该类提供了播放、暂停、停止、和重复播放等方法。该类位于android.media包下,详见API文档。其实除了这个类还有一个音乐播放类那就是SoundPool,这两个类各有不同分析一下便于大家理解MediaPlayer:此... 阅读全文
posted @ 2014-08-31 12:02
大米稀饭
阅读(2808)
评论(0)
推荐(0)
摘要:
private Vibrator vibrator;取得震动服务的句柄vibrator = (Vibrator) getSystemService(VIBRATOR_SERVICE);或者vibrator = (Vibrator)getApplication().getSystemService(S... 阅读全文
posted @ 2014-08-31 12:01
大米稀饭
阅读(248)
评论(0)
推荐(0)
摘要:
IMEI号,IESI号,手机型号:privatevoidgetInfo(){TelephonyManagermTm=(TelephonyManager)getSystemService(TELEPHONY_SERVICE);Stringimei=mTm.getDeviceId();Stringims... 阅读全文
posted @ 2014-08-31 11:58
大米稀饭
阅读(302)
评论(0)
推荐(0)
摘要:
开发Android软件中我们可能经常需播放多媒体声音文件,一般使用MediaPlayer类但该类占用资源较多,对于游戏等应用可能不是很适合,SoundPool类在SDK的android.media.SoundPool,顾名思义是声音池的意思。主要播放一些较短的声音片段,可以从程序的资源或文件系统加载... 阅读全文
posted @ 2014-08-31 11:53
大米稀饭
阅读(345)
评论(0)
推荐(0)
浙公网安备 33010602011771号