[android-developers] Regarding CTS test apk Signing procedure

2010-05-07 Thread pradeep
Hi

I am trying to develop new cts testcases. After I ran those testcases
by adding them in CTS,
I got the below error.

Permission Denial: starting  instrumentation
ComponentInfo{com.android.cts.performance4/
android.test.InstrumentationTestRunner}
from pid=6365, uid=6365 not allowed because package
com.android.cts.performance4  does not have a signature matching the
target com.android.mms

I thought it is something related to signing the newly developed test
apks.

I have the below queries related to signing the cts test apks. I would
be grateful if any one can clear these doubts.

1.  What kind of signing should be followed to sign  cts test apks if
they have to be build in ubuntu linux.
2.  Do we need to get signed our certificate from any Certification
authority
3.  Since CTS test apks test other applications, do they need to be
signed with same certificate [used to sign android applications
present in the phone]. If yes , then is it required to specify that
private key in Android manifest file

Thanks,
Pradeep

-- 
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: Low Memory. No More Background Process

2010-05-07 Thread EboMike
1. That's a somewhat common message, but can you actually correlate it
to a problem? The message says background processes, and your app is
most likely not a background process. What is the exact problem?

2. Are you dealing with bitmaps at all?

3. Do you only see the problem when debugging, or also when you don't
have a debugger attached?

4. The obvious one - did you check for memory leaks?

-Mike


On May 6, 10:47 pm, Sasikumar.S sasikumar.it1...@gmail.com wrote:
 Hi,

 I'm facing a new problem in my app. That is 'Low Memory. No More Background
 Process'.
 In my app i'm just retrieving data from DB and displaying in custom
 Listview. I'm using view flipper also.
 when i start running my app its running fine. in few seconds its closing
 without any information.
 what's the problem in this ?
 Any suggestion ?

 --
 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 
 athttp://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] Paypal integration in my Application

2010-05-07 Thread jaimin mehta
Hi.

In my application i need to integrate paypal payment gateway.

But My main concerned is can Android market approved my application
with PAYPAL gateway ?

Because In Android market  uses Google Checkout for Payment Gateway

So can i use Paypal payment gateway in my application ?

can Android market approved my application with Paypal payment
gateway?

please do needful.

Regards
jaimin.

-- 
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: Low Memory. No More Background Process

2010-05-07 Thread Sasikumar.S
I'm not dealing with any bitmaps...
No memory leak in my DB.
Just retrieve data from DB and display in custom listview.


On Fri, May 7, 2010 at 12:10 PM, EboMike ebom...@gmail.com wrote:

 1. That's a somewhat common message, but can you actually correlate it
 to a problem? The message says background processes, and your app is
 most likely not a background process. What is the exact problem?

 2. Are you dealing with bitmaps at all?

 3. Do you only see the problem when debugging, or also when you don't
 have a debugger attached?

 4. The obvious one - did you check for memory leaks?

 -Mike


 On May 6, 10:47 pm, Sasikumar.S sasikumar.it1...@gmail.com wrote:
  Hi,
 
  I'm facing a new problem in my app. That is 'Low Memory. No More
 Background
  Process'.
  In my app i'm just retrieving data from DB and displaying in custom
  Listview. I'm using view flipper also.
  when i start running my app its running fine. in few seconds its closing
  without any information.
  what's the problem in this ?
  Any suggestion ?
 
  --
  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.comandroid-developers%2bunsubscr...@googlegroups.com
  For more options, visit this group athttp://
 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.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en




-- 
Thanks  Regards
Sasikumar.S

-- 
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: Low Memory. No More Background Process

2010-05-07 Thread EboMike
Let me rephrase my questions.

1. What EXACTLY happens?

2. How does it correlate to the message you're seeing?

3. Leaks can be anywhere, not just in the database. Having static
members is an excellent way to create leaks, but there are lots of
other potential problems.

-Mike


On May 7, 12:06 am, Sasikumar.S sasikumar.it1...@gmail.com wrote:
 I'm not dealing with any bitmaps...
 No memory leak in my DB.
 Just retrieve data from DB and display in custom listview.





 On Fri, May 7, 2010 at 12:10 PM, EboMike ebom...@gmail.com wrote:
  1. That's a somewhat common message, but can you actually correlate it
  to a problem? The message says background processes, and your app is
  most likely not a background process. What is the exact problem?

  2. Are you dealing with bitmaps at all?

  3. Do you only see the problem when debugging, or also when you don't
  have a debugger attached?

  4. The obvious one - did you check for memory leaks?

  -Mike

  On May 6, 10:47 pm, Sasikumar.S sasikumar.it1...@gmail.com wrote:
   Hi,

   I'm facing a new problem in my app. That is 'Low Memory. No More
  Background
   Process'.
   In my app i'm just retrieving data from DB and displaying in custom
   Listview. I'm using view flipper also.
   when i start running my app its running fine. in few seconds its closing
   without any information.
   what's the problem in this ?
   Any suggestion ?

   --
   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.comandroid-developers%2Bunsubs
cr...@googlegroups.com
   For more options, visit this group athttp://
  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.comandroid-developers%2Bunsubs 
  cr...@googlegroups.com
  For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en

 --
 Thanks  Regards
 Sasikumar.S

 --
 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 
 athttp://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] Reading contacts

2010-05-07 Thread EPecorari
Hi,
I'm trying to read all the contacts stored in the phone using this
code:

Cursor cursorNumber =
context.getContentResolver().query( Contacts.Phones.CONTENT_URI,
new String[]
{ Contacts.Phones._ID, Contacts.Phones.NAME,
Contacts.Phones.NUMBER }, null, null, null );

but the result seems empty until the moment I sync the contacts with
Google. Is that possible? Is it a limitation of Google Contacts API?

-- 
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: Low Memory. No More Background Process

2010-05-07 Thread Sasikumar.S
Please see my log cat msg :



05-07 12:50:05.411: DEBUG/dalvikvm(979): GC freed 544 objects / 26080 bytes
in 251ms
05-07 12:50:11.361: DEBUG/dalvikvm(999): GC freed 5234 objects / 431272
bytes in 208ms
05-07 12:50:15.611: INFO/WindowManager(57): WIN DEATH: Window{43b51108
com.android.launcher/com.android.launcher.Launcher paused=false}
05-07 12:50:15.681: INFO/ActivityManager(57): Process android.process.acore
(pid 979) has died.
05-07 12:50:15.761: INFO/ActivityManager(57): Low Memory: No more background
processes.
05-07 12:50:20.002: DEBUG/dalvikvm(999): GC freed 4502 objects / 407936
bytes in 390ms
05-07 12:50:21.081: DEBUG/skia(983): purging 6K from font cache [1 entries]
05-07 12:50:21.753: DEBUG/dalvikvm(983): GC freed 1008 objects / 77688 bytes
in 479ms
05-07 12:50:21.792: DEBUG/DEBUG(999): 1
05-07 12:50:22.691: WARN/IInputConnectionWrapper(999): finishComposingText
on inactive InputConnection
05-07 12:50:24.352: DEBUG/dalvikvm(999): GC freed 1416 objects / 111352
bytes in 169ms
05-07 12:50:26.161: DEBUG/skia(57): purging 8K from font cache [1 entries]
05-07 12:50:26.613: DEBUG/dalvikvm(57): GC freed 2689 objects / 120408 bytes
in 403ms
05-07 12:50:26.681: INFO/ActivityManager(57): Process
com.android.inputmethod.latin (pid 983) has died.
05-07 12:50:26.792: WARN/ActivityManager(57): Scheduling restart of crashed
service com.android.inputmethod.latin/.LatinIME in 5000ms
05-07 12:50:27.671: INFO/ActivityManager(57): Low Memory: No more background
processes.
05-07 12:50:27.692: ERROR/ActivityThread(57): Failed to find provider info
for android.server.checkin
05-07 12:50:27.751: WARN/Checkin(57): Can't log event
SYSTEM_SERVICE_LOOPING: java.lang.IllegalArgumentException: Unknown URL
content://android.server.checkin/events
05-07 12:50:31.212: DEBUG/dalvikvm(999): GC freed 2145 objects / 107808
bytes in 251ms
05-07 12:50:33.171: INFO/ActivityManager(57): Start proc
com.android.inputmethod.latin for service
com.android.inputmethod.latin/.LatinIME: pid=1018 uid=10001 gids={3003,
1015}
05-07 12:50:34.081: DEBUG/dalvikvm(102): GC freed 226 objects / 10072 bytes
in 563ms
05-07 12:50:35.371: DEBUG/ddm-heap(1018): Got feature list request
05-07 12:50:49.262: DEBUG/dalvikvm(1018): Trying to load lib
/system/lib/libjni_latinime.so 0x43ab5ad0
05-07 12:50:49.452: DEBUG/dalvikvm(1018): Added shared lib
/system/lib/libjni_latinime.so 0x43ab5ad0
05-07 12:50:50.971: DEBUG/dalvikvm(999): GC freed 8818 objects / 576712
bytes in 809ms
05-07 12:50:51.062: INFO/ActivityManager(57): Start proc
android.process.acore for content provider
com.android.providers.userdictionary/.UserDictionaryProvider: pid=1031
uid=10001 gids={3003, 1015}
05-07 12:50:52.741: DEBUG/ddm-heap(1031): Got feature list request
05-07 12:50:59.192: WARN/ActivityManager(57): Timeout executing service:
ServiceRecord{43d25a00 com.android.inputmethod.latin/.LatinIME}
05-07 12:51:00.201: INFO/ActivityManager(57): ANR in process:
com.android.inputmethod.latin
05-07 12:51:00.201: INFO/ActivityManager(57): Annotation: Executing service
ComponentInfo{com.android.inputmethod.latin/com.android.inputmethod.latin.LatinIME}
05-07 12:51:00.201: INFO/ActivityManager(57): CPU usage:
05-07 12:51:00.201: INFO/ActivityManager(57): Load: 2.72 / 1.2 / 0.6
05-07 12:51:00.201: INFO/ActivityManager(57): CPU usage from 9911ms to 786ms
ago:
05-07 12:51:00.201: INFO/ActivityManager(57):
com.android.inputmethod.latin: 47% = 12% user + 34% kernel / faults: 6093
minor 438 major
05-07 12:51:00.201: INFO/ActivityManager(57):   system_server: 32% = 7% user
+ 25% kernel / faults: 4038 minor 311 major
05-07 12:51:00.201: INFO/ActivityManager(57):   org.myapp.first: 28% = 7%
user + 20% kernel / faults: 2957 minor 249 major
05-07 12:51:00.201: INFO/ActivityManager(57):   com.android.phone: 4% = 0%
user + 3% kernel / faults: 978 minor 39 major
05-07 12:51:00.201: INFO/ActivityManager(57):   adbd: 1% = 0% user + 1%
kernel
05-07 12:51:00.201: INFO/ActivityManager(57):   zygote: 1% = 0% user + 0%
kernel / faults: 140 minor 9 major
05-07 12:51:00.201: INFO/ActivityManager(57):   kswapd0: 0% = 0% user + 0%
kernel
05-07 12:51:00.201: INFO/ActivityManager(57):   logcat: 0% = 0% user + 0%
kernel / faults: 72 minor 5 major
05-07 12:51:00.201: INFO/ActivityManager(57):   rild: 0% = 0% user + 0%
kernel / faults: 37 minor 3 major
05-07 12:51:00.201: INFO/ActivityManager(57):   events/0: 0% = 0% user + 0%
kernel
05-07 12:51:00.201: INFO/ActivityManager(57):   pdflush: 0% = 0% user + 0%
kernel
05-07 12:51:00.201: INFO/ActivityManager(57):  +pre-initialized: 0% = 0%
user + 0% kernel
05-07 12:51:00.201: INFO/ActivityManager(57): TOTAL: 100% = 19% user + 75%
kernel + 4% iowait + 0% softirq
05-07 12:51:00.341: INFO/ActivityManager(57): Removing old ANR trace file
from /data/anr/traces.txt
05-07 12:51:00.752: INFO/Process(57): Sending signal. PID: 1018 SIG: 3
05-07 12:51:00.772: INFO/dalvikvm(1018): threadid=7: reacting to signal 3
05-07 12:51:01.021: INFO/Process(57): Sending signal. PID: 57 SIG: 3
05-07 

[android-developers] Re: Low Memory. No More Background Process

2010-05-07 Thread EboMike
Judging by the many times the GC kicks in, it sounds like something is
constantly allocating memory.

Did you run your app in the DDMS with the heap debug running?

And again-

1. What exactly is happening?

2. Do you see the same problem with and without debugger attached?

3. What is your app? What's the name, what's the package name?

4. I see a few warnings/errors in the log, are they related to your
app?

05-07 12:50:27.751: WARN/Checkin(57): Can't log event
SYSTEM_SERVICE_LOOPING: java.lang.IllegalArgumentException: Unknown
URL
content://android.server.checkin/events
05-07 12:51:04.873: WARN/UsageStats(57): Unexpected resume of
com.android.launcher while already resumed in org.myapp.first



-Mike


