[android-developers] Re: Sending GPS coordinate to emulator reboots it

2011-07-07 Thread Sapna Srivastav
My application running absolutely fine on Android 2.1 and 2.2.
But problem arises when I run the application in android 2.3 and later
version emulator.

On Jul 7, 12:05 pm, Ali Chousein  wrote:
> Bbbrrr, looks scary. I've been working extensively with GPS signal and
> have been sending GPS coordinates to the emulator. The target AVDs I
> created are version 2.1 (updated) and 2.2 and I've never faced any
> issue. Some coordinates I worked with are:
>
> geo fix 5.4780 51.4480
> geo fix 9.9975 48.3945
> geo fix 2.3511 48.8577
>
> Could it be the case that there is a bug in the logic of your code
> which handles the GPS signal? Do you get the same problem when you
> send the GPS coordinates while running the 'Hello World' example?
>
> --
> Ali Chousein
> Geo-Filtered Assistanthttp://geo-filtered-assistant.blogspot.com/
> Cisco Android marketplace 
> (Chosen)https://marketplace.cisco.com/apphq/products/510

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Galaxy Tab and Market filtering

2011-07-07 Thread nadam
The old Galaxy Tab 7" is said to be a large mdpi device but it uses
hdpi drawables. I did an experiment to create an app with the
following restrictions in the manifest.











The Device Availability dialog in the Developer Console tells me that
this app will not be available in Android Market for any Samsung
device. In particular, all variations of Galaxy Tab are listed as
unsupported. Why?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Aidl Error : couldn't find import for class org.json.JSONObject

2011-07-07 Thread rashmi
Hi Mark,
I am working on froyo2.2 source code. My aim is to include the 'import 
org.json.JSONObject' statement in aidl file. It is giving the build error - 
'couldn't find import for class org.json.JSONObject'.

I also tried creating a project in Eclipse and including an aidl file with 
import org.json.JSONObject. Even this project is also giving the same error. 
Please give me solution for how to include json import in aidl.

Thanks,

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Cursor in EditText not visible

2011-07-07 Thread Raghav Sood
It may be that you set your colors to be the same as the cursor and now it
is invisible on the EditText?

On Fri, Jul 8, 2011 at 10:25 AM, Kelly  wrote:

> I'm running into the same issue and I also set my backgroundColor of
> my EditText to be white.
>
> Did you happen to find any solutions to this?
>
> On Jun 30, 10:59 pm, CrazzyAndroidians  wrote:
> > Hi,
> >
> > I am having a strange issue where the cursor in the EditText is not
> > visible but I can type and can do all stuff with the editText. The
> > scenario is I am giving background image to the editText and and
> > setting the textColor to white. The focus is there, then only we can
> > type.
> >
> > I put cursorVisible="true" and tried with lot of trial and error
> > methods to make the cursor visible but of no use. From this I came to
> > know, if we can color the cursor other than the default color, it will
> > be better.
> >
> > Anybody else have this issue earlier
> >
> > Thanks
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] how to typecast String data to Object data type java/Android

2011-07-07 Thread TreKing
On Thu, Jul 7, 2011 at 8:55 PM, Latcho  wrote:

> I you had actually answered the question or remained silent you too had
> served the list because
>

I don't know what that means.


>  A) I was actually interested in the answer
>

I'm sorry to hear that you do not seem understand basic Java.

 B) I had to read your boring reply in the hope of an answer.
>

I'm sorry to have bored you. If it makes you feel better, I was fairly bored
with your reply as well. Call it even?

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Cursor in EditText not visible

2011-07-07 Thread Kelly
I'm running into the same issue and I also set my backgroundColor of
my EditText to be white.

Did you happen to find any solutions to this?

On Jun 30, 10:59 pm, CrazzyAndroidians  wrote:
> Hi,
>
> I am having a strange issue where the cursor in the EditText is not
> visible but I can type and can do all stuff with the editText. The
> scenario is I am giving background image to the editText and and
> setting the textColor to white. The focus is there, then only we can
> type.
>
> I put cursorVisible="true" and tried with lot of trial and error
> methods to make the cursor visible but of no use. From this I came to
> know, if we can color the cursor other than the default color, it will
> be better.
>
> Anybody else have this issue earlier
>
> Thanks

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] record incoming and outgoing calls?

2011-07-07 Thread Hitendrasinh Gohil
any help please?

On Thu, Jul 7, 2011 at 4:47 AM, Hitendrasinh Gohil <
hitendra.virtuei...@gmail.com> wrote:

> Hi,
>
> Just want to know that how to record incoming and outgoing calls on
> wide varity of devices?
>
> I am using the mediarecorder and with this i am able to record
> incoming and outgoing calls with sony xperia x10 mini.
> mediaRecorder.setAudioSource(MediaRecorder.AudioSource.VOICE_CALL);
>
> and same code doesnt work on galaxt tab.
>
> I have googling a lot but from that it seems its not possible to
> record the calls.
> But i have found this link
> https://market.android.com/details?id=com.killermobile.totalrecall.market
>
> and tested it with samsung galaxy tab and sony xperia x10mini.It works
> fine for both the devices.
>
> so can anybody tell me how it can be possible to record calls with
> wide variaty of devices?
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en




-- 
Regards,
Hitendrasinh Gohil

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] geocoding support

2011-07-07 Thread bob
If geocoding is just a matter of talking to a server, how come some
phones don't support it?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread Nathan
For me, technically, I think they would have to go small claims
court ;) (in the most optimistic of cases).

Nathan

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread Chris
I'm guessing whatever was communicated was sent 'in confidence' and by 
emanating the contents would hurt whatever case he had.  Best to leave this 
question alone for a lil while.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread Chris
>I don't give two shits if they want to try and sue me

Me neither.  x% of 0 is still zero.  I love that about math.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
@Mark: No I downloaded them before you put up the release but I got the new
ones now. Thanks

@gjs: Thanks for your support.

On Fri, Jul 8, 2011 at 7:02 AM, gjs  wrote:

> Hi,
>
> Raghav mentioned before he is 14, I think he should be encouraged with
> his efforts.
>
> Regards
>
> On Jul 8, 5:11 am, Mark Murphy  wrote:
> > On Thu, Jul 7, 2011 at 3:09 PM, Raghav Sood 
> wrote:
> > > Thanks Mark. I really appreciate all the help all of you have given me
> so
> > > far. I got your books and they are a lot more straightforward than the
> one I
> > > was using so far.
> >
> > BTW, I just uploaded a new round of editions, so you may want to check
> > and ensure you got the latest ones.
> >
> > --
> > Mark Murphy (a Commons Guy)http://commonsware.com|
> http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy
> >
> > Android Training...At Your Office:http://commonsware.com/training
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Measure View before rendering

2011-07-07 Thread Romain Guy
You need to use MeasureSpec.makeMeasureSpec(). You can't just pass EXACTLY,
you need to pass makeMeasureSpec(EXACTLY, 200) for instance.

On Thu, Jul 7, 2011 at 8:44 PM, Isliguezze  wrote:

> Hello folks!
>
> I have a pretty simple question with probably not that simple answer:
> how do I measure a newly created view before it's been rendered.
>
> For example
>
> TextView tv = getLayoutInflater().inflate(R.layout.textview, null);
>
> tv.getHeight() returns zero after measure() with EXACTLY, and AT_MOST,
> layout(), buildDrawingCache(), etc
>
> I need to get height of the view to show a PopupWindow at some
> location.
>
> Thank you.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Romain Guy
Android framework engineer
romain...@android.com

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Measure View before rendering

2011-07-07 Thread Isliguezze
Hello folks!

I have a pretty simple question with probably not that simple answer:
how do I measure a newly created view before it's been rendered.

For example

TextView tv = getLayoutInflater().inflate(R.layout.textview, null);

tv.getHeight() returns zero after measure() with EXACTLY, and AT_MOST,
layout(), buildDrawingCache(), etc

I need to get height of the view to show a PopupWindow at some
location.

Thank you.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] retrieving thumbnails of images

2011-07-07 Thread Honest
Hello,

I want to retrieve Thumbnails of all images  stored in SD CARD. i have
wrote following code but some how it is only retrieving thumbnails of
only three images. Even if i captured new image it do not come there.
The following is the code. can some one tell me what are the wrong
thing i am doing ?

Uri sdcardImage =
MediaStore.Images.Thumbnails.getContentUri("external");
Cursor c=getContentResolver().query(sdcardImage , null, null, null,
null);c.moveToFirst();

for(int i=0;ihttp://groups.google.com/group/android-developers?hl=en


Re: [android-developers] how to typecast String data to Object data type java/Android

2011-07-07 Thread Latcho
I you had actually answered the question or remained silent you too had 
served the list because

A) I was actually interested in the answer
B) I had to read your boring reply in the hope of an answer.

On 7/7/2011 7:29 PM, TreKing wrote:
On Thu, Jul 7, 2011 at 12:13 PM, naveen kumar 
mailto:kumarnaveen.si...@gmail.com>> wrote:


String epdata="sdfsad";
Object epArry=  (Object) epdata;


This is a basic Java questions and has nothing to do with Android 
development.


-
TreKing  - Chicago 
transit tracking app for Android-powered devices


--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en 


--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread gjs
Hi,

Raghav mentioned before he is 14, I think he should be encouraged with
his efforts.

Regards

On Jul 8, 5:11 am, Mark Murphy  wrote:
> On Thu, Jul 7, 2011 at 3:09 PM, Raghav Sood  wrote:
> > Thanks Mark. I really appreciate all the help all of you have given me so
> > far. I got your books and they are a lot more straightforward than the one I
> > was using so far.
>
> BTW, I just uploaded a new round of editions, so you may want to check
> and ensure you got the latest ones.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy
>
> Android Training...At Your Office:http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Active Installs doing (still) strange things....

