[android-developers] arecord aplay sampling rate

2010-09-22 Thread s n
all,

 how do i change/set the sampling rate and parameters that aplay and
arecord accepts in android?

tia.

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

2010-09-22 Thread William Ferguson
Nice analogy - I'm a Captain Beefheart fan.

But I beg to differ. While the Android SDK most certainly has its
idosyncracies, mostly notably for me the incessant overuse of
implementation inheritance and the use of ints instead of (typed)
enums.
It also requires a good understanding of standard design patterns and
principles. Notably event handling and MVP, but many others besides.
To use it as a training ground for a new developer would be asking for
pain .

It would also produce a whole raft of decidedly crappy apps and
examples from those who had found a way and want to tell the world,
just not a good one. And the hordes would folllow.


On Sep 22, 2:45 pm, Bret Foreman bret.fore...@gmail.com wrote:
 One of the most original musical minds of the 20th century was Don Van
 Vliet aka Captain Beefheart. His music was so unusual that experienced
 musicians had trouble approaching it. He preferred to find non-
 musicians and train them from zero. Android is like that - it's almost
 better to come at it without the expectations that an experienced
 programmer would have.

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

2010-09-22 Thread ko5tik
I do all interchange with my high-score servers ( pretty same use case
as yours,
also with sent flag ;) )  in broadcast receiver - I request regular
updates  via non-wakeup
alarm ( 30 minutes ).   It works fine.

Service is needed when you have to do longer piece of work and stay
alive.

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

2010-09-22 Thread ko5tik


On Sep 21, 10:35 pm, Indicator Veritatis mej1...@yahoo.com wrote:

 in Yeltsin's Russia, for example, it was routine
 to keep one set of books for real and the other to show the taxman.
 You can figure out which showed the higher profits.

It's not quite true ;)  There were 3 books - for yourself, for your
mafia taxes
( roof ) and for taxes , where  first 2 existed virtually.   And it
still the same ;)

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

2010-09-22 Thread Indicator Veritatis
Are you fairly new to developing, or fairly new to developing on
Android? If you don't know Java, learning Android is going to be
needlessly frustrating. You should at least know Java at the level of
the Trails Covering the Basics at http://download.oracle.com/javase/tutorial/
before trying Android: you certainly need to know more than just about
variables, primitives and a few other things. You need to know about
classes and interfaces. Even Patterns, especially the Model-View-
Presenter pattern, Factory pattern and Factory Method pattern.

But you can skim the trails on Swing and Deployment. There are lots of
analogies between Android SDK and Swing, so some acquaintance with
Swing is helfpul, but you don't need to know it really well.
Deployment is even less relevant.

There are also other Java tutorials that are written to be directed at
novice programmers: but I don't have the URL for any of them handy. If
that is what you need, you should Google it yourself.

Finally, yes, your comment about the tutorials simply presenting the
code is a real problem. To some extent, the Sun tutorials have the
same problem. It's the new trend. But that is why people pay good
money for introductory books that go into more detail; some even have
useful exercises. Those that don't rely on you to invent your own.

On Sep 16, 4:06 pm, Se-An-1 sharringto...@gmail.com wrote:
 I'm a fairly new to developing.  Really new.  Actually, I'm taking my
 first class in-school this year on how to program for Windows. However
 I'm only 4 weeks into it so I know only the very basics.  Variables,
 Primitives and a few other things. But that's a separate story (but
 still helps you understand where I come from).

 Anyways, I finally got Eclipse and the SDK working together and I have
 been going through some of the tutorials on developing for Androids.
 I think I'm mostly lost because I barely understand any of the
 concepts told.  I do have some questions though that may help me if
 answered.

 1. Since this is open source, can I find XML that has already been
 created and just tweak a few settings to fit my needs?  Can these just
 be found on the Android Developer site?
 2. How am I supposed to find the code I'm looking for?  I understand
 there is packages and classes but it is overwhelming on how much there
 is and where to go when I get an error.
 3. I feel like the tutorials teach me nothing because all I'm really
 doing is pasting code that they already made.  Is this really the best
 way to learn?
 4. I'm thinking of making an app like the Car Dock but with my own
 shortcuts.  Can you create shortcuts to other apps using XML?

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


[android-developers] SurfaceView flicker on setVisiblity() in 2.0 and later version

2010-09-22 Thread Jitsu
Got this issue developing a game application.

Main concept: We have an activity with layout set to it by
setContentView. Layout has a SurfaceView, which is used to draw some
additional graphics (transition between different screens).
Problem is that on 1.5 and 1.6 everything works prefectly fine.
But testing on 2.0 and greater version of andorid shown a issue: At
the moment when we use setVisiblity(true/false) on our SurfaceView
screen flickers with black.
Seems like starting from 2.0 any changes to order of views in
hierarchy cause some flickering.

Tried removing view using (ViewGroup).removeView(myView) - same
results like in setVisiblility()
Checked sources, in both methods invalidate()-invalidateChild()-
invalidateChildInParent() are called.
May be some problem in SDK methods?

Also noted another issue on 2.0/2.0.1/2.1-update1. If from activity
with layout and surfaceView we start another activity by startActivity/
startActivityForResult() after we get back from that activity, canvas
of the surfaceView will be valid all right, but it will be just black.
And drawing on that canvas will not be shown. Reseting holder of
surface in callback methods didn't help at all.

If anyone happen to know workarounds for these issue, I'll be very
grateful.

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

2010-09-22 Thread Indicator Veritatis
The short answer to your question is, as TreKing said, get a device.
That IS the only practical alternative.

But of course, developers don't want to spend the money on having all
the different kinds of device necessary, so we do as much testing as
we can either on a few chosen devices, or with the emulator.

This is why what a lot of us do is launch the SDK, then the emulator,
both at the start of our work session -- then keep the emulator
running as long as we can. For once it has started up, though still
slow (compared to some phones), the slowness is not nearly so
annoying.

Finally, the other posts should have made it clear by now why no, it
is not as simple as a
GTK application that just opens a window and runs the app.

On Sep 20, 4:14 pm, Gonsolo gons...@gmail.com wrote:
 Is it possible to develop/test/run applications without the slow
 emulator based on qemu?
 It thought Dalvik runs on a PC andn the platform is based on Java so
 it should be possible to test Android applications without that slow
 emulator.
 I imagined a GTK application that just opens a window and runs the
 app. This should be much faster than running the emulator.

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


[android-developers] Re: Live video streaming

2010-09-22 Thread Christina Loop
Thanks a lot for your reply. I need to send it in streaming mode. I
read somewhere that rtp is not possible in android. And that I need to
send it covered in rtsp. I don't know how this can be achieved. You
would help me a lot if you could give me a hint.

Regards,
Christina

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

2010-09-22 Thread Indicator Veritatis
What? No UPnP for Android?

