[android-developers] Img tag replaced in Intent

2011-06-23 Thread rochdev
Hi,

I'm unsure if this is a feature or a bug.

What I'm trying to do is to pass some styled text between two
activities.

final Intent intent = new Intent(this, ActivityB.class);
intent.putExtra("message", Html.fromHtml("My image 
http://example.com/image.png\"; />", imageGetter, null));
startActivity(intent);

Then when I retrieve my text in the new Activity the entire img tag is
replaced by  (OBJ - symbol).

CharSequence message = intent.getCharSequenceExtra("message");

START message
My image 

END

Any thoughts?

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


[android-developers] How to play large size video from sdcard in android

2011-06-23 Thread naveen kumar
Hello Google Android Developer,

I am trying to play large video from sdcard by android code, that is
not playing,i dont want to play video from url,

so please help me how to play large video in android from local
folder..

In case of XCODE by using mediaplayer they able to play any type of
large video.

Android also supports mediaplayer api for media file.

Here i am only listening the voice i am not able to place view on
surface holder.

is possible to see video using mediaplayer in android framework.

Please someone reply me clearly.

if not solution then kindly help me for to divide the 1gb file in
300MB.


Thanks, in advance

i am not getting perfect answer by google.

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


[android-developers] Launching widget in floating mode onHome Screen from an apk

2011-06-23 Thread mayur
Hi ,

  I have an apk from which I want to launch a widget in floating mode
on to the Home Screen.
  Problem is I dont know the layout details [height /width etc ] of
the widget before hand .
  Saw some sample apps where this is done but the layout info etc is
constant there .
  But in my case I wont be having this beforehand .

Could anyone plz suggest a solution .

Thanks for you help in advance.

Regards,
Mayur

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

2011-06-23 Thread Ali Chousein
@Anusha: Try using the Facebook SDK for Android and follow one of the
examples. It should just work. I've integrated the Facebook SDK in my
own application and didn't face any difficulties. Try running one of
the provided examples by Facebook (if you are using Eclipse you need
to integrate both projects for the example and the Facebook SDK) and
follow the code of this example. Please don't forget to use your own
application ID, otherwise it won't work.

@TreKing: Any Android SDK integration question can perfectly be asked
here. Please don't try to stop the majority of the discussions. You
are neither the police nor the owner of this platform; so please don't
try to act like one. If you don't know the answer just don't write
anything. The question of Anusha was perfectly valid: Integration of
Facebook Android SDK. He is not talking about Hong Kong stock exhange.
Really, please, don't try to stop the majority of the discussions. Do
it like the rest of us. If you don't have anything to say, please
don't react. It's easier. Some of the members are really newbies, but
probably eager to learn and also with talent. Don't forget, you also
used to be a newbie.

--
Ali Chousein
Geo-Filtered Assistant
http://geo-filtered-assistant.blogspot.com/

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


Re: [android-developers] Re: Need someone to test app on physical device 2.3, 3.0, 31

2011-06-23 Thread Raghav Sood
Thanks. The app is non commercial and free. It is also open source. I was
just uploading the source but it is taking a while. As it is not really
dependent on screen configurations like a game I suppose I could follow
TreKing's advice. I haven't integrated a bug reporting system as yet but I
will have it done by the next version.

On Fri, Jun 24, 2011 at 11:42 AM, Nikolay Elenkov  wrote:

> On Fri, Jun 24, 2011 at 2:59 PM, Raghav Sood  wrote:
> > Nikolay, I cannot pay the testers. I am 14 years old. It is unlikely that
> > someone would do it for free but it is worth a shot as opposed to buying
> the
> > required devices, which is out of my budget for a very long time.
>
> You might want to say so in the first place. If it's non-commercial,
> volunteer project, etc, people might want to help.
>
> > I am not
> > asking anyone to conduct a test that goes over each and everything of the
> > app. All I want to know is if it starts, displays a list of earthquakes
> and
> > whether or not the preferences (apart from auto update) work.
>
> Doing this on a real device doesn't really buy you much, you can
> do the same thing on the emulator. Thorough testing on a real device
> might uncover some more obscure bugs (including in Android), but
> just a quick run will only get you 'it works'.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



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

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

[android-developers] Re: In which way should I read a video file in binary mode into a byte buffer?

2011-06-23 Thread Zsolt Vasvari
Jiabin,

You would put the video into the "raw" folder, so yeah, it should
work.

http://developer.android.com/guide/topics/resources/providing-resources.html


On Jun 24, 1:44 pm, Jiabin Qin  wrote:
> I searched Google and found several ways , but I am not sure which is
> the correct one.
>
> File mFilePtr = new File(getExternalFilesDir(null), mFilename);
> InputStream is = getResources().openRawResource(id);
>                         is.read(mBuffer, 0, bufsize);
>
> The doubt for this is , in the method: openRawResource(id), on the
> developers site, it says:
> Open a data stream for reading a raw resource. This can only be used
> with resources whose value is the name of an asset files -- that is,
> it can be used to open drawable, sound, and raw resources; it will
> fail on string and color resources.
> id The resource identifier to open, as generated by the appt tool.
>
> Is it ok to read my video in that way?
>
> Thanks in advance!
> Jiabin
> Singapore

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


Re: [android-developers] Re: Need someone to test app on physical device 2.3, 3.0, 31

2011-06-23 Thread Nikolay Elenkov
On Fri, Jun 24, 2011 at 2:59 PM, Raghav Sood  wrote:
> Nikolay, I cannot pay the testers. I am 14 years old. It is unlikely that
> someone would do it for free but it is worth a shot as opposed to buying the
> required devices, which is out of my budget for a very long time.

You might want to say so in the first place. If it's non-commercial,
volunteer project, etc, people might want to help.

> I am not
> asking anyone to conduct a test that goes over each and everything of the
> app. All I want to know is if it starts, displays a list of earthquakes and
> whether or not the preferences (apart from auto update) work.

Doing this on a real device doesn't really buy you much, you can
do the same thing on the emulator. Thorough testing on a real device
might uncover some more obscure bugs (including in Android), but
just a quick run will only get you 'it works'.

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


Re: [android-developers] Re: Need someone to test app on physical device 2.3, 3.0, 31

2011-06-23 Thread TreKing
On Fri, Jun 24, 2011 at 12:59 AM, Raghav Sood  wrote:

> Nikolay, I cannot pay the testers. I am 14 years old. It is unlikely that
> someone would do it for free but it is worth a shot as opposed to buying the
> required devices, which is out of my budget for a very long time. I am not
> asking anyone to conduct a test that goes over each and everything of the
> app. All I want to know is if it starts, displays a list of earthquakes and
> whether or not the preferences (apart from auto update) work. It will take
> less than 5 minutes and the apk is less than 50kb.


If you tested on two devices and several emulators, really, you should be
fine assuming you're not doing anything crazy in your app. Even if someone
confirmed that your app ran on X.Y device, there is no guarantee that it
won't break doing something specific a user would do in a real world
situation or running on another specific phone.

Testing is good but really the only apps that require such intense testing
across many devices are games and such that depend highly on the screen and
hardware. For example I've never tested my app on 3.0 (no device and don't
want to bother with the emulator) but I know it works fine from talking to a
user.

If you haven't already, incorporated ACRA or some such bug reporting
mechanism into your app then release it to the wild and fix the bugs as they
come - and they will come, I don't care how many quick < 5 minute tests you
manage to get.

-
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] Re: Need someone to test app on physical device 2.3, 3.0, 31

2011-06-23 Thread Raghav Sood
Nikolay, I cannot pay the testers. I am 14 years old. It is unlikely that
someone would do it for free but it is worth a shot as opposed to buying the
required devices, which is out of my budget for a very long time. I am not
asking anyone to conduct a test that goes over each and everything of the
app. All I want to know is if it starts, displays a list of earthquakes and
whether or not the preferences (apart from auto update) work. It will take
less than 5 minutes and the apk is less than 50kb.

On Fri, Jun 24, 2011 at 11:15 AM, Nikolay Elenkov  wrote:

> On Fri, Jun 24, 2011 at 2:40 PM, Raghav Sood  wrote:
> > I know that but I really needed to test it on those platforms.
>
> How much are you willing to pay testers? Don't expect people to
> do it for free. If you are in contact with some of users, you can ask
> them to test your app (in exchange for a free upgrade or something).
>
> There are also places that you can go and test on different devices
> (for a fee). Some sites offer to do it for you, don't know how much
> you can trust those.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



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

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

Re: [android-developers] Re: Need someone to test app on physical device 2.3, 3.0, 31

2011-06-23 Thread Nikolay Elenkov
On Fri, Jun 24, 2011 at 2:40 PM, Raghav Sood  wrote:
> I know that but I really needed to test it on those platforms.

How much are you willing to pay testers? Don't expect people to
do it for free. If you are in contact with some of users, you can ask
them to test your app (in exchange for a free upgrade or something).

There are also places that you can go and test on different devices
(for a fee). Some sites offer to do it for you, don't know how much
you can trust those.

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


[android-developers] In which way should I read a video file in binary mode into a byte buffer?

2011-06-23 Thread Jiabin Qin
I searched Google and found several ways , but I am not sure which is
the correct one.

File mFilePtr = new File(getExternalFilesDir(null), mFilename);
InputStream is = getResources().openRawResource(id);
is.read(mBuffer, 0, bufsize);

The doubt for this is , in the method: openRawResource(id), on the
developers site, it says:
Open a data stream for reading a raw resource. This can only be used
with resources whose value is the name of an asset files -- that is,
it can be used to open drawable, sound, and raw resources; it will
fail on string and color resources.
id The resource identifier to open, as generated by the appt tool.

Is it ok to read my video in that way?

Thanks in advance!
Jiabin
Singapore

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


Re: [android-developers] Re: Need someone to test app on physical device 2.3, 3.0, 31

2011-06-23 Thread Raghav Sood
I know that but I really needed to test it on those platforms.

On Fri, Jun 24, 2011 at 11:07 AM, Chris  wrote:

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




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

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

[android-developers] Re: Need someone to test app on physical device 2.3, 3.0, 31

2011-06-23 Thread Chris
This mailing list is not a QA forum.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Which OS is more preferable for Android apps, middleware,source/OEM level development.

2011-06-23 Thread NaveenShrivastva
Both os is good.Xp is good because all software available easy lye  .In case
of Mac it's good for heavy application it's performance is fine.so Mac
environment is good.but need user to more aware abt mac

On Fri, Jun 24, 2011 at 6:34 AM, Nainala Shrinivas wrote:

> Hi,
>
> Could you any one give some clarity for Android development on which
> OS is more preferable?
>
> I am planning to buy new PC for android development for all the
> levels, like Apps, Middle level source modifications, Even we want to
> create own image.
>
> Can we do all the development on MacOS and Ubuntu. Which one more
> suggestible and compatible. Please suggest me :)
>
> Thanks for you help in advance.
>
> BR
> Srinivas
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en




-- 
Naveen Shrivastava
BCA+MCA(LAST SEM)+O/A/B Level(DOEACC SOCITY IT GOVT INDIA)

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

[android-developers] Need someone to test app on physical device 2.3, 3.0, 31

2011-06-23 Thread Raghav Sood
Hi all,

I recently finished the first version of one of my apps. I wrote it for
android 2.2, but later re wrote parts of it so that it would work on 2.1 as
well. I have tested it on the 2.1, 2.2 and 2.3 emulators and 2.1 and 2.2
devices. I would appreciate it if someone could test it on a physical device
running 2.3, 3.0 or 3.1 and post back the results. There are some problems
like the autoupdate does not work as of now which I am aware of. The app is
not malware. It is meant to display a list of earthquakes in the past 24
hours in the United States. I am working on adding more countries.

Thanks

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

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

[android-developers] Re: Which OS is more preferable for Android apps, middleware,source/OEM level development.

2011-06-23 Thread Chris
C64

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

2011-06-23 Thread Ed
you have this twice:
 http://groups.google.com/group/android-developers?hl=en


Re: [android-developers] client-server in android

2011-06-23 Thread Miguel Morales
>
> Dear adrian
>

Who's Adrian?

You can use google to find examples on how to use networking on Android,
it's fairly simple.

On Thu, Jun 23, 2011 at 6:11 PM, Chi Kit Leung wrote:

> I think that is more suitable to use SOA.
>
>
> On Fri, Jun 24, 2011 at 10:43 AM, TreKing  wrote:
>
>> On Thu, Jun 23, 2011 at 6:53 AM, Naga K  wrote:
>>
>>> i am new to android technology,till i struggle develop the android
>>> application,give me idea how to develop client -server android application .
>>
>>
>> Dude, if you're struggling to develop a regular android application,
>> you're not making a "client -server android application", whatever that even
>> means.
>>
>>
>>> if you have any same application please send me.
>>
>>
>> Yeah, sure ... sit right there and I'll send you all da codz you need to
>> perfectly meet your needs.
>>
>>
>> -
>>  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
>>
>
>
>
> --
> Regards,
> Michael Leung
> http://www.itblogs.info
> http://www.michaelleung.info
>
>  --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



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

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

Re: [android-developers] authentication of an app in facebook

2011-06-23 Thread anusha
yes i am using it


On Fri, Jun 24, 2011 at 9:53 AM, ram dharan  wrote:

>
>
> On Thu, Jun 23, 2011 at 3:41 PM, Anusha D  wrote:
>
>> Hi,
>> I am trying to authenticate an app on facebook just similarly as shown
>> in the following link for twitter.Though i logged into my facebook
>> account it says " the information cannot be retrieved as user not
>> logged in". The link is as follows:
>> https://github.com/brione/Brion-Learns-OAuth
>>
>> --
>>
>> You received this message because you are subscribed to the Google
>> Groups "Android Developers" group.
>> To post to this group, send email to android-developers@googlegroups.com
>> To unsubscribe from this group, send email to
>> android-developers+unsubscr...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/android-developers?hl=en
>>
> hii r u using facebook  sdk which is provided in developers site
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
D.Anusha
4/4 B.Tech
Shri Vishnu Engineering College For Women
Bhimavaram
West Godavari Dt.
Andhra Pradesh.

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

2011-06-23 Thread ArcDroid
Thought there might be an easier way, but I got it to work just fine.
Thanks all for your help!
Jake
http://www.arcdroid.com

On Jun 23, 11:06 am, Mark Murphy  wrote:
> On Thu, Jun 23, 2011 at 10:48 AM, ArcDroid  wrote:
> > Thanks, but do you happen to have a simple example?
>
> Of setAdapter() with AlertDialog.Builder? No, 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/smand1,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


Re: [android-developers] Please help me with this issue

2011-06-23 Thread arun kumar
plz send me the login code..


On Fri, Jun 24, 2011 at 5:55 AM, TreKing  wrote:

> On Thu, Jun 23, 2011 at 2:49 PM, Jatin Salla wrote:
>
>> But When I started the Emulator with this new AVD the app is not running
>>
>
> What does that mean, exactly?
>
>
> -
> 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

Re: [android-developers] authentication of an app in facebook

2011-06-23 Thread ram dharan
On Thu, Jun 23, 2011 at 3:41 PM, Anusha D  wrote:

> Hi,
> I am trying to authenticate an app on facebook just similarly as shown
> in the following link for twitter.Though i logged into my facebook
> account it says " the information cannot be retrieved as user not
> logged in". The link is as follows:
> https://github.com/brione/Brion-Learns-OAuth
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en

hii r u using facebook  sdk which is provided in developers site

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

[android-developers] Use extra webcam on android

2011-06-23 Thread Jean
Hello,I got android 3.1 and it has some useful usb APIs.So I want to
use an extra webcam on android,but I dont know how to do.Can somebody
help me?

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


[android-developers] Which OS is more preferable for Android apps, middleware,source/OEM level development.

2011-06-23 Thread Nainala Shrinivas
Hi,

Could you any one give some clarity for Android development on which
OS is more preferable?

I am planning to buy new PC for android development for all the
levels, like Apps, Middle level source modifications, Even we want to
create own image.

Can we do all the development on MacOS and Ubuntu. Which one more
suggestible and compatible. Please suggest me :)

Thanks for you help in advance.

BR
Srinivas

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


[android-developers] HttpClient Secure?

2011-06-23 Thread Piraba
Hi All;

I am new to Android. My requirement is save the data to MSSQL. I have
done using HttpClient.I want to know this HttpClient is secure.If i
want make a secure connection How can I take SSL certification. Please
guide me. This is my code :

HttpClient httpclient = getClient();
HttpPost httppost = new 
HttpPost("http://192.xxx.x.xxx/android/
productInvoiceTest.php");
httppost.setEntity(new 
UrlEncodedFormEntity(nameValuePairs));
HttpResponse response = httpclient.execute(httppost);

Intent intent = new Intent();
intent.setClass(this, InvoiceResult.class);
intent.putExtra("productName", 
productName.getText().toString());
intent.putExtra("productId", 
productId.getText().toString());
startActivity(intent);


public DefaultHttpClient getClient() {
DefaultHttpClient ret = null;

// sets up parameters
HttpParams params = new BasicHttpParams();
HttpProtocolParams.setVersion(params, HttpVersion.HTTP_1_1);
HttpProtocolParams.setContentCharset(params, "utf-8");
params.setBooleanParameter("http.protocol.expect-continue", 
false);

// registers schemes for both http and https
SchemeRegistry registry = new SchemeRegistry();
registry.register(new Scheme("http",
PlainSocketFactory.getSocketFactory(), 80));
final SSLSocketFactory sslSocketFactory =
SSLSocketFactory.getSocketFactory();

sslSocketFactory.setHostnameVerifier(SSLSocketFactory.BROWSER_COMPATIBLE_HOSTNAME_VERIFIER);
registry.register(new Scheme("https", sslSocketFactory, 443));

ThreadSafeClientConnManager manager = new
ThreadSafeClientConnManager(params, registry);
ret = new DefaultHttpClient(manager, params);
return ret;
}

Please guide me whther this code is correct or not.

Thanks in advance.

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


[android-developers] Which OS is more preferable for Android apps, middleware,source/OEM level development.

2011-06-23 Thread Nainala Shrinivas
Hi,

Could you any one give some clarity for Android development on which
OS is more preferable?

I am planning to buy new PC for android development for all the
levels, like Apps, Middle level source modifications, Even we want to
create own image.

Can we do all the development on MacOS and Ubuntu. Which one more
suggestible and compatible. Please suggest me :)

Thanks for you help in advance.

BR
Srinivas

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

2011-06-23 Thread Chris
Presumably iOS exposes this as an event, and he's porting an iOS app.

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

2011-06-23 Thread Spiral123
Hi Prasanna...

That still doesn't answer the question.  Why do you want to notify the
app that the keyboard has been shown/hidden?  What do you want the app
to do with that information?

If you can tell us the answer to these questions then I believe
someone will be able to help you accomplish what you want.


On Jun 23, 1:32 am, Prasannaa  wrote:
> The scenario is ,
> I want to notify the app that a KeyBoard has been shown/hidden from my api.
>
> 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: Alarm Service

2011-06-23 Thread Sivaprakash
Oops :-) I supposed to be till the device get Re-Boot.

2011/6/23 Károly Holczhauser 

> Yahe :D five start :D
>
> On jún. 23, 16:24, Yahel  wrote:
> > > Where I can use Alarm Service, looks like the schedule information will
> be
> > > persisted only till the device gets boot up.
> >
> > The drunk coder from India strikes again :)
> >
> > If you wonder how these messages gets here :
> >
> > Prakash gets drunk, then comes home :
> >
> > "My wife that B..ch.I'll have a boat one dayAnd then he tells
> > me...Oh WTF...Oh yeah Android...Alarm service...Need to pee"
> >
> > and falls asleep :D
> >
> > Yahel
> >
> > On 23 juin, 16:03, Sivaprakash  wrote:
> >
> >
> >
> >
> >
> >
> >
> >
> >
> > > --
> > > - Prakash.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en
>



-- 
- Prakash.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email 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 difference between the garbage collector calls GC Explicit, GC For Malloc, and GC External Malloc?

2011-06-23 Thread Chris
http://stackoverflow.com/questions/4976566/what-do-gc-for-malloc-gc-explicit-and-other-gc-mean-in-android-logcat

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

[android-developers] Re: best way to implement a thread requring a result from a function that must be run on the UI thread

2011-06-23 Thread rukiman
To be more precise the thread which requires a result from the UI
thread is the SurfaceView thread. I do not want to pre generate the
result from the UI thread to minimize the memory footprint.

On Jun 24, 12:03 pm, rukiman  wrote:
> I am in a thread that I did not create, its part of a library and I
> need to generate a result which can only be done in the UI thread.
> Any good tutorial on the best way to achieve this?
>
> I know I will have to post a handler to the UI thread, but whats the
> best way for the UI thread to return the result? And I have to make
> the other thread wait for the result.
>
> A good code snipped would help. 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: weird behaviour while overriding FrameLayout.dispatchDraw() on a view that contains a scrollview

2011-06-23 Thread rukiman
For anyone interested this is the fixed code:

class FrameLayoutWithOfflineBitmap extends FrameLayout {

private Bitmap mOfflineBitmap;
private Canvas mOfflineCanvas;
private Paint paint;

public FrameLayoutWithOfflineBitmap(Context context) {
super(context);
paint = new Paint();
paint.setColor(Color.BLACK);
}

@Override
public void onSizeChanged(int w, int h, int oldw, int oldh) {
// just in case we already had the bitmap allocated before
if(mOfflineBitmap != null) {
mOfflineBitmap.recycle();
}
mOfflineBitmap = Bitmap.createBitmap(w, h, 
Bitmap.Config.RGB_565);
mOfflineCanvas = new Canvas();
mOfflineCanvas.setBitmap(mOfflineBitmap);
}

@Override
public void dispatchDraw(Canvas canvas) {
// draw to our offline bitmap
mOfflineCanvas.drawRect(0, 0, mOfflineBitmap.getWidth(),
mOfflineBitmap.getHeight(), paint);
super.dispatchDraw(mOfflineCanvas);
// now draw our offline bitmap to the system canvas
canvas.drawBitmap(mOfflineBitmap, 0, 0, null);
}

public Bitmap getScreenSnapshot() {
return mOfflineBitmap;
}
}

