[android-beginners] Re: what's vanilla andriod?

2010-04-16 Thread MobDev
I guess Vanilla android would be the first commercial version, ie 1.0
Otherwise it's Android with a Vanilla flavor...

On 8 apr, 07:22, Tao  wrote:
> I heart andriod 1.5,1.6,2.0,2.1;but do not hear vanilla andriod, is
> there anybody know that? Thank you.

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


Re: [android-beginners] Re: what's vanilla andriod?

2010-04-16 Thread Rubén González
"Vanilla" Android is the standard android skin: No Sense, no Motoblur, no
Rachael, etc.
Version number doesn't matter.

On Fri, Apr 16, 2010 at 9:46 AM, MobDev  wrote:

> I guess Vanilla android would be the first commercial version, ie 1.0
> Otherwise it's Android with a Vanilla flavor...
>
> On 8 apr, 07:22, Tao  wrote:
> > I heart andriod 1.5,1.6,2.0,2.1;but do not hear vanilla andriod, is
> > there anybody know that? Thank you.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Beginners" group.
>
> NEW! Try asking and tagging your question on Stack Overflow at
> http://stackoverflow.com/questions/tagged/android
>
> To unsubscribe from this group, send email to
> android-beginners+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-beginners?hl=en
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] wrong example in dev guide - audio capture

2010-04-16 Thread hshong
hi.

below link contains a example code of audio capture
http://developer.android.com/guide/topics/media/index.html#capture

my problem is..
"MediaStore.MediaColumns" class don't have TIMESTAMP constant.
see also, 
http://developer.android.com/reference/android/provider/MediaStore.MediaColumns.html

i'd like to audio capture.
any suggestion?

thanks.

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: listen for changes made in ContactMethod table

2010-04-16 Thread jrichards1...@googlemail.com
Any suggestions please?

On Apr 13, 10:50 am, "jrichards1...@googlemail.com"
 wrote:
> Hi. i am trying tolistenout for forchangesmadeinContactMethodtableusing  the 
> code below:
>
> mPeopleObserver = new ContactContentObserver(mHandler);
>
> this.getContentResolver().registerContentObserver(Contacts.ContactMethods.C­ONTENT_URI,
>                                 true, mPeopleObserver);
>
> It doesnt seem to work whenever i change a contacts email address or
> instant messanger details.
>
> i have a conentObserver method below that should catch and notify me
> of anychangesmadeto thetablebut it doesnt.
>
>         /**
>          * ContentObserver to get the call backs forchangesin the onChange
> method
>          */
>         private class ContactContentObserver extends ContentObserver {
>
>                 public ContactContentObserver(Handler handler) {
>                         super(handler);
>                 }
>
>                 public void onChange(boolean selfChange) {
>                         // Excute Aggregation process
>                         try {
>                                 Log.d("AggregationService", "onChange fired 
> by content observer");
>                                 AggregateContacts();
>                         } catch (Exception e) {
>                                 e.printStackTrace();
>                         }
>                 }
>         }
>
> Cheers in advance.

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] widget setting frame

2010-04-16 Thread manigault
Hi all i am trying to make a widget of my application and i used
http://developer.android.com/guide/practices/ui_guidelines/widget_design.html
as start point. How can i set one of the standart widget frames to my
widget. Thanks

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: How to get child Activity?

2010-04-16 Thread Rodrigo Chiossi
Hi Kitzy.
If you just click the button, the second activity should start in a
state A. if you longpress the button, the activity should start in a
state B and go to state A upon releasing the button (In fact, upon
releasing the screen, since the button does not exists in the second
activity), so i can't start it after release. Your second suggestion
is actually what I managed to do as a workaround: I broadcast an
intent whenever the first activity receives an event and the second
activity has already been started (I set a flag after starting). It's
not a beautiful code, but it's the best solution so far...
I know it would be easy just not to use this kind of interaction, but
this is the key feature of the app.