On Sep 21, 11:20 am, Kostya Vasilyev kmans...@gmail.com wrote:
   Sure, that's possible - as long as the server is accessible from the
 client.

 The easiest case is that both phones are connected to the same Wifi router.

 If the server is behind any NATs (looking from the client's side), the
 client won't be able to get a connection.

 -- Kostya

 21.09.2010 10:35, ambi пишет:



  Hi,

  I am new to developing applications for android but have developed my
  first app. I have following questions.

  1. Is it possible to create a client server app? I mean the
  application on one phone acting as server and applications on other
  phones sending/receiving data from it?

  2. Create a wifi network (may be using bluetooth) for the above client
  server app. The idea being not to use the mobile service provide
  network but rather a local network.

  Thanks.

  Kind Regards,
  Ambi.

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

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


[android-developers] How to create an executable file for android

2010-09-22 Thread Lidia
Hello people,

Can someone tell me  how to create an executable jar file from eclipse
for android?
First of all, how the application should be before creating a jar
file? Should it be runnable?  Do i need an Activity class in it?

I created a simple Android application, which has an activity class:
//--
public class MyClass extends Activity {
@Override
public void onCreate(Bundle  savedInstanceState){
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
}
}
//--

and some other classes. I don't need this activity class in my jar
file, i need only all other simple classes,
I used from the eclipse the option Export -Java -JAR file
As i see, this option creates a simple jar file, it packs the classes,
so their content is invisible, but at the same time, the JAR file
content can be changed. e.g i can assign values to static parameters.

But i need an executable/unchangeable jar file.
If i use from eclipse the option Export -Java -Runnable JAR file -
the Launch Configuration: is empty, and i can't go on

What should i do

Please help me
Lidia




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


[android-developers] can the data via ContentProvider be sent and received from the different packages to the directry as I like?

2010-09-22 Thread Hiko
hello,

at first, I am sorry because I am not good at English.

As the subject of this message, I have tried to send / receive the
data via ContentProvider from the different packages to the common
directory.

In short, for example...

the data run update() or insert() in package  com.test.example.a
would like to be stored into the /data/data/com.common.data/
databases, not /data/data/com.test.example.a/databases/.
As well, I would like to run query() in package com.test.example.b
to query into the data/data/com.common.data/databases which has been
stored at  package  com.test.example.a.

In my understanding, the data can only be created to the directory
which is same as the package name.
as well , the data can only be read(query) from the directory which is
same as the package name.

If misunderstanding concerning the behavior, please correct me.

And please let me know how to refer the same directory which is not
indicated as the package name if you have known.

best Regards,

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

2010-09-22 Thread Kostya Vasilyev

 There are various UPnP projects that could be used, but nothing built-in.

-- Kostya

22.09.2010 11:16, Indicator Veritatis пишет:

What? No UPnP for Android?

On Sep 21, 11:20 am, Kostya Vasilyevkmans...@gmail.com  wrote:

   Sure, that's possible - as long as the server is accessible from the
client.

The easiest case is that both phones are connected to the same Wifi router.

If the server is behind any NATs (looking from the client's side), the
client won't be able to get a connection.

-- Kostya

21.09.2010 10:35, ambi пишет:




Hi,
I am new to developing applications for android but have developed my
first app. I have following questions.
1. Is it possible to create a client server app? I mean the
application on one phone acting as server and applications on other
phones sending/receiving data from it?
2. Create a wifi network (may be using bluetooth) for the above client
server app. The idea being not to use the mobile service provide
network but rather a local network.
Thanks.
Kind Regards,
Ambi.

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



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

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


[android-developers] Re: Cupcake(API3) friendly way to pause/stop sound loops in SoundPool? Any ideas?

2010-09-22 Thread Clankrieger
While this thread is rather old, I have a similar issue - while using
the soundpool with the correct streamIDs.

There is a looping sound being started, remembering its stream id. But
when I try to stop it like this:

SoundPool.stop(mId);

nothing happens... the sound simply keeps looping. This happens on
API3, API4 and API7... The only way to stop the sounds is by releasing
the soundpool instance - but this way, I have to reload all pre-cached
data again.

On Aug 29, 9:16 am, Jason jason.poli...@gmail.com wrote:
 I use the pause() method inSoundPool... implemented since API level 1

 http://developer.android.com/reference/android/media/SoundPool.html#p...)

 The streamID(int) is obtained when you play the sound:

 http://developer.android.com/reference/android/media/SoundPool.html#p...,
 float, float, int, int, float)

 Returns non-zero streamID if successful, zero if failed

 Retain this streamID in your reference the sound, then you can pause
 it using the pause/resume methods.

 Personally I create a wrapper object (I call a Sound) which exposes
 simple methods like play(), pause(),stop() etc and the internals of
 streamID etc are handled in this class.  That way I can swap between
 using theSoundPooland MediaPlayer but still have the same Sound
 class exposed to the app.

 On Aug 29, 8:32 am, BryBam bry...@gmail.com wrote:



  Quick note: I'm using theSoundPoolclass

 http://developer.android.com/reference/android/media/SoundPool.html

  What I have here is a simple button that plays a looped sound while
  it's pressed. It works great. However, sounds.autoPause(); wasn't
  introduced until API 8 and I really need something that is cupcake
  compatible (API 3) So i was going through the dev reference site
  filtered by API 3 stuff and i saw pause so i figured i'd try
  sounds.pause(sound); but it doesn'tstopthe sound when i release it.
  (Maybe i'm just using it wrong?) Does anyone know of a cupcake
  friendly way tostopthis sound? thanks!

  edit: also tried sounds.stop(sound); that didn't work either.

  The Code:

  My onCreate:

  sounds = newSoundPool(5, AudioManager.STREAM_MUSIC, 0);
  sound = sounds.load(this.getApplicationContext(), R.raw.red_long_one,
  1);
  Then here's my touch event

  @Override public boolean onTouch(View arg0, MotionEvent event) {

              switch (event.getAction() ) {
              case MotionEvent.ACTION_DOWN:
                  System.out.println(touch);
                  sounds.play(sound, 1, 1, 1, -1, 1);
                  break;
              case MotionEvent.ACTION_UP:
                  System.out.println(up);
                  //autoPause does not work on anything lower than sdk8
                  sounds.autoPause();
                  break;
              }

              return false;
          }
  I don't understand why sounds.stop(sound); doesn't seem to work, that
  seems to but what any article i read recommends to do

  I think it's worth noting that if i use sounds.stop(sound); it works
  ONE time then after that it won'tstopafter i let go. but the first
  press and release it works as intended.

  Now, I know on the andoird site it says streamID and not soundID but i
  have no idea how to get the streamID

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email 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: Cupcake(API3) friendly way to pause/stop sound loops in SoundPool? Any ideas?

2010-09-22 Thread Jason
There must be something crufty in your code.  I am doing this
currently in my game and it is working on all API versions (3+).

Post your code (both the play code and the stop code).

This is what I do (summarized):

SoundPool pool = ...
boolean loop = ...

int streamId = pool.play(soundId, 1.0f, 1.0f, 1, ( loop ) ? -1 : 0,
1.0f);

...

if(streamId != 0){
pool.stop(streamId);
streamId = 0;
}

On Sep 22, 5:55 pm, Clankrieger tob...@googlemail.com wrote:
 While this thread is rather old, I have a similar issue - while using
 the soundpool with the correct streamIDs.

 There is a looping sound being started, remembering its stream id. But
 when I try to stop it like this:

 SoundPool.stop(mId);

 nothing happens... the sound simply keeps looping. This happens on
 API3, API4 and API7... The only way to stop the sounds is by releasing
 the soundpool instance - but this way, I have to reload all pre-cached
 data again.

 On Aug 29, 9:16 am, Jason jason.poli...@gmail.com wrote:



  I use the pause() method inSoundPool... implemented since API level 1

 http://developer.android.com/reference/android/media/SoundPool.html#p...)

  The streamID(int) is obtained when you play the sound:

 http://developer.android.com/reference/android/media/SoundPool.html#p...,
  float, float, int, int, float)

  Returns non-zero streamID if successful, zero if failed

  Retain this streamID in your reference the sound, then you can pause
  it using the pause/resume methods.

  Personally I create a wrapper object (I call a Sound) which exposes
  simple methods like play(), pause(),stop() etc and the internals of
  streamID etc are handled in this class.  That way I can swap between
  using theSoundPooland MediaPlayer but still have the same Sound
  class exposed to the app.

  On Aug 29, 8:32 am, BryBam bry...@gmail.com wrote:

   Quick note: I'm using theSoundPoolclass

  http://developer.android.com/reference/android/media/SoundPool.html

   What I have here is a simple button that plays a looped sound while
   it's pressed. It works great. However, sounds.autoPause(); wasn't
   introduced until API 8 and I really need something that is cupcake
   compatible (API 3) So i was going through the dev reference site
   filtered by API 3 stuff and i saw pause so i figured i'd try
   sounds.pause(sound); but it doesn'tstopthe sound when i release it.
   (Maybe i'm just using it wrong?) Does anyone know of a cupcake
   friendly way tostopthis sound? thanks!

   edit: also tried sounds.stop(sound); that didn't work either.

   The Code:

   My onCreate:

   sounds = newSoundPool(5, AudioManager.STREAM_MUSIC, 0);
   sound = sounds.load(this.getApplicationContext(), R.raw.red_long_one,
   1);
   Then here's my touch event

   @Override public boolean onTouch(View arg0, MotionEvent event) {

               switch (event.getAction() ) {
               case MotionEvent.ACTION_DOWN:
                   System.out.println(touch);
                   sounds.play(sound, 1, 1, 1, -1, 1);
                   break;
               case MotionEvent.ACTION_UP:
                   System.out.println(up);
                   //autoPause does not work on anything lower than sdk8
                   sounds.autoPause();
                   break;
               }

               return false;
           }
   I don't understand why sounds.stop(sound); doesn't seem to work, that
   seems to but what any article i read recommends to do

   I think it's worth noting that if i use sounds.stop(sound); it works
   ONE time then after that it won'tstopafter i let go. but the first
   press and release it works as intended.

   Now, I know on the andoird site it says streamID and not soundID but i
   have no idea how to get the streamID

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

2010-09-22 Thread Michael A.
On Sep 21, 10:35 pm, Indicator Veritatis mej1...@yahoo.com wrote:
 So the moment the first post in this thread went up, I knew we were
 going to see some responses painting a rosy picture of glowing
 success. But that doesn't really tell us much.

I haven't seen any claims on this thread that I find outlandish by any
means.

At, e.g., $3 a sale, $100 per day is only 33 sales per day = about
10-15K downloads over a year. There are several hundreds of paid apps
that have broken the 10K downloads mark, so I am not surprised to see
several people reporting such income. Note that both niko and Doug -
the two who have cited $100 a day, specifically point out that their
apps have been on the market for a long time = most likely top ranked
apps. These are not apps that have made big money for years - most
likely their current level has only been reached in recent months as
the number of Android devices has gone through the roof.

Of course, one should put their success in perspective by noting that
of 45K+ paid apps, only about 3% have 1000 downloads and less than 1%
have 5000 downloads (according to Androlib). So obviously, success of
that kind is rare and not to be expected for the average app.

The sad thing is that, by iPhone standards, these tales of glowing
success are laughable. Consider for instance Trism (big hit on the
iPhone - sold 50K units in its first 2 months @ 5$) has yet to break
the 500 download mark on Android. Obviously, success is all about
being in the right place at the right time with the right product, but
but such a huge disrepancy in sales can hardly be put down to only
luck. I am looking forward to reading Polyclef's blog when he takes
status of sales on iPhone/Android for his latest cross-platform app
whether he finds the trend of iTunes being immensely superior to the
Android market continuing.

Currently (again according to Androlib), Android has 27 paid apps with
more than 50K sales. Only 1 (Robo Defense) has gone over 250K in
sales. That should really tell people everything they need to know
about the profitability of the market for a regular starting
developer.

If you have the name recognition, of course, big hits are still
possible. Angry Birds will certainly make a killing when it comes on
the paid market. Judging by their download data, the Moron Test is
making well over $600 a day now (5000 downloads between Jun 29 - Jul
11; 40,000 downloads from Jul 11 to Sep 7 @ $0.99). So really good
sales are clearly possible, if you have the right IP.

Regards,

Michael A.

 On Sep 17, 7:40 am, TreKing treking...@gmail.com wrote:

  On Thu, Sep 16, 2010 at 5:22 PM, William Ferguson william.ferguson.au@

  gmail.com wrote:
   Very droll.

  Perhaps =P

  But it's a good question.

  Yes, it would definitely be very interesting to see some stats from various
  developers.

  But it IS a fairly private / personal question not many people are going to
  be willing to answer. Notice how no one has actually answered the question,
  including the OP, save for the one person that was already blogging about it
  anyway.

  BTW, poly, thanks for sharing and congrats on the success. When I'm making
  that much I'll be flaunting it too =P

  -
  TreKing http://sites.google.com/site/rezmobileapps/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: Where has maps.jar gone to? Can't find in basic SDK install

2010-09-22 Thread Lance Nanek
If you are using Eclipse you shouldn't be accessing the maps.jar
manually anyway. Right-click on your project in Eclipse, choose
Properties, choose Android, and check a build target that has Google
APIs as the Target Name. That adds it to your build path for you. If
you don't have a Google APIs build target listed, you need to go to
Window, then Android SDK and AVD Manager, then Available Packages, and
download one.

On Sep 21, 4:11 pm, pawpaw17 georgefraz...@yahoo.com wrote:
 I'm configuring a new machine for Android development - following the
 basic steps. When I brought my app over I get compile
 failures the google maps stuff. On my older machine, the maps.jar file
 is in the add-ons sudirectory fo the sdk, but I can't
 find it in the most recent versions of the sdks.

 Anyone know what I'm doing wrong or where to grab it from?

 Best

 pawpaw17

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

2010-09-22 Thread Pedro Teixeira

I'm really not understanding how to go with this...

I've been reading and reading.. I can find all kind of algorithms.. I  
can find a haversin algorithm that points me to the correct direction  
if my device is pointing north.. but the needle is static... so if i  
change the device orientation the measure is incorrect... and I know  
this happens because I'm not using device's sensor values like  
azimuth, pitch and roll.. oh god.. 2 weeks on this.. I'm just  
desperate now.


On Sep 18, 2010, at 10:29 AM, Kostya Vasilyev wrote:


Pedro,

If I understand you correctly, you are having difficulties with the  
device's orientation.


The bearing angle seems to be computed in the horizontal plane. If  
you wish to adjust for the device's orientation, you need to  
concatenate it with the bearing angle.


Google for quaternions.

This is a (relatively) simple math technique to work with rotations  
the same way you can work with vectors: add / subtract, interpolate.


-- Kostya

18.09.2010 0:56, Pedro Teixeira пишет:

Hi everyone...

I'm back with the same issue for the last couple of days… I'm  
trying

to create a compass for my application BUT the difference is that,
instead of having a line always pointing to north, I want this line  
to

point for a specific point. I've been trying dozens of algorithms and
nothing works..
I've finally found one that points me exactlly to the point I want..
BUT it doesn't move if I change the position of the device which is  
my

objective.. basicly, what I want is that no matter the direction I'm
using my device.. the line always point me to the point
(picLatitude,picLongitude)…

I understood that for the line to move, I can't use static  
variables…

I need to use the values offered by the onSensorChanged(SensorEvent
event).

This are the data I have available:

event.values[0]: azimuth, rotation around the Z axis (device in
relation to north, 0º)
event.values[1]: pitch, rotation around the X axis
event.values[2]: roll, rotation around the Y axis
mLatitude: device current latitude gottern from GPS (variable)
mLongitude: device current longitude gotten from GPS (variable)
picLatitude: static picture latitude established previously
picLongitude: static picture longitude established previously
distance: distance in Km from device to the picture calculated
previously

And this the formula that works correct, and gives me the correct
angle.. ( BUT IT DOESN'T USE ANY OF THE SENSOR DATA SO THE LINE
COMPASS DOESNT MOVE):

double dLong = picLongitude - mLongitude;
double y =  (Math.sin(dLong) * Math.cos(picLatitude));
double x =  (Math.cos(mLatitude) * Math.sin(picLatitude) -
Math.sin(mLatitude)*Math.cos(picLatitude)*Math.cos(dLong));
double angleDegreesWrongRange = Math.abs(Math.toDegrees(Math.atan2(y,
x)));
float angleDegrees = (float) ((angleDegreesWrongRange+360) % 360);

myCompass.updateDirection(angleDegrees);

I got this bearing formula from this website:
http://www.movable-type.co.uk/scripts/latlong.html


Can someone please help me with this?
I've try adding, subtracting… the azimuth.. I've tried with the
others.. seriously at this point I'm just demoralized..

Thank you in advance




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

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


Pedro Teixeira

www.pedroteixeira.org

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


Re: [android-developers] Please help me with calculating direction from point A to B

2010-09-22 Thread Christian Buchner
this sounds trivial to me.

Just compensate the error that is introduced by not actually pointing the
device north by subtracting that error from your arrow's pointing angle. No
need to change any algorithm, just compensate for the dude, you're holding
it wrong

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

2010-09-22 Thread Pedro Teixeira

I've tried it.

Adding and subtracting the value: event.values[0], which is actually  
my Azimuth in degrees returned by the sensor.


But the orientation is off! ..

The algorithm gives the Correct value, but it doesn't move because  
there's not sensor variables involved.. so if I subtract the error it  
points in the wrong direction



On Sep 22, 2010, at 10:08 AM, Christian Buchner wrote:


this sounds trivial to me.

Just compensate the error that is introduced by not actually  
pointing the device north by subtracting that error from your  
arrow's pointing angle. No need to change any algorithm, just  
compensate for the dude, you're holding it wrong




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


Pedro Teixeira

www.pedroteixeira.org

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

[android-developers] Service: both onStart() and onStartCommand() called

2010-09-22 Thread Christoffer Davidsson
Hello (World).

I'm trying to create a Service which is backwards compatible, working
on both pre-2.0 and post-2.0 phones.
Therefore I implement both onStart() and onStartCommand() according
to: 
http://developer.android.com/reference/android/app/Service.html#onStartCommand(android.content.Intent,
int, int).
Where the comments on onStart() say:
// This is the old onStart method that will be called on the pre-2.0
// platform.  On 2.0 or later we override onStartCommand() so this
// method will not be called.

However, running 2.1 in the Emulator, both methods are called when I
start my Service. Is this a bug? Did anyone else have 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] Re: How to compile Android Launcher source code?

2010-09-22 Thread Paolo
Dianne thanks for your answer.

Well, at the moment I don't want to place my Launcher on the Market,
but only to do it for a private use on my Froyo 2.2 device.
My idea is to compile the default Launcher in Eclipse and to modify/
extend it with different features, as ADW Launcher did.

How can I do this? I'm thinking to re-compile Android from source
code, is the right way?

Please answer me.

Thamks,

Paolo

On 21 Set, 19:14, Dianne Hackborn hack...@android.com wrote:
 Launcher currently uses a number of experimental/private APIs.

 If you are doing this to create something you will place on Market, you
 *must* change the code to not use those APIs.

 If you are doing this as part of platform development for a device,
 personally I would recommend just using the platform's build system.

 Any tricks one uses to build Launcher in Eclipse without fixing the code
 will *not* create an application that should be placed on market.  (And if
 you do, I can guarantee that future versions of the platform will break the
 resulting app.)





 On Tue, Sep 21, 2010 at 9:26 AM, Paolo brand...@gmail.com wrote:
  I followed the guide you have posted. Thanks a lot.

  Now I can see the android SDK source code in Eclipse, but I'm still
  not able to compile the Launcher anyway... Eclipse always shows the
  same error on the Launcher code... why? Is there something I don't
  undestand?

  Thanks,
  Paolo

  On 21 Set, 13:01, mani smanikanda...@gmail.com wrote:
   Hi you cannot compile the Launcher code in eclipse with SDK.

   Certain API's are private not exposed to the public SDK.

   Ex. import android.renderscript.*

   But there are certain ways to compile AOSP in eclipse. Please go
   through this link.
 http://blog.michael-forster.de/2008/12/view-android-source-code-in-ec...

   Thanks,
   Mani

   On Sep 21, 6:21 pm, Paolo brand...@gmail.com wrote:

I have just donwload the source code of the Android default Launcher
here:
 http://android.git.kernel.org/?p=platform/packages/apps/Launcher.git;...

But when I import the project, i can't compile it because there is a
lot of errors. Many of this are unresolved name, package, class and
variables... why? what is the problem? How can I solve it?

Please help me.Thanks.

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

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

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

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


Re: [android-developers] Please help me with calculating direction from point A to B

2010-09-22 Thread Pedro Teixeira
Basicly, if my device is pointing the wrong direction. I can't see the  
value.. because the arrow is static. The arrow is always static if I  
don't use any of the sensor values.


On Sep 22, 2010, at 10:08 AM, Christian Buchner wrote:


this sounds trivial to me.

Just compensate the error that is introduced by not actually  
pointing the device north by subtracting that error from your  
arrow's pointing angle. No need to change any algorithm, just  
compensate for the dude, you're holding it wrong




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


Pedro Teixeira

www.pedroteixeira.org

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

[android-developers] Re: how to block buttons with a layout above all?

2010-09-22 Thread Lance Nanek
Setting clickable to false lets clicks through to what is underneath
it. You should set clickable to true, so that it takes the clicks and
nothing else gets them. Setting a listener will set this to true
anyway, though.

On Sep 21, 4:40 am, Marco Alexander Schmitz
marco.alexander.schm...@googlemail.com wrote:
 hi,

 I'd like to add a transparent panel (relativelayout) with fill_parent
 in width and height.

 I want to use this glasspane in order to block all buttons
 underneath.

 Unfortunately I cannot find the right setter / xml  attribute for
 this.

 These wont work:

 .setEnabled(false);
 .setPressed(false);
 .setClickable(false);
 .setFocusable(false);
 .setSaveEnabled(false);
 .setSelected(false);

 Maybe its better to understand if I tell you that I want to create my
 own dialog without extending the class Dialog.

 A dialog also puts a transparent glasspane above all and absorbs all
 clicks underneath...

 Thanks for helping,
 Marco

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email 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: Http chunked response and Connection Reset by Peer error

2010-09-22 Thread Cydrike
New information:

It seems that I don't receive Connection Reset by Peer errors because
Android has dropped the connection.

My exact test case is the following:
- I start my application which creates the request with the previous
posted code
- the app reads the request response waiting for the server
- I put the device in sleep mode by pressing the power button
- I wait 5 minutes (nothing special happens in logs apart from garbage
collector actions)
- I wake up the mobile and force the server to send me something
- Nothing arrives on the mobile anymore, the connection is stucked on
the read

No error can be seen in logcat, no exception is raised.
It seems that Android has just stop using my connection.

Is there some kind of mechanism that kill idle connections while in
sleep mode ?

Cédric



On 6 sep, 14:57, Cydrike cedric.bruck...@gmail.com wrote:
 Cloud 2 Device Messaging seems to be very interesting but I can't use
 it for many reasons.

 I've explicitly tested returned value of Read() method to detect -1.
 But it doesn't change anything.
 My application has been developed for Windows Mobile 6.5 too. Windows
 Mobile always detect the Connection Reset by Peer exception. Test
 protocol is exactly the same as the one used for Android.
 How could this difference be explained ?

 Here's the code I use to create my request with Android:

 HttpURLConnection connection = (HttpURLConnection) new
 URL(request).openConnection();
                 connection.setDefaultUseCaches(false);
                 connection.setUseCaches(false);
                 connection.setDoInput(true);
                 connection.setInstanceFollowRedirects(true);
                 connection.setConnectTimeout(CONNECT_TIMEOUT);
                 connection.setRequestMethod(GET);

 Cédric

 On 6 sep, 11:20, Kostya Vasilyev kmans...@gmail.com wrote:



    The server doing a graceful close can be detected on the client:
  read() will return -1.

  A lost connection (not gracefully closed) generally can't be detected on
  the client. TCP/IP does not transmit data unless your application does,
  so a lost connection looks the same as a connection that simply doesn't
  have any data to receive.

  There is a TCP/IP option to do keepalives at the protocol level,
  SO_KEEPALIVE, but I wouldn't count on it working reliably all the way
  from the phone to the server.

  I recommend you look at Google C2DM (Cloud 2 Device Messaging).

  -- Kostya

  06.09.2010 11:37, Cydrike пишет:

   Hi everyone,

   I'm facing an annoying problem here.
   My application is connected to a server that sends some data from time
   to time. It's some kind of eventing server. In order to receive data,
   I'm connecting to the server with an HttpURLConnection, retrieve the
   response InputStream and loop on it with the read method. The
   connection is always open.

   The distant server is cutting the connection every 5 minutes (for test
   purpose). When connection is closed, my application has to reconnect
   again. We detect a Connection Reset by Peer exception when the server
   closes the connection. The problem is that most of the time, I never
   receive the Connection Reset by Peer exception. So my application
   can't know that is has to reconnect and it's stucked on the read
   instruction.

   The InputStream.Read() method shouldn't always raise an exception if
   the connection is closed?
   What can I do to always detect Connection Reset by Peer exception?

   Thanks for any help,

   Android 2.1
   HTC Desire

   Cédric

  --
  Kostya Vasilyev -- WiFi Manager + pretty widget 
  --http://kmansoft.wordpress.com-Masquer le texte des messages précédents -

  - Afficher le texte des messages précédents -- Masquer le texte des 
  messages précédents -

 - Afficher le texte des messages précédents -

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

