Re: [android-developers] HOW MUCH DOES GOOGLE CHARGE APP DEVELOPERS WHEN A CUSTOMER PURCHASE YOUR APP?

2015-12-04 Thread Andrew Brampton
I literally copied and pasted your subject line into Google.com and it took
me to this page:
https://support.google.com/googleplay/android-developer/answer/112622?hl=en

Google takes 30%, Developer keeps 70%.

Andrew

On 4 December 2015 at 07:02, TRU ASPECT  wrote:

>  Hello, Im Michael
>
> Just wanted to know what was the percentage google takes from a app
> developer after each app purchase?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Android Developers" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to android-developers+unsubscr...@googlegroups.com.
> To post to this group, send email to android-developers@googlegroups.com.
> Visit this group at http://groups.google.com/group/android-developers.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/android-developers/135bfb04-ca28-483b-8b89-57ee7489c409%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
To post to this group, send email to android-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/android-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-developers/CAC2%3DhFDoJ8d4%2BQLXrCLahtEZZMBAV3QFwfqoqHcYhVezH%3Dg8tA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: [android-developers] Run http server in android

2013-07-01 Thread Andrew Brampton
I adapted Nanohttpd to work on Android: https://github.com/bramp/NanoHTTPd you
can easily adapt that to make it a proxy.


On 1 July 2013 04:15, jrichards1...@googlemail.com
jrichards1...@gmail.comwrote:

 anyone?

 --
 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, 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 unsubscribe from this group and stop receiving emails from it, send an
 email to android-developers+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.




-- 
-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, 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 unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [android-developers] Question About GPS while on the phone

2011-01-11 Thread Andrew Brampton
From what I understand, ATT uses GSM and Verizon uses CDMA, which are
different technologies. So it is some what carrier specific only
because each US carrier offers a different technology.

Andrew

On 11 January 2011 14:50, Tommy droi...@gmail.com wrote:
 Very cool. That makes sense.

 Are you sure it's not carrier specific? The reason I ask is because I have 2
 phones both with 3g service one on Verizon and one on ATT. The ATT android
 phone can surf the net and what not while on the phone, my Verizon phone and
 my boss's phones cannot.

 That part isn't a huge deal though.

 Again thank you for your time!

 -Original Message-
 From: android-developers@googlegroups.com
 [mailto:android-develop...@googlegroups.com] On Behalf Of Marcin Orlowski
 Sent: Tuesday, January 11, 2011 2:44 PM
 To: android-developers@googlegroups.com
 Subject: Re: [android-developers] Question About GPS while on the phone

 On 11 January 2011 20:04, Tommy droi...@gmail.com wrote:

 I know that with some providers you can't be on the phone and use
 Internet at the same time. One example would be my moto droid on
 verizon. Not a big deal as we can put in a broadcast receiver to
 listen to the phone state. My question is is the GPS provider affected
 the same way? In otherwords if I am on the phone will the GPS work no
 matter what?

 It's not a carrier fault. Some data xfer standards (i.e. EDGE) cannot
 operate while doing phone call. If you use GPS receiver then it's completely
 different hardware and not interfere with phone radio. However if you want
 to use cell traingulation instead of GPS receiver then it needs data
 connection to map cells to certain location. And it of course may be not
 available when on the call if the situation I formerly described occur

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

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

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


Re: [android-developers] settings - is this a ListView ?

2010-09-29 Thread Andrew Brampton
This is a ListView, as it is quite easy to have every row different.
But in fact that Activity is most likely a PreferenceActivity[1] that
takes a lot of the hassle out of creating a ListView and simplifies
handling preferences.

Andrew

[1] 
http://developer.android.com/reference/android/preference/PreferenceActivity.html

On 29 September 2010 12:19, Marco Alexander Schmitz
marco.alexander.schm...@googlemail.com wrote:
 Hi,

 as we all know in the emulator under settings we can configure out
 device.

 Are these settings views just ListViews?

 The have headings and almost every row looks different - a normal
 ListView makes all rows look the same ?!

 http://www.webinmotion.de/test/masc/device.png

 Best regards,
 DaRolla

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

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


