Re: [android-developers] Re: What is the name of this widget?

2011-01-10 Thread Kostya Vasilyev


I believe the screenshot comes from an HTC device.

If so, then the widget and the application using it are part of HTC 
Sense UI (I'm too lazy to go look at my Hero right now to check). They 
do a lot of custom things in Sense, like scrolling and re-configurable 
widgets.


And while owners of HTC phones would like to see other applications 
looking like Sense, owners of other brands of phones might actually not 
want the HTC look.


Speaking for myself - I now prefer plain Android 2.1 on my Motorola 
Milestone to heavily customized 2.1 on HTC Hero. Looked at an HTC Desire 
HD in a store yesterday, and Sense is even more complex and in-your-face 
there, so I will not be buying that phone just for that reason alone.


( guess I'm more of a "vi" than an "emacs" kind of guy :) )

-- Kostya

10.01.2011 10:07, MerlinBG ?:

Thank you for the help, the proposed widget looks good.

metal mikey, I am interested not in date/time entering, but in a way 
to enter numbers - something like the NumberPicker, which seems to be 
internal, and for the means I need it - the wheel looks cooler.


Having this in mind and since while browsing group I see that 
framework engineers are quite active, I would like to share my first 
impression as complete Android developer newbie - I LOVE the platform 
as a user, however as developer I see some strange things - like 
really useful components staying internal for ages (like 
https://groups.google.com/forum/?fromgroups&pli=1#!searchin/android-developers/numberpicker/android-developers/ZdqYIJmP3ck/SXmDORRPE1QJ 
and several more topics about the NumberPicker), now this wheel thing 
not even in platform, but I see it on my phone?


Keeping widgets public would result in cooler applications, boosting 
the interest to the platform even further. Do not make us 
copy/duplicate everything and reinvent the wheel :)

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



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

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

[android-developers] Re: What is the name of this widget?

2011-01-10 Thread Pent
> That said, the current standard widget pretty much sucks rocks.  We also
> know it sucks rocks, and have desperately wanted to redo it since 1.0.  It
> would be nice to fix that as part of a larger UI overhaul.  Not that I am
> promising anything. :)

If you could also make NumberPicker public during the overhaul that
would be great :-)

Pent

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

2011-01-10 Thread mort
I think if you're feeling masochistic, you could create 9 images and
do some kind of "manual 9-patch image" with e.g. table or linear
layout views. Just like in bad old HTML times... ;)
If your "dynamically created" images aren't too complex, you might
also use something similar to the XML shape drawables. Opposed to 9-
patch drawables, XML drawables always were scaled correctly if I set
them with setImageViewResource. Maybe it works likewise if you create
a Drawable object like GradientDrawable dynamically?

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


Re: [android-developers] Re: RPC service with notification

2011-01-10 Thread Kostya Vasilyev

Jackie,

I already gave you one suggestion, it had to do with 
"AndroidServiceImpl.class".


Here is another:

If inner classes are a new thing to you, don't use one, they can be 
confusing at first.


Make a method in your Service class proper, call it from inside 
AndroidServiceImpl, and then you're back inside your service class, and 
on sample code territory.


Also, using a non-static inner class for the binder (like you are doing) 
causes a memory leak. Here is someone's very nice blog post explaining 
why this happens and what to do about it:


http://www.ozdroid.com/#!BLOG/2010/12/19/How_to_make_a_local_Service_and_bind_to_it_in_Android

-- Kostya

10.01.2011 5:24, Jackie G. пишет:

Thanks so much for taking so much time to try and help me out. Here is
how I create the Notification