2010-09-22 Thread Kostya Vasilyev

 Pedro,

I think you should learn something about the way direction (and 
orientation) is specified in computer programming.


http://en.wikipedia.org/wiki/Yaw,_pitch,_and_roll

http://en.wikipedia.org/wiki/Euler_angles

http://en.wikipedia.org/wiki/Rotation_representation_(mathematics)#Rotation_matrix_.E2.86.94_Euler_angles

I believe that Android orientation sensors work this way.

Now about the compass

There are two ways you can think about this:

First, take the value you get from the algorithm and make it into a 
vector in 3D space (i.e. think of the arrow you're going to draw to 
indicate direction). Then:


One: Compute the device's orientation matrix using sensor data. Take the 
inverse of this matix, and multiply the arrow vector by this matrix.


Two: Compute the device's orientation matrix using sensor data. Rather 
than interpreting it as a rotation matrix, think of it as defining a 
plane in space (aligned with the device's screen).  Then project the 
arrow vector onto this plane, in the plane's coordinates.


You might want to start with compensating just for the vertical axis 
(the device's rotation from the true north direction), it might be enough.


-- Kostya

22.09.2010 13:02, Pedro Teixeira пишет:

I'm really not understanding how to go with this...

I've been reading and reading.. I can find all kind of algorithms.. I 
can find a haversin algorithm that points me to the correct direction 
if my device is pointing north.. but the needle is static... so if i 
change the device orientation the measure is incorrect... and I know 
this happens because I'm not using device's sensor values like 
azimuth, pitch and roll.. oh god.. 2 weeks on this.. I'm just 
desperate now.


On Sep 18, 2010, at 10:29 AM, Kostya Vasilyev wrote:


Pedro,

If I understand you correctly, you are having difficulties with the 
device's orientation.


The bearing angle seems to be computed in the horizontal plane. If 
you wish to adjust for the device's orientation, you need to 
concatenate it with the bearing angle.


Google for quaternions.

This is a (relatively) simple math technique to work with rotations 
the same way you can work with vectors: add / subtract, interpolate.


-- Kostya

18.09.2010 0:56, Pedro Teixeira пишет:

Hi everyone...

I'm back with the same issue for the last couple of days… I'm trying
to create a compass for my application BUT the difference is that,
instead of having a line always pointing to north, I want this line to
point for a specific point. I've been trying dozens of algorithms and
nothing works..
I've finally found one that points me exactlly to the point I want..
BUT it doesn't move if I change the position of the device which is my
objective.. basicly, what I want is that no matter the direction I'm
using my device.. the line always point me to the point
(picLatitude,picLongitude)…

I understood that for the line to move, I can't use static variables…
I need to use the values offered by the onSensorChanged(SensorEvent
event).

This are the data I have available:

event.values[0]: azimuth, rotation around the Z axis (device in
relation to north, 0º)
event.values[1]: pitch, rotation around the X axis
event.values[2]: roll, rotation around the Y axis
mLatitude: device current latitude gottern from GPS (variable)
mLongitude: device current longitude gotten from GPS (variable)
picLatitude: static picture latitude established previously
picLongitude: static picture longitude established previously
distance: distance in Km from device to the picture calculated
previously

And this the formula that works correct, and gives me the correct
angle.. ( BUT IT DOESN'T USE ANY OF THE SENSOR DATA SO THE LINE
COMPASS DOESNT MOVE):

double dLong = picLongitude - mLongitude;
double y =  (Math.sin(dLong) * Math.cos(picLatitude));
double x =  (Math.cos(mLatitude) * Math.sin(picLatitude) -
Math.sin(mLatitude)*Math.cos(picLatitude)*Math.cos(dLong));
double angleDegreesWrongRange = Math.abs(Math.toDegrees(Math.atan2(y,
x)));
float angleDegrees = (float) ((angleDegreesWrongRange+360) % 360);

myCompass.updateDirection(angleDegrees);

I got this bearing formula from this website:
http://www.movable-type.co.uk/scripts/latlong.html


Can someone please help me with this?
I've try adding, subtracting… the azimuth.. I've tried with the
others.. seriously at this point I'm just demoralized..

Thank you in advance




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


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


Pedro Teixeira

www.pedroteixeira.org




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

--
You received 

[android-developers] Re: BroadcastReceiver

2010-09-22 Thread KANTESH BABANNAVAR
Could you please prodice the log events of crash??
i think you may be missing some permissions..

On Sep 22, 8:37 am, perumal316 perumal...@gmail.com wrote:
 Hi All,

 I have written an application to read all incoming SMS and if the SMS
 contains certain string, I will also send a copy of the message to my
 another phone for backup purposes.

 I used the reference from the following website:

 http://www.anddev.org/novice-tutorials-f8/recognize-react-on-incoming...

 It uses BroadcastReceiver to get the incoming SMS, but when I tried to
 send it using the following method:

 private void sendingSMS(String phoneNo,String message){

             SmsManager sms = SmsManager.getDefault();
             sms.sendTextMessage(phoneNo, null, message,null,null);

         }

 It always crashes. Any idea how to resolve it? Is it because of using
 BroadcastReceiver.

 Thanks In Advance,
 Perumal

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


[android-developers] Re: BroadcastReceiver

2010-09-22 Thread KANTESH BABANNAVAR
probably these?
uses-permission android:name=android.permission.SEND_SMS /
uses-permission android:name=android.permission.RECEIVE_SMS /

On Sep 22, 8:37 am, perumal316 perumal...@gmail.com wrote:
 Hi All,

 I have written an application to read all incoming SMS and if the SMS
 contains certain string, I will also send a copy of the message to my
 another phone for backup purposes.

 I used the reference from the following website:

 http://www.anddev.org/novice-tutorials-f8/recognize-react-on-incoming...

 It uses BroadcastReceiver to get the incoming SMS, but when I tried to
 send it using the following method:

 private void sendingSMS(String phoneNo,String message){

             SmsManager sms = SmsManager.getDefault();
             sms.sendTextMessage(phoneNo, null, message,null,null);

         }

 It always crashes. Any idea how to resolve it? Is it because of using
 BroadcastReceiver.

 Thanks In Advance,
 Perumal

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


Re: [android-developers] Re: Http chunked response and Connection Reset by Peer error

2010-09-22 Thread Kostya Vasilyev
 Like I said before, detecting a broken connection on the receiving end 
is difficult, since TCP/IP does not have keep-alives. That's left up to 
the application protocol.


Perhaps what you could do is have your application periodically send 
small amounts of data, just to make sure the connection is still there. 
Just make sure your server can deal with it - actually read the data 
past the initial HTTP request, if only to drop it on the floor.


-- Kostya

22.09.2010 13:21, Cydrike пишет:

New information:

It seems that I don't receive Connection Reset by Peer errors because
Android has dropped the connection.

My exact test case is the following:
- I start my application which creates the request with the previous
posted code
- the app reads the request response waiting for the server
- I put the device in sleep mode by pressing the power button
- I wait 5 minutes (nothing special happens in logs apart from garbage
collector actions)
- I wake up the mobile and force the server to send me something
- Nothing arrives on the mobile anymore, the connection is stucked on
the read

No error can be seen in logcat, no exception is raised.
It seems that Android has just stop using my connection.

Is there some kind of mechanism that kill idle connections while in
sleep mode ?

Cédric



On 6 sep, 14:57, Cydrikecedric.bruck...@gmail.com  wrote:

Cloud 2 Device Messaging seems to be very interesting but I can't use
it for many reasons.

I've explicitly tested returned value of Read() method to detect -1.
But it doesn't change anything.
My application has been developed for Windows Mobile 6.5 too. Windows
Mobile always detect the Connection Reset by Peer exception. Test
protocol is exactly the same as the one used for Android.
How could this difference be explained ?

Here's the code I use to create my request with Android:

HttpURLConnection connection = (HttpURLConnection) new
URL(request).openConnection();
 connection.setDefaultUseCaches(false);
 connection.setUseCaches(false);
 connection.setDoInput(true);
 connection.setInstanceFollowRedirects(true);
 connection.setConnectTimeout(CONNECT_TIMEOUT);
 connection.setRequestMethod(GET);

Cédric

On 6 sep, 11:20, Kostya Vasilyevkmans...@gmail.com  wrote:




   The server doing a graceful close can be detected on the client:
read() will return -1.
A lost connection (not gracefully closed) generally can't be detected on
the client. TCP/IP does not transmit data unless your application does,
so a lost connection looks the same as a connection that simply doesn't
have any data to receive.
There is a TCP/IP option to do keepalives at the protocol level,
SO_KEEPALIVE, but I wouldn't count on it working reliably all the way
from the phone to the server.
I recommend you look at Google C2DM (Cloud 2 Device Messaging).
-- Kostya
06.09.2010 11:37, Cydrike пишет:

Hi everyone,
I'm facing an annoying problem here.
My application is connected to a server that sends some data from time
to time. It's some kind of eventing server. In order to receive data,
I'm connecting to the server with an HttpURLConnection, retrieve the
response InputStream and loop on it with the read method. The
connection is always open.
The distant server is cutting the connection every 5 minutes (for test
purpose). When connection is closed, my application has to reconnect
again. We detect a Connection Reset by Peer exception when the server
closes the connection. The problem is that most of the time, I never
receive the Connection Reset by Peer exception. So my application
can't know that is has to reconnect and it's stucked on the read
instruction.
The InputStream.Read() method shouldn't always raise an exception if
the connection is closed?
What can I do to always detect Connection Reset by Peer exception?
Thanks for any help,
Android 2.1
HTC Desire
Cédric

--
Kostya Vasilyev -- WiFi Manager + pretty widget 
--http://kmansoft.wordpress.com-Masquer le texte des messages précédents -
- Afficher le texte des messages précédents -- Masquer le texte des messages 
précédents -

- Afficher le texte des messages précédents -



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

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


[android-developers] wifi not remembering the access point

2010-09-22 Thread kiran
Hi All
i am using ralink wifi driver in android, i am able to connect to
the access-point using the Wireless Settings provided in the Android, But
once i connect to the network and restart the wifi i have to reconnect
manually by providing the authentication key. Wifi Manager is not
remembering the last access point used . i am using the Settings application
provided by the android.

Regards
Kiran

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

[android-developers] How to create an executable file for android

2010-09-22 Thread Lidia G
I found how to use an android library, from the eclipse 
http://developer.android.com/guide/developing/eclipse-adt.html#libraryProject 
but this is not what i need, i need to comples a library into a jar file and to 
hide the code that can be used from the library.

And i can't create a JAR file using usually jar command from the JDK, because, 
my classes contain some android specific code.

How can i create an executable JAR file from android.
Please help me. 



--- On Wed, 9/22/10, Lidia lidyp...@yahoo.com wrote:

From: Lidia lidyp...@yahoo.com
Subject: [android-developers] How to create an executable file for android
To: Android Developers android-developers@googlegroups.com
Date: Wednesday, September 22, 2010, 7:21 AM

Hello people,

Can someone tell me  how to create an executable jar file from eclipse
for android?
First of all, how the application should be before creating a jar
file? Should it be runnable?  Do i need an Activity class in it?

I created a simple Android application, which has an activity class:
//--
public class MyClass extends Activity {
    @Override
    public void onCreate(Bundle  savedInstanceState){
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
    }
}
//--

and some other classes. I don't need this activity class in my jar
file, i need only all other simple classes,
I used from the eclipse the option Export -Java -JAR file
As i see, this option creates a simple jar file, it packs the classes,
so their content is invisible, but at the same time, the JAR file
content can be changed. e.g i can assign values to static parameters.

But i need an executable/unchangeable jar file.
If i use from eclipse the option Export -Java -Runnable JAR file -
the Launch Configuration: is empty, and i can't go on

What should i do

Please help me
Lidia




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

2010-09-22 Thread student
Dear Android Developers,

  In location we have 2 way
1.gps
2. network

in above 2 of them are treated the seperate thread as thread1 and
thread2

in that if user inside the room gps not shown the latitude and
longitude so it should be activated the network side as thread2
then if user moved out it will be activated both gps and network.
my problem is if user came back to room it should be indicated the
network by comparing the frequency or  speed with gps?
how to do that comparision? what method we have to use in it?


Waiting for ur reply

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


[android-developers] pop-up/toast notification without activity/context

2010-09-22 Thread Vijay Vikrant
Hello everyone,
  Can somebody throw some light on how to display a
pop-up/notification/toast while i am in a broadcast receiver. Toast expects
a context and i don't have a context to pass.
Can somebody help me with this?

-- Vikrant

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] pop-up/toast notification without activity/context

2010-09-22 Thread Mark Murphy
On Wed, Sep 22, 2010 at 7:35 AM, Vijay Vikrant vijayvikran...@gmail.com wrote:
   Can somebody throw some light on how to display a
 pop-up/notification/toast while i am in a broadcast receiver. Toast expects
 a context and i don't have a context to pass.

Sure you do. Look at the first parameter to onReceive().

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

_The Busy Coder's Guide to Android Development_ Version 3.1 Available!

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


[android-developers] Nokia inviting Developers to become an Ovi store publisher.

2010-09-22 Thread Rohan Malhotra
Hey Guys...

I'm a developer and just received an email from Forum Nokia regarding
Unmatched distribution opportunities at Ovi store at NOKIA.
If u are a developer nd dream it big then grab this opportunity today.
Nokia inviting developers to Become an Ovi store publisher.

•   Easy access to reach millions of consumers worldwide
•   Fast time to market with self serve publishing
•   Monetize your apps and content with Nokia- provided billing
•   Daily time sales and usage reports
[B]Unmatched distribution opportunities at Ovi store at NOKIA. [/B]

To Discover How Nokia can make you Instapreneur check this:http://
www.oviinstapreneurs.com/
Be the next big Mobile Enterpreneur Instantly with the help of Nokia
Ovi store

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

2010-09-22 Thread Kostya Vasilyev
Does Nokia have phones that run Android?

--
Kostya Vasilyev -- http://kmansoft.wordpress.com

22.09.2010 15:50 пользователь Rohan Malhotra therohanmalho...@gmail.com
написал:

Hey Guys...

I'm a developer and just received an email from Forum Nokia regarding
Unmatched distribution opportunities at Ovi store at NOKIA.
If u are a developer nd dream it big then grab this opportunity today.
Nokia inviting developers to Become an Ovi store publisher.

*   Easy access to reach millions of consumers worldwide
*   Fast time to market with self serve publishing
*   Monetize your apps and content with Nokia- provided billing
*   Daily time sales and usage reports
[B]Unmatched distribution opportunities at Ovi store at NOKIA. [/B]

To Discover How Nokia can make you Instapreneur check this:http://
www.oviinstapreneurs.com/
Be the next big Mobile Enterpreneur Instantly with the help of Nokia
Ovi store

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

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

Re: [android-developers] pop-up/toast notification without activity/context

2010-09-22 Thread Vijay Vikrant
Thanks for responding..

Below is a shabby but simple piece of code that i am experimenting with..
The onReceive function does have a context - But i just register a
phonestate listener in there and then i have to raise a toast while i am in
the phonestatelistener function. What can i change?


package com.android.prankapp;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.telephony.PhoneStateListener;
import android.telephony.TelephonyManager;
import android.util.Log;
import android.content.BroadcastReceiver;
import android.widget.Toast;

public class PrankAApp extends BroadcastReceiver {

@Override
public void onReceive(Context context, Intent intent) {
Log.d(PrankAApp,BEGIN1);
if(intent.getData()!=null)
{
Log.d(PrankAApp,intent.getDataString() );
}
else
{
Log.d(PrankAApp,DataString == NULL );
}
Log.d(PrankAApp,intent.toString());
TelephonyManager myTelManager =
(TelephonyManager)context.getSystemService(context.TELEPHONY_SERVICE);
MyPhoneStateListener myListner = new MyPhoneStateListener();
myTelManager.listen(myListner,
PhoneStateListener.LISTEN_CALL_STATE);
}

private class MyPhoneStateListener extends PhoneStateListener
{
private static final int CALL_STATE_RINGING = 1;
private static final int CALL_STATE_IDLE = 0;

public void onCallStateChanged (int state, String incomingNumber)
{
if (state == CALL_STATE_RINGING) {
resolveNumber(incomingNumber);
}
}
}

private void resolveNumber ( String incomingNumber)
{
int duration = Toast.LENGTH_SHORT;
CharSequence text = incomingNumber;
Toast toast = Toast.makeText(this, text, duration); *=== How do i
get context here*
toast.show();
}
}

-- Vikrant



On Wed, Sep 22, 2010 at 5:08 PM, Mark Murphy mmur...@commonsware.comwrote:

 On Wed, Sep 22, 2010 at 7:35 AM, Vijay Vikrant vijayvikran...@gmail.com
 wrote:
Can somebody throw some light on how to display a
  pop-up/notification/toast while i am in a broadcast receiver. Toast
 expects
  a context and i don't have a context to pass.

 Sure you do. Look at the first parameter to onReceive().

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

 _The Busy Coder's Guide to Android Development_ Version 3.1 Available!

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

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

[android-developers] Java Guru Query: override a method taking a reflected class argument

2010-09-22 Thread Pent
Since API 7, PhoneStateListener has a function:

void onSignalStrengthsChanged( SignalStrength signalStrength )

Question: how can I override this via reflection so that I can stay
backwards
compatible with earlier APIs that don't have the SignalStrength
class ?

If I make the argument an Object, the signature changes of course.

TIA,

Pent

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


Re: [android-developers] pop-up/toast notification without activity/context

2010-09-22 Thread Vijay Vikrant
got my answers.. sorry for being so stupid..
-- Vikrant



On Wed, Sep 22, 2010 at 5:25 PM, Vijay Vikrant vijayvikran...@gmail.comwrote:

 Thanks for responding..

 Below is a shabby but simple piece of code that i am experimenting with..
 The onReceive function does have a context - But i just register a
 phonestate listener in there and then i have to raise a toast while i am in
 the phonestatelistener function. What can i change?


 package com.android.prankapp;

 import android.content.BroadcastReceiver;
 import android.content.Context;
 import android.content.Intent;
 import android.os.Bundle;
 import android.telephony.PhoneStateListener;
 import android.telephony.TelephonyManager;
 import android.util.Log;
 import android.content.BroadcastReceiver;
 import android.widget.Toast;

 public class PrankAApp extends BroadcastReceiver {

 @Override
 public void onReceive(Context context, Intent intent) {
 Log.d(PrankAApp,BEGIN1);
 if(intent.getData()!=null)
 {
 Log.d(PrankAApp,intent.getDataString() );
 }
 else
 {
 Log.d(PrankAApp,DataString == NULL );
 }
 Log.d(PrankAApp,intent.toString());
 TelephonyManager myTelManager =
 (TelephonyManager)context.getSystemService(context.TELEPHONY_SERVICE);
 MyPhoneStateListener myListner = new MyPhoneStateListener();
 myTelManager.listen(myListner,
 PhoneStateListener.LISTEN_CALL_STATE);
 }

 private class MyPhoneStateListener extends PhoneStateListener
 {
 private static final int CALL_STATE_RINGING = 1;
 private static final int CALL_STATE_IDLE = 0;

 public void onCallStateChanged (int state, String incomingNumber)
 {
 if (state == CALL_STATE_RINGING) {
 resolveNumber(incomingNumber);
 }
 }
 }

 private void resolveNumber ( String incomingNumber)
 {
 int duration = Toast.LENGTH_SHORT;
 CharSequence text = incomingNumber;
 Toast toast = Toast.makeText(this, text, duration); *=== How do i
 get context here*
 toast.show();
 }
 }

 -- Vikrant




 On Wed, Sep 22, 2010 at 5:08 PM, Mark Murphy mmur...@commonsware.comwrote:

 On Wed, Sep 22, 2010 at 7:35 AM, Vijay Vikrant vijayvikran...@gmail.com
 wrote:
Can somebody throw some light on how to display a
  pop-up/notification/toast while i am in a broadcast receiver. Toast
 expects
  a context and i don't have a context to pass.

 Sure you do. Look at the first parameter to onReceive().

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

 _The Busy Coder's Guide to Android Development_ Version 3.1 Available!

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




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

[android-developers] Trouble with TableLayout wrapping text

2010-09-22 Thread Doug Gordon
I have a 2-column table where the right-hand column in the rows might
have too much text to fit on one line, so I wanted it to wrap and
expand the table cell similar to the way it would work on a web page.
This turned out to be more difficult than I expected. When I
configured that TextView to wrap_content for both width and height,
the text would wrap, but not correctly. Some of the text was missing
as though the lines were extending past the right edge of the screen.

I finally solved it by putting shrinkColumns on the 2nd column; the
text wraps and it's all there. But I'm still curious as to what the
problem was with the off-screen wrapping. The table is fill_parent
wide, so how can a row exceed its width? And why did shrinkColumns fix
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: Please help me with calculating direction from point A to B

2010-09-22 Thread Per
this works for me:

1: listen to location changes. Store the most recent location. You
need it below.
2: listen to orientation changes. Store the most recent heading
(azimuth) in mHeading - that's the compass direction corresponding to
your viewing direction when holding your phone horizontally in
portrait mode;
3: the bearing to your destination (assuming you have its coordinates)
can be found using Location.distanceBetween() (call it mBearing)
4: to point your directional arrow towards the destination, its
required rotation (from 'up') is  ((mBearing - mHeading)+360) % 360;

You may wish to compensate for device rotation (portrait/landscape),
too. See Display.getOrientation / Display.getRotation

Not a complete 3D solution, but works ok.

/Per


(not sure if the terms bearing/heading are 100% in sync with common
naval use, but hey...)

On 22 Sep., 11:28, Kostya Vasilyev kmans...@gmail.com wrote:
   Pedro,

 I think you should learn something about the way direction (and
 orientation) is specified in computer programming.

 http://en.wikipedia.org/wiki/Yaw,_pitch,_and_roll

 http://en.wikipedia.org/wiki/Euler_angles

 http://en.wikipedia.org/wiki/Rotation_representation_(mathematics)#Ro...

 I believe that Android orientation sensors work this way.

 Now about the compass

 There are two ways you can think about this:

 First, take the value you get from the algorithm and make it into a
 vector in 3D space (i.e. think of the arrow you're going to draw to
 indicate direction). Then:

 One: Compute the device's orientation matrix using sensor data. Take the
 inverse of this matix, and multiply the arrow vector by this matrix.

 Two: Compute the device's orientation matrix using sensor data. Rather
 than interpreting it as a rotation matrix, think of it as defining a
 plane in space (aligned with the device's screen).  Then project the
 arrow vector onto this plane, in the plane's coordinates.

 You might want to start with compensating just for the vertical axis
 (the device's rotation from the true north direction), it might be enough.

 -- Kostya

 22.09.2010 13:02, Pedro Teixeira пишет:





  I'm really not understanding how to go with this...

  I've been reading and reading.. I can find all kind of algorithms.. I
  can find a haversin algorithm that points me to the correct direction
  if my device is pointing north.. but the needle is static... so if i
  change the device orientation the measure is incorrect... and I know
  this happens because I'm not using device's sensor values like
  azimuth, pitch and roll.. oh god.. 2 weeks on this.. I'm just
  desperate now.

  On Sep 18, 2010, at 10:29 AM, Kostya Vasilyev wrote:

  Pedro,

  If I understand you correctly, you are having difficulties with the
  device's orientation.

  The bearing angle seems to be computed in the horizontal plane. If
  you wish to adjust for the device's orientation, you need to
  concatenate it with the bearing angle.

  Google for quaternions.

  This is a (relatively) simple math technique to work with rotations
  the same way you can work with vectors: add / subtract, interpolate.

  -- Kostya

  18.09.2010 0:56, Pedro Teixeira пишет:
  Hi everyone...

  I'm back with the same issue for the last couple of days… I'm trying
  to create a compass for my application BUT the difference is that,
  instead of having a line always pointing to north, I want this line to
  point for a specific point. I've been trying dozens of algorithms and
  nothing works..
  I've finally found one that points me exactlly to the point I want..
  BUT it doesn't move if I change the position of the device which is my
  objective.. basicly, what I want is that no matter the direction I'm
  using my device.. the line always point me to the point
  (picLatitude,picLongitude)…

  I understood that for the line to move, I can't use static variables…
  I need to use the values offered by the onSensorChanged(SensorEvent
  event).

  This are the data I have available:

  event.values[0]: azimuth, rotation around the Z axis (device in
  relation to north, 0º)
  event.values[1]: pitch, rotation around the X axis
  event.values[2]: roll, rotation around the Y axis
  mLatitude: device current latitude gottern from GPS (variable)
  mLongitude: device current longitude gotten from GPS (variable)
  picLatitude: static picture latitude established previously
  picLongitude: static picture longitude established previously
  distance: distance in Km from device to the picture calculated
  previously

  And this the formula that works correct, and gives me the correct
  angle.. ( BUT IT DOESN'T USE ANY OF THE SENSOR DATA SO THE LINE
  COMPASS DOESNT MOVE):

  double dLong = picLongitude - mLongitude;
  double y =  (Math.sin(dLong) * Math.cos(picLatitude));
  double x =  (Math.cos(mLatitude) * Math.sin(picLatitude) -
  Math.sin(mLatitude)*Math.cos(picLatitude)*Math.cos(dLong));
  double angleDegreesWrongRange = Math.abs(Math.toDegrees(Math.atan2(y,
  x)));
  

[android-developers] Re: Nokia inviting Developers to become an Ovi store publisher.

2010-09-22 Thread DanH
The Nokia platforms running Qt are probably generally friendlier to
the programmer than Android, and market penetration of the Nokia
phones in Europe is quite high.  Plus problems with piracy are much
less.  The main downsides are the crummy pressure-sensitive touch
screens and the short battery life.

That said, this is a really clumsy spamming effort, and I'm a little
surprised that Nokia is (apparently) doing it.  (Unless this is the
first work of that new marketing manager they hired off of Microsoft.)

On Sep 21, 1:03 pm, SheikhAman shekh.a...@gmail.com wrote:
 I don't think Nokia is interested in Android.
 all they want you to come in for is Meego.

 On Sep 21, 2:25 pm, Kumar Bibek coomar@gmail.com wrote:

  Definitely a SPAM...

  On Sep 20, 8:23 pm, TreKing treking...@gmail.com wrote:

   On Mon, Sep 20, 2010 at 2:27 AM, James Baker 
   james.baker...@gmail.comwrote:

If u are a developer nd dream it big then grab this opportunity today.

   I think this says it all.

   If u try it out post back nd let us know how it goes.

   -
   TreKing http://sites.google.com/site/rezmobileapps/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] ACTION_VIEW exception

2010-09-22 Thread Neilz
I try and open up a new activity, pointing to the market, with the
following code:

Intent i = new Intent(android.content.Intent.ACTION_VIEW);
i.setData(Uri.parse(myMarketDetialsHere));
startActivity(i);

It works fine on the device, but the Emulator throws an Exception:

android.content.ActivityNotFoundException: No Activity found to handle
Intent { action=android.intent.action.VIEW data=market://search?
q=MyMarketDetailsHere }

I'm not sure if this is just an emulator thing, or whether this could
replicate on a real device?

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

2010-09-22 Thread DanH
OK, checked that domain name, and it appears to be hosted out of
Houston TX.  Not at all what I'd expect for a Nokia site.  So odds are
it's a phishing site.

Odd that so much work went into the site -- hard to see what they
expect to gain.

On Sep 22, 7:16 am, DanH danhi...@ieee.org wrote:
 The Nokia platforms running Qt are probably generally friendlier to
 the programmer than Android, and market penetration of the Nokia
 phones in Europe is quite high.  Plus problems with piracy are much
 less.  The main downsides are the crummy pressure-sensitive touch
 screens and the short battery life.

 That said, this is a really clumsy spamming effort, and I'm a little
 surprised that Nokia is (apparently) doing it.  (Unless this is the
 first work of that new marketing manager they hired off of Microsoft.)

 On Sep 21, 1:03 pm, SheikhAman shekh.a...@gmail.com wrote:

  I don't think Nokia is interested in Android.
  all they want you to come in for is Meego.

  On Sep 21, 2:25 pm, Kumar Bibek coomar@gmail.com wrote:

   Definitely a SPAM...

   On Sep 20, 8:23 pm, TreKing treking...@gmail.com wrote:

On Mon, Sep 20, 2010 at 2:27 AM, James Baker 
james.baker...@gmail.comwrote:

 If u are a developer nd dream it big then grab this opportunity today.

I think this says it all.

If u try it out post back nd let us know how it goes.

-
TreKing http://sites.google.com/site/rezmobileapps/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: LVL returns LICENSED with anonymous accounts...

2010-09-22 Thread MarcoAndroid
I do see this behaviour too (though dev account on emulator and test
account on N1). My next thing to try would be uploading my app (but
not publishing it) to see if that then gives back what I set in the
dev console... Though from previous answers I probably get back
LICENSED which as you say is not very handy for real device testing...


On 27 aug, 11:21, Mark Carter mjc1...@googlemail.com wrote:
 Can anyone else confirm this please?

 On Aug 20, 11:27 am, Mark Carter mjc1...@googlemail.com wrote:



  This is not what I'm seeing.

  I'm writing a new app which has never been published or in draft.

  I have two devices. One (N1, running 2.2), I'm logged into my main
  Google account (which has the Developer account). The other (Hero
  running 2.1-update1) is a test account I use (no developer account).

  When I use the N1, I always get the response specifed in my Dev
  Console settings.
  When I use the Hero, I always get ERROR_NOT_MARKET_MANAGED.

  It appears the logic goes something like this for non-Market
  (published or draft) apps:

  Check the user has a Dev account.
  If so, use the response set there.
  If not, return ERROR_NOT_MARKET_MANAGED.

  Notice, its the setting for the user, not the dev (because theMarket
  does not know who the dev is), that is used.

  Anyone confirm this?

  On Aug 7, 1:26 am, Trevor Johns tjo...@google.com wrote:

   If an app is not published AND not draft, then you'll get
   ERROR_NOT_MARKET_MANAGED.

   If an app is in draft (never published), then we sendLICENSEDfor all
   requests for that app.

   If an app is published (or has been published then unpublished), then
   the response
   is driven by the dev console settings for the developer/testers, and 
   purely
   by purchase history for everyone else.

   --
   Trevor Johns
   Google Developer Programs, Androidhttp://developer.android.com

   On Thu, Aug 5, 2010 at 4:18 AM, Mark Carter mjc1...@googlemail.com 
   wrote:
So to confirm. If an app is not published (nor draft) then the response 
is
dictated by the user's (i.e. the user running the app, not the one who
developed the app) setting in the Dev Console. If the user does not 
have a
Dev account (like many beta testers) then the response will be like 
Respond
normally?

If the app is published (or draft) then the response is driven 
primarily by
the dev's console settings and secondarily by theMarketlicense server
(storing who has paid for what).

 I think the first part could catch a lot of people out...

On 5 August 2010 11:03, Trevor Johns tjo...@google.com wrote:

If the app isn't in AndroidMarket, the license server will return
ERROR_NOT_MARKET_MANAGED. LicenseValidator considers that to be a fatal
error due to programmer error, and should invoke the applicationError()
callback method.

My understanding from the server team is that uploading a draft 
version is
supposed to be sufficient to avoid getting ERROR_NOT_MARKET_MANAGED. 
(In the
case of existing applications, you'll also need to increment your 
version
code.)

The other way you'll avoid this is precisely as Mark mentioned. If we
don't find the application, we check to see if the current user has a
developer account, and will send a test response (if one is set) using 
the
user's RSA keypair.

--
Trevor Johns

On Wed, Aug 4, 2010 at 12:30 AM, Kirky rob.kirkbr...@gmail.com wrote:

Trevor,

Can you clarify what the licensing server returns if the App is not in
the AndroidMarket? In my experience (and it seems other people) it is
returningLICENSED. This does not seem sensible to me.

Thanks

Rob

On Aug 4, 3:23 am, Trevor Johns tjo...@google.com wrote:

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

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

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

[android-developers] Re: Nokia inviting Developers to become an Ovi store publisher.

2010-09-22 Thread DanH
(I've reported this problem to Nokia through a couple of routes.)

On Sep 22, 7:32 am, DanH danhi...@ieee.org wrote:
 OK, checked that domain name, and it appears to be hosted out of
 Houston TX.  Not at all what I'd expect for a Nokia site.  So odds are
 it's a phishing site.

 Odd that so much work went into the site -- hard to see what they
 expect to gain.

 On Sep 22, 7:16 am, DanH danhi...@ieee.org wrote:

  The Nokia platforms running Qt are probably generally friendlier to
  the programmer than Android, and market penetration of the Nokia
  phones in Europe is quite high.  Plus problems with piracy are much
  less.  The main downsides are the crummy pressure-sensitive touch
  screens and the short battery life.

  That said, this is a really clumsy spamming effort, and I'm a little
  surprised that Nokia is (apparently) doing it.  (Unless this is the
  first work of that new marketing manager they hired off of Microsoft.)

  On Sep 21, 1:03 pm, SheikhAman shekh.a...@gmail.com wrote:

   I don't think Nokia is interested in Android.
   all they want you to come in for is Meego.

   On Sep 21, 2:25 pm, Kumar Bibek coomar@gmail.com wrote:

Definitely a SPAM...

On Sep 20, 8:23 pm, TreKing treking...@gmail.com wrote:

 On Mon, Sep 20, 2010 at 2:27 AM, James Baker 
 james.baker...@gmail.comwrote:

  If u are a developer nd dream it big then grab this opportunity 
  today.

 I think this says it all.

 If u try it out post back nd let us know how it goes.

 -
 TreKing http://sites.google.com/site/rezmobileapps/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] Drawing a line dynamically in code

2010-09-22 Thread Kevin Courtney
Hello,



This seems like a basic question but I’ve been struggling with it and need
another set of eyes to set me straight.



I’m trying to draw a line using code in a RelativeLayout and it’s not
showing up.  I have this XML file:



?xml version=*1.0* encoding=*utf-8*?

shape xmlns:android=*http://schemas.android.com/apk/res/android*

android:shape=*line*

stroke android:width=*1dp* android:colora=*#FF*/

size android:height=*15dp* /

/shape



I use this file when drawing a line from straight XML and it works fine.


But now I’m trying to use it to draw a line dynamically, in this code…



ScrollView sv = *new* ScrollView(*this*);

  RelativeLayout relativeLayout = *new* RelativeLayout(*this*);

 relativeLayout.setBackgroundResource(R.drawable.*gradient_box*
);



  sv.addView(relativeLayout);



  ImageView imageLineView2 = *new* ImageView(*this*);;

  imageLineView2.setBackgroundResource(R.drawable.*dividing_line_1*);

  RelativeLayout.LayoutParams lpEndOfInfoLineId2 =

   *new* RelativeLayout.LayoutParams(

*   *RelativeLayout.LayoutParams.*WRAP_CONTENT*,

 RelativeLayout.LayoutParams.*FILL_PARENT*);

  relativeLayout.addView(imageLineView2,lpEndOfInfoLineId2);



  // have buttons, text, and images here that show up fine.



  *this*.setContentView(sv);



It uses the same background as my successful use from the XML file so I
don’t think it’s blending into the background.



Do any of you have any suggestions on what I’m missing?



Thanks in advance,



Kevin

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

[android-developers] Re: LVL NOT_MARKET_MANAGED

2010-09-22 Thread MarcoAndroid
My guess is that when the version of the app making thecheck  is lower
than the latest in the market, LICENSED_OLD_KEY is returned as per
http://developer.android.com/guide/publishing/licensing.html#server-response-codes

Is the version of the app making the check higher, then that should be
you testing a new version and you can overwrite via the dev console I
guess.

On 31 jul, 23:45, Brian avalo...@caerleon.us wrote:
 I've done some testing on this, myself, and it seems that it only
 returns theNOT_MARKET_MANAGEDerror for an app in the market if the
 version code (the integer form of the version number in the manifest)
 in the copy making the check is higher than the one currently in the
 market.  If the version code in the copy of the app making the check
 is less than or equal to the current one in the market, then the
 normal license valid/invalid response is given unless there's another
 error.

 That seems acceptable to me, even if it is a bit odd considering the
 docs imply that it indicates only a package name mismatch.

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

2010-09-22 Thread Peter
I also thought about missing permission but I can not find a suitable
one. Could it be a problem of the filesystem at the end the database
is nothing more than a file. Do I need to create it beforehands?

Please, any help would be great.

On 21 Sep., 20:31, Peter peter.osb...@gmail.com wrote:
 Hi list,

 I am trying to develop an application which shall use an
 SQLiteDatabase to store some objects. I went through several tutorials
 and also took a look at the notepad example code in the android code
 section. I always get one and a same exception of which I can't figure
 out why it happens.

 I extended the SQLiteOpenHelper class and in my Activity I try to call
 the getReadableDatabase() method. When I take a look at the StackTrace
 of the exception, I can see that it is thrown in
 ContextWrapper.openOrCreateDatabase().

 09-21 18:07:44.103: ERROR/Homepage Ping(339): null
 09-21 18:07:44.103: ERROR/Homepage Ping(339):
 java.lang.NullPointerException
 09-21 18:07:44.103: ERROR/Homepage Ping(339):     at
 android.content.ContextWrapper.openOrCreateDatabase(ContextWrapper.java:
 193)
 09-21 18:07:44.103: ERROR/Homepage Ping(339):     at
 android.database.sqlite.SQLiteOpenHelper.getWritableDatabase(SQLiteOpenHelp 
 er.java:
 98)
 09-21 18:07:44.103: ERROR/Homepage Ping(339):     at
 android.database.sqlite.SQLiteOpenHelper.getReadableDatabase(SQLiteOpenHelp 
 er.java:
 158)
 09-21 18:07:44.103: ERROR/Homepage Ping(339):     at
 de.peterosburg.android.homepagePing.HomepagePing.initializeWebsites(Homepag 
 ePing.java:
 72)
 09-21 18:07:44.103: ERROR/Homepage Ping(339):     at
 de.peterosburg.android.homepagePing.HomepagePing.init(HomepagePing.java:
 38)
 09-21 18:07:44.103: ERROR/Homepage Ping(339):     at
 java.lang.Class.newInstanceImpl(Native Method)
 09-21 18:07:44.103: ERROR/Homepage Ping(339):     at
 java.lang.Class.newInstance(Class.java:1479)
 09-21 18:07:44.103: ERROR/Homepage Ping(339):     at
 android.app.Instrumentation.newActivity(Instrumentation.java:1021)
 09-21 18:07:44.103: ERROR/Homepage Ping(339):     at
 android.app.ActivityThread.performLaunchActivity(ActivityThread.java:
 2409)
 09-21 18:07:44.103: ERROR/Homepage Ping(339):     at
 android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:
 2512)

 The code of my class looks as follows:

 public class WebsiteData extends SQLiteOpenHelper {

         private static final String DATABASE_NAME = SITES_DATABASE_NAME;
         private static final int DATABASE_VERSION = 1;

         private static String[] FROM = { _ID, SITE_IDENTIFIER, SITE_URL, };
         private static String ORDER_BY = _ID +  ASC;

         public WebsiteData(Context cntxt){
                 super(cntxt, DATABASE_NAME, null, DATABASE_VERSION);
         }

         @Override
         public void onCreate(SQLiteDatabase db) {
                 Log.w(HomepagePing.tag, Creating Websites db);

                 db.execSQL(CREATE TABLE + SITES_TABLE_NAME + (
                                 + _ID +  INTEGER PRIMARY KEY AUTOINCREMENT, 
                                 + SITE_IDENTIFIER +  TEXT NOT NULL 
                                 + SITE_URL +  TEXT NOT NULL
                                 + ););
         }

         @Override
         public void onUpgrade(SQLiteDatabase db, int oldVersion, int
 newVersion) {
                 db.execSQL(DROP TABLE IF EXISTS  + SITES_TABLE_NAME);
                 onCreate(db);
         }

 }

 Within my activity I do the following:

 try{
                         //this.sites_db =
 this.openOrCreateDatabase(SITES_DATABASE_NAME, MODE_PRIVATE, null);
                         WebsiteData data = new WebsiteData(this);
                         SQLiteDatabase db = data.getReadableDatabase();

                 } catch(Exception e){
                         Log.e(HomepagePing.tag, e.getMessage(), e);
                 }

 As you can see the Exception is written to the log at exactly this try-
 catch-block. I squeezed the hell out of Google but couln't find any
 solution yet.

 Any help is highly appreciated.
 I am using an Emulator with API Level 7 (Android2.1-update1)

 If you need any more information, let me know and I try to share it.

 Regards,
 Peter

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


[android-developers] Re: ACTION_VIEW exception

2010-09-22 Thread Chris Stratton
Unless I am remembering wrong, the emulator doesn't have market.

It would also happen if someone manages to get your apk onto a device
without market (of which there are many, especially non-phone tablets)

On Sep 22, 8:17 am, Neilz neilhorn...@gmail.com wrote:
 I try and open up a new activity, pointing to the market, with the
 following code:

 Intent i = new Intent(android.content.Intent.ACTION_VIEW);
 i.setData(Uri.parse(myMarketDetialsHere));
 startActivity(i);

 It works fine on the device, but the Emulator throws an Exception:

 android.content.ActivityNotFoundException: No Activity found to handle
 Intent { action=android.intent.action.VIEW data=market://search?
 q=MyMarketDetailsHere }

 I'm not sure if this is just an emulator thing, or whether this could
 replicate on a real device?

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


[android-developers] Re: wifi not remembering the access point

2010-09-22 Thread Irfan Sheriff
What does the output of $adb shell wpa_cli list_networks look like before
and after you restart wifi?

You could also try doing a $adb shell wpa_cli save_config after adding a
network and doing restart and see if it makes a difference.

On Wed, Sep 22, 2010 at 3:37 AM, kiran kiranbhat2...@gmail.com wrote:

 Hi All
 i am using ralink wifi driver in android, i am able to connect to
 the access-point using the Wireless Settings provided in the Android, But
 once i connect to the network and restart the wifi i have to reconnect
 manually by providing the authentication key. Wifi Manager is not
 remembering the last access point used . i am using the Settings application
 provided by the android.

 Regards
 Kiran

 --
 You received this message because you are subscribed to the Google Groups
 android-ndk group.
 To post to this group, send email to android-...@googlegroups.com.
 To unsubscribe from this group, send email to
 android-ndk+unsubscr...@googlegroups.comandroid-ndk%2bunsubscr...@googlegroups.com
 .
 For more options, visit this group at
 http://groups.google.com/group/android-ndk?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] uninstall missing..

2010-09-22 Thread Vijay Vikrant
Hello,

I made a test app and installed it on my phone. This app kicks in everytime
i get a incoming call and pops up something. I successfully installed this
app on my phone and it seems to be working as desired. But i don't see it in
the settings-applications list. How do i uninstall this app?

Many Thanks,
Vikrant

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

2010-09-22 Thread TreKing
On Wed, Sep 22, 2010 at 4:16 AM, Christoffer Davidsson 
christof...@chlirre.com wrote:

 However, running 2.1 in the Emulator, both methods are called when I start
 my Service.


I don't suppose you're calling super.onStartCommand, are you?

-
TreKing http://sites.google.com/site/rezmobileapps/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] New SDK causes Slow Debugging on N1

2010-09-22 Thread Xavier Ducrohet
Nothing changed in that part. All the tool does anyway is connect the
Eclipse debugger to the device VM.

Xav

On Mon, Sep 20, 2010 at 2:26 PM, ADRA dche...@gmail.com wrote:
 I've got a Nexus One running a debug version of my application, and I
 just today downloaded and installed the 0.9.8 version of the SDK
 tools, and I swear that Debugging latency has increased incredibly. I
 never bothered to measure the overhead before the upgrade because I
 always found the phone's debugging overhead to be small enough to not
 affect matter. Well, now I have AI code which runs at ~10 MS
 standalone taking 300-400MS through debugging. A 40X performance loss
 is not something to cough at. Is it just me not seeing the performance
 loss previously, or has something broken?

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




-- 
Xavier Ducrohet
Android SDK Tech Lead
Google Inc.

Please do not send me questions directly. 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] Determing end of Scroll View scroll

2010-09-22 Thread ben
Is there any way you to determine the pixel value where a scroll view
stops on a fling. It's easy enough to find when the user is scrolling
the view with a touch but I see no way to determine the end point of a
fling. The only solution I could come up with is to use a gesture
detector to catch a fling and then calculate where it would stop based
on the velocity, is that the best way?

I'm trying to create a view that will indicate to the user when there
is more to scroll to, and then have the indicator vanish when the
scroll view is at the beginning or end.

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

2010-09-22 Thread Xavier Ducrohet
hmm this is strange. The warning is normal but it should still work.

We're fixing this for the next version of the tools, but as Dianne
said, 2.0.1 is considered obsolete and there's no point targeting it.
You can target 2.1 (API 7).

Xav

On Tue, Sep 21, 2010 at 6:47 AM, Leigh McRae
leigh.mc...@lonedwarfgames.com wrote:
 I have updated my tools to revision 7 and now I can't do a build as it
 says the API level is obsolete.  I can understand warning but it won't
 build at all.  I am using android.bat to generate a build.xml for
 release versions.  So the build.xml gets made from scratch each time.
 If I switch to --target 8 it builds but I have already released it on
 the Android Market with 6.  Won't this mean that some people that have
 Android 2.0.1 won't be able to run it?

 android update project --name Tanks --target 6 --path $
 {dist.project.dir}

    [setup] Android SDK Tools Revision 7
    [setup] Project Target: Android 2.0
    [setup] API level: 5
    [setup]
    [setup]
    [setup]
    [setup]
 ***
    [setup] WARNING: This platform is obsolete and its Ant rules may
 not work properly.
    [setup] WARNING: It is recommended to develop against a newer
 version of Android.
    [setup] WARNING: For more information about active versions of
 Android see:
    [setup] WARNING: 
 http://developer.android.com/resources/dashboard/platform-versions.html
    [setup]
 ***
    [setup]
    [setup]
    [setup]
    [setup]
    [setup] --
    [setup] Resolving library dependencies:
    [setup] --
    [setup] Ordered libraries:
    [setup] --
    [setup]

 BUILD FAILED
 D:\Android\build.xml:68: The following error occurred while executing
 this line:
 D:\Android\build.xml:215: The following error occurred while executing
 this line:
 D:\Android\dist\market-lite\build.xml:82: Build rules file 'D:\Program
 Files\android-sdk-windows\tools\ant\android_rules.xml' is missing.

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




-- 
Xavier Ducrohet
Android SDK Tech Lead
Google Inc.

Please do not send me questions directly. 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] Build with SDK tool rev 7, gives error: if doesn't support the nested istrue element

