[android-developers] Re: Location is null

2009-01-30 Thread Chander Pechetty


Use the geo command:
http://code.google.com/android/reference/emulator.html#geo

If you are using eclipse plugin for development, you can use the the
Emulator Location Controls.
In Eclipse Go to : Windows/Show View/Others/Android/Emulator

-Chander

On Jan 31, 6:13 am, zeeshan  wrote:
> Hi,
>
> i am trying to run a simple program which shows lat and long values
> but Location value is always null.
>
> LocationManager locationManager;
>     locationManager = (LocationManager)getSystemService
> (Context.LOCATION_SERVICE);
>     Location location = locationManager.getLastKnownLocation
> (LocationManager.GPS_PROVIDER);
>
> emulator shows alert force close - wait
>
> please help me how can i fix this problem and also how can i debug
> line by line,   at the moment i am usinng if, else to see veriable
> value.
>
> Thanks,
> Zeeshan
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] button text change

2009-01-30 Thread Bob

Hi,
How do I change the text on a button at run-time?  This code doesn't
appear to do anything, what am I doing wrong:

 Button button1=(Button)findViewById(R.id.button1);
button1.setText("Change text");

Thanks,
Bob

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] DatePicker -- 2/30; 4/31 is quitely treated as a valid input

2009-01-30 Thread Developer

Why can't Datepicker dialog automatically figure out that there are no
30 and 31 in Feb? Should not this be considered as a bug in DatePicker
class?

The DatePicker dialog's 'set' button can be pushed without telling
user 'this is an invalid date' -- instead, it quietly convert 4/31 to
5/1; 2/30 to 3/2 after you push the button. I think an idea behavior
should be as following:
-- when you currently have "1 31 2009" and push the 'up' button on
'1' (month), you should get "2 28 2009" shown on the three elements

I thought to build a customized subclass, but a lot of the fields are
private and not accessible from subclass, anyone thought of the same
problem?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] what is example of internal_content_uri

2009-01-30 Thread jj

hello
images on sd-card come under external_content_uri,
what is example of internal_content_uri, is the camera images come
under internal_content_uri?

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



[android-developers] BUG in DatePicker! 2/30; 4/31 is quitely treated as a valid input

2009-01-30 Thread Developer

Why can't Datepicker dialog automatically figure out that there are no
30 and 31 in Feb? Should not this be considered as a bug in DatePicker
class?

The DatePicker dialog's 'set' button can be pushed without telling
user 'this is an invalid date' --the application writers could embed
the intelligence on the application side, but post-processing this
invalid date input made the users confused.

I thought to build a customized subclass, but a lot of the fields are
private and not accessible from subclass, anyone thought of the same
problem?


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Search engine app for Android? It's in Perst 4.0 embedded database

2009-01-30 Thread Ted

Nothing is “wrong” with SQLite, but there are many reasons why one
might prefer Perst for an Android application. Here are a few:

Object-Oriented – Perst is an object-oriented DBMS, which many prefer
in Java. It is more efficient to store objects _as java objects_ in an
object database, than having to translate them to another format as
with a relational or object-relational database.

Performance – Check out the TestIndex performance benchmark, available
with source code on McObject’s Web site, http://www.mcobject.com/perst_eval.
It compares SQLite and Perst directly, performing the same database
tasks.

Programming flexibility – Through its specialized collections classes,
Perst supports a wide variety of index types, including R-Tree, B-
Tree, T-Tree, Patricia Trie, KD-Tree and others.

To my knowledge, SQLite offers only B-Tree – which is useful for
general purpose searching but can come up short if working with GIS/
mapping data (here an R-Tree is much better), with data to be managed
in memory (a T-Tree is more efficient), etc.

The efficiency gained through using the optimal index type is
especially important given the limited memory, CPU and storage
resources in mobile device environments…

These are a few reasons. As noted above, the open source Perst is
available at http://www.mcobject.com/perst_eval.



On Jan 27, 8:57 am, loty  wrote:
> What's wrong with SQLite?
>
> On Jan 26, 8:11 pm, Ted  wrote:
>
> > Looking for a way to integrate full-text search and fast, lightweight
> > data management with your Android applications?
>
> > The new Perst 4.0 open source, object-oriented embedded database
> > system brings native full-text search capability to Android and builds
> > on this feature to provide a sample search engine application for
> > contact data residing on mobile phones.
>
> > To provide search, the database stores an inverse index of keywords,
> > with parsing and stemming of indexed text performed either by user-
> > defined code or by Perst's default simple parser and stemmer. The
> > feature supports logical operators and calculates relevance of search
> > results to a query. The new sample application, ContactsIndex, stores
> > and indexes contact information, and could be extended to provide
> > search capabilities for PDF, word processing, HTML and other stored
> > files. The example applications are included with complete source code
> > in the Perst 4.0 for Java distribution.
>
> > Also new in Perst 4.0 for Android: support for non-native objects,
> > which expands the scope of the embedded database to benefit a larger
> > variety of application types.
>
> > The Perst embedded database system helps developers create small-
> > footprint embedded Java applications for Android that are fast,
> > reliable, and cost-effective to develop and maintain.
>
> > You can find out more about what's new in Perst 4.0 at:
>
> >http://www.mcobject.com/perst_v4_for_mobile_phones
>
> > and download the open source Perst and Perst Lite software at:
>
> >http://www.mcobject.com/perst_eval
>
> > Details about Perst and Android are athttp://www.mcobject.com/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] custom themes?

2009-01-30 Thread Craig

Could anyone post or point me to an example of using custom items in a
theme?

I've created a theme that uses custom attributes as item names, and I
want to refer to those items in the code. I can see the theme is
working because it also sets the android:windowBackground color.

As a concrete example, I want an inactiveColor item in my
Theme.GreenWithYellow to use in onDraw methods in my Views.

I think this would be the right mechanism to use to have multiple
color schemes for application specific purposes, but I would be happy
to entertain other approaches, too.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] API to change network settings (2G networks only)

2009-01-30 Thread Kenny

Hi All,

I've been looking around for an API which will allow me to change the
network settings of the phone.  I want to be able to tick/untick "use
2G networks only" via an app.  Can someone please shred me some light
or point me into the right direction as I can't find the API anywhere.

Thanks,
Kenny


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] i hope to Android dev.

2009-01-30 Thread agus tegar

i hope android dev .
focus to :
Theme Style=> with multi theme ( mac , android, iphon , vista ,win
7 ) ,
effect animation ,
google earth ,
google Drive for android ,
and
Window Child in Desktop Android  ( it's for netbook or PC android )

we have big enemy ..
(iphone frimware 2.2 ,nokia , palm pre ,and BB , )

and i hope . android cupcake  make big revolution ..

think deffreent ...with them

think deffreent ... with them

think deffreent ... with them

think deffreent ... with them

think deffreent ... with them


make big revolution 
















--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] App Market app publish question?

2009-01-30 Thread dpackham

I need to test the app upgrade functionality of my app before I
publish it on the market for everyone to find and DL.  to get the
update code to work I need to know my apps ID number to query
versioncode numbers.  how can I publish my app to the market with my
account and get that APP ID number from the market without letting
everyone know my app is ready for DL?  I have not published an app
before and dont want to let the app out before its working and
upgradeable...  any ideas?  any way to upload an app and hide it?

Thanks

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



[android-developers] Re: Android Developers in Atlanta, GA

2009-01-30 Thread Simon

I'd be interested in possibly getting together.

On Jan 30, 9:10 am, BarbieDahl  wrote:
> Are there any developers in Atlanta, GA that would like to meet and
> discuss android app ideas as well as learn new and advanced android
> topics? I would like to network with some other developers in and
> around Atlanta, GA for help, mentoring and support.  Please reply if
> you are interested.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Location is null

2009-01-30 Thread zeeshan

Hi,

i am trying to run a simple program which shows lat and long values
but Location value is always null.

LocationManager locationManager;
locationManager = (LocationManager)getSystemService
(Context.LOCATION_SERVICE);
Location location = locationManager.getLastKnownLocation
(LocationManager.GPS_PROVIDER);


emulator shows alert force close - wait

please help me how can i fix this problem and also how can i debug
line by line,   at the moment i am usinng if, else to see veriable
value.

Thanks,
Zeeshan

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] headset button

2009-01-30 Thread Brodsky

Hi!  Does anyone know how to tell when the headset button is being
pressed?  I'd like to support the usb headsets and possibly bluetooth
headsets.  My app is a media player and ideally, I could register it
somewhere so that if no app that uses the headset button has focus it
button press would act as a play/pause command in my app. If the phone
is ringing or a call is in progress, I'd like to be sensitive to that
and let the button do what it normally does: pickup and hang up
calls.  we've been trying to chase the button down using this:

IntentFilter headsetFilter = new IntentFilter
(Intent.ACTION_HEADSET_PLUG);
headsetFilter.addAction
("android.intent.action.HEADSET_STATE_CHANGED");
headsetFilter.addAction("android.bluetooth.intent.HEADSET_STATE");
headsetFilter.addAction
("android.bluetooth.intent.HEADSET_STATE_CHANGED");
headsetFilter.addAction
("android.bluetooth.intent.action.MODE_CHANGED");
headsetFilter.addAction("android.intent.action.MODE_CHANGED");

no luck as of yet.  Any help would be greatly 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.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] The help on working out JMCAD is necessary

2009-01-30 Thread Yuriy Mikhaylovskiy

The help on working out JMCAD is necessary

JMCAD is an program for the modeling and simulation of complex dynamic 
systems. This includes the ability to construct and simulate block 
diagrams. The visual block diagram interface offers a simple method for 
constructing, modifying and maintaining complex system models.

Project detail and discuss:
http://jmcad.sourceforge.net/
http://sourceforge.net/projects/jmcad/

To join this project, please contact the project administrators

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: webview extracting html

2009-01-30 Thread dai

Hi Fred, thanks for your response. Which one is the crayon css
example? Is this embedded into the API demos or something?
Are you meaning that we can only get images file information just from
css??

Grazie,



On 1月31日, 午前9:53, "Fred Grott(shareme)"  wrote:
> Hello Dai, welcome to the new hacking trend Hybrid Moble RIAs
>
> Yes, any html manipulation you do in other RIAs you can do in
> webview..
>
> For example that crayon css example where the picture is created with
> just css can be done in webview and among other examples.
>
> I would start exploring html 5 entity called canvas..
>
> On Jan 30, 4:34 pm, dai  wrote:
>
> > guys, is it possible to extranct html content from webview component/
> > class?
> > I wanna show an img file from getting rid of  tag from html of
> > webivew.
>
> > grazie so much
>
>
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: opengl & gc

2009-01-30 Thread fadden

On Jan 30, 2:34 am, Steven Lagerweij  wrote:
> I found that GC can be prevented when using VBOs, nice and steady, high
> fps too. But still it would be nice to see the source and/or know what
> is going on when using Buffers instead. Anyone?

You can use the "allocation tracker" tab in the stand-alone version of
DDMS to see the last 512 allocations, with stack traces.  This might
help identify what all the allocations are.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Howto remove thread from Dalvik VM????

2009-01-30 Thread fadden

On Jan 30, 6:30 am, Sagar Parmar  wrote:
> I am using Thread to display animation..I create a new thread whenever user
> preference is changed.Now I want to Remove the previous thread from Dalvik
> VM so that my application does not crash..How can I remove Thread from DVM??
> I use Thread.stop() but it is not working..Please help..

Killing one thread from another is dangerous, because you don't know
what resources are being held by the target thread.  The Thread
methods for doing this are deprecated, and have not been implemented
in Dalvik.

The thread should check a variable periodically to see if it should
continue running.  In many situations you'll want to declare the
variable "volatile".

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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 check what is the topmost activity on screen.

2009-01-30 Thread lucius

Hi,

I am reading the source code of ForwardingTest.java. It has this in
the testLilfeCycleCreate() method:

getInstrumentation().callActivityOnPause(activity);

// At this point you could confirm that the activity has
paused properly, as if it is
// no longer the topmost activity on screen.

My question is how can I check what is the topmost activity on the
screen.

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



[android-developers] Re: Memory leak in BitmapFactory/Gallery?

2009-01-30 Thread fadden

On Jan 30, 3:39 pm, blindfold  wrote:
> Never mind, I found the culprit and fixed it. Not killing all threads
> when pressing the back button seems to have been the root cause of my
> problems.

FYI, we do now have a tool that can convert Android "hprof" output
into a format accepted by common heap analysis tools.  It's checked
into "cupcake" but hasn't yet appeared in the git repository.

For lack of a better place I'm hanging a temporary copy here:
http://bigflake.com/HprofConv.c.txt

Once you get the hprof data (there are instructions somewhere, can't
find them at the moment) you just need to run:

% hprof-conv < android.hprof > standard.hprof

This can then be fed into "jhat" (part of the JDK) or MAT or your
favorite tool.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] MapView disable?

