[android-developers] Re: Problem loading gadget
Sigh. It's not ONLY the XML, I just cited that as one example. My point is that this message can be easy to stumble into when upgrading your app. You need to be quite diligent about testing the upgrade process BEFORE you release it to the Market. But all that's for future reference if you've already released this. At this point, you just need to tell your users to delete and re-add the widget. And all that's assuming you don't have a runtime error causing the problem, as Mark said. 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] How to properly implement a custom AdapterView's setSelection method
I'm working on designing a HorizontalListView widget and I'm getting stuck on what to do with the setSelection methods. It seems like every example of extending an ArrayAdapter never touches this method. I can have a long list, so filling to the right from 0 - my position isn't an option. Ideally I'd like to have only one view created since my children are the entire width of the screen. I have a few variables to play with: mLeftViewIndex, mRightViewIndex, mOffset, mCurrentX, mNextX, but the combinations of the variables aren't happening. Can someone tell me roughly what is supposed to happen in the setSelection method? Am I just supposed to move the offset and set the view indexes? I know this is a bit vague, but looking for a high level answer. 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] Smoothing out Handler sent repaint events
Im having trouble smoothing out a hand made animation, specifically the logo on my site at www.users.on.net/~rossn The spinning sections of the logo are redrawn every frame rather a pair of rotating images, because rotating is slow and sometimes looks bad with poor rotation algorithms on other graphics libraries - the same code has been used over and over with a few different libraries now... I currently have a Handler which is sending a reoccuring repaint call to recalculate and redraw the lines. For the most part this works, but occasionally it becomes a bit choppy. I assume this is because other jobs are being processed by the same looper? Garbach collection maybe? Is it best to try and pull the redraw loop out into a seperate thread/Looper? I should note that Im not too keen on doing that because I'll be using the same setup later with game animations - the world will need to be updated between screen refreshes making syncing two threads a lot of hard work when one thread will do. Anyway here is code, with unrelated stuff removed and some names changed... The MyView class onDraw(), which is not shown, recalculates and redraws the lines of the logo on the view. public class MyClass extends Activity{ MyView view; @Override public void onCreate(Bundle savedInstanceState){ super.onCreate(savedInstanceState); requestWindowFeature(Window.FEATURE_NO_TITLE); getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN); view = new MyView(this); this.setContentView(view); new RefreshHandler().run(); } class RefreshHandler extends Handler implements Runnable{ @Override public void run(){ view.invalidate(); this.post(this); } } } -Numeron -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Get Row Id of draggable and droppable listview
Hi, I'm building a project using draggable and droppable listview. I found the source code of creating draggable and droppable listview supported by google. In my project , there are 4 items in listview ( search, list, history and shortcut). Each item in listview interacts with each activity. The problem is when I change position of items in listview the items in listview interact with wrong activities ( e.g search item iteracts with list activity instead of search item interacts with search activity) Could anybody give me a solution for this? 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] Marquee is not worked when screen rotate
Hi all, In my application I am using marquee. It works perfectly, but when I rotate screen then it is not working. following is my code. public class TextViewMarquee extends Activity { private TextView tv; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); tv = (TextView) this.findViewById(R.id.mywidget); tv.setSelected(true); // Set focus to the textview } } main.xml file is as ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/mywidget android:layout_width=wrap_content android:layout_height=wrap_content android:ellipsize=marquee android:fadingEdge=horizontal android:marqueeRepeatLimit=marquee_forever android:scrollHorizontally=true android:textColor=#ff4500 android:text=Simple application that shows how to use marquee, with a long text / /RelativeLayout what should I have to do so marquee also works after screen rotate? 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 do i upload the file from android mobile to public server
hi, y i didnt get any reply? i have tested this application from real device. i am getting IO Exception. i have posted the errror log below: kindly guide me to solve this problem. /kernel ( 115): [ 508.395324] device rmnet0 entered promiscuous mode W/System.err( 1281): java.io.IOException: Unable to connect to server: Unable to retrieve file: 550 W/System.err( 1281): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:203) W/System.err( 1281): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.getOutputStream(FtpURLConnection.java:339) W/System.err( 1281): at com.example.android.uplaod.MyFileupload.upload(MyFileupload.java:102) W/System.err( 1281): at com.example.android.uplaod.MyFileupload$1.onClick(MyFileupload.java:37) W/System.err( 1281): at android.view.View.performClick(View.java:2534) W/System.err( 1281): at android.view.View$PerformClick.run(View.java:9210) W/System.err( 1281): at android.os.Handler.handleCallback(Handler.java:587) W/System.err( 1281): at android.os.Handler.dispatchMessage(Handler.java:92) W/System.err( 1281): at android.os.Looper.loop(Looper.java:123) W/System.err( 1281): at android.app.ActivityThread.main(ActivityThread.java:3701) W/System.err( 1281): at java.lang.reflect.Method.invokeNative(Native Method) W/System.err( 1281): at java.lang.reflect.Method.invoke(Method.java:507) W/System.err( 1281): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:862) W/System.err( 1281): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:620) W/System.err( 1281): at dalvik.system.NativeStart.main(Native Method) I/System.out( 1281): connection opened W/System.err( 1281): java.io.IOException: Unable to connect to server: Unable to retrieve file: 550 W/System.err( 1281): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:203) W/System.err( 1281): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.getOutputStream(FtpURLConnection.java:339) W/System.err( 1281): at com.example.android.uplaod.MyFileupload.upload(MyFileupload.java:102) W/System.err( 1281): at com.example.android.uplaod.MyFileupload$1.onClick(MyFileupload.java:37) W/System.err( 1281): at android.view.View.performClick(View.java:2534) W/System.err( 1281): at android.view.View$PerformClick.run(View.java:9210) W/System.err( 1281): at android.os.Handler.handleCallback(Handler.java:587) W/System.err( 1281): at android.os.Handler.dispatchMessage(Handler.java:92) W/System.err( 1281): at android.os.Looper.loop(Looper.java:123) W/System.err( 1281): at android.app.ActivityThread.main(ActivityThread.java:3701) W/System.err( 1281): at java.lang.reflect.Method.invokeNative(Native Method) Thanks Regards Sneha On Thu, Mar 31, 2011 at 11:37 AM, snehalal gangadharam snehala...@gmail.com wrote: hi , i have debuged the code, i am getting IO Exception, 03-31 10:47:17.001: WARN/System.err(278): java.io.IOException: Unable to connect to server: null 03-31 10:47:17.061: WARN/System.err(278): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:204) 03-31 10:47:17.061: WARN/System.err(278): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.getOutputStream(FtpURLConnection.java:344) 03-31 10:47:17.061: WARN/System.err(278): at com.example.android.uplaod.MyFileupload.upload(MyFileupload.java:103) 03-31 10:47:17.072: WARN/System.err(278): at com.example.android.uplaod.MyFileupload$1.onClick(MyFileupload.java:37) 03-31 10:47:17.092: WARN/System.err(278): at android.view.View.performClick(View.java:2408) 03-31 10:47:17.092: WARN/System.err(278): at android.view.View$PerformClick.run(View.java:8816) 03-31 10:47:17.102: WARN/System.err(278): at android.os.Handler.handleCallback(Handler.java:587) 03-31 10:47:17.102: WARN/System.err(278): at android.os.Handler.dispatchMessage(Handler.java:92) 03-31 10:47:17.111: WARN/System.err(278): at android.os.Looper.loop(Looper.java:123) 03-31 10:47:17.111: WARN/System.err(278): at android.app.ActivityThread.main(ActivityThread.java:4627) 03-31 10:47:17.121: WARN/System.err(278): at java.lang.reflect.Method.invokeNative(Native Method) 03-31 10:47:17.121: WARN/System.err(278): at java.lang.reflect.Method.invoke(Method.java:521) 03-31 10:47:17.131: WARN/System.err(278): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868) 03-31 10:47:17.141: WARN/System.err(278): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626) 03-31 10:47:17.141: WARN/System.err(278): at dalvik.system.NativeStart.main(Native Method) Android not able to recognize the FTP server, Thanks Regards Aswini On Sat, Mar 26, 2011 at 5:17 AM, Nicholas Johnson metthejohn...@gmail.com wrote: I believe the first error that is causing
[android-developers] Re: Marquee is not worked when screen rotate
Create a bug report on http://b.android.com I dont' see anything wrong with your code. Using the emulator, try to determine on which Android SDK level it broke on and file a bug report. Put Regression, Honeycomb and 3.0 in the title, if it applies so that you get some Google people to pay attention. Don't expect a respone, but with any luck, it will be fixed in the next SDK update. On Apr 8, 2:37 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi all, In my application I am using marquee. It works perfectly, but when I rotate screen then it is not working. following is my code. public class TextViewMarquee extends Activity { private TextView tv; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); tv = (TextView) this.findViewById(R.id.mywidget); tv.setSelected(true); // Set focus to the textview } } main.xml file is as ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/mywidget android:layout_width=wrap_content android:layout_height=wrap_content android:ellipsize=marquee android:fadingEdge=horizontal android:marqueeRepeatLimit=marquee_forever android:scrollHorizontally=true android:textColor=#ff4500 android:text=Simple application that shows how to use marquee, with a long text / /RelativeLayout what should I have to do so marquee also works after screen rotate? 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 do i upload the file from android mobile to public server
Hi, may be this link will be helpful to u.. http://androidsnips.blogspot.com/2011_03_01_archive.html On Fri, Apr 8, 2011 at 11:36 AM, snehalal gangadharam snehala...@gmail.comwrote: hi, y i didnt get any reply? i have tested this application from real device. i am getting IO Exception. i have posted the errror log below: kindly guide me to solve this problem. /kernel ( 115): [ 508.395324] device rmnet0 entered promiscuous mode W/System.err( 1281): java.io.IOException: Unable to connect to server: Unable to retrieve file: 550 W/System.err( 1281): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:203) W/System.err( 1281): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.getOutputStream(FtpURLConnection.java:339) W/System.err( 1281): at com.example.android.uplaod.MyFileupload.upload(MyFileupload.java:102) W/System.err( 1281): at com.example.android.uplaod.MyFileupload$1.onClick(MyFileupload.java:37) W/System.err( 1281): at android.view.View.performClick(View.java:2534) W/System.err( 1281): at android.view.View$PerformClick.run(View.java:9210) W/System.err( 1281): at android.os.Handler.handleCallback(Handler.java:587) W/System.err( 1281): at android.os.Handler.dispatchMessage(Handler.java:92) W/System.err( 1281): at android.os.Looper.loop(Looper.java:123) W/System.err( 1281): at android.app.ActivityThread.main(ActivityThread.java:3701) W/System.err( 1281): at java.lang.reflect.Method.invokeNative(Native Method) W/System.err( 1281): at java.lang.reflect.Method.invoke(Method.java:507) W/System.err( 1281): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:862) W/System.err( 1281): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:620) W/System.err( 1281): at dalvik.system.NativeStart.main(Native Method) I/System.out( 1281): connection opened W/System.err( 1281): java.io.IOException: Unable to connect to server: Unable to retrieve file: 550 W/System.err( 1281): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:203) W/System.err( 1281): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.getOutputStream(FtpURLConnection.java:339) W/System.err( 1281): at com.example.android.uplaod.MyFileupload.upload(MyFileupload.java:102) W/System.err( 1281): at com.example.android.uplaod.MyFileupload$1.onClick(MyFileupload.java:37) W/System.err( 1281): at android.view.View.performClick(View.java:2534) W/System.err( 1281): at android.view.View$PerformClick.run(View.java:9210) W/System.err( 1281): at android.os.Handler.handleCallback(Handler.java:587) W/System.err( 1281): at android.os.Handler.dispatchMessage(Handler.java:92) W/System.err( 1281): at android.os.Looper.loop(Looper.java:123) W/System.err( 1281): at android.app.ActivityThread.main(ActivityThread.java:3701) W/System.err( 1281): at java.lang.reflect.Method.invokeNative(Native Method) Thanks Regards Sneha On Thu, Mar 31, 2011 at 11:37 AM, snehalal gangadharam snehala...@gmail.com wrote: hi , i have debuged the code, i am getting IO Exception, 03-31 10:47:17.001: WARN/System.err(278): java.io.IOException: Unable to connect to server: null 03-31 10:47:17.061: WARN/System.err(278): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:204) 03-31 10:47:17.061: WARN/System.err(278): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.getOutputStream(FtpURLConnection.java:344) 03-31 10:47:17.061: WARN/System.err(278): at com.example.android.uplaod.MyFileupload.upload(MyFileupload.java:103) 03-31 10:47:17.072: WARN/System.err(278): at com.example.android.uplaod.MyFileupload$1.onClick(MyFileupload.java:37) 03-31 10:47:17.092: WARN/System.err(278): at android.view.View.performClick(View.java:2408) 03-31 10:47:17.092: WARN/System.err(278): at android.view.View$PerformClick.run(View.java:8816) 03-31 10:47:17.102: WARN/System.err(278): at android.os.Handler.handleCallback(Handler.java:587) 03-31 10:47:17.102: WARN/System.err(278): at android.os.Handler.dispatchMessage(Handler.java:92) 03-31 10:47:17.111: WARN/System.err(278): at android.os.Looper.loop(Looper.java:123) 03-31 10:47:17.111: WARN/System.err(278): at android.app.ActivityThread.main(ActivityThread.java:4627) 03-31 10:47:17.121: WARN/System.err(278): at java.lang.reflect.Method.invokeNative(Native Method) 03-31 10:47:17.121: WARN/System.err(278): at java.lang.reflect.Method.invoke(Method.java:521) 03-31 10:47:17.131: WARN/System.err(278): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868) 03-31 10:47:17.141: WARN/System.err(278): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626) 03-31 10:47:17.141: WARN/System.err(278): at
[android-developers] RelativeLayout subclass ignoring explicit background color
I'm using a custom list item subclassed from a RelativeLayout, but the layout seems to be ignoring the background colour: my class looks like this: public class MyListItem extends RelativeLayout { public MyListItem(Context context) { super(context); } public MyListItem(Context context, AttributeSet attrs) { super(context, attrs); } public MyListItem(Context context, AttributeSet attrs, int defStyle) { super(context, attrs, defStyle); } public void bindViewInit(MessageList.MessageListAdapter adapter, boolean allowBatch) { ... capture values to work with touch events in the list item } public boolean onTouchEvent(MotionEvent event) { ... handle touch events on child components ... } } My layout looks like this: mypackage.MyListItem xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=match_parent android:layout_height=?android:attr/listPreferredItemHeight android:paddingRight=10dip android:background=@android:color/white other components ... /mypackage.MyListItem The problem is that MyListItem seems to be ignoring the background colour attribute set in the layout. I've also tried setting the background colour on the list view that contains the list item with no luck. Does anyone have any idea whats going on here? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Marquee is not worked when screen rotate
Hi, Zsolt Vasvari Thanks for reply. When I tried above code with large string message then marquee works properly. Is that mean marquee useful for only large string i.e to show large line data which is not fit into screen size? On Apr 8, 11:56 am, Zsolt Vasvari zvasv...@gmail.com wrote: Create a bug report onhttp://b.android.com I dont' see anything wrong with your code. Using the emulator, try to determine on which Android SDK level it broke on and file a bug report. Put Regression, Honeycomb and 3.0 in the title, if it applies so that you get some Google people to pay attention. Don't expect a respone, but with any luck, it will be fixed in the next SDK update. On Apr 8, 2:37 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi all, In my application I am using marquee. It works perfectly, but when I rotate screen then it is not working. following is my code. public class TextViewMarquee extends Activity { private TextView tv; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); tv = (TextView) this.findViewById(R.id.mywidget); tv.setSelected(true); // Set focus to the textview } } main.xml file is as ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/mywidget android:layout_width=wrap_content android:layout_height=wrap_content android:ellipsize=marquee android:fadingEdge=horizontal android:marqueeRepeatLimit=marquee_forever android:scrollHorizontally=true android:textColor=#ff4500 android:text=Simple application that shows how to use marquee, with a long text / /RelativeLayout what should I have to do so marquee also works after screen rotate? 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
[android-developers] Getting started with Android NDK
Hi, I have to use NDK for porting of my C/C++ code into ANDROID Game. Now that I am having problem to start with NDK. I have downloaded the NDK-r5b from developer.android.com But now, I am not even able to run the Hello-jni program provided within NDK samples. I have installed CYGWIN When i run: $ cd /cygdrive/c/android/android-ndk-r5b/samples/hello-jni $ ndk-build I get an ERROR: You are using a non-Cygwin compatible Make program. I tried installing GNUMake 3.81 but the problem persist. ** I tried to run HELLO-JNI sample program of NDK through Eclipse IDE There is force close on the Android AVD. logcat was showing exception like below - 04-08 12:32:11.609: ERROR/AndroidRuntime(274): FATAL EXCEPTION: main 04-08 12:32:11.609: ERROR/AndroidRuntime(274): java.lang.ExceptionInInitializerError 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at java.lang.Class.newInstanceImpl(Native Method) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at java.lang.Class.newInstance(Class.java:1429) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at android.app.Instrumentation.newActivity(Instrumentation.java:1021) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java: 2577) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java: 2679) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at android.app.ActivityThread.access$2300(ActivityThread.java:125) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2033) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at android.os.Handler.dispatchMessage(Handler.java:99) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at android.os.Looper.loop(Looper.java:123) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at android.app.ActivityThread.main(ActivityThread.java:4627) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at java.lang.reflect.Method.invokeNative(Native Method) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at java.lang.reflect.Method.invoke(Method.java:521) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:868) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at dalvik.system.NativeStart.main(Native Method) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): Caused by: java.lang.UnsatisfiedLinkError: Library hello-jni not found 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at java.lang.Runtime.loadLibrary(Runtime.java:461) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at java.lang.System.loadLibrary(System.java:557) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): at com.example.hellojni.HelloJni.clinit(HelloJni.java:67) 04-08 12:32:11.609: ERROR/AndroidRuntime(274): ... 15 more 04-08 12:32:11.678: WARN/ActivityManager(59): Force finishing activity com.example.hellojni/.HelloJni 04-08 12:32:12.340: WARN/ActivityManager(59): Activity pause timeout for HistoryRecord{44f925c8 com.example.hellojni/.HelloJni} Thanks in advance. Atul Prakash Singh -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] HttpURLConnection responsecode 414-url too long issue
Hi all, i have to download data but having big ur,l it's character is going to increase more than 4048, for small url it is working fine but for big url it has been giving response code 414- url too long. what would be feasible way to handle this issue? example of url is http://www.someserver.com/api/recipeBatch?
Re: [android-developers] Re: resizing the touch event generating area
Well sure if the device you are on can only recognize N fingers and the user has N+1 fingers, you aren't going to get a happy result. I'm not sure this is even worth thinking about. It's a limitation of that device, the user is going to live with this in every single part of the UI of that device, so it isn't like it is unexpected. I mean, if the device only recognizes 1 finger, why care about what happens if they have two fingers on the screen? On Thu, Apr 7, 2011 at 10:32 PM, andre andre.steingr...@gmail.com wrote: Thank you for your response, Dianne. I may need to verify this once again but it seemed to me (with the left hand on the screen and doing the actual signing with my right hand) that events in the ignore area already triggered the maximum number of multitouch pointers on this device (galaxy tab), with the consequence that ACTION_DOWN events in the signing area could not be received anymore. Andre -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Smoothing out Handler sent repaint events
I wouldn't suggest having a handler sitting there trying to post messages to itself as fast as possible. You are just writing code that sits there consuming every bit of CPU it can get for no useful reason. Either use postMessageDelayed/AtTime() to actually have controlled timing, or just do invalidate() each time you draw to tie to the frame rate. That said, if you are getting glitches of significantly less than 60fps than you simply have performance issues. Look at the log to see if you are GCing a lot (hint: you absolutely do not want to be creating temporary objects in your drawing path), and use the profiling to see what is taking a long time in your code. On Thu, Apr 7, 2011 at 11:29 PM, Numeron numeronreac...@gmail.com wrote: Im having trouble smoothing out a hand made animation, specifically the logo on my site at www.users.on.net/~rossn The spinning sections of the logo are redrawn every frame rather a pair of rotating images, because rotating is slow and sometimes looks bad with poor rotation algorithms on other graphics libraries - the same code has been used over and over with a few different libraries now... I currently have a Handler which is sending a reoccuring repaint call to recalculate and redraw the lines. For the most part this works, but occasionally it becomes a bit choppy. I assume this is because other jobs are being processed by the same looper? Garbach collection maybe? Is it best to try and pull the redraw loop out into a seperate thread/Looper? I should note that Im not too keen on doing that because I'll be using the same setup later with game animations - the world will need to be updated between screen refreshes making syncing two threads a lot of hard work when one thread will do. Anyway here is code, with unrelated stuff removed and some names changed... The MyView class onDraw(), which is not shown, recalculates and redraws the lines of the logo on the view. public class MyClass extends Activity{ MyView view; @Override public void onCreate(Bundle savedInstanceState){ super.onCreate(savedInstanceState); requestWindowFeature(Window.FEATURE_NO_TITLE); getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN); view = new MyView(this); this.setContentView(view); new RefreshHandler().run(); } class RefreshHandler extends Handler implements Runnable{ @Override public void run(){ view.invalidate(); this.post(this); } } } -Numeron -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Running multiple Services in Android
Hi, Services can run in there own separate processes if necessary you can also start run more threads in a service. http://developer.android.com/guide/topics/manifest/service-element.html Regards On Apr 8, 2:04 am, declantraynor dec...@gmail.com wrote: Hi, I'm currently building some movement-detection functionality into my application. I haven't found a way of continually monitoring the accelerometer without keeping the phone awake all the time. In trying to overcome this, I currently have a Service implementing SensorEventListener. I can start this service at intervals (using alarm manager), get readings from the device acclerometer, determine if the device is moving, and then shut down the service. Generally, this appears as follows: public class MyService extends Service implements SensorEventListener { @Override public void onCreate() { super.onCreate(); } @Override public int onStartCommand(Intent intent, int flags, int startId) { super.onStartCommand(intent, flags, startId); /* Register this SensorEventListener with Android sensor service */ return START_STICKY; } @Override public IBinder onBind(Intent intent) { return null; } @Override public void onDestroy() { /* Unregister SensorEventListener */ } /* SensorEventListener Implementation / @Override public void onAccuracyChanged(Sensor sensor, int accuracy) {} /* Receives callback when sensor values change */ @Override public void onSensorChanged(SensorEvent event) { /* Determine if moving then call stopSelf() to shut service down */ } } I have a further problem, however, in that my application has a second service which is invoked on a different schedule. As far as I know, both of the services will be run in the same thread, which is not good as they could conflict. I need to know if there is a safe way to run more than one service simultaneously within the same application. I have considered the use of IntentService instead of the standard Service class. I am aware that these implement their own worker thread for handling invocations. The problem there is that I have no idea how I can implement the type of asynchronous callbacks required by SensorEventListener from within an IntentService. To put it another way, I have no guarantee that a method like onSensorChanged will receive a callback before IntentService completes its work and shuts down. Any suggestions on a workaround to this problem are highly appreciated. Thanks, Declan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Setting screen on/off
Hi, I'm trying to develop something similar to the proximity event of the dialer during a call, this is: when something is near the proxmity sensor turn off the screen and when there's not power it on again. I've had no problem making the sensor's events work, that was easy, but I'm having a lot of trouble trying to set the screen on/off, this is what I've got this far: - I can power the screen off by setting brightness to zero (using the WindowManager.LayoutParams), the problem is that it locks the screen instead of just setting it off. - I've tried using a PowerManager.WakeLock to several things: - using as flag PARTIAL_WAKE_LOCK which should keep the cpu running but allowing the screen and keyboard to go off (but not actually setting them off at the moment, it waits for the configured timeout) - using as flag SCREEN_DIM_WAKE_LOCK | ACQUIRE_CAUSES_WAKEUP and then setting the screen off using the brightness trick but I still do have to manually press the button to bring the screen up. Now, I'm playing with some flags in the Window, but still nothing, I always do have to bring the screen back by pressing the power button. Any ideas/snippets to make this work like when you're inside a call in Android's default dialer? 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: Running multiple Services in Android
No please please do NOT run things in a separate process for this. That is a huge waste, for no reason. Since the sensor API is all callback based, there is no problem here. The callbacks will happen on the main thread. The main thread should always be responsive. No problem. If your other service has some long-running task, then do it on another thread (or use IntentService or AsyncTask or whatever). As long as you follow the general rule of not doing long running work on the main thread of the process, things will be fine. On Fri, Apr 8, 2011 at 12:24 AM, gjs garyjamessi...@gmail.com wrote: Hi, Services can run in there own separate processes if necessary you can also start run more threads in a service. http://developer.android.com/guide/topics/manifest/service-element.html Regards On Apr 8, 2:04 am, declantraynor dec...@gmail.com wrote: Hi, I'm currently building some movement-detection functionality into my application. I haven't found a way of continually monitoring the accelerometer without keeping the phone awake all the time. In trying to overcome this, I currently have a Service implementing SensorEventListener. I can start this service at intervals (using alarm manager), get readings from the device acclerometer, determine if the device is moving, and then shut down the service. Generally, this appears as follows: public class MyService extends Service implements SensorEventListener { @Override public void onCreate() { super.onCreate(); } @Override public int onStartCommand(Intent intent, int flags, int startId) { super.onStartCommand(intent, flags, startId); /* Register this SensorEventListener with Android sensor service */ return START_STICKY; } @Override public IBinder onBind(Intent intent) { return null; } @Override public void onDestroy() { /* Unregister SensorEventListener */ } /* SensorEventListener Implementation / @Override public void onAccuracyChanged(Sensor sensor, int accuracy) {} /* Receives callback when sensor values change */ @Override public void onSensorChanged(SensorEvent event) { /* Determine if moving then call stopSelf() to shut service down */ } } I have a further problem, however, in that my application has a second service which is invoked on a different schedule. As far as I know, both of the services will be run in the same thread, which is not good as they could conflict. I need to know if there is a safe way to run more than one service simultaneously within the same application. I have considered the use of IntentService instead of the standard Service class. I am aware that these implement their own worker thread for handling invocations. The problem there is that I have no idea how I can implement the type of asynchronous callbacks required by SensorEventListener from within an IntentService. To put it another way, I have no guarantee that a method like onSensorChanged will receive a callback before IntentService completes its work and shuts down. Any suggestions on a workaround to this problem are highly appreciated. Thanks, Declan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Setting screen on/off
Doing this kind of stuff from third party apps isn't really supported. You may be able to hack up a somewhat working solution, but I don't think you can actually implement a fully working robust solution with the SDK APIs. On Fri, Apr 8, 2011 at 12:24 AM, luiX_ lui...@gmail.com wrote: Hi, I'm trying to develop something similar to the proximity event of the dialer during a call, this is: when something is near the proxmity sensor turn off the screen and when there's not power it on again. I've had no problem making the sensor's events work, that was easy, but I'm having a lot of trouble trying to set the screen on/off, this is what I've got this far: - I can power the screen off by setting brightness to zero (using the WindowManager.LayoutParams), the problem is that it locks the screen instead of just setting it off. - I've tried using a PowerManager.WakeLock to several things: - using as flag PARTIAL_WAKE_LOCK which should keep the cpu running but allowing the screen and keyboard to go off (but not actually setting them off at the moment, it waits for the configured timeout) - using as flag SCREEN_DIM_WAKE_LOCK | ACQUIRE_CAUSES_WAKEUP and then setting the screen off using the brightness trick but I still do have to manually press the button to bring the screen up. Now, I'm playing with some flags in the Window, but still nothing, I always do have to bring the screen back by pressing the power button. Any ideas/snippets to make this work like when you're inside a call in Android's default dialer? 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 -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Marquee is not worked when screen rotate
Hi pramod, For me also it's working, whenever the string length is more. So that i have given the string like this string On Fri, Apr 8, 2011 at 12:36 PM, pramod.deore deore.pramo...@gmail.comwrote: Hi, Zsolt Vasvari Thanks for reply. When I tried above code with large string message then marquee works properly. Is that mean marquee useful for only large string i.e to show large line data which is not fit into screen size? On Apr 8, 11:56 am, Zsolt Vasvari zvasv...@gmail.com wrote: Create a bug report onhttp://b.android.com I dont' see anything wrong with your code. Using the emulator, try to determine on which Android SDK level it broke on and file a bug report. Put Regression, Honeycomb and 3.0 in the title, if it applies so that you get some Google people to pay attention. Don't expect a respone, but with any luck, it will be fixed in the next SDK update. On Apr 8, 2:37 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi all, In my application I am using marquee. It works perfectly, but when I rotate screen then it is not working. following is my code. public class TextViewMarquee extends Activity { private TextView tv; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); tv = (TextView) this.findViewById(R.id.mywidget); tv.setSelected(true); // Set focus to the textview } } main.xml file is as ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/mywidget android:layout_width=wrap_content android:layout_height=wrap_content android:ellipsize=marquee android:fadingEdge=horizontal android:marqueeRepeatLimit=marquee_forever android:scrollHorizontally=true android:textColor=#ff4500 android:text=Simple application that shows how to use marquee, with a long text / /RelativeLayout what should I have to do so marquee also works after screen rotate? 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: How to eliminate paint sawtooth
2011/4/8 a a harvey.a...@gmail.com: I draw a 30 degree line with paint, but it seams not smoothness. How can i eliminate the sawtooth? my code below: mPaint.setColor(Color.WHITE); mPaint.setAntiAlias(true); mPaint.setStrokeCap(Paint.Cap.ROUND); mPaint.setStyle(Paint.Style.STROKE); Canvas.drawLine(x1, y1, x2, y2, mPaint); That's ok. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: How to retrieve a JSON object from a php url to my android
look here, there are videos and the code attached that explain how to do http://www.embarcadero.com/rad-in-action/php-android On 7 Apr, 06:14, Jency Johnson jen...@gmail.com wrote: Hi, I am having this code HttpClient client = new DefaultHttpClient(); HttpGet request = new HttpGet(); request.setURI(new URI(uri)); HttpResponse response=client.execute(new HttpGet(uri)); InputStream ips = response.getEntity().getContent(); //String a = String(ips); BufferedReader buf = new BufferedReader(new InputStreamReader(ips,UTF-8)); But am not getting the result.Somebody please help. I want to get the JSON object in my android class. I have went through almost all questionnaires in this site. 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
[android-developers] Re: Marquee is not worked when screen rotate
Yes, that's correct. The marquee is only used when the text doesn't fit its container. On Apr 8, 3:06 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi, Zsolt Vasvari Thanks for reply. When I tried above code with large string message then marquee works properly. Is that mean marquee useful for only large string i.e to show large line data which is not fit into screen size? On Apr 8, 11:56 am, Zsolt Vasvari zvasv...@gmail.com wrote: Create a bug report onhttp://b.android.com I dont' see anything wrong with your code. Using the emulator, try to determine on which Android SDK level it broke on and file a bug report. Put Regression, Honeycomb and 3.0 in the title, if it applies so that you get some Google people to pay attention. Don't expect a respone, but with any luck, it will be fixed in the next SDK update. On Apr 8, 2:37 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi all, In my application I am using marquee. It works perfectly, but when I rotate screen then it is not working. following is my code. public class TextViewMarquee extends Activity { private TextView tv; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); tv = (TextView) this.findViewById(R.id.mywidget); tv.setSelected(true); // Set focus to the textview } } main.xml file is as ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/mywidget android:layout_width=wrap_content android:layout_height=wrap_content android:ellipsize=marquee android:fadingEdge=horizontal android:marqueeRepeatLimit=marquee_forever android:scrollHorizontally=true android:textColor=#ff4500 android:text=Simple application that shows how to use marquee, with a long text / /RelativeLayout what should I have to do so marquee also works after screen rotate? Thanks in advance- Hide quoted text - - Show quoted text - -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Marquee is not worked when screen rotate
Hi Abhilash, for lengthy string its working. try with smaller String like Test String and let me know marquee is working or not? I am using 2.1 Update1. API level is 7 On Apr 8, 12:37 pm, Abhilash baddam abhilash.androiddevelo...@gmail.com wrote: Hi pramod, For me also it's working, whenever the string length is more. So that i have given the string like this string On Fri, Apr 8, 2011 at 12:36 PM, pramod.deore deore.pramo...@gmail.comwrote: Hi, Zsolt Vasvari Thanks for reply. When I tried above code with large string message then marquee works properly. Is that mean marquee useful for only large string i.e to show large line data which is not fit into screen size? On Apr 8, 11:56 am, Zsolt Vasvari zvasv...@gmail.com wrote: Create a bug report onhttp://b.android.com I dont' see anything wrong with your code. Using the emulator, try to determine on which Android SDK level it broke on and file a bug report. Put Regression, Honeycomb and 3.0 in the title, if it applies so that you get some Google people to pay attention. Don't expect a respone, but with any luck, it will be fixed in the next SDK update. On Apr 8, 2:37 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi all, In my application I am using marquee. It works perfectly, but when I rotate screen then it is not working. following is my code. public class TextViewMarquee extends Activity { private TextView tv; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); tv = (TextView) this.findViewById(R.id.mywidget); tv.setSelected(true); // Set focus to the textview } } main.xml file is as ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/mywidget android:layout_width=wrap_content android:layout_height=wrap_content android:ellipsize=marquee android:fadingEdge=horizontal android:marqueeRepeatLimit=marquee_forever android:scrollHorizontally=true android:textColor=#ff4500 android:text=Simple application that shows how to use marquee, with a long text / /RelativeLayout what should I have to do so marquee also works after screen rotate? 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Marquee is not worked when screen rotate
Ok Zsolt Vasvari. Thanks for confirming. On Apr 8, 1:09 pm, Zsolt Vasvari zvasv...@gmail.com wrote: Yes, that's correct. The marquee is only used when the text doesn't fit its container. On Apr 8, 3:06 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi, Zsolt Vasvari Thanks for reply. When I tried above code with large string message then marquee works properly. Is that mean marquee useful for only large string i.e to show large line data which is not fit into screen size? On Apr 8, 11:56 am, Zsolt Vasvari zvasv...@gmail.com wrote: Create a bug report onhttp://b.android.com I dont' see anything wrong with your code. Using the emulator, try to determine on which Android SDK level it broke on and file a bug report. Put Regression, Honeycomb and 3.0 in the title, if it applies so that you get some Google people to pay attention. Don't expect a respone, but with any luck, it will be fixed in the next SDK update. On Apr 8, 2:37 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi all, In my application I am using marquee. It works perfectly, but when I rotate screen then it is not working. following is my code. public class TextViewMarquee extends Activity { private TextView tv; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); tv = (TextView) this.findViewById(R.id.mywidget); tv.setSelected(true); // Set focus to the textview } } main.xml file is as ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/mywidget android:layout_width=wrap_content android:layout_height=wrap_content android:ellipsize=marquee android:fadingEdge=horizontal android:marqueeRepeatLimit=marquee_forever android:scrollHorizontally=true android:textColor=#ff4500 android:text=Simple application that shows how to use marquee, with a long text / /RelativeLayout what should I have to do so marquee also works after screen rotate? Thanks in advance- Hide quoted text - - Show quoted text - -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Marquee is not worked when screen rotate
Hi Pramod, For small String its not working i am also using the same version. On Fri, Apr 8, 2011 at 1:42 PM, pramod.deore deore.pramo...@gmail.comwrote: Hi Abhilash, for lengthy string its working. try with smaller String like Test String and let me know marquee is working or not? I am using 2.1 Update1. API level is 7 On Apr 8, 12:37 pm, Abhilash baddam abhilash.androiddevelo...@gmail.com wrote: Hi pramod, For me also it's working, whenever the string length is more. So that i have given the string like this string On Fri, Apr 8, 2011 at 12:36 PM, pramod.deore deore.pramo...@gmail.com wrote: Hi, Zsolt Vasvari Thanks for reply. When I tried above code with large string message then marquee works properly. Is that mean marquee useful for only large string i.e to show large line data which is not fit into screen size? On Apr 8, 11:56 am, Zsolt Vasvari zvasv...@gmail.com wrote: Create a bug report onhttp://b.android.com I dont' see anything wrong with your code. Using the emulator, try to determine on which Android SDK level it broke on and file a bug report. Put Regression, Honeycomb and 3.0 in the title, if it applies so that you get some Google people to pay attention. Don't expect a respone, but with any luck, it will be fixed in the next SDK update. On Apr 8, 2:37 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi all, In my application I am using marquee. It works perfectly, but when I rotate screen then it is not working. following is my code. public class TextViewMarquee extends Activity { private TextView tv; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); tv = (TextView) this.findViewById(R.id.mywidget); tv.setSelected(true); // Set focus to the textview } } main.xml file is as ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/mywidget android:layout_width=wrap_content android:layout_height=wrap_content android:ellipsize=marquee android:fadingEdge=horizontal android:marqueeRepeatLimit=marquee_forever android:scrollHorizontally=true android:textColor=#ff4500 android:text=Simple application that shows how to use marquee, with a long text / /RelativeLayout what should I have to do so marquee also works after screen rotate? 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Smoothing out Handler sent repaint events
On Friday, April 8, 2011 4:51:23 PM UTC+9:30, Dianne Hackborn wrote: I wouldn't suggest having a handler sitting there trying to post messages to itself as fast as possible. You are just writing code that sits there consuming every bit of CPU it can get for no useful reason. Either use postMessageDelayed/AtTime() to actually have controlled timing, or just do invalidate() each time you draw to tie to the frame rate. I wouldnt have thought it would work like a busy method if its adding itself to something like an event queue or whatever, but I'll take your word on it. Having said that Im pretty sure that your suggestion to invalidate() at the end of onDraw() would turn out to be busy too. I have changed the line to this.postDelayed(this, 10); with no change in fps according to my code so that appears to be the best thing to do for the cpu anyway. That said, if you are getting glitches of significantly less than 60fps than you simply have performance issues. Look at the log to see if you are GCing a lot (hint: you absolutely do not want to be creating temporary objects in your drawing path), and use the profiling to see what is taking a long time in your code. I held my device up to my monitor so I could watch logcat and the animation at the same time, and it seems like it is the GC. It busts a move every 5-10 seconds and results in a split second jolt in the animation. I've poured through the code and pulled out many unnessecary temporary objects, but it will still need further work - thanks for that tip! -Numeron -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Audio initialization and recording
Hi, I'm having problem with audio initialization in Android. When application starts recording in logcat appears message I/libpjsip( 2248): 15:19:25.328 android_jni_de Record thread : error while reading data... is there something we can do here? -3 D/libpjsip( 2248): 15:19:25.328 Master/sound Underflow, buf_cnt=0, will generate 1 frame I/libpjsip( 2248): 15:19:25.342 android_jni_de Record thread : error while reading data... is there something we can do here? -3 D/libpjsip( 2248): 15:19:25.349 Master/sound Underflow, buf_cnt=0, will generate 1 frame I/libpjsip( 2248): 15:19:25.354 android_jni_de Record thread : error while reading data... is there something we can do here? -3 D/libpjsip( 2248): 15:19:25.357 Master/sound Underflow, buf_cnt=0, will generate 1 frame I/libpjsip( 2248): 15:19:25.367 android_jni_de Record thread : error while reading data... is there something we can do here? -3 D/libpjsip( 2248): 15:19:25.379 Master/sound Underflow, buf_cnt=0, will generate 1 frame I/libpjsip( 2248): 15:19:25.380 android_jni_de Record thread : error while reading data... is there something we can do here? -3 I/libpjsip( 2248): 15:19:25.393 android_jni_de Record thread : error while reading data... is there something we can do here? -3 D/libpjsip( 2248): 15:19:25.404 Master/sound Underflow, buf_cnt=0, will generate 1 frame I/libpjsip( 2248): 15:19:25.405 android_jni_de Record thread : error while reading data... is there something we can do here? -3 I/libpjsip( 2248): 15:19:25.418 android_jni_de Record thread : error while reading data... is there something we can do here? -3 I/libpjsip( 2248): 15:19:25.431 android_jni_de Record thread : error while reading data... is there something we can do here? -3 D/libpjsip( 2248): 15:19:25.434 Master/sound Underflow, buf_cnt=0, will generate 1 frame D/libpjsip( 2248): 15:19:25.439 Master/sound Underflow, buf_cnt=0, will generate 1 frame I/libpjsip( 2248): 15:19:25.444 android_jni_de Record thread : error while reading data... is there something we can do here? -3 I/libpjsip( 2248): 15:19:25.457 android_jni_de Record thread : error while reading data... is there something we can do here? -3 D/libpjsip( 2248): 15:19:25.460 Master/sound Underflow, buf_cnt=0, will generate 1 frame Can somebody tell me what's that message? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Intent not received after application started
Hi, I am trying to read NFC tags with my Nexus S mobile. In my Manifest file I have the intent filtered: intent-filter action android:name=android.nfc.action.NDEF_DISCOVERED/ data android:mimeType=*/* / category android:name=android.intent.category.DEFAULT/ /intent-filter When the mobile detects a tag and the intent is created by the system, my application is started. So, the filter works fine. The problem is that, once the application is opened via Intent, if the mobile detects another NDEF_DISCOVERED the application does not receive it. I have implemented the onNewIntent method, but it is not called. I also have added the android:launchMode=singleTop line to my activity. Does anyone know can I solve my problem? Thanks and bye. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Thread and ProgressDialog
Hi, you have to dissmiss progressdialog at the end of the method which you calling in thread bu using runonUIThread method. -- Thanks Regards, Kapil Lokhande | Dexter Advisory Pvt. Ltd. http://dexterltd.com/ | Android Developer [image: dexterlogo.jpg] On Fri, Apr 8, 2011 at 10:53 AM, pankaj pandey pankaj...@gmail.com wrote: Better suggestion, please use handler. Thanks On Fri, Apr 8, 2011 at 8:42 AM, TreKing treking...@gmail.com wrote: On Wed, Apr 6, 2011 at 10:10 PM, Kromosome m...@kromosome.net wrote: For starters you're still in the UI thread, your application is not multi threaded, try using a real thread What? Since when is a Thread not a real thread? - 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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=endexterlogo.jpg
[android-developers] In-app billing problem
Hi guys, I'm trying to integrate in-app billing in an app but for some reason I can't get the Dungeons sample app to work, even with static responses. What I've done is: - i've setup a publisher and merchant accounts - copied my public key from publisher profile in base64EncodedPublicKey in Security.java in Dungeons - uploaded a signed apk and installed the same on my phone - Motorola Milestone 2.1 with Market app 2.3.4 - using my developer's account and License Test Response is set to Licensed on the phone When I start the sample and select one of the static items - e.g. android.test.purchased, the payment screen with a VISA xxx-FAKE opens, but afterwards only shows Authorizing purchase and doesn't complete and nothing shows up in Items you own. Am I forgetting a step or my phone is the problem maybe? Do you have any idea before I start debugging the issue? Cheers, Ivan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Android Playing YouTube video in WebView
Hi, Use webview client. best example is on android developers | webview. go to http://developer.android.com/resources/tutorials/views/hello-webview.html -- Thanks Regards, Kapil Lokhande | Dexter Advisory Pvt. Ltd. http://dexterltd.com/ | Android Developer [image: dexterlogo.jpg] On Thu, Apr 7, 2011 at 7:24 PM, Dan danielmoses2...@gmail.com wrote: I am trying to implement a web browser within my app and using WebView for that. For playing youtube video I used the following resource to start playing the video: http://stackoverflow.com/questions/3815090/webview-and-html5-video To stay in the webView when a link is pressed and not go to the web browser, I had to add @Override public boolean shouldOverrideUrlLoading(WebView view, String url) { view.loadUrl(url); return true; } This seems to work well if I am touching the screen to start the video. However if I call webView.dispatchKeyEvent to navigate to the video image on the screen and then send a dispatchKeyEvent KEYCODE_DPAD_CENTER Down followed by up, the image shows loading and stays in the same state. So it did react to this key event but did not start playing the video. I noticed that if I touch on the video image, onShowCustomView is called in WebChromeClient. However, if the a KEYCODE_DPAD_CENTER is sent to the selected video image, shouldOverrideUrlLoading is called. Can anyone help how to get this video playing with a dispatchKeyEvent ? Thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=endexterlogo.jpg
Re: [android-developers] Re: Tab Layout not working
Hi, As u mentioned u r new to android. You may forget to declare tabs individual activity in manifest. -- Thanks Regards, Kapil Lokhande | Dexter Advisory Pvt. Ltd. http://dexterltd.com/ | Android Developer [image: dexterlogo.jpg] On Thu, Apr 7, 2011 at 9:34 PM, TreKing treking...@gmail.com wrote: On Thu, Apr 7, 2011 at 4:23 AM, Liunai tidolamiam...@gmail.com wrote: Actually, that's what I did... or at least tried to do. It seems that the problem is calling setContentView() with the reference to the XML, R.layout.datiattrib. Why does it seem that that's the problem? - 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=endexterlogo.jpg
Re: [android-developers] Re: Honeycomb Sourcecode
On 7 April 2011 21:06, JAlexoid (Aleksandr Panzin) jalex...@gmail.comwrote: Why would you need Honeycomb source? To see how some things are done? Regards, Marcin Orlowski *Tray Agenda http://bit.ly/trayagenda* - keep you daily schedule handy... WebnetMobile on *Facebook http://webnetmobile.com/fb/* and *Twitterhttp://webnetmobile.com/twitter/ * -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Help in android code syntax
On 8 April 2011 06:50, ahens h ahens...@gmail.com wrote: i want to write the same thing in android, can you people please help me out in this and let me know.. There's no writting in android. It's writting in Java Regards, Marcin Orlowski *Tray Agenda http://bit.ly/trayagenda* - keep you daily schedule handy... WebnetMobile on *Facebook http://webnetmobile.com/fb/* and *Twitterhttp://webnetmobile.com/twitter/ * -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Parsing data from a calender on a website
You should probably include the URL of the calendar application (if you can) if you expect any sort of useful response. But, since you've posted a question for an online calendar that apparently (?) loads the calendar dynamically with javascript you could try checking if the calendar uses any AJAX-service on the HTTP server to retrieve the calendar events (using for instance Firefox with the Firebug plug-in). That would typically yield a more parseable source of calendar data (such as a REST service returning JSON or XML) than trying to pick apart javascript. (Checking the TOS for the service might also be a nice gesture, they may not be too keen on 3rd parties piggy-backing on their calendar) On 6 Apr, 17:52, Neutron_boy arctikz...@gmail.com wrote: I am fairly new to Android, but have some experience reading and understanding code, including Java. My question is: If I want to parse a URL such as a calender from a web page, how do I go about this? My thoughts: To pull the XML, do I use text? i.e.: try { URL text = new URL( http:// and here is where I am not sure what to have. The script below is the source for the calender in the XML of the website script type=text/javascript src=9278a6f3de5f9e54f2aeeb74ac1f0a7eembedcompiled__en.js/script) Do I then follow with XmlPullParserFactgory parserCreator = XmlPullParserFactory.newInstance(); XmlPullParser parser = parserCreator.newPullParser(); parser.setInput(text.openStream(), null); Do I still use an open stream here? rest of code... Thanks in advance for the help and insoght -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Method startActivity is called twice from click on notification
On stackoverflow it was confirmed that it is a samsung bug: http://stackoverflow.com/questions/5538969 How to report bugs to samsung? Regards, Peter. -- http://jetwick.com - Personalized Twitter Search On 5 Apr., 00:11, Karussell tableyourt...@googlemail.com wrote: The strange thing is that it only occurs on my samsung device not in the emulator. I even reproduced it with a fresh mini project (from eclipse 'new project') creating only one notification (like in the gist) at startup. Clicking on that notification results in two calls of startActivity on device. It results only in one call of startActivity in emulator. Could this be a bug? Regards, Peter. On 4 Apr., 12:29, Karussell tableyourt...@googlemail.com wrote: Hi there, what is wrong when my activity is started twice when I click on the created notification? I'm creating the notification inside a thread of a service. Here is the creation code:https://gist.github.com/899952 I read that singleTop could solve this problem but I'm implementing a search so singleTop is not an option for me as I want to preserve history. Regards, Peter. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] How to use charts in android
On 7 April 2011 07:31, amey bura ameybur...@gmail.com wrote: I want use charts in my application.. Actually i want to draw varoius charts for example bar /pie chart by using the values from database.. so can anyone tell me how do i pass the values from my app to xml programs which is used for drawing the chart Refer to API documentation of the xml programs you intent do use? Regards, Marcin Orlowski *Tray Agenda http://bit.ly/trayagenda* - keep you daily schedule handy... WebnetMobile on *Facebook http://webnetmobile.com/fb/* and *Twitterhttp://webnetmobile.com/twitter/ * -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: OpenGL ES for Android tutorial
GDC 2011 had a better example for OGLES2.0 https://code.google.com/p/gdc2011-android-opengl/ On 5 Apr, 18:41, J javier.sed...@gmail.com wrote: Hi, anybody can sugest a tutorial for OpenGL ES on Android? The official documentation is not very extensive... Thanks, J -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] From I get API used in Script
Hi, I have written the following commands : import android import time ab = android.Android(1) ab.makeToast(Its rahul) in python file for blinking the name in the emulator screen and it works. I am using SDK2.2 platform with ASE_r_25. Maketoast is API. I just want to know all the APIs supported by ASE_r_25 or from where I get those APIs for the same -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: How do i upload the file from android mobile to public server
It seems like your error is occurring at line 203 in the FtpURLConnection class. Find out what's at the line, and you'll be closer to solving your problem. W/System.err( 1281): at org.apache.harmony.luni.internal.net.www.protocol.ftp.FtpURLConnection.connect(FtpURLConnection.java:203) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 problem
Ivan, I have same exact setup, also Milestone 2.1.1, and the rest is the same. Buying test items worked yesterday, but is not working now, same as for you: the transaction never completes. Looks like something in billing is just broken right now. I wonder how well it's going to work in production. BTW, when this happens, I also see logcat messages from GTalkService: W/GTalkService( 1364): [DataMsgMgr] broadcast intent callback: result=CANCELLED forIntent { act=android.intent.action.REMOTE_INTENT cat=[*com.android.vending.billing.IN_APP_NOTIFY*] (has extras) } W/GTalkService( 1364): TODO: implement reportNoReceiverError! Are you seeing this too? I wonder why GTalkService gets billing broadcasts, whether this is normal, and whether it aborts the broadcast causing it to not be seen by the Dungeon's billing receiver. -- Kostya 08.04.2011 13:14, Ivan ?: Hi guys, I'm trying to integrate in-app billing in an app but for some reason I can't get the Dungeons sample app to work, even with static responses. What I've done is: - i've setup a publisher and merchant accounts - copied my public key from publisher profile in base64EncodedPublicKey in Security.java in Dungeons - uploaded a signed apk and installed the same on my phone - Motorola Milestone 2.1 with Market app 2.3.4 - using my developer's account and License Test Response is set to Licensed on the phone When I start the sample and select one of the static items - e.g. android.test.purchased, the payment screen with a VISA xxx-FAKE opens, but afterwards only shows Authorizing purchase and doesn't complete and nothing shows up in Items you own. Am I forgetting a step or my phone is the problem maybe? Do you have any idea before I start debugging the issue? Cheers, Ivan -- Kostya Vasilyev -- http://kmansoft.wordpress.com -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] How do i Download the Mp3 file from server
Am a newbie to android development .Please let me know how can i download MP3 file from my server to my android sdcard folder. Please help me out. -Riyas -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Getting a delay between starting current activity after returning from startActivityForResult()
Hello guyz, I am facing problem with starting MainActivity again and perform remaining tasks, after returning from startActvityForREsult() My code structrue goes like: MainActivity{ // this method calls different activities of my application based on the result of onActivityResult startCustomActivity() ; } //Code goes like : Class MainActivity extends Activity{ startCustomActivity() { if( Condition1) { Intent subIntent = new Intent(); subIntent.setClassName(getApplicationContext(),com.android.SubActivity); subIntent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP); startActvityForResult(subIntent); startActivityForResult(subIntent,Constant.REQUEST_SUB_SCREEN); // REQUEST_SUB_SCREEN = 20; } else if (Condition 2) { //start activity 2 startActivityForResult(,..,..,); } else if (Condition3) { //start activity 3 startActivityForResult(,..,..,); } else if (Condition 4) { //start activity 4 } } onActivtyResult(,..,..,) { if(requestCode == Constant.REQUEST_SUB_SCREEN) { if(responseCode == RESULT_OK) { startCustomActivity(getIntent().getAction(), getIntent()); } } } AndroidManifest.xml activity android:name=com.android.SubActivity android:theme=@android:style/ Theme.Translucent.NoTitleBar.Fullscreen android:screenOrientation=sensor android:label=@string/ app_name1 android:icon=@drawable/qo !--android:noHistory = true this is not working as well -- intent-filter action android:name=android.intent.action.VIEW / category android:name=android.intent.category.DEFAULT / /intent-filter /activity SubActivity.java //Here on GoBack button, I want to send control back to calling Activity ii.e. MainActivity /// code starts GoBackButton.setOnClickListener(new OnClickListener() { public void onClick(View arg0) { setResult(RESULT_OK); finish(); causing problem } }); //code ends Whats happening is ... My control is going back to MainActiivty on pressing GOBack button, but the problem is since I am finishing SubAcitivty in GoBackButton itself, it takes some time for control to go back to onActivityResult() and do remaining task and launch another activity say Activity 2, as a result of which on pressing GoBack button, for few seconds , homeScreen (device homescreen) is dispalyed and then later, my activity2 gets launched. I want to remove that delay between GoBack button and launch of Activity2 I wan to end SubAcitivty as soon as user navigates away from this activity and send back control to calling activity. I also tried setting android:noHistory = true instead of calling finish() but nothing is working. Please help :( -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Getting started with Android NDK
On Fri, Apr 8, 2011 at 3:08 AM, Atul Prakash atul.prakas...@gmail.com wrote: I have to use NDK for porting of my C/C++ code into ANDROID Game. Now that I am having problem to start with NDK. Questions regarding the NDK are better asked on the [android-ndk] Google Group. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Video Call Recording Feature
There is no support for video calling in Android. On Fri, Apr 8, 2011 at 12:36 AM, Guna skarthikare...@gmail.com wrote: Can someone pls respond! On Mar 31, 10:17 am, Guna skarthikare...@gmail.com wrote: Please let me know whetherVideoCallRecordingis possible on Android Phones any version On Mar 30, 9:26 am, Guna skarthikare...@gmail.com wrote: Hello all, I am working onVideoCallRecording feature on 2.3, and wondering if this is possible with out any framework changes I mean as a stand alone application. Till now I have written the code working for VoiceCallRecording. I have 2 problems here: 1 Once the Voicecallis connected when I try to start the camcorder on thecallconnected Screen, its hanging and Camcorder screen never shows up. 2 Is it possible to record aVideoCall??? with regards, Guna -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Amazon MP3 store intents - quick how to.
On Thu, Apr 7, 2011 at 5:23 AM, Kent goo...@yourarcade.com wrote: It has been pretty difficult to track down information on interacting with the Amazon MP3 application. I do not believe that there are any documented and supported ways to interact with the Amazon MP3 application. Intent i = new Intent(); String query = SEARCH TERMS; i.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); i.setClassName(com.amazon.mp3, com.amazon.mp3.activity.IntentProxyActivity); i.setAction(MediaStore.INTENT_ACTION_MEDIA_SEARCH); i.putExtra(MediaStore.EXTRA_MEDIA_TITLE, query); This code may break for any Amazon MP3 app version that is not the one you tested. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] change icon notification when we drag
Hi All I would like to know is it possible to change different icon for notification when will drag status bar in notification list ? please help me any one thanks regards vinod -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Problem with ListAdapters and Cursors
Hello people, so I am trying to build a somewhat simple app where I am working with an array of objects where is of those objects had also an array of other objects. I have made this array a public variable and placed it in a class that extends Application. ( I found that on the net as the best way to have a public variable) So now that I have an Array of Objects, I need to display a list of names of those objects. Object has variables: mName, mArray (of objects), mLength and I need to display in my ListView a list of mNames. First problem I have is that I am not really into these cursors and adapters and second, I am not sure what is the best way to pass this global array variable. I know passing a global variable sounds weird but since I am initializing this variable in one class (class of the main View), and I am switching to another View where I want to show the contents of this array I am a bit stuck should I send this variable or somehow fetch a reference to it through this or whichever way. I must say I am a noob at this :-/ Thanks for any help or a pointer what to read. Tnx! D. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] ListView + Activity change
Hi! I created a ListActivity with 5 items. My goal: when I click on an item, the app switches to an other activity. I've tried with this code: protected void onListItemClick(ListView l, View v, int position, long id) { .. Intent i1 = new Intent(thisActivity.this, otherActivity.class); // also tried with this instead of thisActivity.this this.startActivity(i1); // and with startActivity(i1) ... } but I got runtime error. How can I solve this problem? Thank's for your help :) Peter -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: ListView + Activity change
did you define it in applicationmanifest.xml? On Apr 8, 1:59 pm, skera szrnka.pe...@gmail.com wrote: Hi! I created a ListActivity with 5 items. My goal: when I click on an item, the app switches to an other activity. I've tried with this code: protected void onListItemClick(ListView l, View v, int position, long id) { .. Intent i1 = new Intent(thisActivity.this, otherActivity.class); // also tried with this instead of thisActivity.this this.startActivity(i1); // and with startActivity(i1) ... } but I got runtime error. How can I solve this problem? Thank's for your help :) Peter -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: HttpURLConnection responsecode 414-url too long issue
http://developer.android.com/reference/org/apache/http/client/methods/HttpPost.html On Apr 8, 3:18 am, imran ali imran...@gmail.com wrote: Hi all, i have to download data but having big ur,l it's character is going to increase more than 4048, for small url it is working fine but for big url it has been giving response code 414- url too long. what would be feasible way to handle this issue? example of url is http://www.someserver.com/api/recipeBatch? ids=4851525ids=4853720ids=4856090ids=4856180ids=4856578ids=4856896ids =4857838ids=4868265ids=4870144ids=4872175ids=4873117ids=4874637ids=48 86446ids=4884421ids=4890580ids=4893541ids=4895198ids=4896616ids=48971 90ids=4906517ids=4910167ids=4910750ids=4914019ids=4914793ids=4930683 ids=4931662ids=4942292ids=4943674ids=4944087ids=4948064ids=4948689ids =4950569ids=4951079ids=4951158ids=4951458ids=4951527ids=4968303ids=49 87650ids=4998068ids=5011131ids=5030410ids=5032766ids=5038993ids=50421 14ids=5042926ids=5043864ids=5044355ids=5045172ids=5045455ids=5048149 ids=5048807ids=5049176ids=5050035ids=5051338ids=5051603ids=5058635ids =5063844ids=5064957ids=5064992ids=5067489ids=5071162ids=5071995ids=50 74463ids=5075159ids=5075857ids=5076056ids=5076121ids=5074881ids=50797 39ids=5081334ids=2234957ids=5081824ids=5085662ids=5085784ids=5086014 ids=5089511ids=5089553ids=5063887ids=5094282ids=5081529ids=5081567ids =5096193ids=5102101ids=5105007ids=5105954ids=5110247ids=5114009ids=51 31981ids=5133620ids=5134093ids=5134345ids=5134574ids=5135015ids=51353 87ids=5135757ids=5136048ids=5137546ids=5137622ids=5137745ids=5137816 ids=5137981ids=5138944ids=5134411ids=5143470ids=5143749ids=5146587ids =5148052ids=5148565ids=5148833ids=5149384ids=5150021ids=5149431ids=51 50738ids=5155419ids=5155465ids=5156683ids=5157055ids=5168327ids=51718 92ids=5171238ids=5175327ids=5180693ids=5192169ids=5192363ids=5196355 ids=5204192ids=5204372ids=5204860ids=5205023ids=5205544ids=5205815ids =5206266ids=5211308ids=5214898ids=5228889ids=5233501ids=5233752ids=52 33948ids=5234281ids=5237005ids=5250119ids=5256897ids=5264031ids=52681 46ids=5268248ids=5268345ids=5268803ids=5269131ids=5269407ids=5272693 ids=5273069ids=5273264ids=5273286ids=5273684ids=5273833ids=5274841ids =5280922ids=5280968ids=5283699ids=5284404ids=5292730ids=5293268ids=52 96919ids=5298108ids=5313136ids=5319462ids=5319589ids=5320884ids=53257 21ids=5330535ids=5346537ids=5346689ids=5347023ids=5347274ids=5347504 ids=5354776ids=5364266ids=5368271ids=5370416ids=5370695ids=5370848ids =5371469ids=5372480ids=5374462ids=5367607ids=5377061ids=5377768ids=53 77973ids=5380175ids=5388800ids=5389196ids=5393385ids=5395090ids=53960 43ids=5398021ids=5398133ids=5398277ids=5400158ids=5400360ids=5400567 ids=5400660ids=5404506ids=5404917ids=5405084ids=5405390ids=5405591ids =5410131ids=5410158ids=5410177ids=5410200ids=5419771ids=5420840ids=54 21226ids=5422793ids=5435538ids=5440539ids=5452083ids=5457859ids=54582 54ids=5464133ids=5467029ids=5473150ids=5492445ids=5500039ids=5500382 ids=5500701ids=5501816ids=5501859ids=5504442ids=5512085ids=5514683ids =5514979ids=5515818ids=5515958ids=5516139ids=5517592ids=5517934ids=55 22014ids=5524345ids=5524213ids=5524999ids=5525936ids=5528470ids=55189 25ids=5535751ids=5544083ids=5549827ids=5553861ids=5557141ids=5557332 ids=5557788ids=5569681ids=5572911ids=5581712ids=5616134ids=5620017ids =5620858ids=5625089ids=5631094ids=5634189ids=5644210ids=5646419ids=56 46812ids=5653376ids=5653936ids=5668329ids=5668650ids=5668926ids=56693 56ids=5669705ids=5670314ids=5685601ids=5688679ids=5695989ids=5698438 ids=5700271ids=5700853ids=5701107ids=5718198ids=5719235ids=5724791ids =5732743ids=5735801ids=5736687ids=5741333ids=5751399ids=5751528ids=57 48434ids=5767084ids=5772435ids=5772672ids=5776988ids=558ids=57782 44ids=5778564ids=5780645ids=5794202ids=5794524ids=5794907ids=5795444 ids=5795652ids=5795857ids=5796670ids=5796978ids=5798910ids=5799635ids =5806912ids=5809229ids=5810008ids=5810533ids=5810572ids=5810998ids=58 17312ids=5817409ids=5818307ids=5818462ids=5826072ids=5827867ids=58282 23ids=5831289ids=5841534ids=5844927ids=5851631ids=5857923ids=5860910 ids=5858071ids=5863100ids=5863346ids=5893542ids=5906079ids=5914916ids =5935483ids=5936232ids=5948072ids=5953829ids=5962154ids=5959319ids=59 66229ids=5966740ids=5968619ids=5971726ids=5974362ids=5976630ids=59839 31ids=5987191ids=5992672ids=5993869ids=5998552ids=6000219ids=6000344 ids=6000488ids=6005235ids=6008579ids=6008591ids=6015507ids=6030631ids =6032271ids=6036924ids=6040534ids=6045398ids=6045526ids=6045710ids=60 45895ids=6046061ids=6048340ids=6050146ids=2194788ids=6058039ids=60585 78ids=6069173ids=6069918ids=6054209ids=6072634ids=6072966ids=6073233 ids=6075626ids=6076013ids=6076909ids=6077398ids=6078627ids=6079009ids =6087207ids=6089341ids=6089598ids=6093264ids=6095279ids=6095590ids=20 52467ids=6101661ids=6102038ids=6116005ids=6126958ids=6137999ids=61393
[android-developers] Re: ListView + Activity change
Yes, I did. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: ListView + Activity change
It was an error I made a few times :) Don't know then, does the new class extend Activity? On Apr 8, 2:11 pm, skera szrnka.pe...@gmail.com wrote: Yes, I did. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: ListView + Activity change
Intent i = new Intent(this, yourNewClass.class); startActivity(i); If you get an error with that, post the exact runtime error you're getting and we can tell you what's wrong. On Apr 8, 8:11 am, skera szrnka.pe...@gmail.com wrote: Yes, I did. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Device Admin - Email account policy enforcement - pop and exchange
On Friday, April 8, 2011 6:16:12 AM UTC+1, progtad wrote: I would still like to get confirmation that this is not possible if I could. This is a corporate requirement I am looking into. I've been able to implement several of the requirements for android phones use acceptance but this one alludes me. Assuming this is not possible, can someone tell me if programmatic manipulation of email account setup for corporate policy enforcement, is being considered for future versions of Android. I understand your need for this information, but just a couple of tips... First, questions like is ___ possible are usually met with silence here, because very few people know definitively what is or is not possible. If extensive research didn't turn up an answer for you, it's likely that nobody here is in possession of that information either. Second, Google virtually never reveals development plans for Android, so I'm afraid you're not likely to get an answer to that one either. If you've satisfied yourself that you can't find a way to do it, your best bet is probably to submit an enhancement request at http://b.android.com, and hope that the platform team picks it up. Good luck, 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: ListView + Activity change
Problem solved :) The other class I extended the Activity class and implemented the AdapterView.OnItemSelectedListener which is necessary for a Spinner. I've deleted the implements part of the code, and now I can switch between the activites. But in activity2 the spinner selector doesn't work. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: ListView + Activity change
I think I'll use Checkbox instead of Spinner. :) 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: ListView + Activity change
You don't have to implement the listener on the activity to use it. You can just make a new OnItemSelectedListener and then use spinnerControl.setOnItemSelectedListener(listener) to achieve the same thing. Of course first you'll have to grab a reference to the spinner with findViewById. On Apr 8, 8:31 am, skera szrnka.pe...@gmail.com wrote: Problem solved :) The other class I extended the Activity class and implemented the AdapterView.OnItemSelectedListener which is necessary for a Spinner. I've deleted the implements part of the code, and now I can switch between the activites. But in activity2 the spinner selector doesn't work. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Regarding Video Recording
Hi All, Require Proper Code for Video recording for my app so please some one help me in this coding coz am android beginner so.. Regards, Yogi -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] ANR Problem with FLAG_NOT_TOUCHABLE
Hi, i'm trying to make a workaround for the inCall problem I was having. Now, I'm trying to just set a low brightness and disable touch events, something like this: @Override public void onSensorChanged(SensorEvent event) { Log.w(LOG_TAG, onSensorChanged: + event.values[0]); if (event.values[0] == 0.0) { Window mywindow = getWindow(); WindowManager.LayoutParams lp = mywindow.getAttributes(); lp.screenBrightness = 0.1f; mywindow.addFlags(WindowManager.LayoutParams.FLAG_NOT_TOUCHABLE); mywindow.setAttributes(lp); Log.w(LOG_TAG, Screen goes off!); } else { Window mywindow = getWindow(); WindowManager.LayoutParams lp = mywindow.getAttributes(); lp.screenBrightness = this.defBrightness; mywindow.clearFlags(WindowManager.LayoutParams.FLAG_NOT_TOUCHABLE); mywindow.setAttributes(lp); Log.w(LOG_TAG, Screen goes on!); } } Now, my problem is that, when screen touch is disabled and I start touching it I got an ANR exception due to the keyDispatching timeOut. Any idea on how can I avoid this? I tried overriding the method onTouchEvent with no luck :( 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: Problem with ListAdapters and Cursors
I guess it is either too complicated question or badly asked. To simplify it: Here is one class definition. Class x { string mName; int mID; ArrayList mTmrs; } in the class that extends application I create a public variable like this: public ArrayList mList; in that list I insert several objects of class x. how do I create data for ListView from this mList array from mName variable? 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: Problem with ListAdapters and Cursors
Put a get and set function in your application class that lets you interact with the variable you need to pass around. Then in your listactivity class get a reference to the application class with getApplicationContext();. As far as getting it into the list, you just need to put it into an ArrayAdapter adapter using adapter.add and then you can do listview.setAdapter(adapter). On Apr 8, 8:47 am, Duskox dus...@gmail.com wrote: I guess it is either too complicated question or badly asked. To simplify it: Here is one class definition. Class x { string mName; int mID; ArrayList mTmrs; } in the class that extends application I create a public variable like this: public ArrayList mList; in that list I insert several objects of class x. how do I create data for ListView from this mList array from mName variable? 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: Problem with ListAdapters and Cursors
Sorry those should be ListAdapters not ArrayAdapters. A question about a spinner got me all mixed up. On Apr 8, 8:50 am, loweroctave twinte...@gmail.com wrote: Put a get and set function in your application class that lets you interact with the variable you need to pass around. Then in your listactivity class get a reference to the application class with getApplicationContext();. As far as getting it into the list, you just need to put it into an ArrayAdapter adapter using adapter.add and then you can do listview.setAdapter(adapter). On Apr 8, 8:47 am, Duskox dus...@gmail.com wrote: I guess it is either too complicated question or badly asked. To simplify it: Here is one class definition. Class x { string mName; int mID; ArrayList mTmrs; } in the class that extends application I create a public variable like this: public ArrayList mList; in that list I insert several objects of class x. how do I create data for ListView from this mList array from mName variable? 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: Problem with ListAdapters and Cursors
Thanks!! :) On Apr 8, 2:55 pm, loweroctave twinte...@gmail.com wrote: Sorry those should be ListAdapters not ArrayAdapters. A question about a spinner got me all mixed up. On Apr 8, 8:50 am, loweroctave twinte...@gmail.com wrote: Put a get and set function in your application class that lets you interact with the variable you need to pass around. Then in your listactivity class get a reference to the application class with getApplicationContext();. As far as getting it into the list, you just need to put it into an ArrayAdapter adapter using adapter.add and then you can do listview.setAdapter(adapter). On Apr 8, 8:47 am, Duskox dus...@gmail.com wrote: I guess it is either too complicated question or badly asked. To simplify it: Here is one class definition. Class x { string mName; int mID; ArrayList mTmrs; } in the class that extends application I create a public variable like this: public ArrayList mList; in that list I insert several objects of class x. how do I create data for ListView from this mList array from mName variable? 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: Problem with ListAdapters and Cursors
ArrayAdapter works fine with a ListView, and is easer to get going. 08.04.2011 16:55, loweroctave пишет: Sorry those should be ListAdapters not ArrayAdapters. A question about a spinner got me all mixed up. -- Kostya Vasilyev -- http://kmansoft.wordpress.com -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Thread and ProgressDialog
Unfortunately it's much more complicated that it looks like. Check out this thread: http://bit.ly/i5e9Eq Cheers Emanuel Moecklin On Apr 6, 12:45 am, SD315 sailer...@gmail.com wrote: Hello, i'm trying to do some work in a thread while showing a progress dialog until the work is done in the most simple possible way, so far i got this: // this is the current activity final ProgressDialog prgDialog = ProgressDialog.show(this, , Working..., true, false); new Thread() { public void run() { Util.DoSomeWork(); // a static method prgDialog.dismiss(); }}.start(); at least it work fine in the emulator, but i'm concerned about it's correctness, specifically about calling prgDialog.dismiss(); (note that the variable prgDialog is created in the main thread), is this correct? bye -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Remote access to phones
Hi all - trying this once again - has anyone managed to access Android phones remotely with ssh? Any hits you can share that would certainly help. Thanks On Apr 5, 3:48 pm, kypriakos demet...@ece.neu.edu wrote: Hi all, I am trying to figure out a way to access the htc phones (running Android 1.6 and 2.2) over ssh. I used the following I found from a posting: setprop service.adb.tcp.port stop adbd (by the way this means reboot unless you have a terminal on the phone) start adbd and from remote node use adb connect ip addr: Is there an open-source ssh server package somewhere? I didn't find one on Market. 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: Remote access to phones
I haven't, but you may want to ask on android-porting. Those folks deal with setprop and ports much more than us humble SDK users :) -- Kostya 08.04.2011 17:20, kypriakos пишет: Hi all - trying this once again - has anyone managed to access Android phones remotely with ssh? Any hits you can share that would certainly help. Thanks -- Kostya Vasilyev -- http://kmansoft.wordpress.com -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] 3d engine advices
Hi I've some background in 3d desktop programming. I've also developed some 2d games on android. I'll start 3d programming in android. I think using an engine would be better rather than using opengl directly. Do you mind sharing your experiences on 3d engines? These are some engines I've found: libgdx jmonkey jpct ardor3d min3d catcake alien3d forget3d dwarf-fw android-3d-engine Especially the last ones are very primitive. Some of you may suggest unity but my impression is that it is more appropriate for designers who know some coding rather than hardcore programmers. I also want something in java. I've used opengl and jmonkey on desktop before. One of the main contributors of the jmonkey started to a new engine, ardor3d. It seemed promising at first but then they got slow. It has been more than a year they started working on android but still there is not even a tutorial about how to start. I was planning to use it at first but I started to change my mind. I think it would be better to ask here first. I am aware that I didn't ask for specific features about 3d engine comparison but I think any comments would be helpful. When I searched through the old group messages I couldn't come up with many topics related with 3d engines. -- Drokid -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Eclipse linux error
Hi, I know that this question is better suited to Ubuntu Forums but I have already tried there and received no reply. I installed the SDK, eclipse, adt plugin and completed all the steps to set up a development environment. This entire setup worked for only one day. The next day when I tried start eclipse the eclipse splash screen without the progress bar shows and is then replaced by a dialogue box with the title eclipse but no text inside it. This dialogue box does not close. I am running Ubuntu 10.10. I have the latest version of Java installed. Even downloading eclipse again did not solve the problem. The SDK manager starts up fine. Please help Thanks -- Raghav Sood http://www.raghavsood.com/ http://www.androidappcheck.com/ http://www.telstop.tel/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Widgets: Lanscape vs Portrait
I have a 2x1 widget with two textviews, aligned top and bottom to the baseline, that display fine in Portrait. When I switch to landscape, there is insufficient room for the two textviews (the widget becomes long and narrow) so the two textviews overlap each other. What is the correct way to handle this? Do I need a create a 2x1 landscape layout so that Android will use that specific layout instead of reusing my one layout? If so, and if that new layout uses one textview instead of two, how do I know at runtime which layout is being used? Or do I keep the code the same and uses the same IDs on both layouts and updating that second textview id won't hurt anything? -- Jake Colman -- Android Tinkerer -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Parsing data from a calender on a website
hi you can use the saxparser or dom parser you can find example on android developer. to put the whole data in your application and then use it. On Apr 6, 8:52 pm, Neutron_boy arctikz...@gmail.com wrote: I am fairly new to Android, but have some experience reading and understanding code, including Java. My question is: If I want to parse a URL such as a calender from a web page, how do I go about this? My thoughts: To pull the XML, do I use text? i.e.: try { URL text = new URL( http:// and here is where I am not sure what to have. The script below is the source for the calender in the XML of the website script type=text/javascript src=9278a6f3de5f9e54f2aeeb74ac1f0a7eembedcompiled__en.js/script) Do I then follow with XmlPullParserFactgory parserCreator = XmlPullParserFactory.newInstance(); XmlPullParser parser = parserCreator.newPullParser(); parser.setInput(text.openStream(), null); Do I still use an open stream here? rest of code... Thanks in advance for the help and insoght -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Eclipse linux error
I had a similar problem, what eclipse version are you using? I downloaded Helios, and then had to download the provious version (the recommended one) to finalize the configuration and then I can use Helios as usually... 2011/4/8 Raghav Sood raghavs...@gmail.com Hi, I know that this question is better suited to Ubuntu Forums but I have already tried there and received no reply. I installed the SDK, eclipse, adt plugin and completed all the steps to set up a development environment. This entire setup worked for only one day. The next day when I tried start eclipse the eclipse splash screen without the progress bar shows and is then replaced by a dialogue box with the title eclipse but no text inside it. This dialogue box does not close. I am running Ubuntu 10.10. I have the latest version of Java installed. Even downloading eclipse again did not solve the problem. The SDK manager starts up fine. Please help Thanks -- Raghav Sood http://www.raghavsood.com/ http://www.androidappcheck.com/ http://www.telstop.tel/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Widgets: Lanscape vs Portrait
08.04.2011 19:25, Jake Colman пишет: I have a 2x1 widget with two textviews, aligned top and bottom to the baseline, that display fine in Portrait. When I switch to landscape, there is insufficient room for the two textviews (the widget becomes long and narrow) so the two textviews overlap each other. Yep, there is typically less per-widget height in landscape mode. One way to handle this is to use Launcher shortcut - sized widgets, but those are pretty small. Making larger widgets requires some more work: What is the correct way to handle this? Do I need a create a 2x1 landscape layout so that Android will use that specific layout instead of reusing my one layout? Yes, make a landscape version with the same name in res/layout-land. If so, and if that new layout uses one textview instead of two, how do I know at runtime which layout is being used? You don't - especially since onUpdate doesn't get called for widget orientation changes. So whatever you push out into the widget with RemoteViews has to work for both orientations. Resources do get reloaded though, so you can rely on resource qualifiers like -land, etc. Or do I keep the code the same and uses the same IDs on both layouts and updating that second textview id won't hurt anything? I'd keep both text views in both layout, using visibility=gone where a view is not supposed to show - just to be safe. You could also use one text view, combining data from your original two, in landscape mode. In that case, you'd have a total of three views, and make portrait-only views gone in the landscape layout, and vise versa. -- Kostya -- Kostya Vasilyev -- http://kmansoft.wordpress.com -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Eclipse linux error
Hi, Thanks luiX_ I am using Helios. So are you saying that I download the previous version configur it and then Helios will work? Thanks On Fri, Apr 8, 2011 at 9:29 PM, luiX_ lui...@gmail.com wrote: I had a similar problem, what eclipse version are you using? I downloaded Helios, and then had to download the provious version (the recommended one) to finalize the configuration and then I can use Helios as usually... 2011/4/8 Raghav Sood raghavs...@gmail.com Hi, I know that this question is better suited to Ubuntu Forums but I have already tried there and received no reply. I installed the SDK, eclipse, adt plugin and completed all the steps to set up a development environment. This entire setup worked for only one day. The next day when I tried start eclipse the eclipse splash screen without the progress bar shows and is then replaced by a dialogue box with the title eclipse but no text inside it. This dialogue box does not close. I am running Ubuntu 10.10. I have the latest version of Java installed. Even downloading eclipse again did not solve the problem. The SDK manager starts up fine. Please help Thanks -- Raghav Sood http://www.raghavsood.com/ http://www.androidappcheck.com/ http://www.telstop.tel/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Raghav Sood http://www.raghavsood.com/ http://www.androidappcheck.com/ http://www.telstop.tel/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] ANR Problem with FLAG_NOT_TOUCHABLE
What is the stack reported for your app ANR? (You can find it in /data/anr/traces.txt). It's possible this is just a platform bug. Changing a window like this is probably not something anyone else has done. If it is a platform problem it could also vary significantly across platform releases -- most platform versions have had some significant work on event dispatching, especially 2.3 which completely rewrote it. On Fri, Apr 8, 2011 at 5:44 AM, luiX_ lui...@gmail.com wrote: Hi, i'm trying to make a workaround for the inCall problem I was having. Now, I'm trying to just set a low brightness and disable touch events, something like this: @Override public void onSensorChanged(SensorEvent event) { Log.w(LOG_TAG, onSensorChanged: + event.values[0]); if (event.values[0] == 0.0) { Window mywindow = getWindow(); WindowManager.LayoutParams lp = mywindow.getAttributes(); lp.screenBrightness = 0.1f; mywindow.addFlags(WindowManager.LayoutParams.FLAG_NOT_TOUCHABLE); mywindow.setAttributes(lp); Log.w(LOG_TAG, Screen goes off!); } else { Window mywindow = getWindow(); WindowManager.LayoutParams lp = mywindow.getAttributes(); lp.screenBrightness = this.defBrightness; mywindow.clearFlags(WindowManager.LayoutParams.FLAG_NOT_TOUCHABLE); mywindow.setAttributes(lp); Log.w(LOG_TAG, Screen goes on!); } } Now, my problem is that, when screen touch is disabled and I start touching it I got an ANR exception due to the keyDispatching timeOut. Any idea on how can I avoid this? I tried overriding the method onTouchEvent with no luck :( 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 -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Eclipse linux error
Yep, it worked for me :) 2011/4/8 Raghav Sood raghavs...@gmail.com Hi, Thanks luiX_ I am using Helios. So are you saying that I download the previous version configur it and then Helios will work? Thanks On Fri, Apr 8, 2011 at 9:29 PM, luiX_ lui...@gmail.com wrote: I had a similar problem, what eclipse version are you using? I downloaded Helios, and then had to download the provious version (the recommended one) to finalize the configuration and then I can use Helios as usually... 2011/4/8 Raghav Sood raghavs...@gmail.com Hi, I know that this question is better suited to Ubuntu Forums but I have already tried there and received no reply. I installed the SDK, eclipse, adt plugin and completed all the steps to set up a development environment. This entire setup worked for only one day. The next day when I tried start eclipse the eclipse splash screen without the progress bar shows and is then replaced by a dialogue box with the title eclipse but no text inside it. This dialogue box does not close. I am running Ubuntu 10.10. I have the latest version of Java installed. Even downloading eclipse again did not solve the problem. The SDK manager starts up fine. Please help Thanks -- Raghav Sood http://www.raghavsood.com/ http://www.androidappcheck.com/ http://www.telstop.tel/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Raghav Sood http://www.raghavsood.com/ http://www.androidappcheck.com/ http://www.telstop.tel/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Smoothing out Handler sent repaint events
On Fri, Apr 8, 2011 at 1:16 AM, Numeron numeronreac...@gmail.com wrote: I wouldnt have thought it would work like a busy method if its adding itself to something like an event queue or whatever, but I'll take your word on it. Well it is going to continually execute messages, even if it isn't needed. That is, if it takes you 10ms to draw a frame and the frame rate is 60Hz (20ms between frames), you should be using 50% of the CPU. But with your code you will consume all of the rest of the CPU dispatching these messages for no reason. Having said that Im pretty sure that your suggestion to invalidate() at the end of onDraw() would turn out to be busy too. Drawing is throttled to the frame rate. -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: HttpURLConnection responsecode 414-url too long issue
As another poster was hinting, this is a job for HTTP POST, not HTTP GET. GET puts all arguments into the URL. POST puts a short URL, and then adds all of the arguments to the hidden handshaking conversation that follows the network connection. The good news is that many CGI programs don't even notice that you've made the request in a different way. The program just gets its arguments and is happy. The bad news is that this is not guaranteed. (A side benefit of POST is that all of these ugly or semi- private facts don't show up in the URL.) If you can't accept HTTP POST arguments this way for some reason but you can modify the CGI script (recipeBatch in your example), then you may get a little farther by compacting the arguments a bit. You have a couple hundred copies of the characters 'ids='. Make it one argument with + separators, and split it on the CGI side. That gives you a little bit of room, but it's not unlimited by URL length like POST is. I am hoping that those 7-digit numbers are not phone numbers. I'd hate to think I was helpful AT ALL to someone building an annoying telemarketing system. On Apr 8, 3:18 am, imran ali imran...@gmail.com wrote: Hi all, i have to download data but having big ur,l it's character is going to increase more than 4048, for small url it is working fine but for big url it has been giving response code 414- url too long. what would be feasible way to handle this issue? example of url is http://www.someserver.com/api/recipeBatch? ids=4851525ids=4853720ids=4856090ids=4856180ids=4856578ids= ... -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] How do i Download the Mp3 file from server
On Fri, Apr 8, 2011 at 5:25 AM, Riyas abdrahma...@gmail.com wrote: Am a newbie to android development Read the documentation. - 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] Regarding Video Recording
On Fri, Apr 8, 2011 at 7:39 AM, yogendra G yogi2...@gmail.com wrote: Require Proper Code for Video recording for my app so please some one help me in this coding coz am android beginner so.. ... so RTFM. - 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] Getting a delay between starting current activity after returning from startActivityForResult()
On Fri, Apr 8, 2011 at 5:44 AM, Kacee komal...@gmail.com wrote: Please help :( Try removing the Clear Top flag. - 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: Honeycomb Sourcecode
On Apr 7, 3:06 pm, JAlexoid (Aleksandr Panzin) jalex...@gmail.com wrote: Why would you need Honeycomb source? I think the issue is not need vs want. Yet. It's doing the right thing. If a network router uses some open-licensed code, but doesn't provide the sources, they are rightly brought to task for it through a legal challenge. If Motorola has shipped stock Honeycomb 3.0 (per words from Google reps here), then Motorola's users should have access to the software on the device. While you can quibble about distinctions between Apache vs GPL, and deltas from version 2.3 to version 3.0, the point is the same: users can't call it OPEN unless the users can have the CODE. For Google to call it OPEN when users do not in fact have the CODE is disingenuous at best, and becomes more nefarious over time. Google's really good at hoovering in all kinds of data and coming up with some sort of corporate strategy from it. Google has not shown the same level of ability at communicating in the other direction. If we developers are going to be Google's partner in making Android a success, then Google needs to communicate with us. That goes for Android Market, Android Platform, and all other areas upon which we mutually depend. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] deepan_android
Hi All, I have joined as new member. for your kind reference , I am android developer. Thanks, Williams Deepan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] internet connection problem using emulator. can you help??
Hi We have an issue when Android emulator runs for several hours or sometimes even when we star it up, the internet connection is breaks and does not come back on the emulator. In the server running the internet the internet is fine. In the log, there is two sorts of exception for internet Connction. org.apache.http.client.ClientProtocolException java.net.UnknownHostException:Unable to resolve host abc.xyz.com.au no address associated with host name After these exception, I also couldn't connection internet with chrome browser of android. The program runs several hours, then exception happened. Does anyone know what might be wrong or how we can fix? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] local and remote database synchronization
I need to write the application where the application should be able to provide full functionality in offline mode(Internet dis- connection). so, I am going fetch the required data at once and use it for the offline mode.. and the save data from my application will be store in the local mobile database and send to web service when the internet connection provide... so, I think about the database synchronization, but no idea that how to implement it.. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Racoon is not initiating a connection with x509 L2TP/IPSec
Hello all, I am trying to setup a VPN connection on Android v2.2.2. I am currently unable to connect to my VPN server. The VPN server is Openswan which is running with xl2tpd. I am using X. 509 certificates to identify clients. Android does not seem to initiate a connection to the VPN server, the logs on the server show no entries of any clients connecting. This setup works on my telephone when running windows mobile 6.5, or when connecting with computers running windows or OSX. The logs from android show that racoon is not able to create a key socket. Can anyone please point me in the right direction to solve this problem? Greetings, Bart The logs below are from android: I/ActivityManager( 1331): Starting activity: Intent { act=android.intent.action.MAIN cmp=com.android.settings/.vpn.VpnSettings } D/VpnManager( 1409): succeeded to connect to VPN service D/VpnSettings( 1409): received connectivity: 129.125.102.34: connected? IDLE err=0 I/ActivityManager( 1331): Displayed activity com.android.settings/.vpn.VpnSettings: 480 ms (total 480 ms) I/keystore( 1315): uid: 1000 action: t - 1 state: 1 - 1 retry: 4 I/keystore( 1315): uid: 1000 action: e - 1 state: 1 - 1 retry: 4 I/keystore( 1315): uid: 1000 action: e - 1 state: 1 - 1 retry: 4 D/dalvikvm( 1649): GC_EXPLICIT freed 3326 objects / 192224 bytes in 130ms D/VpnManager( 1409): succeeded to connect to VPN service D/com.android.settings.vpn.AuthenticationActor( 1409): ~~ connect() succeeded! I/SProxy_mtpd( 1734): Stop VPN daemon: mtpd D/SProxy_mtpd( 1734): mtpd is stopped after 0 msec D/SProxy_mtpd( 1734): stopping mtpd, success? true I/SProxy_racoon( 1734): Stop VPN daemon: racoon D/SProxy_racoon( 1734): racoon is stopped after 0 msec D/SProxy_racoon( 1734): stopping racoon, success? true D/VpnService( 1734): Local IP: 10.15.104.141, if: ppp0 D/VpnService( 1734):VPN UP: down I/SProxy_racoon( 1734): Start VPN daemon: racoon D/VpnSettings( 1409): received connectivity: 129.125.102.34: connected? CONNECTING err=0 D/SProxy_racoon( 1734): racoon is running after 200 msec D/SProxy_racoon( 1734): service not yet listen()ing; try again D/dalvikvm( 1396): GC_EXTERNAL_ALLOC freed 2710 objects / 121312 bytes in 100ms D/racoon ( 2025): Waiting for control socket D/racoon ( 2025): Received 5 arguments E/racoon ( 2025): Cannot create KEY socket I/SProxy_racoon( 1734): got data from control socket: -1 E/VpnService( 1734): onError() E/VpnService( 1734): java.io.IOException: socket error, result from service: -1 E/VpnService( 1734): at com.android.server.vpn.DaemonProxy.sendCommand(DaemonProxy.java:89) E/VpnService( 1734): at com.android.server.vpn.VpnDaemons.startIpsecForL2tp(VpnDaemons.java: 70) E/VpnService( 1734): at com.android.server.vpn.L2tpIpsecService.connect(L2tpIpsecService.java: 37) E/VpnService( 1734): at com.android.server.vpn.VpnService.onConnect(VpnService.java:135) E/VpnService( 1734): at com.android.server.vpn.VpnServiceBinder $2.run(VpnServiceBinder.java:114) E/VpnService( 1734): at java.lang.Thread.run(Thread.java:1096) I/VpnService( 1734): disconnecting VPN... D/VpnSettings( 1409): received connectivity: 129.125.102.34: connected? DISCONNECTING err=0 I/SProxy_mtpd( 1734): Stop VPN daemon: mtpd D/SProxy_mtpd( 1734): mtpd is stopped after 0 msec D/SProxy_mtpd( 1734): stopping mtpd, success? true I/SProxy_racoon( 1734): Stop VPN daemon: racoon D/SProxy_racoon( 1734): racoon is stopped after 0 msec D/SProxy_racoon( 1734): stopping racoon, success? true D/VpnService( 1734): onFinalCleanUp() I/VpnService( 1734): restore original suffices -- null D/VpnSettings( 1409): received connectivity: 129.125.102.34: connected? IDLE err=101 D/VpnSettings( 1409): create reconnect dialog for event 101 E/Tethering( 1331): attempting to remove unknown iface (usb0), ignoring E/Tethering( 1331): attempting to remove unknown iface (usb0), ignoring D/VpnSettings( 1409):onIdle() -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Share the theme among all the projects in android
Hi,I want to share the theme among all the projects in android,which effect is like HTC skin.How can I implement this function? I study the AssetManager. Can I add the resource.arc(which is like the framework- res) to all the projects with AssetManager? I modify the ActivityThread as the following code:add assets.addAssetPath(/system/ app/ShareTheme.apk); /** * Creates the top level Resources for applications with the given compatibility info. * * @param resDir the resource directory. * @param compInfo the compability info. It will use the default compatibility info when it's * null. */ Resources getTopLevelResources(String resDir, CompatibilityInfo compInfo) { synchronized (mPackages) { // Resources is app scale dependent. ResourcesKey key = new ResourcesKey(resDir, compInfo.applicationScale); if (false) { Log.w(TAG, getTopLevelResources: + resDir + / + compInfo.applicationScale); } WeakReferenceResources wr = mActiveResources.get(key); Resources r = wr != null ? wr.get() : null; if (r != null r.getAssets().isUpToDate()) { if (false) { Log.w(TAG, Returning cached resources + r + + resDir + : appScale= + r.getCompatibilityInfo().applicationScale); } return r; } //if (r != null) { //Log.w(TAG, Throwing away out-of-date resources //+ r + + resDir); //} AssetManager assets = new AssetManager(); if (assets.addAssetPath(resDir) == 0) { return null; } assets.addAssetPath(/system/app/ShareTheme.apk);// ===This line add by me!! //Log.i(TAG, Resource: key= + key + , display metrics= + metrics); DisplayMetrics metrics = getDisplayMetricsLocked(false); r = new Resources(assets, metrics, getConfiguration(), compInfo); if (false) { Log.i(TAG, Created app resources + resDir + + r + : + r.getConfiguration() + appScale= + r.getCompatibilityInfo().applicationScale); } // XXX need to remove entries when weak references go away mActiveResources.put(key, new WeakReferenceResources(r)); return r; } } Who can help me or can give me some precious advice about it. Thank you very much!! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Marquee is not worked when screen rotate
Ok. In HTML we can use marquee for small string so I thought in Android it also worked. Ok Thanks guys. On Apr 8, 1:16 pm, Abhilash baddam abhilash.androiddevelo...@gmail.com wrote: Hi Pramod, For small String its not working i am also using the same version. On Fri, Apr 8, 2011 at 1:42 PM, pramod.deore deore.pramo...@gmail.comwrote: Hi Abhilash, for lengthy string its working. try with smaller String like Test String and let me know marquee is working or not? I am using 2.1 Update1. API level is 7 On Apr 8, 12:37 pm, Abhilash baddam abhilash.androiddevelo...@gmail.com wrote: Hi pramod, For me also it's working, whenever the string length is more. So that i have given the string like this string On Fri, Apr 8, 2011 at 12:36 PM, pramod.deore deore.pramo...@gmail.com wrote: Hi, Zsolt Vasvari Thanks for reply. When I tried above code with large string message then marquee works properly. Is that mean marquee useful for only large string i.e to show large line data which is not fit into screen size? On Apr 8, 11:56 am, Zsolt Vasvari zvasv...@gmail.com wrote: Create a bug report onhttp://b.android.comI dont' see anything wrong with your code. Using the emulator, try to determine on which Android SDK level it broke on and file a bug report. Put Regression, Honeycomb and 3.0 in the title, if it applies so that you get some Google people to pay attention. Don't expect a respone, but with any luck, it will be fixed in the next SDK update. On Apr 8, 2:37 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi all, In my application I am using marquee. It works perfectly, but when I rotate screen then it is not working. following is my code. public class TextViewMarquee extends Activity { private TextView tv; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); tv = (TextView) this.findViewById(R.id.mywidget); tv.setSelected(true); // Set focus to the textview } } main.xml file is as ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/mywidget android:layout_width=wrap_content android:layout_height=wrap_content android:ellipsize=marquee android:fadingEdge=horizontal android:marqueeRepeatLimit=marquee_forever android:scrollHorizontally=true android:textColor=#ff4500 android:text=Simple application that shows how to use marquee, with a long text / /RelativeLayout what should I have to do so marquee also works after screen rotate? 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Digest for android-developers@googlegroups.com - 25 Messages in 15 Topics
Hi , i'm doing my final year project and i am new to this technology. In my first UI i need a google map and i successfully integrated google map to my app,But i need a seach button on top of the UI and it should pop-up the particular location on that has entered in search option. please let me how can implement this search option. Thanks Syed -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 xml
I am trying to search how to pass values from activity to xml file which is used for displaying charts.. anyone know how to do this?? plz send me a link.. any suggestions are welcome...! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: CallLog.Calls filter by date
Hi. I'm facing the same issue. My requirement is to get calls from the call log after a certain date. The following statement does not give error, but always fetches the whole list: Cursor c = DirectoryListing.mainActivity.getContentResolver().query( android.provider.CallLog.Calls.CONTENT_URI, null, (android.provider.CallLog.Calls.DATE ++ lastFetchedDate), null, android.provider.CallLog.Calls.DATE + ASC); lastFetchedDate is an int value which is initially 0, but gets set to the maximum value of the date field each time my method runs. I'm new to Android development. Is there something wrong in my code? Is date field in CallLog content provider not indexed/searchable? Thanks, Tan On Mar 8, 5:12 pm, lerage nogeekyn...@gmail.com wrote: I am new to android and java and so sorry if its a simple question. I have tried to search but I am getting the answer nowhere. So, I am trying to getcalllogdetails using the CallLog.Calls content provider. I am able to get results with simple queries however I am not able to get any result when I try to run a WHERE query byDATE. Here's the query below ... Cursor c = getContentResolver().query(CallLog.Calls.CONTENT_URI, null, CallLog.Calls.DATE+ =?, new String[] {String.valueOf(date)}, ORDER_BY); As this query works when the WHERE clause include Number or Type (call type) etc., I think I am having problem (sometimes getting Illegal type error and sometimes getting no results but no errors) because I am not sure how exactly to convert theDatesupplied to epoch dates. How to do this? Any help people? 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] Streaming youtube video
Hello I need an example source of streaming RTSP youtube video's inside a Video view -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 Entry Uri 's are generated insides each plan in CTS?
We have Some plans in Android CTS.In each plan we have some Entry Uri's How these are generated.i.e in which file the code is written to generate that Entry uri's in each plan. Supose In Cts we have Android plan .we open that Android.xml plan we see like below::: Android.xml: ?xml version=1.0 encoding=UTF-8? TestPlan version=1.0 Entry uri=android.apidemos.cts/ Entry uri=android.CalendarTests/ Entry uri=android.accessibilityservice/ Entry uri=android.accounts/ Entry uri=android.app/ Entry uri=android.bluetooth/ Entry uri=android.content/ Entry uri=android.database/ Entry uri=android.dpi/ Entry uri=android.dpi2/ Entry uri=android.example/ Entry uri=android.gesture/ Entry uri=android.graphics/ Entry uri=android.hardware/ Entry uri=android.jni/ Entry uri=android.location/ Entry uri=android.media/ Entry uri=android.net/ Entry uri=android.os/ Entry uri=android.permission2/ Entry uri=android.permission/ Entry uri=android.preference/ Entry uri=android.provider/ Entry uri=android.sax/ Entry uri=android.speech/ Entry uri=android.telephony/ Entry uri=android.text/ Entry uri=android.util/ Entry uri=android.view/ Entry uri=android.webkit/ Entry uri=android.widget/ Entry uri=android.SimpleCalculator1/ Entry uri=android.tests.appsecurity/ /TestPlan How these are generated while we make the CTS i.e make cts -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Possible to use bouncy castle package in android sdk
Is is possible/ compatible to include bouncy castle jar file in android sdk thanks in advance With regards K.Nivethaa Shree -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Do I need to make an app for each Brand?
Hi, We are looking intop make some apps for internal use. Our developer claims that andriod mobilephone solution needs to be developed for each brand. I'm a bit amazed that the most common buttons aren't standardized. Further more inbuilt feautes like camera, speaker and microphone are they standardized? All Gurus, please advise Best regards Rune -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 obtainStyledAttributes to get a String from a Theme
Hi, I have declared a styleable like this: declare-styleable name=Test attr name=myString format=string / attr name=myNumber format=integer / /declare-styleable I'm using this with the following java code in a constructor of a custom View class: TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.Test, defStyle, 0); String str = a.getString(R.styleable.Test_myString); int num = a.getInt(R.styleable.Test_myNumber, -1); a.recycle(); Log.d(Test, string: + str); Log.d(Test, number: + num); It works as expected when I set the attributes in the layout xml, and it also works when I define a style with these attributes and use the style from the layout xml. But somehow I cannot get it to work when I set the attributes in the theme: style name=MyTheme parent=@android:style/Theme item name=myStringfoobar/item item name=myNumber12345/item /style When I do this, I get the following output: string: Avbryt number: 12345 So obtaining the value of the number works, but the string contains a bogus value, which seems to be the value of an random android string resource. I tested this on the emulator 2.2 and 2.3.3. I also tried to use a package prefix item name=com.mypackage:myString but it does not make any difference. Why can't I access a string the same way like a number? Am I doing something wrong? How can I get the value of the string? I'm doing this because I want to use a custom font from the asset directory. Any help is appreciated. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] zxing library in my application
Hi all, i have some questions as far as the zxing library is concerned. I have already integrated the zxing library on my project but i can't configure the way that zxing handles the qr codes after scanned them. So, i want to decode something that i have encode and then do something, but my problem is that i don't know the way that xzing handles the scanned info.. I am referring in the CaptureActivity.java and more specific in the handleDecode() function which handles the scanned info. Any help? Thanks in advance, Nik -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] how do i devlope an android keybord
i try to dwonload SoftKeyboardLanguagePackTemplate but it dont run like keybord -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Marquee is not worked when screen rotate
Ok Abhilash thanks. I thought it work like HTML marquee. So it means If I want marquee like feel then it will worked only if String os not fit in container. On Apr 8, 1:16 pm, Abhilash baddam abhilash.androiddevelo...@gmail.com wrote: Hi Pramod, For small String its not working i am also using the same version. On Fri, Apr 8, 2011 at 1:42 PM, pramod.deore deore.pramo...@gmail.comwrote: Hi Abhilash, for lengthy string its working. try with smaller String like Test String and let me know marquee is working or not? I am using 2.1 Update1. API level is 7 On Apr 8, 12:37 pm, Abhilash baddam abhilash.androiddevelo...@gmail.com wrote: Hi pramod, For me also it's working, whenever the string length is more. So that i have given the string like this string On Fri, Apr 8, 2011 at 12:36 PM, pramod.deore deore.pramo...@gmail.com wrote: Hi, Zsolt Vasvari Thanks for reply. When I tried above code with large string message then marquee works properly. Is that mean marquee useful for only large string i.e to show large line data which is not fit into screen size? On Apr 8, 11:56 am, Zsolt Vasvari zvasv...@gmail.com wrote: Create a bug report onhttp://b.android.comI dont' see anything wrong with your code. Using the emulator, try to determine on which Android SDK level it broke on and file a bug report. Put Regression, Honeycomb and 3.0 in the title, if it applies so that you get some Google people to pay attention. Don't expect a respone, but with any luck, it will be fixed in the next SDK update. On Apr 8, 2:37 pm, pramod.deore deore.pramo...@gmail.com wrote: Hi all, In my application I am using marquee. It works perfectly, but when I rotate screen then it is not working. following is my code. public class TextViewMarquee extends Activity { private TextView tv; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); tv = (TextView) this.findViewById(R.id.mywidget); tv.setSelected(true); // Set focus to the textview } } main.xml file is as ?xml version=1.0 encoding=utf-8? RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/mywidget android:layout_width=wrap_content android:layout_height=wrap_content android:ellipsize=marquee android:fadingEdge=horizontal android:marqueeRepeatLimit=marquee_forever android:scrollHorizontally=true android:textColor=#ff4500 android:text=Simple application that shows how to use marquee, with a long text / /RelativeLayout what should I have to do so marquee also works after screen rotate? 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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