Re: [android-developers] How did you get into Android development

2011-05-15 Thread Knutsford Software


- Original Message - 
From: Andrew Gregory

To: android-developers@googlegroups.com
Sent: Sunday, May 15, 2011 5:08 AM
Subject: Re: [android-developers] How did you get into Android development


Apart from the obvious of starting your own app from scratch, you could try 
searching for an open source Android project and fix some bugs or add a 
feature.

Andrew




Hmm - I fancy that idea as I can't think of one of my own at the moment - 
where would I find 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: [android-developers] How did you get into Android development

2011-05-15 Thread Raghav Sood
Search for Android on google code.

On Sun, May 15, 2011 at 12:37 PM, Knutsford Software <
i...@knutsford-software.co.uk> wrote:

>
> - Original Message - From: Andrew Gregory
>
> To: android-developers@googlegroups.com
> Sent: Sunday, May 15, 2011 5:08 AM
>
> Subject: Re: [android-developers] How did you get into Android development
>
>
> Apart from the obvious of starting your own app from scratch, you could try
> searching for an open source Android project and fix some bugs or add a
> feature.
> Andrew
>
>
>
>
> Hmm - I fancy that idea as I can't think of one of my own at the moment -
> where would I find 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
>



-- 
Raghav Sood
http://www.raghavsood.com/
http://www.androidappcheck.com/
http://www.telstop.tel/

-- 
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] Payout problem on the Android Market?

2011-05-15 Thread Zsolt Vasvari
I just posted this on the Android Market support problem.

Suprise, suprise, Google is not paying me for all my sales:


"According to the purchase list, I had 27 purchases of my app on May
13th.  The payout received seemed low, so I checked what Google paid
me for -- and they only paid for 20 purchases.

Does anybody else see a problem with their payouts?  The last think I
want to have to do is look over every day to make sure I am getting
paid for all sales."

-- 
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 did you get into Android development

2011-05-15 Thread Knutsford Software


- Original Message - 
From: Raghav Sood 
To: android-developers@googlegroups.com 
Sent: Sunday, May 15, 2011 8:15 AM

Subject: Re: [android-developers] How did you get into Android development


Search for Android on google code. 




Ahh - I thanks I didn't know that existed

--
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] Google Maps "heat map" type overlay?

2011-05-15 Thread Boozel
Hi
I have google maps working great in my app.
I now want to put on an overlay but instead of discrete icons i want to 
overlay the map with a semi transparent heat map type layer.
Can anyone recommend a way to do this?
Thanks 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] How did you get into Android development

2011-05-15 Thread Harri Smått
On May 15, 2011, at 6:18 AM, Adam Ratana wrote:

> - have fun, experience some joy and passion for the process, it's an end in 
> itself!

I can't help from leaving a comment on this point. For me, the whole buzz 
around Android reminds me a lot of the times we had back in 90s on C64 (here in 
Finland at least). Back then, almost all of my friends had a personal 'software 
house', writing some kind of a game from their head using basic mostly. This 
time there's the Internet, making it a bit more of a 'global' thing, but I see 
many similarities. In the 90s you showcased your application to your parents 
and friends most of the time, now you have AppStore etc for wider audience.

But all the same, I've been very pleased to see how many people have gotten 
involved into software development, thanks to Android, and maybe iOS too (I 
really have no idea what's happening on that side) lately. So yeah, from what 
I've seen so far, there seem to many people, me included, who really enjoy all 
this.

--
H

-- 
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] Error Message Help

2011-05-15 Thread Big Al
I need help with my programme. I am writing the prograame in Eclipse
and it complies ok and says there are no errors, but when I run it in
the android emulator it comes up with a box that says the following
message:

Sorry!
The application Weapon List
(process com.example) has
stopped unexpectedly. Please
try again.

It has a button that says force close and that is my only option. When
I try to run the programme again it does the same thing.

Is there anyway to log or look at a log that can tell me why the
programme keeps crashing?

-- 
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 did you get into Android development

2011-05-15 Thread DanH
I got laid off with 35 years of programming experience, got hired at
1/4 the salary by a small phone app outfit, and drew the short straw
to do some Android work.

On May 13, 5:24 am, "Knutsford Software"  wrote:
> How did people on this list get from learning about Android to getting paid 
> work developing apps. In other words how did you get past the no experience 
> no work stage?

-- 
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] Error Message Help

2011-05-15 Thread Marcin Orlowski
> Is there anyway to log or look at a log that can tell me why the
> programme keeps crashing?

If it crashed check logcat for the detailed information on potential
culprit. Also it helps to run the app under control of debugger, plant some
breakpoints and try to narrow down the place it goes crazy.

PS: Check http://en.wikipedia.org/wiki/Program to find out what "programme"
refer to, because you use it incorrectly.

Regards,
Marcin Orlowski

*Tray Agenda * - keep you daily schedule handy...
*Date In Tray*  - current date at glance...
WebnetMobile on *Facebook * and
*Twitter
*

-- 
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 did you get into Android development

2011-05-15 Thread DanH
A smart hiring manager knows that programming skill is far more
important than being "up" on a specific technology.  A skilled
programmer with no Android experience will take about 2 weeks to begin
earning his keep, and a month or two to become comfortable with the
technology.  A wet-behind-the-ears type will take 6 months to become
productive (if ever), even if he has a few apps to demo.  And someone
who's "maze bright" in Android, say, will be lost if switching to
iPhone or Blackberry, but a skilled programmer will switch modes in a
few weeks.

If you know of an outfit you'd like to work for, go there and tell
them you'll work for lunch money.  Once you've demonstrated your skill
(if you have them) you can negotiate for more money.  Or, better
still, work contacts you have (even old, long-forgotten ones) --
people who know your skills.

On May 13, 8:02 am, "Knutsford Software"  wrote:
> - Original Message -
> From: Marcin Orlowski
> To: android-developers@googlegroups.com
> Sent: Friday, May 13, 2011 12:15 PM
> Subject: Re: [android-developers] How did you get into Android development
>
> On 13 May 2011 12:24, Knutsford Software 
> wrote:
>
> How did people on this list get from learning about Android to getting paid
> work developing apps. In other words how did you get past the no experience
> no work stage?
>
> You miss the point. If you are not a programmer in general sense then I
> suggest you look for other job. But if you are programmer then you got
> experience. Experience "in programming". So it's irrelevant if Android or
> anything is new platform for you or not. Or if Java or other language is
> something you do know or not. These are just tools, like hammers or drills.
> If you do not know certain type of tool then you can simply learn how to use
> it because you got experience with that type of tools like programming
> languages, software development etc.
>
> Regards,
> Marcin Orlowski
>
> I am a programmer. The point is how do you get paid Android work if you
> haven't already done some that you can show people. It is the catch 22
> situation. How have other people on the list manages to get out of 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: How did you get into Android development

2011-05-15 Thread DanH
I started with Java 1.0.x -- writing a virtual machine for it.

On May 13, 11:25 pm, Brill Pappin  wrote:
> haha, particularly since 25 years ago, hardly anyone knew java (if it was
> even released).
> I have something between 15 or 16 years of experience with java now now
> (exact numbers are fuzzy in my old age)... and I started with java 1.1 :)
> In fact i think its only about 17 years old!
>

-- 
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] GingerBread Compliance with AT&T requirements...

2011-05-15 Thread sahil gupta
Hello Android Team,

Just want to get your inputs on details about how shall i go about
studying Android (GingerBread) compliance with AT&T's device
requirements (ADAPT), if anyone has carried out this study kindly
share your experience and inputs. Any pointers on this??


Regards
Sahil Gupta

-- 
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] GingerBread Compliance with AT&T requirements...

2011-05-15 Thread sahil gupta
Hello Android Team,

Just want to get your inputs on details about how shall i go about
studying Android (GingerBread) compliance with AT&T's device
requirements (ADAPT), if anyone has carried out this study kindly
share your experience and inputs. Any pointers on this??


Regards
Sahil Gupta

-- 
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 did you get into Android development

2011-05-15 Thread DanH
One hint.  Look around locally for a business that could use some sort
of business-specific app.  Eg, an inventory tool of some sort -- like
one that will help a warehouseman find a specific item int the
warehouse.  Negotiate whatever deal you can to do an app for them (eg,
first two installs free, then $N per phone and $M per month for
maintenance), then, after you've proved yourself, do more of the same
for other businesses.

Some places like restaurants might want a free app for customers to,
eg, allow customers to check the menu and make reservations, but
they'll generally want iPhone first.  For such customers you're better
off if you can do both iPhone and Android.

On May 13, 5:24 am, "Knutsford Software"  wrote:
> How did people on this list get from learning about Android to getting paid 
> work developing apps. In other words how did you get past the no experience 
> no work stage?

-- 
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] GingerBread Compliance with AT&T requirements...

2011-05-15 Thread Mark Murphy
You have posted this question several times in several places. Your
various posts are now most of the top search results on:

at&t adapt device requirements

I have no idea what "AT&T's device requirements (ADAPT)" are, and
based on the search results, it's unclear if anyone else on this
planet does, either.

Rather than reposting the same question over and over again (e.g., 3+
times on this group alone), you might consider elaborating on your
question.

On Sun, May 15, 2011 at 8:12 AM, sahil gupta  wrote:
> Hello Android Team,
>
> Just want to get your inputs on details about how shall i go about
> studying Android (GingerBread) compliance with AT&T's device
> requirements (ADAPT), if anyone has carried out this study kindly
> share your experience and inputs. Any pointers on this??
>
>
> Regards
> Sahil Gupta
>
> --
> 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 App Developer 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-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] Need help understanding crash report.

2011-05-15 Thread cellurl
Would anyone want to help me understand this crash-descript/logcat
from Amazon.
Rgds
cellurl

--
Your application attempts to call an Android Activity lifecycle method
on a background thread. Amazon DRM does not allow developers to invoke
Android Activity lifecycle methods on background thread. For more
information on processes and threads, please visit:
http://developer.android.com/guide/topics/fundamentals/processes-and-threads.html
Additionally, the Android UI toolkit is not thread-safe. So, you must
not manipulate your UI from a worker thread — you must do all
manipulation to your user interface from the UI thread. There are two
rules to Android's single thread model: * Do not block the UI thread *
Do not access the Android UI toolkit from outside the UI thread

Please see below for the section of aLogCat you need.  The starred
line is the problem area.

D/dalvikvm( 1051): GC_FOR_MALLOC freed 99 objects / 4264 bytes in 63ms
D/PowerManagerService(   97): New lightsensor value:320, lcdValue:130
D/dalvikvm( 1051): GC_FOR_MALLOC freed 7649 objects / 468904 bytes in
84ms
D/NativeCrypto( 1051): Freeing OpenSSL session
D/dalvikvm( 1051): GC_EXTERNAL_ALLOC freed 8476 objects / 431920 bytes
in 78ms
D/PowerManagerService(   97): New lightsensor value:640, lcdValue:160
D/dalvikvm(  639): GC_EXPLICIT freed 7400 objects / 331752 bytes in
409ms
D/dalvikvm( 1051): GC_FOR_MALLOC freed 9299 objects / 723704 bytes in
66ms
D/UpdateService( 1051): Received action:
com.amazon.mas.client.framework.UpdateService.EXECUTE_REFRESHMENT_TASKS
from intent: Intent
{ act=com.amazon.mas.client.framework.UpdateService.EXECUTE_REFRESHMENT_TASKS
cmp=com.amazon.venezia/com.amazon.mas.client.framework.UpdateService }
D/AndroidRuntime( 1051): Shutting down VM
***W/dalvikvm( 1051): threadid=1: thread exiting with
uncaught exception (group=0x400259f8)
D/dalvikvm( 1051): GC_FOR_MALLOC freed 22703 objects / 1274048 bytes
in 56ms
D/NativeCrypto( 1051): Freeing OpenSSL session
D/dalvikvm( 1051): GC_FOR_MALLOC freed 8820 objects / 541776 bytes in
48ms
D/dalvikvm( 1051): GC_FOR_MALLOC freed 1583 objects / 283936 bytes in
44ms
I/Process ( 1051): Sending signal. PID: 1051 SIG: 9
W/ContentService(   97): binderDied() at ObserverNode name system