2011-07-07 Thread John Coryat
My numbers are going up every day now and seem to be current. Are they 
right? What is right?

-John Coryat

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Active Installs doing (still) strange things....

2011-07-07 Thread Zsolt Vasvari
Yes, I see this, too.

Did you look at the number on right "Last month sales?"  It's
completely wrong for last month.

On Jul 7, 10:02 pm, Jim Graham  wrote:
> I'm just wondering if anyone else is seeing this
>
> There's still something strange going on in the Market,  and it is a bit
> too much a a coincidence to believe.
>
> For the last several days, EVERY time my total installs goes up by some
> number (regardless of what that number is), active installs goes DOWN
> by exactly the same number.  Not just once, not just twice, EVERY time,
> exactly the same amounts.
>
> Strange, huh?  Has anyone else been seeing anything like this?
>
> Later,
>    --jim
>
> --
> 73 DE N5IAL (/4)        | DMR: So fsck was originally called
> spooky1...@gmail.com    |      something else.
> < Running FreeBSD 7.0 > | Q:   What was it called?
> ICBM / Hurricane:       | DMR: Well, the second letter was different.
>    30.44406N 86.59909W  |    -- Dennis M. Ritchie, Usenix, June 1998.
>
> Point Lobos Photography Set 1 (Photo-posters):  http://jdgapps.com

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Can I hide my app in their application drawer?

2011-07-07 Thread Mark Murphy
On Thu, Jul 7, 2011 at 8:32 PM, neuromit  wrote:
> Is it possible to have my app appear in the application drawer until
> the user has launched it once?

You can use PackageManager to disable the component, sometime after
which it will no longer appear in home screen launchers. Bear in mind
that some home screens cache information about launchable activities,
and so it may not vanish immediately on all devices. Also, if the user
set up a shortcut to the activity, that shortcut will remain and just
fail to work, IIRC.

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

Android Training...At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] MediaController & VideoView

2011-07-07 Thread Mark Murphy
On Thu, Jul 7, 2011 at 8:13 PM, New Developer  wrote:
> Thanks for the fast response
>
> and yes I had read the programatic line
> why then do you have it as an option to add to your own layout.xml ?  IF it 
> can't be used this way ?
> curious?

They elected to implement it as a ViewGroup. Usually ViewGroups are
designed to be put in layouts, but there is no guarantee of that.

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

Android Training...At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Can I hide my app in their application drawer?

2011-07-07 Thread neuromit
Is it possible to have my app appear in the application drawer until
the user has launched it once?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Holding down Touch Screen

2011-07-07 Thread Mark Murphy
You will need to pay attention to the MotionEvents yourself, watching
for ACTION_POINTER_DOWN and ACTION_POINTER_UP on the same pointer. So
long as you have seen a DOWN and not the corresponding UP, the finger
has not left the screen. You may or may not care about ACTION_MOVE or
other events related to this finger.

And with that, you have pretty much exhausted my knowledge of
MotionEvents, so if you have follow-up questions, I'm hoping somebody
else can help... :-)

On Thu, Jul 7, 2011 at 8:13 PM, Joseph bates  wrote:
> So I am working on my first android game and I am going along with
> assistance from Beginning Android Games by Mario Zechner. Its a good
> book, but using his approach for input gathering, I can only seem to
> register touch input if its from a simple tap. My game requires the
> user to be able to hold down a "button" to keep the character
> constantly moving as long as the button is held down. The book tells
> me nothing about how to do this. Any assitance would be greatly
> appreciated.

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

Android Training...At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: How can Button clicks be sent to a View that has been disabled?

2011-07-07 Thread William Ferguson
Has no one seen an incidence of this occurring?
I would have said flat out it can't occur except that I see a couple
of instances each day.

Does this mean that all handler code needs to explicitly check to see
if a button is enabled first before executing its action?


On Jul 7, 10:31 am, William Ferguson 
wrote:
> I'm finding that some of my users are occasionally getting a button
> firing twice in rapid succession (less than 100 millis) even though
> the first thing the handler does is to disable the button. ie
>
> button.addOnClickListener(new OnClickListener() {
>    public void onClick(View view) {
>       button.setEnabled(false);
>       // do some stuff.
>    }
>
> });
>
> Is this expected behaviour?
> Ie that the InputEvents (button clicks) stack and will be sent to a
> View even though the View is disabled?
>
> William

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Holding down Touch Screen

2011-07-07 Thread Joseph bates
So I am working on my first android game and I am going along with
assistance from Beginning Android Games by Mario Zechner. Its a good
book, but using his approach for input gathering, I can only seem to
register touch input if its from a simple tap. My game requires the
user to be able to hold down a "button" to keep the character
constantly moving as long as the button is held down. The book tells
me nothing about how to do this. Any assitance would be greatly
appreciated.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] MediaController & VideoView

2011-07-07 Thread New Developer
Thanks for the fast response

and yes I had read the programatic line
why then do you have it as an option to add to your own layout.xml ?  IF it 
can't be used this way ?
curious?


On Jul 7, 2011, at 7:49 PM, Mark Murphy wrote:

> On Thu, Jul 7, 2011 at 7:42 PM, New Developer  wrote:
>> I have a simple  layout.xml  with a
>> 
>> > and
>>  
> Quoting the MediaController documentation: "The way to use this class
> is to instantiate it programatically." You don't put it in a layout.
> 
>> Purpose being I want the media controller visible at all times
> 
> I am not aware that MediaController can be used that way, though you
> can write your own -- it's not that tough.
> 
> -- 
> Mark Murphy (a Commons Guy)
> http://commonsware.com | http://github.com/commonsguy
> http://commonsware.com/blog | http://twitter.com/commonsguy
> 
> Android Training...At Your Office: http://commonsware.com/training
> 
> -- 
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] MediaController & VideoView

2011-07-07 Thread Mark Murphy
On Thu, Jul 7, 2011 at 7:42 PM, New Developer  wrote:
> I have a simple  layout.xml  with a
>
>  and
>  Purpose being I want the media controller visible at all times

I am not aware that MediaController can be used that way, though you
can write your own -- it's not that tough.

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

Android Training...At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] MediaController & VideoView

2011-07-07 Thread New Developer
Hi

I have a simple  layout.xml  with a

http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread JAlexoid (Aleksandr Panzin)
Would you feel better if Google wrote a similar letter to Lodsys? You do 
understand that that letter is just that - a letter.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread JAlexoid (Aleksandr Panzin)
PS: Nilay Patel did a little review for This Is My Next... 
http://thisismynext.com/2011/05/17/lodsys-sends-ios-developers-cease-and-desist-letters-in-app-purchases-on/

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread JAlexoid (Aleksandr Panzin)
Yeah... My bad. It's ~%.6. Forgot the "." before 6

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] List in appwidget going blank suddenly

2011-07-07 Thread Padma
Hi,

I have created an appwidget with a listview on Honeycomb 3.1. I am
using the RemoteViewsService and RemoteViewsFactory. However sometimes
I see that the listview suddenly becomes empty. The logs dont have
anything specific to my application. However I see the following in
the logs:

E/RemoteViewsAdapter(  873): Error in updateMetaData: null

Did anyone see a similar issue previously? If so, could you please
suggest a solution to this.

Regards,
Padma.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: Android and OSGi/Apache Felix

2011-07-07 Thread Richard S. Hall
At a minimum, I'd try asking your question on the Apache Felix users 
mailing list...


-> richard

On 7/7/11 18:07, Jesse wrote:
I have looked at that, but the EZDroid community hasn't been updated 
since 2009 and there is practically no content on their site. This 
makes me think it is completely abandoned. They do link to some code 
which was presented at a conference a few years 
back: https://opensource.luminis.net/wiki/display/SITE/Apache+Felix+on+Androids 
 The code is extremely basic though and it doesn't address any of my 
concerns. In their example projects, they create all views through 
code. They don't reference any Android resources, such as layout 
files. There is no discussion on what happens to the view created by 
the bundle if the bundle needs to be updated or removed.


Also, there is the fact that it is impossible to add an activity or 
service to an application without modifying the Android manifest.



--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en 


--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread Nathan


On Jul 6, 4:44 am, Mark Murphy  wrote:
> On Wed, Jul 6, 2011 at 6:48 AM, String  wrote:
> > Or, if not,
> > present a reasonable alternative to knuckling under to Lodsys' demands?
>
> In chronological order, here is advice from some actual attorneys
> (Patrick Igoe and Mark Webbink):
>
> http://www.groklaw.net/article.php?story=20110614184205441
>http://www.groklaw.net/article.php?story=20110615111436917
>http://www.groklaw.net/article.php?story=2011061608115990
>

The second article claims that seeking reexamination of the Lodsys
patents costs no money.

If so, how is it actually done? Do I just email the right guy at the
patent office? And how do I know if it has been done?

Nathan

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: EditText stops displaying characters as I'm typing?

2011-07-07 Thread Eric Carman
Hello e2gGuy,

I would encourage you to check out the issue I submitted:

http://code.google.com/p/android/issues/list

Search for issue 17508. 

Please add a comment with any additional information you may have and "Star" 
it. So far it doesn't appear to have been noticed.

Thank you.

Best Regards,
Eric

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Android and OSGi/Apache Felix

2011-07-07 Thread Jesse
I have looked at that, but the EZDroid community hasn't been updated since 
2009 and there is practically no content on their site. This makes me think 
it is completely abandoned. They do link to some code which was presented at 
a conference a few years 
back: https://opensource.luminis.net/wiki/display/SITE/Apache+Felix+on+Androids 
 The code is extremely basic though and it doesn't address any of my 