2010-09-22 Thread Xavier Ducrohet
We have our own if task since it's not standard. If you are using
another if task there may be a conflict (ours doesn't support this)

On Sat, Sep 18, 2010 at 2:24 PM, Huey ly.h...@gmail.com wrote:
 Our project was built  fine with SDK tool rev 6 and Ant version 1.7.1.
 After updating the SDK tool to rev 7 we start seeing error:

 if doesn't support the nested istrue element

 below is ant task has istrue:

    taskdef name=setup
        classname=com.android.ant.SetupTask
        classpathref=android.antlibs/
                if
                !--  This work fine with SDK tool Rev 6  --
                istrue value=${build.debug}/
                then
                                mkdir dir=${build.dist}/dbg_libs//
                /then
                else
                                mkdir dir=${build.dist}/rel_libs//
                /else
        /if

    setup /

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




-- 
Xavier Ducrohet
Android SDK Tech Lead
Google Inc.

Please do not send me questions directly. 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] Threading and the emulator

2010-09-22 Thread kypriakos

Hi all,

Are there any limits on the number of threads or any constraints
on how the emulator (under Eclipse) schedules the application
threads? I get suspended threads that don't really wait on anything
but rather get bumped out from execution time ... I will try using the
Debug class to get some statistics on the thread alloc etc. even
though
the DDMS does that already.

