[android-developers] How to fix the image size(28 x 29 png file) in the grouptIndicator of the ExpandableListview ???
how to fix the image size(28 x 29 png file) in the grouptIndicator of the ExpandableListview ??? I use expandableListview and android:groupIndicator in the attribute. The png image size is 28x29. But The Imgae is stretched. Does anyone Know this? Any answer is useful for me . thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Extracting colors from Themes?
Hey Nick, that's the thing. It's not that easy. Checkout what I wrote in my initial post: item name=colorBackground@android:color/background_dark/item item name=textColorPrimary@android:color/primary_text_dark/item They basically look the same right? And they are both public, right? However so far I have only been able to pry the RGB values from the framework's hands for the first, but not the second. And I think it's my fault. It is not straight forward. I think you need to possibly deal with drawables (hopefully not, as this would never give me rgb values) and color state lists. That's the reason I was looking for documentation and sample uses in codesearch.google.com, but to no avail. Cheers, Mariano On Thu, Apr 29, 2010 at 9:11 PM, patbenatar patbena...@gmail.com wrote: Mariano- Well if the colors are publicly accessible you could access them directly [find out the color resource identifiers by digging through the source for the system theme/style xml files.. available in the Git repo], something like: @android:color/resourceid .. This will allow you to use the same colors a theme is using [providing those color resources are public.. I've never tried this]. -Nick On Apr 29, 2:46 am, Mariano Kamp mariano.k...@gmail.com wrote: Hey Pat. Thanks for your chipping in. No, I could also hardcode the colors and that is what it seems I will have to do. In my particular case it won't make much difference at the moment. For now I just need two values and they correspond to the light and dark. But for the future my needs will grow and it is also not so much fun to maintain a shadow theme administration on the side. I would have preferred to be a model citizen on the Android platform and use the themes. Hardcoding might be the quickest solution, but would fail if I want to use platform properties that are overwritten by vendor themes. To give you an example. On a stock Android device you'll see an orange background behind a selected list item, on an HTC sense device it would be green instead. Also as themes look so central to me, I was kind of hoping that I just missed the relevant documentation and that somebody else would point me to RTFM ;-) Cheers Mariano On Tue, Apr 27, 2010 at 9:38 AM, patbenatar patbena...@gmail.com wrote: Do you need to be doing this programatically? You could always take a screenshot of your phone [either using DDMS on a non-rooted device or the PicMe app on a rooted device] and then grab the colors using Photoshop or any image editing software. Another option, again not programmatic, would be to download the Android source [or you can browse it online in the Git repo] and find the declarations for those colors. -Nick On Apr 26, 3:23 am, Mariano Kamp mariano.k...@gmail.com wrote: Hi, I want to use colors from a Theme to apply it to HTML my app is rendering. I am wondering if I can do that? I am looking to use colors like they are specified in themes.xml: item name=colorForeground@android:color/bright_foreground_dark/item .. item name=colorBackground@android:color/background_dark/item .. item name=textColorPrimary@android:color/primary_text_dark/item .. So it looks to me those are declared in the same way. When trying to access those values this way: TypedValue tv = new TypedValue(); getTheme().resolveAttribute(android.R.attr.colorBackground, tv, true); System.out.println(tv.string= + tv.string); System.out.println(tv.coerced= + tv.coerceToString()); int colorResourceId = getResources().getColor(tv.resourceId); System.out.println(colorResourceId= + colorResourceId); tv = new TypedValue(); getTheme().resolveAttribute(android.R.attr.textColorPrimary, tv, true); System.out.println(tv.string= + tv.string); System.out.println(tv.coerced= + tv.coerceToString()); colorResourceId = getResources().getColor(tv.resourceId); System.out.println(colorResourceId= + colorResourceId); I get this as a result: I/System.out( 1578): tv.string=null I/System.out( 1578): tv.coerced=# I/System.out( 1578): colorResourceId=-1 I/System.out( 1578): tv.string=res/color/primary_text_light.xml I/System.out( 1578): tv.coerced=res/color/primary_text_light.xml I/System.out( 1578): colorResourceId=-16777216 The results are different. The first one actually gives me the color #fff which would work for me, the second one only gives me an xml. Do I need to jump through a few more hoops here to resolve the actual color? Does my original intention work at all? Maybe it won't work, because colors could be arbitrary drawables? I didn't find any relevant documentation, but if you know any, just point me there
Re: [android-developers] Re: Option Menu Customization
Hi Rob Mazur, I don't agree with your point, I test on the device with a long enough width for the 3rd option, but we get three rows, each option takes a line. Anyway, thanks for your advice. Best Regards, D.Y -邮件原件- 发件人: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] 代表 Rob Mazur 发送时间: 2010年4月29日 11:34 收件人: Android Developers 主题: [android-developers] Re: Option Menu Customization Looks like they are using custom icons. I bet if you create the icon at a long enough width for your 3rd option (which you want on its own row) it may sort the way you want it to. As long as its a transparent PNG it should look fine. If it does work then just make sure to check it on different screen resolutions. On Apr 28, 10:45 pm, D.Y android.and...@gmail.com wrote: Dear Shekhar, I think it's possible, there should be a solution, you can visit the following link:http://androidandme.com/wp-content/uploads/2009/12/05.categories_opti.. .. jpg But I have no source code, if you have resolved this issue, would you please share it with me? Thanks, Best Regards, D.Y -邮件原件- 发件人: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] 代表 Shekhar 发送时间: 2010年4月25日 0:06 收件人: Android Developers 抄送: shekhar...@gmail.com 主题: [android-developers] Option Menu Customization Hi, Can we customize the Option menu at the UI level.Suppose for one row I want to display three menu items and for the next row only single item.And in the last row only two items? Please let me know if it is possible. Thanks, Shekhar -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- Rob Mazur http://droiddojo.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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Process Crash whilst using JUnit
A couple of thoughts. If it's not consistent when and where it crashes, you may have some type of memory corruption, possibly even a GC bug, though in my experience those are rare beasts. If you have JNI code, (and you do, even if it's not yours), it's more likely in there. Since you've been carefully building your app a little at a time, and since you've been using JUnit, I can offer you two paths along two dimensions, that may help. First, backtrack. Try earlier versions until you find one that does not exhibit this problem, and then see what changed between when you did not, and when you do see this problem. (Since you're using JUnit, I assume you're astute enough to also use a revision control system!) The other approach is to enable and disable unit tests until you find which unit tests are involved in the failure. These should each produce a small set of code as candidates for what triggers the problem. You might need to do things like reorder tests, or repeat them -- it's possible to fix the problem by simply not tripping over the memory corruption. Calling System.gc() twice in a tearDown() after every test may help trigger the problem more promptly and avoid the issue -- but it may not as well, depending on which memory is corrupted. (It's not certain it's a memory corruption -- it could be thread related -- but the initial strategy would be similar). Good luck! On Apr 29, 4:08 am, brucko geoff.bruck...@gmail.com wrote: Nearly at my wits end. Been slowly building my app and now JUnit is crashing regularly with logcat as below. There are no other real hints. No relevant code as this can happen at multiple points of the code. There are no other errors or exceptions thrown. As far as I can tell there is plenty of memory left and my app does not appear to have any leaks I can find during a run outside of JUnit. Any ideas? 04-29 15:05:23.125 I/DEBUG (10948): Build fingerprint: 'htc_asia_wwe/ htc_hero/hero/hero:1.5/2.73.707.9/62020:user/release-keys' 04-29 15:05:23.125 I/DEBUG (10948): pid: 11005, tid: 11006 com.mydomain.myapp 04-29 15:05:23.125 I/DEBUG (10948): signal 11 (SIGSEGV), fault addr 0004 04-29 15:05:23.125 I/DEBUG (10948): r0 r1 4356abd0 r2 4108dd50 r3 0010 04-29 15:05:23.125 I/DEBUG (10948): r4 ad03dc11 r5 00156d78 r6 4356abd0 r7 04-29 15:05:23.125 I/DEBUG (10948): r8 100ffd00 r9 4100af98 10 4100af84 fp 0001 04-29 15:05:23.125 I/DEBUG (10948): ip ad374dd0 sp 100ffcd4 lr ad33a6f1 pc a9d214b6 cpsr 0030 04-29 15:05:23.235 D/AK8973 ( 41): Compass CLOSE 04-29 15:05:23.305 I/DEBUG (10948): #00 pc 000214b6 / system/lib/libutils.so 04-29 15:05:23.305 I/DEBUG (10948): #01 lr ad33a6f1 / system/lib/libandroid_runtime.so 04-29 15:05:23.345 D/UserCreator(11005): onStop 04-29 15:05:23.345 I/ActivityManager( 63): Stopping service: com.mydomain.myapp/.database.UserDbAdapter 04-29 15:05:23.355 D/UserCreator(11005): unbind 04-29 15:05:23.375 I/DEBUG (10948): stack: 04-29 15:05:23.375 I/DEBUG (10948): 100ffc94 afe39dd0 04-29 15:05:23.375 I/DEBUG (10948): 100ffc98 a000 [heap] 04-29 15:05:23.375 I/DEBUG (10948): 100ffc9c afe39dd0 ...and so on then... 04-29 15:36:42.557: INFO/DEBUG(12024): debuggerd committing suicide to free the zombie! 04-29 15:36:42.567: INFO/DEBUG(12175): debuggerd: Aug 28 2009 20:35:01 04-29 15:36:42.577: INFO/ActivityManager(63): Process com.mydomain.myapp (pid 12117) has died. 04-29 15:36:42.577: WARN/ActivityManager(63): Crash of app com.mydomain.myapp running instrumentation ComponentInfo{com.ozdroid.scanner.tests/ android.test.InstrumentationTestRunner} -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Input method recreated many times
hi all, I am trying to create an input method which has some heavy initialization to do in OnCreate(). The problem is whenever i am switching to my Ime from another ime, it is taking 2-3 seconds to initialize and in mean time if i press edit text repeatedly, OnCreate() and OnDestroy() of my IME are called multiple times. Can I somehow prevent this from happening? Thanks in advance. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] scroll view and TableLayout
Hi I have a Scrollview Table Layout. In which i have a header column and another header row. I want to scroll the table without scrolling the headers. Ie i want to selectively stop scrolling of the top row and first column. Can anyone please hel[p me out.. PLEASE i need this to work -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Alarm Clock Localization query
Hi All , I am bit confused about location stuff in Alarm clock application in Eclair 2.1 . I want to confirm if its a feature or a bug . 1 . Click on Main Menu - Alarm Clock -(Any Set Alarm)-Repeat . This pops up list of all weekdays from Monday to Sunday along with check button so as to enable them for corresponding alarm . 2. Now select Dutch(Netherland language) Click on Main Menu-Settings- Language Keyboard- Select Locale-Dutch (Netherlands) This will install Dutch environment in Android . 3. Click on Main Menu - Alarm Clock(Wekker) -(Any Set Alarm)- Herhalen(Repeat) . This will show list of index for week days . rather than this dutch version of weekdays (Mon to Sun) should list out . Concern source code for fetching weekdays is in Alarms.java file under : ANDROID_TOP/packages/apps/AlarmClock/src/com/android/alarmclock for (int i = 0; i 7; i++) { if ((mDays (1 i)) != 0) { ret.append(dayList[DAY_MAP[i]]); dayCount -= 1; if (dayCount 0) ret.append( context.getText(R.string.day_concat)); } } Other localization strings are in strings.xml file under ANDROID_TOP/packages/apps/AlarmClock/res/values-*/ Does it like to have only indexes 0,1,2,,,instead of translated strings for Mon,Tues,... in Dutch etc languages for Alarm Clock ?? Any Help would be appreciated . Thanks : Uander -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en/* * Copyright (C) 2009 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the License); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an AS IS BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package com.android.alarmclock; import android.content.Context; import android.database.Cursor; import android.media.RingtoneManager; import android.net.Uri; import android.os.Parcel; import android.os.Parcelable; import android.provider.BaseColumns; import android.text.format.DateFormat; import java.text.DateFormatSymbols; import java.util.Calendar; public final class Alarm implements Parcelable { // // Parcelable apis // public static final Parcelable.CreatorAlarm CREATOR = new Parcelable.CreatorAlarm() { public Alarm createFromParcel(Parcel p) { return new Alarm(p); } public Alarm[] newArray(int size) { return new Alarm[size]; } }; public int describeContents() { return 0; } public void writeToParcel(Parcel p, int flags) { p.writeInt(id); p.writeInt(enabled ? 1 : 0); p.writeInt(hour); p.writeInt(minutes); p.writeInt(daysOfWeek.getCoded()); p.writeLong(time); p.writeInt(vibrate ? 1 : 0); p.writeString(label); p.writeParcelable(alert, flags); p.writeInt(silent ? 1 : 0); } // // end Parcelable apis // // // Column definitions // public static class Columns implements BaseColumns { /** * The content:// style URL for this table */ public static final Uri CONTENT_URI = Uri.parse(content://com.android.alarmclock/alarm); /** * Hour in 24-hour localtime 0 - 23. * PType: INTEGER/P */ public static final String HOUR = hour; /** * Minutes in localtime 0 - 59 * PType: INTEGER/P */ public static final String MINUTES = minutes; /** * Days of week coded as integer * PType: INTEGER/P */ public static final String DAYS_OF_WEEK = daysofweek; /** * Alarm time in UTC milliseconds from the epoch. * PType: INTEGER/P */ public static final String ALARM_TIME = alarmtime; /** * True if alarm is active * PType: BOOLEAN/P */ public static final String ENABLED = enabled; /** * True if alarm should vibrate * PType:
[android-developers] long HOME KEY press in android 1.6
hi all, normally, when we press long key on HOME KEY, there will show the recently used app list, now if I want to let this long press behavior do nothing, is it possiable? 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: How to see all the applicat ions in the Google Market?
There's also http://www.appbrain.com You can link directly to your apps, e.g.: http://www.appbrain.com/app/com.sfsmart.volume.free On Apr 29, 2:07 am, tobias429 ecker...@gmx.de wrote: Try those web-sites: http://www.androlib.comhttp://www.cyrket.comhttp://www.androidpit.comhttp://www.androidzoom.com Anyone knows further sites? On Apr 29, 8:30 am, Grant Jia jeasun...@gmail.com wrote: Hi, friends, The official web site just show the top applications both free and paid, where or how could I see all the applications in the market? Thanks. Best Regards, Grant -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Android ANT build
Hi all, Is there any tool in eclipse to generate build.xml for my android project. I couldn't get solution to write build.xml. Is it possible to generate APK file and install it on emulator using ANT. Please help. Thanks Veradis -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Developing a C++ static library for use with Java on the Android
Hello Ravi, Thanks for the example .. but it is an example for a dynamic linked lib ( *.so ) not for using any existing code as a static lib ( *.a ). Nevertheless thanks for your efforts and to everybody who provides examples,details and comments. Frank On 29 Apr., 19:32, ravindra singhai singhai.ravin...@gmail.com wrote: Hi Josh, I've attached a sample application athttp://www.naresh.se/phpBB/viewtopic.php?f=10t=19p=33#p33 Attached is a very basic sample application ( SimpleJNI.zip) which will guide you to use C/C++ static library ( .so ) file from android java file. Steps are also mentioned to create C/C++ static library using NDK. Note: Attached SimpleJNI.zip is a bit modified from the one which is available with android open-soruce code. Try this and feel free to ask if it doesn't work :) Cheers !! Ravi On Thu, Apr 29, 2010 at 12:21 PM, FrankG frankgru...@googlemail.com wrote: Hello Kelly, I would not say this can be so easy at the end. Josh says he want to use a static library, but with JNI he need to use a dynamic one or at least a dynamic lib which wraps the static one. And even with this wrapper he can run into linker problems not finding all symbols. It can be a nightmare at the end, but it depends from the complexity of his C++ stuff. Good luck ! Frank On 28 Apr., 19:41, Kelly senor...@gmail.com wrote: Download the android NDK and see how they use libraries. Just reverse engineer their very simple JNI projects and you can build yours no 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.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en- 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: [OpenGL] change coodinate system
Sorry, I didn't really mean it to be that sarcastic -- more educational with a humorous note. But I was a bit rushed, so I kind of skipped over the explanation part, and the humor, well, my humor is of a hit-or-miss variety...but usually I have the good sense to not apply it in online discussions like that. You'll notice that Robert's code does exactly what I said -- an odd number of axis in the scaling are negative. Think about what that does -- it mirrors it across the plane formed by the other two axis. Any odd number of mirrorings will leave you with the handedness of the coordinate system flipped. This can be across ANY planes. But you can decompose any set of linear transformations to be a scaling times every everything else, so you can flip, then move that plane around, to achieve mirroring across any plane whatsoever. There's no other way to do it, this is the complete set. See, I really was giving you a complete solution -- in condensed form! Now, I was slightly careless in my description. If you scale any axis by zero, you reduce the number of dimensions by one. Do it once, and you have Flatland -- and you no longer have a concept of handedness at all. Do it twice, and you get a linear world. Not very interesting. Do it three times, and you've got a point -- but I can't see it! On Apr 29, 8:24 am, Juan Aranda-Alvarez juan.arandaalva...@gmail.com wrote: Thanks, wow, it really was simple. Thanks for the sane answer. Juan On Wed, Apr 28, 2010 at 11:02 PM, Robert Green rbgrn@gmail.com wrote: Juan, their sarcasm is well-founded. It's not only possible but trivial. One easy way to change the coordinate system: // start drawing gl.glMatrixMode(GL10.GL_MODELVIEW); gl.glLoadIdentity(); gl.glScalef (1, 1, -1); GLU.gluLookAt(gl, pos.x, pos.y, pos.z, lookAt.x, lookAt.y, lookAt.z, upVec.x, upVec.y, upVec.z); Enjoy your new left-handed coordinate system. On Apr 28, 7:39 pm, Bob Kerns r...@acm.org wrote: You mean, other than any affine transform that decomposes to include scaling of an odd number of axis by a negative value? Nope, other than that infinite number of ways, nope, no way. On Apr 27, 7:13 pm, Juan Aranda-Alvarez juan.arandaalva...@gmail.com wrote: OpenGL works in 3D space, so if you would like another orientation you could rotate the scene moving the POV (camera) position. But there is no way to move from a right-hand coordinate system to a Left-side one. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2Bunsubs cr...@googlegroups.com For more options, visit this group athttp:// groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2Bunsubs cr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Android ANT compilation
Start by reading the documentation here: http://developer.android.com/intl/de/guide/developing/other-ide.html There's no tool actually within Eclipse to do this, but you could define it as an external tool if you want. On Apr 28, 9:12 pm, veradis tech veradism...@gmail.com wrote: I am using apache ant 1.8 for compilation. I need help on creating build.xml. 1) Is there is any tool in eclipse to do so. 2) Also, i am importing a jar file in project. How can i specify the jar file in build .xml file. Thanks in advance Veradis On Tue, Apr 27, 2010 at 1:29 AM, Xavier Ducrohet x...@android.com wrote: It looks like your using a 3rd party Ant build system instead of the one that comes with the SDK. From the stack trace of the exception it looks like this is http://code.google.com/p/autoandroid/wiki/AndroidAnt You might want to file a bug there, or ask a question to the commiter of that project. Xav On Sat, Apr 24, 2010 at 12:57 AM, veradis veradism...@gmail.com wrote: Hi, I want to compile my Android APP using ANT in windows. I placed build.xml in project root and included necessary jars in project lib folder. I had made proper configurations for ant also, but its not working. Please help me on this. Error C:\Documents and Settings\nav\workspace\YumFlixMobileant Buildfile: C:\Documents and Settings\nav\workspace\YumFlixMobile \build.xml clean: resource-src: BUILD FAILED C:\Documents and Settings\nav\workspace\YumFlixMobile\build.xml:33: java.lang.Nu llPointerException at com.googlecode.androidant.AndroidTools.locateTool(AndroidTools.java:8 1) at com.googlecode.androidant.AndroidTools.startTool(AndroidTools.java:74 ) at com.googlecode.androidant.AndroidTools.startTool(AndroidTools.java:62 ) at com.googlecode.androidant.WindowsAndroidTools.aapt(WindowsAndroidTool s.java:36) at aapt.main(aapt.java:7) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.taskdefs.ExecuteJava.run(ExecuteJava.java:217) at org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:15 2) at org.apache.tools.ant.taskdefs.Java.run(Java.java:771) at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java: 221) at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java: 135) at org.apache.tools.ant.taskdefs.Java.execute(Java.java:108) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:68) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.jav a:398) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.Target.execute(Target.java:390) at org.apache.tools.ant.Target.performTasks(Target.java:411) at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1360) at org.apache.tools.ant.Project.executeTarget(Project.java: 1329) at
[android-developers] Re: Android ANT compilation
I didn't even mention Eclipse. Use the android tool to set up your ant project -- it knows how to set up for the android Ant tasks. They will, of course, need the SDK, but they will NOT need Eclipse. I do not build (nor do I recommend building) my product for distribution with Eclipse. On Apr 25, 9:48 pm, veradis tech veradism...@gmail.com wrote: Thanks Bob Kerns. My aim is to make the code available for all. I will move the source to SVN, and anyone can download/update it and compile it using ANT. I don't want to use eclipse for this. Thanks Veradis On Sat, Apr 24, 2010 at 9:12 PM, Bob Kerns r...@acm.org wrote: Your build.xml doesn't look anything at all like what's generated by the 'android' tool. It looks like you've undergone a major manual effort, instead. Why not just use the android tool to set up your project? http://developer.android.com/intl/de/guide/developing/other-ide.html You can create a blank project, and edit the build.xml and such if you want. As far as I know, the android tool is the only thing that knows what the requirements are for the various android ant tasks. I suspect one requirement is that sdk.dir be set to point to the sdk. On Apr 24, 12:57 am, veradis veradism...@gmail.com wrote: Hi, I want to compile my Android APP using ANT in windows. I placed build.xml in project root and included necessary jars in project lib folder. I had made proper configurations for ant also, but its not working. Please help me on this. Error C:\Documents and Settings\nav\workspace\YumFlixMobileant Buildfile: C:\Documents and Settings\nav\workspace\YumFlixMobile \build.xml clean: resource-src: BUILD FAILED C:\Documents and Settings\nav\workspace\YumFlixMobile\build.xml:33: java.lang.Nu llPointerException at com.googlecode.androidant.AndroidTools.locateTool(AndroidTools.java:8 1) at com.googlecode.androidant.AndroidTools.startTool(AndroidTools.java:74 ) at com.googlecode.androidant.AndroidTools.startTool(AndroidTools.java:62 ) at com.googlecode.androidant.WindowsAndroidTools.aapt(WindowsAndroidTool s.java:36) at aapt.main(aapt.java:7) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.taskdefs.ExecuteJava.run(ExecuteJava.java:217) at org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:15 2) at org.apache.tools.ant.taskdefs.Java.run(Java.java:771) at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java: 221) at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java: 135) at org.apache.tools.ant.taskdefs.Java.execute(Java.java:108) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:68) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.jav a:398) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.Target.execute(Target.java:390)
[android-developers] Re: Android ANT build
Already answered for you, in the thread you asked it earlier. Start by reading the documentation here: http://developer.android.com/intl/de/guide/developing/other-ide.html There's no tool actually within Eclipse to do this, but you could define it as an external tool if you want. Really, I must insist. Read the documentation. Use the tool. I answered this for you on April 24, and you keep ignoring the answer and asking variations on the same question. On Apr 30, 12:07 am, veradis veradism...@gmail.com wrote: Hi all, Is there any tool in eclipse to generate build.xml for my android project. I couldn't get solution to write build.xml. Is it possible to generate APK file and install it on emulator using ANT. Please help. Thanks Veradis -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Device Seeding Program for Top Android Market Developers
Munich - Germany - here it is! I got mine today from FedEx here in Munich Sent from FedEx Netherlands Great. Many many thanks Google! I think i sent Google my response on the 4th of March so 7 weeks ago or so ?! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] System design consult
Hi, in my system i have component dispatcher, which in one side listen to a server and get messages, and from the other side dispatch the meassage to the right component. now about the components in the system let's say component: A which doing some operation(and finish) and component B(which doing another operation - and finish). now those operations components doesnt have to be in the background all the time.. i just passing to them message they do with it something.. and they could be shut off till next time. the dispatcher decided which component i have to use next. now i think i should create my dispatcher/listener as a remote service coz i need it to work all the time, but how would i implement my operation components? and i do want my system to be modular, coz i will need times to times to updates those components. when i mean modular, i need each component to be in diffrent apk, so i can maintence them in the future. any suggestaions? thanks. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Device Seeding Program for Top Android Market Developers
Got mine in Stuttgart today. Thank you Google! On 30 April 2010 10:03, Ginda guentherhaslb...@gmail.com wrote: Munich - Germany - here it is! I got mine today from FedEx here in Munich Sent from FedEx Netherlands Great. Many many thanks Google! I think i sent Google my response on the 4th of March so 7 weeks ago or so ?! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Retrieving the Json data into a list view...
Hi, I want to retrieve the data from the url(http://www.sumasoftware.com/ alerts/GetAlerts.php) and parse the data. The data should be inserted to a list view showing alert text and the corresponding date. I have done this using a text view. But cant figure out how to display using list view... Plz help me out. I'll be grateful if anyone could provide some sample code too... -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Device Seeding Program for Top Android Market Developers
Arrived in Oslo, Norway 2010/4/30 Ilya Shinkarenko shin...@gmail.com Got mine in Stuttgart today. Thank you Google! On 30 April 2010 10:03, Ginda guentherhaslb...@gmail.com wrote: Munich - Germany - here it is! I got mine today from FedEx here in Munich Sent from FedEx Netherlands Great. Many many thanks Google! I think i sent Google my response on the 4th of March so 7 weeks ago or so ?! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: droidfanz.com -- what does it take to get them taken down?
Put a version of your own app there. With a timebomb so that the app stops working after a month and displays you are a pirate. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Device Seeding Program for Top Android Market Developers
Just got mine in York, UK Took a long time but, I guess it's worth it :) Thanks Google! :) On Apr 30, 11:17 am, Vaervarsel vaervar...@gmail.com wrote: Arrived in Oslo, Norway 2010/4/30 Ilya Shinkarenko shin...@gmail.com Got mine in Stuttgart today. Thank you Google! On 30 April 2010 10:03, Ginda guentherhaslb...@gmail.com wrote: Munich - Germany - here it is! I got mine today from FedEx here in Munich Sent from FedEx Netherlands Great. Many many thanks Google! I think i sent Google my response on the 4th of March so 7 weeks ago or so ?! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2Bunsubs cr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2Bunsubs cr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] long HOME KEY press in android 1.6
tstanly wrote: hi all, normally, when we press long key on HOME KEY, there will show the recently used app list, now if I want to let this long press behavior do nothing, is it possiable? You can change that if you write your own firmware and create your own phone. You cannot change that from an ordinary SDK application. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Development Wiki: http://wiki.andmob.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
Re: [android-developers] can change the search/query key behavior?
tstanly wrote: hi all, I want to change the search/query key on phone by application code, so I use the keyevent, the code is: === public boolean onKeyDown(int keyCode, KeyEvent event) { if (keyCode == KeyEvent.KEYCODE_SEARCH) { //do what you want System.out.println(this is key SEARCH!); } return true; } === but when I press the search button, there are nothing to change and no message on the logcat, so, is possiable to change search/query button by application code? For your activity, yes. See here for a project that does this: http://github.com/commonsguy/cw-advandroid/tree/master/Camera/Picture/ If you are looking to change the behavior for the entire device, the best you can do is try to create an activity that responds to ACTION_SEARCH -- the user *might* be prompted to choose between your application and the built-in search system. I have not tried this and do not know how well it will work, if at all. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Development Wiki: http://wiki.andmob.org -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Device Seeding Program for Top Android Market Developers
N1 recived in Poland. Thanks again Google! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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 query information of my APP?
I find some web site can display comments and download number of my application. Does anyone knows how to query market information about my application? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Not calling OnStop when an incoming call is received
Ned Fox wrote: I have an application that is silencing the ringer while it is open, then when it closes it unsilences it. Currently I am doing these two things in OnStart and OnStop. The only problem (and it's a big one) is that when a phone call comes in, it stops my application (calling OnStop), then rings at its normal volume. I would think this is a good thing, at least from the user's standpoint. Is there any way to get around this? Around what? Your activity is going to be stopped, because it is losing the foreground. That will be true if a call comes in, or the user presses HOME, or the user presses BACK, or the user slides down the notification drawer, or... I tried using onCreate and onDestroy, but I want to restore the original volume setting as soon as the program is closed, which onDestroy doesn't seem to do. While this should work, I seriously question whether it is the right thing by users. What you are saying is that you want total control over their ringer volume for an indeterminate period of time. After all, if they press HOME, they may not come back to your activity for *weeks*, yet it might hang out in memory that long, if the user has a device with a lot of RAM and doesn't use a lot of apps. What gives you the right to say their phone shouldn't ring for weeks? -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy _Beginning Android 2_ from Apress Now 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: Device Seeding Program for Top Android Market Developers
On Thu, Apr 29, 2010 at 8:25 PM, Jon jbcam...@gmail.com wrote: to those who received a droid in US... i got a text message regarding a number to call to switch an actual verizon line to the phone. i accidentally deleted that 800# and was wondering if anyone else got it. thanks! I used #228 to activate mine. -- Greg Donald destiney.com | gregdonald.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] Location of launcher icons on Android home screen
akshay wrote: Is there any way to get the location or (x,y) coordinates of the launcher icons on home screen. How do you know the home screen the user is using even *has* the concept of launcher icons? Please remember that there is no single home screen: Google Experience devices have two (1.x, 2.x), HTC Sense devices have at least one, MOTOBLUR devices have at least one, etc. Plus, there are third-party home screens that can be installed and used. In short, no, there is no way to get the location or (x,y) coordinates of the launcher icons on home screen, and any design that assumes anything about the nature of the home screen is doomed. Sorry! -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy _Beginning Android 2_ from Apress Now 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] Read Gmail from my app
ling chiao wrote: Hi: I got exception trying to read email Uri uri = Uri.parse(content://com.android.provider/EmailProvider/); Intent intent = new Intent(Intent.ACTION_VIEW, uri); startActivity(intent); No Activity found to handle Intent { act=android.intent.action.VIEW dat=content://com.android.provider/EmailProvider/ } Is this doable from my app? What is the right URI? That content provider is not part of the SDK and may not exist on some devices. Please bear in mind that there are many possible email clients, including ones from device manufacturers or ones installed by end users. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Warescription: Three Android Books, Plus Updates, One Low Price! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] USB programming SDK?
hakuthedog wrote: Hello android developers, I am new in Android development, and I want to write a server/client program with which phone and pc communicates via USB (or whichever wired) interface. The reason for that is that the amount I want to transfer is pretty big and also I want to keep the cellular line always open. So configuring wireless LAN for this server/client is not an option. I looked at Android SDK, but didn't find anything relevant. Is there somebody who worked on any phone in this context? There is nothing in the Android SDK for working with USB -- sorry! -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Warescription: Three Android Books, Plus Updates, One Low Price! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Problem in SimpleDateFormat MMM return month number
Hi,, when we are using simpledateformat MMM it should return month abbrevation. Example :- If it is a june month it should return jun. But in my program it returns 6 . That is month number. I created my program 3 days before. Till today morning i did not got any error in that. Today morning only i faced this problem . I don't know why?.. Any one faced this problem.. -- Thanks Regards Sasikumar.S -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Retrieving the Json data into a list view...
I have done the following. But still i cant get the result... Can anyone help me determine what the error is...Pl help me out... public class AlertsAdd { public ArrayListJSONObject retrieveJSONArray(String urlString) { String result = queryRESTurl(urlString); ArrayListJSONObject ALERTS = new ArrayListJSONObject(); if (result != null) { try { JSONObject json = new JSONObject(result); Log.i(Info,json.toString()); JSONObject alertsObject = json.getJSONObject(alertid); ALERTS.add(alertsObject); return ALERTS; } catch (JSONException e) { Log.e(JSON, There was an error parsing the JSON, e); } } JSONObject myObject = new JSONObject(); try { myObject.put(Alert Id,myObject.getJSONArray(alertid)); ALERTS.add(myObject); } catch (JSONException e1) { Log.e(JSON, There was an error creating the JSONObject, e1); } return ALERTS; } public class AlertsAdapter extends ArrayAdapterJSONObject { public AlertsAdapter(Activity activity, ListJSONObject alerts) { super(activity, 0, alerts); } @Override public View getView(int position, View convertView, ViewGroup parent) { Activity activity = (Activity) getContext(); LayoutInflater inflater = activity.getLayoutInflater(); View rowView = inflater.inflate(R.layout.list_text, null); JSONObject imageAndText = getItem(position); TextView textView = (TextView) rowView.findViewById(R.id.last_build_stat); try { textView.setText((String)imageAndText.get(alertid)); } catch (JSONException e) { textView.setText(JSON Exception); } return rowView; } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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 in SimpleDateFormat MMM return month number
You would have changed your code. Do have a look. Thanks and Regards, Kumar Bibek On Apr 30, 4:40 pm, Sasikumar.S sasikumar.it1...@gmail.com wrote: Hi,, when we are using simpledateformat MMM it should return month abbrevation. Example :- If it is a june month it should return jun. But in my program it returns 6 . That is month number. I created my program 3 days before. Till today morning i did not got any error in that. Today morning only i faced this problem . I don't know why?.. Any one faced this problem.. -- Thanks Regards Sasikumar.S -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: USB programming SDK?
On Apr 29, 8:00 pm, hakuthedog fjk89...@gmail.com wrote: Hello android developers, I am new in Android development, and I want to write a server/client program with which phone and pc communicates via USB (or whichever wired) interface. You can forward a TCP port to the phone using adb and communicate via that. I.e, on the phone: ./server --port 2345 On the PC: ./adb forward tcp:2345 tcp:2345 ./client --port 2345 localhost That is how proxoid (and I assume pdanet) work. On linux you could set up a script to do the port forwarding automatically when you plug in the phone. Not sure about windows. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Device Seeding Program for Top Android Market Developers
@Vaervarsel: Did you get it delivered to the door by FedEx, or did you get it by Posten (local mail)? On Apr 30, 12:17 pm, Vaervarsel vaervar...@gmail.com wrote: Arrived in Oslo, Norway 2010/4/30 Ilya Shinkarenko shin...@gmail.com Got mine in Stuttgart today. Thank you Google! On 30 April 2010 10:03, Ginda guentherhaslb...@gmail.com wrote: Munich - Germany - here it is! I got mine today from FedEx here in Munich Sent from FedEx Netherlands Great. Many many thanks Google! I think i sent Google my response on the 4th of March so 7 weeks ago or so ?! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Device Seeding Program for Top Android Market Developers
2010/4/30 Trygve trygv...@gmail.com @Vaervarsel: Did you get it delivered to the door by FedEx, or did you get it by Posten (local mail)? http://groups.google.com/group/android-developers?hl=en To the door by FedEx. Call FedEx Oslo and ask them to search for the package sent from Netherlands at 28. april. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Can custom read/write permissions effect user acceptance of an application?
Yes, I have a paid version with bells whistles and a free version with the basic functionality. My demonstration video of the of paid version, so perhaps the free version is too big a step down once they see it. Thanks for the information. On Apr 29, 3:31 pm, TreKing treking...@gmail.com wrote: On Thu, Apr 29, 2010 at 3:28 PM, Brion Emde brione2...@gmail.com wrote: The question is: is it possible that the permission acceptance part of installing my app could be putting customers off? Possible? Sure. Everyone has their own criteria for downloading, trying, and buying apps. I'm sure there are some that look at that and get put off. I'm willing to bet though that the majority of people don't think twice about permissions. I don't know what other's acceptance rate is, but mine is around 50% of customers who download it have active installs. You mentioned two apps, but it sounds like you're referring specifically to one. Is is a free version and full version of the same app? If not, and you only have one paid app, then it could be people are taking advantage of the refund policy to try the app out, if there's no free alternative, and refund it if it's not what they want. Are you getting any comments or emails from people complaining about these permissions? The ones that would care are also likely to be very vocal about their disapproval. --- -- TreKing - Chicago transit tracking app for Android-powered deviceshttp://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Can custom read/write permissions effect user acceptance of an application?
Thanks for the information. 250K installs! Wow! Nice work. On Apr 29, 4:25 pm, Maps.Huge.Info (Maps API Guru) cor...@gmail.com wrote: My main app (Radar Now!) has over 250,000 installs. I've received questions, comments and numerous other contacts from users but never once has anyone even mentioned permissions. I believe that the average user just clicks through those warnings without reading them. -John Coryat -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Alarm Clock Localization query
Hi All , Issue I mentioned here works fine in cupcake android 1.5 . it refers to a OHA issue 3985: http://code.google.com/p/android/issues/detail?id=3985 Please suggest how to fix it . in Alarms.java file , I used DateFormatSymbols(Locale.getDefault()) instead of simple DateFormatSymbols() it doesn't work while in same file Locale.getDefault().toString()) equates to ja_JP that indicates japanese locales are supported in eclair 2.1 . Thanks : Uander On Fri, Apr 30, 2010 at 12:18 PM, Uander uandro...@gmail.com wrote: Hi All , I am bit confused about location stuff in Alarm clock application in Eclair 2.1 . I want to confirm if its a feature or a bug . 1 . Click on Main Menu - Alarm Clock -(Any Set Alarm)-Repeat . This pops up list of all weekdays from Monday to Sunday along with check button so as to enable them for corresponding alarm . 2. Now select Dutch(Netherland language) Click on Main Menu-Settings- Language Keyboard- Select Locale-Dutch (Netherlands) This will install Dutch environment in Android . 3. Click on Main Menu - Alarm Clock(Wekker) -(Any Set Alarm)- Herhalen(Repeat) . This will show list of index for week days . rather than this dutch version of weekdays (Mon to Sun) should list out . Concern source code for fetching weekdays is in Alarms.java file under : ANDROID_TOP/packages/apps/AlarmClock/src/com/android/alarmclock for (int i = 0; i 7; i++) { if ((mDays (1 i)) != 0) { ret.append(dayList[DAY_MAP[i]]); dayCount -= 1; if (dayCount 0) ret.append( context.getText(R.string.day_concat)); } } Other localization strings are in strings.xml file under ANDROID_TOP/packages/apps/AlarmClock/res/values-*/ Does it like to have only indexes 0,1,2,,,instead of translated strings for Mon,Tues,... in Dutch etc languages for Alarm Clock ?? Any Help would be appreciated . Thanks : Uander -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Retrieving the Json data into a list view...
I don't see a problem. You should look at your log file or post it. Have you traced through your code via the debugger? That is a good way to see what is happening. On Apr 30, 6:16 am, Rahul rahulvarma.kalidindi0...@gmail.com wrote: I have done the following. But still i cant get the result... Can anyone help me determine what the error is...Pl help me out... public class AlertsAdd { public ArrayListJSONObject retrieveJSONArray(String urlString) { String result = queryRESTurl(urlString); ArrayListJSONObject ALERTS = new ArrayListJSONObject(); if (result != null) { try { JSONObject json = new JSONObject(result); Log.i(Info,json.toString()); JSONObject alertsObject = json.getJSONObject(alertid); ALERTS.add(alertsObject); return ALERTS; } catch (JSONException e) { Log.e(JSON, There was an error parsing the JSON, e); } } JSONObject myObject = new JSONObject(); try { myObject.put(Alert Id,myObject.getJSONArray(alertid)); ALERTS.add(myObject); } catch (JSONException e1) { Log.e(JSON, There was an error creating the JSONObject, e1); } return ALERTS; } public class AlertsAdapter extends ArrayAdapterJSONObject { public AlertsAdapter(Activity activity, ListJSONObject alerts) { super(activity, 0, alerts); } �...@override public View getView(int position, View convertView, ViewGroup parent) { Activity activity = (Activity) getContext(); LayoutInflater inflater = activity.getLayoutInflater(); View rowView = inflater.inflate(R.layout.list_text, null); JSONObject imageAndText = getItem(position); TextView textView = (TextView) rowView.findViewById(R.id.last_build_stat); try { textView.setText((String)imageAndText.get(alertid)); } catch (JSONException e) { textView.setText(JSON Exception); } return rowView; } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Retrieving the Json data into a list view...
Rahul, This should solve your problem if you get stuck let me know. I just wrote this specifically to address your problem and for my own reference http://www.josecgomez.com/2010/04/30/android-accessing-restfull-web-services-using-json/ Sincerely Jose C Gomez http://www.josecgomez.com On Fri, Apr 30, 2010 at 8:16 AM, Rahul rahulvarma.kalidindi0...@gmail.comwrote: I have done the following. But still i cant get the result... Can anyone help me determine what the error is...Pl help me out... public class AlertsAdd { public ArrayListJSONObject retrieveJSONArray(String urlString) { String result = queryRESTurl(urlString); ArrayListJSONObject ALERTS = new ArrayListJSONObject(); if (result != null) { try { JSONObject json = new JSONObject(result); Log.i(Info,json.toString()); JSONObject alertsObject = json.getJSONObject(alertid); ALERTS.add(alertsObject); return ALERTS; } catch (JSONException e) { Log.e(JSON, There was an error parsing the JSON, e); } } JSONObject myObject = new JSONObject(); try { myObject.put(Alert Id,myObject.getJSONArray(alertid)); ALERTS.add(myObject); } catch (JSONException e1) { Log.e(JSON, There was an error creating the JSONObject, e1); } return ALERTS; } public class AlertsAdapter extends ArrayAdapterJSONObject { public AlertsAdapter(Activity activity, ListJSONObject alerts) { super(activity, 0, alerts); } @Override public View getView(int position, View convertView, ViewGroup parent) { Activity activity = (Activity) getContext(); LayoutInflater inflater = activity.getLayoutInflater(); View rowView = inflater.inflate(R.layout.list_text, null); JSONObject imageAndText = getItem(position); TextView textView = (TextView) rowView.findViewById(R.id.last_build_stat); try { textView.setText((String)imageAndText.get(alertid)); } catch (JSONException e) { textView.setText(JSON Exception); } return rowView; } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Retrieving the Json data into a list view...
Here's how the errors in the log looks like... Tried different ways to fix the problem. but of no use... 04-30 13:09:46.656: INFO/ActivityManager(584): Starting activity: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x1000 cmp=com.WorldToyota/.Alerts } 04-30 13:09:50.417: ERROR/JSON(924): There was an error parsing the JSON 04-30 13:09:50.417: ERROR/JSON(924): org.json.JSONException: JSONArray[0] is not a JSONObject. 04-30 13:09:50.417: ERROR/JSON(924): at org.json.JSONArray.getJSONObject(JSONArray.java:268) 04-30 13:09:50.417: ERROR/JSON(924): at com.WorldToyota.AlertsAdd.retrieveJSONArray(AlertsAdd.java:30) 04-30 13:09:50.417: ERROR/JSON(924): at com.WorldToyota.Alerts.onCreate(Alerts.java:20) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java: 1123) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java: 2364) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java: 2417) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.access$2100(ActivityThread.java:116) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread $H.handleMessage(ActivityThread.java:1794) 04-30 13:09:50.417: ERROR/JSON(924): at android.os.Handler.dispatchMessage(Handler.java:99) 04-30 13:09:50.417: ERROR/JSON(924): at android.os.Looper.loop(Looper.java:123) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.main(ActivityThread.java:4203) 04-30 13:09:50.417: ERROR/JSON(924): at java.lang.reflect.Method.invokeNative(Native Method) 04-30 13:09:50.417: ERROR/JSON(924): at java.lang.reflect.Method.invoke(Method.java:521) 04-30 13:09:50.417: ERROR/JSON(924): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:791) 04-30 13:09:50.417: ERROR/JSON(924): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549) 04-30 13:09:50.417: ERROR/JSON(924): at dalvik.system.NativeStart.main(Native Method) 04-30 13:09:50.688: ERROR/JSON(924): There was an error creating the JSONObject 04-30 13:09:50.688: ERROR/JSON(924): org.json.JSONException: JSONObject[suggestions] not found. 04-30 13:09:50.688: ERROR/JSON(924): at org.json.JSONObject.get(JSONObject.java:287) 04-30 13:09:50.688: ERROR/JSON(924): at org.json.JSONObject.getJSONArray(JSONObject.java:362) 04-30 13:09:50.688: ERROR/JSON(924): at com.WorldToyota.AlertsAdd.retrieveJSONArray(AlertsAdd.java:41) 04-30 13:09:50.688: ERROR/JSON(924): at com.WorldToyota.Alerts.onCreate(Alerts.java:20) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java: 1123) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java: 2364) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java: 2417) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.access$2100(ActivityThread.java:116) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread $H.handleMessage(ActivityThread.java:1794) 04-30 13:09:50.688: ERROR/JSON(924): at android.os.Handler.dispatchMessage(Handler.java:99) 04-30 13:09:50.688: ERROR/JSON(924): at android.os.Looper.loop(Looper.java:123) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.main(ActivityThread.java:4203) 04-30 13:09:50.688: ERROR/JSON(924): at java.lang.reflect.Method.invokeNative(Native Method) 04-30 13:09:50.688: ERROR/JSON(924): at java.lang.reflect.Method.invoke(Method.java:521) 04-30 13:09:50.688: ERROR/JSON(924): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:791) 04-30 13:09:50.688: ERROR/JSON(924): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549) 04-30 13:09:50.688: ERROR/JSON(924): at dalvik.system.NativeStart.main(Native Method) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Feedback Experiment: Freeze/Crash Reporting
Are you guys all seeing this new feedback feature in the Android Developer Console? At first I thought it was an extension of the Android Market commenting system, but no...looks like error reporting! From what I've seen of it so far, this feature looks awesome. I'd had to implement my own manual error tracking, having users email stack traces back to me. Now I don't have to do that. Thanks, Android Team. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Feedback Experiment: Freeze/Crash Reporting
polyclefsoftware wrote: Are you guys all seeing this new feedback feature in the Android Developer Console? At first I thought it was an extension of the Android Market commenting system, but no...looks like error reporting! From what I've seen of it so far, this feature looks awesome. I'd had to implement my own manual error tracking, having users email stack traces back to me. Now I don't have to do that. This has been experimented with for the better part of a month, at least on the device side: http://stackoverflow.com/questions/2567197 I asked a member of the Android developer advocacy team to have somebody make a public statement somewhere about what's going on. AFAICT, no such statement has been made. I agree, it's awesome...so long as it is somewhat controllable. There are apps for which this would be potentially troublesome, if the developer has no control over what gets reported (e.g., due to medical privacy laws). -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Online Training: 10-14 May 2010: http://onlc.com -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] How to custom option menu to arrange four menu items at the one line??
On Fri, Apr 30, 2010 at 12:24 AM, nyuri hanyou...@gmail.com wrote: I just want to custom option menu like that, any suggestion will be grateful. http://groups.google.com/group/android-developers/browse_thread/thread/f0e82fb265c1be80/3adc59d8ad22a2fd - TreKing - Chicago transit tracking app for Android-powered devices http://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] OpenID for Android?
I want to get rid of my app registration and embrace OpenID, but is it possible to do this type of thing with an Android Application? Regards, Eurig -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 custom option menu to arrange three menu items where 2 menu items are displayed at the top and the third below it.
2010/4/29 D.Y android.and...@gmail.com Our UI Team has some professional idea that the menu layout like I told is more friendly to the customer in my application, I would argue that adhering to the standard conventions that the user is accustomed to is more friendly to the customer. But then again, I'm no UI expert with professional ideas. and I can implement the menu as such in Activity but failed in ListActivity with our own menu implementation. If you can make it work in a standard Activity, there's really no reason it can't work in a ListActivity. - TreKing - Chicago transit tracking app for Android-powered devices http://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Feedback Experiment: Freeze/Crash Reporting
It's still very 'beta' like. I can't see the feedback of any app but my own. At least in IE8, when i choose to see the feedback of com.android.browser (or another that's not mine), my browser keeps refreshing until eternity (although haven't waited *that* long :-)). I now can remove my stack-trace logging code. Although, the feedback does not send phone-information back (what phone, model, etc). But it has reports of freezes, which my strack-trace logging code did not have... It looks like it's still quite 'beta'. I can't wait until it's officially rolled out. On Apr 30, 9:47 am, Mark Murphy mmur...@commonsware.com wrote: polyclefsoftware wrote: Are you guys all seeing this new feedback feature in the Android Developer Console? At first I thought it was an extension of the Android Market commenting system, but no...looks like error reporting! From what I've seen of it so far, this feature looks awesome. I'd had to implement my own manual error tracking, having users email stack traces back to me. Now I don't have to do that. This has been experimented with for the better part of a month, at least on the device side: http://stackoverflow.com/questions/2567197 I asked a member of the Android developer advocacy team to have somebody make a public statement somewhere about what's going on. AFAICT, no such statement has been made. I agree, it's awesome...so long as it is somewhat controllable. There are apps for which this would be potentially troublesome, if the developer has no control over what gets reported (e.g., due to medical privacy laws). -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android Online Training: 10-14 May 2010:http://onlc.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 athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Android ANT compilation
What do you debug with? I would love to leave Eclipse behind. Leigh On 4/30/2010 3:37 AM, Bob Kerns wrote: I didn't evenmention Eclipse. Use the android tool to set up your ant project -- it knows how to set up for the android Ant tasks. They will, of course, need the SDK, but they will NOT need Eclipse. I do not build (nor do I recommend building) my product for distribution with Eclipse. On Apr 25, 9:48 pm, veradis techveradism...@gmail.com wrote: Thanks Bob Kerns. My aim is to make the code available for all. I will move the source to SVN, and anyone can download/update it and compile it using ANT. I don't want to use eclipse for this. Thanks Veradis On Sat, Apr 24, 2010 at 9:12 PM, Bob Kernsr...@acm.org wrote: Your build.xml doesn't look anything at all like what's generated by the 'android' tool. It looks like you've undergone a major manual effort, instead. Why not just use the android tool to set up your project? http://developer.android.com/intl/de/guide/developing/other-ide.html You can create a blank project, and edit the build.xml and such if you want. As far as I know, the android tool is the only thing that knows what the requirements are for the various android ant tasks. I suspect one requirement is that sdk.dir be set to point to the sdk. On Apr 24, 12:57 am, veradisveradism...@gmail.com wrote: Hi, I want to compile my Android APP using ANT in windows. I placed build.xml in project root and included necessary jars in project lib folder. I had made proper configurations for ant also, but its not working. Please help me on this. Error C:\Documents and Settings\nav\workspace\YumFlixMobileant Buildfile: C:\Documents and Settings\nav\workspace\YumFlixMobile \build.xml clean: resource-src: BUILD FAILED C:\Documents and Settings\nav\workspace\YumFlixMobile\build.xml:33: java.lang.Nu llPointerException at com.googlecode.androidant.AndroidTools.locateTool(AndroidTools.java:8 1) at com.googlecode.androidant.AndroidTools.startTool(AndroidTools.java:74 ) at com.googlecode.androidant.AndroidTools.startTool(AndroidTools.java:62 ) at com.googlecode.androidant.WindowsAndroidTools.aapt(WindowsAndroidTool s.java:36) at aapt.main(aapt.java:7) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.taskdefs.ExecuteJava.run(ExecuteJava.java:217) at org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:15 2) at org.apache.tools.ant.taskdefs.Java.run(Java.java:771) at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java: 221) at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java: 135) at org.apache.tools.ant.taskdefs.Java.execute(Java.java:108) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:68) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.jav a:398) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at
[android-developers] Re: Retrieving the Json data into a list view...
Really thank you Jose for posting the code. I'll definitely try it out and let you know if there are any further issues. Regarding the logcat, Hey Brion,I have posted wrong log cat in the above posts. Sorry for that... Below you can see the exact log cat errors... 04-30 13:09:46.656: INFO/ActivityManager(584): Starting activity: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x1000 cmp=com.WorldToyota/.Alerts } 04-30 13:09:50.417: ERROR/JSON(924): There was an error parsing the JSON 04-30 13:09:50.417: ERROR/JSON(924): org.json.JSONException: JSONArray[0] is not a JSONObject. 04-30 13:09:50.417: ERROR/JSON(924): at org.json.JSONArray.getJSONObject(JSONArray.java:268) 04-30 13:09:50.417: ERROR/JSON(924): at com.WorldToyota.AlertsAdd.retrieveJSONArray(AlertsAdd.java:30) 04-30 13:09:50.417: ERROR/JSON(924): at com.WorldToyota.Alerts.onCreate(Alerts.java:20) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java: 1123) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java: 2364) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java: 2417) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.access$2100(ActivityThread.java:116) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread $H.handleMessage(ActivityThread.java:1794) 04-30 13:09:50.417: ERROR/JSON(924): at android.os.Handler.dispatchMessage(Handler.java:99) 04-30 13:09:50.417: ERROR/JSON(924): at android.os.Looper.loop(Looper.java:123) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.main(ActivityThread.java:4203) 04-30 13:09:50.417: ERROR/JSON(924): at java.lang.reflect.Method.invokeNative(Native Method) 04-30 13:09:50.417: ERROR/JSON(924): at java.lang.reflect.Method.invoke(Method.java:521) 04-30 13:09:50.417: ERROR/JSON(924): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:791) 04-30 13:09:50.417: ERROR/JSON(924): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549) 04-30 13:09:50.417: ERROR/JSON(924): at dalvik.system.NativeStart.main(Native Method) 04-30 13:09:50.688: ERROR/JSON(924): There was an error creating the JSONObject 04-30 13:09:50.688: ERROR/JSON(924): org.json.JSONException: JSONObject[suggestions] not found. 04-30 13:09:50.688: ERROR/JSON(924): at org.json.JSONObject.get(JSONObject.java:287) 04-30 13:09:50.688: ERROR/JSON(924): at org.json.JSONObject.getJSONArray(JSONObject.java:362) 04-30 13:09:50.688: ERROR/JSON(924): at com.WorldToyota.AlertsAdd.retrieveJSONArray(AlertsAdd.java:41) 04-30 13:09:50.688: ERROR/JSON(924): at com.WorldToyota.Alerts.onCreate(Alerts.java:20) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java: 1123) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java: 2364) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java: 2417) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.access$2100(ActivityThread.java:116) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread $H.handleMessage(ActivityThread.java:1794) 04-30 13:09:50.688: ERROR/JSON(924): at android.os.Handler.dispatchMessage(Handler.java:99) 04-30 13:09:50.688: ERROR/JSON(924): at android.os.Looper.loop(Looper.java:123) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.main(ActivityThread.java:4203) 04-30 13:09:50.688: ERROR/JSON(924): at java.lang.reflect.Method.invokeNative(Native Method) 04-30 13:09:50.688: ERROR/JSON(924): at java.lang.reflect.Method.invoke(Method.java:521) 04-30 13:09:50.688: ERROR/JSON(924): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:791) 04-30 13:09:50.688: ERROR/JSON(924): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549) 04-30 13:09:50.688: ERROR/JSON(924): at dalvik.system.NativeStart.main(Native Method) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Device Seeding Program for Top Android Market Developers
The package is waiting for me at my home too, Frankfurt, Germany. Thanks Google! On Fri, Apr 30, 2010 at 3:00 PM, Vaervarsel vaervar...@gmail.com wrote: 2010/4/30 Trygve trygv...@gmail.com @Vaervarsel: Did you get it delivered to the door by FedEx, or did you get it by Posten (local mail)? http://groups.google.com/group/android-developers?hl=en To the door by FedEx. Call FedEx Oslo and ask them to search for the package sent from Netherlands at 28. april. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Which Intent Flags when setting PendingIntents in multiple app widget scenario?
I have one WidgetProvider but expect the user to have multiple instances of the widget on the home screen. When the user clicks on the widget, an intent is fired to start an activity A passing a String extra (which is specific to that instance of the app widget). Everything works fine unless the activity is already running, in which case the activity is shown in its previous state (and so the intent extra data is ignored). I've tried using various Intent flags (like FLAG_ACTIVITY_NEW_TASK) but they don't seem to help. I suppose I could implement something in onResume() but that seems like a hack. Any tips? Note: I'm testing on a Nexus One. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Which Intent Flags when setting PendingIntents in multiple app widget scenario?
westmeadboy wrote: I have one WidgetProvider but expect the user to have multiple instances of the widget on the home screen. When the user clicks on the widget, an intent is fired to start an activity A passing a String extra (which is specific to that instance of the app widget). Everything works fine unless the activity is already running, in which case the activity is shown in its previous state (and so the intent extra data is ignored). I've tried using various Intent flags (like FLAG_ACTIVITY_NEW_TASK) but they don't seem to help. Try FLAG_ACTIVITY_SINGLE_TOP and then override onNewIntent() in your activity -- you should get the extra that way. http://developer.android.com/reference/android/app/Activity.html#onNewIntent(android.content.Intent) -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Training in US: 14-18 June 2010: http://bignerdranch.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: Device Seeding Program for Top Android Market Developers
Hi all, I just received mine @ Marino (Rome) Italy Many Thanks GOOGLE !!! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Which Intent Flags when setting PendingIntents in multiple app widget scenario?
Excellent, that works. Thanks Mark. On Apr 30, 4:09 pm, Mark Murphy mmur...@commonsware.com wrote: westmeadboy wrote: I have one WidgetProvider but expect the user to have multiple instances of the widget on the home screen. When the user clicks on the widget, an intent is fired to start an activity A passing a String extra (which is specific to that instance of the app widget). Everything works fine unless the activity is already running, in which case the activity is shown in its previous state (and so the intent extra data is ignored). I've tried using various Intent flags (like FLAG_ACTIVITY_NEW_TASK) but they don't seem to help. Try FLAG_ACTIVITY_SINGLE_TOP and then override onNewIntent() in your activity -- you should get the extra that way. http://developer.android.com/reference/android/app/Activity.html#onNe...) -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android Training in US: 14-18 June 2010:http://bignerdranch.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 athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Drillable ListView Example
On Thu, Apr 29, 2010 at 10:28 PM, AndroidGoose fel...@gmail.com wrote: Does anyone know of a good example of a ListView that is drillable to other ListViews where the 2nd list populates based off of the click on the first list? Example? No, I don't. But having two list view activities where one is sent an index or something from the first which tells it which item was selected isn't too complicated. What, exactly, are you having trouble with? - TreKing - Chicago transit tracking app for Android-powered devices http://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] onLocationChanged Not Calling
Hi, I write a class which implements LocationListener. Its just listeneing to the location. I tried the code in Tatoo, but its not working. The code is.. public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); lm = (LocationManager) getSystemService(Context.LOCATION_SERVICE); lm.requestLocationUpdates(LocationManager.GPS_PROVIDER, 0, 0, this); tv = new TextView(this); latLongString = Lat: + currLat + \nLong: + currLong; tv.setText(latLongString); setContentView(tv, new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT)); } public void onLocationChanged(Location location) { // TODO Auto-generated method stub System.out.println( onLocationChanged :: ); if (location != null) { latLongString = Lat : + location.getLatitude() + Long : + location.getLongitude(); Log.i(onLocationChanged(): , latLongString); Toast.makeText(this, latLongString, Toast.LENGTH_SHORT).show(); tv.setText(latLongString); } else { latLongString = Location not found; tv.setText(latLongString); } // tv.invalidate(); } onLocationChanged is not calling at all. GPS is enabled in the device and I put all permissions in manifest also. uses-permission android:name=android.permission.ACCESS_COARSE_LOCATION / uses-permission android:name=android.permission.ACCESS_FINE_LOCATION / Nithin -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Device Seeding Program for Top Android Market Developers
Arrived, Scotland. Thanks google -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Device Seeding Program for Top Android Market Developers
finally, I received it. But the charger is EU standard not UK standard :-( On Apr 30, 3:09 pm, Ottavio Vanini ottavio.van...@gmail.com wrote: Hi all, I just received mine @ Marino (Rome) Italy Many Thanks GOOGLE !!! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: droidfanz.com -- what does it take to get them taken down?
Heh, what could possibly go wrong? On Apr 30, 5:18 am, mot12 martin.hu...@gmail.com wrote: Put a version of your own app there. With a timebomb so that the app stops working after a month and displays you are a pirate. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Drawing of location accuracy in Google Maps app
Hi folks, I'm working on a mapping application which uses the Projection.metersToEquatorPixels method to convert distances in meters to distances in screen pixels. Here is what the documentation says about this method: Converts a distance in meters (along the equator) to one in (horizontal) pixels at the current zoomlevel. In the default Mercator projection, the actual number of pixels for a given distance will get higher as you move away from the equator. Therefore I adjust the resulting distance based on the current latitude, and this seems to work just fine. But I am puzzled when I compare my results to those in the official Google Maps app. The circle of accuracy drawn around the same location and at the same zoom level is significantly smaller in the Google Maps app than in my app. If I revert to using the metersToEquatorPixels without adjustment in my app, I get the same result as in the Google Maps app. Now to my question: have I overlooked something fundamental, or is there a bug in the drawing of location accuracy in the Google Maps app? Any clarification on this matter would be much appreciated. Best, 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] Re: PendingIntent getBroadcast Can't use FLAG_RECEIVER_BOOT_UPGRADE here
The actual intents being provided to the functions are flagged with FLAG_ACTIVITY_NEW_TASK. The intent is started and then passed to the code above. When creating the pending intent with FLAG_CANCEL_CURRENT I receive the error message Can't use FLAG_RECEIVER_BOOT_UPGRADE here. This only occurs after the intent has been started. On Apr 29, 9:58 pm, Dianne Hackborn hack...@android.com wrote: The Intent flags are supposed to be put on the Intent object (where they are defined). The flags when creating a pending intent are different. Also FLAG_RECEIVER_BOOT_UPGRADE is not for applications to use. It is not in the SDK. On Thu, Apr 29, 2010 at 4:03 PM, cnich cnichol...@gmail.com wrote: Info on this error is elusive. It occurs in versions greater than 2.0. I am firing a one time alarm using a Pending Intent. To create the PendingIntent I pass an intent (alarm), context and, receiver class into a function called startAlarm. alarm.setClass(context, receiver); PendingIntent alarmIntent = PendingIntent.getBroadcast(context, API_ID +alarm.getIntExtra(ALARM_ID, -1), alarm, PendingIntent.FLAG_CANCEL_CURRENT); I can call the function without error before the alarm occurs ... but after the PendingIntent has launched I receive Can't use FLAG_RECEIVER_BOOT_UPGRADE here, when calling getBroadcast() This occurs with all FLAGS except NO_CREATE. What exactly is causing this error? Thanks for any info. -Cody -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- 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 athttp://groups.google.com/group/android-developers?hl=en- 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] Can anyone with a Moto Droid run a quick test on my app please?
Hi, My app is working fine on G1, N1, Hero etc but crashes on Droid. If anyone can quickly run a test for me on a Motorola Droid and email me the logcat output it would be very helpful. Please email me if you can spare the time and I will send a link to download the apk. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Stopping or Killing a Thread
Thank you for the fast reply, I will try this out! Cameron On Apr 29, 10:51 pm, Anurag Singh anusingh...@gmail.com wrote: You can use Interrupt to strop a thread. http://java.sun.com/docs/books/tutorial/essential/concurrency/interru... - Anurag Singh -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] One clicklistener for many buttons.
Dear all, I'm implementing an app that has 12 buttons placed in a grid. When one is pressed, the number that the button displays (through button.getText()) has to be retrieved and passed to a common method. I've gone down the route of implementing OnClickListener e.g. public class WordRecall extends Activity implements OnClickListener and then overriding public void onClick(View v) to handle events. However, what I want to avoid is having to repeat the following lines 12 times : Button btn4Button = (Button)findViewById(R.id.fourWords); btn4Button.setOnClickListener(this); Is there a way in Android 1.5 of avoiding this as there is in 1.6? Am I better off using 1.6 for development instead of 1.5? Regards Angus -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: Not calling OnStop when an incoming call is received
Just to emphasize Mark's point: Thousands of people have downloaded my app to *prevent* accidental changes to volume controls, primarily the ringer volume. And many thousands more have downloaded quite a number of other applications that also perform this function. Can you imagine the comment that will be left when one of your users realizes that the reason he missed the call with the new job, the big contract, or that he needs to pick up the kids, is that your app turned off his ringer -- days ago? More business for me, but the goal is to make the phone work BETTER for the user. On Apr 30, 3:44 am, Mark Murphy mmur...@commonsware.com wrote: Ned Fox wrote: I have an application that is silencing the ringer while it is open, then when it closes it unsilences it. Currently I am doing these two things in OnStart and OnStop. The only problem (and it's a big one) is that when a phone call comes in, it stops my application (calling OnStop), then rings at its normal volume. I would think this is a good thing, at least from the user's standpoint. Is there any way to get around this? Around what? Your activity is going to be stopped, because it is losing the foreground. That will be true if a call comes in, or the user presses HOME, or the user presses BACK, or the user slides down the notification drawer, or... I tried using onCreate and onDestroy, but I want to restore the original volume setting as soon as the program is closed, which onDestroy doesn't seem to do. While this should work, I seriously question whether it is the right thing by users. What you are saying is that you want total control over their ringer volume for an indeterminate period of time. After all, if they press HOME, they may not come back to your activity for *weeks*, yet it might hang out in memory that long, if the user has a device with a lot of RAM and doesn't use a lot of apps. What gives you the right to say their phone shouldn't ring for weeks? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 fix the image size(28 x 29 png file) in the grouptIndicator of the ExpandableListview ???
On Fri, Apr 30, 2010 at 1:04 AM, nyuri hanyou...@gmail.com wrote: But The Imgae is stretched. Does anyone Know this? Try the indicatorLeft and indicatorRight properties? - TreKing - Chicago transit tracking app for Android-powered devices http://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Open Browser with full screen
String url = http://xx;; Intent i = new Intent(Intent.ACTION_VIEW); i.setData(Uri.parse(url)); startActivity(i); I want this activity ( browser) to be opened with full screen, is it possible? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] How to fix the image size(28 x 29 png file) in the grouptIndicator of the ExpandableListview ???
On Fri, Apr 30, 2010 at 10:46 AM, TreKing treking...@gmail.com wrote: Try the indicatorLeft and indicatorRight properties? Sorry, posted too soon. I think what you want is to make a PNG.9 image for your drawable. Take a look at the resources provided with the SDK that has the default image used for the expandable list view. You should be able to just copy that and change the main image. - TreKing - Chicago transit tracking app for Android-powered devices http://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] How to get information about my application from market
I find some web site can show information about my application, such as user comment and download count. Does anybody could tell me, how to retrieve those information from Google? 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: uploading image + optional tags via HTTP POST
I found this bit of code. Not put it to use yet, but looks good to go. The data object is the byte[] representing the image. PostMethod method; try { HttpClient client = new HttpClient(); client.getHttpConnectionManager().getParams().setConnectionTimeout( 5000); method = new PostMethod(urlString); Part[] parts = { new FilePart(videoFile, new ByteArrayPartSource( videoFile, data)), new StringPart(videoName, filename) }; method.setRequestEntity(new MultipartRequestEntity(parts, method .getParams())); client.executeMethod(method); response = method.getResponseBodyAsString(); method.releaseConnection(); } catch (Exception ex) { Log.v(TAG, Exception, ex); } finally { method.releaseConnection(); } On Apr 29, 3:25 am, Amit prabhudesai.a...@gmail.com wrote: Hi, I am a newbie to Android development; and I want to upload an image (NOT an image file on the device, but a frame from a camera preview) to a web-server. I searched around and got a snippet of code that can be used to upload a byte array. This is the code: public void uploadImage(final byte[] data) { // spawn off a new thread to do the image uploading new Thread(new Runnable() { @Override public void run() { // TODO Auto-generated method stub Log.d(TAG, onRun:); HttpURLConnection conn = null; try { serverURL = new URL(URL); } catch (MalformedURLException e) { // TODO Auto-generated catch block Log.e(TAG, Malformed URL!); e.printStackTrace(); } try { // open up a connection with the server conn = (HttpURLConnection) serverURL.openConnection(); // set up the conection conn.setDoInput(true); conn.setDoOutput(true); conn.setUseCaches(true); conn.setRequestMethod(POST); conn.setRequestProperty(Connection, Keep-Alive); // now transfer the byte-stream DataOutputStream ostream = new DataOutputStream(conn.getOutputStream()); ostream.write(data); ostream.flush(); ostream.close(); } catch (IOException e) { // TODO Auto-generated catch block Log.e(TAG, No response from server!); e.printStackTrace(); } finally { conn.disconnect(); } // wait for server response try { BufferedReader reader = new BufferedReader( new InputStreamReader(conn.getInputStream()) ); String response; while ((response = reader.readLine()) != null ) { Log.d(server response: , response); } reader.close(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } }).start(); } First, is this code right, or am I missing something here? Next, I want to know how can I simultaneously upload image AND optional image tags to the server? I got to the level that I need
[android-developers] Re: uploading image + optional tags via HTTP POST
If Android does not have all the classes necessary to compile that, try include commons-httpclient in your classpath (http://hc.apache.org/ downloads.cgi) On Apr 30, 11:54 am, shaun shashepp...@gmail.com wrote: I found this bit of code. Not put it to use yet, but looks good to go. The data object is the byte[] representing the image. PostMethod method; try { HttpClient client = new HttpClient(); client.getHttpConnectionManager().getParams().setConnectionTimeout( 5000); method = new PostMethod(urlString); Part[] parts = { new FilePart(videoFile, new ByteArrayPartSource( videoFile, data)), new StringPart(videoName, filename) }; method.setRequestEntity(new MultipartRequestEntity(parts, method .getParams())); client.executeMethod(method); response = method.getResponseBodyAsString(); method.releaseConnection(); } catch (Exception ex) { Log.v(TAG, Exception, ex); } finally { method.releaseConnection(); } On Apr 29, 3:25 am, Amit prabhudesai.a...@gmail.com wrote: Hi, I am a newbie to Android development; and I want to upload an image (NOT an image file on the device, but a frame from a camera preview) to a web-server. I searched around and got a snippet of code that can be used to upload a byte array. This is the code: public void uploadImage(final byte[] data) { // spawn off a new thread to do the image uploading new Thread(new Runnable() { @Override public void run() { // TODO Auto-generated method stub Log.d(TAG, onRun:); HttpURLConnection conn = null; try { serverURL = new URL(URL); } catch (MalformedURLException e) { // TODO Auto-generated catch block Log.e(TAG, Malformed URL!); e.printStackTrace(); } try { // open up a connection with the server conn = (HttpURLConnection) serverURL.openConnection(); // set up the conection conn.setDoInput(true); conn.setDoOutput(true); conn.setUseCaches(true); conn.setRequestMethod(POST); conn.setRequestProperty(Connection, Keep-Alive); // now transfer the byte-stream DataOutputStream ostream = new DataOutputStream(conn.getOutputStream()); ostream.write(data); ostream.flush(); ostream.close(); } catch (IOException e) { // TODO Auto-generated catch block Log.e(TAG, No response from server!); e.printStackTrace(); } finally { conn.disconnect(); } // wait for server response try { BufferedReader reader = new BufferedReader( new InputStreamReader(conn.getInputStream()) ); String response; while ((response = reader.readLine()) != null ) { Log.d(server response: , response); } reader.close(); } catch (IOException e) { // TODO Auto-generated catch block
Re: [android-developers] Re: Device Seeding Program for Top Android Market Developers
Received it in Romania! Thanks Google! On Thu, Apr 29, 2010 at 12:15 PM, Martin Adamek martin.ada...@gmail.comwrote: Not in Germany, but YES in Prague! FedEx has just delivered my shiny new Nexus One 10 minutes ago. http://www.martinadamek.com/2010/04/29/nexus-one-from-android-device-seeding-program/ -M On Apr 15, 10:59 pm, Daniel daniel.himmel...@googlemail.com wrote: Has anybody from Germany already got his or her Android phone from the deviceseedingprogram? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Teo www.teodorfilimon.com Romania, Europe (GMT +2) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: HTC Incredible no default external storage?
My guess is that both External and Internal are mounted and unmounted at the same time. Another question is the WRITE_EXTERNAL_STORAGE permission. Does it also apply to the internal storage, or is there a new separate permission for this. On Apr 30, 4:51 am, Streets Of Boston flyingdutc...@gmail.com wrote: Exactly. And how is the shared internal storage of the Desire (GLOBAL_CONTENT_URI, '/emmc') being accessed when the user wants to copy images from his/her PC onto the phone, and vice versa? What happens to the MediaScanner (if /emmc can be mounted and unmounted...)? I'm curious On Apr 29, 7:27 pm, Filipe Abrantes filipe.abran...@gmail.com wrote: Hi all, Maybe this is an easy question but I couldn't find the answer by myself. Does anyone have an idea whether it is possible to get the users music in internal _and_ external storage through a simple content provider query? Right now we have to do something along the lines of: return resolver.query( MediaStore.Audio.Albums.EXTERNAL_CONTENT_URI, Constants.albumProjection, null, null, null); and I only see these two constants defined for Mediastore.Audio.Album Uri EXTERNAL_CONTENT_URI The content:// style URI for the primary external storage volume. Uri INTERNAL_CONTENT_URI The content:// style URI for the internal storage. There is no thing such as GLOBAL_CONTENT_URI? Shall we ask users where they want to go fetch their music? Shall we do the merging of cursor by ourselves (and later on resorting it)? Both alternatives seem like a step backwards, so Im crossing my fingers this is not the case :). Cheers, Filipe -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Device Seeding Program for Top Android Market Developers
OK, we get it, the phones are rolling into the rest of the world, finally. Congratulations to all of you. I'm sure you're all very excited and I'm sure the rest of us are quite happy for you, but there's really no need for every single person to confirm they've received their phone and update this thread every 10 - 15 minutes. =) - TreKing - Chicago transit tracking app for Android-powered devices http://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: How to get information about my application from market
The sites you're seeing this on (like cyrket.com, androlib.com et al) have broken the market API, which requires some clever work on their part. It's not terribly difficult but you risk getting cut off by Google. Hopefully, Google will open up the market API to our use soon, I think we're seeing some of this happening with their feedback experiment. One thing you can count on with Google, they will make data and API's available eventually if there is any good use a developer can put it to. -John Coryat -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] How to reflect the settings changed in the web to the device
Hello all, In my Gps app there is a Setting page. user can make changes to the setting page from device and from web , like others(register , login etc). so when the user make some changes in the settings page form the web how could it get reflected in the device setting page. i am not finding a flexible solution. if anybody have knowledge please help me. Thanking in advance, Best Regards Subrat Kumar Panda India -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Sending programmatic email with attachment
Background: I have a voice messaging app that needs to send an email with the audio file attached when user records and presses send. I dont want to have the user see a mail client and press Send in it. He's already aware my app is going to send an email and has pressed a send button in the app. The audio file is in the app folder area, not on the sdcard. Problem: Using ACTIONSEND and Intent.EXTRA_STREAM (a) requires the file to be on sdcard and (b) displays a mail client UI. I found a library called javamail_lbmod.jar but it is over 1MB large; I feel thats overkill for what I need. Anyone know of a small library or other solution for my issue. I could live with the sdcard requirement if I could just suppress the mail client UI. thanks Jay ps: I posted this message yesterday and it has completely disappeared from the list. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Change text size and color of listview
Hi all, I am adding listview programmatically. My code is as follow. --- start LinearLayout llIn2 = new LinearLayout(this); llIn2.setOrientation(LinearLayout.VERTICAL); llIn2.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); ListView lv = new ListView(this); lv.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); lv.setAdapter(new ArrayAdapterString(getApplicationContext(), android.R.layout.simple_list_item_1, alPlaces)); llIn2.addView(lv); this.setContentView(llIn2); --end now i want to change the size and color of text. [there is know method like lv.settextsize / lv.settextcolor ] Any kind of help will be grateful Thanks, Pawan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Change text size and color of listview
pawan nimje wrote: Hi all, I am adding listview programmatically. My code is as follow. --- start LinearLayout llIn2 = new LinearLayout(this); llIn2.setOrientation(LinearLayout.VERTICAL); llIn2.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); ListView lv = new ListView(this); lv.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); lv.setAdapter(new ArrayAdapterString(getApplicationContext(), android.R.layout.simple_list_item_1, alPlaces)); llIn2.addView(lv); this.setContentView(llIn2); --end now i want to change the size and color of text. [there is know method like lv.settextsize / lv.settextcolor ] You need to change the rows, not the ListView. Instead of using android.R.layout.simple_list_item_1, create your own row layout that is styled the way you want it to be. Here is an excerpt from one of my books that covers this process: http://commonsware.com/Android/excerpt.pdf -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Training...At Your Office: http://commonsware.com/training -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Device Seeding Program for Top Android Market Developers
In Norway. Still no N1. :-( -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Change text size and color of listview
hey thanks pal it worked On Fri, Apr 30, 2010 at 11:22 PM, Mark Murphy mmur...@commonsware.comwrote: pawan nimje wrote: Hi all, I am adding listview programmatically. My code is as follow. --- start LinearLayout llIn2 = new LinearLayout(this); llIn2.setOrientation(LinearLayout.VERTICAL); llIn2.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); ListView lv = new ListView(this); lv.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT)); lv.setAdapter(new ArrayAdapterString(getApplicationContext(), android.R.layout.simple_list_item_1, alPlaces)); llIn2.addView(lv); this.setContentView(llIn2); --end now i want to change the size and color of text. [there is know method like lv.settextsize / lv.settextcolor ] You need to change the rows, not the ListView. Instead of using android.R.layout.simple_list_item_1, create your own row layout that is styled the way you want it to be. Here is an excerpt from one of my books that covers this process: http://commonsware.com/Android/excerpt.pdf -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Training...At Your Office: http://commonsware.com/training -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Device Seeding Program for Top Android Market Developers
You just need a 2pin to 3pin converter and the charger will work just fine in the UK :D On Apr 30, 4:15 pm, feilfly feil...@gmail.com wrote: finally, I received it. But the charger is EU standard not UK standard :-( On Apr 30, 3:09 pm, Ottavio Vanini ottavio.van...@gmail.com wrote: Hi all, I just received mine @ Marino (Rome) Italy Many Thanks GOOGLE !!! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Retrieving the Json data into a list view...
That first logcat you posted was pretty interesting. It was telling you that what you are getting back from you webservice is a JSONArray, not a JSONObject, as you are assuming it is. They aren't the same thing. You need to get clear on what you are expecting with what they are sending or you are not going to have luck here. On Apr 30, 7:57 am, Rahul rahulvarma.kalidindi0...@gmail.com wrote: Really thank you Jose for posting the code. I'll definitely try it out and let you know if there are any further issues. Regarding the logcat, Hey Brion,I have posted wrong log cat in the above posts. Sorry for that... Below you can see the exact log cat errors... 04-30 13:09:46.656: INFO/ActivityManager(584): Starting activity: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x1000 cmp=com.WorldToyota/.Alerts } 04-30 13:09:50.417: ERROR/JSON(924): There was an error parsing the JSON 04-30 13:09:50.417: ERROR/JSON(924): org.json.JSONException: JSONArray[0] is not a JSONObject. 04-30 13:09:50.417: ERROR/JSON(924): at org.json.JSONArray.getJSONObject(JSONArray.java:268) 04-30 13:09:50.417: ERROR/JSON(924): at com.WorldToyota.AlertsAdd.retrieveJSONArray(AlertsAdd.java:30) 04-30 13:09:50.417: ERROR/JSON(924): at com.WorldToyota.Alerts.onCreate(Alerts.java:20) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java: 1123) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java: 2364) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java: 2417) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.access$2100(ActivityThread.java:116) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread $H.handleMessage(ActivityThread.java:1794) 04-30 13:09:50.417: ERROR/JSON(924): at android.os.Handler.dispatchMessage(Handler.java:99) 04-30 13:09:50.417: ERROR/JSON(924): at android.os.Looper.loop(Looper.java:123) 04-30 13:09:50.417: ERROR/JSON(924): at android.app.ActivityThread.main(ActivityThread.java:4203) 04-30 13:09:50.417: ERROR/JSON(924): at java.lang.reflect.Method.invokeNative(Native Method) 04-30 13:09:50.417: ERROR/JSON(924): at java.lang.reflect.Method.invoke(Method.java:521) 04-30 13:09:50.417: ERROR/JSON(924): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:791) 04-30 13:09:50.417: ERROR/JSON(924): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549) 04-30 13:09:50.417: ERROR/JSON(924): at dalvik.system.NativeStart.main(Native Method) 04-30 13:09:50.688: ERROR/JSON(924): There was an error creating the JSONObject 04-30 13:09:50.688: ERROR/JSON(924): org.json.JSONException: JSONObject[suggestions] not found. 04-30 13:09:50.688: ERROR/JSON(924): at org.json.JSONObject.get(JSONObject.java:287) 04-30 13:09:50.688: ERROR/JSON(924): at org.json.JSONObject.getJSONArray(JSONObject.java:362) 04-30 13:09:50.688: ERROR/JSON(924): at com.WorldToyota.AlertsAdd.retrieveJSONArray(AlertsAdd.java:41) 04-30 13:09:50.688: ERROR/JSON(924): at com.WorldToyota.Alerts.onCreate(Alerts.java:20) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java: 1123) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java: 2364) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java: 2417) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.access$2100(ActivityThread.java:116) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread $H.handleMessage(ActivityThread.java:1794) 04-30 13:09:50.688: ERROR/JSON(924): at android.os.Handler.dispatchMessage(Handler.java:99) 04-30 13:09:50.688: ERROR/JSON(924): at android.os.Looper.loop(Looper.java:123) 04-30 13:09:50.688: ERROR/JSON(924): at android.app.ActivityThread.main(ActivityThread.java:4203) 04-30 13:09:50.688: ERROR/JSON(924): at java.lang.reflect.Method.invokeNative(Native Method) 04-30 13:09:50.688: ERROR/JSON(924): at java.lang.reflect.Method.invoke(Method.java:521) 04-30 13:09:50.688: ERROR/JSON(924): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:791) 04-30 13:09:50.688: ERROR/JSON(924): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:549) 04-30 13:09:50.688: ERROR/JSON(924): at dalvik.system.NativeStart.main(Native Method) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com
[android-developers] Help With Drawable.getPadding ?
I am trying to use getPadding() to get the padding information for a Drawable and then use that padding information to position an ImageView above the Drawable. Here's what I'm trying, but obviously this code is wrong. Rect paddingInfo = theDrawable.getPadding(); imageView.setPadding(paddingInfo.left, paddingInfo.top-20, 0, 0); -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Is Google working on the Bluetooth bug? Any estimated date of completion?
I am not sure if it is the same issue but it sounds related. My app was eventually able to connect to the device I was having trouble with but only after I manually unpaired it. I never deliberately paired it in the first place and I was never asked for a pin during the time it was failing to connect. The device had apparently been automatically paired by Android when it was first detected, as are other nearby laptops and phones and PDAs. After unpairing it, I did not re-pair through the Android utility but ran my app again and attempted to connect to it, at which time I was prompted to enter the pin and to pair. This request to pair did not come directly from my code but resulted from a call to BluetoothSocket.connect( ). At this point it successfully connected and continues to connect. So it seems like the automatic pairing does something that prevents later connection. I wonder if once it is automatically paired without a pin, future attempts to connect recognize that it has been paired but doesn't recognize that no pin was ever requested and so fails for lack of a valid pin. Just a guess. On Apr 29, 9:21 am, frankentux cfarrell1...@googlemail.com wrote: Is this related to: http://stackoverflow.com/questions/2661932/problem-with-bluetooth-on-... http://pastebin.org/191806http://pastebin.org/191824http://pastebin.org/191830 It sounds like the same issue... On Apr 29, 2:09 am, DonFrench dcfre...@gmail.com wrote: (sorry, premature Send of previous message) As I was saying, the two devices have the same name but different MAC addresses. Whether this was related to the problem I am not sure. But simply unpairing the device that would not connect solved the problem. It re-paired the next time my code tried to connect and from then on I could connect to either device without doing any more unpairing. On Apr 28, 5:03 pm, DonFrench dcfre...@gmail.com wrote: Update to this problem: I discovered that the device that could not be connected to had been paired at some time in the past. Both devices have the same name but different MAC On Apr 24, 4:30 pm, DonFrench dcfre...@gmail.com wrote: There is an apparentbugin theBluetoothservice discovery code, as has been mentioned by several people on several forums. The upshot is that the BluetoothSocket.connect( ) method consistently fails to discover a valid SPP service on some devices that are discoverable with non-Android devices while it consistently succeeds to discover the SPP service on seemingly identical devices. Obviously, the two devices are not identical but the fact is that I manufacture two such devices and there is nothing obviously different about them. I can consistently connect to both devices from a Windows Mobile app. I hope that Google will address thisbugin the very near future. I will be willing to test any trialbug-fixes on my devices. Here is the relevant log output from the failed attempt: 04-24 15:23:33.268: INFO/ActivityManager(82): Starting activity: Intent { cmp=com.thegadgetworks/.DeviceListActivity } 04-24 15:23:33.308: DEBUG/DeviceListActivity(8055): doDiscovery() 04-24 15:23:33.318: ERROR/BluetoothEventLoop.cpp(82): event_filter: Received signal org.bluez.Adapter:PropertyChanged from /org/bluez/7766/ hci0 04-24 15:23:33.318: VERBOSE/BluetoothEventRedirector(4213): Received android.bluetooth.adapter.action.DISCOVERY_STARTED 04-24 15:23:36.608: ERROR/BluetoothEventLoop.cpp(82): event_filter: Received signal org.bluez.Adapter:DeviceFound from /org/bluez/7766/ hci0 04-24 15:23:36.638: VERBOSE/BluetoothEventRedirector(4213): Received android.bluetooth.device.action.FOUND 04-24 15:23:40.368: ERROR/BluetoothEventLoop.cpp(82): event_filter: Received signal org.bluez.Adapter:PropertyChanged from /org/bluez/7766/ hci0 04-24 15:23:40.368: ERROR/BluetoothService.cpp(82): stopDiscoveryNative: D-Bus error in StopDiscovery: org.bluez.Error.Failed (Invalid discovery session) 04-24 15:23:40.408: VERBOSE/BluetoothEventRedirector(4213): Received android.bluetooth.adapter.action.DISCOVERY_FINISHED 04-24 15:23:40.418: ERROR/BluetoothService.cpp(82): stopDiscoveryNative: D-Bus error in StopDiscovery: org.bluez.Error.Failed (Invalid discovery session) 04-24 15:23:40.428: ERROR/BluetoothEventLoop.cpp(82): onCreateDeviceResult: D-Bus error: org.bluez.Error.AlreadyExists (Device already exists) 04-24 15:23:40.448: VERBOSE/BluetoothEventRedirector(4213): Received android.bleutooth.device.action.UUID 04-24 15:23:46.448: VERBOSE/BluetoothEventRedirector(4213): Received android.bleutooth.device.action.UUID 04-24 15:24:14.168: ERROR/BluetoothService.cpp(82): stopDiscoveryNative: D-Bus error in StopDiscovery: org.bluez.Error.Failed (Invalid discovery session) And here is the log from when it successfully connected:
[android-developers] Re: Stopping or Killing a Thread
The problem I am continuing to have is that SurfaceCreated gets called instead of onCreate when the app restarts. I was using the join() method which I thought terminates the thread but SurfaceCreated still gets called first. Is there a way to call onCreate from SurfaceCreated? Another solution I tried to just set the thread to a paused state (ie. setRunnable(false) ), and when the app restarts simply setRunnable(true) to run the thread again, but all I get is a black screen when I do this... All the settings, variables and graphics are loaded but nothing happens. On Apr 29, 10:51 pm, Anurag Singh anusingh...@gmail.com wrote: You can use Interrupt to strop a thread. http://java.sun.com/docs/books/tutorial/essential/concurrency/interru... - Anurag Singh On Fri, Apr 30, 2010 at 3:57 AM, Cameron.M.Johnson -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] onLocationChanged - differences between emulator 1.5 and emulator 2.1
Hi, I would really appreciate if an experienced Android developer could provide their insights regarding the following. I am testing requestLocationUpdates/onLocationChanged on emulator using Eclipse emulator control in Debug perspective. Everything works as expected when I test on emulator running AVD 2.1. (Both manual mode and GPX file works as expected) However when I run the same code on emulator running AVD 1.5, onLocationChanged is never called. onStatusChanged is called only once with TEMPORARILY_UNAVAILABLE only once. I found the following link regarding this. http://code.google.com/p/android/issues/detail?id=2545 However there are lot of conflicting comments in this thread. I would really appreciate if someone could clarify the following: 1.) Does the onLocationChanged bug exist only the Android 1.5 emulator or does it also reproduce on real devices running Android 1.5? 2.) How do you write code that needs periodic location updates that works on all Android versions including 1.5? Thanks, --MB. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email 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: onLocationChanged Not Calling
I am facing a similar issue on emulator running 1.5. It does not happen on emulator running 2.1 You can find more details regarding these difference in the following thread (A few comments are conflicting). http://code.google.com/p/android/issues/detail?id=2545 Perhaps this bug exists even on real devices running firmware 1.5. I hope some experience developers can comment on this. What is the firmware version on your Tatoo? On Apr 30, 7:46 am, Nithin nithin.war...@gmail.com wrote: Hi, I write a class which implements LocationListener. Its just listeneing to the location. I tried the code in Tatoo, but its not working. The code is.. public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); lm = (LocationManager) getSystemService(Context.LOCATION_SERVICE); lm.requestLocationUpdates(LocationManager.GPS_PROVIDER, 0, 0, this); tv = new TextView(this); latLongString = Lat: + currLat + \nLong: + currLong; tv.setText(latLongString); setContentView(tv, new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT)); } public void onLocationChanged(Location location) { // TODO Auto-generated method stub System.out.println( onLocationChanged :: ); if (location != null) { latLongString = Lat : + location.getLatitude() + Long : + location.getLongitude(); Log.i(onLocationChanged(): , latLongString); Toast.makeText(this, latLongString, Toast.LENGTH_SHORT).show(); tv.setText(latLongString); } else { latLongString = Location not found; tv.setText(latLongString); } // tv.invalidate(); } onLocationChanged is not calling at all. GPS is enabled in the device and I put all permissions in manifest also. uses-permission android:name=android.permission.ACCESS_COARSE_LOCATION / uses-permission android:name=android.permission.ACCESS_FINE_LOCATION / Nithin -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Activity receiving messages after onDestroy
use removeCallbacksAndMessages(null) Thanks. Where is this documented? There's no mention in the Handler documentation about passing a null Object to this method. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Easiest way to communicate between two activities in two different Applications
Hi together. I have an application A and a application B that both have an activity. Now i want to send Data from activity A1 to activity B1 and back. Whats the easiest way to to dis? I tried to use Remote Service via AIDL, but this doesn't work very well in both directions because I only can pass the primitives data types and not every object i like (ok i would have to implement parceable but this is not really practicle). Then i read this post by Dianne Hackborn: If you are communicating via a Service, you can use Messenger as the interface returned by onBind(), and you can stuff fairly arbitrary data in the Message with message.setData(). Now im wondering how this should work. If in the Service implementaiton i change the return type to Messenger instead of IBinder im not overriding anymore the onbind method of Service. so how to do that?? Then i also tried to use intents. I start my second activity (b1) the following way: Intent intent = new Intent(b.intent.action.Launch); intent.addFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP); startActivity(intent); Every time i tried to send a message i sent an Intent to this activity by the following code: Intent intent = new Intent(b.intent.action.Launch); intent.addFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP); intent.putExtra(test, testmsg); To receive the intent i overwrote the onNewIntent() method in the receving activity (b1). But nevertheless, the code there is never executed. So what can i do to solve this problem? Any help is really appreciated. Thanks! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Easiest way to communicate between two activities in two different Applications
On Fri, Apr 30, 2010 at 3:03 PM, sebastian23 sebastia...@gmail.com wrote: So what can i do to solve this problem? Any help is really appreciated. Thanks! I think is what BroadcastReceivers are for ... - TreKing - Chicago transit tracking app for Android-powered devices http://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Android ANT compilation
I debug with Eclipse. You should be able to use any Java debugger, but there are none that come close to Eclipse, and the SDK provides all this nice Eclipse integration you won't get anywhere else. Why do you want to leave Eclipse behind? I mean, besides the inherent shortcomings of using an IDE to do production builds. On Apr 30, 6:56 am, Leigh McRae leigh.mc...@lonedwarfgames.com wrote: What do you debug with? I would love to leave Eclipse behind. Leigh On 4/30/2010 3:37 AM, Bob Kerns wrote: I didn't evenmention Eclipse. Use the android tool to set up your ant project -- it knows how to set up for the android Ant tasks. They will, of course, need the SDK, but they will NOT need Eclipse. I do not build (nor do I recommend building) my product for distribution with Eclipse. On Apr 25, 9:48 pm, veradis techveradism...@gmail.com wrote: Thanks Bob Kerns. My aim is to make the code available for all. I will move the source to SVN, and anyone can download/update it and compile it using ANT. I don't want to use eclipse for this. Thanks Veradis On Sat, Apr 24, 2010 at 9:12 PM, Bob Kernsr...@acm.org wrote: Your build.xml doesn't look anything at all like what's generated by the 'android' tool. It looks like you've undergone a major manual effort, instead. Why not just use the android tool to set up your project? http://developer.android.com/intl/de/guide/developing/other-ide.html You can create a blank project, and edit the build.xml and such if you want. As far as I know, the android tool is the only thing that knows what the requirements are for the various android ant tasks. I suspect one requirement is that sdk.dir be set to point to the sdk. On Apr 24, 12:57 am, veradisveradism...@gmail.com wrote: Hi, I want to compile my Android APP using ANT in windows. I placed build.xml in project root and included necessary jars in project lib folder. I had made proper configurations for ant also, but its not working. Please help me on this. Error C:\Documents and Settings\nav\workspace\YumFlixMobileant Buildfile: C:\Documents and Settings\nav\workspace\YumFlixMobile \build.xml clean: resource-src: BUILD FAILED C:\Documents and Settings\nav\workspace\YumFlixMobile\build.xml:33: java.lang.Nu llPointerException at com.googlecode.androidant.AndroidTools.locateTool(AndroidTools.java:8 1) at com.googlecode.androidant.AndroidTools.startTool(AndroidTools.java:74 ) at com.googlecode.androidant.AndroidTools.startTool(AndroidTools.java:62 ) at com.googlecode.androidant.WindowsAndroidTools.aapt(WindowsAndroidTool s.java:36) at aapt.main(aapt.java:7) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.taskdefs.ExecuteJava.run(ExecuteJava.java:217) at org.apache.tools.ant.taskdefs.ExecuteJava.execute(ExecuteJava.java:15 2) at org.apache.tools.ant.taskdefs.Java.run(Java.java:771) at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java: 221) at org.apache.tools.ant.taskdefs.Java.executeJava(Java.java: 135) at org.apache.tools.ant.taskdefs.Java.execute(Java.java:108) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:68) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces sorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.jav a:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.jav a:398) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at
[android-developers] trying to write to file and failing
hi im just trying to save some text to a file on android and while it works fine on the emulator dont crash, when i try it on my phone it crashes, what am i doing wrong? heres the code: try{ File root = Environment.getExternalStorageDirectory(); if (root.canWrite()){ File file = new File(root, file.txt); FileWriter writer = new FileWriter(file); BufferedWriter out = new BufferedWriter(writer); out.write(some data); out.close(); showMes(File saved.); }else{ showMes(Could not save file.); } }catch(Exception e){ showMes(e.toString()); } i do know it crashes on File root = Environment.getExternalStorageDirectory(); i just dont know why. showMes() is just a function to make toast. thanks for any help. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] trying to write to file and failing
emada.adame wrote: hi im just trying to save some text to a file on android and while it works fine on the emulator dont crash, when i try it on my phone it crashes, what am i doing wrong? heres the code: try{ File root = Environment.getExternalStorageDirectory(); if (root.canWrite()){ File file = new File(root, file.txt); FileWriter writer = new FileWriter(file); BufferedWriter out = new BufferedWriter(writer); out.write(some data); out.close(); showMes(File saved.); }else{ showMes(Could not save file.); } }catch(Exception e){ showMes(e.toString()); } i do know it crashes on File root = Environment.getExternalStorageDirectory(); That would be very surprising. Make sure you have the WRITE_EXTERNAL_STORAGE permission. Make sure your device has an SD card installed, and that it is not mounted on the development PC as a USB drive. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy Android Consulting: http://commonsware.com/consulting -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] How to debug SIGSEV?
Hi, I am wondering if there is any way to debug a SIGSEV? I have not much experience with those native crashs. This issue only seems to happen with the HTC Incredible and I would at least guess that my Java code cannot be the actual cause, but maybe there is something I can do to avoid triggering it? Where can I find more information? Is it possible to see which of my code lines triggered it? Cheers, Mariano 04-30 15:33:23.329 I/ActivityManager( 77): Starting activity: Intent { dat=newsrob://act?activity=com.newsrob.activities.ShowArticleActivityFILTER_LABEL=all%20articlesFILTER_FEED=10HIDE_READ_ARTICLES=trueSORT_ASC=false flg=0x8 cmp=com.newsrob/.activities.ShowArticleActivity (has extras) } 04-30 15:33:23.404 D/MultiTouchDetector( 1263): MultiTouchDetector v0.36,bAccelerate=true 04-30 15:33:23.514 D/dalvikvm( 1263): GC freed 10573 objects / 916872 bytes in 64ms 04-30 15:33:23.534 E/webcoreglue( 1263): The real object has been deleted 04-30 15:33:23.634 I/DEBUG ( 57): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** 04-30 15:33:23.634 I/DEBUG ( 57): Build fingerprint: 'verizon/inc/inc/inc:2.1-update1/ERE27/161493:user/release-keys' 04-30 15:33:23.634 I/DEBUG ( 57): pid: 1263, tid: 1264 com.newsrob 04-30 15:33:23.634 I/DEBUG ( 57): signal 11 (SIGSEGV), fault addr 0003 04-30 15:33:23.634 I/DEBUG ( 57): r0 0003 r1 r2 0003 r3 4184bf90 04-30 15:33:23.634 I/DEBUG ( 57): r4 0003 r5 0014a9f0 r6 r7 4184bf5c 04-30 15:33:23.634 I/DEBUG ( 57): r8 100ffcf8 r9 4184bf54 10 4184bf40 fp 00169e20 04-30 15:33:23.634 I/DEBUG ( 57): ip ac13e62c sp 100ffcb8 lr ac04a340 pc afb04524 cpsr 2010 04-30 15:33:23.654 I/DEBUG ( 57): #00 pc 4524 /system/lib/libcutils.so 04-30 15:33:23.654 I/DEBUG ( 57): #01 pc 0004a33c /system/lib/libskia.so 04-30 15:33:23.654 I/DEBUG ( 57): #02 pc 0004a9a0 /system/lib/libskia.so 04-30 15:33:23.654 I/DEBUG ( 57): #03 pc 0004aa60 /system/lib/libskia.so 04-30 15:33:23.654 I/DEBUG ( 57): #04 pc 0004408e /system/lib/libandroid_runtime.so 04-30 15:33:23.654 I/DEBUG ( 57): #05 pc eef4 /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #06 pc 00038c18 /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #07 pc 00013bf8 /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #08 pc 00019790 /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #09 pc 00018c60 /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #10 pc 0004f834 /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #11 pc 0004f85c /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #12 pc 000453d6 /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #13 pc 00045462 /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #14 pc 000458ec /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #15 pc 00042cac /system/lib/libdvm.so 04-30 15:33:23.654 I/DEBUG ( 57): #16 pc fdf4 /system/lib/libc.so 04-30 15:33:23.654 I/DEBUG ( 57): #17 pc f8c0 /system/lib/libc.so 04-30 15:33:23.654 I/DEBUG ( 57): 04-30 15:33:23.654 I/DEBUG ( 57): code around pc: 04-30 15:33:23.654 I/DEBUG ( 57): afb04514 e8bd4010 e12fff1e e92d4010 e1a02000 04-30 15:33:23.654 I/DEBUG ( 57): afb04524 e592 e3e03a0f e28fe004 e2401001 04-30 15:33:23.654 I/DEBUG ( 57): afb04534 e243f03f 3af9 e2810001 e8bd4010 04-30 15:33:23.654 I/DEBUG ( 57): 04-30 15:33:23.654 I/DEBUG ( 57): code around lr: 04-30 15:33:23.654 I/DEBUG ( 57): ac04a330 e354 08bd8070 e1a4 ebff7662 04-30 15:33:23.654 I/DEBUG ( 57): ac04a340 e351 0a02 e3a03000 e5853000 04-30 15:33:23.654 I/DEBUG ( 57): ac04a350 e8bd8070 e1a4 ebff85a5 e3a03000 04-30 15:33:23.654 I/DEBUG ( 57): 04-30 15:33:23.654 I/DEBUG ( 57): stack: 04-30 15:33:23.654 I/DEBUG ( 57): 100ffc78 afe3db80 04-30 15:33:23.654 I/DEBUG ( 57): 100ffc7c afe0f190 /system/lib/libc.so 04-30 15:33:23.654 I/DEBUG ( 57): 100ffc80 afe3db80 04-30 15:33:23.654 I/DEBUG ( 57): 100ffc84 afe0f190 /system/lib/libc.so 04-30 15:33:23.654 I/DEBUG ( 57): 100ffc88 04-30 15:33:23.654 I/DEBUG ( 57): 100ffc8c afe0f0a8 /system/lib/libc.so 04-30 15:33:23.654 I/DEBUG ( 57): 100ffc90 afe3db80 04-30 15:33:23.654 I/DEBUG ( 57): 100ffc94 afe0f190 /system/lib/libc.so 04-30 15:33:23.654 I/DEBUG ( 57): 100ffc98 afe3db80 04-30 15:33:23.674 I/DEBUG ( 57): 100ffc9c afe0f190 /system/lib/libc.so 04-30 15:33:23.674 I/DEBUG ( 57): 100ffca0 04-30 15:33:23.674 I/DEBUG ( 57): 100ffca4 afe0f0a8 /system/lib/libc.so 04-30 15:33:23.674 I/DEBUG ( 57): 100ffca8 0001 04-30 15:33:23.674 I/DEBUG ( 57): 100ffcac
[android-developers] Re: Different screen sizes x different layouts
One other interesting thing My FWQVGA avd (android 2.1 + skin WQVGA432) seems to work only for one session. If I close and run it again the resolution changes, icons appear a lot bigger and it displays the UI componentes totally misplaced. I don´t know if I made a huge mess with last posts so I will try to resume my main concern: If I set android:largeScreens=false so android can adapt my layout for large screens, my /layout-normal-long isn´t displayed correctly on my FWQVGA avd (android 2.1 + skin WQVGA432). If I set android:largeScreens=true the layout is displayed perfectly on the same AVD (need to recreate it because, as I said, just work for 1 session) but is not adjusted for large devices. Well, took a long time to figure this out because to me it makes no sense since this FWQVGA avd emulates a normal device with a low density, so no changes to android:largeScreens should have impact to it, right? On 30 abr, 02:03, Gabriel Simões gsim...@gmail.com wrote: Some other conclusions ... I´ve have found another interesting fact (at least on my environment): if on my AndroidManifest.xml I set android:largeScreens=true, my avd running the skin WQVGA432 works just as it is supposed to (there shouldn´t be any connection between them, right?), but large avds display my layout horribly (as expected). Well, if I set it as false, don´t ask me why the layout is not displayed right on WQVGA432. Indeed it looks like it´s height is a lot smaller than it should (I have an widget anchored at the bottom of the screen and it shows up +/- at 2/3). The only thing I did was to change this setting, back and forth, many times and the error appeared repeatedly in all of them. Leaving this way my app should now work on cellphones but not on tablets or other devices (since it´s gonna look back on a FQWVGA phone.). Any thoughts on this one? Gabriel On 29 abr, 23:48, Gabriel Simões gsim...@gmail.com wrote: Thanks for your reply Mark! Took some time to answer because I was testing the new layouts. What I did: /layout (for HVGA displays - medium density and normal size) /layout-small (for QVGA displays - low density and low size) /layout-long (for all the other displays). At first everything was working great! indeed better than I expected. Well, I wrote was because I only tested on emulators of small (QVGA) and medium size (WQVGA, FWQVGA, HVGA, WVGA, FWVGA) displays. When I tried to use /layout-long on emulators of large displays (skins WVGA800 and WVGA854 with density = 160 - medium) all my widgets were displayed just like in the HVGA emulator (I guess as expected since they have the same density) but, as the screen is much bigger, they were completly misplaced. By what I understand, large displays are only for tablets ? Motorola Droid and Google Nexus One are both Normal Size High Density display devices, am I right? Thinking so I decided to change AndroidManifest.xml to use compatibility mode for large screens. Problem 2: the display was not right because it was loading a long layout and rescaling it for compatibility as a normal layout (this, to me, is a bug). Then, to finish the saga I decided to rename the folder /layout-long to /layout-normal-long (so it works only for cellphones). Now, for large displays, the compatibility mode works nice (using my HVGA layout, unfortunately), and for normal and small displays everything seems ok. I just don´t know if it was the best solution. Thanks, Gabriel Simões On 28 abr, 13:16, Mark Murphy mmur...@commonsware.com wrote: Gabriel Simões wrote: If I´m allowed to make another question ... Any ideas on how I could handle the different screen height/width proportions (for example, the WVGA´s proportion is bigger than the HVGA ´s so a layout based on relativeLayout build up considering a HVGA device will leave a lot of empty space in the bottom of a WVGA device). That´s my main problem right now and to fix this I can only think about creating a new layout for large/normal-hpdi devices, one for normal-ldpi (if the one for the large screens doesn´t work here, but I think this should work) and a last one for small-ldpi devices. There are the -long and -notlong resource set suffixes you can use to distinguish between these aspect ratios. -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android Development Wiki:http://wiki.andmob.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 athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google
[android-developers] Re: trying to write to file and failing
Hi Mark thanks for the reply, and yes i WRITE_EXTERNAL_STORAGE set like so: uses-permission android:name=android.permission.WRITE_EXTERNAL_STORAGE/uses- permission and i load the app onto my phone then disconnect the phone from my pc and then try my save function, still crashes. any ideas? On Apr 30, 3:15 pm, Mark Murphy mmur...@commonsware.com wrote: emada.adame wrote: hi im just trying to save some text to a file on android and while it works fine on the emulator dont crash, when i try it on my phone it crashes, what am i doing wrong? heres the code: try{ File root = Environment.getExternalStorageDirectory(); if (root.canWrite()){ File file = new File(root, file.txt); FileWriter writer = new FileWriter(file); BufferedWriter out = new BufferedWriter(writer); out.write(some data); out.close(); showMes(File saved.); }else{ showMes(Could not save file.); } }catch(Exception e){ showMes(e.toString()); } i do know it crashes on File root = Environment.getExternalStorageDirectory(); That would be very surprising. Make sure you have the WRITE_EXTERNAL_STORAGE permission. Make sure your device has an SD card installed, and that it is not mounted on the development PC as a USB drive. -- Mark Murphy (a Commons Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy Android Consulting:http://commonsware.com/consulting -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: trying to write to file and failing
emada.adame wrote: Hi Mark thanks for the reply, and yes i WRITE_EXTERNAL_STORAGE set like so: uses-permission android:name=android.permission.WRITE_EXTERNAL_STORAGE/uses- permission and i load the app onto my phone then disconnect the phone from my pc and then try my save function, still crashes. any ideas? Use adb logcat, DDMS, or the DDMS perspective in Eclipse to get the full stack trace of the exception. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.0 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