private Notification notification;
private static final int NOTIFICATION_ID=1;
protected Context context;
@Override
public IBinder onBind(Intent arg0) {
// TODO Auto-generated method stub
return new AndroidServiceImpl();
}
@Override
public void onCreate(){
super.onCreate();
NotificationManager currentManager = (NotificationManager)
getSystemService(Context.NOTIFICATION_SERVICE);

I think the real problem is with the context in the Impl. Can I even
get an application context from the impl? Should this be passed to the
service from the application? Can it be grabed from AndroidService?

public class AndroidServiceImpl extends IAndroidService.Stub{
public String getAndroidText(String conversation)
throws RemoteException {
// TODO Auto-generated method stub
NotificationManager currentManager = 
(NotificationManager)
getSystemService(Context.NOTIFICATION_SERVICE);

Context context = getApplicationContext();

This is for an open source class I am teaching so I can create a
Google project tomorrow if you still want to help. That way you can
see the whole code.

On Jan 9, 2:39 pm, Kostya Vasilyev  wrote:

How are you creating "notification" ?

09.01.2011 22:33, Jackie G. пишет:




Also double checked and it is hitting the breakpoint.
On Jan 9, 11:35 am, Kostya Vasilyevwrote:

I don't see code in getAndroidText that would initialize "notification".
It should be something like:
notification = new Notification(R.drawable.status_icon, "Hello",
System.currentTimeMillis());
And does getAndroidText really get called? You can verify by setting a
breakpoint.
-- Kostya
09.01.2011 19:03, Jackie G. пишет:

Kostya,
Thanks for the advice I did as you have said and everything compiles.
There is still a problem, however, the notification manager does not
show the updates I am expecting.
Here is my Service Impl
public class AndroidServiceImpl extends IAndroidService.Stub{
   public String getAndroidText(String conversation)
   throws RemoteException {
   // TODO Auto-generated method stub
   NotificationManager currentManager = (NotificationManager)
getSystemService(Context.NOTIFICATION_SERVICE);
   Context context = getApplicationContext();
   CharSequence contentTitle = "Sogeti";
   CharSequence contentText = "This is a message";
   Intent notificationIntent = new
Intent(AndroidService.this, AndroidServiceImpl.class);
   PendingIntent contentIntent =
PendingIntent.getActivity(AndroidService.this, 0, notificationIntent,
0);
   notification.setLatestEventInfo(context, contentTitle,
contentText, contentIntent);
   currentManager.notify(NOTIFICATION_ID, notification);
   return "Android Services are Fun!";
   }
   }
And the parts of the activity that call the service...
@Override
   public void onCreate(Bundle savedInstanceState) {
   super.onCreate(savedInstanceState);
   setContentView(R.layout.main);
   bindService(new
Intent("com.sogeti.walkthrough.service.ANDROID_SERVICE"), serConn,
Context.BIND_AUTO_CREATE);
   serviceBtn = (Button)findViewById(R.id.serviceBtn);
   serviceBtn.setOnClickListener(new OnClickListener() {
   public void onClick(View v) {
   callService();
   }
   });
   }
   private void callService(){
   try{
   String text = androidService.getAndroidText("Test");
   String other = "test";
   }
   catch(NullPointerException npe){
   //TODO: Log Null pointer
   }
   catch(RemoteException rme){
   //TODO: log errors
   }
   }
On Jan 8, 3:05 pm, Kostya Vasilyev  wrote:

Intent(Context context, Class cls)
needs a Context as first parameter, which
AndroidService.AndroidServiceImpl is not :)
I see you have a variable called "context", you

[android-developers] How to monitor android application memory leak? is there tools do it?

2011-01-10 Thread water boiled
I want to find my android application whether has memory leak  . and
some tool help me do i

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


Re: [android-developers] Re: What is the name of this widget?

2011-01-10 Thread MerlinBG
Yes, you are right, it is from HTC Desire.

First thought that Sense adds some kind of skin over the NumberPicker, but 
this seems not to be the case when I duplicated it... or perhaps I miss 
something, I am still newbie with Android.
Well, I guess the general feeling is up to the user, I personally like Sense 
a lot.
However, generic things like the NumberPicker should be public, imo.

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

[android-developers] A Requirement in Browser.

2011-01-10 Thread yogi
Hi All,

I have a requirement like open "http://www.google.com/support/accounts/
bin/answer.py?hl=en&answer=55393&from=48601&rd=1"
in this page there is  "Language Change" option which contains list of
language to choose. As an Dialog Box . My requirement is showing this
dialog as a Activity screen...how to handle this screen...
Thanks in Advance.

Regards
Yogi

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

2011-01-10 Thread mort
I don't know if I get a bit off-topic, but it's still related to
Honeycomb and tablets:
I've seen several apps in the Honeycomb videos which displayed in one
screen what must've been multiple Activities before, like e.g. the
mail list and single mail view.
Will there be an easy way to support multiple visible "Activities", or
is it just hard work to create mightier "Widgets" (e.g. something like
the mail list as Widget instead of ListActivity) and lots of "if that
Widget exists in the current layout ..."?
I think it'd be a good idea to give developers some chance to prepare
for things like that. Properly supporting tablets is more than just
supporting a different screen size, it's often a completely different
UI that must be supported in the same app...
Also, can you give some hints how the future way is planned? Will
there be a Honeycomb for smartphones with a different UI? Will tablet
and smartphone APIs remain compatible? (You know the problem with the
bad long "f" word... ;))

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

2011-01-10 Thread x-a...@gueei.com
This is a one-time post to announce the creation of the Android
Binding Framework, an open source Android Programming library that
helps implementing MVVM Pattern in Android programs, through the
binding of View Model to the XML Layout View file in declarative way.
A first demo app is uploaded to the Android Market, [Search "Android
Binding" in market], which demonstrate the idea of the framework.
Android Binding is under active development, testers and contributors
are welcome to join.

Home page: https://code.google.com/p/android-binding/  (may move to a
separate homepage later)

Features:
- Binding to models through XML declaration
- Works with android.widget.*
- Scalable, can configure to support custom views
- binding markup and original android markup can sit side-by-side
- WPF inspired binding

Requirements:
- Android 1.6+

For more information, please come to  https://code.google.com/p/android-binding/

Thanks,
-Andy Tsui

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

2011-01-10 Thread Adam Goodchild
Hey,

Ive been looking into getting Custom Attributes working within an
application. I have this working up to the point where I am able to
assign the custom attribute via XML to one of my Views (a Background
or Image Source for example).

What I now want to do is access the Custom Attributes via Code, within
my Activity. I am not implementing custom Views here. I am just
wanting to access, within my Activity, the custom attributes that I
have defined. I will use these to programatically change the look of
my List View based on certain criteria.

Is there a way I can do this? I have the following code, but it does
not work, returns null each time. The code is just a test to assign a
background of the splash programatically.

@Override
public void onCreate(Bundle icicle) {
 super.onCreate(

 setContentView(R.layout.splash);

 TypedArray a =
getApplicationContext().obtainStyledAttributes(R.styleable.MainSplash);
 int i =
a.getResourceId(R.styleable.MainSplash_splashDrawable, 0);
 }

I always get returned '0' when using the above code. Any ideas?

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


Re: [android-developers] Custom Attributes - Accessing via Activity

2011-01-10 Thread Kostya Vasilyev

Where and how are you setting attribute values?

Your call to getStylableAttributes is looking for attribute values in 
the activity's theme, is that where you've specified your values?


-- Kostya

10.01.2011 12:35, Adam Goodchild пишет:

Hey,

Ive been looking into getting Custom Attributes working within an
application. I have this working up to the point where I am able to
assign the custom attribute via XML to one of my Views (a Background
or Image Source for example).

What I now want to do is access the Custom Attributes via Code, within
my Activity. I am not implementing custom Views here. I am just
wanting to access, within my Activity, the custom attributes that I
have defined. I will use these to programatically change the look of
my List View based on certain criteria.

Is there a way I can do this? I have the following code, but it does
not work, returns null each time. The code is just a test to assign a
background of the splash programatically.

 @Override
 public void onCreate(Bundle icicle) {
  super.onCreate(

  setContentView(R.layout.splash);

  TypedArray a =
getApplicationContext().obtainStyledAttributes(R.styleable.MainSplash);
  int i =
a.getResourceId(R.styleable.MainSplash_splashDrawable, 0);
  }

I always get returned '0' when using the above code. Any ideas?




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

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


Re: [android-developers] convert web page to pdf

2011-01-10 Thread kavitha b
Thanks for reply MarksMurphy.

Please suggest any solution to try upon on this.

On Sat, Jan 8, 2011 at 7:01 PM, Mark Murphy  wrote:

> On Sat, Jan 8, 2011 at 4:12 AM, kavitha b  wrote:
> > I have requirement in which I need to convert web page to pdf.
>
> Whoever gives you these requirements desperately needs to get a grip.
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com | http://github.com/commonsguy
> http://commonsware.com/blog | http://twitter.com/commonsguy
>
> _The Busy Coder's Guide to Android Development_ Version 3.4 Available!
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

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

[android-developers] filesystem access on emulator

2011-01-10 Thread Ajay Prabandham
Dear All,
Does anyone in this comunitys,know now to access the linux 
filesytem local to the emulator? Ironically, i am using the windows version 
of the Android SDK API 9.
I need to locate the .apk file that one loads onto the emulator to run/debug 
the project binary.

Thanks and Regards,
Ajay

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

2011-01-10 Thread Adam Goodchild
Ok, I have the following files: attrs.xml, styles.xml, themes.xml
Here is my attrs.xml file:








Here is my themes.xml file:


@drawable/splash


Here is my styles.xml file:


?attr/myMainSplashImage


I have looked at different tutorials and libraries (GreenDroid) to
implement the above.
So I have basically set my custom attribute to whatever I have defined
in my Theme file. This allows me to create different theme files for
different projects (as this is a library project).

I have assigned the Theme to the entire library project. I dont know
if I now have to assign something else to my splash layout file?

On Jan 10, 9:53 am, Kostya Vasilyev  wrote:
> Where and how are you setting attribute values?
>
> Your call to getStylableAttributes is looking for attribute values in
> the activity's theme, is that where you've specified your values?
>
> -- Kostya
>
> 10.01.2011 12:35, Adam Goodchild пишет:
>
>
>
> > Hey,
>
> > Ive been looking into getting Custom Attributes working within an
> > application. I have this working up to the point where I am able to
> > assign the custom attribute via XML to one of my Views (a Background
> > or Image Source for example).
>
> > What I now want to do is access the Custom Attributes via Code, within
> > my Activity. I am not implementing custom Views here. I am just
> > wanting to access, within my Activity, the custom attributes that I
> > have defined. I will use these to programatically change the look of
> > my List View based on certain criteria.
>
> > Is there a way I can do this? I have the following code, but it does
> > not work, returns null each time. The code is just a test to assign a
> > background of the splash programatically.
>
> >     �...@override
> >      public void onCreate(Bundle icicle) {
> >           super.onCreate(
>
> >           setContentView(R.layout.splash);
>
> >           TypedArray a =
> > getApplicationContext().obtainStyledAttributes(R.styleable.MainSplash);
> >           int i =
> > a.getResourceId(R.styleable.MainSplash_splashDrawable, 0);
> >       }
>
> > I always get returned '0' when using the above code. Any ideas?
>
> --
> Kostya Vasilyev -- WiFi Manager + pretty widget 
> --http://kmansoft.wordpress.com

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


[android-developers] How to build static lib

2011-01-10 Thread hen
Hi dear,

I succeeded to built NDK r5 samples "test-libstdc++" to executable and
shared lib, but if I try to build if for static lib, the make
message always just output:

make: Entering directory `/cygdrive/d/cygwin/path/android-ndk-r5/
samples/test-libstdc++'
make: Leaving directory `/cygdrive/d/cygwin/path/android-ndk-r5/
samples/test-libstdc++'

How could I build the program to static lib, do I miss to set some
options ? 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: filesystem access on emulator

2011-01-10 Thread Sarwar Erfan
No need to access emulator filesystem for this. You can find that in the bin 
directory of your project directory in your PC.

Regards
Sarwar Erfan

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

[android-developers] Display admob in full screen

2011-01-10 Thread kavitha b
Hi All,

How to show admob in full screen in android instead of wrap_content?

  

The examples what I see will be shown as a strip of ads.

Please help me.

Thanks,
Kavitha

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

[android-developers] Native heap size

2011-01-10 Thread pedr0
Hi at all,

I am a little bit confused about the native heap on android, I would
like know the native heap max size, there is a way to know it?

Like getRuntime().maxMemory()  which I use for know the maximum limit
of VM heap.

Another question is relative at how the native heap memory is
released, I read that IS NOT the GC of Dalvik which free that memory,
is correct? If yes, when the memory of native heap is released?


Thanks a lot in advance for any suggestion.

pedr0


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


Re: [android-developers] update app without deleting DB

2011-01-10 Thread kavitha b
I hope you can use OnUpgrade method of DB when upgrading the app

On Sun, Jan 9, 2011 at 9:15 PM, Mark Murphy  wrote:

> On Sun, Jan 9, 2011 at 10:37 AM, Alex  wrote:
> > Simple question :
> > I published an app (2months ago). It uses a DB to retrieve
> > information, and the user saves some parameters in the DB.
> > Now, I want to update my app, that means : I want to put more
> > information in the DB but without erasing parameters set by the user.
> >
> > How can I do that ?
>
> Write Java code to "put more information in the DB but without erasing
> parameters set by the user".
>
> For example, if you are using SQLiteOpenHelper, increment the version
> number of your schema. That will cause onUpgrade() to be called in
> your SQLiteOpenHelper subclass the first time your app is run after
> the upgrade. There, you can execute whatever code you want to adjust
> the schema and/or data in the database.
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com | http://github.com/commonsguy
> http://commonsware.com/blog | http://twitter.com/commonsguy
>
> Android Training in London: http://bit.ly/smand1 and http://bit.ly/smand2
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>

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

[android-developers] Re: How to Build Modofied launcher source code

2011-01-10 Thread Sunil
sri  gmail.com> writes:

> 
> Hi,
> 
> As per my requirement i have to modify the Launcher source code.
> 
> I have imported the launcher code in to Eclipse IDE and i could see
> many import errors and variable not found errors.
> 
> Can any body tell me how to build the launcher source code as weel as
> how to build the modified launcher code?
> 
> I have tried digging for information related to this but could not get
> any pointers.
> 
> Can any body help me out in this?
> 
> Thanks in advance for the help!
> 
Sri,

Its is due to the path problems in Eclipse please correct them. Also when you 
build the whole source (in linux), the build should go through.

If your are enabling launcher2 in Eclair, you need to enable the 
RenderScript(librs.so) library in Framework as well.

Please follow the below steps:

1. Edit Android.mk in frameworks/base/graphics/jni, 
Comment out the line line 41 (add # in the beginning)
#LOCAL_MODULE_TAGS := optional

2. Edit Android.mk in frameworks/base/libs/rs,
Comment out the line line 106
#LOCAL_MODULE_TAGS := optional

3. Then issue "make" (better "make clean") in the eclair directory.

HTH,
Sunil




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


Re: [android-developers] Re: Custom Attributes - Accessing via Activity

2011-01-10 Thread Kostya Vasilyev

Adam,

I am not sure about the extra indirection level you have in your code 
(the "?attr" stuff), but this should work:








@drawable/splash



With this in the manifest:





And then:

TypedArray a = 
this.obtainStyledAttributes(R.styleable.MainSplash);


Drawable d1 = 
a.getDrawable(R.styleable.MainSplash_splashDrawable);


a.recycle();


BTW, you can put all this xml stuff in one file - the name doesn't 
matter, as long as it's inside res/values.


--- Kostya

10.01.2011 13:09, Adam Goodchild пишет:

Ok, I have the following files: attrs.xml, styles.xml, themes.xml
Here is my attrs.xml file:

 


 



Here is my themes.xml file:

 
@drawable/splash


Here is my styles.xml file:

 
?attr/myMainSplashImage


I have looked at different tutorials and libraries (GreenDroid) to
implement the above.
So I have basically set my custom attribute to whatever I have defined
in my Theme file. This allows me to create different theme files for
different projects (as this is a library project).

I have assigned the Theme to the entire library project. I dont know
if I now have to assign something else to my splash layout file?

On Jan 10, 9:53 am, Kostya Vasilyev  wrote:

Where and how are you setting attribute values?

Your call to getStylableAttributes is looking for attribute values in
the activity's theme, is that where you've specified your values?

-- Kostya

10.01.2011 12:35, Adam Goodchild пишет:




Hey,
Ive been looking into getting Custom Attributes working within an
application. I have this working up to the point where I am able to
assign the custom attribute via XML to one of my Views (a Background
or Image Source for example).
What I now want to do is access the Custom Attributes via Code, within
my Activity. I am not implementing custom Views here. I am just
wanting to access, within my Activity, the custom attributes that I
have defined. I will use these to programatically change the look of
my List View based on certain criteria.
Is there a way I can do this? I have the following code, but it does
not work, returns null each time. The code is just a test to assign a
background of the splash programatically.
  @Override
  public void onCreate(Bundle icicle) {
   super.onCreate(
   setContentView(R.layout.splash);
   TypedArray a =
getApplicationContext().obtainStyledAttributes(R.styleable.MainSplash);
   int i =
a.getResourceId(R.styleable.MainSplash_splashDrawable, 0);
   }
I always get returned '0' when using the above code. Any ideas?

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



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

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


Re: [android-developers] Re: How to exit the application..?

2011-01-10 Thread 20plus10 30
Use this:

This will stop the proccess:

android.os.Process.killProcess(android.os.Process.myPid());


/Maali

2011/1/10 dilu 

> Even I tried with System.exit(0).
> But its not working .So question is that how to completly exit the
> application if we want to do .
>
> On Dec 29 2010, 11:10 am, Dianne Hackborn  wrote:
> > No, it doesn't, it exits the process, but leaves whatever activity stack
> is
> > being maintained by the system.
> >
> > 2010/12/28 Sandeep N M 
> >
> >
> >
> >
> >
> > > System.exit(0);
> >
> > > Gets you out of anywhere to home screen :).
> >
> > > Regards
> > > Sandeep
> > > On Dec 27, 4:43 pm, Manoj Maurya  wrote:
> > > > you have to call finish() whenever u want to exit.
> >
> > > > Thanks
> > > > Manoj Kumar Maurya
> >
> > > > > any help please...
> >
> > > > > 2010/12/27 Abhilash baddam 
> >
> > > > >> Hi viktor,
> >
> > > > >> What your saying is if i use finish(); method in my code, is i
> > > > >> have to use android:launchMode="singleTask" in manifest file
> right?
> >
> > > > >> 2010/12/27 viktor 
> >
> > > > >> You can set for every Activities android:launchMode="singleTask" ;
> >
> > > > >>> And if you go Home, you always restart an Activity with onCreate
> > > > >>> state.
> >
> > > > >>> On 27 Грд, 10:40, Abhilash baddam
> > > > >>>  wrote:
> > > > >>> > Hi ,
> >
> > > > >>> > I am new to android. How can we exit from application...For
> example
> > > > >>> if
> > > > >>> > we have 3 activities each activity consists one button..when we
> > > click
> > > > >>> on a
> > > > >>> > button which may be from any activity, i want to exit from
> > > application
> > > > >>> and
> > > > >>> > it should go home screen. again if we start the application
> from
> > > > >>> emulator it
> > > > >>> > should start from the beginning of the application. How can we
> do
> > > > this.?
> >
> > > > >>> > Regards,
> > > > >>> > Abhilash.B
> >
> > > > >>> --
> > > > >>> You received this message because you are subscribed to the
> Google
> > > > >>> Groups "Android Developers" group.
> > > > >>> To post to this group, send email to
> > > android-developers@googlegroups.com
> > > > >>> To unsubscribe from this group, send email to
> > > > >>> android-developers+unsubscr...@googlegroups.com
> 
> >
> > > 
> 
> >
> >
> > > > 
> 
> >
> > > 
> 
> >
> >
> > > > >>> For more options, visit this group at
> > > > >>>http://groups.google.com/group/android-developers?hl=en
> >
> > > > > --
> > > > > You received this message because you are subscribed to the Google
> > > > > Groups "Android Developers" group.
> > > > > To post to this group, send email to
> > > android-developers@googlegroups.com
> > > > > To unsubscribe from this group, send email to
> > > > > android-developers+unsubscr...@googlegroups.com
> 
> >
> > > 
> 
> >
> >
> > > > > For more options, visit this group at
> > > > >http://groups.google.com/group/android-developers?hl=en
> >
> > > --
> > > You received this message because you are subscribed to the Google
> > > Groups "Android Developers" group.
> > > To post to this group, send email to
> android-developers@googlegroups.com
> > > To unsubscribe from this group, send email to
> > > android-developers+unsubscr...@googlegroups.com
> 
> >
> > > For more options, visit this group at
> > >http://groups.google.com/group/android-developers?hl=en
> >
> > --
> > Dianne Hackborn
> > Android framework engineer
> > hack...@android.com
> >
> > Note: please don't send private questions to me, as I don't have time to
> > provide private support, and so won't reply to such e-mails.  All such
> > questions should be posted on public forums, where I and others can see
> and
> > answer them.- 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

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

Re: [android-developers] Re: How to exit the application..?

2011-01-10 Thread Kostya Vasilyev
And then if you have a Service component, be prepared for it to stop 
working after a period of time.


10.01.2011 14:04, 20plus10 30 пишет:

Use this:

This will stop the proccess:

android.os.Process.killProcess(android.os.Process.myPid());


/Maali

2011/1/10 dilu >


Even I tried with System.exit(0).
But its not working .So question is that how to completly exit the
application if we want to do .

On Dec 29 2010, 11:10 am, Dianne Hackborn mailto:hack...@android.com>> wrote:
> No, it doesn't, it exits the process, but leaves whatever
activity stack is
> being maintained by the system.
>
> 2010/12/28 Sandeep N M mailto:donks...@gmail.com>>
>
>
>
>
>
> > System.exit(0);
>
> > Gets you out of anywhere to home screen :).
>
> > Regards
> > Sandeep
> > On Dec 27, 4:43 pm, Manoj Maurya mailto:manojk.mau...@gmail.com>> wrote:
> > > you have to call finish() whenever u want to exit.
>
> > > Thanks
> > > Manoj Kumar Maurya
>
> > > > any help please...
>
> > > > 2010/12/27 Abhilash baddam
mailto:abhilash.androiddevelo...@gmail.com>>
>
> > > >> Hi viktor,
>
> > > >> What your saying is if i use finish(); method in my code,
is i
> > > >> have to use android:launchMode="singleTask" in manifest
file right?
>
> > > >> 2010/12/27 viktor mailto:victor.scherb...@gmail.com>>
>
> > > >> You can set for every Activities
android:launchMode="singleTask" ;
>
> > > >>> And if you go Home, you always restart an Activity with
onCreate
> > > >>> state.
>
> > > >>> On 27 Грд, 10:40, Abhilash baddam
> > > >>> mailto:abhilash.androiddevelo...@gmail.com>> wrote:
> > > >>> > Hi ,
>
> > > >>> > I am new to android. How can we exit from
application...For example
> > > >>> if
> > > >>> > we have 3 activities each activity consists one
button..when we
> > click
> > > >>> on a
> > > >>> > button which may be from any activity, i want to exit from
> > application
> > > >>> and
> > > >>> > it should go home screen. again if we start the
application from
> > > >>> emulator it
> > > >>> > should start from the beginning of the application.
How can we do
> > > this.?
>
> > > >>> > Regards,
> > > >>> > Abhilash.B
>
> > > >>> --
> > > >>> You received this message because you are subscribed to
the Google
> > > >>> Groups "Android Developers" group.
> > > >>> To post to this group, send email to
> > android-developers@googlegroups.com

> > > >>> To unsubscribe from this group, send email to
> > > >>> android-developers+unsubscr...@googlegroups.com

mailto:android-developers%252bunsubs-cr...@googlegroups.com>>
> > mailto:android-developers%252bunsubscr...@googlegroups.com>mailto:android-developers%25252bu-nsubscr...@googlegroups.com>>
>
> > > mailto:android-developers%252bunsubscr...@googlegroups.com>mailto:android-developers%25252bu-nsubscr...@googlegroups.com>>
> > mailto:android-developers%25252bunsubscr...@googlegroups.com>mailto:android-developers%25252-52bunsubscr...@googlegroups.com>>
>
> > > >>> For more options, visit this group at
> > > >>>http://groups.google.com/group/android-developers?hl=en
>
> > > > --
> > > > You received this message because you are subscribed to
the Google
> > > > Groups "Android Developers" group.
> > > > To post to this group, send email to
> > android-developers@googlegroups.com

> > > > To unsubscribe from this group, send email to
> > > > android-developers+unsubscr...@googlegroups.com

mailto:android-developers%252bunsubs-cr...@googlegroups.com>>
> > mailto:android-developers%252bunsubscr...@googlegroups.com>mailto:android-developers%25252bu-nsubscr...@googlegroups.com>>
>
> > > > For more options, visit this group at
> > > >http://groups.google.com/group/android-developers?hl=en
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to
android-developers@googlegroups.com

> > To unsubscribe from this group, send email to
> > android-developers+unsubscr...@googlegroups.com

mailto:android-developers%252bunsubs-cr...@googlegroups.com>>
> > For more options, visit this group at
> >http://groups.google.com/group/android-developers?hl=en
>
> --
> Dianne Hackborn
> Android framework engineer
> hack...@android.

[android-developers] WebView image source

2011-01-10 Thread Neilz
Hi all.

I have a WebView where I embed an image in the HTML:

pageContent += "";

However I already have the image cached in memory, which can be called
via a static method to return a Bitmap.

Is there a way I can call the cached Bitmap to go in the 'src' tag?
The method getImage currently returns the full URL of the image.

Thanks.

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


Re: [android-developers] Re: How to exit the application..?

2011-01-10 Thread 20plus10 30
It wil stop the application ttally.
It kills its own proccess.

2011/1/10 Kostya Vasilyev 

>  And then if you have a Service component, be prepared for it to stop
> working after a period of time.
>
> 10.01.2011 14:04, 20plus10 30 пишет:
>
> Use this:
>
> This will stop the proccess:
>
> android.os.Process.killProcess(android.os.Process.myPid());
>
>
> /Maali
>
> 2011/1/10 dilu 
>
>> Even I tried with System.exit(0).
>> But its not working .So question is that how to completly exit the
>> application if we want to do .
>>
>> On Dec 29 2010, 11:10 am, Dianne Hackborn  wrote:
>> > No, it doesn't, it exits the process, but leaves whatever activity stack
>> is
>> > being maintained by the system.
>> >
>> > 2010/12/28 Sandeep N M 
>> >
>> >
>> >
>> >
>> >
>> > > System.exit(0);
>> >
>> > > Gets you out of anywhere to home screen :).
>> >
>> > > Regards
>> > > Sandeep
>> > > On Dec 27, 4:43 pm, Manoj Maurya  wrote:
>> > > > you have to call finish() whenever u want to exit.
>> >
>> > > > Thanks
>> > > > Manoj Kumar Maurya
>> >
>> > > > > any help please...
>> >
>> > > > > 2010/12/27 Abhilash baddam 
>> >
>> > > > >> Hi viktor,
>> >
>> > > > >> What your saying is if i use finish(); method in my code, is i
>> > > > >> have to use android:launchMode="singleTask" in manifest file
>> right?
>> >
>> > > > >> 2010/12/27 viktor 
>> >
>> > > > >> You can set for every Activities android:launchMode="singleTask"
>> ;
>> >
>> > > > >>> And if you go Home, you always restart an Activity with onCreate
>> > > > >>> state.
>> >
>> > > > >>> On 27 Грд, 10:40, Abhilash baddam
>> > > > >>>  wrote:
>> > > > >>> > Hi ,
>> >
>> > > > >>> > I am new to android. How can we exit from application...For
>> example
>> > > > >>> if
>> > > > >>> > we have 3 activities each activity consists one button..when
>> we
>> > > click
>> > > > >>> on a
>> > > > >>> > button which may be from any activity, i want to exit from
>> > > application
>> > > > >>> and
>> > > > >>> > it should go home screen. again if we start the application
>> from
>> > > > >>> emulator it
>> > > > >>> > should start from the beginning of the application. How can we
>> do
>> > > > this.?
>> >
>> > > > >>> > Regards,
>> > > > >>> > Abhilash.B
>> >
>> > > > >>> --
>> > > > >>> You received this message because you are subscribed to the
>> Google
>> > > > >>> Groups "Android Developers" group.
>> > > > >>> To post to this group, send email to
>> > > android-developers@googlegroups.com
>> > > > >>> To unsubscribe from this group, send email to
>> > > > >>> android-developers+unsubscr...@googlegroups.com
>> 
>> >
>> > > 
>> 
>> >
>> >
>> > > > 
>> 
>> >
>> > > 
>> 
>> >
>> >
>> > > > >>> For more options, visit this group at
>> > > > >>>http://groups.google.com/group/android-developers?hl=en
>> >
>> > > > > --
>> > > > > You received this message because you are subscribed to the Google
>> > > > > Groups "Android Developers" group.
>> > > > > To post to this group, send email to
>> > > android-developers@googlegroups.com
>> > > > > To unsubscribe from this group, send email to
>> > > > > android-developers+unsubscr...@googlegroups.com
>> 
>> >
>> > > 
>> 
>> >
>> >
>> > > > > For more options, visit this group at
>> > > > >http://groups.google.com/group/android-developers?hl=en
>> >
>> > > --
>> > > You received this message because you are subscribed to the Google
>> > > Groups "Android Developers" group.
>> > > To post to this group, send email to
>> android-developers@googlegroups.com
>> > > To unsubscribe from this group, send email to
>> > > android-developers+unsubscr...@googlegroups.com
>> 
>> >
>> > > For more options, visit this group at
>> > >http://groups.google.com/group/android-developers?hl=en
>> >
>> > --
>> > Dianne Hackborn
>> > Android framework engineer
>> > hack...@android.com
>> >
>> > Note: please don't send private questions to me, as I don't have time to
>> > provide private support, and so won't reply to such e-mails.  All such
>> > questions should be posted on public forums, where I and others can see
>> and
>> > answer them.- 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
>
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>
>
>
> --
> Kostya Vasilyev -- WiFi Manager + pretty widget -- 
> http://kmansoft.wordpress.com
>
>  --
> You r

Re: [android-developers] Layout problem on Galaxy tab emulator

2011-01-10 Thread Shashidhar
Any Success on this.
I am also having the same issue.

Thanks,
Shashidhar

On Mon, Dec 20, 2010 at 1:21 PM, Bape  wrote:

> I want to develop a application on Samsung Galaxy.
> The resolution is 1024 * 600
> My mainlayout should look like this:
>
> http://office.techniconsulting.be/~peeters/eclipse_screenshot.jpg
>
> I've a left image (296 *600) and right image (728 * 600) as
> background.
> mail.xml looks like:
>
> 
> http://schemas.android.com/apk/res/
> android"
>android:orientation="horizontal" android:layout_height="600px"
> android:layout_width="1024px">
>
>   android:background="@drawable/frame_left" android:gravity="left"
> android:layout_width="296px" android:layout_height="600px"> LinearLayout>
>  android:gravity="right" android:background="@drawable/
> frame_right_kelder" android:layout_width="728px"
> android:layout_height="600px">
> 
>
>
> Whwen I run it in the simulator it looks like:
>
> http://office.techniconsulting.be/~peeters/emulator_screenshot.jpg
>
> Is it not possible to work with pixel height en width in the emulator?
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

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

[android-developers] call .aspx page from Android..

2011-01-10 Thread peria abirami
i need to call .aspx page from android code...

Can any one help on this issue

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

Re: [android-developers] call .aspx page from Android..

2011-01-10 Thread Mark Murphy
Use HttpClient.

On Mon, Jan 10, 2011 at 7:06 AM, peria abirami  wrote:
> i need to call .aspx page from android code...
> Can any one help on this issue
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en



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

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

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


Re: [android-developers] Layout problem on Galaxy tab emulator

2011-01-10 Thread Kostya Vasilyev

This has been resolved.

Set minSdk to 4 or above:

http://developer.android.com/guide/topics/manifest/uses-sdk-element.html

-- Kostya

10.01.2011 15:02, Shashidhar ?:

Any Success on this.
I am also having the same issue.

Thanks,
Shashidhar

On Mon, Dec 20, 2010 at 1:21 PM, Bape > wrote:


I want to develop a application on Samsung Galaxy.
The resolution is 1024 * 600
My mainlayout should look like this:

http://office.techniconsulting.be/~peeters/eclipse_screenshot.jpg


I've a left image (296 *600) and right image (728 * 600) as
background.
mail.xml looks like:


http://schemas.android.com/apk/res/
android"
   android:orientation="horizontal" android:layout_height="600px"
android:layout_width="1024px">






Whwen I run it in the simulator it looks like:

http://office.techniconsulting.be/~peeters/emulator_screenshot.jpg


Is it not possible to work with pixel height en width in the emulator?

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to
android-developers@googlegroups.com

To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com

For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


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



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

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

[android-developers] Re: TextView and ellipsize

2011-01-10 Thread Neilz
I found other people asking this on StackOverflow, it appears there is
a bug here with no fix.

There's a link to a potential solution: is it just me or is there
nothing there?

http://code.google.com/p/android-textview-multiline-ellipse/

On Jan 7, 12:04 am, D K  wrote:
> On Thu, Jan 6, 2011 at 4:01 PM, TreKing  wrote:
> > On Thu, Jan 6, 2011 at 5:27 PM, Neilz  wrote:
>
> >> Nope, no joy unfortunately.
>
> > Lame. What happens if you make it large enough for 4 lines? :-P
>
> > -
> > TreKing  - Chicago
> > transit tracking app for Android-powered devices
>
> >  --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to android-developers@googlegroups.com
> > To unsubscribe from this group, send email to
> > android-developers+unsubscr...@googlegroups.com
> > For more options, visit this group at
> >http://groups.google.com/group/android-developers?hl=en

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


[android-developers] Help with Content Providers / Content Resolvers

2011-01-10 Thread Pedro Duque
Hi,

I'm developing an editor for my application data. This application has a
free and a premium version, so each one has it's own content provider with
different authorities to avoid clashes. The editor also have a local content
provider so it can work standalone.

What I want to do is to check for a content provider existence when I start
the editor so I can choose to use the local one, the one from the free
application or the one from the premium application. I've search the
documentation but I can't find a way to list the content providers
available, for ex., for a specific MIME type.

Can somebody help me?

Regards,
PMD

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

2011-01-10 Thread Juhani Lehtim?ki
This is turning out to be very difficult problem. I found a solution to one 
part of my problem by reading Android's gallery app's source. When I get the 
picture from gallery it works. This is a code snippet from my 
onActivityResult()

final Uri imageUri = data.getData();

String[] columns = {MediaStore.Images.Media.DATA, 
MediaStore.Images.Media.ORIENTATION};

Cursor cursor = getContentResolver().query(imageUri, 
columns, null, null, null);


if (cursor == null) {

return;
}

cursor.moveToFirst();

int columnIndex = cursor.getColumnIndex(columns[0]);
int orientationColumnIndex = 
cursor.getColumnIndex(columns[1]);


String filePath = cursor.getString(columnIndex);
int orientation = cursor.getInt(orientationColumnIndex);

Log.d(TAG, "got image orientation "+orientation);

This works and I get correct orientation information on phones that don't 
rotate the image automatically.


However! This approach does not work when I get the image directly from 
camera intent. I can still run the same query with the camera intent uri but 
the orientation column is always 0 regardless of the orientation. 
Do someone know how I could get the image orientation from camera intent? 

Any help very much appreciated! 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

Re: [android-developers] Re: TextView and ellipsize

2011-01-10 Thread Kostya Vasilyev

10.01.2011 15:37, Neilz пишет:

I found other people asking this on StackOverflow, it appears there is
a bug here with no fix.

There's a link to a potential solution: is it just me or is there
nothing there?


http://code.google.com/p/android-textview-multiline-ellipse/source/browse/#svn%2Ftrunk


http://code.google.com/p/android-textview-multiline-ellipse/

On Jan 7, 12:04 am, D K  wrote:

On Thu, Jan 6, 2011 at 4:01 PM, TreKing  wrote:

On Thu, Jan 6, 2011 at 5:27 PM, Neilz  wrote:

Nope, no joy unfortunately.

Lame. What happens if you make it large enough for 4 lines? :-P
-
TreKing  - Chicago
transit tracking app for Android-powered devices
  --
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en



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

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


Re: [android-developers] Help with Content Providers / Content Resolvers

2011-01-10 Thread Kostya Vasilyev
The mime type mapping works in the other direction: once you have a 
ContentProvider (or more specifically, a URI for a data query) it can be 
used to get the mime type.


For your task, take a look at:

http://developer.android.com/reference/android/content/pm/PackageManager.html#queryContentProviders(java.lang.String, 
int, int)


If both lite / pro versions share the same user id, you can try using 
that for the first parameter. If not, just filter the results by 
authority (since you know what you expect).


You can also use:

http://developer.android.com/reference/android/content/pm/PackageManager.html#getProviderInfo(android.content.ComponentName, 
int)


by calling it with the lite / pro authorities and checking the return value.

-- Kostya

10.01.2011 15:50, Pedro Duque пишет:

Hi,

I'm developing an editor for my application data. This application has 
a free and a premium version, so each one has it's own content 
provider with different authorities to avoid clashes. The editor also 
have a local content provider so it can work standalone.


What I want to do is to check for a content provider existence when I 
start the editor so I can choose to use the local one, the one from 
the free application or the one from the premium application. I've 
search the documentation but I can't find a way to list the content 
providers available, for ex., for a specific MIME type.


Can somebody help me?

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



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

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


[android-developers] Re: TextView and ellipsize

2011-01-10 Thread Neilz
Ah... thanks!

On Jan 10, 12:52 pm, Kostya Vasilyev  wrote:
> 10.01.2011 15:37, Neilz пишет:
>
> > I found other people asking this on StackOverflow, it appears there is
> > a bug here with no fix.
>
> > There's a link to a potential solution: is it just me or is there
> > nothing there?
>
> http://code.google.com/p/android-textview-multiline-ellipse/source/br...
>
>
>
>
>
>
>
> >http://code.google.com/p/android-textview-multiline-ellipse/
>
> > On Jan 7, 12:04 am, D K  wrote:
> >> On Thu, Jan 6, 2011 at 4:01 PM, TreKing  wrote:
> >>> On Thu, Jan 6, 2011 at 5:27 PM, Neilz  wrote:
>  Nope, no joy unfortunately.
> >>> Lame. What happens if you make it large enough for 4 lines? :-P
> >>> -
> >>> TreKing  - Chicago
> >>> transit tracking app for Android-powered devices
> >>>   --
> >>> You received this message because you are subscribed to the Google
> >>> Groups "Android Developers" group.
> >>> To post to this group, send email to android-developers@googlegroups.com
> >>> To unsubscribe from this group, send email to
> >>> android-developers+unsubscr...@googlegroups.com
> >>> For more options, visit this group at
> >>>http://groups.google.com/group/android-developers?hl=en
>
> --
> Kostya Vasilyev -- WiFi Manager + pretty widget 
> --http://kmansoft.wordpress.com

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


[android-developers] does a handler prevents memory leaks???

2011-01-10 Thread Shawn Brown
Hi,

Android docs(1) suggest using threads and a handler to send messages
(to avoid ANR).

Fine.  I've always done that but then porting some code to Android
noticed that it's not necessary.

Passing the Activity (i.e. Context) works fine.

public class WorkerThread extends Thread {

private Activity mActivity;

public WorkerThread(Activity mActivity) {
super();
this.mActivity = mActivity;
}

 @Override
public void run() {
  mActivity.showToast("WorkerThread thread says hello");  //
displays a message
  //setting a TextView works fine too
...
}

I understand the potential for memory leaks (2), but if I control the
WorkerThread lifecycle (it dies when the the Activity  pauses), then
really there is no need to use a handler, is there?  Or do I
misunderstand?

Shawn

(1) Handling Expensive Operations in the UI Thread -
http://developer.android.com/guide/appendix/faq/commontasks.html
(2) http://android-developers.blogspot.com/2009/01/avoiding-memory-leaks.html

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


[android-developers] Re: update app without deleting DB

2011-01-10 Thread Alex
Thanks for your answers!
I'll try this.

On Jan 10, 5:26 am, kavitha b  wrote:
> I hope you can use OnUpgrade method of DB when upgrading the app
>
> On Sun, Jan 9, 2011 at 9:15 PM, Mark Murphy  wrote:
> > On Sun, Jan 9, 2011 at 10:37 AM, Alex  wrote:
> > > Simple question :
> > > I published an app (2months ago). It uses a DB to retrieve
> > > information, and the user saves some parameters in the DB.
> > > Now, I want to update my app, that means : I want to put more
> > > information in the DB but without erasing parameters set by the user.
>
> > > How can I do that ?
>
> > Write Java code to "put more information in the DB but without erasing
> > parameters set by the user".
>
> > For example, if you are using SQLiteOpenHelper, increment the version
> > number of your schema. That will cause onUpgrade() to be called in
> > your SQLiteOpenHelper subclass the first time your app is run after
> > the upgrade. There, you can execute whatever code you want to adjust
> > the schema and/or data in the database.
>
> > --
> > Mark Murphy (a Commons Guy)
> >http://commonsware.com|http://github.com/commonsguy
> >http://commonsware.com/blog|http://twitter.com/commonsguy
>
> > Android Training in London:http://bit.ly/smand1andhttp://bit.ly/smand2
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to android-developers@googlegroups.com
> > To unsubscribe from this group, send email to
> > android-developers+unsubscr...@googlegroups.com
> > For more options, visit this group at
> >http://groups.google.com/group/android-developers?hl=en

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


[android-developers] google analytics jar does not seem to work now

2011-01-10 Thread David Liebman
HI,

I have google analytics incorporated in my android app. When I first
added the code, and then updated my app on android market I got lots
of hits. Now I get none. I know people might just be not using my app,
but I started up the gingerbread emulator and did everything that was
necessary for my app to report using analytics. When I looked at my
google analytics page the next day there was nothing. I could swear
that this worked (from the emulator) before. Unfortunately I have no
access to an actual phone right now. Has anyone else had these
problems? Below are the links to the google analytics android jar file
instructions.

http://www.google.com/url?sa=D&q=http://android-developers.blogspot.com/2010/12/analytics-for-android-apps.html%3Futm_source%3Dfeedburner%26utm_medium%3Dfeed%26utm_campaign%3DFeed%253A%2Bblogspot%252FhsDu%2B%2528Android%2BDevelopers%2BBlog%2529&usg=AFQjCNH6acMiDzFwfl6SCUygAym80-748g

http://code.google.com/mobile/analytics/docs/android/

Here is a link to the barcode for my app on the market if anyone would
like to try it out.

http://android-awesomeguy.blogspot.com/2010/10/awesomeguy-on-android-market.html

Thanks.

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


Re: [android-developers] Help with Content Providers / Content Resolvers

2011-01-10 Thread Pedro Duque
Thank you Kostya, that's exactly what I was looking for!

On 10 January 2011 13:02, Kostya Vasilyev  wrote:

> The mime type mapping works in the other direction: once you have a
> ContentProvider (or more specifically, a URI for a data query) it can be
> used to get the mime type.
>
> For your task, take a look at:
>
>
> http://developer.android.com/reference/android/content/pm/PackageManager.html#queryContentProviders(java.lang.String,
> int, int)
>
> If both lite / pro versions share the same user id, you can try using that
> for the first parameter. If not, just filter the results by authority (since
> you know what you expect).
>
> You can also use:
>
>
> http://developer.android.com/reference/android/content/pm/PackageManager.html#getProviderInfo(android.content.ComponentName,
> int)
>
> by calling it with the lite / pro authorities and checking the return
> value.
>
> -- Kostya
>
> 10.01.2011 15:50, Pedro Duque пишет:
>
>> Hi,
>>
>> I'm developing an editor for my application data. This application has a
>> free and a premium version, so each one has it's own content provider with
>> different authorities to avoid clashes. The editor also have a local content
>> provider so it can work standalone.
>>
>> What I want to do is to check for a content provider existence when I
>> start the editor so I can choose to use the local one, the one from the free
>> application or the one from the premium application. I've search the
>> documentation but I can't find a way to list the content providers
>> available, for ex., for a specific MIME type.
>>
>> Can somebody help me?
>>
>> Regards,
>> PMD
>> --
>> You received this message because you are subscribed to the Google
>> Groups "Android Developers" group.
>> To post to this group, send email to android-developers@googlegroups.com
>> To unsubscribe from this group, send email to
>> android-developers+unsubscr...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/android-developers?hl=en
>>
>
>
> --
> Kostya Vasilyev -- WiFi Manager + pretty widget --
> http://kmansoft.wordpress.com
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

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