On Apr 16, 1:48 am, Kitzy  wrote:
> What if you start your activity after release?  Or use a broadcast
> receiver?
>
> Why do you need the new activity to know when you release?
>
> -Kitzy
>
> On Apr 15, 10:35 am, Rodrigo Chiossi  wrote:
>
>
>
>
>
> > I have already tried 3 different approaches to the problem:
> > The first was this one i described previously, which would be the
> > ideal for my app.
> > The second one, i created an ActivityGroup which was responsible for
> > starting two activities and on LongClick event I was swaping the
> > DecorViews of the activities. Still, the same problem happened: the
> > ACTION_UP was being delivered to the wrong activity.
> > My last approach was to create a single activity and call
> > setContentView to swap between the two layouts, and still, the event
> > was not delivered to the right view.
> > I'm just wondering if there is a way for an Activity to request Input
> > events...
>
> > @Mark: you are right, i messed those approaches a little. I have the
> > getParent only when I use an ActivityGroup.
>
> > On Apr 15, 12:23 pm, Mark Murphy  wrote:
>
> > > Rodrigo Chiossi wrote:
> > > > First, the user press a button on the main Activity. When the
> > > > LongClick triggers, I start the second Activity wich also has a button
> > > > which should be pressed when the activity starts and should only be
> > > > released when the user takes his finger off the screen.
>
> > > Why are you using multiple activities? UI events are not designed to
> > > span multiple activities.
>
> > > > In order to triggers the onTouch of the button in the second activity,
> > > > i create a copy of the MotionEvent in the first activity and send it
> > > > as an Intent Extra to the second activity which call it's own onTouch
> > > > passing this MotionEvent as parameter.
>
> > > Ick.
>
> > > > Oh, and btw, I call it a 'child' activity since it has a "getParent()"
> > > > method which returns the main activity...
>
> > > Then you are not starting the "child activity" via startActivity().
>
> > > --
> > > Mark Murphy (a Commons 
> > > Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> > > _Android Programming Tutorials_ Version 2.0 Available!
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Beginners" group.
>
> NEW! Try asking and tagging your question on Stack Overflow 
> athttp://stackoverflow.com/questions/tagged/android
>
> To unsubscribe from this group, send email to
> android-beginners+unsubscr...@googlegroups.com
> For more options, visit this group 
> athttp://groups.google.com/group/android-beginners?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: Add two buttons to a graphics view?

2010-04-16 Thread tony obrien
You can (easily?) create a simple main.xml layout file that contains,
say, a LINEAR LAYOUT with the buttons...

Then in your programming call the SetContextView(R.layout.main) and
you WILL have an R.id.BUTTON#1 to use.

You may have to call the super(canvas) in the override of onDraw() to
ensure that xml items get drawn in addition to whatever you're drawing
in onDraw().



On Apr 15, 10:20 pm, BobG  wrote:
> So I have a class graphicsView that extends View, and in that I do
> that @Override onDraw(Canvas canvas) and start drawing my picture with
> a paint and canvas.drawRect and drawLine and drawText.. So how would
> one add a couple buttons to this canvas, since I declared it
> programmatically, I cant look it up in findViewById(R.id,Button01)?
> Seems like I need a 'graphics button' rather than a 'text button'?? I
> dont have a good model of this yet as you can see. Insight
> appreciated.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Beginners" group.
>
> NEW! Try asking and tagging your question on Stack Overflow 
> athttp://stackoverflow.com/questions/tagged/android
>
> To unsubscribe from this group, send email to
> android-beginners+unsubscr...@googlegroups.com
> For more options, visit this group 
> athttp://groups.google.com/group/android-beginners?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: Android emulator problem

2010-04-16 Thread tony obrien
Try letting ECLIPSE start it for you... make sure you have an AVD
defined.


On Apr 15, 2:03 pm, "anton.maximov"  wrote:
> I try to start emulator and manually, over commandline, and over
> Eclipse. And each time i see this problem (

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


Re: [android-beginners] wrong example in dev guide - audio capture

2010-04-16 Thread Kenn Lisudza
Hi,

Try out this code base:

*package com.audio.recorder;*
*
*
*import java.io.File;*
*
*
*import android.app.Activity;*
*import android.media.MediaPlayer;*
*import android.media.MediaRecorder;*
*import android.os.Bundle;*
*import android.util.Log;*
*import android.view.View;*
*import android.view.View.OnClickListener;*
*import android.widget.Button;*
*
*
*/***
* * *
* * @author lisudza*
* **
* */*
*
*
*public class AudioRecorder extends Activity {*
*
*
* **private MediaPlayer mediaPlayer;*
* **private MediaRecorder mediaRecorder;*
* **private static final String OUTPUT_FILE = "/sdcard/recordoutput.3gpp";*
* **private String APP_NAME = "AudioRecorder";*
*
*
* **/** Called when the activity is first created. */*
* *...@override*
* **public void onCreate(Bundle savedInstanceState) {*
* **super.onCreate(savedInstanceState);*
* **setContentView(R.layout.main);*
* **Button startBtn = (Button) findViewById(R.id.beginRecording);*
* **Button endBtn = (Button) findViewById(R.id.stopRecording);*
* **Button playRecordingBtn = (Button) findViewById(R.id.playRecording);*
* **Button stpPlayingRecordingBtn = (Button) findViewById(R.id.stopPlaying);
*
*
*
* **startBtn.setOnClickListener(new OnClickListener() {*
*
*
* **public void onClick(View v) {*
* **// TODO Auto-generated method stub*
* **try {*
* **Log.d(APP_NAME, "Start recording..");*
* **beginRecording();*
* **} catch (Exception ex) {*
* **Log.e(APP_NAME, "Failed to start recording ", ex);*
* **}*
* **}*
* **});*
*
*
* **endBtn.setOnClickListener(new OnClickListener() {*
*
*
* **public void onClick(View v) {*
* **try {*
* **stopRecording();*
* **} catch (Exception ex) {*
* **Log.e(APP_NAME, "Oh Oh Failed to stop recording. ", ex);*
* **}*
* **}*
* **});*
*
*
* **stpPlayingRecordingBtn.setOnClickListener(new OnClickListener() {*
*
*
* **public void onClick(View v) {*
* **try {*
* **stopPlayingRecording();*
* **Log.d(APP_NAME, "Just stopped Recording...");*
* **} catch (Exception ex) {*
* **Log.e(APP_NAME, "Not Good could not stop playing the recorded sound. ",
ex);*
* **}*
* **}*
* **});*
*
*
* **playRecordingBtn.setOnClickListener(new OnClickListener() {*
*
*
* **public void onClick(View v) {*
* **// TODO Auto-generated method stub*
* **try {*
* **playRecording();*
* **} catch (Exception ex) {*
* **Log.e(APP_NAME, "Application could play the recording...",*
* **ex);*
* **}*
* **}*
* **});*
*
*
* **stpPlayingRecordingBtn.setOnClickListener(new OnClickListener() {*
*
*
* **public void onClick(View v) {*
* **try {*
* **playRecording();*
* **}catch (Exception ex ){*
* **Log.e(APP_NAME, "Failed to Start Playing the record...", ex);*
* **}*
* **}*
* **});*
* **}*
*
*
* **/***
* ** * Method beginRecording prepares and starts the audio capturing.
*
* ** * *
* ** * @throws Exception*
* ** */*
* **private void beginRecording() throws Exception {*
* **killMediaRecorder();*
*
*
* **File outFile = new File(OUTPUT_FILE);*
*
*
* **if (outFile.exists()) {*
* **Log.d(APP_NAME, "The File exists. Deleted");*
* **outFile.delete();*
* **}*
*
*
* **mediaRecorder = new MediaRecorder();*
* **mediaRecorder.setAudioSource(MediaRecorder.AudioSource.MIC);*
* **mediaRecorder.setOutputFormat(MediaRecorder.OutputFormat.THREE_GPP);*
* **mediaRecorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB);*
* **mediaRecorder.setOutputFile(OUTPUT_FILE);*
* **mediaRecorder.prepare();*
* **mediaRecorder.start();*
* **}*
*
*
* **/***
* ** * Method killMediaRecorder - checks for an active MediaRecorder*
* ** * object and kills it.*
* ** * *
* ** */*
*
*
* **private void killMediaRecorder() {*
* **if (mediaRecorder != null) {*
* **mediaRecorder.release();*
* **}*
* **}*
*
*
* **private void stopRecording() {*
* **if (mediaRecorder != null) {*
* **mediaRecorder.stop();*
* **}*
* **}*
*
*
* **/***
* ** * Method  killMediaPlayer kills and releases the media player.*
* ** */*
* **private void killMediaplayer() {*
* **if (mediaPlayer != null) {*
* **try {*
* **mediaPlayer.release();*
* **} catch (Exception ex) {*
* **Log.e(APP_NAME, "Failed to kill the media player.", ex);*
* **}*
* **}*
* **}*
*
*
* **private void playRecording() throws Exception {*
* **killMediaplayer();*
* **mediaPlayer = new MediaPlayer();*
* **mediaPlayer.setDataSource(OUTPUT_FILE);*
* **mediaPlayer.prepare();*
* **mediaPlayer.start();*
* **}*
*
*
* **private void stopPlayingRecording() throws Exception {*
* **if (mediaPlayer != null) {*
* **mediaPlayer.stop();*
* **}*
* **}*
*
*
* *...@override*
* **protected void onDestroy() {*
* **super.onDestroy();*
* **killMediaplayer();*
* **killMediaRecorder();*
* **Log.d(APP_NAME, "Finished clearing all held resources...");*
* **}*
*}*
*
*

Here is the layout file:

**
*http://schemas.android.com/apk/res/android"*
*android:orientation="vertical"*
*android:layout_width="fill_parent"*
*android:layout_height="fill_parent">*
* ***
**
**
*** *
*** *
**


Hope it helps. Its running on my G1 perfectly.


On Fri, Apr 16, 2010 at 3:46 AM, hshong  wrote:

> hi.
>
> below link

[android-beginners] Emulator disconnected

2010-04-16 Thread Miguel Guirao
Hi Androids,

I'm brand new into mobile application development and into android. I have
been following the examples on the Android web site to get my Hello World
app done, bun when I run the app on Eclipse Galileo, it compiles with out
errors, opens the emulator, but few seconds later I got the leyend "Emulator
disconnected" on Eclipse. I'm using the latest versions of the Android SDK
and the ADT pluging for Eclipse.

Any ideas?

Miguel Guirao A

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: Android emulator problem

2010-04-16 Thread Kitzy
Try using eclipse to first - create the avd
And second - to start it

Within eclipse you can create many avds, see if by creating a new on
you still have the problem.

-Kitzy

On Apr 16, 7:22 am, tony obrien  wrote:
> Try letting ECLIPSE start it for you... make sure you have an AVD
> defined.
>
> On Apr 15, 2:03 pm, "anton.maximov"  wrote:
>
> > I try to start emulator and manually, over commandline, and over
> > Eclipse. And each time i see this problem (
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Beginners" group.
>
> NEW! Try asking and tagging your question on Stack Overflow 
> athttp://stackoverflow.com/questions/tagged/android
>
> To unsubscribe from this group, send email to
> android-beginners+unsubscr...@googlegroups.com
> For more options, visit this group 
> athttp://groups.google.com/group/android-beginners?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: How to get child Activity?

2010-04-16 Thread Kitzy
What if you left state b as part of activity 1? Then pressing button
or releasing long-press would start activity 2 (with all of state a).

Long pressing the button would inflate a view with state b (all inside
activity 1)

-Kitzy

On Apr 16, 6:31 am, Rodrigo Chiossi  wrote:
> Hi Kitzy.
> If you just click the button, the second activity should start in a
> state A. if you longpress the button, the activity should start in a
> state B and go to state A upon releasing the button (In fact, upon
> releasing the screen, since the button does not exists in the second
> activity), so i can't start it after release. Your second suggestion
> is actually what I managed to do as a workaround: I broadcast an
> intent whenever the first activity receives an event and the second
> activity has already been started (I set a flag after starting). It's
> not a beautiful code, but it's the best solution so far...
> I know it would be easy just not to use this kind of interaction, but
> this is the key feature of the app.
>
> On Apr 16, 1:48 am, Kitzy  wrote:
>
> > What if you start your activity after release?  Or use a broadcast
> > receiver?
>
> > Why do you need the new activity to know when you release?
>
> > -Kitzy
>
> > On Apr 15, 10:35 am, Rodrigo Chiossi  wrote:
>
> > > I have already tried 3 different approaches to the problem:
> > > The first was this one i described previously, which would be the
> > > ideal for my app.
> > > The second one, i created an ActivityGroup which was responsible for
> > > starting two activities and on LongClick event I was swaping the
> > > DecorViews of the activities. Still, the same problem happened: the
> > > ACTION_UP was being delivered to the wrong activity.
> > > My last approach was to create a single activity and call
> > > setContentView to swap between the two layouts, and still, the event
> > > was not delivered to the right view.
> > > I'm just wondering if there is a way for an Activity to request Input
> > > events...
>
> > > @Mark: you are right, i messed those approaches a little. I have the
> > > getParent only when I use an ActivityGroup.
>
> > > On Apr 15, 12:23 pm, Mark Murphy  wrote:
>
> > > > Rodrigo Chiossi wrote:
> > > > > First, the user press a button on the main Activity. When the
> > > > > LongClick triggers, I start the second Activity wich also has a button
> > > > > which should be pressed when the activity starts and should only be
> > > > > released when the user takes his finger off the screen.
>
> > > > Why are you using multiple activities? UI events are not designed to
> > > > span multiple activities.
>
> > > > > In order to triggers the onTouch of the button in the second activity,
> > > > > i create a copy of the MotionEvent in the first activity and send it
> > > > > as an Intent Extra to the second activity which call it's own onTouch
> > > > > passing this MotionEvent as parameter.
>
> > > > Ick.
>
> > > > > Oh, and btw, I call it a 'child' activity since it has a "getParent()"
> > > > > method which returns the main activity...
>
> > > > Then you are not starting the "child activity" via startActivity().
>
> > > > --
> > > > Mark Murphy (a Commons 
> > > > Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> > > > _Android Programming Tutorials_ Version 2.0 Available!
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Beginners" group.
>
> > NEW! Try asking and tagging your question on Stack Overflow 
> > athttp://stackoverflow.com/questions/tagged/android
>
> > To unsubscribe from this group, send email to
> > android-beginners+unsubscr...@googlegroups.com
> > For more options, visit this group 
> > athttp://groups.google.com/group/android-beginners?hl=en
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Beginners" group.
>
> NEW! Try asking and tagging your question on Stack Overflow 
> athttp://stackoverflow.com/questions/tagged/android
>
> To unsubscribe from this group, send email to
> android-beginners+unsubscr...@googlegroups.com
> For more options, visit this group 
> athttp://groups.google.com/group/android-beginners?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Latin characters in EditText Android

2010-04-16 Thread Murilo Braga
Hi everyone,
   Does anyone know how can i use Latin characters such as ç á é ê in
android?
   All my EditText components do not accept it, neither does the Contacts
Application for instance.

   Whenever i raise my application and emulator i get the following error:
 Application Android Keyboard (in process com.android.inputmethod.latin)
is not responding.

I don't know if this problem is related, but i think so.


can anyone help me out?


-- 
Murilo Costa
muri...@gmail.com
twitter.com/murilobtc

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: Is there a concept like DLL in Andoirds?

2010-04-16 Thread Kitzy
You can create libraies in C/C++ and share them with your
applications. Look at the NDK to see if that may help.

http://developer.android.com/sdk/ndk/index.html

-Kitzy

On Apr 16, 12:01 am, Prashant Shelar  wrote:
> Hello,
>
> I know that we can use a concept "Java Package" but I just wanted to
> know that whether Android has provided a DLL concept where I can my
> most of the functionality.
>
> Is there any concept like DLL on Android OS?
>
> Can we develop a DLL for better modularization and other benefits on
> Android?
>
> Thanks and Regards,
> Prashant.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Beginners" group.
>
> NEW! Try asking and tagging your question on Stack Overflow 
> athttp://stackoverflow.com/questions/tagged/android
>
> To unsubscribe from this group, send email to
> android-beginners+unsubscr...@googlegroups.com
> For more options, visit this group 
> athttp://groups.google.com/group/android-beginners?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: Latin characters in EditText Android

2010-04-16 Thread Murilo Braga
Forgot to say i'm in Brazil, so it should be portuguese characters.

On Fri, Apr 16, 2010 at 2:29 PM, Murilo Braga  wrote:

> Hi everyone,
>Does anyone know how can i use Latin characters such as ç á é ê in
> android?
>All my EditText components do not accept it, neither does the Contacts
> Application for instance.
>
>Whenever i raise my application and emulator i get the following error:
>  Application Android Keyboard (in process
> com.android.inputmethod.latin) is not responding.
>
> I don't know if this problem is related, but i think so.
>
>
> can anyone help me out?
>
>
> --
> Murilo Costa
> muri...@gmail.com
> twitter.com/murilobtc
>



-- 
Murilo Costa
muri...@gmail.com
twitter.com/murilobtc

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Compile Help

2010-04-16 Thread Rayborn
I have attempted many times to use the make function on the android
source
This is the following error I am always receiving, I highly doubt its
my source because i have redownloaded the source multiple times. Could
any shed some light or a gentle nudge in the right direction?


Install: out/target/product/sholes-open/system/lib/
libopencore_streamingreg.so
target thumb C++: libopencorehw <= hardware/ti/omap3/libopencorehw/
android_surface_output_omap34xx.cpp
hardware/ti/omap3/libopencorehw/android_surface_output_omap34xx.cpp:
In constructor
'AndroidSurfaceOutputOmap34xx::AndroidSurfaceOutputOmap34xx()':
hardware/ti/omap3/libopencorehw/android_surface_output_omap34xx.cpp:
78: error: 'mNumberOfFramesToHold' was not declared in this scope
hardware/ti/omap3/libopencorehw/android_surface_output_omap34xx.cpp:
In member function 'virtual void
AndroidSurfaceOutputOmap34xx::setParametersSync(void*, PvmiKvp*, int,
PvmiKvp*&)':
hardware/ti/omap3/libopencorehw/android_surface_output_omap34xx.cpp:
289: error: 'class PVMFYuvFormatSpecificInfo0' has no member named
'width'
hardware/ti/omap3/libopencorehw/android_surface_output_omap34xx.cpp:
293: error: 'class PVMFYuvFormatSpecificInfo0' has no member named
'height'
hardware/ti/omap3/libopencorehw/android_surface_output_omap34xx.cpp:
297: error: 'class PVMFYuvFormatSpecificInfo0' has no member named
'display_height'
hardware/ti/omap3/libopencorehw/android_surface_output_omap34xx.cpp:
302: error: 'class PVMFYuvFormatSpecificInfo0' has no member named
'display_width'
make: *** [out/target/product/sholes-open/obj/SHARED_LIBRARIES/
libopencorehw_intermediates/android_surface_output_omap34xx.o] Error 1

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: Add two buttons to a graphics view?

2010-04-16 Thread BobG
Hi Tony. Thanks for replying. Seems like what happens is: I make the
GraphicsView view that extends view, and the first thing one has to do
in graphics mode is drawPaint, which clears the whole screen,
including the buttons which had been drawn in the startup Textview. So
Someone needs to point me to the example that shows a big square of
graphics in the middle of a portrait screem with a pair of buttons on
the right or left of the graphics, maybe labeled 'up' and 'dn' and
out' and 'in' or similar. I'm tempted to try and draw some ascii
graphics, but they always get formatted into a mishmash.
=
On Apr 16, 9:20 am, tony obrien  wrote:
> You can (easily?) create a simple main.xml layout file that contains,
> say, a LINEAR LAYOUT with the buttons...
>
> Then in your programming call the SetContextView(R.layout.main) and
> you WILL have an R.id.BUTTON#1 to use.
>
> You may have to call the super(canvas) in the override of onDraw() to
> ensure that xml items get drawn in addition to whatever you're drawing
> in onDraw().
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: Need Help: Can't play multiple sounds simultaneously with SoundPool

2010-04-16 Thread BobG
Wouldnt you add both sounds to the pool, and issue 2 play looping
commands? Then you can adj rate and volume while they are playing.

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: Need Help: Can't play multiple sounds simultaneously with SoundPool

2010-04-16 Thread BobG
Looks like you are only adding sound1 to the pool. Need to add sound2
also? You need to remember the soundid the pool gives you... you could
start 'airplane sound' then start 3 more of them, and they all have
diff IDs so you can adj the vol of each as they fly by, etc.

On Apr 13, 5:26 pm, Jack  wrote:
> Thanks BobG.
> But it doesn't work. I was told that if I call
> mSoundManager.playSound() twice in immediate succession, then it might
> work, but it doesn't. Can somebody help?
>
> On Apr 13, 12:53 pm, BobG  wrote:
>
>
>
> > Try declaring soundpool for 4 more sounds than you want to play.
> > There's some messages saying that helps?- Hide quoted text -
>
> - Show quoted text -

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Paint.setTextSize(size) and canvas

2010-04-16 Thread melling
I'm drawing text on a canvas.  How can I adjust the text size so that
it sizes appropriately on different displays?  There doesn't seem to
be a generic method like specifying "sp" in the XML files:

android:textSize="14sp"

-Mike


-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Searching Files that have been scanned by the MediaScanner

2010-04-16 Thread Gubatron
Is there a way to programatically search the files scanned by the
MediaScanner?

I see that you can only connect to it to let it know about new files
it should scan.

I thought I could use SearchManager, but I don't want to trigger the
user interface I need to do something else with the search results.

I'd like to have something like this:

List searchFilters;
...

List results = SearchIndex.search(keyword, searchFilters);

or at least be able to iterate through all the scanned files,
otherwise I'll have to scan myself and that's not the best idea.


I've been looking at MediaStore and subclasses, but I see no search or
iterative methods there (just a stupid keyFor(String  name) method).
I'd also like to be able to iterate through all the files that have
been scanned.

Can anybody point me to something similar. How can I get a hold of
what MediaScanner has indexed, I need to iterate or search through
those files.

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


Re: [android-beginners] Searching Files that have been scanned by the MediaScanner

2010-04-16 Thread Mark Murphy
Gubatron wrote:
> I've been looking at MediaStore and subclasses, but I see no search or
> iterative methods there (just a stupid keyFor(String  name) method).

MediaStore represents a family of ContentProviders. ContentProvider,
through a ContentResolver, offers a query() method. Various MediaStore
inner classes offer Uri values you can use with ContentResolver (e.g.,
MediaStore.Images.Media.EXTERNAL_CONTENT_URI).

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://twitter.com/commonsguy

_Beginning Android 2_ from Apress Now Available!

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] calling an existing app with an intent

2010-04-16 Thread moiraine
I'm trying to write an app that contains a store locator, and right
now the best solution I can think of is to use the already-existing
app, YellowPages.  Is it possible to call the YellowPages app in an
intent, and have it return the location?

If so, can someone help me out or give me some places to look to
figure out how to do this?

Thanks,
Emily

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


Re: [android-beginners] calling an existing app with an intent

2010-04-16 Thread Mark Murphy
moiraine wrote:
> I'm trying to write an app that contains a store locator, and right
> now the best solution I can think of is to use the already-existing
> app, YellowPages.  Is it possible to call the YellowPages app in an
> intent, and have it return the location?

That would be a fine question to ask the author of the YellowPages app.
I'm not sure it is possible for anyone else to answer your question.

Sorry!

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://twitter.com/commonsguy

Android App Developer Books: http://commonsware.com/books

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] Re: Android Emulator don't show up (Linux Fedora 12 x86_64)

2010-04-16 Thread Indicator Veritatis
You should not have to disable audio to run the emulator.

I wish I could be sure my proposal would work for this problem, but I
don't: since it is a good idea anyway, I will go ahead and say you
should try removing pulse-audio from your Fedora installation, since
nobody uses it anymore anyway, yet it causes lots of weird problems.

I have a lot fewer audio problems ever since removing pulse about a
month ago. Unfortunately, I can't remember exactly how it is done: try
"yum info pulse-audio" as superuser to see if that gives you the exact
package name to remove. Then remove it with "yum remove "

On Apr 14, 1:34 pm, yodaa  wrote:
> I hopefully found a workaround
> see:http://forums.fedoraforum.org/showthread.php?p=1350997&posted=1#post1...
>
> That's weird but audio is involved is this issue, arguments must
> passed in the run configuration to disable audio:
>
> In Eclipse, "Run" > "Run Configuration" > "Android Application" > "my
> android app" tab > "target tab > "Additionnal Emulator Command Line
> Options" type "-no-audio" + "Apply"
>
> Running the application is now a success:
>
> [2010-04-14 22:16:36 - HelloDroid] Android Launch!
> [2010-04-14 22:16:36 - HelloDroid] adb is running normally.
> [2010-04-14 22:16:36 - HelloDroid] Performing
> com.tests.HelloDroid.HelloDroid activity launch
> [2010-04-14 22:16:36 - HelloDroid] Automatic Target Mode: launching
> new emulator with compatible AVD 'FakePhone_2_1'
> [2010-04-14 22:16:36 - HelloDroid] Launching a new emulator with
> Virtual Device 'FakePhone_2_1'
> [2010-04-14 22:16:37 - HelloDroid] New emulator found: emulator-5554
> [2010-04-14 22:16:37 - HelloDroid] Waiting for HOME
> ('android.process.acore') to be launched...
> [2010-04-14 22:17:32 - HelloDroid] WARNING: Application does not
> specify an API level requirement!
> [2010-04-14 22:17:32 - HelloDroid] Device API version is 7 (Android
> 2.1)
> [2010-04-14 22:17:32 - HelloDroid] HOME is up on device
> 'emulator-5554'
> [2010-04-14 22:17:32 - HelloDroid] Uploading HelloDroid.apk onto
> device 'emulator-5554'
> [2010-04-14 22:17:32 - HelloDroid] Installing HelloDroid.apk...
> [2010-04-14 22:17:45 - HelloDroid] Success!
> [2010-04-14 22:17:45 - HelloDroid] Starting activity
> com.tests.HelloDroid.HelloDroid on device
> [2010-04-14 22:17:58 - HelloDroid] ActivityManager: Starting: Intent
> { act=android.intent.action.MAIN
> cat=[android.intent.category.LAUNCHER]
> cmp=com.tests.HelloDroid/.HelloDroid }
>
> On 26 mar, 21:37, yodaa  wrote:> Hello,
>
> > I decided to install my Android development environment on my second
> > OS: Fedora 12 x_86_64 (KDE)
> > with proprietary NVIDIA Drivers. My distribution is up to date.
>
> > SUN Java JRE, JDK and Eclipse Galileo EE are installed, Android SDK
> > 2.1, ADT eclipse plugin
> > , android SDK tools, Google APIs... are up to date. I also set up the
> > ~bashrc file for my current user.
>
> > I tried to create a new Android project (Hello World flavour) and get
> > the following error:
>
> > Failed to parse the out of 'adb version'
> > android-sdk/tools/adb: error while loading shared libraries:
> > libncurses.so.5:
> > cannot open shared object file
>
> > I figured out that the 32bits libs were missing. So I followed
> > instructions about 32bits needed 
> > packages:http://www.crashcourse.ca/wiki/index.php/The_Android_SDK_on_64-bit_Fe...
> > and installed them:
>
> > ##
> > # yum install glibc.i686
> > # yum install glibc-devel.i686
> > # yum install libstdc++.i686
> > # yum install zlib-devel.i686
> > # yum install ncurses-devel.i686
> > # yum install libX11-devel.i686
> > ##
>
> > I restarted Eclipse, the previous error message disappeared.
> > I created a virtual device called "fake_phone_2_1" and target my
> > "Hello World" project to Android 2.1.
> > So created my project (HelloDroid), and ran it.
> > The emulator didn't showed up, even after a few minutes.
> > I got no error or warning... I'm missing something here.
>
> > Console output within Eclipse:
> > 
> > [2010-03-26 20:09:07 - HelloDroid] Android Launch!
> > [2010-03-26 20:09:08 - HelloDroid] adb is running normally.
> > [2010-03-26 20:09:08 - HelloDroid] Performing
> > com.tests.HelloDroid.HelloDroid activity launch
> > [2010-03-26 20:09:08 - HelloDroid] Automatic Target Mode: launching
> > new emulator with compatible AVD 'FakePhone_2_1'
> > [2010-03-26 20:09:08 - HelloDroid] Launching a new emulator with
> > Virtual Device 'FakePhone_2_1'
>
> > Please find below somemore information about my environement setup:
>
> > 1 ) JRE and JDK location
> > --
> > /opt/jdk1.6.0_18
> > /opt/jre1.6.0_18
>
> > 2 ) SUN JAVA version
> > 
> > Java(TM) SE Runtime Environment (build 1.6.0_18-b07)
> > Java HotSpot(TM) 64-Bit Server VM (build 16.0-b13, mixed mode)
>
> > 3 ) Eclipse Galileo IDE for Java EE Developers
> > ---