---

I started with Jetboy and butchered it to become my app called
"Steampunk Speed Limits".
So the UI is identical to Jetboy if that helps.
I added GPS, so thats the only newness...

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: How did you get into Android development

2011-05-15 Thread Kostya Vasilyev

15.05.2011 16:12, DanH пишет:

I started with Java 1.0.x -- writing a virtual machine for it.


I did start with Java 1.0 as well, integrating it as a scripting 
language into a game engine. It almost worked before the startup ran out 
of money :)



On May 13, 11:25 pm, Brill Pappin  wrote:

>  haha, particularly since 25 years ago, hardly anyone knew java (if it was
>  even released).


That was my point about HR specialists and managers at _some_ places. 
You'd see 'checkbox' oriented job requirement sheets, which have as 
little relation to reality as that. I'd avoid them whenever possible.



--
Kostya Vasilyev -- http://kmansoft.wordpress.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] Re: PVMFFailure when using MediaPlayer for radio streams

2011-05-15 Thread Menny
I had this issues too, with Android device 1.6 and 2.2 (actually, the only 
2.2 device I had this issue with was Galaxy Tab).
The solution I found, was to re-encode the original WAV files to MP3 with 
ffmpeg:
ffmpeg -i 1.wav -acodec libmp3lame -b 96k -ar 160001.mp3

-- 
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: PVMFFailure when using MediaPlayer for radio streams

2011-05-15 Thread Menny
Ho. And in the HTTP header, I made sure I get "audio/mpeg" value for the 
"Content-Type" header key.

-- 
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: Appending nodes to an existing XML file

2011-05-15 Thread lbendlin
Throw away your requirement ("no rewriting of the file") and you have a simple 
solution. 

-- 
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] XML files working one minute. failing with multiple errors the next, without any changes

2011-05-15 Thread Spooky
I'm working on a set of photography apps (currently splitting them up
by
category, e.g., ScenicNature, Lightning_etc,
Eglin_AFB_Armament_Museum,
etc.).  Right now, I'm experimenting with building it based loosely on
the MultiResolution sample in the SDK (under Android-8, building for
Android 1.5 and up).  At this point, I'm just trying to get this to
build
with my photos from one category:  Scenic/Nature (39 files, 3.2 MB).
All
images are PNG (reduced size, of course---the high-resolution images
from
my Nikon digital or the TIFF scans from 35mm would make each app
incredibly huge...not good).

I'm using the two layout XML files directly from the sample, except
for
removing the comments (even the COMMENTS were causing errors---things
like "Android is misspelled" (Android was spelled correctly).  It also
said that Apache was spelled incorrectly  Of course, removing all
of
that only removed those "errors", but I tried, just in case.

I've changed (per one of the various sets of instructions for
installing
Java, Eclipse, and the SDK) to Eclipse Classic (version 3.6.2), then
added the Android stuff, etc.  It didn't make any difference at all.
I
re-created the project, making sure I got every entry field in the
project properties correct.  No change.

Here is one of the two layout XML files (layout/status.xml---the other
is layout-land/status.xml):

---  CUT HERE  ---


http://schemas.android.com/apk/res/
android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" android:background="@drawable/
background">














---  CUT HERE  ---

And these are the errors I'm getting from Eclipse:

error: Error: String types not allowed:

   (at 'layout_height' with value 'match_parent'). line 3
   (at 'layout_width' with value 'match_parent').  line 3
   (at 'layout_height' with value 'match_parent'). line 7
   (at 'layout_width' with value 'match_parent').  line 7
   (at 'layout_height' with value 'match_parent'). line 10
   (at 'layout_width' with value 'match_parent').  line 10
   (at 'layout_height' with value 'match_parent'). line 13
   (at 'layout_width' with value 'match_parent').  line 13
   (at 'layout_width' with value 'match_parent').  line 25

All errors are type Android AAPT Problem.

In ScenicNatue.java:  everywhere where R.[whatever] (e.g.,
R.drawable.srsound01, R.layout.status, etc.) is listed, this
error appears:  "R cannot be resolved to a variable".  Ok,
fine...it hasn't generated gen/R.java yet...  The problem is,
it isn't generating it at all.

These same files built ok earlier, but after renaming the
project and replacing the sample images with my own, the
very same XML files suddenly have all of these errors (even
though they haven't changed, except for being re-formatted
by Eclipse, which removed some errors, but not the ones
listed above---they didn't change at all).

Am I missing something here?  Or, more to the point, can anyone
point me me toward what I could be missing?  After about 18 hours
of trying to figure out what's wrong, nothing I've tried has been
able to remove these "errors".  I'm still very new with XML and
Java (not to programming in general, just to these two)

Thanks,
   --jim

-- 
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] XML files working one minute. failing with multiple errors the next, without any changes

2011-05-15 Thread Kostya Vasilyev

15.05.2011 19:10, Spooky пишет:

Right now, I'm experimenting with building it based loosely on
the MultiResolution sample in the SDK (under Android-8, building for
Android 1.5 and up).


match_parent was introduced in Android 2.2 (API level 8) as an alias for 
fill_parent.


Either change your project's settings to build with 2.2 or later, or 
change all occurrences of match_parent to fill_parent, which existed before.


http://developer.android.com/reference/android/view/ViewGroup.LayoutParams.html

You might also have issues with -hdpi / -mdpi / -ldpi suffixes if you 
have them, those appeared in 1.6.


--
Kostya Vasilyev -- http://kmansoft.wordpress.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: Need help understanding crash report.

2011-05-15 Thread Nicholas Johnson
It sounds like you are trying to update an UI element from a non-UI thread. 
Are you using an AsyncTask, thread, IntentService, etc. and trying to update 
a UI element from it?

Nick

-- 
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] Google I/O 2011 Session material downloads/pdfs working for anyone?

2011-05-15 Thread Adam Ratana
I enjoyed and found very useful many of the Android presentations from this 
year's Google I/O; however, I am unable to download the related session 
PDFs.  For example, the android protips 
at 
http://www.google.com/events/io/2011/sessions/android-protips-advanced-topics-for-expert-android-app-developers.html
 
was useful, there's a decent amount of code that would be nice to examine. 
 Is the "Session presentation" link working for anyone?  I get a 404.  This 
is for a few of the other presentations with links as well.  Not sure if 
this is the right forum to ask about this, but given that some of the 
presenters themselves are present on here, figured it's worth a shot --

Adam

-- 
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: Payout problem on the Android Market?

2011-05-15 Thread Nicholas Johnson
Nope, no payout problems here. In fact, I've been recently surprised by the 
Android Market since Google IO 2011. The market seems to be refreshing 
multiple times daily, etc.

Nick 

-- 
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: How did you get into Android development

2011-05-15 Thread Harri Smått
On May 15, 2011, at 3:09 PM, DanH wrote:
> A skilled programmer with no Android experience will take about 2 weeks to 
> begin
> earning his keep, and a month or two to become comfortable with the
> technology. 

Here I tend to have slightly different opinion. While I agree mostly, I've seen 
following happening (not to forget Nokia made their decision to switch to 
Windows Phone on pretty much the same reason). Meaning many of the highly 
skilled software developers I've had pleasure to work with seem to be a bit 
afraid of Android. There's so huge momentum many seem to think it's difficult 
to find your place as a senior software developer, architect what so ever, the 
role you're used to be at, given the fact you have to start everything from 
scratch. And for many, it's been C/C++ they've been working with. Some of them 
their whole working career.

Now, given Java, not everyone is very much interested in learning it, and 
explore yet unknown possibilities of Android in general. And if this is the 
case, I find it very difficult to see who should be considered  'more 
experienced', the one with enthusiasm or the one with 10+ years of previous 
programming experience.

Granted, it seems to be very difficult to become successful within Android 
market, and making your living out of it isn't the simplest task one can think 
of. But still, I tend to think it's better to have too much competition 
compared to situation where there is no competition at all (this is why I 
rarely have talks with sales department  :).

But oh well, back to on-topic, and more specific questions. Just wanted to 
share my 2 cents.

--
H

-- 
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: XML files working one minute. failing with multiple errors the next, without any changes

2011-05-15 Thread Spooky


On May 15, 10:33 am, Kostya Vasilyev  wrote:
> 15.05.2011 19:10, Spooky пишет:
>
> > Right now, I'm experimenting with building it based loosely on
> > the MultiResolution sample in the SDK (under Android-8, building for
> > Android 1.5 and up).
>
> match_parent was introduced in Android 2.2 (API level 8) as an alias for
> fill_parent.

That would certainly explain a lot!  :-)   Yeah, I'll make those
changes
as soon as I post this.  Something tells me that's THE problem...but
I'm
not going to put money (that I don't have) on that   It seems I
keep
running into so many errors caused by typos, platform problems,
CPU being wimpy (AVD won't start up), and now, lack of a history
of what was released with what API level.  I'm really glad people
here are patient with those of us who are still learning.

> Either change your project's settings to build with 2.2 or later

I'll make the changes.  I'm hoping, when I actually get these
photography
apps done, to make at least a little bit of money with them.  I'm
going to
make them ad-supported, with a domation that removes the ads, and IF
I can find out how to do this, setup a form from within each app that
allows users to order poster-size prints from me.  I think that last
bit
has more potential than the rest, but we'll see.  I know at least one
in
there has already sold several for $75, so there is potentialand I
don't
want to limit the user-base to 1/3 (from the chart I saw) of the
Android
users.

> http://developer.android.com/reference/android/view/ViewGroup.LayoutP...

I'll be reading that, too.

> You might also have issues with -hdpi / -mdpi / -ldpi suffixes if you
> have them, those appeared in 1.6.

Those are about to go away, then.  :-)

Thanks for the information.  I'll post a followup in a little while
with the
new status.

   --jim

-- 
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 did you get into Android development

2011-05-15 Thread giangiammy
Hi,

I was interested in working with Android.
I had experience as linux embedded developer.
I spoke with a firm (for which I already did some works) interested into 
moving to android embedded market.

I offered to start working on Android embedded!
My reference was not Android experience (I had none before 
starting this work) but my general expertise in linux and embedded systems.

bye
giammy

--  
Gianluca Moro --- http://giammy.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] Re: XML files working one minute. failing with multiple errors the next, without any changes

2011-05-15 Thread Kostya Vasilyev

15.05.2011 20:20, Spooky пишет:

It seems I
keep
running into so many errors


When resources (XML files) fail to compile, it causes errors in the Java 
code as well, because R.*.* symbols are a result of a successful 
resource compilation.



caused by typos,


You can just ignore Eclipse's spell checker that highlights unknown 
words in comments.



platform problems,
CPU being wimpy (AVD won't start up),


The emulator can take a while to start up, but you can keep it running 
for multiple debug/run iterations, just like a real device.



and now, lack of a history
of what was released with what API level.


2.2:

http://developer.android.com/sdk/android-2.2.html

http://developer.android.com/sdk/api_diff/8/changes.html

2.0:

http://developer.android.com/sdk/android-2.0.html

http://developer.android.com/sdk/api_diff/5/changes.html

1.6:

http://developer.android.com/sdk/android-1.6.html

http://developer.android.com/sdk/api_diff/4/changes.html

-- Kostya

--
Kostya Vasilyev -- http://kmansoft.wordpress.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: XML files working one minute. failing with multiple errors the next, without any changes

2011-05-15 Thread Spooky


SUCCESS!!!

I have a few more things to change (image files getting renamed
without my knowing about it,
causing mis-matches, etc.  But after making all of the changes,
getting rid of res/drawable-*
and limiting it to drawable/, fixing the names, restarting Eclipse a
few times, etc., etc., it finally
built, loaded onto my Motorola Bravo, and worked very nicely.

Next on my list:
   1) remove the Android icon and the "Next" text and replace them
with left and right arrows
(previous and next image, respectively).

2) Find out (probably by asking here, unless I find it somewhere else)
how best to allow
   users to order poster-size prints of any photos they want in poster-
size (and how they
   pay for them),

3) make the form and code for #2.