[android-developers] Two problems with SeekBars, one with ListViews, and one inside a PreferenceActivity

2010-09-20 Thread Andrew Brampton
Hi,
I've identified a problem with a SeekBar being inside a ListView, and
a problem with a SeekBar being inside a Preference on Android 2.2. I'm
trying to figure out if I'm doing something wrong, or this is a
limitation/bug of Android.

The first problem with the ListView is that I am unable to use the
trackball/arrow keys to move the SeekBar when it is inside a ListView.
This seems to apply to all versions of Android 1.5-2.2. The following
simple example shows this:

public final class TestActivity extends ListActivity {

public SeekBar makeSeekBar() {
SeekBar s = new SeekBar(this);
s.setMax(10);
s.setKeyProgressIncrement(1);
return s;
}

public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);

setListAdapter(new BaseAdapter() {

@Override
public int getCount() {
return 5;
}

@Override
public Object getItem(int position) {
return null;
}

@Override
public long getItemId(int position) {
return 0;
}

@Override
public View getView(int position, View convertView, 
ViewGroup parent) {
return makeSeekBar();
}
});
}
}

The previous example code creates a ListActivity with a simple
ListAdapter which displays 5 SeekBars. Each SeekBar seems to work
correctly when in touch mode, but I am unable to move the bar left of
right by using the arrow keys (in the emulator) or the trackball (on
my G1). If I instead make a Activity with a SeekBar in it, then the
arrow keys/track ball can easily move the SeekBar left and right. Is
this a limitation? or just an oversight? or am I missing something?


The second problem (with led me to the first problem), is I have a
custom Preference class called SeekBarPreference, which if you can't
guess displays a SeekBar on a PreferenceActivity. It doesn't display
the SeekBar in a popup dialog, but instead directly in the
PreferenceActivity[1]. This works great in touch mode, unless I use
Android 2.2. On Android 2.2 it seems every time I start to slide the
bar left or right, as soon as it moves one notch a onStopTrackingTouch
is received, and the bar no longer slides. So basically the SeekBar
will only move to where you click and no longer slides. Under Android
1.6-2.1 the slide behaviour worked fine!.

I did some debugging, and the call stack from the onStopTrackingTouch
is as follows:
SeekBarPreference.onStopTrackingTouch(SeekBar) line: 110
SeekBar.onStopTrackingTouch() line: 115 
SeekBar(AbsSeekBar).onTouchEvent(MotionEvent) line: 311 
SeekBar(View).dispatchTouchEvent(MotionEvent) line: 3766
RelativeLayout(ViewGroup).dispatchTouchEvent(MotionEvent) line: 936 
LinearLayout(ViewGroup).dispatchTouchEvent(MotionEvent) line: 936   
LinearLayout(ViewGroup).dispatchDetachedFromWindow() line: 1148 
ListView(ViewGroup).removeDetachedView(View, boolean) line: 2333
AbsListView.access$2700(AbsListView, View, boolean) line: 72
AbsListView$RecycleBin.addScrapView(View) line: 4068
ListView.layoutChildren() line: 1514
ListView(AbsListView).onLayout(boolean, int, int, int, int) line: 1147  
ListView(View).layout(int, int, int, int) line: 7035
FrameLayout.onLayout(boolean, int, int, int, int) line: 333 
FrameLayout(View).layout(int, int, int, int) line: 7035 
PhoneWindow$DecorView(FrameLayout).onLayout(boolean, int, int, int,
int) line: 333
PhoneWindow$DecorView(View).layout(int, int, int, int) line: 7035   
ViewRoot.performTraversals() line: 1045 
ViewRoot.handleMessage(Message) line: 1727  
ViewRoot(Handler).dispatchMessage(Message) line: 99 

From this I can see that the ListView is removing the view with the
SeekBar in it (inside removeDetachedView) which calls
dispatchDetachedFromWindow and fires a MotionEvent.ACTION_CANCEL
event, causing the Tracking to stop.

I have not been able to figure out why the ListView is detaching the
SeekBar's view, and this does not seem to happen in my simple ListView
case. I will continue to debug the problem and generate a simple test
case others can use, but I thought I better ask.