One example is, I have a simple class that simply prints a '.' every
3 seconds - well, the LogCat shows the emulator collecting garbage
objects but the thread is suspended and does not print the '.' ... I
may
be missing something simple here

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] gps and wifi

2010-09-22 Thread TreKing
On Wed, Sep 22, 2010 at 6:30 AM, student alsharewit...@gmail.com wrote:

 my problem is if user came back to room it should be indicated the network
 by comparing the frequency or  speed with gps?


I'm sorry ... what?

-
TreKing http://sites.google.com/site/rezmobileapps/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: overriding Home button

2010-09-22 Thread ferar
thanks ...

On Sep 21, 3:29 pm, Bret Foreman bret.fore...@gmail.com wrote:
 This group is for application development and I think you want the
 platform development group.

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


Re: [android-developers] Build with SDK tool rev 7, gives error: if doesn't support the nested istrue element

2010-09-22 Thread Xavier Ducrohet
btw if you want to use our custom if task you can, the syntax is:
if condition=${build.debug}then.../thenelse/else/if

For the next tools update we should probably rename our task to
androidif to be sure it doesn't interfere with another if task.


On Wed, Sep 22, 2010 at 7:21 AM, Xavier Ducrohet x...@android.com wrote:
 We have our own if task since it's not standard. If you are using
 another if task there may be a conflict (ours doesn't support this)

 On Sat, Sep 18, 2010 at 2:24 PM, Huey ly.h...@gmail.com wrote:
 Our project was built  fine with SDK tool rev 6 and Ant version 1.7.1.
 After updating the SDK tool to rev 7 we start seeing error:

 if doesn't support the nested istrue element

 below is ant task has istrue:

    taskdef name=setup
        classname=com.android.ant.SetupTask
        classpathref=android.antlibs/
                if
                !--  This work fine with SDK tool Rev 6  --
                istrue value=${build.debug}/
                then
                                mkdir dir=${build.dist}/dbg_libs//
                /then
                else
                                mkdir dir=${build.dist}/rel_libs//
                /else
        /if

    setup /

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




 --
 Xavier Ducrohet
 Android SDK Tech Lead
 Google Inc.

 Please do not send me questions directly. Thanks!




-- 
Xavier Ducrohet
Android SDK Tech Lead
Google Inc.

Please do not send me questions directly. 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: 1-star Market weirdness

2010-09-22 Thread dm1973
Everyone has their own criteria. I released a game and got a ton of
4/5 star ratings and a bunch of 1/2 stars that said things like Fun
game but I prefer games like Halo. Yes my 2d puzzle game is a
horrible Halo clone. Read the reviews for bugs/things to improve and
learn to ignore the really odd reviews. You will be happier

On Sep 21, 4:29 pm, mah m...@heilpern.com wrote:
 I have an app with only 8 ratings, at 4 stars overall. One of the
 ratings was a 1 star rating, and it included a comment that states my
 app would be better if some feature it doesn't claim to support was
 supported, but it's a good app.

 Let me rephrase that: it's a good app, but it doesn't support X so I'm
 giving it 1 star.

 My personal feeling is not that feature X will turn his 1 star rating
 into 5 stars, but that he didn't intend to rate me in what is
 effectively a negative manner. Oh well, at least the other raters have
 the same understanding that I have, with regards to what 1star vs. 5
 means.

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

2010-09-22 Thread Neilz
Ah yes I believe you're right. So as long as my code works on the
actual device, I shouldn't be concerned then.

On Sep 22, 2:38 pm, Chris Stratton cs07...@gmail.com wrote:
 Unless I am remembering wrong, the emulator doesn't have market.

 It would also happen if someone manages to get your apk onto a device
 without market (of which there are many, especially non-phone tablets)


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

2010-09-22 Thread Bret Foreman
I would love to see this information set out in tabular form. I'm
always suspicious of a missing case until I see a truth table of the
logic.

On Aug 6, 4:26 pm, Trevor Johns tjo...@google.com wrote:
 If an app is not published AND not draft, then you'll get
 ERROR_NOT_MARKET_MANAGED.

 If an app is in draft (never published), then we send LICENSED for all
 requests for that app.

 If an app is published (or has been published then unpublished), then
 the response
 is driven by the dev console settings for the developer/testers, and purely
 by purchase history for everyone else.

 --
 Trevor Johns
 Google Developer Programs, Androidhttp://developer.android.com


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


[android-developers] Re: ACTION_VIEW exception

2010-09-22 Thread Chris Stratton
Essentially.  Though you might want to decide what should happen when
it inevitably finds its way to a device without market - ie, fail
gracefully with minimal reduction in functionality or Your device
does not support this application or Your device is not authorized
to run this application or This is a pirated install.  Fail! -
essentially depending on how you feel about people re-distributing
your app via other channels in non-market countries and communities
built around non-market tablets and MIDs.

On Sep 22, 11:07 am, Neilz neilhorn...@gmail.com wrote:
 Ah yes I believe you're right. So as long as my code works on the
 actual device, I shouldn't be concerned then.

 On Sep 22, 2:38 pm, Chris Stratton cs07...@gmail.com wrote:

  Unless I am remembering wrong, the emulator doesn't have market.

  It would also happen if someone manages to get your apk onto a device
  without market (of which there are many, especially non-phone tablets)



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

2010-09-22 Thread Vijay Vikrant
Hello,

Since the market is not open to India for paid apps - What will be a
good server/store to host paid apps that target indian audiences?

Many Thanks,
Vikrant

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

2010-09-22 Thread Bret Foreman
Tre,

I think he's talking about finding location from the GPS (by
satellite) or from the network (by base station and sector). He's
trying to manage which mode to use in which situation and how/when to
switch.