4) repeat all of this for the other categories.  :-)

5) get all of these on the Market..and first, read up on how to do
that.

Thanks for the help!
   --jim

-- 
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] ListView Divider not showing when color changed

2011-05-15 Thread luiX_
Hi,

I have this layout for a ListView:

   
  

and the divider shows fine at the bottom, but if I try to change the color
of the divider like this:

   
  

then the divider is never shown. Any idea?

Also, I'd like to change the color of the "glowing" that shows up at the
bottom/head of the ListView when you're at the last/firts item, does anyone
how can I change that gradient color?

Thanks guys! :D

Luis.

-- 
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] ListView Divider not showing when color changed

2011-05-15 Thread Nasif Noorudeen
use your own list view
don't use built in inside android


change



  




On Sun, May 15, 2011 at 10:55 PM, luiX_  wrote:

> Hi,
>
> I have this layout for a ListView:
>
>   android:layout_width="fill_parent"
>   android:layout_height="wrap_content"
>   android:layout_below="@id/free_shopping_title"
>   android:layout_above="@id/free_shopping_total_price">
>   
>
> and the divider shows fine at the bottom, but if I try to change the color
> of the divider like this:
>
>   android:layout_width="fill_parent"
>   android:layout_height="wrap_content"
>   android:layout_below="@id/free_shopping_title"
>   android:layout_above="@id/free_shopping_total_price"
>   android:divider="#FF">
>   
>
> then the divider is never shown. Any idea?
>
> Also, I'd like to change the color of the "glowing" that shows up at the
> bottom/head of the ListView when you're at the last/firts item, does anyone
> how can I change that gradient color?
>
> Thanks guys! :D
>
> Luis.
>
> --
> 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] Problem of Focusing Keeping (I think)

2011-05-15 Thread Andrea Richiardi
My problem is really difficult to explain actually...

I have a ViewAnimator which has some View inside.

Views are custom, and each view has its own background. The background
is a selector, partly taken from Android source, especially the
transition between longpress/normal press (two 9 patch images).

I have a Gesture Listener that triggers when a Fling (Swipe) is
performed and it changes my view with showNext().

The ViewAnimator doesn't have anything as attribute, just
longClickable and focusable to "true".
It passes his states on childs, or better, state are duplicated by
child with the duplicateParentState attribute.

The problem is this:

If I swipe, the Gesture triggers and changes my Views, but the click
state is mantained, as I see the next View already pressed (and by the
way, the background draws an horizontal blue line, take from
nowhere!).

Skipping the blue line part, I think that the problem is on the
ViewAnimator, which holds its pressed (or long pressed) state.

Someone has ever run into this kind of problem? It really bothers me.

Thanks everybody!

-- 
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: Why WebView can't click on the link

2011-05-15 Thread Menny
I noticed that OSes prior to 2.3 failed to follow links if 
setHorizontalScrollBarEnabled and setVerticalScrollBarEnabled are set to 
false.

-- 
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] ListView Divider not showing when color changed

2011-05-15 Thread luiX_
If that's needed, this should be a bug in the framework, isn't it?

I'm asking in order to open a bug report.

2011/5/15 Nasif Noorudeen 

> use your own list view
> don't use built in inside android
>
>
> change
>
>
>  android:id="@+id/som_id"
>
>   android:layout_width="fill_parent"
>   android:layout_height="wrap_content"
>   android:layout_below="@id/free_shopping_title"
>   android:layout_above="@id/free_shopping_total_price">
>   
>
>
>
>
> On Sun, May 15, 2011 at 10:55 PM, luiX_  wrote:
>
>> Hi,
>>
>> I have this layout for a ListView:
>>
>>>   android:layout_width="fill_parent"
>>   android:layout_height="wrap_content"
>>   android:layout_below="@id/free_shopping_title"
>>   android:layout_above="@id/free_shopping_total_price">
>>   
>>
>> and the divider shows fine at the bottom, but if I try to change the color
>> of the divider like this:
>>
>>>   android:layout_width="fill_parent"
>>   android:layout_height="wrap_content"
>>   android:layout_below="@id/free_shopping_title"
>>   android:layout_above="@id/free_shopping_total_price"
>>   android:divider="#FF">
>>   
>>
>> then the divider is never shown. Any idea?
>>
>> Also, I'd like to change the color of the "glowing" that shows up at the
>> bottom/head of the ListView when you're at the last/firts item, does anyone
>> how can I change that gradient color?
>>
>> Thanks guys! :D
>>
>> Luis.
>>
>> --
>> 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] Task State Being Lost

2011-05-15 Thread Eric
I have two "launchMode:singleTask" activities in my app.

Activity A (also the MAIN/LAUNCHER Activity);
taskAffinity="Affinity.A"; alwaysRetainTaskState="true"
Activity B (taskAffinity="Affinity.B"; alwaysRetainTaskState="true")

1. When I run the app from the Home Launcher, Activity A starts as
expected.

2. I navigate into Activity A1 from a button in Activity A.  Activity
A1 launches as the second Activity on the main Task's stack, as
expected.

3. When I hit a button on Activity A1 that starts Activity B, Activity
B starts in it's own new Task, as expected (due to singleTask
definition on B).

4. When I click a button in Activity B that does

   startActivity(new Intent(this, ActivityA.class)

the system takes me back to the first (root) activity in Activity A
which is not what I want. I want it to resume the main Task where it
left off in Activity A1.  The documentation for singleTask indicates
the system is supposed to take you back where you left off in the
Task, but this is clearly not happening.  When I hit the back button
from the newly started Activity A, it goes back to Activity B, then
exits the app if I hit it again, so it is definitely not adding
another Activity A on the stack, it is resuming the main Task but just
not getting me back to where I left off.

Am I doing something wrong?  Do I need to ditch launchMode=singleTask
and use FLAG_ACTIVITY_NEW_TASK instead when calling startActivity()?
I found another flag FLAG_ACTIVITY_RESET_TASK_IF_NEEDED, and I'm
confused as to what that is supposed to do, while guessing that it
may(?) help me here?

-- 
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] Application not showing up in Settings->Manage Apps-->Running Apps

2011-05-15 Thread Eric
I am absolutely sure my application is running, but after I hit the
HOME button and navigate to Settings->Manage Apps-->Running Apps, I
don't see my app in the running list.  If I re-enter the app from the
LAUNCHER the logs indicate that the app/process is resumed (and NOT
restarted), so I'm positive the app is running after I hit HOME to
exit it.  It's just not showing up in the Running Apps list.

Has anyone seen this happen ever, and is there a workaround?

- 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


[android-developers] Layout sizes not determined when I need them

2011-05-15 Thread RLScott
I have a main activity whose layout is from a typical XML Relative
Layout.  One of the items in that layout is TextView whose textSize is
15sp.  I want to capture the actual size of this TextView after the
layout is inflated for use elsewhere in my app.  So I tried calling
the view.getHeight() method as late as possible in my activity startup
so as to capture it after the inflation process.  But I find through
debugging that getHeight() returns 0 when called from anywhere in my
activitiy's onCreate() or onResume() method.  And I don't know of
anything that is always called after onResume().  However, if I call
getHeight() much later, say as part of an onClick handler in my
activity, then getHeight() returns a more reasonable 21.  Apparently
the height of my TextView (which is part of my main activity layout)
is not yet computed until later than I have been calling.  When can I
call getHeight() and get a reasonable answer?

-- 
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: Task State Being Lost

2011-05-15 Thread Eric
One more note on item #4 above.  I have set logs in my Activity.onStop/
onDestroy() methods, and strangely I do not see ActivityA1.onDestroy()
being called after I resume the main Task in step 4, and the system
takes me back to the root ActivityA.  The system has apparently
orphaned the previously running Activity A1 by not destroying it when
the root Activity A resumes with onNewIntent.

-- 
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: Progress circle (NOT indeterminate!)

2011-05-15 Thread Serdel
Thanks guys, I have tested all this and almost achieved what I want. I
have change the code form Romain Guy a little bit so now I have:








And this is almost what I want. I would like to change the eliminate
the gradient factor so the circle that is 'unfolding' has the same
colour all the time. If this is manageable then I guess I'm home :>

On 14 Maj, 20:42, Dianne Hackborn  wrote:
> Just set this as the drawable in a ProgressBar widget and control it with
> that.
>
> On Sat, May 14, 2011 at 5:43 AM, Serdel wrote:
>
>
>
>
>
>
>
>
>
> > That in deed is a nice approach. I wasn't aware that android has such
> > a drawable. To abd this is more a 'ring' shape than a filled circle,
> > but I guess a ring is also acceptable. But can you give me a hint how
> > to control the 'progress' in the java code? So that I can i.e.
> > increase it fluently in a timer or indicate a progress in downloading
> > a file.
>
> > On 13 Maj, 23:19, Romain Guy  wrote:
> > > You don't need to do all this. All you need is a drawable that supports
> > > levels. Android even provides a circle drawable that gets filled when you
> > > change the progress. Here's an example:
>
> > > http://schemas.android.com/apk/res/android";>
> > >      > android:drawable="@android:drawable/progress_circular_background" />
> > >     
> > >          > >                android:innerRadiusRatio="3.4"
> > >                android:thicknessRatio="6.0">
> > >              > >                    android:useLevel="true"
> > >                    android:type="sweep"
> > >                    android:startColor="#ff00"
> > >                    android:endColor="#" />
> > >         
> > >     
> > >     
> > >          > >             android:pivotX="50%" android:pivotY="50%"
> > >             android:fromDegrees="0" android:toDegrees="360"
> > >             android:drawable="@android:drawable/progress_particle" />
> > >     
> > > 
>
> > > On Fri, May 13, 2011 at 2:12 PM, Nicholas Johnson
> > > wrote:
>
> > > > Here's what you can do:
>
> > > > Extend the AbsSeekBar class<
> >http://developer.android.com/reference/android/widget/AbsSeekBar.html>,
> > > > and implement the onDraw method to your liking. You can capture the
> > height
> > > > and width of your custom view by capturing those values in the
> > onSizeChanged
> > > > method. By drawing your circle programatically you can easily make a
> > > > progress circle that looks good at all resolutions. Also, you don't
> > have to
> > > > worry about different device resolutions, since you just need to
> > control the
> > > > size of the view in the layout.
>
> > > > Or, you could extend the ProgressBar class and do the same thing.
>
> > > > Nick
>
> > > >  --
> > > > 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
>
> > > Note: please don't send private questions to me, as I don't have time to
> > > provide private support.  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
>
> --
> Dianne Hackborn
> Android framework engineer
> hack...@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