On Jun 24, 12:00 pm, rukiman  wrote:
> Btw forgot to say thanks Romain for your help. I have another question
> (see forum) which I'm sure you are very capable of answering :D
>
> On Jun 24, 10:56 am, rukiman  wrote:
>
>
>
>
>
>
>
> > Found the issue is because I have to clear the bitmap first before
> > rendering the view onto it, the edges are transparent and its showing
> > through to what was drawn before.
> > Question is how would I know what color to clear the bitmap with?
>
> > On Jun 24, 10:14 am, Romain Guy  wrote:
>
> > > The drawing cache is per view, so if you need to capture several views
> > > (sibling, and not a subtree like you are doing in your example) if
> > > would be better to allocate a single bitmap. This works of course only
> > > if all the views have the same size.
>
> > > On Thu, Jun 23, 2011 at 5:06 PM, rukiman  
> > > wrote:
> > > > I am suspecting using the view cache system causes the view system to
> > > > allocate memory for the view.
> > > > Now lets say I can to capture 3 views, does that mean memory is
> > > > allocated for 3 views worth of caches if I don't destroy the cache?
>
> > > > Also I noticed through profiling that this code runs around 100ms
> > > > view.setDrawingCacheEnabled(true);
> > > >        view.setDrawingCacheQuality(View.DRAWING_CACHE_QUALITY_HIGH);
> > > >        view.setDrawingCacheBackgroundColor(Color.BLACK);
> > > >        Bitmap bitmap = view.getDrawingCache();
> > > >        Bitmap retVal = bitmap == null ? null :
> > > > bitmap.copy(bitmap.getConfig(), false);
> > > >        view.destroyDrawingCache();
> > > >        view.setDrawingCacheEnabled(false);
> > > >        return retVal;
>
> > > > while this runs at around 60ms
> > > > mCanvas.setBitmap(mBitmapCapture);
> > > >   view.draw(mCanvas);
> > > >   Bitmap retVal = mBitmapCapture;
>
> > > > I have to capture a few views and trying to speed them as quick as
> > > > possible and at the same time not use much memory. I guess the slight
> > > > speed difference is in enabling and destroying the view drawing cache?
> > > > What is the effect of not destroying it? Does that mean it will suffer
> > > > from my approach above that is double the workload on each frame as
> > > > well?
>
> > > > Going back to my approach my code is just as I pasted it, should I be
> > > > saving the canvas and restoring it in the dispatchDraw? Any help is
> > > > appreciated. Thanks.
>
> > > > On Jun 24, 9:47 am, Romain Guy  wrote:
> > > >> It's either because you don't properly save/restore the state of your
> > > >> offline Canvas or maybe because of the bitmap config (although it
> > > >> should work just fine in 565.)
>
> > > >> What I don't understand however is why you refuse to use the drawing
> > > >> cache API that already exists for this purpose? Using this API will
> > > >> not necessarily force another redraw of the view. With the drawing
> > > >> cache, the cache is automatically redrawn whenever the view changes.
> > > >> Your approach however doubles the workload on *every* frame.
>
> > > >> On Thu, Jun 23, 2011 at 4:23 PM, rukiman  
> > > >> wrote:
> > > >> > I am trying to understand which this code which works perfectly for
> > > >> > capturing almost any view except if there is a ScrollView in the
> > > >> > framelayout, in this case there is a slight issue with the top and
> > > >> > bottom areas where scrollview fades its contents. There is some
> > > >> > corruption occurring.
>
> > > >> > public class FrameLayoutWithOfflineBitmap extends FrameLayout {
>
> > > >> >        private Bitmap mOfflineBitmap;
> > > >> >        private Can

[android-developers] What is the difference between the garbage collector calls GC Explicit, GC For Malloc, and GC External Malloc?

2011-06-23 Thread Greg Siano
I want to know how many times my game is causing the garbage collector
to run but I don't know which calls I should be looking for, and maybe
some of them are not from my application and are unavoidable.

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


[android-developers] best way to implement a thread requring a result from a function that must be run on the UI thread

2011-06-23 Thread rukiman
I am in a thread that I did not create, its part of a library and I
need to generate a result which can only be done in the UI thread.
Any good tutorial on the best way to achieve this?

I know I will have to post a handler to the UI thread, but whats the
best way for the UI thread to return the result? And I have to make
the other thread wait for the result.

A good code snipped would help. 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: weird behaviour while overriding FrameLayout.dispatchDraw() on a view that contains a scrollview

2011-06-23 Thread rukiman
Btw forgot to say thanks Romain for your help. I have another question
(see forum) which I'm sure you are very capable of answering :D

On Jun 24, 10:56 am, rukiman  wrote:
> Found the issue is because I have to clear the bitmap first before
> rendering the view onto it, the edges are transparent and its showing
> through to what was drawn before.
> Question is how would I know what color to clear the bitmap with?
>
> On Jun 24, 10:14 am, Romain Guy  wrote:
>
>
>
>
>
>
>
> > The drawing cache is per view, so if you need to capture several views
> > (sibling, and not a subtree like you are doing in your example) if
> > would be better to allocate a single bitmap. This works of course only
> > if all the views have the same size.
>
> > On Thu, Jun 23, 2011 at 5:06 PM, rukiman  wrote:
> > > I am suspecting using the view cache system causes the view system to
> > > allocate memory for the view.
> > > Now lets say I can to capture 3 views, does that mean memory is
> > > allocated for 3 views worth of caches if I don't destroy the cache?
>
> > > Also I noticed through profiling that this code runs around 100ms
> > > view.setDrawingCacheEnabled(true);
> > >        view.setDrawingCacheQuality(View.DRAWING_CACHE_QUALITY_HIGH);
> > >        view.setDrawingCacheBackgroundColor(Color.BLACK);
> > >        Bitmap bitmap = view.getDrawingCache();
> > >        Bitmap retVal = bitmap == null ? null :
> > > bitmap.copy(bitmap.getConfig(), false);
> > >        view.destroyDrawingCache();
> > >        view.setDrawingCacheEnabled(false);
> > >        return retVal;
>
> > > while this runs at around 60ms
> > > mCanvas.setBitmap(mBitmapCapture);
> > >   view.draw(mCanvas);
> > >   Bitmap retVal = mBitmapCapture;
>
> > > I have to capture a few views and trying to speed them as quick as
> > > possible and at the same time not use much memory. I guess the slight
> > > speed difference is in enabling and destroying the view drawing cache?
> > > What is the effect of not destroying it? Does that mean it will suffer
> > > from my approach above that is double the workload on each frame as
> > > well?
>
> > > Going back to my approach my code is just as I pasted it, should I be
> > > saving the canvas and restoring it in the dispatchDraw? Any help is
> > > appreciated. Thanks.
>
> > > On Jun 24, 9:47 am, Romain Guy  wrote:
> > >> It's either because you don't properly save/restore the state of your
> > >> offline Canvas or maybe because of the bitmap config (although it
> > >> should work just fine in 565.)
>
> > >> What I don't understand however is why you refuse to use the drawing
> > >> cache API that already exists for this purpose? Using this API will
> > >> not necessarily force another redraw of the view. With the drawing
> > >> cache, the cache is automatically redrawn whenever the view changes.
> > >> Your approach however doubles the workload on *every* frame.
>
> > >> On Thu, Jun 23, 2011 at 4:23 PM, rukiman  
> > >> wrote:
> > >> > I am trying to understand which this code which works perfectly for
> > >> > capturing almost any view except if there is a ScrollView in the
> > >> > framelayout, in this case there is a slight issue with the top and
> > >> > bottom areas where scrollview fades its contents. There is some
> > >> > corruption occurring.
>
> > >> > public class FrameLayoutWithOfflineBitmap extends FrameLayout {
>
> > >> >        private Bitmap mOfflineBitmap;
> > >> >        private Canvas mOfflineCanvas;
>
> > >> >        public FrameLayoutWithOfflineBitmap(Context context) {
> > >> >                super(context);
> > >> >        }
>
> > >> >        @Override
> > >> >        public void onSizeChanged(int w, int h, int oldw, int oldh) {
> > >> >                // just in case we already had the bitmap allocated 
> > >> > before
> > >> >                if(mOfflineBitmap != null) {
> > >> >                        mOfflineBitmap.recycle();
> > >> >                }
> > >> >                mOfflineBitmap = Bitmap.createBitmap(w, h, 
> > >> > Bitmap.Config.RGB_565);
> > >> >                mOfflineCanvas = new Canvas();
> > >> >                mOfflineCanvas.setBitmap(mOfflineBitmap);
> > >> >        }
>
> > >> >        @Override
> > >> >        public void dispatchDraw(Canvas canvas) {
> > >> >                // draw to our offline bitmap
> > >> >                super.dispatchDraw(mOfflineCanvas);
> > >> >                // now draw our offline bitmap to the system canvas
> > >> >                canvas.drawBitmap(mOfflineBitmap, 0, 0, null);
> > >> >        }
>
> > >> >        public Bitmap getScreenSnapshot() {
> > >> >                return mOfflineBitmap;
> > >> >        }
> > >> > }
>
> > >> > I understand there are other ways to capture the view such as using
> > >> > the View's drawing cache, but I am not interested in this method. Can
> > >> > someone explain to me what is going on here and if there is way to
> > >> > address this issue? Basically I am trying to get access to a snapshot
> > >> > of a view a

Re: [android-developers] Re: circular rotating and vertically aligned Image switcher

2011-06-23 Thread TreKing
On Thu, Jun 23, 2011 at 6:44 PM, Indicator Veritatis wrote:

> Now, as Android slowly takes over the mobile world and generations of
> programmers search Google to find this post
>

No worries there - if this group is any indication, the vast majority of
"programmers" have never heard of Google.

-
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: Full screen on HTC sensation (qHD)

2011-06-23 Thread Chris
Just to confirm the OP's experience, I've noticed that a lot of other apps 
I've downloaded since don't scale well.  A lot of these use webviews as 
their root view... but the problem isn't limited to webview.

The Sensation has an odd resolution.

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

2011-06-23 Thread JK Park
thank you for your reply

On 6월24일, 오전7시59분, Mark Murphy  wrote:
> On Thu, Jun 23, 2011 at 7:35 AM, JK Park  wrote:
> > I am trying to build up a program that managing android on web server.
>
> > So when a customer is installing my app, I want to show a form and
> > then send a filled form to server.
> > the form is basic information such as name, address and job.
>
> > Can anyone tell me how to show a form when a app is installing?
>
> This is not possible. Please collect this information on the first run
> of the application, when the user launches it from the home screen
> launcher.
>
> --
> 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/smand1,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


[android-developers] Re: Speech Recognition in Android

2011-06-23 Thread davemac
Recognizing speech is really hard to do well. What you get with
Google's Android Recognizer is pretty good. If you want to consider
another, you could look at Sphinx.

- dave
www.androidbook.com/proandroid3

On Jun 23, 6:05 pm, Droid  wrote:
> The speech recogniser often makes mistakes, so you have to think about
> how to handle wrong words. Otherwise its quite easy to feed voice
> recognition to text.
> There is lots of code on Google to do that. I have a loop that asks if
> the text is correct or not. Well, it works fine, but most users do not
> like using it unfortunately. I suppose because its slow.
>
> On Jun 23, 9:30 am, khanh_qhi™  wrote:
>
>
>
> > Hi,
> > I need build a small application about Speech Recognition based-on Android
> > platform, such as: port speech input to text.
> > Hence, is there a way/open source that to do for this?
>
> > ---
> > Regards,
> > Khanh.

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

2011-06-23 Thread Chi Kit Leung
I think that is more suitable to use SOA.

On Fri, Jun 24, 2011 at 10:43 AM, TreKing  wrote:

> On Thu, Jun 23, 2011 at 6:53 AM, Naga K  wrote:
>
>> i am new to android technology,till i struggle develop the android
>> application,give me idea how to develop client -server android application .
>
>
> Dude, if you're struggling to develop a regular android application, you're
> not making a "client -server android application", whatever that even means.
>
>
>> if you have any same application please send me.
>
>
> Yeah, sure ... sit right there and I'll send you all da codz you need to
> perfectly meet your needs.
>
>
> -
> 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
>



-- 
Regards,
Michael Leung
http://www.itblogs.info
http://www.michaelleung.info

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

[android-developers] Re: How to Implement Drag And Drop for image views by extending View Group

2011-06-23 Thread davemac
Are you doing this in Android 3 or an earlier version? There's direct
support for drag and drop since Android 3.0 so it's much easier. See
the DragEvent class. But it's possible prior to Android 3.0, just
harder.

- dave
http://www.androidbook.com/proandroid3

On Jun 22, 11:57 pm, ram dharan  wrote:
> Hii all i m new to android,m developing an app which needs Drag and
> Drop if images by extending View Group Class.Could any one plz tell
> how can i achieve this.any help is 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: weird behaviour while overriding FrameLayout.dispatchDraw() on a view that contains a scrollview

2011-06-23 Thread rukiman
Found the issue is because I have to clear the bitmap first before
rendering the view onto it, the edges are transparent and its showing
through to what was drawn before.
Question is how would I know what color to clear the bitmap with?

On Jun 24, 10:14 am, Romain Guy  wrote:
> The drawing cache is per view, so if you need to capture several views
> (sibling, and not a subtree like you are doing in your example) if
> would be better to allocate a single bitmap. This works of course only
> if all the views have the same size.
>
>
>
>
>
>
>
>
>
> On Thu, Jun 23, 2011 at 5:06 PM, rukiman  wrote:
> > I am suspecting using the view cache system causes the view system to
> > allocate memory for the view.
> > Now lets say I can to capture 3 views, does that mean memory is
> > allocated for 3 views worth of caches if I don't destroy the cache?
>
> > Also I noticed through profiling that this code runs around 100ms
> > view.setDrawingCacheEnabled(true);
> >        view.setDrawingCacheQuality(View.DRAWING_CACHE_QUALITY_HIGH);
> >        view.setDrawingCacheBackgroundColor(Color.BLACK);
> >        Bitmap bitmap = view.getDrawingCache();
> >        Bitmap retVal = bitmap == null ? null :
> > bitmap.copy(bitmap.getConfig(), false);
> >        view.destroyDrawingCache();
> >        view.setDrawingCacheEnabled(false);
> >        return retVal;
>
> > while this runs at around 60ms
> > mCanvas.setBitmap(mBitmapCapture);
> >   view.draw(mCanvas);
> >   Bitmap retVal = mBitmapCapture;
>
> > I have to capture a few views and trying to speed them as quick as
> > possible and at the same time not use much memory. I guess the slight
> > speed difference is in enabling and destroying the view drawing cache?
> > What is the effect of not destroying it? Does that mean it will suffer
> > from my approach above that is double the workload on each frame as
> > well?
>
> > Going back to my approach my code is just as I pasted it, should I be
> > saving the canvas and restoring it in the dispatchDraw? Any help is
> > appreciated. Thanks.
>
> > On Jun 24, 9:47 am, Romain Guy  wrote:
> >> It's either because you don't properly save/restore the state of your
> >> offline Canvas or maybe because of the bitmap config (although it
> >> should work just fine in 565.)
>
> >> What I don't understand however is why you refuse to use the drawing
> >> cache API that already exists for this purpose? Using this API will
> >> not necessarily force another redraw of the view. With the drawing
> >> cache, the cache is automatically redrawn whenever the view changes.
> >> Your approach however doubles the workload on *every* frame.
>
> >> On Thu, Jun 23, 2011 at 4:23 PM, rukiman  wrote:
> >> > I am trying to understand which this code which works perfectly for
> >> > capturing almost any view except if there is a ScrollView in the
> >> > framelayout, in this case there is a slight issue with the top and
> >> > bottom areas where scrollview fades its contents. There is some
> >> > corruption occurring.
>
> >> > public class FrameLayoutWithOfflineBitmap extends FrameLayout {
>
> >> >        private Bitmap mOfflineBitmap;
> >> >        private Canvas mOfflineCanvas;
>
> >> >        public FrameLayoutWithOfflineBitmap(Context context) {
> >> >                super(context);
> >> >        }
>
> >> >        @Override
> >> >        public void onSizeChanged(int w, int h, int oldw, int oldh) {
> >> >                // just in case we already had the bitmap allocated before
> >> >                if(mOfflineBitmap != null) {
> >> >                        mOfflineBitmap.recycle();
> >> >                }
> >> >                mOfflineBitmap = Bitmap.createBitmap(w, h, 
> >> > Bitmap.Config.RGB_565);
> >> >                mOfflineCanvas = new Canvas();
> >> >                mOfflineCanvas.setBitmap(mOfflineBitmap);
> >> >        }
>
> >> >        @Override
> >> >        public void dispatchDraw(Canvas canvas) {
> >> >                // draw to our offline bitmap
> >> >                super.dispatchDraw(mOfflineCanvas);
> >> >                // now draw our offline bitmap to the system canvas
> >> >                canvas.drawBitmap(mOfflineBitmap, 0, 0, null);
> >> >        }
>
> >> >        public Bitmap getScreenSnapshot() {
> >> >                return mOfflineBitmap;
> >> >        }
> >> > }
>
> >> > I understand there are other ways to capture the view such as using
> >> > the View's drawing cache, but I am not interested in this method. Can
> >> > someone explain to me what is going on here and if there is way to
> >> > address this issue? Basically I am trying to get access to a snapshot
> >> > of a view as quick as possible. My idea is that the view is already
> >> > drawn onto the screen, we should be able to get access to this without
> >> > having to force another redundant redraw of the view.
>
> >> > I am also very keen to understand the flaw with the above code in
> >> > terms of the scrollview. Thanks.
>
> >> > --
> >> > You received this message beca

[android-developers] Re: circular rotating and vertically aligned Image switcher

2011-06-23 Thread Zsolt Vasvari
I love Durians.  They may stink, but they taste great.

On Jun 24, 7:44 am, Indicator Veritatis  wrote:
> Well thanks a lot, ZZsolt! Now, as Android slowly takes over the
> mobile world and generations of programmers search Google to find this
> post, they will curse your name for wasting their time with your
> childish sarcasm. "Juicy Fruit" indeed! You should be allowed to use
> only the Durian version instead;)
>
> On Jun 23, 12:36 am, Zsolt Vasvari  wrote:
>
>
>
> > Darn, I think those methods may have been added in Android 5.0 Juicy-
> > Fruit.  Sorry.
>
> > On Jun 23, 3:32 pm, Sapna Srivastav  wrote:> There 
> > is no such methods that you told to use in my code.
>
> > > On Jun 23, 12:23 pm, Zsolt Vasvari  wrote:
>
> > > > myImageSwitcher.setVerticalAlign(true);
> > > > myImageSwitcher.setCircularRotatory(true);
>
> > > > On Jun 23, 2:39 pm, Sapna Srivastav  wrote:
>
> > > > > Hi all
>
> > > > > Would you tell me how can I make an image switcher vertical align and
> > > > > circular rotatory.
>
> > > > > Thanks and regards
> > > > > Sapna Srivastav- Hide quoted text -
>
> > > - Show quoted text -- Hide quoted text -
>
> - Show quoted text -

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