concerns. In their example projects, they create all views through code. 
They don't reference any Android resources, such as layout files. There is 
no discussion on what happens to the view created by the bundle if the 
bundle needs to be updated or removed.

Also, there is the fact that it is impossible to add an activity or service 
to an application without modifying the Android manifest.


-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Android and OSGi/Apache Felix

2011-07-07 Thread Richard S. Hall

I know it is done:

http://luminis-technologies.com/?page_id=21

-> richard

On 7/7/11 17:23, Jesse wrote:
Your link also demonstrates another worry of mine: nearly all 
discussions of OSGi on Android are from several years ago. --

You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en 


--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Android and OSGi/Apache Felix

2011-07-07 Thread Jesse
Your link also demonstrates another worry of mine: nearly all discussions of 
OSGi on Android are from several years ago.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Android and OSGi/Apache Felix

2011-07-07 Thread Streets Of Boston
I would be reaaallly surprised if OSGi would work on an Android 
phone/device.
Also, it would be a huge security risk if code could be automatically 
updated without any user-interaction.

However, you're not alone :)
http://www.osgi.org/blog/2007/11/android-and-osgi.html

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread Jim Graham
On Thu, Jul 07, 2011 at 10:22:11AM -0700, Miguel Morales wrote:

> cave in, go ahead.  But you're further perpetuating the situation.

Based on what I read in one of the articles from the links posted earlier
(I think it was groklaw.com, or something like that), caving in is
exactly what lodsys is counting on people to do.  They see these
frivolous lawsuits as a business.  The more people fight back, the
more it hurts their so-called "business".  That's one thing the articles
were very clear on---this is their business...buying vaguely-defined
patents and suing anyone who uses any portion of the descriptions in
those patents for small amounts, and hoping that people will just pay,
rather than go through the hassle of fighting back.

Btw, this is paraphrasing from either the first of the four links
posted earlier, or from the "Read More" (or something like that) link
within that article (or both).

If I were to get the letter, for my app that has NO billing of any kind
(or my next app, which will use the regular Market billing as a simple
paid app), I'd contact the CLRC (Cancer Legal Resource Center), get a
lawyer here in town who'd take the case for free (pro bono, I think is
the term) unless we win, and I'd sue them right back for trying to pull
me into a frivolous law suit.  That, or I'd get the lawyer to file for
reexamination of the patent, whichever the LAWYER said was the way to go.
No way would I even consider paying them.

And as everyone else has been clear to point out, I am not a lawyer,
nor do my comments here represent legal opinion.  However, as my
oncologists and the neurosurgeon who did my brain surgeries and, despite
my being right there, fully awake the same day[1], swore over and over
that my being awake that soon was absolutely impossible, that after a set
of surgeries as severe as mine, it was an absolute given that I'd be in a
coma for AT LEAST a month, will all verify, I am a stubborn SOB who will
NOT accept being attacked without fighting back twice as hard as my
attacker.  My former cancer, if it still existed, would also "agree" (you
know what I mean).  When I was diagnosed (26Jan2006), my soon-to-be
oncologist gave me a 50% chance of getting out of the hospital alive.  I
less-than-politely told him what he could do with his 50%.  He was glad
to hear me say that, and immediately raised it to 80%, and the next day,
to 100%.  IMHO, that's how we should all, collectively or individually,
fight back here, too.  But that is just my opinion.  Take it or leave it.

Later,
   --jim

[1] I also woke up during one of the three brain surgeries...but that's
another story

-- 
73 DE N5IAL (/4)| Peter da Silva:  No, try "rm -rf /"
spooky1...@gmail.com| Dave Aronson:As your life flashes before
< Running FreeBSD 7.0 > |  your eyes, in the unit of time known as an
ICBM / Hurricane:   |  ohnosecond (alt.sysadmin.recovery)
   30.44406N 86.59909W  |

Point Lobos Photography Set 1 (Photo-posters):  http://jdgapps.com

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Android and OSGi/Apache Felix

2011-07-07 Thread Jesse
My company is working on an app that will be distributed outside of the 
Android Market. We plan to preinstall our app on devices and then loan the 
devices out to customers. We really want the ability to update our app 
completely automatically, without the customer having to do anything. I can 
see two options:

1) Use a custom ROM and give our app root permissions
2) Use OSGi

Does anyone have experience using OSGi in an Android app? All of the 
discussions I've found are several years old. My main worries center around 
possible conflicts between the Android lifecycle and OSGi lifecycle. For 
example, would there be issues unloading a bundle that contained a layout 
and replacing it with a different layout? What happens if that layout is 
currently being used by an activity? I can see similar issues arising around 
Strings. Android is designed to update an application's components on app 
version changes; I just don't know if it's wise to use something like OSGi 
to bypass this process. I can see all sorts of potential for conflicts and 
memory leaks.

What I'd really like to know is if anyone has successfully used OSGi to 
update Android specific things, like layout files and strings.

Thanks for any help,
Jesse

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] What is a "binder thread"?

2011-07-07 Thread Kees Jongenburger
Hi

On Wednesday, September 29, 2010 11:32:57 PM UTC+2, Dianne Hackborn wrote:
>
> Specifically, each process has a pool of "binder threads" which sit there 
> waiting for incoming IPCs from other process.  When an IPC is dispatched to 
> your process, one of these threads comes out of the pool to process it. 
>  These may come to you directly through an IBinder you publish from a 
> Service to another process, semi-directly through calls from another process 
> to a ContentProvider you have published, or indirectly from a wide range of 
> IPCs the system does into app processes to tell it to launch an activity, 
> receive an intent, etc.
>

I have been trying to get a better understanding of how this works. Will 
every thread have it's own iocl/binder with the kernel or will there still 
be a main binder thread dispatching call to the processing threads?

Thanks
 

>
> On Wed, Sep 29, 2010 at 9:42 AM, Mark Murphy wrote:
>
>> If I understand correctly, for IPC via AIDL, the object that is
>> responding to the IPC is invoked on a binder thread. The object
>> definitely is not invoked on the main application thread.
>>
>> They may have additional uses, but that's the one I can think off of
>> the top o' my head.
>>
>> On Wed, Sep 29, 2010 at 12:37 PM, DanH  wrote:
>> > I tried Google, but the only answer I could find is "They were created
>> > by the system and they don't do any harm."  I'm not worried about them
>> > per se, but was just curious about what they actually do and why
>> > they're there.
>>
>> --
>> Mark Murphy (a Commons Guy)
>> http://commonsware.com | http://github.com/commonsguy
>> http://commonsware.com/blog | http://twitter.com/commonsguy
>>
>> Android 2.2 Programming Books: http://commonsware.com/books
>>
>> --
>> You received this message because you are subscribed to the Google
>> Groups "Android Developers" group.
>> To post to this group, send email to android-d...@googlegroups.com
>> To unsubscribe from this group, send email to
>> android-develop...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/android-developers?hl=en
>>
>
>
>
> -- 
> Dianne Hackborn
> Android framework engineer
> hac...@android.com
>
> Note: please don't send private questions to me, as I don't have time to 
> provide private support, and so won't reply to such e-mails.  All such 
> questions should be posted on public forums, where I and others can see and 
> answer them.
>
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread Jim Graham
On Thu, Jul 07, 2011 at 10:12:49AM -0700, John Coryat wrote:
> >> If I get that letter, I'll reply to them to kindly...
> 
> I did that exactly once in my life and it took two years and a lot of pain 
> and suffering (and legal bills) to get passed that one outburst. I was young 
> and foolish at the time. 
> 
> Just remember, never respond to any legal letter with anything less than 
> another legal letter.
> 
> Not heading this advice will just feed the sender with things they can put 
> in front of a judge. If you want to have fun with the legal system, then by 
> all means do so. For me, there is nothing fun about lawyers, judges or 
> judgements.
> 
> The saying "The person who legally defends themselves has a fool for a 
> client." is appropriate.
> 
> -John Coryat
> 
> -- 
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

-- 
73 DE N5IAL (/4)| Peter da Silva:  No, try "rm -rf /"
spooky1...@gmail.com| Dave Aronson:As your life flashes before
< Running FreeBSD 7.0 > |  your eyes, in the unit of time known as an
ICBM / Hurricane:   |  ohnosecond (alt.sysadmin.recovery)
   30.44406N 86.59909W  |

Point Lobos Photography Set 1 (Photo-posters):  http://jdgapps.com

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Question about the values of the Audio Buffer

2011-07-07 Thread jdarladimas
Thank you niko for your quick response.

Do you happen to know what the negative vanues mean and what does each
buffer element represent? Is it a specific audio frequency?

On Jul 7, 8:04 pm, niko20  wrote:
> No, they should be real RAW 16bit PCM values. If you aren't getting
> values that make sense at just 16 bit shorts, then you have something
> else wrong in your code. Make sure you are not casting weird or
> anything like that.
>
> -niko
>
> On Jul 7, 12:53 pm, jdarladimas  wrote:
>
>
>
>
>
>
>
> > Hello Developers,
>
> > In an application that I am developing, I am using the AudioRecord
> > class to detect sounds from the microphone.
> > The minimum Buffer Size that I am allowed to use is 4096.
>
> > So, I get the values from the microphone buffer and put them in a
> > short[] array that has the same size as the microphone buffer.
> > The range of those values are from -2^15=-32768 up to 2^15,
> > which makes sense since I am using PCM_16_ENCODING and the size of a
> > short element is 16 bits.
>
> > When I test the app, I notice that it is quiet, the buffer values tend
> > to 0.
> > On the other hand, when there is noise, both the positive and the
> > negative buffer values tend to their maximum( 32768 and -32768
> > respectively).
> > My question is what those buffer values represent...
> > Are they quantization levels or something else?? Can anybody help me?
> > It is really important..
>
> > Thank you in advance

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Mark Murphy
On Thu, Jul 7, 2011 at 3:09 PM, Raghav Sood  wrote:
> Thanks Mark. I really appreciate all the help all of you have given me so
> far. I got your books and they are a lot more straightforward than the one I
> was using so far.

