[android-developers] Re: Enabling root permissions/functioanlities from the Android application or a folder in Android filesystem with default Permission
Hi Chris , Thanks for the reply it worked pretty well. The /data folder in the android file system has the default application folder where the application specific read write happens they generally looks like this : */data/data/my.package.name/app_my custom folder/* **directory=getDir(fodlername, Context.MODE_WORLD_WRITEABLE | Context.MODE_WORLD_READABLE); and this directory has been used to do the file ops. *Also if I want to the same in the SD card is there any way to gain the permission and then do it on that.ideally once the permission is gained we can do the normal file operation just like i did above for the android file system* Thanks , Rgds, saurabh ..pain is temporary.quitting lasts forever.. On Tue, Jul 26, 2011 at 10:46 PM, Chris Stratton cs07...@gmail.com wrote: On Tuesday, July 26, 2011 4:39:36 AM UTC-4, Jessica wrote: *Other way round for this problem is -- Is there any folder in the android file system where i could create a database(sqlite) and do the file operation(read write ) in this case I dont have to enable the chmod permission .* Yes, android provides an internal storage directory for applications and also a related place for them to create sqlite databases. At the java level, finding the appropriate path is handled automatically by some of the typical functions, but you can determine it with Context.getDir() and Context.getFileDir() - if you want to do something in the NDK, probably call one of those from java and pass the result to your ndk routines as a java string, where you would convert it to a native string for the posix file functions. Using root access is to be avoided as it's not available on unmodified devices, and should cause some due suspicion (why does this app need that?) on the part of the user even where it is. It's also entirely outside the scope of the ndk list. -- You received this message because you are subscribed to the Google Groups android-ndk group. To view this discussion on the web visit https://groups.google.com/d/msg/android-ndk/-/IdiVQai6JIcJ. To post to this group, send email to android-...@googlegroups.com. To unsubscribe from this group, send email to android-ndk+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/android-ndk?hl=en. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: HTTP Post of Image
In your manifest file add permissions to camera and for uploading internet permission as follows uses-permission android:name=android.permission.INTERNET / uses-permission android:name=android.permission.CAMERA / On Thu, Jul 28, 2011 at 11:07 AM, perumal316 perumal...@gmail.com wrote: Hi Siva, But my application keeps on crashing when I insert this line: URI mCapturedImageURI = getContentResolver().insert(MediaStore.Images.Media.EXTERNAL_CONTENT_URI, values); Must I add any permission in the manifest file? Basically I just want to get the string containing the path to the image saved e.g: /sdcard/DCIM/12345.jpg Must I use contentprovider? Thanks In Advance, Perumal On Jul 28, 12:23 pm, Sivasankar K sivasanka...@greatinnovus.com wrote: using the uri of content resolver you can get the path where it is getting stored URI mCapturedImageURI = getContentResolver().insert(MediaStore.Images.Media.EXTERNAL_CONTENT_URI, values); Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); intent.putExtra(MediaStore.ACTION_IMAGE_CAPTURE, capturedImage); intent.putExtra(MediaStore.EXTRA_OUTPUT, mCapturedImageURI); On Thu, Jul 28, 2011 at 8:14 AM, perumal316 perumal...@gmail.com wrote: Hi All, I am using the following intent to invoke the camera: Intent cameraIntent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE); startActivity(cameraIntent); The image is saved into the sdcard with the time/date as the name. I want to do a HTTPPost of this image once the picture is taken. How do I get the name of the picture stored? Or how to I change the name of the image stored? Thanks In Advance, Perumal -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- K Siva Sankar -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- K Siva Sankar -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Regarding User Authentication
Hello ListNameValuePair httpparams = new ArrayListNameValuePair(); httpparams .add(new BasicNameValuePair(user, androidUser)); httpparams .add(new BasicNameValuePair(pass, androidpassword)); URI uri = URIUtils.createURI(http, yourUrl, -1, / youractionOrPage, URLEncodedUtils.format(httpparams , UTF-8), null); HttpGet httpget = new HttpGet(uri); Enjoy On Jul 27, 8:43 am, rajesh nair rajjeshgn...@gmail.com wrote: Members, I have developed an application using which I can view mjpeg stream being streamed from my camera, on my android phone. It works fine if a user authentication is not required. But fails when the server requires a user authentication. Following code is used to read the Mjpeg stream. //url =http://xyz.xyz.xyz.xyz:80/xyz/mjpeg.cgi //usrid = admin //password = admin public static MjpegInputStream read(String url, String usrid, String password) { HttpResponse res; DefaultHttpClient httpclient = new DefaultHttpClient(); try { res = httpclient.execute(new HttpGet(URI.create(url))); return new MjpegInputStream(res.getEntity().getContent()); } catch (ClientProtocolException e) { } catch (IOException e) {} return null; } Could someone please explain to me how I can include the usrid and the password to the above code and make it work? Thanks in advance Rajesh -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Comments in market place
Is there anyway to remove spam comments from your applications? I have several applications on the market place, today someone has posted a comment saying the application contains spyware, which is complete rubbish and not true, how can you prevent this kind of thing? -- Regards, Sy -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Comments in market place
No, you can't. You could probably mark that comment as spam, but just your vote doesn't count towards anything. I am not sure if Google cares about spammy comments. *Thanks and Regards, Kumar Bibek* * http://techdroid.kbeanie.com http://www.kbeanie.com* On Thu, Jul 28, 2011 at 12:08 PM, Simon Platten simonaplat...@googlemail.com wrote: Is there anyway to remove spam comments from your applications? I have several applications on the market place, today someone has posted a comment saying the application contains spyware, which is complete rubbish and not true, how can you prevent this kind of thing? -- Regards, Sy -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Comments in market place
On Thu, Jul 28, 2011 at 3:38 PM, Simon Platten simonaplat...@googlemail.com wrote: Is there anyway to remove spam comments from your applications? No. I have several applications on the market place, today someone has posted a comment saying the application contains spyware, which is complete rubbish and not true, how can you prevent this kind of thing? You can mark it as spam. That doesn't remove it, but it (probably) won't display at the top with the new Market client. https://market.android.com/support/developer/bin/answer.py?hl=enanswer=113417 -- Regards, Sy -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] LocationManager using Network provider returns stale locations
Hi, I have the following scenario t1 : sitting at home - wifi connected - location manager using network provider returns the correct location (home) t2 : I get in my car, use the location manager now with gps provider - returns correct locations throughout the trip (100km) t3 : arrive at work - wifi connected - location manager again using network provider returns the location from t1, and not the current location. timestamp on the location resource object coming from the location manager is an up-to-date timestamp. distance / time between t1 and t3 is 100km / 1hour Is there some kind of caching mechanism that I need to be aware of, and can it be invalidated ? How can I force the locationmanager (using network provider) to always return an up-to-date location ? Both in t1 and t3, the phone is connected to a WiFi base station that is known to Google (capable of being correctly resolved into an address). between t1 and t3 the Wifi radio is on, but obviously not connected to a basestation, and the locationmanager is using the gps provider. Also, sometimes, even when connected to a WiFi basestation, the locationmanager doesn't return a location (using a 30 second timeout). In all cases, the WiFi base stations can be resolved to an address. Any ideas ? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: google map marker
Android cannot give you an error of lines not supported. Did you try modifying the code to work with your project or did you just blindly copy paste? Did you change the variables and the XML files to the ones you have in your project? There are thousands of tutorials for this on the Internet. Google it. Thanks On Thu, Jul 28, 2011 at 10:35 AM, arun kumar hariarun2...@gmail.com wrote: abhishek can you send source code with xml file and android manifest file like project. because i try your coding its shows error.like some lines are not supported. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Raghav Sood http://www.raghavsood.com/ http://wiki.androidappcheck.com/ http://www.telstop.tel/ https://market.android.com/developer?pub=Appaholics -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: The emulator died when I execute ping in adb shell repeatly
It seams hang at bufferReader.readLine() when read from InputStream On 7月28日, 上午9时19分, nanhu tianlifeixue...@gmail.com wrote: only when the ping execution failed,the problem can appear On 7月27日, 下午2时57分, nanhu tianlifeixue...@gmail.com wrote: when I execute ping -c 20 -i 0.2 -s 92 -W 1www.google.com in adb shell repeatly , after dozens of times , it can not execute , and I can not login another shell -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 web data into TextViews?
hello Droid, you can use this method to get return string from server private InputStream OpenHttpConnection(String urlString) throws IOException { InputStream in = null; int response = -1; URL url = new URL(urlString); URLConnection conn = url.openConnection(); if (!(conn instanceof HttpURLConnection)) throw new IOException(Not an HTTP connection); try{ HttpURLConnection httpConn = (HttpURLConnection) conn; httpConn.setAllowUserInteraction(false); httpConn.setInstanceFollowRedirects(true); httpConn.setRequestMethod(GET); httpConn.connect(); response = httpConn.getResponseCode(); if (response == HttpURLConnection.HTTP_OK) { in = httpConn.getInputStream(); } } catch (Exception ex) { throw new IOException(Error connecting); } return in; } private String DownloadText(String URL) { int BUFFER_SIZE = 2000; InputStream in = null; try { in = OpenHttpConnection(URL); } catch (IOException e1) { // TODO Auto-generated catch block e1.printStackTrace(); return ; } InputStreamReader isr = new InputStreamReader(in); int charRead; String str = ; char[] inputBuffer = new char[BUFFER_SIZE]; try { while ((charRead = isr.read(inputBuffer))0) { //---convert the chars to a String--- String readString = String.copyValueOf(inputBuffer, 0, charRead); str += readString; inputBuffer = new char[BUFFER_SIZE]; } in.close(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); return ; } return str; } try call this function in your main code, where str is return string from server String str = DownloadText(http://kabarku.com/androidwww/endyk- test.php); textView.setText(str); extend your self that code, happy coding :) On Jul 27, 7:30 pm, Droid rod...@gmail.com wrote: I am looking for an example of how to get lines of text from a web server query into simple TextViews - NOT WebViews. I have found complex examples with all types of extras that make it horrifically difficult to follow. This example is way too hard for me:http://www.ibm.com/developerworks/xml/library/x-dataAndroid/ Can some kind person point me at a straightforward example. I think I need an Async Task or some type of web fetch thread involved. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Date Picker using xml layout - problem in android app
i have some problems in using the date picker from xml layout. in my app when the user clicks a text view a custom dialog box opens. In the layout of the custom dialog box i am showing a date picker which i have place in my xml file. When it appears in the app i want a particular date to be viewed, for example as 01 Jan 1950. Every time it opens it is showing the present date only. In my dialog box i have a set and cancel buttons. The Cancel button cancels the dialog box where as when i click the Set button i want the current date to be stored to a String. In another activity of my app in a custom dialog box i want to show a date picker only with the year columns, i dont need the date and month columns. How to get it, please help me friends -- K Siva Sankar -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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]Proximity Alerts in LocationManager not working as expected.
Hi everyone, I have an application which needs to call a new screen if it comes within the proximity of a few locations. So I am using the addProximityAlerts() function as follows: But this does not work at all. My code is shown below *public void setupLocationMonitoring(Intent newIntent) { for (int i = 0; i locations.size(); i++) { newIntent.putExtra(widgetId, i); newIntent.setAction(IntentAction); PendingIntent intent1= PendingIntent.getBroadcast(HaiMap.this, i, newIntent, PendingIntent.FLAG_CANCEL_CURRENT); double lati=(double) (locations.get(i).getLatitudeE6()) / 1E6; double longi =(double) (locations.get(i).getLongitudeE6()) / 1e6; lm.addProximityAlert(lati,longi,200,0, intent1); } } * The Manifest entry for the broadbase receiver which is supposed to receive the intents is as follows; * receiver android:name=com.deepak.sample.receiver.MyBroadCastReceiver intent-filter action android:name=com.deepak.sample.view.HaiMap.intentWiki/action /intent-filter /receiver* I am trying to create proximity alerts for a few locations with the following code. I have searched for some time but there is no good answer to this question anywhere on the web. Thanks and Regards, Deepak -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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]Proximity Alerts in LocationManager not working as expected.
how many times do you intend to post the same question? 2011/7/28 deepak subramanian deepak.s...@gmail.com Hi everyone, I have an application which needs to call a new screen if it comes within the proximity of a few locations. So I am using the addProximityAlerts() function as follows: But this does not work at all. My code is shown below *public void setupLocationMonitoring(Intent newIntent) { for (int i = 0; i locations.size(); i++) { newIntent.putExtra(widgetId, i); newIntent.setAction(IntentAction); PendingIntent intent1= PendingIntent.getBroadcast(HaiMap.this, i, newIntent, PendingIntent.FLAG_CANCEL_CURRENT); double lati=(double) (locations.get(i).getLatitudeE6()) / 1E6; double longi =(double) (locations.get(i).getLongitudeE6()) / 1e6; lm.addProximityAlert(lati,longi,200,0, intent1); } } * The Manifest entry for the broadbase receiver which is supposed to receive the intents is as follows; * receiver android:name=com.deepak.sample.receiver.MyBroadCastReceiver intent-filter action android:name=com.deepak.sample.view.HaiMap.intentWiki/action /intent-filter /receiver* I am trying to create proximity alerts for a few locations with the following code. I have searched for some time but there is no good answer to this question anywhere on the web. Thanks and Regards, Deepak -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Game made with andengine has weird crashes.
Hi, I have made two versions of my desktop game on android using andengine. One uses a normal image background and the other has augmented reality as the background. The links to both the games are: https://market.android.com/details?id=com.raghavsood.speedball https://market.android.com/details?id=com.raghavsood.speedballar One common problem in both the games is that sometimes the moving ball disappears. This in itself does not cause a crash or anything like that but spoils the game as the ball is kind of the point. The next few problems are related only to the augmented reality one (link 2) 1) When the game is started sometimes it displays the ACRA toast saying my app has crashed but then continues straight on and opens the game which works fine. 2) Sometimes the game crashes on pressing the back button, opening it after pressing the home button. The two stacktraces below appear in both the problems. java.lang.RuntimeException: Fail to connect to camera service at android.hardware.Camera.native_setup(Native Method) at android.hardware.Camera.init(Camera.java:264) at android.hardware.Camera.open(Camera.java:239) at com.raghavsood.speedballar.CameraPreviewSurfaceView.surfaceCreated(CameraPreviewSurfaceView.java:45) at android.view.SurfaceView.updateWindow(SurfaceView.java:552) at android.view.SurfaceView.dispatchDraw(SurfaceView.java:350) at android.view.ViewGroup.drawChild(ViewGroup.java:1644) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1373) at android.view.View.draw(View.java:6883) at android.widget.FrameLayout.draw(FrameLayout.java:357) at android.view.ViewGroup.drawChild(ViewGroup.java:1646) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1373) at android.view.View.draw(View.java:6883) at android.widget.FrameLayout.draw(FrameLayout.java:357) at com.android.internal.policy.impl.PhoneWindow$DecorView.draw(PhoneWindow.java:1874) at android.view.ViewRoot.draw(ViewRoot.java:1524) at android.view.ViewRoot.performTraversals(ViewRoot.java:1260) at android.view.ViewRoot.handleMessage(ViewRoot.java:1861) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:123) at android.app.ActivityThread.main(ActivityThread.java:3729) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:507) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:874) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:632) at dalvik.system.NativeStart.main(Native Method) And java.lang.RuntimeException: setParameters failed at android.hardware.Camera.native_setParameters(Native Method) at android.hardware.Camera.setParameters(Camera.java:914) at com.raghavsood.speedballar.CameraPreviewSurfaceView.surfaceChanged(CameraPreviewSurfaceView.java:62) at android.view.SurfaceView.updateWindow(SurfaceView.java:549) at android.view.SurfaceView.dispatchDraw(SurfaceView.java:348) at android.view.ViewGroup.drawChild(ViewGroup.java:1644) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1373) at android.view.View.draw(View.java:6883) at android.widget.FrameLayout.draw(FrameLayout.java:357) at android.view.ViewGroup.drawChild(ViewGroup.java:1646) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:1373) at android.view.View.draw(View.java:6883) at android.widget.FrameLayout.draw(FrameLayout.java:357) at com.android.internal.policy.impl.PhoneWindow$DecorView.draw(PhoneWindow.java:1862) at android.view.ViewRoot.draw(ViewRoot.java:1522) at android.view.ViewRoot.performTraversals(ViewRoot.java:1258) at android.view.ViewRoot.handleMessage(ViewRoot.java:1859) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:130) at android.app.ActivityThread.main(ActivityThread.java:3683) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:507) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597) at dalvik.system.NativeStart.main(Native Method) CameraPreviewSurfaceView.java reads (Lines 62 and 45 from the above stacktraces are in bold.): package com.raghavsood.speedballar; import java.io.IOException; import org.anddev.andengine.util.Debug; import android.content.Context; import android.hardware.Camera; import android.view.SurfaceHolder; import android.view.SurfaceView; class CameraPreviewSurfaceView extends SurfaceView implements SurfaceHolder.Callback { private final SurfaceHolder mSurfaceHolder; private Camera mCamera; public CameraPreviewSurfaceView(final Context pContext) { super(pContext); this.mSurfaceHolder = this.getHolder(); this.mSurfaceHolder.addCallback(this); this.mSurfaceHolder.setType(SurfaceHolder.SURFACE_TYPE_PUSH_BUFFERS); } public void surfaceCreated(final SurfaceHolder pSurfaceHolder) { *this.mCamera =
[android-developers] Re: changing listview content in separate thread issue
On Jul 27, 7:07 am, Wall-E bashee...@gmail.com wrote: If anybody has any ideas on how to deal with this situation where the content of a listview is changing in another thread where I don't have access to the listview and need to notify the listview that the content has changed I'd appreciate your input. The description of your problem kind of sounds like a catch-22. Someone needs to tell a ListView something, yet they don't know what that ListView is. Does that sound problematic to you? At some point, the thing in your system that has updates for a list needs to notify the list itself. Usually, one would do this through the Adapter that backs the list. You'll need some sort of bridge between the two, perhaps a listener type interface or a broadcast. Doug -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] retrieve an object from another activity back
try using bundle put it in intent and use startActivityForResults() method... On Wed, Jul 27, 2011 at 1:26 PM, torr eceooz...@gmail.com wrote: I have a class called BookmarksStruct and a ArrayListBokmarksStruct typed object called bookmarksarray. I want to pass the object and get back again from second activity to the first activity but I can't find how can I retrieve the object back. Because there is only get methods for int string char etc. Can anyone help me? thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Call Background Service from Intent
Hi I have written an intent for Camera device, which will basically listen for snaps. If any new photo taken it will trigger my intent. I want to call a background service (which I have implemented already) from the intent to upload the file. How can bridge these two? Any samples or explanations would be appreciated. Thanks Siva -- - Prakash. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Curious NPE
On Jul 27, 6:35 pm, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Thu, Jul 28, 2011 at 3:35 AM, Doug beafd...@gmail.com wrote: On Jul 27, 1:25 am, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Wed, Jul 27, 2011 at 5:07 PM, Doug beafd...@gmail.com wrote: I see checked exceptions as a compile-time reminder that it's always a good idea to handle potential errors. This is almost exactly the same concept as diligently checking the return codes from C functions that can fail. I suppose if you are the kind of engineer that doesn't make a priority of checking return codes, then you probably also don't like Java forcing you to do something with potential error conditions. You are making too many assumptions, but have fun with it. I actually write all of my C code in a giant main() function and I never ever check return codes. I am that good. I pass around NULL pointers like crazy, but it's OK, because I'm a lucky guy. Satisfied? No, I'm not, because you're not using logic to address to issue at hand. If you are that kind of engineer (and I would argue that you are not actually an engineer), then don't use Java. Java is old. And because it's 'enterprise', it won't change much. Checked exceptions is not the only problem with it. So yes, when possible, I use more modern alternatives. Go on. I'm listening. Please don't just say do your own research or smart people write about this. The whole point is, that with checked exceptions you are forced to handle or re-throw/declare them even if you don't what to do that *in that particular part* of your code. Nobody is saying 'we will ignore all exceptions and keep our fingers crossed'. Truthfully, how often do you really NEED to ignore checked exceptions? It does come up, but not enough for me to get upset that I have to do it. For me, it's a few extra lines of code in a few places. Again, I never said ignore. I said 'don't handle in that particular place'. A few extra lines of code multiplied by a hundred places makes for a lot code bloat. Don't you just love it when you have to handle IOException when calling close()? Please answer my question above. How often? In my experience (16 years) it's not common enough to complain about. There are cases, yes, but only on shutdown/termination. I don't obsess on those cases. I do them one and be done with it. It takes at most 1 minute out of my day. If you can't spare that 1 minute, then don't use Java. We can go on forever, but there's not much point. Have fun with your exceptions. Please make a case for your alternative. I'm listening. Please make it relevant to Android development, considering the forum in which we're participating. If you have an axe to grind against Java as a language, I suggest you do it elsewhere. Doug -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Proximity Alerts in LocationManager not working as expected.
Its a pending intent in action :) The first few times I posted it never went through. Also, the fact remains that I am really stuck on this issue and the documentation is patchy on the addProximityAlert function. My apologies if it bothered ya but it would be great if you could also advise me on how to proceed. I wont send more on the same stuff. On Jul 28, 12:53 am, Francisco Dalla Rosa soares soa...@argo.bz wrote: how many times do you intend to post the same question? 2011/7/28 deepak subramanian deepak.s...@gmail.com Hi everyone, I have an application which needs to call a new screen if it comes within the proximity of a few locations. So I am using the addProximityAlerts() function as follows: But this does not work at all. My code is shown below *public void setupLocationMonitoring(Intent newIntent) { for (int i = 0; i locations.size(); i++) { newIntent.putExtra(widgetId, i); newIntent.setAction(IntentAction); PendingIntent intent1= PendingIntent.getBroadcast(HaiMap.this, i, newIntent, PendingIntent.FLAG_CANCEL_CURRENT); double lati=(double) (locations.get(i).getLatitudeE6()) / 1E6; double longi =(double) (locations.get(i).getLongitudeE6()) / 1e6; lm.addProximityAlert(lati,longi,200,0, intent1); } } * The Manifest entry for the broadbase receiver which is supposed to receive the intents is as follows; * receiver android:name=com.deepak.sample.receiver.MyBroadCastReceiver intent-filter action android:name=com.deepak.sample.view.HaiMap.intentWiki/action /intent-filter /receiver* I am trying to create proximity alerts for a few locations with the following code. I have searched for some time but there is no good answer to this question anywhere on the web. Thanks and Regards, Deepak -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 can we keep a particular application on the top always
Hi , I want to keep my application ( Application A ) on the top always in Android. Application A is not a full screen application, it is a floating window or dialog theme based application. The Application A can launch other application.\ from its own UI portion also other applications can be launched from background from Home screen shortcut / Application Launcher screen. How can we do it? Also the application which are in the background with Application A on top should work normally. e.g. it can Launch other activities (of it own own or some other application), dialog etc. Second doubt/ requirement is - Activity Y is below Activity X, Activity X is below Activity A (of Application A) . Activity X has a close/exit button which would finish its own activity X. Now when that button is pressed the activity get closed but leaves a black screen below activity A. Why does this happen (i think may be because it requires the Back stack to be rearranged) and is their a turn around way of being able to do this. If any application in the background launches another activity/ application then also my application ( Application A ) should come at the top of the launched activity/application. Thanks , Ankit -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: aapt problem!! /usr/lib/libz.so.1: no version information available
On Jul 26, 7:29 pm, sim yang vincentff...@gmail.com wrote: android-sdk-linux_x86/platform-tools/aapt: /usr/lib/libz.so.1: no version information available (required by /home/android/android-sdk- linux_x86/platform-tools/aapt) I am a new beginner in android. I am using a 64 centos in vmware and eclipse . I have searched on the Internet, and havan't found any conclusions. Can anyone help me ? At the end of your build, is there something not working? I think what you're seeing is just a warning and not a significant error. Doug -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Communication between android app and application on a remote server
Could anyone help me out with this? Thanks On Jul 25, 3:14 pm, work_84 work8...@gmail.com wrote: Hello, I am developing an Android application which has to send/receive data to/from a remote server securely. The Android application has to authenticate the server and the server needs to authenticate the device. The data sent/received should also be encrypted. I have implemented similar feature on desktop applications using OpenVPN and thrift(Since the server is in C++ and the client in java). I was planning to use the same on Android but am not sure if openvpn package is available to be used by android applications. Any suggestions on this will be very much helpful. 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: DategramSocket.receive returns after a long time
Have any relevant network bugs been reported for the device you are using? I have never seen such a failure on my G2. On Jul 27, 12:19 am, Heidi Zhou Nolan heidi.zhou.no...@qnective.com wrote: Yes, the application can receive the data well when the browser is not running. I wonder if I have to use native code for this. Now, I am using Java's DatagramSocket class. On Jul 26, 10:11 pm, Indicator Veritatis mej1...@yahoo.com wrote: Does your UDP receive code work fine if the browser is not running? On Jul 26, 4:52 am, Heidi Zhou Nolan heidi.zhou.no...@qnective.com wrote: I am implementing a UDP application on Android. The problem I have is that, on the sender side of the UDP connection, the sender sends around 2 packets every 40 milliseconds; the receiver side of the UDP connection uses java.net.DatagramSocket.receive(...) function to receive data over the network in a while loop. The receiver receives 2 packets roughly every 40 milliseconds. While our Android application is running, the internet browser is launched and start downloading/retrieving webpage. The receive(...) function won't return any data until the browser stop its downloading. I did a measurement that the receive(...) function returns data after almost 700 milliseconds. It seems that all the packets to our application are hold until the browser is done with its network activity. I am looking for the solution to still receive data over the network even there is other application sends or receive data over network at the same time. It would be better if the solution can make our application have higher priority in using the network. Thank you in advance for your 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 To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Update activity UI from service using observer pattern
I finally figured out the issue. For those who might encounter the same not to lose their time. The answer on my initial question is really YES, observer pattern works in decribed scenario with local binding to service which runs AsyncTasks. My problem happened because ListView calls getView() for each row twice when its layout_height=wrap_content. That is why really I've updated not the view that was shown. It took near 2 weeks to understand that problem is not in code! Phew! Tutorials I've found (including with help of this email list) do not explicitly state possible issue (and actually, I think, won't work just like mine if one changes layout_height) however they are of great help to understand how to work with ListView in android correctly to make use of its optimizations. Anyways, struggling with this simple problem I investigated implementation of ProgressBar, TextView, wrote several test apps, decompiled AndroidMarket app and read lots of stuff :) Useful links: http://android-developers.blogspot.com/2010/07/multithreading-for-performance.html http://codehenge.net/blog/2011/06/android-development-tutorial-asynchronous-lazy-loading-and-caching-of-listview-images/ http://developer.android.com/resources/articles/listview-backgrounds.html 2011/6/26 Vadim Khondar vadim.khon...@gmail.com: 2011/6/25 Kostya Vasilyev kmans...@gmail.com: Ok, here is that post: http://android-developers.blogspot.com/2010/07/multithreading-for-performance.html -- Kostya Thanks alot for that link! When all supposed keywords in google are exhausted without success considerable references are of great help. I'll investigate it asap. -- Best regards, Vadim God, grant me the serenity to accept the things I cannot change, courage to change the things I can, and wisdom always to tell the difference. Rainhold Niebuhr -- Best regards, Vadim God, grant me the serenity to accept the things I cannot change, courage to change the things I can, and wisdom always to tell the difference. Rainhold Niebuhr -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: google map marker
Hello Raghav, you cannot understand my words. first analyze other words what they are saying and their situation right? then you tell your own suggestion. otherwise dont tell this kind of blindly copy paste words. On 7/28/11, Raghav Sood raghavs...@gmail.com wrote: Android cannot give you an error of lines not supported. Did you try modifying the code to work with your project or did you just blindly copy paste? Did you change the variables and the XML files to the ones you have in your project? There are thousands of tutorials for this on the Internet. Google it. Thanks On Thu, Jul 28, 2011 at 10:35 AM, arun kumar hariarun2...@gmail.com wrote: abhishek can you send source code with xml file and android manifest file like project. because i try your coding its shows error.like some lines are not supported. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Raghav Sood http://www.raghavsood.com/ http://wiki.androidappcheck.com/ http://www.telstop.tel/ https://market.android.com/developer?pub=Appaholics -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: google map marker
I am not telling you to blindly copy paste. On the contrary I am telling you not to copy paste anything blindly. If you had bothered to read my mail properly you would have noticed that I asked you if you had changed the code given by Abhishek to be usable with your project. That is changed the variable names, changed the R.class references to what you are using. I also pointed out that if you Google this problem you will get many tutorials that clearly explain what you are trying to achieve. Thanks On Thu, Jul 28, 2011 at 3:17 PM, arun kumar hariarun2...@gmail.com wrote: Hello Raghav, you cannot understand my words. first analyze other words what they are saying and their situation right? then you tell your own suggestion. otherwise dont tell this kind of blindly copy paste words. On 7/28/11, Raghav Sood raghavs...@gmail.com wrote: Android cannot give you an error of lines not supported. Did you try modifying the code to work with your project or did you just blindly copy paste? Did you change the variables and the XML files to the ones you have in your project? There are thousands of tutorials for this on the Internet. Google it. Thanks On Thu, Jul 28, 2011 at 10:35 AM, arun kumar hariarun2...@gmail.com wrote: abhishek can you send source code with xml file and android manifest file like project. because i try your coding its shows error.like some lines are not supported. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Raghav Sood http://www.raghavsood.com/ http://wiki.androidappcheck.com/ http://www.telstop.tel/ https://market.android.com/developer?pub=Appaholics -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 -- Raghav Sood http://www.raghavsood.com/ http://wiki.androidappcheck.com/ http://www.telstop.tel/ https://market.android.com/developer?pub=Appaholics -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] ADT PluginURL isn't work
https://dl-ssl.google.com/android/eclipse/ The eclipse plugins isn't available. How to install it? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: google map marker
ya i change his code for my purpose. but got some error. i tried another code and i got multiple markers in google map. Thanks for your suggestion RAGAV. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] ADT PluginURL isn't work
http://developer.android.com/sdk/eclipse-adt.html#installing Scroll down to Troubleshooting ADT Installation. Thanks On Thu, Jul 28, 2011 at 3:40 PM, Clement Yuan spyworl...@gmail.com wrote: https://dl-ssl.google.com/android/eclipse/ The eclipse plugins isn't available. How to install it? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Raghav Sood http://www.raghavsood.com/ http://wiki.androidappcheck.com/ http://www.telstop.tel/ https://market.android.com/developer?pub=Appaholics -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Curious NPE
On Thu, Jul 28, 2011 at 5:29 PM, Doug beafd...@gmail.com wrote: On Jul 27, 6:35 pm, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Thu, Jul 28, 2011 at 3:35 AM, Doug beafd...@gmail.com wrote: On Jul 27, 1:25 am, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Wed, Jul 27, 2011 at 5:07 PM, Doug beafd...@gmail.com wrote: I see checked exceptions as a compile-time reminder that it's always a good idea to handle potential errors. This is almost exactly the same concept as diligently checking the return codes from C functions that can fail. I suppose if you are the kind of engineer that doesn't make a priority of checking return codes, then you probably also don't like Java forcing you to do something with potential error conditions. You are making too many assumptions, but have fun with it. I actually write all of my C code in a giant main() function and I never ever check return codes. I am that good. I pass around NULL pointers like crazy, but it's OK, because I'm a lucky guy. Satisfied? No, I'm not, because you're not using logic to address to issue at hand. Well, neither are you. You are assuming something I never said, and are building your 'case' from there. As you see, this doesn't work. Again, I never said ignore. I said 'don't handle in that particular place'. A few extra lines of code multiplied by a hundred places makes for a lot code bloat. Don't you just love it when you have to handle IOException when calling close()? Please answer my question above. How often? In my experience (16 years) it's not common enough to complain about. Pretty darn often. Every time you need to deal with file IO, connect to a database, or call a network service. Consider a simple data access interface. You might have a file implementation and a database implementation with the same interface. You can't exactly declare it to throw IOException *and* SQLException, but still want to make people handle the exceptions your implementation throws. So you invent a checked DataAccessException and declare it in your interface. You feel pretty satisfied about your abstraction. Then you implement it, wrapping your IOExceptions and SQLExceptions in the shiny new DataAccessException. People use your classes and need to handle errors at some point. But what does DataAccessException mean? Not much. So, they dig in, get the cause and go from there. Neither compiler checking, nor your design by contract have made people's life easier. Or say you need to implement a third party interface. Your implementation needs to use a file, but the interface doesn't declare an exception. You need to stick to the original interface's contract! So what do you do: log and swallow the exception? wrap in up in a RuntimeException? declare all interface methods to throw Exception? None of those are too good. And just the time spent considering it is wasted. You say there is value in checked exception: they force lazy programmer's to deal with errors; they make your contracts explicit; the compiler can check them for you. OK, maybe. But the problems they produce: breaking encapsulation, forcing people to write boilerplate code when they don't need to, making it hard to evolve your design, proliferating endless hierarchies/chains of Exceptions far outweigh the benefits. There are cases, yes, but only on shutdown/termination. I don't obsess on those cases. I do them one and be done with it. It takes at most 1 minute out of my day. If you can't spare that 1 minute, then don't use Java. See above. It's about writing less boilerplate code and being more productive. Multiply your one minute by the number of times you've had to deal with checked exceptions when you didn't really need or intend to, just because the language forces you to (in your long Java career), add in the time spent considering whether an Exception should be checked or unchecked; even the time spent in this thread, and you will see that you have wasted a lot of time. We can go on forever, but there's not much point. Have fun with your exceptions. Please make a case for your alternative. I'm listening. Please make it relevant to Android development, considering the forum in which we're participating. If you have an axe to grind against Java as a language, I suggest you do it elsewhere. I don't have an axe to grind. Java is a good language. Lots of good ideas in it. As for Android, it's a good fit for mobile development: it's widespread, it's fairly high level, but it still lets you get close to the metal when you need to (via JNI, which is a pain, but still); it has garbage collection. It is perfect: no. Is there any chance that the flaws will be fixed: no. Or it will take 5 to 10 years of going through JSR/JCP, corporate struggles and some lawsuits. Fortunately, people are building some really good things upon the JVM, so there are alternatives. To make the relevance to Android development blatantly explicit: those
[android-developers] How to set style attribute for progress bar programmatically?
Hi all, The default ProgressBar is white in color, which will not be visible on white background. So I needed a black progressbar in my application which I acheived by setting the style attribute (*progressBarStyleInverse*) in xml as given below: ProgressBar android:id=*@+id/progress_bar* android:layout_width=*wrap_content* android:layout_height=*wrap_content* android:layout_centerInParent=*true* style=*?android:attr/progressBarStyleInverse* / But I need to set the style attribute in my java code after this line. ProgressBar progressbar = *new* ProgressBar(context); Please help. Regards, Shruthi. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 set style attribute for progress bar programmatically?
You cannot change styles via Java code. You will need to examine what is defined in progressBarStyleInverse (e.g., background) and apply those individually. On Thu, Jul 28, 2011 at 7:03 AM, Shruthi Varma shruthi.tlis...@gmail.com wrote: Hi all, The default ProgressBar is white in color, which will not be visible on white background. So I needed a black progressbar in my application which I acheived by setting the style attribute (progressBarStyleInverse) in xml as given below: ProgressBar android:id=@+id/progress_bar android:layout_width=wrap_content android:layout_height=wrap_content android:layout_centerInParent=true style=?android:attr/progressBarStyleInverse / But I need to set the style attribute in my java code after this line. ProgressBar progressbar = new ProgressBar(context); Please help. Regards, Shruthi. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Training in NYC: http://marakana.com/training/android/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Problem with Layout with WEIGHT and VISIBILITY params
Hi there! I have a LinearLayout composed by 4 RelativeLayout. Every RelativeLayout has the weight params set in order to fill all the screen. All layouts are set as fill_parent for W and H. + LinearLayout + Relative 1 weight = 4 (visible) + Relative 2 weight = 5 (gone) + Relative 3 weight = 5 (visible) + Relative 4 weight = 5 (visible) I want to animate the Relative 3 and 4 and then hide them, so I set VISIBILITY.GONE when the animation ends. At this point I'd like to show the Relative 2, which was gone before, so I set it to VISIBLE So I get: + LinearLayout + Relative 1 weight = 4 (visible) + Relative 2 weight = 5 (visible) + Relative 3 weight = 5 (gone) + Relative 4 weight = 5 (gone) I expected that the dimensions didn't changed and that the Relative 2 substituted all the space covered by the others (3 and 4). Instead the Relative 1 changes its own height... I guess it depends on the weight params how to avoid it? Please help me... it's quite urgent! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Regarding google Map
Hi, I developed an application, which consists if map activity.When i run application it displayed map along with marker, but after when i run application its showing only the marker of current location but no map(displaying only tiles). So, please tell me the problem its important. Thanking you, Nagu. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 google Map
Either: -- you do not have the INTERNET permission, or -- your device or emulator does not have Internet access, or -- your API key is wrong On Thu, Jul 28, 2011 at 7:15 AM, nageswara rao rajana nagu.raj...@gmail.com wrote: Hi, I developed an application, which consists if map activity.When i run application it displayed map along with marker, but after when i run application its showing only the marker of current location but no map(displaying only tiles). So, please tell me the problem its important. Thanking you, Nagu. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Training in NYC: http://marakana.com/training/android/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 google Map
Hi, But it displaying the marker on map along with address, is it possible without internet. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 google Map
You need Internet access to download map tiles. If you need offline maps, you cannot use Google Maps -- take a look at Open Street Map. On Thu, Jul 28, 2011 at 7:21 AM, nageswara rao rajana nagu.raj...@gmail.com wrote: Hi, But it displaying the marker on map along with address, is it possible without internet. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Training in NYC: http://marakana.com/training/android/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: button id causes app to crash
I tried several different id names and none of them worked, but I just tried my app on a different computer and it worked fine with three button id's in the dialog (which is what crashed the emulator on my other one ). I will try to recreate the problem on the original computer and post the full log On Jul 27, 10:54 am, TreKing treking...@gmail.com wrote: On Wed, Jul 27, 2011 at 9:34 AM, DB12 daniel.burg...@gmail.com wrote: if im reading it correctly it says java.lang.ClassCastException: android.widget.button You want to just post the full stack trace you get? Particularly the part including and after the Caused by line. is there a limit to the amount of buttons you can have in a custom dialog? No and this does not indicate that would be the problem. Did you try a different id other than random? - TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago transit tracking app for Android-powered devices -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: ninepatch tool
HI converted the png image into nine patch image...but when i using the different screen sizes the image becoming blurred...(in all screen sizes the image should appear same) Thankyou in advance arun -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Openssl for Android (libssl.so and libcrypto.so)
Hi, http://android.git.kernel.org/?p=platform/external/openssl.git;a=summary this is the project that I'm using to try to create a libssl.so compatible with Qt necessitas target:Android Since I can't find a already compiled libssl and libcrypto to direct download... and adb pulling those files from a Android's /system/lib folder fixes the incompatible libssl.so and libssl.a erros when I - lssl in the .pro file on my project, but I still get erros like: release/isd_connection.o: In function `dsaKey::~dsaKey()': isd_connection.cpp:(.text._ZN6dsaKeyD1Ev[dsaKey::~dsaKey()]+0x16): undefined reference to `DSA_free' release/isd_connection.o: In function `privateDSAKey::privateDSAKey(QString const, QString const)': isd_connection.cpp: (.text._ZN13privateDSAKeyC1ERK7QStringS2_[privateDSAKey::privateDSAKey(QString const, QString const)]+0x54): undefined reference to `DSA_free' release/dsa_key.o: In function `~dsaKey': /home/hormonde/uni_net-student-android-tablet/uni_net-project/ staticlib-build-android/../staticlib/include/dsa_key.h:73: undefined reference to `DSA_free' /home/hormonde/uni_net-student-android-tablet/uni_net-project/ staticlib-build-android/../staticlib/include/dsa_key.h:73: undefined reference to `DSA_free' release/dsa_key.o: In function `createNewDSA()': /home/hormonde/uni_net-student-android-tablet/uni_net-project/ staticlib-build-android/../staticlib/src/dsa_key.cpp:684: undefined reference to `DSA_new' /home/hormonde/uni_net-student-android-tablet/uni_net-project/ staticlib-build-android/../staticlib/src/dsa_key.cpp:690: undefined reference to `BN_new' /home/hormonde/uni_net-student-android-tablet/uni_net-project/ staticlib-build-android/../staticlib/src/dsa_key.cpp:690: undefined reference to `BN_new' /home/hormonde/uni_net-student-android-tablet/uni_net-project/ staticlib-build-android/../staticlib/src/dsa_key.cpp:690: undefined reference to `BN_new' /home/hormonde/uni_net-student-android-tablet/uni_net-project/ staticlib-build-android/../staticlib/src/dsa_key.cpp:690: undefined reference to `BN_new' ... as I think it has to do with this similar issue as Ó.Egilsson on his last post: http://groups.google.com/group/android-ndk/browse_thread/thread/74cef4a7d6fec819/cce69b1d4e4dda49 which there errors are supposed to go away if the correct libs are linked... (as the same code runs perfectly on a linux version of the application) So can some one please help me out how to compile these libs? I don't have a clue on what configurations I need to change in order to make a successful build... I get stuck in step 3) and 4) of the read me file... 3) Run: ./import_openssl.sh import openssl-*.tar.gz 4) If there are any errors, then modify openssl.config, openssl.version and patches in patches/ as appropriate. You might want to use: ./import_openssl.sh regenerate patches/*.patch Repeat step 3. as well as I don't know what the commands on step 5) and 6) are... they aren't recognized by my console ( commands m and 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
Re: [android-developers] Regarding google Map
thank you, i have internet permissions, my issue is map is loading but very very slow is there any process to speed up the rendering of the map(using map cache etc,.) in my app. if there is any other possibility,please let me know. Awaiting for your reply. On Thu, Jul 28, 2011 at 4:58 PM, Mark Murphy mmur...@commonsware.comwrote: You need Internet access to download map tiles. If you need offline maps, you cannot use Google Maps -- take a look at Open Street Map. On Thu, Jul 28, 2011 at 7:21 AM, nageswara rao rajana nagu.raj...@gmail.com wrote: Hi, But it displaying the marker on map along with address, is it possible without internet. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Training in NYC: http://marakana.com/training/android/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Disable Specific Cell Boadcasts
Hi, I wish to disable Cell Broadcasts for Advertisements in my app. The ISms AIDL has the disableCellBroadcast with messageIdentifier as the parameter. I went through the 3GPP TS 23.041 doc and also searched the net but could not find Message Identifier for Advertisements. Can anyone help me with this one ? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 google Map
On Thu, Jul 28, 2011 at 7:36 AM, nageswara rao rajana nagu.raj...@gmail.com wrote: thank you, i have internet permissions, my issue is map is loading but very very slow is there any process to speed up the rendering of the map(using map cache etc,.) in my app. Not really. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Training in NYC: http://marakana.com/training/android/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: ninepatch tool
Did you define the stretchable areas correctly? On Thu, Jul 28, 2011 at 5:01 PM, arun kumar arun.kata...@gmail.com wrote: HI converted the png image into nine patch image...but when i using the different screen sizes the image becoming blurred...(in all screen sizes the image should appear same) Thankyou in advance arun -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Raghav Sood http://www.raghavsood.com/ http://wiki.androidappcheck.com/ http://www.telstop.tel/ https://market.android.com/developer?pub=Appaholics -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: The emulator died when I execute ping in adb shell repeatly
On Wednesday, July 27, 2011 7:57:30 AM UTC+1, nanhu wrote: when I execute ping -c 20 -i 0.2 -s 92 -W 1 www.google.com in adb shell repeatly , after dozens of times My advice: don't do that. String -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Is the screensaver in source code Launcher?
FYI, what you're calling a screensaver is actually the *lock screen*, I believe. I've never looked for its source myself, but knowing that might help you find it. String -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Programmatically find best-matching resource at runtime
Is it possible to find the best-matching resource Programmatically at run-time ? For example I have some device that have screen properties that makes perfect match for layout-normal-mdpi. How can I, at run time, read that specification ? For example for my screen the result should be normal screen size and for the density mdpi as perfect match. How can I read this matching at runtime ? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Listview with image, text and checkbox
I have done this with the help of a boolean arraylist maintaining the state of the check boxes On Wed, Jul 27, 2011 at 10:23 PM, Simon Platten simonaplat...@googlemail.com wrote: In a nutshell as was said by the last poster, the listview re-uses the same objects over and over for those items on view. In your adapter you can have an array which contains the entire content but you should be very careful that you aren't storing to much in this array, for example don't attempt to hold all your images in memory, chances are it will fail at some point. Below is a work in progress from my application, I've added a few more comments to make it a bit clearer whats going on: public View getView(int position, View convertView, ViewGroup parent) { View vi = convertView; try{ // Get a reference to the actual element from the big array, this array contains all the items that will be shown in the listview, but note the array only stores file names, not images imgFile objActual = m_aryImages.get(position); // This is a temporary reference that will be used to ref to the item on view from the list, this is not the same as objects in the array imgFile objOnView; if ( vi == null ) { // If we get here then this is the first time that this object has been created, each 'visible' item in the listview will get here. vi = m_layoutInfater.inflate(R.layout.lvimages, null); // Create a new object for this item, these are recycled when the listview is scrolled. objOnView = new imgFile(); // Set-up references to all the controls in the item objOnView.setThumbnail((ImageView)vi.findViewById(R.id.ivthumbNail)); objOnView.setUseCheckBox((CheckBox)vi.findViewById(R.id.chkUse)); objOnView.setCCWbutton((ImageButton)vi.findViewById(R.id.btnCCW)); objOnView.setCWbutton((ImageButton)vi.findViewById(R.id.btnCW)); // Add a reference to the object vi.setTag(objOnView); } else { // Get the object from the list view that we will recycle for the next view objOnView = (imgFile)vi.getTag(); } // In the temporary objects in the listview I store the actual LV index so I can compare before they get recycle, helps to transfer information back to the large array. int intArrayRef = objOnView.getLVindex(); if ( intArrayRef != imgFile.NO_REF intArrayRef m_aryImages.size() ) { // If we get here it means the object has been used before and is about to be recycled, so I transfer the information from the temporary object back into the array. imgFile objOriginal = m_aryImages.get(intArrayRef); objOriginal.setUse(objOnView.getUse()); objOriginal.setAngle(objOnView.getAngle()); } // Make sure the listview index is up to date for next time objOnView.setLVindex(position); // Get the properties of the actual array entry and populate the list view object String strFullPath = objActual.getFilename(); // Set-up the text view with just the file name String[] aryFile = uwrTabActivity.splitPath(strFullPath); if ( aryFile == null ) { throw new Exception( Cannot split image path! ); } // Transfer the data from the actual object to the object on view objOnView.setFilename(objActual.getFilename()); objOnView.setUse(objActual.getUse()); objOnView.setAngle(objActual.getAngle()); // Set-up the use check-box CheckBox cbUse = objOnView.getUseCheckBox(); cbUse.setText(aryFile[1]); cbUse.setChecked(objActual.getUse()); cbUse.setTag(objOnView); cbUse.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { CheckBox cb = (CheckBox)v; imgFile ii = (imgFile)v.getTag(); ii.setUse(cb.isChecked()); } }); // Set-up rotation buttons with listeners ImageButton btn = objOnView.getCCWbutton(); btn.setTag(objOnView); btn.setOnClickListener(new OnClickListener() { @Override public void onClick(View v) { ImageButton ibtn = (ImageButton)v; imgFile ii = (imgFile)ibtn.getTag(); ii.rotateThumbnail(imgFile.ROTATE_CCW); } }); btn = objOnView.getCWbutton(); btn.setTag(objOnView); btn.setOnClickListener(new
Re: [android-developers] Comments in market place
On Thu, Jul 28, 2011 at 03:46:32PM +0900, Nikolay Elenkov wrote: with the new Market client. Speaking of which, has anyone else had it force close on them? I got a notification that there were updates to install, and pressed that to go to the Market for the updates. Before I got that far (or was it just AFTER I got that far?), it force closed. Later, --jim -- 73 DE N5IAL (/4)MiSTie #49997 Running FreeBSD 7.0 spooky1...@gmail.com ICBM/Hurricane: 30.44406N 86.59909W Point Lobos Photography Set 1 (Photo-posters): http://jdgapps.com Do not look into laser with remaining eye! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Alert dialog shown but not visible
I have an activity where I start the built-in camera using onActivityResult. After taking a picture, I go back to my application and show a pop up asking to the user if he wants to take more pictures or no. It works fine, but after taking the picture, when I press the save button on the built-in camera app, and inmediatly I press the home button, If I go back to my application, my activity is visible but not active and the popup that should be visible is there but I cannot see it. If I press the back button and cancel the pop up, my activity is active again, but I dont want to allow the user cancelling the pop up, so I set my dialog not cancelable. Now, when this extrange behavior occurs, I cannot use my app, I just have to kill it... The question is, how can I force to the dialog being always on the top if it is shown? Cause seems like it is behind the activity, waiting for the user to interact with it... Thanks! PD: I also posted this question in StackOverflow: http://stackoverflow.com/questions/6858047/alert-dialog-shown-but-not-visible/6858112#comment-8156186 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Game made with andengine has weird crashes.
On Thu, Jul 28, 2011 at 08:15:03AM -0500, Jim Graham wrote: This sounds *VERY* familiar (back button, home button, force close). Correction: when I saw it, it was back button, force close. No home button. Sorry, just remembered that. Still, might be related and/or the same problem. Later, --jim -- 73 DE N5IAL (/4)| DMR: So fsck was originally called spooky1...@gmail.com| something else. Running FreeBSD 7.0 | Q: What was it called? ICBM / Hurricane: | DMR: Well, the second letter was different. 30.44406N 86.59909W |-- Dennis M. Ritchie, Usenix, June 1998. Point Lobos Photography Set 1 (Photo-posters): http://jdgapps.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] Game made with andengine has weird crashes.
On Thu, Jul 28, 2011 at 01:35:53PM +0530, Raghav Sood wrote: 2) Sometimes the game crashes on pressing the back button, opening it after pressing the home button. This sounds *VERY* familiar (back button, home button, force close). I saw this in one of the AndEngine demos. It's why I'd initially turned away from it. In my case, what fixed it was pulling the most recent AndEngine code via the Mercurial plugin in Eclipse. Then I built it all from there, and it ran flawlessly. So maybe you have the same downloaded version I'd started with Hope this helps. Later, --jim -- 73 DE N5IAL (/4)MiSTie #49997 Running FreeBSD 7.0 spooky1...@gmail.com ICBM/Hurricane: 30.44406N 86.59909W Point Lobos Photography Set 1 (Photo-posters): http://jdgapps.com 'Wrong' is one of those concepts that depends on witnesses. --Catbert: Evil Director of Human Resources (Dilbert, 05Nov09) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Game made with andengine has weird crashes.
Thanks Jim. the problem comes with three different button press opening app combinations but it never takes place every single time on a combination. 1) Back button pressed- Crash 2) Home button pressed. Another app opened. Open my app again-crash 3) Home button pressed. Open app - crash Sometimes the app crashes when you open it. In all cases except 1 the app shows the crash toast but works fine (in 1 you exit it anyways). Sometime though my ball sprite disappears.(And no it does not move of the screen. It simply vanishes.) Any help? There us a discussion for this on the AndEngine forums but nothing useful so far. http://www.andengine.org/forums/development/andengine-problems-in-production-games-t4243.html Thanks On Thu, Jul 28, 2011 at 6:47 PM, Jim Graham spooky1...@gmail.com wrote: On Thu, Jul 28, 2011 at 08:15:03AM -0500, Jim Graham wrote: This sounds *VERY* familiar (back button, home button, force close). Correction: when I saw it, it was back button, force close. No home button. Sorry, just remembered that. Still, might be related and/or the same problem. Later, --jim -- 73 DE N5IAL (/4)| DMR: So fsck was originally called spooky1...@gmail.com| something else. Running FreeBSD 7.0 | Q: What was it called? ICBM / Hurricane: | DMR: Well, the second letter was different. 30.44406N 86.59909W |-- Dennis M. Ritchie, Usenix, June 1998. Point Lobos Photography Set 1 (Photo-posters): http://jdgapps.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 -- Raghav Sood http://www.raghavsood.com/ http://wiki.androidappcheck.com/ http://www.telstop.tel/ https://market.android.com/developer?pub=Appaholics -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Aw: Re: [android-developers] Re: ninepatch tool
Have you tried the Gimp Tool? http://www.gimp.org/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: button id causes app to crash
On Wednesday, July 27, 2011 9:11:08 AM UTC-4, DB12 wrote: the app crashes when you try to load it, i don't even get to press the button that opens my custom dialog On Jul 22, 11:41 am, DB12 daniel@gmail.com wrote: Howdy, I searched for about 30 minutes to see if anyone had the same issue but couldn't find anything. I've had this happen before, typically when refactoring resources and such. Try to Clean your project and then rebuild it, what is happening here most likely is that R.java is not getting re-generated correctly so it is using the wrong identifier mapping for your button id. Another example of this type of behavior is when you see the wrong images being loaded right after you do some renaming of image resources. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Openssl for Android (libssl.so and libcrypto.so)
Nevermind step 3) and 4) I fixed it. If anyone gets this error follow http://www.openssl.org/news/secadv_20101116-2.txt and manually patch the ssl/t1_lib.c accordingly to your openssl version. Now the only thing that I can't overcome is the m and mm commands... :\ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Error in http request. Status:0
Hi All, I am getting this error (Error in http request. Status:0) when I am trying to load a url in webview in my application. Here is my code: webView.getSettings().setJavaScriptEnabled(true); webView.loadUrl(webUrl); webView.setWebChromeClient(new WebChromeClient() { public void onProgressChanged(WebView view, int progress) { progressbar.setProgress(progress); progressbar.setVisibility(View. VISIBLE); if(progress == 100) progressbar.setVisibility(View. INVISIBLE); } }); webView.setWebViewClient(new HelloWebViewClient()); webView.getSettings().setBuiltInZoomControls(true); webView.getSettings().setUseWideViewPort(true); webView.getSettings().setLoadWithOverviewMode(true); What am I supposed to do? Please help. Regards, Shruthi. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=enattachment: error.png
[android-developers] Static Initializers - interdependencies
What happens if I have two classes, each with some static variables, and some initializer in one class references a static variable in another class? the beginning of class A: public static ByteBuffer audioInByteBuffer = ByteBuffer.allocateDirect(Main.bytesPerBlock); and in the beginning of class Main: public static int samplesPerBlock=1024; Is it possible for the static initializers of class A to run before the static initializers of class Main, so that Main.bytesPerBlock is not defined at the time it is used in the initializer of audioInByteBuffer? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] WebView text selection and persistent highlighting dilemma
Hello All, I am working on a non-trivial epub format book reader project in 3.1+, implementing it within a WebView. I am stymied at the text selection/highlight phase (luckily ? I have many more operations to polish up and implement). I can , of course highlight text and use the Clipboard manager in it's intended role (copy/paste, et al). The problem is twofold when I attempt to enable persistent text highlighting within the WebView itself: 1) the ClipboardManager does not (currently) seem well-suited for this -- I have implemented the OnPrimaryClipChangedListener to capture the clipboard text and process it within my WebView, but, being that I cannot override the System Clipboard ActionBar menu, I receive the text as would any app, only upon clicking Copy etc... and the menu, though nice, is not ours. I have seen the results of polling the ClipboardManager.hasPrimaryClip() for it's text as well so I believe that path is doom-laden :) 2) I have attempted to use the ActionMode pattern, but overriding onDragEvent() within my WebView is non-responsive (as in it never fires) and gives me the dreaded Miss a drag as we are waiting for WebCore's response for touch down. -- as I am trying to control page turning/navigation within the WebView (javascript disables ontouch events) for the obvious reason that it is a book reader, not a webpage. As an aside, I notice that Google's flagship Books app, though pretty, also does not allow highlighting/text selection... with the splitting of images between pages, we were thinking it might be a WebView implementation as well -- just a slight beg for source code... only slight, really :) If it is not clear from the above, I am wondering how to get control of the ClipboardManager, or barring that (which I assume I cannot do as it is a System service), maybe someone can point me in the direction of a workaround for webcore so cruelly denying Java the ability to control the world. I am open to taking complete control of motion events if need be, but that is so demanding for such a seemingly simple task as this... I mean, really, Amazon does what we want to do in Kindle for Droid... :) Thanks for your time! Peace, 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] Date Picker using xml layout - problem in android app
On Thu, Jul 28, 2011 at 2:33 AM, Sivasankar K sivasanka...@greatinnovus.com wrote: When it appears in the app i want a particular date to be viewed, for example as 01 Jan 1950. Every time it opens it is showing the present date only. Are you setting the date to display ... ? In my dialog box i have a set and cancel buttons. The Cancel button cancels the dialog box where as when i click the Set button i want the current date to be stored to a String. OK. In another activity of my app in a custom dialog box i want to show a date picker only with the year columns, i dont need the date and month columns. How to get it, please help me friends Read the documentation for this widget. If there is no indication that you can remove those columns, use another widget that allows for single-value editing or make your own. It's not that hard. - TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago transit tracking app for Android-powered devices -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Hard Crash (Reboot) in 3.2
Our app, which works fine in 3.1 and earlier, has started experiencing a hard crash that cause our XOOM to reboot. Usually, when this happens, the logs disappear, but in a couple of cases, we've managed to catch the exception. Anybody have a clue what these logs might be trying to tell us? Crash 1: 07-21 16:52:29.050: INFO/dalvikvm(730): Jit: resizing JitTable from 4096 to 8192 07-21 16:59:26.740: INFO/DEBUG(85): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** 07-21 16:59:26.740: INFO/DEBUG(85): Build fingerprint: 'motorola/ tervigon/wingray:3.2/HTJ85B/140714:user/release-keys' 07-21 16:59:26.740: INFO/DEBUG(85): pid: 144, tid: 264 system_server 07-21 16:59:26.740: INFO/DEBUG(85): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr afa0be00 07-21 16:59:26.740: INFO/DEBUG(85): r0 0050 r1 0014 r2 0001 r3 0022c298 07-21 16:59:26.740: INFO/DEBUG(85): r4 0022c298 r5 r6 0001 r7 0001 07-21 16:59:26.740: INFO/DEBUG(85): r8 0001 r9 0022c264 10 a7d45252 fp 0096 07-21 16:59:26.740: INFO/DEBUG(85): ip a7d47f44 sp 5bff98c8 lr a7d3ced3 pc afa0be00 cpsr 0010 07-21 16:59:26.740: INFO/DEBUG(85): d0 3f003f80 d1 3ff0 07-21 16:59:26.740: INFO/DEBUG(85): d2 3ff0 d3 4085e000 07-21 16:59:26.740: INFO/DEBUG(85): d4 401c d5 4059 07-21 16:59:26.740: INFO/DEBUG(85): d6 43e0 d7 3f803f80 07-21 16:59:26.740: INFO/DEBUG(85): d8 d9 07-21 16:59:26.740: INFO/DEBUG(85): d10 d11 07-21 16:59:26.740: INFO/DEBUG(85): d12 d13 07-21 16:59:26.740: INFO/DEBUG(85): d14 d15 07-21 16:59:26.740: INFO/DEBUG(85): scr 2012 07-21 16:59:26.920: INFO/DEBUG(85): #00 pc afa0be00 07-21 16:59:26.920: INFO/DEBUG(85): #01 pc 0001ded0 /system/ lib/libutils.so (_ZNK7android10VectorImpl8capacityEv) 07-21 16:59:26.920: INFO/DEBUG(85): #02 pc 0001e1fc /system/ lib/libutils.so (_ZN7android10VectorImpl5_growEjj) 07-21 16:59:26.920: INFO/DEBUG(85): #03 pc 0001e2de /system/ lib/libutils.so (_ZN7android10VectorImpl8insertAtEPKvjj) 07-21 16:59:26.920: INFO/DEBUG(85): #04 pc 0001e316 /system/ lib/libutils.so (_ZN7android10VectorImpl3addEPKv) 07-21 16:59:26.920: INFO/DEBUG(85): #05 pc 0002240a /system/ lib/libutils.so (_ZN7android6Looper12pushResponseEiRKNS0_7RequestE) 07-21 16:59:26.920: INFO/DEBUG(85): #06 pc 000226b6 /system/ lib/libutils.so (_ZN7android6Looper9pollInnerEi) 07-21 16:59:26.920: INFO/DEBUG(85): #07 pc 00022822 /system/ lib/libutils.so (_ZN7android6Looper8pollOnceEiPiS1_PPv) 07-21 16:59:26.930: INFO/DEBUG(85): #08 pc c19c /system/ lib/libgui.so (_ZNK7android16SensorEventQueue12waitForEventEv) 07-21 16:59:26.930: INFO/DEBUG(85): #09 pc 00063d00 /system/ lib/libandroid_runtime.so 07-21 16:59:26.930: INFO/DEBUG(85): libc base address: afc1f000 07-21 16:59:26.930: INFO/DEBUG(85): code around pc: 07-21 16:59:26.930: INFO/DEBUG(85): afa0bde0 07-21 16:59:26.930: INFO/DEBUG(85): afa0bdf0 07-21 16:59:26.930: INFO/DEBUG(85): afa0be00 07-21 16:59:26.930: INFO/DEBUG(85): afa0be10 07-21 16:59:26.930: INFO/DEBUG(85): afa0be20 07-21 16:59:26.930: INFO/DEBUG(85): code around lr: 07-21 16:59:26.930: INFO/DEBUG(85): a7d3ceb0 60046083 bf00bd10 af7e ffc8 07-21 16:59:26.930: INFO/DEBUG(85): a7d3cec0 4603b510 b1206840 0c0cf850 f7f36919 07-21 16:59:26.930: INFO/DEBUG(85): a7d3ced0 bd10e9f4 4790b510 bf00bd10 b90b6843 07-21 16:59:26.930: INFO/DEBUG(85): a7d3cee0 e0024618 fb006900 47703001 b51068c3 07-21 16:59:26.930: INFO/DEBUG(85): a7d3cef0 d402079b 68db6803 bd104798 4c05b570 07-21 16:59:26.930: INFO/DEBUG(85): stack: 07-21 16:59:26.930: INFO/DEBUG(85): 5bff9888 a7d450b0 /system/ lib/libutils.so 07-21 16:59:26.930: INFO/DEBUG(85): 5bff988c a7d3d31b /system/ lib/libutils.so 07-21 16:59:26.930: INFO/DEBUG(85): 5bff9890 5bff98a0 07-21 16:59:26.930: INFO/DEBUG(85): 5bff9894 a7d4140f /system/ lib/libutils.so 07-21 16:59:26.930: INFO/DEBUG(85): 5bff9898 07-21 16:59:26.930: INFO/DEBUG(85): 5bff989c 0002 07-21 16:59:26.930: INFO/DEBUG(85): 5bff98a0 003b80b0 07-21 16:59:26.930: INFO/DEBUG(85): 5bff98a4 07-21 16:59:26.930: INFO/DEBUG(85): 5bff98a8 003b80b8 07-21 16:59:26.930: INFO/DEBUG(85): 5bff98ac 80d0 /system/ bin/app_process 07-21 16:59:26.930: INFO/DEBUG(85): 5bff98b0 07-21 16:59:26.930: INFO/DEBUG(85): 5bff98b4 0014 07-21 16:59:26.930: INFO/DEBUG(85): 5bff98b8 80d0 /system/ bin/app_process 07-21 16:59:26.930: INFO/DEBUG(85): 5bff98bc 0001 07-21
Re: [android-developers] Static Initializers - interdependencies
On 28 July 2011 15:51, RLScott fixthatpi...@yahoo.com wrote: What happens if I have two classes, each with some static variables, and some initializer in one class references a static variable in another class? the beginning of class A: public static ByteBuffer audioInByteBuffer = ByteBuffer.allocateDirect(Main.bytesPerBlock); and in the beginning of class Main: public static int samplesPerBlock=1024; Is it possible for the static initializers of class A to run before the static initializers of class Main, so that Main.bytesPerBlock is not defined at the time it is used in the initializer of audioInByteBuffer? No. The static initialisation of class A references class Main. This means that initialisation of class A will cause class Main to load, which in turn will run its initialisers. -- Daniel Drozdzewski -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 gridview troubles
Hi. have some troubles with GridView. after populate grid - height of each cell isn't actual Here google do not allow post this question (very long?) . See please on stackoverflow: http://stackoverflow.com/questions/6861445/android-gridview-troubles Can anybody 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 To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Installation: Separated Client and Service
Hello, We have an application that consists of a UI and a download-service that downloads content. In the future, we would like to: 1. Share our download-service with other applications 2. Offer various branded and customised versions of the client [Would appear as separate downloads in the Android store] We would like all clients running on the phone to share the download- service. Android is designed to facilitate thisBUT If we create 2 package files. How do we handle installations? Scenario 1: New User A new user (without the download-service) installs the client from the Android market. How do we seamlessly accomplish the install? (Avoid them installing each package separately) Scenario 2: A user with the download-service already installed downloads another client. How do we detect that the service is already installed? Does anyone have any suggestions to simplify the installation process? Thanks, Glen -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Why up-scaling a smaller image into an ImageView does not work?
I think it's because you have android:layout_height=wrap_content. Try android:layout_height=200dp. On 23 Juli, 15:56, tiba till.baumgaer...@googlemail.com wrote: Hey all, does anybody have a clue what I do wrong? There's an image guy.png size 50x50 pixels and I'd like to get this up-scaled. Just for reasons of testing I tried to get it fitted with aspect ratio maintained into an ImageView of 200dip(!) height like this: ImageView android:minHeight=200dip android:layout_width=fill_parent android:src=@drawable/guy android:layout_below=@+id/txt_title android:layout_height=wrap_content android:id=@+id/img_guy android:scaleType=centerInside /ImageView But that just won't work. The image does not grow larger. The maximum size is the original image size. Does somebody know why? Thanks in advance, till -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Static Initializers - interdependencies
On Jul 28, 10:26 am, Daniel Drozdzewski daniel.drozdzew...@gmail.com wrote: No. The static initialisation of class A references class Main. This means that initialisation of class A will cause class Main to load, which in turn will run its initialisers. And what if class Main happens to have static initializers that reference some class A static variable. Then the references become circular. How is that resolved? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Programmatically find best-matching resource at runtime
On Thu, Jul 28, 2011 at 7:08 AM, Petko Petkov krstekr...@gmail.com wrote: Is it possible to find the best-matching resource Programmatically at run-time ? This is something the platform does for you if you lay your resources out right. - TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago transit tracking app for Android-powered devices -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Installation: Separated Client and Service
On Thu, Jul 28, 2011 at 10:31 AM, Glen Cook glenandr...@googlemail.comwrote: Scenario 1: New User A new user (without the download-service) installs the client from the Android market. How do we seamlessly accomplish the install? (Avoid them installing each package separately) You don't - they would have to install the separate package separately. Scenario 2: A user with the download-service already installed downloads another client. How do we detect that the service is already installed? PackageManager. - TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago transit tracking app for Android-powered devices -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] getExternalFilesDir() on Acer Iconia Tab A500
I am getting some error reports that indicate that getExternalFilesDir() is returning null on A500 with 3.1. Anyone having similar issues? From what I understand, external storage on the A500 is simulated, so it can't really be unmounted. Plus I'm checking this, and the environment is as below: getDataDirectory=/data getDownloadCacheDirectory=/cache getExternalStorageAndroidDataDir=/mnt/sdcard/Android/data getExternalStorageDirectory=/mnt/sdcard getExternalStorageState=mounted getRootDirectory=/system getSecondVolumeStorageDirectory=/mnt/external_sd getSecondVolumeStorageState=removed getSecureDataDirectory=/data getSystemSecureDirectory=/data/system getThirdVolumeStorageDirectory=/mnt/usb_storage getThirdVolumeStorageState=removed isEncryptedFilesystemEnabled=false isExternalStorageEmulated=true isExternalStorageRemovable=false BTW, getThirdVolumeStorageDirectory()? That's doesn't seem to be in the API. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Openssl for Android (libssl.so and libcrypto.so)
Nevermind step 3) and 4) I fixed it. If anyone gets this error follow http://www.openssl.org/news/secadv_20101116-2.txt and manually patch the ssl/t1_lib.c accordingly to your openssl version. Now the only thing that I can't overcome is the m and mm commands... : \ as in: 5) Cleanup before building with: m -j16 clean-libcrypto clean-libssl clean-openssl clean-ssltest 6) Build openssl from the external/openssl directory with: mm -j16 snod adb sync system If there are build errors, then patches/*.mk, openssl.config, or android-config.mk may need updating. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Static Initializers - interdependencies
I would say, try it out :) You can set breakpoints/System.out.println-s inside static-initializer blocks: class A { static final Integer TEST_A_INT; static { TEST_A_INT = new Integer(B.TEST_B_STRING); } } class B { static final String TEST_B_STRING; static final Integer TEST_B_INT; static { TEST_B_INT= A.TEST_A_INT; TEST_B_STRING = new String(3004); } } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Inflated Window has unwanted background
Have you tested this on a device as well as on the emulator? Do you get the same problem in both? On 26 Juli, 06:30, Skyre ksmic...@gmail.com wrote: In one spot of my app, I use a LayoutInflater to create a little settings window. On versions of Android prior to Gingerbread this works beautifully, but on Gingerbread there is an unsightly black background shown behind the XML view. It seems to be like a base context menu background or something, but I cannot for the life of me figure out how to get rid of it, as it really makes things look bad. I figured if I set the window to wrap_content that it would just shrink down to the size of the XML and be fine, but it is still slightly bigger on the Y, and stretches all the way across the screen on the X. Even if I set the size to exact pixel values, or ones based on the pixel width/height of the screen, you can still see the black background, and if I do that it also does this weird graphical glitch on the side that makes it look even worse. If somebody knows of a simple solution to this I'd be really grateful to hear it. Ideally I'd like to fix it without ruining the current setup, since it works perfect with older versions, but I'll do whatever has to be done to get it done right. Thank you. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Static Initializers - interdependencies
On 28 July 2011 16:45, RLScott fixthatpi...@yahoo.com wrote: On Jul 28, 10:26 am, Daniel Drozdzewski daniel.drozdzew...@gmail.com wrote: No. The static initialisation of class A references class Main. This means that initialisation of class A will cause class Main to load, which in turn will run its initialisers. And what if class Main happens to have static initializers that reference some class A static variable. Then the references become circular. How is that resolved? Not allowed... http://java.sun.com/docs/books/jls/third_edition/html/execution.html#44557 have a read... There is this paragraph: ' The static initializers and class variable initializers are executed in textual order, and may not refer to class variables declared in the class whose declarations appear textually after the use, even though these class variables are in scope (§8.3.2.3). This restriction is designed to detect, at compile time, most circular or otherwise malformed initializations.' Daniel -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Curious NPE
Doug, may I point you to the JPA API, made by Gavin King and approved by the JCP, it's based on unchecked exceptions. Also you can read Clean Code, A Handbook of Agile Software Craftmanship by Robert C. Martin he talks about the bennefits of using unchecked exceptions over checked. I agree with you, this flame war is losing sense, also the original poster dissapeared years ago. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: How to add header in ListFragment?
You can supply your own XML including a ListView. From the documentation of ListFragment: ListFragment has a default layout that consists of a single list view. However, if you desire, you can customize the fragment layout by returning your own view hierarchy from onCreateView(LayoutInflater, ViewGroup, Bundle). To do this, your view hierarchy must contain a ListView object with the id @android:id/list (or list if it's in code) This is quite similar to how you do for a ListActivity. Another option is to skip the ListFragment and use a ListView directly instead. You only need to use ListFragment if the same list (and related logic) should be displayed in two different activities. On 24 Juli, 14:33, vovs vov...@gmail.com wrote: I have some fragment(see below code). In this fragment i populate ListView. I have Categories and feeds. I want to create header to my ListView which will be always on top and don't hide when scrolling. This header will show Category name. Or how can I add staticview(TextView) and below it add list? Can anybody help me? public class FeedsListForViewFragment extends ListFragment { private Context mContext; ListFeedItem items; private int layoutForList = R.layout.list_feeds_simple; private ActiveRecordBase _db; private Activity mActivity; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); mActivity = getActivity(); _db = ((JtjApplication)getActivity().getApplication()).getDatabase(); try { _db.open(); } catch (ActiveRecordException e) { e.printStackTrace(); } } public void setItemsToList(ListFeedItem items, int curPosition) { mContext = getActivity().getApplicationContext(); this.items = items; ListView lv = getListView(); setListAdapter(new ListOfFeedsAdapter(mContext, layoutForList, items, mActivity)); lv.setChoiceMode(ListView.CHOICE_MODE_SINGLE); lv.setCacheColorHint(Color.WHITE); setPosition(curPosition); } @Override public void onListItemClick(ListView l, View v, int position, long id) { super.onListItemClick(l, v, position, id); if (!(((FeedsActivity) getActivity()).getCurrentPosition() == position)) { updateUnreadItemsInDb(position); updateLinksList(position, items.get(position)); ((FeedsActivity) getActivity()).setCurrentPosition(position); } } @SuppressWarnings(unchecked) private void updateUnreadItemsInDb(int position) { FeedItem feed = items.get(position); if (feed.isRead != true) { ListFeedItem feedsForUpdate = null; ListFeedType lft = null; try { feedsForUpdate = _db.find(FeedItem.class, false, GUID=?, new String[] { String.valueOf(feed.guid) }, null, null, PUBLICATIONDATE DESC, null); lft = _db.findAll(FeedType.class); } catch (ActiveRecordException e1) { e1.printStackTrace(); } for (FeedItem curFeed:feedsForUpdate) { curFeed.isRead = true; try { curFeed.save(); FeedType ft = lft.get(Integer.parseInt(curFeed.channel_id) - 1); ft.unread_count = ft.unread_count - 1; ft.update(); } catch (ActiveRecordException e) { e.printStackTrace(); } } items.get(position).isRead = true; ((ArrayAdapterFeedItem) getListView().getAdapter()).notifyDataSetChanged(); } } private void setPosition(int position) { ListView lv = getListView(); lv.setSelection(position); lv.setItemChecked(position, true); try{ updateLinksList(position, items.get(position)); } catch (IndexOutOfBoundsException e) { e.printStackTrace(); } } private void updateLinksList(int position, FeedItem feedItem) { FeedsViewFragment viewFragment = (FeedsViewFragment) getFragmentManager().findFragmentById(R.id.feed_view_fragment); viewFragment.setViewItem(feedItem); } } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: How to add header in ListFragment?
On Thu, Jul 28, 2011 at 12:26 PM, nadam a...@anyro.se wrote: Another option is to skip the ListFragment and use a ListView directly instead. You only need to use ListFragment if the same list (and related logic) should be displayed in two different activities. Or if the list needs to be a Fragment for other reasons (e.g., to participate in the tab navigation in the action bar). Right now, there are few of these, but I suspect that there will be more of those Fragment dependencies in the future. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Training in NYC: http://marakana.com/training/android/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Is there a way to display fragments in TabHost?
I think you should go with option B. Why do you need to access the original parent Activity? On 26 Juli, 11:13, Zsombor scythe...@gmail.com wrote: I'd like to show a different fragment in a TabHost, for every tab. But it seems that there's no easy way to do this. TabHost can only accept A. Views or B. Intents that launch Activities when the user selects a tab. Going with A means that I have to initialize every fragment and load them into container Views that are given to the TabHost. But I want these fragments to load only when needed - when the user selects their tab that is. Going with B means that I load the fragments into separate Activities for each tab. But I'd like the fragment to be able to reach the original parent Activity, not just some shell Activity that hosts them in a tab content. Am I missing something? Is there a way to manage fragments with TabHost properly? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 force restart activity from intent
Just override onNewIntent(). http://developer.android.com/reference/android/app/Activity.html#onNewIntent(android.content.Intent) On 26 Juli, 11:01, jjoe64 g.jjo...@googlemail.com wrote: hello. my MainActivity has the lauchMode=singleTask now I want to start the activity from a notification with special intent data. in MainActivity#onResume I access the given intent data... the problem is: When the activity already exists, and I click on the notification, the activity comes to foreground, but the method #onResume is not called and I cannot access the intent data. I tried the flag FLAG_ACTIVITY_CLEAR_TASK and this works for honeycomb but not for gingerbread. This is how I start the activity from notification: Intent intent = new Intent(); intent.setClass(this, MainActivity.class); intent.putExtra(triggerid, triggerid); startActivity(intent); -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: The emulator died when I execute ping in adb shell repeatly
I was tempted to answer his first post that way, but I refrained. Why did you cave in?;) Seriously: he probably simply shouldn't do that, since, among other reasons, Google does not have any implicit responsibility to reply to such pings, but I am not too surprised he thinks it is a bug. On Jul 28, 4:58 am, String sterling.ud...@googlemail.com wrote: On Wednesday, July 27, 2011 7:57:30 AM UTC+1, nanhu wrote: when I execute ping -c 20 -i 0.2 -s 92 -W 1www.google.com in adb shell repeatly , after dozens of times My advice: don't do that. String -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: changing listview content in separate thread issue
Doug, I currently do send a broadcast that notifies that data has been changed which in the receiver I notify the ListView/Adapter but obviously that didn't work since I still get the IllegalStateException. I'm guessing that it's critical that the listview be immediately notified and the broadcast doesn't satisfy that immediate notification requirement. On Jul 28, 4:15 am, Doug beafd...@gmail.com wrote: On Jul 27, 7:07 am, Wall-E bashee...@gmail.com wrote: If anybody has any ideas on how to deal with this situation where the content of a listview is changing in another thread where I don't have access to the listview and need to notify the listview that the content has changed I'd appreciate your input. The description of your problem kind of sounds like a catch-22. Someone needs to tell a ListView something, yet they don't know what that ListView is. Does that sound problematic to you? At some point, the thing in your system that has updates for a list needs to notify the list itself. Usually, one would do this through the Adapter that backs the list. You'll need some sort of bridge between the two, perhaps a listener type interface or a broadcast. Doug -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Is there a way to display fragments in TabHost?
On Tue, Jul 26, 2011 at 6:13 PM, Zsombor scythe...@gmail.com wrote: I'd like to show a different fragment in a TabHost, for every tab. But it seems that there's no easy way to do this. TabHost can only accept A. Views or B. Intents that launch Activities when the user selects a tab. The compatibility library has a sample of how to do this. I didn't have time to look at in detail, but apparently it's sort of a hack. It does work though. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Curious NPE
You and William F. misunderstood Nikolay: he did NOT say don't use exceptions; they are a bad idea. He said it was the DISTINCTION between 'checked' and 'unchecked' exceptions that is botched. He is not alone in this claim, he is in good company. Even the deservedly famous Java expert, author and teacher Bruce Eckel says something very similar, saying, It has been an experiment, which no language since has chosen to duplicate. He goes on to explain why the idea looks good in small examples, but in larger programs it introduces more problems than it solves (Thinking in Java 3rd ed, chapter 9). But by no means is he against using exceptions. He is only against the misuse of them that the distinction encourages, e.g., subverting the exception handling mechanism by writing 'spurious' code to suppress exceptions. On Jul 25, 11:23 pm, Zsolt Vasvari zvasv...@gmail.com wrote: A checked exception is an exceptional state that you expect to happen, like the user entering some wrong values, you check that ant throw the ckecked exception. No, exceptions shouldn't be used as a program flow control mechanism, which is what your example is. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Curious NPE
I don't think you are listening. He gave you the links, read them. On Jul 28, 1:29 am, Doug beafd...@gmail.com wrote: On Jul 27, 6:35 pm, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Thu, Jul 28, 2011 at 3:35 AM, Doug beafd...@gmail.com wrote: On Jul 27, 1:25 am, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Wed, Jul 27, 2011 at 5:07 PM, Doug beafd...@gmail.com wrote: I see checked exceptions as a compile-time reminder that it's always a good idea to handle potential errors. This is almost exactly the same concept as diligently checking the return codes from C functions that can fail. I suppose if you are the kind of engineer that doesn't make a priority of checking return codes, then you probably also don't like Java forcing you to do something with potential error conditions. You are making too many assumptions, but have fun with it. I actually write all of my C code in a giant main() function and I never ever check return codes. I am that good. I pass around NULL pointers like crazy, but it's OK, because I'm a lucky guy. Satisfied? No, I'm not, because you're not using logic to address to issue at hand. If you are that kind of engineer (and I would argue that you are not actually an engineer), then don't use Java. Java is old. And because it's 'enterprise', it won't change much. Checked exceptions is not the only problem with it. So yes, when possible, I use more modern alternatives. Go on. I'm listening. Please don't just say do your own research or smart people write about this. The whole point is, that with checked exceptions you are forced to handle or re-throw/declare them even if you don't what to do that *in that particular part* of your code. Nobody is saying 'we will ignore all exceptions and keep our fingers crossed'. Truthfully, how often do you really NEED to ignore checked exceptions? It does come up, but not enough for me to get upset that I have to do it. For me, it's a few extra lines of code in a few places. Again, I never said ignore. I said 'don't handle in that particular place'. A few extra lines of code multiplied by a hundred places makes for a lot code bloat. Don't you just love it when you have to handle IOException when calling close()? Please answer my question above. How often? In my experience (16 years) it's not common enough to complain about. There are cases, yes, but only on shutdown/termination. I don't obsess on those cases. I do them one and be done with it. It takes at most 1 minute out of my day. If you can't spare that 1 minute, then don't use Java. We can go on forever, but there's not much point. Have fun with your exceptions. Please make a case for your alternative. I'm listening. Please make it relevant to Android development, considering the forum in which we're participating. If you have an axe to grind against Java as a language, I suggest you do it elsewhere. Doug -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: No error notification for basic errors. (bad Wifi password, ext4 formatted SD card).
Shouldn't the UI provide error notification? On Jul 25, 10:15 am, Nikolay Elenkov nikolay.elen...@gmail.com wrote: You should complain to whoever sold you your phone, not here. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Hard Crash (Reboot) in 3.2
On Thursday, July 28, 2011 11:21:18 AM UTC-4, Joshua Smith wrote: Our app, which works fine in 3.1 and earlier, has started experiencing a hard crash that cause our XOOM to reboot. Kernel reboot, or android runtime restart? You can tell the difference soon thereafter from cat /proc/uptime or (if present) the uptime command at the adb shell -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Project setup question, android library
Anyone? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] About Messaging in Android Phones
Hi, I am developing a input system to the Android devices. I want to show Unicode characters when I type in the text box. I started to build my system by using the Sample Keyboard which given in the sample folder. I can see only boxes. I know if I can install unicode font then I can see the characters. But still I could not find any solution for that. Could you please tell me how to install a font to the android emulator. Other thing is I am using Eclipse for development. When I type characters in the text box in the emulator can i synchronize emulator and the eclipe editor and show those characters in the eclipse editor. I need this to check the characters typed correct. Thank you. Randil -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Project setup question, android library
On Wed, Jul 27, 2011 at 11:28 PM, dnkoutso dnkou...@gmail.com wrote: Suggestions? Try it and see what happens. - TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago transit tracking app for Android-powered devices -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Inflated Window has unwanted background
Yes, sorry for forgetting to include that information. I have tested both on the emulator, as well as my 2.3.3 Droid X device, and both have the same issue. On Jul 28, 11:12 am, nadam a...@anyro.se wrote: Have you tested this on a device as well as on the emulator? Do you get the same problem in both? On 26 Juli, 06:30, Skyre ksmic...@gmail.com wrote: In one spot of my app, I use aLayoutInflaterto create a little settings window. On versions of Android prior to Gingerbread this works beautifully, but on Gingerbread there is an unsightly black background shown behind the XML view. It seems to be like a base context menu background or something, but I cannot for the life of me figure out how to get rid of it, as it really makes things look bad. I figured if I set the window to wrap_content that it would just shrink down to the size of the XML and be fine, but it is still slightly bigger on the Y, and stretches all the way across the screen on the X. Even if I set the size to exact pixel values, or ones based on the pixel width/height of the screen, you can still see the black background, and if I do that it also does this weird graphical glitch on the side that makes it look even worse. If somebody knows of a simple solution to this I'd be really grateful to hear it. Ideally I'd like to fix it without ruining the current setup, since it works perfect with older versions, but I'll do whatever has to be done to get it done right. Thank you. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] paused activity
I have an application with 3 activities, which i will call A, B and C. The activities fire in sequence A-B-C, with each previous activity being paused. My question is, how do i go from the C activity back to the A activity, without going to the B activity first, i.e. C-A? Finish() will only bring me back to the previous activity and i do not wish to use an intent to restart the A activity. Any ideas? Ab -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] postInvalidate
Hi Does postInvalidate guarantee that View's onDraw() method will be called? I call view.postInvalidate() every second and few minutes it works fine. I've added Log.d flag in onDraw() and I see that onDraw is called every time. But after a few minutes (there's no fixed time value) it stops working... I don't see Log.d output from onDraw() method. Any ideas? Thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Soft Keyboard appears when entering on an Activity
There you go, https://github.com/fr4gus/AndroidSoftKeyboardBug I uploaded a really simple project, in case someone wants to test it on their devices :D -f4 On Jul 5, 2:47 pm, fr4gus fggar...@gmail.com wrote: Thank you all, and setting windowSoftInputModem stateHidden solves the problem. I'm still wondering why we should explicitly set this value, is this a bug? Kind regards, -f4 On Jul 4, 2:35 pm, fr4gus fggar...@gmail.com wrote: I'm able to replicate a unusual issue with EditText. But it doesn't happen on all devices. Let's say you have the following layout: ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/ android android:layout_width=fill_parent android:layout_height=fill_parent !-- ScrollView, GridView, etc also causes this. -- ListView android:id=@+id/listView1 android:layout_width=match_parent android:layout_height=wrap_content android:layout_alignParentTop=true/ListView EditText android:id=@+id/editText1 android:layout_width=wrap_content android:layout_height=wrap_content android:layout_alignParentBottom=true android:text=EditText/EditText /RelativeLayout When your activity is created and displayed the first time, softKeyboard will be shown even if user doesn't select the EditText field. I haven't reported this issue on Android trouble ticket system, since I think this is an issue on manufacturer implementation (may be) Devices we have: Sonyericsson Xperia x10 (with Cyanogen 6) - Issue doesn't appear. Motorola Milestone - Issue doesn't appear. HTC Desire - Issue happens on it. LG GX2 (T-Mobile) - Issue happens on it. The recipe to replicate this seems to be, having a ViewGroup above any EditText, will cause in certain devices, soft keyboard to appear, when entering on an Activity. I just would like to know if other ppl is able to replicate it, on which devices, and if possible, what's the workaround. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Query
pl.suggest soln to this. My date column has date like:2011-07-25. final Calendar c = Calendar.getInstance(); int myMonth = (c.get(Calendar.MONTH)+1); int myDay = c.get(Calendar.DAY_OF_MONTH); String query = select * from table1 where (SUBSTR(date,6,2)== + myMonth + AND SUBSTR(date,9,2)= + myDay + ) UNION ALL select * from table1 where (SUBSTR(date,6,2)== + myMonth + AND SUBSTR(date, 9,2) + myDay + ) UNION ALL select * from table1 where SUBSTR(date,6,2) + myMonth + UNION ALL select * from table1 where SUBSTR(date,6,2) + myMonth + ; ; -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: floating listview
how to use custom view can anybody help me. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] How do we get Google's attention regarding the problems around randomly sorting comments in the Android Market?
I think the randomly sorted comments in the Android Market are about the worst thing that can happen to devs and users. Right now, comments are showing up on apps across the board that date back months. Many times they are negative, 1-star reviews, that refer to a long out-dated version of the application. We work HARD to create great apps and update them based on customer feedback and Market comments. But now, all that is in vain as the fruits of our labors are blatantly ignored in the comment system. Your Dev Console may still show all the great reviews that come in for your recently updated app - but since only a random subset of old reviews show up at the top on your App in the New Market and Web Market now, it's as if the update never happened. It's like all the hard work that was put it didn't matter because it's showing complaints from really old versions of the app. There are some simple solutions. 1) Show 3 random comments from the date of the most recent update. 2) Show them in reverse chronological order as they were. 3) Or come up with a far more sophisticated, logical, approach to displaying comments. For example, if you have 80% 5-Star ratings, the top 2 comments should be 2 random 5-star ratings, and if you have 10% 4-Star ratings, the last one should be a 4-star. At least it would be reflective of your actual ratings. 4) LOTS of other great ideas are out there. The question is tho, if others are on the same page as me, how do we get this issue fixed by Google for the good of Users and Devs alike? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 use Camera setPreviewCallback listener?
Thanks Adam, I've been bogging down trying almost every callback method, but NONE of them gets called. I am stuck, I need to transfer cam view to another tabled PC. Any recommendations welcome Regards TM -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Most Efficient (TIMING) way to save the images onto the Tablet!!!!
Putting this to the top to see if someone has an answer... thank you On Jul 25, 2011 11:20 AM, Sebastian Tomaszewski stomasze101...@gmail.com wrote: Do any of you guys know an answer to this.. Just wondering... On Fri, Jul 22, 2011 at 5:24 PM, Sebo stomasze101...@gmail.com wrote: Hello All, Here is my Problem, I am trying to safe an image (1280x800) into the memory and I am running into some timing issues Meaning I want to get it done As fast as possible wihtout losing the image sizing and crispness I had been trying to resolve this problem for last couple of days and I am running always to gotchias (The final destination of the Image I want it to be in the SDCARD) 1. I tried writing directly an image to the SD-CARD and it took about about 180 msec 2. I tried writing to internal cache memory first (160msec) and then copying using the FileChannel the image to SDCARD (4msec) Does anyone know what would be even faster? If there is no faster way to do this, that is fine, but I just want to make sure that I visited all of the possible ways. Thank you all for your help ahead of time. Thank you and Best Regards, Sebo --- I eat droids for Breakfast -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Most Efficient (TIMING) way to save the images onto the Tablet!!!!
Your timings don't seem that bad - 180 ms for approximately 3 MB image (you didn't write anything about compression) is about 16 MB / sec. I'd recommend you run some kind of compression on the image data. It doesn't have to be anything fancy that gets you the minimum possible image size, but rather the opposite - something that can reduce the file size, while taking less time than it will save on I/O. -- Kostya 28.07.2011 22:20, Sebastian Tomaszewski ?: Putting this to the top to see if someone has an answer... thank you On Jul 25, 2011 11:20 AM, Sebastian Tomaszewski stomasze101...@gmail.com mailto:stomasze101...@gmail.com wrote: Do any of you guys know an answer to this.. Just wondering... On Fri, Jul 22, 2011 at 5:24 PM, Sebo stomasze101...@gmail.com mailto:stomasze101...@gmail.com wrote: Hello All, Here is my Problem, I am trying to safe an image (1280x800) into the memory and I am running into some timing issues Meaning I want to get it done As fast as possible wihtout losing the image sizing and crispness I had been trying to resolve this problem for last couple of days and I am running always to gotchias (The final destination of the Image I want it to be in the SDCARD) 1. I tried writing directly an image to the SD-CARD and it took about about 180 msec 2. I tried writing to internal cache memory first (160msec) and then copying using the FileChannel the image to SDCARD (4msec) Does anyone know what would be even faster? If there is no faster way to do this, that is fine, but I just want to make sure that I visited all of the possible ways. Thank you all for your help ahead of time. Thank you and Best Regards, Sebo --- I eat droids for Breakfast -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Kostya Vasilyev -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 do we get Google's attention regarding the problems around randomly sorting comments in the Android Market?
On Thu, Jul 28, 2011 at 1:05 PM, BenMc selticesyst...@gmail.com wrote: The question is tho, if others are on the same page as me, how do we get this issue fixed by Google for the good of Users and Devs alike? https://www.google.com/support/androidmarket/bin/request.py?contact_type=contact_policypolicy=apps Not that it does any good. - TreKing http://sites.google.com/site/rezmobileapps/treking - Chicago transit tracking app for Android-powered devices -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Most Efficient (TIMING) way to save the images onto the Tablet!!!!
When writing to the sdcard directly did you wrap your file stream around a buffered stream with a 8k buffer? On Thu, Jul 28, 2011 at 11:37 AM, Kostya Vasilyev kmans...@gmail.com wrote: Your timings don't seem that bad - 180 ms for approximately 3 MB image (you didn't write anything about compression) is about 16 MB / sec. I'd recommend you run some kind of compression on the image data. It doesn't have to be anything fancy that gets you the minimum possible image size, but rather the opposite - something that can reduce the file size, while taking less time than it will save on I/O. -- Kostya 28.07.2011 22:20, Sebastian Tomaszewski пишет: Putting this to the top to see if someone has an answer... thank you On Jul 25, 2011 11:20 AM, Sebastian Tomaszewski stomasze101...@gmail.com wrote: Do any of you guys know an answer to this.. Just wondering... On Fri, Jul 22, 2011 at 5:24 PM, Sebo stomasze101...@gmail.com wrote: Hello All, Here is my Problem, I am trying to safe an image (1280x800) into the memory and I am running into some timing issues Meaning I want to get it done As fast as possible wihtout losing the image sizing and crispness I had been trying to resolve this problem for last couple of days and I am running always to gotchias (The final destination of the Image I want it to be in the SDCARD) 1. I tried writing directly an image to the SD-CARD and it took about about 180 msec 2. I tried writing to internal cache memory first (160msec) and then copying using the FileChannel the image to SDCARD (4msec) Does anyone know what would be even faster? If there is no faster way to do this, that is fine, but I just want to make sure that I visited all of the possible ways. Thank you all for your help ahead of time. Thank you and Best Regards, Sebo --- I eat droids for Breakfast -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Kostya Vasilyev -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- ~ Jeremiah:9:23-24 Android 2D MMORPG: http://solrpg.com/, http://www.youtube.com/user/revoltingx -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en