[android-developers] Re: Javascript openDatabase callback never executes
Hi and thanks for both replies. I have set a database path and on a rooted device verified that all is working as intended. Shame the callback is not supported on the older versions of Android - i shall have to think up a workaround in the javascript. Martin. On Jan 30, 8:48 pm, John Purcell jsp...@gmail.com wrote: Also keep in mind that certain versions of Android you should/must give webkit a custom path for your databases (websettings.setDatabasePath(), et al), which can be set on a per view basis (unlike AppCache, which is a singleton per app). On Jan 29, 1:26 am, Martin warwo...@gmail.com wrote: Hi. I'm using the Database Storage API in a WebView and have been researching the available javascript methods. The javascript openDatabase() method is documented to have an optional fifth parameter which is a callback function to execute once the openDatabase() method has completed (but only if the database has been created - see below). The openDatabase() method is asyncronous so i need to query the database after it has been created and is ready for use, NOT after the openDatabase() method has been executed. Hope that makes sense but anyway my question is does the WebView's javascript openDatabase() method support this fifth optional parameter? Some example javascript: function dbCreated(transaction){ console.log('debug#2');} console.log('debug#1'); var shortName='locationTracker', version='1.0', displayName='Some text', maxSize=32768; var database=openDatabase(shortName, version, displayName, maxSize, dbCreated); console.log('debug#3'); In the log i see 'debug#1' and 'debug#3' but never see 'debug#2'. The callback is supposed to only be called if the database has been created and opened. It is not called if the database already existed and has been opened but not created. http://html5doctor.com/introducing-web-sql-databases/ Scroll down to 'Creating and Opening Databases' and 5. Creation callback. I've uninstalled my app a few times and reinstalled it - thinking that the database definitely will not exist so will be created and the callback will execute but the callback still fails to execute. This is on a Froyo emulator and also on my ZTE Blade with cyanogen mod Gingerbread. Has anyone got any experience with the javascript database storage api and could tell me if this callback is supported? Thanks. Martin. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Layout supporting word wrap for Views?
Here's mine, it maybe a bit more full featured. It also supports centering the views vertically on each line: package your.package.here; import java.util.ArrayList; import java.util.Collection; import java.util.List; import android.content.Context; import android.content.res.TypedArray; import android.util.AttributeSet; import android.view.View; import android.view.ViewGroup; public class FlowLayout extends ViewGroup { private int[] rowHeights; public FlowLayout(Context context, AttributeSet attrs) { super(context, attrs); } @Override protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { int widthMode = MeasureSpec.getMode(widthMeasureSpec); int heightMode = MeasureSpec.getMode(heightMeasureSpec); int maxInternalWidth = MeasureSpec.getSize(widthMeasureSpec) - getHorizontalPadding(); int maxInternalHeight = MeasureSpec.getSize(heightMeasureSpec) - getVerticalPadding(); ListRowMeasurement rows = new ArrayListRowMeasurement(); RowMeasurement currentRow = null; for (View child : getLayoutChildren()) { LayoutParams childLayoutParams = (LayoutParams)child.getLayoutParams(); int childWidthSpec = createChildMeasureSpec(childLayoutParams.width, maxInternalWidth, widthMode); int childHeightSpec = createChildMeasureSpec(childLayoutParams.height, maxInternalHeight, heightMode); child.measure(childWidthSpec, childHeightSpec); int childWidth = child.getMeasuredWidth(); int childHeight = child.getMeasuredHeight(); if ((currentRow == null) || currentRow.isWouldExceedMax(childWidth)) { currentRow = new RowMeasurement(maxInternalWidth, widthMode); rows.add(currentRow); } currentRow.addChildDimensions(childWidth, childHeight); } int longestRowWidth = 0; int totalRowHeight = 0; int rowCount = rows.size(); this.rowHeights = new int[rowCount]; for (int rowIndex = 0; rowIndex rowCount; rowIndex++) { RowMeasurement row = rows.get(rowIndex); int rowHeight = row.getHeight(); this.rowHeights[rowIndex] = rowHeight; totalRowHeight = totalRowHeight + rowHeight; longestRowWidth = Math.max(longestRowWidth, row.getWidth()); } setMeasuredDimension((widthMode == MeasureSpec.EXACTLY) ? MeasureSpec.getSize(widthMeasureSpec) : (longestRowWidth + getHorizontalPadding()), (heightMode == MeasureSpec.EXACTLY) ? MeasureSpec.getSize(heightMeasureSpec) : (totalRowHeight + getVerticalPadding())); } private int createChildMeasureSpec(int childLayoutParam, int max, int parentMode) { int spec; if (childLayoutParam == ViewGroup.LayoutParams.FILL_PARENT) spec = MeasureSpec.makeMeasureSpec(max, MeasureSpec.EXACTLY); else if (childLayoutParam == ViewGroup.LayoutParams.WRAP_CONTENT) spec = MeasureSpec.makeMeasureSpec(max, ((parentMode == MeasureSpec.UNSPECIFIED) ? MeasureSpec.UNSPECIFIED : MeasureSpec.AT_MOST)); else spec = MeasureSpec.makeMeasureSpec(childLayoutParam, MeasureSpec.EXACTLY); return spec; } @Override protected LayoutParams generateDefaultLayoutParams() { return new LayoutParams(); } @Override protected boolean checkLayoutParams(ViewGroup.LayoutParams layoutParams) { return (layoutParams instanceof LayoutParams); } @Override public LayoutParams generateLayoutParams(AttributeSet attrs) { return new LayoutParams(getContext(), attrs); } @Override protected ViewGroup.LayoutParams generateLayoutParams(ViewGroup.LayoutParams p) { return new LayoutParams(p); } @Override protected void onLayout(boolean changed, int leftPosition, int topPosition, int rightPosition, int bottomPosition) { int widthOffset = getMeasuredWidth() - getPaddingRight(); int x = getPaddingLeft(); int y = getPaddingTop(); int rowIndex = 0; for (View child : getLayoutChildren()) { int childWidth = child.getMeasuredWidth(); int childHeight = child.getMeasuredHeight(); LayoutParams layoutParams = (LayoutParams)child.getLayoutParams(); if ((x + childWidth) widthOffset) { x = getPaddingLeft(); y = y + this.rowHeights[rowIndex]; rowIndex = rowIndex + 1; } int _y; if (layoutParams.centerVertical) _y = y + ((this.rowHeights[rowIndex] - childHeight) / 2); else _y = y; child.layout(x, _y, x + childWidth, _y + childHeight); x = x + childWidth; } } private CollectionView getLayoutChildren() {
Re: [android-developers] Unpublish application
It's worth mentioning that even after you unpublish an app, users can still leave comments and ratings. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] hey all
i want to monitor another phone number's location, which listeners should i use? -- Be good to not only people but also machines -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] PreferenceActivity, configuration screen and back button
hello all, i've got widget using a Preference activity (Honeycomb). When I try to add the widget on my home, the configure screen is display. I implement the new mechanism for Honeycomb described at : http://developer.android.com/guide/topics/appwidgets/index.html#Configuring I found some example describing that the preference must notify the widget after configuration modification. All example use a button or have only one list catching the user selection to update the widget. My preference screen has some different parameters, I don't want a button to set the preferences and I want to update parameters when user leaves the configuration screen. I tried to update my widget on onBackPressed event of my PreferenceActivity. It doesn't work. The widget doesn't have the good preference just after closing the preferenceactivity, but only after added a new time. So, what is the tips to do this ? (Hoping that my explanation are enough and clearly :)) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Encoder???
Date: Mon, 30 Jan 2012 23:01:31 -0800 Subject: [android-developers] Re: Encoder??? From: psk...@gmail.com To: android-developers@googlegroups.com On Jan 31, 7:31 am, Muhammad UMER muhammad.ume...@hotmail.com wrote: What can i do, to start mdat from offset 0x20? your server side doesn't write your data correctly - you can use wireshark to see whats on the wire Thanks, i got my error and also i resolve it. now mdat at offset 0x20. you have to copy first 28 bytes from normal_file to the first 28 bytes of server_file Please can you pacify(highlight) these 28 bytes, that i have to copy? what to highlight? You have to copy bytes 0, 1, 2, .. 26, 27 of the normal_file to the beginning of the server_file, thats all Because i haven't write a video file before, that's why i say you to highlight these bytes. i mean to say how to get these bytes from normal file. may i have to hard code these bytes. like e.g String s = ftyp3gp4; byte data[] = s.getBytes(); and write this byte array to the file. I don't know from where the moov atom start? yes, but you have to find it in the file, just google about pattern search or something pskink -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] How to Check Or Enable GPRS Programatically
*I am having application where i compulsory need GPRS (Not Wifi) ON. Is there any way to check wether GPRS is ON? and if it is OFF ,Is there any way to make it turn on without/With user interaction * -- Thanks Best Regards. Dhaval varia -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 using Assets
I'd like to use html (with images, btw) to provide documentation for my app. I thought to store my documentation pages in assets and use webview but I cannot find a way to link the webview to the assets. Does anyone know if this is possible? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] c2dn on simulator ?
hi all, I am asked to do a c2dm feasibility, can I do it in simulator ? is there any beginner tutorial for c2dm ? regards -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: WebView using Assets
You have to use loadData applied on webview and you can retrieve your assets using getAssetManager -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Unpublish application
Thanks for the info. Would all the description on the application, pictures, analitics and so on is gone when unpublishing? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Better UI Designing
Hey all, How do I design better UI for my android application? Are there any software or tutorials available which would help in refining the UIs? I am looking for some help or some software or tutorials for designing a better UI for Android 2.1+. Something that would make my task easier. As for an example if anyone does know how they design the custom layouts for apps like Go Sms or Viber. Regards, Brad -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: WebView problem with youtube video
In general, the loading of the URL should come last (right now you've got plugins and Javascript enabled messages being sent to the webcore after you send a url request). Is this on Honeycomb or ICS? (I'm guessing ICS due to the 'normal' errors you posted above). Keep in mind that video needs special handling in older versions of android (well, in all versions really). http://code.google.com/p/html5webview/ will work for 2.x, but is out of date for 3.x/4.x On Jan 30, 3:34 pm, drenda daniele.re...@gmail.com wrote: PLease, someone has some ideas? Thanks! On 29 Gen, 22:38, drenda daniele.re...@gmail.com wrote: Hi, i made a simple example in order to display in my app some youtube's video of a playlist. I created a WebView: @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); try { setContentView(R.layout.video); final WebView webView = (WebView) findViewById(R.id.video_webview); webView.loadUrl(getString(R.string.urlYouTube)); webView.getSettings().setJavaScriptEnabled(true); webView.getSettings().setPluginsEnabled(true); } catch (Exception e) { Log.e(Rubner, e.getMessage()); e.printStackTrace(); } The webview is render correctly and display the videos of playlist. When you click on a video is displayed the page of the video with play button but if you click on it the video don't start!!! Are raised these errors: 01-29 22:37:28.714: W/System.err(5963): Error reading from ./org/ apache/harmony/luni/internal/net/www/protocol/data/Handler.class 01-29 22:37:28.934: E/libEGL(5963): call to OpenGL ES API with no current context (logged once per thread) 01-29 22:37:28.934: D/ShaderProgram(5963): couldn't load the vertex shader! Any ideas of the problem?? Thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] WebView using Assets
On Tue, Jan 31, 2012 at 5:31 AM, atcal alan.williams...@ya.com wrote: I'd like to use html (with images, btw) to provide documentation for my app. I thought to store my documentation pages in assets and use webview but I cannot find a way to link the webview to the assets. Does anyone know if this is possible? webView.loadUrl(file:///android_asset/path/to/your/file.html) works fine. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Browsing CTS code online
On Tue, Jan 31, 2012 at 12:27 AM, anup Jaipurkar androida...@gmail.com wrote: Can I browse android CTS code online. Please provide the URL. No, AFAIK, but it is a simple ZIP download: http://source.android.com/compatibility/downloads.html -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] how to integrate sharepoint website with android client application
Dear all i need a help please I have a sharepoint website and the task is to make an android client application to integrate with this website , this application will just view the content of the website and add comment feedback. i don't know what is the steps to do this task ,i just want steps to follow to start this app thank you all waiting your answers -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Horizontal swipe three images at a time in honeycomb
Hi All, I am developing a speech therapy apps for Android 3.2, in that i have to swipe three images at a time and all the three images are clickable, when we click on any of the image corresponding sound should come. so please if any one have this answer please help me. Thanks in advance. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Unpublish application
On Tue, Jan 31, 2012 at 5:01 AM, Daniel Kubovsky kubovs...@gmail.comwrote: Would all the description on the application, pictures, analitics and so on is gone when unpublishing? Did you read my first response? would all the descriptions, pictures and so on regarding the application is gone too? From the Market, yes. From your dev console, no. - 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: How I use Web Services in android.?
Hello, I am just stuck to a thing. I am using a soap service with method called LoadForm. I am sending as request serviceId(int) and it is responding me with ResponseForm(string) and that is an entire html code of the online form. How should I use it to built an activity i.e. to show that form in my activity. Please reply if you have some ideas. Thanks, Harpreet. On Jan 30, 3:06 pm, Harpreet Singh harry...@gmail.com wrote: Hi friends, I resolved my problem, actually i have to call the soap service in my app and i was finding the way to develop that service in my. How silly of me... :P Moreover I find out that the service was not working in AVD version 2.1 and it worked well in AVD version 2.3.x. Thanks for all your support. I also get successful in saving the user info by using SharedPreferences to make my app autologin each time user open the app. Thanks, Harpreet. On Jan 25, 5:52 pm, unicus unicus unicus...@gmail.com wrote: Harpit, I have developed sample tutorial.You can idea how to access webservice in android. please following linkhttp://androidbasic-answer.blogspot.com/2012/01/access-webservice-fro... -- *More info*,http://androidbasic-answer.blogspot.com/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: How to test Activity, which is run in the separate process (android.process=:process in the manifest file)
Anyone? On Thu, Jan 19, 2012 at 12:50 PM, Yahor Paulavets ypaulav...@agilefusion.com wrote: Hello, Thanks for the replies! Just out of interest, what do you mean by 'test?' - I mean GUI Robotium test - ActivityInstrumentationTestCase2 etc. Which should be run from the shell ot the CI Server. Just remove the process attribute from your manifest while testing - I have tried, but by this way we are able only to run the application, then it crashes without separate process.. It has near 10 activities with separate process, if I remove all of them it doesn't work anyway.. But looks like it is only the direction we can find any solution. I said that it is bug only because of it is illogical to have a huge testing infrastructure and cool big apps which are not testable due to the are no way to get control over the Activities which is run in a separate process.. Please advise, is there any possible solution? Best regards, Yahor On Wed, Jan 18, 2012 at 8:45 AM, Diego Torres Milano dtmil...@gmail.comwrote: Just remove the process attribute from your manifest while testing and re-enable it when exporting a production APK. Probably you have to remove others as well (i.e. debuggable), so why bother. On Jan 17, 2:03 am, Kristopher Micinski krismicin...@gmail.com wrote: Just out of interest, what do you mean by 'test?' Do you mean, run in eclipse with the 'test' functionality in that IDE? Or perhaps you mean under something like monkeyrunner.. Depending on what you want to test, I don't see what your problem is, which I suspect is why few people responded. True, if something is running in a separate process it's not as easy to debug it, you could always attack a debugger to the other process, but this isn't a bug in Android, per se. P.s., there have been so many people on this list lately with here, I've found an obvious bug in android that doesn't really make sense, please think deeply before you blame a highly trusted framework (/system/framework/etc...) On Tue, Jan 17, 2012 at 1:54 AM, Yahor Paulavets ypaulav...@agilefusion.com wrote: Anyone? On Tue, Jan 10, 2012 at 5:12 PM, Yahor Paulavets ypaulav...@agilefusion.com wrote: Hello, After the week of hard workaround I didn't find any possible solution to test Activity if it is run with specified android.process=:process param (private, isolated process). Please help to find any possible solution to understand how to test such Activities. Is it Android bug, that Activities in the separate process are not testable? :( Any help is highly appreciated. Best regards, Yahor -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Have you read my blog ? http://dtmilano.blogspot.com android junit tests ui linux cult thin clients -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: How to test Activity, which is run in the separate process (android.process=:process in the manifest file)
I have shared a lot of knowledges, how to interact with android device using shell: http://softteco.blogspot.com/2011/03/android-low-level-shell-click-on-screen.html And answering to every questions, guys have. I'm so disappointed that there are nobody to help ME to solve MY problem :((( Very frustrating and disappointing.. On Tue, Jan 31, 2012 at 4:15 PM, Yahor Paulavets ypaulav...@agilefusion.com wrote: Anyone? On Thu, Jan 19, 2012 at 12:50 PM, Yahor Paulavets ypaulav...@agilefusion.com wrote: Hello, Thanks for the replies! Just out of interest, what do you mean by 'test?' - I mean GUI Robotium test - ActivityInstrumentationTestCase2 etc. Which should be run from the shell ot the CI Server. Just remove the process attribute from your manifest while testing - I have tried, but by this way we are able only to run the application, then it crashes without separate process.. It has near 10 activities with separate process, if I remove all of them it doesn't work anyway.. But looks like it is only the direction we can find any solution. I said that it is bug only because of it is illogical to have a huge testing infrastructure and cool big apps which are not testable due to the are no way to get control over the Activities which is run in a separate process.. Please advise, is there any possible solution? Best regards, Yahor On Wed, Jan 18, 2012 at 8:45 AM, Diego Torres Milano dtmil...@gmail.comwrote: Just remove the process attribute from your manifest while testing and re-enable it when exporting a production APK. Probably you have to remove others as well (i.e. debuggable), so why bother. On Jan 17, 2:03 am, Kristopher Micinski krismicin...@gmail.com wrote: Just out of interest, what do you mean by 'test?' Do you mean, run in eclipse with the 'test' functionality in that IDE? Or perhaps you mean under something like monkeyrunner.. Depending on what you want to test, I don't see what your problem is, which I suspect is why few people responded. True, if something is running in a separate process it's not as easy to debug it, you could always attack a debugger to the other process, but this isn't a bug in Android, per se. P.s., there have been so many people on this list lately with here, I've found an obvious bug in android that doesn't really make sense, please think deeply before you blame a highly trusted framework (/system/framework/etc...) On Tue, Jan 17, 2012 at 1:54 AM, Yahor Paulavets ypaulav...@agilefusion.com wrote: Anyone? On Tue, Jan 10, 2012 at 5:12 PM, Yahor Paulavets ypaulav...@agilefusion.com wrote: Hello, After the week of hard workaround I didn't find any possible solution to test Activity if it is run with specified android.process=:process param (private, isolated process). Please help to find any possible solution to understand how to test such Activities. Is it Android bug, that Activities in the separate process are not testable? :( Any help is highly appreciated. Best regards, Yahor -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Have you read my blog ? http://dtmilano.blogspot.com android junit tests ui linux cult thin clients -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: How I use Web Services in android.?
Any example/ sample you have for :: If I develop my own xml_layouts of forms and save them to server, so then how I'll use them to get as response and then show them as activity in app? Please help if you have any idea. Or Can tell any other way to use a form coming as response, to use it as activity. Thanks, Harpreet. On Jan 30, 3:06 pm, Harpreet Singh harry...@gmail.com wrote: Hi friends, I resolved my problem, actually i have to call the soap service in my app and i was finding the way to develop that service in my. How silly of me... :P Moreover I find out that the service was not working in AVD version 2.1 and it worked well in AVD version 2.3.x. Thanks for all your support. I also get successful in saving the user info by using SharedPreferences to make my app autologin each time user open the app. Thanks, Harpreet. On Jan 25, 5:52 pm, unicus unicus unicus...@gmail.com wrote: Harpit, I have developed sample tutorial.You can idea how to access webservice in android. please following linkhttp://androidbasic-answer.blogspot.com/2012/01/access-webservice-fro... -- *More info*,http://androidbasic-answer.blogspot.com/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] how to use AsyncTask
Hello, How can i use Asynctask for the following code: public static String getXML() { String line = null; DefaultHttpClient httpClient = new DefaultHttpClient(); HttpPost httpPost = new HttpPost(http://someurl/index.xml;); try { HttpResponse httpResponse = httpClient.execute(httpPost); HttpEntity httpEntity = httpResponse.getEntity(); line = EntityUtils.toString(httpEntity); } catch (UnsupportedEncodingException e) { line = results status=\error\msgCan't connect to server/ msg/results; } catch (MalformedURLException e) { line = results status=\error\msgCan't connect to server/ msg/results; } catch (IOException e) { line = results status=\error\msgCan't connect to server/ msg/results; } return line; } this basicaly gets an xml from the website Thanks in advance -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: How to test Activity, which is run in the separate process (android.process=:process in the manifest file)
On Tue, Jan 31, 2012 at 8:18 AM, Yahor Paulavets ypaulav...@agilefusion.com wrote: I have shared a lot of knowledges, how to interact with android device using shell: http://softteco.blogspot.com/2011/03/android-low-level-shell-click-on-screen.html And answering to every questions, guys have. I'm so disappointed that there are nobody to help ME to solve MY problem :((( Very frustrating and disappointing.. What is frustrating and disappointing is that you are using android:process in your app to the extent that you are. Using it once would require serious justification. 10 activities with separate process would get you fired within minutes. Get rid of android:process and solve whatever problems you think that they are solving. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Edittext Scrolling
Hi all, I am creating an app. It contain an edit text inside a scroll view. The edit text support multiple lines.My problem is that i can't make edit text scrollable.In the same screen there is a list view, it is scrollable.How i can possible to scroll through the edit text.Please help me. Thanks and Regards -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Home screed Widget crash
Hello guys, I am working on an homescreen widget app that shows images downloaded from the internet. The flow is widget starts a service and the service runs a thread every 15 seconds. The thread downloads image and shows it on the homescreen. The issue is that after showing the images 4 to 6 times, it stops updating the imageView on homescreen, and finally crashes, giving a 'failed binder transaction' error on further web requests. I read about it on the internet, some said that the image has to be resized, and it did actually help a little, the widget now crashes after showing more images than before. Others said that it is a bug with android. Any help/suggestions ? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 test Activity, which is run in the separate process (android.process=:process in the manifest file)
Hello, It is not my app, it is app I have to test. And it is not testable, because it has :separate processes. I wonder to know, is there are any way to test such processes? Or how can I submit a bug/ask google/whatever to get the answer or direction.. Best regards, Yahor On Tue, Jan 31, 2012 at 4:27 PM, Mark Murphy mmur...@commonsware.comwrote: On Tue, Jan 31, 2012 at 8:18 AM, Yahor Paulavets ypaulav...@agilefusion.com wrote: I have shared a lot of knowledges, how to interact with android device using shell: http://softteco.blogspot.com/2011/03/android-low-level-shell-click-on-screen.html And answering to every questions, guys have. I'm so disappointed that there are nobody to help ME to solve MY problem :((( Very frustrating and disappointing.. What is frustrating and disappointing is that you are using android:process in your app to the extent that you are. Using it once would require serious justification. 10 activities with separate process would get you fired within minutes. Get rid of android:process and solve whatever problems you think that they are solving. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 test Activity, which is run in the separate process (android.process=:process in the manifest file)
update: if I remove :process separate process definition in the manifest file, application crashes and there are no way to run it without separate process definition. Best regards, Yahor On Tue, Jan 31, 2012 at 4:36 PM, Yahor Paulavets ypaulav...@agilefusion.com wrote: Hello, It is not my app, it is app I have to test. And it is not testable, because it has :separate processes. I wonder to know, is there are any way to test such processes? Or how can I submit a bug/ask google/whatever to get the answer or direction.. Best regards, Yahor On Tue, Jan 31, 2012 at 4:27 PM, Mark Murphy mmur...@commonsware.comwrote: On Tue, Jan 31, 2012 at 8:18 AM, Yahor Paulavets ypaulav...@agilefusion.com wrote: I have shared a lot of knowledges, how to interact with android device using shell: http://softteco.blogspot.com/2011/03/android-low-level-shell-click-on-screen.html And answering to every questions, guys have. I'm so disappointed that there are nobody to help ME to solve MY problem :((( Very frustrating and disappointing.. What is frustrating and disappointing is that you are using android:process in your app to the extent that you are. Using it once would require serious justification. 10 activities with separate process would get you fired within minutes. Get rid of android:process and solve whatever problems you think that they are solving. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 test Activity, which is run in the separate process (android.process=:process in the manifest file)
On Tue, Jan 31, 2012 at 8:36 AM, Yahor Paulavets ypaulav...@agilefusion.com wrote: It is not my app, it is app I have to test. And it is not testable, because it has :separate processes. Ah, my apologies. Please direct my rants to the developers, who should have their heads examined. I wonder to know, is there are any way to test such processes? I doubt it, at least in terms of ActivityInstrumentationTestCase2 and kin. Android does some magic to load your test cases into the same process as the main app; I'll be rather surprised if they can somehow magically extend that to other processes and coordinate between them. Or, to look at it another way, if Diego Torres Milano did not have a solution for you, then it is likely that no such solution exists -- he's probably the world's leading expert on this subject. You could try monkeyrunner, as that has a chance of handling multiple processes. Or how can I submit a bug/ask google/whatever to get the answer or direction.. You are welcome to file a feature request at http://b.android.com. That will not help you in the short term. update: if I remove :process separate process definition in the manifest file, application crashes and there are no way to run it without separate process definition. That is because the developers wrote a lousy app. If monkeyrunner does not fit your needs, report back to whoever assigned this app to you that the app is untestable in its current state, and that the developers should remove the android:process attributes and fix their app. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] This is my first application
Hello friends, it is my first application. http://selametoglu.blogspot.com/2012/01/light-show-android-uygulamas.html ( translate english google: http://translate.google.com.tr/translate?hl=trsl=trtl=enu=http%3A%2F%2Fselametoglu.blogspot.com%2F2012%2F01%2Flight-show-android-uygulamas.html ) if you write comment on site, i can development my self and people read Thanks. good codes.. Salih SELAMETOĞLU Teknopalas RFID Yazılım Çözümleri / Yazılım Uzman Yardımcısı İstanbul Üni. Bil. Müh. 4. Sınıf http://www.linkgizle.com http://selametoglu.blogspot.com/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Resume activity while download
Hi, I'm currently working on an app where the user can start a download of a big file (in an activity called FileDetailsActivity). I can properly start, cancel, restart and handle the download, everything works fine. But, I'm looking for a way to implement this use-case: * the user goes back to the previous activity (let's call it ListingOfFilesActivity) * Eventually, the user can choose another file in the list to start the FileDetailsActivity and come back to the ListingOfFilesActivity. * -- When the user resumes the FileDetailsActivity he started before (with a downloading async thread), i would like to resume the display state. I don't know if i'm clear about what i would like to have... An example of an existing implementation is the Android Market. The user can start to download an app (let's say Hangman) and the App's page. Then he can go back and keep looking other things. And then, if he goes back to the Hangman's app page, he can see how far is its download... Can anyone help me with this ? Thanks a lot. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] nullpointer on getPreferenceManager() in sdk 13 and up
I'm trying to implement a fragemented preferences activity. This is only the first part of my activity where it already fails: public class PreferencesICSActivity extends PreferenceActivity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); PreferenceManager preferenceManager = PreferencesICSActivity.this.getPreferenceManager(); preferenceManager.setSharedPreferencesName(Constants.Preferences.PREFERENCES_NAME); } ... } I used to do the same in sdk version 7, there it worked. Now however the getPreferenceManager() is null... What am I doing wrong? Kr, Dirk Vranckaert -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] nullpointer on getPreferenceManager() in sdk 13 and up
getPreferenceManager() looks like it will return null if you are using preference headers. My guess is that you are supposed to use the PreferenceManager from your PreferenceFragments. On Tue, Jan 31, 2012 at 9:22 AM, Dirk Vranckaert dirkvrancka...@gmail.com wrote: I'm trying to implement a fragemented preferences activity. This is only the first part of my activity where it already fails: public class PreferencesICSActivity extends PreferenceActivity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); PreferenceManager preferenceManager = PreferencesICSActivity.this.getPreferenceManager(); preferenceManager.setSharedPreferencesName(Constants.Preferences.PREFERENCES_NAME); } ... } I used to do the same in sdk version 7, there it worked. Now however the getPreferenceManager() is null... What am I doing wrong? Kr, Dirk Vranckaert -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] ExpandableListView How to get bitmap of each item separately
Hi, I am trying expand/collapse animation in expandable listview but i am stuck :( i have two group each with some dynamic number of items. so when first group expands, second group slides down (along with its child items) smoothly and displays first group child items with some alpha animation. I got idea for this animation but i have to get bitmap for each (group and child) and draw this bitmap on surfaceview canvas with some logic but problem is how to get bitmap for group/child items . I tried following and got first group bitmap : View mView = mExpandableListView.getChildAt(0); mView.setDrawingCacheEnabled(true); mView.setDrawingCacheQuality(DRAWING_CACHE_QUALITY_HIGH); Bitmap sweet = mView.getDrawingCache(); but how to get bitmap for particular group /child generically ? Please help me with your valuable comments :) Thanks and regards -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] In-App Billing Tracking By Android Market
If I provide the traditional lite/paid versions that can exist in the market prior to In-App billing and then I change the Lite version to support In-App billing and unlock features to make it now the same as the paid version, then how does the market know that I have unlocked these features and that the Lite version is really now the Paid version? In pre - InApp Billing one way was to have different package names. When I unlock the features do I then change the Apps Package name? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] VideoView and buffering
Hi, I'm using the reset() now. There's a little bump in the playback every time it reaches the end of the content that existed in the file when it was initially loaded which I don't like but I'm using prepareAsync so I think this hiccup is as small as I can make it with a single VideoView. Thanks for your help. -jm On Mon, Jan 30, 2012 at 11:16 AM, Daniel Drozdzewski daniel.drozdzew...@gmail.com wrote: John-Marc, I have not done this myself, but here is tutorial on how to do it: http://blog.pocketjourney.com/2008/04/04/tutorial-custom-media-streaming-for-androids-mediaplayer/ They actually create new MediaPlayer object upon every update to the buffer file and point this new MediaPlayer to the updated buffer every single time. I would test calling MediaPlayer.reset() first instead of creating new player object every time, to see whether time and memory consumed by such solution is a bit better. HTH, Daniel On 30 January 2012 15:49, John-Marc Desmarais j...@ieee.org wrote: Hi, I am currently writing a video file to the SDCard while playing it with VideoView. My problem is that, if I buffer 1MB of video and begin the Video playback, the video stops after 1MB has been played, even though by this time, 5MBs of file has now been written to the sdcard. I have been trying various things in onCompletion handler.. such as: int curLoc = mp.getCurrentPosition(); Log.e(LogName.onCompletion, LogName.onCompletion + CurrentLocation: + mp.getCurrentPosition()); Log.e(LogName.onCompletion, LogName.onCompletion + Duration: + mp.getDuration()); mp.pause(); mp.prepareAsync(); mp.start(); mp.seekTo(curLoc); In this case I get a Cannot play video message. Or: int curLoc = mp.getCurrentPosition(); Log.e(LogName.onCompletion, LogName.onCompletion + CurrentLocation: + mp.getCurrentPosition()); Log.e(LogName.onCompletion, LogName.onCompletion + Duration: + mp.getDuration()); mp.prepareAsync(); mp.start(); mp.seekTo(curLoc); This crashes with prepare Async in State 128. Has anyone solved the problem of re-queuing file in the videoView so that it plays everything that has been written to the sdcard even though it starts with a smaller file? Regards, -jm -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] ExpandableListView How to get bitmap of each item separately
On Tue, Jan 31, 2012 at 8:41 AM, Mansoor musafir4frie...@gmail.com wrote: I tried following and got first group bitmap : View mView = mExpandableListView.getChildAt(0); but how to get bitmap for particular group /child generically ? Well, if getChildAt(0) get your the first one, replace 0 with the index of the ones you want. - 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] In-App Billing Tracking By Android Market
On Tue, Jan 31, 2012 at 8:49 AM, beachboy jfma...@gmail.com wrote: how does the market know that I have unlocked these features and that the Lite version is really now the Paid version? It doesn't - *your app* would check if the user bought the unlock item and react accordingly. - 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] Resume activity while download
On Tue, Jan 31, 2012 at 8:01 AM, ColletJb collet...@gmail.com wrote: Can anyone help me with this ? Instead of background thread you probably want a background service, to which you bind and unbind as your details activity comes and goes. So the download logic and state is stored in the service and reflected in the Activity when the user comes back to it. Your Market example does this - you'll see the download / install progress as a notification as the (assumed) background service is doing its thing. - 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] Better UI Designing
On Tue, Jan 31, 2012 at 5:18 AM, Brad Stintson geek.bin...@gmail.comwrote: How do I design better UI for my android application? Are there any software or tutorials available which would help in refining the UIs? http://developer.android.com/design/index.html - 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: Resume activity while download
With my current implementation, I use AsyncTask. It supports progress updates and many other things. How could I handle the progress updates with a separated service ? With AIDL ? Thanks for your help On 31 jan, 15:59, TreKing treking...@gmail.com wrote: On Tue, Jan 31, 2012 at 8:01 AM, ColletJb collet...@gmail.com wrote: Can anyone help me with this ? Instead of background thread you probably want a background service, to which you bind and unbind as your details activity comes and goes. So the download logic and state is stored in the service and reflected in the Activity when the user comes back to it. Your Market example does this - you'll see the download / install progress as a notification as the (assumed) background service is doing its thing. --- -- 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] MediaRecorder.start() hangs on Galaxy S2
Hi, I'm trying to develop a call recording app. This is the code to start recording: code try { MediaRecorder callRecorder = new MediaRecorder(); callRecorder.setAudioSource(AudioSource.VOICE_CALL); callRecorder.setOutputFormat(MediaRecorder.OutputFormat.RAW_AMR); callRecorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB); callRecorder.setOutputFile(recordingPath); callRecorder.prepare(); callRecorder.start(); } catch (Exception e) { } /code I'm facing some problems testing in Galaxy S2 device. It works great on Galaxy S+, and in other phone models it fails, but at least an exception is raised (start failed message, not very explanatory). With Galaxy S2 this code hangs in callRecorder.start(); It never returns. Has anybody found this problem? Any idea about what can be wrong with this code? Thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Resume activity while download
On Tue, Jan 31, 2012 at 9:10 AM, ColletJb collet...@gmail.com wrote: How could I handle the progress updates with a separated service ? With AIDL ? Check the Service documentation page. There is a LocalService example. - 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] how to integrate sharepoint website with android client application
Dear all i need a help please I have a sharepoint website and the task is to make an android client application to integrate with this website , this application will just view the content of the website and add comment feedback. i don't know what is the steps to do this task ,i just want steps to follow to start this app thank you all waiting your answers -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Add Native Support not found in Eclipse
On Jan 11, 12:25 am, John-Marc Desmarais j...@ieee.org wrote: Hi, Thanks for your help. I installed Sequoya and MTJ but, I still have no AddNativeSupport under Android Tools. I have also tried installing android-ndk-r6b and having C:\android\android-ndk-r6b in the path. But, currently, I have C:\android\android-ndk-r7 installed and in the system path. Maybe Indigo is the problem. I'll try Helios. -jm I have Sequoya with plain minimal Indigo Eclipse (not for C/C++), it works (almost) with android-ndk-r7. Almost has nothing to do with Eclipse, the same almost applies to command line build of the project: it's some funny cygwin issues with the NDK. Maybe your problem is this C/C++ version? Sequoya assumes you can build a usual Android app (that is, JDK, Android SDK, ADT are all installed and working with Eclipse). Hope this helps, Alex -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: lockNow() API throws error on a few LG phones
anyone? On Jan 30, 3:55 pm, Priyank priyankvma...@gmail.com wrote: Hi, I am trying to use the lockNow() method from the DevicePolicyManager. It works fine for most of the phones I have tested. But on a couple of LG phones, the method is throwing a null pointer exception. The LG phones I am getting this error are: LG Vortex(Android Version 2.2.2) LG Enlighten (Android Version 2.3.4). I also saw this post with a similar problem sometime back but no positive answers to it: http://groups.google.com/group/android-developers/browse_thread/threa... Could someone help me with this. Thanks, Priyank -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] VideoView and buffering
John-Marc, I am glad that it works. I am not sure whether prepareAsync would be quicker than blocking prepare call. I mean that whatever the system implementation of the player, preparing it takes the same amount of time and async call simply does not block, but if you call play as a next statement after prepareAsync, I think playing will be put on hold until the player is ready to play. You could test both approaches by adding some logging and swapping these calls to prepare. I was also thinking that you could create 2 MediaPlayer objects and the one that is not playing at the moment is being prepared in the background with the new data that arrived. In MediaPlayer.OnCompletionListener of the first player you simply cause the background, prepared player to swap seats with the one that just finished. Maybe that would be a bit smoother... ( I am only speculating here). This is simple double buffering used all over computers to avoid flickering when displaying moving objects. Not the easiest approach, but if you are swapping the files from underneath 1 player, then swapping players from underneath 1 activity should not be much more complex. Daniel On 31 January 2012 14:50, John-Marc Desmarais j...@ieee.org wrote: Hi, I'm using the reset() now. There's a little bump in the playback every time it reaches the end of the content that existed in the file when it was initially loaded which I don't like but I'm using prepareAsync so I think this hiccup is as small as I can make it with a single VideoView. Thanks for your help. -jm On Mon, Jan 30, 2012 at 11:16 AM, Daniel Drozdzewski daniel.drozdzew...@gmail.com wrote: John-Marc, I have not done this myself, but here is tutorial on how to do it: http://blog.pocketjourney.com/2008/04/04/tutorial-custom-media-streaming-for-androids-mediaplayer/ They actually create new MediaPlayer object upon every update to the buffer file and point this new MediaPlayer to the updated buffer every single time. I would test calling MediaPlayer.reset() first instead of creating new player object every time, to see whether time and memory consumed by such solution is a bit better. HTH, Daniel On 30 January 2012 15:49, John-Marc Desmarais j...@ieee.org wrote: Hi, I am currently writing a video file to the SDCard while playing it with VideoView. My problem is that, if I buffer 1MB of video and begin the Video playback, the video stops after 1MB has been played, even though by this time, 5MBs of file has now been written to the sdcard. I have been trying various things in onCompletion handler.. such as: int curLoc = mp.getCurrentPosition(); Log.e(LogName.onCompletion, LogName.onCompletion + CurrentLocation: + mp.getCurrentPosition()); Log.e(LogName.onCompletion, LogName.onCompletion + Duration: + mp.getDuration()); mp.pause(); mp.prepareAsync(); mp.start(); mp.seekTo(curLoc); In this case I get a Cannot play video message. Or: int curLoc = mp.getCurrentPosition(); Log.e(LogName.onCompletion, LogName.onCompletion + CurrentLocation: + mp.getCurrentPosition()); Log.e(LogName.onCompletion, LogName.onCompletion + Duration: + mp.getDuration()); mp.prepareAsync(); mp.start(); mp.seekTo(curLoc); This crashes with prepare Async in State 128. Has anyone solved the problem of re-queuing file in the videoView so that it plays everything that has been written to the sdcard even though it starts with a smaller file? Regards, -jm -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Daniel Drozdzewski -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send
Re: [android-developers] Edittext Scrolling
On Tue, Jan 31, 2012 at 7:27 AM, aru padam deepesh...@gmail.com wrote: How i can possible to scroll through the edit text. Try setting the maxlines property. Or show your layout. - 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: Edittext Scrolling
Hmm I'm not 100% clear, but I think that you will get the behavior that you want if you extend the EditText class and override the onTouchEvent() method: public boolean onTouchEvent(MotionEvent ev) { boolean canScroll = !this.isFocusable() || !this.isEnabled() || (this.isFocused() this.isFocusable() this.isEnabled() ); if (ev.getAction() == MotionEvent.ACTION_DOWN canScroll) { this.getParent().requestDisallowInterceptTouchEvent(true); } if (ev.getAction() == MotionEvent.ACTION_UP) { this.getParent().requestDisallowInterceptTouchEvent(false); } return super.onTouchEvent(ev); } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] VideoView and buffering
Daniel, It is my feeling that since the swap is being done in the onCompletion handler, there would be a gap in playback in either case. If prepare is the time consuming part of Prepare(), Start(), Seekto().. then I can see this shrinking the gap. But, if there is a detectable delay, then the length of this delay is of lesser concern. If I get the time to go back to this component when I'm done some other bits, I'll let you know how it turns out. I find it odd that the VideoView screen doesn't ever re-read from the file. I've tried buffering 1MB or 2MB before starting to play, but it still doesn't go back to the file to read more data, I'm guessing it loads all 2MB into memory before starting to play. I'll try some bigger buffer sizes as well to see if I can force it to reread before the video runs out. -jm On Tue, Jan 31, 2012 at 11:08 AM, Daniel Drozdzewski daniel.drozdzew...@gmail.com wrote: John-Marc, I am glad that it works. I am not sure whether prepareAsync would be quicker than blocking prepare call. I mean that whatever the system implementation of the player, preparing it takes the same amount of time and async call simply does not block, but if you call play as a next statement after prepareAsync, I think playing will be put on hold until the player is ready to play. You could test both approaches by adding some logging and swapping these calls to prepare. I was also thinking that you could create 2 MediaPlayer objects and the one that is not playing at the moment is being prepared in the background with the new data that arrived. In MediaPlayer.OnCompletionListener of the first player you simply cause the background, prepared player to swap seats with the one that just finished. Maybe that would be a bit smoother... ( I am only speculating here). This is simple double buffering used all over computers to avoid flickering when displaying moving objects. Not the easiest approach, but if you are swapping the files from underneath 1 player, then swapping players from underneath 1 activity should not be much more complex. Daniel On 31 January 2012 14:50, John-Marc Desmarais j...@ieee.org wrote: Hi, I'm using the reset() now. There's a little bump in the playback every time it reaches the end of the content that existed in the file when it was initially loaded which I don't like but I'm using prepareAsync so I think this hiccup is as small as I can make it with a single VideoView. Thanks for your help. -jm On Mon, Jan 30, 2012 at 11:16 AM, Daniel Drozdzewski daniel.drozdzew...@gmail.com wrote: John-Marc, I have not done this myself, but here is tutorial on how to do it: http://blog.pocketjourney.com/2008/04/04/tutorial-custom-media-streaming-for-androids-mediaplayer/ They actually create new MediaPlayer object upon every update to the buffer file and point this new MediaPlayer to the updated buffer every single time. I would test calling MediaPlayer.reset() first instead of creating new player object every time, to see whether time and memory consumed by such solution is a bit better. HTH, Daniel On 30 January 2012 15:49, John-Marc Desmarais j...@ieee.org wrote: Hi, I am currently writing a video file to the SDCard while playing it with VideoView. My problem is that, if I buffer 1MB of video and begin the Video playback, the video stops after 1MB has been played, even though by this time, 5MBs of file has now been written to the sdcard. I have been trying various things in onCompletion handler.. such as: int curLoc = mp.getCurrentPosition(); Log.e(LogName.onCompletion, LogName.onCompletion + CurrentLocation: + mp.getCurrentPosition()); Log.e(LogName.onCompletion, LogName.onCompletion + Duration: + mp.getDuration()); mp.pause(); mp.prepareAsync(); mp.start(); mp.seekTo(curLoc); In this case I get a Cannot play video message. Or: int curLoc = mp.getCurrentPosition(); Log.e(LogName.onCompletion, LogName.onCompletion + CurrentLocation: + mp.getCurrentPosition()); Log.e(LogName.onCompletion, LogName.onCompletion + Duration: + mp.getDuration()); mp.prepareAsync(); mp.start(); mp.seekTo(curLoc); This crashes with prepare Async in State 128. Has anyone solved the problem of re-queuing file in the videoView so that it plays everything that has been written to the sdcard even though it starts with a smaller file? Regards, -jm -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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:eclipse plugin phonegap
Hi iam working android project my apps targeting cross platform like blackberry,iphone where can i get phoneGap plugin for eclipse ganymade can any one share the link might useful very 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] still having problems with gridview and spacing.
Hello I am still having a problem with gridview and spacing. Would love to talk to someone regarding the issue. I've considered chaning text orientation for column headings or using two line text. Here is more info including screenshots: http://netskink.blogspot.com/2012/01/gridview-take2-issues.html -- John F. Davis 独树一帜 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: eclipse plugin phonegap
You can do it here: http://docs.phonegap.com/en/1.4.0/guide_getting-started_android_index.md.html#Getting%20Started%20with%20Android I set it up today. It is very easy to get started. They have their own Google group here: http://groups.google.com/group/phonegap Cheers, Glen On Jan 31, 4:58 pm, Jagadeesh mjagadeeshb...@gmail.com wrote: Hi iam working android project my apps targeting cross platform like blackberry,iphone where can i get phoneGap plugin for eclipse ganymade can any one share the link might useful very 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] Re: eclipse plugin phonegap
I think the phonegap download includes an eclipse plugin. On Jan 31, 8:58 am, Jagadeesh mjagadeeshb...@gmail.com wrote: Hi iam working android project my apps targeting cross platform like blackberry,iphone where can i get phoneGap plugin for eclipse ganymade can any one share the link might useful very 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] Re: clearAnimation() Causes onAnimationEnd to fire Twice?? Please Help
Hi, I saw this problem as well. To workaround it I created a boolean flag in my anonymous instance of AnimationListener so that it only happens once. animSet.setAnimationListener(new AnimationListener() { private boolean ended = false; @Override public void onAnimationEnd(Animation animation) { if (ended) return; ended = true; animation.reset(); clearAnimation(); ... Cheers, Brady On Dec 16 2011, 6:06 pm, Tommy Hartz droi...@gmail.com wrote: Hi, I am trying to fade an ImageView Out, change the Image, then fade it back in. Here is the code I am using: private void fadeOut(){ AnimationSet myAnimationOut = new AnimationSet(true); myAnimationOut.setAnimationListener(new AnimationListener(){ @Override public void onAnimationEnd(Animation arg0) { currWeatherAdRotator.clearAnimation(); if(currAd == 0){ currWeatherAdRotator.setBackgroundResource(R.drawable.lbanner2); currAd = 1; }else if(currAd == 1){ currWeatherAdRotator.setBackgroundResource(R.drawable.lbanner3); currAd = 2; }else if(currAd == 2){ currWeatherAdRotator.setBackgroundResource(R.drawable.lbanner4); currAd = 3; }else if(currAd == 3){ currWeatherAdRotator.setBackgroundResource(R.drawable.lbanner1); currAd = 0; } fadeIn(); } @Override public void onAnimationRepeat(Animation arg0) { // TODO Auto-generated method stub } @Override public void onAnimationStart(Animation arg0) { // TODO Auto-generated method stub } }); It seems however that currWeatherAdRotator.clearAnimation(); causes this bit of code to run twice which messes up my sequence. If I remove currWeatherAdRotator.clearAnimation(); It creates a black flicker at the end of the animation. I have the fadeout feature set up on a timer that goes off every 15 seconds. I tried creating a new class that extends the ImageView (as I read was a work around) but when I do this I can't run my timers because I get an error when calling runOnUiThread. Basically I want to rotate through these image every 15 seconds continuously. Can someone please tell me how I can do this or what I am doing wrong? Thanks 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
[android-developers] Re: clearAnimation() Causes onAnimationEnd to fire Twice?? Please Help
Hi, I saw this problem as well. To workaround it I created a boolean flag in my anonymous instance of AnimationListener so that it only happens once. animSet.setAnimationListener(new AnimationListener() { private boolean ended = false; @Override public void onAnimationEnd(Animation animation) { if (ended) return; ended = true; animation.reset(); clearAnimation(); ... Cheers, Brady On Dec 16 2011, 6:06 pm, Tommy Hartz droi...@gmail.com wrote: Hi, I am trying to fade an ImageView Out, change the Image, then fade it back in. Here is the code I am using: private void fadeOut(){ AnimationSet myAnimationOut = new AnimationSet(true); myAnimationOut.setAnimationListener(new AnimationListener(){ @Override public void onAnimationEnd(Animation arg0) { currWeatherAdRotator.clearAnimation(); if(currAd == 0){ currWeatherAdRotator.setBackgroundResource(R.drawable.lbanner2); currAd = 1; }else if(currAd == 1){ currWeatherAdRotator.setBackgroundResource(R.drawable.lbanner3); currAd = 2; }else if(currAd == 2){ currWeatherAdRotator.setBackgroundResource(R.drawable.lbanner4); currAd = 3; }else if(currAd == 3){ currWeatherAdRotator.setBackgroundResource(R.drawable.lbanner1); currAd = 0; } fadeIn(); } @Override public void onAnimationRepeat(Animation arg0) { // TODO Auto-generated method stub } @Override public void onAnimationStart(Animation arg0) { // TODO Auto-generated method stub } }); It seems however that currWeatherAdRotator.clearAnimation(); causes this bit of code to run twice which messes up my sequence. If I remove currWeatherAdRotator.clearAnimation(); It creates a black flicker at the end of the animation. I have the fadeout feature set up on a timer that goes off every 15 seconds. I tried creating a new class that extends the ImageView (as I read was a work around) but when I do this I can't run my timers because I get an error when calling runOnUiThread. Basically I want to rotate through these image every 15 seconds continuously. Can someone please tell me how I can do this or what I am doing wrong? Thanks 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
[android-developers] Quick question about Quick Actions
Hi, I don't see Quick Actions metaphor over at Android Design guide ( http://developer.android.com/design/index.html). Is that metaphor not being endorsed? Has it been de-favoured in favour of Multi-panel Layouts, Swipe Views and Action Bar? So instead of having Quick Actions on item in a list view, now I should swipe it to get to detail and have Actions on the bar there? I'd like to know before I spend too much time messing about the Quick Actions. 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] Re: WebView problem with youtube video
Hi John, thanks for your replay. I'm usign Honeycomb on a tablet. Unfortunally the order of the loading url don't resolve the problem. I'm try with this code: setContentView(R.layout.video); final WebView webView = (WebView) findViewById(R.id.video_webview); webView.getSettings().setJavaScriptEnabled(true); webView.getSettings().setPluginsEnabled(true); webView.loadUrl(getString(R.string.urlYouTube)); You can test this simple code with some video on youtube and you realize that you can see the preview image of the video but when you click on play button the video don't start!! Moreover if you click on maximise icon of the video the application crash as you can see here: 01-31 20:41:24.778: E/AndroidRuntime(399): FATAL EXCEPTION: main 01-31 20:41:24.778: E/AndroidRuntime(399): java.lang.NullPointerException 01-31 20:41:24.778: E/AndroidRuntime(399): at android.webkit.HTML5VideoFullScreen.enterFullScreenVideoState(HTML5VideoFullScreen.java: 253) 01-31 20:41:24.778: E/AndroidRuntime(399): at android.webkit.HTML5VideoViewProxy $VideoPlayer.enterFullScreenVideo(HTML5VideoViewProxy.java:161) 01-31 20:41:24.778: E/AndroidRuntime(399): at android.webkit.HTML5VideoViewProxy.enterFullScreenVideo(HTML5VideoViewProxy.java: 667) 01-31 20:41:24.778: E/AndroidRuntime(399): at android.webkit.WebView $PrivateHandler.handleMessage(WebView.java:8017) 01-31 20:41:24.778: E/AndroidRuntime(399): at android.os.Handler.dispatchMessage(Handler.java:99) 01-31 20:41:24.778: E/AndroidRuntime(399): at android.os.Looper.loop(Looper.java:132) 01-31 20:41:24.778: E/AndroidRuntime(399): at android.app.ActivityThread.main(ActivityThread.java:4123) 01-31 20:41:24.778: E/AndroidRuntime(399): at java.lang.reflect.Method.invokeNative(Native Method) 01-31 20:41:24.778: E/AndroidRuntime(399): at java.lang.reflect.Method.invoke(Method.java:491) 01-31 20:41:24.778: E/AndroidRuntime(399): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:841) 01-31 20:41:24.778: E/AndroidRuntime(399): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:599) 01-31 20:41:24.778: E/AndroidRuntime(399): at dalvik.system.NativeStart.main(Native Method) Thanks very much Best regards Daniele On Jan 31, 1:02 pm, John Purcell jsp...@gmail.com wrote: In general, the loading of the URL should come last (right now you've got plugins and Javascript enabled messages being sent to the webcore after you send a url request). Is this on Honeycomb or ICS? (I'm guessing ICS due to the 'normal' errors you posted above). Keep in mind that video needs special handling in older versions of android (well, in all versions really).http://code.google.com/p/html5webview/will work for 2.x, but is out of date for 3.x/4.x On Jan 30, 3:34 pm, drenda daniele.re...@gmail.com wrote: PLease, someone has some ideas? Thanks! On 29 Gen, 22:38, drenda daniele.re...@gmail.com wrote: Hi, i made a simple example in order to display in my app some youtube's video of a playlist. I created a WebView: @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); try { setContentView(R.layout.video); final WebView webView = (WebView) findViewById(R.id.video_webview); webView.loadUrl(getString(R.string.urlYouTube)); webView.getSettings().setJavaScriptEnabled(true); webView.getSettings().setPluginsEnabled(true); } catch (Exception e) { Log.e(Rubner, e.getMessage()); e.printStackTrace(); } The webview is render correctly and display the videos of playlist. When you click on a video is displayed the page of the video with play button but if you click on it the video don't start!!! Are raised these errors: 01-29 22:37:28.714: W/System.err(5963): Error reading from ./org/ apache/harmony/luni/internal/net/www/protocol/data/Handler.class 01-29 22:37:28.934: E/libEGL(5963): call to OpenGL ES API with no current context (logged once per thread) 01-29 22:37:28.934: D/ShaderProgram(5963): couldn't load the vertex shader! Any ideas of the problem?? Thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Quick question about Quick Actions
I can tell you that the Contacts app no longer uses the Android 2.x-style quick actions balloon. Tapping a contact photo now brings up a dialog that contains all the stuff the quick actions balloon used to, but it looks substantially different. On Tue, Jan 31, 2012 at 3:00 PM, gnugu rho...@gmail.com wrote: Hi, I don't see Quick Actions metaphor over at Android Design guide (http://developer.android.com/design/index.html). Is that metaphor not being endorsed? Has it been de-favoured in favour of Multi-panel Layouts, Swipe Views and Action Bar? So instead of having Quick Actions on item in a list view, now I should swipe it to get to detail and have Actions on the bar there? I'd like to know before I spend too much time messing about the Quick Actions. 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 -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Simulating Mouse Click
Thank you for your reply Kris. I am trying to create a low-level mapping where some button press on my 22-button device is to be seen as left click, by following this configuration: http://source.android.com/tech/input/key-layout-files.html I know Android is a flexible system and without rooting a device, it is TOTALLY possible to create your own input device as a mouse + keyboard + touchpad + braille + whatever kind of input you wish to send to android. (NOT simulate keys, but actually send the corresponding byes for Left Click or Right Click or move pointer). Consider a professional artists who purchases a digital drawing pad *with* a stylus pen for accuracy and all his/her drawings on the drawing pad are directly sent to Android as legit mouse or stylus events. This includes the pressure of the lines drawn as well, without having to directly simulate each event. It just seems that not one Google employee seems to know about this. Documentation is barely existent (and whatever is there is very poor), books don't help (not one book dares touch on this topic). I've gone back and forth all over the web to find an answer and unfortunately, only someone in this area of expertise can actually help me. What better place to post a question about Android than the source itself? Thank you, Dritan p.s. If I don't get a reply from a competent Google employee (or really, anyone who's competent in this area), I shall re-post this question with a different title, every single week. I don't want to root the phone, nor do I feel like re-compiling the source to get the .java files for the source (even then it's a tremendous headache). Any help related directly to this matter is greatly appreciated, thank you! On Jan 30, 6:49 pm, Kristopher Micinski krismicin...@gmail.com wrote: Anyone have any experience with custom Bluetooth devices and simulating key mouse events? If View.performClick() is the only way, is there a way to obtain the view of the top Activity and inject a click event? (again, not clicking at an OK or Cancel, but merely register a click that the activity can pickup and pass it down as an event) This is also impossible: consider the background service that grabs the current view and records the contents of it to a log, which is then later sent out to my service. (I'm trying to point you at counterexamples so you'll have some rationale beyond just a you can't do that.) kris -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Quick question about Quick Actions
I noticed that too. I guess, they are going away from Quick Actions. Thanks Mark. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Simulating Mouse Click
On Tue, Jan 31, 2012 at 4:01 PM, Dritan djdea...@gmail.com wrote: Thank you for your reply Kris. I am trying to create a low-level mapping where some button press on my 22-button device is to be seen as left click, by following this configuration: http://source.android.com/tech/input/key-layout-files.html I know Android is a flexible system and without rooting a device, it is TOTALLY possible to create your own input device as a mouse + keyboard + touchpad + braille + whatever kind of input you wish to send to android. (NOT simulate keys, but actually send the corresponding byes for Left Click or Right Click or move pointer). I totally agree with you. It's not that what you're doing is fundamentally flawed, it's that you're thinking about it the wrong way. You're looking to solve it using the naive hackey behavior typical of malware. You have to remember that your app would be potentially killed off at any time, so even if you launched it as a background and were able to register clicks to the toplevel view, your app could always annoyingly disappear! Consider a professional artists who purchases a digital drawing pad *with* a stylus pen for accuracy and all his/her drawings on the drawing pad are directly sent to Android as legit mouse or stylus events. This includes the pressure of the lines drawn as well, without having to directly simulate each event. True. It just seems that not one Google employee seems to know about this. Documentation is barely existent (and whatever is there is very poor), books don't help (not one book dares touch on this topic). I've gone back and forth all over the web to find an answer and unfortunately, only someone in this area of expertise can actually help me. Well, to be fair, this list isn't something that Google is responsible for answering questions on. What better place to post a question about Android than the source itself? Personally I did not know that you could add such low level support at the application level. The only thing I'm aware of is adding HID profiles, and the docs for those are here: http://source.android.com/tech/input/overview.html Thank you, Dritan p.s. If I don't get a reply from a competent Google employee (or really, anyone who's competent in this area), I shall re-post this question with a different title, every single week. I don't want to root the phone, nor do I feel like re-compiling the source to get the .java files for the source (even then it's a tremendous headache). Any help related directly to this matter is greatly appreciated, thank you! That's a very passive aggressive threat.. I'm sure the discussion around the office will be something like did you answer that guy yet, tom? No, he said he would repost every week until I did, I figured I'd see how long he could keep it up. What do you mean by recompiling the source to get the java files for the source? That doesn't make any sense, you already have all the system source, it's in the public repository, and you can browse and modify it yourself. The reason you don't want to do so is that if you do, nobody will have your hacked firmware, unless Google accepted your patch, which they might do. Your problem is that what you're wanting to write isn't an app, it's a driver for the device. You won't be able to do that through an app, the system doesn't work like that. There isn't much HID support, from cupcake onward, iirc, because it's just not very mature. There are some projects out there aiming to support this eventually, but I don't know a general way to get support for your device on Android if it has to do lower level things.. http://code.google.com/p/androhid/ For example kris -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Home screed Widget crash
The failed binder transaction issue basically happens whenever you send data too fast to an AppWidget, where too fast is loosely defined. You can definitely cause it by sending 1MB at once, but you can also get it by sending much smaller quantities at too fast a rate. Which is what it sounds like you're doing. Your best solution is probably to create a content provider and have your widget access that directly for the images, which will avoid the RemoteViews (and thus the binder which is causing the problem). A Google search for *image content provider* should get you started. Having said all that, updating an AppWidget with an image every 15 seconds sounds like a recipe for battery drain. You might want to test that hypothesis, see how bad the power drain is before you go to the trouble of re-implementing the image delivery mechanism. You may need to rethink your concept at a deeper level instead. 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] Re: Simulating Mouse Click
On Tue, Jan 31, 2012 at 4:01 PM, Dritan djdea...@gmail.com wrote: I am trying to create a low-level mapping where some button press on my 22-button device is to be seen as left click, by following this configuration: http://source.android.com/tech/input/key-layout-files.html I know Android is a flexible system and without rooting a device, it is TOTALLY possible to create your own input device as a mouse + keyboard + touchpad + braille + whatever kind of input you wish to send to android. (NOT simulate keys, but actually send the corresponding byes for Left Click or Right Click or move pointer). Not at the SDK level. You mentioned that your device uses the Bluetooth HID profile. Find some existing Bluetooth mouse/keyboard/whatever that has the behaviors you want, and reverse-engineer how they're doing it through the Bluetooth HID profile. Or, follow the Bluetooth HID standards, which I am sure are written up somewhere. Or, visit http://source.android.com, click on the Community tab, find the right Google Group that might deal with hardware driver issues, and inquire there about their level of Bluetooth HID support. This Google Group is for development with the Android SDK. It is absolutely is not possible for an ordinary SDK application to inject input events to arbitrary applications on unrooted devices. That would represent a world-class security flaw. Consider a professional artists who purchases a digital drawing pad *with* a stylus pen for accuracy and all his/her drawings on the drawing pad are directly sent to Android as legit mouse or stylus events. This includes the pressure of the lines drawn as well, without having to directly simulate each event. AFAIK, all of which would have be handled through the existing Bluetooth HID support, or possibly via patches to improve the Bluetooth HID support. It just seems that not one Google employee seems to know about this. Oh, I am certain a few do. You will have better luck once you ask on a relevant list, one that would pertain to the functionality of the Bluetooth HID drivers. books don't help (not one book dares touch on this topic). There is an Android internals book that I know of that is under development, but I don't know how much the author will go into Bluetooth profiles, let alone how much that will be useful to you. Heck, I don't even know when he'll get it done, though I've pestered him about it. p.s. If I don't get a reply from a competent Google employee (or really, anyone who's competent in this area), I shall re-post this question with a different title, every single week. OMG! How will we cope? If only somebody had invented the email filter, so that we can block people who attack us with unwanted messages! Without this, we're doomed! Doomed, I say! -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: EditText in ListView footer not visible when the soft keyboard is present
The problem is that the list activity is contained in a tab activity that needs to set to adjustPan. When I make the tab activity adjustResize too, everything works as expected. I'm guessing I'll need to work some magic in code. Does anyone have an suggestions on where to start? Thanks. On Jan 30, 9:34 am, ivan istas...@gmail.com wrote: Anyone? On Jan 27, 12:44 pm, ivan istas...@gmail.com wrote: I have a ListView and I'm placing an EditText view in its footer, but the soft keyboard blocks the EditText view when it pops up. My AndroidManifest has: activity android:name=com.myapp.views.activities.StoresSearchActivity android:label=@string/appName android:screenOrientation=portrait android:launchMode=singleInstance android:windowSoftInputMode=adjustResize / My activity layout: ListView android:id=@+id/stores_preferredStores xmlns:android=http://schemas.android.com/apk/res/android; android:orientation=vertical android:layout_width=fill_parent android:layout_height=fill_parent android:dividerHeight=0dp android:divider=# android:overScrollFooter=@null / My footer is a complex view with a couple different buttons and an edit text view so it doesn't make sense to not have it scroll with the list view, being so tall. My footer layout: RelativeLayout xmlns:android=http://schemas.android.com/apk/res/ android android:id=@+id/footerlayout android:layout_width=fill_parent android:layout_height=wrap_content android:layout_marginBottom=10dp TextView android:layout_height=wrap_content android:id=@+id/store_search_text android:text=@string/store_search_find_header_text android:layout_width=fill_parent android:layout_marginLeft=10dp android:layout_marginRight=10dp android:textColor=@color/white android:layout_alignParentLeft=true /TextView Button android:id=@+id/store_search_use_location_button android:layout_width=fill_parent android:layout_marginTop=10dp android:layout_height=40dp android:layout_below=@id/store_search_text android:text=@string/store_search_location_button_text android:layout_alignLeft=@id/store_search_text android:layout_alignRight=@id/store_search_text style=@style/ActionButton.LtBlue /Button TextView android:layout_height=wrap_content android:id=@+id/store_search_or android:text=Or android:textColor=@color/white android:layout_width=fill_parent android:layout_marginTop=10dp android:layout_below=@id/ store_search_use_location_button android:layout_alignLeft=@+id/ store_search_use_location_button android:layout_alignRight=@+id/ store_search_use_location_button /TextView EditText android:layout_height=wrap_content android:id=@+id/store_search_query android:layout_width=fill_parent android:layout_marginLeft=10dp android:layout_marginRight=10dp android:layout_marginTop=10dp android:paddingLeft=5dp android:layout_below=@id/store_search_or android:hint=@string/search_hint android:inputType=textPostalAddress android:imeOptions=actionDone /EditText Button android:id=@+id/store_search_find_location android:layout_width=fill_parent android:layout_height=40dp android:layout_below=@id/store_search_query android:text=@string/ store_search_find_location_button_text android:layout_alignLeft=@+id/store_search_query android:layout_alignRight=@+id/store_search_query style=@style/ActionButton.LtBlue /Button /RelativeLayout I've set up an OnScrollListener, and it appears the ListView is not getting resized as it should when the soft keyboard pops up. Does anyone have any ideas on how I can get the EditText above the soft keyboard? Thanks. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Automatic word wrap for views?
Won't a GridView 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: WebView using Assets
Thanks. It was the form of URL I was missing. On Jan 31, 1:19 pm, Mark Murphy mmur...@commonsware.com wrote: On Tue, Jan 31, 2012 at 5:31 AM, atcal alan.williams...@ya.com wrote: I'd like to use html (with images, btw) to provide documentation for my app. I thought to store my documentation pages in assets and use webview but I cannot find a way to link the webview to the assets. Does anyone know if this is possible? webView.loadUrl(file:///android_asset/path/to/your/file.html) works fine. -- Mark Murphy (a Commons Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: NFC Secure Element
Fernando, In that case, what's api to send apdu to external SE and how can we have external SE added to the phone. regards malls -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] AR.Drone compilation for Android
All, Has anyone got the ARDrone API 1.8 example code and ARDroneLib compiled on a recent version of Android NDK? I would love some direction I have wasted so much time it is not funny. Damien -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: In-App Billing Tracking By Android Market
I assume then that during an uninstall and reinstall of the Lite version that my app will have to check the market to see if the user had previously purchased the advanced capabilities and then unlock those during the install. It still seems like the user is misinformed as to which version of the app he is using from a market perspective. On Jan 31, 9:56 am, TreKing treking...@gmail.com wrote: On Tue, Jan 31, 2012 at 8:49 AM, beachboy jfma...@gmail.com wrote: how does the market know that I have unlocked these features and that the Lite version is really now the Paid version? It doesn't - *your app* would check if the user bought the unlock item and react accordingly. --- -- 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: NFC Secure Element
Fernando, I was wondering if I can emulate the card in my application and send it to the terminal. regards malls -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Strange behavior with Theme.DeviceDefault.Light
Just to let everyone who stumbles upon this that I had the confirmation from Adam Powel that this was a bug that slipped through, it has been fixed for the next update. Problem 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
[android-developers] Need architecture guidance in reference to a social app
i need to know how an actual developer might solve this problem . I have the app on my device and so do you. In the app i write a message and this message is passed to your app . You open and your app are notified a new message awaits. The action you take in reference to this message generates a notification to me and an update to facebook. This action also generates a date and time that will populate another activity on your app and mine. I am thinking sqllite running off the sd on each device Question: How do i handle the exchange between the two devices. Am i going to need a server to accomplish this? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: In-App Billing Tracking By Android Market
On Tue, Jan 31, 2012 at 5:49 PM, beachboy jfma...@gmail.com wrote: I assume then that during an uninstall and reinstall of the Lite version that my app will have to check the market to see if the user had previously purchased the advanced capabilities Right. and then unlock those during the install. No. You can't do anything during the install. You check when you run. It still seems like the user is misinformed as to which version of the app he is using from a market perspective. I don't know what you mean. - 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: How to test Activity, which is run in the separate process (android.process=:process in the manifest file)
Hello, Sarcasm is not necessary. Just try to imagine, that devs have changed a very big application's design a bit to use separate processes and as a result you have lost almost 4 human years of work. All UI tests. And all Continious Integration servers became useless, because there are no tests to run anymore. I would love to laugh with you on my problem after we find the solution, but now there are nothing to laugh on.. Best regards, Yahor On Tue, Jan 31, 2012 at 3:43 PM, Mark Murphy mmur...@commonsware.comwrote: On Tue, Jan 31, 2012 at 8:36 AM, Yahor Paulavets ypaulav...@agilefusion.com wrote: It is not my app, it is app I have to test. And it is not testable, because it has :separate processes. Ah, my apologies. Please direct my rants to the developers, who should have their heads examined. I wonder to know, is there are any way to test such processes? I doubt it, at least in terms of ActivityInstrumentationTestCase2 and kin. Android does some magic to load your test cases into the same process as the main app; I'll be rather surprised if they can somehow magically extend that to other processes and coordinate between them. Or, to look at it another way, if Diego Torres Milano did not have a solution for you, then it is likely that no such solution exists -- he's probably the world's leading expert on this subject. You could try monkeyrunner, as that has a chance of handling multiple processes. Or how can I submit a bug/ask google/whatever to get the answer or direction.. You are welcome to file a feature request at http://b.android.com. That will not help you in the short term. update: if I remove :process separate process definition in the manifest file, application crashes and there are no way to run it without separate process definition. That is because the developers wrote a lousy app. If monkeyrunner does not fit your needs, report back to whoever assigned this app to you that the app is untestable in its current state, and that the developers should remove the android:process attributes and fix their app. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.7 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Need architecture guidance in reference to a social app
Why not just send an SMS message, and look for a particular beginning to a message, perhaps. You can read this blog to see how to read messages: http://droidcoders.blogspot.com/2011/09/sms-receive.html On Tue, Jan 31, 2012 at 8:20 PM, leftcont...@gmail.com leftcont...@gmail.com wrote: i need to know how an actual developer might solve this problem . I have the app on my device and so do you. In the app i write a message and this message is passed to your app . You open and your app are notified a new message awaits. The action you take in reference to this message generates a notification to me and an update to facebook. This action also generates a date and time that will populate another activity on your app and mine. I am thinking sqllite running off the sd on each device Question: How do i handle the exchange between the two devices. Am i going to need a server to accomplish this? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- I know that you believe you understand what you think I said, but I'm not sure you realize that what you heard is not what I meant. - Robert McCloskey -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] AR.Drone compilation for Android
On Tue, Jan 31, 2012 at 5:04 PM, Damien Cooke cooke.dam...@gmail.comwrote: Has anyone got the ARDrone API 1.8 example code and ARDroneLib compiled on a recent version of Android NDK? I would love some direction I have wasted so much time it is not funny. There is a separate list for NDK related questions. - 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] c2dn on simulator ?
On Tue, Jan 31, 2012 at 4:48 AM, Jags jag...@gmail.com wrote: is there any beginner tutorial for c2dm ? http://tinyurl.com/7egymyf - 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] Need architecture guidance in reference to a social app
Question: How do i handle the exchange between the two devices. Am i going to need a server to accomplish this? The basic answer is: yes. You *do* need a server to accomplish this. Having a backend solution is probably the most feasible path, and it's done the majority of the time. There are other ways, sms, bluetooth, email, etc... But these aren't really as common as using a web backend. kris -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Simulating Mouse Click
OK so first things first, yes I was kind of angry/upset because it seemed like I had tried all possible routes and have no solution. I apologize if my threat to re-post this question every week (lol) came off too strong. But honestly, I've been at this for nearly a month where I bought a Bluetooth adapter for $80 and hooked it up to Arduino as my driver- interface. I used Arduino to communicate with the adapter, but because the adapter does not have a HID profile, I am kind of stuck. (Re-)write a HID profile? how to add profile to BT stack? Re-invent the wheel? Are my #googling skills up to par? So I resorted to reading a bluetooth stream from the device via BT. I manually send signals to Arduino (from button or typing) which get sent over BT to the tablet. I've got IME's down. But for mouse clicks and motions and pressure and all the goodies ... I've been royally stuck :( I'm sorry but in the name of learning I shall continue to ask! ..and thank you for replying :) Dritan On Jan 31, 1:20 pm, Kristopher Micinski krismicin...@gmail.com wrote: On Tue, Jan 31, 2012 at 4:01 PM, Dritan djdea...@gmail.com wrote: Thank you for your reply Kris. I am trying to create a low-level mapping where some button press on my 22-button device is to be seen as leftclick, by following this configuration:http://source.android.com/tech/input/key-layout-files.html I know Android is a flexible system and without rooting a device, it is TOTALLY possible to create your own input device as amouse+ keyboard + touchpad + braille + whatever kind of input you wish to send to android. (NOT simulate keys, but actually send the corresponding byes for LeftClick or RightClick or move pointer). I totally agree with you. It's not that what you're doing is fundamentally flawed, it's that you're thinking about it the wrong way. You're looking to solve it using the naive hackey behavior typical of malware. You have to remember that your app would be potentially killed off at any time, so even if you launched it as a background and were able to register clicks to the toplevel view, your app could always annoyingly disappear! Consider a professional artists who purchases a digital drawing pad *with* a stylus pen for accuracy and all his/her drawings on the drawing pad are directly sent to Android as legitmouseor stylus events. This includes the pressure of the lines drawn as well, without having to directly simulate each event. True. It just seems that not one Google employee seems to know about this. Documentation is barely existent (and whatever is there is very poor), books don't help (not one book dares touch on this topic). I've gone back and forth all over the web to find an answer and unfortunately, only someone in this area of expertise can actually help me. Well, to be fair, this list isn't something that Google is responsible for answering questions on. What better place to post a question about Android than the source itself? Personally I did not know that you could add such low level support at the application level. The only thing I'm aware of is adding HID profiles, and the docs for those are here: http://source.android.com/tech/input/overview.html Thank you, Dritan p.s. If I don't get a reply from a competent Google employee (or really, anyone who's competent in this area), I shall re-post this question with a different title, every single week. I don't want to root the phone, nor do I feel like re-compiling the source to get the .java files for the source (even then it's a tremendous headache). Any help related directly to this matter is greatly appreciated, thank you! That's a very passive aggressive threat.. I'm sure the discussion around the office will be something like did you answer that guy yet, tom? No, he said he would repost every week until I did, I figured I'd see how long he could keep it up. What do you mean by recompiling the source to get the java files for the source? That doesn't make any sense, you already have all the system source, it's in the public repository, and you can browse and modify it yourself. The reason you don't want to do so is that if you do, nobody will have your hacked firmware, unless Google accepted your patch, which they might do. Your problem is that what you're wanting to write isn't an app, it's a driver for the device. You won't be able to do that through an app, the system doesn't work like that. There isn't much HID support, from cupcake onward, iirc, because it's just not very mature. There are some projects out there aiming to support this eventually, but I don't know a general way to get support for your device on Android if it has to do lower level things.. http://code.google.com/p/androhid/ For example kris -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to
[android-developers] Remote administration in Android
Hi all, I am having a scenario like i have a procedure in my application for encrypting files and i have to call or initiate the procedure from a Remote server, so in a generic way i want to do Remote administration in Android, can someone please give me an idea about it, how it can be done in android? Is there any API available in android for doing this? any help is appreciated Thanks Chandra -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] alarm vs. service
I think I know the answer, but will this alarm continue to repeat if the phone is rebooted? If not, should I use a Service instead? I want to use the alarm to send out a Notification every few hours. // AlarmActivity.java public class AlarmActivityAlarmController extends Activity { Toast mToast; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); // Watch for button clicks. //Button button = (Button)findViewById(R.id.one_shot); //button.setOnClickListener(mOneShotListener); Button button = (Button)findViewById(R.id.start_repeating); button.setOnClickListener(mStartRepeatingListener); button = (Button)findViewById(R.id.stop_repeating); button.setOnClickListener(mStopRepeatingListener); } private OnClickListener mStartRepeatingListener = new OnClickListener() { public void onClick(View v) { // When the alarm goes off, we want to broadcast an Intent to our // BroadcastReceiver. Here we make an Intent with an explicit class // name to have our own receiver (which has been published in // AndroidManifest.xml) instantiated and called, and then create an // IntentSender to have the intent executed as a broadcast. // Note that unlike above, this IntentSender is configured to // allow itself to be sent multiple times. Intent intent = new Intent(AlarmActivity.this, RepeatingAlarm.class); PendingIntent sender = PendingIntent.getBroadcast(AlarmActivity.this, 0, intent, 0); // We want the alarm to go off 30 seconds from now. long firstTime = SystemClock.elapsedRealtime(); firstTime += 5*1000; // Schedule the alarm! AlarmManager am = (AlarmManager)getSystemService(ALARM_SERVICE); am.setRepeating(AlarmManager.ELAPSED_REALTIME_WAKEUP, firstTime, 3*60*60*1000, sender); // Tell the user about what we did. if (mToast != null) { mToast.cancel(); } mToast = Toast.makeText(AlarmActivity.this, Started: Repeating Alarm (every 5s), Toast.LENGTH_SHORT); mToast.show(); } }; private OnClickListener mStopRepeatingListener = new OnClickListener() { public void onClick(View v) { // Create the same intent, and thus a matching IntentSender, for // the one that was scheduled. Intent intent = new Intent(AlarmActivity.this, RepeatingAlarm.class); PendingIntent sender = PendingIntent.getBroadcast(AlarmActivity.this, 0, intent, 0); // And cancel the alarm. AlarmManager am = (AlarmManager)getSystemService(ALARM_SERVICE); am.cancel(sender); // Tell the user about what we did. if (mToast != null) { mToast.cancel(); } mToast = Toast.makeText(AlarmActivity.this, Stopped: Repeating Alarm, Toast.LENGTH_SHORT); mToast.show(); } }; } // RepeatingAlarm.java public class RepeatingAlarm extends BroadcastReceiver { @Override public void onReceive(Context context, Intent intent) { //HACK: http://stackoverflow.com/questions/368094/system-currenttimemillis-vs-new-date-vs-calendar-getinstance-gettime Toast.makeText(context, Repeating Alarm now!, Toast.LENGTH_SHORT).show(); // Send a notification. } } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: In-App Billing Tracking By Android Market
The preferred route would be to convert the paid app to use in-app billing and make it free. But this can only be done once the suggestion here has been implemented: http://code.google.com/p/marketbilling/issues/detail?id=17#c7 Then you could ditch the free version altogether. However, please note that non-paid app countries (e.g. China and Taiwan) cannot see free apps that use in-app billing. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] alarm vs. service
Can you register your app to receive the on boot broadcast and then start the alarm manager there? kris On Wed, Feb 1, 2012 at 12:52 AM, Anuj Goyal anuj.go...@gmail.com wrote: I think I know the answer, but will this alarm continue to repeat if the phone is rebooted? If not, should I use a Service instead? I want to use the alarm to send out a Notification every few hours. // AlarmActivity.java public class AlarmActivityAlarmController extends Activity { Toast mToast; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); // Watch for button clicks. // Button button = (Button)findViewById(R.id.one_shot); // button.setOnClickListener(mOneShotListener); Button button = (Button)findViewById(R.id.start_repeating); button.setOnClickListener(mStartRepeatingListener); button = (Button)findViewById(R.id.stop_repeating); button.setOnClickListener(mStopRepeatingListener); } private OnClickListener mStartRepeatingListener = new OnClickListener() { public void onClick(View v) { // When the alarm goes off, we want to broadcast an Intent to our // BroadcastReceiver. Here we make an Intent with an explicit class // name to have our own receiver (which has been published in // AndroidManifest.xml) instantiated and called, and then create an // IntentSender to have the intent executed as a broadcast. // Note that unlike above, this IntentSender is configured to // allow itself to be sent multiple times. Intent intent = new Intent(AlarmActivity.this, RepeatingAlarm.class); PendingIntent sender = PendingIntent.getBroadcast(AlarmActivity.this, 0, intent, 0); // We want the alarm to go off 30 seconds from now. long firstTime = SystemClock.elapsedRealtime(); firstTime += 5*1000; // Schedule the alarm! AlarmManager am = (AlarmManager)getSystemService(ALARM_SERVICE); am.setRepeating(AlarmManager.ELAPSED_REALTIME_WAKEUP, firstTime, 3*60*60*1000, sender); // Tell the user about what we did. if (mToast != null) { mToast.cancel(); } mToast = Toast.makeText(AlarmActivity.this, Started: Repeating Alarm (every 5s), Toast.LENGTH_SHORT); mToast.show(); } }; private OnClickListener mStopRepeatingListener = new OnClickListener() { public void onClick(View v) { // Create the same intent, and thus a matching IntentSender, for // the one that was scheduled. Intent intent = new Intent(AlarmActivity.this, RepeatingAlarm.class); PendingIntent sender = PendingIntent.getBroadcast(AlarmActivity.this, 0, intent, 0); // And cancel the alarm. AlarmManager am = (AlarmManager)getSystemService(ALARM_SERVICE); am.cancel(sender); // Tell the user about what we did. if (mToast != null) { mToast.cancel(); } mToast = Toast.makeText(AlarmActivity.this, Stopped: Repeating Alarm, Toast.LENGTH_SHORT); mToast.show(); } }; } // RepeatingAlarm.java public class RepeatingAlarm extends BroadcastReceiver { @Override public void onReceive(Context context, Intent intent) { //HACK: http://stackoverflow.com/questions/368094/system-currenttimemillis-vs-new-date-vs-calendar-getinstance-gettime Toast.makeText(context, Repeating Alarm now!, Toast.LENGTH_SHORT).show(); // Send a notification. } } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: ListView item into ListView
On Tue, Jan 31, 2012 at 1:46 AM, fala70 fal...@gmail.com wrote: then ? what is the best solution to use a list variable items into an item listview ? Hey, what about ExpandableListView? Try that, may be helpful for you. With Regards, NSR -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: ListView item into ListView
On Tue, Jan 31, 2012 at 1:46 AM, fala70 fal...@gmail.com wrote: then ? what is the best solution to use a list variable items into an item listview ? Hey, What about ExpandableListView? Try that, may be helpful for 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: In-App Billing Tracking By Android Market
On Wed, Feb 1, 2012 at 2:56 PM, Mark Carter mjc1...@googlemail.com wrote: However, please note that non-paid app countries (e.g. China and Taiwan) cannot see free apps that use in-app billing. Which kind of defeats the purpose of trying to have a single app. If you try to use IAB, you will get an error if it's not available, so why block the app from the Market? I guess they are just checking for the BILLING permission to filter, but still, why not let people use the free app. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: In-App Billing Tracking By Android Market
Which kind of defeats the purpose of trying to have a single app. If you try to use IAB, you will get an error if it's not available, so why block the app from the Market? I guess they are just checking for the BILLING permission to filter, but still, why not let people use the free app. It's clearly politics. Why not let people from Taiwan and PRC buy apps in the first place? 1+ billion potential customers. So it's politics. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: ExpandableListView How to get bitmap of each item separately
Hi Treking Thanks for your reply :) I am facing one issue even for getting bitmap of first group item. My group item layout/UI changes in expand and collapse state . If i get drawing cache in expand state i am getting bitmap correspond to collapse state ... How to get latest bitmap of corresponding group ? Thanks and regards Mansoor V.M -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] alarm vs. service
I could do that, but most material on the net seems to prefer using a Service. I have yet to see a webpage that nicely details the performance implications of using an Alarm vs. a Service. Even a short list of pros/cons for each class would be useful to me to understand the philosophy behind them. Currently they seem like they do similar things. http://www.androidenea.com/2009/09/starting-android-service-after-boot.html and http://androidcookbook.com/Recipe.seam;jsessionid=5424397F3130CE7769FF47DD67742911?recipeId=1662recipeFrom=ViewTOC Chapter4. Inter/Intra-Application Communicationhttp://androidcookbook.com/ChapterView.seam;jsessionid=5BE755569DB714C4A1AE979DFF1D82E5?chapterId=3610cid=77584 Contributed byAshwini Shahapurkarhttp://androidcookbook.com/Profile.seam;jsessionid=5BE755569DB714C4A1AE979DFF1D82E5?personId=1330 2011-05-24 11:33:24 (updated 2011-12-13 06:35:56) In Published Edition?Yes 2 Votes Problem You have a service in your app and you want it to start after the phone reboots. Solution You need to listen to intent for boot events and start the service when event occurs. Discussion Whenever the platform boot is completed, an intent with android.intent.action.BOOT_COMPLETED action is broadcasted. You need to register your application to receive this intent. For registering add this to your AndroidManifest.xml receiver android:name=ServiceManager intent-filter action android:name=android.intent.action.BOOT_COMPLETED / /intent-filter/receiver So you will have *ServiceManager* as broadcast receiver to receive the intent for boot event. The ServiceManager class shall be as follows: public class ServiceManager extends BroadcastReceiver { Context mContext; private final String BOOT_ACTION = android.intent.action.BOOT_COMPLETED; @Override public void onReceive(Context context, Intent intent) { // All registered broadcasts are received by thismContext = context; String action = intent.getAction(); if (action.equalsIgnoreCase(BOOT_ACTION)) { //check for boot complete event start your service startService(); } } private void startService() { //here, you will start your service Intent mServiceIntent = new Intent(); mServiceIntent.setAction(com.bootservice.test.DataService); mContext.startService(mServiceIntent); } } Since we are starting the Service, it too must be mentioned in AndroidManifest: service android:name=.LocationService intent-filter action android:name=com.bootservice.test.DataService/ /intent-filter/service The Service class must of course extend Service; for more on this see the recipe Keeping a Service running while other apps are on displayhttp://androidcookbook.com/Recipe.seam?recipeId=844title=Keeping%20a%20Service%20running%20while%20other%20apps%20are%20on%20display . Both the XML *receiver* and *service* definitions must be inside the * application* element in AndroidManifest.xml. There is no requirement to have any Activity in this application at all, but it will probably be more user-friendly if you do. In one example we have used a *PreferenceActivity* implementation as the main (and only) Activity of an app whose service is started at Reboot. On Tue, Jan 31, 2012 at 9:57 PM, Kristopher Micinski krismicin...@gmail.com wrote: Can you register your app to receive the on boot broadcast and then start the alarm manager there? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en