On Sep 22, 7:44 am, TreKing treking...@gmail.com wrote:
 On Wed, Sep 22, 2010 at 6:30 AM, student alsharewit...@gmail.com wrote:
  my problem is if user came back to room it should be indicated the network
  by comparing the frequency or  speed with gps?

 I'm sorry ... what?

 -
 TreKing http://sites.google.com/site/rezmobileapps/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: Please help me with calculating direction from point A to B

2010-09-22 Thread Pedro Teixeira

I'll try this method you described.

I have 1. 2. and the destinations coordinates of 3.So I guess I can  
use it


PS: I just want this for landscape mode, I've set it on the Manifest  
already.


On Sep 22, 2010, at 1:12 PM, Per wrote:


this works for me:

1: listen to location changes. Store the most recent location. You
need it below.
2: listen to orientation changes. Store the most recent heading
(azimuth) in mHeading - that's the compass direction corresponding to
your viewing direction when holding your phone horizontally in
portrait mode;
3: the bearing to your destination (assuming you have its coordinates)
can be found using Location.distanceBetween() (call it mBearing)
4: to point your directional arrow towards the destination, its
required rotation (from 'up') is  ((mBearing - mHeading)+360) % 360;

You may wish to compensate for device rotation (portrait/landscape),
too. See Display.getOrientation / Display.getRotation

Not a complete 3D solution, but works ok.

/Per


(not sure if the terms bearing/heading are 100% in sync with common
naval use, but hey...)

On 22 Sep., 11:28, Kostya Vasilyev kmans...@gmail.com wrote:

  Pedro,

I think you should learn something about the way direction (and
orientation) is specified in computer programming.

http://en.wikipedia.org/wiki/Yaw,_pitch,_and_roll

http://en.wikipedia.org/wiki/Euler_angles

http://en.wikipedia.org/wiki/Rotation_representation_(mathematics)#Ro...

I believe that Android orientation sensors work this way.

Now about the compass

There are two ways you can think about this:

First, take the value you get from the algorithm and make it into a
vector in 3D space (i.e. think of the arrow you're going to draw to
indicate direction). Then:

One: Compute the device's orientation matrix using sensor data.  
Take the
inverse of this matix, and multiply the arrow vector by this  
matrix.


Two: Compute the device's orientation matrix using sensor data.  
Rather

than interpreting it as a rotation matrix, think of it as defining a
plane in space (aligned with the device's screen).  Then project the
arrow vector onto this plane, in the plane's coordinates.

You might want to start with compensating just for the vertical axis
(the device's rotation from the true north direction), it might be  
enough.


-- Kostya

22.09.2010 13:02, Pedro Teixeira пишет:






I'm really not understanding how to go with this...


I've been reading and reading.. I can find all kind of  
algorithms.. I
can find a haversin algorithm that points me to the correct  
direction

if my device is pointing north.. but the needle is static... so if i
change the device orientation the measure is incorrect... and I know
this happens because I'm not using device's sensor values like
azimuth, pitch and roll.. oh god.. 2 weeks on this.. I'm just
desperate now.



On Sep 18, 2010, at 10:29 AM, Kostya Vasilyev wrote:



Pedro,



If I understand you correctly, you are having difficulties with the
device's orientation.



The bearing angle seems to be computed in the horizontal plane. If
you wish to adjust for the device's orientation, you need to
concatenate it with the bearing angle.



Google for quaternions.



This is a (relatively) simple math technique to work with rotations
the same way you can work with vectors: add / subtract,  
interpolate.



-- Kostya



18.09.2010 0:56, Pedro Teixeira пишет:

Hi everyone...


I'm back with the same issue for the last couple of days… I'm  
trying

to create a compass for my application BUT the difference is that,
instead of having a line always pointing to north, I want this  
line to
point for a specific point. I've been trying dozens of  
algorithms and

nothing works..
I've finally found one that points me exactlly to the point I  
want..
BUT it doesn't move if I change the position of the device which  
is my
objective.. basicly, what I want is that no matter the direction  
I'm

using my device.. the line always point me to the point
(picLatitude,picLongitude)…


I understood that for the line to move, I can't use static  
variables…
I need to use the values offered by the onSensorChanged 
(SensorEvent

event).



This are the data I have available:



event.values[0]: azimuth, rotation around the Z axis (device in
relation to north, 0º)
event.values[1]: pitch, rotation around the X axis
event.values[2]: roll, rotation around the Y axis
mLatitude: device current latitude gottern from GPS (variable)
mLongitude: device current longitude gotten from GPS (variable)
picLatitude: static picture latitude established previously
picLongitude: static picture longitude established previously
distance: distance in Km from device to the picture calculated
previously



And this the formula that works correct, and gives me the correct
angle.. ( BUT IT DOESN'T USE ANY OF THE SENSOR DATA SO THE LINE
COMPASS DOESNT MOVE):



double dLong = picLongitude - mLongitude;
double y =  (Math.sin(dLong) * Math.cos(picLatitude));
double x =  

[android-developers] Re: best place to host apps that target indian market.

2010-09-22 Thread Bret Foreman
I believe Motodev/Shop4Apps covers India for paid apps.

On Sep 22, 8:23 am, Vijay Vikrant vijayvikran...@gmail.com wrote:
 Hello,

         Since the market is not open to India for paid apps - What will be a
 good server/store to host paid apps that target indian audiences?

 Many Thanks,
 Vikrant

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


[android-developers] can i filter some apps from Intent.createChooser?

2010-09-22 Thread genxsol
Hi there,

i am looking to access some chosen native apps available in my phone.

i used the code below but it display some other Apps also which i dont
want.
 intent.setType(text/plain);

 intent.putExtra(Intent.EXTRA_SUBJECT, subject);
 intent.putExtra(Intent.EXTRA_TEXT, text);
 startActivity(Intent.createChooser(intent,
getString(R.string.share_prompt)));


i need to know if i can filter some apps in createChooser like just
facebook, google mail and mail?

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] regarding signing the JCE provider jar file for Android

2010-09-22 Thread Kamal
I am developing a sample JCE service provider that implements a
encryption algorithm. When i tried to test it in android emulator it
is failing. I want to know whether  this JCE provider jar file needs
to be signed for using this encryption method. Who should sign this
jar file for using it in Android platform.

Regards,
Kamal.

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


[android-developers] Resources - common error

2010-09-22 Thread kypriakos

Hi all,

apparently this is a common error that many beginners get -
Resources don't contain package for resource number 0x7x.

However, what's the explanation when the R.java does not call
for any of the resources that the emulator is complaining about?
Who and/or where are these calls originating from otherwise?
None of the imported packages import their own R.java ..


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: deep effect in gallery?

2010-09-22 Thread genxsol
i am still struggle with this but no clue at all

On Sep 1, 2:14 pm, genxsol genx...@gmail.com wrote:
 Hi Folks,

 I am looking for Deep effect in Androidgallery.
 i did some work around coverflow 
 athttp://www.inter-fuser.com/search/label/Coverflow
 but it also do scroll left and right. it does give me the idea to
 calculate offset top and left for each item separately but still there
 is no access.

 what i am trying to do is,
 when user scroll, images would scroll from deep behind the right edge
 to center and then to left side deep behind.

 i am wondering if anyone have some thought about arranging the
 imageView's on deep offset (something likeVshape) rather than on
 horizontal as it is.

 can anybody point me to the right direction plz

 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: Drawing a line dynamically in code

2010-09-22 Thread Kumar Bibek
No you can't. What you are doing is right. If I understand correctly,
you want to use the draw method to draw a line, am I correct?

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

On Sep 22, 5:53 pm, Kevin Courtney kevinjcourt...@gmail.com wrote:
 Hello,

 This seems like a basic question but I’ve been struggling with it and need
 another set of eyes to set me straight.

 I’m trying to draw a line using code in a RelativeLayout and it’s not
 showing up.  I have this XML file:

 ?xml version=*1.0* encoding=*utf-8*?

 shape xmlns:android=*http://schemas.android.com/apk/res/android*

 android:shape=*line*

     stroke android:width=*1dp* android:colora=*#FF*/

     size android:height=*15dp* /

 /shape

 I use this file when drawing a line from straight XML and it works fine.

 But now I’m trying to use it to draw a line dynamically, in this code…

 ScrollView sv = *new* ScrollView(*this*);

       RelativeLayout relativeLayout = *new* RelativeLayout(*this*);

              relativeLayout.setBackgroundResource(R.drawable.*gradient_box*
 );

       sv.addView(relativeLayout);

       ImageView imageLineView2 = *new* ImageView(*this*);;

       imageLineView2.setBackgroundResource(R.drawable.*dividing_line_1*);

       RelativeLayout.LayoutParams lpEndOfInfoLineId2 =

        *new* RelativeLayout.LayoutParams(

 *           *RelativeLayout.LayoutParams.*WRAP_CONTENT*,

      RelativeLayout.LayoutParams.*FILL_PARENT*);

       relativeLayout.addView(imageLineView2,lpEndOfInfoLineId2);

       // have buttons, text, and images here that show up fine.

       *this*.setContentView(sv);

 It uses the same background as my successful use from the XML file so I
 don’t think it’s blending into the background.

 Do any of you have any suggestions on what I’m missing?

 Thanks in advance,

 Kevin

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


[android-developers] Re: appbucket: all apps for $9.99 per year, are we just going to watch?

2010-09-22 Thread mot12
AppBucket sent me this email:

---
Hi Martin,

Thought you would want to know and you can make it known to the rest
of
our fan boys...

We didn't get banned from posting anything. We deliberately didn't
post
anything today for a few reasons:

-Adding some firewalls to server [For douche bags trying to DDOS
us :)]
-Analysis of the way you guys would react. Seems weird how the
comments on
FREE apps don't even get noticed. Maybe a turn for the better...
-Tracking some other stuff I wont deliberate on.