BTW, I just uploaded a new round of editions, so you may want to check
and ensure you got the latest ones.

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

Android Training...At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
Thanks Mark. I really appreciate all the help all of you have given me so
far. I got your books and they are a lot more straightforward than the one I
was using so far.

I won't forget to sleep. In fact I am going to do it now. It is about 00:30
here in India.

Thanks a lot for your help.

On Fri, Jul 8, 2011 at 12:17 AM, Mark Murphy wrote:

> On Thu, Jul 7, 2011 at 2:38 PM, Raghav Sood  wrote:
> > @Mark: Where can I get your book in New Delhi, India? I can't find it at
> any
> > of the major stores and I don't have any virtual cash or credit card to
> buy
> > it online. (A small downside of being 14.)
>
> You're 14?
>
> I take back anything I ever said bad about you... :-)
>
> The books that CommonsWare publishes are not available in physical
> bookstores. You could pick up one of the _Beginning Android_ series
> from Apress, which are editions of _The Busy Coder's Guide to Android
> Development_ under a different title.
>
> But, for that, you may as well grab the free older editions off of my
> Web site -- they're about the same age as the print one and have the
> added advantage of being free.
>
> Just visit http://commonsware.com, click on any of the books, and tap
> on the "Four-to-Free Guarantee" tab mid-way down the page. There are
> several free editions of each of my books; just grab the highest
> version # one.
>
> In fact, I have another batch of those that I need to process and
> upload later today.
>
> BTW, don't forget to sleep!
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com | http://github.com/commonsguy
> http://commonsware.com/blog | http://twitter.com/commonsguy
>
> Android Training...At Your Office: http://commonsware.com/training
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Need dictionary database.

2011-07-07 Thread Justin Giles
On Thu, Jul 7, 2011 at 1:34 PM, Ali Chousein  wrote:

> Check online dictionaries to see if any of them provides a REST
> interface which would allow you to make queries. Other than that, I'm
> afraid the late Webster (and peace be upon him) is not a member of
> this group.
>
>
Ditto to this.  Also, Dictionary.com has an API that they provide to
developers.  It's free use is limited, but might fulfill your needs.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Question about the values of the Audio Buffer

2011-07-07 Thread niko20
No, they should be real RAW 16bit PCM values. If you aren't getting
values that make sense at just 16 bit shorts, then you have something
else wrong in your code. Make sure you are not casting weird or
anything like that.

-niko

On Jul 7, 12:53 pm, jdarladimas  wrote:
> Hello Developers,
>
> In an application that I am developing, I am using the AudioRecord
> class to detect sounds from the microphone.
> The minimum Buffer Size that I am allowed to use is 4096.
>
> So, I get the values from the microphone buffer and put them in a
> short[] array that has the same size as the microphone buffer.
> The range of those values are from -2^15=-32768 up to 2^15,
> which makes sense since I am using PCM_16_ENCODING and the size of a
> short element is 16 bits.
>
> When I test the app, I notice that it is quiet, the buffer values tend
> to 0.
> On the other hand, when there is noise, both the positive and the
> negative buffer values tend to their maximum( 32768 and -32768
> respectively).
> My question is what those buffer values represent...
> Are they quantization levels or something else?? Can anybody help me?
> It is really important..
>
> Thank you in advance

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Mark Murphy
On Thu, Jul 7, 2011 at 2:38 PM, Raghav Sood  wrote:
> @Mark: Where can I get your book in New Delhi, India? I can't find it at any
> of the major stores and I don't have any virtual cash or credit card to buy
> it online. (A small downside of being 14.)

You're 14?

I take back anything I ever said bad about you... :-)

The books that CommonsWare publishes are not available in physical
bookstores. You could pick up one of the _Beginning Android_ series
from Apress, which are editions of _The Busy Coder's Guide to Android
Development_ under a different title.

But, for that, you may as well grab the free older editions off of my
Web site -- they're about the same age as the print one and have the
added advantage of being free.

Just visit http://commonsware.com, click on any of the books, and tap
on the "Four-to-Free Guarantee" tab mid-way down the page. There are
several free editions of each of my books; just grab the highest
version # one.

In fact, I have another batch of those that I need to process and
upload later today.

BTW, don't forget to sleep!

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

Android Training...At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
I think I'll go with Status Bar notification. I might add a form later
asking them whether or not they have a SIM card and ship it as a custom
variable with ACRA. (Only reason I can think of for the null value is a
missing SIM card as I use the cell network for location.)

And before someone tells me that ACRA supports user dialogues. I tried
getting them to work but it didn't show up.

On Fri, Jul 8, 2011 at 12:09 AM, Kostya Vasilyev  wrote:

> **
> You can use a status bar notification, or implement some sort of callback
> (listener) that takes you back to the activity, where you can e.g. display a
> dialog:
>
> myObject.setErrorListener(new ErrorListener() {
> @Override
> public void somethingBadHappened( ) {
> // display a dialog, a toast, or call activity.finish() :)
> }
> };
>
> -- Kostya
>
> 07.07.2011 22:33, Raghav Sood пишет:
>
> I know :(. But I am at a loss as to how to notify my users that there is
> something wrong.
>
> On Thu, Jul 7, 2011 at 11:59 PM, TreKing  wrote:
>
>>  On Thu, Jul 7, 2011 at 1:24 PM, Raghav Sood wrote:
>>
>>> P.S. If I have a method in my Activity to display a toast can I safely
>>> call it from the Overlay class?
>>
>>
>>  Well, sure, with a valid reference to the Activity. But injecting a
>> dependency on the Activity into your Overlay to display a toast does not
>> seem like a great idea.
>
>
> --
> Kostya Vasilyev
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Kostya Vasilyev
You can use a status bar notification, or implement some sort of 
callback (listener) that takes you back to the activity, where you can 
e.g. display a dialog:


myObject.setErrorListener(new ErrorListener() {
@Override
public void somethingBadHappened( ) {
// display a dialog, a toast, or call activity.finish() :)
}
};

-- Kostya

07.07.2011 22:33, Raghav Sood ?:
I know :(. But I am at a loss as to how to notify my users that there 
is something wrong.


On Thu, Jul 7, 2011 at 11:59 PM, TreKing > wrote:


On Thu, Jul 7, 2011 at 1:24 PM, Raghav Sood mailto:raghavs...@gmail.com>> wrote:

P.S. If I have a method in my Activity to display a toast can
I safely call it from the Overlay class?


Well, sure, with a valid reference to the Activity. But injecting
a dependency on the Activity into your Overlay to display a toast
does not seem like a great idea.



--
Kostya Vasilyev

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
I should probably change it.

Seeing as this book has given me more errors than knowledge I think I'd get
another one. Maybe one of Mark's.

@Mark: Where can I get your book in New Delhi, India? I can't find it at any
of the major stores and I don't have any virtual cash or credit card to buy
it online. (A small downside of being 14.)

On Fri, Jul 8, 2011 at 12:02 AM, TreKing  wrote:

> On Thu, Jul 7, 2011 at 1:24 PM, Raghav Sood  wrote:
>
>> I needed a custom graphic and text on the location point and the book I
>> used said it was not possible with MyLocationOverlay.
>
>
> I like this book less and less.
>
> MyLocationOverlay is just another Overlay that handles the drawing of a
> dot, radius, and getting location updates. If you need custom drawing, then
> you can just override the draw() function, call super() to draw the default
> location and radius, and then continue doing your own drawing for the text
> and graphics.
>
> Meanwhile you get the location update logic for free.
>
>
> -
> TreKing  - Chicago
> transit tracking app for Android-powered devices
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread TreKing
On Thu, Jul 7, 2011 at 1:33 PM, Raghav Sood  wrote:

> I know :(. But I am at a loss as to how to notify my users that there is
> something wrong.


Well your overlay has access to the MapView on which it is drawing, which in
turn has a Context, which is all you really need for Toast.makeText().

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Need dictionary database.

2011-07-07 Thread Ali Chousein
Check online dictionaries to see if any of them provides a REST
interface which would allow you to make queries. Other than that, I'm
afraid the late Webster (and peace be upon him) is not a member of
this group.

--
Ali Chousein
Geo-Filtered Assistant
http://geo-filtered-assistant.blogspot.com/
Cisco Android marketplace (Chosen for Cisco Cius)
https://marketplace.cisco.com/apphq/products/510


On Jul 7, 12:46 pm, Aditya  wrote:
> Hello All,
> Am in the middle of implementing one application which includes dictionary
> feature(English).
> Can anyone help me in finding a dictionary database for my application?
>
> Thanks in Advance
> Aditya.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
I know :(. But I am at a loss as to how to notify my users that there is
something wrong.

On Thu, Jul 7, 2011 at 11:59 PM, TreKing  wrote:

> On Thu, Jul 7, 2011 at 1:24 PM, Raghav Sood  wrote:
>
>> P.S. If I have a method in my Activity to display a toast can I safely
>> call it from the Overlay class?
>
>
> Well, sure, with a valid reference to the Activity. But injecting a
> dependency on the Activity into your Overlay to display a toast does not
> seem like a great idea.
>
>
>
> -
> TreKing  - Chicago
> transit tracking app for Android-powered devices
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread TreKing
On Thu, Jul 7, 2011 at 1:24 PM, Raghav Sood  wrote:

> I needed a custom graphic and text on the location point and the book I
> used said it was not possible with MyLocationOverlay.


I like this book less and less.

MyLocationOverlay is just another Overlay that handles the drawing of a dot,
radius, and getting location updates. If you need custom drawing, then you
can just override the draw() function, call super() to draw the default
location and radius, and then continue doing your own drawing for the text
and graphics.

Meanwhile you get the location update logic for free.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: App not visible from Android Market on the device

2011-07-07 Thread Manuel R. Ciosici
All of a sudden the app is visible again, I haven't received any reply
from Google though...

Manuel

On Jul 7, 3:01 pm, "Manuel R. Ciosici" 
wrote:
> @TreKing
> Thank you for the reply. Interesting read, but doesn't apply in my
> case.
>
> In the meantime also sent an email to Android market support, maybe
> they have a explanation.
>
> Manuel
>
> On Jul 7, 2:45 pm, TreKing  wrote:
>
>
>
>
>
>
>
> >http://www.google.com/support/androidmarket/developer/bin/static.py?p...
>
> > See "Can't Find App" (and "Applications Missing From Android Market" -
> > though not exactly your use case). These reeks of another Android Market
> > Screw Up™
>
> > --- 
> > --
> > TreKing  - Chicago
> > transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread TreKing
On Thu, Jul 7, 2011 at 1:24 PM, Raghav Sood  wrote:

> P.S. If I have a method in my Activity to display a toast can I safely call
> it from the Overlay class?


Well, sure, with a valid reference to the Activity. But injecting a
dependency on the Activity into your Overlay to display a toast does not
seem like a great idea.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
I needed a custom graphic and text on the location point and the book I used
said it was not possible with MyLocationOverlay. Also later on I plan on
adding a few more things that would not work with MyLocationOverlay.

Thanks

P.S. If I have a method in my Activity to display a toast can I safely call
it from the Overlay class?

On Thu, Jul 7, 2011 at 11:48 PM, TreKing  wrote:

> On Thu, Jul 7, 2011 at 1:11 PM, Raghav Sood  wrote:
>
>> Okay. Maybe I am missing something here but AFAIK the if statement check
>> to see that location is not equal to null and if that is true (location not
>> being null)
>> it passes it on to the Overlay.
>>
>> Did I get that right?
>>
>
> What I do for the user's location on the map is get their location first,
> then, when a valid location is obtained, create the marker and add it to the
> map.
>
> Sidenote: is there some reason you're not using MyLocationOverlay?
>
>
>
> -
> TreKing  - Chicago
> transit tracking app for Android-powered devices
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
Right. Got it now.

Basically I need to check location for null twice. Once in the Activity and
once in the Overlay.

Thanks

On Thu, Jul 7, 2011 at 11:44 PM, TreKing  wrote:

> On Thu, Jul 7, 2011 at 1:00 PM, Raghav Sood  wrote:
>
>> But the thing is location can't be null.
>
>
> It can and it is.
>
>
>> If it was the app wouldn't have reached here.
>
>
> Correct. But this is not where the crash is.
>
>
>> I check for location being null in my main activity:
>>
>> if (location != null) {
>>
>>  // Update my location marker
>>
>> positionOverlay.setLocation(location);
>>
>>
>> Only the does MyPositionOverlay receive location.
>>
>
> Precisely - only there does it receive location - otherwise it remains null
> (the default for an object) and you don't check for null in your draw()
> call. Thus, unless you set a valid Location object in your main activity,
> your internal location will remain null and you will crash and burn as you
> have already seen when your position overlay goes to draw.
>
>
> -
> TreKing  - Chicago
> transit tracking app for Android-powered devices
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread TreKing
On Thu, Jul 7, 2011 at 1:11 PM, Raghav Sood  wrote:

> Okay. Maybe I am missing something here but AFAIK the if statement check to
> see that location is not equal to null and if that is true (location not
> being null)
> it passes it on to the Overlay.
>
> Did I get that right?
>

What I do for the user's location on the map is get their location first,
then, when a valid location is obtained, create the marker and add it to the
map.

Sidenote: is there some reason you're not using MyLocationOverlay?

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread TreKing
On Thu, Jul 7, 2011 at 1:00 PM, Raghav Sood  wrote:

> But the thing is location can't be null.


It can and it is.


> If it was the app wouldn't have reached here.


Correct. But this is not where the crash is.


> I check for location being null in my main activity:
>
> if (location != null) {
>
>  // Update my location marker
>
> positionOverlay.setLocation(location);
>
>
> Only the does MyPositionOverlay receive location.
>

Precisely - only there does it receive location - otherwise it remains null
(the default for an object) and you don't check for null in your draw()
call. Thus, unless you set a valid Location object in your main activity,
your internal location will remain null and you will crash and burn as you
have already seen when your position overlay goes to draw.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: how to typecast String data to Object data type java/Android

2011-07-07 Thread Radeg


On 7 июл, 21:13, naveen kumar  wrote:
> String epdata="sdfsad";
> Object epArry=  (Object) epdata;
>
> facing issues plz help me

public final class String extends Object implements ...
javadoc just for knowledge

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
Okay. Maybe I am missing something here but AFAIK the if statement check to
see that location is not equal to null and if that is true (location not
being null)
it passes it on to the Overlay.

Did I get that right?

On Thu, Jul 7, 2011 at 11:36 PM, Mark Murphy wrote:

> On Thu, Jul 7, 2011 at 2:00 PM, Raghav Sood  wrote:
> > But the thing is location can't be null. If it was the app wouldn't have
> > reached here. I check for location being null in my main activity:
> >
> > if (location != null) {
> >
> >  // Update my location marker
> >
> > positionOverlay.setLocation(location);
> >
> > Only the does MyPositionOverlay receive location.
>
> As I indicated in your previous thread, if you try to use the overlay
> and YOU HAVE NOT RECEIVED A LOCATION YET (caps to ensure you pay
> attention), your location variable will be null simply because you
> haven't ever had any valid Location to use.
>
> So, as I wrote before, you either need to not set up the overlay until
> you actually have a Location, or you need to have more smarts in the
> overlay to deal with the null location case.
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com | http://github.com/commonsguy
> http://commonsware.com/blog | http://twitter.com/commonsguy
>
> Android Training...At Your Office: http://commonsware.com/training
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Re: Installing APK + DB

2011-07-07 Thread Kostya Vasilyev

Hector,

What I was hinting at (sorry if I was being too oblique) is that:

1 - There is a bug in your code when the activity gets recreated for 
configuration changes;
2 - The most frequent case of a configuration change is the screen 
orientation change;
3 - There are other cases configuration change cases, and I provided the 
steps for one of them;
4 - Rather than putting lipstick over the bug with your manifest change, 
treat it as an opportunity to easily find and fix the bug;
5 - Once that's done, and your code survives an orientation change, add 
back the manifest changes as an optimization, if needed.


-- Kostya

07.07.2011 20:31, hectordu...@yahoo.com пишет:

"your application is still likely crash if you leave it
by pressing Home, change the phone's language in Settings, and return
to
the app (via launcher icon or recent app list)..."


YEAH !
it is still crashing but i don't know exactly when :-(
but ot works fine by pressing HOME, or returning to the app via the
icon.

it sounds rare but is there a light sensor some where in the phone?


On Jul 6, 12:11 pm, "hectordu...@yahoo.com"
wrote:

no kostya,
by the moment it thasn't crash for that ...
know i am geting conflicts with single and double click on a
button .. :-(
it looks like when i make a double click also tryes to execute some
associates methods to single click ...
plase help  :-)
hector

On Jul 5, 1:33 pm, Kostya Vasilyev  wrote:


That's good, but your application is still likely crash if you leave it
by pressing Home, change the phone's language in Settings, and return to
the app (via launcher icon or recent app list)...
05.07.2011 22:13, hectordu...@yahoo.com пишет:

about the screen orientation, i have included this line in the
manfest:
android:configChanges="orientation|keyboardHidden"
... works:-)

--
Kostya Vasilyev


--
Kostya Vasilyev

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Mark Murphy
On Thu, Jul 7, 2011 at 2:00 PM, Raghav Sood  wrote:
> But the thing is location can't be null. If it was the app wouldn't have
> reached here. I check for location being null in my main activity:
>
> if (location != null) {
>
>          // Update my location marker
>
>         positionOverlay.setLocation(location);
>
> Only the does MyPositionOverlay receive location.

As I indicated in your previous thread, if you try to use the overlay
and YOU HAVE NOT RECEIVED A LOCATION YET (caps to ensure you pay
attention), your location variable will be null simply because you
haven't ever had any valid Location to use.

So, as I wrote before, you either need to not set up the overlay until
you actually have a Location, or you need to have more smarts in the
overlay to deal with the null location case.

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

Android Training...At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Re: NullPointerException when checking for orientation

2011-07-07 Thread Kostya Vasilyev
A complex expression like this can cause a bit of confusion with line 
numbers.


You can watch it in the debugger, while single-stepping, the current 
line can jump down and up. I suppose it's the same with getting the 
stack trace.


To pinpoint what's going on, rewrite this section of code to use local 
temporary objects, something along these lines:


if((ViewByRoom.controls&  CAN_DISPLAY_QUEUE) == CAN_DISPLAY_QUEUE) {
{
Activity activity = getActivity();
View view = activity.findViewById(R.id.queueframe);
if (view == null) {
// old code here
}
}

-- Kostya

07.07.2011 21:28, Kim пишет:

Is it possible that the exception is actually caused by the
getActivity(), even though the LogCat is pointing to the .findViewByID
line?



--
Kostya Vasilyev

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
But the thing is location can't be null. If it was the app wouldn't have
reached here. I check for location being null in my main activity:

if (location != null) {

 // Update my location marker

positionOverlay.setLocation(location);


Only the does MyPositionOverlay receive location.


On Thu, Jul 7, 2011 at 11:23 PM, TreKing  wrote:

> On Thu, Jul 7, 2011 at 12:45 PM, Raghav Sood  wrote:
>
>> Double latitude = location.getLatitude()*1E6;
>>
>>
>> It is a NullPointerException so I suppose it is returning null.
>>
>
> NullPointerExceptions are cause by *objects* that are set to null. The only
> *object* in that statement is "location". Thus, that's what is null.
>
> You can verify this by using your debugger and breaking at that line.
>
> I'd recommend you brush up on Java and the different between Object types
> and Value types to understand the differences between the two.
>
>
> -
> TreKing  - Chicago
> transit tracking app for Android-powered devices
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread TreKing
On Thu, Jul 7, 2011 at 12:45 PM, Raghav Sood  wrote:

> Double latitude = location.getLatitude()*1E6;
>
>
> It is a NullPointerException so I suppose it is returning null.
>

NullPointerExceptions are cause by *objects* that are set to null. The only
*object* in that statement is "location". Thus, that's what is null.

You can verify this by using your debugger and breaking at that line.

I'd recommend you brush up on Java and the different between Object types
and Value types to understand the differences between the two.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Question about the values of the Audio Buffer

2011-07-07 Thread jdarladimas
Hello Developers,

In an application that I am developing, I am using the AudioRecord
class to detect sounds from the microphone.
The minimum Buffer Size that I am allowed to use is 4096.

So, I get the values from the microphone buffer and put them in a
short[] array that has the same size as the microphone buffer.
The range of those values are from -2^15=-32768 up to 2^15,
which makes sense since I am using PCM_16_ENCODING and the size of a
short element is 16 bits.

When I test the app, I notice that it is quiet, the buffer values tend
to 0.
On the other hand, when there is noise, both the positive and the
negative buffer values tend to their maximum( 32768 and -32768
respectively).
My question is what those buffer values represent...
Are they quantization levels or something else?? Can anybody help me?
It is really important..

Thank you in advance

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Mark Murphy
Your location variable is null.

On Thu, Jul 7, 2011 at 1:45 PM, Raghav Sood  wrote:
> Double latitude = location.getLatitude()*1E6;
>
> It is a NullPointerException so I suppose it is returning null.

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

Android Training...At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
TreKing I had this in a previous thread to but that problem was fixed. This
is another one causing the same error/

java.lang.NullPointerException
at com.raghavsood.findme.MyPositionOverlay.draw(MyPositionOverlay.java:37)
at com.google.android.maps.Overlay.draw(Overlay.java:179)
at com.google.android.maps.OverlayBundle.draw(OverlayBundle.java:45)
at com.google.android.maps.MapView.onDraw(MapView.java:494)
at android.view.View.draw(View.java:6740)
at android.view.ViewGroup.drawChild(ViewGroup.java:1640)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1367)
at android.view.ViewGroup.drawChild(ViewGroup.java:1638)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1367)
at android.view.View.draw(View.java:6743)
at android.widget.FrameLayout.draw(FrameLayout.java:352)
at android.view.ViewGroup.drawChild(ViewGroup.java:1640)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1367)
at android.view.ViewGroup.drawChild(ViewGroup.java:1638)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1367)
at android.view.View.draw(View.java:6743)
at android.widget.FrameLayout.draw(FrameLayout.java:352)
at
com.android.internal.policy.impl.PhoneWindow$DecorView.draw(PhoneWindow.java:1847)
at android.view.ViewRoot.draw(ViewRoot.java:1407)
at android.view.ViewRoot.performTraversals(ViewRoot.java:1163)
at android.view.ViewRoot.handleMessage(ViewRoot.java:1727)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:123)
at android.app.ActivityThread.main(ActivityThread.java:4627)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:521)
at
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
at dalvik.system.NativeStart.main(Native Method)

And MyPositionOverlay.java:37 is:

Double latitude = location.getLatitude()*1E6;


It is a NullPointerException so I suppose it is returning null.
On Thu, Jul 7, 2011 at 11:10 PM, TreKing  wrote:

> On Thu, Jul 7, 2011 at 12:38 PM, Raghav Sood  wrote:
>
>> I am trying to guard against them being null.
>
> I am getting error reports from users via ACRA that these are returning
>> null sometimes.
>
>
> That's not possible. Double-check your logs and what variable they point
> to. The Location object may be null, but it's double type variables cannot.
>
>
> -
> TreKing  - Chicago
> transit tracking app for Android-powered devices
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread TreKing
On Thu, Jul 7, 2011 at 12:38 PM, Raghav Sood  wrote:

> I am trying to guard against them being null.

I am getting error reports from users via ACRA that these are returning null
> sometimes.


That's not possible. Double-check your logs and what variable they point to.
The Location object may be null, but it's double type variables cannot.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
I am trying to guard against them being null. I am getting error reports
from users via ACRA that these are returning null sometimes. Hence the
safeguard.

On Thu, Jul 7, 2011 at 11:05 PM, TreKing  wrote:

> On Thu, Jul 7, 2011 at 12:22 PM, Raghav Sood  wrote:
>
>> I am getting an error that I can not compare these values as they are
>> Doubles in nature and null is not valid here with ||. How can I compare
>> these?
>
>
> As the error indicates, they are not object that are comparable to null.
> They are guaranteed to have *some* value. What are you trying to guard
> against?
>
>
> -
> TreKing  - Chicago
> transit tracking app for Android-powered devices
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en




-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread TreKing
On Thu, Jul 7, 2011 at 12:22 PM, Raghav Sood  wrote:

> I am getting an error that I can not compare these values as they are
> Doubles in nature and null is not valid here with ||. How can I compare
> these?


As the error indicates, they are not object that are comparable to null.
They are guaranteed to have *some* value. What are you trying to guard
against?

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] how to typecast String data to Object data type java/Android

2011-07-07 Thread TreKing
On Thu, Jul 7, 2011 at 12:13 PM, naveen kumar
wrote:

> String epdata="sdfsad";
> Object epArry=  (Object) epdata;
>

This is a basic Java questions and has nothing to do with Android
development.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: NullPointerException when checking for orientation

2011-07-07 Thread Kim
Is it possible that the exception is actually caused by the
getActivity(), even though the LogCat is pointing to the .findViewByID
line?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Comparing getLatitude() and getLongitude() to null

2011-07-07 Thread Raghav Sood
Hi all,

In my app I have to compare getLatitude() and getLongitude() with null in an
if statement to check, well, if they are null.

My statement looks like this:

 if (location.getLatitude() != null || location.getLongitude() != null)

location is a Location variable. I am getting an error that I can not
compare these values as they are Doubles in nature and null is not valid
here with ||. How can I compare these?

Thanks
-- 
Raghav Sood
http://www.raghavsood.com/
http://wiki.androidappcheck.com/
http://www.telstop.tel/
https://market.android.com/developer?pub=Raghav+Sood

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread Miguel Morales
So, I have to find somebody to find a nice, legal way to say 'suck my
balls, your patent doesn't apply to my app?'  Ok.
Sorry, but I'm not going to let these suit retards try to get any
money from me.
Then again, I live in a shitty apartment and the most expensive thing
I own is my do, I ride my bike to places, and I buy everything with
cash.
I don't give two shits if they want to try and sue me.  Good luck
trying to find me physically.  I'll just re-register my app from my
home country of El Salvador.
I've done this with medical and towing bills and it costs them a lot
more to try to get the money from you constantly then any profit they
hoped to gain.  Eventually they gave up.
I guess if you want to be a wuss and cave in, go ahead.  But you're
further perpetuating the situation.

On Thu, Jul 7, 2011 at 10:12 AM, John Coryat  wrote:
>>> If I get that letter, I'll reply to them to kindly...
> I did that exactly once in my life and it took two years and a lot of pain
> and suffering (and legal bills) to get passed that one outburst. I was young
> and foolish at the time.
> Just remember, never respond to any legal letter with anything less than
> another legal letter.
> Not heading this advice will just feed the sender with things they can put
> in front of a judge. If you want to have fun with the legal system, then by
> all means do so. For me, there is nothing fun about lawyers, judges or
> judgements.
>
> The saying "The person who legally defends themselves has a fool for a
> client." is appropriate.
>
> -John Coryat
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en



-- 
~ Jeremiah:9:23-24
Android 2D MMORPG: http://solrpg.com/, http://www.youtube.com/user/revoltingx

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread John Coryat
>> We received the letter today.

Can you detail what Lodsys is demanding of you? 

-John Coryat

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] NullPointerException when checking for orientation

2011-07-07 Thread Kim
I am using the recommended method to check orientation when using
frames in 3.0 or higher:

if(((ViewByRoom.controls & CAN_DISPLAY_QUEUE) == CAN_DISPLAY_QUEUE)
&& getActivity()
.findViewById(R.id.queueframe)==null) {

but sometimes I get a nullpointer exception on the line with
".findViewById(R.id.queueframe) = null" in it.
I put it in a separate line from the getActivity() to make sure the
exception was referring to that line.

This code is in one fragment and is checking to see if the other
fragment exists (is in portrait mode).
Shouldn't that line just return false (causing the if statement to
fail)? it does work most of the time, only occasionally giving the
exception when I change orientation.

Kim

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] how to typecast String data to Object data type java/Android

2011-07-07 Thread naveen kumar
String epdata="sdfsad";
Object epArry=  (Object) epdata;

facing issues plz help me

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] ftdio_sio stop receive bytes on pandaboard

2011-07-07 Thread Mark Murphy
Visit http://source.android.com and click on the Community tab to find
a suitable group for your question.

On Thu, Jul 7, 2011 at 12:35 PM, dani maoz  wrote:
> Hi
> I have connected usb to serial dongle to pandaboard.
> I wrote an application which open ttyUSB0 port and print the information to
> the screen,
> after a while it stop receiving data, in order to solve the problem i have
> to reopen the port,
> i used usbmon tool and saw that after a while it stop polling the bulk
> endpoint, (this is the reason i stop receiving data)
> How can i solve this issue ( i tried to disable usb suspend but it didn't
> help)
> Regards,
> Dani
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en



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

Android Training...At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread John Coryat
>> If I get that letter, I'll reply to them to kindly...

I did that exactly once in my life and it took two years and a lot of pain 
and suffering (and legal bills) to get passed that one outburst. I was young 
and foolish at the time. 

Just remember, never respond to any legal letter with anything less than 
another legal letter.

Not heading this advice will just feed the sender with things they can put 
in front of a judge. If you want to have fun with the legal system, then by 
all means do so. For me, there is nothing fun about lawyers, judges or 
judgements.

The saying "The person who legally defends themselves has a fool for a 
client." is appropriate.

-John Coryat

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: [android-developers] EventQueue.peekMessage

2011-07-07 Thread Jeffrey Brown
You can use a Canvas to draw an image into a Bitmap on a background
thread.  Then when that's finished, draw the Bitmap into the View (in
onDraw) on the main thread.