Re: [android-developers] moving buttons

2011-06-23 Thread TreKing
On Wed, Jun 22, 2011 at 11:16 PM, yasith miuranga
wrote:

> I want to know how to make Android UI with buttons moving.


They're called "Animations".

-
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] client-server in android

2011-06-23 Thread TreKing
On Thu, Jun 23, 2011 at 6:53 AM, Naga K  wrote:

> i am new to android technology,till i struggle develop the android
> application,give me idea how to develop client -server android application .


Dude, if you're struggling to develop a regular android application, you're
not making a "client -server android application", whatever that even means.


> if you have any same application please send me.


Yeah, sure ... sit right there and I'll send you all da codz you need to
perfectly meet your needs.

-
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 Implement Drag And Drop for image views by extending View Group

2011-06-23 Thread TreKing
On Wed, Jun 22, 2011 at 10:57 PM, ram dharan  wrote:

> Hii all i m new to android,m developing an app which needs Drag and Drop if
> images by extending View Group Class.

Could any one plz tell how can i achieve this.any help is greatly
> appreciated.Thanks
>

http://tinyurl.com/6eqvtp9
http://www.catb.org/~esr/faqs/smart-questions.html

Do they not teach you how to spell "please" wherever you're from?

-
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: Generic resizable appwidgets in Android 3.1

2011-06-23 Thread Ed
Ahh yeah - forgot about our friend RemoteView :(

On Jun 24, 9:05 am, Mark Murphy  wrote:
> On Thu, Jun 23, 2011 at 6:28 PM, Ed  wrote:
> > Can you have a custom view inside the widget that is fill_parent and
> > do what you need to do in the onDraw?
>
> No. You cannot have custom Views in app widgets, period.
>
> --
> 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/smand1,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


Re: [android-developers] authentication of an app in facebook

2011-06-23 Thread TreKing
On Thu, Jun 23, 2011 at 5:11 AM, Anusha D  wrote:

> I am trying to authenticate an app on facebook


Questions regarding authenticating on Facebook should probably go to a forum
dedicated to developing for Facebook.

-
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] Please help me with this issue

2011-06-23 Thread TreKing
On Thu, Jun 23, 2011 at 2:49 PM, Jatin Salla wrote:

> But When I started the Emulator with this new AVD the app is not running
>

What does that mean, exactly?

-
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] Re: weird behaviour while overriding FrameLayout.dispatchDraw() on a view that contains a scrollview

2011-06-23 Thread Romain Guy
The drawing cache is per view, so if you need to capture several views
(sibling, and not a subtree like you are doing in your example) if
would be better to allocate a single bitmap. This works of course only
if all the views have the same size.

On Thu, Jun 23, 2011 at 5:06 PM, rukiman  wrote:
> I am suspecting using the view cache system causes the view system to
> allocate memory for the view.
> Now lets say I can to capture 3 views, does that mean memory is
> allocated for 3 views worth of caches if I don't destroy the cache?
>
> Also I noticed through profiling that this code runs around 100ms
> view.setDrawingCacheEnabled(true);
>        view.setDrawingCacheQuality(View.DRAWING_CACHE_QUALITY_HIGH);
>        view.setDrawingCacheBackgroundColor(Color.BLACK);
>        Bitmap bitmap = view.getDrawingCache();
>        Bitmap retVal = bitmap == null ? null :
> bitmap.copy(bitmap.getConfig(), false);
>        view.destroyDrawingCache();
>        view.setDrawingCacheEnabled(false);
>        return retVal;
>
> while this runs at around 60ms
> mCanvas.setBitmap(mBitmapCapture);
>   view.draw(mCanvas);
>   Bitmap retVal = mBitmapCapture;
>
> I have to capture a few views and trying to speed them as quick as
> possible and at the same time not use much memory. I guess the slight
> speed difference is in enabling and destroying the view drawing cache?
> What is the effect of not destroying it? Does that mean it will suffer
> from my approach above that is double the workload on each frame as
> well?
>
> Going back to my approach my code is just as I pasted it, should I be
> saving the canvas and restoring it in the dispatchDraw? Any help is
> appreciated. Thanks.
>
>
>
>
> On Jun 24, 9:47 am, Romain Guy  wrote:
>> It's either because you don't properly save/restore the state of your
>> offline Canvas or maybe because of the bitmap config (although it
>> should work just fine in 565.)
>>
>> What I don't understand however is why you refuse to use the drawing
>> cache API that already exists for this purpose? Using this API will
>> not necessarily force another redraw of the view. With the drawing
>> cache, the cache is automatically redrawn whenever the view changes.
>> Your approach however doubles the workload on *every* frame.
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> On Thu, Jun 23, 2011 at 4:23 PM, rukiman  wrote:
>> > I am trying to understand which this code which works perfectly for
>> > capturing almost any view except if there is a ScrollView in the
>> > framelayout, in this case there is a slight issue with the top and
>> > bottom areas where scrollview fades its contents. There is some
>> > corruption occurring.
>>
>> > public class FrameLayoutWithOfflineBitmap extends FrameLayout {
>>
>> >        private Bitmap mOfflineBitmap;
>> >        private Canvas mOfflineCanvas;
>>
>> >        public FrameLayoutWithOfflineBitmap(Context context) {
>> >                super(context);
>> >        }
>>
>> >        @Override
>> >        public void onSizeChanged(int w, int h, int oldw, int oldh) {
>> >                // just in case we already had the bitmap allocated before
>> >                if(mOfflineBitmap != null) {
>> >                        mOfflineBitmap.recycle();
>> >                }
>> >                mOfflineBitmap = Bitmap.createBitmap(w, h, 
>> > Bitmap.Config.RGB_565);
>> >                mOfflineCanvas = new Canvas();
>> >                mOfflineCanvas.setBitmap(mOfflineBitmap);
>> >        }
>>
>> >        @Override
>> >        public void dispatchDraw(Canvas canvas) {
>> >                // draw to our offline bitmap
>> >                super.dispatchDraw(mOfflineCanvas);
>> >                // now draw our offline bitmap to the system canvas
>> >                canvas.drawBitmap(mOfflineBitmap, 0, 0, null);
>> >        }
>>
>> >        public Bitmap getScreenSnapshot() {
>> >                return mOfflineBitmap;
>> >        }
>> > }
>>
>> > I understand there are other ways to capture the view such as using
>> > the View's drawing cache, but I am not interested in this method. Can
>> > someone explain to me what is going on here and if there is way to
>> > address this issue? Basically I am trying to get access to a snapshot
>> > of a view as quick as possible. My idea is that the view is already
>> > drawn onto the screen, we should be able to get access to this without
>> > having to force another redundant redraw of the view.
>>
>> > I am also very keen to understand the flaw with the above code in
>> > terms of the scrollview. 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
>>
>> --
>> Romain Guy
>> Android framework engineer
>> romain..

[android-developers] Re: weird behaviour while overriding FrameLayout.dispatchDraw() on a view that contains a scrollview

2011-06-23 Thread rukiman
Also its not technically double the work load, as I suspect the
children views take much longer to render themselves compared to
simply drawing a bitmap out to the screen.