[android-beginners] Re: calling an existing app with an intent

2010-04-16 Thread moiraine
Hrm, well if that's not possible, do you know of any store-locator api
or such that exists?

I know the normal google maps API contains it, using the "GGoogleBar",
but the google maps API for android doesn't seem to contain it, or I'm
missing it somewhere.  Any idea?

On Apr 16, 3:03 pm, Mark Murphy  wrote:
> moiraine wrote:
> > I'm trying to write an app that contains a store locator, and right
> > now the best solution I can think of is to use the already-existing
> > app, YellowPages.  Is it possible to call the YellowPages app in an
> > intent, and have it return the location?
>
> That would be a fine question to ask the author of the YellowPages app.
> I'm not sure it is possible for anyone else to answer your question.
>
> Sorry!
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> Android App Developer Books:http://commonsware.com/books
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Beginners" group.
>
> NEW! Try asking and tagging your question on Stack Overflow 
> athttp://stackoverflow.com/questions/tagged/android
>
> To unsubscribe from this group, send email to
> android-beginners+unsubscr...@googlegroups.com
> For more options, visit this group 
> athttp://groups.google.com/group/android-beginners?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


Re: [android-beginners] Re: Android Emulator don't show up (Linux Fedora 12 x86_64)

2010-04-16 Thread Michael Cheselka
Hello,