[android-developers] Re: XML Signature

2011-01-10 Thread Miguel Paraz
On Jan 4, 5:46 am, spock  wrote:
> How is it possible to generate XML signature on Android. In pure JAVA
> I would probably follow this tutorial:
>
> http://java.sun.com/developer/technicalArticles/xml/dig_signature_api/
>
> but I cannot find following packages on android:
>
> javax.xml.crypto
> javax.xml.crypto.dsig
> javax.xml.crypto.dsig.keyinfo
> javax.xml.crypto.dsig.spec
> javax.xml.crypto.dom
> javax.xml.crypto.dsig.dom
>
> Any suggestions?
>
> Kind Regards



Hi,
I was looking for the same thing. Looks like we need to port a JSR-105
implementation manually.

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


[android-developers] View HTML in Android browser

2011-01-10 Thread perumal316
Hi All,

I want to open saved HTML pages in default Android browser. But
currently when I open the HTML, it is only showing me the option to
either open in HTML viewer not the browser.

How do I make it to open in Android browser?

Thanks and Regards,
Perumal

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


[android-developers] Changing the height of ContextMenu at runtime

2011-01-10 Thread yogi
Hi All,

I have a requirement in which i have to  adjust the height of the
contextMenu at run time.The List already have enough element to  make
scroll in the context menu (11-12 items). so that I can shrink and
expand the contextual menu.