thanks for any help on either problems
Andrew

[1] Shameless plug, but if anyone wants to see the SeekBarPreference
in action, download my new app MusicGrid and view the settings. As I
say the problem only appears on 2.2 phones.

-- 
You received this message because you 

Re: [android-developers] Re: List of Android Devices with specifications to use in Emulator

2010-09-08 Thread Andrew Brampton
On 8 September 2010 09:05, Fabrizio Giudici
fabrizio.giud...@tidalwave.it wrote:
 There's a more efficient way to gather these data. For instance, look
 at http://droidparade.noser.com/droidparade/droidparade.html


 They're collecting the data from people willing to run their
 diagnostic app. It's a very good approach since there's no manual copy
 of data and thus no errors, and they're collecting a large number of
 attributes for each model.
 You have to click on a model to have the details and data aren't ready
 to consume as in a spreadsheet, but it would not be difficult to write
 a small HTML scraper to automatically extract the data.

 - --
 Fabrizio Giudici - Java Architect, Project Manager


 =vbdq
 -END PGP SIGNATURE-

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

Very awesome. I had searched for a site like that but I didn't find anything.

thanks
Andrew

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


[android-developers] List of Android Devices with specifications to use in Emulator

2010-09-07 Thread Andrew Brampton
Hi,
I'm going to try something here, and hopefully it'll work.

I've written a few apps and occasionally I'll have someone email me
saying it doesn't work correctly on their phone. As I don't have
access to their phone I try and recreate their device in the emulator
by using the same Android version, screen size, and whatever else I
think is important.

Until now I've been keeping a list of all the different specifications
of the devices, as I couldn't find a good list online. So I figure
today I'd put what little research I've done into a spreadsheet and
share it with the Android community. What I also hope is that people
will start to add devices that I'm missing.

So please take a look at this spreadsheet and fill free to edit it (in
a sensible way). If there is another column of data you would like to
add then feel free and hopefully any blanks will be filled in.

https://spreadsheets.google.com/ccc?key=0AlXAdnQtmZFZdHBBcnBmNlkwU0JxSGVaWnJyRC1nc0Ehl=en_GBauthkey=CL2OsNkG

Thanks
Andrew

P.S Of course in a perfect world we shouldn't need such as list as our
apps should just work on any Android device, but I've noticed a few
minor quirks which have annoyed me in the past.

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

2010-09-06 Thread Andrew Brampton
Is anyone willing to share their code? Perhaps that will help us
figure out what's wrong.

Andrew

On 6 September 2010 10:41, Nand nandithab...@gmail.com wrote:
 Hi,
 Did you solve this stack corruption detected issue? Even I'm facing
 similar problem.

 Regards,
 Nand

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

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


Re: [android-developers] @override

2010-07-08 Thread Andrew Brampton
It is a Java annotation:
http://download.oracle.com/docs/cd/E17409_01/javase/tutorial/java/javaOO/annotations.html

Andrew

On 8 July 2010 11:49, B Woods bradleydeanwo...@gmail.com wrote:
 What is the purpose of this?

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

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


Re: [android-developers] Can I put a donation link in my free app?

2010-06-27 Thread Andrew Brampton
Yup donations are fine, you could even put adverts in.

Andrew

On 27 June 2010 14:16, Alex Xin xinxi...@gmail.com wrote:
 Hi, folks
 I want to login my app as free app, but I think maybe I can put a donation
 link in my app, of course, my users can use my app without any donations. I
 don't sell my app.
 Does Google allow developer to do this?
 Thanks a lot
 Alex

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

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


Re: [android-developers] Eclipse Helios

2010-06-23 Thread Andrew Brampton
I've been using the Android SDK with the Helios release candidate with
no problems.

Andrew

On 23 June 2010 05:24, BuckeyeDroid bill.schric...@gmail.com wrote:
 As you're probably aware, the Helios release of Eclipse is released on
 June 23rd. Will this be supported by the Android SDK?

 Thanks!

 --
 You received this message because you are subscribed to the Google
 Groups Android Developers group.
 To post to this group, send email to android-developers@googlegroups.com
 To unsubscribe from this group, send email to
 android-developers+unsubscr...@googlegroups.com
 For more options, visit this group 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: Android Library Project

