Re: [android-developers] Re: Android Dev Phone with 2.x?
By the way, Google has shutdown their online phone shop ( as I remember). I don't think you can get Nexus One directly from Google anymore. 2010/6/3 Tomáš Hubálek tom.huba...@gmail.com I'm trying to put this question to the top again as I would like to know the answer from Google. For me as owner of ADP1 is starts more and more important as I don't believe in official Froyo port for ADP1. Thanks Tom On 21 kvě, 06:57, Tomáš Hubálek tom.huba...@gmail.com wrote: Nexus One is not (contrary to Dev phones) available in our country (Czech Republic, EU member!). And probably never will be... :-( Tom On May 21, 2010 12:58 AM, Eddie Ringle ed...@eringle.net wrote: I think the Nexus One counts as the current unofficial Android Developer Phone. (Unofficial in that it hasn't been given that title officially) On May 14, 9:36 am, Tomáš Hubálek tom.huba...@gmail.com wrote: Hello, I'm owner of ADP1 (1... -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 athttp:// 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%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Regards, Michael Leung http://www.itblogs.info http://www.michaelleung.info -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Developing sotfkeyboard
'The sample soft keyboard'? Which one? And will it work even on phones that have no localization for Amharic? On Jun 3, 10:52 pm, andu alemf...@yahoo.com wrote: how are you all? I am trying to develop soft keyboard in my language, Amharic (Ethiopian language). I start developing the soft keyboard by using the sample soft keyboard with is included in the android SDK. But I have the following questions to ask: 1. How can I include keyboard setting options such as vibrate on key press, sound on key press, etc. such setting options are available in English soft keyboard. If you have any idea about this, please help me. 2. The other question is related to copyright issue. If I can succeed in developing the keyboard and want to sell it in market, am I going to violate the copyright law? Because I have developed this application by using the sample soft keyboard. thank you in advance -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Multiple notifications, single icon on notification bar?
Can't you do what GMail does and shows the # of items in parantheses? On Jun 4, 8:51 am, TreKing treking...@gmail.com wrote: On Thu, Jun 3, 2010 at 5:30 PM, Mark Wyszomierski mar...@gmail.com wrote: Is there a way to use only one icon on the notification bar, but still keep three entries in the pull down? Don't think so - each icon represents an entry in the pull down - having one icon represent multiple entries wouldn't really make sense. The docs say that setting notification.number to zero or a negative # will prevent it from showing up on the notifications bar, This prevents the number that's overlayed on the icon from showing up, not the icon itself. ----- TreKing - Chicago transit tracking app for Android-powered deviceshttp://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 sotfkeyboard
http://code.google.com/p/android-greek-ime/ Gala On Fri, Jun 4, 2010 at 3:30 PM, Indicator Veritatis mej1...@yahoo.com wrote: 'The sample soft keyboard'? Which one? And will it work even on phones that have no localization for Amharic? On Jun 3, 10:52 pm, andu alemf...@yahoo.com wrote: how are you all? I am trying to develop soft keyboard in my language, Amharic (Ethiopian language). I start developing the soft keyboard by using the sample soft keyboard with is included in the android SDK. But I have the following questions to ask: 1. How can I include keyboard setting options such as vibrate on key press, sound on key press, etc. such setting options are available in English soft keyboard. If you have any idea about this, please help me. 2. The other question is related to copyright issue. If I can succeed in developing the keyboard and want to sell it in market, am I going to violate the copyright law? Because I have developed this application by using the sample soft keyboard. thank you in advance -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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 generating final archive
Did you try Project - Clean? Not even sure if its relevant, but something similar happened to me a few weeks ago and that helped. On Jun 3, 1:00 pm, Matthew Patience matthewj.patie...@gmail.com wrote: I am trying to add some updates to an already released application but something has happened with my workspace that prevents me from Running or Exporting the application. I keep getting the following: Error generating final archive: duplicate entry: res/drawable-hdpi/ icon.png TwitocTwo Unknown Android Packaging Problem You think it would be an easy fix but I looked into the HDPI drawables folder and there were no doubles. I even went as far as to delete the entire folder and the error still appears. Anyone got any clever ideas? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: glGenTextures going crazy on actual device
As per another thread, I do feel there is a relationship to: GLUtils.texImage2D( GL10.GL_TEXTURE_2D, 0, bitmap, 0); involved as well. but to give a little example, this works in google api 3: glGenTextures() // allocate texture Ids // prep an individual texture glBindTexture( an id we got from glGenTextures() GLUtils.texImage2D( GL10.GL_TEXTURE_2D, 0, bitmap, 0); gl.glTexParameterf( GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_S, GL10.GL_CLAMP_TO_EDGE ); So, again, in 1.5 that works fine for all textures (total set is about 20 textures). But in 1.6, about half of those textures end up rendering all white. And if I enable debugging: setDebugFlags( DEBUG_CHECK_GL_ERROR | DEBUG_LOG_GL_CALLS ); Then I get a GL check error in the call to gl.glTexParameterf( GL10.GL_TEXTURE_2D, GL10.GL_TEXTURE_WRAP_S, GL10.GL_CLAMP_TO_EDGE ); But I get that error for every texture, not just the ones that render white with debugging turned off. if I remove the texParameter call, then I get an error in whatever the next thing I do with that texture handle is. But if I remove the GLUtils() call, then I get no errors at all (but all textures are white). But it doesn't complain about the handles. So, it's like some calls to GLUtils.texImage2D() manage to corrupt things enough to screw up subsequent calls. (though it's not the source bitmaps, I can scramble those and the error tracks the texture Id, not the bitmap) But, others have complained about GLUtils, and the fact that the GLUtil call generates no logging whatsoever makes me wonder if there is some context violation there. (and maybe the gl error is just a red herring due to GLUTil not going through the same wrapper code that the debugging turns on.) ANYWAY, since I had nothing better to waste two hours on in the sweaty 102 degree heat... I converted the code to load the pixels into directallocated byte buffers and use the raw glTexImage2D function instead. So now I don't use GLUtils at all, and... it fails in exactly the same way. Eventually I will be frustrated enough to return to api 3, I imagine. But it's got to be something extremely simple. - Dan On Jun 3, 9:51 pm, Samsyn d...@synthetic-reality.com wrote: For what it's worth, I started having the identical problem this evening, after changing my app to use API4 instead of API3 (where the glGenTextures() was working fine) Now I get the exact same list of goofy texture Ids when I use my phone (Droid 2.1), but it's fine in the emulator. At first I thought maybe it was unhappy with an int[] and really was starting to insist on an IntBuffer, but nope... Now, API4 brings GL11 to play, and I am still using all the GL10 constants, and setDebugFlags( DEBUG_CHECK_GL_ERROR | DEBUG_LOG_GL_CALLS ); (which I also turned on this evening) is still giving me some other complaints... so I am going to work through those in the emulator and see if it fixes the glGenTextures() on its own. The emulator is just so painfully slow in GL, it's sort of a drag :-) And I really don't want to have to sift through for positive values my code is all clean and neat at the moment and I hate to bend it in that way... - Dan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Call a service hosted in a windows service from Android
Hello! Yes you did undertand the issue, and i tried what u said yesterday and it didn't work, and yes i'm calling my wcf from the emulator, and i call my wcf using soap and http protocole like this : try { SoapObject request = new SoapObject(NAMESPACE, METHOD_NAME); request.addProperty(value, 2); SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11); envelope. dotNet=true; envelope.setOutputSoapObject(request); HttpTransportSE androidHttpTransport = new HttpTransportSE(URL); androidHttpTransport.call( SOAP_ACTION, envelope); SoapObject result = (SoapObject)envelope.getResponse(); } catch (Exception e) { } Thx 2010/6/3 Brad Gies rbg...@gmail.com It should work fine using localhost for the service address. Just use the real IP address of your machine when calling the service from Android. Are you calling it from the emulator or from a cell phone? How are you connected to your PC from your Android app? I just want to be sure I am understanding what you are doing. If I understand correctly, your WCF service is on your PC and you can access it using your browser (also on your PC) using localhost. When you call the WCF service from Android you are not finding it, or it's not returning. If that's the case then from a Windows command line prompt do ipconfig /all, find your machines IP address (in my case it's 192.168.1.103 and use that instead of localhost when you are calling the service from your Android app. If I'm misunderstanding, please clarify :). Good luck. On 03/06/2010 8:33 AM, Lamia Hannoun wrote: I tried also to change the adress of my endpoints :s but it didn't work :(. I want to know if i changed the adresse of my service (different that loacalhost) it will work perfectly isn't it, this pb is only caused by this local address ??? Am i right? Has anyone test this before? cuz till now i'm developping don't have a server yet to use its address!! Thx 2010/6/3 Lamia Hannoun lamia.hann...@gmail.com mailto: lamia.hann...@gmail.com U mean using it instead of using 10.0.2.2 or in the adress endpoint of the wcf, i did the first option it didn't work :s :s 2010/6/3 Brad Gies rbg...@gmail.com mailto:rbg...@gmail.com Try using the real IP address of your machine. That works (for me at least). On 03/06/2010 5:50 AM, Lamia Hannoun wrote: Hello! I hosted my service WCF (.net) using a windows service, i can access to the service from any browser but when i tried to call it from android it doesn't respond. it works fine before the hosting procedure (i used host client by default on Visual Studio). The url that i try to attempt is http://10.0.2.2/.. from android emulator, and installed my webservice in the same local machine(endpoints address http://localhost http://localhost/ http://localhost/.). Thx for any help !! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com mailto:android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com mailto:android-developers%2bunsubscr...@googlegroups.comandroid-developers%252bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Sincerely, Brad Gies --- Bistro Bot - Bistro Blurb http://www.bgies.com http://www.bgies.com/ http://www.bistroblurb.com http://www.bistroblurb.com/ http://www.bistrobot.com http://www.bistrobot.com/ --- Never doubt that a small group of thoughtful, committed people can change the world. Indeed. It is the only thing that ever has - Margaret Mead -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com mailto:android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com mailto:android-developers%2bunsubscr...@googlegroups.comandroid-developers%252bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message
[android-developers] Re: glGenTextures going crazy on actual device
and yes, if I regress to api 3, the problem goes away, but apis 4 and 5 both have the problem. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Map is not dispalying in the android emulator
Hi, Thanks for your reply, i am posting the source code, manifest file and layout here. this application developed as per the below link. http://mobiforge.com/developing/story/using-google-maps-android please guide me , what i am doing wrong in this. 1.certificate fingure print which i generated from command prompt keytool.exe -list -alias androiddebugkey -keystore C:\Documents and Settings\sujai.s\.android\ debug.keystore -storepass android -keypass android Certificate FingurePrint MD5 :99:31:66:92:62:81:96:1D: 3F:F0:48:C2:9A:C4:33:CB 2..API KEY generated by google account Thank you for signing up for an Android Maps API key! Your key is: 0QdugGF3zaZNNlcTKc-t-JIr7TuUP2Rt2mf3a6 AThis key is good for all apps signed with your certificate whose fingerprint is: 99:31:66:92:62:81:96:1D:3F:F0:48:C2:9A:C4:33:CBHere is an example xml layout to get you started on your way to mapping glory: com.google.android.maps.MapView android:layout_width=fill_parent android:layout_height=fill_parent android:apiKey=0QdugGF3zaZNNlcTKc-t- JIr7TuUP2Rt2mf3a6A / 3..source code: package com.example.android.location; import com.google.android.maps.MapActivity; import android.app.Activity; import android.os.Bundle; public class currentlocation extends MapActivity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); } @Override protected boolean isRouteDisplayed() { // TODO Auto-generated method stub return false; } } 4..Mnifest file: ?xml version=1.0 encoding=utf-8? manifest xmlns:android=http://schemas.android.com/apk/res/android; package=com.example.android.location android:versionCode=1 android:versionName=1.0 application android:icon=@drawable/icon android:label=@string/ app_name uses-library android:name=com.google.android.maps android:required=true/uses-library activity android:name=.currentlocation android:label=@string/app_name intent-filter action android:name=android.intent.action.MAIN / category android:name=android.intent.category.LAUNCHER / /intent-filter /activity /application uses-permission android:name=android.permission.INTERNET/uses- permissionuses-sdk android:minSdkVersion=8 / /manifest 5..Main.xml file ?xml version=1.0 encoding=utf-8? LinearLayout xmlns:android=http://schemas.android.com/apk/res/ android android:orientation=vertical android:layout_width=fill_parent android:layout_height=fill_parent com.google.android.maps.MapView android:layout_width=fill_parent android:layout_height=fill_parent android:apiKey=0QdugGF3zaZNNlcTKc-t- JIr7TuUP2Rt2mf3a6A / /LinearLayoutmenu xmlns:android=http://schemas.android.com/apk/res/ android/menu thanks aswini -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Call a service hosted in a windows service from Android
But maybe if a use a different address it'll work perfectly?? Don't u think? because the emulator can't reach the local host by using (localhost or 127.0.0.1) by default localhost=10.0.2.2 http://developer.android.com/guide/developing/tools/emulator.html I don't know how it worked for u?!!! 2010/6/4 Lamia Hannoun lamia.hann...@gmail.com Hello! Yes you did undertand the issue, and i tried what u said yesterday and it didn't work, and yes i'm calling my wcf from the emulator, and i call my wcf using soap and http protocole like this : try { SoapObject request = new SoapObject(NAMESPACE, METHOD_NAME); request.addProperty(value, 2); SoapSerializationEnvelope envelope = new SoapSerializationEnvelope(SoapEnvelope.VER11); envelope. dotNet=true; envelope.setOutputSoapObject(request); HttpTransportSE androidHttpTransport = new HttpTransportSE(URL); androidHttpTransport.call( SOAP_ACTION, envelope); SoapObject result = (SoapObject)envelope.getResponse(); } catch (Exception e) { } Thx 2010/6/3 Brad Gies rbg...@gmail.com It should work fine using localhost for the service address. Just use the real IP address of your machine when calling the service from Android. Are you calling it from the emulator or from a cell phone? How are you connected to your PC from your Android app? I just want to be sure I am understanding what you are doing. If I understand correctly, your WCF service is on your PC and you can access it using your browser (also on your PC) using localhost. When you call the WCF service from Android you are not finding it, or it's not returning. If that's the case then from a Windows command line prompt do ipconfig /all, find your machines IP address (in my case it's 192.168.1.103 and use that instead of localhost when you are calling the service from your Android app. If I'm misunderstanding, please clarify :). Good luck. On 03/06/2010 8:33 AM, Lamia Hannoun wrote: I tried also to change the adress of my endpoints :s but it didn't work :(. I want to know if i changed the adresse of my service (different that loacalhost) it will work perfectly isn't it, this pb is only caused by this local address ??? Am i right? Has anyone test this before? cuz till now i'm developping don't have a server yet to use its address!! Thx 2010/6/3 Lamia Hannoun lamia.hann...@gmail.com mailto: lamia.hann...@gmail.com U mean using it instead of using 10.0.2.2 or in the adress endpoint of the wcf, i did the first option it didn't work :s :s 2010/6/3 Brad Gies rbg...@gmail.com mailto:rbg...@gmail.com Try using the real IP address of your machine. That works (for me at least). On 03/06/2010 5:50 AM, Lamia Hannoun wrote: Hello! I hosted my service WCF (.net) using a windows service, i can access to the service from any browser but when i tried to call it from android it doesn't respond. it works fine before the hosting procedure (i used host client by default on Visual Studio). The url that i try to attempt is http://10.0.2.2/.. from android emulator, and installed my webservice in the same local machine(endpoints address http://localhost http://localhost/ http://localhost/.). Thx for any help !! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com mailto:android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com mailto:android-developers%2bunsubscr...@googlegroups.comandroid-developers%252bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Sincerely, Brad Gies --- Bistro Bot - Bistro Blurb http://www.bgies.com http://www.bgies.com/ http://www.bistroblurb.com http://www.bistroblurb.com/ http://www.bistrobot.com http://www.bistrobot.com/ --- Never doubt that a small group of thoughtful, committed people can change the world. Indeed. It is the only thing that ever has - Margaret Mead -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com mailto:android-developers@googlegroups.com To unsubscribe from this group, send email to
[android-developers] Re: Two articles on Android app development
The experience I shared there was practical - and there are times and requirements when you do need to start a service at the boot time, and it's really better to run it in a separate process. For example, any mail-like application would have such requirements. Autostart might be useful, but usually the service doesn't need to run all the time. I'd stop the service after retrieving mail (unless it's bound, i.e. an activity is visible, of course) and use AlarmManager to schedule the next update. OK, push mail might be a different story... However in my experience, many users don't check running services but use task managers, where services are listed once they ran to handle a broadcast and are stopped for ages, so you'd get complaints about always running services anyway. ;) It's probably the simplicity of the functionality of that small example that makes the chosen architecture look a bit overshot. Partly that, partly because of the huge amount of misunderstandings in several other blogs, books and forums, partly because of weird behaviour on some devices and/or older Android versions. E.g. I had some troubles with local services that were suspended when the activity of the same app was left (yes, I did startService before bindService - pretty mean pitfall for beginners btw.), so I did a remote service. Now it works as local service as well, I assume android:exported=true did the trick... Now, I would be happy to hear something about the loopers and the handlers. :) Just one note: I think Services do have internal Loopers as well, not just the UI thread. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Map is not dispalying in the android emulator
from your code, just remove, android:required=true from uses- library tag. For you, i created a simple program to display map as, public class ShowMap extends MapActivity { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); MapView mapView = new MapView(this, 0QTYhfJNb0lwM3PQi_6xS4NvSE-SeVI23aNlIMg); setContentView(mapView); } @Override protected boolean isRouteDisplayed() { // TODO Auto-generated method stub return false; } } and the manifest is, ?xml version=1.0 encoding=utf-8? manifest xmlns:android=http://schemas.android.com/apk/res/android; package=com.showmap android:versionCode=1 android:versionName=1.0 uses-permission android:name=android.permission.INTERNET / application android:icon=@drawable/icon android:label=@string/ app_name uses-library android:name=com.google.android.maps/uses-library activity android:name=.ShowMap android:label=@string/app_name intent-filter action android:name=android.intent.action.MAIN / category android:name=android.intent.category.LAUNCHER / /intent-filter /activity /application /manifest Nithin On Jun 4, 12:40 pm, aswini aswin...@gmail.com wrote: Hi, Thanks for your reply, i am posting the source code, manifest file and layout here. this application developed as per the below link.http://mobiforge.com/developing/story/using-google-maps-android please guide me , what i am doing wrong in this. 1.certificate fingure print which i generated from command prompt keytool.exe -list -alias androiddebugkey -keystore C:\Documents and Settings\sujai.s\.android\ debug.keystore -storepass android -keypass android Certificate FingurePrint MD5 :99:31:66:92:62:81:96:1D: 3F:F0:48:C2:9A:C4:33:CB 2..API KEY generated by google account Thank you for signing up for an Android Maps API key! Your key is: 0QdugGF3zaZNNlcTKc-t-JIr7TuUP2Rt2mf3a6 AThis key is good for all apps signed with your certificate whose fingerprint is: 99:31:66:92:62:81:96:1D:3F:F0:48:C2:9A:C4:33:CBHere is an example xml layout to get you started on your way to mapping glory: com.google.android.maps.MapView android:layout_width=fill_parent android:layout_height=fill_parent android:apiKey=0QdugGF3zaZNNlcTKc-t- JIr7TuUP2Rt2mf3a6A / 3..source code: package com.example.android.location; import com.google.android.maps.MapActivity; import android.app.Activity; import android.os.Bundle; public class currentlocation extends MapActivity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); } @Override protected boolean isRouteDisplayed() { // TODO Auto-generated method stub return false; } } 4..Mnifest file: ?xml version=1.0 encoding=utf-8? manifest xmlns:android=http://schemas.android.com/apk/res/android; package=com.example.android.location android:versionCode=1 android:versionName=1.0 application android:icon=@drawable/icon android:label=@string/ app_name uses-library android:name=com.google.android.maps android:required=true/uses-library activity android:name=.currentlocation android:label=@string/app_name intent-filter action android:name=android.intent.action.MAIN / category android:name=android.intent.category.LAUNCHER / /intent-filter /activity /application uses-permission android:name=android.permission.INTERNET/uses- permissionuses-sdk android:minSdkVersion=8 / /manifest 5..Main.xml file ?xml version=1.0 encoding=utf-8? LinearLayout xmlns:android=http://schemas.android.com/apk/res/ android android:orientation=vertical android:layout_width=fill_parent android:layout_height=fill_parent com.google.android.maps.MapView android:layout_width=fill_parent android:layout_height=fill_parent android:apiKey=0QdugGF3zaZNNlcTKc-t- JIr7TuUP2Rt2mf3a6A / /LinearLayoutmenu xmlns:android=http://schemas.android.com/apk/res/ android/menu thanks aswini -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more
[android-developers] How to show a dialog even if the Activity is in background
If my Activity is switched to background, when something takes place, I want to show a dialog without switching the Activity to foreground. In other word, no matter what application is running on foreground, use can watch the dialog. Thanks. -Jiang. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Play 2 sounds at once with different apps?
Android supports mixing of audio streams. http://developer.android.com/reference/android/media/SoundPool.html As for Pandora, yes, I have to pause it before playing YouTube or it will mix the two. On Jun 3, 6:56 pm, bschuhma b...@thelastmilellc.com wrote: Is it possible to play audio via an app like slacker.com or pandora.com or your personal audio files and simultaneously play another audio track over the top of it with a second app? My question is whether the sound hardware gets locked by the first app that accesses the audio hardware or whether a second app can access the hardware simultaneously, too. Thanks, Bret -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 graphical capabilities
Yeah, it's the dynamics that really give it a nice feel. And a touch-list without fling support is not useful at all... Though the third part of the tutorial is not quite ready yet. It will probably be posted in about a week on the blog. Untill then I suggest playing around with the graphics :) BTW, if you (or anyone else) have any ideas or requests for other tutorials, let me know! We are planning to continue with tutorials and it would be great if you had any input. No promises though :) /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Neilz Sent: den 3 juni 2010 20:16 To: Android Developers Subject: [android-developers] Re: Android graphical capabilities Hi Anders. Do you have the code for part 3 available? The first two are great, but really it's not so great without the finishing touches from part 3! On Jun 3, 2:18 pm, Ericson, Anders anders.eric...@sonyericsson.com wrote: The reference app on market has minSdkVersion set to 4 (=1.6) and the main reason is to enable the support for different screen sizes (mdpi, ldpi, hdpi). The code itself has very little (if any) dependencies to 1.6 specific APIs. You can always download the code and just rename the directories for the drawables, that should be enough to get it to work on a 1.5 device. We'll look into supporting 1.5 for the reference app as well. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Neilz Sent: den 3 juni 2010 14:21 To: Android Developers Subject: [android-developers] Re: Android graphical capabilities Hi Anders. Thanks for these, they look great, just the sort of thing I'm after. I notice that it isn't available for my older Hero with 1.5. Is this not compatible with 1.5? How would you resolve that if you wanted your app to reach all devices? On Jun 3, 11:37 am, Ericson, Anders anders.eric...@sonyericsson.com wrote: Hi, I recently wrote a tutorial on how to do a cool 3D list. You can find the latest part on: http://blogs.sonyericsson.com/developerworld/category/tutorials/ There you can also find a tutorial on how to do a cool zoom written by a colleague of mine. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Neilz Sent: den 3 juni 2010 10:38 To: Android Developers Subject: [android-developers] Android graphical capabilities My apps are functionally good, and in my time learning android I have covered most features. But one thing my apps lack is graphical coolness... you know the type of thing the top branded apps have, and particularly those from the iPhone which are always very impressive. I want to improve my graphical skills for layouts, menus, galleries, interactive buttons - the kind of stuff that makes your apps look great, as well as performing well. What should I look at? Where should I start? Any links, tips, welcome! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://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 athttp://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
[android-developers] Re: Android finishActivity()
hi Sean Hodges, it's working correctly. and is there a way to achieve this thing using startActivity()??? Starting Activity B like this startActivity(intent); so when i press back button from Activity B i'm doing this @Override public boolean onKeyDown(int keyCode, KeyEvent event) { // TODO Auto-generated method stub if (keyCode == KeyEvent.KEYCODE_BACK) { finish(); return true; } return false; } and i don't want to redirect to the Activity A. i just want to send it to another activity. is this possible??? regards, Mike -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Android finishActivity()
hi Sean Hodges, it's working correctly. and is there a way to achieve this thing using startActivity()??? Starting Activity B like this startActivity(intent); so when i press back button from Activity B i'm doing this @Override public boolean onKeyDown(int keyCode, KeyEvent event) { // TODO Auto-generated method stub if (keyCode == KeyEvent.KEYCODE_BACK) { finish(); return true; } return false; } and i don't want to redirect to the Activity A. i just want to send it to another activity. is this possible??? regards, Mike -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] problem installing my app on real device
Thanks i'll try to check for UnknownSources is ON And about device view: i am not adding it into device list. I just copying apk on the device (over USB cable) , and then try to install it. About zipalign: doesn't Eclipse do it for you? On Jun 3, 12:20 pm, 楊健 youken1...@gmail.com wrote: 1.Can you see your phone in the devices view? If you can't maybe you should install a driver first. 2.Maybe you had installed the same app with different sign.At this case you can uninstall the old app first. 3.Check your setting of setting - application - UnknownSources is ON when you try to install a debug app on the phone. 4.Have you seen the zipalign.exe part of the SDK document? Can you show the log of Console? -元のメッセージ- 差出人: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] 代理人 alariq 送信日時: 2010年6月3日 17:59 宛先: Android Developers 件名: [android-developers] problem installing my app on 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] Stop mobile modem
Hi all, I search for a long time to stop the mobile modem (to restart it later). In this group, I watch some thread indicating a reference to APNdroid. Apparently it works changing the APN (name or other information) to cut the connection. Is there only this way? WifiManager has its own method to turn off. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 finishActivity()
Mike, You need to think of activities like a stack of cards. If you open one, it will be placed on top of the pack. So if you want to open a new activity from Activity B, just do use startActivity() as normal. Activity A --- Activity B -- Activity C When you close Activity C, do a setResult(RESULT_CANCELLED) followed by finish() just like I described for Activity B. Activity B will handle the onActivityResult(), where you tell it to do the same thing again. This way you are popping the activities off the stack one-by-one, when there are no more activities left, the app will close. To the user, this will appear as though Activity A and Activity B had been closed when Activity C opened. Your second option, which I did not think of before, is to add the android:noHistory=true attribute to Activity A and Activity B in your AndroidManifest.xml. I don't have much experience with this flag, but my understanding is that it will close the current activity when another one is opened. The first approach will give you more control, but this attribute might be simpler: http://developer.android.com/intl/fr/guide/topics/manifest/activity-element.html#nohist If I'm on the wrong track here, perhaps you could describe what you want step-by-step. At the moment, it sounds like you want the stack to have just one activity at all times. Cheers, Sean On Fri, Jun 4, 2010 at 9:52 AM, mike hasitharand...@gmail.com wrote: hi Sean Hodges, it's working correctly. and is there a way to achieve this thing using startActivity()??? Starting Activity B like this startActivity(intent); so when i press back button from Activity B i'm doing this �...@override public boolean onKeyDown(int keyCode, KeyEvent event) { // TODO Auto-generated method stub if (keyCode == KeyEvent.KEYCODE_BACK) { finish(); return true; } return false; } and i don't want to redirect to the Activity A. i just want to send it to another activity. is this possible??? regards, Mike -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] 最近写了两个应用,MMTi mer,火车余票查询
*火车余票查询* http://www.androidin.net/bbs/android-110739-1-1.html *MMTimer* http://www.androidin.net/bbs/android-110551-1-1.html MMTimer的widget有问题,现在还没有放出来,对widget的更新还不是很清楚,有点问题。稍后还需要大家的帮忙,遇到了更新问题了。 MMTimer让您每天拥有1440次恋爱。 *主要功能 -MMTimer每一分钟自动更新内容,更换不同的照片,一分钟一张图片,一份欣 喜,一小时60张微笑,一天1440次约会。 -系统资源占用率低; -提供高清真人报时图片,看时间看美女两不误; -采用离线数据库,一张图片按30K来计算,一小时就是1800K,一天就是1800*24/1024=42M,为您节省宝贵的流量; -提供不同版本的报时主题,目前暂提供美女车模版,街头美女版,街头美女版 II,后续将推出更多的版本; -美女车模版和街头美女版II由于服务器不稳定,数据有少量丢失,但不影响使用,用户可以自定义图片; 美女数据大家可以从 https://code.google.com/p/mmtimer/downloads 处下载得到,放到/sdcard/MMTimer目录下; -可以自定义不同时间的MM或帅锅; -自定义不同版本的时间,亲人好友等的都行; -提供保存,让你在什么时候也可以看到您喜欢的MM; 大家有兴趣就支持下吧,呵呵。 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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/LocationManager does not give a fix in my app
I am waiting a few minutes. long enough I think, specially considering that, as I mentioned before, other apps like Google Maps get a fix after just a few seconds. So it shouldn't be a matter of waiting, I guess there has to be something I am doing wrong, thou I'm unable to find what. Oh and I'm trying it outdoors, shouldn't be a signal strength related problem either. Any other suggestions are more than welcome. Thank you! On Jun 4, 5:45 am, Maps.Huge.Info (Maps API Guru) cor...@gmail.com wrote: Don't forget that it doesn't work well indoors either... -John Coryat -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] problem installing my app on real device
It seems you have done everything for releasing a apk. You need not to enable the UnknownSources if you have signed the apk file correctly. : ) -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of alariq Sent: Friday, June 04, 2010 6:00 PM To: Android Developers Subject: Re: 返: [android-developers] problem installing my app on real device Thanks i'll try to check for UnknownSources is ON And about device view: i am not adding it into device list. I just copying apk on the device (over USB cable) , and then try to install it. About zipalign: doesn't Eclipse do it for you? On Jun 3, 12:20 pm, 楊健 youken1...@gmail.com wrote: 1.Can you see your phone in the devices view? If you can't maybe you should install a driver first. 2.Maybe you had installed the same app with different sign.At this case you can uninstall the old app first. 3.Check your setting of setting - application - UnknownSources is ON when you try to install a debug app on the phone. 4.Have you seen the zipalign.exe part of the SDK document? Can you show the log of Console? -元のメッセージ- 差出人: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] 代理人 alariq 送信日時: 2010年6月3日 17:59 宛先: Android Developers 件名: [android-developers] problem installing my app on 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Any ScoreLoop users out there?
Hi Nightwolf, Yes we do give a hoot about such things! We have an English language blacklist that would filter and reject profanity. Unfortunately, currently, you would not be able to attach pictures to user profiles. Regards, Junde On Jun 2, 12:25 pm, Nightwolf mikh...@gmail.com wrote: Sometimes users enter profanity as their nick name. Are there any means to avoid that with ScoreLoop? If the answer is positive then what are the supported languages? Is it possible to attach a picture to user record? On May 29, 11:28 am, Prenitha prenitha...@yahoo.co.in wrote: Hi Neil, We have posted the answer to your query as an FAQ on Scoreloop's support website. You can directly click the following link to get there. http://support.scoreloop.com/faqs/android-development/removing-search... If you have any additional queries, the fastest way to get a response will be to use our support website. Regards, Prenitha. On May 27, 12:18 am, Neilz neilhorn...@googlemail.com wrote: Great, thanks Junde. Can you tell me how I can filter this list, to only show the values I want? Like my example with the Jewels game, I really only want the first three items in the list, at most. Or is it just a simple code hack? On May 26, 6:29 pm, Junde (Scoreloop) jun...@gmail.com wrote: Hi Neil, I'm sure there should be some Scoreloop users here. There's actually guys from the Scoreloop team here too, I'm one of them :) These are basically some ISO jargon, that we are going to replace with friendlier words very soon. Basically, iso3166_1 refers to country codes, and iso3166_2 refers to country subdivision codes (regions/cities etc). So it's 2 additional ways of filtering scores. As for how iso3166_1 differs from your Country, I think your Country is based on the user's input on their player profile, while iso3166 is based on detection. I'll verify this for you. By the way, we've also got a nice support forum up athttp://support.Scoreloop.com if you're interested to learn more. Cheers, Junde On May 26, 9:42 pm, Neilz neilhorn...@googlemail.com wrote: I'm implementing ScoreLoop for my game. There is a standard selection widget for the leaderboard type, which lets you refine the scores. By default, I get: - Global Leaderboard - Your Country Leaderboard - 24h Leaderboard - search_list.nationality_iso3166_1 - search_list.nationality_iso3166_2 What on earth are the last two items? This list seems to come from ScoreLoop, rather than being anything configurable in the xml. I only want the first three in the list, is there anyway I can set this somewhere? I notice that other games that use ScoreLoop (like Jewels for example) only have the first three items also. Thanks. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Android graphical capabilities
For me, anything that shows how to do something different from the standard API demos would be great. Such as, when you start a new activity, changing the way it loads... rather than just sliding across the screen, it could spiral out from the center, or flip over from the right. That kind of thing. Also, how do you handle your splash screens? For example, in your tutorial app, it starts with a splash screen with some small animation on it - just as most high profile games do. What's the best way to handle that? Thanks again Anders. On Jun 4, 9:42 am, Ericson, Anders anders.eric...@sonyericsson.com wrote: Yeah, it's the dynamics that really give it a nice feel. And a touch-list without fling support is not useful at all... Though the third part of the tutorial is not quite ready yet. It will probably be posted in about a week on the blog. Untill then I suggest playing around with the graphics :) BTW, if you (or anyone else) have any ideas or requests for other tutorials, let me know! We are planning to continue with tutorials and it would be great if you had any input. No promises though :) /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf OfNeilz Sent: den 3 juni 2010 20:16 To: Android Developers Subject: [android-developers] Re: Android graphical capabilities Hi Anders. Do you have the code for part 3 available? The first two are great, but really it's not so great without the finishing touches from part 3! On Jun 3, 2:18 pm, Ericson, Anders anders.eric...@sonyericsson.com wrote: The reference app on market has minSdkVersion set to 4 (=1.6) and the main reason is to enable the support for different screen sizes (mdpi, ldpi, hdpi). The code itself has very little (if any) dependencies to 1.6 specific APIs. You can always download the code and just rename the directories for the drawables, that should be enough to get it to work on a 1.5 device. We'll look into supporting 1.5 for the reference app as well. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf OfNeilz Sent: den 3 juni 2010 14:21 To: Android Developers Subject: [android-developers] Re: Android graphical capabilities Hi Anders. Thanks for these, they look great, just the sort of thing I'm after. I notice that it isn't available for my older Hero with 1.5. Is this not compatible with 1.5? How would you resolve that if you wanted your app to reach all devices? On Jun 3, 11:37 am, Ericson, Anders anders.eric...@sonyericsson.com wrote: Hi, I recently wrote a tutorial on how to do a cool 3D list. You can find the latest part on: http://blogs.sonyericsson.com/developerworld/category/tutorials/ There you can also find a tutorial on how to do a cool zoom written by a colleague of mine. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf OfNeilz Sent: den 3 juni 2010 10:38 To: Android Developers Subject: [android-developers] Android graphical capabilities My apps are functionally good, and in my time learning android I have covered most features. But one thing my apps lack is graphical coolness... you know the type of thing the top branded apps have, and particularly those from the iPhone which are always very impressive. I want to improve my graphical skills for layouts, menus, galleries, interactive buttons - the kind of stuff that makes your apps look great, as well as performing well. What should I look at? Where should I start? Any links, tips, welcome! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://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 athttp://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 athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the
[android-developers] Debugging C++ code in Android
Hi all, I am able to debug only till framework level using eclipse. Can anyone let me know how to debug C++ or library code in android. Thanks in advance, POP -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Android Dev Phone with 2.x?
In this case there is no chance in our country as Vodafone (as Nexus One distributor in Europe) said that they will not sell this phone in Czech Republic. I wish there would be ADP 3 as I like to have phone officially rooted (because of unofficially rooted phones lose warranty here). Tom On 4 čvn, 08:29, Chi Kit Leung michaelchi...@gmail.com wrote: By the way, Google has shutdown their online phone shop ( as I remember). I don't think you can get Nexus One directly from Google anymore. 2010/6/3 Tomáš Hubálek tom.huba...@gmail.com I'm trying to put this question to the top again as I would like to know the answer from Google. For me as owner of ADP1 is starts more and more important as I don't believe in official Froyo port for ADP1. Thanks Tom On 21 kvě, 06:57, Tomáš Hubálek tom.huba...@gmail.com wrote: Nexus One is not (contrary to Dev phones) available in our country (Czech Republic, EU member!). And probably never will be... :-( Tom On May 21, 2010 12:58 AM, Eddie Ringle ed...@eringle.net wrote: I think the Nexus One counts as the current unofficial Android Developer Phone. (Unofficial in that it hasn't been given that title officially) On May 14, 9:36 am, Tomáš Hubálek tom.huba...@gmail.com wrote: Hello, I'm owner of ADP1 (1... -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 athttp:// 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 -- Regards, Michael Leunghttp://www.itblogs.infohttp://www.michaelleung.info -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Microphone input level
Hi, is there a way to change the mic audio input level? This is not about increasing it, as I can do this by applying a software gain. I need to reduce the level, to avoid clipping in loud sound conditions. -- Olivier -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] PopupWindow can't be dismissed when press back key
Hi, I've created a custom PopupWindow but when I press back button, the window doesn't dissapear. If somebody found a solution please response. Thanks, Ionel. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Android finishActivity()
hi Sean, this is what i have done. i Have 3 activities. Activity A, Activity B, and Activity C. Activity A is the starting Activity. according to a user action Activity A will navigate to Activity B like this. finish(); startActivityForResult(Activity B, 102); Activity A -- Activity B after 5 seconds Activity B will starts Activity C StartActivity(Activity C) and will not finish Activity B. on top of Activity B, Activity C will be run. this is Activity C onCreate method @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); Bundle b = getIntent().getExtras(); msg_id = b.getLong(ID); getWindow().setFlags(WindowManager.LayoutParams.FLAG_BLUR_BEHIND, WindowManager.LayoutParams.FLAG_BLUR_BEHIND); setContentView(R.layout.blur_blue); } this is manifest.xml activity android:name=.Activity C android:theme=@style/ Theme.Blue/ this is my theme.xml ?xml version=1.0 encoding=utf-8? resources drawable name=Blue#77ff/drawable drawable name=Green#7700ff00/drawable drawable name=Purple#70970468/drawable drawable name=Pink#70de6496/drawable drawable name=Red#7f00/drawable drawable name=Orange#70ff7e00/drawable drawable name=Yellow#70fff000/drawable /resources so Activity C will run on top of Activity B. so when i pressed back button from activity C application should redirects to Activity A. @Override public boolean onKeyDown(int keyCode, KeyEvent event) { // TODO Auto-generated method stub if (keyCode == KeyEvent.KEYCODE_BACK) { finish(); finishActivity(102); startActivity(new Intent(Acitivyt C, Activity A )); return true; } return false; } Application redirects to Activity A and when i pressed back from Activity A again it redirects to Activity B and will not close the application. this is what i'm doing in Activity A @Override public boolean onKeyDown(int keyCode, KeyEvent event) { // TODO Auto-generated method stub boolean b = false; if (keyCode == KeyEvent.KEYCODE_BACK) { // int x = android.os.Process.SIGNAL_QUIT; finish(); finishActivity(102); } return b; } so Sean what do you think?? what can be done. regards, Randika -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Open native Maps with directions??
Hi, I open my Native Google Maps like: Uri uri = Uri.parse(geo:0,0?q=Boston); Intent intent = new Intent(Intent.ACTION_VIEW, uri); startActivity(intent); That works fine! BUT... how to open it with a direction request like q=Boston+to:+Washington that works fine in google maps http://maps.google.com/?q=boston+to:+washington but doesnt do anything when I try to do the same with the native App on my Android Device!? thx chris -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Android finishActivity()
hi Sean, this is what i have done. i Have 3 activities. Activity A, Activity B, and Activity C. Activity A is the starting Activity. according to a user action Activity A will navigate to Activity B like this. finish(); startActivityForResult(Activity B, 102); Activity A -- Activity B after 5 seconds Activity B will starts Activity C StartActivity(Activity C) and will not finish Activity B. on top of Activity B, Activity C will be run. this is Activity C onCreate method @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); Bundle b = getIntent().getExtras(); msg_id = b.getLong(ID); getWindow().setFlags(WindowManager.LayoutParams.FLAG_BLUR_BEHIND, WindowManager.LayoutParams.FLAG_BLUR_BEHIND); setContentView(R.layout.blur_blue); } this is manifest.xml activity android:name=.Activity C android:theme=@style/ Theme.Blue/ this is my theme.xml ?xml version=1.0 encoding=utf-8? resources drawable name=Blue#77ff/drawable drawable name=Green#7700ff00/drawable drawable name=Purple#70970468/drawable drawable name=Pink#70de6496/drawable drawable name=Red#7f00/drawable drawable name=Orange#70ff7e00/drawable drawable name=Yellow#70fff000/drawable /resources so Activity C will run on top of Activity B. so when i pressed back button from activity C application should redirects to Activity A. @Override public boolean onKeyDown(int keyCode, KeyEvent event) { // TODO Auto-generated method stub if (keyCode == KeyEvent.KEYCODE_BACK) { finish(); finishActivity(102); startActivity(new Intent(Acitivyt C, Activity A )); return true; } return false; } Application redirects to Activity A and when i pressed back from Activity A again it redirects to Activity B and will not close the application. this is what i'm doing in Activity A @Override public boolean onKeyDown(int keyCode, KeyEvent event) { // TODO Auto-generated method stub boolean b = false; if (keyCode == KeyEvent.KEYCODE_BACK) { // int x = android.os.Process.SIGNAL_QUIT; finish(); finishActivity(102); } return b; } so Sean what do you think?? what can be done. regards, Mike -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Two articles on Android app development
Ivan wrote: The experience I shared there was practical - and there are times and requirements when you do need to start a service at the boot time, and it's really better to run it in a separate process. For example, any mail-like application would have such requirements. There is absolutely no reason why the activity for a mail client would need to run in a separate process from the service handling the mail protocol. By using android:process=:remote, you are going to force those to be in separate processes unnecessarily, consuming a lot of extra RAM along the way. With respect to having the service component of a mail application run forever, I would really recommend polling at least as a option for users who do not wish your service to attempt to run forever. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android App Developer Books: http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Creating a hidden partition
surendra wrote: hi, I am new to android platform. Please give me some pointers on how to make partitions invisible and provide access to few applications only on this invisible partition That is not possible, except maybe by developing your own firmware. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Consulting: http://commonsware.com/consulting -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: HeapWorker is wedged problem
hey guys, i do have exactly the same issue here it's about 11 seconds... but there - IS - a progess... i'm parsing an HTML page... it has to take that long... ;=) i'm extracting information... i can't do anything against it, any possibilities or ideas in eliminating this error? or some kind of workaround...? thanks! On 7 Apr., 08:40, fadden fad...@android.com wrote: On Apr 3, 2:52 am, Mr. Kakakuva Bird ashish531...@gmail.com wrote: I am using edtftpj-pro3.1 trial copy in my android app to make SFTP connection with the server. After few connections with the server with 5-6 file transfers, my app is crashing with following exception HeapWorker is wedged. I'm using Sqlite dbms. Is it causing the problem or what could be the problem?? The interesting part is: 04-03 15:06:35.663: ERROR/dalvikvm(12526): HeapWorker is wedged: 13056ms spent inside Lcom/enterprisedt/net/j2ssh/sftp/SftpFileOutputStream;.finalize()V It spent 13 seconds in a single finalizer function without making any progress. It appears to be waiting on some other thread: 04-03 15:06:36.122: INFO/dalvikvm(12526): HeapWorker daemon prio=5 tid=5 TIMED_WAIT 04-03 15:06:36.122: INFO/dalvikvm(12526): | group=system sCount=1 dsCount=0 s=Y obj=0x42e186d8 self=0x116928 04-03 15:06:36.122: INFO/dalvikvm(12526): | sysTid=12527 nice=0 sched=0/0 cgrp=default handle=1140944 04-03 15:06:36.122: INFO/dalvikvm(12526): at java.lang.Object.wait(Native Method) 04-03 15:06:36.122: INFO/dalvikvm(12526): at java.lang.Object.wait(Object.java:326) 04-03 15:06:36.122: INFO/dalvikvm(12526): at com.enterprisedt.net.j2ssh.sftp.B.A((null):-1) 04-03 15:06:36.122: INFO/dalvikvm(12526): at com.enterprisedt.net.j2ssh.sftp.SftpSubsystemClient.getOKRequestStatus((nul l):-1) 04-03 15:06:36.122: INFO/dalvikvm(12526): at com.enterprisedt.net.j2ssh.sftp.SftpFileOutputStream.A((null):-1) 04-03 15:06:36.122: INFO/dalvikvm(12526): at com.enterprisedt.net.j2ssh.sftp.SftpFileOutputStream.close((null):-1) 04-03 15:06:36.122: INFO/dalvikvm(12526): at com.enterprisedt.net.j2ssh.sftp.SftpFileOutputStream.finalize((null):-1) 04-03 15:06:36.122: INFO/dalvikvm(12526): at dalvik.system.NativeStart.run(Native Method) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Adding data in a tree to a ContentProvider
At the application level, my data is of the form * Event * Contact List * Contact * Name * Email * Contact * Name * Email The number of contacts is not predefined. Any thoughts on how to push this into a ContentProvider in one go? I basically dont want my application to worry about the hierarchy and bulk insert or something, I want to hand this responsibility over to the ContentProvider. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Adding data in a tree to a ContentProvider
Kind of like inserting into a View (at the database level below the ContentProvider, this is literally inserting into a View: Sqlite Views are read-only!) Vikram wrote: At the application level, my data is of the form * Event * Contact List * Contact * Name * Email * Contact * Name * Email The number of contacts is not predefined. Any thoughts on how to push this into a ContentProvider in one go? I basically dont want my application to worry about the hierarchy and bulk insert or something, I want to hand this responsibility over to the ContentProvider. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Map is not dispalying in the android emulator
The code that I gave doesn't contain anything, except creating an object of mapView with API key and displaying it. Nithin On Jun 4, 5:00 pm, aswini aswin...@gmail.com wrote: hi , thanks for your reply, i have tried the code which u have sent, still i didnt get the map, i have attached the logcat below. my android emulator run behind the proxy. i am working on latest andrid 2.2 version. how can i check my api key is correct or not? is there any way to find the api key which i have generated is valid? logcat: 06-04 16:58:22.538: INFO/DEBUG(30): debuggerd: May 12 2010 20:17:37 06-04 16:58:22.689: DEBUG/qemud(37): entering main loop 06-04 16:58:22.710: INFO/Netd(29): Netd 1.0 starting 06-04 16:58:22.730: INFO/Vold(28): Vold 2.1 (the revenge) firing up 06-04 16:58:22.759: DEBUG/Vold(28): Volume sdcard state changing -1 (Initializing) - 0 (No-Media) 06-04 16:58:23.249: WARN/Vold(28): No UMS switch available 06-04 16:58:23.599: DEBUG/qemud(37): fdhandler_accept_event: accepting on fd 10 06-04 16:58:23.599: DEBUG/qemud(37): created client 0xe078 listening on fd 8 06-04 16:58:23.619: DEBUG/qemud(37): client_fd_receive: attempting registration for service 'boot-properties' 06-04 16:58:23.619: DEBUG/qemud(37): client_fd_receive: - received channel id 1 06-04 16:58:23.630: DEBUG/qemud(37): client_registration: registration succeeded for client 1 06-04 16:58:23.630: INFO/qemu-props(52): connected to 'boot- properties' qemud service. 06-04 16:58:23.640: INFO/qemu-props(52): received: qemu.sf.lcd_density=160 06-04 16:58:23.640: INFO/qemu-props(52): received: dalvik.vm.heapsize=16m 06-04 16:58:23.900: DEBUG/qemud(37): fdhandler_accept_event: accepting on fd 10 06-04 16:58:23.900: DEBUG/qemud(37): created client 0xe078 listening on fd 11 06-04 16:58:23.900: DEBUG/qemud(37): fdhandler_event: disconnect on fd 11 06-04 16:58:23.929: DEBUG/qemud(37): fdhandler_accept_event: accepting on fd 10 06-04 16:58:23.929: DEBUG/qemud(37): created client 0xe078 listening on fd 11 06-04 16:58:23.929: DEBUG/qemud(37): client_fd_receive: attempting registration for service 'gsm' 06-04 16:58:23.929: DEBUG/qemud(37): client_fd_receive: - received channel id 2 06-04 16:58:23.939: DEBUG/qemud(37): client_registration: registration succeeded for client 2 06-04 16:58:24.369: DEBUG/AndroidRuntime(32): AndroidRuntime START 06-04 16:58:24.369: DEBUG/AndroidRuntime(32): CheckJNI is ON 06-04 16:58:25.070: INFO/(33): ServiceManager: 0xacd0 06-04 16:58:25.089: DEBUG/AudioHardwareInterface(33): setMode(NORMAL) 06-04 16:58:25.099: INFO/CameraService(33): CameraService started: pid=33 06-04 16:58:25.119: INFO/AudioFlinger(33): AudioFlinger's thread 0xb3d0 ready to run 06-04 16:58:25.240: DEBUG/AndroidRuntime(32): --- registering native functions --- 06-04 16:58:25.880: INFO/SamplingProfilerIntegration(32): Profiler is disabled. 06-04 16:58:25.980: INFO/Zygote(32): Preloading classes... 06-04 16:58:25.980: ERROR/Zygote(32): setreuid() failed. errno: 2 06-04 16:58:25.999: DEBUG/dalvikvm(32): GC_EXPLICIT freed 819 objects / 47368 bytes in 16ms 06-04 16:58:26.449: DEBUG/dalvikvm(32): GC_EXPLICIT freed 219 objects / 13576 bytes in 8ms 06-04 16:58:26.580: DEBUG/dalvikvm(32): GC_EXPLICIT freed 253 objects / 14352 bytes in 12ms 06-04 16:58:26.699: DEBUG/dalvikvm(32): GC_EXPLICIT freed 466 objects / 28912 bytes in 9ms 06-04 16:58:27.240: DEBUG/dalvikvm(32): GC_EXPLICIT freed 2090 objects / 108368 bytes in 14ms 06-04 16:58:27.589: WARN/MediaProfiles(32): could not find media config xml file 06-04 16:58:27.630: DEBUG/dalvikvm(32): GC_EXPLICIT freed 279 objects / 15984 bytes in 12ms 06-04 16:58:28.230: DEBUG/dalvikvm(32): GC_FOR_MALLOC freed 4964 objects / 221896 bytes in 26ms 06-04 16:58:28.320: DEBUG/dalvikvm(32): GC_EXPLICIT freed 924 objects / 36592 bytes in 20ms 06-04 16:58:28.490: DEBUG/dalvikvm(32): GC_EXPLICIT freed 544 objects / 27176 bytes in 21ms 06-04 16:58:28.570: DEBUG/dalvikvm(32): GC_EXPLICIT freed 402 objects / 22096 bytes in 22ms 06-04 16:58:28.910: DEBUG/dalvikvm(32): GC_EXPLICIT freed 286 objects / 34176 bytes in 36ms 06-04 16:58:29.089: DEBUG/dalvikvm(32): GC_EXPLICIT freed 277 objects / 18872 bytes in 33ms 06-04 16:58:29.519: DEBUG/dalvikvm(32): GC_EXPLICIT freed 319 objects / 17808 bytes in 34ms 06-04 16:58:29.788: DEBUG/dalvikvm(32): GC_EXPLICIT freed 452 objects / 27648 bytes in 36ms 06-04 16:58:29.960: DEBUG/dalvikvm(32): GC_EXPLICIT freed 265 objects / 21832 bytes in 39ms 06-04 16:58:32.309: DEBUG/dalvikvm(32): GC_EXPLICIT freed 508 objects / 59600 bytes in 42ms 06-04 16:58:32.440: DEBUG/dalvikvm(32): GC_EXPLICIT freed 639 objects / 34760 bytes in 41ms 06-04 16:58:32.600: DEBUG/dalvikvm(32): GC_EXPLICIT freed 842 objects / 45968 bytes in 47ms 06-04 16:58:34.129: DEBUG/dalvikvm(32): GC_FOR_MALLOC freed 12448 objects / 449808 bytes in 56ms 06-04 16:58:34.669: DEBUG/dalvikvm(32): GC_FOR_MALLOC freed 10024 objects / 464616
[android-developers] Run in emulator
hi I developed a softphone which is running on device but not in emulator how to change wifi setting . plz tell me thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: GPS/LocationManager does not give a fix in my app
On Fri, Jun 4, 2010 at 4:35 AM, Charly carlos.per...@gmail.com wrote: Any other suggestions are more than welcome. I'll ask for third time, then I'm giving up on you. Does your location listener never get called or does it get called with bad / inaccurate values? - TreKing - Chicago transit tracking app for Android-powered devices http://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Regarding enter key on virtual keyboard
Hi Rajiv, Thanks for the reply..but in my app i want to trap the virtual keyboard keycodes , VK_RETURN etc, which i referred from this link *http://www.codeweblog.com/virtual-keyboard-key-code-table/* which are not getting captured by onKeyDown method. How can i do that ? Thanks in advance, Ameya On Fri, Jun 4, 2010 at 10:04 AM, Rajiv rajiv...@gmail.com wrote: Hi ameya, I think u may have did little bit mistake in your application, if you will implement these things in the following way, offcource you will got the solution. Suppose you are using Layout as *account* and Activity as *AccountActivity *, you need to do the following modification in there account.xml ?xml version=1.0 encoding=UTF-8? LinearLayout xmlns:android=http://schemas.android.com/apk/res/android; android:orientation=vertical android:layout_width=fill_parent android:layout_height=fill_parent ScrollView android:layout_width=fill_parent android:layout_height=wrap_content RelativeLayout android:orientation=vertical android:layout_width=fill_parent android:layout_height=wrap_content android:gravity=left TextView android:layout_width=fill_parent android:layout_height=wrap_content android:paddingTop=4dip android:paddingLeft=4dip android:text=Email address: android:id=@+id/emailtext/ EditText android:id=@+id/email android:layout_width=fill_parent android:layout_height=wrap_content android:layout_marginLeft=8dip android:layout_marginRight=8dip android:hint=Your email address android:inputType=textEmailAddress android:layout_below = @id/emailtext/ TextView android:layout_width=fill_parent android:layout_height=wrap_content android:paddingTop=4dip android:paddingLeft=4dip android:text=Password: android:id=@+id/passwdtext android:layout_below = @id/email / EditText android:id=@+id/password android:layout_width=fill_parent android:layout_height=wrap_content android:layout_marginLeft=8dip android:layout_marginRight=8dip android:hint=Your password android:inputType=textPassword android:layout_below = @id/passwdtext/ TextView android:layout_width=fill_parent android:layout_height=wrap_content android:paddingTop=2dip android:id=@+id/space1 android:layout_below = @id/password / Button android:id=@+id/validate android:layout_width=wrap_content android:layout_height=wrap_content android:text=continue android:layout_below = @id/space1 android:layout_centerInParent = true/ /RelativeLayout /ScrollView /LinearLayout AccountActivity //package //import public class AccountActivity extends Activity implements OnClickListener, AlertDialog.OnClickListener { private EditText userNameEditText; private EditText passwordEditText; private Button validateAccountButton; protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.account); userNameEditText = (EditText) findViewById(R.id.email); passwordEditText = (EditText) findViewById(R.id.password); validateAccountButton = (Button) findViewById(com.skyscape.packageajccsevenektwondata.android.voucher.ui.R.id.validate); validateAccountButton.setOnClickListener(this); } public void onClick(View view) { if (view == validateAccountButton) { validate(); } } protected void validate() { //Validate your Account } public boolean onKeyDown(int keyCode, KeyEvent event) { return super.onKeyDown(keyCode, event); } } If you implement in this way, i think you will got your desired result. Let me know if you still have doubt. Regards, Rajiv On Thu, Jun 3, 2010 at 7:17 PM, ameya dandekar ameya...@gmail.com wrote: Hi, I am currently working on sdk 1.5, in which i want capture the Click event of Enter key on Virtual Keypad. My requirement is, for my Username/Password Login screen. Click on Username field. Cursor is displayed in Text entry box. Click on Enter key on Virtual Keypad. Cursor should be displayed in Password field. Take the cursor in Password field. Click on Enter key on Virtual Keypad. Virtual Keypad should be closed. I am testing the app on HTC Magic. Regards, Ameya. -- You received this message because you are subscribed to the Google Groups Android Developers group. 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
Re: [android-developers] Regarding enter key on virtual keyboard
ameya dandekar wrote: Hi Rajiv, Thanks for the reply..but in my app i want to trap the virtual keyboard keycodes , VK_RETURN etc, which i referred from this link *http://www.codeweblog.com/virtual-keyboard-key-code-table/* which are not getting captured by onKeyDown method. How can i do that ? The table at that URL has nothing at all to do with Android. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Training...At Your Office: http://commonsware.com/training -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 finishActivity()
OK Mike, so reading carefully through your explanation, it looks to me that the process you want is this: A - B - C - A - (app close) Whilst what you are actually getting, with your current code, is this: A - B - C - A - A - B - (unknown) The complex nature of your activity jumping suggests that the code is simply too complex. I suggest you replace all the onKeyDown() and startActivityForResult() handling for something like this: Activity A // This code goes in the correct method of Activity A to start Activity B startActivity(new Intent(ActivityA, ActivityB)); Activity B // This code goes in the correct method of Activity B to start Activity C startActivity(new Intent(ActivityB, ActivityC)); // Set the noHistory attribute for Activity B in your AndroidManifest.xml activity android:name=ActivityB android:noHistory=true.../activity Activity C // This code goes in the correct method of Activity C to jump back to Activity A finish(); The outcome should be the navigation you are looking for. Activity B is skipped when you press the back button from Activity C. Pressing the back button again will close the application. Cheers, Sean On Fri, Jun 4, 2010 at 1:03 PM, mike hasitharand...@gmail.com wrote: hi Sean, this is what i have done. i Have 3 activities. Activity A, Activity B, and Activity C. Activity A is the starting Activity. according to a user action Activity A will navigate to Activity B like this. finish(); startActivityForResult(Activity B, 102); Activity A -- Activity B after 5 seconds Activity B will starts Activity C StartActivity(Activity C) and will not finish Activity B. on top of Activity B, Activity C will be run. this is Activity C onCreate method �...@override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); Bundle b = getIntent().getExtras(); msg_id = b.getLong(ID); getWindow().setFlags(WindowManager.LayoutParams.FLAG_BLUR_BEHIND, WindowManager.LayoutParams.FLAG_BLUR_BEHIND); setContentView(R.layout.blur_blue); } this is manifest.xml activity android:name=.Activity C android:theme=@style/ Theme.Blue/ this is my theme.xml ?xml version=1.0 encoding=utf-8? resources drawable name=Blue#77ff/drawable drawable name=Green#7700ff00/drawable drawable name=Purple#70970468/drawable drawable name=Pink#70de6496/drawable drawable name=Red#7f00/drawable drawable name=Orange#70ff7e00/drawable drawable name=Yellow#70fff000/drawable /resources so Activity C will run on top of Activity B. so when i pressed back button from activity C application should redirects to Activity A. �...@override public boolean onKeyDown(int keyCode, KeyEvent event) { // TODO Auto-generated method stub if (keyCode == KeyEvent.KEYCODE_BACK) { finish(); finishActivity(102); startActivity(new Intent(Acitivyt C, Activity A )); return true; } return false; } Application redirects to Activity A and when i pressed back from Activity A again it redirects to Activity B and will not close the application. this is what i'm doing in Activity A �...@override public boolean onKeyDown(int keyCode, KeyEvent event) { // TODO Auto-generated method stub boolean b = false; if (keyCode == KeyEvent.KEYCODE_BACK) { // int x = android.os.Process.SIGNAL_QUIT; finish(); finishActivity(102); } return b; } so Sean what do you think?? what can be done. regards, Mike -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] How to get the screen lock status
Hi All, I am looking for a method to get the current screen lock status. I would like to know if it is locked or not. I have a live wall paper that only need to work if the screen is unlock (i.e. full display is on), otherwise, it should be just blank. Thanks, Sorry if this is a newbie question. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] How to get the screen lock status
ubuntu_user wrote: Hi All, I am looking for a method to get the current screen lock status. I would like to know if it is locked or not. I have a live wall paper that only need to work if the screen is unlock (i.e. full display is on), otherwise, it should be just blank. Watch for ACTION_SCREEN_ON and ACTION_SCREEN_OFF broadcast Intents. Or, for Android 2.1 devices and newer, use isScreenOn() in PowerManager. I realize that this is not necessarily identical to the screen lock status, but it is as close as you are going to get, AFAICT. -- 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 *Advanced* Android Development_ Version 1.5 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
Re: [android-developers] How to show a dialog even if the Activity is in background
On Fri, Jun 4, 2010 at 3:09 AM, Jiang webs...@yahoo.cn wrote: In other word, no matter what application is running on foreground, use can watch the dialog. Let me get this straight - you want to force a popup dialog in front of the user's current activity after they've made the deliberate decision to navigate away from your app? Why, exactly, would you want to do this? - TreKing - Chicago transit tracking app for Android-powered devices http://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] How to get the screen lock status
On Friday 04 June 2010 17:44:19 ubuntu_user wrote: I am looking for a method to get the current screen lock status. I would like to know if it is locked or not. I have a live wall paper that only need to work if the screen is unlock (i.e. full display is on), otherwise, it should be just blank. You should just reimplement WallpaperService::Engine::onVisibilityChanged(bool) inside your live wallpaper's engine - this will tell you when wallpaper gets shown/hidden. It's better to use this method, because you don't need to do anything not only if screen is locked, but e.g. when some other app starts and wallpaper isn't visible. onVisibilityChanged is exactly what you need in this case :) See http://developer.android.com/reference/android/service/wallpaper/WallpaperService.Engine.html#onVisibilityChanged(boolean) Cheers, Dmitry. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: PopupWindow can't be dismissed when press back key
- Use a Dialog component or - Catch the event on back button to finish your PopupWindow. Best On Jun 4, 1:42 pm, ionel ionelt2...@gmail.com wrote: Hi, I've created a custom PopupWindow but when I press back button, the window doesn't dissapear. If somebody found a solution please response. Thanks, Ionel. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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 does a held wakelock impact if the service dies with out releasing it?
Scenario: 1. Broadcast Receiver holds a static wake lock hoping the service it started, when it finishes will release the lock 2. Howvever Service dies with out releasing the wake lock? What is likely to happen? I am assuming the process will be stopped after calling the onDestory() of the service, and I am hoping the device will go to sleep ignoring the held wake lock. Or does the call to onDestroy() delayed because of the wakelock although the service called stopSelf() Thanks Satya -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] findViewbyId returns null --- called in a custom CursorAdapter -- bindView() method. Codes in body.
package edu.ohio.android.bmm.activity; import android.content.Context; import android.database.Cursor; import android.graphics.Bitmap; import android.graphics.BitmapFactory; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.CursorAdapter; import android.widget.ImageView; import android.widget.ListView; import android.widget.TextView; import edu.ohio.android.bmm.R; import edu.ohio.android.bmm.db.BMMDBOpenHelper.Diary; public class DiaryList extends BMMActivity { // Cursor for sqlite database private Cursor cursor; private LayoutInflater mInflater; // Icons bound to rows private Bitmap mild; private Bitmap moderate; private Bitmap severe; /*** * */ @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); cursor = fetchAllDiary(); this.setListAdapter(new DiaryListAdapter(this, cursor, true)); } /** * * @author vycon * */ public class DiaryListAdapter extends CursorAdapter { /** * * @param context * @param cursor * @param autoRequery */ public DiaryListAdapter(Context context, Cursor cursor, boolean autoRequery) { super(context, cursor, autoRequery); mInflater = LayoutInflater.from(context); // icons bound to the rows mild = BitmapFactory.decodeResource(context.getResources(), R.drawable.mild); moderate = BitmapFactory.decodeResource(context.getResources(), R.drawable.moderate); severe = BitmapFactory.decodeResource(context.getResources(), R.drawable.severe); } /** * */ @Override public void bindView(View view, Context context, Cursor cursor) { TextView tvStartTime = (TextView) view.findViewById(R.id.diary_list_row_dateAndTime); TextView tvDuration = (TextView) view.findViewById(R.id.diary_list_row_duration); TextView tvSymptom = (TextView) view.findViewById(R.id.diary_list_row_symptom); TextView tvMedication = (TextView) view.findViewById(R.id.diary_list_row_medication); ImageView ivMaxSeverity = (ImageView) view.findViewById(R.id.diary_list_row_maxSeverity); ImageView ivInitSeverity = (ImageView) view.findViewById(R.id.diary_list_row_initSeverity); String maxSeverity = cursor.getString(cursor.getColumnIndex(Diary.MAX_SEVERITY)); String initSeverity = cursor.getString(cursor.getColumnIndex(Diary.INIT_SEVERITY)); tvStartTime.setText(cursor.getString(cursor.getColumnIndex(Diary.START_TIME))); tvDuration.setText(cursor.getString(cursor.getColumnIndex(Diary.DURATION))); tvSymptom.setText(cursor.getString(cursor.getColumnIndex(Diary.SYMPTOM))); tvMedication.setText(cursor.getInt(cursor.getColumnIndex(Diary.MEDICATION_ID))); if (maxSeverity.equalsIgnoreCase(mild)) { ivMaxSeverity.setImageBitmap(mild); } if (maxSeverity.equalsIgnoreCase(moderate)) { ivMaxSeverity.setImageBitmap(moderate); } if (maxSeverity.equalsIgnoreCase(severe)) { ivMaxSeverity.setImageBitmap(severe); } if (initSeverity.equalsIgnoreCase(mild)) { ivInitSeverity.setImageBitmap(mild); } if (initSeverity.equalsIgnoreCase(moderate)) { ivInitSeverity.setImageBitmap(moderate); } if (initSeverity.equalsIgnoreCase(severe)) { ivInitSeverity.setImageBitmap(severe); } } /** * */ @Override public View newView(Context context, Cursor cursor, ViewGroup parent) { final View view = mInflater.inflate(R.layout.diary_list_view, parent, false); //bindView(view, context, cursor); return view; } } /** * */ @Override protected void onListItemClick(ListView l, View v, int position,
Re: [android-developers] How does a held wakelock impact if the service dies with out releasing it?
Wake locks should be released when the object is garbage collected. See the finalize() method in the WakeLock subclass here: http://android.git.kernel.org/?p=platform/frameworks/base.git;a=blob;f=core/java/android/os/PowerManager.java You will get a thrown exception in your logs if this occurs. So, as long as your Service is no longer referenced in memory (e.g. it has been destroyed), the wakelock should be released. Obviously this should not be the behaviour by design :) On Fri, Jun 4, 2010 at 3:36 PM, Satya Komatineni satya.komatin...@gmail.com wrote: Scenario: 1. Broadcast Receiver holds a static wake lock hoping the service it started, when it finishes will release the lock 2. Howvever Service dies with out releasing the wake lock? What is likely to happen? I am assuming the process will be stopped after calling the onDestory() of the service, and I am hoping the device will go to sleep ignoring the held wake lock. Or does the call to onDestroy() delayed because of the wakelock although the service called stopSelf() Thanks Satya -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: HTC Incredible suffering a reset while service running.
I haven't even used a wakelock yet, so I don't think a wakelock is the problem. I've thought of using a brief wakelock around a single file download. But I also think that users can leave the phone plugged in if they want the download to complete soon. Nathan On Jun 3, 9:15 pm, nikhil nik...@gmail.com wrote: I am not sure about the exact reason but I feel it was because of mishandling of partial wakelock. Like your app, I had a service which remained active all time and for that I had to hold on to the wakelock. The phone did not restart if I commented out my wakelock code. Interesting thing is it never restarted untill I tried to change call forward setting or use car navigator app (thankfully, this was observed when we tested the app for any kind of conflicts) .Then I realised that I should not hold on to the wakelock for long, to avoid conflicts. When I went the AlarmManager way all conflicts vanished. Are you holding on to wakelock? If you are, you may try commenting out that part and keep your app active until download is complete so that you don't loose network connection. Just perform few tests with the wakelock thing hopefully you should get the answer. You may have to split your file download into batches so that you can release the wakelock. On Jun 3, 3:28 pm, Nathan critter...@crittermap.com wrote: On Jun 3, 12:47 pm, nikhil nik...@gmail.com wrote: Nathan, I had similar issue long time back when I had implemented the service architecture. I had observed few things: 1. My phone (Nexus One) used to restart (with my service running in background) when I tried to change the call forward setting or I tried to use the google car navigator app. 2. The phone did not restart if it was plugged into a computer. (May be related to network connectivity.) I tried all kind of stuff the only way I was able to get my app working was by referring to Mark Murphy's wakefulintentservice structure which uses the alarm manager. Thanks. Did you find out why the restart was triggered? Or did you simply managed to avoid it? Was it because of many notifications, or just the fact that it was running for long time, or that Android tried to kill it? The alarm manager isn't appropriate for this task, at least I don't think so, because it is not a service that wakes up periodically and does some work. It has a defined list of files to download and then finishes, but it is actively working all that time. Nathan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Touch events
Hi i was able to see that the events goes in the WindowManagerService.java, Can you please let me know where exactly (which method is used to cancel the events) it is done. Thanks and Regards, Rahul On May 26, 9:55 pm, john wang altavista.w...@gmail.com wrote: in WindowManagerService.java 2010/5/26 rahul rahulii...@gmail.com Hi All, I have a query related to the touch events. When the user opens the landscape orientation on-screen qwerty keyboard and presses their thumb onto the space bar but over half of their thumb's touch area is outside of the screen area. Therefore the touch is reported with a coordinate outside of the display range and is discarded. I could see the raw events coming till InputDevice.java (generateAbsMotion method) but they are not sent to apps. Can someone please let me know where exactly these events are discarded. Whether in KeyInputQueue or WindowManagerService.java? Thanks in advance. Regards, Rahul -- You received this message because you are subscribed to the Google Groups Android Developers group. 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.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: glGenTextures going crazy on actual device
Try and generate only one texture id at a time and see what happens. You never know. From what I am getting, it seems like the texture you're uploading isn't valid for the context somehow. Unfortunately OpenGL error checking can be hard since it was meant to be really light weight. It could be that a previous state has caused a problem that only shows up when a texture is actually being used. So far my experience with OpenGL on Android is that the context choosing is really bad. I would have something that dumps out all the config attributes for the context that you create and see if something is fishy. Be 100% sure that your gl and egl calls have all passed. It sounds like you're using GLSurfaceView and IMHO I wouldn't. I wrote my own support so that I could have full control and didn't have to rely on things being bug free. It's also not very portable. On 6/4/2010 3:35 AM, Samsyn wrote: and yes, if I regress to api 3, the problem goes away, but apis 4 and 5 both have the problem. -- Leigh McRae www.lonedwarfgames.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] Camera Portrait
Hi all I am opening camera from my application...and the orientation of camera is Landscape... but i actually want it to be portrait ... im using code from here: http://snippets.dzone.com/user/Jbeer any kind of help will do... Thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] how to listen for system wide key presses
Hello, I am trying to add a listener to my service that listens for volume key presses. I would like to act on presses even if my service is not in focus. Any idea how to do this? I have looked over the API, as well as performed google searches. 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: glGenTextures going crazy on actual device
If I take a default API level 3 app, load the icon using BitmapFactory.decodeResource, and check Bitmap#getWidth and Bitmap#getHeight, then I get the values of 48 on the Droid. Now if I set android:minSdkVersion to 4 or higher in the manifest, then I get the values of 72. This is because changing the API level changes the default values for the screens supported: http://developer.android.com/guide/topics/manifest/supports-screens-element.html It takes the app out of compatibility mode, where Android reports a smaller screen resolution than actually exists, and it starts scaling up resources from directories like the drawable directory, which is considered medium density when there is no density specifier, not high density. So anyway, depending on how you are storing and loading the images you are using for your textures, changing the API level may be causing Android to resize them. Textures have to have power of 2 size dimensions, so this resize can make an image that can be used as a texture into an image that can't be used. It's pretty easy to prevent the resizing, there are previous threads on that. On Jun 4, 3:35 am, Samsyn d...@synthetic-reality.com wrote: and yes, if I regress to api 3, the problem goes away, but apis 4 and 5 both have the problem. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: glGenTextures going crazy on actual device
Good call. That is most likely the issue. I myself use the drawable-nodpi and set the screen selection to disable this feature. Leigh On 6/4/2010 11:27 AM, Lance Nanek wrote: If I take a default API level 3 app, load the icon using BitmapFactory.decodeResource, and check Bitmap#getWidth and Bitmap#getHeight, then I get the values of 48 on the Droid. Now if I set android:minSdkVersion to 4 or higher in the manifest, then I get the values of 72. This is because changing the API level changes the default values for the screens supported: http://developer.android.com/guide/topics/manifest/supports-screens-element.html It takes the app out of compatibility mode, where Android reports a smaller screen resolution than actually exists, and it starts scaling up resources from directories like the drawable directory, which is considered medium density when there is no density specifier, not high density. So anyway, depending on how you are storing and loading the images you are using for your textures, changing the API level may be causing Android to resize them. Textures have to have power of 2 size dimensions, so this resize can make an image that can be used as a texture into an image that can't be used. It's pretty easy to prevent the resizing, there are previous threads on that. On Jun 4, 3:35 am, Samsynd...@synthetic-reality.com wrote: and yes, if I regress to api 3, the problem goes away, but apis 4 and 5 both have the problem. -- Leigh McRae www.lonedwarfgames.com -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] how to listen for system wide key presses
I'm not aware of a system-wide key press listener, but check out the org.openintents.audio.action_volume_update bradcast intent: http://www.openintents.org/en/node/380 That should allow you to detect changes in the volume setting (including the button presses). On Fri, Jun 4, 2010 at 4:24 PM, EdKawas ed.ka...@gmail.com wrote: Hello, I am trying to add a listener to my service that listens for volume key presses. I would like to act on presses even if my service is not in focus. Any idea how to do this? I have looked over the API, as well as performed google searches. 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
[android-developers] Re: Creating an Android VN
Overlapping things in Android is pretty trivial. For example, when you put multiple children in a FrameLayout, they are all shown on top of each other as per the documentation: http://developer.android.com/reference/android/widget/FrameLayout.html Another method is the Toast utility for showing text messages on top of everything else: http://developer.android.com/reference/android/widget/Toast.html And of course dialogs are another way to show a window of content on top of another screen: http://developer.android.com/guide/topics/ui/dialogs.html It isn't far enough along that I've put any effort into cleaning up the code/XML, but you can see the FrameLayout method being used to compose layers of a character and controls here: http://code.google.com/p/growing-phone-pet/source/browse/trunk/res/layout/show_pet.xml There's a FrameLayout there explicitly, but the PetView that is composing the different images that make up the scenery and character is also a subclass of FrameLayout. On Jun 4, 12:10 am, EwanG ewan.grant...@gmail.com wrote: OK, so... question was too broad? No such examples exist? No one here who would be interested in such a thing if it were written? :-) On May 30, 10:04 pm, EwanG ewan.grant...@gmail.com wrote: I am looking for an example of how to setup a screen with a background, an overlay image (my character), and over that a frame that sometimes has text, and sometimes has menu options. To make myself clearer, as I suggest in the title I'm trying to create aVisualNovelfor Android. Something like I've done in Flash and using RenPy, but with mobile sensibilities (make the buttons more touch friendly, use the accelerator for certain inputs, etc). Any good, publicly available source code I should check out? I have written one previous Android Program (Mars Lander which I gather is still floating about), but this is different enough I think I need a bit of help. Thanks in advance! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] how to listen for system wide key presses
There was a thread last year on the topic of being able to intercept or respond to key strokes when the activity is not in focus. I believe the general consensus was that there is no such facility and that it is a good thing for privacy reasons as well. On Fri, Jun 4, 2010 at 11:42 AM, Sean Hodges seanhodge...@googlemail.com wrote: I'm not aware of a system-wide key press listener, but check out the org.openintents.audio.action_volume_update bradcast intent: http://www.openintents.org/en/node/380 That should allow you to detect changes in the volume setting (including the button presses). On Fri, Jun 4, 2010 at 4:24 PM, EdKawas ed.ka...@gmail.com wrote: Hello, I am trying to add a listener to my service that listens for volume key presses. I would like to act on presses even if my service is not in focus. Any idea how to do this? I have looked over the API, as well as performed google searches. 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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 listen for system wide key presses
Thanks for the quick reply. How does one use the intents from openintents.org? I took a look at their faq and didnt see anything. These intents cannot already be bundled with android, can they? Thanks. On Jun 4, 8:42 am, Sean Hodges seanhodge...@googlemail.com wrote: I'm not aware of a system-wide key press listener, but check out the org.openintents.audio.action_volume_update bradcast intent: http://www.openintents.org/en/node/380 That should allow you to detect changes in the volume setting (including the button presses). -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] determining if phone is rooted
I have an Android game where location is very important to the rules. There have been a bunch of cheaters and I have spent a long time closing off the ways that they exploit the system to cheat. One way they have been cheating is using a location spoofing app. I tried shutting that off by seeing if Allow mock locations is set to true and if it is I won't let the game run. After some research I see that rooted phones can run the location spoofing app without having to set allow mock locations. I want to be able to determine if the phone is rooted so I can add extra checks to make sure that they are not spoofing their location. The only suggestion I have seen to do this is to check to see if /system/bin/su exists. I don't think this is a reliable way to do this but it is all I have so far. Can anyone suggest any other ways to determine if the phone is a rooted phone? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: glGenTextures going crazy on actual device
Lance, That sounds pretty plausible. I did notice that api4 suddently started showing the true screen dimensions of my Droid (and unfortunately that also lowered my frame rate as there are more pixels to fill now :-) On Jun 4, 8:27 am, Lance Nanek lna...@gmail.com wrote: If I take a default API level 3 app, load the icon using BitmapFactory.decodeResource, and check Bitmap#getWidth and Bitmap#getHeight, then I get the values of 48 on the Droid. Now if I set android:minSdkVersion to 4 or higher in the manifest, then I get the values of 72. This is because changing the API level changes the default values for the screens supported:http://developer.android.com/guide/topics/manifest/supports-screens-e... It takes the app out of compatibility mode, where Android reports a smaller screen resolution than actually exists, and it starts scaling up resources from directories like the drawable directory, which is considered medium density when there is no density specifier, not high density. So anyway, depending on how you are storing and loading the images you are using for your textures, changing the API level may be causing Android to resize them. Textures have to have power of 2 size dimensions, so this resize can make an image that can be used as a texture into an image that can't be used. It's pretty easy to prevent the resizing, there are previous threads on that. On Jun 4, 3:35 am, Samsyn d...@synthetic-reality.com wrote: and yes, if I regress to api 3, the problem goes away, but apis 4 and 5 both have the problem.- Hide quoted text - - Show quoted text - -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: How to get the screen lock status
Thanks for your response. However, as you can see the moment the user wake up the screen but before the user slide the lock key, I would like to know if the phone is in this state or not. As far as I can tell, the onVisibilityChanged will send me a true status as soon as the user wake up the screen. I would like to be notified or a query API that I can tell if the phone has been unlocked (after user slide the lock button over). On Jun 4, 7:17 am, Dmitry Suzdalev dim...@gmail.com wrote: On Friday 04 June 2010 17:44:19 ubuntu_user wrote: I am looking for a method to get the current screen lock status. I would like to know if it is locked or not. I have a live wall paper that only need to work if the screen is unlock (i.e. full display is on), otherwise, it should be just blank. You should just reimplement WallpaperService::Engine::onVisibilityChanged(bool) inside your live wallpaper's engine - this will tell you when wallpaper gets shown/hidden. It's better to use this method, because you don't need to do anything not only if screen is locked, but e.g. when some other app starts and wallpaper isn't visible. onVisibilityChanged is exactly what you need in this case :) Seehttp://developer.android.com/reference/android/service/wallpaper/Wall...) Cheers, Dmitry. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: glGenTextures going crazy on actual device
Lance, (and everyone) Thank you so much! That was exactly it. All I had to do was rename my drawables folder to drawables-nodpi (and I did a full rebuild just to be nice) and now everything is back to normal, with api 4 in place. Of course, now I have to decide if I want to support higher rez screens at the expense of frame rate or not. It's so PRETTY, but it's at least 50% slower. :) Again, I was really pulling my hair out on this. Of course it might have been NICE if the GL Error Check actually mentioned it didn't feel the texture was a power of two. I, of course, just knew that it was, so I never logged a getWidth() on it. It's still a little odd that some textures were happier than others, but I imagine that is something to do with which wrong-sized-texture stepped on the memory of which other. :-) Once again, thank you! - Dan On Jun 4, 8:27 am, Lance Nanek lna...@gmail.com wrote: If I take a default API level 3 app, load the icon using BitmapFactory.decodeResource, and check Bitmap#getWidth and Bitmap#getHeight, then I get the values of 48 on the Droid. Now if I set android:minSdkVersion to 4 or higher in the manifest, then I get the values of 72. This is because changing the API level changes the default values for the screens supported:http://developer.android.com/guide/topics/manifest/supports-screens-e... It takes the app out of compatibility mode, where Android reports a smaller screen resolution than actually exists, and it starts scaling up resources from directories like the drawable directory, which is considered medium density when there is no density specifier, not high density. So anyway, depending on how you are storing and loading the images you are using for your textures, changing the API level may be causing Android to resize them. Textures have to have power of 2 size dimensions, so this resize can make an image that can be used as a texture into an image that can't be used. It's pretty easy to prevent the resizing, there are previous threads on that. On Jun 4, 3:35 am, Samsyn d...@synthetic-reality.com wrote: and yes, if I regress to api 3, the problem goes away, but apis 4 and 5 both have the problem.- Hide quoted text - - Show quoted text - -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] MediaController in MediaPlayer
Hello, I am using MediaPlayer to build a Video player for playing local video files. However, I don't know how to enable MediaController for my player. I want the media control buttons that pop up when you touch the video surface. Can anyone help me out please? Thanks, Abhi -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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 show a dialog even if the Activity is in background
Use a Notification that shows on the notifcation bar instead, showing the text that you want to convey to the use. This will be unobtrusive and still effective. On Jun 4, 4:09 am, Jiang webs...@yahoo.cn wrote: If my Activity is switched to background, when something takes place, I want to show a dialog without switching the Activity to foreground. In other word, no matter what application is running on foreground, use can watch the dialog. Thanks. -Jiang. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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/LocationManager does not give a fix in my app
I though I implicitly answered. As soon as I changed location_manager.requestLocationUpdates(LocationManager.GPS_PROVIDER, scanTimer, 0, location_listener); into location_manager.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, scanTimer, 0, location_listener); everything was working properly, so I assume (maybe I shouldn't?): 1. Location listener gets called. 2. It gets the right values. Actually I'm just using the default constructor, no values are given whatsoever. Thanks. On Jun 4, 2:55 pm, TreKing treking...@gmail.com wrote: On Fri, Jun 4, 2010 at 4:35 AM, Charly carlos.per...@gmail.com wrote: Any other suggestions are more than welcome. I'll ask for third time, then I'm giving up on you. Does your location listener never get called or does it get called with bad / inaccurate values? --- -- TreKing - Chicago transit tracking app for Android-powered deviceshttp://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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 custom format text in EditText
I'm just starting to drink from the fire hose that is android. For my first project I would like to have an EditText field for numeric input that will automatically reformat the input as the user types to something like: #,##0.00 as the user types in the value. I can't seen to find the right place to add the code, I thought something like: EditText edittext = (EditText)findViewById(R.id.num_input); edittext.setOnKeyListener(new OnKeyListener() { @Override public boolean onKey(View v, int keyCode, KeyEvent event) { DecimalFormat twoDecimalPlaces = new DecimalFormat(#,##0.00); String valStr = ((EditText)v).getText().toString(); double val = Double.parseDouble(cleanNumber(valStr)); ((EditText)v).setText(twoDecimalPlaces.format(val)); return false; } }); the cleanNumber method strips out the commas from the string so it can be parsed. This does not work however. For one it is called before the key stroke is added to the text. Any suggestions on the best way to do this? Jim -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: how to obtain email address?
(refurbished) does anybody know how to programmingly obtain the (GMail) email address configured on a phone, which is usually the one initially entered to activate the phone? MANY thanks in advance for any know-how. On Jun 2, 9:43 am, HeHe cnm...@gmail.com wrote: does anybody know how to programmatically obtain the email address configured on an android phone? that is the one which was used to activate the phone? thanks in advance for the know-how. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Why is making orientation configChanges manually frowned upon?
I posted this same question on stackoverflow, but didn't really get an answer: http://stackoverflow.com/questions/2967903/handling-orientation-changes-yourself When it comes to threading and handling orientation changes, it can become quite tedious because the Activity gets destroyed. You have to create some way to store the thread (and any other data you want to preserve) so that you can point it at the new Activity. When handling the orientation changes yourself, to me, it seems a lot easier, and less tedious. You just call setContentView in your onConfigurationChanged method, which you have to do anyway when you create the Activity. However, the documentation states that you should only do that sort of thing as a last resort. What is considered a last resort? Would this be an acceptable use-case? I feel like I'm missing something important here. -- Adam Olsen SendOutCards.com http://www.vimtips.org http://last.fm/user/synic -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Update ongoing notification only when notification window shown?
Is there any way to detect whether the Notification Windows is being shown? I have a service that updates an ongoing notification, complete with a progress bar and text? Is there a way to know if the notifiication screen is actually being shown, so I can adjust how often I wouldn't be so concerned if not for the fact that the HTC Incredible will reboot after it receives several hundred or so updates. Based on a controlled experiment with a beta tester, the service could continue for 24 hours if it did not update progress, but dies after several hundred updates. So I am desperate to reduce the notifications, if that's what works, and one of the ways I could do that is by not updating as much or at all if that screen isn't being shown. Nathan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Update ongoing notification only when notification window shown?
Nathan, Have you considered doing away with detailed progress info in the notification pulldown? The pulldown (Notification) could just indicate that there are downloads in progress, perhaps their total number. Then upon the user clicking on the notification item, you could display an activity with detailed information, which would be updated in real time. This is inspired by what Android Market does, perhaps it's a viable option for your app as well? -- Kostya 05.06.2010 0:27, Nathan пишет: Is there any way to detect whether the Notification Windows is being shown? I have a service that updates an ongoing notification, complete with a progress bar and text? Is there a way to know if the notifiication screen is actually being shown, so I can adjust how often I wouldn't be so concerned if not for the fact that the HTC Incredible will reboot after it receives several hundred or so updates. Based on a controlled experiment with a beta tester, the service could continue for 24 hours if it did not update progress, but dies after several hundred updates. So I am desperate to reduce the notifications, if that's what works, and one of the ways I could do that is by not updating as much or at all if that screen isn't being shown. Nathan -- Kostya Vasilev -- WiFi Manager + pretty widget -- http://kmansoft.wordpress.com -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: glGenTextures going crazy on actual device
I recall getting bitten by this same bug a while ago when I switch an app out of density-compatibility scaling. One thing you may need to watch out for is a bug in Android 1.5 - it mangles the dimensions of images in the drawable-nodpi directory iirc. There's a bit of code you might find useful here: http://blog.tomgibara.com/post/190539066/android-unscaled-bitmaps -- Tom Gibara email: m...@tomgibara.com web: http://www.tomgibara.com blog: http://blog.tomgibara.com twitter: tomgibara On 4 June 2010 17:47, Samsyn d...@synthetic-reality.com wrote: Lance, (and everyone) Thank you so much! That was exactly it. All I had to do was rename my drawables folder to drawables-nodpi (and I did a full rebuild just to be nice) and now everything is back to normal, with api 4 in place. Of course, now I have to decide if I want to support higher rez screens at the expense of frame rate or not. It's so PRETTY, but it's at least 50% slower. :) Again, I was really pulling my hair out on this. Of course it might have been NICE if the GL Error Check actually mentioned it didn't feel the texture was a power of two. I, of course, just knew that it was, so I never logged a getWidth() on it. It's still a little odd that some textures were happier than others, but I imagine that is something to do with which wrong-sized-texture stepped on the memory of which other. :-) Once again, thank you! - Dan On Jun 4, 8:27 am, Lance Nanek lna...@gmail.com wrote: If I take a default API level 3 app, load the icon using BitmapFactory.decodeResource, and check Bitmap#getWidth and Bitmap#getHeight, then I get the values of 48 on the Droid. Now if I set android:minSdkVersion to 4 or higher in the manifest, then I get the values of 72. This is because changing the API level changes the default values for the screens supported: http://developer.android.com/guide/topics/manifest/supports-screens-e... It takes the app out of compatibility mode, where Android reports a smaller screen resolution than actually exists, and it starts scaling up resources from directories like the drawable directory, which is considered medium density when there is no density specifier, not high density. So anyway, depending on how you are storing and loading the images you are using for your textures, changing the API level may be causing Android to resize them. Textures have to have power of 2 size dimensions, so this resize can make an image that can be used as a texture into an image that can't be used. It's pretty easy to prevent the resizing, there are previous threads on that. On Jun 4, 3:35 am, Samsyn d...@synthetic-reality.com wrote: and yes, if I regress to api 3, the problem goes away, but apis 4 and 5 both have the problem.- Hide quoted text - - Show quoted text - -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.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: HTC Incredible suffering a reset while service running.
How do you not loose network connectivity without holding on to wakelock? Any secrets :P Or does the user keep the app active untill the download ends. On Jun 4, 10:02 am, Nathan critter...@crittermap.com wrote: I haven't even used a wakelock yet, so I don't think a wakelock is the problem. I've thought of using a brief wakelock around a single file download. But I also think that users can leave the phone plugged in if they want the download to complete soon. Nathan On Jun 3, 9:15 pm, nikhil nik...@gmail.com wrote: I am not sure about the exact reason but I feel it was because of mishandling of partial wakelock. Like your app, I had a service which remained active all time and for that I had to hold on to the wakelock. The phone did not restart if I commented out my wakelock code. Interesting thing is it never restarted untill I tried to change call forward setting or use car navigator app (thankfully, this was observed when we tested the app for any kind of conflicts) .Then I realised that I should not hold on to the wakelock for long, to avoid conflicts. When I went the AlarmManager way all conflicts vanished. Are you holding on to wakelock? If you are, you may try commenting out that part and keep your app active until download is complete so that you don't loose network connection. Just perform few tests with the wakelock thing hopefully you should get the answer. You may have to split your file download into batches so that you can release the wakelock. On Jun 3, 3:28 pm, Nathan critter...@crittermap.com wrote: On Jun 3, 12:47 pm, nikhil nik...@gmail.com wrote: Nathan, I had similar issue long time back when I had implemented the service architecture. I had observed few things: 1. My phone (Nexus One) used to restart (with my service running in background) when I tried to change the call forward setting or I tried to use the google car navigator app. 2. The phone did not restart if it was plugged into a computer. (May be related to network connectivity.) I tried all kind of stuff the only way I was able to get my app working was by referring to Mark Murphy's wakefulintentservice structure which uses the alarm manager. Thanks. Did you find out why the restart was triggered? Or did you simply managed to avoid it? Was it because of many notifications, or just the fact that it was running for long time, or that Android tried to kill it? The alarm manager isn't appropriate for this task, at least I don't think so, because it is not a service that wakes up periodically and does some work. It has a defined list of files to download and then finishes, but it is actively working all that time. Nathan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Update ongoing notification only when notification window shown?
On Jun 4, 1:41 pm, Kostya Vasilyev kmans...@gmail.com wrote: Nathan, Have you considered doing away with detailed progress info in the notification pulldown? The pulldown (Notification) could just indicate that there are downloads in progress, perhaps their total number. Then upon the user clicking on the notification item, you could display an activity with detailed information, which would be updated in real time. This is inspired by what Android Market does, perhaps it's a viable option for your app as well? Yes, I have. I may do it - and put the progress on the cancel/continue activity. It's less convenient for the users, perhaps, but I can't have it crashing on one particular device. I've also considered scrapping the whole service/notification thing and doing a download as an async task in an activity. But it seems like a fit for the service model. Nathan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: HTC Incredible suffering a reset while service running.
On Jun 4, 2:02 pm, nikhil nik...@gmail.com wrote: How do you not loose network connectivity without holding on to wakelock? Any secrets :P Or does the user keep the app active untill the download ends. On Jun 4, 10:02 am, Nathan critter...@crittermap.com wrote: I don't know actually. Maybe the notification activity is actually keeping it active. But it is more likely that the users are plugged into power. Downloads also have a timeout and up to three retries. Are you saying that the device will turn off wifi/network before it goes into power save and shuts down the whole thing? Maybe I need the wakelock, but now you have me worried about trying it, if it will cause other problems. Right now, I believe I will shut down on battery power and then continue when restarted. If I acquire a wakelock, then I will probably run the battery down for sure if the download takes hours. Nathan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: HTC Incredible suffering a reset while service running.
It's the other way around with WiFi and the screen - first, the screen switches off, then WiFi (after a delay). 05.06.2010 2:02 пользователь Nathan critter...@crittermap.com написал: On Jun 4, 2:02 pm, nikhil nik...@gmail.com wrote: How do you not loose network connectivity with... I don't know actually. Maybe the notification activity is actually keeping it active. But it is more likely that the users are plugged into power. Downloads also have a timeout and up to three retries. Are you saying that the device will turn off wifi/network before it goes into power save and shuts down the whole thing? Maybe I need the wakelock, but now you have me worried about trying it, if it will cause other problems. Right now, I believe I will shut down on battery power and then continue when restarted. If I acquire a wakelock, then I will probably run the battery down for sure if the download takes hours. Nathan -- You received this message because you are subscribed to the Google Groups Android Deve... -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Bitmap memory handling with ImageView.setimage
I've read a lot of previous messages on this topic but couldn't find universal agreement on the whole. I can't reproduce this in house, but a customer got an OutOfMemoryError when using an icon chooser dialog. This dialog is much like the Grid1 example - only it's in a dialog. The bitmap memory seems to run out after running the dialog a few times for a customer, resulting in java.lang.OutOfMemoryError: bitmap size exceeds VM budget public View getView(int pos, View convertView, ViewGroup parent) { ImageView imageView; if (convertView == null) { imageView = new ImageView(mContext); //imageView.setLayoutParams(new GridView.LayoutParams(40, 40)); imageView.setAdjustViewBounds(false); imageView.setScaleType(ImageView.ScaleType.CENTER_CROP); imageView.setPadding(4, 4, 4, 4); } else { imageView = (ImageView) convertView; } imageView.setImageResource(idlist.get(pos).value); imageView.setTag(idlist.get(pos).key); return imageView; } Should I try to call recycle on the bitmap from an ImageView when I reuse the view? Or would the ImageView do that anyway? But even if I do that, that's only a small portion of the bitmaps because most of them are seen without scrolling. The Adapter and the GridView are both local variables and therefore shouldn't be referenced after the dialog is dismissed. I do believe that it should be possible to use many bitmaps in an app - Google Maps does it, Picture Gallery does it. But maybe I need to learn more rules. Some say you should call bitmap.recycle, some say you shouldn't have to. Many say calling gc.collect will make it worse, etc. Nathan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: HTC Incredible suffering a reset while service running.
On Jun 4, 3:06 pm, Kostya Vasilyev kmans...@gmail.com wrote: It's the other way around with WiFi and the screen - first, the screen switches off, then WiFi (after a delay). So when does the CPU turn off? After wifi? Nathan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Detect Google map moving
Hi all ! I have a google map included on my phone. I would like to ask, how can I detect the user has pointed the screen and he/she moved a map away from the current location ? I'm going to make a navigation system witch always following the user's icon on the map as he/she is moving, but he/she touch the screen and move the map away I would like to stop the automatic tracking service:) I need some event, what I should listen or something like that:) or any good idea. Please, help me I you can, Thx : Karoly -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Calculate Time Elapsed
Hello, So I've been struggling with this and I am not sure why because it should be simple, but for some reason I just can not get my head around it !! I am developing a game and when the user saves their game, I write out the last time I checked their stats using System.currentTimeMillis(). Then when they load in the game I want to see how many total seconds have elapsed since it was last saved. Naturally I thought of getting System.currentTimeMillis() and then deducting my saved value and then converting that into seconds using this := long timePassed = System.currentTimeMillis() - lastCheck; int seconds = (int) ((timePassed / 1000) % 60); But on each load the seconds keep altering, but not within the right bounds. For example on one load it comes as 59 seconds, then it showed 23 seconds etc. Obviously my algorithm is slightly wonky but I can't work out why. Could some one please elaborate where I am going ? Regards Anthoni -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: HTC Incredible suffering a reset while service running.
I was talking about WiFi vs. the screen - not the CPU state. That, I don't know. 05.06.2010 2:24 пользователь Nathan critter...@crittermap.com написал: On Jun 4, 3:06 pm, Kostya Vasilyev kmans...@gmail.com wrote: It's the other way around with Wi... So when does the CPU turn off? After wifi? Nathan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-develop...@googlegro... -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Calculate Time Elapsed
Was that really supposed to be a %? The modulo (remainder) operator? 05.06.2010 2:56 пользователь Anthoni anthoni.gard...@gmail.com написал: Hello, So I've been struggling with this and I am not sure why because it should be simple, but for some reason I just can not get my head around it !! I am developing a game and when the user saves their game, I write out the last time I checked their stats using System.currentTimeMillis(). Then when they load in the game I want to see how many total seconds have elapsed since it was last saved. Naturally I thought of getting System.currentTimeMillis() and then deducting my saved value and then converting that into seconds using this := long timePassed = System.currentTimeMillis() - lastCheck; int seconds = (int) ((timePassed / 1000) % 60); But on each load the seconds keep altering, but not within the right bounds. For example on one load it comes as 59 seconds, then it showed 23 seconds etc. Obviously my algorithm is slightly wonky but I can't work out why. Could some one please elaborate where I am going ? Regards Anthoni -- You received this message because you are subscribed to the Google Groups Android Developers group. 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] android.permission.MOUNT_UNMOUNT_FILESYSTEMS problem / questions
I am writing an app to move data between the host and the phone. Initially I need to do it by copying files to the SDcard, then mounting the SDCard as host mass storage ( while unmounting it from the phone). And vica-versa. I am trying to do this using the mount call defined in SYSCALLS.TXT. I make the calls from a JNI C function library, and loadLibrary() etc. AndroidManifest.xml has the uses-permission set up for android.permission.MOUNT_UNMOUNT_FILESYSTEM. The code builds, loads runs, but mount or umount return -1 and errno == 1, which is Operation Not permitted. It sounds to me like I am close, but missing something. What steps could I be missing. ? Or am I using the mechanism incorrectly ? Or the wrong mechanism? What is android.permission.MOUNT_UNMOUNT_FILESYSTEM used for if not for this ? Can someone help ? thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: HeapWorker is wedged problem
On Jun 4, 5:28 am, m2k to.mikeko...@gmail.com wrote: i'm parsing an HTML page... it has to take that long... ;=) i'm extracting information... i can't do anything against it, The problem is that a *finalizer* is stuck for that long. If you can eliminate the finalizer, problem solved. If you can't, you need to eliminate the interdependence between the finalizer and the slow-running thread. The VM assumes that finalizers finish quickly, and anything taking a really long time is probably deadlocked. Rather than wait for the VM to run out of resources and crash mysteriously, it tells you about the problem immediately, and then shoots itself in the head to make sure you notice. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Calculate Time Elapsed
The number of seconds elapsed is just timePassed/1000. You're trying to make it more complicated than it really is. 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] Skinning Buttons
I want to provide my own images for buttons. Now I can call the setBackgroundResource(id) function to change the background of a button, but it does not handle the various states. How do I specify a different image for each state (normal, pressed, selected)? 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] Random pauses with “Key dispa tching timed out sending to null” when closing Android S urfaceView
When I close an Android SurfaceView Activity (this sometimes happens when bringing up the menu for that activity as well), the app sometimes pauses and almost gets an ANR (Application Not Responding) message. Looking at LogCat, it appears to be timing out trying to send keys to it. I tried modifying the code to setFocusable(false) when in the onKeyDown handler for the SurfaceView, but that doesn't seem to affect this. Any other ideas on what might be causing this? Or what these messages in Logcat even mean? If you wait for a few seconds, it becomes responsive again. This happens on Android 1.5 and 2.1 devices (I was hoping it was just a 1.5 bug) but doesn't seem as noticeable on faster devices like the Droid... = 05-31 19:35:35.285: INFO/WindowManager(586): focus null mToken is null at event dispatch! 05-31 19:35:35.295: WARN/WindowManager(586): Current state: {{KeyEvent{action=1 code=4 repeat=0 meta=0 scancode=158 mFlags=8} to null @ 1275334535292 lw=null lb=null fin=true gfw=true ed=true tts=0 wf=false fp=false mcf=null}} 05-31 19:35:35.305: WARN/WindowManager(586): Continuing to wait for key to be dispatched 05-31 19:35:40.306: WARN/WindowManager(586): Key dispatching timed out sending to 05-31 19:35:40.316: WARN/WindowManager(586): Dispatch state: {{KeyEvent{action=0 code=4 repeat=0 meta=0 scancode=158 mFlags=8} to Window{43763540 com.myapp/com.myapp.DiagramEdit paused=false} @ 1275334499512 lw=Window{43763540 com.myapp/com.myapp.DiagramEdit paused=false} lb=android.os.binderpr...@43702190 fin=false gfw=true ed=true tts=0 wf=false fp=false mcf=null}} 05-31 19:35:40.326: INFO/WindowManager(586): focus null mToken is null at event dispatch! 05-31 19:35:40.326: WARN/WindowManager(586): Current state: {{KeyEvent{action=1 code=4 repeat=0 meta=0 scancode=158 mFlags=8} to null @ 1275334540327 lw=null lb=null fin=true gfw=true ed=true tts=0 wf=false fp=false mcf=null}} 05-31 19:35:40.326: WARN/WindowManager(586): Continuing to wait for key to be dispatched -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Skinning Buttons
John Gaby wrote: I want to provide my own images for buttons. Now I can call the setBackgroundResource(id) function to change the background of a button, but it does not handle the various states. How do I specify a different image for each state (normal, pressed, selected)? You need to make that resource be a StateListDrawable. The easiest way to do this is to copy the XML for the standard Button StateListDrawable. You can find this in: $ANDROID_HOME/platforms/$VERSION/data/res/drawable/btn_default.xml (where $ANDROID_HOME is where you installed the SDK and $VERSION is one of the SDK versions) Change that to point to your own nine-patch images for your various button backgrounds (normal, pressed, selected). -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android 2.2 Programming Books: http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Calculate Time Elapsed
Hi Peter, Thanks. Certainly was trying to over complicate things, but not sure why. Anyway, removing the last part solves the problem. Regards Anthoni On Jun 5, 1:54 am, Peter Eastman peter.east...@gmail.com wrote: The number of seconds elapsed is just timePassed/1000. You're trying to make it more complicated than it really is. 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: 最近写了两个应用, MMTimer,火车余票查询
It seems (using Google's translation service) that you say you have a problem, but do you have a question? This looks to me more like an ad On Jun 4, 2:33 am, igo where wuzeju...@gmail.com wrote: I train ticket query * *http://www.androidin.net/bbs/android-110739-1-1.html * MMTimer *http://www.androidin.net/bbs/android-110551-1-1.htmlMMTimer the widget in question, have not yet released, the update of the widget is not very clear, a problem.Later still need everyone's help, have encountered a problem updating.MMTimer you have a 1440 times a day love.* Main function-MMTimer automatically updates every minute, switch to a different picture, one minute a picture of a happy, smiling an hour 60, day 1440 meeting date.- Low system resources occupancy;- Provide high-definition real timekeeping picture to see time to see beautiful things correct;- With off-line database, an image calculated by 30K an hour is 1800K, the day is 1800 * 24/1024 = 42M, save you valuable traffic;- To provide different versions of the newspaper theme, beautiful car models currently provide temporary version, street version of beauty, street beauty Edition II, the follow-up to introduce more versions;- Beautiful car models and street beauty Edition II Edition as the server instability, a small amount of data loss, but does not affect the use, the user can customize the image; Beauty of data we canhttps: / / code.google.com / p / mmtimer / downloadsDepartment for download, put / sdcard / MMTimer directory;- Can customize the different times of MM or handsome pot;- Customize a different version of the time, family friends, etc. are all OK;- Provide save, when you can see your favorite MM; We are interested to support it, huh, huh. *火车余票查询* http://www.androidin.net/bbs/android-110739-1-1.html *MMTimer* http://www.androidin.net/bbs/android-110551-1-1.html MMTimer的widget有问题,现在还没有放出来,对widget的更新还不是很清楚,有点问题。稍后还需要大家的帮忙,遇到了更新问题了。 MMTimer让您每天拥有1440次恋爱。 *主要功能 -MMTimer每一分钟自动更新内容,更换不同的照片,一分钟一张图片,一份欣 喜,一小时60张微笑,一天1440次约会。 -系统资源占用率低; -提供高清真人报时图片,看时间看美女两不误; -采用离线数据库,一张图片按30K来计算,一小时就是1800K,一天就是1800*24/1024=42M,为您节省宝贵的流量; -提供不同版本的报时主题,目前暂提供美女车模版,街头美女版,街头美女版 II,后续将推出更多的版本; -美女车模版和街头美女版II由于服务器不稳定,数据有少量丢失,但不影响使用,用户可以自定义图片; 美女数据大家可以从 https://code.google.com/p/mmtimer/downloads 处下载得到,放到/sdcard/MMTimer目录下; -可以自定义不同时间的MM或帅锅; -自定义不同版本的时间,亲人好友等的都行; -提供保存,让你在什么时候也可以看到您喜欢的MM; 大家有兴趣就支持下吧,呵呵。 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: glGenTextures going crazy on actual device
Thanks for the nodpi tip... I do have a followup question though. To control performance, I would like to be able to tell android no matter what the phones native resolution is, if it is bigger than X, could you please lie to me, as in api 3, and make it closer to X, but don't just render me as a postage stamp with black bars, but fill the screen with me? Something like I would like the height no greater than 320ish and it would pick something close to that, then tell me a height and width which had an aspect ratio matching the actual screen.. I would render to that height and width, and android would fill the screen... All with the assumption that that would be faster than my rendering to the full screen would be. (my fps took a definite hit going from api 3 to api 4, and I *assume* that is because the size of the GL surface increased from the it's about 480x320 lie to the it's exactly 857x480 truth.) I messed with the android:large-screens=false sorts of things in the manifest, but none of them seemed to do what I was looking for. I'm open to any other tips for speeding up GL. But first I need to add some stats to see just how many triangles I am rendering overall at the moment, maybe it's more than I realize. I have some fairly aggressive Level of Detail code, so I don't expect it to be much... I think I make fewer than 10 calls to drawPrimitives (grouping my triangles into as few shipments as possible, as it were). I'm cramming a zillion things into each texture (uv subrectangles) I was getting 30fps in api 3, and now seem almost half of that. - Dan On Jun 4, 1:43 pm, Tom Gibara m...@tomgibara.com wrote: I recall getting bitten by this same bug a while ago when I switch an app out of density-compatibility scaling. One thing you may need to watch out for is a bug in Android 1.5 - it mangles the dimensions of images in the drawable-nodpi directory iirc. There's a bit of code you might find useful here: http://blog.tomgibara.com/post/190539066/android-unscaled-bitmaps -- Tom Gibara email: m...@tomgibara.com web:http://www.tomgibara.com blog:http://blog.tomgibara.com twitter: tomgibara On 4 June 2010 17:47, Samsyn d...@synthetic-reality.com wrote: Lance, (and everyone) Thank you so much! That was exactly it. All I had to do was rename my drawables folder to drawables-nodpi (and I did a full rebuild just to be nice) and now everything is back to normal, with api 4 in place. Of course, now I have to decide if I want to support higher rez screens at the expense of frame rate or not. It's so PRETTY, but it's at least 50% slower. :) Again, I was really pulling my hair out on this. Of course it might have been NICE if the GL Error Check actually mentioned it didn't feel the texture was a power of two. I, of course, just knew that it was, so I never logged a getWidth() on it. It's still a little odd that some textures were happier than others, but I imagine that is something to do with which wrong-sized-texture stepped on the memory of which other. :-) Once again, thank you! - Dan On Jun 4, 8:27 am, Lance Nanek lna...@gmail.com wrote: If I take a default API level 3 app, load the icon using BitmapFactory.decodeResource, and check Bitmap#getWidth and Bitmap#getHeight, then I get the values of 48 on the Droid. Now if I set android:minSdkVersion to 4 or higher in the manifest, then I get the values of 72. This is because changing the API level changes the default values for the screens supported: http://developer.android.com/guide/topics/manifest/supports-screens-e... It takes the app out of compatibility mode, where Android reports a smaller screen resolution than actually exists, and it starts scaling up resources from directories like the drawable directory, which is considered medium density when there is no density specifier, not high density. So anyway, depending on how you are storing and loading the images you are using for your textures, changing the API level may be causing Android to resize them. Textures have to have power of 2 size dimensions, so this resize can make an image that can be used as a texture into an image that can't be used. It's pretty easy to prevent the resizing, there are previous threads on that. On Jun 4, 3:35 am, Samsyn d...@synthetic-reality.com wrote: and yes, if I regress to api 3, the problem goes away, but apis 4 and 5 both have the problem.- Hide quoted text - - Show quoted text - -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en- Hide quoted
[android-developers] How do we attach an image/files to a forum posting?
I've seen a few people attached images files to their posts. Could somebody explain how I can do this? I don't see any options for doing this when I post a message. 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: Need help on List Adapter
Any help is greatly appreciated!!! Please guys share your thougths On Sun, May 30, 2010 at 8:01 AM, Ramesh Sangili ramesh.sang...@gmail.comwrote: Guys, I am extending BaseAdapter and trying to populate the List Screen on my Activity Screen. NotifyDataSetChanged is not working as expected. Please find the below snippet of code. Please do let me know your thoughts. public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); initialize(); context = this; config = Config.getInstance(); searchText = new EditText(this); handler = new Handler() { @Override public void handleMessage(Message msg) { msgQueueAdapter.notifyDataSetChanged(); context.msgQueueAdapter.notifyDataSetChanged(); msgQueueAdapter.notifyDataSetInvalidated(); } }; searchText.addTextChangedListener( new TextWatcher() { @Override public void onTextChanged(CharSequence s, int start, int before, int count) { // TODO Auto-generated method stub Log.d(on text, String: + s); loadData(s.toString()); msgQueueAdapter = new ListAdapter(context, msgQueueList); Message msg = handler.obtainMessage(); handler.sendMessage(msg); searchText.bringToFront(); runOnUiThread(new Runnable() { @Override public void run() { msgQueueAdapter.notifyDataSetChanged(); searchText.setCursorVisible(true); searchText.setClickable(true); } }); } @Override public void beforeTextChanged(CharSequence s, int start, int count, int after) { } @Override public void afterTextChanged(Editable s) { // TODO Auto-generated method stub } }); msgQueueAdapter = new ListAdapter(this, msgQueueList); Log.d(list, List Display - 1 + msgQueueAdapter); msgQueueListView = this.getListView(); msgQueueListView.addHeaderView(searchText); setListAdapter(msgQueueAdapter); msgQueueAdapter.notifyDataSetChanged(); this.msgQueueAdapter.notifyDataSetInvalidated(); } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Creating an Android VN
Thanks for the suggestions. This at least gives me somewhere to start! On Jun 4, 10:44 am, Lance Nanek lna...@gmail.com wrote: Overlapping things in Android is pretty trivial. For example, when you put multiple children in a FrameLayout, they are all shown on top of each other as per the documentation:http://developer.android.com/reference/android/widget/FrameLayout.html Another method is the Toast utility for showing text messages on top of everything else:http://developer.android.com/reference/android/widget/Toast.html And of course dialogs are another way to show a window of content on top of another screen:http://developer.android.com/guide/topics/ui/dialogs.html It isn't far enough along that I've put any effort into cleaning up the code/XML, but you can see the FrameLayout method being used to compose layers of a character and controls here:http://code.google.com/p/growing-phone-pet/source/browse/trunk/res/la... There's a FrameLayout there explicitly, but the PetView that is composing the different images that make up the scenery and character is also a subclass of FrameLayout. On Jun 4, 12:10 am, EwanG ewan.grant...@gmail.com wrote: OK, so... question was too broad? No such examples exist? No one here who would be interested in such a thing if it were written? :-) On May 30, 10:04 pm, EwanG ewan.grant...@gmail.com wrote: I am looking for an example of how to setup a screen with a background, an overlay image (my character), and over that a frame that sometimes has text, and sometimes has menu options. To make myself clearer, as I suggest in the title I'm trying to create aVisualNovelfor Android. Something like I've done in Flash and using RenPy, but with mobile sensibilities (make the buttons more touch friendly, use the accelerator for certain inputs, etc). Any good, publicly available source code I should check out? I have written one previous Android Program (Mars Lander which I gather is still floating about), but this is different enough I think I need a bit of help. Thanks in advance! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: 最近写了两个应 用,MMTimer,火车余票查询
hi,thanks for you help.I post it is really to be a ad. when i use the widget, i occur the following issue. 05-28 12:01:14.937: WARN/ActivityManager(52): Unable to launch app com.mmtimer/10024 for broadcast Intent { act=android.appwidget.action. APPWIDGET_ENABLED cmp=com.mmtimer/.MMWidget }: process is bad 05-28 12:01:14.947: WARN/ActivityManager(52): Unable to launch app com.mmtimer/10024 for broadcast Intent { act=android.appwidget.action.APPWIDGET_UPDATE cmp=com.mmtimer/.MMWidget (has extras) }: process is bad. And I had try what I can do, but it also can't work. so,Could you like help me ,thanks. 在 2010年6月5日 上午9:45,Bob Kerns r...@acm.org写道: It seems (using Google's translation service) that you say you have a problem, but do you have a question? This looks to me more like an ad On Jun 4, 2:33 am, igo where wuzeju...@gmail.com wrote: I train ticket query * * http://www.androidin.net/bbs/android-110739-1-1.html * MMTimer *http://www.androidin.net/bbs/android-110551-1-1.htmlMMTimerthe widget in question, have not yet released, the update of the widget is not very clear, a problem.Later still need everyone's help, have encountered a problem updating.MMTimer you have a 1440 times a day love.* Main function-MMTimer automatically updates every minute, switch to a different picture, one minute a picture of a happy, smiling an hour 60, day 1440 meeting date.- Low system resources occupancy;- Provide high-definition real timekeeping picture to see time to see beautiful things correct;- With off-line database, an image calculated by 30K an hour is 1800K, the day is 1800 * 24/1024 = 42M, save you valuable traffic;- To provide different versions of the newspaper theme, beautiful car models currently provide temporary version, street version of beauty, street beauty Edition II, the follow-up to introduce more versions;- Beautiful car models and street beauty Edition II Edition as the server instability, a small amount of data loss, but does not affect the use, the user can customize the image; Beauty of data we canhttps: / / code.google.com / p / mmtimer / downloadsDepartment for download, put / sdcard / MMTimer directory;- Can customize the different times of MM or handsome pot;- Customize a different version of the time, family friends, etc. are all OK;- Provide save, when you can see your favorite MM; We are interested to support it, huh, huh. *火车余票查询* http://www.androidin.net/bbs/android-110739-1-1.html *MMTimer* http://www.androidin.net/bbs/android-110551-1-1.html MMTimer的widget有问题,现在还没有放出来,对widget的更新还不是很清楚,有点问题。稍后还需要大家的帮忙,遇到了更新问题了。 MMTimer让您每天拥有1440次恋爱。 *主要功能 -MMTimer每一分钟自动更新内容,更换不同的照片,一分钟一张图片,一份欣 喜,一小时60张微笑,一天1440次约会。 -系统资源占用率低; -提供高清真人报时图片,看时间看美女两不误; -采用离线数据库,一张图片按30K来计算,一小时就是1800K,一天就是1800*24/1024=42M,为您节省宝贵的流量; -提供不同版本的报时主题,目前暂提供美女车模版,街头美女版,街头美女版 II,后续将推出更多的版本; -美女车模版和街头美女版II由于服务器不稳定,数据有少量丢失,但不影响使用,用户可以自定义图片; 美女数据大家可以从 https://code.google.com/p/mmtimer/downloads 处下载得到,放到/sdcard/MMTimer目录下; -可以自定义不同时间的MM或帅锅; -自定义不同版本的时间,亲人好友等的都行; -提供保存,让你在什么时候也可以看到您喜欢的MM; 大家有兴趣就支持下吧,呵呵。 -- You received this message because you are subscribed to the Google Groups Android Developers group. 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: Any ScoreLoop users out there?
Hi again Nightwolf, But optional Scoreloop profile images will be something coming up soon. Watch this space :) On Jun 4, 6:06 pm, Junde (Scoreloop) jun...@gmail.com wrote: Hi Nightwolf, Yes we do give a hoot about such things! We have an English language blacklist that would filter and reject profanity. Unfortunately, currently, you would not be able to attach pictures to user profiles. Regards, Junde On Jun 2, 12:25 pm, Nightwolf mikh...@gmail.com wrote: Sometimes users enter profanity as their nick name. Are there any means to avoid that with ScoreLoop? If the answer is positive then what are the supported languages? Is it possible to attach a picture to user record? On May 29, 11:28 am, Prenitha prenitha...@yahoo.co.in wrote: Hi Neil, We have posted the answer to your query as an FAQ on Scoreloop's support website. You can directly click the following link to get there. http://support.scoreloop.com/faqs/android-development/removing-search... If you have any additional queries, the fastest way to get a response will be to use our support website. Regards, Prenitha. On May 27, 12:18 am, Neilz neilhorn...@googlemail.com wrote: Great, thanks Junde. Can you tell me how I can filter this list, to only show the values I want? Like my example with the Jewels game, I really only want the first three items in the list, at most. Or is it just a simple code hack? On May 26, 6:29 pm, Junde (Scoreloop) jun...@gmail.com wrote: Hi Neil, I'm sure there should be some Scoreloop users here. There's actually guys from the Scoreloop team here too, I'm one of them :) These are basically some ISO jargon, that we are going to replace with friendlier words very soon. Basically, iso3166_1 refers to country codes, and iso3166_2 refers to country subdivision codes (regions/cities etc). So it's 2 additional ways of filtering scores. As for how iso3166_1 differs from your Country, I think your Country is based on the user's input on their player profile, while iso3166 is based on detection. I'll verify this for you. By the way, we've also got a nice support forum up athttp://support.Scoreloop.com if you're interested to learn more. Cheers, Junde On May 26, 9:42 pm, Neilz neilhorn...@googlemail.com wrote: I'm implementing ScoreLoop for my game. There is a standard selection widget for the leaderboard type, which lets you refine the scores. By default, I get: - Global Leaderboard - Your Country Leaderboard - 24h Leaderboard - search_list.nationality_iso3166_1 - search_list.nationality_iso3166_2 What on earth are the last two items? This list seems to come from ScoreLoop, rather than being anything configurable in the xml. I only want the first three in the list, is there anyway I can set this somewhere? I notice that other games that use ScoreLoop (like Jewels for example) only have the first three items also. Thanks. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Need help on List Adapter
i think you should not need to montior the change, one thing you need do is to change the baseAdapter ,i do like this public SimpleAdapter initAdapter( ArrayListHashMapString, String listDataSource) { SimpleAdapter mSchedule = new SimpleAdapter(this, listDataSource, R.layout.left_ticket_list_item,// ListItem的XML实现 new String[] { String.valueOf(R.string.ret_id), String.valueOf(R.id.train_no), String.valueOf(R.id.start_time), String.valueOf(R.id.arrive_time), String.valueOf(R.id.esep_time), String.valueOf(R.id.left_hard_seat), String.valueOf(R.id.left_hard_berth), String.valueOf(R.id.left_soft_berth), String.valueOf(R.id.left_LevOne_Seat), String.valueOf(R.id.left_LevSec_Seat) }, new int[] { R.id.query_ret_id, R.id.train_no, R.id.start_time, R.id.arrive_time, R.id.esep_time, R.id.left_hard_seat, R.id.left_hard_berth, R.id.left_soft_berth, R.id.left_LevOne_Seat, R.id.left_LevSec_Seat }); return mSchedule; } public void showQueryLeftTicketRet( ArrayListLeftTicketInfo al_retleftTicketInfo) { HashMapString, String queryRetListMap = new HashMapString, String(); queryRetList.clear(); if (al_retleftTicketInfo.size() == 0) { this.showQueryRet.setVisibility(0); } else { this.showQueryRet.setVisibility(2); for (int i = 0; i al_retleftTicketInfo.size(); i++) { queryRetListMap = new HashMapString, String(); queryRetListMap.put(String.valueOf(R.string.ret_id), al_retleftTicketInfo.get(i).id); queryRetListMap.put(String.valueOf(R.id.train_no), al_retleftTicketInfo.get(i).trainNo); queryRetListMap.put(String.valueOf(R.id.start_time), al_retleftTicketInfo.get(i).startTime); queryRetListMap.put(String.valueOf(R.id.arrive_time), al_retleftTicketInfo.get(i).arriveTime); queryRetListMap.put(String.valueOf(R.id.esep_time), al_retleftTicketInfo.get(i).esepTime); queryRetListMap.put(String.valueOf(R.id.left_hard_seat), al_retleftTicketInfo.get(i).leftHardSeat); queryRetListMap.put(String.valueOf(R.id.left_hard_berth), al_retleftTicketInfo.get(i).leftHardBerth); queryRetListMap.put(String.valueOf(R.id.left_soft_berth), al_retleftTicketInfo.get(i).leftSoftBerth); queryRetListMap.put(String.valueOf(R.id.left_LevOne_Seat), al_retleftTicketInfo.get(i).leftLevOneSeat); queryRetListMap.put(String.valueOf(R.id.left_LevSec_Seat), al_retleftTicketInfo.get(i).leftLevSecSeat); queryRetList.add(queryRetListMap); //Log.v(INFO, al_retleftTicketInfo.get(i).id); } } this.queryLeftTicketRetListView.setAdapter(initAdapter(queryRetList) ); } 2010/6/5 Ramesh Sangili ramesh.sang...@gmail.com Any help is greatly appreciated!!! Please guys share your thougths On Sun, May 30, 2010 at 8:01 AM, Ramesh Sangili ramesh.sang...@gmail.comwrote: Guys, I am extending BaseAdapter and trying to populate the List Screen on my Activity Screen. NotifyDataSetChanged is not working as expected. Please find the below snippet of code. Please do let me know your thoughts. public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); initialize(); context = this; config = Config.getInstance(); searchText = new EditText(this); handler = new Handler() { @Override public void handleMessage(Message msg) { msgQueueAdapter.notifyDataSetChanged(); context.msgQueueAdapter.notifyDataSetChanged(); msgQueueAdapter.notifyDataSetInvalidated(); } }; searchText.addTextChangedListener( new TextWatcher() { @Override public void onTextChanged(CharSequence s, int start, int before, int count) { // TODO Auto-generated method stub Log.d(on text, String: + s); loadData(s.toString()); msgQueueAdapter = new ListAdapter(context, msgQueueList); Message msg = handler.obtainMessage(); handler.sendMessage(msg); searchText.bringToFront(); runOnUiThread(new Runnable() { @Override public void run() { msgQueueAdapter.notifyDataSetChanged(); searchText.setCursorVisible(true); searchText.setClickable(true); } }); } @Override public void beforeTextChanged(CharSequence s, int start, int count, int after) { } @Override public void afterTextChanged(Editable s)