2009-01-30 Thread Keiji Ariyama

Hi folks,

Now, I'm developing an Android app called "Echo".
But 5 hours ago, My Dev phone haven't displayed MapView.

First, I supposed that my API-key have been disabled.
I tried to Maps API Key signup agian. But google server response error.

> Server Error
> The server encountered a temporary error and could not complete your request.
> 
> Please try again in 30 seconds. 

And not only Echo but also other all map apps cannot display map.

Default map apps display error message that "[Attention] There is a
connection problem... we'll keep trying.".

If you can think of anything that may help me, I'll appreciate it.

-- 
Keiji,
ml_andr...@c-lis.co.jp

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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 overlay an image over the camera preview?

2009-01-30 Thread Dave Sparks

No, you don't draw on the camera preview surface. You create a
transparent surface above it in the Z stack and draw on that.

On Jan 30, 5:31 pm, srajpal  wrote:
> I checked out the api demo, it helps to place the camera preview on
> top of the surface view, but the buffers are handid over to the camera
> so anything drawn on the canvas, which is received from the handler,
> is ignored.
>
> There must be some way.  I just don't know it yet.
>
> On Jan 30, 7:27 pm, Dianne Hackborn  wrote:
>
> > There is an Api Demo showing how to generally do this with a surface view.
> > It's very easy, since SurfaceView essentially operates like any other view
> > in terms of compositing.
>
> > On Fri, Jan 30, 2009 at 3:48 PM, srajpal  wrote:
>
> > > Does someone know how I can overlay an image over the camera preview?
>
> > --
> > 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.  All such questions should be posted on public
> > forums, where I and others can see and answer them.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: gapless playback

2009-01-30 Thread Dave Sparks

Use Ogg files, you can get a nice seamless loop. We use this for the
ringtones.

On Jan 30, 10:30 am, "ph...@grantmidwinter.com"
 wrote:
> Hoya,
>
> When using a mediaplayer to play back an audio file, you can set
> looping to true - that's not the issue here.
>
> If looping is set to true, there's still an audible gap between the
> file finishing and then starting again.
>
> How could I achieve true gapless playback? I've attempted using two
> instances of the same file, overriding oncomplete and onseek.. can't
> seem to improve the gap though. Any help appreciated.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: how to overlay an image over the camera preview?

2009-01-30 Thread srajpal


I checked out the api demo, it helps to place the camera preview on
top of the surface view, but the buffers are handid over to the camera
so anything drawn on the canvas, which is received from the handler,
is ignored.

There must be some way.  I just don't know it yet.




On Jan 30, 7:27 pm, Dianne Hackborn  wrote:
> There is an Api Demo showing how to generally do this with a surface view.
> It's very easy, since SurfaceView essentially operates like any other view
> in terms of compositing.
>
> On Fri, Jan 30, 2009 at 3:48 PM, srajpal  wrote:
>
> > Does someone know how I can overlay an image over the camera preview?
>
> --
> 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.  All such questions should be posted on public
> forums, where I and others can see and answer them.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: J2ME Sprite equivalent api

2009-01-30 Thread Fred Grott(shareme)

Yes but sprite level apis usually are referring to image level
manipulation

And there are some 2d java sprite apis around in fact..


The other way would be filmstrip  the set of images and manipulate
them that way and thus form your own sprite library..

Basically my menu in webview is s et of sprites manipulated by css
with org image sprite sbeing in an image filmstrip..file

Its not hard just takes time to organize..


On Jan 30, 6:47 pm, Dianne Hackborn  wrote:
> Android at the UI level has basically nothing in common with j2se, except
> for the OpenGL APIs.
>
> At any rate, Canvas fully supports arbitrary clipping.
>
> On Fri, Jan 30, 2009 at 4:32 PM, Fred Grott(shareme)
> wrote:
>
>
>
> > Android java is based on j2se so if you look at j2se game libraries
> > you should be able to find a sprite api to use
>
> > On Jan 30, 4:25 am, Raja Nagendra Kumar 
> > wrote:
> > > Does Android has any equivalent Sprint API of J2ME..
>
> > > Drawable does not seem to support cliping regions...
>
> > > Regards,
> > > Raja Nagendra Kumar.
> > > C.T.Owww.tejasoft.com
>
> --
> 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.  All such questions should be posted on public
> forums, where I and others can see and answer them.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: webview extracting html

2009-01-30 Thread Fred Grott(shareme)

Hello Dai, welcome to the new hacking trend Hybrid Moble RIAs

Yes, any html manipulation you do in other RIAs you can do in
webview..


For example that crayon css example where the picture is created with
just css can be done in webview and among other examples.

I would start exploring html 5 entity called canvas..




On Jan 30, 4:34 pm, dai  wrote:
> guys, is it possible to extranct html content from webview component/
> class?
> I wanna show an img file from getting rid of  tag from html of
> webivew.
>
> grazie so much
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: J2ME Sprite equivalent api

2009-01-30 Thread Dianne Hackborn
Android at the UI level has basically nothing in common with j2se, except
for the OpenGL APIs.

At any rate, Canvas fully supports arbitrary clipping.

On Fri, Jan 30, 2009 at 4:32 PM, Fred Grott(shareme)
wrote:

>
> Android java is based on j2se so if you look at j2se game libraries
> you should be able to find a sprite api to use
>
> On Jan 30, 4:25 am, Raja Nagendra Kumar 
> wrote:
> > Does Android has any equivalent Sprint API of J2ME..
> >
> > Drawable does not seem to support cliping regions...
> >
> > Regards,
> > Raja Nagendra Kumar.
> > C.T.Owww.tejasoft.com
> >
>


-- 
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.  All such questions should be posted on public
forums, where I and others can see and answer them.

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



[android-developers] Re: J2ME Sprite equivalent api

2009-01-30 Thread Fred Grott(shareme)

Android java is based on j2se so if you look at j2se game libraries
you should be able to find a sprite api to use

On Jan 30, 4:25 am, Raja Nagendra Kumar 
wrote:
> Does Android has any equivalent Sprint API of J2ME..
>
> Drawable does not seem to support cliping regions...
>
> Regards,
> Raja Nagendra Kumar.
> C.T.Owww.tejasoft.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: how to overlay an image over the camera preview?

2009-01-30 Thread Dianne Hackborn
There is an Api Demo showing how to generally do this with a surface view.
It's very easy, since SurfaceView essentially operates like any other view
in terms of compositing.

On Fri, Jan 30, 2009 at 3:48 PM, srajpal  wrote:

>
> Does someone know how I can overlay an image over the camera preview?
> >
>


-- 
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.  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] how to overlay an image over the camera preview?

2009-01-30 Thread srajpal

Does someone know how I can overlay an image over the camera preview?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Want to help us port our iPhone app to Android?

2009-01-30 Thread Jamie

cool app, im game. email specifics: jamie.hu...@gmail.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: Memory leak in BitmapFactory/Gallery?

2009-01-30 Thread blindfold

Never mind, I found the culprit and fixed it. Not killing all threads
when pressing the back button seems to have been the root cause of my
problems.

On Jan 30, 6:08 pm, blindfold  wrote:
> > I read in this post that I am supposed to have 16Mb available for my
> > computer, but when I check the "heap size" it is never > 2.8Mb, and
> > yet it still crashes.
>
> Did youmakeanyprogresson this? Your description sounds very
> similar to what I experience with my own app. My app never uses more
> than 4 MB or so, leaks some 50 K per run, yet crashes after just a few
> runs (back button - relaunch cycles), unless I kill its process in
> between; it also crashes after a few visits to the home screen with
> the Home button. I'm not making anyprogressin tracking down the root
> causes. I use BitmapFactory (and the camera) but not the Gallery.
>
> Thanks
>
> On Jan 18, 6:44 pm, gymshoe  wrote:
>
> > I don't think I am doing anything "funky".
> > Basically I have a view composed of two pages, one which is visible
> > and one which is invisible at any given time. When the visible page is
> > clicked, the visible page becomes invisible and the invisible page is
> > made visible.
> > One page consists of a gallery.  The other page is an ImageView. Each
> > time the ImageView is made visible it is updated with a call to:
> > ImageView.setImageBitmap(BitmapFactory.decodeFile
> > (currentGalleryPicture)).  After about 20 iterations of this, there is
> > OOM error.
>
> > From your helpful comments, I realize that my OOM error is occurring
> > without the debugger attached.  This must relate then to the decodeFile
> > () problem more than the Gallery memory leak.  I tried attaching the
> > debugger and attempted to get an OOM simply from using gallery, but I
> > was not able to get it to crash.  Perhaps my gallery is too small
> > (20items, each ~20k).
>
> > I read in this post that I am supposed to have 16Mb available for my
> > computer, but when I check the "heap size" it is never > 2.8Mb, and
> > yet it still crashes.  (The "allocated" is never >2Mb...)   When you
> > wrote: "I noticed an immediate continual increase in memory usage ",
> > which memory are you referring to: "heap size" or "allocated"?  I
> > don't see either of these change except when there is GC, which I can
> > identify by the log file, but that doesn't happen very often.  I did
> > notice that if I go very slowly toggling my views, then the uncommon
> > GC that does occur is adequate to prevent an OOM error.  However, the
> > GC certainly isn't doing its job.
>
> > Thanks for your comments, Mike, it improved my understanding of the
> > issues.
>
> > Jim
>
>
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: When does my thread die?

2009-01-30 Thread Mark Murphy

blindfold wrote:
> Aaargh! Thank you for this post, as it led me to fix a memory leak
> where my app would consume 50K more with every run. I was looking into
> all sorts of context leaks, but it was just that threads are not
> automatically killed when pressing the back button to "exit" the app,
> so if one launches a thread in onCreate(), one adds about 10K per run,
> and DDMS will show a growing pile of threads as the run count
> increases...

I try to use queues for controlling work done in background threads,
mostly because that's how I was controlling background threads in
pre-Android development. LinkedBlockingQueue is a great choice, though
there are plenty of others in java.util.concurrent.

(java.util.concurrent, by the way, written by Doug Lea, author of the
book and the extract of same that M. Perrot linked to)

So, in onDestroy(), I just pop my own KillEvent object on the queue(s)
and, once the queues get to that message, they terminate their own
threads simply by falling out of the queue-processing loop. So long as
your queues don't get backed up too deep, you should be OK, and I think
there's a priority queue implementation in java.util.concurrent as well
if your threads still aren't closing up shop fast enough.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com
_The Busy Coder's Guide to Android Development_ Version 2.0 Published!

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: When does my thread die?

2009-01-30 Thread blindfold

Aaargh! Thank you for this post, as it led me to fix a memory leak
where my app would consume 50K more with every run. I was looking into
all sorts of context leaks, but it was just that threads are not
automatically killed when pressing the back button to "exit" the app,
so if one launches a thread in onCreate(), one adds about 10K per run,
and DDMS will show a growing pile of threads as the run count
increases...

Thanks

On Jan 24, 4:04 pm, Guillaume Perrot  wrote:
> If you want to stop athreadthat is running long operations, you
> should read this:http://g.oswego.edu/dl/cpj/cancel.html.
> In your service onDestroy you should not "join" yourthread, just
> launch the cancel operation, the trick with all lifecycle methods
> (including services) is that they are called in the mainthread.
> If you block on the mainthread, you won't be able to start a new
> activity from this process (the process is rarely stopped, and
> relaunched automatically when a crash occurs), it will freeze and
> you'll see the "sorry dialog" with the "wait" and "force close"
> buttons.
>
> On Jan 24, 11:01 am, Mariano Kamp  wrote:
>
> > And when implementing stuff as a service where would the actual long running
> > functionality go?
> > In a separatethread?
> > How should I stop thatthread?
>
> > Is acting on Service.onDestroy() the right time and will it definitively be
> > called?
> > How much time do I have in onDestroy()?
> > Is it acceptable behavior to set a flag that the backgroundthreadshould
> > stop and then wait for thethreadsignaling that it is finished?
>
> > To illustrate that, think of a Download Service that should download four
> > files.
> > When onDestroy() is called a flag shouldShutdown is set to true and
> > onDestroy() waits then for thethreadto finish (Thread.join()).
> > Thethreaditself is in the midst of downloading the 2nd file and monitors
> > shouldShutdown and doesn't start a new download (if possible doesn't even
> > ask for the next bytes) when it is set, but cleans up resources (open
> > connections) and terminates itself.
>
> > Is that ok?
>
> > It would certainly not help the OS to quickly get rid of the service, at
> > least when the service is busy with a "long" lasting operation.
>
> > On Fri, Jan 23, 2009 at 6:45 PM, Dianne Hackborn wrote:
>
> > > On Fri, Jan 23, 2009 at 7:47 AM, g1bb  wrote:
>
> > >> I realized this right after I posted, by running a bunch of other apps
> > >> while my app was still running. It seems like 'setPersistent' on the
> > >> activity should most likely prevent this. Any ideas?
>
> > > DO NOT DO THAT.
>
> > > Please read this:http://code.google.com/android/intro/lifecycle.html
>
> > > Basically you should have things you want to continue running in the
> > > background implemented as a Service.
>
> > > Also there is generally no need to create a whole newThreadfor this kind
> > > of stuff, you can just post delayed messages to your own handler.
>
> > > Finally, for something like a countdown timer, you really might want to
> > > consider using the alarm manager so you don't need to keep your app 
> > > running
> > > at all while it is in the background.  That is the kind of thing a well
> > > behaving Android app will do.  To be able to show the remaining time if 
> > > the
> > > user returns to your activity, you can store on SharedPreferences the time
> > > the countdown was started.
>
> > > Using the alarm manager is also the only way you can make sure you execute
> > > when the time expires, even if the user has turned off the phone.
>
> > >> Thanks again.
>
> > >> On Jan 23, 8:36 am, Torgny  wrote:
> > >> > Your application background process might get killed if you run
> > >> > another application that takes up a lot of memory, for instance the
> > >> > browser with several windows. As far as I understand it, the
> > >> > application in the foreground takes priority as far as memory and
> > >> > processing power goes over services and threads.
>
> > >> > On Jan 23, 9:15 am, g1bb  wrote:
>
> > >> > > Hello,
>
> > >> > > I've created an app that functions as a countdown timer via athread,
> > >> > > a wakelock, and a handler back to my activity. My question is, what
> > >> > > will cause mythreadto die, or app to not be running in memory
> > >> > > anymore? I've had this happen once, and can't seem to recreate it
> > >> > > again.
>
> > >> > > Thanks in advance!- Hide quoted text -
>
> > >> > - Show quoted text -
>
> > > --
> > > 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.  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 fr

