**** BEGIN LOGGING AT Sun Jul 26 02:59:56 2009 Jul 26 03:00:21 so I deleted my aidl Java file so that it would regen. but it's not. How do I recreate the aidl JAVA file? Jul 26 03:03:12 do anyone know how to use oauth Jul 26 04:52:34 I have a bunch of nested arrays in a javascript source file, and I'm wondering how best to import that into an android app Jul 26 04:53:31 what I'm wondering is should I reformat it into java source and compile it in, or put it into an sqlite db, or what Jul 26 04:59:42 <_Spyrorocks> Hey guys, Just a quick question, I created an app that uses an online MP3 search engine to stream full tracks to your phone, would this app be allowed in the android market or is it breaking any rules? Jul 26 05:14:54 _Spyrorocks: the android market is not the iphone market Jul 26 05:15:05 the android market is generally very free Jul 26 05:18:09 <_Spyrorocks> loke_: If the users could use my app to possibly infringe copyright, am I liable or would google not care or ??? Jul 26 05:20:12 _Spyrorocks: people could use most apps to possibly infringe anything. That said, it all depends on the country you live in since some countries has awfully draconian leginslations. Jul 26 05:20:57 <_Spyrorocks> loke_: I guess worst comes to worst I pull the app.. Im in Canada. Jul 26 05:22:58 _Spyrorocks: you could always check with a lawyer, but personally I think that'd be overkill. If you don't want trouble you can always pull it if someone tells you to Jul 26 05:23:22 _Spyrorocks: by default, make sure it searches the free archives, and you'll be ok Jul 26 05:23:35 <_Spyrorocks> Right now it just uses an online search engine to find the tracks Jul 26 05:23:43 <_Spyrorocks> its basically just a front end Jul 26 05:24:06 <_Spyrorocks> Id advertise it as like, discover new bands or something Jul 26 05:24:25 <_Spyrorocks> but if the user decides to type in something that may be copyrighted.... Jul 26 05:25:35 Which search engine? Jul 26 05:26:45 <_Spyrorocks> an mp3 search engine Jul 26 05:26:45 Talking about it doesn't do you any good :-) "...are you talking to me on a public IRC? I don't know you. Who is this? Don't come here. I'm hanging up the phone. Prank caller! Prank caller!" Jul 26 05:26:58 <_Spyrorocks> huh? Jul 26 05:28:12 http://tvtropes.org/pmwiki/pmwiki.php/Main/ImplausibleDeniability Jul 26 05:46:18 haha, I don't know if it was a good idea to make keystore user ID 4294957295 Jul 26 06:05:47 Has anyone messed around with the accelerometers and orientation sensors? Jul 26 06:06:36 I'm trying to calculate raw acceleration, regardless of orientation, so I'm trying to rotate the acceleration vector by the orientation, but obviously I'm getting the math wrong :-) Jul 26 06:34:20 Hi, i'm seeing this in the logs a lot: http://dpaste.com/71499/ my app uses the compass. does anyone know what could be causing this? this snippet repeats over and over Jul 26 06:49:10 how do I access the controls on an activty from within a service? Jul 26 06:59:50 mikem`: are you reopening the Sensor device? Jul 26 07:21:14 how do I access a View from within a service? Jul 26 07:21:53 Hi guys Jul 26 07:22:22 I have a question about customizing the default ProgressBar via theme Jul 26 07:22:39 I dont think anyone is here Jul 26 07:22:59 do you know how I can access a View from within a Service? Jul 26 07:23:24 I need to update a TextView from within a Service I have inside my application. Jul 26 07:23:33 Cant find it in the docs ... Jul 26 07:23:35 i guess you may communicate via Intent Jul 26 07:24:08 because there is no gaurantee that your view be always there while your service is running on background Jul 26 07:24:42 the safe way is via Intent.... but still not sure Jul 26 07:31:21 My Main activity implements and start an instance of a Service... my Service needs to update a View on that Activity Jul 26 07:41:23 loke_: I have some code that un-registers a sensor listener in onPause() and re-registers it in onResume() Jul 26 07:42:17 mikem`: that's OK, that's the same as I do Jul 26 07:42:28 I'm not using mag sensors though, only accel and orient Jul 26 07:45:35 i'm only using orient Jul 26 07:45:41 * mikem` needs to do more reading on this Jul 26 07:49:05 can your overload and ovveride a constructor in Java? Jul 26 07:51:33 @Fenderman yes if the overloaded constructor has different parameters. Jul 26 07:52:38 it does... I need to overload the overriden constructor of a service class Jul 26 07:52:54 whats the syntax to do so? Jul 26 07:55:02 e.g. If the constructor is public A( int resId ), then you declare public A( int resId, Foo foo ) but within this overload ctor, invoke super( resId ) Jul 26 07:57:07 Has anybody tried to set an Activity's launchModes ? What's it for ? Jul 26 08:46:32 What is the point of implementing the interface Parcelable ? Jul 26 08:48:18 ashitaka: it allows the framework to "serialize" your class and "inflate" it again on the other end... ie: when passing objects in bundles Jul 26 08:48:46 i guess serialize/deserialize or deflate/inflate Jul 26 08:56:44 @mikem ok thanks. If I'm not doing any IPC with services, I think can forget about them for now. Jul 26 08:58:31 How does one maintain a login session for an app ? Since a login session is a transient thing, where do you store it ? In SharedPreferences ? Basically every Activity should be able to access the user's userid. Or do I have to resort to Singletons ? How do you do it in your app ? Thanks Jul 26 09:14:48 Hi, does anyone know how to prevent G1 from charging the battery when connected using USB? During development my G1 is always attached using USB and I believe that the battery will get sometime get worse when always on 100% Jul 26 10:15:59 ccmas, very easy. remove the batterie ;) Jul 26 10:16:45 when the elektronic is easy, then you must remove the battery. i don't think there is an "enable" line in the charge-electronic Jul 26 10:32:38 SiO2: ok, thanks! Jul 26 10:44:07 Anyone got a quick link on how to run 2 emulators together on the same machine ? Jul 26 10:51:46 Does anyone know how I can overlay two SurfaceViews inside a FrameLayout? I always only see one, settings background to transparent etc. does not help Jul 26 10:54:17 Didn't the android developer blog have an article on that a few months ago? Jul 26 10:54:55 there was something about transaprency not working by default to save CPU cycles. you had to enable something Jul 26 10:56:06 loke_: thanks! I will look for that Jul 26 11:05:15 is still part of the development on the Android framework going on behind closed doors? I mean can we expect a huge patch coming in like with the cupcake branch? Jul 26 11:38:19 hey Jul 26 11:47:38 hi all, is it possible to read ANY string from within the android os, if I know the ID ? Jul 26 11:47:46 *getString Jul 26 12:14:06 aVirulence: seems so, the donut drop is just such a patch Jul 26 12:15:43 <_Auron_> they better fix this openGL bug in donut Jul 26 12:15:52 yeah I just noticed Jul 26 12:15:54 <_Auron_> I don't think I can hack my own fix Jul 26 12:17:16 <_Auron_> tmzt: I believe I found the source of the problem I've had the past several days, btw Jul 26 13:04:02 <_Auron_> can anyone explain to me why an application would call onCreate() the second time it is 'run', when it is not terminated? Jul 26 13:12:49 is it possible to change the package name in Eclipse? Jul 26 13:13:40 refactor should work Jul 26 13:16:00 <_Auron_> shouldn't onResume() be called the second time? Jul 26 13:24:31 <_Auron_> anyone? Jul 26 14:26:00 _Auron_: I think super.onResume calls onCreate Jul 26 14:26:01 not sure Jul 26 14:26:47 <_Auron_> aVirulence: here's my issue: http://pastebin.org/4335 Jul 26 14:29:28 _Auron_: you could look into onRetainNonConfigurationInstance(), so you do not use data or the OpenGL object. Jul 26 14:32:05 hmm, never thought of doing a backtrace. Jul 26 14:32:06 * wmealing thinks Jul 26 14:33:45 <_Auron_> aVirulence: what? Jul 26 14:45:55 _Auron_: well, if onCreate is called, you lose your current information. Jul 26 14:46:12 _Auron_: here's some information on that: http://androidguys.com/?p=2642 Jul 26 14:46:18 worked like a charm for me Jul 26 14:48:07 <_Auron_> except setRenderer() causes my program to break the second time onCreate is called, so the current information (or at least openGL setup) is NOT lost, and therefore it gets stuck in a dumbfounded state Jul 26 14:49:35 <_Auron_> android's GLSurfaceView is clearly not handling something right Jul 26 14:49:50 <_Auron_> if I'm right, there's absolutely nothing I can do to fix this until it's fixed in Android Jul 26 14:50:16 Who wants to bet it's in the qualcomm library breaking this too :) Jul 26 14:53:14 <_Auron_> hunterkll, shutup Jul 26 14:57:20 _Auron_, I don't see you trying to fix the donut build system. :X Jul 26 14:57:21 sigh Jul 26 14:57:30 i have about 300 pages of printed makefiles taped up all over my room Jul 26 14:57:40 with lines drawn between them Jul 26 14:57:46 F#)*%@)%@#%)&@#%)#@%@# google Jul 26 14:57:59 I don't think you can expect the gl state to remain Jul 26 14:58:27 great. Jul 26 14:58:33 i just lost all mass storage entries in /dev Jul 26 14:58:39 and i've got about 30+ zombie processes Jul 26 14:58:44 how did a makefile even do that? Jul 26 14:59:28 donut is about to make me slam my head into the wall. harshly. Jul 26 14:59:36 no. no. i'll just go eat a donut, then i'll feel better... Jul 26 15:00:25 if you dont mind me asking, why are you printing out makefiles ? Jul 26 15:00:42 wmealing, there's a build error that occurs when you try and make the donut source Jul 26 15:00:47 and i'm trying to trace the source of it Jul 26 15:00:54 but it dosn't happen on all systems Jul 26 15:00:55 just some Jul 26 15:01:14 jbq was like "well, you're not on ubuntu 8.04.3 so i can't really say much" Jul 26 15:01:15 _Auron_: yeah, but if you would override the onRetainNonConfigurationInstance() and return an object, you could test in onCreate whether the object is actually there and if so, it shouldn't call setRenderer(). Jul 26 15:01:42 if i can fix this and keep building on my real system and not ubuntu Jul 26 15:01:51 i will be happier then.... a kid in a candy store? Jul 26 15:01:56 an android in a phone dev lab? Jul 26 15:01:58 I don't know. :) Jul 26 15:17:37 <_Auron|G1_> aVirulence: um. a new instance of the prog is made Jul 26 15:17:59 <_Auron|G1_> therefore it's a new activity covering the old one that's still running Jul 26 15:18:59 <_Auron|G1_> the opengl view still has to be rebuilt Jul 26 15:20:05 <_Auron|G1_> it's a lose-lose situation Jul 26 15:20:32 * sammyF thinks loudly "welcome to the wonderfull world of Android OpenGL" Jul 26 15:26:12 i think that was a little more than thinking Jul 26 15:56:28 wmealing: just frustrated by it I'm afraid Jul 26 16:39:29 I deleted my aidl java file is there a way to regenerate it? Jul 26 16:40:20 brombomb: update it again from your source control system? Jul 26 16:45:14 you're funny loke Jul 26 16:45:35 I don't have any backups or a source control system in place Jul 26 16:46:09 brombomb: well, then you're doing it wrong, and you should think of using it. It's not like initialising a subversion repository is a particularly hard thing to do. (hint: it's one command) Jul 26 16:49:01 is there a way to get ecplise to regenerate the file? Jul 26 16:50:53 can't you just use the aidl tool? Jul 26 16:52:17 I didn't know there was an aidl tool Jul 26 16:58:05 Ah ha!@ Jul 26 16:58:28 so after I deleted it I had a bunch of refernce errors (becuase it no longer existsed correctly) Jul 26 16:58:48 After commenting out all lines pointing to it then removing the adil and readding it it was regenerated Jul 26 17:00:58 or even easier, git Jul 26 17:01:43 can anyone tell me why my listview appears empty when it should list "poo" Jul 26 17:01:55 not without code. no Jul 26 17:01:58 http://pastebin.com/m5000e28 Jul 26 17:02:00 there it is Jul 26 17:06:49 that was a trick question, wasnt it Jul 26 17:07:31 no? Jul 26 17:07:49 i actually wondering why it doesnt populate anything to the list at all Jul 26 17:08:46 i'm not sure either, but I do mine differently. Jul 26 17:08:53 http://www.softwarepassion.com/?p=189 <-- i do mine more along those lines. Jul 26 17:09:07 AndyArmstrong, you never told your adapter that the data changed, I believe Jul 26 17:09:31 also, what is it with people and not formatting their code? INDENTATION, PEOPLE! ECLIPSE DOES IT FOR YOU AUTOMATICALLY! Jul 26 17:09:41 yes i did tell it to update KNY Jul 26 17:09:48 setnotifyonchange(true) Jul 26 17:10:03 just under the wordlist declaration Jul 26 17:10:03 wordlist.setNotifyOnChange(true); Jul 26 17:10:22 read the docs Jul 26 17:10:24 http://developer.android.com/reference/android/widget/ArrayAdapter.html#setNotifyOnChange(boolean) Jul 26 17:10:27 * wmealing hides his vim Jul 26 17:10:49 wmealing, I assume you can do that with vim too. But if not, you at least have an excuse Jul 26 17:11:49 but I swear, if I have to read another pastebin with horrible formatting and a completely random indentation scheme again, I'm going to lose my mind Jul 26 17:11:54 Jul 26 17:12:05 next time ill do my little formating finger dance then Jul 26 17:12:11 to keep KNY smiling Jul 26 17:12:17 AndyArmstrong, set eclipse to format on save Jul 26 17:12:20 ok im trying the manual notify of change Jul 26 17:12:21 i really should get around to learning eclipse Jul 26 17:12:25 ooo how do u do that? Jul 26 17:12:30 i just keep getting stuck. Jul 26 17:12:30 window -> preferences Jul 26 17:13:40 ok KNY adding wordlist.notifyDataSetChanged(); under words[0]="poo" still doesnt help Jul 26 17:13:57 AndyArmstrong, try doing it after you set the adapter Jul 26 17:15:52 ok trying now - KNY im being thick i cannot find that option under window -> prefs Jul 26 17:15:54 wmealing you develeop your android apps in VIM ? I love vim for php :) Jul 26 17:16:18 I do. I just feel like i'm struggling with anything else. Jul 26 17:16:25 oh dear Jul 26 17:16:28 whats wrong with eclipse wmealing Jul 26 17:16:39 AndyArmstrong: can't seem to get my unit tests running on it Jul 26 17:16:50 ah Jul 26 17:16:52 Its also a little small when editing kernel code Jul 26 17:16:58 it goes out of memory Jul 26 17:16:59 a little small? Jul 26 17:17:00 AndyArmstrong, window -> preferences -> code style (clean up, formatter) Jul 26 17:17:02 oh i c Jul 26 17:17:16 KNY that still didnt help - notify after set adapter Jul 26 17:17:19 not so good on a netbook screen. (although i understand why) Jul 26 17:17:25 AndyArmstrong, also: window -> preferences -> editor -> save actions (turn on format all lines, organize imports) Jul 26 17:17:40 and I can't get its "make" for C to work in a certain directory, which is important when you are building large projects Jul 26 17:17:47 so you dont rebuild the entire damn tree. Jul 26 17:17:58 again, could be doing it very.. very wrong Jul 26 17:18:03 shouldn't make from the root only rebuild the stuff that's changed? Jul 26 17:18:10 KNY: no make in root. Jul 26 17:18:13 sounds like you have a goofy makefile Jul 26 17:18:19 tell the kernel guys that. Jul 26 17:18:21 haha Jul 26 17:18:23 touche Jul 26 17:18:33 hello hello people Jul 26 17:18:37 When I focus on an EditText, the focus is automatically shifted to it and the keyboard is brought up. How can I return focus to the original invoking point after the user presses 'return'. Jul 26 17:18:51 haha chomchom - tried and failed with that Jul 26 17:19:09 say i'm fixing a bug in something that is userspace and kernel space.. i make a new project, import both sets of source code.. attempt to "make" the local app (with make srpm, or the like) it simply can't do a "make" from a subdirectory. Jul 26 17:19:12 chomchom, where do you want focus to go? Jul 26 17:19:22 wmealing, ah Jul 26 17:19:32 Back to the invoking view. Jul 26 17:19:40 so KNY - your advice made sense but didnt make the app work Jul 26 17:19:40 which really drives me balmy. Jul 26 17:19:43 it still has an empty listview Jul 26 17:19:57 like, unspecifically just so you can see the full screen. Jul 26 17:20:22 Maybe there is like a kill on scren keyboard function Jul 26 17:20:31 there isnt chomchom Jul 26 17:20:40 ive tried and tried with that Jul 26 17:20:50 chomchom I've noticed from "use" that you might be able to change the "return" button to a "done" button Jul 26 17:20:51 the idea is the user has control over that Jul 26 17:20:52 you're kidding, right? Jul 26 17:20:58 you can kill the OSK in like 2 lines Jul 26 17:21:11 hmm pity i or nobody else never told me that Jul 26 17:21:23 but i need help with my listview right now :( Jul 26 17:21:26 ((InputMethodManager) getSystemService(INPUT_METHOD_SERVICE)).hideSoftInputFromWindow(mSearch.getWindowToken(), 0); Jul 26 17:21:35 Oh whatta guy Jul 26 17:21:39 danke Jul 26 17:21:43 AndyArmstrong, two seconds on Google would have found that :) Jul 26 17:21:47 haha Jul 26 17:21:50 i tried and tried Jul 26 17:21:54 wasnt exactly sure of its name tbh Jul 26 17:21:55 made it hard Jul 26 17:22:00 any listviews Jul 26 17:22:01 I must have been wrongly typing! Jul 26 17:22:02 http://www.google.com/search?q=android+hide+virtual+keyboard Jul 26 17:22:03 :) Jul 26 17:22:17 virtual being keyword there Jul 26 17:32:24 KNY so any ideas about this phantom word in my listview Jul 26 17:33:59 I assume you've stepped through and verified that the word actually gets added to the array? Jul 26 17:34:34 oh, nevermind Jul 26 17:34:42 I'm pretty sure that it's because you're creating a new String[] Jul 26 17:35:00 I believe that means that the adapter has a reference to the old one Jul 26 17:38:41 sorry got dced , so any advise for that listview Jul 26 17:38:59 sorry Jul 26 17:40:36 I'm pretty sure that it's because you're creating a new String[] Jul 26 17:40:36 I believe that means that the adapter has a reference to the old one Jul 26 19:17:59 so what should i do Jul 26 19:18:07 cos i dont know the size of the string[] when i make it Jul 26 19:18:16 KNY Jul 26 19:21:24 AndyArmstrong1, I believe you have just discovered why you should use something more powerful than ArrayAdapter Jul 26 19:23:55 ur totally gona say extend baseadapter arent u Jul 26 19:24:41 I know this is about java and not so much android. the variable scope is a little confusing to me. in a class with two methods "a" and "b" method a can call method b just by "b();" shouldn't it needs to use "this.b();" Jul 26 19:25:18 you can use b() or this.b() Jul 26 19:25:20 either way Jul 26 19:25:33 does the compiler assume "this." if b is not already defined elsewhere Jul 26 19:25:37 yes Jul 26 19:25:40 this. is normally used when there's shadowing issues Jul 26 19:25:41 ahhh Jul 26 19:25:44 for instance if I have: Jul 26 19:25:47 class A { Jul 26 19:25:49 int foo; Jul 26 19:25:54 void b(int foo) { Jul 26 19:25:55 } Jul 26 19:25:55 { Jul 26 19:26:06 inside b you would use this.foo to reference the instance member foo Jul 26 19:26:10 or foo to reference the parameter Jul 26 19:26:29 AndyArmstrong1, no, there are plenty of adapters that will do what you want Jul 26 19:35:47 Can anyone recommend a resource detailing interaction with key clicks from the on screen keyboard? Jul 26 20:14:14 Hi! Jul 26 20:54:01 Where can I go to get steps to installing/setting up whatever is needed to develop on the android? Jul 26 20:54:10 http://d.android.com/ Jul 26 20:54:36 all i need is the sdk? Jul 26 20:54:44 yes Jul 26 20:54:57 oh ok I thought I'd need eclipse or something Jul 26 20:56:57 wow, kny, are you working on weekends? Jul 26 20:57:10 aunn, work? I'm in school, mate Jul 26 20:57:19 oh ok Jul 26 20:57:23 haha Jul 26 20:57:52 dunno, heh, some ppl work reaaly hard, thought that u might be one of them :) Jul 26 20:58:52 aunn, haha not yet Jul 26 22:06:50 MUWAHAHA I've got air conditioning in my room! Now I can code during the day Jul 26 22:18:10 is there a way to get the src attribute from an ImageView? Jul 26 22:22:27 what do you mean? Jul 26 22:24:40 You can get the drawable, do you mean get the location on the file system of the drawable? Jul 26 22:33:47 romainguy, well, like setViewImage(ImageView, String) gets passed in whatever is trying to be bound to the view Jul 26 22:34:00 chomchom, no Jul 26 22:34:13 stupid question. How to get application created onto my phone? google answers not cutting it. Jul 26 22:34:39 KNY: I don't understand Jul 26 22:35:30 cold2na: you want to create an application for your android phone? Jul 26 22:35:54 romainguy, I'm using a SimpleAdapter and I'm saying bind this string to this imageview. Is there a way, using just the ImageView reference, to get what string is trying to be bound? Jul 26 22:36:07 chomchom : already did. Not sure how to put on though. Jul 26 22:36:45 also: idea for eclair: have Android support HTTP urls to images in lists (and other imageviews I guess) and have it download it automagically Jul 26 22:36:53 that would rule so hard Jul 26 22:36:56 So you have made an application, ran it successfully in your emulator and now you want to put it on your phone? Jul 26 22:37:20 chomchom: yep. a few. Jul 26 22:37:34 cold2na, just plug in your phone and close your emulator Jul 26 22:37:42 Well you can either use the wire that came with your phone to install the app via a connection with your computer Jul 26 22:38:06 Or you can stick the apks in any location to whih you can browse with your phone Jul 26 22:38:21 KNY: no Jul 26 22:38:37 romainguy, alright Jul 26 22:38:56 and er... Jul 26 22:39:01 ImageView.setImageUri() Jul 26 22:39:06 that might work with HTTP Jul 26 22:39:22 hmm Jul 26 22:40:10 chomchom: so I add the program where? Jul 26 22:41:23 romainguy, nope, failed on bad bitmap uri Jul 26 22:41:45 What do you mean add the program? You only deal with the compiled binary. You either browse to it in a web browser with your phone or you can select to run the source on your phone via your IDE like you did with the emulator but instead select your phone as the target deployment location. Jul 26 22:42:00 cold2na, http://d.android.com/guide/developing/device.html Jul 26 22:42:02 read that Jul 26 22:42:05 The binary in this case is the .apk file Jul 26 22:43:15 romainguy, could you clarify the queuing of AsyncTasks for me? if i tell 100 to execute, why do I get an ... ExecutionRejectedException (?) Jul 26 22:43:31 100? Jul 26 22:43:38 that's not what AsyncTask is meant for Jul 26 22:44:25 would the same thing happen with threads? Jul 26 22:44:46 no Jul 26 22:44:52 but then you'd have 100 threads Jul 26 22:44:57 which would not be a good thing Jul 26 22:45:02 right Jul 26 22:45:05 why would you need so many tasks?? Jul 26 22:45:38 I'm wondering if I should just extend ImageView and override setImageURI to accept HTTP URLs Jul 26 22:45:50 but if each one starts downloading its own image, that might kill the system, haha Jul 26 22:46:10 I'll have to implement a thread queue of some sort, no? Jul 26 22:47:19 (my app is loading remote images all over the place, so it would simplify my code a lot if I could get that to work) Jul 26 22:54:44 Is there any way I can add an application into the context menu for an sms's attach? Jul 26 22:56:37 I have tried registering many mime types without success Jul 26 23:00:17 anyone know the easiest way to get the size of the activity? (excluding the titlebar etc, just the area where the actual contentViews end up) Jul 26 23:01:25 grab one of your vies Jul 26 23:01:26 views Jul 26 23:01:32 then myView.getRootView() Jul 26 23:01:38 and getWidth()/getHeight() Jul 26 23:04:56 chomchom: not working . my 'adb devices' command only shows emulator. Something I'm missing. Jul 26 23:05:35 romainguy: but this data isn't avail in onCreate, is it? Jul 26 23:05:48 nope Jul 26 23:06:11 why do you need that info in onCreate()? Jul 26 23:06:51 to see how much info fits on the screen and then from that start a background service Jul 26 23:07:51 cold2na, Another way is to put the .apk files on your memory card and insert the memory card. Then browse to the android market and got to the apps installer application. They should appear there. Jul 26 23:10:33 cold2na, what platform are you on? Jul 26 23:10:41 chomchom, please stop telling him the idiotic ways of doing this? Jul 26 23:10:47 oops, leave off that last ? Jul 26 23:10:57 :) Jul 26 23:10:59 I'm getting java.lang.RuntimeException: Binary XML file line #25: You must supply a layout_height attribute. but every layout i've checked has android_height! Jul 26 23:11:35 android_height? Jul 26 23:11:42 err Jul 26 23:11:44 android:layout_height Jul 26 23:11:49 every element needs layout_height Jul 26 23:12:58 wait. use the apk installer from marketplace? any reasons why the adb devices could not spot my phone? Jul 26 23:13:28 cold2na, again: what platform are you on? Jul 26 23:13:34 cold2na, ignore everything that chomchom has said Jul 26 23:14:00 cold2na: turn on usb debugging in settings, applications? Jul 26 23:14:11 KNY, right, i've looked through all of my layouts and i can't find an elemnt without layout_height Jul 26 23:14:17 Another way is to write out all the bytes of your binary on a sheet of A4 paper, then hold the paper up to a mirror and take a photo of the piece of paper with your camera. Then chant the names of all the members of the android team while selecting the photo from your gallery. That works sometimes as well. Jul 26 23:14:24 follow steps at http://developer.android.com/guide/developing/device.html Jul 26 23:14:53 usb debuggins. ok. platform Linux. Jul 26 23:15:19 cold2na: try running adb as root, or add udev rules depending on distro Jul 26 23:15:36 yeah, I'm sure you just need to start it as root Jul 26 23:16:44 well, i don't need root. i follow a few instruction for ubuntu and i can just use adb without being root Jul 26 23:16:56 got it.USB debugging was what the hold up was about. Read that article earlier. Missed it and skipped right over the line. Jul 26 23:17:11 nice Jul 26 23:17:49 but u should at least try out chomchom's last suggestion tho :D Jul 26 23:20:23 is there a way of editing every value of a text field in a Cursor (substring to limit length, append "...") before applying it to a SimpleCursorAdaptor without changing the data in the database? Jul 26 23:20:59 martin___: why not use ellipsize="end" on the textviews? Jul 26 23:21:56 ellipsized means faded out? Jul 26 23:22:04 thanks you guys. Any advice for an absolute newbie Jul 26 23:22:23 jsharkey: the same who did the connectbot? Jul 26 23:22:27 cold2na, d.android.com -- learn it, love it Jul 26 23:22:32 martin___: nope, "..." = http://en.wikipedia.org/wiki/Ellipsis Jul 26 23:23:00 you might be confusing it with ellipsize="marquee", which does the faded version Jul 26 23:23:02 cold2na, not to speak for him or anything, but yes Jul 26 23:23:16 cold2na: yea, but kRutOn did most of it ;) Jul 26 23:23:45 i just whipped up the UI for the 1.0 launch Jul 26 23:24:06 awesome. code celebrity in my opinion. Jul 26 23:24:33 lol nah Jul 26 23:25:02 haha Jul 26 23:25:15 there are many better than i on the android team Jul 26 23:25:16 don't forget compareeverywhere Jul 26 23:25:24 :) Jul 26 23:25:52 ooh i have something new i should finish up and release at some point Jul 26 23:28:26 since doing the 'set Debuggable to true' on the Applications.xml . eclipse wont load anything . keeps freezing up on me Jul 26 23:29:32 jsharkey, you're talking about donut, right ;-) Jul 26 23:29:45 cold2na, you don't need debuggable="true" anymore Jul 26 23:30:38 KNY: actually it will work on cupcake Jul 26 23:31:10 i'm having trouble with this... can someone have a look? http://pastebin.com/m713acd3d Jul 26 23:31:33 it should print out "SubClass", but it prints out "BaseClass"... anyone see what i'm doing wrong? Jul 26 23:32:47 jsharkey, what will? debuggable? Jul 26 23:33:17 that "something new" Jul 26 23:33:23 debuggable should have worked all along Jul 26 23:33:53 jsharkey, yeah, but you don't need it (debuggable) Jul 26 23:34:43 wait. it just keeps loading 'building workspace (%)' . hasnt changed. Jul 26 23:35:09 hmm ive attached debuggers in the past, but never had to mark the packages as debuggable, maybe because im always using an eng build Jul 26 23:35:17 cold2na: anything in the eclipse console? Jul 26 23:35:50 jsharkey, you used to have to in 1.0 anyway, maybe not 1.1. I thought it was on the 1.5 changelog though Jul 26 23:36:00 nothing can be saved or edited. yes in eclipse Jul 26 23:39:14 Okay, I made a couple edits. If anyone can see what I'm doing wrong please let me know: http://pastebin.com/ma90c783 Jul 26 23:46:11 mpardo: i don't understand what you're trying to do with the generics Jul 26 23:46:26 It's a Typed class Jul 26 23:52:36 why is main an int? Jul 26 23:54:34 and this mFoo = (T)BaseClass.FOO; doesn't even make sense Jul 26 23:54:43 casting a string to type T ? Jul 26 23:55:25 +1 Jul 26 23:55:29 mpardo: you might try a general purpose channel, like ##java Jul 26 23:55:47 mpardo: i take it you're coming from C/C++ ? Jul 26 23:56:07 brb phone Jul 27 00:00:19 yea i guess now that I look at that it doesnt make sense Jul 27 00:00:51 here's what I'm trying to do: I have a base class with all my main methods/properties and then i have subclasses of this base class that add some properties and methods. Jul 27 00:01:41 one of the properties (FOO) get's overridden in the subclasses. I want other classes to be able to get FOO of the subclass by type Jul 27 00:02:31 so i have Cat extends Animal... Animal.Name = "" and Cat.Name = "Cat" Jul 27 00:02:42 oh Jul 27 00:02:48 use the instanceof keyword Jul 27 00:03:22 Kennel has ArrayList and CatKennel has ArrayList Jul 27 00:03:25 ok i'll try that Jul 27 00:07:22 mpardo I've only used abstraction like that for making collections of objects of any type, such as if you wanted to make your own List class that could store anything Jul 27 00:07:52 abstraction isn't the right word Jul 27 00:09:34 generics Jul 27 00:25:14 okay... see if this makes a little more sense - http://pastebin.com/m5ae981a Jul 27 00:31:42 you're mixing and mashing abstraction and generics where you don't need to Jul 27 00:32:21 Yea i was just thinking I could set it i the constructor of the subclass, but I guess i just wanted it to be a bit cleaner than that Jul 27 00:39:13 Hello, i have a question about changing views, when I rotate my device it flips back to my original view Jul 27 00:39:22 * shakes head * Jul 27 00:40:37 I have a question about your question Jul 27 00:40:37 is there anything I can do to stop that? Jul 27 00:40:39 what? Jul 27 00:41:06 you can override the default view change Jul 27 00:41:22 whaledawg, in my app if I click on - 'show options' and then rotate my device it will go to my main app view Jul 27 00:42:13 when the device is rotated Jul 27 00:42:24 the whole intent is destroyed and restarted Jul 27 00:42:35 oh dear Jul 27 00:42:38 with the proper layout Jul 27 00:43:03 you can override this behavior, but you have to say so in your manifest Jul 27 00:43:15 and then catch rotation events yourself Jul 27 00:44:14 oh, in the mail app for example, if i view a message and then rotate, the message stays there Jul 27 00:44:26 i guess they catch rotations Jul 27 00:44:28 not quite Jul 27 00:44:35 it's destroyed and then restored Jul 27 00:44:48 when your app is destroyed you save your state Jul 27 00:44:53 that's what you should be doing Jul 27 00:45:11 thanks whaledawg! Jul 27 00:45:15 np Jul 27 00:45:22 mpardo: this is a cleaned, compilalbe version of what you're thinking of: http://pastebin.com/m51c0b994 Jul 27 00:45:52 whaledawg, super.onCreate(savedInstanceState); i use this already with onCreate Jul 27 00:46:47 ah... so setting the animal name in the constructor will do it? Jul 27 00:46:51 but what information do you put into savedInstanceState and how do you use it to resotre your app? Jul 27 00:48:27 mpardo: the problem really is the Kennel constructor Jul 27 00:48:48 try having an abstract getName() method in animal, and overriding it in cat Jul 27 00:49:03 so you can call it in the Kennel constructor and act the way you want it to Jul 27 00:49:12 Queue29, also Cat doesn't need the myName field, it gets it from Animal Jul 27 00:49:15 even with just having an Animal type Jul 27 00:49:20 true Jul 27 00:50:32 name is private, but also, CatKennel has ArrayList getCats() which extends ArrayList getAnimals() in Kennel Jul 27 00:50:41 that's why I use generics in Kennel Jul 27 00:50:58 (these are all example classes, not real classes btw) Jul 27 00:53:30 would you not just make Kennel generic and remove CatKennel? public class Kennel { private ArrayList occupants; public Kennel(T) { occupants = new ArrayList; } Jul 27 00:53:50 and then have methods taking objects of class T to add etc Jul 27 00:54:29 then you can put whatever you want in a kennel (although it's pointless, as ArrayList is already generic) Jul 27 00:57:39 yea... i guess there are a lot of options to make it work. I was just hoping for some generic magic to make it a little cleaner Jul 27 00:58:45 I think you were making it more complicated for yourself :) Jul 27 01:00:22 k thx guys... later Jul 27 01:03:58 BTW, for anyone who's interested there's an androiddev reddit now: http://www.reddit.com/r/androiddev/ Jul 27 01:07:22 i waste too much time on reddit Jul 27 01:07:28 used to have it blocked in my hosts file Jul 27 01:11:51 What is the after a class name? Jul 27 01:12:10 Jackmordal, http://en.wikipedia.org/wiki/Generics_in_Java Jul 27 01:12:28 exactly what I was hoping for thank you Jul 27 01:14:52 anyone in here get mulitpart http posts working? Jul 27 01:16:44 I think I am missing something. Jul 27 01:17:10 what is not working? Jul 27 01:18:45 if someone is so kind to explain, how do I properly go through views, if I go to some other view and hit "Back" the app closes down and I see the main android screen. Jul 27 01:19:21 what do you mean by go through views, through things with a different UI? Jul 27 01:20:14 well in my app, i click on a button in my main menu and it goes off to show me a webview , and then in that webview if i hit Back on my phone it goes all the way back to the home sreen. Jul 27 01:20:37 the back button shows you the last activity that was opened, if you are changing your UI by setContentView() and different layout xml file, then there is better ways Jul 27 01:21:04 yes i use setContentView() : ( Jul 27 01:21:11 don't then :p Jul 27 01:21:16 just start a new activity Jul 27 01:21:20 not to worry, a lot of the code can be reused... but you'll need a lot more :P Jul 27 01:21:38 you would be better off creating a new Activity for each of your layout files. You can start them with an intent and the startActivityForResult() method Jul 27 01:21:55 which lets you know when the thing you're calling has finished and what the outcome was Jul 27 01:22:37 oh nice! i am going to look that up! Jul 27 01:22:45 thanks for your help, you guys rock! Jul 27 01:22:48 this way when you press back the activity that you clicked to bring up the new onewill appear Jul 27 01:23:21 vladikoff, exercise 2 here: http://d.android.com/guide/tutorials/notepad/index.html demonstrates Jul 27 01:23:24 it will go to the old activity? Jul 27 01:23:50 you can imagine it like a stack, when you click back the thing on the top gets popped off and you see what was below Jul 27 01:24:19 bewarned with that tutorial though, there's two slight errors Jul 27 01:24:30 ok Jul 27 01:24:40 thanks again, i am hyped to get it all working :) Jul 27 01:26:06 romainguy, http://groups.google.com/group/android-discuss/browse_thread/thread/81704ad210bab3ea <-- posted this yesterday but had to wait for moderation, is it the right place? I was advised to post on the mailing list but I didn't know which one Jul 27 01:45:59 <_avatar> scre -r Jul 27 01:46:08 <_avatar> erm. wrong console. Jul 27 01:51:18 martin____ and romainguy, thanks got it to work, now i am the master of activities Jul 27 01:51:48 good Jul 27 01:51:58 now, you must chop down every tree in the forest with a herring Jul 27 01:51:59 :D Jul 27 01:52:11 D: Jul 27 01:52:25 hehe Jul 27 02:14:34 Can someone help me a little bit? Jul 27 02:14:57 Minty, /topic Jul 27 02:15:19 Sorry Im confused :(? Jul 27 02:15:35 type "/topic" and hit enter. Read what comes up. Jul 27 02:15:59 "TOPIC Not enough parameters" Jul 27 02:16:11 :o Jul 27 02:16:13 /topic #android-dev Jul 27 02:16:14 sorry Jul 27 02:16:18 Thanks xD Jul 27 02:16:40 Can someone help me a little bit? Jul 27 02:16:47 Minty, /topic Jul 27 02:16:51 I did do that! Jul 27 02:16:51 >.< Jul 27 02:16:56 you didn't read it, then Jul 27 02:17:03 Yes i did.. Jul 27 02:17:11 yeah? did you miss this bit? "Got a question? Just ask!" Jul 27 02:17:19 I saw that Jul 27 02:17:36 his question must be, 'can someone help?' Jul 27 02:17:41 Yes :P Jul 27 02:17:44 oh, well then the answer is "no" Jul 27 02:17:45 in that case, yea Jul 27 02:17:46 now get out Jul 27 02:17:49 sorry, bud :) Jul 27 02:18:16 I had some questions about some syntax... Jul 27 02:18:29 well don't leave us hanging Jul 27 02:18:45 sec.. Jul 27 02:19:11 Well can I pm u, I really don't want to spam the chat Jul 27 02:19:13 Minty, what we're getting at here is this: don't ask to ask. Just ask. Jul 27 02:19:19 no, ask the channel. That's why it's here. Jul 27 02:19:24 ok ok Jul 27 02:19:34 Well before I start asking quesitons about syntax.. Jul 27 02:19:39 * KNY dies Jul 27 02:19:47 I was wondering what would be the best direction for me to take Jul 27 02:19:52 to get a better grasp on android Jul 27 02:20:05 direction? head to http://d.android.com/ Jul 27 02:20:19 So far I have done the Views on code.google Jul 27 02:20:34 if you like hard books: Jul 27 02:20:35 http://commonsware.com/Android/ Jul 27 02:20:35 Also im in the process of making a sudoku game from the book "Hello, Android" Jul 27 02:21:33 Ive checked out 2 android books from the library.. Jul 27 02:21:45 But they dont really explain everything Jul 27 02:22:07 Minty, you can't learn everything from a book. Come up with an app idea and start working. Jul 27 02:22:25 Well thats the thing :P Jul 27 02:22:31 I have many ideas but not sure how to get started Jul 27 02:22:45 the tutorials are a great place Jul 27 02:22:50 Which is why im trying to get a better grasp on android Jul 27 02:22:58 Minty, I started with tutorials and googling Jul 27 02:23:01 Minty, `android create project` is a good place to start Jul 27 02:23:24 Minty, also videos from Google I/O helped me Jul 27 02:23:25 Whats the best place for tutorials? Jul 27 02:23:34 http://d.android.com/ Jul 27 02:25:14 Minty, this page http://d.android.com/guide/basics/what-is-android.html and that navigation tree helped me a lot Jul 27 02:25:31 that nav on the left Jul 27 02:25:35 Cool, thanks Jul 27 02:28:47 Minty, just type along the sudoku game from hello android instead of reading(browsing) Jul 27 02:29:47 Bonjour, Hello. Jul 27 02:30:10 Will android.webkit.CookieManager affect the cookies used by HttpClient apis ? Jul 27 02:30:40 I am NOT using the WebView. Only HttpClient. Jul 27 02:30:47 ashitaka, use HttpClient.getCookieStore() or whatever it is Jul 27 02:31:06 all right. will look into that @KNY Jul 27 02:31:32 aunn, I have been, and the great thing is I understand almost all of it, but the problem is that I know I wouldn't be able to make a similar application by myself because I wouldn't know where to start or what functions to use (havent memorized them yet at least..) Jul 27 02:31:59 Minty, and you think you'll be able to do that if you read more books? Jul 27 02:32:06 just start working on a project of your own Jul 27 02:32:11 yay, critical thinking! Jul 27 02:32:18 :| Jul 27 02:32:22 more like inductive learning Jul 27 02:32:57 Ok ill start on a simple project and look here for help :) Jul 27 02:33:58 it won't be long before you re-create this for android: http://sudokugrab.blogspot.com/2009/07/how-does-it-all-work.html Jul 27 02:34:38 minty, fork sudoku Jul 27 02:34:58 write similar app base on the sudoku framework Jul 27 02:35:50 u will run into problems ... that's where u start learning cause u have to look for the cause of the problems Jul 27 02:36:18 can I ask a question for permision to ask if it's ok to query the channel? Jul 27 02:36:57 I just want to open a jpg file, any jpg file, to test some stuff. What's the easiest way to find the path to one? Jul 27 02:38:06 oh, don't be cheap, get ur own books instead of using library books if u r serious about learning ;) but that's my 2 cent Jul 27 02:39:30 what does " super." do Jul 27 02:40:04 you should check out a book on java while you're at it :) Jul 27 02:40:32 I dont know all the syntax :P Jul 27 02:41:05 learn java first before u touch android then Jul 27 02:41:27 well I did a lot of java work beforehand Jul 27 02:41:37 I just havent learned ALL the syntax Jul 27 02:42:07 And I already know C++ so most of it is straightforward.. Jul 27 02:43:19 In java, super.whatever calls the whatever method of the parent class Jul 27 02:43:57 Does anyone know how to get the 'value' from my string array (Map 1), I got my code working to show me 'Map 1' with String selectedItemString = (String) s.getSelectedItem(); but I want that 'map1' value? Jul 27 02:46:33 Do you mean the strings.xml file? Jul 27 02:46:55 which one of us is tripping? is it me? Jul 27 02:46:55 i am using arrays.xml Jul 27 02:47:25 whaledawg, Jul 27 02:47:25 Jul 27 02:49:02 I don't think you're supposed to do it like that Jul 27 02:49:14 An array should be refered to by number, not value Jul 27 02:49:36 so the whole value="" thing should be ignored Jul 27 02:49:57 whaledawg, http://www.designerandroid.com/?cat=4 this guy uses red, is he wrong? Jul 27 02:51:11 well, he's using name="" which still seems weird for an array Jul 27 02:51:15 whaledawg you can try something like this, it will give u the path of the pics http://pastebin.com/m3f521089 Jul 27 02:51:31 but that at least makes sense, name/value pairs Jul 27 02:52:29 whaledawg, he thats what I thought, i think an xml is better for this Jul 27 02:55:05 oh, u need this line first startActivityForResult(new Intent(Intent.ACTION_PICK, android.provider.MediaStore.Images.Media.INTERNAL_CONTENT_URI), SELECT_IMAGE); Jul 27 02:55:24 aunn, SELECT_IMAGE is giving me static Jul 27 02:55:37 aunn, also is photoPath a string? Jul 27 02:56:05 it's uri Jul 27 02:58:24 Bmp= Media.getBitmap(getContentResolver(),photopath); is after that. Jul 27 02:58:58 whaledawg, do you think I can use something else instead of that string-array? or Should I just create an xml file and all that xmlreader jazz? Jul 27 02:59:13 aunn, where does SELECT_IMAGE come from? Jul 27 02:59:30 vladikoff, what are you trying to do? **** ENDING LOGGING AT Mon Jul 27 02:59:57 2009