Thanks in Advance..
Regards
Yogi

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


[android-developers] Re: Google Nexus S - Please provide as DEV phone, asap :-)

2011-01-10 Thread Leon Moreyn-Android Development
Sony Ericsson X10a as sold by AT&T does not meet this standard I
believe.

On Jan 8, 3:25 pm, Dianne Hackborn  wrote:
> On Sat, Jan 8, 2011 at 8:34 AM, JP  wrote:
> > On Jan 8, 7:57 am, Mark Murphy  wrote:
> > > "Dev phones" are for people devising alternative firmware. They are
> > > not necessary for ordinary Android SDK development.
> > ... but sure are a good idea to have. We've seen a selection of "dogs"
> > where USB drivers weren't available or LogCat wouldn't pick anything
> > up because the device wouldn't provide any output on the USB port... I
> > also like the presence of dev devices so scope can be established when
> > writing proposals, along the line of "... tested on the Android
> > reference devices Google Ion and Nexus One."
>
> It is required for a device to ship with Market that it full support
> development and debugging over USB.  If you find a device with Market where
> this doesn't work, please let us know -- we aggressively pursue CDD
> incompatibilities to get them fixed (it is a requirement for someone to ship
> with Market to fix any such issues that are found).
>
> That said, yes the dev devices are partly there to be a benchmark for how
> that platform is expected to behave.  (Though for most cases you can test
> against the base platform using the emulator as well.)  I sometimes like to
> refer to them as "Android reference devices." :)
>
> --
> Dianne Hackborn
> Android framework engineer
> hack...@android.com
>
> Note: please don't send private questions to me, as I don't have time to
> provide private support, and so won't reply to such e-mails.  All such
> questions should be posted on public forums, where I and others can see and
> answer them.

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