[android-developers] Re: Swapping in and out ViewGroups (Layout) within a container ViewGroup.

2009-01-30 Thread steele johnson

Ok, I figured it out.

When you use LayoutInflater.inflate(id, root), the return value will
be the inflated xml root if you _didn't_ provide the root, or it will
be the root if you did. To remedy the problem I was having, I simple
passed null for the root and then called mContainerLayout.addView
(mInnerLayout) and it worked. What was happen is that it was returning
the root and I thought it was the inner layout. ;)

On Jan 30, 5:39 pm, steele johnson  wrote:
> Hello,
> ViewFlipper doesn't help either because I still need to add the layout
> dynamically. The problem really comes down to this:
>
> mInnerLayout = (LinearLayout) layout.inflate(
>                                         R.layout.multiple_select, 
> mContainerLayout);
>
> How can I add mInnerLayout to mContainerLayout after it has been
> removed?
>
> On Jan 30, 5:02 pm, Mark Murphy  wrote:
>
> > steele johnson wrote:
> > > I'm trying to dynamically swap in and out various layouts to one
> > > layout container.
>
> > Option #1: go the path you are trying
>
> > Option #2: use ViewFlipper or ViewSwitcher for parent container and have
> > it handle changing the children
>
> > > I've instantiated the container layout (mContainerLayout) by finding
> > > it using the id through the maine Activity layout. This is successful.
>
> > > Next, I add the inner layout by calling:
>
> > > layoutInflater = this.getLayoutInflater();
>
> > > and then inflating the inner layout like this:
>
> > > mInnerLayout = (LinearLayout) layoutInflater .inflate(
> > >                                    R.layout.inner_layout, 
> > > mContainerLayout);
>
> > > This seems to work fine. I see the inner layout displayed in the
> > > Activity that holds the containing layout. Next, I want to swap in
> > > another inner layout, so I call:
>
> > > mContainerLayout.removeAllViews();
>
> > > and then I repeat the steps above. This is successful as well.
>
> > > The problem is when I try to swap in and out the instantiated layouts
> > > (the one that's returned from the inflate() call). When I call:
>
> > > mContainerLayout.removeAllViews();
>
> > > and then call:
>
> > > mContainerLayout.addView(mInnerLayout );
>
> > > I get a 'source not found' error.
>
> > > My question is: how can I swap the Layouts that have already been
> > > instantiated?
>
> > Try removing the single view representing the "inner layout" instead of
> > the whole view tree. In other words, use removeView() instead of
> > removeAllViews().
>
> > Personally, I typically just use ViewFlipper, so it can handle this
> > case, plus give me the option for animating the transition between child
> > views if I so choose.
>
> > --
> > Mark Murphy (a Commons Guy)http://commonsware.com
> > _The Busy Coder's Guide to Android Development_ Version 2.0 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: Swapping in and out ViewGroups (Layout) within a container ViewGroup.

2009-01-30 Thread steele johnson

Hello,
ViewFlipper doesn't help either because I still need to add the layout
dynamically. The problem really comes down to this:

mInnerLayout = (LinearLayout) layout.inflate(
R.layout.multiple_select, 
mContainerLayout);

How can I add mInnerLayout to mContainerLayout after it has been
removed?

On Jan 30, 5:02 pm, Mark Murphy  wrote:
> steele johnson wrote:
> > I'm trying to dynamically swap in and out various layouts to one
> > layout container.
>
> Option #1: go the path you are trying
>
> Option #2: use ViewFlipper or ViewSwitcher for parent container and have
> it handle changing the children
>
>
>
> > I've instantiated the container layout (mContainerLayout) by finding
> > it using the id through the maine Activity layout. This is successful.
>
> > Next, I add the inner layout by calling:
>
> > layoutInflater = this.getLayoutInflater();
>
> > and then inflating the inner layout like this:
>
> > mInnerLayout = (LinearLayout) layoutInflater .inflate(
> >                                    R.layout.inner_layout, mContainerLayout);
>
> > This seems to work fine. I see the inner layout displayed in the
> > Activity that holds the containing layout. Next, I want to swap in
> > another inner layout, so I call:
>
> > mContainerLayout.removeAllViews();
>
> > and then I repeat the steps above. This is successful as well.
>
> > The problem is when I try to swap in and out the instantiated layouts
> > (the one that's returned from the inflate() call). When I call:
>
> > mContainerLayout.removeAllViews();
>
> > and then call:
>
> > mContainerLayout.addView(mInnerLayout );
>
> > I get a 'source not found' error.
>
> > My question is: how can I swap the Layouts that have already been
> > instantiated?
>
> Try removing the single view representing the "inner layout" instead of
> the whole view tree. In other words, use removeView() instead of
> removeAllViews().
>
> Personally, I typically just use ViewFlipper, so it can handle this
> case, plus give me the option for animating the transition between child
> views if I so choose.
>
> --
> Mark Murphy (a Commons Guy)http://commonsware.com
> _The Busy Coder's Guide to Android Development_ Version 2.0 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] webview extracting html

2009-01-30 Thread dai

guys, is it possible to extranct html content from webview component/
class?
I wanna show an img file from getting rid of  tag from html of
webivew.

grazie so much
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: discover intents that an app supports

2009-01-30 Thread Dianne Hackborn
And btw, a significant number of things you can do with the applications are
documented in the Intent class as generic protocols (such as VIEW or
GET_CONTENT) along with the various MIME types and URIs defined by the
standard content providers in android.provider.

On Fri, Jan 30, 2009 at 2:29 PM, Dianne Hackborn wrote:

> I'll still say, if it hasn't been documented, then you probably have no
> business using it.
>
> If you want to go use private implementation details of the platform, you
> can browse through the source code and look at the manifests of the apps.
> That is all that the system knows about the intent protocols they support.
>
>
> On Fri, Jan 30, 2009 at 1:07 PM, jarkman  wrote:
>
>>
>> I understand the point about trying to stick to intents which have
>> been documented by their developers.
>>
>> The problem is, even a well-intentioned but busy developer may simply
>> not get round to writing that documentation. The system applications
>> are a great example of that effect.
>>
>> At least, with a discovery API, we could find out what the things were
>> in some reliable way. We'd also have a better chance of understanding
>> why our intents failed when they did. Right now, I sometimes feel like
>> I'm on a random hunt for a magic string. It is the single most
>> frustrating thing about developing for Android.
>>
>> Do you think there's any chance one will appear in a future version ?
>>
>> Or, can you think of any way to acheive the effect in the current
>> version ? I had a vague idea about feeding generalities to
>> PackageManager.queryIntentActivities(), but I have not found a way to
>> make that work.
>>
>> Thanks,
>>
>> Richard
>>
>>
>>
>>
>> On Jan 30, 8:31 pm, Dianne Hackborn  wrote:
>> > You shouldn't just look at what intents an app happens to use: unless
>> > someone publishes official protocols, those should be considered
>> private.
>> > Unless an app developer is explicitly maintaining them, they could
>> change
>> > their app arbitrarily and break someone using those implementation
>> details.
>> >
>> > And Amazon MP3 app is owned by amazon, who just happened to have it
>> > installed on the G1.  It is not part of the platform, and so they would
>> need
>> > to document and maintain whatever intent protocols they want to publish.
>> >
>> > Finally, yes, we need to do a better job at defining official protocols
>> for
>> > the system applications.  This is something that got dropped in the push
>> to
>> > get the initial full product out.
>> >
>> >
>> >
>> > On Fri, Jan 30, 2009 at 11:48 AM, jarkman  wrote:
>> >
>> > > Peter - I agree completely. OpenIntents is a great idea, but it
>> > > doesn't fix my problem either.
>> >
>> > > The strangeness is not just limited to the lack of a discovery API.
>> > > There's also a peculiar lack of documentation on what the built-in
>> > > apps can do, leaving us wasting a lot of time poking about making up
>> > > intents by experiment.
>> >
>> > > My hope is that both of these - intent discovery APIs and better docs
>> > > on the existing intents - are in the plan, just not done yet.
>> >
>> > > Richard
>> >
>> > > On Jan 30, 5:29 pm, Peter Jeffe  wrote:
>> > > > On Jan 30, 10:45 am, Peli  wrote:
>> >
>> > > > > For this reason, we have created the OpenIntents intents registry:
>> > >
>> http://www.openintents.org/en/http://www.openintents.org/en/intentstable
>> >
>> > > > > Even if there is a way to find all intents supported by an
>> > > > > application, this will not tell you what kind of extras are
>> supported
>> > > > > or required or which result (if at all) is returned.
>> >
>> > > > I think your site is great Peli, I agree with your reasoning and
>> > > > applaud your efforts.  Unfortunately in this case I'm interested in
>> > > > invoking the Amazon MP3 app, and no one has registered it on
>> > > > OpenIntents, so I was trying to discover anything I could about it.
>> >
>> > > > I think it is very strange that Android has this nice concept of
>> apps
>> > > > registering the services that they provide, but there's no means for
>> > > > other apps to discover what services are provided.  Is it just me,
>> or
>> > > > does anyone else think this really limits the usefulness of this
>> > > > feature?
>> >
>> > > > -- Peter
>> >
>> > --
>> > 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.  All such questions should be posted on public
>> > forums, where I and others can see and answer them.
>> >>
>>
>
>
> --
> 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.  All such questions should be posted on public
> forums, where I and others can see and answer them.
>
>


-- 
Dianne Hackborn
Android framework engineer
hack...@android.com

Note: please don't send private questions to me

[android-developers] Re: discover intents that an app supports

2009-01-30 Thread Dianne Hackborn
I'll still say, if it hasn't been documented, then you probably have no
business using it.

If you want to go use private implementation details of the platform, you
can browse through the source code and look at the manifests of the apps.
That is all that the system knows about the intent protocols they support.

On Fri, Jan 30, 2009 at 1:07 PM, jarkman  wrote:

>
> I understand the point about trying to stick to intents which have
> been documented by their developers.
>
> The problem is, even a well-intentioned but busy developer may simply
> not get round to writing that documentation. The system applications
> are a great example of that effect.
>
> At least, with a discovery API, we could find out what the things were
> in some reliable way. We'd also have a better chance of understanding
> why our intents failed when they did. Right now, I sometimes feel like
> I'm on a random hunt for a magic string. It is the single most
> frustrating thing about developing for Android.
>
> Do you think there's any chance one will appear in a future version ?
>
> Or, can you think of any way to acheive the effect in the current
> version ? I had a vague idea about feeding generalities to
> PackageManager.queryIntentActivities(), but I have not found a way to
> make that work.
>
> Thanks,
>
> Richard
>
>
>
>
> On Jan 30, 8:31 pm, Dianne Hackborn  wrote:
> > You shouldn't just look at what intents an app happens to use: unless
> > someone publishes official protocols, those should be considered private.
> > Unless an app developer is explicitly maintaining them, they could change
> > their app arbitrarily and break someone using those implementation
> details.
> >
> > And Amazon MP3 app is owned by amazon, who just happened to have it
> > installed on the G1.  It is not part of the platform, and so they would
> need
> > to document and maintain whatever intent protocols they want to publish.
> >
> > Finally, yes, we need to do a better job at defining official protocols
> for
> > the system applications.  This is something that got dropped in the push
> to
> > get the initial full product out.
> >
> >
> >
> > On Fri, Jan 30, 2009 at 11:48 AM, jarkman  wrote:
> >
> > > Peter - I agree completely. OpenIntents is a great idea, but it
> > > doesn't fix my problem either.
> >
> > > The strangeness is not just limited to the lack of a discovery API.
> > > There's also a peculiar lack of documentation on what the built-in
> > > apps can do, leaving us wasting a lot of time poking about making up
> > > intents by experiment.
> >
> > > My hope is that both of these - intent discovery APIs and better docs
> > > on the existing intents - are in the plan, just not done yet.
> >
> > > Richard
> >
> > > On Jan 30, 5:29 pm, Peter Jeffe  wrote:
> > > > On Jan 30, 10:45 am, Peli  wrote:
> >
> > > > > For this reason, we have created the OpenIntents intents registry:
> > >
> http://www.openintents.org/en/http://www.openintents.org/en/intentstable
> >
> > > > > Even if there is a way to find all intents supported by an
> > > > > application, this will not tell you what kind of extras are
> supported
> > > > > or required or which result (if at all) is returned.
> >
> > > > I think your site is great Peli, I agree with your reasoning and
> > > > applaud your efforts.  Unfortunately in this case I'm interested in
> > > > invoking the Amazon MP3 app, and no one has registered it on
> > > > OpenIntents, so I was trying to discover anything I could about it.
> >
> > > > I think it is very strange that Android has this nice concept of apps
> > > > registering the services that they provide, but there's no means for
> > > > other apps to discover what services are provided.  Is it just me, or
> > > > does anyone else think this really limits the usefulness of this
> > > > feature?
> >
> > > > -- Peter
> >
> > --
> > 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.  All such questions should be posted on public
> > forums, where I and others can see and answer them.
> >
>


-- 
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.  All such questions should be posted on public
forums, where I and others can see and answer them.

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



[android-developers] Re: Need help in running the android junit test case for andriod APIDemo in eclipse

2009-01-30 Thread ying lcs

Hi,

I tried that again, but it does not work now, for some reason.

I did load 'ApiDemos' project first, but I don't see the 'Test for Api
Demo' in the 'Instrumentation.' screen.
Then, I manually load the 'ApiDemosTest2' project again, I still don't
see the  'Test for Api Demo'.

But from the Eclipse output, I do see that both apk has been installed.

Any idea why it does not work?
Thank you for any help.

[2009-01-30 14:09:26 - ApiDemos] HOME is up on device 'emulator-5554'
[2009-01-30 14:09:26 - ApiDemos] Uploading ApiDemos.apk onto device
'emulator-5554'
[2009-01-30 14:09:28 - ApiDemos] Installing ApiDemos.apk...
[2009-01-30 14:09:37 - ApiDemos] Success!
[2009-01-30 14:09:38 - ApiDemos] Starting activity
com.example.android.apis.ApiDemos on device
[2009-01-30 14:09:39 - ApiDemos] ActivityManager: Starting: Intent {
comp={com.example.android.apis/com.example.android.apis.ApiDemos} }
[2009-01-30 14:09:39 - ApiDemos] Attempting to connect debugger to
'com.example.android.apis' on port 8613
[2009-01-30 14:15:00 - ApiDemosTest2] --
[2009-01-30 14:15:00 - ApiDemosTest2] Android Launch!
[2009-01-30 14:15:00 - ApiDemosTest2] adb is running normally.
[2009-01-30 14:15:00 - ApiDemosTest2] Launching:
com.example.android.apis.tests.Dummy
[2009-01-30 14:15:00 - ApiDemosTest2] Automatic Target Mode: using
existing emulator: emulator-5554
[2009-01-30 14:15:00 - ApiDemosTest2] Uploading ApiDemosTest2.apk onto
device 'emulator-5554'
[2009-01-30 14:15:00 - ApiDemosTest2] Installing ApiDemosTest2.apk...
[2009-01-30 14:15:03 - ApiDemosTest2] Success!
[2009-01-30 14:15:03 - ApiDemosTest2] Starting activity
com.example.android.apis.tests.Dummy on device
[2009-01-30 14:15:04 - ApiDemosTest2] ActivityManager: Starting:
Intent { 
comp={com.example.android.apis.tests/com.example.android.apis.tests.Dummy}
}
[2009-01-30 14:15:04 - ApiDemosTest2] Attempting to connect debugger
to 'com.example.android.apis.tests' on port 8617


On Thu, Jan 29, 2009 at 6:31 PM, Xavier Ducrohet  wrote:
>
> Using the "new android project" wizard, you can create a project from
> existing source.
> This is probably what you used to create a project for ApiDemos. Just
> use it again for the tests project (point the wizard to
> /samples/ApiDemos/tests).
>
> The compilation problem is because the tests project doesn't know the
> ApiDemos classes until you tell it where they are.
> Right click the tests project in the package Explorer and choose Build
> Path > Configure Build Path.
> In the "Projects" tab, click Add and choose your ApiDemos project.
>
> Because deployment of instrumentation projects is not supported in ADT
> you will have install ApiDemos and your test project manually.
>
> We do intend to improve this workflow in the future.
>
> Xav
>
> On Thu, Jan 29, 2009 at 6:25 PM, ying lcs  wrote:
>>
>> On Thu, Jan 29, 2009 at 6:12 PM, Xavier Ducrohet  wrote:
>>>
>>> You will never really be able to just use the default Run as JUnit test 
>>> action.
>>>
>>> This is because this setups up the tests to run using the system
>>> library of the project which, for Android project, is android.jar.
>>> android.jar in the SDK is only stubbed methods/classes, and contains no 
>>> code.
>>>
>>> You can run unit tests by setting up Eclipse using the follow
>>> instructions: 
>>> http://code.google.com/android/kb/troubleshooting.html#addjunit
>>>
>>> Note that this will only work for tests not using the Android APIs.
>>>
>> Thanks. But most likely most of my classes will use android APIs, so
>> using this to unit-test is not that common, right?
>> Or I am mis-understanding the condition.
>> I would like to have 1 way to unit-test my android code.
>>
>>
>>> If you wish to run true android test, please use instrumentations
>>> running on the device.
>>> See 
>>> http://code.google.com/android/reference/android/test/InstrumentationTestRunner.html
>>> for more information.
>>>
>>
>>
>>
>>> The information from Diego to setup the test runners for ApiDemos is
>>> good, except that you don't need to create a new project and copy
>>> things over, you can simply create a project for the existing source
>>> (you will need to link the apidemos project in your build path).
>>>
>>
>> Thank you. I have followed Diego instructions, and I finally get that to 
>> work.
>> But you mention that there a way not to create a new project.
>> Can you please tell me how to do that?
>>
>> I have create an 'apidemos' project in eclipse, but the 'tests'
>> directory is not in the build path. Hence they are not compile.
>>
>> So what should I do to run the code 'tests' code without creating a
>> new project like Diego described.
>>
>> Thank you for any tips.
>>
>>
>>> Xav
>>>
>>> On Thu, Jan 29, 2009 at 5:44 PM, ying...@gmail.com  
>>> wrote:

 Thanks. But can you please tell me if it is possible to
 * run junit test within eclipse using the 'Debug->Run as Junit Test'?
 * run junit test as part of the ant script? (i.e. automatically via
 comma

[android-developers] ADP1 not showing in ddms

2009-01-30 Thread Cassius

Hi,
my ADP1 is not showing in ddms, I have:

Ubuntu 8.10
eclipse version: 3.4.1
jdk: sun-java6-jdk
android-sdk-linux_x86-1.0_r2

I'be also removed default-jdk and openjdk-6-jdk to be sure.

On: telnet localhost 9700
I have: Trying 127.0.0.1...
Connected to localhost.

When I start ddms on psauxf I have:
PID%CPU  %MEMVSZ  RSSTTYSTATSTART   TIME COMMAND
7532 26.5  3.2  131348  66888 ?Sl
23:130:03 java -Xmx256M -


It's a usb - serial driver problem?

On Windows I haven't any problem, but I don't want to use Windows!

Any hint?

Thanks,
Maurizio

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Swapping in and out ViewGroups (Layout) within a container ViewGroup.

2009-01-30 Thread steele johnson

Thanks for the help. I'll check out ViewFlipper.

On Jan 30, 5:02 pm, Mark Murphy  wrote:
> steele johnson wrote:
> > I'm trying to dynamically swap in and out various layouts to one
> > layout container.
>
> Option #1: go the path you are trying
>
> Option #2: use ViewFlipper or ViewSwitcher for parent container and have
> it handle changing the children
>
>
>
> > I've instantiated the container layout (mContainerLayout) by finding
> > it using the id through the maine Activity layout. This is successful.
>
> > Next, I add the inner layout by calling:
>
> > layoutInflater = this.getLayoutInflater();
>
> > and then inflating the inner layout like this:
>
> > mInnerLayout = (LinearLayout) layoutInflater .inflate(
> >                                    R.layout.inner_layout, mContainerLayout);
>
> > This seems to work fine. I see the inner layout displayed in the
> > Activity that holds the containing layout. Next, I want to swap in
> > another inner layout, so I call:
>
> > mContainerLayout.removeAllViews();
>
> > and then I repeat the steps above. This is successful as well.
>
> > The problem is when I try to swap in and out the instantiated layouts
> > (the one that's returned from the inflate() call). When I call:
>
> > mContainerLayout.removeAllViews();
>
> > and then call:
>
> > mContainerLayout.addView(mInnerLayout );
>
> > I get a 'source not found' error.
>
> > My question is: how can I swap the Layouts that have already been
> > instantiated?
>
> Try removing the single view representing the "inner layout" instead of
> the whole view tree. In other words, use removeView() instead of
> removeAllViews().
>
> Personally, I typically just use ViewFlipper, so it can handle this
> case, plus give me the option for animating the transition between child
> views if I so choose.
>
> --
> Mark Murphy (a Commons Guy)http://commonsware.com
> _The Busy Coder's Guide to Android Development_ Version 2.0 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: Swapping in and out ViewGroups (Layout) within a container ViewGroup.

2009-01-30 Thread Mark Murphy

steele johnson wrote:
> I'm trying to dynamically swap in and out various layouts to one
> layout container.

Option #1: go the path you are trying

Option #2: use ViewFlipper or ViewSwitcher for parent container and have
it handle changing the children

> I've instantiated the container layout (mContainerLayout) by finding
> it using the id through the maine Activity layout. This is successful.
> 
> Next, I add the inner layout by calling:
> 
> layoutInflater = this.getLayoutInflater();
> 
> and then inflating the inner layout like this:
> 
> mInnerLayout = (LinearLayout) layoutInflater .inflate(
>   R.layout.inner_layout, 
> mContainerLayout);
> 
> This seems to work fine. I see the inner layout displayed in the
> Activity that holds the containing layout. Next, I want to swap in
> another inner layout, so I call:
> 
> mContainerLayout.removeAllViews();
> 
> and then I repeat the steps above. This is successful as well.
> 
> The problem is when I try to swap in and out the instantiated layouts
> (the one that's returned from the inflate() call). When I call:
> 
> mContainerLayout.removeAllViews();
> 
> and then call:
> 
> mContainerLayout.addView(mInnerLayout );
> 
> I get a 'source not found' error.
> 
> My question is: how can I swap the Layouts that have already been
> instantiated?

Try removing the single view representing the "inner layout" instead of
the whole view tree. In other words, use removeView() instead of
removeAllViews().

Personally, I typically just use ViewFlipper, so it can handle this
case, plus give me the option for animating the transition between child
views if I so choose.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com
_The Busy Coder's Guide to Android Development_ Version 2.0 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] Swapping in and out ViewGroups (Layout) within a container ViewGroup.

2009-01-30 Thread steele johnson

Hello,
I'm trying to dynamically swap in and out various layouts to one
layout container.

I've instantiated the container layout (mContainerLayout) by finding
it using the id through the maine Activity layout. This is successful.

Next, I add the inner layout by calling:

layoutInflater = this.getLayoutInflater();

and then inflating the inner layout like this:

mInnerLayout = (LinearLayout) layoutInflater .inflate(
R.layout.inner_layout, 
mContainerLayout);

This seems to work fine. I see the inner layout displayed in the
Activity that holds the containing layout. Next, I want to swap in
another inner layout, so I call:

mContainerLayout.removeAllViews();

and then I repeat the steps above. This is successful as well.

The problem is when I try to swap in and out the instantiated layouts
(the one that's returned from the inflate() call). When I call:

mContainerLayout.removeAllViews();

and then call:

mContainerLayout.addView(mInnerLayout );

I get a 'source not found' error.

My question is: how can I swap the Layouts that have already been
instantiated?

Thank you


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



[android-developers] Re: performCompletion on AutoCompleteTextView

2009-01-30 Thread oliver

thanks for your answer. good to hear it's gonna be fixed in cupcake.
the reason i call performCompletion() is i also want to react to
certain key events. a key event does not trigger the completion by
itself.

cheers,
oliver


On Jan 30, 6:54 pm, Romain Guy  wrote:
> This will all be fixed in cupcake. But why do you need to call
> performCompletion() yourself? There is no reason to do so.
>
>
>
> On Fri, Jan 30, 2009 at 3:43 AM, oliver  wrote:
>
> > hi,
> > i'm having a problem when using the performCompletion method on an
> > AutoCompleteTextView.
> > when i start typing the suggestions work fine (an entry is
> > highlighted). as soon as i type enough characters so that no match is
> > possible anymore, the suggestion list disappears (which is ok).
> > when i know delete some characters so the suggestion list appears
> > again nothing will be selected (even though it will still narrow down
> > it's hits the more characters i type again)
> > now the problem:  in an onKey listener i check if the suggestions are
> > showing (isPopupShowing) and if so i try to call performCompletion.
> > now the AutoCompleteListener finds out that nothing is selected and
> > replaces my content with "".
>
> > does anybody know of a way
> > - how to re-enable the selection on the suggestion list ?
> > - or how to find out if anything is selected at all? in that case i
> > would not call the performCompletion method
>
> > thnx!
>
> --
> Romain Guy
> Android framework engineer
> romain...@android.com
>
> Note: please don't send private questions to me, as I don't have time
> to provide private support.  All such questions should be posted on
> public forums, where I and others can see and answer them
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: discover intents that an app supports

2009-01-30 Thread jarkman

I understand the point about trying to stick to intents which have
been documented by their developers.

The problem is, even a well-intentioned but busy developer may simply
not get round to writing that documentation. The system applications
are a great example of that effect.

At least, with a discovery API, we could find out what the things were
in some reliable way. We'd also have a better chance of understanding
why our intents failed when they did. Right now, I sometimes feel like
I'm on a random hunt for a magic string. It is the single most
frustrating thing about developing for Android.

Do you think there's any chance one will appear in a future version ?

Or, can you think of any way to acheive the effect in the current
version ? I had a vague idea about feeding generalities to
PackageManager.queryIntentActivities(), but I have not found a way to
make that work.

Thanks,

Richard




On Jan 30, 8:31 pm, Dianne Hackborn  wrote:
> You shouldn't just look at what intents an app happens to use: unless
> someone publishes official protocols, those should be considered private.
> Unless an app developer is explicitly maintaining them, they could change
> their app arbitrarily and break someone using those implementation details.
>
> And Amazon MP3 app is owned by amazon, who just happened to have it
> installed on the G1.  It is not part of the platform, and so they would need
> to document and maintain whatever intent protocols they want to publish.
>
> Finally, yes, we need to do a better job at defining official protocols for
> the system applications.  This is something that got dropped in the push to
> get the initial full product out.
>
>
>
> On Fri, Jan 30, 2009 at 11:48 AM, jarkman  wrote:
>
> > Peter - I agree completely. OpenIntents is a great idea, but it
> > doesn't fix my problem either.
>
> > The strangeness is not just limited to the lack of a discovery API.
> > There's also a peculiar lack of documentation on what the built-in
> > apps can do, leaving us wasting a lot of time poking about making up
> > intents by experiment.
>
> > My hope is that both of these - intent discovery APIs and better docs
> > on the existing intents - are in the plan, just not done yet.
>
> > Richard
>
> > On Jan 30, 5:29 pm, Peter Jeffe  wrote:
> > > On Jan 30, 10:45 am, Peli  wrote:
>
> > > > For this reason, we have created the OpenIntents intents registry:
> >http://www.openintents.org/en/http://www.openintents.org/en/intentstable
>
> > > > Even if there is a way to find all intents supported by an
> > > > application, this will not tell you what kind of extras are supported
> > > > or required or which result (if at all) is returned.
>
> > > I think your site is great Peli, I agree with your reasoning and
> > > applaud your efforts.  Unfortunately in this case I'm interested in
> > > invoking the Amazon MP3 app, and no one has registered it on
> > > OpenIntents, so I was trying to discover anything I could about it.
>
> > > I think it is very strange that Android has this nice concept of apps
> > > registering the services that they provide, but there's no means for
> > > other apps to discover what services are provided.  Is it just me, or
> > > does anyone else think this really limits the usefulness of this
> > > feature?
>
> > > -- Peter
>
> --
> 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.  All such questions should be posted on public
> forums, where I and others can see and answer them.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: how to implement scrolling text?

2009-01-30 Thread Romain Guy

Note that cupcake will have the marquee feature on TextView.

On Fri, Jan 30, 2009 at 12:31 PM, Zach Hobbs  wrote:
>
> You can create a custom singleLine TextView and animate it by creating a loop
> and calling scrollBy(x,y) incrementing/decrementing the x value.
>
> -Zach
>
>
>
>
> On Thursday 29 January 2009 7:47:49 pm Rodrigo wrote:
>> HI,
>>
>> What is the best way to implement scrolling text (with behavior
>> similar to that of HTML tag 'marquee')??
>>
>> I've been trying to do this using TextViews + Animations but I'm
>> having troubles primarily because of sizing issues. If my text is long
>> enough that it exceeds the screen width, it won't be drawn completely
>> (it's size will be chopped at screen width). Thus,  when I animate it
>> from right to left, only a part of the text will be displayed. This
>> happens if I allow a maximum of 1 line in my TextView, because
>> otherwise it makes the TextView have multiple lines. If I make it
>> horizontally scrollable, the same 'chopped-off' behavior is seen.
>>
>> I think this happens because the TextView's parent imposes some
>> restrictions on its size. Is there a way to bypass these restrictions
>> so that the TextView is 'drawn' even if parts of it will be off-
>> screen?
>>
>> If that's not possible, what's an alternative way of implementing this
>> behavior?
>>
>> Thanks!
>>
>
>
> --
>
> Zach Hobbs
> HelloAndroid.com
> Android OS news, tutorials, downloads
>
> >
>



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

Note: please don't send private questions to me, as I don't have time
to provide private support.  All such questions should be posted on
public forums, where I and others can see and answer them

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



[android-developers] Re: Want to help us port our iPhone app to Android?

2009-01-30 Thread mathiastck

Then you linux types may want to try:

http://app-store.appspot.com/

pulling the ID out of cmxlgy's link and dropping it here works for me:

http://app-store.appspot.com/?url=viewSoftware%3Fid%3D297414943

On Jan 29, 9:05 pm, wellwatch  wrote:
> dude, I run linux and can't install itunes can you give me another
> link to your app?
>
> On Jan 29, 8:55 pm, cmxlgy  wrote:
>
> > Hi all -
>
> > Just curious if anyone would be interested in helping us port our
> > iPhone app to Android? It would be on a revenue share basis. Drop us a
> > line off-list.
>
> > Link to app:
>
> >http://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=297...
>
> > Thanks
>
>
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: How to scroll a Listview to focus a particular element?

2009-01-30 Thread mysmallbrain

Hi,

I had a problem on a listview to scroll the items with the up / down
keys
(the selected item gets invisible or out of screen). My solution for
that
problem was:
..
public void onItemSelected(AdapterView parent, View v, int position,
long id) {
// adjust visible state of the item if necessary
Rect r = new Rect();
v.getHitRect(r);
getListView().requestRectangleOnScreen(r);
  ...
}
..

--
CU
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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 implement scrolling text?

2009-01-30 Thread Zach Hobbs

You can create a custom singleLine TextView and animate it by creating a loop 
and calling scrollBy(x,y) incrementing/decrementing the x value.

-Zach




On Thursday 29 January 2009 7:47:49 pm Rodrigo wrote:
> HI,
>
> What is the best way to implement scrolling text (with behavior
> similar to that of HTML tag 'marquee')??
>
> I've been trying to do this using TextViews + Animations but I'm
> having troubles primarily because of sizing issues. If my text is long
> enough that it exceeds the screen width, it won't be drawn completely
> (it's size will be chopped at screen width). Thus,  when I animate it
> from right to left, only a part of the text will be displayed. This
> happens if I allow a maximum of 1 line in my TextView, because
> otherwise it makes the TextView have multiple lines. If I make it
> horizontally scrollable, the same 'chopped-off' behavior is seen.
>
> I think this happens because the TextView's parent imposes some
> restrictions on its size. Is there a way to bypass these restrictions
> so that the TextView is 'drawn' even if parts of it will be off-
> screen?
>
> If that's not possible, what's an alternative way of implementing this
> behavior?
>
> Thanks!
> 


-- 

Zach Hobbs 
HelloAndroid.com 
Android OS news, tutorials, downloads

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: discover intents that an app supports

2009-01-30 Thread Dianne Hackborn
You shouldn't just look at what intents an app happens to use: unless
someone publishes official protocols, those should be considered private.
Unless an app developer is explicitly maintaining them, they could change
their app arbitrarily and break someone using those implementation details.

And Amazon MP3 app is owned by amazon, who just happened to have it
installed on the G1.  It is not part of the platform, and so they would need
to document and maintain whatever intent protocols they want to publish.

Finally, yes, we need to do a better job at defining official protocols for
the system applications.  This is something that got dropped in the push to
get the initial full product out.

On Fri, Jan 30, 2009 at 11:48 AM, jarkman  wrote:

>
> Peter - I agree completely. OpenIntents is a great idea, but it
> doesn't fix my problem either.
>
> The strangeness is not just limited to the lack of a discovery API.
> There's also a peculiar lack of documentation on what the built-in
> apps can do, leaving us wasting a lot of time poking about making up
> intents by experiment.
>
> My hope is that both of these - intent discovery APIs and better docs
> on the existing intents - are in the plan, just not done yet.
>
> Richard
>
>
> On Jan 30, 5:29 pm, Peter Jeffe  wrote:
> > On Jan 30, 10:45 am, Peli  wrote:
> >
> > > For this reason, we have created the OpenIntents intents registry:
> http://www.openintents.org/en/http://www.openintents.org/en/intentstable
> >
> > > Even if there is a way to find all intents supported by an
> > > application, this will not tell you what kind of extras are supported
> > > or required or which result (if at all) is returned.
> >
> > I think your site is great Peli, I agree with your reasoning and
> > applaud your efforts.  Unfortunately in this case I'm interested in
> > invoking the Amazon MP3 app, and no one has registered it on
> > OpenIntents, so I was trying to discover anything I could about it.
> >
> > I think it is very strange that Android has this nice concept of apps
> > registering the services that they provide, but there's no means for
> > other apps to discover what services are provided.  Is it just me, or
> > does anyone else think this really limits the usefulness of this
> > feature?
> >
> > -- Peter
> >
>


-- 
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.  All such questions should be posted on public
forums, where I and others can see and answer them.

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



[android-developers] Re: discover intents that an app supports

2009-01-30 Thread Peli

> The strangeness is not just limited to the lack of a discovery API.

What I'm trying to say is, even if they were discovery APIs they would
be of limited use, because they could never tell you which extras you
have to use, what they mean, and how to interpret the result.

The only thing that can help you is better documentation.

> There's also a peculiar lack of documentation on what the built-in
> apps can do, leaving us wasting a lot of time poking about making up
> intents by experiment.

For built-in apps, you can always look into the source code to see
what their intents expect:
http://android.git.kernel.org/
(see platform/packages/...)

For some applications, the developers update their intents themselves
already at OpenIntents.org and document them over there. See e.g.
http://www.openintents.org/en/node/94

Some intents are frequently asked for, so that we have small code
snippets:
http://www.openintents.org/en/node/121

If you use undocumented intents by closed source applications that the
developer did not publish information about, chances are the developer
may change the intents anytime, so your application could break if you
use their intents...

Is there a specific application you would like to know more
information about?

Peli
www.openintents.org

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



[android-developers] Re: Need help in running the android junit test case for andriod APIDemo in eclipse

2009-01-30 Thread ying lcs

Thank you.  Xavier,

Can you please tell me if this will run other vanilla junit test
cases? The ones just inherit from Junit framework, not the ones which
are sub-classed from Google TestCase classes?

Thank you.

On Thu, Jan 29, 2009 at 6:31 PM, Xavier Ducrohet  wrote:
>
> Using the "new android project" wizard, you can create a project from
> existing source.
> This is probably what you used to create a project for ApiDemos. Just
> use it again for the tests project (point the wizard to
> /samples/ApiDemos/tests).
>
> The compilation problem is because the tests project doesn't know the
> ApiDemos classes until you tell it where they are.
> Right click the tests project in the package Explorer and choose Build
> Path > Configure Build Path.
> In the "Projects" tab, click Add and choose your ApiDemos project.
>
> Because deployment of instrumentation projects is not supported in ADT
> you will have install ApiDemos and your test project manually.
>
> We do intend to improve this workflow in the future.
>
> Xav
>
> On Thu, Jan 29, 2009 at 6:25 PM, ying lcs  wrote:
>>
>> On Thu, Jan 29, 2009 at 6:12 PM, Xavier Ducrohet  wrote:
>>>
>>> You will never really be able to just use the default Run as JUnit test 
>>> action.
>>>
>>> This is because this setups up the tests to run using the system
>>> library of the project which, for Android project, is android.jar.
>>> android.jar in the SDK is only stubbed methods/classes, and contains no 
>>> code.
>>>
>>> You can run unit tests by setting up Eclipse using the follow
>>> instructions: 
>>> http://code.google.com/android/kb/troubleshooting.html#addjunit
>>>
>>> Note that this will only work for tests not using the Android APIs.
>>>
>> Thanks. But most likely most of my classes will use android APIs, so
>> using this to unit-test is not that common, right?
>> Or I am mis-understanding the condition.
>> I would like to have 1 way to unit-test my android code.
>>
>>
>>> If you wish to run true android test, please use instrumentations
>>> running on the device.
>>> See 
>>> http://code.google.com/android/reference/android/test/InstrumentationTestRunner.html
>>> for more information.
>>>
>>
>>
>>
>>> The information from Diego to setup the test runners for ApiDemos is
>>> good, except that you don't need to create a new project and copy
>>> things over, you can simply create a project for the existing source
>>> (you will need to link the apidemos project in your build path).
>>>
>>
>> Thank you. I have followed Diego instructions, and I finally get that to 
>> work.
>> But you mention that there a way not to create a new project.
>> Can you please tell me how to do that?
>>
>> I have create an 'apidemos' project in eclipse, but the 'tests'
>> directory is not in the build path. Hence they are not compile.
>>
>> So what should I do to run the code 'tests' code without creating a
>> new project like Diego described.
>>
>> Thank you for any tips.
>>
>>
>>> Xav
>>>
>>> On Thu, Jan 29, 2009 at 5:44 PM, ying...@gmail.com  
>>> wrote:

 Thanks. But can you please tell me if it is possible to
 * run junit test within eclipse using the 'Debug->Run as Junit Test'?
 * run junit test as part of the ant script? (i.e. automatically via
 command line)

 Thank you.


 On Jan 29, 3:08 pm, Diego Torres Milano  wrote:
> This may help 
> youhttp://dtmilano.blogspot.com/2008/11/android-testing-on-android-platf...
>
> On Jan 29, 1:55 am, "ying...@gmail.com"  wrote:
>
> > Hi,
>
> > I am trying to run Junit test case for the android APIDemo project
> > under eclipse.
>
> > I create an eclipse project from the APIDemo source, it compiles fine
> > and then I did:
> > 1. Debug->Run as Junit tests
>
> > But I get this error:
> > 'Lanuching AllTests' has encountered a problem.
> > Cannot connect to VM.
>
> > And I find this in the .log file in eclipse:
> > !ENTRY org.eclipse.core.net 1 0 2009-01-28 15:03:52.799
> > !MESSAGE System property http.nonProxyHosts has been set to
> > local|*.local|169.25
> > 4/16|*.169.254/16 by an external source. This value will be
> > overwritten
> > using th
> > e values from the preferences
>
> > !ENTRY org.eclipse.jdt.launching 4 120 2009-01-28 15:04:03.269
> > !MESSAGE Cannot connect to VM
> > !STACK 0
> > java.net.SocketException: Socket closed
> > at java.net.PlainSocketImpl.socketAccept(Native Method)
> > at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:384)
> > at java.net.ServerSocket.implAccept(ServerSocket.java:450)
> > at java.net.ServerSocket.accept(ServerSocket.java:421)
> > at
> > org.eclipse.jdi.internal.connect.SocketTransportService.accept(Socket
> > TransportService.java:95)
> > at
> > org.eclipse.jdi.internal.connect.SocketTransportImpl.accept(SocketTra
> > nsportImpl.java:56)
> >   

[android-developers] Re: what's the "Media Button"?

2009-01-30 Thread Marco Nelissen
And in Cupcake it's also used for the buttons on bluetooth a2dp/avrcp
devices.


On Fri, Jan 30, 2009 at 12:02 PM, Zach Hobbs  wrote:

>
> It's the button on the headset included with the G1.
>
> Thanks,
> Zach
>
>
> On Friday 30 January 2009 12:39:37 pm Peter Jeffe wrote:
> > Documentation for Intent.ACTION_MEDIA_BUTTON says "Broadcast Action:
> > The "Media Button" was pressed."  Anyone know exactly what the media
> > button is?  Is it intended for devices that have a dedicated hard
> > media button, and therefore non-functional on the G1, or is it
> > something else?  Thanks.
> >
> > -- Peter
> >
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] local service getting killed

2009-01-30 Thread brs

I have an app loosely based on the LocalService example from the SDK
with a controller activity and a long-running, stateful service which
is doing stuff on a periodic handler. The service is also a bit of a
memory hog.

It seems that the service is sometimes killed by the activity-manager
and immediately restarted. I don't see any stack trace, so I assume it
is not the application crashing but the system doing that, presumably
to claim resources. Is that what is going on here?

Is there a way to tell the system that this process is kind of
important, even though it has no foreground activity and should only
be killed as a last resort?

Bernhard
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Error reading jdwp list: null

2009-01-30 Thread Xavier Ducrohet

This is not related to your application code.

This means that DDMS lost contact with the emulator or device.
If you do 'adb devices', you probably won't see your device in the list.

Xav

On Fri, Jan 30, 2009 at 5:19 AM, mrinal.expl...@gmail.com
 wrote:
>
> I have created an Android project which was working fine but suddenly
> some problem has occured..whenever i m debugging the
> project it is showing the following error message in the DDMS
> console...
>
> [2009-01-30 17:36:28 - DeviceMonitor]Error reading jdwp list: EOF
> [2009-01-30 18:38:27 - DeviceMonitor]Error reading jdwp list: null
>
> I m working on Eclipse 3.4 Ganymede.basically what i m trying
> to do is read a file from the sdcard's file system and parse this into
> a buffer.
>
> All suggestions are welcome..
>
> Thnx in advance..
>
>
> >
>

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



[android-developers] Re: what's the "Media Button"?

2009-01-30 Thread Zach Hobbs

It's the button on the headset included with the G1.

Thanks,
Zach


On Friday 30 January 2009 12:39:37 pm Peter Jeffe wrote:
> Documentation for Intent.ACTION_MEDIA_BUTTON says "Broadcast Action:
> The "Media Button" was pressed."  Anyone know exactly what the media
> button is?  Is it intended for devices that have a dedicated hard
> media button, and therefore non-functional on the G1, or is it
> something else?  Thanks.
>
> -- Peter
> 

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: discover intents that an app supports

2009-01-30 Thread jarkman

Peter - I agree completely. OpenIntents is a great idea, but it
doesn't fix my problem either.

The strangeness is not just limited to the lack of a discovery API.
There's also a peculiar lack of documentation on what the built-in
apps can do, leaving us wasting a lot of time poking about making up
intents by experiment.

My hope is that both of these - intent discovery APIs and better docs
on the existing intents - are in the plan, just not done yet.

Richard


On Jan 30, 5:29 pm, Peter Jeffe  wrote:
> On Jan 30, 10:45 am, Peli  wrote:
>
> > For this reason, we have created the OpenIntents intents 
> > registry:http://www.openintents.org/en/http://www.openintents.org/en/intentstable
>
> > Even if there is a way to find all intents supported by an
> > application, this will not tell you what kind of extras are supported
> > or required or which result (if at all) is returned.
>
> I think your site is great Peli, I agree with your reasoning and
> applaud your efforts.  Unfortunately in this case I'm interested in
> invoking the Amazon MP3 app, and no one has registered it on
> OpenIntents, so I was trying to discover anything I could about it.
>
> I think it is very strange that Android has this nice concept of apps
> registering the services that they provide, but there's no means for
> other apps to discover what services are provided.  Is it just me, or
> does anyone else think this really limits the usefulness of this
> feature?
>
> -- Peter
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: (simple?) problem with table layout

2009-01-30 Thread Sundog

Oops, I mean vertical alignment. Other layouts like relative would
work too I would think.

On Jan 30, 12:38 pm, Sundog  wrote:
> You might try using a couple of separate one-row tables within a
> LinearLayout set for horizontal alignment..
>
> On Jan 30, 11:46 am, James Yum  wrote:
>
>
>
> > Hi,
>
> > Unfortunately, row spanning is not supported. You may be able to come
> > up with a workaround, such as using vertical linear layouts for the
> > first three columns in the first row (the last column would be the
> > tall button).
>
> > Cheers,
> > James
>
> > On Fri, Jan 30, 2009 at 6:31 AM, madcoder  wrote:
>
> > > I want to create a table layout so I don't have to use absolute
> > > values.
>
> > > I have 2 's in my , and each row has 4 buttons,
> > > all the same width.
>
> > > The problem I'm having is with the last button on the first row.  the
> > > button is as tall as two buttons combined.  I can make a button span 2
> > > columns (width), but how do I make it span two rows and not move the
> > > second row down?
>
> > > e.g., What I would like (please excuse my poor ASCII art)
>
> > > +++  +++  +++  +++
> > > +=+  +=+  +=+  +=+
> > > +++  +++  +++  +=+
> > >                        +=+
> > > +++  +++  +++  +=+
> > > +=+  +=+  +=+  +=+
> > > +++  +++  +++  +=+
>
> > > What I'm getting:
>
> > > +++  +++  +++  +++
> > > +=+  +=+  +=+  +=+
> > > +++  +++  +++  +=+
> > >                        +=+
> > >                        +=+
> > >                        +=+
> > >                        +++
> > > +++  +++  +++
> > > +=+  +=+  +=+
> > > +++  +++  +++
>
> > > Any advice on how to do this properly?!
>
> > > Thanks- Hide quoted text -
>
> > - Show quoted text -- 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] Re: (simple?) problem with table layout

2009-01-30 Thread Sundog

You might try using a couple of separate one-row tables within a
LinearLayout set for horizontal alignment..

On Jan 30, 11:46 am, James Yum  wrote:
> Hi,
>
> Unfortunately, row spanning is not supported. You may be able to come
> up with a workaround, such as using vertical linear layouts for the
> first three columns in the first row (the last column would be the
> tall button).
>
> Cheers,
> James
>
>
>
> On Fri, Jan 30, 2009 at 6:31 AM, madcoder  wrote:
>
> > I want to create a table layout so I don't have to use absolute
> > values.
>
> > I have 2 's in my , and each row has 4 buttons,
> > all the same width.
>
> > The problem I'm having is with the last button on the first row.  the
> > button is as tall as two buttons combined.  I can make a button span 2
> > columns (width), but how do I make it span two rows and not move the
> > second row down?
>
> > e.g., What I would like (please excuse my poor ASCII art)
>
> > +++  +++  +++  +++
> > +=+  +=+  +=+  +=+
> > +++  +++  +++  +=+
> >                        +=+
> > +++  +++  +++  +=+
> > +=+  +=+  +=+  +=+
> > +++  +++  +++  +=+
>
> > What I'm getting:
>
> > +++  +++  +++  +++
> > +=+  +=+  +=+  +=+
> > +++  +++  +++  +=+
> >                        +=+
> >                        +=+
> >                        +=+
> >                        +++
> > +++  +++  +++
> > +=+  +=+  +=+
> > +++  +++  +++
>
> > Any advice on how to do this properly?!
>
> > Thanks- 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] Re: String Resource - name "continue"

2009-01-30 Thread Romain Guy

continue is a Java keyword and thus cannot be used to name resources.
Otherwise the compiler would complain about the generated R.java file.

On Fri, Jan 30, 2009 at 11:34 AM, Nmix  wrote:
>
> I created a new string in the resource file and got what seems to be
> an odd error.  The name of the string was "continue".  The error
> reported: ERROR invalid symbol: 'continue'
>
> Changing the name by even one character solved the problem so it's
> nothing serious.  My question: is there some set of names we must not
> use as resource identifiers?
>
> Thanks.
> >
>



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

Note: please don't send private questions to me, as I don't have time
to provide private support.  All such questions should be posted on
public forums, where I and others can see and answer them

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



[android-developers] Re: ListView with the CheckBoxPreference look

2009-01-30 Thread James Yum

Hi Dan,

android.R.layout.simple_list_item_multiple_choice and
android.R.layout.simple_list_item_1 actually refer to built-in android
layouts, so for example:

http://android.git.kernel.org/?p=platform/frameworks/base.git;a=blob;f=core/res/res/layout/simple_list_item_multiple_choice.xml

Note that for this particular layout, there is only a "text1".

I think what you want to do, is define your own layout under
"res/layout". You could base it off of preference.xml:

http://android.git.kernel.org/?p=platform/frameworks/base.git;a=blob;f=core/res/res/layout/preference.xml

You'll have to modify it to include a checkbox inside widget_frame.
Also the ids would be android.R.id.title and android.R.id.summary.

Cheers,
James

On Fri, Jan 30, 2009 at 3:31 AM, Dan Dromereschi
 wrote:
>
> Hi James,
>
> Sure, the code snippet is below:
>
>mList.setItemsCanFocus(false);
>mList.setChoiceMode(ListView.CHOICE_MODE_MULTIPLE);
>mListAdapter = new SimpleAdapter(this, mListValues,
> android.R.layout.simple_list_item_multiple_choice,
>new String[] {"name", "desc"}, new int[] {android.R.id.text1,
> android.R.id.text2});
>mList.setAdapter(mListAdapter);
>
> Considering text1 as the item text, text2 as the item summary (the
> smaller text below the item text), when running the code above, only
> text1 and the checkbox are displayed.
> If in the code above I replace the resource that currently has the
> android.R.layout.simple_list_item_multiple_choice value with
> android.R.layout.simple_list_item_2, I can see both text1 and text2.
> If I try to "OR" the 3 values:
> android.R.layout.simple_list_item_multiple_choice |
> android.R.layout.simple_list_item_1 |
> android.R.layout.simple_list_item_2, as I was used to when writing SWT
> based applications, nothing is displayed.
>
> So, I am not sure how to make all the 3 things displaying.
>
> Thanks,
>
> Dan
>
>
> On Jan 29, 8:17 pm, James Yum  wrote:
>> Hi Dan,
>> Can you post some code?
>>
>> Cheers,
>> James
>>
>> On Thu, Jan 29, 2009 at 6:31 AM, Dan Dromereschi
>> wrote:
>>
>>
>>
>> > Hello,
>>
>> > I am trying to build a ListView that contains items that look exactly
>> > like the CheckBoxPreference, an android.R.id.text1, an
>> > android.R.id.text2 and a checkbox.
>>
>> > I am using a SimpleAdapter and I manage to either have only text1 and
>> > the checkbox, or text1 and text2, but never all the 3 of them. Is
>> > there something I am missing?
>>
>> > Thanks,
>>
>> > Dan
>>
>>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] String Resource - name "continue"

2009-01-30 Thread Nmix

I created a new string in the resource file and got what seems to be
an odd error.  The name of the string was "continue".  The error
reported: ERROR invalid symbol: 'continue'

Changing the name by even one character solved the problem so it's
nothing serious.  My question: is there some set of names we must not
use as resource identifiers?

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



[android-developers] eclipse warnings and aidl generated classes

2009-01-30 Thread jason...@spy.net


Does anyone know of a way to suppress the eclipse warnings from
classes generated by aidl?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: (simple?) problem with table layout

2009-01-30 Thread James Yum

Hi,

Unfortunately, row spanning is not supported. You may be able to come
up with a workaround, such as using vertical linear layouts for the
first three columns in the first row (the last column would be the
tall button).

Cheers,
James

On Fri, Jan 30, 2009 at 6:31 AM, madcoder  wrote:
>
> I want to create a table layout so I don't have to use absolute
> values.
>
> I have 2 's in my , and each row has 4 buttons,
> all the same width.
>
> The problem I'm having is with the last button on the first row.  the
> button is as tall as two buttons combined.  I can make a button span 2
> columns (width), but how do I make it span two rows and not move the
> second row down?
>
> e.g., What I would like (please excuse my poor ASCII art)
>
> +++  +++  +++  +++
> +=+  +=+  +=+  +=+
> +++  +++  +++  +=+
>+=+
> +++  +++  +++  +=+
> +=+  +=+  +=+  +=+
> +++  +++  +++  +=+
>
> What I'm getting:
>
> +++  +++  +++  +++
> +=+  +=+  +=+  +=+
> +++  +++  +++  +=+
>+=+
>+=+
>+=+
>+++
> +++  +++  +++
> +=+  +=+  +=+
> +++  +++  +++
>
>
> Any advice on how to do this properly?!
>
> Thanks
>
> >
>

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



[android-developers] Re: android.graphics.Camera is stable in SDK 1.0?

2009-01-30 Thread blindfold

Oops, sorry, overlooked the android.graphics versus android.hardware
distinction. BTW, my latest webcam does 3D transformations too
(anaglyph encoding). :-)

On Jan 30, 6:11 pm, plusminus  wrote:
> Hi blindfold,
>
> I am referring to another Camera-Class - not the one for taking
> pictures, but the one capable of doing 3d transformations.
>
> Best Regards,
> plusminus

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] gapless playback

2009-01-30 Thread ph...@grantmidwinter.com

Hoya,

When using a mediaplayer to play back an audio file, you can set
looping to true - that's not the issue here.

If looping is set to true, there's still an audible gap between the
file finishing and then starting again.

How could I achieve true gapless playback? I've attempted using two
instances of the same file, overriding oncomplete and onseek.. can't
seem to improve the gap though. Any help appreciated.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Activity Title font

2009-01-30 Thread AusR

Thanks guys!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Debugging live processes?

2009-01-30 Thread Charlie Collins

Check out the adb shell tool, it has a ton of stuff:

http://code.google.com/android/reference/adb.html#shellcommands
http://en.androidwiki.com/wiki/ADB_Shell_Command_Reference

For instance, try "adb shell dumpsys activity" - and so on, see what's
there with "debugtool" and such too.

On Jan 30, 10:58 am, dpackham  wrote:
> is there any way to debug live running apps to see what processes are
> taking alot of cpu time?  I see the options in DDMS but they are not
> really live.  I would just like to see what processes took alot of
> time so I can dig into the code to optimize it
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Dialing Permission

2009-01-30 Thread Charlie Collins

I don't think you need any permission to initial a phone call using
the built in Activity. As long as you go through the built in activity
and included user interface, no perms required.
The CALL_PHONE permission is for making a call on your own without
using the built in Activity, as I understand it (if you want to write
your own dialer, or otherwise not go through the built in dialer).

(And the built in Activity probably HAS the CALL_PHONE permission, so
it's not your app that needs the permission if you are handing off,
etc.)

On Jan 30, 7:07 am, Sohail  wrote:
> Hi,
>
> I just created a simple application, that starts the Dial Activity and
> place a call. I did not provide any permission in the manifest file to
> start a call, but still the call activity starts.
>
> I also checked the AndroidManifest.xml file, there is no permission
> added, still the activity starts.
>
> can anyone explain, why this is so.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: what is maximum height and width of image which can display?

2009-01-30 Thread Dianne Hackborn
It's not, it's for the whole process.

The 16MB limit isn't a hard-coded fixed limit.  It is a limit that makes
sense on the G1 given its available memory and the resources apps need.  You
can assume this will be larger on devices with more memory and more
expensive resources like larger screens, higher resolution camers, etc.

On Fri, Jan 30, 2009 at 3:57 AM, Marco Schmitz <
netzprofi.ma...@googlemail.com> wrote:

>
> I think 16MB is max for one activity...
>
> greetings,
> darolla
>
> 2009/1/29 jj :
> >
> > what is maximum height and width of image which can display?
> >
> > When I try for 1000px height and 1000pix width it work, but for beyond
> > it,
> > it gives exception, appl force close.
> > >
> >
>
> >
>


-- 
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.  All such questions should be posted on public
forums, where I and others can see and answer them.

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



[android-developers] Re: migrate android to hardware

2009-01-30 Thread Pierre Bonnefoy
Hi,
My two cents :
- use the correct group, android-porting, which is full of discussions like
this one.
- you can also have a look at sites like http://elinux.org/Android_on_OMAP

But if you look at the discussions on android-porting, you will find loads
of ressources, informations and people already trying to achieve what you
are asking for ;-).

Regards,

Pierre

2009/1/30 jacky 

> Hi all:
>
>I'am going to migrate android to OMAP2430. how could I get start?
>Is there any migration step I can follow ? Is that possible to share
> some resource with me?
>Thanks
> >
>

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



[android-developers] Generate a white noise mp3 file

2009-01-30 Thread ph...@grantmidwinter.com

Ho,

I'm trying to write an array of random bytes to a file, specifically
to generate white noise.

I'm having some trouble though finding how to get a FileOutputStream
written... does anyone have any idea how I can output my bytearray?

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Dialing Permission

2009-01-30 Thread Dianne Hackborn
You don't need a permission to start the dialer.  That requires the user to
be involved in placing the call, so it wouldn't be useful to have a
permission on it.

On Fri, Jan 30, 2009 at 4:07 AM, Sohail wrote:

>
> Hi,
>
> I just created a simple application, that starts the Dial Activity and
> place a call. I did not provide any permission in the manifest file to
> start a call, but still the call activity starts.
>
> I also checked the AndroidManifest.xml file, there is no permission
> added, still the activity starts.
>
> can anyone explain, why this is so.
>
>
> >
>


-- 
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.  All such questions should be posted on public
forums, where I and others can see and answer them.

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



[android-developers] Re: performCompletion on AutoCompleteTextView

2009-01-30 Thread Romain Guy

This will all be fixed in cupcake. But why do you need to call
performCompletion() yourself? There is no reason to do so.

On Fri, Jan 30, 2009 at 3:43 AM, oliver  wrote:
>
> hi,
> i'm having a problem when using the performCompletion method on an
> AutoCompleteTextView.
> when i start typing the suggestions work fine (an entry is
> highlighted). as soon as i type enough characters so that no match is
> possible anymore, the suggestion list disappears (which is ok).
> when i know delete some characters so the suggestion list appears
> again nothing will be selected (even though it will still narrow down
> it's hits the more characters i type again)
> now the problem:  in an onKey listener i check if the suggestions are
> showing (isPopupShowing) and if so i try to call performCompletion.
> now the AutoCompleteListener finds out that nothing is selected and
> replaces my content with "".
>
> does anybody know of a way
> - how to re-enable the selection on the suggestion list ?
> - or how to find out if anything is selected at all? in that case i
> would not call the performCompletion method
>
> thnx!
>
> >
>



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

Note: please don't send private questions to me, as I don't have time
to provide private support.  All such questions should be posted on
public forums, where I and others can see and answer them

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



[android-developers] Error reading jdwp list: null

2009-01-30 Thread mrinal.expl...@gmail.com

I have created an Android project which was working fine but suddenly
some problem has occured..whenever i m debugging the
project it is showing the following error message in the DDMS
console...

[2009-01-30 17:36:28 - DeviceMonitor]Error reading jdwp list: EOF
[2009-01-30 18:38:27 - DeviceMonitor]Error reading jdwp list: null

I m working on Eclipse 3.4 Ganymede.basically what i m trying
to do is read a file from the sdcard's file system and parse this into
a buffer.

All suggestions are welcome..

Thnx in advance..


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



[android-developers] Re: Activity Title font

2009-01-30 Thread DaRolla

http://code.google.com/p/android-titlebar/

On 30 Jan., 11:42, AusR  wrote:
> Anyone know what the default Activity Title font size/style is?
>
> I'm creating a custom title but would like to match the other
> Activities.
>
> Thanks.

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



[android-developers] Re: Pre populating emulator with sms message

2009-01-30 Thread PR S
You might try saving them as draft and see if thats ok.



On Thu, Jan 29, 2009 at 9:31 PM, reyjexter  wrote:

>
> Hi,
>
> I'm developing an application that makes use of sms. How can I pre
> populate the emulator when it starts so I can try reading its content?
>
>
> -rey
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Dialing Permission

2009-01-30 Thread Sohail

Hi,

I just created a simple application, that starts the Dial Activity and
place a call. I did not provide any permission in the manifest file to
start a call, but still the call activity starts.

I also checked the AndroidManifest.xml file, there is no permission
added, still the activity starts.

can anyone explain, why this is so.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: ListView with the CheckBoxPreference look

2009-01-30 Thread Marco Schmitz

maybe this helps you:
http://www.jsharkey.org/blog/2008/08/18/separating-lists-with-headers-in-android-09/

greetings,
darolla

2009/1/29 Dan Dromereschi :
>
> Hello,
>
> I am trying to build a ListView that contains items that look exactly
> like the CheckBoxPreference, an android.R.id.text1, an
> android.R.id.text2 and a checkbox.
>
> I am using a SimpleAdapter and I manage to either have only text1 and
> the checkbox, or text1 and text2, but never all the 3 of them. Is
> there something I am missing?
>
> Thanks,
>
> Dan
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: what is maximum height and width of image which can display?

2009-01-30 Thread Marco Schmitz

I think 16MB is max for one activity...

greetings,
darolla

2009/1/29 jj :
>
> what is maximum height and width of image which can display?
>
> When I try for 1000px height and 1000pix width it work, but for beyond
> it,
> it gives exception, appl force close.
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Anybody having trouble accessing https://dl-ssl.google.com/android/eclipse/ - ie the eclipse / android integration plugin ?

2009-01-30 Thread Marco Schmitz

using http without s works for me fine inside eclipse...

greetings,
darolla

2009/1/30 blindfold :
>
> http://code.google.com/intl/ru/android/adt_download.html
>
> On Jan 30, 9:57 am, Richard Green  wrote:
>> I can't seem to get anything back 
>> fromhttps://dl-ssl.google.com/android/eclipse/
>> - even accessing from a browser just gives a 404.
>>
>> Is it just me ?!?!
> >
>

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



[android-developers] Re: The adb tool of emulator

2009-01-30 Thread Daniel Drigo Pastore

Hi there!

I just wanted to use this thread, since the subject is the same:
is there anyone there who knows how to access the shell with a shell
user? Let me try to be more especific: when i access adb on the
emulator i have root access and i wanted to have shell-user access to
know how would my app behave when accessed from a device... does it
make sense to anyone out there? hehehe...

Thanks a lot!

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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 use proxy server on the g1?

2009-01-30 Thread joff

Anyone figured this one out yet?

On Jan 24, 9:38 pm, DJMoran  wrote:
> I also need the exact same help, my school uses a proxy server to
> access the web.
>
> Also my home wireless doesn't need a proxy to access the web.
>
> I know the iPhone and iPod touch can use multiple proxy settings
> depending on the network it is connected to but what about the G1
>
> On Jan 10, 1:52 pm, "kevkev...@googlemail.com"
>
>  wrote:
> > Does anyone know how to connect to the internet via a proxy server on
> > a g1 handset? I need to use a proxy server at school to get on the
> > internet on wifi.
>
> > 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 at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Repo Client init problem ubuntu 8.10

2009-01-30 Thread Bernhard

Same Problem here:
i flowed the instrcutions at: 
http://docs.google.com/View?docid=ajdmx8kfg357_81cmpr56f6
VMware with Ubuntu 8.10
---
m...@desktop:~/eee$ repo init -u 
git://android.git.kernel.org/platform/manifest.git
Traceback (most recent call last):
  File "/bin/repo", line 590, in 
main(sys.argv[1:])
  File "/bin/repo", line 557, in main
_Init(args)
  File "/bin/repo", line 176, in _Init
_CheckGitVersion()
  File "/bin/repo", line 205, in _CheckGitVersion
proc = subprocess.Popen(cmd, stdout=subprocess.PIPE)
  File "/usr/lib/python2.5/subprocess.py", line 594, in __init__
errread, errwrite)
  File "/usr/lib/python2.5/subprocess.py", line 1153, in
_execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
---

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] performCompletion on AutoCompleteTextView