[android-developers] Re: Task State Being Lost

2011-05-15 Thread Eric
One more item of interest that I just noticed.  If I navigate into the
Settings-->Manage Apps (all apps), and find my application and select
it, I do see the button for "Force stop" enabled.  Is my understanding
of Running Apps incorrect, in that Android only shows the apps that
are _actually_ running and not the ones that are suspended after
someone hits HOME?

-- 
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] Google Maps "heat map" type overlay?

2011-05-15 Thread TreKing
On Sun, May 15, 2011 at 5:12 AM, Boozel  wrote:

> Can anyone recommend a way to do this?


Sub-class Overlay and do custom drawing.

-
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: Task State Being Lost

2011-05-15 Thread Eric
On May 15, 2:40 pm, Eric  wrote:
> One more item of interest that I just noticed.  If I navigate into the
> Settings-->Manage Apps (all apps), and find my application and select
> it, I do see the button for "Force stop" enabled.  Is my understanding
> of Running Apps incorrect, in that Android only shows the apps that
> are _actually_ running and not the ones that are suspended after
> someone hits HOME?

Please ignore this last post, I posted it to the wrong 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: Application not showing up in Settings->Manage Apps-->Running Apps

2011-05-15 Thread Eric
One more item of interest that I just noticed.  If I navigate into
the
Settings-->Manage Apps (all apps), and find my application and select
it, I do see the button for "Force stop" enabled.  Is my
understanding
of Running Apps incorrect, in that Android only shows the apps that
are _actually_ running and not the ones that are suspended after
someone hits HOME?

-- 
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] ListView Divider not showing when color changed

2011-05-15 Thread Kostya Vasilyev

15.05.2011 22:28, luiX_ пишет:



AFAIK, "@id/android:list" is not valid ID syntax.

It's either:

"@id/your_application_package_id"

"@+id/your_application_package_id"

or

"@android:id/predefined_android_id"

For ListActivity, that should be

"@android:id/list"

-- Kostya

--
Kostya Vasilyev -- http://kmansoft.wordpress.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: Task State Being Lost

2011-05-15 Thread Eric
Here is the result of "adb shell dumpsys activity" before/after I
navigate from TaskB/ActivityB back to resuming TaskA (where I expect
activity A1 to be at the top of the stack, but it is somehow dropped
and I'm left with the root ActivityA).




BEFORE
===

Activity stack:
  * TaskRecord{4055ce18 #8 A .activities.ActivityB}
clearOnBackground=false numActivities=1 rootWasReset=false
affinity=.activities.ActivityB
intent={flg=0xc0
cmp=com.mycompany.android.myapp/.activities.ActivityB}
realActivity=com.mycompany.android.myapp/.activities.ActivityB
lastActiveTime=642306 (inactive for 2s)
* Hist #3: HistoryRecord{4091f998
com.mycompany.android.myapp/.activities.ActivityB}
packageName=com.mycompany.android.myapp
processName=com.mycompany.android.myapp
launchedFromUid=10010 app=ProcessRecord{40745a28
750:com.mycompany.android.myapp/10010}
Intent { flg=0x80
cmp=com.mycompany.android.myapp/.activities.ActivityB }
frontOfTask=true task=TaskRecord{4055ce18 #8
A .activities.ActivityB}
taskAffinity=.activities.ActivityB
realActivity=com.mycompany.android.myapp/.activities.ActivityB
base=/data/app/com.mycompany.android.myapp-1.apk/data/app/
com.mycompany.android.myapp-1.apk data=/data/data/
com.mycompany.android.myapp
labelRes=0x7f080046 icon=0x7f020043 theme=0x7f090018
stateNotNeeded=false componentSpecified=true
isHomeActivity=false
configuration={ scale=1.0 imsi=0/0 loc=en_US touch=3
keys=1/1/2 nav=3/1 orien=1 layout=34 uiMode=17 seq=5}
launchFailed=false haveState=false icicle=null
state=RESUMED stopped=false delayedResume=false
finishing=false
keysPaused=false inHistory=true launchMode=2
fullscreen=true visible=true frozenBeforeDestroy=false
thumbnailNeeded=false idle=true
waitingVisible=false nowVisible=true
  * TaskRecord{4092b378 #7 A .activities.ActivityA}
clearOnBackground=false numActivities=2 rootWasReset=true
affinity=.activities.ActivityA
intent={flg=0x40
cmp=com.mycompany.android.myapp/.activities.ActivityA}
realActivity=com.mycompany.android.myapp/.activities.ActivityA
lastActiveTime=642263 (inactive for 2s)
* Hist #2: HistoryRecord{4095e0f0
com.mycompany.android.myapp/.activities.ActivityA1}
packageName=com.mycompany.android.myapp
processName=com.mycompany.android.myapp
launchedFromUid=10010 app=ProcessRecord{40745a28
750:com.mycompany.android.myapp/10010}
Intent { flg=0x80
cmp=com.mycompany.android.myapp/.activities.ActivityA1 }
frontOfTask=false task=TaskRecord{4092b378 #7
A .activities.ActivityA}
taskAffinity=.activities.ActivityA
 
realActivity=com.mycompany.android.myapp/.activities.ActivityA1
base=/data/app/com.mycompany.android.myapp-1.apk/data/app/
com.mycompany.android.myapp-1.apk data=/data/data/
com.mycompany.android.myapp
labelRes=0x7f080034 icon=0x7f02002c theme=0x7f090018
stateNotNeeded=false componentSpecified=true
isHomeActivity=false
configuration={ scale=1.0 imsi=0/0 loc=en_US touch=3
keys=1/1/2 nav=3/1 orien=1 layout=34 uiMode=17 seq=5}
launchFailed=false haveState=true
icicle=Bundle[mParcelledData.dataSize=3308]
state=STOPPED stopped=true delayedResume=false finishing=false
keysPaused=false inHistory=true launchMode=0
fullscreen=true visible=false frozenBeforeDestroy=false
thumbnailNeeded=false idle=true
* Hist #1: HistoryRecord{406a8838
com.mycompany.android.myapp/.activities.ActivityA}
packageName=com.mycompany.android.myapp
processName=com.mycompany.android.myapp
launchedFromUid=10026 app=ProcessRecord{40745a28
750:com.mycompany.android.myapp/10010}
Intent { act=android.intent.action.MAIN
cat=[android.intent.category.LAUNCHER] flg=0x1020
cmp=com.mycompany.android.myapp/.activities.ActivityA }
frontOfTask=true task=TaskRecord{4092b378 #7
A .activities.ActivityA}
taskAffinity=.activities.ActivityA
realActivity=com.mycompany.android.myapp/.activities.ActivityA
base=/data/app/com.mycompany.android.myapp-1.apk/data/app/
com.mycompany.android.myapp-1.apk data=/data/data/
com.mycompany.android.myapp
labelRes=0x7f080016 icon=0x7f020037 theme=0x7f090018
stateNotNeeded=false componentSpecified=true
isHomeActivity=false
configuration={ scale=1.0 imsi=0/0 loc=en_US touch=3
keys=1/1/2 nav=3/1 orien=1 layout=34 uiMode=17 seq=5}
launchFailed=false haveState=true
icicle=Bundle[mParcelledData.dataSize=2168]
state=STOPPED stopped=true delayedResume=false finishing=false
keysPaused=false inHistory=true launchMode=2
fullscreen=true visible=false frozenBeforeDestroy=false
thumbnailNeeded=false idle=true
  * TaskRecord{4070f668 #2 A com.android.launcher}
clearOnBackground=true numActivities=1 rootWasReset=true
affinity=com.android.launcher
intent={act=android.intent.action.MAIN
cat=[an

Re: [android-developers] Application not showing up in Settings->Manage Apps-->Running Apps

2011-05-15 Thread Dianne Hackborn
What version of Android are you running?

On Sun, May 15, 2011 at 11:33 AM, Eric  wrote:

> I am absolutely sure my application is running, but after I hit the
> HOME button and navigate to Settings->Manage Apps-->Running Apps, I
> don't see my app in the running list.  If I re-enter the app from the
> LAUNCHER the logs indicate that the app/process is resumed (and NOT
> restarted), so I'm positive the app is running after I hit HOME to
> exit it.  It's just not showing up in the Running Apps list.
>
> Has anyone seen this happen ever, and is there a workaround?
>
> - 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
>



-- 
Dianne Hackborn
Android framework engineer
hack...@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

[android-developers] Re: How did you get into Android development

2011-05-15 Thread DanH
For several years our JVM (IBM Series i) held the worldwide
performance record.

On May 15, 8:04 am, Kostya Vasilyev  wrote:
> 15.05.2011 16:12, DanH пишет:
>
> > I started with Java 1.0.x -- writing a virtual machine for it.
>
> I did start with Java 1.0 as well, integrating it as a scripting
> language into a game engine. It almost worked before the startup ran out
> of money :)
>
> > On May 13, 11:25 pm, Brill Pappin  wrote:
> >> >  haha, particularly since 25 years ago, hardly anyone knew java (if it 
> >> > was
> >> >  even released).
>
> That was my point about HR specialists and managers at _some_ places.
> You'd see 'checkbox' oriented job requirement sheets, which have as
> little relation to reality as that. I'd avoid them whenever possible.
>
> --
> Kostya Vasilyev --http://kmansoft.wordpress.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: Application not showing up in Settings->Manage Apps-->Running Apps

2011-05-15 Thread Eric


On May 15, 2:57 pm, Dianne Hackborn  wrote:
> What version of Android are you running?

2.3.4, NexusOne

-- 
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 did you get into Android development

2011-05-15 Thread DanH
Actually, I do find that Android is harder to get the hang of than
either iPhone or Qt for Nokia, but it's because the Android
environment is so obscure and irregular.  Switching from Objective C
to Qt/C++ to Java is no problem for anyone with reasonable programming
skills -- you could fairly easily write a program to translate between
them for "business logic".  The harder part is the environment/OS and,
to a lesser extent, the UI.

On May 15, 10:56 am, Harri Smått  wrote:
> On May 15, 2011, at 3:09 PM, DanH wrote:
>
> > A skilled programmer with no Android experience will take about 2 weeks to 
> > begin
> > earning his keep, and a month or two to become comfortable with the
> > technology.
>
> Here I tend to have slightly different opinion. While I agree mostly, I've 
> seen following happening (not to forget Nokia made their decision to switch 
> to Windows Phone on pretty much the same reason). Meaning many of the highly 
> skilled software developers I've had pleasure to work with seem to be a bit 
> afraid of Android. There's so huge momentum many seem to think it's difficult 
> to find your place as a senior software developer, architect what so ever, 
> the role you're used to be at, given the fact you have to start everything 
> from scratch. And for many, it's been C/C++ they've been working with. Some 
> of them their whole working career.
>
> Now, given Java, not everyone is very much interested in learning it, and 
> explore yet unknown possibilities of Android in general. And if this is the 
> case, I find it very difficult to see who should be considered  'more 
> experienced', the one with enthusiasm or the one with 10+ years of previous 
> programming experience.
>
> Granted, it seems to be very difficult to become successful within Android 
> market, and making your living out of it isn't the simplest task one can 
> think of. But still, I tend to think it's better to have too much competition 
> compared to situation where there is no competition at all (this is why I 
> rarely have talks with sales department  :).
>
> But oh well, back to on-topic, and more specific questions. Just wanted to 
> share my 2 cents.
>
> --
> H

-- 
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 did you get into Android development

2011-05-15 Thread DanH
If you look around, about half those posting here (and on other forums
for other platforms) are kids who have essentially no programmer
training but have managed to modify a few example projects to do
interesting (to them) things and hence consider themselves to be
programmers.  They all believe that they have (or very shortly will
have) the next killer app (which is usually a game) and are only
months away from striking it rich (if only those curmudgeons on the
forums would answer their queries with a few hundred lines of free
code rather than cryptic "read the documentation" responses).  A few
of these guys will go on to develop decent programming skills, but
most don't have the patience for it (and patience is the #2
requirement for programming).

(The #1 requirement for programming is a love of it that surpasses
your love for money and often your love of food and sleep.)

On May 15, 5:30 am, Harri Smått  wrote:
> On May 15, 2011, at 6:18 AM, Adam Ratana wrote:
>
> > - have fun, experience some joy and passion for the process, it's an end in 
> > itself!
>
> I can't help from leaving a comment on this point. For me, the whole buzz 
> around Android reminds me a lot of the times we had back in 90s on C64 (here 
> in Finland at least). Back then, almost all of my friends had a personal 
> 'software house', writing some kind of a game from their head using basic 
> mostly. This time there's the Internet, making it a bit more of a 'global' 
> thing, but I see many similarities. In the 90s you showcased your application 
> to your parents and friends most of the time, now you have AppStore etc for 
> wider audience.
>
> But all the same, I've been very pleased to see how many people have gotten 
> involved into software development, thanks to Android, and maybe iOS too (I 
> really have no idea what's happening on that side) lately. So yeah, from what 
> I've seen so far, there seem to many people, me included, who really enjoy 
> all this.
>
> --
> H

-- 
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: Layout sizes not determined when I need them

2011-05-15 Thread RLScott

After some Googling I found that others had asked the same quesiton,
and here is the answer:  You can get a reliable getHeight() or
getWidth() for the TextViews in an activity layout until the
activity's onWindowFocusChanged(true).

-- 
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: How did you get into Android development

2011-05-15 Thread Harri Smått
On May 15, 2011, at 10:17 PM, DanH wrote:
> If you look around, about half those posting here (and on other forums
> for other platforms) are kids who have essentially no programmer
> training but have managed to modify a few example projects to do
> interesting (to them) things and hence consider themselves to be
> programmers.

I preferred not to make assumptions on the goals people have if all I see is a 
question accompanied with a few lines of code. What ever they are, I'm still 
hoping it's something they feel happy about once get around the problems 
they're facing during this time. And even though not everyone will be a 'real' 
programmer one day, it was the same during C64 era too, guess one could say it 
shouldn't do any harm to have some basic insight on the topic either.

Actually, many of the people I admire yet today, didn't make it to software 
industry. But having a background as a 'hobbyist programmer' still shows on 
their work.

--
H

-- 
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: Application not showing up in Settings->Manage Apps-->Running Apps

2011-05-15 Thread appel
In running services press menu and select show cached processes. 

-- 
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] TextView looks great, but drawText() looks crummy !

2011-05-15 Thread RLScott
If you look closely at a TextView, you will see that it is clean and
clear because it uses half-tone shading to avoid that pixelated look.
But in my custom view I am calling drawText, and the results are not
as good.  The stuff drawn with drawText looks a bit ragged because it
does not use any half-tone shading.  Every pixel is either completely
black or completely white.  How can I get Canvas.drawText() to look as
good as the text in a TextView?

-- 
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] TextView looks great, but drawText() looks crummy !