Re: [android-developers] Layout problem on Galaxy tab emulator

2011-01-10 Thread Shashidhar
@Kostya: Thanks a lot. I Was struggling all the day for this.

On Mon, Jan 10, 2011 at 5:43 PM, Kostya Vasilyev  wrote:

>  This has been resolved.
>
> Set minSdk to 4 or above:
>
> http://developer.android.com/guide/topics/manifest/uses-sdk-element.html
>
> -- Kostya
>
> 10.01.2011 15:02, Shashidhar пишет:
>
> Any Success on this.
> I am also having the same issue.
>
>  Thanks,
> Shashidhar
>
> On Mon, Dec 20, 2010 at 1:21 PM, Bape  wrote:
>
>> I want to develop a application on Samsung Galaxy.
>> The resolution is 1024 * 600
>> My mainlayout should look like this:
>>
>> http://office.techniconsulting.be/~peeters/eclipse_screenshot.jpg
>>
>> I've a left image (296 *600) and right image (728 * 600) as
>> background.
>> mail.xml looks like:
>>
>> 
>> http://schemas.android.com/apk/res/
>> android"
>>android:orientation="horizontal" android:layout_height="600px"
>> android:layout_width="1024px">
>>
>>  > android:background="@drawable/frame_left" android:gravity="left"
>> android:layout_width="296px" android:layout_height="600px">> LinearLayout>
>> > android:gravity="right" android:background="@drawable/
>> frame_right_kelder" android:layout_width="728px"
>> android:layout_height="600px">
>> 
>>
>>
>> Whwen I run it in the simulator it looks like:
>>
>> http://office.techniconsulting.be/~peeters/emulator_screenshot.jpg
>>
>> Is it not possible to work with pixel height en width in the emulator?
>>
>> --
>> You received this message because you are subscribed to the Google
>> Groups "Android Developers" group.
>> To post to this group, send email to android-developers@googlegroups.com
>> To unsubscribe from this group, send email to
>> android-developers+unsubscr...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/android-developers?hl=en
>
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>
>
>
> --
> Kostya Vasilyev -- WiFi Manager + pretty widget -- 
> http://kmansoft.wordpress.com
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>

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

Re: [android-developers] Changing the height of ContextMenu at runtime

2011-01-10 Thread Kostya Vasilyev
Just don't add so many items, perhaps choosing which ones to add based 
on what the user is doing, and what UI element triggered the menu.


-- Kostya

10.01.2011 17:25, yogi пишет:

Hi All,

I have a requirement in which i have to  adjust the height of the
contextMenu at run time.The List already have enough element to  make
scroll in the context menu (11-12 items). so that I can shrink and
expand the contextual menu.

Thanks in Advance..
Regards
Yogi




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

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


[android-developers] Re: Rotating an Android VideoView

2011-01-10 Thread Justin Buser
So if I am correct you are saying that you want the video to be
landscape and the player controls to be portrait while the phone is
portrait oriented?

On Jan 7, 12:41 am, Darshan  wrote:
> My app's requirement is that it should display the Video in Landscape
> mode only even when the device's orientation is changed to Portrait
> leaving all other controls to be in sync with the device's
> orientation. Thats why I am looking for a way to rotate the VideoView
> alone.
>
> I am looking for a way to handle the below scenario:
> 1. Initially the device is in Portrait mode when the 'Play Video"
> button is pressed.
> 2. The video will be fetched and prepared for display.
> 3. Now, when displaying the first frame, I need to rotate the video
> view so that the video gets displayed as in Landscape mode (note that
> the device is still in Portrait mode).
> 4. Once a way for achieving what is required in point 3) above is
> available, I can then need not worry on rotating the videoview on
> further device orientation changes.
>
> Hope I had clearly explained the scenario.
>
> Thanks,
> Darshan
>
> On Jan 7, 10:30 am, Darshan  wrote:
>
> > My app's requirement is that it should display the Video in Landscape
> > mode only even when the device's orientation is changed to Portrait
> > leaving all other controls to be in sync with the device's
> > orientation. Thats why I am looking for a way to rotate the VideoView
> > alone.
>
> > ---
> > Darshan
>
> > On Jan 6, 10:06 pm, TreKing  wrote:
>
> > > On Thu, Jan 6, 2011 at 8:03 AM, Darshan  wrote:
> > > > But, what I want is to display the video in Landscape mode even when the
> > > > device is in Portrait mode. All other UI elements (textview, an edittext
> > > > field, a 'Play Video' Button etc.,) should be displayed in Portrait.
>
> > > Why even bother doing this? If you're not going to rotate the video, then
> > > there's no reason for the user to rotate their phone and thus no reason to
> > > rotate the controls.
>
> > > -
> > > TreKing  - Chicago
> > > transit tracking app for Android-powered devices

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


[android-developers] Re: How to exit the application..?

2011-01-10 Thread dilu
Thanks to everyone who all shared their idea.
I used Abhilash'c link i.e.
http://androidsnips.blogspot.com/2010/08/finish-application.html
Its working perfectly for me.

Regards
Dileep

On Jan 10, 4:27 pm, 20plus10 30 <20plu...@gmail.com> wrote:
> It wil stop the application ttally.
> It kills its own proccess.
>
> 2011/1/10 Kostya Vasilyev 
>
>
>
> >  And then if you have a Service component, be prepared for it to stop
> > working after a period of time.
>
> > 10.01.2011 14:04, 20plus10 30 пишет:
>
> > Use this:
>
> > This will stop the proccess:
>
> > android.os.Process.killProcess(android.os.Process.myPid());
>
> > /Maali
>
> > 2011/1/10 dilu 
>
> >> Even I tried with System.exit(0).
> >> But its not working .So question is that how to completly exit the
> >> application if we want to do .
>
> >> On Dec 29 2010, 11:10 am, Dianne Hackborn  wrote:
> >> > No, it doesn't, it exits the process, but leaves whatever activity stack
> >> is
> >> > being maintained by the system.
>
> >> > 2010/12/28 Sandeep N M 
>
> >> > > System.exit(0);
>
> >> > > Gets you out of anywhere to home screen :).
>
> >> > > Regards
> >> > > Sandeep
> >> > > On Dec 27, 4:43 pm, Manoj Maurya  wrote:
> >> > > > you have to call finish() whenever u want to exit.
>
> >> > > > Thanks
> >> > > > Manoj Kumar Maurya
>
> >> > > > > any help please...
>
> >> > > > > 2010/12/27 Abhilash baddam 
>
> >> > > > >> Hi viktor,
>
> >> > > > >> What your saying is if i use finish(); method in my code, is i
> >> > > > >> have to use android:launchMode="singleTask" in manifest file
> >> right?
>
> >> > > > >> 2010/12/27 viktor 
>
> >> > > > >> You can set for every Activities android:launchMode="singleTask"
> >> ;
>
> >> > > > >>> And if you go Home, you always restart an Activity with onCreate
> >> > > > >>> state.
>
> >> > > > >>> On 27 Грд, 10:40, Abhilash baddam
> >> > > > >>>  wrote:
> >> > > > >>> > Hi ,
>
> >> > > > >>> > I am new to android. How can we exit from application...For
> >> example
> >> > > > >>> if
> >> > > > >>> > we have 3 activities each activity consists one button..when
> >> we
> >> > > click
> >> > > > >>> on a
> >> > > > >>> > button which may be from any activity, i want to exit from
> >> > > application
> >> > > > >>> and
> >> > > > >>> > it should go home screen. again if we start the application
> >> from
> >> > > > >>> emulator it
> >> > > > >>> > should start from the beginning of the application. How can we
> >> do
> >> > > > this.?
>
> >> > > > >>> > Regards,
> >> > > > >>> > Abhilash.B
>
> >> > > > >>> --
> >> > > > >>> You received this message because you are subscribed to the
> >> Google
> >> > > > >>> Groups "Android Developers" group.
> >> > > > >>> To post to this group, send email to
> >> > > android-developers@googlegroups.com
> >> > > > >>> To unsubscribe from this group, send email to
> >> > > > >>> android-developers+unsubscr...@googlegroups.com
> >> 
>
> >> > > 
> >> 
>
> >> > > > 
> >> 
>
> >> > > 
> >> 
>
> >> > > > >>> For more options, visit this group at
> >> > > > >>>http://groups.google.com/group/android-developers?hl=en
>
> >> > > > > --
> >> > > > > You received this message because you are subscribed to the Google
> >> > > > > Groups "Android Developers" group.
> >> > > > > To post to this group, send email to
> >> > > android-developers@googlegroups.com
> >> > > > > To unsubscribe from this group, send email to
> >> > > > > android-developers+unsubscr...@googlegroups.com
> >> 
>
> >> > > 
> >> 
>
> >> > > > > For more options, visit this group at
> >> > > > >http://groups.google.com/group/android-developers?hl=en
>
> >> > > --
> >> > > You received this message because you are subscribed to the Google
> >> > > Groups "Android Developers" group.
> >> > > To post to this group, send email to
> >> android-developers@googlegroups.com
> >> > > To unsubscribe from this group, send email to
> >> > > android-developers+unsubscr...@googlegroups.com
> >> 
>
> >> > > For more options, visit this group at
> >> > >http://groups.google.com/group/android-developers?hl=en
>
> >> > --
> >> > Dianne Hackborn
> >> > Android framework engineer
> >> > hack...@android.com
>
> >> > Note: please don't send private questions to me, as I don't have time to
> >> > provide private support, and so won't reply to such e-mails.  All such
> >> > questions should be posted on public forums, where I and others can see
> >> and
> >> > answer them.- 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
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this

[android-developers] Questions about Custom (Compound) control

2011-01-10 Thread Ale
Hi,

I've developed a custom (compound) control with a count-down progress
bar that I want to embed in some my activities. Now I have the
following questions:

1 - I want, when the count down stops, to let the activity that
contains the control that the count down has stopped. How to do that?

2 - From Android documentation I read the following:

"Note that you also might introduce your own attributes and parameters
into the XML that can be pulled out and used by your constructor"

But how? Do I just need to declare in the control my own attributes,
and how to declare them in XML?

Thank you in advance!

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


Re: [android-developers] Questions about Custom (Compound) control

2011-01-10 Thread Kostya Vasilyev

Ale,

1 - You can model your notification on the type of interface callback 
mechanism used by Android views and widgets:


http://developer.android.com/reference/android/view/View.html#setOnClickListener(android.view.View.OnClickListener)

In your case, you'd define your own interface with a notification method 
(onCountdownReachedZero or something).


2 - Search for "declare styleable". This is the first link from Google:

http://blog.pocketjourney.com/2008/05/02/android-tutorial-42-passing-custom-variables-via-xml-resource-files/

-- Kostya

10.01.2011 18:06, Ale пишет:

Hi,

I've developed a custom (compound) control with a count-down progress
bar that I want to embed in some my activities. Now I have the
following questions:

1 - I want, when the count down stops, to let the activity that
contains the control that the count down has stopped. How to do that?

2 - From Android documentation I read the following:

"Note that you also might introduce your own attributes and parameters
into the XML that can be pulled out and used by your constructor"

But how? Do I just need to declare in the control my own attributes,
and how to declare them in XML?

Thank you in advance!




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

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


[android-developers] Animation on slide drawer

2011-01-10 Thread nikki
Hi Group