On Jun 24, 9:47 am, Romain Guy  wrote:
> It's either because you don't properly save/restore the state of your
> offline Canvas or maybe because of the bitmap config (although it
> should work just fine in 565.)
>
> What I don't understand however is why you refuse to use the drawing
> cache API that already exists for this purpose? Using this API will
> not necessarily force another redraw of the view. With the drawing
> cache, the cache is automatically redrawn whenever the view changes.
> Your approach however doubles the workload on *every* frame.
>
>
>
>
>
>
>
>
>
> On Thu, Jun 23, 2011 at 4:23 PM, rukiman  wrote:
> > I am trying to understand which this code which works perfectly for
> > capturing almost any view except if there is a ScrollView in the
> > framelayout, in this case there is a slight issue with the top and
> > bottom areas where scrollview fades its contents. There is some
> > corruption occurring.
>
> > public class FrameLayoutWithOfflineBitmap extends FrameLayout {
>
> >        private Bitmap mOfflineBitmap;
> >        private Canvas mOfflineCanvas;
>
> >        public FrameLayoutWithOfflineBitmap(Context context) {
> >                super(context);
> >        }
>
> >        @Override
> >        public void onSizeChanged(int w, int h, int oldw, int oldh) {
> >                // just in case we already had the bitmap allocated before
> >                if(mOfflineBitmap != null) {
> >                        mOfflineBitmap.recycle();
> >                }
> >                mOfflineBitmap = Bitmap.createBitmap(w, h, 
> > Bitmap.Config.RGB_565);
> >                mOfflineCanvas = new Canvas();
> >                mOfflineCanvas.setBitmap(mOfflineBitmap);
> >        }
>
> >        @Override
> >        public void dispatchDraw(Canvas canvas) {
> >                // draw to our offline bitmap
> >                super.dispatchDraw(mOfflineCanvas);
> >                // now draw our offline bitmap to the system canvas
> >                canvas.drawBitmap(mOfflineBitmap, 0, 0, null);
> >        }
>
> >        public Bitmap getScreenSnapshot() {
> >                return mOfflineBitmap;
> >        }
> > }
>
> > I understand there are other ways to capture the view such as using
> > the View's drawing cache, but I am not interested in this method. Can
> > someone explain to me what is going on here and if there is way to
> > address this issue? Basically I am trying to get access to a snapshot
> > of a view as quick as possible. My idea is that the view is already
> > drawn onto the screen, we should be able to get access to this without
> > having to force another redundant redraw of the view.
>
> > I am also very keen to understand the flaw with the above code in
> > terms of the scrollview. 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
>
> --
> Romain Guy
> Android framework engineer
> romain...@android.com
>
> Note: please don't send private questions to me, as I don't have time
> to provide private support.  All such questions should be posted on
> public forums, where I and others can see and answer them

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


[android-developers] Re: weird behaviour while overriding FrameLayout.dispatchDraw() on a view that contains a scrollview

2011-06-23 Thread rukiman
I am suspecting using the view cache system causes the view system to
allocate memory for the view.
Now lets say I can to capture 3 views, does that mean memory is
allocated for 3 views worth of caches if I don't destroy the cache?

Also I noticed through profiling that this code runs around 100ms
view.setDrawingCacheEnabled(true);
view.setDrawingCacheQuality(View.DRAWING_CACHE_QUALITY_HIGH);
view.setDrawingCacheBackgroundColor(Color.BLACK);
Bitmap bitmap = view.getDrawingCache();
Bitmap retVal = bitmap == null ? null :
bitmap.copy(bitmap.getConfig(), false);
view.destroyDrawingCache();
view.setDrawingCacheEnabled(false);
return retVal;

while this runs at around 60ms
mCanvas.setBitmap(mBitmapCapture);
   view.draw(mCanvas);
   Bitmap retVal = mBitmapCapture;

I have to capture a few views and trying to speed them as quick as
possible and at the same time not use much memory. I guess the slight
speed difference is in enabling and destroying the view drawing cache?
What is the effect of not destroying it? Does that mean it will suffer
from my approach above that is double the workload on each frame as
well?

Going back to my approach my code is just as I pasted it, should I be
saving the canvas and restoring it in the dispatchDraw? Any help is
appreciated. Thanks.




On Jun 24, 9:47 am, Romain Guy  wrote:
> It's either because you don't properly save/restore the state of your
> offline Canvas or maybe because of the bitmap config (although it
> should work just fine in 565.)
>
> What I don't understand however is why you refuse to use the drawing
> cache API that already exists for this purpose? Using this API will
> not necessarily force another redraw of the view. With the drawing
> cache, the cache is automatically redrawn whenever the view changes.
> Your approach however doubles the workload on *every* frame.
>
>
>
>
>
>
>
>
>
> On Thu, Jun 23, 2011 at 4:23 PM, rukiman  wrote:
> > I am trying to understand which this code which works perfectly for
> > capturing almost any view except if there is a ScrollView in the
> > framelayout, in this case there is a slight issue with the top and
> > bottom areas where scrollview fades its contents. There is some
> > corruption occurring.
>
> > public class FrameLayoutWithOfflineBitmap extends FrameLayout {
>
> >        private Bitmap mOfflineBitmap;
> >        private Canvas mOfflineCanvas;
>
> >        public FrameLayoutWithOfflineBitmap(Context context) {
> >                super(context);
> >        }
>
> >        @Override
> >        public void onSizeChanged(int w, int h, int oldw, int oldh) {
> >                // just in case we already had the bitmap allocated before
> >                if(mOfflineBitmap != null) {
> >                        mOfflineBitmap.recycle();
> >                }
> >                mOfflineBitmap = Bitmap.createBitmap(w, h, 
> > Bitmap.Config.RGB_565);
> >                mOfflineCanvas = new Canvas();
> >                mOfflineCanvas.setBitmap(mOfflineBitmap);
> >        }
>
> >        @Override
> >        public void dispatchDraw(Canvas canvas) {
> >                // draw to our offline bitmap
> >                super.dispatchDraw(mOfflineCanvas);
> >                // now draw our offline bitmap to the system canvas
> >                canvas.drawBitmap(mOfflineBitmap, 0, 0, null);
> >        }
>
> >        public Bitmap getScreenSnapshot() {
> >                return mOfflineBitmap;
> >        }
> > }
>
> > I understand there are other ways to capture the view such as using
> > the View's drawing cache, but I am not interested in this method. Can
> > someone explain to me what is going on here and if there is way to
> > address this issue? Basically I am trying to get access to a snapshot
> > of a view as quick as possible. My idea is that the view is already
> > drawn onto the screen, we should be able to get access to this without
> > having to force another redundant redraw of the view.
>
> > I am also very keen to understand the flaw with the above code in
> > terms of the scrollview. 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
>
> --
> Romain Guy
> Android framework engineer
> romain...@android.com
>
> Note: please don't send private questions to me, as I don't have time
> to provide private support.  All such questions should be posted on
> public forums, where I and others can see and answer them

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

Re: [android-developers] Mapview can not be resolved to a type

2011-06-23 Thread Samson Akisanya
Check ur android properties of your project...it should be set to Google api
not 2.2 etc
On 23 Jun 2011 23:43, "juhi paunikar"  wrote:
> Hi,
> i tried the project which is given belows link:
> http://developer.android.com/resources/tutorials/views/hello-mapview.html
>
> i am getting error as given below:
> Mapview can not be resolved to a type.
>
> Can anybody give me suggestion to solve this 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

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] weird behaviour while overriding FrameLayout.dispatchDraw() on a view that contains a scrollview

2011-06-23 Thread Romain Guy
It's either because you don't properly save/restore the state of your
offline Canvas or maybe because of the bitmap config (although it
should work just fine in 565.)

What I don't understand however is why you refuse to use the drawing
cache API that already exists for this purpose? Using this API will
not necessarily force another redraw of the view. With the drawing
cache, the cache is automatically redrawn whenever the view changes.
Your approach however doubles the workload on *every* frame.

On Thu, Jun 23, 2011 at 4:23 PM, rukiman  wrote:
> I am trying to understand which this code which works perfectly for
> capturing almost any view except if there is a ScrollView in the
> framelayout, in this case there is a slight issue with the top and
> bottom areas where scrollview fades its contents. There is some
> corruption occurring.
>
> public class FrameLayoutWithOfflineBitmap extends FrameLayout {
>
>        private Bitmap mOfflineBitmap;
>        private Canvas mOfflineCanvas;
>
>        public FrameLayoutWithOfflineBitmap(Context context) {
>                super(context);
>        }
>
>        @Override
>        public void onSizeChanged(int w, int h, int oldw, int oldh) {
>                // just in case we already had the bitmap allocated before
>                if(mOfflineBitmap != null) {
>                        mOfflineBitmap.recycle();
>                }
>                mOfflineBitmap = Bitmap.createBitmap(w, h, 
> Bitmap.Config.RGB_565);
>                mOfflineCanvas = new Canvas();
>                mOfflineCanvas.setBitmap(mOfflineBitmap);
>        }
>
>        @Override
>        public void dispatchDraw(Canvas canvas) {
>                // draw to our offline bitmap
>                super.dispatchDraw(mOfflineCanvas);
>                // now draw our offline bitmap to the system canvas
>                canvas.drawBitmap(mOfflineBitmap, 0, 0, null);
>        }
>
>        public Bitmap getScreenSnapshot() {
>                return mOfflineBitmap;
>        }
> }
>
> I understand there are other ways to capture the view such as using
> the View's drawing cache, but I am not interested in this method. Can
> someone explain to me what is going on here and if there is way to
> address this issue? Basically I am trying to get access to a snapshot
> of a view as quick as possible. My idea is that the view is already
> drawn onto the screen, we should be able to get access to this without
> having to force another redundant redraw of the view.
>
> I am also very keen to understand the flaw with the above code in
> terms of the scrollview. 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
>



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

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

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


[android-developers] Re: circular rotating and vertically aligned Image switcher

2011-06-23 Thread Indicator Veritatis
Well thanks a lot, ZZsolt! Now, as Android slowly takes over the
mobile world and generations of programmers search Google to find this
post, they will curse your name for wasting their time with your
childish sarcasm. "Juicy Fruit" indeed! You should be allowed to use
only the Durian version instead;)

On Jun 23, 12:36 am, Zsolt Vasvari  wrote:
> Darn, I think those methods may have been added in Android 5.0 Juicy-
> Fruit.  Sorry.
>
> On Jun 23, 3:32 pm, Sapna Srivastav  wrote:> There is 
> no such methods that you told to use in my code.
>
> > On Jun 23, 12:23 pm, Zsolt Vasvari  wrote:
>
> > > myImageSwitcher.setVerticalAlign(true);
> > > myImageSwitcher.setCircularRotatory(true);
>
> > > On Jun 23, 2:39 pm, Sapna Srivastav  wrote:
>
> > > > Hi all
>
> > > > Would you tell me how can I make an image switcher vertical align and
> > > > circular rotatory.
>
> > > > Thanks and regards
> > > > Sapna Srivastav- Hide quoted text -
>
> > - Show quoted text -

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


[android-developers] Re: Full screen on HTC sensation (qHD)

2011-06-23 Thread RichardC
Just confirming what Chris said.  On my Sensation - my apps, test apps
and downloads from the market all fill the expected area of the
screen.

On Jun 24, 12:04 am, Chris  wrote:
> I don't have a solution to your problem, but I just got a Sensation and my
> app which uses a scrollview as its root with fill_parent uses all available
> screen real estate.  So there has to be something in your layout limiting
> 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] weird behaviour while overriding FrameLayout.dispatchDraw() on a view that contains a scrollview

2011-06-23 Thread rukiman
I am trying to understand which this code which works perfectly for
capturing almost any view except if there is a ScrollView in the
framelayout, in this case there is a slight issue with the top and
bottom areas where scrollview fades its contents. There is some
corruption occurring.

public class FrameLayoutWithOfflineBitmap extends FrameLayout {

private Bitmap mOfflineBitmap;
private Canvas mOfflineCanvas;

public FrameLayoutWithOfflineBitmap(Context context) {
super(context);
}

@Override
public void onSizeChanged(int w, int h, int oldw, int oldh) {
// just in case we already had the bitmap allocated before
if(mOfflineBitmap != null) {
mOfflineBitmap.recycle();
}
mOfflineBitmap = Bitmap.createBitmap(w, h, 
Bitmap.Config.RGB_565);
mOfflineCanvas = new Canvas();
mOfflineCanvas.setBitmap(mOfflineBitmap);
}

@Override
public void dispatchDraw(Canvas canvas) {
// draw to our offline bitmap
super.dispatchDraw(mOfflineCanvas);
// now draw our offline bitmap to the system canvas
canvas.drawBitmap(mOfflineBitmap, 0, 0, null);
}

public Bitmap getScreenSnapshot() {
return mOfflineBitmap;
}
}

I understand there are other ways to capture the view such as using
the View's drawing cache, but I am not interested in this method. Can
someone explain to me what is going on here and if there is way to
address this issue? Basically I am trying to get access to a snapshot
of a view as quick as possible. My idea is that the view is already
drawn onto the screen, we should be able to get access to this without
having to force another redundant redraw of the view.

I am also very keen to understand the flaw with the above code in
terms of the scrollview. 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: update spinner

2011-06-23 Thread TreKing
On Thu, Jun 23, 2011 at 6:03 PM, Indicator Veritatis wrote:

