**** BEGIN LOGGING AT Sun Mar 29 02:59:57 2009 Mar 29 04:20:19 is there a way to look at logcat log on the phone itself? Mar 29 04:21:03 that log collecter app is annoying Mar 29 04:25:16 it IS logcating the phone Mar 29 04:25:42 how? Mar 29 04:25:53 through an api? Mar 29 04:26:05 or command line Mar 29 04:26:07 wait...you want your app to logcat? Mar 29 04:26:14 to put stuff in the logcat? Mar 29 04:26:22 no, i want to read logcat Mar 29 04:26:32 ??? Mar 29 04:26:34 adb logcat Mar 29 04:27:01 i can't do that on the phone Mar 29 04:27:10 not a rooted one anyway Mar 29 04:27:44 ? Mar 29 04:27:47 you cant? Mar 29 04:28:00 i dont think it should matter... Mar 29 04:28:01 where, in a terminal app? Mar 29 04:28:07 no... Mar 29 04:28:13 via the SDK Mar 29 04:28:15 my usb doesn't work Mar 29 04:28:25 then you have in issue Mar 29 04:28:29 in/an Mar 29 04:28:42 if they can do it in an app, i can do it on the phone Mar 29 04:28:51 was just wondering how "log collecter" did it Mar 29 04:28:56 oh wait... Mar 29 04:29:06 there is an app called log collector? Mar 29 04:29:10 yup Mar 29 04:30:12 hmm... Mar 29 04:30:24 and why arent you using that? Mar 29 04:30:57 it's annoying as hell to use Mar 29 04:31:11 scrolling doesn't work well Mar 29 04:31:31 then make your own? Mar 29 04:31:53 hence my original question :) Mar 29 04:32:00 ah Mar 29 04:32:00 how do they do it Mar 29 04:32:02 lol Mar 29 04:32:06 lemme check the api Mar 29 04:34:00 http://dev.android.com/reference/android/util/LogPrinter.html Mar 29 04:34:36 khert_: there you go? Mar 29 04:35:27 this prints to the log, not give the whole thing to you. sokay, i'll search somemore Mar 29 04:35:35 oh wait Mar 29 04:35:42 ya Mar 29 04:35:43 woops Mar 29 04:35:46 i read it wrong Mar 29 04:37:39 khert_ does Log Collecter just make an email? Mar 29 04:45:22 yeah, but i tried sending and... nothin Mar 29 04:47:08 hmm.. Mar 29 04:48:34 http://dev.android.com/reference/android/util/DebugUtils.html Mar 29 04:48:36 ? Mar 29 04:48:58 lol im just lookin at random api's Mar 29 04:50:11 heh Mar 29 04:50:19 this is just a filter i think Mar 29 04:50:32 hmm.. Mar 29 04:50:42 is it possible to make your own api? Mar 29 04:52:24 AakashPatel: yes and no, and yes and no. If you're making a phone, there's a mechanism to add your own libraries without having to modify the system itself. As an app developer, you can expose activities, services, providers to other apps. Mar 29 04:53:51 jbq: so how did the person who made log collecter make it so the phone reads its own logs? Mar 29 04:53:59 is there a file they're stored in or something? Mar 29 04:54:17 AakashPatel: /dev/log, I think, or something like that. Mar 29 04:54:44 $ cat /dev/log Mar 29 04:54:45 /dev/log: invalid length Mar 29 04:54:47 ??? Mar 29 04:55:56 jbq: wtf does that mean? Mar 29 04:56:35 running "logcat" i get "unable to open log device '/dev/log/main': permission denied" Mar 29 04:57:46 :-/ Mar 29 04:57:49 AakashPatel: I don't know, I didn't write the log driver, or cat, or anything that sits in between. Mar 29 04:57:50 get root :-P Mar 29 04:58:25 jbq: okay Mar 29 05:29:53 what's the polite way for an app to exit if someone tells it to quite? Mar 29 05:29:58 s/quite/quit/ Mar 29 05:32:09 calling finish() on the front activity, stopSelf() on the services? Mar 29 05:39:43 ah, yah Mar 29 05:39:59 I was doing something nasty as a stopgap: getRuntime.kill() or something Mar 29 05:40:08 finish() sounds much better :) Mar 29 05:54:34 is onSizeChanged() all that's called when someone flips from portrait to landscape ? Mar 29 05:55:43 pjz: no, rotation is a configuration change Mar 29 05:56:08 unless you ask otherwise, android tears down your entire activity and starts it up again from onCreate() Mar 29 05:56:11 between each rotatoin Mar 29 05:59:23 so, other than on start up, onSizeChanged() would not be called unless you're in a windowing system? Mar 29 05:59:42 like if you'r resizing the window of the app Mar 29 06:00:28 jsharkey: so what am I not handling that's causing my app to crash when I rotate the phone? Mar 29 06:02:51 ah, okay, just found configChanges Mar 29 06:11:57 oh, hrm. okay, so doing that is likely a bad idea. Mar 29 06:32:13 pjz: what does the crash stacktrace look like? Mar 29 06:32:29 it might be if you forget to call through to super.onPause() ect, if you're overriding those Mar 29 06:45:21 jsharkey: http://pastebin.ca/1375495 Mar 29 06:45:57 O.O Mar 29 06:46:22 thats as deep as the stacktrace goes? Mar 29 06:59:02 jsharkey: uh, it goes a little longer Mar 29 06:59:35 oh, hah, nevermind. silly rethrow had me confused Mar 29 07:11:04 I have a thread class and I want to make sure that there is only ever once instance of it.. I know java has a built in way of doing this but I don't know what it's called Mar 29 07:11:17 anyone help me out with the what-to-google-for? Mar 29 07:11:36 s/once/one Mar 29 07:12:18 no, Java does not have a built-in way to do this Mar 29 07:12:23 you have to use a singleton pattern Mar 29 07:12:55 ok thanks! Mar 29 07:13:37 that'd be implimented in the constructor no? Mar 29 07:14:45 see the java section in http://en.wikipedia.org/wiki/Singleton_pattern Mar 29 07:15:17 tnx Mar 29 09:54:52 so, if I have TextEditPreferences, is there any good way to validate the value the user inputs (aside from icky manual methods)? Mar 29 13:07:33 hello. I'm new to the android platform. Is it possible to log a debug message to the eclipse console with the emulator? Mar 29 13:13:16 Log.* found it. Mar 29 13:13:33 How can I remove an app when I don't want it on my device anymore? Mar 29 14:50:32 romainguy_, you around? Mar 29 14:59:52 if I have my activity defined as landscape:orientation, why does opening or closing the keyboard tear down the activity? Mar 29 14:59:58 shouldn't it just not do anything? Mar 29 15:27:29 hi Mar 29 16:02:37 KNY: default behavior is to restart activities when config changes Mar 29 16:02:48 KNY: orientation=landscape just chooses the default Mar 29 16:02:48 TD, is there a way to change that? Mar 29 16:02:55 yes, but you have to be aware of the consequences Mar 29 16:03:04 it's that way by default for a reason :) Mar 29 16:03:26 you can use the android:configurationChanged attribute (iirc that's the name). BUT why do you want to avoid the rebuild cycle? Mar 29 16:03:29 TD, could you explain them briefly? (or tell me what to search for?) Mar 29 16:03:37 it should be invisible to the user. there is only one case i'm aware of when it's not Mar 29 16:03:42 TD, because nothing's changing :) Mar 29 16:04:04 so why worry then? if it's a no-op, just let the OS do its thing. Mar 29 16:05:05 the point of the rebuild cycle is to avoid subtle bugs to do with reconfiguring guis on the fly Mar 29 16:05:23 TD, but the orientation isn't changing; why would the GUI need to be reconfigured? Mar 29 16:05:37 i found that when i disabled this for a non-trivial activity things "went weird" fast. activities have to be able to rebuild themselves without the user noticing anyway .... Mar 29 16:05:37 oh, i see Mar 29 16:05:51 because there's actually two "configurations" changing Mar 29 16:05:55 one is landscape vs portrait Mar 29 16:06:00 another is whether there's a keyboard active Mar 29 16:06:22 i do not know why they are separate, however, it's fair to assume that in future hardware keyboard vs no-keyboard will be independent from orientation Mar 29 16:06:46 unless it's making the user experience worse for some reason, i'd ignore this for now. there may be some g1-specific optimization in future OS builds that avoids this Mar 29 16:06:51 who knows .... Mar 29 16:07:23 TD, true, I should watch out for devices like the Magic Mar 29 16:07:39 where landscape + text entry could be .. problematic Mar 29 16:08:11 i dunno how it's going to work. i assume they've thought of something smart. the iphone loses so much screenspace it's not even funny, so i guess hardware with keyboards may still be popular even when the magic is released Mar 29 16:08:38 yeah. I should probably fire up the cupcake emulator and test it out Mar 29 16:09:12 why do you force the orientation of the activity btw? Mar 29 16:09:26 i do it in my app, but that's because i am loading external ui i don't control and it doesn't fit on mobile-sized screens unless it's in landscape mode Mar 29 16:10:38 TD, because I'm too lazy to design a portrait layout :) Mar 29 16:10:57 also, I figured that if I kept it consistent, it would avoid these problems Mar 29 16:11:04 hah Mar 29 16:11:05 since I won't, though, I'll add a portrait mode Mar 29 16:11:26 the built-in reflow doesn't produce a nice ui in both orientations for you huh Mar 29 16:12:19 nah, it's not your typical UI Mar 29 16:12:20 heh Mar 29 16:35:23 Hi AakashPatel Mar 29 16:35:43 hey Mar 29 16:36:48 AakashPatel, have you made any apps? Mar 29 16:36:56 Wifi Lock Mar 29 16:37:03 im working on another one right now... Mar 29 16:37:08 APT for android Mar 29 16:37:10 ToggleWifi? Mar 29 16:37:19 Wifi Lock by Aakash Patel Mar 29 16:37:22 gotcha Mar 29 16:37:25 very simple Mar 29 16:37:26 one Mar 29 16:37:37 APT for android? Mar 29 16:37:40 but the other ones didnt have an icon that showed up.. Mar 29 16:37:46 TD: ya... Mar 29 16:38:02 apt as in the one with supercow powers? Mar 29 16:38:20 sure? Mar 29 16:38:42 an alternative to the market Mar 29 16:39:06 (cause the market's full of dumb****) Mar 29 16:39:11 heh Mar 29 16:39:23 lol the reviewers atleast Mar 29 16:39:35 but do we really need apt-style dependency resolution? or would it just be a command-line style way to access the market apps Mar 29 16:39:57 fwiw i am convinced the linux/repo model of software distribution is one major cause why linux never went anywhere on the desktop Mar 29 16:40:12 market is way, way better imho. and it's still early days. Mar 29 16:41:47 TD: idk lol we just had that idea last night Mar 29 16:41:59 heh, well have fun :) Mar 29 17:26:54 so I made some of my objects Parcelable, but... what causes them to be bundled up? Mar 29 17:28:59 oic, onSaveInstanceState() Mar 29 17:43:42 is there a way to use a TextView to have it use the biggest font that will fit in its container? (if that makes sense) Mar 29 17:44:00 like `sm` on linux Mar 29 19:05:02 who's used the gapp's API? Mar 29 19:05:22 well, not me :P Mar 29 19:05:31 are you taking a survey or are you trying to get help with a problem? Mar 29 19:05:46 trying to get help with a problem Mar 29 19:05:59 you'd have better luck stating the problem :) Mar 29 19:06:29 okay....if you make an app that needs those api's...you have to import em..right? Mar 29 19:06:38 ...well i cant figure out how ot! Mar 29 19:06:43 ot/to Mar 29 19:07:16 what APIs are you referring to? do you have a link? Mar 29 19:07:25 http://code.google.com/apis/finance/developers_guide_java.html Mar 29 19:07:30 err... Mar 29 19:07:31 i think Mar 29 19:08:18 AakashPatel, http://code.google.com/apis/finance/developers_guide_java.html#GettingStarted Mar 29 19:08:20 second sentence Mar 29 19:08:40 I assume you download the library and add that jar onto your build path in eclipse Mar 29 19:08:44 ... Mar 29 19:09:04 i just used the -cp option on javac Mar 29 19:10:23 err...i Mar 29 19:10:36 feel like a dumbass x2 Mar 29 19:26:32 wtf Mar 29 19:26:35 KNY: javac -cp gdata/java/lib/gdataclient-1.0.jar CalenderTest.java Mar 29 19:26:46 http://code.google.com/apis/gdata/articles/java_client_lib.html#helloworld Mar 29 19:26:56 and i get a shit load of errors Mar 29 19:42:31 KNY: !!! Mar 29 20:36:16 is there a clean way to filter/validate input users enter into a TextEditPreference? say I want to make sure they put in at least 13 characters and all were alphanumeric. Mar 29 20:37:23 it seems like I can do it manually by events after/as it's saving the value, but I was wondering if there was some better built in way. Mar 29 21:27:19 can anyone explain the purpose of "@override" in the skeleton android app? Mar 29 22:35:27 Some exceptions seem not to show up in the logcat output. How do enable logging of all messages regardless of the Thread of my service they were thrown from? Mar 29 22:36:30 Well, I am not sure it has to do with thread. But usually I see NullpointerExceptions. But not from a Smack Listener Thread Mar 29 22:43:14 keep getting INSTALL_PARSE_FAILED_UNEXPECTED_EXCEPTION when trying to install an apk any ideas? Mar 29 22:51:20 anyone know why my ProgressDialog (I'm using managed dialogs) isn't being killed by removeDialog()? Mar 29 22:51:29 it's not even closing the dialog Mar 29 23:05:02 snlemons, well, you could filter the input with the android:digits (I think that's it anyway) XML attribute Mar 29 23:06:50 KNY: I'll look into that. does it limit to only numbers? Mar 29 23:07:18 snlemons, you specify what characters are valid Mar 29 23:07:40 oh, sweet. any way I can specify min length? Mar 29 23:07:40 unfortunately it doesn't take a regex so you'd have to do "0123456789abcdefghijkl...." Mar 29 23:07:53 I'm not sure Mar 29 23:07:58 oh, that's fine. I'm alright with typing that once. :) Mar 29 23:08:04 heh yeah Mar 29 23:08:18 you'll need the ABCDEF ones too Mar 29 23:08:23 apparently WEP doesn't like if your encryption key is too short. picky jerk. Mar 29 23:09:03 more specifically, wpa_supplicant doesn't like it. Mar 29 23:09:54 haha Mar 29 23:10:00 the bastards Mar 29 23:10:22 KNY: do you know f digits is case-sensitive? Mar 29 23:10:25 *if Mar 29 23:10:31 I'm pretty sure it is Mar 29 23:10:34 check the docs Mar 29 23:11:35 hm... not seeing anything, actually. Mar 29 23:12:03 I'll just assume it is case-sensitive. Mar 29 23:14:03 can any1 help me install a resigned apk? Mar 29 23:14:52 haitiankid4lyf1, don't ask to ask :) just state your question/problem Mar 29 23:16:48 trying to install a resigned apk but get [INSTALL_PARSE_FAILED_UNEXPECTED_EXCEPTION] Mar 29 23:16:59 the resigner works Mar 29 23:17:15 it gives me that error when i change an icon, in te res folder Mar 29 23:17:27 is there something else that i need to change? Mar 29 23:21:13 does it give you the exception? Mar 29 23:21:24 (the stack trace) Mar 29 23:23:14 it only gives me the exception when i replace the file Mar 29 23:23:30 is it the same file name? Mar 29 23:24:13 yes icon.png Mar 29 23:24:26 and its 48x48 like the original Mar 29 23:24:51 mm Mar 29 23:24:53 hmm* Mar 29 23:25:20 im pulling my hair out over here, trying to figure it out Mar 29 23:25:37 :( and its most likely some miniscule step i didnt do Mar 29 23:30:15 KNY: I can't figure out if there's a good way just to disallow certain characters using the digits attribute. do you know? Mar 29 23:31:58 snlemons, no, sorry. I haven't explored it that much. Mar 29 23:34:00 no worries. I'm just going to list the things I think are reasonable. Mar 29 23:37:09 hopefully people don't cry over SSIDs being limited to alphanumeric and '.', '_' ,' ' Mar 29 23:46:27 Anyone here in Australia supplying Android Dev phones? Mar 29 23:48:08 beilabs, as far as I know, Google is the only supplier of the ADP1 Mar 29 23:48:29 KNY: catch' without 'try' Mar 29 23:48:30 ? Mar 29 23:48:34 KNY, Hmm, between shipping etc it's not particularly worthwhile getting it from google USA. Mar 29 23:48:43 AakashPatel, have you ever programmed java before? Mar 29 23:48:49 barely Mar 29 23:48:50 AakashPatel, this is seriously a java 101 question Mar 29 23:48:55 i know... Mar 29 23:49:02 if you tell me ill learn :-( Mar 29 23:49:02 are you even reading the error message? Mar 29 23:49:04 AakashPatel, try #java for those questions Mar 29 23:49:06 it tells you right there Mar 29 23:49:20 ya...idk how to usetry Mar 29 23:49:28 AakashPatel, I'm sure Google does Mar 29 23:49:45 beilabs, I know; from what I hear Google jacks up the price for other countries Mar 29 23:49:46 sucks Mar 29 23:50:09 SEH is more than java. Mar 29 23:53:22 KNY: I got one of those ADP1 in germany for about 170$ shiping. But that includes all taxes and customs handling. and shipping within 6 days. I don't this is "jacking up" Mar 29 23:53:39 I don't think even Mar 29 23:53:58 biafra, just stating what I've heard from people in #android(-dev) Mar 29 23:54:23 apparently people calculated what it should be and there were discrepancies or something. I'm honestly not really sure Mar 29 23:57:02 KNY: well. I am sure there is a fee. But I doubt its more than about 20$ or 30$. In the end it was 440€ for me at the time. and that is not expensive for an unlocked smartphone. Mar 29 23:58:02 I'd prefer that over a 2 year contract with T-mobile any time :-) Mar 30 00:11:49 I have created a broadcast receiver in the Manifest, and I have created one in code. The Manifest created receiver gets notified when a port directed sms comes in, but the other receiver does not. I cannot see how it is any different Mar 30 00:17:35 Does anyone know where the parsing/loading of the Manifest happens in the android source? Mar 30 00:45:52 do I have to grab the whole android source tree to get the source for the included com.android libraries? **** ENDING LOGGING AT Mon Mar 30 02:59:57 2009