This is wrong!  Pulse Audio is new, not old.  People are using it more
and more not less and less.

It is working better all the time on Fedora 12.  Originally I had
problems now and then with Pulse Audio but  not in the last few
months.  In fact, my bluetooth headphones work best under Fedora 12
than under Vista 64 Ultimate or XP Pro.

It is used now with Gnome, MS Windows, and the Palm Pre.

Try to fix the problem rather than strip down the OS.

Read about Pulse Audio here:

http://en.wikipedia.org/wiki/PulseAudio

Regards,
Michael Cheselka
650-488-4820




On Fri, Apr 16, 2010 at 15:37, Indicator Veritatis  wrote:
> You should not have to disable audio to run the emulator.
>
> I wish I could be sure my proposal would work for this problem, but I
> don't: since it is a good idea anyway, I will go ahead and say you
> should try removing pulse-audio from your Fedora installation, since
> nobody uses it anymore anyway, yet it causes lots of weird problems.
>
> I have a lot fewer audio problems ever since removing pulse about a
> month ago. Unfortunately, I can't remember exactly how it is done: try
> "yum info pulse-audio" as superuser to see if that gives you the exact
> package name to remove. Then remove it with "yum remove  name>"
>
> On Apr 14, 1:34 pm, yodaa  wrote:
>> I hopefully found a workaround
>> see:http://forums.fedoraforum.org/showthread.php?p=1350997&posted=1#post1...
>>
>> That's weird but audio is involved is this issue, arguments must
>> passed in the run configuration to disable audio:
>>
>> In Eclipse, "Run" > "Run Configuration" > "Android Application" > "my
>> android app" tab > "target tab > "Additionnal Emulator Command Line
>> Options" type "-no-audio" + "Apply"
>>
>> Running the application is now a success:
>>
>> [2010-04-14 22:16:36 - HelloDroid] Android Launch!
>> [2010-04-14 22:16:36 - HelloDroid] adb is running normally.
>> [2010-04-14 22:16:36 - HelloDroid] Performing
>> com.tests.HelloDroid.HelloDroid activity launch
>> [2010-04-14 22:16:36 - HelloDroid] Automatic Target Mode: launching
>> new emulator with compatible AVD 'FakePhone_2_1'
>> [2010-04-14 22:16:36 - HelloDroid] Launching a new emulator with
>> Virtual Device 'FakePhone_2_1'
>> [2010-04-14 22:16:37 - HelloDroid] New emulator found: emulator-5554
>> [2010-04-14 22:16:37 - HelloDroid] Waiting for HOME
>> ('android.process.acore') to be launched...
>> [2010-04-14 22:17:32 - HelloDroid] WARNING: Application does not
>> specify an API level requirement!
>> [2010-04-14 22:17:32 - HelloDroid] Device API version is 7 (Android
>> 2.1)
>> [2010-04-14 22:17:32 - HelloDroid] HOME is up on device
>> 'emulator-5554'
>> [2010-04-14 22:17:32 - HelloDroid] Uploading HelloDroid.apk onto
>> device 'emulator-5554'
>> [2010-04-14 22:17:32 - HelloDroid] Installing HelloDroid.apk...
>> [2010-04-14 22:17:45 - HelloDroid] Success!
>> [2010-04-14 22:17:45 - HelloDroid] Starting activity
>> com.tests.HelloDroid.HelloDroid on device
>> [2010-04-14 22:17:58 - HelloDroid] ActivityManager: Starting: Intent
>> { act=android.intent.action.MAIN
>> cat=[android.intent.category.LAUNCHER]
>> cmp=com.tests.HelloDroid/.HelloDroid }
>>
>> On 26 mar, 21:37, yodaa  wrote:> Hello,
>>
>> > I decided to install my Android development environment on my second
>> > OS: Fedora 12 x_86_64 (KDE)
>> > with proprietary NVIDIA Drivers. My distribution is up to date.
>>
>> > SUN Java JRE, JDK and Eclipse Galileo EE are installed, Android SDK
>> > 2.1, ADT eclipse plugin
>> > , android SDK tools, Google APIs... are up to date. I also set up the
>> > ~bashrc file for my current user.
>>
>> > I tried to create a new Android project (Hello World flavour) and get
>> > the following error:
>>
>> > Failed to parse the out of 'adb version'
>> > android-sdk/tools/adb: error while loading shared libraries:
>> > libncurses.so.5:
>> > cannot open shared object file
>>
>> > I figured out that the 32bits libs were missing. So I followed
>> > instructions about 32bits needed 
>> > packages:http://www.crashcourse.ca/wiki/index.php/The_Android_SDK_on_64-bit_Fe...
>> > and installed them:
>>
>> > ##
>> > # yum install glibc.i686
>> > # yum install glibc-devel.i686
>> > # yum install libstdc++.i686
>> > # yum install zlib-devel.i686
>> > # yum install ncurses-devel.i686
>> > # yum install libX11-devel.i686
>> > ##
>>
>> > I restarted Eclipse, the previous error message disappeared.
>> > I created a virtual device called "fake_phone_2_1" and target my
>> > "Hello World" project to Android 2.1.
>> > So created my project (HelloDroid), and ran it.
>> > The emulator didn't showed up, even after a few minutes.
>> > I got no error or warning... I'm missing something here.
>>
>> > Console output within Eclipse:
>> > 
>> > [2010-03-26 20:09:07 - HelloDroid] Android Launch!
>> > [2010-03-26 20:09:08 - HelloDroid] adb is running normally.
>> > [2010-03-26 20:09:08 - HelloDroid] 