I'd be worried about a drawing function that takes several seconds to
run.  We like to keep drawing well under 16ms in order to ensure a
good framerate and smooth animations.

Jeff.

On Thu, Jul 7, 2011 at 9:53 AM, andrei-dmitriev
 wrote:
> The longRoutine is the drawing procedure which may take up to several
> seconds.
>
> Yep, I tried to relay that onto another thread and draw into the SurfaceView
> but the problem I've faced is that
> the original view(s) are still repainted with onDraw() thus the content (the
> background thread is rendering all the time) is missing. It's called from
> the deep android internals so I don't believe I trigger it somehow - it's
> just a reaction on the invalidate().
> Well, it is covered with blank rectangle but I can see the actual content
> under that rectangle.
> BTW that looks like a thread condition over there as sometimes (very rarely)
> I can see the content for a few moments which then becomes covered with
> background color.
>
> So far I also tried to:
> a) setWillNotDraw(true);
> b) unset the background color of the view
>
> Interestingly that in a sample application (a SurfaceView in a RelativeView)
> the b) approach does help and since that we don't have such a problem there.
>
> So the problem now could be read like this (I'm starting to think there is
> no way to peek events from the queue, right? :) :
> How to switch the SurfaceView's onDraw() method off?
> Any cluea of what can make it been called also appreciated.
>
> Thanks,
> Andrei
>
>
> 07.07.2011 17:18, Mark Murphy пишет:
>>
>> On Thu, Jul 7, 2011 at 9:11 AM, andrei-dmitriev
>>   wrote:
>>>
>>> why there is no a way to poll or peek the message from the event queue?
>>> I want it to implement the break for the routine running on the UI
>>> thread.
>>> private void longRoutine() {
>>>    while (flag){
>>>        if (queue.peekMessage() != null) {
>>>            return;
>>>        }
>>> 
>>>    }
>>> }
>>>
>>> Or am I missing something and actually a way exists?
>>
>> It's called a "background thread". All the cool programmers use them.
>>
>> Why do you think that you need longRoutine() to be on the main
>> application thread?
>>
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] EventQueue.peekMessage