2011-05-15 Thread Romain Guy
You need to enable anti-aliasing your Paint object:
myPaint.setAntiAlias(true)

On Sun, May 15, 2011 at 1:00 PM, RLScott  wrote:

> If you look closely at a TextView, you will see that it is clean and
> clear because it uses half-tone shading to avoid that pixelated look.
> But in my custom view I am calling drawText, and the results are not
> as good.  The stuff drawn with drawText looks a bit ragged because it
> does not use any half-tone shading.  Every pixel is either completely
> black or completely white.  How can I get Canvas.drawText() to look as
> good as the text in a TextView?
>
> --
> 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

Note: please don't send private questions to me, as I don't have time to
provide private support.  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

[android-developers] Re: TextView looks great, but drawText() looks crummy !

2011-05-15 Thread RLScott
Thanks.  Now it looks great!

-- 
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: Application not showing up in Settings->Manage Apps-->Running Apps

2011-05-15 Thread Eric


On May 15, 3:52 pm, appel  wrote:
> In running services press menu and select show cached processes.

That did the trick, 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] Re: Application not showing up in Settings->Manage Apps-->Running Apps

2011-05-15 Thread Eric
It's interesting to note that my Application is cached by Android as a
'cached process' immediately after I hit the HOME button.  Is this
usually what happens, or is Android treating my app different than
usual because it happens to consume a lot of memory (on the order of
~15MB)?

-- 
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] Activity/Service in separate process

2011-05-15 Thread Mark Cz
Hi,

Is it possible for two apks to SHARE one service that runs in one of
the apks process or runs in a different process ?

Meaning,
I have two apks running in two different processes (the normal way),
for simplicity each apk has only one activity.
In addition each apk has one ,
can I share this service between the two (or more) apks ?

The apks have a different certificate, different packageName, what
should I write in the manifest of each of them to achieve my goal ?


-- 
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: Appending nodes to an existing XML file

2011-05-15 Thread Bob Kerns
Simple, yes, but it performs as O(n^2). As your file gets longer and longer, 
your application will perform slower and slower. If you don't take care to 
do it off the UI thread, you will eventually start getting force-closes 
because it stalls out the UI thread.

Not generally recommended.

All of these solutions have potential issues with incomplete writes, due to 
the application being shut down in mid-write. 

A more robust solution, also quite simple, is to stick all the data into a 
database -- and output it as XML at the point you need XML. In most 
scenarios, this is the approach I would recommend.

On Sunday, May 15, 2011 7:47:34 AM UTC-7, lbendlin wrote:
>
> Throw away your requirement ("no rewriting of the file") and you have a 
> simple solution. 

-- 
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: Appending nodes to an existing XML file

2011-05-15 Thread DanH
Another alternative is a journaled approach.  Write the updates to a
journal, then merge them with the main file from time to time in a
"batch" processing step.

On May 15, 4:57 pm, Bob Kerns  wrote:
> Simple, yes, but it performs as O(n^2). As your file gets longer and longer,
> your application will perform slower and slower. If you don't take care to
> do it off the UI thread, you will eventually start getting force-closes
> because it stalls out the UI thread.
>
> Not generally recommended.
>
> All of these solutions have potential issues with incomplete writes, due to
> the application being shut down in mid-write.
>
> A more robust solution, also quite simple, is to stick all the data into a
> database -- and output it as XML at the point you need XML. In most
> scenarios, this is the approach I would recommend.
>
> On Sunday, May 15, 2011 7:47:34 AM UTC-7, lbendlin wrote:
>
> > Throw away your requirement ("no rewriting of the file") and you have a
> > simple solution.

-- 
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 did you get into Android development

2011-05-15 Thread DanH
The better programmers have an engineering background, IMO (or at
least an "engineering way of thinking").

On May 15, 2:43 pm, Harri Smått  wrote:
> On May 15, 2011, at 10:17 PM, DanH wrote:
>
> > If you look around, about half those posting here (and on other forums
> > for other platforms) are kids who have essentially no programmer
> > training but have managed to modify a few example projects to do
> > interesting (to them) things and hence consider themselves to be
> > programmers.
>
> I preferred not to make assumptions on the goals people have if all I see is 
> a question accompanied with a few lines of code. What ever they are, I'm 
> still hoping it's something they feel happy about once get around the 
> problems they're facing during this time. And even though not everyone will 
> be a 'real' programmer one day, it was the same during C64 era too, guess one 
> could say it shouldn't do any harm to have some basic insight on the topic 
> either.
>
> Actually, many of the people I admire yet today, didn't make it to software 
> industry. But having a background as a 'hobbyist programmer' still shows on 
> their work.
>
> --
> H

-- 
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 did you get into Android development

2011-05-15 Thread amenra horus
I'm  undergrad  computer science student and would love to make software 
development for android in particular a career path any tips or  intern work 
u can point me in the direction of?

-- 
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: How did you get into Android development

2011-05-15 Thread Miguel Morales
Android development is relatively easy to get into.  (For example, I never
went to college and work as an Android dev.)
Here in the US though, you have to be good at it or else your job will be
sent to India.
But on the other hand, apps are not as demanding as say making scalable
backend software.  So, right now if you're a good android dev you'll be
making the same as a senior backend dev but doing much less stressful work.


On Sun, May 15, 2011 at 3:10 PM, amenra horus  wrote:

> I'm  undergrad  computer science student and would love to make software
> development for android in particular a career path any tips or  intern work
> u can point me in the direction of?
>
> --
> 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

Re: [android-developers] Re: Appending nodes to an existing XML file

2011-05-15 Thread Miguel Morales
Hmm, I'd probably do it one of two ways depending on how big the xml file is
expected to grow.

If it's relatively small, read it into memory, deserialize it, find the
node/tag where you wish to append your node, append it and then re-serialize
it into the same file.  But that's only if it's small.

If it's larger, probably stream de-serialize the file, look for the tag and
append the node there. (and don't store to memory any tags you don't care
about.)

Obviously any de-serialization will have to take place in a worker thread.

On Sun, May 15, 2011 at 3:02 PM, DanH  wrote:

> Another alternative is a journaled approach.  Write the updates to a
> journal, then merge them with the main file from time to time in a
> "batch" processing step.
>
> On May 15, 4:57 pm, Bob Kerns  wrote:
> > Simple, yes, but it performs as O(n^2). As your file gets longer and
> longer,
> > your application will perform slower and slower. If you don't take care
> to
> > do it off the UI thread, you will eventually start getting force-closes
> > because it stalls out the UI thread.
> >
> > Not generally recommended.
> >
> > All of these solutions have potential issues with incomplete writes, due
> to
> > the application being shut down in mid-write.
> >
> > A more robust solution, also quite simple, is to stick all the data into
> a
> > database -- and output it as XML at the point you need XML. In most
> > scenarios, this is the approach I would recommend.
> >
> > On Sunday, May 15, 2011 7:47:34 AM UTC-7, lbendlin wrote:
> >
> > > Throw away your requirement ("no rewriting of the file") and you have a
> > > simple solution.
>
> --
> 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] Android Connect to python and send current location