But be sure to check again in a few days or tomorrow for more ;)

Also you guys may want to stem your efforts to other sites as we
aren't
the only one or the biggest. Oh! and we buy all the apps! and keep
them! No
refunds on anything.

One more thing... That guy John commenting above you.. I like him
lol...
But yea, currently we have all requested apps removed, and plan to
keep it
that way. Now mind you we have a method to just hide them from view
but we
don't. I respect the wishes of developers who request removal.

All those downloads you guys see as non-paid aren't from us, like I
said
we should be the least of your concerns. We do not crack apps either.
Check
out the biggest site... ask around some may know the site I am
referring to
as they know the BIG dramatic take-down of it months ago.

There users CRACK ALL apps not us. We do not have the time to do it.
Plus
its not worth it. Especially when others will do it.

But yea, I'll answer questions for devs through you as long as you
post
what I type and nothing else or less. Not evil over here...

---


I am amazed how he thinks that he is not evil. As if only cracking
or not paying for the app would make it evil and otherwise it it ok.
Anyhow, I wrote back:

I am baffled by your attitude. You think anybody cares if you buy the
apps or not? That's $2 in my pocket, I am supposed to be grateful for
that? Every copy you distribute of my app, is stealing $2 out of my
pocket.

Imagine all Android users would use your site rather than buying
through the market. This is certainly something you would want, no?
Then the developers get paid once and that's it, and most of us would
stop developing because we need to feed our families and need to get
paid for our work.  The result is that you will find only apps by
school children and apps by companies for advertising purposes. That's
what you work towards. I love Android, I love the ability to
contribute apps to the Android community and you are actively working
on destroying that.

I feel violated and hurt by you. Your attitude disgusts me. There is
absolutely nothing legal or justifiable about your making money of
other people's work. You should be ashamed. Why don't you write apps
yourself and contribute to Android? That's too hard? Thieving is
always easier.

Martin

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] location NOT working correctly in droid after the upgrade to 2.2

2010-09-22 Thread sunny
Sorry I was on vacation - took a break away from all the tech madness.. :-)

launch your browser--checkyour location-. it shows incorrectly from what I
get in the google map.
anyway, thats not my biggest issue NOW. The GeoCode reverseAPI is crashing
with a status of 20. Therefore getting address from lat,lnt is returning
null causing an exception.. any clue on this ?. I will send a new post on
this..

On Mon, Sep 6, 2010 at 9:10 PM, Frank Weiss fewe...@gmail.com wrote:

   However, when I use the google search or use the browser and check for
 the location . It shows a different a zipcode ( city).


 Sorry, I don't understand those two use cases (google search and browser)
 how they relate to location?

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


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

[android-developers] Re: Nokia inviting Developers to become an Ovi store publisher.

2010-09-22 Thread DanH
The (preliminary) word that folks at Nokia are giving me is that the
site is legit, though the posts are suspicious, at least.  They're
trying to figure out whether it's a true bad actor or just someone in
marketing run amok.

On Sep 22, 7:44 am, DanH danhi...@ieee.org wrote:
 (I've reported this problem to Nokia through a couple of routes.)

 On Sep 22, 7:32 am, DanH danhi...@ieee.org wrote:

  OK, checked that domain name, and it appears to be hosted out of
  Houston TX.  Not at all what I'd expect for a Nokia site.  So odds are
  it's a phishing site.

  Odd that so much work went into the site -- hard to see what they
  expect to gain.

  On Sep 22, 7:16 am, DanH danhi...@ieee.org wrote:

   The Nokia platforms running Qt are probably generally friendlier to
   the programmer than Android, and market penetration of the Nokia
   phones in Europe is quite high.  Plus problems with piracy are much
   less.  The main downsides are the crummy pressure-sensitive touch
   screens and the short battery life.

   That said, this is a really clumsy spamming effort, and I'm a little
   surprised that Nokia is (apparently) doing it.  (Unless this is the
   first work of that new marketing manager they hired off of Microsoft.)

   On Sep 21, 1:03 pm, SheikhAman shekh.a...@gmail.com wrote:

I don't think Nokia is interested in Android.
all they want you to come in for is Meego.

On Sep 21, 2:25 pm, Kumar Bibek coomar@gmail.com wrote:

 Definitely a SPAM...

 On Sep 20, 8:23 pm, TreKing treking...@gmail.com wrote:

  On Mon, Sep 20, 2010 at 2:27 AM, James Baker 
  james.baker...@gmail.comwrote:

   If u are a developer nd dream it big then grab this opportunity 
   today.

  I think this says it all.

  If u try it out post back nd let us know how it goes.

  -
  TreKing http://sites.google.com/site/rezmobileapps/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] Automatic testing tool for Android?

2010-09-22 Thread Timo Reimann
Hey,


On 17.09.2010 08:38, Dajinsol Jeon wrote:
 Yesterday, I heard that there is a program to test Android application
 automatically after installing apk onto real device. The one I have
 heard is commercial, and very expensive. Is there a open source tool? I
 know that adb shell support monkey test, but is it possible to use adb
 for UI interaction? For example, is it possible to send button-click
 event to button (which is specified by id or something else) in
 application by using adb?

I don't know about automatic testing on real devices but the SDK
provides a testing framework which you can use to write emulator-based
tests, including UI. Take a look at the relevant guide section:

http://developer.android.com/guide/developing/testing/index.html


HTH,

--Timo

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


[android-developers] reverseGeocode is returning null in android 2.2

2010-09-22 Thread sunny
Dear Folks!!,
Looks like reverseGeocode ( getFromLocation())  is not working in android
2.2. It is not able to fetch the address from the coordinates. It returns
null and crashing my app.

Any clues ?. do you see this too ?. very frustrating indeed.

In general 2.2 is not stable - 2.1 was much better. UI response , UI
rotation when rotate the phone etc doesn't work reliably

sorry I could not respond to some of the earlier emails directed to me as I
was on vacation...

thanks a ton for your response
Sunny

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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] Compile error in the new “Hello Testing” Tutorials program

2010-09-22 Thread Timo Reimann
On 19.09.2010 12:55, Kieu Hua wrote:
 There is compile error in HelloAndroidTest program in the Tutorials
 “Hello Testing” program, because I got this compile error.
 “com.example.helloandroid.R.id.textview can not be resolved.”
 
 @Override
 protected void setUp() throws Exception {
 super.setUp();
 mActivity = this.getActivity();
 mView = (TextView)
 mActivity.findViewById(com.example.helloandroid.R.id.textview);
 resourceString =
 mActivity.getString(com.example.helloandroid.R.string.hello);
 }
 
 My com.example.helloandroid.R doesn’t have R.id.textview, and
 endroid.R.id class does not have endroid.R.id.textview field.
 
 Where do I support to get this field, 
 “com.example.helloandroid.R.id.textview”?

You need to assign an ID to the TextView element which is to be
instantiated in mView. The ID should be set in the XML file defining the
UI and should look like this:

  android:id=@+id/textview

You probably skipped the Hello, World! tutorial which sets up an XML
layout here:

http://developer.android.com/resources/tutorials/hello-world.html#upgrading


Cheers,

--Timo

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


[android-developers] Re: Scaling / Animating a Camera preview surface

2010-09-22 Thread Jon Sutherland
Anyone have any insight at all?  Was I not clear about my problem?

I am simply trying to zoom in or zoom out on the camera preview but I
am not using the Camera smooth zoom API in 2.2 since it seems to only
work for levels of zoom that are different for each phone/camera.
Also, it appears that it can not zoom using a floating point scale.

If I try scaling the FrameLayout around the preview SurfaceView it
looks like it kind of works, but the preview goes completely black
while the animation is running.

I am starting to think maybe this will work by grabbing each frame
from the preview and drawing to a canvas white scaling, but this seems
over-complicated compared to using the Animations API.

If someone can help point me in the right direction that would be
awesome!

Thanks,


Jon