2010-06-15 Thread Andrew Brampton
I reported this the bug to do with the src directories:
http://code.google.com/p/android/issues/detail?id=8502
I was looking at fixing it myself but I failed to get the eclipse
plugin to compile so I gave up, admittedly without putting much effort
in.

Andrew

On 12 June 2010 12:50, Ratamovic ratamo...@gmail.com wrote:
 Hi Xavier and all,

 There is clearly some problems with project naming.
 I usually name my projects with '-' (e.g. Project-Lib) but that
 doesn't work for my library unless I rename them (to ProjectLib) and
 restart my Eclipse. I also noticed that to create a link to a library
 project, the library and application source folder Must be named
 'src' (sadly I name them java since I work with the NDK...). I am not
 sure weither it would work if my source folder was inside 'src' (e.g.
 like 'src/java'). Also It is not working if your library src folder is
 in fact an Eclipse folder link. I need a hard Linux symbolic link.
 That would be really great to indicate these issues in the Android
 manual page :)!

 Regards.


 On 5 juin, 22:56, Xavier Ducrohet x...@android.com wrote:
 How does your library project depend on the (standard?) java project?

 From the refactoring feature point of view, both projects are Java
 project (a library project, like normal Android project, is both Java
 and Android projects), so I'm not sure how it's the fault of the
 library feature?
 (Now, after participating in this thread a couple weeks back, I have
 been to busy to see if linked folders in Eclipse have poor refactoring
 support, so there may be issues there. I'll try that soon hopefully)

 Anytime you touch a java file in a some advanced way (renaming,
 moving, extracting, refactoring) the android plug-in does nothing,
 it's all the JDT.

 In the end, I think dealing with the pain of refactoring might be
 worth it if the library really provides benefit once the refactoring
 is done, since this should be a one time thing, but you're going to
 use your library many times in various projects (I would expect, or
 you wouldn't need the library in the first place)

 Xav

 On Fri, Jun 4, 2010 at 10:47 PM, Mark Carter mjc1...@googlemail.com wrote:
  I had to abandon the Library Project approach in the end because I was
  running into so many eclipse errors it was really slowing me down. This is
  particularly true when refactoring - which, I suppose, is the first thing
  people do when changing their code to use libraries.
  For example, if your Library project depends on a Java project and you do
  things like rename packages in that Java project, then eclipse would throw
  up an error (unfortunately can't remember which one). Restarting eclipse
  didn't seem to make a difference. Workaround was to create a new package 
  and
  move classes into that. Didn't isolate the problem so there might be other
  factors involved here - like another Android project also depending on that
  Java project.

  On 3 June 2010 18:01, Didier Girard didier.gir...@gmail.com wrote:

  Xavier,
  I was just in front of the same problem.
  If you could just add a note about restarting eclipse in the following
  page it could help a lot :
 http://developer.android.com/guide/developing/eclipse-adt.html
  Thanks in advance,
  Didier

  On May 23, 9:06 pm, Xavier Ducrohet x...@android.com wrote:
   When you do the link between the main project and the library (as
   shown
   here:http://developer.android.com/images/developing/adt-props-libRef.png),
   try to simply restart Eclipse (I know it's annoying) and the link
   should happen.

   The library source folder will appear in your main project as a new
   source folder named after your library project name with a [Android
   Library] tag after it. I'm trying to attach a small screenshot that
   shows the connection.

   Xav

   On Sun, May 23, 2010 at 11:53 AM, Michael A. michael.aki...@gmail.com
   wrote:
Just to note that I am fully up to date with both the SDK and Eclipse
plugins, so that does not appear to be the problem.

On May 23, 8:45 pm, Michael A. michael.aki...@gmail.com wrote:
Yes - I realize that. It just doesn't work in my setup. :-(

I can see the R.java file from the library gets included in the
generated content, but i don't get access to the classes in the
library project. Very frustrating.

Regards,

Michael A.

On May 23, 7:24 pm, Lance Nanek lna...@gmail.com wrote:

 The only time I've seen that Could not find otherproject.apk
 warning was in the same situation as mentioned above, when the
 project
 being run used an Eclipse, Java Build Path, Project dependency on
 the
 other project.

 If you want to double check that you don't have that, right click
 on
 the project being run, choose Properties from the menu that pops
 up,
 then choose Java Build Path on the left, then choose the Projects
 tab.
 Make sure you don't have any Android projects listed there. With
 this
 

Re: [android-developers] Re: Developing Android REST client applications

2010-06-09 Thread Andrew Brampton
Ah thanks Streets Of Boston, I did not know about that guarantee. That
surely does make it easier and avoids losing updates.

Andrew

On 9 June 2010 02:29, Streets Of Boston flyingdutc...@gmail.com wrote:
 I report the result by using onPostExecute.

 Android guarantees that during a configuration change, no message will
 be posted to 'the' activity inbetween an onDestroy and an onCreate (i
 remember a post by Dianna about this).

 This means that the result from the onPostExecute either arrives
 before the activity is destroyed or after it is created (during a
 configuration change).

 I give the requests unique IDs and save these IDs within the 'last-
 configuration-change' object. When the onCreate is called, i get the
 'last-configuration-change' object and restore these IDs in the new
 activity instance.

 When the onPostExecute finishes, it queries which activity of the
 expected class is on top of the activity stack of my app. If it finds
 one, the result is sent to this activity and handled by it. If it
 can't find one, the activity has been paused (hidden) or permanently
 destroyed and the user is no longer interested in the result.


 On Jun 8, 7:45 pm, Andrew Brampton bramp...@gmail.com wrote:
 On 9 June 2010 00:02, Streets Of Boston flyingdutc...@gmail.com wrote:

  However, that approach can still lose responses or duplicate network
  usage if the Activity is destroyed/created while the AsyncTask is
  doing its job

  Is that an issue with the Droid-fu or with AsyncTask?
  I don't have that issue. When configuration changes take place, no new
  requests are duplicated and existing ones just keep going, as long as
  you put the AsyncTasks in a static context (not an (activity) instance
  context).

 Maybe I'm making an assumption about how you are using AsyncTask, but
 what happens in the gap between the old Activity being destroyed and
 before the new one has been created. What happens to the result in
 that gap as you have no valid Activity to display the result? Either
 you are losing your response, or you have to re-request it (hence
 duplicate network usage). Or I guess you could be storing the result
 temporary in your Application class?

 Andrew

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

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


Re: [android-developers] Re: Create Wav File

2010-06-09 Thread Andrew Brampton
This shows you how to write files to the SD card:
http://www.anddev.org/working_with_files-t115.html

Then you write your own wav header, and your own pcm samples.

Andrew

On 9 June 2010 08:37, zenoname zenonamem...@gmail.com wrote:
 Sorry but how it's gone help me to find how to create wav file with
 android SDK ?
 I know what is wav file format and how to create wav file using c++
 for example (add riff header, writing pcm samples ...)
 My question is : how can I do that with android SDK - 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

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

2010-06-09 Thread Andrew Brampton
Tell us what you have tried and what exactly you typed to get that
error message.

On 9 June 2010 16:47, HAROON RASEED haaro...@gmail.com wrote:
 Hi

 I am new to android development. I try to download source code from
 http://android.git.kernel.org/;. Its always through the error.
 fatal: The remote end hung up unexpectedly

 Please help me how to down load the code from repository.

 Thanks in Advance .

 Regards
 Haroon

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

2010-06-08 Thread Andrew Brampton
I've watched many of the Google IO talks and one that I'm trying to
reproduce is Developing Android REST client applications[1]. In this
talk Virgil suggests you should not execute your RESTful queries
inside a Thread/AsyncTask spawned from your Activity (which I had been
doing), instead you should use a more complex architecture that uses a
combination of a ContentProvider and a Service.

From what I understood the reason for this design was so your data was
more persistent between app restarts, and so your queries don't
disappear if your Activity starts/stops (e.g on a screen rotation). I
buy into both those reasons hence I'm trying to implement this.

On the slides[2] page 45 We have an Activity calling a
ContentProvider. Now the ContentProvider checks its local database, if
the content is not there it sends an Intent to a service which fetches
the content, inserts it into the ContentProvider, then the
ContentProvider calls back to the Activity (with a ContentObserver)
and the Activity can carry on. The question I have is how is this
callback setup. The ContentProvider exposes simple methods, query,
insert, update, delete which don't seem easy to adapt to a callback
interface.

It could be implemented by a Cursor which is designed to block, but
that could be problematic as you don't' want to block your UI Thread.
I'd appreciate if anyone could make this clearer to me, or show me
some code. I'm hoping the Twitter app will be open sourced soon which
apparently uses this architecture.

thanks
Andrew

[1] 
http://code.google.com/events/io/2010/sessions/developing-RESTful-android-apps.html
[2] 
http://dl.google.com/googleio/2010/android-developing-RESTful-android-apps.pdf

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

2010-06-08 Thread Andrew Brampton
On 8 June 2010 17:52, Mark Murphy mmur...@commonsware.com wrote:
 Andrew Brampton wrote:
 On the slides[2] page 45 We have an Activity calling a
 ContentProvider. Now the ContentProvider checks its local database, if
 the content is not there it sends an Intent to a service which fetches
 the content, inserts it into the ContentProvider, then the
 ContentProvider calls back to the Activity (with a ContentObserver)
 and the Activity can carry on. The question I have is how is this
 callback setup. The ContentProvider exposes simple methods, query,
 insert, update, delete which don't seem easy to adapt to a callback
 interface.

 The ContentObserver *is* your callback. You call
 registerContentObserver() to say that you want to find out about certain
 changes to the content, supplying a ContentObserver. That observer will
 be called with onChange() when such a change occurs.


On, so you call query() on a ContentProvider, which returns a empty
Cursor, call registerContentObserver on it, then when the Cursor
eventually gets the data your call back is called and you begin to use
the Cursor. That makes sense.


 I haven't watched the presentation yet but I did read through the
 slides. Off the cuff, the architecture presented there will probably
 work well for something that is pretty truly RESTful, where the REST API
 specifically is designed for inserting, updating, and deleting data. So,
 for example, I can easily see the Twitter API fitting their proposed
 architecture, at least for the timeline, but perhaps only for read
 operations.

I watched that presentation (and then many others) after reading your
suggestion on your blog. BTW Thanks for your blog, help and book (even
though admittedly I've not looked at your book).


 I'll have to experiment with their structure sometime and see if I can
 create some reusable bits to reduce the complexity. Based on the slides,
 this doesn't feel terribly easy for a developer to implement.


I was missing this Cursor registerContentObserver method, but I feel I
can implement this myself and put it on github. If you want I can
email you when I'm done.

thanks
Andrew

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

2010-06-08 Thread Andrew Brampton
On 8 June 2010 20:25, Streets Of Boston flyingdutc...@gmail.com wrote:
 I still need to watch this talk... when i get some time :-)

 Right now i'm working on a project for my job that involves a REST-ful
 client on Android and a REST server.

 I have not implemented the REST-communication on the client using a
 ContentProvider and Service. I did do that a good year ago with
 another project (Smugmug REST) and it's elegant, but I found that it
 is not really necessary.

 In my current project, I've implemented the REST-communication using
 AsyncTask and the 'Restlet for Android' library. The AsyncTask holds
 on to an application-context (not the context of an activity, since
 that could introduce memory leaks) and keeps track of pending REST-
 requests in an object passed around by through 'last-configuration-
 instance'. By not using a ContentProvider/Service, the callback
 mechanisms has been simplified a *lot*.



Thanks for your input. Holding onto the application context is
actually the way I'm doing it now, using the Droid-fu[1] library which
simplifies things a lot. However, that approach can still lose
responses or duplicate network usage if the Activity is
destroyed/created while the AsyncTask is doing its job.

I would be interested to hear other people's opinions on this matter.
But for no reason other than it be interesting to see how well it
works I am going to try the Service/ContentProvider approach.

Andrew

[1] http://github.com/kaeppler/droid-fu

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

2010-06-08 Thread Andrew Brampton
I would agree that the bug tracker needs more developers looking at
it, and this was mentioned at Google IO during one of the discussions.

However, I have to say the bugs I have reported have been assigned and
fixed promptly, but my bugs have mostly been minor, and weren't
feature changes.

But I still agree the Google needs to improve their response to bugs,
and for their developers to ignore, OR outright refuse without reason
changes. For example, one suggested change I found earlier today[1]
was replied with Thanks for the feedback, but this behavior is
working as intended., when the bug was about extending the behaviour
to make it far more useful.

Andrew

[1] http://code.google.com/p/android/issues/detail?id=665

On 7 June 2010 06:58, Colin colinjone...@gmail.com wrote:
 I find astounding, rude and arrogant the complete disregard with which
 Google treats people attempting to access help on the tracker.

 Thread after thread - even ones that are 18+ months old, with 400+
 posts and nearly 1000 stars, have gone completely unanswered - look at
 the Wifi/Proxy issue for instance, or the Gapless audio, or even the
 3g-to-WiFi switching issues that has many hundreds of posts and only
 towards the end is there even a luke-warm response from Google! But no
 ownership or actual interest.

 Most of the tickets are still, perversely, marked as New even after a
 year of people begging, pleading, demanding solutions!! No owner
 allocated.

 I could understand if somehow the development resources available to
 the world's fastest growing and probably most successful mobile OS
 were limited - but given the fanfare, hype, etc from Google, that
 seems unlikely. But the VERY LEAST someone could do is respond to
 these poor bastards, and acknowledge their pain, even if it is just to
 say we are too busy to address this right now.

 But no, the response is, no response. Deafening silence. The rudeness
 and arrogance is mindboggling!! Where the hell are your customer
 service skills?

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

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


Re: [android-developers] Re: Developing Android REST client applications

2010-06-08 Thread Andrew Brampton
On 9 June 2010 00:02, Streets Of Boston flyingdutc...@gmail.com wrote:
 However, that approach can still lose responses or duplicate network
 usage if the Activity is destroyed/created while the AsyncTask is
 doing its job

 Is that an issue with the Droid-fu or with AsyncTask?
 I don't have that issue. When configuration changes take place, no new
 requests are duplicated and existing ones just keep going, as long as
 you put the AsyncTasks in a static context (not an (activity) instance
 context).



Maybe I'm making an assumption about how you are using AsyncTask, but
what happens in the gap between the old Activity being destroyed and
before the new one has been created. What happens to the result in
that gap as you have no valid Activity to display the result? Either
you are losing your response, or you have to re-request it (hence
duplicate network usage). Or I guess you could be storing the result
temporary in your Application class?

Andrew

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

2010-05-31 Thread Andrew Brampton
I've just sent a complaint to http://www.justhost.com/submit-ticket
which I believe is their webhost. Perhaps others who have their apps
illegally listed on there should do the same.

Andrew

On 31 May 2010 23:51, Paul Burke (iPaul Pro) mr.paulbu...@gmail.com wrote:
 Please be aware that http://android-themes.com is pirating paid apps.
 I already found both of mine on there.

 Thought some of you would like to know.

 Paul (iPaul Pro)
 Finer Mobile

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

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


Re: [android-developers] Re: Android Library Project

2010-05-27 Thread Andrew Brampton
On 26 May 2010 19:58, Mark Carter mjc1...@googlemail.com wrote:
 On 26 May 2010 20:33, Xavier Ducrohet x...@android.com wrote:

 The problem is not so much generating the R class, it's making sure
 the library project is compiled with this composite R class made of
 all the projects (main + libs).

 Is it essential for the library project to be compiled with the composite R
 class?
 At each level in the library hierarchy, the R class would only include the
 resources of its own project and any descendant libraries. You could enforce
 that no two projects in the hierarchy define the same resource (otherwise
 give a compiler error).


By compiling the library with the composite R you are allowing your
application to override a resource used by the library. Which I think
is a very good thing.

Andrew

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