I created a slide drawer for my application but it doesn't open
smoothly as it get close. Is there any way i can add animation effect
on opening of my slide drawer..??

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


[android-developers] Create a subset of Bitmap without make a copy

2011-01-10 Thread pedr0
Hi at all,

I have this problem, when I try to make a new bitmap for another one,
like this:

first_data = Bitmap.createBitmap(data, 0, 0, data.getWidth() /
2,data.getHeight());
second_data =  Bitmap.createBitmap(data, data.getWidth() / 2, 0,
data.getWidth() / 2, data.getHeight() );

I meet an OutOfMemoryException...

If i use only the original full image I don't meet this issues, I
think that  Bitmap.createBitmap() make a copy of the original first
image.

There are a way to specify that I DON'T WANT make a copy of that?

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


Re: [android-developers] A Requirement in Browser.

2011-01-10 Thread TreKing
Your question is not very clear.

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

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

Re: [android-developers] How to build static lib

2011-01-10 Thread TreKing
On Mon, Jan 10, 2011 at 4:09 AM, hen  wrote:

> I succeeded to built NDK


You probably want to try asking on another group focused on the NDK.

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

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

Re: [android-developers] Display admob in full screen

2011-01-10 Thread TreKing
On Mon, Jan 10, 2011 at 4:13 AM, kavitha b  wrote:

> How to show admob in full screen in android instead of wrap_content?


Don't use wrap_content?

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

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

Re: [android-developers] Carousel View Animation..?

2011-01-10 Thread TreKing
On Mon, Jan 10, 2011 at 8:01 AM, Abhilash baddam <
abhilash.androiddevelo...@gmail.com> wrote:

> How can i oscillate  the image like a pendulum.
>
Can any one give me the guidance to achieve this one.
> Can anyone give suggestions or related code snippets.
>

Try a (customized) Gallery and some math.

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

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

[android-developers] Re: RTSP streaming with mediaplayer

2011-01-10 Thread Indicator Veritatis
At this point in time, given your post, the best help we can offer is
to refer you to http://www.catb.org/~esr/faqs/smart-questions.html

On Jan 9, 9:43 pm, mayank bisht  wrote:
> I am playing the media player on  rtsp url its playing fine but it is
> not pausing and playing again and again.while if i am using VideoView
> to play the stream it paused but it is showing error in resume the
> video I am using samsung galaxy 3 with android 2.1.Can anyone help me
> please on this topic ?

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


[android-developers] JDK 5 problem

2011-01-10 Thread peeyush varshney
Dear All,

sun-java5-jdk is not getting installed in ubuntu 10.04. how to make it
possible.

-- 
Thank & Regards
Peeyush Varshney

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

Re: [android-developers] JDK 5 problem

2011-01-10 Thread Kumar Bibek
Whats the error?

Kumar Bibek
http://techdroid.kbeanie.com
http://www.kbeanie.com



On Mon, Jan 10, 2011 at 11:04 PM, peeyush varshney <
varshney.peey...@gmail.com> wrote:

> Dear All,
>
> sun-java5-jdk is not getting installed in ubuntu 10.04. how to make it
> possible.
>
> --
> Thank & Regards
> Peeyush Varshney
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

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

Re: [android-developers] JDK 5 problem

2011-01-10 Thread peeyush varshney
package is not there...

On Mon, Jan 10, 2011 at 11:05 PM, Kumar Bibek  wrote:

> Whats the error?
>
> Kumar Bibek
> http://techdroid.kbeanie.com
> http://www.kbeanie.com
>
>
>
> On Mon, Jan 10, 2011 at 11:04 PM, peeyush varshney <
> varshney.peey...@gmail.com> wrote:
>
>> Dear All,
>>
>> sun-java5-jdk is not getting installed in ubuntu 10.04. how to make it
>> possible.
>>
>> --
>> Thank & Regards
>> Peeyush Varshney
>>
>> --
>> You received this message because you are subscribed to the Google
>> Groups "Android Developers" group.
>> To post to this group, send email to android-developers@googlegroups.com
>> To unsubscribe from this group, send email to
>> android-developers+unsubscr...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/android-developers?hl=en
>
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en




-- 
Thank & Regards
Peeyush Varshney

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

2011-01-10 Thread DebUggEr
That is a good guess. I will experiment 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] Installation error: INSTALL_PARSE_FAILED_NO_CERTIFICATES

2011-01-10 Thread MobileVisuals
My project has worked before on a Windows 7 PC. I then installed the
Android developement tools on a Vista PC.
I tried to run my project, but got:

Installation error: INSTALL_PARSE_FAILED_NO_CERTIFICATES
Please check logcat output for more details

Why does this happen and how can I resolve it? This thread

http://code.google.com/p/android/issues/detail?id=830

recommends renaming resource files to resolve it. I tried this, but it
didn't help. How can I check the logcat output?

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


[android-developers] repo intialization

2011-01-10 Thread peeyush varshney
Dear All,

i wanted to initialize the repo in specific folder. whenever  i initialized
the  repo . it initialize in home folder only even i make the directory and
run the command.
my concerned is to keep the froyo and gingerbeard code in separate folder,
but it will replace previous one.


-- 
Thank & Regards
Peeyush Varshney

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

Re: [android-developers] JDK 5 problem

2011-01-10 Thread TreKing
On Mon, Jan 10, 2011 at 12:02 PM, peeyush varshney <
varshney.peey...@gmail.com> wrote:

> package is not there...


You're really going to have to provide more information if you expect to get
help.

Try googling the EXACT error you're getting, for starters.

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

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

[android-developers] Re: View HTML in Android browser

2011-01-10 Thread DanH
I'm guessing you'd say myIntent.setDataAndType(myUri, "text/plain");

On Jan 10, 8:18 am, perumal316  wrote:
> Hi All,
>
> I want to open saved HTML pages in default Android browser. But
> currently when I open the HTML, it is only showing me the option to
> either open in HTML viewer not the browser.
>
> How do I make it to open in Android browser?
>
> Thanks and Regards,
> Perumal

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

2011-01-10 Thread Scott Deutsch
Mark, I will take a look at that and try out the progressbar thingy.

Now for my other issue with streaming the video (it is laggy...cause
it catches up to real time then it needs to buffer more), what would
be the best solution group?

I would like to check how much buffered then play it at a certain
percentage, but when it catches up, I would pause the video until it
buffers more then it would resume. Or, what would be a better
solution. Another solution could be downloading temp files, but I want
your guys take on that also.

My ears are open on this subject since I never tackled something like
this before.

Thanks a bunch group.

On Jan 9, 8:34 am, Mark Murphy  wrote:
> On Sun, Jan 9, 2011 at 11:20 AM, Scott Deutsch  wrote:
> > Ok, so now it streams the video. Thanks.
>
> > But now the problem is, how can I put a buffering bar on top of the
> > surfaceview so they know when it will play.
>
> Use a ProgressBar. Put it and the SurfaceView in RelativeLayout, with
> the ProgressBar a later child, so it stacks on top in the Z-axis.
>
> Here is a sample project designed to demonstrate streaming video with
> such a custom controller:
>
> https://github.com/commonsguy/vidtry
>
> (note: I haven't tried this app in a long time, so there may be minor issues)
>
> > Also, how can I make it so
> > that it doesn't skip like crazy. Like check how muched buffered and if
> > it is 10% resume play and if it catches up...pause.
>
> I haven't seen it skip ever, so I can't comment on that, sorry.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy
>
> Android Training in London:http://bit.ly/smand1andhttp://bit.ly/smand2

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


[android-developers] Code analysis, anyone?

2011-01-10 Thread paladin
Has anyone any experience with Klocwork code analysis for their
Android apps? Is it any good? Or is there some other form of analysis
that anyone has done?

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

2011-01-10 Thread Leon Moreyn-Android Development
What are these other APKs you are trying to DL? Are you taking about
something like a speech engine? Or completely independent
applications?

On Jan 9, 11:41 pm, xeagle  wrote:
> Hi,
> My application contains several apks. I'd like upload my app to
> android Market. If user download my app, can all of these apks be
> installed? 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] Simple compass functionality

2011-01-10 Thread Phil Endecott
Dear Experts,

I'm trying to understand how to get simple compass functionality
working, i.e. I have a map that I want to add a "facing this way"
arrow to.  I don't need other orientation angles i.e. it's not
Augmented Reality, but I do need it to work correctly as the display
orientation changes.  I know about magnetic deviation but will
overlook it in this post.

As far as I can see, there is a reasonably simple deprecated method: I
getDefaultSensor(TYPE_ORIENTATION), and use values[0].  It's
unfortunate that this is deprecated.

The replacement for this deprecated method seems to be:
1. getDefaultSensor(TYPE_GRAVITY) and
getDefaultSensor(TYPE_MAGNETIC_FIELD)
2. When I have new values from both sensors (which don't necessarily
arrive at the same rate), pass them to getRotationMatrix() and then
pass the rotation matrix to getOrientation() to get the angles.

...but that doesn't allow for the display orientation.  I think that I
need to get that (from where?) and subtract it from the result.

...and I also don't think it does the right thing when I am holding
the device near-vertically.  Say you're standing, facing East, holding
the device in front of your face, viewing a map; it will have East at
the top.  But if you tilt the device so it is slightly "overhanging",
this method will flip it so that West is at the top, won't it?  That's
certainly not what the user would expect.

...and I don't really think the accelerometer is needed for this.  I
think the accelerometer is only really needed to get the two other
outputs (pitch and roll) from getOrientation() that I ignore.  Though
I may be wrong about that, if I fix the previous issue, due to varying
magnetic dip angles.

So, has anyone else worked out how all of this should hang together?
Is there some simpler API somewhere that I have missed?


Thanks,  Phil.

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


[android-developers] Activity / Live Wallpaper communication in Android

2011-01-10 Thread Josh
I've got a live wallpaper that I'd like to communicate with from an
Activity in the same package. I've never done any work with services.
Would I be able to use the Local Service pattern, or am I restricted
because my service is a live wallpaper, and need to use Intents or
AIDL?

I think the flow would go something like this, please correct me where
my process might fail:

   1. Preview the live wallpaper from the Live Wallpaper Chooser
   2. Go into my custom Settings activity
   3. Click on a "Screen Shot" button or preference to open up a
"Screen Shot" activity
   4. Send a message to my wallpaper, asking for a screen shot bitmap
to be rendered
   5. The wallpaper service receives the message and renders its
current visuals to a bitmap in the app's data directory
   6. The wallpaper sends a message back to the activity indicating
success and location of the bitmap
   7. The activity receives this message, loads the bitmap from the
given location, and displays it to the user for further processing /
sharing

The parts I'm not sure about are the message passing in 4-7.

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

2011-01-10 Thread A. Elk
AndroidTestCase.getContext() returns a normal Context object. It's the
Context of the test case, not the component under test.

IsolatedContext returns a "mock" Context. I put "mock" in quotes
because its not a mock in the normal sense of that term (for testing).
Instead, it's a template Context that you have to set up yourself. It
"isolates" you from the running Android system, so that your Context
or your test doesn't accidentally get outside of the test fixture. For
example, an IsolatedContext won't accidentally hit a production
database (unless you set it up to do that!) Note, however, that some
of the methods in an IsolatedContext may throw exceptions.
IsolatedContext is documented in the Developer Guide under Framework
Topics > Testing, both in Testing Fundamentals and in Content Provider
Testing.

You haven't said anything more about what you're trying to test, but I
find it interesting that you're using AndroidTestCase instead of one
of the more specific classes. Any reason for this?

Elkmeister.

On Jan 9, 11:56 pm, Mattias Svala  wrote:
> Hello!
>
> I'm writing some tests to test my database code. Can someone here explain if
> there would be a difference writing those tests using the context I get from
> AndroidTestCase.getContext() or using an IsolatedContext.
>
> Speaking of IsolatedContext, what is the easiest way to create one if I just
> need it for some sqlite database testing?
>
> Regards,
> Mattias

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


Re: [android-developers] Re: How to exit the application..?

2011-01-10 Thread Dianne Hackborn
On Mon, Jan 10, 2011 at 3:27 AM, 20plus10 30 <20plu...@gmail.com> wrote:

> It wil stop the application ttally.
> It kills its own proccess.
>

It does kill the process, but that does not stop the application totally.
 Don't use this.

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

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

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

Re: [android-developers] Re: Google Nexus S - Please provide as DEV phone, asap :-)

2011-01-10 Thread Dianne Hackborn
On Mon, Jan 10, 2011 at 6:27 AM, Leon Moreyn-Android Development <
lmor...@earthcam.com> wrote:

> Sony Ericsson X10a as sold by AT&T does not meet this standard I
> believe.
>