> Well now, TreKing, I have read the documentation on both, and I still don't
> consider the answer obvious.
>

OP asked "How can i update my spinner with the last value i have choise,
using shared preference??"

Taking the question at face value, this implies to me A) getting and setting
the value from / to a Spinner, which you can do with obviously named methods
and B) getting and setting this value from / to a SharedPreference, which
you can also do with equally obviously named methods.

The details of a full working scenario are, of course, a bit more involved
but given the question, the answer is readily obtained by a good perusal of
the docs, IMHO.


> Not even after also noticing from the Spinner Tutorial that he should use
> an Adapter too, most likely SpinnerAdapter. Even what seems 'obvious' after
> reading all that just looks and feels wrong, "object disoriented".
>

OK - seems beyond the scope of the question posed though.


> Especially since the Android word 'Adapter' is not very closely related to
> the Adapter Pattern its name so strongly suggests.
>

An Android Adapter provides the interface by which a user-defined object can
be used and represented in Android's system. It "adapts" your object to
Android's way of displaying data. Seems aptly named to me.

-
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] Re: ANR in process

2011-06-23 Thread TreKing
On Thu, Jun 23, 2011 at 5:58 PM, Indicator Veritatis wrote:

> It always helps to give an explicit example of a Google query he could
> have used to answer his question. I found the answer in the top item
> listed after searching google with "android developer anr", which is
> titled "Design for responsiveness"
>

Huh? Where does the link I posted take you, if not the exact page you just
described?

-
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] NDK build/awk/extract-debuggable.awk fails on Windows line endings

2011-06-23 Thread Mark Murphy
You will have better luck with NDK issues if you discuss them on the
[android-ndk] Google Group.

On Thu, Jun 23, 2011 at 2:13 AM, Jonathan McCaffrey
 wrote:
> When run on an Android manifest with Windows line endings from a Linux
> shell, extract-debuggable.awk fails on the first XML attribute, at
> this panic:
>
>            if ( _xml_attrib !~ /^[a-z][-+_0-9a-z:]*$/ ) # validate it
>                _xml_panic("Invalid attribute name: " _xml_attrib);
>
> Changing the line endings to Unix solves the 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
>



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


Re: [android-developers] Re: Generic resizable appwidgets in Android 3.1

2011-06-23 Thread Mark Murphy
On Thu, Jun 23, 2011 at 6:28 PM, Ed  wrote:
> Can you have a custom view inside the widget that is fill_parent and
> do what you need to do in the onDraw?

No. You cannot have custom Views in app widgets, period.

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


Re: [android-developers] AppWidget update question

2011-06-23 Thread Mark Murphy
On Thu, Jun 23, 2011 at 10:48 AM, mexibec  wrote:
> Folks, I got an AppWidget working great, but I need it to be updated
> whenever it is visible. It doesn't need to be refreshed if the user is
> not looking at it. For instance, if the device is sleeping, or if it
> sits on a home screen that the user is not looking at, then it needs
> no update. But the second it becomes visible, it needs to be updated,
> and then periodically every minute, until it's no longer visible, at
> which point it doesn't need any update, and so on.
>
> Setting an intent SCREEN_ION does not work. I don't want to sleep an
> alarm when it's not visible (especially not every minute!) Any idea
> about how I can achieve this?

Update it every minute, regardless of whether it is visible. Use
AlarmManager and a non-WAKEUP alarm instead of
android:updatePeriodMillis if you do not want to wake up the phone.
Ideally, you would allow the user to configure the update interval --
while you may think every minute is a fine answer, users may disagree.

> FYI, back in the Pocket PC/Windows Mobile era, the Today screen plug-
> ins had those features i.e. the plug-ins would be notified when
> visible, and periodically afterwards. This is what I'm looking for
> because that perfectly fits my apps requirements.

This is not possible, sorry.

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


[android-developers] Re: Full screen on HTC sensation (qHD)

2011-06-23 Thread Chris
I don't have a solution to your problem, but I just got a Sensation and my 
app which uses a scrollview as its root with fill_parent uses all available 
screen real estate.  So there has to be something in your layout limiting 
it.

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

[android-developers] Re: update spinner

2011-06-23 Thread Indicator Veritatis
Well now, TreKing, I have read the documentation on both, and I still
don't consider the answer obvious. Not even after also noticing from
the Spinner Tutorial that he should use an Adapter too, most likely
SpinnerAdapter. Even what seems 'obvious' after reading all that just
looks and feels wrong, "object disoriented". Especially since the
Android word 'Adapter' is not very closely related to the Adapter
Pattern its name so strongly suggests.

On Jun 23, 8:29 am, TreKing  wrote:
> On Thu, Jun 23, 2011 at 4:26 AM, souissi haythem wrote:
>
> > How can i update my spinner with the last value i have choise, using shared
> > preference??
>
> Read the documentation for both Spinner and SharePreferences and use the
> functions provided on each to do what you seek.
>
> -
> 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] Re: Android Market Developer Console not updating

2011-06-23 Thread TreKing
On Thu, Jun 23, 2011 at 8:43 AM, cranktheory.apps <
cranktheory.a...@googlemail.com> wrote:

> My statistics didn't update the last two weeks, too (Using Andlytics,
> too). Only active installs increase sometimes, but total downloads
> haven't changed since then. This is really bugging me.
>

At some point you will come to terms with the Market, then it will not
bother you anymore once you accept that this is how things are.

-
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] Mapview can not be resolved to a type

2011-06-23 Thread Mark Murphy
Change your build target to one that has Google Maps. In Eclipse, this
is in the Android portion of project properties. For command-line
builds, this is in default.properties.

On Thu, Jun 23, 2011 at 8:18 AM, juhi paunikar  wrote:
> Hi,
> i tried the project which is given belows link:
> http://developer.android.com/resources/tutorials/views/hello-mapview.html
>
> i am getting error as given below:
> Mapview can not be resolved to a type.
>
> Can anybody give me suggestion to solve this 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
>



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


Re: [android-developers] I want to develope android NFC read/write application

2011-06-23 Thread Mark Murphy
On Thu, Jun 23, 2011 at 6:30 AM, Adiga  wrote:
>     I want to develop NFC read/write application. Can anyone help
> me

http://developer.android.com/guide/topics/nfc/index.html
https://github.com/commonsguy/cw-advandroid/tree/master/NFC/URLTagger

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


Re: [android-developers] filling form when a app is installed

2011-06-23 Thread Mark Murphy
On Thu, Jun 23, 2011 at 7:35 AM, JK Park  wrote:
> I am trying to build up a program that managing android on web server.
>
> So when a customer is installing my app, I want to show a form and
> then send a filled form to server.
> the form is basic information such as name, address and job.
>
> Can anyone tell me how to show a form when a app is installing?

This is not possible. Please collect this information on the first run
of the application, when the user launches it from the home screen
launcher.

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


[android-developers] Re: ANR in process

2011-06-23 Thread Indicator Veritatis
It always helps to give an explicit example of a Google query he could
have used to answer his question. I found the answer in the top item
listed after searching google with "android developer anr", which is
titled "Design for responsiveness" and says:

"Generally, the system displays an ANR if an application cannot
respond to user input. ... In both of these cases, the recommended
approach is to create a child thread and do most of your work there."

It is almost certain that that is the right answer for his problem. If
not, then he should still read the rest of the article -- as well as
look for what platform methods he might be using that are running on
the main UI thread when they should not be...


On Jun 23, 8:39 am, TreKing  wrote:
> On Thu, Jun 23, 2011 at 7:01 AM, Sapna Srivastav 
> wrote:
>
> > Please tell me in which condition an application goes in ANR state and how
> > can I avoid this state?
>
> Please check the documentation for stuff like 
> this.http://developer.android.com/guide/practices/design/responsiveness.html
>
> -
> 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 add Third party Pre-Compiled Shared Libraries

2011-06-23 Thread Mark Murphy
http://developer.android.com/sdk/ndk/index.html

On Thu, Jun 23, 2011 at 1:16 AM, arun kumar  wrote:
> what is meant by ndk
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, send email to
> android-developers+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en



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

Android Training in London: http://bit.ly/smand1, 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


[android-developers] Re: Join us for "Android Programming June 23rd, 2011 Webinar - "Testing""

2011-06-23 Thread Indicator Veritatis
Please don't niggle, Mr. Niggle;)

Most likely the reason is that the software for connecting you to the
Webinar only runs on Windows or Mac OS, NOT because they really have
anything against developing for Android under Linux (I use Fedora, not
Ubuntu, with few complaints).

On Jun 23, 9:35 am, Fred Niggle  wrote:
> Why no Ubuntu?
> From what I know more Developers are using Ubuntu (linux) to develop
> for Android (linux)...
>
> On 23/06/2011, Sang Shin  wrote:
>
> > Android Programming June 23rd, 2011 Webinar - "Testing"
>
> > Join us for a Webinar on June 23
>
> > 
>
> > *Space is limited.*
> > Reserve your Webinar seat now at:
> >https://www3.gotomeeting.com/register/385540934
>
> > In this Webinar, we are going to cover "Testing"
>
> > *Title:*   Android Programming June 23rd, 2011 Webinar - "Testing"
> > *Date:*    Thursday, June 23, 2011
> > *Time:*    5:00 PM - 6:00 PM EDT
>
> > After registering you will receive a confirmation email containing
> > information about joining the Webinar.
>
> > *System Requirements*
> > PC-based attendees
> > Required: Windows® 7, Vista, XP or 2003 Server
>
> > Macintosh®-based attendees
> > Required: Mac OS® X 10.4.11 (Tiger®) or newer
>
> > --
> > ---
> >               Sang Shin, sangshinpass...@gmail.com
> >            Founder and Chief Instructor of JavaPassion.com
> >http://javapassion.com/portal/instructors/sang-shin-schedule(Bio)
> >          http://www.linkedin.com/in/javapassion(Linkedin)
> >                      @javapassion (Tweeter)
> >              Life is worth living... with Passion!
> > --
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to android-developers@googlegroups.com
> > To unsubscribe from this group, 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: Orientation change action

2011-06-23 Thread Oleg V
I've actually been looking for a solution to this quandary for some time. 
The quickest is just to add this property to each activity tag in your 
AndroidManifest.xml file:

*android*:configChanges="keyboardHidden|*orientation*"


However, this won't keep your task/download working if, say, the user takes 
a call or presses the home key. However, although the official documentation 
advises against using this method, it is actually used in the messaging 
application.

Anyways, you probably want a more robust method. To do this, you can either:

   1. Create a service and work with downloads in there, and communicate 
   with your UI activity if it exists. This approach is better if you have some 
   sort of download manager or feed updater that must work in the background
   2. Work in AsyncTask, which is better for shorter tasks (if you want to 
   quickly fetch a file, parse it, and update the user interface). There are a 
   few techniques here. You can pass references to your task when the activity 
   is destroyed between orientation changes 
   with onRetainNonConfigurationInstance(). Or, you can hold the reference to 
   your task by holding it in the Application object, accessible to all 
   activities. Have a look at 
   
http://www.fattybeagle.com/2011/02/15/android-asynctasks-during-a-screen-rotation-part-ii/
 for 
   code (and read Part I where the author goes over the other possibilities)
   
Hope this helps!

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

[android-developers] Please help me with this issue

2011-06-23 Thread Jatin Salla
I am new to Android and have almost completed developing the Mobile
app which consumes the REST service and also uses Google API for this
app.
This application is developed in Android Version 2.3.3 API level 10
(Google API (Google Inc.) - API level 10).

I thought of checking the backward compatibility of the app I created,
hence changed the AVD (also tried creating new AVD) to point to
Android version 2.1.1(Google API (Google Inc.) - API Level 7).

But When I started the Emulator with this new AVD the app is not
running and I check the logcat and getting following issue in the
logcat