2011-05-15 Thread ingy abbas
I want to connect android code with is Map View code with my python
code (server ) so i want when i touch the screen or i want to make
button when i click to it the android send to the server using the gps
i do Send my current location to server SO can i add buttons appear in
my map and be action listener or when touch the map it send the
location i created a socket in my map view code i added this method


 public void connect(View view){
try{
clientSocket= new Socket("10.0.2.2",54633);
Text.append( "\n created a socket");
outToServer = new
DataOutputStream(clientSocket.getOutputStream());
Text.append( "\n created a datastream");
inFromServer = new BufferedReader(new
InputStreamReader(clientSocket.getInputStream()));
   ;
   }catch(Exception e){
System.out.println("Error");
   }
   }
So i want to add action listener when i click on map and be able to
send my current location

-- 
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] Trying to access a text (string) array via integer AND question on image size vs ads

2011-05-15 Thread Spooky
New question

I'm trying to access an array of text strings by its integer index (at
laest, I think that's what I'm trying to do!).

The array is defined as (it's actually longer than this---this is the
shortened version):

String[] descriptions = {"Santa Rosa Sound (NW FL)",
"Sailboat on SR Sound", "SR Sound Sunset #1",
"SR Sound Sunset #2", "SR Sound Sunset #3",
"SR Sound Sunset #4", "NW FL Sunset",
"SR Sound from Okaloosa Island", "Beaches on the
Island" );

and I'm trying to use it, just a few lines later, like this
(indentation
shortened here):

   TextView statusText = (TextView) findViewById(R.id.status_text);
  statusText.setText(String.format("%s",
descriptions(photoIndex)));

I also tried this:

   TextView statusText = (TextView) findViewById(R.id.status_text);
  statusText.setText(descriptions(photoIndex));

Eclipse insists on including an Object definition which merely
returns null.  I tried editing it to return descriptions(photoIndex),
and it Force Closed every time I tried to run it.  Obviously not the
right way to do this.

I *THINK* I'm following what an example shows to do, but I either get
null or a Force Close.  The example is at:

http://stackoverflow.com/questions/4986786/using-string-array-list-length-as-an-integer

What I'm trying to do is access the descriptions array by the same
index that the photo being loaded onto the screen is using.  The idea
here is to replace the "1/39" with "Santa Rosa Sound (NW FL)".

Can anyone either let me know what I'm doing wrong, or point me to the
appropriate FM that will show me how I *SHOULD* be doing it?  :-)



Another question regarding image dimensions.  This app will be
ad-supported, and in landscape mode, some of the photos take up the
entire screen on my Android.  Will that block ads from being seen?
Or is the container for this app reduced by the ads, thus reducing the
parent to be filled by the photo to begin with?

Thanks,
   --jim

PS:  Last newbie question from me today...follow-ups to this, yes, but
another newbie question, not today..  If I get this working, I'm
done
for the day.  Then tomorrow, it's just cleaning up the screen...easy
stuff.

-- 
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] Open multiple cameras simultaneously

2011-05-15 Thread QD
I want to open at least two cameras at the same time for some usage, (2.3.3 
and up)

but the log message always shows that "CamerasService *
lockIfMessageWanted*"

Is that means open multiple cameras simultaneously is impossible currently?

or just my mistake

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

[android-developers] Remotely trigger notifications

2011-05-15 Thread Mike
I am trying to write an app that will notify the user when a new piece
of content is added to my database.  I know I can make a service that
would just poll the database every two hours or so but I feel like
there is a much better way to do this.  Is this really the only and or
best way to do this?

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


[android-developers] How can i find out where the apk was installed?

2011-05-15 Thread Brill Pappin
I've got a situation where we had set our apk to install to location 
preferExternal but have found that is causes problems.

We want to notify the user if they have the apk installed on the SD card and 
ask them to move it to the phone if they are experiencing problems.

How do we determine if the app is installed on the SD card or internal 
memory?

- brill

-- 
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 did you get into Android development

2011-05-15 Thread Brill Pappin
Yah... maybe true... i don't know... but you and i both were those kids at 
one point.

-- 
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] GSM signal strength "unknown" returned in Gingerbread 2.3.3

2011-05-15 Thread Alex
I have registered a PhoneStateListener and I am listening to
onSignalStrengthChanged(asu) and
onSignalStrengthsChanged(SignalStrength signalStrength).

On Eclair, these events correctly return the GSM signal strength in
asu, but on Gingerbread onSignalStrengthChanged always returns -1 and
signalStrength.GetGsmSignalStrength() always returns -99
(UNKNOWN_RSSI).

This means it is impossible to read the signal strength on
Gingerbread.

I tried my app on a phone with Gingerbread version 2.3.4 and it worked
fine.

Is this a known issue with 2.3.3?  Is there a workaround?

-- 
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] Remotely trigger notifications

2011-05-15 Thread Mark Murphy
On Sun, May 15, 2011 at 7:15 PM, Mike  wrote:
> I am trying to write an app that will notify the user when a new piece
> of content is added to my database.  I know I can make a service that
> would just poll the database every two hours or so but I feel like
> there is a much better way to do this.  Is this really the only and or
> best way to do this?

When you add a new piece of content to the database, raise a
Notification. Or, if you think your client activity will be running at
the time, use an ordered broadcast to either notify your activity or
raise a Notification:

http://commonsware.com/blog/2010/08/11/activity-notification-ordered-broadcast.html

-- 
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] Activity/Service in separate process

2011-05-15 Thread Mark Murphy
On Sun, May 15, 2011 at 5:15 PM, Mark Cz  wrote:
> Is it possible for two apks to SHARE one service that runs in one of
> the apks process or runs in a different process ?

Yes.

> Meaning,
> I have two apks running in two different processes (the normal way),
> for simplicity each apk has only one activity.
> In addition each apk has one  android:name="com.me.global.Service"/>,
> can I share this service between the two (or more) apks ?

Yes.

> The apks have a different certificate, different packageName, what
> should I write in the manifest of each of them to achieve my goal ?

For the purposes of this answer, App A is the one with the service,
and App B is the one that is using the service from App A. Have App A
supply an  for the service (e.g., one with a custom
). Have App B use an Intent matching that filter when it calls
startService() or bindService().

-- 
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] Google I/O 2011 Session material downloads/pdfs working for anyone?

2011-05-15 Thread Mark Murphy
I know that the ProTips presentation was delivered via a custom
Android app. I'm not sure if Reto plans on publishing a PDF or not.
Keep tabs on his blog to see if he announces something:

http://blog.radioactiveyak.com/

On Sun, May 15, 2011 at 11:46 AM, Adam Ratana  wrote:
> I enjoyed and found very useful many of the Android presentations from this
> year's Google I/O; however, I am unable to download the related session
> PDFs.  For example, the android protips
> at http://www.google.com/events/io/2011/sessions/android-protips-advanced-topics-for-expert-android-app-developers.html
> was useful, there's a decent amount of code that would be nice to examine.
>  Is the "Session presentation" link working for anyone?  I get a 404.  This
> is for a few of the other presentations with links as well.  Not sure if
> this is the right forum to ask about this, but given that some of the
> presenters themselves are present on here, figured it's worth a shot --
> Adam
>
> --
> 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


[android-developers] send lat and long using open socket

2011-05-15 Thread ingy abbas
I want to send this Lat and Long the gps current location on my open
socket between my android and my python server .

enter code here
public void onLocationChanged(Location loc)

{

GeoPoint point = new GeoPoint((int) (loc.getLatitude() * 1E6),
(int) (loc.getLongitude() * 1E6));


String Text = "My current location is: " +

"Latitud =" + loc.getLatitude()+

"Longitud =" +loc.getLongitude() ;
Toast.makeText(getApplicationContext(),

Text,

Toast.LENGTH_SHORT).show();
so i save it on string text and i add button to connect it to the
server now i want to send the lat and lang each time so how to send
this string using the open socket ??

-- 
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 did you get into Android development

2011-05-15 Thread DanH
I'm sorry to tell you that Android development is not a "career
path".  Android, as you know it, probably won't exist in 10 years, and
likely will be headed downhill in 5.  And even if it does survive it
will be a "dead end job".

If you want a job in software development (and not in management or
marketing), you need to broaden your knowledge.  Learn database (more
than the narrow POV of Android), learn communications.  Learn all the
different platforms you can find.  Learn assembly language, learn C++,
and, perhaps, even RPG (there's still a big market for RPG
programmers).  Learn about compilers -- parsing and code generation
and optimization.  Learn algorithms -- trees and tries, Newton's
method and Quicksort.

You don't need to get this stuff "down cold", but you need the
exposure.  Then, ten years from now, you'll be faced with a knotty
problem and be able to solve it with a bit of knowledge you'd
forgotten you even knew.

And read some of the old "classics":  "GOTO Considered Harmful",
"Structured Programming", "Travels in Computerland", and several
others I can't recall at the moment.

On May 15, 5:10 pm, amenra horus  wrote:
> I'm  undergrad  computer science student and would love to make software
> development for android in particular a career path any tips or  intern work
> u can point me in the direction of?

-- 
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 did you get into Android development

2011-05-15 Thread DanH
It's one thing to be a kid at 15, playing around with programming.
It's entirely another to be a college student (or dropout) at 22 who
believes that he's going to "strike it rich" with apps.  Programming
is HARD WORK, and you don't learn how to do it well without
considerable effort (and practice).

It's a general rule that you need to spend about 10,000 hours doing
something to become an expert at it.  That's 5 years of 40-hour
weeks.  Patience and perseverance is required.

On May 15, 6:34 pm, Brill Pappin  wrote:
> Yah... maybe true... i don't know... but you and i both were those kids at
> one point.

-- 
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: Application not showing up in Settings->Manage Apps-->Running Apps

2011-05-15 Thread Dianne Hackborn
It is not treating it differently, this UI change was made in 2.3 to reduce
the worry people have about application processes being left around in the
background.

On Sun, May 15, 2011 at 1:20 PM, Eric  wrote:

> It's interesting to note that my Application is cached by Android as a
> 'cached process' immediately after I hit the HOME button.  Is this
> usually what happens, or is Android treating my app different than
> usual because it happens to consume a lot of memory (on the order of
> ~15MB)?
>
> --
> 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
>



-- 
Dianne Hackborn
Android framework engineer
hack...@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

[android-developers] Re: Image Picker and Cropper

2011-05-15 Thread neuromit
bump...

On May 14, 10:17 am, neuromit  wrote:
> Is there a way to pick an image from the gallery while also specifying
> that it should be cropped or resized to certain dimensions?

-- 
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: Image Picker and Cropper

2011-05-15 Thread Nicholas Johnson
is this a programming question?

-- 
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] Google I/O 2011 Session material downloads/pdfs working for anyone?

2011-05-15 Thread Adam Ratana
Hi Mark, if you click the link, there is a "Session Presentation" PDF link 
which purports to be the presentation.   He also said in the presentation to 
not write it all down because it will be released! :)  It's also the same 
for the other sessions that have PDFs attached. The error message and url it 
resolves to makes me think it might be a google permission issue.

Adam