2009-01-30 Thread oliver

hi,
i'm having a problem when using the performCompletion method on an
AutoCompleteTextView.
when i start typing the suggestions work fine (an entry is
highlighted). as soon as i type enough characters so that no match is
possible anymore, the suggestion list disappears (which is ok).
when i know delete some characters so the suggestion list appears
again nothing will be selected (even though it will still narrow down
it's hits the more characters i type again)
now the problem:  in an onKey listener i check if the suggestions are
showing (isPopupShowing) and if so i try to call performCompletion.
now the AutoCompleteListener finds out that nothing is selected and
replaces my content with "".

does anybody know of a way
- how to re-enable the selection on the suggestion list ?
- or how to find out if anything is selected at all? in that case i
would not call the performCompletion method

thnx!

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: Activity Title font

2009-01-30 Thread DaRolla

hi,

just take a look at
android\android-sdk-windows-1.0_r2\tools\lib\res\default\values
styles.xml and themes.xml

greetings,
darolla

On 30 Jan., 11:42, AusR  wrote:
> Anyone know what the default Activity Title font size/style is?
>
> I'm creating a custom title but would like to match the other
> Activities.
>
> Thanks.

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



[android-developers] Re: Running more than one .apk in the same process?

2009-01-30 Thread Marco Schmitz

and how can you startup both .apks ?

greetings,
darolla

2009/1/30 Dianne Hackborn :
> The two .apks must be signed with the same certificate, use
> android:sharedUserId in their manifest to be assigned the same uid, and then
> can use android:process to specify the same name of the process to run in.
>
> On Thu, Jan 29, 2009 at 9:33 PM, mongd  wrote:
>>
>> According to the docs in the Android developer's site, processes can
>> be used to reduce overhead by running the code of multiple .apks in
>> the same process. (see application model)
>> What I'm wondering is HOW I can run multiple .apk in the same process.
>>
>> Since an image from one of the Google I/O video shows that process can
>> run one .apk or just part of one .apk, I'm little confused about
>> processes.
>>
>> Thank you!
>>
>
>
>
> --
> 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.  All such questions should be posted on public
> forums, where I and others can see and answer them.
>
>
> >
>

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



[android-developers] Re: Activity Title font

2009-01-30 Thread Marco Schmitz

hi,

just take a look at
android\android-sdk-windows-1.0_r2\tools\lib\res\default\values
styles.xml and themes.xml

greetings,
darolla

2009/1/30 AusR :
>
> Anyone know what the default Activity Title font size/style is?
>
> I'm creating a custom title but would like to match the other
> Activities.
>
> Thanks.
> >
>

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



[android-developers] migrate android to hardware

2009-01-30 Thread jacky
Hi all:
 
I'am going to migrate android to OMAP2430. how could I get start?
Is there any migration step I can follow ? Is that possible to share some 
resource with me?
Thanks
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~--~~~~--~~--~--~---



[android-developers] Re: Activity Title font

2009-01-30 Thread DaRolla

hi,

just take a look at
android\android-sdk-windows-1.0_r2\tools\lib\res\default\values
styles.xml and themes.xml

greetings,
darolla


On Jan 30, 11:42 am, AusR  wrote:
> Anyone know what the default Activity Title font size/style is?
>
> I'm creating a custom title but would like to match the other
> Activities.
>
> Thanks.

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



[android-developers] Re: Add new contacts directly in "My Contacts".

2009-01-30 Thread Rishi

Hi,

You can use People.addToMyContactsGroup to add a particular contact
you want to be visible in the "My Contacts".
e.g.,
People.addToMyContactsGroup(getContentResolver(), 16);
where 16 is the _id of the contact to be visible .

Regards,
Rishi Kaura

On Jan 29, 2:45 pm, DarkJJ  wrote:
> Hi all.
>
> I want to create anewcontactin the group "My Contacts", with name
> and number phone like data.
>
> I only have seen this example that how must i do 
> this:http://code.google.com/intl/es-ES/android/devel/data/contentproviders...
>
> But in this example, thenewcontacts are added in the list
> "Favorites" and i dont like this to my app. If i change the value of
> SCARRED thecontactis or not is in this list.
>
> ¿How can iaddnewcontacts directly in "My Contacts" ?...  i have
> looked for information about this but i didnt find nothing to do , ¿is
> posible this function?
>
> Thanks.

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



[android-developers] Hi

2009-01-30 Thread pavojan

Help me!!:)

