Android: Difference between revisions

From Wildsong
Jump to navigationJump to search
Brian Wilson (talk | contribs)
mNo edit summary
Brian Wilson (talk | contribs)
Line 1: Line 1:
== Settings ==
== Settings ==


The ellipsis thing (three vertical dots) is called "Settings".
That ellipsis thing (three vertical dots) is called "Settings".
To create items in the settings menu, make a folder called xml under res and put a file in it, eg
preferences.xml in it. [[preferences.xml sample]]
 
Add another activity, for example "AppSettings.java".
Do this by adding it to src/ and eclipse will add it to the manifest for you.
 
It's getting stuck at addPreferenceFromResource(R.xml.preferences);


I want my app to show a menu when the user clicks on it, so I have to add a PreferencesActivity.
I also need to associate the resources with it to define what shows up.


== Samples ==
== Samples ==

Revision as of 00:04, 21 September 2012

Settings

That ellipsis thing (three vertical dots) is called "Settings".

I want my app to show a menu when the user clicks on it, so I have to add a PreferencesActivity. I also need to associate the resources with it to define what shows up.

Samples

AccelerometerPlay

ActionBarCompat

AndroidBeamDemo

ApiDemos

AppNavigation

BackupRestore

BasicGLSurfaceView

BluetoothChat

BluetoothHDP

ContactManager

content_hash.properties

CrossCompatibility

CubeLiveWallpaper

GestureBuilder

HelloEffects

Home

HoneycombGallery

JetBoy

KeyChainDemo

LunarLander

MultiResolution

NotePad

RandomMusicPlayer

RenderScript

SampleSyncAdapter

SearchableDictionary

SipDemo - VOIP phone app, almost works with our PBX. Phone apparently registers but I can't get calls to go. Does show how to use the ellipsis thing though (...).

SkeletonApp

Snake

SoftKeyboard

SpellChecker

Spinner

SpinnerTest

TicTacToeLib

TicTacToeMain

ToyVpn

TtsEngine

USB

VoicemailProviderDemo

VoiceRecognitionService

WeatherListWidget

WidgetPreview

WiFiDirectDemo

Wiktionary

WiktionarySimple

XmlAdapters