2011-07-07 Thread andrei-dmitriev
The longRoutine is the drawing procedure which may take up to several 
seconds.


Yep, I tried to relay that onto another thread and draw into the 
SurfaceView but the problem I've faced is that
the original view(s) are still repainted with onDraw() thus the content 
(the background thread is rendering all the time) is missing. It's 
called from the deep android internals so I don't believe I trigger it 
somehow - it's

just a reaction on the invalidate().
Well, it is covered with blank rectangle but I can see the actual 
content under that rectangle.
BTW that looks like a thread condition over there as sometimes (very 
rarely) I can see the content for a few moments which then becomes 
covered with background color.


So far I also tried to:
a) setWillNotDraw(true);
b) unset the background color of the view

Interestingly that in a sample application (a SurfaceView in a 
RelativeView) the b) approach does help and since that we don't have 
such a problem there.


So the problem now could be read like this (I'm starting to think there 
is no way to peek events from the queue, right? :) :

How to switch the SurfaceView's onDraw() method off?
Any cluea of what can make it been called also appreciated.

Thanks,
Andrei


07.07.2011 17:18, Mark Murphy пишет:

On Thu, Jul 7, 2011 at 9:11 AM, andrei-dmitriev
  wrote:

why there is no a way to poll or peek the message from the event queue?
I want it to implement the break for the routine running on the UI thread.
private void longRoutine() {
while (flag){
if (queue.peekMessage() != null) {
return;
}

}
}

Or am I missing something and actually a way exists?

It's called a "background thread". All the cool programmers use them.

Why do you think that you need longRoutine() to be on the main
application thread?



--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: Android Charting dll for plotting Graphs

2011-07-07 Thread MartyMoose
I have used TeeCharts for Windows for a number of years.  I'm porting
some of my applications to Android so I am evaluating TeeCharts for
Android.  I'm hoping it will make porting a bit easier.

http://www.steema.com/entry/63/h4/TeeChart_Java_for_Android_now_available



Marty

On Jul 7, 8:20 am, "s.rawat"  wrote:
> Thanks Fred, very well said
> Rgds,
> -Saurabh
> "..pain is temporary.quitting lasts forever.."
>
> On Wed, Jul 6, 2011 at 8:59 PM, Fred Niggle wrote:
>
>
>
>
>
>
>
> > Hello.
>
> > Try to drop the windows mindset when coding for android, in Linux
> > there is no such thing as a dll (as for as I know).
>
> > There are API's for creating graphs:
> >http://android.arnodenhond.com/components/graphview
> > andhttp://androidplot.com/wiki/Home
>
> > are just two I found with a very quick google search...
>
> > Hope this helps,
> > Fred
>
> > On 06/07/2011, s.rawat  wrote:
> > > yeah Mark even less than 10 secs..Thanks..
> > > I will use it nd post the code once done..
> > > Rgds,
> > > Saurabh
> > > "..pain is temporary.quitting lasts forever.."
>
> > > On Tue, Jul 5, 2011 at 6:56 PM, Mark Murphy 
> > wrote:
>
> > >> ChartDroid
> > >> AndroidPlot
> > >> AChartEngine
>
> > >> There are probably others, but those were what showed up in the first
> > >> 10 seconds of searching on Google.
>
> > >> On Tue, Jul 5, 2011 at 9:21 AM, s.rawat 
> > wrote:
> > >> > HI All,
> > >> > is there any charting dll or library for android with the sample code
> > >> which
> > >> > can be used for plotting charts.I have used dotnetcharting dlls for
> > >> plotting
> > >> > the graphs in the C# where you can get the sampe code for different
> > >> > forms
> > >> of
> > >> > charts as well.
> > >> > Is there any such library for android wth the sample codes.
> > >> > Rgds,
> > >> > Saurabh
>
> > >> > "..pain is temporary.quitting lasts forever.."
>
> > >> > --
> > >> > You received this message because you are subscribed to the Google
> > >> > Groups "Android Developers" group.
> > >> > To post to this group, send email to
> > android-developers@googlegroups.com
> > >> > To unsubscribe from this group, send email to
> > >> > android-developers+unsubscr...@googlegroups.com
> > >> > For more options, visit this group at
> > >> >http://groups.google.com/group/android-developers?hl=en
>
> > >> --
> > >> Mark Murphy (a Commons Guy)
> > >>http://commonsware.com|http://github.com/commonsguy
> > >>http://commonsware.com/blog|http://twitter.com/commonsguy
>
> > >> _The Busy Coder's Guide to Android Development_ Version 3.6 Available!
>
> > >> --
> > >> You received this message because you are subscribed to the Google
> > >> Groups "Android Developers" group.
> > >> To post to this group, send email to
> > android-developers@googlegroups.com
> > >> To unsubscribe from this group, send email to
> > >> android-developers+unsubscr...@googlegroups.com
> > >> For more options, visit this group at
> > >>http://groups.google.com/group/android-developers?hl=en
>
> > > --
> > > You received this message because you are subscribed to the Google
> > > Groups "Android Developers" group.
> > > To post to this group, send email to android-developers@googlegroups.com
> > > To unsubscribe from this group, send email to
> > > android-developers+unsubscr...@googlegroups.com
> > > For more options, visit this group at
> > >http://groups.google.com/group/android-developers?hl=en
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to android-developers@googlegroups.com
> > To unsubscribe from this group, send email to
> > android-developers+unsubscr...@googlegroups.com
> > For more options, visit this group at
> >http://groups.google.com/group/android-developers?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] ftdio_sio stop receive bytes on pandaboard

2011-07-07 Thread dani maoz
Hi
I have connected usb to serial dongle to pandaboard.
I wrote an application which open ttyUSB0 port and print the information to
the screen,
after a while it stop receiving data, in order to solve the problem i have
to reopen the port,
i used usbmon tool and saw that after a while it stop polling the bulk
endpoint, (this is the reason i stop receiving data)
How can i solve this issue ( i tried to disable usb suspend but it didn't
help)
Regards,
Dani

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Installing APK + DB

2011-07-07 Thread hectordu...@yahoo.com
"your application is still likely crash if you leave it
by pressing Home, change the phone's language in Settings, and return
to
the app (via launcher icon or recent app list)..."