After pushing numerous pictures onto an SD card image, I'm having
trouble displaying them in a grid-like view.  I am trying to use
android.provider.MediaStore.Images.Thumbnails to access image
thumbnails, but I can't find a way to generate thumbnails and populate
the thumbnails table.
How do I create thumbnails?

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] help please

2009-01-30 Thread Arnauld NDEFO


Hello, I am a young student from cameroon.J like to be part of this
groupe.I am currently developing an application on android and I would
like your help because I have many problem.I want to receive the
coordinate GPS with android ( r on the emulator). First, I have not a
provide but I use the DDMS to generate coordinate.but I can not
receive GPS coordinates provided by the DDMS.This my code

package android.phonedial;

import java.util.List;
import android.app.Activity;
import android.content.Context;
import android.location.Criteria;
import android.location.Location;
import android.location.LocationManager;
import android.location.LocationListener;
import android.location.LocationProvider;
import android.os.Bundle;
import android.widget.TextView;


public class TestProviderController extends Activity {

public  LocationManager locationManager;
public LocationListener locationlistener;
@Override
public void onCreate(Bundle tracabilite) {
super.onCreate(tracabilite);
setContentView(R.layout.main);

String location_context = Context.LOCATION_SERVICE;
locationManager = (LocationManager)getSystemService
(location_context);

testProviders();

}
public void testProviders() {

TextView tv = (TextView)findViewById(R.id.myTextView);
StringBuilder sb = new StringBuilder("Enabled Providers:");
List providers = locationManager.getProviders(true);


for (String provider : providers) {
locationManager.requestLocationUpdates(provider, 1000, 0,
new LocationListener() {
public void onLocationChanged(Location location) {}
public void onProviderDisabled(String provider){}
public void onProviderEnabled(String provider){}
public void onStatusChanged(String provider, int status,
Bundle extras){}
});

 sb.append("\n").append(provider).append(": ");

Location location = 
locationManager.getLastKnownLocation(provider);



if  (location != null)
{
 double lat = location.getLatitude();
 double lng = location.getLongitude();
sb.append(lat).append(", ").append(lng);
} else {
 sb.append("No Location");

}
}
tv.setText(sb);
}
}

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