On May 7, 12:24 am, Sasikumar.S sasikumar.it1...@gmail.com wrote:
 Please see my log cat msg :

 05-07 12:50:05.411: DEBUG/dalvikvm(979): GC freed 544 objects / 26080 bytes
 in 251ms
 05-07 12:50:11.361: DEBUG/dalvikvm(999): GC freed 5234 objects / 431272
 bytes in 208ms
 05-07 12:50:15.611: INFO/WindowManager(57): WIN DEATH: Window{43b51108
 com.android.launcher/com.android.launcher.Launcher paused=false}
 05-07 12:50:15.681: INFO/ActivityManager(57): Process android.process.acore
 (pid 979) has died.
 05-07 12:50:15.761: INFO/ActivityManager(57): Low Memory: No more background
 processes.
 05-07 12:50:20.002: DEBUG/dalvikvm(999): GC freed 4502 objects / 407936
 bytes in 390ms
 05-07 12:50:21.081: DEBUG/skia(983): purging 6K from font cache [1 entries]
 05-07 12:50:21.753: DEBUG/dalvikvm(983): GC freed 1008 objects / 77688 bytes
 in 479ms
 05-07 12:50:21.792: DEBUG/DEBUG(999): 1
 05-07 12:50:22.691: WARN/IInputConnectionWrapper(999): finishComposingText
 on inactive InputConnection
 05-07 12:50:24.352: DEBUG/dalvikvm(999): GC freed 1416 objects / 111352
 bytes in 169ms
 05-07 12:50:26.161: DEBUG/skia(57): purging 8K from font cache [1 entries]
 05-07 12:50:26.613: DEBUG/dalvikvm(57): GC freed 2689 objects / 120408 bytes
 in 403ms
 05-07 12:50:26.681: INFO/ActivityManager(57): Process
 com.android.inputmethod.latin (pid 983) has died.
 05-07 12:50:26.792: WARN/ActivityManager(57): Scheduling restart of crashed
 service com.android.inputmethod.latin/.LatinIME in 5000ms
 05-07 12:50:27.671: INFO/ActivityManager(57): Low Memory: No more background
 processes.
 05-07 12:50:27.692: ERROR/ActivityThread(57): Failed to find provider info
 for android.server.checkin
 05-07 12:50:27.751: WARN/Checkin(57): Can't log event
 SYSTEM_SERVICE_LOOPING: java.lang.IllegalArgumentException: Unknown URL
 content://android.server.checkin/events
 05-07 12:50:31.212: DEBUG/dalvikvm(999): GC freed 2145 objects / 107808
 bytes in 251ms
 05-07 12:50:33.171: INFO/ActivityManager(57): Start proc
 com.android.inputmethod.latin for service
 com.android.inputmethod.latin/.LatinIME: pid=1018 uid=10001 gids={3003,
 1015}
 05-07 12:50:34.081: DEBUG/dalvikvm(102): GC freed 226 objects / 10072 bytes
 in 563ms
 05-07 12:50:35.371: DEBUG/ddm-heap(1018): Got feature list request
 05-07 12:50:49.262: DEBUG/dalvikvm(1018): Trying to load lib
 /system/lib/libjni_latinime.so 0x43ab5ad0
 05-07 12:50:49.452: DEBUG/dalvikvm(1018): Added shared lib
 /system/lib/libjni_latinime.so 0x43ab5ad0
 05-07 12:50:50.971: DEBUG/dalvikvm(999): GC freed 8818 objects / 576712
 bytes in 809ms
 05-07 12:50:51.062: INFO/ActivityManager(57): Start proc
 android.process.acore for content provider
 com.android.providers.userdictionary/.UserDictionaryProvider: pid=1031
 uid=10001 gids={3003, 1015}
 05-07 12:50:52.741: DEBUG/ddm-heap(1031): Got feature list request
 05-07 12:50:59.192: WARN/ActivityManager(57): Timeout executing service:
 ServiceRecord{43d25a00 com.android.inputmethod.latin/.LatinIME}
 05-07 12:51:00.201: INFO/ActivityManager(57): ANR in process:
 com.android.inputmethod.latin
 05-07 12:51:00.201: INFO/ActivityManager(57): Annotation: Executing service
 ComponentInfo{com.android.inputmethod.latin/com.android.inputmethod.latin.L 
 atinIME}
 05-07 12:51:00.201: INFO/ActivityManager(57): CPU usage:
 05-07 12:51:00.201: INFO/ActivityManager(57): Load: 2.72 / 1.2 / 0.6
 05-07 12:51:00.201: INFO/ActivityManager(57): CPU usage from 9911ms to 786ms
 ago:
 05-07 12:51:00.201: INFO/ActivityManager(57):
 com.android.inputmethod.latin: 47% = 12% user + 34% kernel / faults: 6093
 minor 438 major
 05-07 12:51:00.201: INFO/ActivityManager(57):   system_server: 32% = 7% user
 + 25% kernel / faults: 4038 minor 311 major
 05-07 12:51:00.201: INFO/ActivityManager(57):   org.myapp.first: 28% = 7%
 user + 20% kernel / faults: 2957 minor 249 major
 05-07 12:51:00.201: INFO/ActivityManager(57):   com.android.phone: 4% = 0%
 user + 3% kernel / faults: 978 minor 39 major
 05-07 12:51:00.201: INFO/ActivityManager(57):   adbd: 1% = 0% user + 1%
 kernel
 05-07 12:51:00.201: INFO/ActivityManager(57):   zygote: 1% = 0% user + 0%
 kernel / faults: 140 minor 9 major
 05-07 12:51:00.201: INFO/ActivityManager(57):   kswapd0: 0% = 0% user + 0%
 kernel
 05-07 12:51:00.201: 

[android-developers] Pay pal Integration in my application

2010-05-07 Thread RamaMohan
Hi all,
I am developing an application which consist of performing some
shopping related type.So i need to integrate pay pal in my
application.I found that In  pay pal site they given some sample code
in java but i am not sure that it wont work for android.

If anyone knows , how to implement pay pal with in the application.

Thanks in advance
Ram

-- 
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] BGRA format support

2010-05-07 Thread manjunath
Hi,

My hardware expect the pixel format for 32-bit to of BGRA instead of
RGBA which android is currently supporting.
Can anyone help me how and where to change the code for BGRA pixel
format.

I changed  the format in   SurfaceFlinger::createNormalSurfaceLocked
function in SurfaceFlinger.cpp. i.e. instead of
// format = PIXEL_FORMAT_RGBA_;
 format = PIXEL_FORMAT_BGRA_;

I also changed the format in DisplayHardware.cpp and
EGLDisplaySurface.cpp to  BGRA format.

But this change is not helping me on my target. when i launch a 32-bit
application like browser, I see the screen gets dim and no window
opens up.

I'm working on android 1.6x86.  Please help

-- 
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] BGRA format support

2010-05-07 Thread manjunath
Hi,

My hardware expect the pixel format for 32-bit to of BGRA instead of
RGBA which android is currently supporting.
Can anyone help me how and where to change the code for BGRA pixel
format.

I changed  the format in   SurfaceFlinger::createNormalSurfaceLocked
function in SurfaceFlinger.cpp. i.e. instead of
// format = PIXEL_FORMAT_RGBA_;
 format = PIXEL_FORMAT_BGRA_;

I also changed the format in DisplayHardware.cpp and
EGLDisplaySurface.cpp to  BGRA format.

But this change is not helping me on my target. when i launch a 32-bit
application like browser, I see the screen gets dim and no window
opens up.

I'm working on android 1.6x86.  Please help


Thanks,
Manjunath

-- 
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: Wifi drop Issues on Motorola Droid

2010-05-07 Thread Kostya Vasilyev

There might be a bug in Droid/Milestone.

I had a user report that my app, WiFi Manager crashes when enabling WiFi  
on the Droid.


All my code does is call wifiManager.setWifiEnabled(true)

-- Kostya


mort m...@sto-helit.de писал(а) в своём письме Fri, 07 May 2010 10:01:51  
+0400:


You're going to want to create a  
WifiManager.WifiLockhttp://developer.android.com/intl/de/reference/android/net/wifi/WifiM...


I get WiFi drops even when using Android's browser or when Market is
opened and updating some apps, often only a couple of seconds after
the connection is established. Doesn't Google use it's own APIs? Or is
there an additional bug on the Droid/Milestone?




--
Kostya Vasilyev - WiFi Manager + pretty widget -  
http://kmansoft.wordpress.com/sw


--
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] Neighbouring Cell info - Clarification needed

2010-05-07 Thread Vinay S
Hi,

I need one clarification regarding the NeighbouringCellInfo.

When i query for the getNeighbouringCellInfo() method, it returns me
with 5-6 values. Sample response is below:

06 05 2010 23:59:19.643  Neighbouring Cell Info :
Cell Info [1] :   Cell Id :20438  RSSI :-67  LAC :6012]
Cell Info [2] :   Cell Id :22058  RSSI :-69  LAC :6012]
Cell Info [3] :   Cell Id :22567  RSSI :-69  LAC :6010]
Cell Info [4] :   Cell Id :22259  RSSI :-69  LAC :6012]
Cell Info [5] :   Cell Id :22428  RSSI :-67  LAC :6012]
Cell Info [6] :   Cell Id :7  RSSI :85  LAC :0]

My Question is, where these Cell Id and LAC given are specific to the
SIM operator or is it from all providers in this area?
If it is from multiple operators.., how can I distinguish them?

Any kind of info regarding this will be useful.

Thanks and Regards,
Vinay

-- 
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] questions about developing soft keyboard

2010-05-07 Thread andu
how are you all?

I am trying to develop soft keyboard in my language, Amharic
(Ethiopian language). I start developing the soft keyboard by using
the sample soft keyboard with is included in the android SDK. But I
have the following questions to ask:

   1. How can I include  keyboard setting options such as vibrate on
key press, sound on key press, etc. such setting options are available
in English soft keyboard. If you have any idea about this, please help
me.

   2. The other question is related to copyright issue. If I can
succeed in developing the keyboard and want to sell it in market, am I
violating the copyright rule? Because I have developed this
application by using the sample soft keyboard.

thank you in advance


Andu

-- 
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] sending file to server

2010-05-07 Thread pramod.deore
Hello everybody, I am developing an application in that I am reading
image from mobile and send it to server.If size of image is less than
700kb then it is uploaded on server sucessfully, but for big size
images it throws OutOfMemoryException. So now I want to send image in
parts to server.  How should I do this?

 I want to read image convert it to Base64 format and send
it to server.I have Base 64 class which accept byte array and return
string. On server side image is decoded from Base64 directly in one
part(in one shot).

 So I think I had to create ont txt file and read image in
parts say 100kb , convert it to Base64 format and write that string to
txt file and after reading  whole file I had to send data from that
txt file to server in parts. I had tried to write the code but it is
not work properly. My code is like

import java.io.BufferedWriter;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileWriter;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.net.HttpURLConnection;
import java.net.MalformedURLException;
import java.net.URL;



import android.app.Activity;
import android.os.Bundle;

public class MicroFinalImageUp1 extends Activity
{

File myFile = new File(/sdcard/Images/c.jpeg);
File myFile1 = new File(/sdcard/Images/micro.txt);
PrintWriter pw ;
int noOfChunks ;
String base64String,str;
boolean test = true;
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState)
{
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
try
{
myFile1.createNewFile();
pw = new PrintWriter(myFile1);
}
catch (Exception e)
{
e.printStackTrace();
}

   sendData(0213456789_P~myimage.jpg~START~10);  // This line I
have to send every time before sending   actual data
readFile();
pw.flush();
pw.close();

sendData(0213456789_P~myimage.jpg~END~10);  //After sending
actual data I have to sent this

}



public void readFile()
{


 try
 {

 byte[] byteArray = new byte[102400];
 FileInputStream fstream = new FileInputStream(myFile);
 int bytesRead = 0;
 while((bytesRead = fstream.read(byteArray)) != -1)
 {
 pw = new PrintWriter(myFile1);
 str = new String(byteArray,0,bytesRead);

 base64String = Base64.encode(byteArray);
 writeDataToFile();

 System.out.println(**+base64String);

 sendData(0213456789_P~myimage.jpg~10~+base64String);
 base64String=null;
 pw.flush();
 pw.close();
 }




 }
 catch (IOException ioe)
 {
 ioe.printStackTrace();
 }



}

public void writeDataToFile()
{
try
{

pw.write(base64String);


}
catch (Exception e)
{
// TODO Auto-generated catch block
e.printStackTrace();
}

}