The AT&T devices don't have side-loading through the UI enabled.  They still
allow development (including installing) through ADB, and as I said if they
didn't this would be a very large violation of the CDD.

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

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

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

Re: [android-developers] Re: What's new in honeycomb?

2011-01-10 Thread Dianne Hackborn
On Mon, Jan 10, 2011 at 12:43 AM, mort  wrote:

> I've seen several apps in the Honeycomb videos which displayed in one
> screen what must've been multiple Activities before, like e.g. the
> mail list and single mail view.
> Will there be an easy way to support multiple visible "Activities", or
> is it just hard work to create mightier "Widgets" (e.g. something like
> the mail list as Widget instead of ListActivity) and lots of "if that
> Widget exists in the current layout ..."?
>

I think Andy made a comment about this a while ago.  I can't get into
details about Honeycomb at this point.

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

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

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

[android-developers] Re: WebView image source

2011-01-10 Thread Neilz
Perhaps I need to save the Bitmap somewhere on the device prior to
calling my img src in the webview?

I wouldn't want to use the SD card though, it would need to be
internal to the app... and how would I refer to it from the src tag?

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


Re: [android-developers] JDK 5 problem

2011-01-10 Thread peeyush varshney
i am using ubunu 10.04. It does not have jdk 5 related package. If i
download the binary from oracle link n try to install. It shows some .so
dependency.

Thanks
On 11-Jan-2011 12:03 AM, "TreKing"  wrote:
> On Mon, Jan 10, 2011 at 12:02 PM, peeyush varshney <
> varshney.peey...@gmail.com> wrote:
>
>> package is not there...
>
>
> You're really going to have to provide more information if you expect to
get
> help.
>
> Try googling the EXACT error you're getting, for starters.
>
>
-
> TreKing  - Chicago
> transit tracking app for Android-powered devices
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

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

[android-developers] Focusing a video camera

2011-01-10 Thread elik
I developed a small video camera application. It is based on code from
the android sources.
It all works fine except focus. First, I was surprised to see that the
sample video camera code don't have autofocus (or focus).
I understand I need to call camera.autofocus, but I don't really know
where is the right place to put the call it. Anyone ever succeeded in
autofocusing a video camera on android?

Thank
Eli

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

2011-01-10 Thread Mattias Svala
I have just started out developing Android applications, so the only reason 
for me using AndroidTestCase is me being clueless about the other test case 
classes. 

The test I'm writing in this case is for testing some sqlite code. I could 
not find any test case class during my initial investigation that seemed 
appropriate for me to use. What test case class do you think I should use 
and what benefits would that class give me when testing my sqlite code?

:.:: mattias

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

Re: [android-developers] Re: Change the background of an AppWidget

2011-01-10 Thread YuviDroid
>
> Maybe it works likewise if you create
> a Drawable object like GradientDrawable dynamically?


Unfortunately there is no RemoteViews.setImageViewDrawable() :(((


On Mon, Jan 10, 2011 at 9:28 AM, mort  wrote:

> I think if you're feeling masochistic, you could create 9 images and
> do some kind of "manual 9-patch image" with e.g. table or linear
> layout views. Just like in bad old HTML times... ;)
> If your "dynamically created" images aren't too complex, you might
> also use something similar to the XML shape drawables. Opposed to 9-
> patch drawables, XML drawables always were scaled correctly if I set
> them with setImageViewResource. Maybe it works likewise if you create
> a Drawable object like GradientDrawable dynamically?
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
YuviDroid
Check out Launch-X  (a widget to
quickly access your favorite apps and contacts!)
http://android.yuvalsharon.net

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

Re: [android-developers] Re: WebView image source

2011-01-10 Thread Stephen Jungels
If the image is cached in a format that is understood by the browser
(ie JPEG, PNG), you should be able to create a content provider that
will feed the image to the browser via a custom scheme.

On the other hand this could end up wasting a lot of memory so is
there a need to cache the image, rather than letting the WebView
handle that?

SJ

On Mon, Jan 10, 2011 at 2:59 PM, Neilz  wrote:
> Perhaps I need to save the Bitmap somewhere on the device prior to
> calling my img src in the webview?
>
> I wouldn't want to use the SD card though, it would need to be
> internal to the app... and how would I refer to it from the src tag?
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

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


[android-developers] Looking up a View inside a ViewGroup via coordinates

2011-01-10 Thread Abdull
I have a ViewGroup (for instance, a RelativeLayout). This ViewGroup is
populated with several Views (for instance, a few Buttons).
Given a Point relative to the ViewGroup's coordinate system, I would
like to look up the View which is located at this Point. That is, I'm
looking for a public method with a signature similar to

class ViewGroup {
...
public View findViewAt(int x, int y)
...
}

Does the Android GUI Framework include such a method? I had a look in
the API documentation but couldn't find something like this. Isn't
this a classic feature GUI APIs usually provide?

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

2011-01-10 Thread Neilz
Well the reason I'm looking for a way around this is:

The WebView loads the textual content, then a second or so later the
image loads from the given URL. But when the image loads into the
WebView, it screws up the text that is already on display. For some
reason it makes it all garbled and unreadable. So I'm trying to think
of a way to have the image ready before the WebView loads.

On Jan 10, 8:42 pm, Stephen Jungels  wrote:
> If the image is cached in a format that is understood by the browser
> (ie JPEG, PNG), you should be able to create a content provider that
> will feed the image to the browser via a custom scheme.
>
> On the other hand this could end up wasting a lot of memory so is
> there a need to cache the image, rather than letting the WebView
> handle that?
>
> SJ
>
> On Mon, Jan 10, 2011 at 2:59 PM, Neilz  wrote:
> > Perhaps I need to save the Bitmap somewhere on the device prior to
> > calling my img src in the webview?
>
> > I wouldn't want to use the SD card though, it would need to be
> > internal to the app... and how would I refer to it from the src tag?
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to android-developers@googlegroups.com
> > To unsubscribe from this group, send email to
> > android-developers+unsubscr...@googlegroups.com
> > For more options, visit this group at
> >http://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] Looking up a View inside a ViewGroup via coordinates

2011-01-10 Thread Kostya Vasilyev

Abdull,

Take a look at the source for ViewGroup.dispatchTouchEvent.

http://www.netmite.com/android/mydroid/frameworks/base/core/java/android/view/ViewGroup.java

It has code to hit-test children, and it's only a few lines of code.

( provided you can't set click listeners on individual views, which is 
the usual way to handle this )


-- Kostya

10.01.2011 23:44, Abdull пишет:

I have a ViewGroup (for instance, a RelativeLayout). This ViewGroup is
populated with several Views (for instance, a few Buttons).
Given a Point relative to the ViewGroup's coordinate system, I would
like to look up the View which is located at this Point. That is, I'm
looking for a public method with a signature similar to

class ViewGroup {
...
public View findViewAt(int x, int y)
...
}

Does the Android GUI Framework include such a method? I had a look in
the API documentation but couldn't find something like this. Isn't
this a classic feature GUI APIs usually provide?




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

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


Re: [android-developers] Re: WebView image source

2011-01-10 Thread Kostya Vasilyev

10.01.2011 23:52, Neilz пишет:

But when the image loads into the
WebView, it screws up the text that is already on display. For some
reason it makes it all garbled and unreadable.


I would try to fix this first (instead of trying to manage load order).

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

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


[android-developers] Re: does a handler prevents memory leaks???

2011-01-10 Thread Kumar Bibek
Well, if you don't handle that, it will leak. Preferably, you should
be passing the application's context and not the activity's context.
Since, Activity's context depends on the state of the particular
activity, and the context you are probably interested in inside the
Worker thread is most of the times an application context.

On Jan 10, 6:09 pm, Shawn Brown  wrote:
> Hi,
>
> Android docs(1) suggest using threads and a handler to send messages
> (to avoid ANR).
>
> Fine.  I've always done that but then porting some code to Android
> noticed that it's not necessary.
>
> Passing the Activity (i.e. Context) works fine.
>
> public class WorkerThread extends Thread {
>
>     private Activity mActivity;
>
>     public WorkerThread(Activity mActivity) {
>         super();
>         this.mActivity = mActivity;
>     }
>
> �...@override
>     public void run() {
>       mActivity.showToast("WorkerThread thread says hello");  //
> displays a message
>       //setting a TextView works fine too
> ...
>
> }
>
> I understand the potential for memory leaks (2), but if I control the
> WorkerThread lifecycle (it dies when the the Activity  pauses), then
> really there is no need to use a handler, is there?  Or do I
> misunderstand?
>
> Shawn
>
> (1) Handling Expensive Operations in the UI Thread 
> -http://developer.android.com/guide/appendix/faq/commontasks.html
> (2)http://android-developers.blogspot.com/2009/01/avoiding-memory-leaks

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

2011-01-10 Thread Kumar Bibek
Just a doubt. Is your second project (which is used by the first) a
library project? In that case, it should work.

On Jan 9, 10:08 pm, Lazarus 101  wrote:
> I have two projects, the first one has the aidl files and other
> classes that will be shared with the client aps, and the second one
> has the implementation for aidl. First project is set as a dependency
> for the second one, everything compiles just fine and run. But when I
> try to access the service from a client a get a Runtime error
> NoClassDefFoundError.
>
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):
> java.lang.NoClassDefFoundError: my.app.MyService$1
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> my.app.myService.(MyService.java:37)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> java.lang.Class.newInstanceImpl(Native Method)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> java.lang.Class.newInstance(Class.java:1429)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> android.app.ActivityThread.handleCreateService(ActivityThread.java:
> 2940)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> android.app.ActivityThread.access$3300(ActivityThread.java:125)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> android.app.ActivityThread$H.handleMessage(ActivityThread.java:2087)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> android.os.Handler.dispatchMessage(Handler.java:99)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> android.os.Looper.loop(Looper.java:123)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> android.app.ActivityThread.main(ActivityThread.java:4627)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> java.lang.reflect.Method.invokeNative(Native Method)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> java.lang.reflect.Method.invoke(Method.java:521)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> com.android.internal.os.ZygoteInit
> $MethodAndArgsCaller.run(ZygoteInit.java:868)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
> 01-09 18:48:28.003: ERROR/AndroidRuntime(11084):     at
> dalvik.system.NativeStart.main(Native Method)
>
> The problem is fixed if I copy the aidl file in the second project so
> that the generated java interface is in the gen folder from the
> second project. But this is not a viable option because I have to use
> a build server (I don't have direct access to it) and all aidl files
> have to be in the first project.
>
> Anyone else had a similiar 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: What is the name of this widget?

2011-01-10 Thread Kumar Bibek
The reason why a NumberPicker is not public or a part of the SDK is
perhaps because it's not a widely used widget. If it were, it would
have been a part of the SDK, and the widget would have been public.
IMO.

There might be other reasons as well, but this seems to be the most
obvious reason. Remember, the SDK is for a mobile device.

Once we have the tablet specific SDK(if at all), we might see these
widgets as a part of the SDK, since tablets, I assume would have
better hardware than phones.

On Jan 10, 1:38 pm, MerlinBG  wrote:
> Yes, you are right, it is from HTC Desire.
>
> First thought that Sense adds some kind of skin over the NumberPicker, but
> this seems not to be the case when I duplicated it... or perhaps I miss
> something, I am still newbie with Android.
> Well, I guess the general feeling is up to the user, I personally like Sense
> a lot.
> However, generic things like the NumberPicker should be public, imo.

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

2011-01-10 Thread Kumar Bibek
I guess you should stop using Helios. I came across a bunchful of
issues with the current release for Android development.

On Jan 8, 4:31 am, Dan  wrote:
> After upgrading to ADT 8.0.1 with Eclipse Helios (3.6.1) I am still
> getting freezes with code assist. Does anyone have any ideas to fix or
> is this still a bug?

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

2011-01-10 Thread Kumar Bibek
Which example are you following, and what are your exact problems?

On Jan 7, 11:05 pm, John Lussmyer  wrote:
> Is there a tutorial on how to write an Account Authenticator?
> I'm working from the one example I've found, SampleSyncAdapter, and having a
> lot of trouble understanding what the actual flow of control should be.
> For one thing, I actually have a separate Authorization Token - which is NOT
> the password.  I'm having real problems figuring out how it's passed around,
> retrieved, updated, etc...

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

2011-01-10 Thread Kumar Bibek
>From the documentation, I couldn't find an easy way to do this. The
theme, will only change things, that it declares. So, to change the
colors, you might have to dig deep into the DatePickerDialog source
code.

But, I think, an easier way to do this is to create your own
DatePickerDialog by extending the Dialog class.

On Jan 7, 11:02 am, "pramod.deore"  wrote:
> How to change the change color of DatePickerDialog widget? In docs
> there is one constructor which has theme field
>
> public  DatePickerDialog  (Context context, int theme,
> DatePickerDialog.OnDateSetListener callBack, int year, int
> monthOfYear, int dayOfMonth)
>
> But when I tried for different theme value then only size of
> DatePickerDialog  widget changes. If I want to change the color then
> how to do this?
> Thanks

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


[android-developers] Re: ADT plugin for Eclipse under Rational Application Developer 8.0

2011-01-10 Thread Kumar Bibek
There might be conflicts between the packages and/or classnames. The
documentation doesn't say that it's compatible with any other IDE
other than some variations of eclipse. (Even the helios is not fully
supported). So, instead of banging your head, please use the correct
IDE and it will work like a charm :)

On Jan 6, 1:43 am, dg  wrote:
> I deployed the ADT plugin for Eclipse on Rational Application
> Developer 8.0. When I try to compile the HelloAndroid tutorial I get
> the following error. The jdk used is 1.6:
>
> Problems occurred building the selected resources.
> Errors running builder 'Android Package Builder' on project
> 'TestAndroid'.
> sun/security/x509/X500Name
>
> 
>  product-id="com.ibm.rational.rsa4ws.product.v80.ide" product-
> name="Rational® Software Architect for WebSphere Software" time="Wed
> Jan 05 15:32:01 EST 2011" version="1.2">
>         
>          version="6.1 build 7600"/>
>          version="3.6.1.M20100825-0800" severity="4">
>                  plugin-version="8.0.1.v201012062107-82219" severity="4">
>                          type="java.lang.NoClassDefFoundError">
>                                  class="com.android.sdklib.internal.build.SignedJarBuilder"
> method="writeSignatureBlock"/>
>                                  class="com.android.sdklib.internal.build.SignedJarBuilder"
> method="close"/>
>                                  class="com.android.sdklib.build.ApkBuilder"
> method="sealApk"/>
>                                  class="com.android.ide.eclipse.adt.internal.build.BuildHelper"
> method="finalPackage"/>
>                                  class="com.android.ide.eclipse.adt.internal.build.BuildHelper"
> method="finalDebugPackage"/>
>                                  class="com.android.ide.eclipse.adt.internal.build.builders.PostCompilerBuilder"
> method="build"/>
>                                  class="org.eclipse.core.internal.events.BuildManager$2"
> method="run"/>
>                                  class="org.eclipse.core.runtime.SafeRunner" method="run"/>
>                                  class="org.eclipse.core.internal.events.BuildManager"
> method="basicBuild"/>
>                                  class="org.eclipse.core.internal.events.BuildManager"
> method="basicBuild"/>
>                                  class="org.eclipse.core.internal.events.BuildManager$1"
> method="run"/>
>                                  class="org.eclipse.core.runtime.SafeRunner" method="run"/>
>                                  class="org.eclipse.core.internal.events.BuildManager"
> method="basicBuild"/>
>                                  class="org.eclipse.core.internal.events.BuildManager"
> method="basicBuild"/>
>                                  class="org.eclipse.core.internal.events.BuildManager"
> method="build"/>
>                                  class="org.eclipse.core.internal.resources.Project$1"
> method="run"/>
>                                  class="org.eclipse.core.internal.resources.Workspace"
> method="run"/>
>                                  class="org.eclipse.core.internal.resources.Project"
> method="internalBuild"/>
>                                  class="org.eclipse.core.internal.resources.Project"
> method="build"/>
>                                  class="org.eclipse.ui.actions.BuildAction"
> method="invokeOperation"/>
>                                  class="org.eclipse.ui.actions.WorkspaceAction"
> method="execute"/>
>                                  class="org.eclipse.ui.actions.WorkspaceAction$2"
> method="runInWorkspace"/>
>                                  class="org.eclipse.core.internal.resources.InternalWorkspaceJob"
> method="run"/>
>                                  class="org.eclipse.core.internal.jobs.Worker" method="run"/
>
>                         
>                 
>         
> 

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

2011-01-10 Thread Kumar Bibek
Google on how to use HG plugin in eclipse. You will get step by step
instructions on how to do that.

On Jan 6, 3:37 am, gab1972  wrote:
> I'm trying to import the source code provided here: (http://
> code.google.com/p/foursquared/) into Eclipse.  There are instructions
> that say, "Get a local copy of the foursquared repository with this
> command:
>
> hg clonehttps://foursquared.googlecode.com/hg/foursquared";  But how
> do I use that command to get it into Eclipse.  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] Re: Google Nexus S - Please provide as DEV phone, asap :-)

