Android Programming Tutorials
...
TUTORIAL 37 Photographic Memory One logical thing to add to the restaurant information in LunchList would be photos: the exterio ...
Photographic Memory android:targetSdkVersion="7" /> <supports-screens android:largeScreens="true" android:normalScreens="t ...
Photographic Memory The element, indicating that while the code should run on Android 1.5 and newer (android:minSdkVersion="3" ...
Photographic Memory Step #3: Create the Photographer Class Next, we need a class that will both connect the live preview to the ...
Photographic Memory private void takePicture() { camera.takePicture(null, null, photoCallback); } SurfaceHolder.Callback surface ...
Photographic Memory size of the SurfaceView. When the camera button is clicked, we take a picture, re-enabling the preview in th ...
Photographic Memory Extra Credit............................................................................................... ...
...
TUTORIAL 38 Sensing a Disturbance Continuing our additions to LunchList, we really need a solution to the age- old problem of de ...
Sensing a Disturbance Create LunchList/src/apt/tutorial/Shaker.java with the following source: package apt.tutorial; import andr ...
Sensing a Disturbance private void isNotShaking() { long now=SystemClock.uptimeMillis(); if (lastShakeTimestamp> 0 ) { if (no ...
Sensing a Disturbance As The Busy Coder's Guide to Advanced Android Development explains: The Shaker simply converts the three i ...
Sensing a Disturbance We do not want to be tying up the accelerometer when LunchList does not have the foreground. One way to do ...
Sensing a Disturbance i.putExtra(ID_EXTRA, String.valueOf(adapter.getItemId(selection))); startActivity(i); } }; If you rebuild ...
TUTORIAL 39 Getting the Word Out If we are getting together with others for lunch, they may not be familiar with every one of th ...
Getting the Word Out Step #1: Add a "Send SMS" Option Menu........................................ The most likely place to add ...
Getting the Word Out else if (item.getItemId()==R.id.sms) { sendSMS(); return(true); } return(super.onOptionsItemSelected(item)) ...
Getting the Word Out Note that you will need to add the READ_CONTACTS permission to get this to work, since we are directly acce ...
Getting the Word Out Contacts.DISPLAY_NAME, Phone.NUMBER }; String[] ARGS={String.valueOf(Phone.TYPE_MOBILE)}; final Cursor c=ma ...
«
14
15
16
17
18
19
20
21
22
23
»
Free download pdf