[android-beginners] Re: Any good site for searching Android API

2010-04-16 Thread Indicator Veritatis
I downloaded all the *.html fies (well, all of android-sdk-
linux_x86-1.6_r1/docs) and I search the whole thing using Linux
command line as follows:

find . -name "*.html" | xargs grep "ArrayAdapter"

Or, I can put some other keyword in place of ArrayAdapter, not
necessarily a class name or method name.

Does this answer your question?

On Apr 15, 12:34 am, Jacky Lam  wrote:
> Dear all,
>
>         Any good site or offline documentation which allow me to search and
> reference for Android API/Class/Object/Attribute?
>
>         Thanks.
>
> BR,
> Jacky

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en


[android-beginners] requestLocationUpdates issue

2010-04-16 Thread Tejas
Hi,

My class listed below is not working. No idea whatsoever. The
onLocationChanged method is never getting called !
I checked the logs for any errors/exceptions. I have the required
permissions set (fine and course locations).
I doubt the Context I'm setting from the caller. I'm using
getApplicationContext() to pass to the setContext method in this
class.
Can anyone please help ?

public class GPSSensor implements CASensor {

private String LTAG = this.getClass().getName();
Context myContext;
private String GPSData;
public LocationManager lMgr;
public LocationListener myLocListener = new LocationListener() {

public void onStatusChanged(String provider, int status, Bundle
extras) {
Log.v(LTAG, "=== Here 1 ");
}

public void onProviderEnabled(String provider) {
Log.v(LTAG, "=== Here 2 ");
}

public void onProviderDisabled(String provider) {
Log.v(LTAG, "=== Here 3 ");
}

public void onLocationChanged(Location location) {
if (location != null){
GPSData = location.getLatitude() + "," + 
location.getLongitude();
Log.v(LTAG, "GPS data received ===> " + 
GPSData);
}
else
Log.v(LTAG, "Location is null ===> ");
}
};

public String getCurrentData() {
return GPSData;
}

public void setContext(Context context) {
myContext = context;
}

public boolean startSensing() {
if (myContext == null){
Log.w(LTAG, "myContext not set");
return false;
}
Log.v(LTAG, "Starting location updates !");

lMgr = (LocationManager)
myContext.getSystemService(Context.LOCATION_SERVICE);
lMgr.requestLocationUpdates(LocationManager.GPS_PROVIDER, 0, 0,
myLocListener);
//lMgr.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, 
0,
0, myLocListener);
Log.v(LTAG, "Registered myLocListener for GPS");
return true;
}

public boolean stopSensing() {
if (myContext == null){
Log.w(LTAG, "myContext not set");
return false;
}
Log.v(LTAG, "Stopping location updates !");
lMgr.removeUpdates(myLocListener);
return false;
}

}//GPSSensor

-- 
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.

NEW! Try asking and tagging your question on Stack Overflow at
http://stackoverflow.com/questions/tagged/android

To unsubscribe from this group, send email to
android-beginners+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en