2011-01-10 Thread Leon Moreyn-Android Development
Can you provide more details about CDD or confirm that the X10A as
sold by AT&T meets the CDD standard and is fully available for
developer use with all features running.

On Jan 10, 2:18 pm, Dianne Hackborn  wrote:
> On Mon, Jan 10, 2011 at 6:27 AM, Leon Moreyn-Android Development <
>
> lmor...@earthcam.com> wrote:
> > Sony Ericsson X10a as sold by AT&T does not meet this standard I
> > believe.
>
> The AT&T devices don't have side-loading through the UI enabled.  They still
> allow development (including installing) through ADB, and as I said if they
> didn't this would be a very large violation of the CDD.
>
> --
> Dianne Hackborn
> Android framework engineer
> hack...@android.com
>
> Note: please don't send private questions to me, as I don't have time to
> provide private support, and so won't reply to such e-mails.  All such
> questions should be posted on public forums, where I and others can see and
> answer them.

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


Re: [android-developers] Re: Google Nexus S - Please provide as DEV phone, asap :-)

2011-01-10 Thread Kumar Bibek
CDD Details here
http://source.android.com/compatibility/overview.html

I believe it should be.

Kumar Bibek
http://techdroid.kbeanie.com
http://www.kbeanie.com



On Tue, Jan 11, 2011 at 3:06 AM, Leon Moreyn-Android Development <
lmor...@earthcam.com> wrote:

> Can you provide more details about CDD or confirm that the X10A as
> sold by AT&T meets the CDD standard and is fully available for
> developer use with all features running.
>
> On Jan 10, 2:18 pm, Dianne Hackborn  wrote:
> > On Mon, Jan 10, 2011 at 6:27 AM, Leon Moreyn-Android Development <
> >
> > lmor...@earthcam.com> wrote:
> > > Sony Ericsson X10a as sold by AT&T does not meet this standard I
> > > believe.
> >
> > The AT&T devices don't have side-loading through the UI enabled.  They
> still
> > allow development (including installing) through ADB, and as I said if
> they
> > didn't this would be a very large violation of the CDD.
> >
> > --
> > Dianne Hackborn
> > Android framework engineer
> > hack...@android.com
> >
> > Note: please don't send private questions to me, as I don't have time to
> > provide private support, and so won't reply to such e-mails.  All such
> > questions should be posted on public forums, where I and others can see
> and
> > answer them.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

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

[android-developers] Re: Google Nexus S - Please provide as DEV phone, asap :-)

2011-01-10 Thread Leon Moreyn-Android Development
Ok. So here is what I am trying to understand. I have an X10A from
AT&T. I can not develop on the phone because it doesn't allow me to
install third party none market applications. If I try to root the
phone it will remove the 3G and WIFI from functionality from the
phone. At this point I am considering the need that I may need buy a
new phone just for the soul purpose of being able to test the apps I'm
developing. Am I wrong to think that there must be something that AT&T
can provide me with to root the phone so I can develop on it?

On Jan 10, 4:38 pm, Kumar Bibek  wrote:
> CDD Details herehttp://source.android.com/compatibility/overview.html
>
> I believe it should be.
>
> Kumar Bibekhttp://techdroid.kbeanie.comhttp://www.kbeanie.com
>
> On Tue, Jan 11, 2011 at 3:06 AM, Leon Moreyn-Android Development <
>
>
>
> lmor...@earthcam.com> wrote:
> > Can you provide more details about CDD or confirm that the X10A as
> > sold by AT&T meets the CDD standard and is fully available for
> > developer use with all features running.
>
> > On Jan 10, 2:18 pm, Dianne Hackborn  wrote:
> > > On Mon, Jan 10, 2011 at 6:27 AM, Leon Moreyn-Android Development <
>
> > > lmor...@earthcam.com> wrote:
> > > > Sony Ericsson X10a as sold by AT&T does not meet this standard I
> > > > believe.
>
> > > The AT&T devices don't have side-loading through the UI enabled.  They
> > still
> > > allow development (including installing) through ADB, and as I said if
> > they
> > > didn't this would be a very large violation of the CDD.
>
> > > --
> > > Dianne Hackborn
> > > Android framework engineer
> > > hack...@android.com
>
> > > Note: please don't send private questions to me, as I don't have time to
> > > provide private support, and so won't reply to such e-mails.  All such
> > > questions should be posted on public forums, where I and others can see
> > and
> > > answer them.
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to android-developers@googlegroups.com
> > To unsubscribe from this group, send email to
> > android-developers+unsubscr...@googlegroups.com
> > For more options, visit this group at
> >http://groups.google.com/group/android-developers?hl=en

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


Re: [android-developers] does a handler prevents memory leaks???

2011-01-10 Thread Dianne Hackborn
Toasts must be shown from a thread that is running a handler, and by doing
so you are causing that thread to be a UI a thread for the duration of a
toast with the corresponding constraints (it will not execute its work if
you block it with your own stuff).

You are only living on luck if you touch anything in the view hierarchy from
another thread.  The view hierarchy is very, very single threaded.  There
are some sanity checks at places for calls coming in from the wrong thread,
but they won't catch everything, and the things they don't will result in
randomly broken behavior depending on how threads race or not.

On Mon, Jan 10, 2011 at 5:09 AM, Shawn Brown wrote:

> Hi,
>
> Android docs(1) suggest using threads and a handler to send messages
> (to avoid ANR).
>
> Fine.  I've always done that but then porting some code to Android
> noticed that it's not necessary.
>
> Passing the Activity (i.e. Context) works fine.
>
> public class WorkerThread extends Thread {
>
>private Activity mActivity;
>
>public WorkerThread(Activity mActivity) {
>super();
>this.mActivity = mActivity;
>}
>
>  @Override
>public void run() {
>  mActivity.showToast("WorkerThread thread says hello");  //
> displays a message
>  //setting a TextView works fine too
> ...
> }
>
> I understand the potential for memory leaks (2), but if I control the
> WorkerThread lifecycle (it dies when the the Activity  pauses), then
> really there is no need to use a handler, is there?  Or do I
> misunderstand?
>
> Shawn
>
> (1) Handling Expensive Operations in the UI Thread -
> http://developer.android.com/guide/appendix/faq/commontasks.html
> (2)
> http://android-developers.blogspot.com/2009/01/avoiding-memory-leaks.html
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



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

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

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

[android-developers] Re: MediaPlayer StreamVideo question.

2011-01-10 Thread Scott Deutsch
Mark, so the ProgressBar going on top of the SurfaceView worked.

Actually all I had to do was:


http://schemas.android.com/apk/res/android";
android:layout_width="fill_parent"
android:layout_height="fill_parent">






So, now I just need help to fix the lagging streaming video.

Thanks group.

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

[android-developers] Solution for P2P messaging on Wifi LAN

2011-01-10 Thread Nathan
I've seen some older posts on here about P2P messaging. Apparently
there is nothing built in, but there are some libraries that people
were hoping would be ported to Android.

I'm looking for a solution for messaging on a wifi local area network.
No server. No internet. No phone service.

I'd like to be able to send short messages among a group of people.

What solution would you use?

Nathan

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


[android-developers] Re: MediaPlayer StreamVideo question.

2011-01-10 Thread Doug
Any reason why you couldn't post your videos to YouTube and let the
(often built-in) YouTube app or its mobile HTML5 web site figure out
what to do with them?  The bonus is that you do no extra coding, your
app stays smaller, and people have the option to view them in higher
quality on their desktop.

Doug

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

2011-01-10 Thread Scott Deutsch
Well, I wanted to control the vids on my own domain,,,but if it comes to 
thati might do that.

But, for now I am trying to get it to stream on my android using 
MediaPlayerI mean it does, but really choppy.

Any ideas?

Thanks.

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

Re: [android-developers] JDK 5 problem

2011-01-10 Thread Marcin Orlowski
On 10 January 2011 21:19, peeyush varshney  wrote:
> i am using ubunu 10.04. It does not have jdk 5 related package.

And Google is broken too?
http://www.clickonf5.org/linux/how-install-sun-java-ubuntu-1004-lts/

> download the binary from oracle link n try to install.

You should not as in most cases popular software is packaged. May however
be simply not in generic repository but that usually requires one action to
add or enable it in /etc/apt/sources.list

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