[android-developers] Urdu Support in Android message
Hi I am Naveed and i am new in Android world,, I need help regarding support of Urdu messages in Android .. plz guide me how can i do this, a lot of people in my country use to send message in Urdu language but Android does not support Urud yet in messaging. Thanks Naveed Ahmad -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] help required with the tcp socket programming with android
HI Could some one let me know were i am going wrong as i am not able to successfully establish a connection between Android and desktop server pc . My android client program is package com.example.socketandroid; import java.io.DataInputStream; import java.io.DataOutputStream; import java.io.IOException; import java.net.Socket; import java.net.UnknownHostException; import android.app.Activity; import android.os.Bundle; import android.view.View; import android.widget.Button; import android.widget.EditText; import android.widget.TextView; public class SocketAndroid extends Activity { EditText textOut; TextView textIn; /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); textOut = (EditText)findViewById(R.id.textout); Button buttonSend = (Button)findViewById(R.id.send); textIn = (TextView)findViewById(R.id.textin); buttonSend.setOnClickListener(buttonSendOnClickListener); } Button.OnClickListener buttonSendOnClickListener = new Button.OnClickListener(){ @Override public void onClick(View arg0) { // TODO Auto-generated method stub Socket socket = null; DataOutputStream dataOutputStream = null; DataInputStream dataInputStream = null; try { socket = new Socket(192.168.2.4, 5000); dataOutputStream = new DataOutputStream(socket.getOutputStream()); dataInputStream = new DataInputStream(socket.getInputStream()); dataOutputStream.writeUTF(textOut.getText().toString()); textIn.setText(dataInputStream.readUTF()); } catch (UnknownHostException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } finally{ if (socket != null){ try { socket.close(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } if (dataOutputStream != null){ try { dataOutputStream.close(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } if (dataInputStream != null){ try { dataInputStream.close(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } } }}; } The server program import java.io.*; import java.net.*; public class server { /** Main entry point */ public static void main(String args[]) throws Exception { System.out.println(ServerRead is waiting for requests on port 5 ...); // Create a listening Server Socket ServerSocket ss = new ServerSocket(5000); // Wait in a loop for connection requests Socket sCon = ss.accept(); // Wait... // Get an Input Stream InputStream in = sCon.getInputStream(); // Read in a loop from Socket and write to console int c; while((c = in.read()) != -1) System.out.write(c); // Clean up sCon.close(); ss.close(); } } Have also set the permission in the manifest file uses-permission android:name=android.permission.INTERNET / also tried the adb forward tcp:5000 tcp:5000 still no joy. could any one help please -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] WindowManager$BadTokenException
Hi, I am getting WindowManager$BadTokenException when i am trying to launch a popup window after inflating it from a xml layout. The key is if i wait for around 2 sec before launching the popup, it works fine, but when i try to open it immediately it crashes. Does anybody have any clue about this ? Following is the code snippet causing the excepion : mInflater = (LayoutInflater)mContext.getSystemService(Context.LAYOUT_INFLATER_SERVICE); mOptionsPanel = (ViewGroup)mInflater.inflate(R.layout.options, null); mOptionsPopup = new PopupWindow(mOptionsPanel,width,height); mOptionsPopup.showAtLocation(parent, gravity, x, y); Logs : 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): android.view.WindowManager$BadTokenException: Unable to add window -- token null is not valid; is your activity running? 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.view.ViewRoot.setView(ViewRoot.java:476) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:180) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:94) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.view.Window$LocalWindowManager.addView(Window.java:435) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.widget.PopupWindow.invokePopup(PopupWindow.java:822) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.widget.PopupWindow.showAtLocation(PopupWindow.java:689) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at com.google.endpoint.pictureframe.PictureFrameSettings.showPopup(PictureFrameSettings.java:226) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at com.google.endpoint.pictureframe.PictureFrame$2.run(PictureFrame.java:269) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.os.Handler.handleCallback(Handler.java:587) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.os.Handler.dispatchMessage(Handler.java:92) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.os.Looper.loop(Looper.java:123) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.app.ActivityThread.main(ActivityThread.java:4363) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at java.lang.reflect.Method.invokeNative(Native Method) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at java.lang.reflect.Method.invoke(Method.java:521) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:864) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:622) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at dalvik.system.NativeStart.main(Native Method) Thanks, Vivek -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Doubt logcat log - program blocked
Hi everybody! This is my first message since I've just joined your mail list. So first of all hi to everybody. I am now developing for android and having some issues so I will directly publish the problem: I have developed one application which uses the bluetooth and transfers data through a 3g connection. The problem is that, sometimes the application just freezes for a while(maybe half an hour, one hour or just forever). I connected the application to the computer and taken the log from logcat. the moment where the phone seems to be blocked is here: D/QCRIL_MSC ( 73): RIL=AMSS [ label = cm_ph_cmd_get_ph_info()]; D/GsmServiceStateTracker( 231): handlePollStateResult regplmn = 24491 D/MobileDataStateTracker( 133): replacing old mInterfaceName (rmnet0) with rmnet0 for hipri D/NetworkLocationProvider( 133): onDataConnectionStateChanged 3 D/MobileDataStateTracker( 133): default Received state= CONNECTED, old= CONNECTED, reason= (unspecified), apnTypeList= default D/SntpClient( 133): request time failed: java.net.SocketTimeoutException: Connection timed out I/EventLogService( 277): Aggregate from 1304501219994 (log), 1304501219994 (data) D/SntpClient( 133): request time failed: java.net.SocketTimeoutException: Connection timed out D/SntpClient( 133): request time failed: java.net.SocketTimeoutException: Connection timed out E/Sensors ( 133): light: 640 lux E/Sensors ( 133): light: 1280 lux D/SntpClient( 133): request time failed: java.net.SocketTimeoutException: Connection timed out D/SntpClient( 133): request time failed: java.net.SocketTimeoutException: Connection timed out D/QCRIL_MSC ( 73): RIL=AMSS [ label = cm_ph_cmd_get_ph_info()]; D/GsmServiceStateTracker( 231): handlePollStateResult regplmn = 24491 D/QCRIL_MSC ( 73): RIL=AMSS [ label = cm_ph_cmd_get_ph_info()]; D/GsmServiceStateTracker( 231): handlePollStateResult regplmn = 24491 E/Sensors ( 133): light: 640 lux E/Sensors ( 133): light: 320 lux E/Sensors ( 133): light: 640 lux E/Sensors ( 133): light: 320 lux E/BluetoothEventLoop.cpp( 133): event_filter: Received signal org.bluez.Adapter:DeviceFound from /org/bluez/182/hci0 D/BluetoothService( 133): updateDeviceServiceChannelCache(70:F3:95:4B: 12:B2) It seems that the E/Sensors(133) referes to the bluetooth that seem to be away for a while and that sending the information it launches a SocketTimeoutException, but I am checking before sending any data that the NetworkInfos have some wifi/mobile connection available. Additionally, the phone sometimes just reboots alone(the program is running for hours) and stays in the PIN request state. Thank you in advance! Dhay -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] WindowManager$BadTokenException
Hi, I am getting WindowManager$BadTokenException when i am trying to launch a popup window after inflating it from a xml layout. The key is if i wait for around 2 sec before launching the popup, it works fine, but when i try to open it immediately it crashes. Does anybody have any clue about this ? Following is the code snippet causing the excepion : mInflater = (LayoutInflater)mContext.getSystemService(Context.LAYOUT_INFLATER_SERVICE); mOptionsPanel = (ViewGroup)mInflater.inflate(R.layout.options, null); mOptionsPopup = new PopupWindow(mOptionsPanel,width,height); mOptionsPopup.showAtLocation(parent, gravity, x, y); Logs : 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): android.view.WindowManager$BadTokenException: Unable to add window -- token null is not valid; is your activity running? 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.view.ViewRoot.setView(ViewRoot.java:476) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:180) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:94) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.view.Window$LocalWindowManager.addView(Window.java:435) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.widget.PopupWindow.invokePopup(PopupWindow.java:822) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.widget.PopupWindow.showAtLocation(PopupWindow.java:689) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at com.google.endpoint.pictureframe.PictureFrameSettings.showPopup(PictureFrameSettings.java: 226) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at com.google.endpoint.pictureframe.PictureFrame$2.run(PictureFrame.java: 269) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.os.Handler.handleCallback(Handler.java:587) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.os.Handler.dispatchMessage(Handler.java:92) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.os.Looper.loop(Looper.java:123) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at android.app.ActivityThread.main(ActivityThread.java:4363) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at java.lang.reflect.Method.invokeNative(Native Method) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at java.lang.reflect.Method.invoke(Method.java:521) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:864) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:622) 05-04 07:57:54.060: ERROR/AndroidRuntime(1159): at dalvik.system.NativeStart.main(Native Method) Thanks, Vivek -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] IM Application of Android 2.3.3
IM application is not found with Android 2.3.3 Gingerbread.Will it be considered for future release? Forgive me if this question looks silly. I am new to android development. 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] Use Bluetooth hide API (createRfcommSocket,getServiceChannel)
Greeting , I want to use bluetooth hide API like createRfcommSocket , getServiceChannel , etc.,.. my program code is : Method m = blueToothDevice.getClass().getMethod(createRfcommSocket, new Class[] { int.class }); sock = (BluetoothSocket)m.invoke(blueToothDevice, Integer.valueOf(1)); the createRfcommSocket API is work very well . But getServiceChannel is fail . my program code is : Method m_getServiceChannel = null; try { m_getServiceChannel = blueToothDevice.getClass().getMethod(getServiceChannel); // or use m_getServiceChannel = blueToothDevice.getClass().getMethod(getServiceChannel, new Class[] { String.class, short.class}); } } catch (SecurityException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (NoSuchMethodException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IllegalArgumentException e) { // TODO Auto-generated catch block e.printStackTrace(); } I always get NoSuchMethodException error . Is there anything wrong with my procedure or the way to setup is not correct ? -- intgetServiceChannel(ParcelUuid uuid) define is BluetoothDevice.class (hide api) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] How to know if is the first execution after device reboot.
Hi! I want to know if there are any method to know if is the first exuction of an app after reboot, or the app is alredy executed by the user (the app have one activity and to recivers). I'm thinking in methods like write and rewrite a token file every minute, and each time the app starts, check the lastmodified property to know the state, but i think that must be smart ways to do it. Any idea? Thanks in advance, *Ferran* -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Add frames to video stream
Hi, I can't add frames to the video_stream. Value of index always change but index of video_st never changes. So I think I can't add frames but I can't find why.. Can anyone help me.. Thank you.. Here is some parts of my code static void write_video_frame(AVFormatContext *oc,AVFrame *pFrame,int index) { int out_size, ret; AVCodecContext *c; static struct SwsContext *img_convert_ctx; c = video_st-codec; if (oc-oformat-flags AVFMT_RAWPICTURE 0 ) else { printf(Non Raw picture); out_size = avcodec_encode_video(c, video_outbuf, video_outbuf_size, pFrame); if (out_size 0) { AVPacket pkt; av_init_packet(pkt); if (c-coded_frame-pts != AV_NOPTS_VALUE) pkt.pts= av_rescale_q(c-coded_frame-pts, c- time_base, video_st-time_base); if(c-coded_frame-key_frame) pkt.flags |= AV_PKT_FLAG_KEY; pkt.stream_index= video_st-index; pkt.data= video_outbuf; pkt.size= out_size; sprintf(info,write pkt.size %d,pkt.stream_index); log_message(info); ret = av_interleaved_write_frame(oc, pkt); } else { ret = 0; } } if (ret != 0) { fprintf(stderr, Error while writing video frame\n); exit(1); } } void encodeVideo( AVFormatContext *oc,AVOutputFormat *fmt,JNIEnv* env, jobject javaThis , char *orginalfilename, int w,int h,AVFrame *pFrame,int index){ char filename[50] = /sdcard/new_; int i; char deletedfile[40]; char secondfilename[50]; for(i=0;i50;i++){ secondfilename[i]='\0'; } for(i=12;i50;i++){ filename[i]='\0'; } strncpy(secondfilename,orginalfilename +8,strlen(orginalfilename)-8); strcat(filename , secondfilename); av_register_all(); fmt = av_guess_format(NULL, filename, NULL); if (!fmt) { printf(Could not deduce output format from file extension: using MPEG.\n); fmt = av_guess_format(mpeg, NULL, NULL); } if (!fmt) { fprintf(stderr, Could not find suitable output format\n); exit(1); } oc = avformat_alloc_context(); if (!oc) { fprintf(stderr, Memory error\n);log_message(Memory error); exit(1); } oc-oformat = fmt; snprintf(oc-filename, sizeof(oc-filename), %s, filename); video_st = NULL; if (fmt-video_codec != CODEC_ID_NONE) { video_st = add_video_stream(oc,w,h,fmt-video_codec); } if (av_set_parameters(oc, NULL) 0) { fprintf(stderr, Invalid output format parameters\n); exit(1); } dump_format(oc, 0, filename, 1); if (video_st) open_video(oc); if (!(fmt-flags AVFMT_NOFILE)) { if (url_fopen(oc-pb, filename, URL_WRONLY) 0) { fprintf(stderr, Could not open '%s'\n, filename); exit(1); } } av_write_header(oc); write_video_frame(oc,pFrame,index); } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Hello, Android troubles
Hi, I just started developing for Android and followed the Hello, Android tutorials on the Resources tab from Android.com. I followed it step for step and have been going in circles trying to figure out what's wrong. Here's my code: package com.example.helloandroid; import android.app.Activity; import android.os.Bundle; import android.widget.TextView; public class HelloAndroid extends Activity { /** Called when the activity is first created.*/ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); TextView tv = new TextView (this); tv.setText (Hello, Android); setContentView (tv); } } and when I run it I get a class not found error in the console and the applet says it is not initialized. java.lang.ClassNotFoundException: .class at sun.applet.AppletClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.applet.AppletClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.applet.AppletClassLoader.loadCode(Unknown Source) at sun.applet.AppletPanel.createApplet(Unknown Source) at sun.applet.AppletPanel.runLoader(Unknown Source) at sun.applet.AppletPanel.run(Unknown Source) at java.lang.Thread.run(Unknown Source) load: class .class not found. I can post the Manifest if it is needed but I hope it's a simple problem. I already created and recreated an AVD and none of the tutorials are running either so I think it must be something with my setup. I am completely stumped. Any help would be great! 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: Developer Console problem
Hi, try with e.g. 0,79 or 0.8. Had a similar problem today, using just one digit after the dot solved it. Hth, Alex On 3 Mai, 10:02, Michele Galli ing.michelega...@gmail.com wrote: Hey i have a problem! when i try to set the price of my app to 0.79 euro the developer console set it to 79 euro!! i have never had this problem! i can't re-publish my app if i don't solve this issue! ideas? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Developer Console problem
I have the same problem (i'm an italian developer). I try to insert price as 0.99, 4.99, 5.49 or 9.99 euro but the developer console set it to 99, 499, 549, 999 euro. I receive a lot of error messages e i can't re-publish my applications I wait a solution... Thanks bye! On 4 Mag, 03:23, TreKing treking...@gmail.com wrote: On Tue, May 3, 2011 at 3:02 AM, Michele Galli ing.michelega...@gmail.comwrote: Hey i have a problem! when i try to set the price of my app to 0.79 euro the developer console set it to 79 euro!! ideas? Isn't there a $0.99 limit? Maybe it applies to Euros too? Were you able to do this before? Did you try other values to see if anything would stick? 0.99 Euros maybe? smartass Knowing the quality of the product, I would not be surprised if somewhere in the code was something like: ... // Let's screw with a few people :D if (price == 0.79f) price *= 100.0f; ... /smartass ----- 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] Does not work on I1
This not seem to work on I1 do you know why this is. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Demande d'info
Bonjour Est ce que c'est possible de controler les touches non tactile de son terminal mobile. c'est à dire la touche appeler par exemple ou les touches de volume. Je veux que lorsque je fait un clic sur la touche menu, mon programme affiche son menu et non pas celui de SE Android. Est ce que je peu controler ce bouton? Cordialement Haythem -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] HorizontalScrollView automatically scrolling
Hello, I am developing for Honeycomb, and I have a HorizontalScrollView with a number of panels that make up the UI. The rightmost panel changes its content, sometimes displaying a ListView. I also have a sliding drawer that, when opening or closing, causes the HorizontalScrollView to resize. When the HorizontalScrollView resizes, it also jumps to show the rightmost panel, which I don't want. But this only happens when the panel contains a ListView - when the panel contains a LinearLayout the HorizontalScrollView doesn't change it's position when resizing. The only similar issue I found while searching is this: http://stackoverflow.com/questions/1878623/listview-in-a-horizontalscrollview-in-android, but it's triggered by an adapter changing data rather than a resize. How can I stop this automatic scrolling? Thanks, Mike -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Strangely !! The RAM usage of my APK over 20MB
Dear Senior Developers : I'm a junior Android developer. And i can't understand where the problem is. As my Message Title said, i can't convince my Project Manager the RAM usage is so high sometimes. Here is my Steps and Situation for your reference. Situation : My APK have 4 Activities and 1 Service. And I will check my APK status through the function of Setting. Step 1 : From Setting -- Application -- Running Service. Step 2 : Find my APK Name, and you can see the RAM Usage and Service running-time. Normally, my APK will cause about 3 to 5 MB RAM. But i find the RAM Usage will become to 20MB sometimes. So i don't know how to tune my APK or how to avoid the Memory Leak issue. Please kindly to give me any suggestions. Many 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] Request to join Android Developers
Hello I'd be interested in joining your group, as I am quite new to Android development. I have a few questions and I believe that this is one of the best places to ask them. Thanks SorinC -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Needed Help
Hi group members. I developed a twitter apps for twitter users unfollow. But i donot add Non-follower counter. My apps names www.easyunfollow.com. If any members know this coding please share for me. Thanks to regards all members Tipu -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] FOTA-like updates for non-phone devices?
Guys: Are there any docs available which suggest approaches for FOTA-like updates to non-phone Android devices? In a nutshell, I'm looking at deploying Android as the operating system for a device that isn't a phone. I'm trying to figure out what the best way might be to do in-the-field updates of the device, particularly ones that don't require end-user intervention. Updates of both APKs and the core system files are considered. I understand the basics behind all of the above, I'm just wondering if there is existing infrastructure within the Android framework (or elsewhere) that I should be taking advantage of. I have experience with this stuff on non-Android platforms. Thanks! b.g. -- Bill Gatliff b...@billgatliff.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: Optical character recognition
Hello Ezine.sbr23, Can you correct the clock of your computer please? Thanks, Greetings and nice Day/Evening Michelle Konzack -- # Debian GNU/Linux Consultant ## Development of Intranet and Embedded Systems with Debian GNU/Linux itsystems@tdnet France EURL itsystems@tdnet UG (limited liability) Owner Michelle KonzackOwner Michelle Konzack Apt. 917 (homeoffice) 50, rue de Soultz Kinzigstraße 17 67100 Strasbourg/France 77694 Kehl/Germany Tel: +33-6-61925193 mobil Tel: +49-177-9351947 mobil Tel: +49-176-86004575 office http://www.itsystems.tamay-dogan.net/ http://www.flexray4linux.org/ http://www.debian.tamay-dogan.net/ http://www.can4linux.org/ Jabber linux4miche...@jabber.ccc.de ICQ#328449886 Linux-User #280138 with the Linux Counter, http://counter.li.org/ signature.pgp Description: Digital signature
[android-developers] Re: Problem installing android sdk in ubuntu 10.10
I read all the recent messages regarding this issue, and it is still not fixed as of version r10-linux... edit tools/android, go to the last line, add the following exact text : -Djava.net.preferIPv4Stack=true so that the line looks like : exec $java_cmd -Djava.net.preferIPv4Stack=true -Xmx256M $os_opts $java_debug -Dcom.android.sdkmanager.toolsdir=$progdir -classpath $jarpath:$swtpath/swt.jar com.android.sdkmanager.Main $@ (this is all on 1 line) #solved Why does it work : As of today, I don't know of any operating system not enabling IPv6 by default... and this does not mean you are actually able to _communicate_ with IPv6. It's the default policy to first try to use IPv6, but here the app fails (and most Java apps do fail with IPv6...) Running the script with strace showed the problem : $ strace -fF tools/android /tmp/log $ grep -i unreachable /tmp/log [pid 3264] connect(20, {sa_family=AF_INET6, [.cut.] inet_pton(AF_INET6, [...cut] = -1 ENETUNREACH (Network is unreachable) [.cut] = app is using Java and is trying to use IPv6, but is NOT IPv6-ready ... On 24 avr, 12:26, Saurav to.saurav.mukher...@gmail.com wrote: Hi all, I am trying to install android sdk, but the for every try, the android sdk manager gives this error message: Failed to fetch URLhttp://dl-ssl.google.com/android/repository/addons_list.xml, reason: Connection timed out It may look silly, but has anybody solved this? And I have tried with and without https! Thanks in advance. Regards, Saurav Mukherjee. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] SAX PARSER
hello everyone i am developing an Android + Google Health program and i need your help my problem is that my code runs very good as java standalone program but when i run it in ANDROID environment it fails and the error about SAX PARSER could you please help me Regards -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: SAX PARSER
What error? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 know if is the first execution after device reboot.
* Hi! I want to know if there are any method to know if is the first exuction of an app after reboot, or the app is alredy executed by the user (the app have one activity and to recivers).* * * Is this for an application you developed or any arbitrary app? And, WHY? * I'm thinking in methods like write and rewrite a token file every minute, and each time the app starts, check the lastmodified property to know the state, but i think that must be smart ways to do it.* Please tell me you're not serious... You're joking right? Writing a file every minute in the background would surely drain the battery like crazy. A better solution, if you really want to know the first time your app is launched after a reboot is to listen for the Boot Completed broadcast message: http://developer.android.com/reference/android/content/Intent.html#ACTION_BOOT_COMPLETED Have your receiver write out a value to SharedPreferences... something like a boolean key/value pair with a key of LaunchedSinceBoot and a value of false Then when you launch your main app read that value and act accordingly. Then set the value to true so the next time you launch you skip the first-launch-since-boot steps... Thanks, Justin Anderson MagouyaWare Developer http://sites.google.com/site/magouyaware On Wed, May 4, 2011 at 5:34 AM, ferran fabregas ferri...@gmail.com wrote: Hi! I want to know if there are any method to know if is the first exuction of an app after reboot, or the app is alredy executed by the user (the app have one activity and to recivers). I'm thinking in methods like write and rewrite a token file every minute, and each time the app starts, check the lastmodified property to know the state, but i think that must be smart ways to do it. Any idea? Thanks in advance, *Ferran* -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: SAX PARSER
thank you for your reply and i got the following exception org.xml.SAXNotRecognizedException: http://xml.org/sax/feature/external=parameter-entities thank you again for your concern Best Regards. On 5 مايو, 00:38, Streets Of Boston flyingdutc...@gmail.com wrote: What error? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Demande d'info
Pouvez Vous ecrire en anglais? Je pense que vous n'aurez pas une response autremant.. Vous pouvez ecouter a KeyEvent pour la touche menu dans le java code. 2011/5/4 souissi haythem haythe...@gmail.com Bonjour Est ce que c'est possible de controler les touches non tactile de son terminal mobile. c'est à dire la touche appeler par exemple ou les touches de volume. Je veux que lorsque je fait un clic sur la touche menu, mon programme affiche son menu et non pas celui de SE Android. Est ce que je peu controler ce bouton? Cordialement Haythem -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Jordan - http://www.lulz-industries.org -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Android bug/issue on IPv6
Hi all, I am not sure as Google mentioned IPv6 support is available on Android 1.6 or up , but i checked with 2.2 it even does not have link local IPv6 address whereas 3.0 has that. I tried to set up an environment to generate gloabal IPv6 but DHCP can assign IPv6 to other client except 3.0 HoneyComb which may have bug in native code ?. When i got gloabal IPv6 address from server i still not able to connect it says network unreachable ?. Any suggestion -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] adding ads
How do most people typically add ads to an Android app? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] adding ads
With an Ad SDK that is provided by companies like AdMob. On Wed, May 4, 2011 at 4:02 PM, bob b...@coolgroups.com wrote: How do most people typically add ads to an Android app? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- ~ Jeremiah:9:23-24 Android 2D MMORPG: http://solrpg.com/, http://www.youtube.com/user/revoltingx -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: SAX PARSER
Then you need to change your code to not set this sax feature. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: SAX PARSER
how come? if you have any idea about it please help me and share. it`s very important to me to finish this program within the next two day Kind Regards, On 5 مايو, 02:33, Streets Of Boston flyingdutc...@gmail.com wrote: Then you need to change your code to not set this sax feature. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: SAX PARSER
2 days is sufficient to fix a parser :) Search for the right things, and ask the right questions. :) Kumar Bibek http://techdroid.kbeanie.com http://www.kbeanie.com On Thu, May 5, 2011 at 5:49 AM, MEDO kenando.j...@gmail.com wrote: how come? if you have any idea about it please help me and share. it`s very important to me to finish this program within the next two day Kind Regards, On 5 مايو, 02:33, Streets Of Boston flyingdutc...@gmail.com wrote: Then you need to change your code to not set this sax feature. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Appwidget and orientation
Hey all, I have an appwidget that appears to break when the screen is rotated (it has been reported to me, and I can't test it). When I test the orientation on the emulator the orientation seems to work well enough... I have no idea how to debug this or how to figure out what to do. Does anyone have any advice for solving 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] Re: Appwidget and orientation
Found this that suggests creating an activity that detects the orientation change. Is that the best way to get around it? http://stackoverflow.com/questions/3503114/after-orientation-change-buttons-on-a-widget-are-not-responding -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: SAX PARSER
If i understand correctly, you wrote the code that uses the SAX parser. I assume you know something about coding with SAX parsers. There is an issue with the 'parameter-entities' feature. Go to http://developer.android.com and search for the SAX parser classes and figure out which SAX parser implementation is used (if not by documentation, debug it and find it out that way). Then figure out why the 'parameter-entities' feature is not supported. Maybe you just have to not set it or use another feature. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: NFC tags with write protection?
Get MiFare UltraLights. They have protection bits that you can set so that no more writes can occur. I believe this can also be done with MiFare 1k/4k/etc Classic tags as well but the UL's are cheaper. On May 4, 4:08 pm, Mark Wyszomierski mar...@gmail.com wrote: Hi, I've got some NFC tags and have written some data into them using the NXP Tag Writer app available from marketplace. After writing some data in the tag, I'd like to remove write-access to it so people can't overwrite the tag data. Using the Tag Writer app, I get a message stating that write protection is not available for the tags I have. Does anyone know of any tags I can order which are writeable and have write protection available too? 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] 1380 Paid Applications in One Free Torrent then How to SELL it?
How do you expect to make business if your application already end up in a free torrent like below? http://thepiratebay.org/torrent/6287940/1380_Paid_Android_Apps_and_Games_APK Have they stole these apps from android market or ? regards, Varinag -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: SAX PARSER
thank you Mr.Streets Of Boston for your helpful reply and i appreciate you note thank you again On 5 مايو, 04:32, Streets Of Boston flyingdutc...@gmail.com wrote: If i understand correctly, you wrote the code that uses the SAX parser. I assume you know something about coding with SAX parsers. There is an issue with the 'parameter-entities' feature. Go tohttp://developer.android.comand search for the SAX parser classes and figure out which SAX parser implementation is used (if not by documentation, debug it and find it out that way). Then figure out why the 'parameter-entities' feature is not supported. Maybe you just have to not set it or use another feature. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Appwidget and orientation
Ok. I was wrong in my first post about the error not being displayed. The appwidget did indeed just default to the initial value. I solved the issue (I think) by doing the following: public static class orientationDetectionService extends Service { @Override public void onStart( Intent intent, int startID ) { } @Override void onConfigurationChanged( Configuration newConfig ) { Intent intent = new Intent( this, widget.class ); intent.setAction( widget.FORCE_WIDGET_REDRAW ); sendBroadcast( intent ); } @Override public IBinder onBind( Intent arg0 ) { return null; } } I context.startService'd in the onCreate of the widget, and put the service into the manifest too. Is this a heavy solution to the problem? It might be a naive question, but will this solution eat away battery? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Urdu Support in Android message
- Get the source code to Android - Localize it - Submit localized data (text/images/etc.) to Google - Wait for it to appear in the next version of Android. On May 4, 6:30 pm, naveed ahmad navidu...@gmail.com wrote: Hi I am Naveed and i am new in Android world,, I need help regarding support of Urdu messages in Android .. plz guide me how can i do this, a lot of people in my country use to send message in Urdu language but Android does not support Urud yet in messaging. Thanks Naveed Ahmad -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Request to join Android Developers
Thumbs down from me, sorry. On May 4, 11:56 pm, SorinC chiria...@googlemail.com wrote: Hello I'd be interested in joining your group, as I am quite new to Android development. I have a few questions and I believe that this is one of the best places to ask them. Thanks SorinC -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Custom Intent does not reach PhoneApp
Thanks, am posting the question in the Android Platform group. On May 4, 12:52 pm, TreKing treking...@gmail.com wrote: On Tue, May 3, 2011 at 2:42 PM, bluewolf darkmoonst...@gmail.com wrote: I have added an action to the intent filter in packages/apps/Phone/src/ com/android/phone/PhoneApp.java This is not the forum for modifying the source code. Check the documentation for a more appropriate forum. --- -- 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] Event based communication between two apps.
On Wed, May 4, 2011 at 10:45 AM, Jacob jacobroutolo...@gmail.com wrote: I have 2 apps; need to stay communicated with each other Why? What are you trying to achieve? - 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] Determine if device has only SoftMenu Keys ?
On Wed, May 4, 2011 at 3:09 PM, Andy m...@tekx.de wrote: Is there a possibility to determine if the device your App / Game is running has only soft-keys available ? (Like Back, Home, Menu,..) IDK (don't think so though) but what difference does it make? - 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] Select Multiple Contact Through My Application
On Wed, May 4, 2011 at 12:38 AM, sudipta biswas sudipta.x...@gmail.comwrote: I want to access the android phone book contacts through my application and also select multiple contact(as per my choice) from phone book...please help me to find out a suitable way... Try reading the documentation on Contacts. Then try something. - 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] Hello, Android troubles
On Tue, May 3, 2011 at 7:13 PM, exax evan.yeu...@gmail.com wrote: Hi, I just started developing for Android and followed the Hello, Android tutorials on the Resources tab from Android.com. I followed it step for step and have been going in circles trying to figure out what's wrong. What is sun.applet.AppletPanel? - 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] Does not work on I1
On Wed, May 4, 2011 at 1:22 AM, Michael M wolff2000...@gmail.com wrote: This not seem to work on I1 do you know why this is. Gnomes. - 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: Request to join Android Developers
Why do you feel that you have to request to join this group? If you have questions ask them. Personally I prefer asking all of my Android questions on Stack Overflow and leave this for discussions. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] 1380 Paid Applications in One Free Torrent then How to SELL it?
On Wed, May 4, 2011 at 8:37 PM, varinag gold varinagg...@gmail.com wrote: How do you expect to make business if your application already end up in a free torrent like below? Not posting a link to the torrent that's distributing the pirated software might help. - 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: SAX PARSER
For the record I think you would be better off with the Simple XML Library: http://massaioli.homelinux.com/wordpress/2011/04/21/simple-xml-in-android-1-5-and-up/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] 回覆:Hello, Android troubles
did you compile your code in Eclipse or in command line console? look like you didn't include the android sdk in your class path -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Basic Concept
thanx a lot dude .. On Thu, May 5, 2011 at 01:27, Streets Of Boston flyingdutc...@gmail.comwrote: 'this' in an Activity refers to the Context, because an Activity is a Context (Activity extends Context). this.getApplicationContext() returns an Application. An Application is a Context as well. But the ProgressDialog really likes an Activity, not just a Context. As you discovered, not just any Context will work correctly: If the Context is an Application, then you get a run-time error. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] java.io.EOFException
my write code public static void writeFBTagToCache(long crc64) { try { ArrayListtagStruct tags = mItem.getTags(); if(tags == null || tags.size() = 0) { Log.d(TAG, tags is null + + mItem.mGuid); return; } int size = tags.size(); File tempFile = null; final String tempFilePath = FB_TAG_CACHE; String prefix = crc64 + ; tempFile = File.createTempFile(prefix, .cache, new File(tempFilePath)); final FileOutputStream fileOutput = new FileOutputStream(tempFile); final BufferedOutputStream bufferedOutput = new BufferedOutputStream(fileOutput, 1024); final DataOutputStream dataOutput = new DataOutputStream(bufferedOutput); try { for(int i = 0; i size; i++) { tagStruct tag = tags.get(i); dataOutput.writeInt(size); dataOutput.writeFloat(tag.mXcoord); dataOutput.writeFloat(tag.mYcoord); Utils.writeUTF(dataOutput, tag.mTag); } if(dataOutput != null) { dataOutput.close(); bufferedOutput.close(); fileOutput.close(); } } catch (Exception e) { // Was unable to perform the operation, we delete the temp file Log.e(TAG, Unable to write the index file + crc64); tempFile.delete(); } }catch(IOException e) { e.printStackTrace(); } } - my read code public static ArrayListtagStruct createFBTagFromCache(long crc64) { Log.e(harvey, create facebook tag from cache); try { File tempFile = null; final String tempFilePath = FB_TAG_CACHE; String prefix = crc64 + ; tempFile = File.createTempFile(prefix, .cache, new File(tempFilePath)); FileInputStream fileInput = new FileInputStream(tempFile); BufferedInputStream buf = new BufferedInputStream(fileInput); final DataInputStream dataInput = new DataInputStream(buf); try { int size = dataInput.readInt(); ArrayListtagStruct tags = new ArrayListtagStruct(size); for(int i = 0; i size; i++) { tagStruct tag = new tagStruct(); if(i!=0) { int laji = dataInput.readInt(); } tag.mXcoord = dataInput.readFloat(); tag.mYcoord = dataInput.readFloat(); tag.mTag = dataInput.readUTF(); tags.add(tag); } dataInput.close(); return tags; } catch (Exception e) { dataInput.close(); return null; } } catch (IOException e) { e.printStackTrace(); return null; } } - Exceptoin cause following: 05-05 13:32:50.058: WARN/System.err(5268): java.io.EOFException 05-05 13:32:50.058: WARN/System.err(5268): at java.io.DataInputStream.readInt(DataInputStream.java:287) 05-05 13:32:50.058: WARN/System.err(5268): at com.cooliris.media.UriTexture.createFrTagFromCache(UriTexture.java:455) 05-05 13:32:50.058: WARN/System.err(5268): at com.cooliris.media.UriTexture.createFromUri(UriTexture.java:185) 05-05 13:32:50.058: WARN/System.err(5268): at com.cooliris.media.UriTexture.load(UriTexture.java:362) 05-05 13:32:50.058: WARN/System.err(5268): at com.cooliris.media.RenderView.loadTextureAsync(RenderView.java:308) 05-05 13:32:50.058: WARN/System.err(5268): at com.cooliris.media.RenderView.access$6(RenderView.java:306) 05-05 13:32:50.058: WARN/System.err(5268): at com.cooliris.media.RenderView$TextureLoadThread.load(RenderView.java:1176) 05-05 13:32:50.058: WARN/System.err(5268): at com.cooliris.media.RenderView$TextureLoadThread.run(RenderView.java:1160) 05-05 13:32:50.259: WARN/System.err(5268): java.io.EOFException 05-05 13:32:50.259: WARN/System.err(5268): at java.io.DataInputStream.readInt(DataInputStream.java:287) 05-05 13:32:50.259: WARN/System.err(5268): at com.cooliris.media.UriTexture.createFrTagFromCache(UriTexture.java:455) 05-05 13:32:50.259: WARN/System.err(5268): at com.cooliris.media.UriTexture.getTag(UriTexture.java:689) 05-05 13:32:50.259: WARN/System.err(5268): at com.cooliris.media.RenderView.drawTag(RenderView.java:251) 05-05 13:32:50.259: WARN/System.err(5268): at com.cooliris.media.RenderView.uploadTexture(RenderView.java:613) 05-05 13:32:50.259: WARN/System.err(5268): at
Re: [android-developers] Re: Resume for the post of Android Application Developer
Cool, you're hired! Thanks, Justin Anderson MagouyaWare Developer http://sites.google.com/site/magouyaware On Tue, May 3, 2011 at 11:46 PM, metal mikey coref...@gmail.com wrote: [facepalm] On May 4, 2:05 pm, tushar sahni tusharsahn...@gmail.com wrote: Respected Sir I am sending u my latest Resume for the post of Android Application Developer Regards Tushar Sahni Tushar_Sahni (1).doc 85KViewDownload -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Anyone notice active installs plummet WITHOUT releasing update?
Hi Guys, My active installs plummeted in the last week or so for no apparent reason. I've noticed this a couple of times in past history, but almost always related to a release. I think this is not just smoke and mirrors in the stats kept by Android Market - I notice that I'm getting less traffic on the app as well by how hard my servers are getting hit. Does this seem to be a trend? Any ideas? Thanks to all pawpaw17 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Filtering NFC intents, NDEF message external type
Hallo Gorka, for the moment Android provides no means to directly dispatch your application based on an NFC Forum External Type (btw, your external type name does not follow the RTD specification, The External Type Name MUST be formed by taking the domain name of the issuing organization, adding a colon, and then adding the type name as managed by the organization.) By the way, I cannot filter smartposter and URI NDEF message types. Could someone tell me how to do this?? Filtering should work based on the data of the URI record (both for the URI record itself and the SmartPoster's embedded URI record). You can do this with data ... /. br Michael -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Anyone notice active installs plummet WITHOUT releasing update?
I noticed a pretty big hit recently... For several months I have consistently been getting about $80/month (my cut from Google) on two $0.99 apps in the market and this past month I only ended up with about $30... I'm thinking it may be that people are starting to switch more and more to alternative app stores (such as Amazon) and as soon as I push out my next update the next item on my agenda is getting my apps ready for other app stores. Thanks, Justin Anderson MagouyaWare Developer http://sites.google.com/site/magouyaware On Wed, May 4, 2011 at 12:04 AM, pawpaw17 georgefraz...@yahoo.com wrote: Hi Guys, My active installs plummeted in the last week or so for no apparent reason. I've noticed this a couple of times in past history, but almost always related to a release. I think this is not just smoke and mirrors in the stats kept by Android Market - I notice that I'm getting less traffic on the app as well by how hard my servers are getting hit. Does this seem to be a trend? Any ideas? Thanks to all pawpaw17 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: android nfc tech API help
Hallo, which variant did you use, the low-level access or the IsoDep acccess? The low-level example will only work with MIFARE Ultralight cards (these are always NfcA). Sorry, I don't know any example for low-level access to NfcB cards. The IsoDep example will certainly only give a useful result if the card contains the ICAO electronic passport application... br Michael On 30.04.2011 00:58 priti - wrote: Hi Michael, Thanks! that worked with my nfcA cards! But when I use it with my nfcB cards, I am getting a 67 00 (protocol error?) Appreciate your help, Priti On Thu, Apr 28, 2011 at 8:50 AM, Michael Roland mi.rol...@gmail.com mailto:mi.rol...@gmail.com wrote: Hallo, What exactly is low level access? With low-level access (as compared to APDU based access) I mean some vendor specific (proprietary) protocol according to the ISO/IEC 14443-3 standard. Thus, instead of sending high-level APDU commands a more simple protocol is used (such a protocol is for example the MIFARE Ultralight and the MIFARE Classic command-set). How do I send/receive nfcA/nfcB commands then? For NfcA (e.g. MIFARE Ultralight) you would simply retrieve an NfcA object: NfcA myTag = NfcA.getTag(tag); And then transceive low-level commands with transceive() method. E.g. byte[] data = myTag.transceive(new byte[]{ (byte)0x30, (byte)0x00 }); would retrieve the first 16 bytes of data from an MIFARE Ultralight tag. But as you suggested you want to transfer APDUs, instead of getting an NfcA object you would want to get an IsoDep object for the tag. This object wraps an APDU-based (ISO/IEC 14443-4 ISO/IEC 7816-4) connection: IsoDep myCard = IsoDep.getTag(tag); The transceive() method then allows you to directly transmit command APDUs to the contactless smart card and returns the response APDU: byte[] response = myCard.transceive(command); Where command could be, for instance, a SELECT(file by DF name) command. The following command would select the ICAO electronic passport application (AID A002471001): byte[] command = new byte[]{ (byte)0x00, /* CLA = 00 (first interindustry command set) */ (byte)0xA4, /* INS = A4 (SELECT) */ (byte)0x04, /* P1 = 04 (select file by DF name) */ (byte)0x0C, /* P2 = 0C (first or only file; no FCI) */ (byte)0x07, /* Lc = 7 (data/AID has 7 bytes) */ /* AID = A002471001: */ (byte)0xA0, (byte)0x00, (byte)0x00, (byte)0x02, (byte)0x47, (byte)0x10, (byte)0x01 }; As a response you would get e.g. status code 9000 if the applet was found on the card. Best regards, Michael -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Closing canvas view and starting new activity
You already asked this, and I asked a follow-up question to get more information... How are you originally getting into the activity you are trying to finish? The reason I asked this is because I noticed that you are trying to start an activity that displays some sort of game menu... Why not do this: - Initially start the app with the menu activity - From there call the activity with the canvas view in question - Call finish whenever you are done with that activity - By the magic of the Android OS you are automatically back at your menu activity... Thanks, Justin Anderson MagouyaWare Developer http://sites.google.com/site/magouyaware On Mon, May 2, 2011 at 8:02 PM, imz7070 imz7...@gmail.com wrote: Hello, I am playing around with the code in this tutorial: http://www.anddev.org/basic_and_simple_2d_drawing_-_animation-t3085.html The problem is I cannot end this activity and start a new one. I know for XML views you would use this: finish(); startActivity(new Intent(this, MenuActivity.class)); This does not work for canvas views though. Could someone please tell me how I would be able to finish a canvas view and start a new activity? Thanks. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Evernote API: Question related to Intent sample
Seems like a better place to ask this would be some sort of support forum for Evernote... Thanks, Justin Anderson MagouyaWare Developer http://sites.google.com/site/magouyaware On Tue, May 3, 2011 at 8:21 AM, ijaz ijaxah...@googlemail.com wrote: Hi, I am making an application and trying to combine my application with Evernote. for this i have download SDK and sample code. I prefer to use Intent way of calling Evernote through my Application. So the problem is when i call create note intenet the Evernote opens and note is save/uploaded in the Evenote application. After that i want following things, - how can i get New created Note tile to show in my application -How can i get Note gguid back in my application to open specific note later. there is mathod called in my application after return if the intent onActivityResult , im sure something to do in this mathod but not sure what to do. i called this method data.getStringExtra(gguid); in onActivityResult method but it dosent work Could someone please help, Thanks and many regards, ijaz -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Anyone notice active installs plummet WITHOUT releasing update?
On Wed, May 4, 2011 at 3:08 PM, Justin Anderson magouyaw...@gmail.com wrote: I'm thinking it may be that people are starting to switch more and more to alternative app stores (such as Amazon) ... Highly unlikely. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] ActivityAdapter and ActivityIconAdapter - not available anymore??
Im trying to use ActivityAdapter and ActivityIconAdapter but it seems likes it not available. Am i missing something? Are there alternative classes to these? Thanks, Jumana -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Update Contacts
IT WORKED! THANK YOU! I could hit my self... I always use newUpdate(ContactsContract.Data.CONTENT_URI) for updating the values except for the StructuredName... On 4 Mai, 07:42, Stefan S shogu...@gmail.com wrote: I'll try. Thanks for the hint. Curiosley I can update the addresses, organisations etc with the state above but the StructuredName values. This is really strange... On 30 Apr., 10:51, Ali Chousein ali.chous...@gmail.com wrote: Hhhmmm, maybe you should try newUpdate(ContactsContract.Data.CONTENT_URI) instead of newUpdate(ContactsContract.Contacts.CONTENT_URI) I hope it helps :-)- Zitierten Text ausblenden - - Zitierten Text anzeigen - -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Anyone notice active installs plummet WITHOUT releasing update?
Appears to me that google have re-jigged the way active installs are counted. In the statistics view, my historic installs (for a given date or period - say over xmas) are down about 10% on when i view last week, so don't believed they've dropped in the past week as it would first appear. On May 4, 4:24 pm, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Wed, May 4, 2011 at 3:08 PM, Justin Anderson magouyaw...@gmail.com wrote: I'm thinking it may be that people are starting to switch more and more to alternative app stores (such as Amazon) ... Highly unlikely. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] SDCard installs - auto or preferExternal?
I am guessing my manifest entry is better (from the users point of view) as: android:installLocation=preferExternal Would users prefer android:installLocation=auto? Would app users prefer installing to their SDCard by default rather than to internal memory? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Filtering NFC intents, NDEF message external type
Hi, Thanks for your response. On 4 mayo, 08:04, Michael Roland mi.rol...@gmail.com wrote: Hallo Gorka, for the moment Android provides no means to directly dispatch your application based on anNFCForumExternalType (btw, yourexternal type name does not follow the RTD specification, TheExternalType Name MUST be formed by taking the domain name of the issuing organization, adding a colon, and then adding the type name as managed by the organization.) By the way, I cannot filter smartposter and URI NDEF message types. Could someone tell me how to do this?? Filtering should work based on the data of the URI record (both for the URI record itself and the SmartPoster's embedded URI record). You can do this with data ... /. br Michael -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Problems with WebView and soft keyboard
Hi I am having some problems with a WebView (Honeycomb). My WebView is located in a Fragment, where it is placed in a hierachy like this: Fragment ReleativeLayout FrameLayout AbsolutLayout AbsolutLayout WebView When I select an input field in the form (And the keyboard appears), the entire content is moved so that the input field should be visible, but it isnt! Everything except the WebView is moved and drawn correctly (including children to the WebView). Actually it looks like the WebView is moved (I am able to switch between the fields by touching the screen where I expect the fields to be moved to). Somehow the WebView isn’t redrawn after the move, and the inputfields stille appear as they where below the keyboard. Does any one has an idea what the problem is? http://goo.gl/8KpfO http://goo.gl/sYckQ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] LocationManager and MyLocationOverlay
Hello. When booting I get the card user's location on the map: private MapView mapView; private MapController mapController; private MyLocationOverlay myLocationOverlay; private LocationManager mLocationManager; private LocationListener mLocationListener; mapController = mapView.getController(); initMap(); mapController.setZoom(18); mapView.setClickable(true); mapView.setEnabled(true); mapView.setSatellite(false);} private void initMap() { myLocationOverlay = new MyLocationOverlay(this, mapView); mapView.getOverlays().add(myLocationOverlay); myLocationOverlay.enableCompass(); myLocationOverlay.enableMyLocation(); myLocationOverlay.runOnFirstFix(new Runnable() { public void run() { mapController.animateTo(myLocationOverlay.getMyLocation()); } }); How can I update the data after some time. I do so, but it does not work. mLocationManager = (LocationManager) this.getSystemService(Context.LOCATION_SERVICE); mLocationListener = new LocationListener() { public void onLocationChanged(Location location) { makeUseOfNewLocation(location); } public void onStatusChanged(String provider, int status, Bundle extras) {} public void onProviderEnabled(String provider) {} public void onProviderDisabled(String provider) {} }; mLocationManager.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, 0, 0, locationListener); mLocationManager.requestLocationUpdates(LocationManager.GPS_PROVIDER, 0, 0, locationListener); What I am doing no wrong? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: How to add wallpapers from my application code to the Wallpaper Gallery (Home Screen MENU Wallpaper Wallpaper gallery)
I am newbie and this is very basic question, let me clear this again. I want to store some images from my application to some internal device location(not external SD card). Can anyone please let me know which location(any shared directory for all apps) on internal storage is this? thanks you mack On Apr 27, 12:42 pm, mack2978 smashmah...@gmail.com wrote: Pls help me On Apr 27, 12:08 pm, mack2978 smashmah...@gmail.com wrote: Hi All, I want to add wallpapers from my application code to theWallpaper Gallery (HomeScreenMENUWallpaperWallpapergallery). Can anybody please help me how to achive this? Thanks in advance. thanks, mack -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Building C code for Android (no Java/jni)
On Tue, 3 May 2011 09:50:50 -0700 (PDT), Igor Prilepov iprile...@gmail.com wrote: It is possible with NDK and here is the best link I know: http://betelco.blogspot.com/2010/01/buildingdebugging-android-native-c.html However, this approach is helpful only for a very few cases, for example, when you are making some tools for yourself only. Any real application development must be done using Java/JNI approach. Thanks. I'll look at that link. FYI I don't mind using the NDK. I just thought that this was not possible to do using the NDK. The application is just for my own use and I usually use the normal SDK for development. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 Item Focussable issue
Please ignore this question. I think i found my problem. I had forgotten to set the background of the ListView item (item.xml in this case). Added the android:background=@android:drawable/menuitem_background and then i could get the focus for all my ListView Items. Thanks. On May 3, 11:14 pm, droid-stricken harik...@gmail.com wrote: Hi, There seems to be a lot of questions on this very issue. I have gone thro' most of them and yet unable to find a workable solution :( I am unable to get the focus on any item of my list. My Activity DOES NOT extend ListActivity and i do not have any ListView with default ID - android.R.id.list since i have more than one ListViews to deal with in my activity. The following is the relevant code from my ListAdapter. There seems to be this problem whenever i attempt to use convertView.setOnClickListener() instead of the standard listViewInstance.setOnItemClickListener() to react to the user's click on the list items. Why is that? I am forced to use convertView.setOnClickListener() under some circumstances because listViewInstance.setOnItemClickListener() does not seem to work under those cases. Trying to understand the basic difference between the two cases. Interestingly, i am able to detect the click event and the convertView.setOnClickListener() gets called - on the second attempt though - i don't know what's happening to the first click event. Any ideas or links to materials? public class MyListAdapter extends BaseAdapter { protected static final String TAG = MyListAdapter; private LayoutInflater mInflater; private Context mContext; public MyListAdapter(MainActivity mainActivity) { // TODO Auto-generated constructor stub mContext = mainActivity; mInflater = LayoutInflater.from(mainActivity); } @Override public View getView(int position, View convertView, ViewGroup parent) { // TODO Auto-generated method stub ViewItemHolder holder; if (convertView == null) { convertView = mInflater.inflate(R.layout.item, null); convertView.setClickable(true); convertView.setFocusableInTouchMode(true); convertView.setFocusable(true); holder = new ViewItemHolder(); holder.timeStamp = (TextView) convertView.findViewById(R.id.textView1); holder.firstLine = (TextView) convertView.findViewById(R.id.textView2); convertView.setTag(holder); } else { holder = (ViewItemHolder) convertView.getTag(); } holder.timeStamp.setText(itemObj.getTitleItem(position)); holder.firstLine.setText(itemObj.getMessageItem(position)); holder.positionInList = position; holder.listIndex = parent.getId(); convertView.setOnClickListener(clickListener); return convertView; } OnClickListener clickListener = new OnClickListener() { @Override public void onClick(View v) { // TODO Auto-generated method stub ViewItemHolder vh = (ViewItemHolder) v.getTag(); Log.v(TAG, [ + vh.listIndex + ][ + vh.positionInList + ] + (String) vh.timeStamp.getText() + , + (String) vh.firstLine.getText()); } }; } 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 Linkify.addLinks(
The code that I am using is this: In the method getView of the ArrayAdapter class, when you click in the title of one of the items, I do this: class EventoAdapter extends ArrayAdapter { Activity context; EventoAdapter(Activity context) { super(context, R.layout.listitem_titular, miLista); this.context = context; } public View getView(int position, View convertView, ViewGroup parent) { lblTitle.setOnClickListener(new OnClickListener() { public void onClick(View v) { // TODO Auto-generated method stub TextView tv = (TextView)findViewById( R.id.link2_view ); tv.setText(la_dire); Linkify.addLinks( tv, Linkify.WEB_URLS ); } }); } . } When I click labelTitle, the link appeared, and you can click there and open the url . BUt What I want isn´t this, I want when I click in the labelTitle to open the url directly, I don´t want to have to click in the url. How can I do this? thank you very much, excuse my english. On May 3, 12:04 pm, beginer j.ur...@gmail.com wrote: I resolved the problem, but known the link only appear sometimes. I have a List View, and the both elements have a link, but in some element appear the link and in others not. Wht is the problem? thaks very much On May 3, 10:42 am, Kostya Vasilyev kmans...@gmail.com wrote: Something is null at line 147 in your AndroidXml.java. -- Kostya 03.05.2011 12:11, beginer ?: 05-03 08:05:16.051: ERROR/AndroidRuntime(339): FATAL EXCEPTION: main 05-03 08:05:16.051: ERROR/AndroidRuntime(339): java.lang.NullPointerException 05-03 08:05:16.051: ERROR/AndroidRuntime(339): at net.sgoliver.AndroidXml$EventoAdapter.getView(*AndroidXml.java:147*) -- 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] Re: Widget-specific Preferences
Jake, With each widget having its own settings, you are pretty much forced to update them individually. I would have the alarm receiver obtain all widget Ids and send them using startService all at once. The service would then do the filtering for stale Ids, combined with loading actual settings. My code looks like this : int[] widgetIdList = ... WidgetPrefs prefs = for (widgetId : widgetIdList) { if (prefs.load(widgetId)) { build and push an update } } If prefs.load returns false, it means this the widgetId is stale. To your specific questions: 1 - Calling startService once for the entire list should be more efficient; 2 - AppWidgetManager: void updateAppWidget(int appWidgetId, RemoteViews views) 3 - Each RemoteViews update needs to be self-sufficient, that is, contain all the data items (setTextViewText, etc.) as well as PendingIntent's. Do not push separate, incremental, RemoteViews: one for text views, then another for pending intents, etc. If you do, your widget will stop working after a home screen orientation change or if the Launcher is kicked out of memory. http://kmansoft.wordpress.com/2010/05/23/widgets-and-orientation-changes/ The lifetime of widget receiver does not matter here. The contents of RemoteViews is saved by the launcher, and PenidingIntent's are saved by the system. Finally, do not ignore onUpdate. The launcher may have its reasons to rebuild the widgets, such as when the user changes the phone's UI language, and maybe in other cases as well. -- Kostya 04.05.2011 1:56, Jake Colman пишет: Kostya, Hmm. Whenever the alarm in AppWidgetProvider is triggered, I have to update all widget instances as per the widget-specific preference. Based on what you have suggested, does the following make sense: 1) In the AppWidgetProvider's onReceive() method when it receives the intent from the alarm, it cycles through all valid widgetids and starts the service with an intent containing that widgetid. Actually, I can just invoke with service once with an intent containing the list of all valid widgetids. 2) The service cycles through the list of widgetids and updates each widget's remoteview using the widget-specific preference. I didn't check it just now but I'm sure I can get each widget's RemoteView and update each one separately. 3) I currently set the remoteview's onClickPendingIntent in the service. Which means I am setting it up every time the service updates the remoteview. Is that really the best way to do it? Can I set the remoteview's onClickPendingIntent in the AppWidgetProvider or, since the AppWidgetProvider regularly gets destroyed I cannot do it there? ...Jake 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: Parts of words in TextView are out of the screen
The font has to be Right To Left since the app is in Arabic.. On May 4, 5:14 am, Indicator Veritatis mej1...@yahoo.com wrote: Seehttp://stackoverflow.com/questions/2025282/difference-of-px-dp-dip-an... and reconsider your use of 15sp. You may want to set other attributes too, but it seems that using 'sp' for android:padding alone is probably not what you want. It might be a good idea to test it out with other fonts too, in particular, with an alphabet that goes form left to righ to eliminate the possibility that this is a bug in BIDI support. On May 3, 2:07 am, omar omarfb...@gmail.com wrote: Hey, I have a problem where parts of the Text in the TextView are out of the screen, Look at the picture:http://i.imgur.com/fDqa6.png I marked the problem in red squares.. xml: ?xml version=1.0 encoding=utf-8? LinearLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=fill_parent android:background=@drawable/list android:padding=15sp ScrollView android:id=@+id/ScrollView01 android:layout_width=fill_parent android:layout_height=fill_parent LinearLayout android:layout_width=fill_parent android:layout_height=fill_parent android:gravity=right TextView android:id=@+id/TfseerTextView android:layout_width=fill_parent android:layout_height=fill_parent android:textSize=17sp android:textColor=#000 /TextView /LinearLayout /ScrollView /LinearLayout Is it possible to fix? Is there any work around? 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: Evernote API: Question related to Intent sample
Yeah, i did but no reply, still waiting if someone could help. Thanks On May 4, 2:20 am, Justin Anderson magouyaw...@gmail.com wrote: Seems like a better place to ask this would be some sort of support forum for Evernote... Thanks, Justin Anderson MagouyaWare Developerhttp://sites.google.com/site/magouyaware On Tue, May 3, 2011 at 8:21 AM, ijaz ijaxah...@googlemail.com wrote: Hi, I am making an application and trying to combine my application with Evernote. for this i have download SDK and sample code. I prefer to use Intent way of calling Evernote through my Application. So the problem is when i call create note intenet the Evernote opens and note is save/uploaded in the Evenote application. After that i want following things, - how can i get New created Note tile to show in my application -How can i get Note gguid back in my application to open specific note later. there is mathod called in my application after return if the intent onActivityResult , im sure something to do in this mathod but not sure what to do. i called this method data.getStringExtra(gguid); in onActivityResult method but it dosent work Could someone please help, Thanks and many regards, ijaz -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: problem with Linkify.addLinks(
You can set an onClickListener for the view, and use ACTION_VIEW for your http://...; URI. http://stackoverflow.com/questions/2201917/android-open-url-from-code -- Kostya 04.05.2011 12:44, beginer пишет: When I click labelTitle, the link appeared, and you can click there and open the url . BUt What I want isn´t this, I want when I click in the labelTitle to open the url directly, I don´t want to have to click in the url. How can I do this? thank you very much, excuse my english. -- 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: Anyone notice active installs plummet WITHOUT releasing update?
Yes, but I had a minor release at about the same time. Went from 43% active to 37% active in oine hit, the total downloads didn't change at all, just the active installs. I note that my market rank went up one spot when this happened; either it also happened to everybody else or the active installs don't matter much ... OTOH, my first paid app had a 103% active install rate a few days ago, with more active installations than downloads, but is now looking more plausible. On May 4, 4:57 pm, Rich@TheLogicBox richlarco...@gmail.com wrote: Appears to me that google have re-jigged the way active installs are counted. In the statistics view, my historic installs (for a given date or period - say over xmas) are down about 10% on when i view last week, so don't believed they've dropped in the past week as it would first appear. On May 4, 4:24 pm, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Wed, May 4, 2011 at 3:08 PM, Justin Anderson magouyaw...@gmail.com wrote: I'm thinking it may be that people are starting to switch more and more to alternative app stores (such as Amazon) ... Highly unlikely.- 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] Problems with WebView and soft keyboard
If you are seeing this with the Android Compatibility Library, that appears to be a bug: http://code.google.com/p/android/issues/detail?id=16291 On Wed, May 4, 2011 at 3:15 AM, jonfogh jonf...@gmail.com wrote: Hi I am having some problems with a WebView (Honeycomb). My WebView is located in a Fragment, where it is placed in a hierachy like this: Fragment ReleativeLayout FrameLayout AbsolutLayout AbsolutLayout WebView When I select an input field in the form (And the keyboard appears), the entire content is moved so that the input field should be visible, but it isnt! Everything except the WebView is moved and drawn correctly (including children to the WebView). Actually it looks like the WebView is moved (I am able to switch between the fields by touching the screen where I expect the fields to be moved to). Somehow the WebView isn’t redrawn after the move, and the inputfields stille appear as they where below the keyboard. Does any one has an idea what the problem is? http://goo.gl/8KpfO http://goo.gl/sYckQ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.4 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] ActivityAdapter and ActivityIconAdapter - not available anymore??
On Wed, May 4, 2011 at 2:45 AM, Jumana jumanamaj...@gmail.com wrote: Im trying to use ActivityAdapter and ActivityIconAdapter but it seems likes it not available. Am i missing something? Those classes have been gone from the SDK for nearly three years. Are there alternative classes to these? There may be third-party classes that implement this code. There is an ActivityAdapter in the Android open source code that you could copy. Or, just create one yourself. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.4 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Anyone notice active installs plummet WITHOUT releasing update?
The # of installs now match what's show on the graphs. In my case, the install % of my paid app had gone up by 7% while the free app's had gone down by 4%. On May 4, 5:41 pm, Peter Webb r.peter.w...@gmail.com wrote: Yes, but I had a minor release at about the same time. Went from 43% active to 37% active in oine hit, the total downloads didn't change at all, just the active installs. I note that my market rank went up one spot when this happened; either it also happened to everybody else or the active installs don't matter much ... OTOH, my first paid app had a 103% active install rate a few days ago, with more active installations than downloads, but is now looking more plausible. On May 4, 4:57 pm, Rich@TheLogicBox richlarco...@gmail.com wrote: Appears to me that google have re-jigged the way active installs are counted. In the statistics view, my historic installs (for a given date or period - say over xmas) are down about 10% on when i view last week, so don't believed they've dropped in the past week as it would first appear. On May 4, 4:24 pm, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Wed, May 4, 2011 at 3:08 PM, Justin Anderson magouyaw...@gmail.com wrote: I'm thinking it may be that people are starting to switch more and more to alternative app stores (such as Amazon) ... Highly unlikely.- Hide quoted text - - Show quoted text -- 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: Problems with WebView and soft keyboard
Thanks. But my problem isnt that the keyboard dosnt appear, but that the WebView isnt rendered correctly (See links to screen shots in the initial post). On 4 Maj, 11:58, Mark Murphy mmur...@commonsware.com wrote: If you are seeing this with the Android Compatibility Library, that appears to be a bug: http://code.google.com/p/android/issues/detail?id=16291 On Wed, May 4, 2011 at 3:15 AM, jonfogh jonf...@gmail.com wrote: Hi I am having some problems with a WebView (Honeycomb). My WebView is located in a Fragment, where it is placed in a hierachy like this: Fragment ReleativeLayout FrameLayout AbsolutLayout AbsolutLayout WebView When I select an input field in the form (And the keyboard appears), the entire content is moved so that the input field should be visible, but it isnt! Everything except the WebView is moved and drawn correctly (including children to the WebView). Actually it looks like the WebView is moved (I am able to switch between the fields by touching the screen where I expect the fields to be moved to). Somehow the WebView isn’t redrawn after the move, and the inputfields stille appear as they where below the keyboard. Does any one has an idea what the problem is? http://goo.gl/8KpfO http://goo.gl/sYckQ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.4 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Problems with WebView and soft keyboard
On Wed, May 4, 2011 at 6:34 AM, jonfogh jonf...@gmail.com wrote: Thanks. But my problem isnt that the keyboard dosnt appear, but that the WebView isnt rendered correctly (See links to screen shots in the initial post). I can't view those screenshots, as they are hosted by a hosting firm that is serving ads from a malware site, so Chrome is blocking them. Which, since I happen to be on Windows at the moment, is a good thing. I would delete all the AbsoluteLayouts in your code. They should not be used, period, and definitely not in conjunction with fragments. I do not know why you have a FrameLayout in the RelativeLayout. Beyond that, use hierarchyviewer (or the Hierarchy View perspective in DDMS) to see what is going wrong with your layouts. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.4 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] AVD specs for nexus one
Hi, I'm trying to set up my AVD for using like a Nexus one because I have some layout problems. I put in AVD these: Try with WVGA800 and SDK 2.1 But doesnt works!, the screen is very big. Could you help me please? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] http proxy
Hi all, I am creating a app for setting the http-proxy and port for wifi. Can any buddy provide me any API or class for this. I searched in the android docs but didn't find any thing related with this. 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] http proxy
Hi all, I want to change the http proxy and port manually (through adb). Can any buddy have idea about this... 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
Re: [android-developers] Re: Battery Log using service
Look at the stack crawl that is printed when the app is crashed and try to determine from that what went wrong. That is your first job, before asking for help here. On Wed, May 4, 2011 at 1:20 AM, Omkar omkar.ghai...@gmail.com wrote: I have pasted my code below.. I somehow dont get the Toast at all even when the app is triggered on usb cable plugin to the device. It starts off but force closes.. Pls suggest whats wrong here. I have a intent filter under receiver for Action_Power_Connected and disconnected under the manifest file whereas a intentfilter for action_battery_changed for actual battery details. package com.utilities.android.batterylog; import android.app.Activity; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.content.IntentFilter; import android.os.BatteryManager; import android.os.Bundle; import android.os.Handler; import android.os.Message; import android.widget.TextView; import android.widget.Toast; public class BatteryLog extends Activity { private TextView mStatus; private TextView mLevel; private TextView mScale; private TextView mHealth; private TextView mVoltage; private TextView mTemperature; private TextView mTechnology; private static final int EVENT_TICK = 1; private Handler mHandler = new Handler() { @Override public void handleMessage(Message msg) { switch (msg.what) { case EVENT_TICK: //updateBatteryStats(); sendEmptyMessageDelayed(EVENT_TICK, 1000); break; } } }; /** * Format a number of tenths-units as a decimal string without using a * conversion to float. E.g. 347 - 34.7 */ private final String tenthsToFixedString(int x) { int tens = x / 10; return new String( + tens + . + (x - 10*tens)); } /** *Listens for intent broadcasts */ private IntentFilter mIntentFilter; private BroadcastReceiver mIntentReceiver = new BroadcastReceiver() { @Override public void onReceive(Context context, Intent intent) { String action = intent.getAction(); if(action.equals(intent.ACTION_POWER_CONNECTED)) { Toast.makeText(context, Power Connected, (int) System.currentTimeMillis()); } else if(action.equals(intent.ACTION_POWER_DISCONNECTED)) { Toast.makeText(context, Power DisConnected, (int) System.currentTimeMillis()); } else if (action.equals(Intent.ACTION_BATTERY_CHANGED)) { int plugType = intent.getIntExtra(plugged, 0); mLevel.setText(level = + intent.getIntExtra(level, 0)); mScale.setText(scale = + intent.getIntExtra(scale, 0)); mVoltage.setText(voltage = + intent.getIntExtra(voltage, 0) + + getString(R.string.battery_info_voltage_units)); mTemperature.setText(temperature = + tenthsToFixedString(intent.getIntExtra(temperature, 0)) + getString(R.string.battery_info_temperature_units)); mTechnology.setText(technology = + intent.getStringExtra(technology)); int status = intent.getIntExtra(status, BatteryManager.BATTERY_STATUS_UNKNOWN); String statusString; if (status == BatteryManager.BATTERY_STATUS_CHARGING) { statusString = getString(R.string.battery_info_status_charging); if (plugType 0) { statusString = statusString + = + getString( (plugType == BatteryManager.BATTERY_PLUGGED_AC) ? R.string.battery_info_status_charging_ac : R.string.battery_info_status_charging_usb); } } else if (status == BatteryManager.BATTERY_STATUS_DISCHARGING) { statusString = getString(R.string.battery_info_status_discharging); } else if (status == BatteryManager.BATTERY_STATUS_NOT_CHARGING) { statusString = getString(R.string.battery_info_status_not_charging); } else if (status == BatteryManager.BATTERY_STATUS_FULL) { statusString = getString(R.string.battery_info_status_full); } else { statusString = getString(R.string.battery_info_status_unknown); } mStatus.setText(statusString); int health = intent.getIntExtra(health, BatteryManager.BATTERY_HEALTH_UNKNOWN); String healthString; if (health == BatteryManager.BATTERY_HEALTH_GOOD) { healthString = getString(R.string.battery_info_health_good);
Re: [android-developers] Re: Building C code for Android (no Java/jni)
This group is for working with the SDK, so if you don't want to write any Java this is about the last place to look. If you feel like you need to avoid the NDK, you should look on groups like android-porting which are for working with the internal platform. On Wed, May 4, 2011 at 4:17 AM, maf...@yahoo.co.uk wrote: On Tue, 3 May 2011 09:50:50 -0700 (PDT), Igor Prilepov iprile...@gmail.com wrote: It is possible with NDK and here is the best link I know: http://betelco.blogspot.com/2010/01/buildingdebugging-android-native-c.html However, this approach is helpful only for a very few cases, for example, when you are making some tools for yourself only. Any real application development must be done using Java/JNI approach. Thanks. I'll look at that link. FYI I don't mind using the NDK. I just thought that this was not possible to do using the NDK. The application is just for my own use and I usually use the normal SDK for development. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Battery Log using service
I have done that while debugging.. But don't know what exactly to look for in this case.. Hence a clue or something would be helpful. Thats why I have pasted the code so a direct pinpointing at error can be done by someone more experienced than me. Thanks Omkar On May 4, 4:09 pm, Dianne Hackborn hack...@android.com wrote: Look at the stack crawl that is printed when the app is crashed and try to determine from that what went wrong. That is your first job, before asking for help here. On Wed, May 4, 2011 at 1:20 AM, Omkar omkar.ghai...@gmail.com wrote: I have pasted my code below.. I somehow dont get the Toast at all even when the app is triggered on usb cable plugin to the device. It starts off but force closes.. Pls suggest whats wrong here. I have a intent filter under receiver for Action_Power_Connected and disconnected under the manifest file whereas a intentfilter for action_battery_changed for actual battery details. package com.utilities.android.batterylog; import android.app.Activity; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.content.IntentFilter; import android.os.BatteryManager; import android.os.Bundle; import android.os.Handler; import android.os.Message; import android.widget.TextView; import android.widget.Toast; public class BatteryLog extends Activity { private TextView mStatus; private TextView mLevel; private TextView mScale; private TextView mHealth; private TextView mVoltage; private TextView mTemperature; private TextView mTechnology; private static final int EVENT_TICK = 1; private Handler mHandler = new Handler() { @Override public void handleMessage(Message msg) { switch (msg.what) { case EVENT_TICK: //updateBatteryStats(); sendEmptyMessageDelayed(EVENT_TICK, 1000); break; } } }; /** * Format a number of tenths-units as a decimal string without using a * conversion to float. E.g. 347 - 34.7 */ private final String tenthsToFixedString(int x) { int tens = x / 10; return new String( + tens + . + (x - 10*tens)); } /** *Listens for intent broadcasts */ private IntentFilter mIntentFilter; private BroadcastReceiver mIntentReceiver = new BroadcastReceiver() { @Override public void onReceive(Context context, Intent intent) { String action = intent.getAction(); if(action.equals(intent.ACTION_POWER_CONNECTED)) { Toast.makeText(context, Power Connected, (int) System.currentTimeMillis()); } else if(action.equals(intent.ACTION_POWER_DISCONNECTED)) { Toast.makeText(context, Power DisConnected, (int) System.currentTimeMillis()); } else if (action.equals(Intent.ACTION_BATTERY_CHANGED)) { int plugType = intent.getIntExtra(plugged, 0); mLevel.setText(level = + intent.getIntExtra(level, 0)); mScale.setText(scale = + intent.getIntExtra(scale, 0)); mVoltage.setText(voltage = + intent.getIntExtra(voltage, 0) + + getString(R.string.battery_info_voltage_units)); mTemperature.setText(temperature = + tenthsToFixedString(intent.getIntExtra(temperature, 0)) + getString(R.string.battery_info_temperature_units)); mTechnology.setText(technology = + intent.getStringExtra(technology)); int status = intent.getIntExtra(status, BatteryManager.BATTERY_STATUS_UNKNOWN); String statusString; if (status == BatteryManager.BATTERY_STATUS_CHARGING) { statusString = getString(R.string.battery_info_status_charging); if (plugType 0) { statusString = statusString + = + getString( (plugType == BatteryManager.BATTERY_PLUGGED_AC) ? R.string.battery_info_status_charging_ac : R.string.battery_info_status_charging_usb); } } else if (status == BatteryManager.BATTERY_STATUS_DISCHARGING) { statusString = getString(R.string.battery_info_status_discharging); } else if (status == BatteryManager.BATTERY_STATUS_NOT_CHARGING) { statusString = getString(R.string.battery_info_status_not_charging); } else if (status == BatteryManager.BATTERY_STATUS_FULL) { statusString = getString(R.string.battery_info_status_full);
[android-developers] searching the web from phone ..
Hi , is there a possibility for having a sync between the search boxes on android platform ? For example , can i have a edittext on android phone where , what ever i type should be searched in some xyz.com 's site search and should return the exact values that would have displayed when searched on the site . -- ThanksRegards Kaushik Pendurthi http://kaushikpendurthi.blogspot.com/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] WebView and Scroll Vertical
Hello. Webviev use to display pages on the Internet. Horizontal scrolling the village works, and the vertical is not. Phone screen twitches and all. How can there be a problem? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: WebView and Scroll Vertical
is this on 2.3.3? I noticed the webkit browser throwing a few fits with some sites since I upgraded my Nexus One to that version. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: AVD specs for nexus one
Define very big While starting the AVD you can check the scale box. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: SDCard installs - auto or preferExternal?
My testers told me that auto is more appropriate, and we have included text in the help section to show the regular users how to move the app to SD card (and back) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Battery Log using service
post the stack trace. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Can startActivity() be called from any of the Activity lifecycle methods?
and it only gives bad ideas (tm) to people who try to keep their app alive despite the explicit user intent of terminating 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] Re: Problems with WebView and soft keyboard
After searching the net further, I think this might be down to this issue: http://code.google.com/p/android/issues/detail?id=5497 But thanks for your help! Sadly simplifying the hierachy didnt help. On 4 Maj, 12:42, Mark Murphy mmur...@commonsware.com wrote: On Wed, May 4, 2011 at 6:34 AM, jonfogh jonf...@gmail.com wrote: Thanks. But my problem isnt that the keyboard dosnt appear, but that the WebView isnt rendered correctly (See links to screen shots in the initial post). I can't view those screenshots, as they are hosted by a hosting firm that is serving ads from a malware site, so Chrome is blocking them. Which, since I happen to be on Windows at the moment, is a good thing. I would delete all the AbsoluteLayouts in your code. They should not be used, period, and definitely not in conjunction with fragments. I do not know why you have a FrameLayout in the RelativeLayout. Beyond that, use hierarchyviewer (or the Hierarchy View perspective in DDMS) to see what is going wrong with your layouts. -- Mark Murphy (a Commons Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.4 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: SDCard installs - auto or preferExternal?
Yes, maybe 'auto' better, I read somewhere that a few models will fail to install at all if install location is set to preferExternal. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Widget-specific Preferences
KV == Kostya Vasilyev kmans...@gmail.com writes: KV 3 - Each RemoteViews update needs to be self-sufficient, that is, KV contain all the data items (setTextViewText, etc.) as well as KV PendingIntent's. KV Do not push separate, incremental, RemoteViews: one for text KV views, then another for pending intents, etc. If you do, your KV widget will stop working after a home screen orientation change KV or if the Launcher is kicked out of memory. KV http://kmansoft.wordpress.com/2010/05/23/widgets-and-orientation-changes/ KV The lifetime of widget receiver does not matter here. The KV contents of RemoteViews is saved by the launcher, and KV PenidingIntent's are saved by the system. KV Finally, do not ignore onUpdate. The launcher may have its KV reasons to rebuild the widgets, such as when the user changes the KV phone's UI language, and maybe in other cases as well. So it *is* correct always set up the onClickPendingIntent every time I build and push update. I thought maybe I had missed something and was making a colossal error. I guess I will recode my onReceive() to actually do its work by invoking onUpdate(). This way it all works even if the system invokes onUpdate() on its own. Thanks again, Kostya, for your excellent help. This widget of mine started out as a learning exercise (I have many years of C/C++ experience but almost none with Java and none at all with Android) but one that solved a real problem. I posted the widget thinking that others might find it useful too. I now have close to 400 active users (as measured by Flurry via a once daily broadcast) and keep getting requests for enhancements. Without the help of people such as yourself (and Mark Murphy, Treking, and a few others) I never would have made it this far. Thanks! -- 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: Bluetooth server and channel number
I finally figured out what the problem was. The problem is in BluetoothAdapter.getDefaultAdapter(). This method create implicitely a Handler connected to the looper of the current thread. And this method is static and returns a singleton. This mean that the first call, and only the first call, must be done on a thread that will call Looper.loop() and not just exit ! In BluetoothChat sample, the adapter is created in onCreate() of the activity : // Get local Bluetooth adapter mBluetoothAdapter = BluetoothAdapter.getDefaultAdapter(); // If the adapter is null, then Bluetooth is not supported if (mBluetoothAdapter == null) { ... } According to comments, we may think taht this is just to check if a bluetoothAdapter exists but in fact, if it is not done here (but for example on AcceptThread), it will not work at all ! So I think that 1/ the implicit usage of the first thread calling a method that return a singleton is a really bad design 2/ Bluetooth chat sample should maybe have a comment added 3/ BluetoothAdapter.getDefaultAdapter() should maybe start its own thread. Maybe something like : private BluetoothAdapter _btAdapter = null; public synchronized BluetoothAdapter getAdapter() { if (_btAdapter==null) { final boolean[] ok = new boolean[] { false }; Thread t = new Thread() { public void run() { Looper.prepare(); _btAdapter = BluetoothAdapter.getDefaultAdapter(); synchronized (ok) { ok[0]=true; ok.notify(); } Looper.loop(); }; }; t.setDaemon(true); t.setName(bt adapter); t.start(); synchronized (ok) { if (ok[0]==false) { try { ok.wait(); } catch (InterruptedException e) { } } } } return _btAdapter; } (this is what I've finally done to correct ...) my 2 cents ... On Apr 26, 9:53 pm, mbaroukh mike.baro...@gmail.com wrote: Hi all. I'm facing a problem I don't find how to handle. I'm doing an application that listen forbluetoothincomming connection. As recommanded, - I have a BluetoothServerSocket that call listenUsingRfcommWithServiceRecord(() - I'm asking for the BluetoothSocket with accept() method of BluetoothServerSocket. - when a connection is received, the BluetoothServerSocket is closed. First, notice thathttp://developer.android.com/guide/topics/wireless/bluetooth.html says on Connecting as a server section : Unless you want to accept additional connections, call [BluetoothServerSocket] close(). that's what I've done but, unless I'm wrong, the chat Samplehttp://developer.android.com/resources/samples/BluetoothChat/src/com/... does not do it although it accept only one connection ... So the problem is that when listenUsingRfcommWithServiceRecord() is called again, the channel change. But clients continues to think that the service is on the previous channel. The problem is not on client side because just stopping/startingbluetoothon the android server make the client find the new channel for the service. For now, all I can do is not closing BluetoothServerSocket but if the client reconnect quicker than the server calling accept(), the client is connected on ... nothing. the call to accept will not return this connection. Does anybody figure out the same problem or have any advice ? Thanks for any help ! Mike -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: WebView and Scroll Vertical
no version 1.6. ok. thanks. On 4 май, 15:49, lbendlin l...@bendlin.us wrote: is this on 2.3.3? I noticed the webkit browser throwing a few fits with some sites since I upgraded my Nexus One to that version. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en