public void sendData(String line)
{
try
{

URL connectURL = new URL(My URL);
// connectURL is a URL object
System.out.println (After heating url);

HttpURLConnection conn =
(HttpURLConnection)connectURL.openConnection();
// allow inputs
conn.setDoInput(true);

// allow outputs
conn.setDoOutput(true);

// don't use a cached copy
conn.setUseCaches(false);

// use a post method
conn.setRequestMethod(POST);

// set post headers
conn.setRequestProperty(Connection,Keep-Alive);

// open data output stream
OutputStream dos ;

dos=conn.getOutputStream();

System.out.println (Before if statement);

byte[] arr = line.getBytes();

System.out.println (arr auccesfully 
created+arr.length);

dos.write(arr);

System.out.println (write to the page);

System.out.println (After if statement);
dos.flush();

InputStream is = conn.getInputStream();
int ch;
StringBuffer b =new StringBuffer();
System.out.println (Before second while loop);
while(( ch = is.read() ) != -1 )
   

[android-developers] Application Upgrade Related Questions

2010-05-07 Thread Alok Kulkarni
Hi , i wanted to ask a question regarding the upgrading of my
application. I have tested the following thing.
Put the new version of the APK on a server.Open the link of the APK
from the mobile browser .The mobile automatically downloads the APK
and asks for installation.Once installed , the application has got
upgraded.
Now can i do this thing programatically ?
I want that once the user starts the application , a web service will
be called internally which will check that an application upgrade is
available. If its available , i want to internally download the APK on
the device once the user says Yes. And then it should get installed
automatically.

I can download a given file from a given server on the device  on my
SDCard /application folder.
How can i invoke an automatic installation procedure? Can i do this
programatically ?
Thanks,
Alok.

-- 
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: Looking for advice into best way to store images within app

2010-05-07 Thread JimmyHoffa
Hi Rich,

Yes your situation sounds very similar to mine. I can imagine it's a
very common requirement.

Can I ask if you had to write your own content provider or were you
able to use the Media content provider to obtain cursor over your
images?

And are your images only visible through your app or would they appear
in your phones stock 'Gallery' app also?

Thanks,


On May 6, 10:45 pm, r...@thelogicbox richlarco...@gmail.com wrote:
 Jimmy

 Our app has a very similar need, Neatstreets is a reporting tool which
 can include many photo's taken for any given report.
 Westoreall essential report data to an internal db, which includes
 file names references to theimageson the external Sd card (under the
 package named folder - as you mention).

 This way the app can still function if the SDcard is swapped out,
 you'll just need to handle cases whereimagescannot be found. Useful
 if an important req is to maintain the ability to always raise new
 jobs (and your current sd becomes full). However our importance on
 maintaining ease of access to all previousimagesis probably less
 than yours as we also send all reports andimagesto the server.

 Rich

 On May 6, 7:54 pm, JimmyHoffa photos.d...@googlemail.com wrote:



  Thanks for reply.

  I should have stated that app will be offline and not relying on
  online storage so cloud is not really appropriate as the same screen
  will allow the user to grab a picture via the camera and thenstore
  the image.  I think I'll have a play with both media storage and
  database, and see what works best..

  On May 5, 8:00 pm, Kumar Bibek coomar@gmail.com wrote:

   It really depends on the amount of space yourimageswould take up. If
   it runs into less than 100KB, you can put them in the drawable folder.
   but, anything beyond than that is not a good practice. Your final
   apk's size will be huge.

   the best way is to keep yourimagessomewhere in the cloud, and access
   them through the app.

   Thanks and Regards,
   Kumar Bibek

   On May 5, 8:45 pm, JimmyHoffa photos.d...@googlemail.com wrote:

  0  vote down  star

Hi all,

I'm just looking for some insight into what would be the best way for
me tostoreimagesas part of my app.

I have an activity that represents a 'Job' which has a couple of
edittext's and underneath was planning on using the Gallery component
to showimagesrelevant to this job.

The job data is stored in a database (on the sdcard) so was also
thinking of creating a table tostore'JobImages' and having each
image stored as a byte array.

But I'm not sure if it would be better tostoretheimagesdirectly on
sdcard under a folder structure specific to my application and the
job. E.g. using the job ID number as a folder name.

Depending on which method I use will greatly determine the code that
goes into an 'adapter' that allows me to bind to the gallery component
so before I begin I was wondering if anyone has had the same design
problem and what option they chose.

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 
athttp://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 
   athttp://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 
  athttp://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 
 athttp://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] Common code reuse

2010-05-07 Thread Ajay
Hi,
   I have a set of common code (including .java files and resources) ,
which I have to use for two similar applications with different
package names (for different vendors). How can I maintain two packages
which share the common code without making two copies of the common
source?

Thank you,
AJ

-- 
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: updating a contact in 2.x Contacts API

2010-05-07 Thread JKDESAI

Thanks for your replay.

Here is the scenario I am following.

First of all, I am getting a curser for the Contact at some particular
Id using this:

contactCursor =
getContentResolver().query(ContactsContract.Contacts.CONTENT_URI,
null,
ContactsContract.Contacts._ID +  = ?,
new String[]{id}, null);

Now  I need to update the GIVEN_NAME and FAMILY_NAME  of this contact.

For that, What Id I have to pass in the withSelection(String,
String[]) method along with Data.CONTACT_ID ?

I have tried by getting RAW_DATA_ID but no success.

Please help me.

On May 5, 9:53 pm, Dmitri Plotnikov dplotni...@google.com wrote:
 Your query says: update _all_ data rows for this contact, setting one of
 the fields to John and another to Abraham.  Data rows include phone
 numbers, emails, photos, you-name-it.  What you need to do is find a
 specific data row you want to update and then use its _id in the selection
 (or, more commonly, in the URI itself).

 Cheers,
 - Dmitri



 On Tue, May 4, 2010 at 6:46 AM, JKDESAI jk.shona17...@gmail.com wrote:

  On Apr 19, 2:41 pm, Timo Prill timo.pr...@googlemail.com wrote:
   hi all,

   i got a problemupdatingacontact'sdetails.
   i use the following code to update thecontactname:
   operations is a ArrayList of ContentProviderOperation.

   operations.add(ContentProviderOperation.newUpdate(
                        ContactsContract.Data.CONTENT_URI)
                        .withSelection(Data._ID + =?, new String[]{id})

   .withValue(Data.MIMETYPE,StructuredName.CONTENT_ITEM_TYPE)
                        .withValue(StructuredName.GIVEN_NAME, firstName)
                        .withValue(StructuredName.FAMILY_NAME, lastName)
                        .build());

   contentResolver.applyBatch(ContactsContract.AUTHORITY, operations);

   but after this query, thecontactname is not updated.. (at least the
   name did not change in the phone's addressbook)
   i cant figure out why...what am i doing wrong? must be a simple thing i
   am missing..

   thanks in advance
   timo

   --
   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.comandroid-developers%2bunsubscr...@googlegroups.com
   For more options, visit this group athttp://
  groups.google.com/group/android-developers?hl=en

  Hi,

  I have used your code snippet for updating contact details with API
  2.0.

  But using that, display name is updated successfully, but it deletes
  all the other information like phone number and email.

  Can you tell me why it happens?..or I am missing something...

  Here Data used is android.provider.ContactsContract.Data.

  The same code I have used is as below:

                             ArrayListContentProviderOperation
  operations =
                                         new
  ArrayListContentProviderOperation();

   operations.add(ContentProviderOperation.newUpdate(

   ContactsContract.Data.CONTENT_URI).withSelection(
                              Data.CONTACT_ID + =?, new String[]
  { id }).withValue(
                              StructuredName.GIVEN_NAME, John).withValue(
                                         StructuredName.FAMILY_NAME,
  Abraham).build());

                                  try {

   getContentResolver().applyBatch(ContactsContract.AUTHORITY,
  operations);
                                  } catch (RemoteException e) {
                                         System.out.println(Exception :   +
  e.getMessage());
                                         e.printStackTrace();
                                 } catch (OperationApplicationException e) {
                                         System.out.println(Exception :  +
  e.getMessage());
                                         e.printStackTrace();
                                 }

  Please share your thoughts.

  --
  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.comandroid-developers%2bunsubscr...@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 
 athttp://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 

[android-developers] [Help] how to draw multiple lines in Edittext?

2010-05-07 Thread Vincent Tsao
i have a customized LinkedEditText extends from EditText, and override the
onDraw method as below:

protected void onDraw(Canvas canvas) {
canvas.drawColor(paperColor);

int count = getLineCount();
int height = this.getMeasuredHeight();
int line_height = this.getLineHeight();
int page_size = height / line_height + 1;

if (count  page_size) {
count = page_size;
}

for (int i = 1; i  count; i++) {
int posY = i * line_height;

canvas.drawLine(0, posY, getRight(), posY, linePaint);
canvas.save();

}

  super.onDraw(canvas);
  canvas.restore();
}

here is what this customized EdtiText looks like:

[image: new_note_1.png]


as you can see, the text line-height didn't match the lines which i draw.

but AK notes App did it perfect:

[image: ak_note_1.png]


any idea what' wrong did i do? 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=ennew_note_1.pngak_note_1.png

[android-developers] Re: I've found a way to stop piracy of my apps

2010-05-07 Thread Lee
As an aside, why don't google provide their own official API to allow
apps to check with the market whether they've been purchased or not ?

Perhaps it's the 'any security which can be conceivably broken is
useless' line ?

I would be happy with any protection mechanism which forced my apk to
be hacked in order to install it on a non-rooted phone, instead of the
current 'just copy it over, it'll work fine' situation.
I don't need 100% security.

Lee

-- 
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] Gallery with Listview

2010-05-07 Thread RANJAN BANIK
Hi,

I want a screen which will consist of a gallery on the upper half and
a list view in lower half. I dont have any idea how to do it. Please
help me with some example.

Thanks in advance
Ranjan

-- 
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] Common code reuse

2010-05-07 Thread Mark Murphy
Ajay wrote:
 Hi,
I have a set of common code (including .java files and resources) ,
 which I have to use for two similar applications with different
 package names (for different vendors). How can I maintain two packages
 which share the common code without making two copies of the common
 source?

You can compile the source code into a JAR and have the other projects
incorporate that JAR file. However, resources are then a problem -- you
can't use R.layout, R.id, R.string, or similar ways to identify those
resources.

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

_Beginning Android 2_ from Apress Now Available!

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


[android-developers] Re: how to get the camera's focal length

2010-05-07 Thread g k
Thanks for your response.
I think the focal length in the Samasun Glaxy is constant - so it can
be measured once.
Gilad

On Mar 24, 10:01 pm, Streets Of Boston flyingdutc...@gmail.com
wrote:
 In the SDK, you can't.

 There's no access to the camera's shutter-time, aperture, ISO, white-
 balance (you can query the white-balance type, but not the exact
 kelvin and such), etc. No access for reading, no access for writing.

 On Mar 23, 6:16 am, g k gilad.priv...@gmail.com wrote:



  Hello,

  I allready saw Kumar asking  - Subject: [android-developers] How to
  get camera specs. - msg#00106 ,

  Haven't seen any response on this.

  Thanks,
  gilad- Hide quoted text -

 - Show quoted text -

-- 
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] BitmapFactory.decodeStream thread safe ?

2010-05-07 Thread Agus
Is the BitmapFactory.decodeStream method thread safe?

-- 
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 get dimensions of image

2010-05-07 Thread pawan nimje
Hi i have a image in drawable folder and i need to get dimensions of that image.

i tried BitmapFactory,getHeight etc but it is retunning me null

plz help

-- 
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 build the gallery application.

2010-05-07 Thread SaiKiranVeluri
Hi,

I have downloaded the complete software stack, and now i want to
compile the Gallery application separately from Eclipse IDE, when i am
trying to compile it by copying the gallery source separately its
giving lots of compilation errors, so could anybody let me know what
other packages i need to include and how do i include it in the
eclipse to make it compile without any errors?

Thanks  Regards,
Sai Kiran V

-- 
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] Health Care

2010-05-07 Thread olipolus
http://health-olipolus.blogspot.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] how to build the gallery application.

2010-05-07 Thread Mark Murphy
SaiKiranVeluri wrote:
 Hi,
 
 I have downloaded the complete software stack, and now i want to
 compile the Gallery application separately from Eclipse IDE, when i am
 trying to compile it by copying the gallery source separately its
 giving lots of compilation errors, so could anybody let me know what
 other packages i need to include and how do i include it in the
 eclipse to make it compile without any errors?

The Gallery application most likely cannot be built using the SDK. Most
of the built-in applications need to be built as part of the firmware.

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

Android Online Training: 10-14 May 2010: http://onlc.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: [Help] how to draw multiple lines in Edittext?

2010-05-07 Thread Vincent Tsao
any help?



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

Re: [android-developers] How to get dimensions of image

2010-05-07 Thread Mark Murphy
pawan nimje wrote:
 Hi i have a image in drawable folder and i need to get dimensions of that 
 image.
 
 i tried BitmapFactory,getHeight etc but it is retunning me null

getResources().getDrawable().getIntrinsicHeight()

(or getMinimumHeight(), depending on what it is you are trying to do)

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

Android Online Training: 10-14 May 2010: http://onlc.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] Debug key expired and problems to get a new one

2010-05-07 Thread carknue
I started android developping a year ago With Eclipse on a Windows
Machine. Recently I switched to Mac OS X. Android developping worked
fine with newest Eclipse and Android MacOS SDK on my iMac until my
debug.kestore expired yesterday. Goggle suggests in this case to
delete the old key and a new key should be generated automacially. But
this is not working for me. Maybe it is just a missing path for the
keytool. But how do I have to set this path and where? I looked into
the JDK folders, but there are only symbolic links. Could anybody give
me a detailed example how to set this keytool and sdk tools path in
Mac OS X SL?

And what debug.kestore will be used? In Eclipse settings I found a
path to the default debug.keystore and a custom debug.kestore. What is
the difference?

-- 
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: Wifi drop Issues on Motorola Droid

2010-05-07 Thread gcstang
I get drops on my Droid as well any where from seconds to minutes
after starting WiFi, whether using a browser or application.

On May 6, 6:52 am, KK krishnakumar.ramachand...@gmail.com wrote:
 I am trying to develop a streaming application and I am testing it on
 multiple devices. But I am seeing some problems on Motorola Droid with
 regards to wifi connection. The wifi connection drops occasionally and
 comes back in 30 seconds to 1 minute on the Droid. Sometimes while in
 the middle of streaming I get network connection errors even though I
 am standing very next to the wifi router. I am not finding this
 problem with any other devices. Has anyone found any similar issues
 with the Droid? Any idea what can be done in my program to fix this?

 Thanks
 KK

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


[android-developers] Re: how to build the gallery application.

2010-05-07 Thread SaiKiranVeluri
Thanks for the quick response Murphy, any idea like what build in
applications this gallery application is expecting to compile itself?,
from where we can get that info?

Thanks  Regards,
Sai Kiran V

On May 7, 4:52 pm, Mark Murphy mmur...@commonsware.com wrote:
 SaiKiranVeluri wrote:
  Hi,

  I have downloaded the complete software stack, and now i want to
  compile the Gallery application separately from Eclipse IDE, when i am
  trying to compile it by copying the gallery source separately its
  giving lots of compilation errors, so could anybody let me know what
  other packages i need to include and how do i include it in the
  eclipse to make it compile without any errors?

 The Gallery application most likely cannot be built using the SDK. Most
 of the built-in applications need to be built as part of the firmware.

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

 Android Online Training: 10-14 May 2010:http://onlc.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 
 athttp://groups.google.com/group/android-developers?hl=en

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


[android-developers] Re: How to get dimensions of image

2010-05-07 Thread skink


On May 7, 9:42 am, pawan nimje pawanni...@gmail.com wrote:
 Hi i have a image in drawable folder and i need to get dimensions of that 
 image.

 i tried BitmapFactory,getHeight etc but it is retunning me null

 plz help

 --

BitmapFactory,getHeight() cannot return null since there is no such
method

there is a method Bitmap,getHeight() but it cannot either return null
as it returns int

pskink

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


Re: [android-developers] How to get dimensions of image