On Sunday, May 15, 2011 8:23:31 PM UTC-4, Mark Murphy (a Commons Guy) wrote:
>
> I know that the ProTips presentation was delivered via a custom
> Android app. I'm not sure if Reto plans on publishing a PDF or not.
> Keep tabs on his blog to see if he announces something:
>
> http://blog.radioactiveyak.com/
>
> On Sun, May 15, 2011 at 11:46 AM, Adam Ratana  wrote:
> > I enjoyed and found very useful many of the Android presentations from 
> this
> > year's Google I/O; however, I am unable to download the related session
> > PDFs.  For example, the android protips
> > at 
> http://www.google.com/events/io/2011/sessions/android-protips-advanced-topics-for-expert-android-app-developers.html
> > was useful, there's a decent amount of code that would be nice to 
> examine.
> >  Is the "Session presentation" link working for anyone?  I get a 404. 
>  This
> > is for a few of the other presentations with links as well.  Not sure if
> > this is the right forum to ask about this, but given that some of the
> > presenters themselves are present on here, figured it's worth a shot --
> > Adam
> >
> > --
> > 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
>
> -- 
> 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: Open Source Chart

2011-05-15 Thread Josh Burton
Would be great if google would make a Android version of their chart api, so 
we can use it offline.

-- 
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: Task State Being Lost

2011-05-15 Thread Eric
This was working before I upgraded to 2.3.4.  I think a bug was
introduced in the latest version.  I would not be surprised if other
people find that their tasks are not resuming in the Activity where
they left off.

-- 
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] ListView item click can't work

2011-05-15 Thread a a
Dear All,

Why the following function can't work when i click the listview item?

@Override
protected void onListItemClick(ListView l, View v, int position, long id)
{
Log.d("aaa", "onListItemClick" + position);
}

-- 
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 did you get into Android development

2011-05-15 Thread Spooky


On May 15, 2:17 pm, DanH  wrote:
> If you look around, about half those posting here (and on other forums
> for other platforms) are kids who have essentially no programmer
> training but have managed to modify a few example projects to do
> interesting (to them) things and hence consider themselves to be
> programmers.  They all believe that they have (or very shortly will
> have) the next killer app (which is usually a game) and are only
> months away from striking it rich (if only those curmudgeons on the
> forums would answer their queries with a few hundred lines of free
> code rather than cryptic "read the documentation" responses).

Wow.  I haven't been around here long enough to comment on how
true or untrue that is, but I will say that if anyone looks at me that
way, please don't.  Yes, I do have some ideas for niche apps that
may (or may not) make any money.  Yes, I do learn best by taking
example code, along with reference material, and learning by
example and by applying whatever it is that I'm learning.  I DO
sometimes ask stupid questions, but I'm not looking for someone
to post a few hundred lines of free code  A simple pointer to
the appropriate documentation is every bit as welcome to me.
If I'm asking the question, it means I looked, but didn't find said
documentation.  Maybe I looked in the wrong place, maybe I
searched for the wrong thing, or maybe, given the damage done
to my sight (that would be the three brain surgeries to remove
three brain tumors) and to my cognitive abilities (it's commonly
referred to as "chemobrain").  I used to have a 153+ (the test only
went to 153, so I don't know what I would have scored had it
gone to a more reasonable level) IQ.  I haven't been tested
since my cancer nightmare, so I have no idea where it is now.

> (The #1 requirement for programming is a love of it that surpasses
> your love for money and often your love of food and sleep.)

I can see where that is true in many cases, but do not make the
assumption that it is universally true; it isn't.  Aside from a
few classes in college in which I wrote code in 8088
assembly, and another where I had to deal with Fortran, I
did quite a bit of C, combined with Lex and Yacc, also
combined with shell (Bourne shell at the time),  sed, awk,
etc.  Now, most of what I do (on the PC and Unix side) is
Tcl/Tk.  If you're curious, take a look at the hurricane
tracking program I wrote.  It's called JStrack, and is
online at http://www.jstrack.org/jstrack/ (jstrack.org
is a site donated by one of my users).  See the brewing
section for a couple of brewing-related programs.

Before Tcl/Tk, I did most everything in C, including, at
my first job out of college (Network Engineer at
Amoco Corporation's Network Design group), where
I wrote a network disaster and capacity planning
simulator for the N.E.T. IDNX multiplexer.  My
code was based on the actual IDNX routing
algorithm.  I never saw the actual code---I just
wrote my own to implement its algorithm.  In
a test against a professionally-developed system,
theirs failed to route circuits we had on our
network, where mine routed them correctly
(and they WERE working with the actual
code, where again, I had the specs, but
not the code, and implemented it in my
own C code).  It was part of my daily life
at work, as I was the design engineer for
the corporate backbone network (ALL
of Amoco's most critical networks
rode over my network).

But the point here, which so far I've missed getting
to, is that when I code, it's normally to solve some
problem, or address a specific immediate need for
which writing code is the best solution.  I don't
love writing code.  I don't dislike it, either.  It's
a tool that I use when I need it.

As for the money side of things, I am a cancer
survivor living on a monthly Social Security
Disability deposit.  Even a small amount of
extra cash would be a huge benefit for me, so
while I don't expect to strike it rich (though I
certainly would not complain if I did!), I am
hoping to make that extra $25 or $50 per month
that could make a big difference.  Will I get that
much from anything I write?  Who knows.
But I'll never know unless I try, right?

With that, the migraine I had all last week has
trying to come back all day, and is trying even
harder now...so I should probably get away from
this computer ASAP so I can get back to learning
and coding tomorrow.  :-)

Later,
   --jim
--
73 de N5IAL/4
Web site:  http://www.jstrack.org
E-mail:  spooky1...@gmail.com
"Do not look into waveguide with remaining eye."

-- 
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 did you get into Android development

2011-05-15 Thread DanH
About once a day I see something along the lines of the following.  (I
wasn't able to find an example in the Android forum, even though I
know I saw one yesterday or this morning [where the guy had the
audacity to ask for finished code], so this is from a Qt forum.):

Hello Guys...
I want to learn Qt. But I don't have any
idea about C or C++. But I want to
learn Qt.
I want to make a Dictionary. Like
English to other language. Guys help me.
I don't know how to work with slots,
main.cpp etc...
I use nokia qt sdk, qt creator 2.1. Guys,
is it necessary to learn c or c++ for Qt
programming?
Help me.
:-(
Thanx

On May 15, 9:41 pm, Spooky  wrote:
> On May 15, 2:17 pm, DanH  wrote:
>
> > If you look around, about half those posting here (and on other forums
> > for other platforms) are kids who have essentially no programmer
> > training but have managed to modify a few example projects to do
> > interesting (to them) things and hence consider themselves to be
> > programmers.  They all believe that they have (or very shortly will
> > have) the next killer app (which is usually a game) and are only
> > months away from striking it rich (if only those curmudgeons on the
> > forums would answer their queries with a few hundred lines of free
> > code rather than cryptic "read the documentation" responses).
>
> Wow.  I haven't been around here long enough to comment on how
> true or untrue that is, but I will say that if anyone looks at me that
> way, please don't.  Yes, I do have some ideas for niche apps that
> may (or may not) make any money.  Yes, I do learn best by taking
> example code, along with reference material, and learning by
> example and by applying whatever it is that I'm learning.  I DO
> sometimes ask stupid questions, but I'm not looking for someone
> to post a few hundred lines of free code  A simple pointer to
> the appropriate documentation is every bit as welcome to me.
> If I'm asking the question, it means I looked, but didn't find said
> documentation.  Maybe I looked in the wrong place, maybe I
> searched for the wrong thing, or maybe, given the damage done
> to my sight (that would be the three brain surgeries to remove
> three brain tumors) and to my cognitive abilities (it's commonly
> referred to as "chemobrain").  I used to have a 153+ (the test only
> went to 153, so I don't know what I would have scored had it
> gone to a more reasonable level) IQ.  I haven't been tested
> since my cancer nightmare, so I have no idea where it is now.
>
> > (The #1 requirement for programming is a love of it that surpasses
> > your love for money and often your love of food and sleep.)
>
> I can see where that is true in many cases, but do not make the
> assumption that it is universally true; it isn't.  Aside from a
> few classes in college in which I wrote code in 8088
> assembly, and another where I had to deal with Fortran, I
> did quite a bit of C, combined with Lex and Yacc, also
> combined with shell (Bourne shell at the time),  sed, awk,
> etc.  Now, most of what I do (on the PC and Unix side) is
> Tcl/Tk.  If you're curious, take a look at the hurricane
> tracking program I wrote.  It's called JStrack, and is
> online athttp://www.jstrack.org/jstrack/(jstrack.org
> is a site donated by one of my users).  See the brewing
> section for a couple of brewing-related programs.
>
> Before Tcl/Tk, I did most everything in C, including, at
> my first job out of college (Network Engineer at
> Amoco Corporation's Network Design group), where
> I wrote a network disaster and capacity planning
> simulator for the N.E.T. IDNX multiplexer.  My
> code was based on the actual IDNX routing
> algorithm.  I never saw the actual code---I just
> wrote my own to implement its algorithm.  In
> a test against a professionally-developed system,
> theirs failed to route circuits we had on our
> network, where mine routed them correctly
> (and they WERE working with the actual
> code, where again, I had the specs, but
> not the code, and implemented it in my
> own C code).  It was part of my daily life
> at work, as I was the design engineer for
> the corporate backbone network (ALL
> of Amoco's most critical networks
> rode over my network).
>
> But the point here, which so far I've missed getting
> to, is that when I code, it's normally to solve some
> problem, or address a specific immediate need for
> which writing code is the best solution.  I don't
> love writing code.  I don't dislike it, either.  It's
> a tool that I use when I need it.
>
> As for the money side of things, I am a cancer
> survivor living on a monthly Social Security
> Disability deposit.  Even a small amount of
> extra cash would be a huge benefit for me, so
> while I don't expect to strike it rich (though I
> certainly would not complain if I did!), I am
> hoping to make that extra $25 or $50 per month
> that could make a big difference.  Will I get that
> much from anything I write?  Who knows.
> But I'll never know unless I try, right?

Re: [android-developers] ListView item click can't work

2011-05-15 Thread a a
http://schemas.android.com/apk/res/android";
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minHeight="?android:attr/listPreferredItemHeight"
android:orientation="horizontal"
android:paddingRight="6dip"
android:paddingLeft="6dip"
android:paddingTop="5dip"
android:paddingBottom="5dip"
android:gravity="center_vertical" >











2011/5/16 a a :
> Dear All,
>
> Why the following function can't work when i click the listview item?
>
>    @Override
>    protected void onListItemClick(ListView l, View v, int position, long id)
>    {
>        Log.d("aaa", "onListItemClick" + position);
>    }
>

-- 
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: Help me in detecting sound pulses (basically frequency detection)

2011-05-15 Thread Soumyajit Roy
hey thanks for the linkif you have any other material then please
share it...
a material with some code will be great...

On May 13, 3:13 pm, Yahel  wrote:
> You need to take a look at an algorithm called "Fast Fourier
> Transform".
> You can find one implementation here 
> :http://www.badlogicgames.com/wordpress/?p=449
>
> Good luck.
>
> Yahel

-- 
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 did you get into Android development

2011-05-15 Thread Spooky
On May 15, 10:15 pm, DanH  wrote:
> About once a day I see something along the lines of the following.  (I
> wasn't able to find an example in the Android forum, even though I
> know I saw one yesterday

I seem to recall posting something to that effect a few days ago.
Thing is, it was true.  I really had seen whatever it was, and I
really couldn't find it again (and I spent a long time looking
before I posted).  Sometimes people actually ARE
being honest.

