RSS구독하기:SUBSCRIBE TO RSS FEED
즐겨찾기추가:ADD FAVORITE
글쓰기:POST
관리자:ADMINISTRATOR
카테고리 없음  2010. 11. 22. 21:39
private final Runnable mCameraButtonAction = new Runnable() {
public void run() {
// Launch the camera intent.
Intent intent;
if( android.os.Build.MODEL.startsWith("HTC") ) {
// TODO: do ALL HTC devices use the same camera classes?
intent = new Intent(Intent.ACTION_MAIN);
intent.setClassName("com.android.camera", "com.android.camera.CameraEntry");
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
} else if( "Nexus One".equals(android.os.Build.MODEL) ) {
intent = new Intent();
intent.setClassName("com.android.camera", "com.android.camera.Camera");
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
} else {
intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);
intent.putExtra(MediaStore.EXTRA_OUTPUT,
MediaStore.Images.Media.EXTERNAL_CONTENT_URI.toStr ing());
}
mContext.startActivity(intent);
}
};

Trackback
Reply
Moss:
Root (119)
Dev (14)
Life (29)
Programming (2)
Music (2)
Android (4)
Tip (2)
Java (11)
Creative (3)
Lyrics (2)
Windows 7 (2)
Etc (7)
C# (8)
Spring (1)
jQuery (2)
Web (4)
Travel (10)
Cook (0)
«   2024/05   »
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31