2010-05-07 Thread pawan nimje
will try that ...

On Fri, May 7, 2010 at 5:28 PM, Mark Murphy mmur...@commonsware.com wrote:

 pawan nimje wrote:
  Hi i have a image in drawable folder and i need to get dimensions of that
 image.
 
  i tried BitmapFactory,getHeight etc but it is retunning me null

 getResources().getDrawable().getIntrinsicHeight()

 (or getMinimumHeight(), depending on what it is you are trying to do)

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

 Android Online Training: 10-14 May 2010: http://onlc.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.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en

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

Re: [android-developers] Re: how to build the gallery application.

2010-05-07 Thread Mark Murphy
SaiKiranVeluri wrote:
 Thanks for the quick response Murphy, any idea like what build in
 applications this gallery application is expecting to compile itself?,

I will say it again:

The Gallery application most likely cannot be built using the SDK. Most
of the built-in applications need to be built as part of the firmware.

This means what...is expecting to compile itself is: everything.

You are welcome to attempt to make a port of the Gallery application
that builds using just the SDK. You will need to find all unresolved
imports, look at the code from the firmware that is missing, and
determine if that is something you need to clone into your own project
or if it is something you can just comment out (perhaps disabling some
features).

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

Android Online Training: 10-14 May 2010: http://onlc.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] Interpolators and how to repeat endless

2010-05-07 Thread mac-systems
Hello,

im a bit lost in all that Animation Framework Interpolators.

I really looking for some Documentation about the Interpolators and
how i can group sets.

I trying to zoom a View in and then endless zoom out it bit and in
again. How can i obtain this effect ?





-- 
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 to get dimensions of image

2010-05-07 Thread pawan nimje
hey pskink u got me wrong ... i did not use BitmapFactory,getHeight ... i
jus wanted to let know that i have used all the
[bitmap,bitmapfactory,getHeight,getWidth etc]

and it gave nullpointer exception

so plz suggest some other method



On Fri, May 7, 2010 at 5:36 PM, skink psk...@gmail.com wrote:



 On May 7, 9:42 am, pawan nimje pawanni...@gmail.com wrote:
  Hi i have a image in drawable folder and i need to get dimensions of that
 image.
 
  i tried BitmapFactory,getHeight etc but it is retunning me null
 
  plz help
 
  --

 BitmapFactory,getHeight() cannot return null since there is no such
 method

 there is a method Bitmap,getHeight() but it cannot either return null
 as it returns int

 pskink

 --
 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.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en


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

Re: [android-developers] Re: CTS Failure in View.

2010-05-07 Thread LG
Any clue on this??
I am also facing the same issue.

LG


On Wed, May 5, 2010 at 7:14 AM, firewallbreak
firewallbr...@googlemail.comwrote:

 Soft bump


 On 5/3/10, Anonymous Anonymous firewallbr...@googlemail.com wrote:



 Hi All,

 Was playing with CTS ,and came across a failure like below

testAnimation
  fail
  junit.framework.AssertionFailedError: unexpected timeout at
 android.view.animation.cts.DelayedCheck.run DelayedCheck.java:51)

  Can anyone pass me some light on , how to fix this issue? or what should
 be the approach in cases like this?
 Any information will be appreciated.

 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.comandroid-developers%2bunsubscr...@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] ListActivity selection behaves oddly

2010-05-07 Thread momojo
I have a very large ListActivity with about 1000 items. I allow the
user to type so I can filter the list. The problem is that when I try
to grab the list item that the user clicks on (after filtering) I get
the wrong Item. I am obviously missing something in the API?

-- 
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: Wrong date in Calendar day layout, Showing Thursday 01-Jan-1970.

2010-05-07 Thread sandeep gupta
Thanks Brion,

After looking into the code found that problem is here in this snippet of
code:

/**
 * If the given intent specifies a time (in milliseconds since the
epoch),
 * then that time is returned. Otherwise, the current time is returned.
 */
public static final long timeFromIntentInMillis(Intent intent) {
// If the time was specified, then use that.  Otherwise, use the
current time.
long millis = intent.getLongExtra(EVENT_BEGIN_TIME, -1);
if (millis == -1) {
millis = System.currentTimeMillis();
}
return millis;
}

The  intent.getLongExtra is somtimes retuning zero and this should return
-1 if  not able to get correct value of milli second since  epoch.
One fix to this can be call  System.currentTimeMillis() if it return zero
also (as it calls for -1).

I am still looking root cause of this (why it returns zero somtimes ).

Thanks
Sandy






On Wed, May 5, 2010 at 1:31 AM, Brion Emde brione2...@gmail.com wrote:

 You don't show your code, so it's hard to see what the problem is. I'd
 guess that you are creating an uninitialized Calendar of some sort, so
 the date inside of it is zero, corresponding to the date that you
 report.

 A way to get a calendar of the current is like this:

 private Calendar mCalendar = GregorianCalendar.getInstance();



 On May 4, 6:35 am, sandeep gupta skgf...@gmail.com wrote:
  In Android 2.1, when I am opening Calendar application, going to Agenda
 view
  and from their if I go to Day  schedule, that date is shown as Thursday
  01-Jan-1970 in title bar.  It is not picking system date.
 
  This is same case for week and Month view. In week schedule it is showing
  December 1969 - January 1970 and for Month it display January 1970 at
  Calendar title bar. This is happening when I go to day/month/week
 schedule
  from Agenda page.
 
  I am not seeing any error in logcat message when wrong date is displayed.
  Here is the logcat message:
 
  # I/ActivityManager(   54): Starting activity: Intent {
  act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER]
  flg=0x1020 cmp=com.android.calendar/.LaunchActivity }
  D/AccountManagerService(   54): bind attempt failed for Session:
  expectLaunch false, connected false, stats (0/0/0), lifetime 0.001,
  getAccountsByTypeAndFeatures, legacy_hosted_or_google
  I/ActivityManager(   54): Starting activity: Intent { flg=0x2002
  cmp=com.android.calendar/.AgendaActivity }
  I/ActivityManager(   54): Displayed activity
  com.android.calendar/.AgendaActivity: 549 ms (total 678 ms)
  D/dalvikvm(   99): GC freed 617 objects / 32344 bytes in 169ms
  W/KeyCharacterMap(  137): No keyboard for id 0
  W/KeyCharacterMap(  137): Using default keymap:
  /system/usr/keychars/qwerty.kcm.bin
  I/ActivityManager(   54): Starting activity: Intent {
  act=android.intent.action.VIEW flg=0x2002
  cmp=com.android.calendar/.DayActivity (has extras) }
  D/PhoneWindow(  137): couldn't save which view has focus because the
 focused
  view com.android.calendar.agendalistv...@43c591f0 has no id.
  D/dalvikvm(  137): GC freed 1665 objects / 131536 bytes in 84ms
  I/ActivityManager(   54): Displayed activity
  com.android.calendar/.DayActivity: 601 ms (total 601 ms)
  #
 
  Can any body give some pointer to solve this.
 
  Thanks
  Sandy
 
  --
  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.comandroid-developers%2bunsubscr...@googlegroups.com
  For more options, visit this group athttp://
 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.comandroid-developers%2bunsubscr...@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] How to secure passwords

2010-05-07 Thread MSChoi
What is the secure way to store passwords on android device?

I found same topic in Android Developers Group.
Steve918 kindly shared a sample code for it but I can not download it
anymore.
http://steven.bitsetters.com/articles/2007/11/20/android-password-safe/

Does anybody know how to encrypt/decrypt password using Android
supporting secure algorithm?

-- 
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

2010-05-07 Thread ulqui
Hello

I have designed an application with a mediaPlayer
I have a listView with one button and two textView
if i click on the button , a speech appears like this with a progress
bar

http://www.callwave.com/landing/widgets_Gadgets_L1.aspx

So i think that i must use Speechview , right ?

but the problem it s i don t know how to use button or elements in xml
files in speechView because the inflate methode doesn t work with her

thanks a lot for your help

-- 
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] how to draw multiple lines in Edittext?

2010-05-07 Thread social hub
I believe you should include the height of your title bar and status bar as
well. If you account for one of them i guess it will look right



On Fri, May 7, 2010 at 6:54 AM, Vincent Tsao caojunvinc...@gmail.comwrote:

 any help?


  --
 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.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en


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

[android-developers] Re: How to get dimensions of image

2010-05-07 Thread skink


On May 7, 10:21 am, pawan nimje pawanni...@gmail.com wrote:
 hey pskink u got me wrong ... i did not use BitmapFactory,getHeight ... i
 jus wanted to let know that i have used all the
 [bitmap,bitmapfactory,getHeight,getWidth etc]

 and it gave nullpointer exception

 so plz suggest some other method



Bitmap b = BitmapFactory.decode[Whatever](...)

b.getWidth()
b.getHeight()

pskink

-- 
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] how to draw multiple lines in Edittext?

2010-05-07 Thread Vincent Tsao
On Fri, May 7, 2010 at 9:45 PM, social hub shubem...@gmail.com wrote:

 I believe you should include the height of your title bar and status bar as
 well. If you account for one of them i guess it will look right


hi, thanks for your reply.

so getMeasuredHeight() return me the whole view height, which means
getMeasuredHeight() = statusbar + title bar + my edit text?

-- 
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] Determine when application icon is clicked to launch the app

2010-05-07 Thread TreKing
On Thu, May 6, 2010 at 11:15 PM, Pankaj pankajiit...@gmail.com wrote:

 Is there any way to determine when the user clicked the app icon to launch
 the app ?


Nope.


 My question is do I get a call-back for this ?


onPause, and onStart.

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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] Application Upgrade Related Questions

2010-05-07 Thread TreKing
On Fri, May 7, 2010 at 4:14 AM, Alok Kulkarni kulsu...@gmail.com wrote:

 How can i invoke an automatic installation procedure? Can i do
 this programatically ?


I don't think so. The user must confirm any installation (well, except of
some built in apps like the Android Market which are apparently superior to
others and can do this).

You wouldn't want some malicious app installing crap on your phone silently
without your knowledge, now would you?

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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] how to draw multiple lines in Edittext?

2010-05-07 Thread Vincent Tsao
It remind me of considering some margin space, so i change my code as below:

protected void onDraw(Canvas canvas) {
canvas.drawColor(paperColor);

int count = getLineCount();
int height = this.getMeasuredHeight();
int line_height = this.getLineHeight();
int page_size = height / line_height + 1;

if (count  page_size) {
count = page_size;
}

   * int posY = 5; // i guess the margin-top may be 5 px :)*
for (int i = 1; i  count; i++) {
*posY +=  line_height;*

canvas.drawLine(0, posY, getRight(), posY, linePaint);
canvas.save();

}

  super.onDraw(canvas);
  canvas.restore();
}

finally it looks right, so i'm sure there is a margin space between my
EditText  and the default view , but i have no idea about how to get this
height? so i hard code it 5 px

any suggestion?

-- 
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: Can anyone help me make REST calls using HttpClient from Android?

2010-05-07 Thread Streets Of Boston
I can't help you with the preemptive authorization, but why can't you
use cookies?
Cookies, when used as user authentication/authorization, do not
violate any REST principles. In this case, cookies don't hold resource-
state. They hold application-state.

On May 6, 8:31 pm, Preston preston.crawf...@gmail.com wrote:
 I have some questions about a REST client that I'm writing for
 Android. I'm struggling with how to properly do preemptive
 authorization.

 Basically I'm storing client credentials encoded on the client. I want
 to pass them through whenever the user makes a request over HTTPS with
 some caching on the server side.

 #1 - I got the idea to use credentials as opposed to cookies or
 something of that nature from some REST developers. However, I wanted
 to check on the sanity of storing those credentials on the client.

 #2 - Assuming that sounds kosher, then here comes the part where I'm
 struggling. I'm struggling getting those credentials passed
 preemptively once I have them. I've looked at examples using
 HttpRequestInterceptor and they all show it pulling credentials out of
 a CredentialsProvider. Do I have to set that up or is there another
 way?

 Thanks,

 Preston

 --
 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 
 athttp://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] Starting Activity with Tabs

2010-05-07 Thread Károly Holczhauser
Hi Guys !

 I have four activity in a Tab and after the user clicked on the list I
would like to start another one activity, but I can't use
startActivity(Intent), because then I lost the TabHost view, and I get an
activity witch is reserving the full screen:( So the user won't be able to
click on the other tabs.
 What should I use? BroadCastReciver or What ?
 If anyone have any good idea please help on me.

 Thank you so much: Karoly from Hungary

-- 
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] Gallery with Listview

2010-05-07 Thread TreKing
On Fri, May 7, 2010 at 5:09 AM, RANJAN BANIK
ranjanfeelthema...@gmail.comwrote:

 I dont have any idea how to do it.


Sure you do.

You just said I want a screen which will consist of a gallery on the upper
half and a list view in lower half.

So common sense would dictate that you begin with a layout that has a
gallery view at the top and a list view at the bottom and see what happens.
Read the documentation for each view, play with the XML attributes, and see
what you get.

If you get stuck on some SPECIFIC problem, post back that specific problem
with DETAIL and you'll probably get a better response.

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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 implement gallery widget in circular order

2010-05-07 Thread Abdul Mateen
Hi,
Can any body tell me how to make Gallery widget circular.

-- 
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: Google should prohibit task killers on Android Market

2010-05-07 Thread Bob Kerns
While I agree that consuming a bunch of memory has an impact -- it
means apps have to be killed and restarted more often, for example --
there's no connection to GC.

GC is something that happens entirely within your own process, and is
not affected by memory usage by other processes. Allocating a bunch of
memory in your process will trigger the GC. The fact that somebody
else HAS a bunch of memory, but isn't running, will not. Nothing
another process does will trigger a GC in the foreground app.