Later,
   --jim
--
73 de N5IAL/4
Web site:  http://www.jstrack.org
E-mail:  spooky1...@gmail.com
"Do not look into laser with remaining eye."

-- 
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: Task State Being Lost

2011-05-15 Thread Dianne Hackborn
Misc comments for the whole thread:

(1) Please do NOT use affinities named things like "Affinity.A".  The
affinity is a *global* namespace.  If some other app happens to use that
same name, your two apps will get mixed together.  If you want separate
affinities within your own app use a name like ":affinity1" like we do for
process names etc.

(2) This mechanism is intrinsic to how app switching works (for example
tapping on an app icon in home and bringing the app's task up to the front
in its last state), so it is definitely not just broken.

(3) Make sure you are not setting any of the various flags that cause
activities to be finished when their task is brought to the foreground or
other such thing; this is how you make the task reset when this happens.
 There must be something like that going on, because otherwise you are in
the default case of launching apps from home which definitely does work.

(4) Take a look at any messages printed in the log when switching tasks.
 Especially useful can be the event log (adb shell logcat -b event) which
will have a log for every activity that gets finished and the reason it is
finished.

On Sun, May 15, 2011 at 6:53 PM, Eric  wrote:

> This was working before I upgraded to 2.3.4.  I think a bug was
> introduced in the latest version.  I would not be surprised if other
> people find that their tasks are not resuming in the Activity where
> they left off.
>
> --
> 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
>



-- 
Dianne Hackborn
Android framework engineer
hack...@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

[android-developers] Crash Reports - ACRA v4 beta started

2011-05-15 Thread Kevin Gaudin


Hi all,

I had promised it months ago... and it's finally here!

I published one week ago the first beta release of ACRA v4. It finally is a v4, 
because there have been so many changes since ACRA 3.1 that a simple 3.2 
version was just not realistic enough!

The archive can be downloaded here:
http://code.google.com/p/acra/downloads/detail?name=acra-4.0.0b.zip

Some documentation:

   - Setup instructions: 
   http://code.google.com/p/acra/wiki/BasicSetup
   - Advanced usage: 
   here: http://code.google.com/p/acra/wiki/AdvancedUsage
   - Reports fields (old and new): 
   here: http://code.google.com/p/acra/wiki/ReportContent
   - For maven users, a repository is now available: 
   are listed here: http://code.google.com/p/acra/wiki/Maven
   
What are the most significant changes ? Full details are available in the 
ChangeLog (http://code.google.com/p/acra/wiki/ChangeLog) but lets sum this 
up:

   - New data added to reports:
  - logcat: default, events, radio (requires READ_LOGS permission)
  - result of 'dumpsys meminfo' for your application process
  - application version code
  - phone device id (requires READ_PHONE_STATE permission)
  - text events from the system dropbox (requires READ_LOGS)
  - application start date
  - device features
  - report unique id
  - application installation unique id
  - external storage state
  - settings (system and secure)
  - is silent ?
   - As requested by many, a report should only be notified once to the user. 
   Reports which could not be sent due to bad network are still sent but 
   without annoying the user anymore.
   - You can now implement your own Report Sender and do whatever you want 
   with reports data on the device.
   - Basic HTTP Authentification is available for those using the formUri 
   parameter to send reports to a custom script
   - Reports can be sent by a mail Intent, for applications where INTERNET 
   permission is not wanted
   - New SharedPreferences items:
  - include system logs (may contain private data)
  - include Device ID (IMEI) (this a private identifier)
  - include user email (the user inputs his email address in the 
  preference field)
  - always accept sending reports
  - The crash report dialog can now include an email field. The content 
  of this field is saved in SharedPreferences.
   - All android build related fields have been merged in a single BUILD 
   field
   - You can define which fields will be collected and sent. This can 
   improve performance and allow you to get rid of the fields you never read.

Lots of things have been rewritten, so this beta phase will last around a month 
so that we can ensure that there is no major issue using ACRA v4 instead of 
ACRA v3.

As I have really limited time to do deep testing, ACRA relies on your 
testing and bug reports!

Thank you all!

Kevin

-- 
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] NFC Mifare Ultralight Tag write error

2011-05-15 Thread Ajith Kamath
Hi all

I am trying to write Ndef message into Mifare Ultralight Tag.
But I am getting following error:

05-12 17:50:04.686: INFO/ActivityManager(121): Starting: Intent {
act=android.nfc.action.NDEF_DISCOVERED dat=tel:xxx-xxx- flg=0x3000
cmp=com.android.apps.tag/.WriteTagActivity (has extras) } from pid -1
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): Failed
to write tag
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566):
java.io.IOException: Tag is not ndef
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
android.nfc.tech.Ndef.writeNdefMessage(Ndef.java:211)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
com.android.apps.tag.WriteTagActivity.writeTag(WriteTagActivity.java:173)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
com.android.apps.tag.WriteTagActivity.onNewIntent(WriteTagActivity.java:136)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
android.app.Instrumentation.callActivityOnNewIntent(Instrumentation.java:1119)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
android.app.ActivityThread.deliverNewIntents(ActivityThread.java:1722)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
android.app.ActivityThread.performNewIntents(ActivityThread.java:1734)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
android.app.ActivityThread.handleNewIntent(ActivityThread.java:1742)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
android.app.ActivityThread.access$2300(ActivityThread.java:117)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
android.app.ActivityThread$H.handleMessage(ActivityThread.java:978)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
android.os.Handler.dispatchMessage(Handler.java:99)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
android.os.Looper.loop(Looper.java:123)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
android.app.ActivityThread.main(ActivityThread.java:3683)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
java.lang.reflect.Method.invokeNative(Native Method)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
java.lang.reflect.Method.invoke(Method.java:507)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
05-12 17:50:04.799: ERROR/com.android.apps.tag.WriteTagActivity(566): at
dalvik.system.NativeStart.main(Native Method)
05-12 17:50:04.799: INFO/com.android.apps.tag.WriteTagActivity(566): in
onResume() mAdapter!=null
05-12 17:50:04.912: ERROR/NFC JNI(248): phLibNfc_RemoteDev_CheckPresence()
returned 0x00ff[NFCSTATUS_FAILED]


I had enabled WriteTagActivity.java and was trying the write application.
Problem is that the code block from where this IOException is occuring tells
me that the tag is already Ndef formatted.

heres the block  which gets excecuted:

Ndef ndef = Ndef.get(tag);
if (ndef != null) {
ndef.connect();
if (!ndef.isWritable()) {
setStatus("Tag is read-only.", false);
return false;
}
if (ndef.getMaxSize() < mSize) {
setStatus("Tag capacity is " + ndef.getMaxSize() + "
bytes, message is " +
mSize + " bytes.", false);
return false;
}
ndef.writeNdefMessage(mMessage);
setStatus("Wrote message to pre-formatted tag.", true);
return true;


Since ndef!=null block is getting executed, i presume its already ndef
formatted.
I don't get "Tag is read-only." or "Tag capacity is " errors..
Exception is happening  when ndef.writeNdefMessage(mMessage) is executed

Let me know if anyone knows why this error is occuring.

Thanks & Regards,
Ajith

-- 
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: Remotely trigger notifications

2011-05-15 Thread Mike
I'm actually talking about adding to a remote database in the cloud.
So something would have to tell the background service that something
has been added before this method could be used.

On May 15, 7:20 pm, Mark Murphy  wrote:
> On Sun, May 15, 2011 at 7:15 PM, Mike  wrote:
> > I am trying to write an app that will notify the user when a new piece
> > of content is added to my database.  I know I can make a service that
> > would just poll the database every two hours or so but I feel like
> > there is a much better way to do this.  Is this really the only and or
> > best way to do this?
>
> When you add a new piece of content to the database, raise a
> Notification. Or, if you think your client activity will be running at
> the time, use an ordered broadcast to either notify your activity or
> raise a Notification:
>
> http://commonsware.com/blog/2010/08/11/activity-notification-ordered-...
>
> --
> 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


Re: [android-developers] Re: help for chart/graph?

2011-05-15 Thread Hitendrasinh Gohil
hi dan,
thankx for reply.

ya there is a support for pinch zoom.but  what i want is to draw vertical
line at two points.and only  clipped area should be  zoom in-out.


-- 
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] Re: How to draw a circle on an image

2011-05-15 Thread harsh chandel
use custom view to draw the circle and then place it in the activity


On May 15, 2:42 am, Droid  wrote:
> I have an image that needs a red circe at x,y coords. Its in an image
> view. I can get x,y coords but no idea at all about how to place a red
> circle?

-- 
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: keeping track of time a user is actively using an android app

2011-05-15 Thread harsh chandel
You can use a base class  for all activty and use the timer code
within that class
if your program is long you wont have to artie the code in every class

On May 15, 12:51 am, TreKing  wrote:
> On Fri, May 13, 2011 at 2:58 PM, laurent bouis  wrote:
> > I did some research and the only suggestion I found so far is using the
> > onResume() and onPause() methods of activities to keep track of elapsed time
> > between those 2 calls; I would probably need to do this in each activity of
> > the application which doesn't seem to be a very elegant solution.
>
> Probably as good as it's going to get. Check out the delegation patterns
> discussed in this 
> thread:http://groups.google.com/group/android-developers/browse_thread/threa...
>
> You could easily have a delegate object that tracks the time spent in a
> given activity by calling mDelegate.startTiming() / mDelegate.stopTiming()
> in onStart() / onStop(), respectively, in each activity.
>
> Note that you should use the onStart() / onStop() pair. If you show a
> dialog, for example, your activity is still in use but it gets onPause()
> called.
>
> -
> 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] how to shutdown android using java code

2011-05-15 Thread M.Scott
I want to make an app that can shut down android ,
this is the method that I get from the Internet,but when I run it in
the emulator,
I get the following Error message:
Installation error: INSTALL_FAILED_SHARED_USER_INCOMPATIBLE
[2011-05-15 16:32:58 - CCMromoteControl] Please check logcat output
for more details.
[2011-05-15 16:32:58 - CCMromoteControl] Launch canceled!

public class ShutDownAndroid extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
Intent i = new Intent(Intent.ACTION_REBOOT);
i.setAction(Intent.ACTION_REBOOT);
i.putExtra("nowait", 1);
i.putExtra("interval", 1);
i.putExtra("window", 0);
sendBroadcast(i);
}
}

AndroidMainifest:

http://schemas.android.com/apk/res/android";
  package="ccm.romote.control"
  android:versionCode="1"
  android:versionName="1.0"
  android:sharedUserId="android.uid.system"
 >






 





-- 
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] Is there a walkthrough for extending View, especially for the XML layout files?

2011-05-15 Thread Brian Carmicle
Right now, I'm trying to extend Chronometer (1) with a class called
ResettableChronometer. When I try to use it, however, my app crashes
because it couldn't "inflate" ResettableChronometer from the XML
layout file I was using for that Activity. I've found some general
documentation on Views (2), which references LayoutInflater, but I'm
having trouble understanding how this all works (I'm new to Android).
Is there some sort of tutorial or walkthough that can help me
understand how to do this?

(1) http://developer.android.com/reference/android/widget/Chronometer.html
(2) http://developer.android.com/reference/android/view/View.html
(3) http://developer.android.com/reference/android/view/LayoutInflater.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


  1   2   >