[android-developers] android-titlebar (iphone like backbutton)

2009-01-30 Thread DaRolla

hi,

I managed to customize the titlebar and add an iphone like backbutton.

http://code.google.com/p/android-titlebar/

greetings,
darolla

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



[android-developers] Android HAL library

2009-01-30 Thread ganesh

Sir, I am porting Android on freescale board ( IMX31)
I want to know that the HAL layer in the android framework is Hardware
dependent / OS dependent  or not.
if possible can you elaborate about this layer.
I hope you will reply soon

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Device not showing in DDMS preference

2009-01-30 Thread erikgfields

I'm trying to grab some screenshots off my G1 and I cannot get the
device to appear in the "Devices" panel while in DDMS mode in Eclipse.
I've tried a million things and can't get it to work. Does anyone know
a quick trick that will allow me to see my device?

This is what I've tried to do:
Open Eclipse  >  Window  >  Open Perspective  >  Other  >  DDMS
Devices panel opens, emulator displays. I want to select the "Screen
Capture" option.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Debugging live processes?

2009-01-30 Thread dpackham

is there any way to debug live running apps to see what processes are
taking alot of cpu time?  I see the options in DDMS but they are not
really live.  I would just like to see what processes took alot of
time so I can dig into the code to optimize it

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



[android-developers] performCompletion on AutoCompleteTextView