On May 4, 10:52 am, Eric F ericfrie...@gmail.com wrote:
 On May 3, 11:59 pm, mort m...@sto-helit.de wrote:

  And what's wrong with resource consuming? I coud cache several MB of
  data in a non-running service, it wouldn't matter. Android would just
  kick it if the memory's required, and the service would just reload
  the data when it's restarted.
  It's similar with CPU usage. If your service happens to do something
  in the instance the task killer loads it, it'll be killed, even if it
  only does that on certain events or once a day? And some services just
  need to do more than others...
  Besides, most task managers only show the main application, not the
  service. So CPU usage alway is 0, and memory usage, as said, doesn't
  really matter.

 I don't think it's necessarily right to say there's nothing wrong
 with consuming a huge amount of memory if you're sleeping, because the
 low memory killer can just remove you.

 It's been my experience that the user's experience on the phone is
 largely correlated with memory and not CPU usage. When I am flipping
 between activities, stuff feels significantly less responsive as I see
 the GC run. Also, obviously if an activity has dropped out of memory
 because of the low memory killer and it needs to be recreated there's
 going to be slowdown.

 So for some service that is sleeping, but still in memory consuming a
 large amount of RAM, you can only make the claim that it is harmless
 if it doesn't cause extra GC in the foreground apps and also doesn't
 cause a situation where some activity was killed by the low memory
 killer instead of the service. Which I don't think is a claim you can
 make about a resource intensive service that is just sleeping but not
 stopped. Maybe Dianne could comment on that, maybe I'm wrong. But it
 seems to me that you can't guarantee that more activities wouldn't be
 able to fit in memory if the service was actually gone.

 Also, I didn't know that the application stop caused alarmmanager to
 unschedule the app, that certainly makes the use of it almost
 certainly not what the user wants. Perhaps it needs to stay in the API
 to maintain compatibility, but it can cause a pop up with an extra
 disclaimer. Kind of like .apk installs can only be initiated and not
 completed without interaction with the platform.

 -E

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] Re: [Help] how to draw multiple lines in Edittext?

2010-05-07 Thread social hub
u can try getTop getPaddingTop
as well Margins

getLayoutParams and from there getting margins leftmargin

you can google to find more info.

With those info you can properly identify what the initial adjustment will
be

it can be like start from paddingtop

hope it helps


On Fri, May 7, 2010 at 9:36 AM, Vincent Tsao caojunvinc...@gmail.comwrote:

 It remind me of considering some margin space, so i change my code as
 below:

 protected void onDraw(Canvas canvas) {
 canvas.drawColor(paperColor);

 int count = getLineCount();
 int height = this.getMeasuredHeight();
 int line_height = this.getLineHeight();
 int page_size = height / line_height + 1;

 if (count  page_size) {
 count = page_size;
 }

* int posY = 5; // i guess the margin-top may be 5 px :)*

 for (int i = 1; i  count; i++) {
 *posY +=  line_height;*


 canvas.drawLine(0, posY, getRight(), posY, linePaint);
 canvas.save();

 }

   super.onDraw(canvas);
   canvas.restore();
 }

 finally it looks right, so i'm sure there is a margin space between my
 EditText  and the default view , but i have no idea about how to get this
 height? so i hard code it 5 px

 any suggestion?

  --
 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.comandroid-developers%2bunsubscr...@googlegroups.com
 For more options, visit this group at
 http://groups.google.com/group/android-developers?hl=en


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

[android-developers] Re: Google should prohibit task killers on Android Market

2010-05-07 Thread Bob Kerns
The battery power frob is great! But I think it may already be good
enough to serve for this purpose. The apps that are consuming the most
battery power, and the apps that are consuming the most CPU, are
typically the same set.

I'm not arguing against your suggestion -- even if they were always
the same set, it would be more clear for the users. But we can educate
users to look there now for a clue to this information, even if it's
not perfect.

On May 4, 12:06 pm, Tomáš  Hubálek tom.huba...@gmail.com wrote:
 I think that cure can be the same approach as when battery is out of
 power. There is button Why? and it shows major consumers of the power.

 I think that Google could include in Android also some tool that shows
 major CPU  Memory eaters. Users after this info will decide whether
 they want such a greedy apps or not.

 Tom

 On 4 kvě, 19:52, Eric F ericfrie...@gmail.com wrote:





  On May 3, 11:59 pm, mort m...@sto-helit.de wrote:

   And what's wrong with resource consuming? I coud cache several MB of
   data in a non-running service, it wouldn't matter. Android would just
   kick it if the memory's required, and the service would just reload
   the data when it's restarted.
   It's similar with CPU usage. If your service happens to do something
   in the instance the task killer loads it, it'll be killed, even if it
   only does that on certain events or once a day? And some services just
   need to do more than others...
   Besides, most task managers only show the main application, not the
   service. So CPU usage alway is 0, and memory usage, as said, doesn't
   really matter.

  I don't think it's necessarily right to say there's nothing wrong
  with consuming a huge amount of memory if you're sleeping, because the
  low memory killer can just remove you.

  It's been my experience that the user's experience on the phone is
  largely correlated with memory and not CPU usage. When I am flipping
  between activities, stuff feels significantly less responsive as I see
  the GC run. Also, obviously if an activity has dropped out of memory
  because of the low memory killer and it needs to be recreated there's
  going to be slowdown.

  So for some service that is sleeping, but still in memory consuming a
  large amount of RAM, you can only make the claim that it is harmless
  if it doesn't cause extra GC in the foreground apps and also doesn't
  cause a situation where some activity was killed by the low memory
  killer instead of the service. Which I don't think is a claim you can
  make about a resource intensive service that is just sleeping but not
  stopped. Maybe Dianne could comment on that, maybe I'm wrong. But it
  seems to me that you can't guarantee that more activities wouldn't be
  able to fit in memory if the service was actually gone.

  Also, I didn't know that the application stop caused alarmmanager to
  unschedule the app, that certainly makes the use of it almost
  certainly not what the user wants. Perhaps it needs to stay in the API
  to maintain compatibility, but it can cause a pop up with an extra
  disclaimer. Kind of like .apk installs can only be initiated and not
  completed without interaction with the platform.

  -E

  --
  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 
  athttp://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 
 athttp://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] ListActivity selection behaves oddly

2010-05-07 Thread TreKing
On Fri, May 7, 2010 at 7:50 AM, momojo jason.kah...@gmail.com wrote:

  I get the wrong Item.


What's the index of the item you're clicking on versus the index of the item
you're actually getting?
This should tell you how it's behaving.

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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 isn’t multi-touch wor king for imagebuttons?

2010-05-07 Thread Bob Kerns
What about using a TouchDelegate to examine the touches first, and
forward them as separate events?

I haven't tried it, or even thought about it for more than two
minutes, but...

On May 4, 10:42 am, niko20 nikolatesl...@yahoo.com wrote:
 Hi,

 No, it's because the android team decided to implement MultiTouch in a
 way that it only can be used on one View. For example, ImageButtons
 are views. Each ImageButton is a seperate View object. The Android
 multitouch does not just map touches to multiple views like that
 (which I think it should, but the android team does not). Instead you
 end up having to create a View yourself, and drawing the three buttons
 yourself, since multitouch comes to a View as additional touch
 coordinates. In other words, you can only use multitouch per view.
 It can't spread across multiple views. You basically need to create
 one big view object that takes up most of the screen and then draw the
 buttons yourself, and then handle the multitouch messages passed to
 that view.

 Unless there is an easier way that I know of, but I dont think there
 is. IMO how they implemented multitouch is too hackish, and should
 have been transparent to developers by the system automatically
 posting messages to each view that was being touched, instead, you
 have to rewrite the apps completely to handle it.

 -niko

 On May 2, 11:28 am, Codeman codyrotw...@gmail.com wrote:





  I'm using imagebuttons that play sounds using SoundPool. Here is
  example code a couple of the imagebuttons:

  ImageButton Button1 = (ImageButton)findViewById(R.id.sound1);
  Button1.setOnTouchListener(new OnTouchListener() {

          public boolean onTouch(View v, MotionEvent event) {
              if (event.getAction() == MotionEvent.ACTION_DOWN ) {
                  mSoundManager.playSound(1);
                  return false;
              }

              return false;
          }
      });

  ImageButton Button2 = (ImageButton)findViewById(R.id.sound2);
  Button2.setOnTouchListener(new OnTouchListener() {

          public boolean onTouch(View v, MotionEvent event) {
              if (event.getAction() == MotionEvent.ACTION_DOWN ) {
                  mSoundManager.playSound(2);
                  return false;
              }

              return false;
          }
      });

  For some reason, it doesn't allow you to click multiple buttons at the
  same time. Is it because I'm building for 1.6 SDK?

  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 
  athttp://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 
 athttp://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] How to secure passwords

2010-05-07 Thread Kostya Vasilyev

Is this it?

http://code.google.com/p/android-passwordsafe/source/checkout

07.05.2010 16:59, MSChoi пишет:

What is the secure way to store passwords on android device?

I found same topic in Android Developers Group.
Steve918 kindly shared a sample code for it but I can not download it
anymore.
http://steven.bitsetters.com/articles/2007/11/20/android-password-safe/

Does anybody know how to encrypt/decrypt password using Android
supporting secure algorithm?

   



--
Kostya Vasilyev -- WiFi Manager + pretty widget -- 
http://kmansoft.wordpress.com/sw

--
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: Possible to call intent image gallery with scrolling to specific image?

2010-05-07 Thread Bob Kerns
Rather than replying in a random unrelated thread, and changing the
subject, you should post a message in a new thread.

The person you want to reach with the answer to your question may
never read this thread!

On May 5, 7:13 am, Timo Prill timo.pr...@googlemail.com wrote:
 hi,

 is it possible to call the native image gallery intent and pass an image
 uri (or s.th. else identifying an image) as
 an intent's extra so that the gallery automatically scrolls to the
 specific image?

 or maybe something similar?

 cheers

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


[android-developers] Re: Best practices for creating multiple app versions from a single codebase?

2010-05-07 Thread Bob Kerns
I don't recommend doing production builds directly in your Eclipse
environment.

Export a copy, and modify that. In fact, I strongly urge checking out
a pristine copy from revision control for real production builds.

I derive my build numbers from the Eclipse revision I'm building. I
inject that into the AndroidManifest.xml via an XSLT ant task.

I've been meaning to write up my build practices for a while; I keep
holding off for certain refinements, but I really should get to it
soon, since it's a recurring issue for people.

On May 4, 4:42 pm, Leigh McRae leigh.mc...@lonedwarfgames.com wrote:
 Since you talk about a generated ant file tt sounds like you're project
 was created using the android tool instead of Eclipse.  Is this
 correct?  I spent most of today trying to get a non-eclipse project
 going and had some success up until debugging.  I really wanted to use
 NetBeans but it looks like Eclipse is doing quite a bit under the hood
 for you when it comes to debugging.

 If you're using an Ant script for the main build, how are you using
 Eclipse with it?  I wrote something to inc the version number and
 Eclipse really doesn't like the AndroidManifest.xml  file touched.

 Leigh

 On 5/4/2010 4:36 PM, Alex (PS3 Friends) wrote:





  My solution was to create two different starter classes with different
  packages.  One for the paid version and the other for the free
  version.  Since the package name is used to identify the application
  in the market.  You can use this to customize the app, by setting
  properties in the different start classes.  I modified the generated
  Ant file to switch between the paid/free versions.  I created a task
  that uses regular expression replacements, identifying sections and
  replacing the starting class name depending on what I am deploying in
  the manifest.  You can even modify the XML layouts using this method.
  Essentially pre-processing prior to compilation.  The R class is the
  only issue, you need to make sure you include an * import for both
  packages otherwise it won't work, and you will have to modify code
  each time.  Also, Eclipse gets upset when you change things underneath
  it after compiling the R class, you need to delete the generated
  source directory.  This is the best solution I have come up with so
  far, it's not great but it works for me and it is scripted.

  Alex

  On May 4, 3:01 pm, Tomáš  Hubálektom.huba...@gmail.com  wrote:

  I'm thinking about the same thing.

  I believe thathttp://code.google.com/p/maven-android-plugin/couldbe
  a solution. Maven is very powerful tool for building (we are using it
  for JEE projects) so I'm sure that it will support also multiple APKs
  from one source code base.

  But I didn't looked into details yet.

  Tom

  On 4 kvě, 20:37, E.Peld...@gmail.com  wrote:

  Are there any viable approaches for creating multiple .APKs out of a
  single codebase?

  The apps may share the same code, but they could have different
  manifest files, different resources, or different external libraries
  (for example in an app with both free and paid versions, the free
  version could have a library for display ads).

  Ideally, this would be a single Eclipse project, with a way to specify
  which app to build/debug, and possibly a command line way to batch
  build everything.

  --
  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 
  athttp://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 
  athttp://groups.google.com/group/android-developers?hl=en

 --
 Leigh McRaewww.lonedwarfgames.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 
 athttp://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] Regarding layout drawing using code!

2010-05-07 Thread Aditya
Hello everyone,
Here am a new comer to Android, i have a query that can we draw layouts
using code?(without using XML file)
If yes, any one please give me some sample code.

Thanks in advance.
Aditya

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

[android-developers] Re: Problem with Saving and opening file on moto-droid

2010-05-07 Thread André
That was the problem! I had the permissions line in the wrong place.
And then it apparently works on 1.6 phones but not phones with a newer
version of android!

-André


On May 6, 9:54 pm, TreKing treking...@gmail.com wrote:
 On Thu, May 6, 2010 at 2:26 PM, André pha...@hotmail.com wrote:
  Is this correct?

 Think so - that's how I have mine set up and it works just fine.

 --- 
 --
 TreKing - Chicago transit tracking app for Android-powered 
 deviceshttp://sites.google.com/site/rezmobileapps/treking

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


[android-developers] Re: Struggling with Activity/View framework

2010-05-07 Thread Bob Kerns
The Activity may be killed, but the Application will not be. You can
hold onto state there.

However, it would be best to carefully study the lifecycle and look to
minimize how much information you keep there, and ALLOW information to
be discarded (or selected information to be kept) when the activity
that needs it is killed.