06-23 18:43:47.703: ERROR/gralloc(58): [unregister] handle 0x38ce00
still locked (state=4001)
06-23 18:44:06.774: ERROR/Launcher(111): Launcher does not have the
permission to launch Intent { act=android.intent.action.MAIN
cat=[android.intent.category.LAUNCHER] flg=0x1020
cmp=com.test/.Login }. Make sure to create a MAIN intent-filter for
the corresponding activity or use the exported attribute for this
activity.
06-23 18:44:06.774: ERROR/Launcher(111): java.lang.SecurityException:
Permission Denial: starting Intent { act=android.intent.action.MAIN
cat=[android.intent.category.LAUNCHER] flg=0x1020
cmp=com.test/.Login } from ProcessRecord{44d4d040
111:android.process.acore/10001} (pid=111, uid=10001) requires null
06-23 18:44:06.774: ERROR/Launcher(111): at
android.os.Parcel.readException(Parcel.java:1218)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.os.Parcel.readException(Parcel.java:1206)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.app.ActivityManagerProxy.startActivity(ActivityManagerNative.java:
1214)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.app.Instrumentation.execStartActivity(Instrumentation.java:
1373)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.app.Activity.startActivityForResult(Activity.java:2749)
06-23 18:44:06.774: ERROR/Launcher(111): at
com.android.launcher.Launcher.startActivityForResult(Launcher.java:
969)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.app.Activity.startActivity(Activity.java:2855)
06-23 18:44:06.774: ERROR/Launcher(111): at
com.android.launcher.Launcher.startActivitySafely(Launcher.java:1657)
06-23 18:44:06.774: ERROR/Launcher(111): at
com.android.launcher.AllAppsGridView.onItemClick(AllAppsGridView.java:
103)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.widget.AdapterView.performItemClick(AdapterView.java:284)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.widget.AbsListView$PerformClick.run(AbsListView.java:1640)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.os.Handler.handleCallback(Handler.java:587)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.os.Handler.dispatchMessage(Handler.java:92)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.os.Looper.loop(Looper.java:123)
06-23 18:44:06.774: ERROR/Launcher(111): at
android.app.ActivityThread.main(ActivityThread.java:4363)
06-23 18:44:06.774: ERROR/Launcher(111): at
java.lang.reflect.Method.invokeNative(Native Method)
06-23 18:44:06.774: ERROR/Launcher(111): at
java.lang.reflect.Method.invoke(Method.java:521)
06-23 18:44:06.774: ERROR/Launcher(111): at
com.android.internal.os.ZygoteInit
$MethodAndArgsCaller.run(ZygoteInit.java:860)
06-23 18:44:06.774: ERROR/Launcher(111): at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
06-23 18:44:06.774: ERROR/Launcher(111): at
dalvik.system.NativeStart.main(Native Method)


I tried searching through all the blogs but could not find a valid
answer to it.

My manifest file looks like this

http://schemas.android.com/apk/res/android";
  package="com.test"
  android:versionCode="1"
  android:versionName="1.0">
  

 










android:name="com.test.GlobalState"























Can anyone PLEASE help me, I have to release this app within a month
time. I am really frustrated with this.

Please help. Really appreciate a quick response. THANKS in advance
for reading .

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


[android-developers] when will you start fixing earlier mentioned vpn issues with l2tp for example

2011-06-23 Thread evils0n
instead of coming with 100 new features that are buggy why cant you
start fixing in problems with ipsec/vpn for example. Lots of people
having issues with this and there is no work around unless you
constantly using the mobilenetwork if you shall connect over vpn by
using l2tp (psk) dream on if you want to do this over wifi and natted
networks. Or you getting money from the mobileoperators for this?
Frankly this is a "bug" that been since 2.1 when i started to use my
htc hero atleast it have never worked as it supposed to do.

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


[android-developers] Re: Android Market Developer Console not updating

2011-06-23 Thread cranktheory.apps
My statistics didn't update the last two weeks, too (Using Andlytics,
too). Only active installs increase sometimes, but total downloads
haven't changed since then. This is really bugging me.

On 20 Jun., 08:51, Nikolay Elenkov  wrote:
> On Mon, Jun 20, 2011 at 3:47 PM, Yenchi  wrote:
> > I keep a spreadsheet which I update everyday, and I do observe that on
> > some
> > of my less popular apps the install count freezes for a week while
> > active
> > install count do get updated everyday regardless of popularity...
>
> There's an app for that :) I use Andlytics and have been seeing this
> for some time now.
>
> https://market.android.com/details?id=de.betaapps.andlytics

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


[android-developers] MASTERION.COM social application network available

2011-06-23 Thread Iván Martínez
Hello everybody, I hope this is not regarded as spam, as it is the
announcement of a useful development resource.

I'm proud to announce the availability of MASTERION, a messaging
server aimed to serve social applications (such as games). MASTERION
differs from similar networks in the use of the XMPP protocol, making
it available to any application regardless its implementation
language, operating system or hardware. It differs from other XMPP
servers in its plans to implement specific features for social
applications (for example, scoreboards).

There are plenty of libraries that help implementing XMPP clients.
Check http://xmpp.org/ for more info about the protocol. Check
http://masterion.com for more info about MASTERION.

I'm posting this announcement in many places and unfortunately I can't
follow the discussion everywhere. If you have any question, please get
a MASTERION developer account as described in 
http://masterion.com/developers/about-masterion
and post it in http://masterion.com/forum, or write to the Development
Support address in http://masterion.com/contact

Thank you for your attention, I'm looking forward for your feedback.

Ivan Martinez

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


[android-developers] BlueZ version in Android Honeycomb

2011-06-23 Thread Thomas G.
Hello,

I'd like to know a way to know the version of BlueZ (the bluetooth
stack) implemented in Android Honeycomb, without having the source
code of Honeycomb. I am pretty interested in the HDP functionalities
offered by the last versions of this stack.
Also, I heard that it is not recommended to use bluetooth
functionalities by another way than through the Java API, is this
true? Can't we use the embedded libbluetooth.so without trouble?

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] Re: circular rotating and vertically aligned Image switcher

2011-06-23 Thread hunny jain
There is no methods like setvertcalalign and aetvertical scrol
On 23-Jun-2011 12:53 PM, "Zsolt Vasvari"  wrote:
> myImageSwitcher.setVerticalAlign(true);
> myImageSwitcher.setCircularRotatory(true);
>
>
>
> On Jun 23, 2:39 pm, Sapna Srivastav  wrote:
>> Hi all
>>
>> Would you tell me how can I make an image switcher vertical align and
>> circular rotatory.
>>
>> Thanks and regards
>> Sapna Srivastav
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to android-developers@googlegroups.com
> To unsubscribe from this group, 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: circular rotating and vertically aligned Image switcher

2011-06-23 Thread hunny.jain1986
Hi sapna ,
How are u? For this u have to create custum image swither and for
rotating images u have to used canvas.

On Jun 22, 11:39 pm, Sapna Srivastav  wrote:
> Hi all
>
> Would you tell me how can I make an image switcher vertical align and
> circular rotatory.
>
> Thanks and regardsSapnaSrivastav

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


[android-developers] Re: When to close db connection on android?

2011-06-23 Thread Michael Kuethe
Hi Jay,
no you just have to call the closing mechanism once. Normally during
the onDestroy() event of last Activity that remains on the system.
This is normally the launcher Activity.

@Override
protected void onDestroy() {
Log.d(TAG, "onDestroy fired!");
dbhelper.close();
super.onDestroy();
}


regards

Michael


On Jun 21, 11:29 am, Jay XU  wrote:
> Hi,
>
> I am new to Android and I am looking at the Notepad Tutorial sample code
> now. In the NotesDbAdapter class, it defines a close() method to close the
> DatabaseHelper. However I cannot find this method get called anywhere.
>
> So my question is when shall we close the DB connection. I suppose we should
> call it in the onDestroy() mehod of each Activity class. Or will Android
> framework will take care of this so we don't have to worry about it?
>
> Please advise. thanks.
>
> -Jay

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


Re: [android-developers] Can anyone help me please for: Android's Weather and News app Genie Widget.

2011-06-23 Thread arun kumar
send me the code

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

2011-06-23 Thread arun kumar
what is meant by ndk

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

[android-developers] Re: Problem with getting GPS data when using Camera

2011-06-23 Thread b.rye
Have you come across a solution to this? I've recently seen this problem.

I've tested on two phones, and the issue only exists on one of the phones. 
I'm curious about the specs of the phone you've tried, in an attempt to 
narrow down the cause.

It works as expected on a Motorola Droid 2 running Android 2.2.

It does NOT work as expected on an HTC Inspire running Android 2.2.1.

Which phone(s) have you tried, and what OS version is running?

Thanks!

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

[android-developers] How to "select" and highlight an area of an image in Android Application?

2011-06-23 Thread AndreaNobili
Hello,
I have to do the following thing:

My Android application have to show an image (for example the human
body), the user can touch some specific part of this image (for
example the head or the stomach) and this part have to be highlight in
some way (for example by displaying a red circle with a radius in the
area, possibly the red circle have to be semi-transparent)

So, do you have some ideas to do something like this?

Reading this tutorial I thought that Canvas could be a solution but I
don't know because I am quite new in Android development and I never
used Canvas before: 
http://www.anddev.org/the_pizza_timer_-_threading-drawing_on_canvas-t126.html

Thank you
Andrea

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


[android-developers] Full screen on HTC sensation (qHD)

2011-06-23 Thread GekkeHenkie
Hi,

I'm creating my first android app, which I derived from the
BluetoothChat example.

However, on my phone (HTC sensation with qHD resolution, 540 bij 960
pixels) the lowest inch of the screen and a few lines at the sides are
not used by the app. See these images:

http://dl.dropbox.com/u/16350275/android/withoutmenu.png
http://dl.dropbox.com/u/16350275/android/withmenu.png

The layout-items are set to fill_parent so I expected something like
this (scaled, but set at right resolution in eclipse):
http://dl.dropbox.com/u/16350275/android/eclipse.png

Has anybody an idea where I should look to fix this? So far I didn't
find any reference in the projectfiles to the screenresolution.

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


[android-developers] inserting image in list view from url

2011-06-23 Thread varsha
i am using webservice to list detail about local business directory,
here i cant list image from url ,but i got image url which  comes from
web service, now my query is how to list image in list view with
rating bar dynamically from web service.
package xml.parse;



import java.io.InputStream;
import java.net.URL;
import java.util.ArrayList;
import java.util.HashMap;


import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.w3c.dom.NodeList;



import android.app.ListActivity;
import android.content.Context;
import android.content.Intent;
import android.graphics.drawable.Drawable;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.AdapterView;
import android.widget.AdapterView.OnItemClickListener;
import android.widget.BaseAdapter;
import android.widget.Button;
import android.widget.ImageView;
import android.widget.ListAdapter;
import android.widget.ListView;
import android.widget.SimpleAdapter;
import android.widget.TextView;
import android.widget.Toast;

public class Main extends ListActivity {
protected static final int ACTIVITY_CREATE = 0;
private ArrayList > myBooks;
private static final String BOOKKEY ="lastname";
private static final String PRICEKEY = "city";
private static final String Photo = "photo";
String k;
Drawable drawable;
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.listplaceholder);
ListView listView = (ListView)findViewById(R.id.list);
myBooks = new ArrayList>();
HashMap hm = null;


String xml = XMLfunctions.getXML("http://122.165.58.219/demo/
finddentist/listdentist.php");
Document doc = XMLfunctions.XMLfromString(xml);

int numResults = XMLfunctions.numResults(doc);

if((numResults <= 0)){
Toast.makeText(Main.this, "No result found",
Toast.LENGTH_LONG).show();
finish();
}

NodeList nodes = doc.getElementsByTagName("record");

for (int i = 0; i < nodes.getLength(); i++) {
  hm = new HashMap();

Element e = (Element)nodes.item(i);
hm.put(BOOKKEY, XMLfunctions.getValue(e, 
"lastname"));
hm.put(PRICEKEY, XMLfunctions.getValue(e,"city"));
hm.put(Photo, XMLfunctions.getValue(e,"photo"));
  myBooks.add(hm);
  url=(String) hm.get(Photo);
  Toast.makeText(Main.this,k, Toast.LENGTH_LONG).show();

Drawable drawable = LoadImageFromWebOperations(url);
imgView.setImageDrawable(drawable);
  listView.setAdapter(new myListAdapter(myBooks,this));
  listView.setChoiceMode(ListView.CHOICE_MODE_SINGLE);
}
}



