Re: [android-developers] basic question: SharedPreferences and PreferenceActivity

2011-10-31 Thread TreKing
On Fri, Oct 28, 2011 at 4:44 PM, John Goche johngoch...@googlemail.comwrote: Furthermore, what's the point of having more than one preference file per application? What's a practical example of this? To add to Kostya, not all settings are application-wide - some are component scoped. Like if

Re: [android-developers] basic question: SharedPreferences and PreferenceActivity

2011-10-31 Thread John Goche
Thanks TreKing for your reply, To add to Kostya, not all settings are application-wide - some are component scoped. Like if you have an email app with multiple accounts, you want to be able to configure each account individually. They have the same settings, but different instances, so each

Re: [android-developers] basic question: SharedPreferences and PreferenceActivity

2011-10-31 Thread Kostya Vasilyev
Sure, that's a good case: Especially if you use a subclass of PreferenceActivity to let the user modify those options, and use prefManager.setSharedPreferencesName so that it automagically works with the correct (account specific) preference file. -- Kostya 31.10.2011 23:20, John Goche

[android-developers] basic question: SharedPreferences and PreferenceActivity

2011-10-28 Thread John Goche
Hello, I know this is really basic but I am trying to get to grips with preferences. I have defined an xml file and started a PreferenceActivity to read that XML file so as to create and store some preference key-value pairs. However this is in activity B. In activity A which launched B I also

Re: [android-developers] basic question: SharedPreferences and PreferenceActivity

2011-10-28 Thread Kostya Vasilyev
PreferenceActivity by default uses this preference storage: PreferenceManager.getDefaultSharedPreferences(Context) Comes in handy if you want to read those preference values outside your pref activity. Or you can tell PreferenceActivity to use a pref file with a specific name, in your

Re: [android-developers] basic question: SharedPreferences and PreferenceActivity

2011-10-28 Thread John Goche
Thanks Kostya, I also found the following stackoverflow page helpful: http://stackoverflow.com/questions/2614719/how-do-i-get-the-sharedpreferences-from-a-preferenceactivity-in-android On Fri, Oct 28, 2011 at 11:50 PM, Kostya Vasilyev kmans...@gmail.comwrote: PreferenceActivity by default uses

[android-developers] basic question: inserting horizontal rule in user interface

2011-09-14 Thread John Goche
Hello, I was wondering whether there is a way to insert an HTML-like horizontal rule (hr /) in the user interface via an XML file so I can have it show up in my user interface. Do I have to create a custom image/widget or something? Thank you for your help, John Goche -- You received this

Re: [android-developers] basic question: inserting horizontal rule in user interface

2011-09-14 Thread Mark Murphy
Use something like: View android:background=# android:layout_width=match_parent android:layout_height=2dip / On Wed, Sep 14, 2011 at 11:45 AM, John Goche johngoch...@googlemail.com wrote: Hello, I was wondering whether there is a way to insert an HTML-like horizontal rule (hr /) in

[android-developers] Basic Question: Android Intents and WebViews

2011-05-05 Thread oddvark
Can a webpage html contain link that is the URI of an intent and have that intent launch the application when the link is clicked? Lets say I have an app that says Hello World. I want to create an intent that allows anyone to launch my app and it will say Hello World. Let suppose I correctly

Re: [android-developers] Basic Question: Android Intents and WebViews

2011-05-05 Thread TreKing
On Wed, May 4, 2011 at 7:17 PM, oddvark oddvar...@gmail.com wrote: Can a webpage html contain link that is the URI of an intent and have that intent launch the application when the link is clicked? http://groups.google.com/group/android-developers/browse_thread/thread/fa192af3e4b9f86b

[android-developers] Basic Question

2011-04-28 Thread Prayag
Hi guys, I am a Newbie and I have a basic question for which I couldnt get any answer yet. What is the need to use two keywords to express that the given activity is the main activity. eg. We write the code action android:name=android.intent.action.MAIN / category

Re: [android-developers] Basic Question

2011-04-28 Thread Marcin Orlowski
On 27 April 2011 17:07, Prayag prayag.d.pat...@gmail.com wrote: I am a Newbie and I have a basic question for which I couldnt get any answer yet. Did try reading docs first? What is the need to use two keywords to express that the given activity is the main activity. No. You need just

[android-developers] basic question about emulator

2009-12-07 Thread Robotuner
Hi: I am playing with Android Development and have used the following commands to obtain the device id: TelephonyManager mTelephonyManager = (TelephonyManager) getSystemService (Context.TELEPHONY_SERVICE); String deviceid= mTelephonyManager.getDeviceId(); What I am getting is a 15 digit

Re: [android-developers] basic question about emulator

2009-12-07 Thread David Turner
I confirm it's all 0 due to the fact that you're in the emulator. As far as I know, the value should be decimal for GSM networks, but I don't know about other ones like CDMA. On Mon, Dec 7, 2009 at 9:24 AM, Robotuner lk...@engenious.com wrote: Hi: I am playing with Android Development and