Note that simply starting a new activity does NOT guarantee the
previous activity is killed, it only allows for it

All the tools you need are there for information to persist with the
appropriate lifetime.

You should also consider persisting state in a database, preferences
object, or file, rather than retaining it in memory. There's tradeoffs
between memory usage and the cost of reloading data, but reducing
memory usage is important in this environment.

On May 4, 1:06 pm, Leigh McRae leigh.mc...@lonedwarfgames.com wrote:
 I am hoping that someone can help me out with my port to Android.  My
 game has abstracted out a few services and a couple of screens.  There
 services are fine but I have an options screen that needs to be
 implemented using native UI.

  From reading the docs, I gather that I should be using an Activity
 paired with a View for the screen.  The problem is that showing a screen
 forces my Activity to be killed.  I tried to implement the options
 screen using a dialog but then I am restricted from using another
 dialog, for feedback, in the screen.

 The whole life cycle of an Activity is really a ball breaker.  Most
 games load everything they need at startup and never allocate again.  So
 having a game save it's full state, not just save game, is a real
 challenge.  When you add in OpenGL, you pretty much have to keep a
 backing store of all the textures.

 What is one to do?

 --
 Leigh McRaewww.lonedwarfgames.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 
 athttp://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] Starting Activity with Tabs

2010-05-07 Thread Mark Murphy
Károly Holczhauser wrote:
 Hi Guys !
 
  I have four activity in a Tab and after the user clicked on the list I
 would like to start another one activity, but I can't use
 startActivity(Intent), because then I lost the TabHost view, and I get
 an activity witch is reserving the full screen:( So the user won't be
 able to click on the other tabs.
  What should I use? BroadCastReciver or What ?

IMHO, do not use tabs for navigation, particularly on a platform
targeting small screens like Android.

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

Android Training in NYC: 4-6 June 2010: http://guruloft.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 installed twice - may be key pwd change

2010-05-07 Thread MB
Hi James,
I did not try changing back the pwd to original pwd.

Now all the news users have only one icon, but the old users, from
first version have 2 icons.

Even if I change it back to old key pwd now,am not sure it will
install twice or once.

It could be a possibility that If i change the pwd to old one, the new
users who have only one icon, will get another now, as the pwd is
changing.

So still wondering,what could be the solution.

Could you pls advise.

Thanks,
AndyDev

On May 7, 6:31 am, James Wang jameswangc...@gmail.com wrote:
 First, If you did sign your app twice with differect key, the second
 time installation is supposed to be failed.
 But the fact is not. Have you tested with key password changing back?
 If you found the first installed app was replaced, I think you get
 cause.

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] Camera Button in the emulator

2010-05-07 Thread TreKing
On Thu, May 6, 2010 at 3:31 PM, DulcetTone dulcett...@gmail.com wrote:

 Why does this not work?


I have no idea, but maybe the framework checks for the existence of the
hardware before sending the event? A device without a camera obviously
wouldn't have a camera button. If that's the case, it would beg the question
of why it's on the emulator though.

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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: Weird OpenGL performance in Nexus one

2010-05-07 Thread Patrick
I was looking in to finally getting around to trying out
OpenGL to handle Sprites in a game I'm working on.  I
figured before I start I'd run Chris Pruett's
SpriteMethodTest (http://tinyurl.com/2u5tbwj)
to get some numbers and motivation to move to OpenGL
from Canvas drawing.

But on an N1, I'm getting similarly strange numbers
to lixin's above. Moving up to 200 Sprites is an even
more pronounced win for Canvas drawing (at least in
this test). What gives??

100 sprites  Animated

Canvas:
--
Frame: 18ms (55.57 fps)
Min: 8ms  Max: 68
Draw: 10ms
Min: 7ms  Max: 43
Page Flip: 2ms
Min: 1ms  Max 16
Sim: 0ms
Min: 0ms Max: 2

OpenGL ES (Use Basic Vert Quads):

Frame: 23ms (43.47826 fps)
Min: 11ms  Max: 428
Draw: 13ms
Min: 7ms  Max: 252
Page Flip: 9ms
Min: 1ms  Max 319
Sim: 0ms
Min: 0ms Max: 14

OpenGL ES (Use Draw Texture Extension):
--
Frame: 23ms (43.47826 fps)
Min: 16ms  Max: 305
Draw: 12ms
Min: 5ms  Max: 265
Page Flip: 10ms
Min: 2ms  Max 36
Sim: 0ms
Min: 1ms Max: 3

OpenGL ES (Use VBO Extension):
--
Frame: 22ms (45.454544 fps)
Min: 14ms  Max: 420
Draw: 12ms
Min: 4ms  Max: 244
Page Flip: 10ms
Min: 1ms  Max 35
Sim: 0ms
Min: 0ms Max: 3




-- 
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: Best practices for creating multiple app versions from a single codebase?

2010-05-07 Thread greg
Hi, Bob.

A description of best build practices would be pure gold to me.  I'm
nearing an application release (this month I hope) but have not yet
ventured beyond building it with Eclipse.

- Greg

On May 7, 11:25 am, Bob Kerns r...@acm.org wrote:
 I don't recommend doing production builds directly in your Eclipse
 environment.

 Export a copy, and modify that. In fact, I strongly urge checking out
 a pristine copy from revision control for real production builds.

 I derive my build numbers from the Eclipse revision I'm building. I
 inject that into the AndroidManifest.xml via an XSLT ant task.

 I've been meaning to write up my build practices for a while; I keep
 holding off for certain refinements, but I really should get to it
 soon, since it's a recurring issue for people.

 On May 4, 4:42 pm, Leigh McRae leigh.mc...@lonedwarfgames.com wrote:



  Since you talk about a generated ant file tt sounds like you're project
  was created using the android tool instead of Eclipse.  Is this
  correct?  I spent most of today trying to get a non-eclipse project
  going and had some success up until debugging.  I really wanted to use
  NetBeans but it looks like Eclipse is doing quite a bit under the hood
  for you when it comes to debugging.

  If you're using an Ant script for the main build, how are you using
  Eclipse with it?  I wrote something to inc the version number and
  Eclipse really doesn't like the AndroidManifest.xml  file touched.

  Leigh

  On 5/4/2010 4:36 PM, Alex (PS3 Friends) wrote:

   My solution was to create two different starter classes with different
   packages.  One for the paid version and the other for the free
   version.  Since the package name is used to identify the application
   in the market.  You can use this to customize the app, by setting
   properties in the different start classes.  I modified the generated
   Ant file to switch between the paid/free versions.  I created a task
   that uses regular expression replacements, identifying sections and
   replacing the starting class name depending on what I am deploying in
   the manifest.  You can even modify the XML layouts using this method.
   Essentially pre-processing prior to compilation.  The R class is the
   only issue, you need to make sure you include an * import for both
   packages otherwise it won't work, and you will have to modify code
   each time.  Also, Eclipse gets upset when you change things underneath
   it after compiling the R class, you need to delete the generated
   source directory.  This is the best solution I have come up with so
   far, it's not great but it works for me and it is scripted.

   Alex

   On May 4, 3:01 pm, Tomáš  Hubálektom.huba...@gmail.com  wrote:

   I'm thinking about the same thing.

   I believe thathttp://code.google.com/p/maven-android-plugin/couldbe
   a solution. Maven is very powerful tool for building (we are using it
   for JEE projects) so I'm sure that it will support also multiple APKs
   from one source code base.

   But I didn't looked into details yet.

   Tom

   On 4 kvě, 20:37, E.Peld...@gmail.com  wrote:

   Are there any viable approaches for creating multiple .APKs out of a
   single codebase?

   The apps may share the same code, but they could have different
   manifest files, different resources, or different external libraries
   (for example in an app with both free and paid versions, the free
   version could have a library for display ads).

   Ideally, this would be a single Eclipse project, with a way to specify
   which app to build/debug, and possibly a command line way to batch
   build everything.

   --
   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 
   athttp://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 
   athttp://groups.google.com/group/android-developers?hl=en

  --
  Leigh McRaewww.lonedwarfgames.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 
  athttp://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] Re: Alarms/Wake Locks/Sound notification question

2010-05-07 Thread code_android_festival_way
So well I have tested the whole thing with a sample application. At
the moment I am using a fresh Nexus One which I got from Google one
week ago. What can I say ... it does work perfectly on the sample
application and on my own application. I don't really know if it is
the new phone or if I just have been pretty lucky.

Here is the sample application: http://bit.ly/dgEFwE
It is just a pretty simple application which registers an alarm on
start which gets fired every five minutes and sends out a broadcast
which a broadcast receiver uses to set the notification directly.
(default notif)

It would be great to hear about your experience. To stop the alarm
just uninstall the app. (I said it is a really simple app :-) )

Thank you very much.

On 29 Apr., 17:11, code_android_festival_way
festival.s...@googlemail.com wrote:
 Thank you for your questions. I will add a sample app in the next
 days. In addition I will test out if I am able to play simple audio
 file in stand by mode on the Nexus One.

 Regards

 On 28 Apr., 22:40, nikhil nik...@gmail.com wrote:



  Are you atleast able to play a sound file when you are in stand by
  mode?

  On Apr 28, 2:24 pm, code_android_festival_way

  festival.s...@googlemail.com wrote:
   So well I have tested that out once more.

   I have tried different wake lock levels up to the full wake lock. It
   doesn't make any difference. As a last test I have set up a simple
   notification with:
   ...
   notification.defaults = Notification.DEFAULT_ALL;
   nm.notify(123,notification);
   ...

   This one gets started inside the WakefullIntentService which gets
   started every five minutes triggered by an Alarm which is sending a
   broadcast caught by a BroadcastReceiver which starts the service. As
   long as I have the Nexus One plugged in everything is fine. As long as
   I have the screen on everything is fine. But when I set the  phone to
   stand by unplugged from USB I am only getting the vibration but no
   sound (no LED as well, but ok that is caused by the buggy Android
   2.1).

   To sum up sound notifications do not work in stand by using this way.
   I have no idea how to get them working. Perhaps someone got another
   device running Android 2.x and would like to test that one out.

   I would love to hear your opinions.

   On 28 Apr., 18:45, code_android_festival_way

   festival.s...@googlemail.com wrote:
Thank you very much for your answers. I will try all of your devices.

Regarding the following:
I dont know why you have multiple
notifications when you can have all in one.. 

I'd like to stop each notification on its own. So starting them
together would not give me the choice to stop vibrate or sound on its
own.

Regards

On 27 Apr., 20:13, MB manoj.bi...@gmail.com wrote:

 Perhaps, for the sound notification to fire, the screen should be on.
 Try acquring wakelock using different flags.

 I would start with SCREEN_DIM_WAKE_LOCK and move all the way up to
 FULL_WAKE_LOCK.

 On Apr 27, 9:43 am, code_android_festival_way

 festival.s...@googlemail.com wrote:
  Hmm does really no one got an idea what could be wrong here?

  Regards

  On 25 Apr., 19:44, code_android_festival_way

  festival.s...@googlemail.com wrote:
   Well you are right that this will drain the battery pretty 
   heavily. At
   the moment I am using the broadcast which gets fired every n 
   seconds
   and gets caught by the receiver which handles the notifications 
   in its
   onReceive method. But well the problem remains. I haven't found a
   possibility to get the sound noitification working during the wake
   lock.

   If someone has got a solution for that problem I would love 
   hearing
   about it. :)

   On 25 Apr., 17:17, Mark Murphy mmur...@commonsware.com wrote:

code_android_festival_way wrote:
 What do you mean exactly by that? Well I know that 30 seconds 
 or even
 lower is very frequent but I would let the user decide how 
 often he
 would like to be notified.

I mean you may chew up a fair bit of battery life constantly 
cycling
through processes, starting and stopping receiver and/or service
components every 30 seconds. I'd use the battery blame screen in
Settings to test and see how bad this is in reality.

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

_Beginning Android 2_ from Apress Now Available!

--
You received this message because you are subscribed to the 
Google
Groups Android 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 

Re: [android-developers] Re: updating a contact in 2.x Contacts API

2010-05-07 Thread Dmitri Plotnikov
The data structure for contacts is based on three separate tables:
 Contacts, RawContacts and Data.  A Contact can have multiple RawContacts,
which can have multiple Data rows.  Each data row has a mime type that
specifies what kind of data is stored in that row.  Contact name is stored
in a row with the mime type StructuredName.CONTENT_TYPE.

So, in order to change the contact name you first need to find the Data row
that contains the name and then update that Data row.  The provider will
take care of the rest (e.g. promoting the name to the level of RawContact
and then Contact).

I hope this helps,
- Dmitri

On Fri, May 7, 2010 at 2:46 AM, JKDESAI jk.shona17...@gmail.com wrote:


 Thanks for your replay.

 Here is the scenario I am following.

 First of all, I am getting a curser for the Contact at some particular
 Id using this:

 contactCursor =
 getContentResolver().query(ContactsContract.Contacts.CONTENT_URI,
 null,
ContactsContract.Contacts._ID +  = ?,
new String[]{id}, null);

 Now  I need to update the GIVEN_NAME and FAMILY_NAME  of this contact.

 For that, What Id I have to pass in the withSelection(String,
 String[]) method along with Data.CONTACT_ID ?

 I have tried by getting RAW_DATA_ID but no success.

 Please help me.

 On May 5, 9:53 pm, Dmitri Plotnikov dplotni...@google.com wrote:
  Your query says: update _all_ data rows for this contact, setting one of
  the fields to John and another to Abraham.  Data rows include phone
  numbers, emails, photos, you-name-it.  What you need to do is find a
  specific data row you want to update and then use its _id in the
 selection
  (or, more commonly, in the URI itself).
 
  Cheers,
  - Dmitri
 
 
 
  On Tue, May 4, 2010 at 6:46 AM, JKDESAI jk.shona17...@gmail.com wrote:
 
   On Apr 19, 2:41 pm, Timo Prill timo.pr...@googlemail.com wrote:
hi all,
 
i got a problemupdatingacontact'sdetails.
i use the following code to update thecontactname:
operations is a ArrayList of ContentProviderOperation.
 
operations.add(ContentProviderOperation.newUpdate(
 ContactsContract.Data.CONTENT_URI)
 .withSelection(Data._ID + =?, new
 String[]{id})
 
.withValue(Data.MIMETYPE,StructuredName.CONTENT_ITEM_TYPE)
 .withValue(StructuredName.GIVEN_NAME, firstName)
 .withValue(StructuredName.FAMILY_NAME, lastName)
 .build());
 
contentResolver.applyBatch(ContactsContract.AUTHORITY, operations);
 
but after this query, thecontactname is not updated.. (at least the
name did not change in the phone's addressbook)
i cant figure out why...what am i doing wrong? must be a simple thing
 i
am missing..
 
thanks in advance
timo
 
--
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.comandroid-developers%2bunsubscr...@googlegroups.com
 android-developers%2bunsubscr...@googlegroups.comandroid-developers%252bunsubscr...@googlegroups.com
 
For more options, visit this group athttp://
   groups.google.com/group/android-developers?hl=en
 
   Hi,
 
   I have used your code snippet for updating contact details with API
   2.0.
 
   But using that, display name is updated successfully, but it deletes
   all the other information like phone number and email.
 
   Can you tell me why it happens?..or I am missing something...
 
   Here Data used is android.provider.ContactsContract.Data.
 
   The same code I have used is as below:
 
  ArrayListContentProviderOperation
   operations =
  new
   ArrayListContentProviderOperation();
 
operations.add(ContentProviderOperation.newUpdate(
 
ContactsContract.Data.CONTENT_URI).withSelection(
   Data.CONTACT_ID + =?, new String[]
   { id }).withValue(
   StructuredName.GIVEN_NAME,
 John).withValue(
  StructuredName.FAMILY_NAME,
   Abraham).build());
 
   try {
 
getContentResolver().applyBatch(ContactsContract.AUTHORITY,
   operations);
   } catch (RemoteException e) {
  System.out.println(Exception :
   +
   e.getMessage());
  e.printStackTrace();
  } catch (OperationApplicationException
 e) {
  System.out.println(Exception :
  +
   e.getMessage());
  e.printStackTrace();
  }
 
   Please share your thoughts.
 
   --
   You 

[android-developers] أحصل على عمل على الأنترنيت والله لن تخسر شيئ

2010-05-07 Thread web mail
   

السلام عليكم 

طبعا كلنا سمعنا عن الربح من الانترنيت او
عن اشخاص يعملون ويكسبون اموالا طائلة من
التجارة الالكترونية  

لمجرد انهم يعلمون اسرار الربح من
الانترنيت 

 اليوم سنكشف الستار عن هذه الاسرار عبر
موقعنا  WWW.BIT.LY/AHQDXI [1]  

وستجد كل شيئ له علاقة بهذا

والسلام عليكم 

الموقع   

Links:
--
[1] http://www.bit.ly/aHqdxi

-- 
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: Weird OpenGL performance in Nexus one

2010-05-07 Thread Patrick
OK, increased the size and changed the png
images used for the sprites to have transparent
and semi-transparent areas and I get results that
make more sense (but still don't show OpenGL
winning?!?)

200 128x128pixel sprites w/ transparent areas

Canvas:
--
Frame: 46ms (21.73913 fps)

OpenGL ES (Use Basic Vert Quads):

Frame: 47ms (21.276596 fps)

OpenGL ES (Use Draw Texture Extension):
--
Frame: 47ms (21.276596 fps)

OpenGL ES (Use VBO Extension):
--
Frame: 47ms (21.276596 fps)

On May 7, 12:07 pm, Patrick specter...@gmail.com wrote:

 What gives??

-- 
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: Best practices for creating multiple app versions from a single codebase?

2010-05-07 Thread Alex (PS3 Friends)
I agree with Bob on this, you should be able to build your system for
release outside of Eclipse entirely, there should be no dependencies
at all with that environment.  A good way to set this up is to use a
Continuous Integration Server like Hudson to do this.  There are even
Hudson plugins that allow you to tag releases in CVS and do some nice
things.  The nice thing about this, you will end up with a clean
environment that Bob was talking about, and it also makes it easier to
move from one machine to another if need be and helps you document and
clean up your build.

Alex

On May 7, 12:08 pm, greg sep...@eduneer.com wrote:
 Hi, Bob.

 A description of best build practices would be pure gold to me.  I'm
 nearing an application release (this month I hope) but have not yet
 ventured beyond building it with Eclipse.

 - Greg

 On May 7, 11:25 am, Bob Kerns r...@acm.org wrote:



  I don't recommend doing production builds directly in your Eclipse
  environment.

  Export a copy, and modify that. In fact, I strongly urge checking out
  a pristine copy from revision control for real production builds.

  I derive my build numbers from the Eclipse revision I'm building. I
  inject that into the AndroidManifest.xml via an XSLT ant task.

  I've been meaning to write up my build practices for a while; I keep
  holding off for certain refinements, but I really should get to it
  soon, since it's a recurring issue for people.

  On May 4, 4:42 pm, Leigh McRae leigh.mc...@lonedwarfgames.com wrote:

   Since you talk about a generated ant file tt sounds like you're project
   was created using the android tool instead of Eclipse.  Is this
   correct?  I spent most of today trying to get a non-eclipse project
   going and had some success up until debugging.  I really wanted to use
   NetBeans but it looks like Eclipse is doing quite a bit under the hood
   for you when it comes to debugging.

   If you're using an Ant script for the main build, how are you using
   Eclipse with it?  I wrote something to inc the version number and
   Eclipse really doesn't like the AndroidManifest.xml  file touched.

   Leigh

   On 5/4/2010 4:36 PM, Alex (PS3 Friends) wrote:

My solution was to create two different starter classes with different
packages.  One for the paid version and the other for the free
version.  Since the package name is used to identify the application
in the market.  You can use this to customize the app, by setting
properties in the different start classes.  I modified the generated
Ant file to switch between the paid/free versions.  I created a task
that uses regular expression replacements, identifying sections and
replacing the starting class name depending on what I am deploying in
the manifest.  You can even modify the XML layouts using this method.
Essentially pre-processing prior to compilation.  The R class is the
only issue, you need to make sure you include an * import for both
packages otherwise it won't work, and you will have to modify code
each time.  Also, Eclipse gets upset when you change things underneath
it after compiling the R class, you need to delete the generated
source directory.  This is the best solution I have come up with so
far, it's not great but it works for me and it is scripted.

Alex

On May 4, 3:01 pm, Tomáš  Hubálektom.huba...@gmail.com  wrote:

I'm thinking about the same thing.

I believe thathttp://code.google.com/p/maven-android-plugin/couldbe
a solution. Maven is very powerful tool for building (we are using it
for JEE projects) so I'm sure that it will support also multiple APKs
from one source code base.

But I didn't looked into details yet.

Tom

On 4 kvě, 20:37, E.Peld...@gmail.com  wrote:

Are there any viable approaches for creating multiple .APKs out of a
single codebase?

The apps may share the same code, but they could have different
manifest files, different resources, or different external libraries
(for example in an app with both free and paid versions, the free
version could have a library for display ads).

Ideally, this would be a single Eclipse project, with a way to specify
which app to build/debug, and possibly a command line way to batch
build everything.

--
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 
athttp://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] Re: Weird OpenGL performance in Nexus one

2010-05-07 Thread Robert Green
You are witnessing the fill-boundedness of that chip.  Chris's testing
was on a G1.  It has very different performance characteristics.

Canvas is software rendering using a special framebuffer blit which is
lightning fast.
GL is hardware rendering using a texel shader (even if you don't use
it - it's there) and drawing to a framebuffer.

Don't assume one will be faster than the other for all cases but do
assume that the hardware gpu will probably always win when not testing
straight fill-rates.  If your test started skewing/scaling/rotating
the quads, you'll probably see the gpu pull ahead.  If you have to do
hardware transformation of lots of verts, you'll definitely see the
gpu win.


On May 7, 11:52 am, Patrick specter...@gmail.com wrote:
 OK, increased the size and changed the png
 images used for the sprites to have transparent
 and semi-transparent areas and I get results that
 make more sense (but still don't show OpenGL
 winning?!?)

 200 128x128pixel sprites w/ transparent areas

 Canvas:
 --
 Frame: 46ms (21.73913 fps)

 OpenGL ES (Use Basic Vert Quads):
 
 Frame: 47ms (21.276596 fps)

 OpenGL ES (Use Draw Texture Extension):
 --
 Frame: 47ms (21.276596 fps)

 OpenGL ES (Use VBO Extension):
 --
 Frame: 47ms (21.276596 fps)

 On May 7, 12:07 pm, Patrick specter...@gmail.com wrote:



  What gives??

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


[android-developers] Re: Debug key expired and problems to get a new one

2010-05-07 Thread Fred Grott(Android Expert, http://mobilebytes.wordpress.com)
under your user folder on Mac..you should see a hidden folder
called .android

delete the debug.keystore file and everything should regenerate a new
debug.keystore file and you will be fine



On May 7, 6:58 am, carknue pynetm...@googlemail.com wrote:
 I started android developping a year ago With Eclipse on a Windows
 Machine. Recently I switched to Mac OS X. Android developping worked
 fine with newest Eclipse and Android MacOS SDK on my iMac until my
 debug.kestore expired yesterday. Goggle suggests in this case to
 delete the old key and a new key should be generated automacially. But
 this is not working for me. Maybe it is just a missing path for the
 keytool. But how do I have to set this path and where? I looked into
 the JDK folders, but there are only symbolic links. Could anybody give
 me a detailed example how to set this keytool and sdk tools path in
 Mac OS X SL?

 And what debug.kestore will be used? In Eclipse settings I found a
 path to the default debug.keystore and a custom debug.kestore. What is
 the difference?

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] Re: Best practices for creating multiple app versions from a single codebase?

2010-05-07 Thread Greg Donald
On Fri, May 7, 2010 at 12:13 PM, Alex (PS3 Friends) kludg...@gmail.com wrote:
 it also makes it easier to
 move from one machine to another if need be

Just curious.. what problems have you ran into developing across
multiple machines?  I develop on both Win7 and Ubuntu Linux using git
and I have zero issues related to moving back and forth between them.

I have a .gitignore file that looks like this:

*.apk
.metadata
.swp
*/bin/*
*/gen/*

Works really well for me.


-- 
Greg Donald
destiney.com | gregdonald.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] Regarding layout drawing using code!

2010-05-07 Thread TreKing
On Fri, May 7, 2010 at 10:32 AM, Aditya dabhaga...@gmail.com wrote:

 i have a query that can we draw layouts using code?(without using XML file)


Yes. Layouts are always DRAWN using code. Though they may be DEFINED in
either code or XML.


 If yes, any one please give me some sample code.


No. Reading the documentation, picking up a decent book, or doing a simple
Google search should get you all samples you need. Especially when your
question is this vague.

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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: Porting MAME on Android?

2010-05-07 Thread mah
A search of mame on the Android Market shows two items that appear
to be ports. Since both are non-free, I don't guess you'll get many
answers from them, but it seems possible to do at least. I can't speak
to how much effort might be required though.

On May 5, 2:44 am, javame_android su...@softwebsolutions.com wrote:
 Hi,

 I will like to know how can one port MAME on Android?

 MAME is a Multi Arcade Machine Emulator and it does support ROM based
 games. There is already one application called Android Arcade similar
 to this one.

 Can someone tell me how to go about porting it to Android?

 Thanks  Regards
 Sunil

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


[android-developers] Re: Confused on android stacking activies

2010-05-07 Thread Sebastián Treu
Any clues?


-- 
If you want freedom, compile the source.

Sebastián Treu
http://labombiya.com.ar

-- 
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: Confused on android stacking activies

2010-05-07 Thread EboMike
Can you be a bit more descriptive about how you launch application B?

You said A. Application A starts a service and launch[e]s another
application. But you mean that your application used
Activity.startActivity(), so the service has nothing to do with it?

In that case, it's expected behavior - startActivity() puts the new
Activity on the activity stack, so when that returns, you get back to
where you came from, i.e. your own activity. If you don't want that,
you need to call finish() after you start the activity.

Now if you start the other application using other means, please
explain how.

-Mike


On May 7, 12:27 pm, Sebastián Treu sebastian.t...@gmail.com wrote:
 Any clues?

 --
 If you want freedom, compile the source.

 Sebastián Treuhttp://labombiya.com.ar

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] Confused on android stacking activies

2010-05-07 Thread TreKing
On Sun, May 2, 2010 at 8:17 AM, Sebastián Treu sebastian.t...@gmail.comwrote:

 But then, when the user hits the back button, instead of returning to the
 last-in-foreground application, android returns to application A. So now,
 the launched application is on background. Why is this?


Because Activities are stacked by the application they belong to. So when
you press back, you go back in your current application's stack, not a
global stack.


 I have some questions about it:

 1. when the Intent note was launched, did android finish the
 launched application?


What Intent note?


  2. has the Intent context (in fact, the PendingIntent) has anything to do
 with this?


Not really.


  3. Is there a way to make this behaviour turn in what I want?


Look into Task Affinity - I haven't used it myself, but based on what I've
seen around here, it may be what you want.

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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: BitmapFactory.decodeStream thread safe ?

2010-05-07 Thread EboMike
Define thread-safe.

Are you asking if it's possible to decode two bitmaps at the same
time? To decode a stream while something else is using the stream? To
do it in a worker thread?

My take is that it's re-entrant, i.e. you can run it multiple times at
the same time in separate threads, but all the objects it uses (the
stream, the bitmap) should not be touched by any other thread while
the decoding is in progress.

If you do run multiple stream decoders at the same time, keep in mind
that it can be prohibitively expensive if you are working with big
bitmaps.

-Mike



On May 7, 4:26 am, Agus agus.sant...@gmail.com wrote:
 Is the BitmapFactory.decodeStream method thread safe?

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] Confused on android stacking activies

2010-05-07 Thread Sebastián Treu
Thanks both of you. I apologize my english for trying to explain myself.

I thought the stack was global. The service manages notifications to
the user, not necessarily when showing my own Application. So I guess
the Context has to do here when the activity is launched so it then
can return to the proper place.

I'll put my head on Task Affinity.

Thanks for guide my knowlegde,

Best Regards,
-- 
If you want freedom, compile the source.

Sebastián Treu
http://labombiya.com.ar

-- 
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] Confused on android stacking activies

2010-05-07 Thread Dianne Hackborn
The stack is global as an implementation detail, but is organized into tasks
that can be moved around in the stack.  (This could just as well be
implemented as a Z-ordered list of tasks, with an activity stack in each.)

Use adb shell dumpsys activity to see the current activity/task stack
state.

On Fri, May 7, 2010 at 8:31 PM, Sebastián Treu sebastian.t...@gmail.comwrote:

 Thanks both of you. I apologize my english for trying to explain myself.

 I thought the stack was global. The service manages notifications to
 the user, not necessarily when showing my own Application. So I guess
 the Context has to do here when the activity is launched so it then
 can return to the proper place.

 I'll put my head on Task Affinity.

 Thanks for guide my knowlegde,

 Best Regards,
 --
 If you want freedom, compile the source.

 Sebastián Treu
 http://labombiya.com.ar

 --
 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.comandroid-developers%2bunsubscr...@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] nasty phone freeze bug in Android 2.1-update1 showing up in multiple cases on Nexus One and Droid

2010-05-07 Thread Robert Green
I mentioned this earlier but no one seemed to know anything about
this.  It just happened again to me in the middle of testing a new
game, which is the first time I've seen it happen during one of my
games.  The game had been loaded for about a minute and I was playing
and everything was fine and then the phone locked up and this was in
the log:

I/ActivityThread(29551): Publishing provider com.android.deskclock:
com.android.deskclock.AlarmProvider
I/ActivityManager(   74): Process com.amazon.mp3 (pid 26508) has died.
W/BackupManagerService(   74): dataChanged but no participant
pkg='com.android.providers.settings' uid=10025
I/ActivityManager(   74): Process com.google.android.apps.uploader
(pid 26714) has died.
W/SharedBufferStack(29487): waitForCondition(LockCondition) timed out
(identity=1310, status=0). CPU may be pegged. trying again.
W/SharedBufferStack(29487): waitForCondition(LockCondition) timed out
(identity=1310, status=0). CPU may be pegged. trying again.
W/SharedBufferStack(   74): waitForCondition(LockCondition) timed out
(identity=4, status=0). CPU may be pegged. trying again.
W/SharedBufferStack(29487): waitForCondition(LockCondition) timed out
(identity=1310, status=0). CPU may be pegged. trying again.
W/SharedBufferStack(   74): waitForCondition(LockCondition) timed out
(identity=4, status=0). CPU may be pegged. trying again.

The waitForCondition messages kept logging every second until the
phone (Nexus One) rebooted itself.

This continued until the device rebooted.  As you can imagine, process
29487 is my game.  74 is (I think) system service.  Both got hung up
and my game certainly didn't do anything to cause this.  I just use a
GLSurfaceView and a normal logic thread.  Nothing special, no hacks.

This is not the first time I've seen it - it can be reliably
reproduced when flipping orientations on a live wallpaper service and
doing the proper context/display destroy and new EGL init on
orientation change.  It happens almost instantly there.  It's actually
plaguing my live wallpaper because I haven't found a workaround for it
yet.

I've also seen this happen once before to RenderScript, so perhaps it
is OpenGL-related?

I feel like there is a bug down there in the depths of Android

-- 
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 create a layout like this - multiple scrollable ExpandableListViews in a vertical linearlayout?

2010-05-07 Thread MB
Hi,

I would really appreciate any insights/pointers regarding creating a
layout like this. I have wasted quite a bit of time on this.
I want to create a vertical linearlayout which has multiple
ExpandableListViews separated by TextViews.

-
TextView
-
ExpandableListView
-
TextView
-
TextView
-
ExpandableListView
-
ExpandableListView


I tried the following approaches  but each of them has one shortcoming
or the other:

1. Add TextView and ExpandableListViews to a linearlayout.  The
problem with this approach is that LinearLayout by default is
unscrollable.

Adding the LinearLayout to a ScrollableView creates even more issues
because ListViews handle their own scrolling behavior.

2. I tried using a single ExpandableListView to model the above layout
but the problem is that setGroupIndicator applies to the entire
ExpandableListView, not a specific group.

Thanks,

--Manoj.

-- 
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] nasty phone freeze bug in Android 2.1-update1 showing up in multiple cases on Nexus One and Droid

2010-05-07 Thread Jonas Petersson

Robert Green wrote:

I mentioned this earlier but no one seemed to know anything about
this. 

 [...]

W/SharedBufferStack(29487): waitForCondition(LockCondition) timed out
(identity=1310, status=0). CPU may be pegged. trying again.
[...]
I've also seen this happen once before to RenderScript, so perhaps it
is OpenGL-related?

I feel like there is a bug down there in the depths of Android


This sounds lot like what I've experienced and reported here:
http://code.google.com/p/android/issues/detail?id=6478

I just got 2.1-update1 on my Milestone this morning (UK model), so I've 
not seen it there yet, but considering fadden's comment#4 to the bug I 
wouldn't bet on it being fixed...


Speaking of bugs: Even the 2.1-update1 on Milestone refuses to add a 
Google account (Gmail or Apps) - Nexus One works fine though. Anyone 
else experience this? The error message is:


Can't establish a reliable data connection to the server.
(even when entering complete garbage).

Best / Jonas

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


Re: [android-developers] How to create a layout like this - multiple scrollable ExpandableListViews in a vertical linearlayout?

2010-05-07 Thread TreKing
On Fri, May 7, 2010 at 4:27 PM, MB manoj.bi...@gmail.com wrote:

 I would really appreciate any insights/pointers regarding creating a layout
 like this.


As you've seen putting scrollable view inside other scrollable views doesn't
work. You might consider a single ListView that's backed by a fancy custom
adapter that returns the items as you've described.

That, and / or look at the source for the Contacts app. When you edit a
contract, it has this type of view / functionality.

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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: Determine when application icon is clicked to launch the app

2010-05-07 Thread Kumar Bibek
Well, it depends on what you want to do. If you want a callback for
the application as a whole.  it is not possible. But, may be yes, at
the Activity level. In the onResume of an activity, you can try
triggering a braodcast receiever.

Thanks and Regards.
Kumar Bibek

On May 7, 7:12 pm, TreKing treking...@gmail.com wrote:
 On Thu, May 6, 2010 at 11:15 PM, Pankaj pankajiit...@gmail.com wrote:
  Is there any way to determine when the user clicked the app icon to launch
  the app ?

 Nope.

  My question is do I get a call-back for this ?

 onPause, and onStart.

 -
 TreKing - Chicago transit tracking app for Android-powered 
 deviceshttp://sites.google.com/site/rezmobileapps/treking

 --
 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 
 athttp://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] Starting Activity with Tabs

2010-05-07 Thread Károly Holczhauser
Hi there!

 Thanks for the reply, but i have to use tabs for navigation, because I
works for a company and they want tabs:) So how can I switch to Tab2 and
start the activity over there, from Tab1 Activity ?

Thanks: Karoly

-- 
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] Starting Activity with Tabs

2010-05-07 Thread Mark Murphy
Károly Holczhauser wrote:

 So how can I switch to Tab2 and
 start the activity over there, from Tab1 Activity ?

If Tab2 does not exist, Tab1 can call getParent() to get your
TabActivity and have it set up Tab2 with whatever content you want.

If Tab2 already exists, I know of no supported way to replace its
contents with another activity, short of getting rid of Tab2 and
replacing it completely.

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

Android Online Training: 21-25 June 2010: http://onlc.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] Can PendingIntent.getActivity just bring activity to foreground?

2010-05-07 Thread Gabriel Simões
Hello,

I´m trying to figure out how could PendingIntent.getActivity, when
used for a notification, instead of launching a new instance of an
application just bring it´s already running instance to front.

Is that possible? How could I acomplish this effect?

Thanks,
Gabriel

-- 
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: Max size of string array

2010-05-07 Thread fadden
On May 6, 3:12 pm, fadden fad...@android.com wrote:
 I'm not sufficiently familiar with the asset management stuff to
 suggest a workaround.  I'll file a bug and ask around.

The bug has been fixed for a future release of Android.

In the mean time:

  He'll need to split his strings into multiple arrays.  Or another
option is to put them in an XML file and pull them out of that.

Hopefully that helps.

-- 
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: Can PendingIntent.getActivity just bring activity to foreground?

2010-05-07 Thread Gabriel Simões
Also, if there´s no way from a notification to bring the same instante
that launched it to front, am I able to launch a notification with an
empty Intent (just to alert the user that something has happened)?
If I can, how then (null intent or null intent parameters just doesn´t
work, as expected)?

On 7 maio, 20:08, Gabriel Simões gsim...@gmail.com wrote:
 Hello,

 I´m trying to figure out how could PendingIntent.getActivity, when
 used for a notification, instead of launching a new instance of an
 application just bring it´s already running instance to front.

 Is that possible? How could I acomplish this effect?

 Thanks,
 Gabriel

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] Confused on android stacking activies

2010-05-07 Thread Sebastián Treu
Hey guys, thank you so much. From:

http://developer.android.com/intl/fr/guide/topics/manifest/activity-element.html#aff

I set the activity to be android:taskAffinity=some-task, and now
hitting back returns to the some-task application.

I like when people guide others to find the solution thenselves reading =)

Thats what I was looking for, not an actual solution, just a guide
from people who know better of this than me.

Thanks,
Best Regards
-- 
If you want freedom, compile the source.

Sebastián Treu
http://labombiya.com.ar

-- 
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 show numeric only pad with big numbers, such as phone type?

2010-05-07 Thread Juan David Trujillo C.
Hi all !

I want to use an EditText that allows only numeric decimal values,
however, I want the virtual keyboard to display big bumbers, such as
when you use a phone input type.  Is this possible, or do I have to
customize the property?

In order to achieve this, what I tried was that I used the
android:inputType=phone property in the edittext and used custom
java code to validate whether the value  the user entered was a
decimal value, however some users reported that they do not have the
option to enter periods (.) using the phone pad, so this does not
allow them to enter numeric decimal values, as needed.  Is there a
workaround to this situation?

Best regards,

Juan.

-- 
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: I've found a way to stop piracy of my apps

2010-05-07 Thread dadical
I most certainly did NOT use code from that project.  I rolled my own,
thank you very much.  Take a look at that project.  It's over 600k.
AAL is 36k.  I wrote my own implementation of ProtoBuf to pull this
off, and that is no small undertaking.  I did initially consider using
that project, but came to the conclusion fairly quickly that it was
just too fat.  There is not a single piece of code from that project
in AAL.

On May 6, 3:36 am, a1 arco...@gmail.com wrote:
 On May 5, 8:09 pm, dadical keyes...@gmail.com wrote:

  Hey Tim.

  You're correct that validating purchase with the market is a key piece
  of our solution.  Figuring out how exactly to do that using Google's
  binary market protocol in an efficient way (try doing everything that
  AAL does in a 35 KB library) was a fairly significant dev effort.
  What's more, balancing license generation, market API security, cross-
  Android version compatibility, customization, etc., and you've got a
  nice little chunk of work that we put into this solution.

  As for pricing, we'll see what the market will support.  In our own
  single app Screebl, we lose about $100/day in revenue to pirated
  apps, so $50 seems cheap.   I know that not all of that $100 will
  translate into sales, but some percentage will.  My point is it
  shouldn't take long for AAL to pay for itself.

 Are you kidding me? You used code from this 
 project:http://code.google.com/p/android-market-api/[you even left the same
 UA spoof], and whats more important you are trying to charge for
 solution that uses undocuemented google APIs (hence illegal), which
 not only may change at any time but also using it may be legitimate
 reason to block app from android market.

 --
 Bart Janusz (Beepstreet)

 --
 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 
 athttp://groups.google.com/group/android-developers?hl=en

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


[android-developers] Re: I've found a way to stop piracy of my apps

2010-05-07 Thread dadical
Hello Lee.

Regardless of whether anyone purchases AAL, it has been a worthwhile
investment for us.  It took several days (almost a week) for crackers
to decompile Screebl Pro and find a way to circumvent AAL.  Typically
it takes about 90 secs from the time that we publish to the market for
the various warez sites to start tweeting the location of the
download.  I have a feeling that the open source market api is
involved in that scenario for sure.

As you've said, AAL is not fail proof, but I continue to improve it,
and my latest releases will make it even more challenging to reverse
engineer.  AAL is a big stumbling block, but a market API alone is not
worthy of a Google anti-piracy solution.  They will need to do the
same as AAL but also go much further to guarantee that apks aren't
modified (e.g., cracked).  One way to to do this would be to have the
platform calculate a hash of the installed apk and validate that
against what was purchased on the market.  This is going to require
deep integration in the platform and the market to kick it in the arse
for good.

Loving the feedback!


On May 7, 6:09 am, Lee lee.wil...@googlemail.com wrote:
 As an aside, why don't google provide their own official API to allow
 apps to check with the market whether they've been purchased or not ?

 Perhaps it's the 'any security which can be conceivably broken is
 useless' line ?

 I would be happy with any protection mechanism which forced my apk to
 be hacked in order to install it on a non-rooted phone, instead of the
 current 'just copy it over, it'll work fine' situation.
 I don't need 100% security.

 Lee

 --
 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 
 athttp://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


  1   2   3   >