On Sep 20, 7:09 pm, Jon Sutherland jon.sutherl...@gmail.com wrote:
 I am using android.hardware.Camera to get a preview and display it on
 a custom SurfaceView that implements SurfaceHolder.Callback.

 I am trying to zoom in to the camera preview surface by a specified
 scale (not using the camera's digital zoom) but I can't seem to find a
 correct way to do it.  I also need to be able to zoom out and scale
 down the preview.

 I was hoping to be able to do this using a ScaleAnimation but it
 doesn't seem to work on SurfaceView, nor the FrameLayout containing
 the SurfaceView.

 I also tried setting the size of the SurfaceView using setLayoutParams
 but that doesn't seem to work too well on various hardware and it
 would be tough to animate smoothly.

 Does anyone has any suggestions on how to achieve this effect?  Right
 now I am starting to think I might have to implement this using
 GLSurfaceView but I'm very unsure.

 Thanks,

 Jon

-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email 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: Where has maps.jar gone to? Can't find in basic SDK install

2010-09-22 Thread pawpaw17
Lance,

Thanks for the reply. What build target should I be using if I want to
continue support Android 1.5 and forward with google maps?

The project build target dialog has the following target names:

Android 1.5 Platform 1.5
Andorid 1.6 Platform 1.6
Android 2.1 Platform 2.1
Android 2.2 Platform 2.2
Google APIs Platform 2.2

The thing that worries me about the last one is the Platform 2.2. We
need to support all of the existing versions of Android.

Also, if I do a search on my hard drive, maps.jar doesn't even exist
on the machine after installing the full set of Android APIs.
As and experiment, I switched to the Google Apis build target, and I
still get errors for the maps stuff.

Still presuming I'm doing something wrong...

Thanks,

pawpaw17

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

2010-09-22 Thread Pedro Teixeira

Per can you explain your example a little bit further?
My code seems fine but the direction of the arrow doesnt seem accurate:


public void onSensorChanged(SensorEvent event) {
	double mLatitude  =  (mLocation.getLatitude()); // lat1 location  
manager
	double mLongitude =  (mLocation.getLongitude()); // long1 locationg  
manager
	double picLatitude = Double.parseDouble(picLatitudeString); //lat2  
fixed
	double picLongitude = Double.parseDouble(picLongitudeString); //long2  
fixed

float mHeading = event.values[0]; // azimuth value
float[] results = new float[1];
Location.distanceBetween(mLatitude, mLongitude, picLatitude,  
picLongitude, results);

float mBearing = results[1]; // bearing
float angleDegrees =  ((mBearing - mHeading)+360) % 360;

myCompass.updateDirection(angleDegrees);
}

The update method goes simply like this:

public void updateDirection(float dir)
{
firstDraw = false;
direction = dir;
invalidate();
}

And this is how I draw the compass:

public static class compassLook extends View {

private Paint paintPointer = new Paint(Paint.ANTI_ALIAS_FLAG);
private Paint paintCircle = new Paint(Paint.ANTI_ALIAS_FLAG);
private Paint paintLeters = new Paint(Paint.ANTI_ALIAS_FLAG);
private boolean firstDraw;
private float direction;

protected void onDraw(Canvas canvas) {
int cxCompass = (getMeasuredWidth()/2);
int cyCompass = (getMeasuredHeight()/2);
float radiusCompass;
if(cxCompass  cyCompass){
 radiusCompass = (float) (cyCompass * 0.9);
}
else{
 radiusCompass = (float) (cxCompass * 0.9);
}
// circle drawing
canvas.drawCircle(cxCompass, cyCompass, radiusCompass, 
paintCircle);
if(!firstDraw){ 

// line pointer
 canvas.drawLine(cxCompass, cyCompass,
		   (float)(cxCompass + radiusCompass * Math.sin((double)(-direction)  
* 3.14/180)),
		   (float)(cyCompass - radiusCompass * Math.cos((double)(-direction)  
* 3.14/180)),

   paintPointer);
double mLatitude  =  (mLocation.getLatitude()); //lat1
double mLongitude =  (mLocation.getLongitude());//long1
double picLatitude = 
Double.parseDouble(picLatitudeString); //lat2
double picLongitude = 
Double.parseDouble(picLongitudeString); //long2


 // Distance formula (harversin)
float R = 6371; // km
float dLat = (float) 
Math.toRadians(picLatitude-mLatitude);
float dLon = (float) 
Math.toRadians((picLongitude-mLongitude));
float a = (float) (Math.sin(dLat/2) * Math.sin(dLat/2) +
			Math.cos(Math.toRadians(mLatitude)) * Math.cos 
(Math.toRadians(picLatitude)) *

Math.sin(dLon/2) * Math.sin(dLon/2));
float c = (float) (2 * Math.atan2(Math.sqrt(a), 
Math.sqrt(1-a)));
float distancia = R * c;

		 canvas.drawText(String.valueOf(distancia*1000) + m, cxCompass-30,  
cyCompass+20, paintLeters);

}

}

I didn't wrote all the methods on compssLook since they are not  
relevant..



On Sep 22, 2010, at 1:12 PM, Per wrote:


this works for me:

1: listen to location changes. Store the most recent location. You
need it below.
2: listen to orientation changes. Store the most recent heading
(azimuth) in mHeading - that's the compass direction corresponding to
your viewing direction when holding your phone horizontally in
portrait mode;
3: the bearing to your destination (assuming you have its coordinates)
can be found using Location.distanceBetween() (call it mBearing)
4: to point your directional arrow towards the destination, its
required rotation (from 'up') is  ((mBearing - mHeading)+360) % 360;

You may wish to compensate for device rotation (portrait/landscape),
too. See Display.getOrientation / Display.getRotation

Not a complete 3D solution, but works ok.

/Per


(not sure if the terms bearing/heading are 100% in sync with common
naval use, but hey...)

On 22 Sep., 11:28, Kostya Vasilyev kmans...@gmail.com wrote:

  Pedro,

I think you should learn something about the way direction (and
orientation) is specified in computer programming.

http://en.wikipedia.org/wiki/Yaw,_pitch,_and_roll

http://en.wikipedia.org/wiki/Euler_angles

http://en.wikipedia.org/wiki/Rotation_representation_(mathematics)#Ro...

I believe that Android orientation sensors work this way.

Now about the compass

There are two ways you can think about this:

First, take the value you 

Re: [android-developers] uninstall missing..

2010-09-22 Thread TreKing
On Wed, Sep 22, 2010 at 9:02 AM, Vijay Vikrant vijayvikran...@gmail.comwrote:

 But i don't see it in the settings-applications list. How do i uninstall
 this app?


Are you looking at the All list?

-
TreKing http://sites.google.com/site/rezmobileapps/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: On using themes?!

2010-09-22 Thread Mariano Kamp
As it wasn't possible to submit a new post to the existing/old conversation
using the web interface I am copying the message here with Danilo's
permission:

Hi Mariano.

Did you manage to work using themes from drawables xml?
I have same problem and there is no any reference but this thread and
there is no solution here.
If you find solution please let me know.

I currently solved it by using different drawable xml for every
theme but as you can see this isn't a god solution at all.

About your question about getting a color from a theme (I know its old
but for future readers :) ) solution I created is like this:

   private static int getColor(final Context context, final int id,
final int defaultColor) {
   try {
   final Theme theme = context.getTheme();
   if (theme == null) {
   return defaultColor;
   }
   TypedValue typedValue = new TypedValue();

   if (theme.resolveAttribute(id, typedValue, false)) {
   final Resources resources =
context.getResources();
   final int resourceId = typedValue.resourceId;
   if (typedValue.type ==
TypedValue.TYPE_INT_COLOR_RGB8 ||
typedValue.type == TypedValue.TYPE_INT_COLOR_RGB4 || typedValue.type
== TypedValue.TYPE_INT_COLOR_ARGB4
   || typedValue.type ==
TypedValue.TYPE_INT_COLOR_ARGB8 ||
typedValue.type == TypedValue.TYPE_FIRST_COLOR_INT) {
   return typedValue.data;
   } else {
   return
resources.getColor(resourceId);
   }
   }
   return defaultColor;
   } catch (NotFoundException e) {
   // TODO Auto-generated catch block
   e.printStackTrace();
   return defaultColor;
   }
   }

On Tue, May 11, 2010 at 9:08 AM, Mariano Kamp mariano.k...@gmail.comwrote:

 Hi Dianne.

 Thanks very much, almost there.

 I understand the procedure, it would do what I want, but I run into an
 exception:

 D/NewsRobDefaultExceptionHandler( 1839): Caused by:
 java.lang.UnsupportedOperationException: Can't convert to color: type=0x2
 D/NewsRobDefaultExceptionHandler( 1839): at
 android.content.res.TypedArray.getColor(TypedArray.java:273)
 D/NewsRobDefaultExceptionHandler( 1839): at
 android.graphics.drawable.GradientDrawable.inflate(GradientDrawable.java:647)
 D/NewsRobDefaultExceptionHandler( 1839): at
 android.graphics.drawable.Drawable.createFromXmlInner(Drawable.java:788)
 D/NewsRobDefaultExceptionHandler( 1839): at
 android.graphics.drawable.Drawable.createFromXml(Drawable.java:729)
 D/NewsRobDefaultExceptionHandler( 1839): at
 android.content.res.Resources.loadDrawable(Resources.java:1690)

 This happens when using it the way we described here in a drawable xml.
 However to better understand the error I used it on other attributes and
 when using it on the background attribute of a View it works. Maybe this
 approach is incompatible with drawables that are expressed in xml?

 Btw. Is there any way to get the actual #rgb string for a color from a
 theme?

 Cheers,
 Mariano

 On Tue, May 11, 2010 at 8:02 AM, Dianne Hackborn hack...@android.comwrote:

 You need to define an attribute for your value:

 attr name=myColor format=color /

 Then make a custom theme that supplies a value for it:

 style name=MyTheme parent=android:Theme
 item name=com.my.package:myColor#ff808080/item
 /style

  And now you can reference that value from other XML:

 shape xmlns:android=http://schemas.android.com/apk/res/android

 
 android:shape=rectangle
 gradient android:startColor=?com.my.package:myColor

 android:endColor=#66FF
 android:angle=270 /
 /shape


 Note that com.my.package is your manifest's package name.

 Also I just wrote this by hand so I won't guarantee it is completely
 right. :}

 On Mon, May 10, 2010 at 11:02 AM, Mariano Kamp mariano.k...@gmail.comwrote:

 Hmmh, also no answer to this question on themes. Maybe the answer cannot
 be given with two lines? So let me explain what I would expect step by step
 and you stop me were I deviate from the Golden Path? I'll try yes/no
 questions.

 In the simplest terms I would expect that in every place I can specify a
 color in RGB (#) I could also specify a symbolic name instead. This
 should work like @color/xyz, but with one more level of indirection that
 lets me switch between themes, like dark and light.

 Is that possible?

 I would expect those themes to be applicable to (a) widgets, (b)
 drawables (see the mentioned example) and (c) when I need to style something
 myself like HTML. Are (a) - (c) possible?

 Furthermore I would expect that I could define style keys 

[android-developers] Request: Don't make us use Ant

2010-09-22 Thread Craigo
Please update the Eclipse Export Android Application feature to take
the location of Proguard and do the obfuscated build.

The instructions posted 
http://android-developers.blogspot.com/2010/09/proguard-android-and-licensing-server.html
only work if your application is very basic (mine didn't work as it
references other projects in the build path).

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: Drawing a line dynamically in code

2010-09-22 Thread Kevin Courtney
I'm not entirely sure if it's the draw method that I should be
using..at this point I'm looking for any suggestions...

...I need to draw a line on the on this view using code.

The rest of the story is that this code is inside a loop that is
reading records and putting their info on the view.  In between each
record I want to draw a simple line.

Thanks,

Kevin

On Sep 22, 8:44 am, Kumar Bibek coomar@gmail.com wrote:
 No you can't. What you are doing is right. If I understand correctly,
 you want to use the draw method to draw a line, am I correct?

 -Kumar Bibekhttp://techdroid.kbeanie.com

 On Sep 22, 5:53 pm, Kevin Courtney kevinjcourt...@gmail.com wrote:

  Hello,

  This seems like a basic question but I’ve been struggling with it and need
  another set of eyes to set me straight.

  I’m trying to draw a line using code in a RelativeLayout and it’s not
  showing up.  I have this XML file:

  ?xml version=*1.0* encoding=*utf-8*?

  shape xmlns:android=*http://schemas.android.com/apk/res/android*

  android:shape=*line*

      stroke android:width=*1dp* android:colora=*#FF*/

      size android:height=*15dp* /

  /shape

  I use this file when drawing a line from straight XML and it works fine.

  But now I’m trying to use it to draw a line dynamically, in this code…

  ScrollView sv = *new* ScrollView(*this*);

        RelativeLayout relativeLayout = *new* RelativeLayout(*this*);

               relativeLayout.setBackgroundResource(R.drawable.*gradient_box*
  );

        sv.addView(relativeLayout);

        ImageView imageLineView2 = *new* ImageView(*this*);;

        imageLineView2.setBackgroundResource(R.drawable.*dividing_line_1*);

        RelativeLayout.LayoutParams lpEndOfInfoLineId2 =

         *new* RelativeLayout.LayoutParams(

  *           *RelativeLayout.LayoutParams.*WRAP_CONTENT*,

       RelativeLayout.LayoutParams.*FILL_PARENT*);

        relativeLayout.addView(imageLineView2,lpEndOfInfoLineId2);

        // have buttons, text, and images here that show up fine.

        *this*.setContentView(sv);

  It uses the same background as my successful use from the XML file so I
  don’t think it’s blending into the background.

  Do any of you have any suggestions on what I’m missing?

  Thanks in advance,

  Kevin

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


[android-developers] Re: Automatic testing tool for Android?

2010-09-22 Thread DanH
Are you talking about Monkey?  
http://developer.android.com/guide/developing/tools/monkey.html

On Sep 17, 1:38 am, Dajinsol Jeon midgar...@gmail.com wrote:
 Hi all,
 I'm new to Android programming.

 Yesterday, I heard that there is a program to test Android application
 automatically after installing apk onto real device. The one I have heard is
 commercial, and very expensive. Is there a open source tool? I know that adb
 shell support monkey test, but is it possible to use adb for UI interaction?
 For example, is it possible to send button-click event to button (which is
 specified by id or something else) in application by using adb?

 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: Automatic testing tool for Android?

2010-09-22 Thread DanH
Oops -- I see you mentioned Monkey in your original post.

On Sep 22, 11:35 am, DanH danhi...@ieee.org wrote:
 Are you talking about Monkey?  
 http://developer.android.com/guide/developing/tools/monkey.html

 On Sep 17, 1:38 am, Dajinsol Jeon midgar...@gmail.com wrote:

  Hi all,
  I'm new to Android programming.

  Yesterday, I heard that there is a program to test Android application
  automatically after installing apk onto real device. The one I have heard is
  commercial, and very expensive. Is there a open source tool? I know that adb
  shell support monkey test, but is it possible to use adb for UI interaction?
  For example, is it possible to send button-click event to button (which is
  specified by id or something else) in application by using adb?

  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] LogCat and threads

2010-09-22 Thread john brown
Hello,

I am trying to understand threads and how they work, and when, etc. I
expected the pid in LogCat to be different in the background thread
logs but the pid is always the same.

Is the pid something other than the thread ID? If it is, is there a
way to indicate the thread ID in LogCat?

Thanks, John Brown

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

2010-09-22 Thread DanH
(There is a tool that lets you send button clicks.  Don't know
anything about it, but it was mentioned in a post a few days ago.  My
impression was that it's a daemon of sorts that runs on the phone
(perhaps through adb) and that you can send commands to it like press
100 100 to press the button at those coordinates.)

On Sep 17, 1:38 am, Dajinsol Jeon midgar...@gmail.com wrote:
 Hi all,
 I'm new to Android programming.

 Yesterday, I heard that there is a program to test Android application
 automatically after installing apk onto real device. The one I have heard is
 commercial, and very expensive. Is there a open source tool? I know that adb
 shell support monkey test, but is it possible to use adb for UI interaction?
 For example, is it possible to send button-click event to button (which is
 specified by id or something else) in application by using adb?

 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: Automatic testing tool for Android?

2010-09-22 Thread DanH
OK, the tools IS Monkey, and the command is tap, as discussed in
this post: 
http://groups.google.com/group/android-developers/browse_thread/thread/a3141be2636688e0

On Sep 22, 11:41 am, DanH danhi...@ieee.org wrote:
 (There is a tool that lets you send button clicks.  Don't know
 anything about it, but it was mentioned in a post a few days ago.  My
 impression was that it's a daemon of sorts that runs on the phone
 (perhaps through adb) and that you can send commands to it like press
 100 100 to press the button at those coordinates.)

 On Sep 17, 1:38 am, Dajinsol Jeon midgar...@gmail.com wrote:

  Hi all,
  I'm new to Android programming.

  Yesterday, I heard that there is a program to test Android application
  automatically after installing apk onto real device. The one I have heard is
  commercial, and very expensive. Is there a open source tool? I know that adb
  shell support monkey test, but is it possible to use adb for UI interaction?
  For example, is it possible to send button-click event to button (which is
  specified by id or something else) in application by using adb?

  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] LogCat and threads

2010-09-22 Thread Kostya Vasilyev
Process is not the same as thread. A process can have many threads, and they
all share the same data. This is really convenient, since you can reference
Java objects from any thread, regardless of which thread created them.
Processes, on the other hand, do not share each other's memory state - so
your Java objects can't be accessed by other applications.

Note that in Android UI related framework calls have to be made from the
main thread, called the UI thread.

--
Kostya Vasilyev -- http://kmansoft.wordpress.com

22.09.2010 20:40 пользователь john brown johnbrowngreybe...@gmail.com
написал:

Hello,

I am trying to understand threads and how they work, and when, etc. I
expected the pid in LogCat to be different in the background thread
logs but the pid is always the same.

Is the pid something other than the thread ID? If it is, is there a
way to indicate the thread ID in LogCat?

Thanks, John Brown

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

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

[android-developers] [Error ] annot find symbol symbol : method log(java.lang.String)

2010-09-22 Thread Atul Raut
Hi am getting this error :

cannot find symbol symbol  : method log(java.lang.String)
when using method : log(some test, +test);

I have imported

import android.text.TextUtils;
import android.util.Log;


Still its throwing same error why it is so ?

-Atul

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

[android-developers] Dream Calc Scientific Edition

2010-09-22 Thread torrado
DreamCalc Scientific Edition is the smarter alternative to a hand-held
Scientific Calculator for your PC or laptop! You'll get the intuitive
feel and productivity of using a professional hand-held, but one which
adapts to your way of working. Select from Reverse Polish Notation or
two styles of algebraic input, and with the optional ability to run in
your Windows system tray--DreamCalc will always be there whenever you
need to reach for a calculator. DreamCalc also offers you a full range
of scientific functions, statistics, complex numbers, base-n logic,
unit conversions, built-in constants and a powerful polynomial solver.
Because it is software, it allows you to exchange your results and
lists with your other applications. It is a must for business,
science, engineering and education

LinK:
http://www.megaupload.com/?d=3DW93FAR

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


[android-developers] Re: [Error ] annot find symbol symbol : method log(java.lang.String)

2010-09-22 Thread Atul Raut
Hi I have imported import android.os.Message; still giving error.

On Wed, Sep 22, 2010 at 10:24 PM, Atul Raut atul.dr...@gmail.com wrote:

 Hi am getting this error :

 cannot find symbol symbol  : method log(java.lang.String)
 when using method : log(some test, +test);

 I have imported

 import android.text.TextUtils;
 import android.util.Log;


 Still its throwing same error why it is so ?

 -Atul


-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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: [Error ] annot find symbol symbol : method log(java.lang.String)

2010-09-22 Thread Kostya Vasilyev

 22.09.2010 20:57, Atul Raut пишет:

log(some test, +test);

I suppose you could try taking out the comma before the plus sign:

log(some test + test);

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

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


[android-developers] Re: [Error ] annot find symbol symbol : method log(java.lang.String)

2010-09-22 Thread David Turner
Please avoid cross-posting !! this should go into android-developers only.

On Wed, Sep 22, 2010 at 6:57 PM, Atul Raut atul.dr...@gmail.com wrote:

 Hi I have imported import android.os.Message; still giving error.


 On Wed, Sep 22, 2010 at 10:24 PM, Atul Raut atul.dr...@gmail.com wrote:

 Hi am getting this error :

 cannot find symbol symbol  : method log(java.lang.String)
 when using method : log(some test, +test);

 I have imported

 import android.text.TextUtils;
 import android.util.Log;


 Still its throwing same error why it is so ?

 -Atul


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


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

Re: [android-developers] Re: [Error ] annot find symbol symbol : method log(java.lang.String)

2010-09-22 Thread Atul Raut
Thanks Kostya

On Wed, Sep 22, 2010 at 10:31 PM, Kostya Vasilyev kmans...@gmail.comwrote:

  22.09.2010 20:57, Atul Raut пишет:

 log(some test, +test);

 I suppose you could try taking out the comma before the plus sign:

 log(some test + test);

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

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

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

Re: [android-developers] Re: [Error ] annot find symbol symbol : method log(java.lang.String)

2010-09-22 Thread Atul Raut
Hi Kostya ,

I am trying below and still getting error.

*log(Settings onCreate subscription DSDS Enabled = + mSubscription);*

-Atul

On Wed, Sep 22, 2010 at 10:31 PM, Kostya Vasilyev kmans...@gmail.comwrote:

  22.09.2010 20:57, Atul Raut пишет:

 log(some test, +test);

 I suppose you could try taking out the comma before the plus sign:

 log(some test + test);

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

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

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

Re: [android-developers] Re: [Error ] annot find symbol symbol : method log(java.lang.String)

2010-09-22 Thread Kevin Anthony
The method is Log.d(tag,message);
Looking at what you posted, it looks like you need to capitilize the L and
put a d,v,i,w,e for debug verbose info warning error

On Sep 22, 2010 1:04 PM, David Turner di...@android.com wrote:
 Please avoid cross-posting !! this should go into android-developers only.

 On Wed, Sep 22, 2010 at 6:57 PM, Atul Raut atul.dr...@gmail.com wrote:

 Hi I have imported import android.os.Message; still giving error.


 On Wed, Sep 22, 2010 at 10:24 PM, Atul Raut atul.dr...@gmail.com wrote:

 Hi am getting this error :

 cannot find symbol symbol : method log(java.lang.String)
 when using method : log(some test, +test);

 I have imported

 import android.text.TextUtils;
 import android.util.Log;


 Still its throwing same error why it is so ?

 -Atul


 --
 You received this message because you are subscribed to the Google Groups
 android-ndk group.
 To post to this group, send email to android-...@googlegroups.com.
 To unsubscribe from this group, send email to
 android-ndk+unsubscr...@googlegroups.comandroid-ndk%2bunsubscr...@googlegroups.com
android-ndk%2bunsubscr...@googlegroups.comandroid-ndk%252bunsubscr...@googlegroups.com

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


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

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

  1   2   3   >