class myListAdapter extends BaseAdapter{

private ArrayList> Books;
private LayoutInflater mInflater;


public myListAdapter(ArrayList> books,
Context context){


Books = books;
mInflater = LayoutInflater.from(context);
}


@Override
public int getCount() {
// TODO Auto-generated method stub
return Books.size();
}

@Override
public Object getItem(int position) {
// TODO Auto-generated method stub
return Books.get(position);
}

@Override
public long getItemId(int position) {
// TODO Auto-generated method stub
return position;
}

@Override
public View getView(int position, View convertView, ViewGroup
parent) {
// TODO Auto-generated method stub
// A ViewHolder keeps references to children views to 
avoid
unneccessary calls
// to findViewById() on each row.
ViewHolder holder;

// When convertView is not null, we can reuse it 
directly, there is
no need
// to reinflate it. We only inflate a new View when the
convertView supplied
// by ListView is null
 if (convertView == null) {
 convertView = mInflater.inflate(R.layout.listbox, null);
 // Creates a ViewHolder and store references to the two
children views
 // we want to bind data to.
 holder = new ViewHolder();
 holder.v = (TextView)
convertView.findViewById(R.id.text1);
 holder.v1 = (Te

[android-developers] Error"Thread detached"

2011-06-23 Thread saurabh kulkarni
I am getting error in execution of following as "Detached Thread"

*HomeAct.java*
package com.zensar.app;

import java.util.ArrayList;

import android.app.Activity;
import android.content.ContentValues;
import android.database.Cursor;
import android.database.sqlite.SQLiteDatabase;
import android.os.Bundle;
import android.util.Log;
import android.widget.ArrayAdapter;
import android.widget.ListView;
import android.widget.Toast;

public class HomeAct extends Activity {
int ver = 1;
SQLiteDatabase db;
 ListView list;
/** Called when the activity is first created. */
@Override

public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);

init();
loadDataToList();
}

private void loadDataToList() {
// TODO Auto-generated method stub
//DBhelper dbhelper;

//   dbhelper = new DBhelper(this, "MyDb", null, ver);

 db = dbhelper.getReadableDatabase();

 String columns[] = new String[] {"name", "date","etype"};
 Cursor cur = db.query("tbl_event", columns, null, null, null,
null,
"date");

 if( cur == null )
{
Toast.makeText(context, "no rows found",
Toast.LENGTH_SHORT).show();
}
else {
ArrayList arrlist = new ArrayList();
for( int i = 1; i <= cur.getCount(); i++ ) {
cur.moveToNext();
String str = cur.getString(1) + " " +
cur.getInt(0);

arrlist.add(str);
}

ArrayAdapter adapter = new
ArrayAdapter(getApplicationContext(),
android.R.layout.simple_list_item_single_choice, arrlist);
list.setAdapter(adapter);

}
 cur.close();
}

private void init() {
// TODO Auto-generated method stub
DBhelper dbhelper= new DBhelper(this, "MyDb", null, ver);

 SQLiteDatabase db = dbhelper.getWritableDatabase();

  ContentValues val = new ContentValues();
val.put("SK", "10/2/90");
long num = db.insert("tb1_event",null, val);
Log.e("num", num+"");
db.close();

Toast.makeText(this, "Inserted row",
Toast.LENGTH_LONG).show();

}

}

*DBhelper.java*

package com.zensar.app;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;
import android.database.sqlite.SQLiteDatabase.CursorFactory;
import android.widget.Toast;

public class DBhelper extends SQLiteOpenHelper
{

Context context;

public DBhelper(Context context, String name, CursorFactory
factory,
int version) {
super(context, name, factory, version);
this.context=context;
// TODO Auto-generated constructor stub
}

@Override
public void onCreate(SQLiteDatabase db) {

// TODO Auto-generated method stub

final String CREATE_TABLE_EVENT_INFO =
"CREATE TABLE tbl_event ("
+ "id INTEGER PRIMARY KEY AUTOINCREMENT,"
+ "name TEXT NOT NULL,"
+ "date DATE NOT NULL,"
+ "etype TEXT);";

final String CREATE_TABLE_EMAIL_INFO =
"CREATE TABLE tb2_email ("
+ "id INTEGER REFERENCES tb1_event(id),"
+ "email TEXT NOT NULL);";

db.execSQL(CREATE_TABLE_EVENT_INFO);

db.execSQL(CREATE_TABLE_EMAIL_INFO);

Toast.makeText( context ,  "created...",
Toast.LENGTH_SHORT).show();
}

@Override
public void onUpgrade(SQLiteDatabase db, int oldVersion, int
newVersion)
{
// TODO Auto-generated method stub
Toast.makeText( context,  "upgraded..." + oldVersion +" " +
newVersion, Toast.LENGTH_SHORT).show();
}

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


[android-developers] Fragment compatibility package + Android library project + running on API 11+ + DialogFragment in an Activity.

2011-06-23 Thread Nathan Ramsey
~@Dianne:

The preface:

I'm working on an Android Library Project that wants to use Fragments
and support older API levels, so we're using the Android Compatibility
Library.

I have a UI chunk which is a subclass of
android.support.v4.app.DialogFragment.  When running on devices with
SCREENLAYOUT_SIZE_NORMAL or SCREENLAYOUT_SIZE_SMALL our library
launches a new android.support.v4.app.FragmentActivity which displays
the DialogFragment in its embedded mode. All good so far.

The problem:

I also want to be able to display that DialogFragment in its dialog
mode when running on API 11+. (This is why we're using fragments.)
Since I'm working from within a library project, I do not have control
over the host activity's base class, so it may likely be extended from
Activity, not from FragmentActivity.

Is there a way to display my android.support.v4.app.DialogFragment on
API 11+ inside of a subclass of Activity, not FragmentActivity?

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


[android-developers] AppWidget update question

2011-06-23 Thread mexibec
Folks, I got an AppWidget working great, but I need it to be updated
whenever it is visible. It doesn't need to be refreshed if the user is
not looking at it. For instance, if the device is sleeping, or if it
sits on a home screen that the user is not looking at, then it needs
no update. But the second it becomes visible, it needs to be updated,
and then periodically every minute, until it's no longer visible, at
which point it doesn't need any update, and so on.

Setting an intent SCREEN_ION does not work. I don't want to sleep an
alarm when it's not visible (especially not every minute!) Any idea
about how I can achieve this?

FYI, back in the Pocket PC/Windows Mobile era, the Today screen plug-
ins had those features i.e. the plug-ins would be notified when
visible, and periodically afterwards. This is what I'm looking for
because that perfectly fits my apps requirements. 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] Why does ddms heap size not match HPROF?

2011-06-23 Thread Drew DeNardo
I'm doing memory profiling on my Xoom application. DDMS says my heap
size is "96.133M" and that I have "89.136M" allocated. I did a HPROF
dump, ran hprof-conv, and then loaded the .hprof file into MAT. It
says my heap is 37.3 MB. What gives?

Looking at the output of "adb logcat" while my app is running, it
seems to agree with ddms.

06-22 22:05:59.935: DEBUG/dalvikvm(11875): GC_FOR_ALLOC freed 0K, 3%
free 95699K/98567K, paused 172ms

(note the logcat message I grabbed was not taken at the exact same
time as the hprof -- at this time the sizes reported in logcat matched
what ddms says).

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


[android-developers] moving buttons

2011-06-23 Thread yasith miuranga
I want to know how to make Android UI with buttons moving.  it mean
just rotate move image button in the UI.just like dancing buttons.
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] client-server in android

2011-06-23 Thread Naga K
Dear adrian

  i am new to android technology,till i struggle develop the android
application,give me idea how to develop client -server android application
.if you have any same application please send me.
Thanks
Naga

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

[android-developers] Is it possible to use MonkeyRunner from java

2011-06-23 Thread Karthik
Hi,

Is it possible to use monkeyrunner from java.

If yes please let me know the approach.

Thanks in advance

Thanks
--Karthik

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


[android-developers] NDK build/awk/extract-debuggable.awk fails on Windows line endings

2011-06-23 Thread Jonathan McCaffrey
When run on an Android manifest with Windows line endings from a Linux
shell, extract-debuggable.awk fails on the first XML attribute, at
this panic:

if ( _xml_attrib !~ /^[a-z][-+_0-9a-z:]*$/ ) # validate it
_xml_panic("Invalid attribute name: " _xml_attrib);

Changing the line endings to Unix solves the 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] filling form when a app is installed

2011-06-23 Thread JK Park
Hi

I am trying to build up a program that managing android on web server.

So when a customer is installing my app, I want to show a form and
then send a filled form to server.
the form is basic information such as name, address and job.

Can anyone tell me how to show a form when a app is installing?

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


[android-developers] Mapview can not be resolved to a type

2011-06-23 Thread juhi paunikar
Hi,
i tried the project which is given belows link:
http://developer.android.com/resources/tutorials/views/hello-mapview.html

i am getting error as given below:
Mapview can not be resolved to a type.

Can anybody give me suggestion to solve this 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] adb disconnect issue in one round CTS

2011-06-23 Thread lin flinx
Dear all,

As you know that when doing CTS,  there is a configuration about the
maxTestCount, this params is for CTS host to reboot the device after
maxTestCount reached, see below details
from android-cts/repository/host_config.xml, the maxTestCount is set as 200,
that means in CTS environment, it will send reboot request to device(with
adb command over USB for real devices) every 200 test cases be executed(fix
me if I was wrong)





So when you execute "start --plan CTS" in CTS console environment, all of
more than 2700 cases will start to run on the tested devices which connected
to the host via USB(adb). The phenomena I meet is:
After sometimes reboot(it is randomly), CTS console UI print below message,
then the CTS could not continue to run test case anymore.

CTS_INFO >>> Max ADB operations reached. Restarting ADB...



CTS_INFO >>> Restarting device ...

Device(0123456789ABCDEF) disconnected

Test stopped.


But I still can use "adb devices" or "adb shell" in bash  to connect to the
devices.

and the other case is : If I unplug out  the USB cable and then re-plugin
the USB cable, the CTS can connect the device again and continue run the
test suite.


Does anybody meet the same issues on real devices? and any advices on this
will be appreciated.


Thanks & Best Regards,


Frank

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

[android-developers] I want to develope android NFC read/write application

2011-06-23 Thread Adiga
Hi,
 I want to develop NFC read/write application. Can anyone help
me


Regards,
Adiga

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


[android-developers] pre-build a android browser plugin

2011-06-23 Thread rio
I have a problem to pre-build a android browser plugin.

Procedure.
1. Create package/apps/LunaTest directory.
2. Create Android.mk file.
3. The files "LunaTest.apk", "liblunatest.so" and "libysshared.so"
exist in LunaTest directory.
4. Add the string, "LunaTest" into the file generic.mk under "build/
target/product/" directory.
5. Execute "./build_android".


Android.mk is as below:

=
LOCAL_PATH:= $(call my-dir)
include $(CLEAR_VARS)

LOCAL_PROGUARD_ENABLED := disabled
LOCAL_PACKAGE_NAME := lunatest
LOCAL_MODULE := LunaTest
LOCAL_MODULE_TAGS := optional
LOCAL_SRC_FILES := $(LOCAL_MODULE).apk
LOCAL_MODULE_CLASS := APPS
LOCAL_MODULE_SUFFIX := $(COMMON_ANDROID_PACKAGE_SUFFIX)
LOCAL_REQUIRED_MODULES := liblunatest libysshared
LOCAL_CERTIFICATE := platform

include $(BUILD_PREBUILT)

include $(CLEAR_VARS)

LOCAL_MODULE := liblunatest
LOCAL_MODULE_TAGS := optional
LOCAL_SRC_FILES := $(LOCAL_MODULE).so
LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/plugins/
com.luna.lunatest
LOCAL_PRELINK_MODULE := false
LOCAL_MODULE_CLASS := SHARED_LIBRARIES
include $(BUILD_PREBUILT)

include $(CLEAR_VARS)
LOCAL_MODULE := libysshared
LOCAL_MODULE_TAGS := optional
LOCAL_SRC_FILES := $(LOCAL_MODULE).so
LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/plugins/
com.luna.lunatest
LOCAL_PRELINK_MODULE := false
LOCAL_MODULE_CLASS := SHARED_LIBRARIES
include $(BUILD_PREBUILT)
=

First, I copyed the shared object files into "/system/lib/plugins/
com.luna.lunatest", but the plug-in didn't work.
So I moved the files into "/system/lib", but it showed the same
result; it didn't work.

The error message is as below:
=
Can't open dex cache '/data/dalvik-cache/
system@a...@lunatest.apk@classes.dex':No such file or directory.
=

Could anyone help me to solve this 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] How to Implement Drag And Drop for image views by extending View Group

2011-06-23 Thread ram dharan
Hii all i m new to android,m developing an app which needs Drag and
Drop if images by extending View Group Class.Could any one plz tell
how can i achieve this.any help is 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


  1   2   3   >