2009-01-30 Thread oliver

hi,
i'm having a problem when using the performCompletion method on an
AutoCompleteTextView.
when i start typing the suggestions work fine (an entry is
highlighted). as soon as i type enough characters so that no match is
possible anymore, the suggestion list disappears (which is ok).
when i know delete some characters so the suggestion list appears
again nothing will be selected (even though it will still narrow down
it's hits the more characters i type again)
now the problem:  in an onKey listener i check if the suggestions are
showing (isPopupShowing) and if so i try to call performCompletion.
now the AutoCompleteListener finds out that nothing is selected and
replaces my content with "".

does anybody know of a way
- how to re-enable the selection on the suggestion list ?
- or how to find out if anything is selected at all? in that case i
would not call the performCompletion method

thnx!

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Bill Settlement?

2009-01-30 Thread ivan

I'm a hobbiest wondering how Bill Settlement will work once Android
paid apps are introduced.

Will billing go through the mobile operator, or will a third party of
some sort be used for billing?

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



[android-developers] Re: discover intents that an app supports

2009-01-30 Thread Peli

You could leave logcat running while you launch Amazon MP3 in various
ways. This will tell you at least the action you need to use, and
probably something about the data and the mime type (if used).

If the intent has extras then you are out of luck (unless you guess
well). Extras are not specified in the Manifest, but they are only
handled by the application, so the system *truly* does not know about
them.

If you don't want to reverse-engineer the apk, the only possibility is
to contact the application directly to ask for the specification of
the intents used.

(and if you have found them, please add them to the intents
registry ;-) )

OK, actually, as I write about it, there may be a way to find out more
about the intents without reverse engineering the apk:
1) Find the action (and if used mime type) using logcat.
2) Write an intent filter for that action in a test application.
3) Wait for the action to be fired, the activity chooser to pop up,
and choose your test application.
4) Read the intent extras in your test application :-)

Peli

On Jan 30, 6:29 pm, Peter Jeffe  wrote:
> On Jan 30, 10:45 am, Peli  wrote:
>
> > For this reason, we have created the OpenIntents intents 
> > registry:http://www.openintents.org/en/http://www.openintents.org/en/intentstable
>
> > Even if there is a way to find all intents supported by an
> > application, this will not tell you what kind of extras are supported
> > or required or which result (if at all) is returned.
>
> I think your site is great Peli, I agree with your reasoning and
> applaud your efforts.  Unfortunately in this case I'm interested in
> invoking the Amazon MP3 app, and no one has registered it on
> OpenIntents, so I was trying to discover anything I could about it.
>
> I think it is very strange that Android has this nice concept of apps
> registering the services that they provide, but there's no means for
> other apps to discover what services are provided.  Is it just me, or
> does anyone else think this really limits the usefulness of this
> feature?
>
> -- Peter
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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   >