YEAH !
it is still crashing but i don't know exactly when :-(
but ot works fine by pressing HOME, or returning to the app via the
icon.

it sounds rare but is there a light sensor some where in the phone?


On Jul 6, 12:11 pm, "hectordu...@yahoo.com" 
wrote:
> no kostya,
> by the moment it thasn't crash for that ...
> know i am geting conflicts with single and double click on a
> button .. :-(
> it looks like when i make a double click also tryes to execute some
> associates methods to single click ...
> plase help  :-)
> hector
>
> On Jul 5, 1:33 pm, Kostya Vasilyev  wrote:
>
> > That's good, but your application is still likely crash if you leave it
> > by pressing Home, change the phone's language in Settings, and return to
> > the app (via launcher icon or recent app list)...
>
> > 05.07.2011 22:13, hectordu...@yahoo.com пишет:
>
> > > about the screen orientation, i have included this line in the
> > > manfest:
> > > android:configChanges="orientation|keyboardHidden"
>
> > > ... works:-)
>
> > --
> > Kostya Vasilyev

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] rounded corner // Shape Drawable (via xml) vs. PNG

2011-07-07 Thread Mark Murphy
On Thu, Jul 7, 2011 at 11:58 AM, Ralph Bergmann  wrote:
> My question: Why he/she recommends a shape drawable xml file and not a
> png file (9-patch)? Why is a shape drawable better?

A ShapeDrawable is neither better nor worse than a nine-patch PNG, any
more than a hammer is better or worse than a wrench. They are two
tools that can be used in the same places sometimes.

ShapeDrawable is great for simple shapes when the developer is not a
Photoshop expert. ShapeDrawable is excellent for resizeable simple
shapes with gradient fills, for which a nine-patch PNG is unsuitable.

A nine-patch PNG has far richer possibilities, as you are not limited
to the handful of elements and attributes of the ShapeDrawable XML
syntax.

Use whichever you like.

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

Android Training...At Your Office: http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread John Coryat
>> I read yesterday it wasn't 6%, its 0.575%

>From what I understand from that link, that's what they are CURRENTLY 
receiving from Apple, not what they want from us as developers.

Does anyone who received "THE LETTER" have any detail as to what Lodsys is 
demanding?

-John Coryat

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] rounded corner // Shape Drawable (via xml) vs. PNG

2011-07-07 Thread Ralph Bergmann
Hi,


On stackoverflow I found a question about creating a rounded corner graphic.

http://stackoverflow.com/questions/1683185/android-listview-with-rounded-corners

The solution was to create a shape drawable via xml file.

My question: Why he/she recommends a shape drawable xml file and not a
png file (9-patch)? Why is a shape drawable better?



Ralph

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


[android-developers] Re: DexFile Error meaning

2011-07-07 Thread droidGUI
in any case, this is my on Create, when my code crash...

/* (non-Javadoc)
 * @see android.app.Activity#onCreate(android.os.Bundle)
 */
@Override
protected void onCreate(Bundle savedInstanceState) {
// TODO Auto-generated method stub
super.onCreate(savedInstanceState);
Log.i(TAG, "*** Creating MixDroid
***");
setContentView(R.layout.start_activity);
boolean b = NetworkConnection.isOnline(this);
setSharedPreferences(b, false, true, null, null);

Log.w(TAG, getIntent().getExtras()==null?"Running for first
time, no SharedPreferences setted, using default values":
"Have an saved state, checking SharedPreferences...");

if(getIntent().getExtras()==null){
boolean connected = sharedPreferences.getBoolean(ONLINE,
false);
boolean firstTime =
sharedPreferences.getBoolean(FIRST_TIME_USE, true);

if(!connected){
NetworkConnection.startNetworkAlertDialog(this);
}
if(firstTime){
MixDroidUtils.startErrorAlertDialog(this,
MixDroidUtils.RUNNING_FIRST_TIME);
}
}

//set layout
Log.d(TAG, "Setting list adapter");
ButtonsAdapter adapter = new ButtonsAdapter(this,
Order.generateOrders(Order.TYPE_BUTTON, 5));
Log.d(TAG, "putting adapter on list adapter");
setListAdapter(adapter);
}

On Jul 7, 12:25 pm, droidGUI  wrote:
> Strange... now works :)
>
> I tried delete my emulator images once (yesterday), to verify if
> was problem in Debugger machine but not worked...
>
> I tried again (deleted ALL Emulators images) and create
> one new, and now my Launcher Activity works how expected...
> (The DexFile Exception ocurred only when i tried debug my App)...
>
> One Idea about this?
>
> On Jul 7, 12:02 pm, Streets Of Boston  wrote:
>
>
>
>
>
>
>
> > Can't say much without seeing the code of your StartActivity.
> > Do you link to a library (JAR)? Maybe this JAR refers to the
> > ProtectionDomain class of another java-implementation that's not quite
> > compatible with the Android SDK's one.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread Chris
I read yesterday it wasn't 6%, its 0.575% which, principle aside, is a 
paltry amount.  Here's one reference: 
http://9to5mac.com/2011/05/16/lodsys-were-not-patent-trolls-heres-why-were-entitled-to-royalties-over-in-app-purchasing/
 
- I think there's more info at Groklaw about exactly what they're asking.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: DexFile Error meaning

2011-07-07 Thread droidGUI
Strange... now works :)

I tried delete my emulator images once (yesterday), to verify if
was problem in Debugger machine but not worked...

I tried again (deleted ALL Emulators images) and create
one new, and now my Launcher Activity works how expected...
(The DexFile Exception ocurred only when i tried debug my App)...

One Idea about this?

On Jul 7, 12:02 pm, Streets Of Boston  wrote:
> Can't say much without seeing the code of your StartActivity.
> Do you link to a library (JAR)? Maybe this JAR refers to the
> ProtectionDomain class of another java-implementation that's not quite
> compatible with the Android SDK's one.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread String
I'm curious too, where are you getting the 6% figure?

BTW: We have no way of knowing that "Google has the same license Apple has." 
All we know is that Google and Apple each obtained *a* license from 
Intellectual Ventures. It may be a reasonable assumption that the licenses 
have similar terms, but it's by no means definite. Those of us posting on 
this forum don't really know anything about the details of *either* license.

String 

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread John Coryat
>> Question is: Are you ready to spend time and money battling over %6 of US 
sales?

Is this what Lodsys is asking for?

-John Coryat

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Re: RE: [android-developers] Re: Patent Infringement notice by Lodsys.

2011-07-07 Thread JAlexoid (Aleksandr Panzin)
Question is: Are you ready to spend time and money battling over %6 of US 
sales? I don't expect that you live in Texas.
And Apple hasn't really stepped in more than Google has, don't be fooled by 
that letter.

BTW: Google has the same license Apple has. They both acquired the license 
from Intellectual Ventures.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: DexFile Error meaning

2011-07-07 Thread Streets Of Boston
Can't say much without seeing the code of your StartActivity.
Do you link to a library (JAR)? Maybe this JAR refers to the 
ProtectionDomain class of another java-implementation that's not quite 
compatible with the Android SDK's one.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] DexFile Error meaning

2011-07-07 Thread Guilherme Lunhani
Hi,

In a project that i'm working, in some point of development
i found this Exception in DexFile.class, before the application
running my Laucher Activity...

I go to Google and search some
articlesthat
help search
the error in source
code,
but none of lit my doubts about where
my/debugging error comes: what's the meaning of the Exception
in DexFile.class/DexFile.java?

This is my error trace:

Thread [<3> main] (Class load: gml.android.mixdroid.MixDroidUtils)
dalvik.system.DexFile.defineClass(java.lang.String,
java.lang.ClassLoader, int, java.security.ProtectionDomain) line: not
available [native method]
dalvik.system.DexFile.loadClassBinaryName(java.lang.String,
java.lang.ClassLoader) line: 209
dalvik.system.PathClassLoader.findClass(java.lang.String) line: 203

dalvik.system.PathClassLoader(java.lang.ClassLoader).loadClass(java.lang.String,
boolean) line: 573

dalvik.system.PathClassLoader(java.lang.ClassLoader).loadClass(java.lang.String)
line: 532
*gml.android.mixdroid.StartActivity.onCreate(android.os.Bundle) line: 89
*// this is my Laucnher
android.app.Instrumentation.callActivityOnCreate(android.app.Activity,
android.os.Bundle) line: 1047

android.app.ActivityThread.performLaunchActivity(android.app.ActivityThread$ActivityRecord,
android.content.Intent) line: 2459

android.app.ActivityThread.handleLaunchActivity(android.app.ActivityThread$ActivityRecord,
android.content.Intent) line: 2512
android.app.ActivityThread.access$2200(android.app.ActivityThread,
android.app.ActivityThread$ActivityRecord, android.content.Intent) line:
119
android.app.ActivityThread$H.handleMessage(android.os.Message) line:
1863

android.app.ActivityThread$H(android.os.Handler).dispatchMessage(android.os.Message)
line: 99
android.os.Looper.loop() line: 123
android.app.ActivityThread.main(java.lang.String[]) line: 4363
java.lang.reflect.Method.invokeNative(java.lang.Object,
java.lang.Object[], java.lang.Class, java.lang.Class[], java.lang.Class,
int, boolean) line: not available [native method]
java.lang.reflect.Method.invoke(java.lang.Object, java.lang.Object...)
line: 521
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run() line:
860
com.android.internal.os.ZygoteInit.main(java.lang.String[]) line: 618

dalvik.system.NativeStart.main(java.lang.String[]) line: not available
[native method]

Thanks!


-- 
-- 

GUILHERME

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

  1   2   >