**** BEGIN LOGGING AT Mon Feb 06 02:59:58 2012 Feb 06 03:04:02 JakeWharton: an idea ? Feb 06 03:04:11 maxagaz, you're probably doing something wrong Feb 06 03:04:18 Java will automatically convert an int to an Integer Feb 06 03:04:49 put the offending code in a pastebin and put the link in here Feb 06 03:04:54 JakeWharton: is there something wrong in this syntax ? private ArrayList wordsIn = new ArrayList(); Feb 06 03:05:07 well, that is an array of arrays Feb 06 03:05:15 you probably only want ArrayList Feb 06 03:06:20 canadiancow, I FIXED A BUG! Feb 06 03:07:02 JakeWharton: I tried it too, but still it's requiring an integer when doing wordsIn.add(myint); Feb 06 03:08:25 if 'myint' is an int or an Integer that should work fine Feb 06 03:08:31 JakeWharton, cool Feb 06 03:08:32 :) Feb 06 03:08:40 canadiancow, now get off my back! Feb 06 03:08:47 actually, i need to figure out your other one Feb 06 03:08:50 it's a biggun' Feb 06 03:09:06 do you think you could release a compat lib thing with FragmentActivity extends MapActivity ? Feb 06 03:09:13 nope Feb 06 03:09:20 requires a ton of changes Feb 06 03:09:31 doesnt it only require one? Feb 06 03:09:36 the "extends" line? Feb 06 03:09:57 well, then everything extends MapActivity Feb 06 03:10:00 yep Feb 06 03:10:01 and can only run on Google devices Feb 06 03:10:05 yep Feb 06 03:10:07 oh shit Feb 06 03:10:10 FACK MAN Feb 06 03:10:15 well i can live with that Feb 06 03:10:44 im not saying to do it by default, but its much easier for you to have your build script generate me a jar with it than for me to do it myself :P Feb 06 03:11:13 that is true Feb 06 03:11:39 I wish Android embraced Maven :( Feb 06 03:12:27 or any build system really Feb 06 03:12:40 just a *build* system Feb 06 03:12:53 anyway im going to relax Feb 06 03:12:55 i dont do enough of that Feb 06 03:13:08 i feel like im just starting my weekend at 10pm on sunday night Feb 06 03:15:33 well, enjoy yourself then Feb 06 03:15:36 i might grab a beer actually Feb 06 03:15:43 nice! Feb 06 03:16:00 it'll be quiet after all the sports nuts head home Feb 06 03:16:15 as long as you're not near Indianapolis Feb 06 03:16:18 hehe Feb 06 03:16:23 Excellent game though Feb 06 03:16:31 Eli is so underrated Feb 06 03:16:54 Announcers kept boasting about Tom Brady, but this is the second time Eli has beaten him in the super bowl Feb 06 03:17:00 I really dont like sports anymore, but I still get sucked into it Feb 06 03:17:11 and he also has more rings than his brother, Payton Feb 06 03:17:26 but I was barely paying attention during most of the thing Feb 06 03:17:32 but everyone still loves brady and payton Feb 06 03:17:57 exciting game, glad it was close Feb 06 03:18:00 fun to watch Feb 06 03:19:56 JakeWharton, we do embrace a build system any its badass, but its internal only. It's the main reason though why you see no Google things built with maven, because it just doesn't fit with the internal versions of things. Feb 06 03:20:21 I thought the same thing until I joined and then I understood. Feb 06 03:21:35 but lots of open source libraries have made their way over to maven central Feb 06 03:22:45 yeah Feb 06 03:22:50 i actually just got the support lib on maven central Feb 06 03:22:58 oh, awesome! Feb 06 03:23:09 and I'm well aware it's not perfect Feb 06 03:23:16 i just really hate ant :P Feb 06 03:23:59 though i'm technically an uneducated hater since i've never actually used it... Feb 06 03:24:07 yeah, think of a giant source tree, like FreeBSD Ports, no jars, no versions (just 'head') Feb 06 03:24:43 no class-path errors with multiple jar versions Feb 06 03:25:05 that'll keep me up at night Feb 06 03:25:22 There's a public TechTalk which talks about the current build system Feb 06 03:25:53 it would be awesome except it's infeasible to have a cluster large enough for the public to use to make it work efficiently Feb 06 03:27:00 if you used maven and instead of any jars, you put the whole tree in a giant multi-module reactor build, you'd be close to the same thing, then git sync periodically Feb 06 03:28:12 the dependency management and automated multi-module versioning is what draws me to Maven specifically Feb 06 03:28:27 http://google-engtools.blogspot.com/2011/08/build-in-cloud-how-build-system-works.html Feb 06 03:31:21 mrenouf, so, hypothetically, if you were to update something you were responsible for you could potentially break something developed by the guys in, say, London which referenced you lib? Feb 06 03:31:34 oh sure, happens some times Feb 06 03:31:48 but we usually know that before comitting Feb 06 03:31:48 but i'm sure you try to maintain APIs and such so as to not have that happen Feb 06 03:32:04 thats what unit tests and continuous integration are for Feb 06 03:32:10 series starts here: http://google-engtools.blogspot.com/2011/06/build-in-cloud-accessing-source-code.html Feb 06 03:32:18 yeah I was just going to say, I remember reading about the CI you do Feb 06 03:33:24 so I can run a set of tests against a snapshot of what I intend to commit and make sure it passes first Feb 06 03:33:45 i'm surprised that works at Google scale Feb 06 03:33:53 though, being Google, I'm really not surprised that you make it work Feb 06 03:34:15 luckily I rarely touch anything that affects too many projects outside my own :-) Feb 06 03:34:34 JakeWharton: it should but it doesn't work fine (sorry for the late reply), the doc says it doesn't accept integers Feb 06 03:34:57 i get nervous enough releasing things that only a few hundred people may use Feb 06 03:35:01 JakeWharton: at google, you can get 30% of a server group offline and no one *outside* will notice ;) Feb 06 03:35:16 haha i guess that's true too Feb 06 03:35:33 maxagaz, it's hard to understand exactly what you're trying to do without a bit more code Feb 06 03:35:39 JakeWharton: but that's because there are mechanisms in place to turn it back on :) Feb 06 03:36:07 JakeWharton: I'm just trying to have a list of integer, and be able to add new integers in this list Feb 06 03:36:47 p_l|backup, latency might go up 10ms or so ;-) Feb 06 03:37:24 mrenouf: yeah. I'm currently applying for such a position ;) Feb 06 03:37:34 SRE? Feb 06 03:37:37 yep Feb 06 03:37:42 or combined SRE/SWE Feb 06 03:37:57 in Dublin Feb 06 03:38:02 cool. they're the real rockstars, I do not envy their responsibilities Feb 06 03:38:26 I hope to do an SRE rotation some time Feb 06 03:38:30 maxagaz, http://ideone.com/lT5aV Feb 06 03:38:32 mrenouf: heh. I consider SRE job easier than getting software dev. for google :D Feb 06 03:38:57 yeah :( Feb 06 03:39:07 I'm still feeling those burns Feb 06 03:39:09 mrenouf: but I guess I don't feel like I've got algorithm skills to do some of the dev work Feb 06 03:39:25 maybe, the couple times I interviewed they steared me towards SRE because I actually have a lot of networking, IT, low level computer type knowledge that they seem to look for. Feb 06 03:39:39 came from 5 years of IT and desktop support when I was starting out Feb 06 03:40:00 but hardware is annoying and fickle, I prefer software ;-) Feb 06 03:40:16 mrenouf: the original reason my friend pushed me towards SRE (I was contacted by Google once before, but it was a fluke ;)), was because of discussions about things like how dynamic linker links the damned binary Feb 06 03:40:20 networks are like this wierd in between hybrid discipline Feb 06 03:41:01 heh Feb 06 03:41:04 JakeWharton, get a chance to check out the global devcamp thing? Feb 06 03:41:12 I'm slowly learning a bit more about networking Feb 06 03:42:09 JakeWharton: thanks a lot :-) Feb 06 03:42:11 (I could do a local ISP these days, just not necessarily from memory :D) Feb 06 03:42:25 mrenouf, a bit. Only problem is that I'm going to be at a big family reunion-type thing for an 80th birthday that weekend Feb 06 03:42:42 ahh, thats life Feb 06 03:42:44 so internet availability is highly unknown Feb 06 03:42:51 no prob Feb 06 03:43:02 global devcamp? Feb 06 03:43:10 yep, in 2 weeks Feb 06 03:43:14 my grandparents still only have 4 channels, internet is like a completely unknown thing to them :P Feb 06 03:43:24 mrenouf: linky? Feb 06 03:43:34 http://phandroid.com/2012/01/30/global-android-devcamp-coming-to-a-town-near-you/ Feb 06 03:43:48 * p_l|backup spent last half-week getting progressively crazier, then finishing his CV Feb 06 03:44:02 its a coordinated around-the-world weekend of hacking awesomeness Feb 06 03:44:11 I guess I could do it on my phone Feb 06 03:44:16 hehe Feb 06 03:44:21 it's only 15 min chunks right? Feb 06 03:44:46 I've heard only bits of what the plan is, I'm concerned centrally that it's not terrible organized Feb 06 03:44:52 mrenouf: I'll forward that my uni's computing society and BCS Feb 06 03:44:57 yeah information is very scattered Feb 06 03:45:05 I'm finally diving into making an android app that communicates to a web service. The code to send and receive the data itself doesn't seem hard. But it's doing it EFFICIENTLY that's got me going crazy. Obviously doing networking code in the UI thread is a huge huge no-no, but from what I hear, doing it in an AsyncTask isn't the best way either. I just want to find code on how to properly Feb 06 03:45:06 communicate via HTTP Feb 06 03:45:19 but the idea is that experts cannot be everywhere at once, so throught G+ hangouts people could present to all of these groups at once Feb 06 03:46:21 Not to much the HTTP calls themselves, but how to communicate with a service, OR if I should just use AsyncTask anyway. I want to make sure things like phone rotation or and incoming call don't screw with say, a user uploading a photo or downloading lots of data (like thumbnails for user profiles) Feb 06 03:46:53 Jouva, the issue with AsyncTask is that you can't guarantee your app will be in a state to handle the response correctly by the time it comes back. For small non-critical stuff, its fine. But if it matters or its a download or something you need to save the response to, you should fire up a service. Feb 06 03:46:57 you should use a service of some sort for something like that Feb 06 03:47:40 the service is guaranteed* to be around long enough, and can get the result and do whatever, then shut itself down Feb 06 03:47:57 i need to write up a demo app and figure out a good pattern for something like that with proper, responsive, cancelable, concurrent HTTP requests Feb 06 03:48:16 I'm convinced an event bus of some sort is essential Feb 06 03:48:20 though, I've found that background threads live quite a while on newer devices as long as ram is free Feb 06 03:48:22 mrenouf: Well first, my biggest question is whether or not the activity being destroyed due to the layout changing causes the AsyncTask to suddenly stop and then restart the whole thing over once it comes back up Feb 06 03:48:40 it will, unless you manage the asynctask's lifetime yourself Feb 06 03:48:51 and provide a callback mechanism that is NOT dependent on the Activity instance directly Feb 06 03:49:00 Jouva, it doesn't kill the background thread, but it will lose contact with the original activity and be unable to post a result Feb 06 03:49:06 *maybe Feb 06 03:49:10 Ahhh ok Feb 06 03:49:33 would this allow for me to create a list of words and define them when a user selects them? Feb 06 03:49:39 firing an intent might work and be the simplest, then your app has an opportunity to wake back up if needed to deal with it Feb 06 03:50:17 Jouva, if you can be more specific about the use case, I can give better advice Feb 06 03:50:20 http://developer.android.com/resources/tutorials/views/images/hello-listview.png like if they click american samoa I can define it on a new activity? Feb 06 03:50:45 I cannot figure out how the ActionBar version of an ActionMode handles the back key being pressed Feb 06 03:50:54 I know how the Window-level action mode handles it Feb 06 03:51:04 but the version when an action mode is present eludes me Feb 06 03:51:32 how are Views privy to keyEvents? Feb 06 03:51:42 JakeWharton, did I show you http://bitgrind.com/~mrenouf/android-4.0.3_r1/ ? Feb 06 03:51:50 mrenouf: Basically a small social networking-ish app. Users, mail, profiles, photos. But for the worst case scenerio, don't want the list of profiles (which will show their thumbnails) to start getting re-downloaded when the phone rotates. Feb 06 03:52:01 I got sick of not having source handy and linkable Feb 06 03:52:20 ooOOOOO!!! Feb 06 03:52:24 thats everything from base and libcore Feb 06 03:52:36 linkable is extremely nice Feb 06 03:52:39 along with unit tests Feb 06 03:52:49 i've been relying on Sublime Text's quick open and quick find Feb 06 03:52:50 yeah, it's maven's jxr plugin Feb 06 03:53:15 i haxored it to run directly against a source tree of my choosing Feb 06 03:53:18 What is a comment in the layout XML Feb 06 03:53:26 Feb 06 03:53:28 ? Feb 06 03:53:29 Thanks Feb 06 03:53:34 np Feb 06 03:53:48 ... that was weird Feb 06 03:53:50 mrenouf, no frameworks/base/policy? looks like only core/ from base Feb 06 03:54:01 hmm, I can add it... hang on Feb 06 03:54:14 no rush, just an observation Feb 06 03:54:16 I have a script that copies stuff out of the repo tree into a temp dir Feb 06 03:54:25 just give me the path ;-) Feb 06 03:54:28 that's where things like PolicyWindow is with all the fun code that backs Window Feb 06 03:54:50 i think it's just frameworks/base/policy/src/ Feb 06 03:55:03 yep Feb 06 03:56:47 mrenouf: Do I instead want to use Thread and Runnable? Feb 06 03:57:36 Jouva, no thats no better, worse actually Feb 06 03:57:46 Heh, ok then Feb 06 03:57:56 JakeWharton, i was pulling anything with a 'java' dir in it, I added 'src' too Feb 06 04:00:46 rsyncing now Feb 06 04:02:04 man, sometimes the abstraction in Android boggles my mind Feb 06 04:02:10 so difficult to follow these method calls Feb 06 04:02:26 the process in which an ActionMode is started is crazy Feb 06 04:04:24 yeah took me forever to follow the trail across the aidl calls into android server land Feb 06 04:04:43 thats where the ugly code lives Feb 06 04:04:53 giant switch blocks and stuff Feb 06 04:05:31 i can only imagine Feb 06 04:05:50 if any of you like beer I strongly recommend watching Beer Wars Feb 06 04:05:56 (unrelated) Feb 06 04:07:09 mrenouf: What about a bound service? What happens when the activity that called bindService gets killed? Feb 06 04:07:36 the service should stop Feb 06 04:07:43 Hmm Feb 06 04:07:47 unless it was also started Feb 06 04:07:52 Right Feb 06 04:08:23 I tend to prefer startService and stopSelf() inside the service Feb 06 04:08:32 my location system uses that setup Feb 06 04:08:39 Like I said, I want to avoid redoing network calls just because it got paused or stopped or destroyed due to a rotation Feb 06 04:08:52 right, so start the service Feb 06 04:09:16 sent it an intent saying 'do this' Feb 06 04:09:37 service does it. on result, sends a broadcast intent Feb 06 04:09:40 then stops itself Feb 06 04:10:07 your activity will be restarted if necessary Feb 06 04:10:37 if you dont want to interrupt the user, then open a notification with a pending intent to do the same and let the user decide to act on it Feb 06 04:10:46 (like "your download is finished") Feb 06 04:10:52 ok Feb 06 04:10:57 make sense? Feb 06 04:14:27 Mostly. Only thing like I said is that it's not a LONG download, but it's just a whole bunch of downloads to display a page of profiles. So neither a notification nor reopening the activity makes sense. I was wondering if a ContentProvider (or some other simpler way of watching the database) seeing new pieces of cached info getting inserted makes sense? Feb 06 04:16:53 So, service grabs photo and name and whatever else it needs for displaying a page, saves each row of info to a row in a cache database, and if the activity is up, it sees this new row and displays it accordingly, or if it was gone, sees several changes and displays them all accordingly. Would that be a decent way? Feb 06 04:20:57 Err excuse me, ContentObserver I should say Feb 06 04:21:52 I would like to postulate there exists no situation where an XKCD comic is not immediately relevant Feb 06 04:22:24 lol Feb 06 04:23:08 My dad just asked about my "big-ass pillow" to which I replied "ass pillow?" Feb 06 04:23:09 http://xkcd.com/37/ Feb 06 04:24:16 mrenouf: thanks for linking that google engineering blog Feb 06 04:24:40 np Feb 06 04:24:48 wow I just had a vi zen moment Feb 06 04:25:15 I discovered/re-remembered the 'D' command Feb 06 04:27:01 I have never known vi nor emacs Feb 06 04:27:24 Usually I'll be on a foreign machine and type 'git commit' and then have to fight my way out :) Feb 06 04:27:35 D deleted everything up until the end of the line? Feb 06 04:27:39 *deletes Feb 06 04:27:59 that's so useful! I was using d$ Feb 06 04:28:07 C works similarly it seems Feb 06 04:28:07 don't hate Feb 06 04:28:08 $ git config --list --global | grep editor Feb 06 04:28:08 core.editor=nano Feb 06 04:28:39 magit.el ;) Feb 06 04:30:45 I know how Twitter can become profitable Feb 06 04:30:52 charge $0.10 for every additional character over 140 Feb 06 04:31:21 LOL Feb 06 04:31:22 everyone who sits with the glaring "-1" or "-2" will glady pay for those extra chars Feb 06 04:31:27 lol Feb 06 04:34:58 haha Feb 06 04:35:20 then I can sell the unicode packer tool Feb 06 04:35:28 JakeWharton: you're not the first one ;) Feb 06 04:35:34 make a chrome extension that compresses and decompresses automatically Feb 06 04:35:49 you can get 8x the chars Feb 06 04:36:06 haha yeah Feb 06 04:36:07 at least Feb 06 04:36:21 I have a util called base2k() Feb 06 04:36:53 lol Feb 06 04:36:59 btw, I learned vi exactly for that reason, so I'd be able to hack it if I was stuck with it on some system Feb 06 04:37:07 and it just kinda grew on me Feb 06 04:37:23 it was my editor for choice in middle school Feb 06 04:37:27 *of choice Feb 06 04:37:29 wow Feb 06 04:37:44 then I switched to Emacs in HS and that was it :) Feb 06 04:37:45 mine was MS Word in middle school Feb 06 04:38:35 nah, for text documents I used OpenOffice. It had the problem of not having spellchecker for polish, though Feb 06 04:38:52 though with time I learnt TeX :) Feb 06 04:41:23 Can an activity initiated the searchdialog and be the same activity that handles the query ? Feb 06 04:41:31 initiate* Feb 06 04:46:30 jeez, this is making Chrome very sad Feb 06 04:46:56 http://bitgrind.com/~mrenouf/android-4.0.3_r1/com/android/internal/policy/impl/PhoneWindow.html Feb 06 04:46:57 tada Feb 06 04:49:48 JakeWharton, http://bitgrind.com/~mrenouf/android-4.0.3_r1/com/android/internal/policy/impl/PhoneWindow.html#1392 Feb 06 04:50:09 nice :) Feb 06 04:50:28 makes my browser chug a bit loading the index Feb 06 04:57:14 is it too late for caffeine? Feb 06 04:57:24 i should just go to bed Feb 06 04:58:11 almost lunchtime! Feb 06 04:59:04 Leeds: way ahead of yah ;) Feb 06 04:59:30 Leeds: I think we're going to sell the house and get out of Japan. Feb 06 04:59:44 too much sushi? Feb 06 04:59:56 Too much gojirra Feb 06 05:00:44 er... radioactive dinosaurs? Feb 06 05:00:54 Besides, my employment prospects in this country aren't looking great since I lost my job after Cisco closed the dept. I was working for down. Feb 06 05:01:05 Leeds: Yeah Feb 06 05:01:34 Leeds: TOo many disasters/quakes/radiation/volcanoes/typhoons/people speaking Japanese/etc/etc/etc Feb 06 05:01:54 ah, yes... sucks being unemployed in a country where you don't have a network Feb 06 05:02:14 Yes. Yes it is. Feb 06 05:03:08 mrenouf: .... import static? TIL... Feb 06 05:03:24 import static <# Feb 06 05:03:25 er Feb 06 05:03:27 <3 Feb 06 05:03:28 hmm? Feb 06 05:03:35 iz good! Feb 06 05:03:43 I had 8 months out of work here... came very close to throwing in the towel Feb 06 05:03:46 * p_l|backup iz a lisper Feb 06 05:03:58 night all Feb 06 05:04:04 JakeWharton: 'night Feb 06 05:04:12 'night Feb 06 05:04:41 Leeds: HK right? Feb 06 05:04:46 yeah Feb 06 05:04:58 Leeds: There's a lot of English still used in HK though, I think? Feb 06 05:05:05 when you're paying the rent with a cash withdrawal on your credit card, you're close to done Feb 06 05:05:14 whoops Feb 06 05:05:40 yeah, plenty of English here - but I think your Japanese is better than my Cantonese... it could barely be worse Feb 06 05:06:54 Haha you have NO idea how bad my Japanese is. Sure I canorder food, ask directions, etc etc, but don't try to get me involved in a conversation because that ends pretty quickly ;) Feb 06 05:20:46 Does anyone know how to make text centered with respect to the compound drawables? Feb 06 05:20:51 (Vertically) Feb 06 05:21:13 gravity doesnt work for that? Feb 06 05:21:21 gravity="center" Feb 06 05:21:35 or center_vertical Feb 06 05:21:47 Ah, right. Feb 06 05:21:53 Difference between gravity and layout_gravity. Feb 06 05:22:02 That makes sense now. Feb 06 05:22:09 Thanks guys. Feb 06 05:22:50 remember it this way: layout_gravity is external, gravity is internal Feb 06 05:23:24 where the bounds of the widget go, vs. where stuf inside the widget goes Feb 06 05:24:14 my favorite confusing naming: TextView has both setMaxSize/setMinSize and setMaximumSize/setMinimumSize Feb 06 05:24:48 Oh I've just never used gravity before. Feb 06 05:25:00 Didn't realize what it was for. Feb 06 05:25:04 er, I meant min/maxWidth Feb 06 05:25:07 What's the difference between them? Feb 06 05:27:12 Also, is there a way to set margins for Compound Drawables with respect to the text? Feb 06 05:27:23 Like (Text []) vs (Text []) Feb 06 05:27:40 you can pad the compound drawable with setCompoundDrawablePadding Feb 06 05:28:02 Excellent. Feb 06 05:34:30 Whats with all the device-specific API packages coming into the ADK manager? Feb 06 05:34:58 why the hell uses that stuff? does it give device specific themes, etc? Feb 06 05:35:08 I can see maybe for testing? Feb 06 05:38:06 mrenouf: prepared device configurations Feb 06 05:38:27 mrenouf: also, in some cases, stuff that vendors include in classpath Feb 06 05:38:29 oh, so I can select them in layout editor for preview? Feb 06 05:38:46 or just for making AVDs? Feb 06 05:38:58 the ones without libs only for AVDs, I think Feb 06 05:39:06 I want to convert my camera preview into a binary image .. Inside the onPreviewFrame method, how can I check the color of each pixel if it's less than a certain value ? Feb 06 05:39:19 the ones with libs, if the libs include themes or widgets, they should show up Feb 06 05:41:17 yeah but unless you make bloatware for the system image, its of little use because your app would then only work on one model !? Feb 06 05:41:44 (using the special libs from vendor) Feb 06 05:48:20 whats the best way to create a list of words and have them defined when you tap them? Feb 06 05:48:44 like you have go in a list of words, and when you tap it it says "to start a race" Feb 06 05:48:51 would listview do this? Feb 06 05:48:54 yes Feb 06 05:49:14 use a ListActivity and implement onListItemClick Feb 06 05:49:28 (* or ListFragment) Feb 06 05:49:34 sweet Feb 06 05:49:44 i finally picked the right target to do something ha ha Feb 06 05:50:02 yeah, thats a good starting excersize Feb 06 05:50:39 sweet Feb 06 05:51:05 today i've made a login form , an email feedback form, and a webview for rss feed Feb 06 05:51:14 so something with a tutorial will be nice Feb 06 06:20:18 mrenouf: is this the best way to do what I am trying to do? http://developer.android.com/resources/tutorials/views/hello-listview.html Feb 06 06:20:35 yeah, thats a good example Feb 06 06:21:01 listview is a bit busy and complex but if you follow the guide you can ignore most of the details for now Feb 06 06:21:32 but its much more complex and powerful than a simple list Feb 06 06:22:16 right Feb 06 06:22:29 now when i get to this part: // When clicked, show a toast with the TextView text Feb 06 06:22:30 Toast.makeText(getApplicationContext(), ((TextView) view).getText(), Feb 06 06:22:30 Toast.LENGTH_SHORT).show(); Feb 06 06:22:37 how do I define what I want to say Feb 06 06:26:03 ((TextView) view).getText() is returning the text of the view you clicked Feb 06 06:26:28 so instead, you can get that text, look it up and then use the result, just do that right above the toast call Feb 06 06:29:43 would I have to modify the item in strings.xml to reflect what is selected? Feb 06 06:30:21 so in strings Bahrain would become Bahrain Feb 06 06:32:23 i love you Feb 06 06:42:27 I'm creating a web page, is there anyyway to check if an android app is already installed? Feb 06 06:50:21 mrenouf: can define the item by using item name="x" and change the (TextView) view).getText() part in some way? Feb 06 07:02:30 Bear10: from a web page? doubt it Feb 06 07:02:48 hmm Feb 06 07:03:54 mrenouf: ok, so I got the list Feb 06 07:04:13 now how do i take the strings and define them Feb 06 07:04:33 so that when it is clicked, the message displays rather then just the text of what is selected? Feb 06 07:04:44 Bear10: think from a user's point of view - would you really want random web sites to be able to get your list of installed apps? Feb 06 07:04:56 Leeds, no that wouldn't be nice Feb 06 07:05:06 but perhaps if i launched lets say a specific url Feb 06 07:05:12 to launch my app that maybe enough Feb 06 07:05:52 you could try doing that, yes Feb 06 07:06:15 Leeds, however something doesn't seem to be working properly, mind if i pastebin my intent filter? Feb 06 07:06:33 go ahead Feb 06 07:07:49 Leeds, http://pastebin.com/e3DZcidx Feb 06 07:08:42 now in an sms if i have http://www.getmyapp.com it works np, but id like my app to launch if i manually placed it in a url too. (is that possible?) Feb 06 07:10:07 You know, I've been trying to get into android development for a long time, but it's been so frustrating I end up raqequitting every time. Feb 06 07:10:07 Here's a business opportunity for someone: make a website where noobs can be tutored and ask stupid questions for a fee of the tutor's deciding. Feb 06 07:10:34 experts exchange . com isn't a bad place Feb 06 07:10:40 Everyone I know hates java with a passion, so I really have noone to go to, and the guide is about as clear as mud Feb 06 07:10:56 Bear10: hum, haven't heard of it, will have to check it out. Feb 06 07:11:13 aarobc: im getting to that point now Feb 06 07:11:28 but, i am on the last screen of my app Feb 06 07:11:58 dunivan: ha, it's good to know it's not just me. Feb 06 07:12:29 Bear10: you mean you want to launch it if the user types in the URL manually? Feb 06 07:12:33 yeah Feb 06 07:12:36 possible? Feb 06 07:13:28 not sure, to be honest Feb 06 07:13:57 the browser may well not issue an intent for an explicitly-typed URL Feb 06 07:14:19 Leeds, i see, i mean ideally what im trying to do is on social networks there will be links to my app Feb 06 07:14:38 and i want it to be automatically launched if clicked from a browser or another app like fb app (just like its done with youtube videos) Feb 06 07:15:00 *that* should work Feb 06 07:16:09 any idea if i need to make adjustments to my intent filter? Feb 06 07:17:18 anyone really good with list view? Feb 06 07:18:28 I want to find the size of TextView after setting some text to it (to know how many pixels does this text occupied)... how can I do that? Feb 06 07:21:29 Leeds: do you have a few minutes for ListView help? Feb 06 07:22:11 dunivan: not right now, sorry Feb 06 07:22:18 thanks Feb 06 07:23:40 Leeds, hmm if i take out the android:host, theres no problem when i click the link on fb, otherwise there is :/ Feb 06 07:30:39 hm, I am looking at someone elses (android) code in eclipse, and there is a red exclamation mark over the projects name, the console claims that there is an error in the default.properties, but I cannot find where it is being read by eclipse. Feb 06 07:34:51 oi Feb 06 07:44:57 b0nn, use android update project -p Feb 06 07:45:42 dunivan it's better just ask your question so anyone who can help can see it Feb 06 07:45:47 instead of trying to target people Feb 06 07:51:16 i am trying to have toast display a definition of a word selected from ListView Feb 06 07:51:44 coming from this tutorial Feb 06 07:52:01 and what's your issue? Feb 06 07:52:38 no matter how I define the toast command, it either breaks or displays the item from strings.xml Feb 06 07:53:04 i tried getting the item name using getattribute and that broke everything Feb 06 07:53:17 getattribute seems very wrong Feb 06 07:53:36 how did you setup your list view? Feb 06 07:53:51 custom adapter or arraylistadapter? Feb 06 07:54:24 arraylistadapter Feb 06 07:54:59 thats what i thought re: get attribute, but it allows you to pull name from the item in strings.xml, so i thought it was worth a shot Feb 06 07:55:27 are they strings or string-arrays? Feb 06 07:56:41 string-arrays Feb 06 07:56:53 well one string-array Feb 06 07:57:02 they're both not in arrays? Feb 06 07:58:00 you should make your words in an array Feb 06 07:58:09 and your definitions in an array that matches the same positions Feb 06 07:58:24 the list view comes from this in strings.xml Feb 06 07:58:25 http://pastie.org/private/tr5uelru4maaemck62dyag Feb 06 07:58:27 then just use the position of the list item to get the right def from the definitions array Feb 06 07:58:59 you defining cities? Feb 06 07:59:03 you're* Feb 06 07:59:28 would the definitions then be its own .xml in res/values? Feb 06 07:59:37 cities is just for proof of concept Feb 06 08:00:00 you can put it in it's own if you want Feb 06 08:00:00 its from the tutorial Feb 06 08:00:02 but you don't have to Feb 06 08:00:28 you could put both arrays in arrays.xml if you want Feb 06 08:00:55 name doesn't matter as long as the file has as the opening tag Feb 06 08:02:01 hi guys. I have a question about TableLayout. I have TableLayout with layout_width="fill_parent", and how can i make my two columns to have similar width? I tried stretchColumns="0, 1", but witdh of them anyway depends on width of content Feb 06 08:02:15 so in the definition list, would the string-array name then change to seotermdefined_array Feb 06 08:02:43 you can name it whatever you want Feb 06 08:03:10 definitions might be a good name Feb 06 08:04:12 ok, now I have to figure out where i saw get location for toast Feb 06 08:06:24 what does cmp mean? Feb 06 08:06:32 in an intent Feb 06 08:10:34 component Feb 06 08:10:48 ( dunivan ): toast doesn't have a get position Feb 06 08:11:04 but your adapter does, in the onItemClick passes the position to it Feb 06 08:11:39 onItemClick(AdapterView parent, View view, Feb 06 08:11:40 int position, long id) Feb 06 08:12:14 thats there then Feb 06 08:12:27 right, so then get the definition array Feb 06 08:12:40 Leeds, i know what the problem is and im not sure how to solve it. it has to do with the facebook redirect mechanism :( Feb 06 08:12:57 ah... yes, that could cause problems Feb 06 08:13:08 String[] array = getResources().getStringArray(R.array.nameofarray); Feb 06 08:13:42 Leeds, http://stackoverflow.com/questions/8734914/android-https-intent-handler-and-browser-redirects this is the same exact problem Feb 06 08:13:48 just theres no solution :P Feb 06 08:15:00 like this t0mless Toast.makeText(getApplicationContext(), ((TextView) view).getText(R.array.seotermdefined_array), Feb 06 08:15:16 Wrong. Feb 06 08:15:43 getText actually lets you pass it a parameter? Feb 06 08:16:14 you don't need to use the view at all Feb 06 08:16:15 im guessing no Feb 06 08:16:43 you just need the position that was clicked Feb 06 08:17:15 and to apply that position to the defined array Feb 06 08:17:28 after you get the array from resources Feb 06 08:17:35 like I said earlier Feb 06 08:17:44 http://pastie.org/private/mcwyzhmtllbkcmmamnbd7w Feb 06 08:18:18 mind if I post my xml? Feb 06 08:19:10 don't need to see it Feb 06 08:19:48 so int position knows what I select Feb 06 08:20:18 now I am trying to have what is selected pull from R.array.seotermdefined_array Feb 06 08:20:25 http://pastie.org/private/ltv97egzdx78yyywx0dvha Feb 06 08:20:26 should work Feb 06 08:22:29 oh, so you just define a definitions list Feb 06 08:22:31 do you know any java dunivan? Feb 06 08:22:35 now what makes it compare Feb 06 08:22:42 none :( Feb 06 08:22:52 You should learn java before trying to tackle android Feb 06 08:23:06 String[] definitions = getResources().getStringArray(R.array.seotermdefined_array); Feb 06 08:23:16 that pulls the xml defined array into a java object Feb 06 08:23:23 Toast.makeText(SeoGuide.this, definitions[position], Feb 06 08:23:23 Toast.LENGTH_SHORT).show(); Feb 06 08:23:42 that makes the toast using the correct position in the definitions array Feb 06 08:23:43 dunivan, what languages do you know Feb 06 08:23:53 html, php, css Feb 06 08:24:09 im working on converting a web app Feb 06 08:24:12 maybe I should've said "programming languages" ;) Feb 06 08:24:22 :p Feb 06 08:24:40 Any object oriented programming experience? Feb 06 08:25:25 now, i have to figure out the error Feb 06 08:25:34 nope Feb 06 08:25:38 i did try learning rails Feb 06 08:26:05 but the web development environments were a pain to switch over to Feb 06 08:26:08 You should really read some intro to java Feb 06 08:26:29 what error? Feb 06 08:26:59 Cannot refer to a non-final variable definitions inside an inner class defined in a different method Feb 06 08:27:23 line 29 of pastie Feb 06 08:27:42 oh... oops Feb 06 08:27:43 make it final Feb 06 08:28:57 thanks for the help t0mless Feb 06 08:29:06 got any good noob resources? Feb 06 08:29:23 the dev guide on d.android.com, no idea for free java tutorials Feb 06 08:29:26 but they're out there Feb 06 08:32:28 ill have to look Feb 06 08:32:35 thanks again for the help Feb 06 08:33:02 yup Feb 06 08:33:04 not I go to bed Feb 06 08:33:06 now* Feb 06 08:33:42 ha ha me too Feb 06 08:38:09 whaduuuuop Feb 06 09:05:52 can someone guide me as to how to use the "intent:" uri? Feb 06 09:17:52 hmm ok now it works on my emulator but not on phone Feb 06 09:21:41 Bear10, what do you want to try? Feb 06 09:22:06 Number5, well its working on my 1.6 emulator but not on my 2.2 android phone. what im trying to do is run an intent uri in the browser to launch my app Feb 06 09:23:08 when on my phone the browser crashes because of a null pointer exception but doesnt tell me much more than that Feb 06 09:23:43 you mean the Android browser? Feb 06 09:23:47 yea Feb 06 09:24:25 that's odd, such a browser should not crash at all, maybe a an error message or something, but not crash. Feb 06 09:24:39 its a fatal exception Feb 06 09:25:10 Bear10, did you try other uri? Feb 06 09:25:18 going to now Feb 06 09:26:01 hm also crashes Feb 06 09:26:22 Bear10, well, try to figure out that first I think. Feb 06 09:27:03 im doing something similair to, intent:#Intent;action=com.bubblebeats.MY_CUSTOM_ACTION;end Feb 06 09:27:07 for the uri, but nope hmm Feb 06 09:27:39 Bear10, to be honest, I've never started an app from the browser, so I can't help you much on that. Feb 06 09:27:48 oh, its okay np Feb 06 09:28:05 weird though how it works flawlessly on emulator Feb 06 09:28:59 I wonder whether it's a standard behaviour to start an app from a browser, when would you like to use such a feature? Feb 06 09:29:08 it is Feb 06 09:29:24 Number5, when posting a link on fb for example and someone clicks it from their device Feb 06 09:29:40 it'll tell you a stacktrace Feb 06 09:30:24 MDijkstra, ill paste bin it in a sec since i cant make any sense of it Feb 06 09:30:36 to start an app by clicking on a link? That looks like a way to hack on someone's device. Feb 06 09:30:49 it isn't Feb 06 09:31:04 Number5, think about youtube / installing an apk from a url, those are all uses too Feb 06 09:31:22 apps can simply install themselves to handle certain url patterns Feb 06 09:31:38 it's how you can choose to open a youtube link in the app or in the browser, for example Feb 06 09:31:43 yup Feb 06 09:32:05 Bear10, ok, thnx for the info. Feb 06 09:32:09 Hi! Does anybody know why the *.jar files included in the Java Build Path of an Android Library Project are not included in the generated androidlib.jar? Feb 06 09:32:18 Number5, sure thing Feb 06 09:32:26 MDijkstra, thnx that's an example I've seen before. Feb 06 09:32:51 ok on 2.1 emulator it also works let me see the stack trace on my phone Feb 06 09:33:48 but there's not much of a point debugging this if there's nothing you can change about it Feb 06 09:34:27 MDijkstra, http://pastebin.com/L6ygu2Zi Feb 06 09:35:29 MDijkstra, http://pastebin.com/5KW1Rviz the uri intent is at the bottom Feb 06 09:36:50 right Feb 06 09:37:04 what's the url you're sending through it? Feb 06 09:37:13 the thing at the bottom Feb 06 09:37:19 the uri intent is the url Feb 06 09:38:02 huh? I can't see anything at the bottom Feb 06 09:38:09 second paste Feb 06 09:38:13 http://pastebin.com/5KW1Rviz Feb 06 09:38:17 What's the best way to implement a download schedule, where I can add/remove things to the download queue, but only one item gets downloaded at the same time? Needs to keep downloading iin the background. Feb 06 09:38:24 MDijkstra, intent:#Intent;action=com.myapp.VIEW;package=com.myapp;component=com.myapp/.Dashboard;end Feb 06 09:38:33 oh Feb 06 09:38:37 ew Feb 06 09:39:08 I'm pretty sure it can't resolve that Feb 06 09:39:16 what are you trying to accomplish? Feb 06 09:39:18 MDijkstra, does on the emulator Feb 06 09:39:35 I'm looking for the "right" way to do this. Ideally, I would just say "download me this thing" and it would start the download service, the service puts it in its queue and when everything is done the service stops. How to do this without reinventing the wheel? Feb 06 09:39:40 yeah, but that could be a fluke, or due to the fact the security measures are disabled there Feb 06 09:39:56 but this is not how you should go about doing this Feb 06 09:40:15 MDijkstra, no, ive been reading about it and it is how im supposed to do it, read a post from a google dev Feb 06 09:40:33 Bear10: first tell us what you're trying to accomplish Feb 06 09:40:40 launch my app from a url Feb 06 09:40:43 I mean, sure, I could write a facade that caches the download tasks until it gets a callback from the service and gives it to it, but I'm afraid there is already something to do this? Feb 06 09:40:50 MDijkstra, http://stackoverflow.com/questions/2430045/how-to-register-some-url-namespace-myapp-app-start-for-accessing-your-progr/2430468#2430468 hackbod is the author Feb 06 09:41:52 Bear10: yeah, that's great, except for the fact that it crashes when trying to parse it as a SIP URL Feb 06 09:42:11 maybe its my phone? Feb 06 09:42:31 even if it is, you can't be sure Feb 06 09:43:46 tbh I'd just do what he tells you not to do and register your own URL in the http:// namespace Feb 06 09:43:59 MDijkstra, did that but it doesnt work with fb Feb 06 09:44:06 this does Feb 06 09:44:21 again, it's a bit unclear what you are exactly trying to do? Feb 06 09:44:38 what's unclear about it? i have a link, i click it, i want it to launch my app. Feb 06 09:44:40 what does fb have to do with opening a link on a webpage? Feb 06 09:44:47 because the link gets posted on fb Feb 06 09:44:58 yeah, that works fine for youtube urls Feb 06 09:45:01 it'll redirect Feb 06 09:45:05 and then it works Feb 06 09:45:06 yes but not custom schemas Feb 06 09:45:10 schemes* Feb 06 09:45:14 then don't do a custom schema Feb 06 09:45:17 but do a suburl Feb 06 09:45:30 you cant do a redirect to have it launch, itll just stay in the default browser Feb 06 09:45:48 if the browser gets a null pointer exception it's never your fault Feb 06 09:45:59 but there's little you can do to remedy this Feb 06 09:46:06 because fb wraps your content url, launches the default browser, then (even if you set up an intermediate page with a new redirect, it just stays there) Feb 06 09:46:10 yes Feb 06 09:46:23 which works fine, unless you use a custom url scheme Feb 06 09:46:26 however if you redirect to an intent thats a different story Feb 06 09:46:41 so do what youtube does Feb 06 09:46:56 http://somedomainyouown.com/android/ opens the app Feb 06 09:47:08 doesnt do that if launched from fb is what im telling you Feb 06 09:47:14 it works if from sms Feb 06 09:47:17 or from qr Feb 06 09:47:19 Bear10: I'm telling you, it works fine for youtube Feb 06 09:47:28 and for any other app that uses the feature Feb 06 09:47:31 facebook, linkedin Feb 06 09:47:33 name another app plz Feb 06 09:47:53 i already know youtube works, but i did that same method and it wasnt working Feb 06 09:48:00 what won't work is somecustomscheme://url Feb 06 09:48:12 MDijkstra, i already did http://mydomain.com/android/ Feb 06 09:48:17 that didnt work is what im telling you Feb 06 09:48:26 because when you click the fb link, your host isnt the host you typed in Feb 06 09:48:30 the hsot is m.facebook.com Feb 06 09:48:32 I don't know what you did, but I've seen lots of apps use this and they work just fine Feb 06 09:48:37 yes, so it'll redirect Feb 06 09:48:43 and then it'll reach your intended url Feb 06 09:48:47 and launch your app Feb 06 09:48:50 yes but then it just stays in the browser Feb 06 09:48:58 yes, which is not supposed to happen Feb 06 09:49:15 MDijkstra, http://stackoverflow.com/questions/8734914/android-https-intent-handler-and-browser-redirects Feb 06 09:49:19 someone else with my exact problem Feb 06 09:52:02 Is this a bug or is it intentional that an Android Library Project does not include the *.jar files from its Java Build Path? Feb 06 09:52:35 I didn't find any issues on http://code.google.com/p/android/issues - but maybe it's a new one Feb 06 09:52:38 Bear10: again, I've seen a ton of apps that use this, and youtube isn't 'special' in any way (it doesn't get to use special private api's that normal apps can't) Feb 06 09:52:53 Bear10: so I'm inclined to think there's something wrong with your code rather than with the system Feb 06 09:53:10 MDijkstra, i used the intent filters written al across the web... Feb 06 09:54:01 the ... browsable category... default... and then the scheme:http with the host as "myhost.com" Feb 06 09:54:13 i mean that is the code isnt it? Feb 06 09:55:18 yes, but instead of jumping right to the conclusion try debugging the issue Feb 06 09:55:32 i cant debug it when nothng shows up Feb 06 09:55:35 ie, see what facebook tries to do exactly Feb 06 09:55:49 fb rewrites your url... then redirects, once opened Feb 06 09:56:00 yes, but you don't know where it redirects to Feb 06 09:56:05 to my page Feb 06 09:56:08 it could mangle your url in a specific way that breaks it Feb 06 09:56:16 you don't know that Feb 06 09:56:24 well thats why i setup an intermediary page Feb 06 09:56:27 to redirect it properly Feb 06 09:56:30 but even then it doesn't work Feb 06 09:56:44 fb -> middle page -> my page Feb 06 09:56:48 Uhhh, the tag for XML was part of Android since API Level 1 right? Feb 06 09:57:02 For making state list drawables Feb 06 09:59:44 n/m it was something else dumb. 1.5 didn't know about drawable-hdpi folders Feb 06 10:01:32 morning Feb 06 10:01:48 afternoon Feb 06 10:02:32 lunch! Feb 06 10:03:27 and MDijkstra on my phone facebook even for youtube videos takes you to their website Feb 06 10:03:30 it doesnt execute the app Feb 06 10:03:46 yeah, it doesn't on mine Feb 06 10:06:29 I just tried with two youtube URLs, using both the facebook app and the website on the browser Feb 06 10:06:33 on an ICS device Feb 06 10:06:44 and what happened? Feb 06 10:06:49 it works exactly like it's supposed to Feb 06 10:06:59 first you get the redirection page Feb 06 10:07:25 then it opens the youtube app Feb 06 10:07:39 you sure its the youtube app and not fullscreen html5 or something? because mine isnt opening the youtube app Feb 06 10:07:43 its the browser Feb 06 10:07:47 nope, it's definitely the youtube app Feb 06 10:08:23 Bear10, didn't click always use this once did you? Feb 06 10:08:39 i dont think so unless someone else used my phone (which is possible) Feb 06 10:09:37 i think you can check in the settings Feb 06 10:10:20 open settings -> applications -> browser -> there's a subtitle launch by default Feb 06 10:11:02 alex_PP well doesnt look like it was set Feb 06 10:11:08 so no it was not used to run as default Feb 06 10:12:32 I have an ASyncTask that can take any URL as an argument to fetch data from it, how do I avoid writing lots of if-cases in my onPostExecute to insert the data where I want it and instead try to do it more dynamically? Say, like setting a global variable "httpResponse" and use that somehow? Of course I can't use it directly in onCreate because it will be null when the app starts, but... how would I go about it the best way? Feb 06 10:12:42 Hope the question makes sense Feb 06 10:12:49 If I move a canvas on my ImageView, the touch area doesn't move .. how do I move that aswell? Feb 06 10:13:32 getImagematrix.mapPoints Feb 06 10:13:38 on tyour touch x and y Feb 06 10:13:45 Mikellip: implement a delegate on the asynctask Feb 06 10:14:10 MDijkstra: ty, I'll look up delegation :-) Feb 06 10:14:11 ie, have the class which spawns the asynctask provide a delegate that gets called from onPostExecute Feb 06 10:14:11 alex_PP: Thanks I try that Feb 06 10:14:42 new SomeAsyncTask(this).run("http://google.com"); Feb 06 10:15:04 onPostExecute will simply pass the response to that method Feb 06 10:15:14 and the Activity can decide what to do with the response Feb 06 10:18:00 ok ty :-) Feb 06 10:26:11 Mikellip: new FetchTask() { @Override protected void onPostExecute(Void... barf) { handle result here; } }; Feb 06 10:26:31 that's how I would do it, anwyay: specialize your fetching task on the spot to do the right thing with the result Feb 06 10:28:34 yeah, it depends on your use case too Feb 06 10:29:09 if you use the same asynctask many times, then subclass it with the common behavior Feb 06 10:29:14 or even implement a delegate Feb 06 10:29:29 if you're only going to do this once, use an anonymous subclass Feb 06 10:29:51 alankila: ah, didn't think of using an anonymous declaration like that :) Feb 06 10:30:39 Mikellip: well, it depends on whether you want to reuse whatever you're doing in doInBackground Feb 06 10:30:42 you usually do Feb 06 10:32:49 Hi Feb 06 10:33:20 what's new in android Feb 06 10:33:41 android 4.1 comes with a free pony Feb 06 10:33:46 :-D Feb 06 10:33:48 no unicorn? :( Feb 06 10:33:54 Ty MDijkstra and alankila :-) Feb 06 10:33:56 that's a feature for 5.0 Feb 06 10:34:05 pony means Feb 06 10:34:07 ah nice Feb 06 10:34:16 5.0 - Unicorn Dust Cookie Feb 06 10:34:17 you know, a magical creature Feb 06 10:34:20 Android 7.0 will have experimental interface to Google Spouse ;) Feb 06 10:34:22 that brings joy and happiness Feb 06 10:34:34 but only installable separately for those in the test program ;) Feb 06 10:34:56 and gives you contextual ads from time to time Feb 06 10:35:13 a la the truman show Feb 06 10:35:33 nah, that's somewhere after Google gets nanofabs and their cost drop ;) Feb 06 10:36:14 so Google Spouse would be one of the paid services that had no ads yet still be profitable to them ;) Feb 06 10:37:21 Spoogle. Feb 06 10:38:52 sounds about right Feb 06 10:43:17 alankila: Yellow! How's it going? Feb 06 10:45:41 Everything is going remarkably well. Feb 06 10:46:24 alankila: Glad to hear it. :-) Feb 06 10:50:04 I wonder if you really did hear it. Feb 06 10:50:27 because those words always have a certain, soothing machine-intoned resonance to them. Feb 06 10:51:26 actually, the original citation uses the word "extremely". Oh bummer. Feb 06 11:04:55 can i do maps for a imageview like in html? Feb 06 11:05:54 hey anyone know how i check the exact url and params that ive sent with httppost? once u add all the name value pairs etc it would be nice to check the final url Feb 06 11:06:25 Gaz`: observe that the parameters don't go in the url with httppost usually Feb 06 11:06:31 they are submitted as the http request body Feb 06 11:07:11 they _could_ be placed in URL also though. Sometimes the servers even read both and don't care which way the parameter was received Feb 06 11:07:22 aha Feb 06 11:07:26 generally though Feb 06 11:07:33 state modification=POST Feb 06 11:07:37 view options=GET Feb 06 11:07:42 yeh i usually just put them into the url and it works but im sort of trying to do it the way they do in docs Feb 06 11:07:50 its just nice to have a url printed for copying and pasting etc Feb 06 11:07:53 to test Feb 06 11:08:07 ie, you shouldn't put stuff that modifies the app state in GET vars Feb 06 11:08:38 right Feb 06 11:09:34 bit annoying, how are you supposed to actually check the url by eye Feb 06 11:09:38 servers sending back errors Feb 06 11:09:52 or well, if you POST but give the params in a GET manner (ie, in the URL) then I suppose it's ok Feb 06 11:10:10 but you generally don't do that Feb 06 11:10:58 yeh Feb 06 11:11:16 right Feb 06 11:11:20 I restart eclipse Feb 06 11:11:26 and my entire android sdk is missing suddenly Feb 06 11:12:20 No editor descriptor for id com.android.ide.eclipse.editors.resources.ResourcesEditor Feb 06 11:14:18 right Feb 06 11:14:24 I have another eclipse somewhere Feb 06 11:14:25 weird Feb 06 11:19:27 Gaz`: if you're doing anything related to network request, the tool you don't want to live without is named Charles Web Proxy Feb 06 11:19:48 http://www.charlesproxy.com/ Feb 06 11:20:45 There you can check what exactly is being sent (and replied) Feb 06 11:26:54 hrm, I'm experiencing a weird market issue Feb 06 11:27:09 I have version 1.0 on the market Feb 06 11:27:27 now I uploaded an updated apk with version 1.1 Feb 06 11:27:39 and I can activate it just fine, it'll show the new version is now active Feb 06 11:27:52 and a day later it'll revert to 1.0 Feb 06 11:29:29 without any error or message Feb 06 11:50:18 How to put the Image on ImageView without losing its original size.. (android automatically resizes the image to fit in imageview) Feb 06 11:53:35 banpdtr_: do you want to resize the imageview to fit the image? Feb 06 11:53:53 or simply show a part of the unresized image in the imageview? Feb 06 11:54:17 banpdtr_: http://developer.android.com/reference/android/widget/ImageView.ScaleType.html Feb 06 12:04:09 MDijkstra: I want to resize the ImageView to fit the image ... Feb 06 12:06:35 set scaletype to Center Feb 06 12:06:53 and programmatically set the height and width to the height and width of the image Feb 06 12:07:38 oh.. thanks MDijkstra.. will try that now Feb 06 12:22:51 guys. suppose i've got a list view that gets data fed from a content provider into the SimpleCursorAdapter. but that data contains relational data, which comes out of a second content provider. how would I go about displaying related stuff in the view bound to the simple adapter? Feb 06 12:23:42 flashingpumpkin: best is to write your own adapter, imo Feb 06 12:23:53 Make a NotSoSimpleCursorAdapter Feb 06 12:23:58 flashingpumpkin: or to query the cursor yourself, eager load the relations Feb 06 12:24:08 that's a nice and complicated way to say 'I want master-detail' Feb 06 12:24:10 and then provide it the view with an arrayadapter Feb 06 12:24:47 ok, thanks Feb 06 12:24:55 generally it's better (imo) to do the time-memory tradeoff and keep it in memory Feb 06 12:25:09 rather than issuing sql as you go Feb 06 12:26:13 MDijkstra, yes, I was suspecting so Feb 06 12:28:36 Snuffel, I wasn't familiar with master-detail Feb 06 12:30:50 flashingpumpkin: it's very googlable Feb 06 12:41:11 Snuffel: it's not really about separate screens afaik Feb 06 12:41:33 it's about pulling in relational data to format in a single listview Feb 06 12:44:22 i never said anything about separate screens Feb 06 12:47:28 Snuffel: well, I googled the pattern Feb 06 12:47:31 which does mention it Feb 06 12:47:50 ie, http://en.wikipedia.org/wiki/Master%E2%80%93detail_interface Feb 06 12:48:54 no it doesn't Feb 06 12:49:12 A master area can be a form, list or tree of items, and a detail area can be a form, list or tree of items typically placed either below or next to the master area Feb 06 12:49:46 Snuffel: again, that's not what he's describing at all Feb 06 12:50:13 "how would I go about displaying related stuff in the view bound to the simple adapter" Feb 06 12:50:38 it's a data model question, not a UI question Feb 06 12:54:02 NDK question: Assuming I want to pass a float[] buffer from Java to C and vice versa, can i use native float[] in C calling? Or should I use jfloatArray? Feb 06 12:54:40 I'm guessing the latter Feb 06 12:54:48 why else, would jfloatArray exist? Feb 06 12:56:20 yes, jfloatArray, and you need to request the underlying float[] array pointer and release it when done Feb 06 12:56:59 how does java map floats to 'native' floats anyway? Feb 06 12:57:12 does it simply use the underlying format or does it emulate a format of its own? Feb 06 12:57:30 (although that'd probably be way too slow) Feb 06 12:57:41 alankila : right, but how about writing to this buffer so it can be returned to java? Feb 06 12:57:53 GetFloatArrayElements() returns a read/write pointer ? Feb 06 12:59:41 i think i must use ByteBuffer::allocateDirect Feb 06 13:03:19 WindowsNT: you use the jni API. Feb 06 13:03:37 it has the methods for extracting pointer, and notifying java that it has new data when you release it Feb 06 13:04:16 I use env->GetPrimitiveArrayCritical and env->ReleasePrimitiveArrayCritical pair myself Feb 06 13:05:40 these operations lock out GC, so you are best off keeping them brief Feb 06 13:05:55 thats what I did: Feb 06 13:07:38 MDijkstra, looks like my phone was the one causing the issue with the intent uri, because it works fine on emulator and on my dad's phone Feb 06 13:08:22 http://pastebin.com/5mPvK8DP Feb 06 13:08:25 should this work? Feb 06 13:09:30 how hai der Feb 06 13:09:39 WindowsNT: bad code, imo Feb 06 13:10:02 if you fundamentally work with float[], then use float[], don't copy into FloatBuffer first Feb 06 13:10:28 can i pass float[] directly to C? Feb 06 13:10:36 yes. Feb 06 13:10:43 using jfloatArray Feb 06 13:10:44 sure, it's a C primitive type Feb 06 13:10:51 alankila : i want a read/write buffer Feb 06 13:11:28 if i lock the jfloatArray with env->GetFloatArrayElements() Feb 06 13:11:32 Whatever you want doesn't interest me. You can share a float[] buffer between java and C provided you use the jni API Feb 06 13:11:33 then the buffer I get is read only Feb 06 13:11:48 consider GetPrimitiveArrayCritical Feb 06 13:12:10 this returns a read/write buffer? Feb 06 13:12:54 right Feb 06 13:13:12 as I see, GetPrimitiveArrayCritical does not copy Feb 06 13:13:26 it returns the underlying pointer to the float array in your case. Note that you must keep it brief and do not use any other jni methods while you hold the array pointer Feb 06 13:14:13 Critical shit is critical. Has to observe rules. If you want something else, you can ask java to return you a copy and then send back updated data later Feb 06 13:14:27 Hi all Feb 06 13:14:43 I don't want a copy. Feb 06 13:15:09 yeah well then you want critical Feb 06 13:16:47 right, trying. Feb 06 13:17:26 https://github.com/lioncash/droidsound/blob/master/jni/FFT/FFT.cpp Feb 06 13:17:42 happens to be a piece of code I've written that uses jni to manipulate java's short[] array Feb 06 13:19:27 hmm, comments appear to be slightly out of date. Oh well. Feb 06 13:21:54 and to pass/receive chars, i would use a jbyteArray, yes? Feb 06 13:22:48 uuh... you pass/receive bytes using jbytearray. Not same as java chars, maybe same as C chars Feb 06 13:23:00 yes, C chars Feb 06 13:23:01 8 bit Feb 06 13:23:23 would recommend using jbyte as the type Feb 06 13:23:35 consistent signedness with java after that I guess Feb 06 13:23:54 I use unsigned char anyway so it should be equal Feb 06 13:24:04 * alankila is forever impressed by the fact that C guys left char signedness to be implementation defined Feb 06 13:24:09 no, java bytes are signed Feb 06 13:24:44 casting should be automatic anyway. Feb 06 13:24:47 alankila : char is signed Feb 06 13:24:58 as int long short etc Feb 06 13:25:23 according to C standard language layering, char signedness is implementation defined. Feb 06 13:25:30 lawyering Feb 06 13:26:14 I'm not sure, perhaps you are right, or perhaps it has changed in C++ 0x or C99. Feb 06 13:26:23 But all compilers implement it signed by default. Feb 06 13:26:31 probably not. Feb 06 13:27:47 also, now that I use the direct lock with jni it seems to work. Is there a way to debug the C++ code from eclipse ? Feb 06 13:28:56 except using self-debugging using logcat of course Feb 06 13:29:10 i found some resource but they say it's obsolete for ndk7 Feb 06 13:29:48 sorry, not particularly familiar with native development on android. I do it sometimes, but I use logprints... Feb 06 13:30:43 I see, anyway thanks a lot for your time. Feb 06 13:31:04 you're welcome Feb 06 13:33:26 I don't see why, some times, my desire keeps disconnecting from usb debugging mode and I have to re-enable it :( Feb 06 13:33:33 complete time waste Feb 06 13:33:45 flaky connection? try another cable. Feb 06 13:33:51 says someone called windowsnt Feb 06 13:34:37 yea perhaps, although it doesn't happen all the times. Feb 06 13:35:05 is there anyway to update the android browser? Feb 06 13:36:07 Bear10: hmm, I doubt it. The browser's rendering engine is from the framework, so updating just the apk will not do it... But I would imagine people would have made and distributed alternative browsers for android Feb 06 13:36:07 nope Feb 06 13:36:29 darn oks Feb 06 13:36:30 thanks Feb 06 13:36:39 going to try a diff browser Feb 06 13:47:38 hi Feb 06 13:54:59 Another one. I am trying __android_log_print and ld says that it is undefined , although I 've added LOCAL_LDLIBS := -llog to android.mk Feb 06 13:55:56 no idea, that is how it's supposed to work Feb 06 13:58:26 worked Feb 06 13:58:34 it wanted LOCAL_LDLIBS := -llog BEFORE include $(BUILD_SHARED_LIBRARY) Feb 06 13:59:29 afaik that include should be the last thing in you .mk Feb 06 13:59:41 yea obviously Feb 06 14:01:24 Anyone knows how i can upload my android app to the BB appworld? Feb 06 14:03:21 psychuil: yes, RIM know Feb 06 14:05:21 argh... Feb 06 14:05:40 I have a relative layout within a relative layout and it's alignBottom with an element inside the outer relativelayout Feb 06 14:05:53 but it grows completely to the top, eventough it's wrap_content Feb 06 14:06:31 Hey guys, I need some direction please. I am building a little app to enable me receive my mobile calls on my pc, has anyone worked on something similar? Feb 06 14:06:55 iivvoo: it seems rather convoluted to have nested relativelayout Feb 06 14:07:23 iivvoo: and, how would the inner relativelayout determine its sizing? Feb 06 14:07:41 MDijkstra: based on its children, which are a lot smaller Feb 06 14:07:57 MDijkstra, I need something to wrap 2 child elements to set a semi-transparent background Feb 06 14:08:25 they're not fill-parent-width, so I'd get a small area without the background Feb 06 14:13:15 iivvoo: I'm not exactly sure which layout effect you're looking for, but this seems unnecessarily complex Feb 06 14:13:54 iivvoo: relativelayout can almost always be avoided, nevermind about nested relativelayouts Feb 06 14:13:58 psychuil: Have to tested on a RIM device? I know for a fact none of my apps will work at all. Feb 06 14:14:28 iivvoo: also: Feb 06 14:14:28 "Note that you cannot have a circular dependency between the size of the RelativeLayout and the position of its children. For example, you cannot have a RelativeLayout whose height is set to WRAP_CONTENT and a child set to ALIGN_PARENT_BOTTOM. Feb 06 14:14:30 MDijkstra: I'm a fan of nested frame layouts Feb 06 14:14:33 " Feb 06 14:14:46 MDijkstra, I guess that's my problem then Feb 06 14:14:49 thanks Feb 06 14:15:03 iivvoo: np, if you're looking for a toolbar type of effect Feb 06 14:15:17 you could use a framelayout Feb 06 14:16:00 Is gmail dead for others? Getting a 502 here. Feb 06 14:16:16 Very much alive here Feb 06 14:16:52 MrChyizPyiz, i've read somewhere you can just upload android app for the playbook on the appworld Feb 06 14:17:40 alive here Feb 06 14:17:46 psychuil:sure, but my apps require access to various content providers, and broadcast receivers. Without them my apps are useless. Feb 06 14:18:32 Mine doesn't, and i can't seem to find how to upload it.. Feb 06 14:19:20 Estel: 502 is "Bad Gateway" - do you use a proxy, or a provider forcing you through a proxy? Feb 06 14:19:54 redarrow: it's resolved now, but it was a 502 from Google, not locally. Feb 06 14:20:09 Estel: ok Feb 06 14:48:24 Hi. I have started to write a simple app for android but i have troubles. Here is the code : http://pastebin.com/M7DydVhe. And here is what adb logcat tells : http://pastebin.com/jpzXLsEw. I have displayed a log message when the activity is created but i don't understand what happens next Feb 06 14:51:00 toadd: at com.sc2profile.Sc2profileActivity.onCreate(Sc2profileActivity.java:21) Feb 06 14:51:05 w_reader is null Feb 06 14:54:10 i want to register my app users through http. what i have now is an activity which asks for user details->on click starts a service that connects to my server which returns a user id. whats next: should i add the user id to the SharedPreferences while in service? or return the user id to the activity(how?)? Feb 06 14:54:50 *IntentService Feb 06 14:58:08 how to detect text copy event in versions prior to 3.0? Feb 06 15:00:07 SimonVT, thanks. You saw it in the logcat? Feb 06 15:00:15 toadd: yes Feb 06 15:00:42 Just under E/AndroidRuntime( 396): Caused by: java.lang.NullPointerException Feb 06 15:01:09 You generally want to look for a line that says Caused by: something Feb 06 15:01:29 Then look for a line that mentions one of your classes after that Feb 06 15:32:12 native android games are dead Feb 06 15:32:15 html5 is the future Feb 06 15:32:44 suure :) Feb 06 15:32:57 adobe air is teh future! Feb 06 15:33:01 five years later: html5 is dead, gogogadget zomgsauce is the future Feb 06 15:33:22 i'd buy zomgsauce Feb 06 15:34:25 zomgsauce is the future because it promotes synergy across vertically integrated components Feb 06 15:35:00 BINGO! Feb 06 15:36:06 oh, i received my BB playbook btw. Feb 06 15:36:47 any good? Feb 06 15:37:00 haven't played with it yet, it's at my sisters place in London Feb 06 15:37:12 Was it a hassle? Feb 06 15:37:17 quite fast though, only gave them my contact details last week Feb 06 15:37:20 hmm, not really Feb 06 15:37:20 The appworld stuff or whatever Feb 06 15:37:23 yeah Feb 06 15:37:27 they're handing them out for free now? Feb 06 15:37:30 if so, give me 20 Feb 06 15:37:40 MDijkstra: Upload your app, get free playbook Feb 06 15:37:50 I want to make a stand out of them for my galaxy tab Feb 06 15:37:54 * MDijkstra runs Feb 06 15:38:03 the biggest hassle was to get behind their key signing stuff, you need to apply for a couple of files, which are sent to you two days later Feb 06 15:38:15 ah yeah, they extended that offer Feb 06 15:38:31 i think it's stupid of them to open the offer to everyone Feb 06 15:38:36 I kind of attempted to write an app, but couldn't remember flex and gave up Feb 06 15:38:39 so many crappy apps will pop up there :D Feb 06 15:38:52 I'll probably do a fart app Feb 06 15:38:58 just to take the piss Feb 06 15:39:00 RobinB: Yeah, thinking of uploading a crap app as well :p Feb 06 15:39:10 hehe, everyone is. Feb 06 15:39:15 they should have left it invite only Feb 06 15:39:34 which platforms count? Feb 06 15:39:34 guess it's like free ice cubes on the titanic Feb 06 15:39:37 Hello guys, I have my that starts Activity X, this activity starts Activity Y, but than I switch app and than switch back to my App, what happens is it starts with the default Activity X, but it should start Activity Y. Should I manage my own activity administration to see what Activity started last? Or is there a fancyer way to handle that? Cause now my app crashes. Feb 06 15:39:48 ie, can I just port this android app? Feb 06 15:40:08 yeah, you can even do it online, they have a web form to upload your apk Feb 06 15:40:12 lmao Feb 06 15:40:22 okay, I'm getting myself a playbook Feb 06 15:40:36 just do the notepad tutorial, give it a different name, and presto Feb 06 15:40:40 MDijkstra: APK built for 2.2 and an icon 86x86px Feb 06 15:40:43 damn, i feel bad for them :D Feb 06 15:40:59 I don't even need to do that Feb 06 15:41:03 86px icon is just a recommendation Feb 06 15:41:11 I have a couple of android apps that could be easily ported Feb 06 15:41:29 RobinB: Nah, mine failed because my icon wasn't that size. On the online converter at least Feb 06 15:41:49 right, after office hours I'll get back to this Feb 06 15:42:23 can you run android on it? Feb 06 15:43:08 (URL, btw?) Feb 06 15:43:12 maybe it can be hacked onto it, dunno. but it seems to me that their OS is very similar to Android Feb 06 15:43:23 they're using QNX, which is pretty cool Feb 06 15:44:45 I need to send them my ID... then just try to package up an existing app Feb 06 15:45:05 does anyone have an URL for the promotion? Feb 06 15:45:07 did see a comment on a blog that it can take 2 weeks to get an account activated, which makes the offer pretty weak :) Feb 06 15:45:14 hello, I was thinking of the best way to put our calendar events on a tablet. They change once a year. So for our organization I made a public calendar in it with all the dates. And I want it to go onto the device calendar. Then I can grab those dates for a widget. Is there and API to get the calendar from our public calendar into the device calendar? I see in ICS there is a way to access the device calendar. Feb 06 15:45:37 MDijkstra: https://bdsc.webapps.blackberry.com/android/ Feb 06 15:45:37 MDijkstra: http://devblog.blackberry.com/2012/02/latest-blackberry-playbook-tablet-offer-for-android-developers/ Feb 06 15:45:42 cheers Feb 06 15:46:27 Leeds: They're quick if you send them a mail, and ask if you need to do anything else. at least they were two weeks ago Feb 06 15:48:05 so, I just create an ID, port my app and I'm done? Feb 06 15:49:28 MDijkstra: plus some BB bureaucracy and security riffraff, but yeah. Feb 06 15:50:20 you also need to be over 18 and send them proof of identity, like scan of your driving licence Feb 06 15:50:33 How does one port his app? Feb 06 15:50:40 ah, that's not a problem Feb 06 15:50:41 online form. Feb 06 15:50:53 I wasn't able to find it :\ Feb 06 15:50:55 psychuil: https://bdsc.webapps.blackberry.com/android/ Feb 06 15:50:59 <3 Feb 06 15:51:17 And anyone who uploads an app gets a playbook? o_O Feb 06 15:51:34 well, the app has to conform to their T&C Feb 06 15:51:48 there is a clause in there that the app has to be "deemed useful" or something Feb 06 15:51:59 not sure where fart soundboards fall Feb 06 15:52:01 :D Feb 06 15:53:08 can you add a shared calendar to device calendar? with out having to add a google account? Feb 06 15:53:20 My app was downloaded by 126 people and kept by 26. Think that's enough? Feb 06 15:53:41 psychuil: i doubt that they check Market statistics. Feb 06 15:54:15 Can anyone provide me a link or docs how to show the right acticvity when the app is resumed after switching apps? I could keep my own administration of last visible activity, but ... if someone has a good solution conform Android design rules, it would be great. Feb 06 15:54:41 RobinB: fart soundboards don't conform to T&C Feb 06 15:54:49 Is it possible to pack two applications inside a single APK? Feb 06 15:55:04 dunivan: i'm disturbed that you know that. Feb 06 15:55:15 its in the t&c Feb 06 15:55:26 yeah, i'd imagine. i was joking :) Feb 06 15:55:32 I only know because I was going to submit my app which was a web launcher Feb 06 15:55:40 and thats frowned down upon Feb 06 15:55:56 dunivan: did they send you some message in that respect? Feb 06 15:56:03 i'm still waiting for my app world verification though Feb 06 15:56:32 RobinB: nope, saw it in the t&c, under specifically excluded apps Feb 06 15:56:42 haha, oh dear Feb 06 15:56:52 haha, nice Feb 06 15:57:51 I imagine their thought process must have been something like "Shit! That's the 125th fart soundboard that we've received today! Now I know why there's so many apps on the Android Market! Quick, put something in the T&C!" Feb 06 15:58:18 I wonder how picky they really are... if my weather app will pass :) Feb 06 15:58:29 yeah RobinB Feb 06 15:58:45 how long did it take after you sent in your id? Feb 06 15:59:27 dunivan: 40 minutes Feb 06 15:59:47 damn - i'm going on 4 days Feb 06 15:59:50 i sent it to a specific contact though, and that was before the big rush Feb 06 16:00:01 try mailing developeroutreachprogram@rim.com Feb 06 16:00:12 sweet, thanks Feb 06 16:00:29 make sure you give them enough detail to identify your application Feb 06 16:01:30 Ok, waiting on my signature stuff Feb 06 16:04:35 how can i get the content of the clipboard? Feb 06 16:06:24 elye: http://developer.android.com/guide/topics/clipboard/copy-paste.html#RTFMlazyass Feb 06 16:12:53 hi. Anyone work with accelerometer Feb 06 16:17:06 panda81: I'm pretty sure. Feb 06 16:17:45 RobinB: you're on a roll Feb 06 16:18:35 RobinB: I'm curious how responsive are accelerometer applications across multiple devices. I.e., have you experienced slow response on some devices versus others Feb 06 16:18:45 evancharlton: It's hard to hit the snark-sweetspot, don't want to piss off the newbies ;) Feb 06 16:18:53 RobinB: :) Feb 06 16:19:25 panda81: that's a good question actually. Some seem to be a bit more accurate than others, but in general they're not very accurate Feb 06 16:19:32 don't expect wii accuracy, for example. Feb 06 16:19:50 have something in mind? Feb 06 16:20:43 RobinB: for me, my prob with responsiveness. The app I develop, whenever accelerometer driven animation is involved, works somewhat faster on a Xoom than a Galaxy Tab 8.9 Feb 06 16:21:06 hi, I've got an issue with a background service. I have a static instance of my httpHelper and when I'm trying to get it (in my service) I've got a new object, not the object created in my Application class. Any idea? Feb 06 16:22:15 RobinB: yet the Galaxy tab gives more accelerometer readings per second than on the Xoom Feb 06 16:23:17 panda81: there's different settings for the polling speed of the accelerometers, have a look at SensorManager.SENSOR_DELAY_NORMAL _GAME and _FASTEST Feb 06 16:23:51 hello! Is there anyone trying to build android for a dragonboard? It seems their repository on codeaurora still refers to android.kernel.org which no longer exists afaik Feb 06 16:24:05 however, different hardware manufacturers use different accelerometer chips, so you'll always have some difference Feb 06 16:24:17 RobinB: yeah have been trying the different polling speed. Ultimately, the same code runs on the Xoom and Galaxy Tab. Feb 06 16:24:19 also, anyone can confirm android.kernel.org no longer exists? Feb 06 16:24:44 RobinB: so you think the blame can be placed on the accel chip implementation? Feb 06 16:25:05 jprvita: It's not longer hosted there, but it redirects to the right googlesource repos Feb 06 16:25:08 panda81: i'd guess, but i'm really not in my element there Feb 06 16:25:18 adun: You have a static instance in your application and when you try to pass it to your service it is not the same object? Feb 06 16:25:58 SimonVT: weird, I'm getting an error here while trying to repo sync Feb 06 16:26:04 Fetching projects: 2% (3/114) fatal: unable to connect to android.git.kernel.org: Feb 06 16:26:05 android.git.kernel.org[0: 149.20.4.77]: errno=Connection refused Feb 06 16:26:17 RobinB: hehe. Yeah it's hard to know. I only have two devices. Don't know how to tell supervisor what else is there to be done to prove if it's a problem I can solve Feb 06 16:26:39 adun: Are you trying to pass it from the application to the service or are you trying to retrieve it from your application in your service? Feb 06 16:26:56 panda81: i could run a quick test on a GNex and a Galaxy 10.1 tab Feb 06 16:27:16 jrgarcia I'm not trying to pass it throw putExtra but directly trying to retrieve it that way : getApplication() or httpHelper.getInstance Feb 06 16:27:25 jprvita: they changed the location. the website redirects, but the git-urls don't. Feb 06 16:28:03 RobinB: thanks. If I get permission I'll let you know. The 10.1 should have the same hardware as my 8.9 right Feb 06 16:29:06 adun: How are you creating the httpHelper in your Application? More specifically, at what event in the lifecycle does it get created? Feb 06 16:29:17 Xperimental: is there any way I can fix it locally? or should I ping someone from codeaurora and wait for them to fix it? Feb 06 16:29:50 panda81: probably, though there've been different hw iterations with the gtab 10 alone Feb 06 16:30:24 have you used repo? Feb 06 16:30:27 I am trying to tint an image by using the "tint" attribute however instead of tinting it completely fills in the object with whatever color i use. How do you tint an image? Feb 06 16:30:31 jrgarcia the onCreate() method of MyApplication class (extends Application) Feb 06 16:30:49 Gsingh: tried adjusting the alpha value? Feb 06 16:31:03 RobinB: oh one thing has been on my mind. Each time I get an accel reading, I call glSurfaceView.requestRender(); Is this ok Feb 06 16:31:21 RobinB: I'm still a newbie to android what is the alpha value? Feb 06 16:31:45 Xperimental: yes, im using repo Feb 06 16:31:46 panda81: errr, dunno. I'd decouple graphics from sensors though Feb 06 16:32:22 Gsingh alpha is for transparency Feb 06 16:33:00 in a RGBA color context Feb 06 16:33:20 jprvita: you could probably try to get the new manifests for the projects and then resync. Feb 06 16:33:29 but I haven't tried that myself. Feb 06 16:33:44 hmm... does anyone know if it's normal that ABS 3.5.1 Light theme is unskinned on Android 4.0? Feb 06 16:33:59 jprvita: wait. you are not using the standard manifests, right? Feb 06 16:34:05 any of you guys using Intellij? Feb 06 16:34:06 but I need the codeaurora repositories Feb 06 16:34:15 Xperimental: no, I using the codeaurora ones Feb 06 16:34:30 AOSP manifest clones right with repo :) Feb 06 16:34:45 Yes mikedg Feb 06 16:34:54 perhaps you could patch the manifests yourself... Feb 06 16:34:56 but I'm trying to build for the dragonboard, and there is some modifications from codeaurora I need Feb 06 16:35:18 SimonVT: is there any way to just open a directory? WebStorm lets you do that, and it's convenient Feb 06 16:35:23 Xperimental: any hints on what should I look for? Feb 06 16:35:34 I don't get the whole jetbrains IDE topology :/ Feb 06 16:36:23 It is still filling in the image completly Feb 06 16:36:31 mikedg: I don't believe so :F Feb 06 16:36:58 like it seems like intellij should have most of the features of webstorm, but theres no clear cut explanation Feb 06 16:37:49 jprvita: take a look at .repo/manifests Feb 06 16:38:09 don't know if it will work... Feb 06 16:38:46 haven't used repo for more than getting the AOSP source myself Feb 06 16:39:06 and i cant figure out if its worth buing both intellij and webstorm? Feb 06 16:40:01 I can't find platform/libcore at github.com/android... is it mirrored somewhere else? and if it's indeed not mirrored at github, can anyone explain why? Feb 06 16:40:16 mikedg: I've only relaly used it for android dev, so can't really help you there :F Feb 06 16:40:49 Anyone have any ideas? I still have the entire image fill in with the color instead of it being tinted Feb 06 16:42:05 Gsingh: You probably have to do it manually Feb 06 16:42:25 either tint the image, and make a semi-transparent overlay with the original image Feb 06 16:42:44 or use something like this http://xjaphx.wordpress.com/2011/10/18/image-processing-tint-color-yet-another/ Feb 06 16:43:40 I'm having a look at it Feb 06 16:43:41 mikedg: it seems to me that JetBrains have compiled some features in some versions of the IDE and not in others Feb 06 16:44:03 hi Feb 06 16:44:21 but globally, it's so much better than freaking Eclipse. I tried using it this morning, it's absolutely terrible compared to IntelliJ Feb 06 16:44:50 can I reuse a private class MyCustomAdapter (nested in my activity's class) in another activity ? Feb 06 16:44:52 I never gave intellij a chance Feb 06 16:45:00 but i started using webstorm for some html 5 game work Feb 06 16:45:02 and its awesome Feb 06 16:45:09 so im gonna give intellij a chance Feb 06 16:45:19 I've been using IntelliJ exclusively for my Android work, and it's awesome Feb 06 16:45:39 RobinB: as to your first suggestion, do you mean make a copy of the same image and tint it in photoshop or something? Feb 06 16:46:08 I want to apply this as a style thats why i dont want to do it programmaticaly Feb 06 16:47:17 Gsingh: I meant the one-color version you had earlier (probably via ColorFilter filter = new LightingColorFilter(Color.RED, 1); p.setColorFilter(filter); or similar), and overlay that with the original Feb 06 16:48:11 ah i see Feb 06 16:50:44 what is the correct syntax to have both ListActivity and BaseAdapter in : public class MyCustomAdapter extends ListActivity extends BaseAdapter {...} ? Feb 06 16:51:18 you can only inherits from one class Feb 06 16:51:40 btw you can implements many interfaces Feb 06 16:51:50 adun: how ? Feb 06 16:52:24 public class MyCustomAdapter extends ListActivity { ... } Feb 06 16:53:15 adun: and then, how can I use BaseAdapter methods ? Feb 06 16:53:28 maxagaz: you can't; it doesn't work that way Feb 06 16:53:44 maxagaz: and you almost certainly don't want to do that, anyway Feb 06 16:53:47 maxagaz: you could use an inner class Feb 06 16:53:51 what are the downsides of using largeHeap Feb 06 16:54:18 but i would suggest you use a seperate class for the adapter Feb 06 16:54:55 Xperimental: actually my class extending BaseAdapter was in another class extending ListActivity, but as I want to reuse it, I decided to put it in its own class file Feb 06 16:56:52 maxagaz: When you now have a FooListActivity, a BarListActivity and your MyBaseAdapter as seperate files, then you have done what i meant Feb 06 16:57:20 actually, the only error I get when having it in a new class file is this one : public MyCustomAdapter() { mInflater = (LayoutInflater) getSystemService(Context.LAYOUT_INFLATER_SERVICE); } Feb 06 16:58:06 Xperimental: that's what I'm doing, thanks :) Feb 06 16:58:37 sry ppl could somebody tell me how i support multible languages or whats the best way to make the xml understand it needs to choose the right file? Feb 06 16:58:42 maxagaz: getSystemService is a method of Context. when you have your adapter as a seperate class you will have to pass the context as a parameter Feb 06 16:59:06 Xperimental: okay Feb 06 17:02:47 Everyone knows Andorid-15+ has awesome cool features. But my client says don't keep telling him this bullshit, since most people on the planet uses 2.2! x-( Feb 06 17:03:21 :( Feb 06 17:03:33 there are many compability packages out there Feb 06 17:03:36 first of all, i think technically, most are on 2.3 Feb 06 17:03:41 second, what features from 15 do you need Feb 06 17:03:45 which add features like the action bar for preICS Feb 06 17:04:35 canadiancow: I would like to have everything from iconed buttons Feb 06 17:04:52 iconed buttons? xDD Feb 06 17:05:07 jrgarcia I'm getting it, In eclipse debug perspective I can see my service is lanched in another Application that's why my singleton fails Feb 06 17:05:28 http://developer.android.com/resources/dashboard/platform-versions.html Feb 06 17:05:31 2.3.3, actually :P Feb 06 17:05:49 :) Feb 06 17:06:19 napster: what are "iconed buttons"? Feb 06 17:07:25 evancharlton: Leave it, I was kidding! Feb 06 17:07:27 i love how customers just don't appear at their appointments -.-' Feb 06 17:08:54 adun: Ah, yes. I was wondering about that, but didn't have enough context and didn't want to ask for your codebase :) You won't be able to ask for it directly like that, but you should be able to get around it. Feb 06 17:09:55 I'm developing for Android mobile devices using Eclipse and Google's SDK/AVD managers. Can I set an already-open android virtual device (android emulator) as the target for my app? Feb 06 17:10:14 Eclipse seems to start a new android emulator every time I test my app. Feb 06 17:10:51 jrgarcia thanks for your help, this leads me to the fix (just forgot about the remote process -_-") Feb 06 17:11:20 Pritchard: If you don't close the emulator, eclipse should not start a new one Feb 06 17:11:44 eclaesson: Huh. Thanks. Feb 06 17:18:11 Xperimental: did you mean that I should have something like this : mInflater = (LayoutInflater) getSystemService(Context.LAYOUT_INFLATER_SERVICE); mAdapter = new MyCustomAdapter(mInflater); ? Feb 06 17:19:42 Xperimental: doesn't seem to make sense... Feb 06 17:24:44 brb Feb 06 17:31:05 adun:? Feb 06 17:34:02 I'm a bit confused, I don't understand where and how should be reconfigured "public MyCustomAdapter() { mInflater = (LayoutInflater) getSystemService(Context.LAYOUT_INFLATER_SERVICE); }" nested in MyCustomAdapter once MyCustomAdapter class is in its own class file Feb 06 17:34:26 Pass your context to the adapter Feb 06 17:34:47 context.getSystemService Feb 06 17:42:28 SimonVT: where is set the context variable ? Feb 06 17:42:45 Pass it in the constructor Feb 06 17:42:57 public MyCustomAdapter(Context context) Feb 06 17:43:18 SimonVT: how ? Feb 06 17:43:22 sorry Feb 06 17:44:08 How? Change the constructor to accept context? Feb 06 17:47:09 SimonVT: with something like this: mAdapter = new MyCustomAdapter(Context context); ? Feb 06 17:55:19 SimonVT: but where do I get the context variable from ? Feb 06 17:57:47 * g00s updated 2009 mbp to Lion - worst mistake EVAR Feb 06 17:58:02 ouch Feb 06 17:58:07 is it really this bad? Feb 06 17:58:24 too slow, animations laggy, takes up too much memory Feb 06 17:58:37 oh .. how much ram do you have? Feb 06 17:58:40 4g Feb 06 17:58:46 ah this may explain that Feb 06 17:58:51 Or just the graphics adapter Feb 06 17:58:57 after doing almost nothing, i realized i had 900mb free Feb 06 17:59:11 I feel your pain Feb 06 17:59:21 and this was a fresh install, wiped drive first Feb 06 17:59:25 lol Feb 06 17:59:30 windows ftw Feb 06 17:59:50 where the fuck did spaces go Feb 06 17:59:52 maybe it's like in win7? It grabs as much ram as it can, but frees it if required by other apps Feb 06 18:00:04 RobinB: dunno, my hd is grinding a lot Feb 06 18:00:07 spaces was replaced Feb 06 18:00:07 g00s: they moved the space-bar as well? damn! Feb 06 18:00:14 Did anyone see my question earlier -- is it possible to put two applications in a single APK ? Feb 06 18:00:28 by Mission Control (much better & more useful IMHO) Feb 06 18:00:50 Cpudan80: yes, there's a guide in the docs about this Feb 06 18:00:52 Cpudan80: should be. Feb 06 18:01:09 fpillet: really? Can you provide a link? Feb 06 18:01:14 Cpudan80: http://developer.android.com/guide/market/publishing/multiple-apks.html Feb 06 18:01:47 no ... thats not what I want Feb 06 18:02:00 Basically I have a photo / markup activity that is eating up too much memory Feb 06 18:02:05 And is basically unusable Feb 06 18:02:23 So the idea was to put it in a separate app altogether, to get that app more juice Feb 06 18:02:40 Split into separate activities Feb 06 18:02:59 Memory is per application, not per activity Feb 06 18:03:14 And it's already separate activities Feb 06 18:04:02 you want to have 2 icons in the launcher for one apk? so to say Feb 06 18:04:12 Are you handling low memory notifications? your inactive activities should be removed from memory, unless you have a bug (retain cycle by a service?) that keeps them there Feb 06 18:04:35 Aeefire: you can turn off icons in the launcher Feb 06 18:04:57 fpillet: Yeah, the problem is that I have several services in my application, and after a while they eat up most of the memory Feb 06 18:05:05 ah, there you go Feb 06 18:05:31 Then fix your memory retain bugs first, that should solve your issues :-) Feb 06 18:06:07 fpillet: Well - in the long term - I need to put the services in a separate thing altogether Feb 06 18:06:24 You don't need to, really Feb 06 18:06:33 Mmm yeah, I do Feb 06 18:06:37 AFAIK splitting in separate apps won't solve your memory consumption issues Feb 06 18:06:43 Hmm Feb 06 18:07:13 fpillet: Why wouldnt they, each app gets it own memory pool... right? Feb 06 18:07:23 How would this solve your problem? Feb 06 18:07:42 Can someone please help me, I have a STRING named "categoryName" and I would like to use that STRING to fetch the ARRAY that has the same name as the VALUE of the categoryName STRING Feb 06 18:07:48 At some point, the OS will kill one of your services because it needs the memory for your other one :-) Feb 06 18:07:59 Well, each app gets say 10 MB of memory Feb 06 18:08:01 What you need to do is offload as much data as you can on storage Feb 06 18:08:12 Currently, when I got to take a photo, I go above the limit and crash Feb 06 18:08:28 So, the theory was to use a separate photo app Feb 06 18:08:36 Which would have 10 MB of its own (or whatever) Feb 06 18:09:29 fpillet: the application is complicated ---- we've offloaded as much as we can, but we still run up against the wall when we take photos Feb 06 18:09:36 Cpudan80: you can specify that a service runs in a separate process, according to the docs Feb 06 18:09:59 fpillet: Well yeah, that is part of the long term fix -- but for the immediate term I dont want to mess with that Feb 06 18:10:33 So - that goes back to the original question -- will putting the photo activity into its own app fix my problem? Feb 06 18:10:52 something like this SasaKaranovic http://daniel-codes.blogspot.com/2009/12/dynamically-retrieving-resources-in.html ? Feb 06 18:11:33 fpillet: The problem we're having is that when the user snaps the photo, the callback gives us a big giant byte array - which blows up Feb 06 18:11:43 Even if we've set the compression to like 90% JPG Feb 06 18:13:19 the giant byte array will probably be the raw bitmap object, i don't think the compression matters at that point Feb 06 18:13:51 zeeZ: I would like to use something like this, String[] listElements = getResources().getStringArray(R.array.categoryName); Feb 06 18:14:04 i'm subclassing a view, and i'd like it to subscribe to a global event when it gets created, and unsubscribe when it gets destroyed... are there any methods in the View that i can override, like onPause/onResume in the activity? Feb 06 18:14:33 zeeZ: Is there any way I can tell compiler that categoryName is not name of the category but the string that contains the name of the string Feb 06 18:14:38 Well if you're going to split the app, you'll have IPC between services already. I don't see why going the extra mile and starting the service from the same app in a separate process is much more work Feb 06 18:14:59 actually, all you have to do is add android:process=":remote" in your manifest Feb 06 18:15:27 fpillet: well, for the immediate term I was only going to move the photo activity, not the whole service stack Feb 06 18:15:37 apple really goes out of their way to make installing the jdk on lion as much of a pita as possible Feb 06 18:16:12 guys have you had problem on htc where when I connect htc desire z to my PC and set internet pass through as my regime eclipse wont find my phone Feb 06 18:16:31 when I choosed another regime my phone is found but I can't access internet through USB which I need for my APp Feb 06 18:16:44 fpillet: that process:remote thing ... is interesting ... Feb 06 18:16:47 I'll try it Feb 06 18:16:55 I can't put application on phone and launch it directly but still seems rather odd Feb 06 18:17:12 anyone know the best version of the JDK to use on Lion ? Feb 06 18:17:30 g00s: I use the latest one IIRC Feb 06 18:17:43 fpillet: uh, whats the 'latest one' Feb 06 18:18:00 dec 22, 2011 is a dev preview- don't want that Feb 06 18:18:00 found the info by googling, you should be able to do it too -) Feb 06 18:18:06 nah no dev preview Feb 06 18:18:13 yeah, i am looking at their list of excrement Feb 06 18:18:21 just used the official released one or whatever Feb 06 18:18:44 i googled too and went to developer.apple.com Feb 06 18:18:58 but each jdk i find says 'pre-release' Feb 06 18:19:02 Trudko: I don't think debugging via USB is possible if you share your connection vis USB Feb 06 18:19:11 *via Feb 06 18:19:50 ok that make sense...and i guess it same if i debug and even if I don't.. Feb 06 18:20:01 eclaesson: it works, but you use adb connect Feb 06 18:27:48 fpillet: Well I added that :remote thing to my service just as a test --- it comes up with a class cast exception when I try to bind to the service Feb 06 18:27:50 Hey, do you guys know if there's a way to make it so you can't ignore the install signature on my apps? Feb 06 18:28:09 So that if I want to install the non-market version over the market version or if I build on different computers. Feb 06 18:28:10 Question : I want a textview with my own font. TextView::setTypeface apparently succeeds but the text is displayed using the internal fonts Feb 06 18:28:28 Cpudan80: blame the docs :-) or maybe just read them more thoroughly than I did, I found this from a cursory look but don't use this flag myself Feb 06 18:28:29 fpillet: I bind like ((myService.LocalBinder)service).getService(); Feb 06 18:28:34 Typeface::createfromAsset also succeeds Feb 06 18:28:51 is there an easy way to debug javascript in the android browser? I need to dump some objects but compared to chrome it's impossible to work with Feb 06 18:28:51 fpillet: yeah, the docs made it sound good ... :-) Feb 06 18:29:01 I don't even know where to start. I can't see the resources that were loaded and in what order so I have no idea why it doesn't find a script that all desktop browsers find Feb 06 18:29:22 Cpudan80: is the flag supported by the OS version you're targetting? Feb 06 18:30:35 fpillet: yeah Feb 06 18:32:56 somewhere I read that font changing isn't working on API leve 8+, is that true Feb 06 18:35:14 Is it no longer true that personal fonts aren't recommended in the design guidelines? Feb 06 18:35:30 I was always under the impression that loading custom fonts was kinda resource intensive. Feb 06 18:36:35 I need some help about having my custom adapter in its own class file Feb 06 18:37:22 RMapZero: I'd be wary of using custom fonts, but sometimes it's necessary Feb 06 18:37:34 well Feb 06 18:37:38 i need a symbol font Feb 06 18:37:43 particular to the app Feb 06 18:37:44 its not a text font Feb 06 18:38:02 WindowsNT: then remember to use some tool to cut out unnecessary symbols Feb 06 18:38:52 ? Feb 06 18:39:05 WindowsNT: remove symbols you aren't going to use Feb 06 18:39:13 all of them are used Feb 06 18:39:36 i'm curious about something Feb 06 18:39:45 has anyone here gone through a 4 year university CS program recently? Feb 06 18:39:50 like in the last few years? Feb 06 18:40:25 i am interested to know if through your coursework you were ever introduced to any form of version control, and if so, which tools and to what degree? Feb 06 18:41:00 specifically through the coursework, not external experience. Feb 06 18:41:07 jasta: officially - SVN, a little Feb 06 18:41:19 can you quantify a little? Feb 06 18:41:21 jasta, i did computer engineering, and no, not really Feb 06 18:41:40 unofficially: one of my courses requires building up a complete software solution, in a team, from scratch. You either figure out VCS or perish Feb 06 18:41:46 jasta: completed a BSc 2 years ago, we were introduced to SVN, and were taught to use that through a major group project Feb 06 18:41:55 the class materials had SVN, nothing more Feb 06 18:42:10 my team uses Git :3 Feb 06 18:42:25 skfax: just for 1 project? Feb 06 18:42:50 jasta: usually that project is part of some "software engineering" class Feb 06 18:43:19 surviving the drivel related to UP and UML is... Feb 06 18:43:24 well yeah, a large group project the last year. i also used it for my bsc project. they can't really do anything besides teach you how to use it, or use it for group projects :) Feb 06 18:43:28 jasta: I graduated last summer and the only thing we officially had to use was RCS during CS1. Be afraid. Feb 06 18:43:58 evancharlton: so, that is the experience i am seeing most often. Feb 06 18:44:17 i'm currently looking for junior devs at my current company to takeover grunt work the core team should not be wasting their time on Feb 06 18:44:19 no luck even in onDraw() :( Feb 06 18:44:21 can't display the font Feb 06 18:44:32 and im finding these guys look at me like i'm insane when i even say "version control" Feb 06 18:44:43 i couldn't be more furious how our schools are failing the industry Feb 06 18:44:50 jasta: do a bootcamp Feb 06 18:45:19 using Full Metal Jacket for inspiration Feb 06 18:45:32 watched that yesterday Feb 06 18:45:55 "get some!" Feb 06 18:46:22 I informed my team that anyone sending around tarballs/zips of code instead of using git, will die slowly disemboweled with a rusty spoon Feb 06 18:47:14 p_l|backup: http://www.youtube.com/watch?v=M3iOROuTuMA Feb 06 18:47:44 trying it in 1.5 emulator Feb 06 18:47:48 to see if it works in previous versions Feb 06 18:51:46 I'd like to build up a dream Ubuntu machine for Android development. Anybody have any thoughts / feedback on this? Feb 06 18:51:57 hmm Feb 06 18:52:00 with another font Feb 06 18:52:01 it works Feb 06 18:52:04 Currently using a mid-level Lenovo which works fine, but I'm looking to upgrade. Feb 06 18:52:06 so is there a problem with my font? Feb 06 18:56:20 how should be set the variable Context in: mAdapter = new MyCustomAdapter(Context); ? Feb 06 18:58:02 where do I take it from ? Feb 06 18:58:10 maxagaz, depends on where you're calling it from Feb 06 18:58:19 Activity, Service, Application are all Context objects Feb 06 18:58:20 jasta: btw, some things I gleamed from others who did project management. Those juniors *won't* know things like not committing to master repo if it does't pass the tests Feb 06 18:58:58 jasta, school is about a CS education, not job training Feb 06 18:59:08 Hi All, I've started my own app where I want it to loop an audio file a certain amount of times (let's say 1hours worth), then rest for a given amount of time (let's say 20 minutes). I want this whole process to be iterated a certain amount of times, for now lets say 3 times. Does this sound like a feasible program? I have the portion of the code working to play the audio looped a set amount of times. However, I am having trouble figuring out w Feb 06 18:59:08 to begin to make the application wait a certain amount of time before it starts looping the audio. Feb 06 18:59:09 scm/vc is not a part of cs education, really Feb 06 18:59:27 Any suggestions on how to get started with the sleep/wait function? Feb 06 18:59:47 hansvg, you use notify/wait Feb 06 18:59:49 not sleep Feb 06 18:59:49 pfn: activity Feb 06 18:59:54 pfn: I don't think it's an excuse for them Feb 06 18:59:54 maxagaz, then 'this' Feb 06 19:00:03 pfn: Thanks, I'll read up on notify/wait Feb 06 19:00:37 hansvg, otherwise, look at all the java.util.concurrent.locks classes Feb 06 19:00:40 you can use any of those as well Feb 06 19:01:04 pfn: so? Feb 06 19:01:28 maxagaz, use 'this' Feb 06 19:01:44 maxagaz, spend a little bit of time learning about the class hierachy Feb 06 19:02:20 thank you pfn Feb 06 19:02:26 pfn: btw, the schools are failing on the "CS" front too, officially going after what "bussiness wants". Result is bullshit on both CS ("basic knowledge") and the Engineering ("how to apply it instead of writing papers") fronts Feb 06 19:02:42 well, CS seems a bit more focused on academics than basic knowledge Feb 06 19:02:58 pfn: if you have some good doc to suggest me about this, I'd be happy to read it Feb 06 19:03:29 i still truly dont udnerstand why schools have not broken apart CS and computer programming Feb 06 19:03:39 pfn: I meant that "CS" is basic knowledge for this area Feb 06 19:03:42 the industry is large enough now to just define two different majors. Feb 06 19:03:45 jasta: wouldn't really work Feb 06 19:03:46 well, you have devry and ITT to do the latter Feb 06 19:03:58 and all the vocational schools like that Feb 06 19:04:41 separating theory and application is IMHO wrong in CS Feb 06 19:05:08 it's not theory and application, why did you assume that's what i meant? Feb 06 19:05:17 CS depends on your school. Because I had some applicable CS classes that werne't just theory and application Feb 06 19:05:23 computer programming is a theoretical discipline as well. Feb 06 19:05:52 But I do agree, as a whole it is simply theoretical. It took me until going into industry to learn what and how to use version control Feb 06 19:05:59 better said, both have sufficient theoretical depth to fill an academic degree by current standards. Feb 06 19:06:01 which really should be covered in any CS program, IMO Feb 06 19:06:18 schools aren't a job training program, most people seem to think it is Feb 06 19:06:20 its a basic fundemental part about development, yet it is rarely covered. Feb 06 19:06:22 that's the biggest fallacy Feb 06 19:06:51 pfn: i agree with you, but allow me to play devil's advocate. what then is law school or med school? Feb 06 19:06:53 pfn: ya, but schools still should give you the opportunity to learn applicable skills, other then the basics of programming Feb 06 19:07:04 why do med students observe practicing doctors? Feb 06 19:07:10 if not to train them to do their job Feb 06 19:08:41 jasta, because it's a bastardized apprenticeship program Feb 06 19:09:17 if it wasn't part of med school, it would just be part of what you do after med school. Feb 06 19:09:21 it is a necessity for them to learn. Feb 06 19:09:58 i don't think apprenticeships are specifically a requirement of any major, that's why i said ia gree with you, but in principle there should still be a strong understand that the next step for most after university is to actually do the thing they are showing interest in learning about. Feb 06 19:10:33 understanding* Feb 06 19:11:48 In my opinion, things like version control, profiling, debugging etc. are CS' equivalents of Psychology practicals where we had to design, conduct and analyse experiments (similar stuff exists in Chemistry, Physics, etc.) Feb 06 19:12:58 Anybody have any thoughts on a killer Ubuntu setup for Android dev? Thoughts on machines that work well with Ubuntu? Feb 06 19:13:56 pfn: you really saved me, thanks a lot Feb 06 19:14:01 VonRath: I wouldn't have used Ubuntu, but I'd look into big amounts of memory, and >4-way system Feb 06 19:16:39 jasta, well, I think some people do agree that some form of apprenticeship in engineering would be worthwhile Feb 06 19:17:10 jasta, just as apprenticeships exist in other vocations, contracting: plumbing, electrical, construction, etc. Feb 06 19:17:26 jasta, right now, it's all up to on-the-job training Feb 06 19:18:49 Steve McConnell wrote all about this topic in 'Professional Software Developmen', basically nobody can agree on a curriculum or definition of programmer & engineer Feb 06 19:19:13 For an activity: Is there a guarantee given that there will always be an Intent? Feb 06 19:19:56 g00s: software engineering is not, most of the time the stuff that goes there is really bad IMHO Feb 06 19:20:51 in the us there is this idea of 'professional engineer' , some states like tx use licensing / regulation around this Feb 06 19:21:08 to work on certain types of systems you need a PE certificate Feb 06 19:21:49 we have that here too Feb 06 19:21:50 g00s: in UK bestowing the title of engineer is done by an external society (in case of CS, British Computing Society) Feb 06 19:21:55 it's why you cant spell out the acronym MCSE Feb 06 19:22:08 http://www.tbpe.state.tx.us/ Feb 06 19:22:09 and here, CS is NOT engineering Feb 06 19:22:19 how should I rewrite this to use it in a different class: "DictTabActivity ParentActivity = (DictTabActivity) getParent();" ? (my problem being the getParent method) Feb 06 19:22:21 Poland has separate certifications and engineering title Feb 06 19:25:23 p_l|backup: What do you mean by >4-way system? Feb 06 19:25:32 VonRath: 4 cpu (cores,whatever) Feb 06 19:25:42 mmm Feb 06 19:25:42 4way Feb 06 19:25:51 I want to bring the old term back! Feb 06 19:26:05 :D Feb 06 19:26:40 I'm still confused. Elucidation? Feb 06 19:26:48 * p_l|backup remembers seeing one of the first 16-way Opteron workstations... back when it required 8 cpus Feb 06 19:27:23 VonRath: 1-way - single processing unit, 2-way - two processing units (simultaneous), 4-way etc. Feb 06 19:27:51 a "dual core" single module would be a 2-way system, technically Feb 06 19:28:49 I'm cool with that. And there are 4-way CPUs now? Jeez. I've been sleeping, I guess. Feb 06 19:28:52 anyway, SSD might be useful, but lots of RAM will be always needed, as well as pretty strong cpu Feb 06 19:29:03 quad cores are available, yes, even in quite cheap laptops Feb 06 19:29:35 (there's a 500 GBP quad-core, 64bit laptop at local Curry's) Feb 06 19:34:37 ah, loving it when you're almost done with a new update Feb 06 19:34:51 and you can just spend time polishing with nice error handling and such ^.^ Feb 06 19:38:22 Is it possible to require a password to unistall an application on android? Feb 06 19:40:00 no Feb 06 19:40:12 only device administrator applications Feb 06 19:40:17 and only for themselves Feb 06 19:40:20 right Feb 06 19:40:33 The method getParent() is undefined for the type new View.OnClickListener() {} Feb 06 19:40:35 I can't get my parent tab, it says Feb 06 19:40:48 thanks p_l|backup Feb 06 19:40:49 there are some "security" applications that try and use various tricks to enforce it, but it's definitely not supported Feb 06 19:40:51 what's just before Feb 06 19:41:13 Thoughts on this machine for Android dev with Ubuntu? Feb 06 19:41:14 http://www.newegg.com/Product/Product.aspx?Item=N82E16834230142 Feb 06 19:41:19 Might just go for it. Feb 06 19:41:26 hey guys Feb 06 19:41:31 what exactly is considered silicon valley Feb 06 19:41:38 oh, can it be true? mobilism.org is gone? yes!! Feb 06 19:42:00 RobinB: what was mobilism.org? Feb 06 19:42:08 pirate bay for mobile apps Feb 06 19:42:23 jfisk1987: the south end of the San Francisco bay, generally Feb 06 19:42:25 good now u cant pirate my apps Feb 06 19:42:26 RobinB: nice! Feb 06 19:43:19 RobinB: Works fine here? :F Feb 06 19:43:23 evancharlton: yeah, it was a big hassle to shoot down pirated copies from there. but i guess some knock-off will appear within days Feb 06 19:43:24 really? damn Feb 06 19:43:29 i still pirate yo apps :3 Feb 06 19:43:37 * RobinB slaps storkme around a bit with a large trout Feb 06 19:44:10 VonRath: Might be nice to get something with SSD, otherwise it seems fine Feb 06 19:44:35 Hi everybody, i have a question, i need to know the Width and height of my layout BUT without the heigh of the title bar etc .. How to get this ? Or did some one know how many pixel did the title bar use ? now i am using it : Feb 06 19:44:36 DisplayMetrics metrics = new DisplayMetrics(); getWindowManager().getDefaultDisplay().getMetrics(metrics); return metrics.widthPixels; Feb 06 19:45:11 cyber37: there are a ton of StackOverflow questions on this Feb 06 19:45:23 hum Feb 06 19:45:28 I suggest you search there; it should be in the first few results Feb 06 19:45:30 i have bad english, Feb 06 19:45:32 ok Feb 06 19:45:33 getResources().getDisplayMetrics() Feb 06 19:45:34 RobinB: mobilism.org loads just fine here Feb 06 19:45:41 usually easier to get a context than a window mananger Feb 06 19:46:07 i went to a mobile web development conference called mobilism, i wonder if they're relatewd Feb 06 19:46:09 canadiancow|work: ... you can get a window manager from a context, too Feb 06 19:46:19 http://mobilism.nl/ Feb 06 19:46:24 orly Feb 06 19:46:31 canadiancow|work: context.getSystemService(Context.WINDOW_SERVICE) or whatever the constant i Feb 06 19:46:31 well theres some reason i prefer my way over the other Feb 06 19:46:34 is* Feb 06 19:46:45 storkme: looks very different though Feb 06 19:47:01 Yeah, a lot less warez there, storkme :p Feb 06 19:47:02 i also dont really like the whole create an object, then pass it in, and it comes out filled Feb 06 19:47:09 when i can just getDisplayMetrics() Feb 06 19:47:20 maybe it's just my isp blocking mobilism org, or something Feb 06 19:47:35 RobinB: it took a while to load Feb 06 19:48:15 ah yeah, now loading again here. darn. Feb 06 19:50:07 And now you just told the whole world where you get free apps :( Feb 06 19:51:01 s/you/to Feb 06 19:51:26 thanks br0, this is gonna save me so much money Feb 06 19:51:48 evancharlton: :P Feb 06 19:52:01 as if they didn't know Feb 06 19:52:19 ^_^ Feb 06 19:52:27 devs should know anyhow. feels weird to be on the other side though, and send out DMCAs Feb 06 19:55:01 I'm trying to put in a string in my intent uri that launches my app, but it doesnt look like its launching the intent as id expect it to Feb 06 19:56:05 'Fetching children of Indigo' … okay Feb 06 19:59:35 now that my class is in its own file, this doesn't work anymore: "DictTabActivity ParentActivity = (DictTabActivity) getParent();" ? Does someone know how to rewrite it, I tried from v, but unsuccessfully Feb 06 20:00:44 maxagaz: we hate playing guess and check. Put some of your source into pastebin.com and send us the link. Feb 06 20:01:45 is getParent() static? Did you import your class? Feb 06 20:02:56 i dont find how to get the pixel size with title bar size :s Feb 06 20:06:22 evancharlton: http://pastebin.com/FhxDMYxi Feb 06 20:08:03 evancharlton, aww come on its like a puzzle. psychic troubleshooting is a hobby of mine :-) Feb 06 20:08:41 andy_: I didn't write the getParent(), the class is woking fine except from this Feb 06 20:11:18 maxagaz: I assume your class is extending from activity... in that case getParent() is _not_ static, that means you need to instanciate you class first... but that will obviously not gonna work since it is an activity... Feb 06 20:12:08 https://plus.google.com/108967384991768947849/posts/DcsFABkyuYM <--- wat Feb 06 20:12:13 suddenly, so much gets easier Feb 06 20:12:26 andy_: so, what should I do ? Feb 06 20:12:31 Hi guys, I am doing some test driven android development. I have made a custom class extending Application and a custom class extending Activity. My application class has 2 methods getApplicationFactory() and setApplicationFactory. In my ActivityTest class I would like to inject a custom application factory before the Activity is started. Feb 06 20:12:41 p_l|backup: old news :p Feb 06 20:12:45 When I call getActivity the activity is started, but I need to call it to call the getApplication method, to inject a new applicationFactory. Feb 06 20:12:59 SimonVT: I missed that Feb 06 20:13:02 Does my problem make sense to any of you guys, or do I need to elaborate? Feb 06 20:13:04 But yea, it's nice Feb 06 20:13:27 I use it for exactly the same as in the example Feb 06 20:13:46 how to get the screen width without the TITLE BAR SIZE ? Feb 06 20:14:03 or what is the size of title bar pleaze ? Feb 06 20:14:06 "RIM woos developers with free tablet" , too funny Feb 06 20:14:55 g00s, i need to submit my app to that Feb 06 20:14:56 lol Feb 06 20:15:07 I thought the deadline passed already Feb 06 20:15:11 for two reasons: 1. if it works, hten it increases my market, and 2. free tablet! Feb 06 20:15:12 nawwww Feb 06 20:15:13 I signed up, waiting for them to create my account Feb 06 20:15:14 it just started Feb 06 20:16:20 maxagaz: depends on what you intent to do? why do you need the instance of an activity thats not running? Feb 06 20:16:43 andy_: the activity is running Feb 06 20:18:19 maxagaz: so you are running getParent from running activity? then I dont know. what kind of exception you get, classcast exception? Feb 06 20:19:03 pfn: feb 13 Feb 06 20:19:26 oh Feb 06 20:19:27 not bad Feb 06 20:19:29 andy_: I have this error messsage : The method getParent() is undefined for the type new View.OnClickListener() Feb 06 20:20:59 maxagaz: Uhm... thne you nested a class inside you class. you can define a local function that you are calling inside you onclicklistener and run getParent inside of it. Feb 06 20:21:24 maxagaz, of course, getParent isn't a method on View.OnClickListener Feb 06 20:22:02 andy_: this class used to be nested in another class and it worked like this, it doesn't work since this nested class is in its own class file Feb 06 20:23:46 dunno, but you seem done more than that. without code I can Feb 06 20:23:51 'not tell you more Feb 06 20:24:13 andy_: my goal is to switch tab, I used to do this : "DictTabActivity ParentActivity = (DictTabActivity) getParent(); ParentActivity.tabHost.setCurrentTab(1);" which worked before Feb 06 20:24:53 Don't suppose anyone have a ready-made app which simply prints stuff like dpi, screen size, etc? Feb 06 20:25:16 maxagaz, need to learn a bit more java... Feb 06 20:25:57 pfn: I'm trying too Feb 06 20:26:26 maxagaz, probably a good idea to get thinking-in-java (a book) Feb 06 20:26:48 maxagaz, http://www.mindview.net/Books/TIJ/ Feb 06 20:27:24 maxagaz, that's probably a good book for an android developer to read Feb 06 20:29:21 buy, download, read, whatever Feb 06 20:30:11 pfn: thanks for this suggestion Feb 06 20:30:17 is it possible to force multiline in javadoc? Say i return a cursor with 3 fields and i want it to show them underneath eachother Feb 06 20:30:34 xorgate: use HTML Feb 06 20:30:34 How can I scale a background resource in code? Feb 06 20:30:38


etc Feb 06 20:30:43 romainguy ok cool thanks Feb 06 20:31:12 romainguy, so... is there any plan to ever help hide the systemui bar on tablets? gesture-based or whatever Feb 06 20:31:49 pfn: it's needed to access the home button Feb 06 20:32:18 romainguy, I know, but there needs to be some way of hiding the bar Feb 06 20:32:25 romainguy, via power menu or whatever Feb 06 20:32:35 "needs"? Feb 06 20:33:04 pfn: certain apps (system-signed?) can already do it. See Gallery, for example. Feb 06 20:33:15 evancharlton: only for video I believe Feb 06 20:33:21 romainguy, I agree. Nextflix app on CM 7 at least used to do it. Hides it when it starts playing Feb 06 20:33:23 romainguy, http://code.google.com/p/android/issues/detail?id=15408 Feb 06 20:33:28 romainguy, you closed that workingasintended Feb 06 20:33:33 romainguy, but the comments continue to flow in Feb 06 20:33:43 doesn't google video hide those buttons? Feb 06 20:33:51 romainguy: yeah Feb 06 20:34:11 YouTube can also do it Feb 06 20:34:23 youtube uses lightsoutmode Feb 06 20:34:25 which is different Feb 06 20:34:26 Any app can do it Feb 06 20:34:26 and crappy Feb 06 20:34:29 also would be nice to have a lock button to disable pop-up if clicked anywhere on the screen Feb 06 20:34:35 it's mega crappy Feb 06 20:34:47 all it does is black out the bar Feb 06 20:34:54 enable of the bar... Feb 06 20:34:57 it doesn't actually allow you to use the ~40 pixels of wasted space Feb 06 20:35:06 There's another flag for removing it Feb 06 20:35:08 pfn: no, it goes full screen on my GN Feb 06 20:35:10 But buttons are still accessible Feb 06 20:35:11 How can I scale a background resource? Feb 06 20:35:13 evancharlton, that's a phone Feb 06 20:35:16 evancharlton, not a tablet Feb 06 20:35:17 pfn: so? Feb 06 20:35:19 ahoy, does anyone know where I could have read about the "use task-killers argumentation"? iirc it was here Feb 06 20:35:27 s.o. posted a link to some blog, but i don't find it Feb 06 20:35:28 evancharlton, the ICS release notes specifically say it's a *phone only* feature Feb 06 20:35:36 pfn: ah Feb 06 20:35:48 oh Feb 06 20:36:04 didn't realize it was specifically phone-only Feb 06 20:36:16 evancharlton: it's for 720p videos Feb 06 20:36:19 that's an interesting design choice Feb 06 20:36:21 on the phone the screen is 720p Feb 06 20:36:24 so the bar needs to go away Feb 06 20:36:36 on a 1280x800 tablet you have room for both a 720p video *and* the system bar Feb 06 20:36:43 what if your tablet is 1280x720? Feb 06 20:36:52 or 1920x1080 Feb 06 20:36:58 romainguy, it's not just that, but the buttons are also easily activated accidentally Feb 06 20:37:01 or [insert common video resolution] Feb 06 20:37:15 romainguy, but what if I want to hide it? There is nothing in API to hide it on tablets? Feb 06 20:37:15 romainguy, e.g. see all the comments about keyboard usage, or video games Feb 06 20:37:21 xbb, you have lights out mode Feb 06 20:37:25 xbb: only the lights out mode Feb 06 20:37:27 romainguy: I guess that makes sense for 720p, but what if it's not 1280x720 (like a 4x3 video?) Feb 06 20:37:42 lights out? Feb 06 20:37:44 anyway, I haven't found it to be a serious problem on tablet Feb 06 20:37:52 evancharlton, http://developer.android.com/sdk/android-4.0.html Feb 06 20:38:00 evancharlton: well the screen won't change size/resolution so… Feb 06 20:38:10 evancharlton, controls for system ui visibility Feb 06 20:38:14 evancharlton: at least you can get 720p videos without black bars and full screen Feb 06 20:38:21 evancharlton, I find it a problem that annoys me daily when I use my tablet Feb 06 20:38:40 * pfn wrote an app to hide the bar even... Feb 06 20:38:49 but it's rendered ineffective on ICS Feb 06 20:39:28 since ics blocks the killing of system/persistent processes Feb 06 20:39:56 not to mention, my app causes drawing slowness because it uses a transparent overlay... Feb 06 20:40:36 tested blackberry app conversion, looks like junk :( Feb 06 20:41:01 of course, it''s blackberry Feb 06 20:41:04 pfn: this book is more than 1000 pages... Feb 06 20:41:07 dunivan, got screenshots of before and after? Feb 06 20:41:13 maxagaz, go get started reading Feb 06 20:41:20 if I have images in the hd res folder, say 128 x 128, will they scale accordingly for md and ld? Feb 06 20:41:25 maxagaz, seriously, you'll be a much better android developer for it Feb 06 20:41:31 pfn: but it looks good indeed Feb 06 20:41:34 what book pfn Feb 06 20:41:43 dunivan, thinking in java by bruce eckel Feb 06 20:42:07 that a good intro to advanced book? Feb 06 20:42:14 dunivan, yes Feb 06 20:42:20 pfn: before that, I'll try to put the setOnClickListener only in the previous activity file... Feb 06 20:42:21 it's an overall good java book Feb 06 20:42:31 awesome Feb 06 20:42:34 ill check that out Feb 06 20:42:40 dunivan, and it's available in soft-copy Feb 06 20:42:54 3e, doesn't have java5 features, but those you can pickup pretty easily after reading 3e Feb 06 20:42:58 yeah, i found a google code pdf Feb 06 20:43:15 i'll put it on my ipad and take a read Feb 06 20:43:56 covers all the major topics minus UI... which is perfect for android developers Feb 06 20:44:09 pfn, romainguy this app https://market.android.com/details?id=com.mxtech.videoplayer.ad&hl=en has lock button that will prevent bar from showing up unless lock button is pressed. This is good when kids use tablet. Feb 06 20:44:28 can anyone help with that @drawables question? Feb 06 20:44:40 I guess they did it themselves (?) but would be nice to have it as part of API Feb 06 20:45:51 xbb, eh? does it actually remove the bar, or just block input to the bar Feb 06 20:46:25 blocks input. I creates a small square in the top left corner, so you have to press that. Feb 06 20:46:31 I/it Feb 06 20:46:54 xbb, yeah, I know about that... it doesn't actually make it go away so you can use the bottom 1/3" of the screen Feb 06 20:48:03 right, but I am saying that at least that is good to prevent kids from clicking on the bottom 1/3 and getting lost in the desktop. Feb 06 20:48:17 I guess that's an option.... not so great, though Feb 06 20:48:43 https://market.android.com/details?id=com.hanhuy.android.hsbm Feb 06 20:48:46 I wrote this Feb 06 20:48:50 but it doesn't work on ics :-/ Feb 06 20:49:04 and because it's compositing a transparent view, it slows down drawing sometimes Feb 06 20:49:08 (e.g. swiping the launcher) Feb 06 20:49:40 i see Feb 06 20:50:29 pfn: you're adding an extra layer to the compositor, which will make it fall out of the optimized path in some situations Feb 06 20:50:36 (more than 4 layers on screen) Feb 06 20:50:38 Is there reason why bar is not hidden on tablets other than available space? Feb 06 20:50:51 romainguy, I know... the app is worthless after ics anyway :-/ Feb 06 20:51:26 so I'm not even bothering to fix it until I can find some scheme that might work on ics, but it's looking nigh impossible, since killing the systemui process is locked up tight now :( Feb 06 20:52:48 romainguy, is there any way to add a transparent view that doesn't need to be composited? Feb 06 20:52:57 no Feb 06 20:52:59 that's one thing I was wondering about Feb 06 20:54:27 hmm, can a GLSurfaceView be placed in a GestureOverlayView without obstructing button presses of a FrameLayout that is atop said GLSurfaceView? Feb 06 20:55:14 romainguy, another reason for wanting to hide the bar would be for kiosk, preso, or demo modes Feb 06 20:55:32 romainguy, e.g. I got an email from some indian firm that wanted me to add a pin-lock entry to my hider app Feb 06 20:55:37 hey james541, the send email failure was in fact the firewall. At home everything worked. Feb 06 20:55:45 so that they could use the device in kiosk mode without worrying about users escaping back to the home screen Feb 06 20:56:07 pfn: you'd just write your app as a launcher, then Feb 06 20:56:07 Aha! There is a need for this. Feb 06 20:56:18 evancharlton, that doesn't really work Feb 06 20:56:18 evancharlton: or modify the system Feb 06 20:56:23 romainguy: yeah Feb 06 20:56:32 romainguy, modifying the system is not exactly an easy endeavor Feb 06 20:56:58 they could just a duct tape on the screen :) Feb 06 20:57:03 +use Feb 06 20:57:07 evancharlton, using a launcher doesn't hide the bar or prevent the bar from activating Feb 06 20:57:24 Will Android support multi-user environment in the future? Feb 06 20:57:24 pfn: but the user couldn't escape, other than by going through settings I suppose Feb 06 20:57:42 like multiple accounts per device Feb 06 20:57:45 ahh Feb 06 20:58:11 xbb: It would be nice, especially for tablets Feb 06 20:58:21 it would be a nice feature to have Feb 06 20:58:22 xbb: good to know :) Feb 06 20:58:25 but I'm not holding my breath for it Feb 06 20:58:27 good to be right sometimes Feb 06 20:58:27 especially for tablets Feb 06 20:58:31 I had a feeling Feb 06 20:58:42 james541, heh :) Feb 06 20:59:10 hey how can I create an API key only for testing porpuses, I need one for google map Feb 06 21:00:09 djx: google maps on android? you have one already Feb 06 21:00:37 andy_ it's for that tutorial http://developer.android.com/resources/tutorials/views/hello-mapview.html Feb 06 21:01:33 djx: did you read the passage about Obtaining a Maps API Key? Feb 06 21:02:13 andy_ but it's necessary only for testing porpuses? Feb 06 21:02:15 general question. if you were a mobile developer, what do you think is more important : (1) knowing more than one mobile platform or (2) being able to do the server side of things also. i'm trying to plan learning a new os or maybe shifting to server side things Feb 06 21:02:26 djx: yes, it is. Feb 06 21:02:27 g00s, #1 Feb 06 21:02:32 g00s, both of that Feb 06 21:02:51 g00s, server side is unimportant as a mobile developer... unless you /want/ to be doing server-side things Feb 06 21:02:54 andy_ can I create many keys as I want? Feb 06 21:03:02 g00s, or you are gonna be a 1-man consulting shop Feb 06 21:03:19 i wonder how often mobile devs are asked to do the whole stack Feb 06 21:03:37 g00s, in a job, rarely... unless you're at a really really early-phase startup Feb 06 21:03:40 g00s, not that often, however I do get offers where I have to build whole solution Feb 06 21:03:45 g00s: that is what I'm going right now (whole stack + iOS) Feb 06 21:03:46 or you're hired by some mom&pop shop Feb 06 21:03:53 *doing Feb 06 21:04:00 djx: dunno, read the terms of service: http://code.google.com/android/maps-api-signup.html Feb 06 21:04:03 g00s, pretty much depends on where you work - if you're a freelancer taking projects then you're gonna be doing whole stack more often Feb 06 21:04:17 pfn: Mavrik : ok, thanks Feb 06 21:04:22 if you're working in a cubicle farm, then you probably won't touch other peoples work Feb 06 21:04:32 it really depends on your end-goal Feb 06 21:04:32 maybe i should just become a farmer and grow corn Feb 06 21:04:39 I haven't seen as much "cross-platform" projects though, people usually ask iOS first and ANdroid second Feb 06 21:04:39 g00s: and anecdotally it seems teams either have ppl do whole stack or have 2-3 guys do the various chunks of the stack in-house (iOS, Droid, Web dev) Feb 06 21:04:46 g00s, but corn subsidies are over, good luck :p Feb 06 21:04:53 g00s, now you need to expand your crops to something else Feb 06 21:04:56 yeah, what james541 said Feb 06 21:04:58 * g00s sighs, no free lunch Feb 06 21:05:14 ok ok, I've other question, I saw that the API version is already on 15, so how do I know that an app I create with that API will work with android 1.5 for example? Feb 06 21:05:22 even though, if you're a developer worth something, being able to do all of that shouldn't pose much of a problem Feb 06 21:05:24 djx, you test on android 1.5 Feb 06 21:05:33 djx: set the min SDK number in the AndroidManifest.xml Feb 06 21:05:54 james541, the question is how to know setting the min sdk version will be ok :p Feb 06 21:06:05 pfn yes! lol Feb 06 21:06:09 ahh misunderstood Feb 06 21:06:14 what pfn said then Feb 06 21:06:22 djx, the basic answer is that you don't know, until you test Feb 06 21:06:23 pfn I need to test it all the androids? Feb 06 21:06:27 along djx question, I see that NumberPicker is available in android 3.x. However, I am developing for 2.x . This means I cannot use those methods, correct? I'll have to create my own? Feb 06 21:06:37 djx, depends on the app Feb 06 21:07:07 Mavrik: yeah, but knowing iOS and android well enough to be hirable is a formidable challenge, i think Feb 06 21:07:10 Is there a way to force an EditText to scroll instead of enlarging its size? Feb 06 21:07:27 pfn, i don't know if you're a developer, but you code with API 15? Feb 06 21:07:27 and then windows phone 8, sigh Feb 06 21:07:50 g00s, as I said, depends on what do you really do Feb 06 21:08:00 g00s, knowig all platforms in depth is hard Feb 06 21:08:12 knowing enough so you can develop an app on any of those... not so much Feb 06 21:08:14 hansvg: short answere yes, long answere: there's a very very very dirty hack. better you develop you own version and check for android >= 3 for native numberpicker Feb 06 21:08:22 actually MS has a tool to help porting from iOS -> win phone, but I guess that is OT here Feb 06 21:08:29 don't know how good it is though Feb 06 21:08:36 andy_: Thanks. Will do Feb 06 21:08:43 james541: i would be skeptical of anything like that Feb 06 21:09:00 agreed, but it might be a way to feel your way around the SDK Feb 06 21:09:01 the really annoying thing is figuring out good UX for each platform :) Feb 06 21:09:11 I would never accept an autotranslation blindly Feb 06 21:09:28 yes*10 @ Mavrik Feb 06 21:10:48 fuck, I hate this office building all the toilet stalls are always occupied Feb 06 21:11:18 anyone know scrolling for EditText? Feb 06 21:11:22 how do i know when my app has lost foreground? Feb 06 21:11:49 Is there a way to force 2 action bars? I.e. one on top and one on the bottom? It sounds like split action bars only do it when there's overflow items Feb 06 21:12:02 not when a particular activity has since i may just be navigating to another one of my app's activities Feb 06 21:12:07 jasonmog, onpause and onstop Feb 06 21:12:26 jasonmog: also activity lifecycle Feb 06 21:12:35 those only tell me when a particular activity has lost foreground Feb 06 21:12:44 shurane: split action bar is there whenever you have menuitems Feb 06 21:13:17 zerkz: just put it into a scrollview Feb 06 21:13:49 i want to close a bluetooth connection when my app is not in the foreground Feb 06 21:13:54 SimonVT: I know. I was wondering if there's just a way to have two action bars consistently. Feb 06 21:14:12 hey guys, what kind of value do you have to give to Location.setBearing(), 0-360 or -180->180 Feb 06 21:14:41 shurane: So you want it even if its empty? oO Feb 06 21:14:45 jasonmog: just a suggestion: you can share an instance with methods across objects that can be called from onPause and onStop, but that's all I can think of. Feb 06 21:15:09 :\ Feb 06 21:15:16 SimonVT: rather, i'm going to populate the second bar with results based on selection Feb 06 21:15:34 SimonVT: for example, inside a webview. Feb 06 21:15:55 jasonmog: keep a service and each activity calls an increment on start and decrement on pause? Feb 06 21:15:58 Ah, well.. I don't know :F Feb 06 21:16:09 jasonmog: if 0 for X seconds, terminate the BT conn in the service Feb 06 21:16:20 it can't be that involved. google makes better conventions Feb 06 21:16:47 surely there is something i can override in my application subclass Feb 06 21:16:55 or add a listener to something Feb 06 21:17:45 SimonVT: I guess what would be more approriate is I want something like the ad overlay (but more action-bar-y) that every other free app has. Feb 06 21:18:08 I used a method to encode a YUV image to RGB .. Now I have my pixels in an int[] ... How can check if each pixel is less than a certain threshold ? Feb 06 21:18:19 use a singleton true in onresume false in onpause and not foreground in onstop Feb 06 21:18:21 shurane: Well, custom view then I guess. The split actionbar is only there when you have menu items ;O Feb 06 21:18:39 If false in onsfop then kill Feb 06 21:18:53 thanks Feb 06 21:20:00 hey, after using keytool and put it on the google page, it says the key isn't valid :S Feb 06 21:20:47 djx, then read to see why it isn't valid Feb 06 21:21:09 pfn, read what? only says that xD Feb 06 21:21:39 no idea what you're referencing Feb 06 21:21:57 I need to go to this page right? Feb 06 21:21:59 http://code.google.com/intl/pt/android/maps-api-signup.html Feb 06 21:22:21 and put the key resulting from this command right? Feb 06 21:22:23 keytool -list -alias androiddebugkey -keystore ~/.android/debug.keystore -storepass android -keypass android Feb 06 21:22:46 djx, and what did you enter? Feb 06 21:22:49 http://pastebin.com/HuB96q0r Is there any reason why the bearing changes hardly ever Feb 06 21:23:03 the SHA1 key gerated Feb 06 21:23:07 androiddebugkey, 5/Fev/2012, PrivateKeyEntry, Feb 06 21:23:20 djx, did you read the page to see what it asked? Feb 06 21:23:32 omg... Feb 06 21:23:43 i hope developers keep blindly submitting their apps Feb 06 21:23:56 because it really messes up my phone :( Feb 06 21:24:10 coughcough Google coughcough Feb 06 21:24:16 hey it's generating sha1 and not md5? :S Feb 06 21:24:29 djx, are you using java7? Feb 06 21:24:37 pfn yes Feb 06 21:24:41 don't Feb 06 21:25:03 java7 is not suitable for android development Feb 06 21:25:07 why? google doesn't support it yet? Feb 06 21:25:16 oh tks for the advice ;) Feb 06 21:25:20 pretty much Feb 06 21:25:45 can i use an APK to fix a non working app? Feb 06 21:25:53 no Feb 06 21:28:06 can i disable an app from backgrounding? Feb 06 21:28:14 no Feb 06 21:28:18 just kill on home? Feb 06 21:28:44 @Override public void onPause() { /* lol don't call super */ } Feb 06 21:28:45 boom Feb 06 21:29:02 note: that's a pretty stupid idea :) Feb 06 21:29:04 why don't you just set true in onResume, false in onPause, check t/f in onStop, if false, close your connection Feb 06 21:29:14 set it on a singleton Feb 06 21:30:57 evancharlton: Doesn't the framework check that? Feb 06 21:31:06 If super is called Feb 06 21:31:07 SimonVT, yeah, you get a force-close Feb 06 21:31:14 I know it does for Fragments Feb 06 21:31:23 that's why "boom" Feb 06 21:31:31 alrighty then :p Feb 06 21:34:42 SimonVT: yeah, one way to ensure you're never running in the background is to crash :P Feb 06 21:34:54 ah :p Feb 06 21:39:52 how do I scale a background image? Feb 06 21:43:37 how do i finish all activitiies, including the root, at once? Feb 06 21:49:04 much easier to just finish all of my activities rather than keep the app running and enable/disable logic as the app toggles foreground Feb 06 21:50:26 jasonmog, you don't... you can start subsequent activities with start for result Feb 06 21:50:32 jasonmog, and if the result is finish activity, do so Feb 06 21:50:53 we'll see about that Feb 06 21:51:19 although, flagging in onpause/resume and checking in onstop is pretty simple Feb 06 21:51:44 Excuse me, can I have a View with an addView method? Feb 06 21:51:50 using startForResult is more functional... Feb 06 21:52:02 NicholasRoge, if it's a ViewGroup Feb 06 21:52:17 I don't need a ViewGroup though, is the problem. Feb 06 21:52:48 Because I'm not /actually/ adding the views to it. Only making a list of children that should be associated with it. Feb 06 21:53:21 make your own View that supports addView Feb 06 21:53:22 The views actually get added to a "super viewgroup". Feb 06 21:53:48 But if I just add a method called addView to a View object, will it get called when adding something to it in the XML? Feb 06 21:53:59 probably not, unless it's a viewgroup Feb 06 21:54:00 no Feb 06 21:54:02 does any one know of a good linux-native android rom-flashing utility like odin ? Feb 06 21:54:13 Faris, fastboot Feb 06 21:54:16 I didn't think so. Feb 06 21:54:36 pfn: does it support Samsung Galaxy ? Feb 06 21:55:00 Faris, if the sgs supports fastboot, yes Feb 06 21:55:16 :) Feb 06 21:55:16 "Senior/Lead/Extra-Badass Developer at xxx" … sounds legit Feb 06 21:55:17 Hey, im compiling 2.3.7 for the huawei s7, i made some changes here and there, but suddenly it stopped spitting out the boot.img , and the build process said nothing about that Feb 06 21:55:41 anyone know what could cause that? Feb 06 21:55:43 threader: try #android-root Feb 06 21:55:49 k thanks Feb 06 21:55:52 this is for app dev using the sdk Feb 06 21:55:56 aah Feb 06 21:56:10 ahh, indeed Feb 06 21:56:14 how do i get the instance of the activity that started the current one with startActivity()? Feb 06 21:56:22 you dont Feb 06 21:56:26 and you dont want to Feb 06 21:57:17 JakeWharton: Did this lead to anything? https://gist.github.com/1108374 Feb 06 22:03:16 has anyone here ever used Heimdall ? Feb 06 22:03:30 if so would u recommend it for a Samsung i5500 Feb 06 22:03:30 ? Feb 06 22:07:33 adblock or adblock plus(beta) for chrome ? Feb 06 22:07:37 :/ Feb 06 22:08:56 abp Feb 06 22:09:43 adblock plus deluxe extreme Feb 06 22:10:45 wasn't there some controversy where abp started letting adds through ? Feb 06 22:11:03 (if they paid the dev enough ;) Feb 06 22:11:23 haven't really heard about it Feb 06 22:11:48 although I guess I saw something about "reasonable ads" Feb 06 22:12:10 im really tempted to block access to my website if you have an ad blocker Feb 06 22:13:19 ... seems legit Feb 06 22:13:20 adds start reasonably Feb 06 22:13:29 but almost always become unreasonable Feb 06 22:15:04 When it got to the point where I had to actually scroll down before being able to view a websites content, I started blocking Feb 06 22:16:01 SimonVT: reminds me of various "portals", which unfortunately are still major news outlets, which are completely unviewable without an adblocker Feb 06 22:16:48 Also those flash ads with sound and shit Feb 06 22:16:49 fuck off Feb 06 22:17:04 we had the phoenix open here the other day … and they had those trucks driving around with advertisements scrolling on all sides Feb 06 22:17:22 what a pile of crap. do they want us to drive or crash >? Feb 06 22:18:16 its always a battle, inevitably advertisers seem to cross the line Feb 06 22:18:31 i can count the times i have clicked on an ad, with intent to learn more about the thing advertised on one hand Feb 06 22:19:06 i needn't even use 1 hand. Feb 06 22:19:08 ads are a necessary evil if whoever owns the website has no other channel of revenue Feb 06 22:19:23 so it was a pron ad then jasta ? ;) Feb 06 22:19:56 storkme: they are not evil :( Feb 06 22:19:56 i was truly amazed when we first implemented adsense into our forum Feb 06 22:20:04 earned us 100 bucks in two weeks Feb 06 22:20:18 my ads dont even cover my server costs Feb 06 22:20:18 after that it was down to 10 bucks Feb 06 22:20:31 the admarket wants new sites to bid on apparently Feb 06 22:21:26 Probably a stupied question but I'm tryin got get a grip on fragments. In my preference activity I'm overriding onPreferenceStartFragment in order to "start" another Fragment. How is that done? I instantiate the fragment, add it to a FragmentTransaction and commit. But doesn't seem to be correct. Feb 06 22:21:27 canadiancow|work: so why even bother Feb 06 22:21:34 well it comes close :P Feb 06 22:21:47 $50 out of pocket, fine Feb 06 22:21:49 $300, fuck off Feb 06 22:21:51 I have seen good ads. I sometimes click on the ads. But I never click on the offensive, screaming shit Feb 06 22:22:06 i was getting £300 a week on ads at one point, but that was only because i had no other way of paying for a very expensive application Feb 06 22:22:12 the best stuff could technically be implemented without JS, even Feb 06 22:22:34 i use adblock by default, enabling it selectively ... i am a bad person i guess? Feb 06 22:22:47 people who show ads are bad people Feb 06 22:22:50 300/wk on ads? Feb 06 22:22:55 that's pretty impressive Feb 06 22:22:57 yeah Feb 06 22:26:01 hello, I'm having a problem with some rendering on a surface view and the layouts that should appear on top of it: everything gets drawn normally as excpected except that my linearlayout containing a text view is being hidden for some reason behind the surface view and thus not displayed (the LL has been declared after the SV) Feb 06 22:26:28 this is a layout currently being used on a custom dialog Feb 06 22:26:50 Is there no way to draw a Bitmap to a Canvas and specify the width on screen without using a Rect? Feb 06 22:36:37 why would you not want to use a rect] Feb 06 22:42:41 aright so i've got an activity in a tabhost with 4 tabs. the i need to send a message of some kind containing an int to a tab in the tabhost from another tab, and the intent may not have fired off in the other tab as of yet, so it may not be running.... Feb 06 22:44:06 Jygga, what kind of traffic are you seeing on average per week? Feb 06 22:45:35 zomg no doubles Feb 06 22:45:43 sharedpreferences Feb 06 22:49:18 moonlightcheese 2kunique20k hits'ish didnt even log into analytics for months Feb 06 22:50:04 jasonmog: the shared preference stuff is pretty ghetto Feb 06 22:50:34 you'll have to store it as 3 ints Feb 06 22:50:46 in teh ghettooo Feb 06 22:51:00 Storing with String.valueOf(wut) doesn't work? Feb 06 22:51:08 doubles are lame Feb 06 22:51:13 alankila: doing that Feb 06 22:51:18 kill the doubles ! Feb 06 22:51:20 round to ints Feb 06 22:51:23 Hey JakeWharton :) Feb 06 22:51:24 do you have to have default constructors on fragments when working with the compatibility library? It seems that the compat lib is trying to reflectively instantiate my fragment and failing as it doesn't have a default constructor... but it needn't have one Feb 06 22:51:27 what's the worst that could happen Feb 06 22:51:34 hello thar SimonVT Feb 06 22:51:46 abaratican: you need em. context, int Feb 06 22:51:52 or context, attributeset Feb 06 22:52:00 jasonmog: that's not a default constructor. Feb 06 22:52:03 pakerfeldt, no. there's a version that uses reflection on xda-developers Feb 06 22:52:08 pakerfeldt, send me the link if you find it Feb 06 22:52:08 oh right Feb 06 22:52:11 how about not having constructors for fragments? the default should be OK, because android needs to be able to build those objects Feb 06 22:52:15 default in that sense of the word Feb 06 22:52:18 abaratican: yes, you need default constructors Feb 06 22:52:30 abaratican, you must have one Feb 06 22:52:31 JakeWharton: In hindsight, that overflow menu bug was kinda obvious, huh :p Feb 06 22:52:42 on honeycomb, usin gnative fragments, you don't.. but you do with compat? Feb 06 22:52:52 I have no idea how many times I've looked at it Feb 06 22:52:58 SimonVT, very much so. You stare at some code long enough and you just overlook things Feb 06 22:53:38 JakeWharton: You basically just need to fix styles now? Feb 06 22:54:01 yeah, which is just a tedious task Feb 06 22:54:09 http://digg.com/newsbar/topnews/as_apple_and_samsung_accelerate_htc_s_sales_fade_away Feb 06 22:54:11 i'm going to do the normal theme tonight and release another beta Feb 06 22:54:13 gah Feb 06 22:54:31 if all goes well i'll implement the other two themes in the coming days and then we can cut off a 4.0 final soon Feb 06 22:55:01 better http://gigaom.com/mobile/as-apple-and-samsung-accelerate-htcs-sales-fade-away/ Feb 06 22:55:28 digg Feb 06 22:55:29 ha Feb 06 22:55:29 Yeah, I can imagine Feb 06 22:55:37 JakeWharton: so this constraint of having a default constructor is due to using the compatibility library, right? because on honeycomb it works just fine without one. Feb 06 22:56:07 abaratican, i'd be surprised at that... native fragments differ very little from the support library implementation Feb 06 22:56:27 hmm actually i see the docs say you do in fact need a default ctor Feb 06 22:56:41 yet it seemed happy enough without it on hc.. alright, guess that answers that. Feb 06 22:57:02 Wait, what? Feb 06 22:57:14 You need a ctor in every Fragment? Feb 06 22:57:21 a default one, yes Feb 06 22:57:24 (or none at all) Feb 06 22:57:29 Oh, alright Feb 06 22:57:37 SimonVT: just one particular fragment i was using without the compatibility library had only one constructor, that took a class of mine Feb 06 22:57:48 SimonVT: then i had problems using compat, assumed it was a bug in compat Feb 06 22:57:55 but in fact it's just odd that id idnt have the problem before Feb 06 22:58:06 because the docs clearly say I must have one. =) Feb 06 22:58:10 Remember, abaratican. When the framework recreates the fragment, it only passes the arguments bundle Feb 06 22:58:12 simple fix. Feb 06 22:58:13 you should be using the static newInstance pattern Feb 06 22:58:18 SimonVT: yea, i see that doc now Feb 06 22:58:18 Not whatever stuff you passed in the constructor Feb 06 22:58:27 What JakeWharton said Feb 06 22:58:36 JakeWharton said what? Feb 06 22:58:49 canadiancow, BOTH YOUR BUGS ARE FIXED! Feb 06 22:58:56 fuck Feb 06 22:58:57 THAT'LL BE $34.82 Feb 06 22:58:59 that means i need to like Feb 06 22:59:00 do shit Feb 06 22:59:04 didn't know about newinstance either Feb 06 22:59:12 learned from bad example code it seems Feb 06 22:59:16 abaratican, it's just a convention Feb 06 22:59:20 at the ADL in Melbourne they screwed that up and did their own constructor. The next day in Sydney they had the static newInstance pattern ;) Feb 06 22:59:43 but still screwed it up and had crashes on gingerbread Feb 06 22:59:48 abaratican: Basically, newInstance which takes your arguments. new Fragment() in that, bundle arguments, setArguments, return fragment Feb 06 23:00:31 JakeWharton: dude, $34.82 for two bugs? Feb 06 23:00:46 in canadian Feb 06 23:00:47 for $17.41/bug, I'll gladly send all my bugs your way Feb 06 23:00:50 that's like $2.34 in real money Feb 06 23:01:01 SimonVT: yea, i just didn't know it even existed. :) Feb 06 23:01:07 thanks guys Feb 06 23:01:09 I'd pay for that out of pocket Feb 06 23:01:12 haha Feb 06 23:01:23 well they were fairly simple bugs, just needed some fresh eyes really Feb 06 23:01:31 "fresh" Feb 06 23:01:36 becuase i had totally tried to fix them myself Feb 06 23:01:42 iiiiin west philadelphia ... Feb 06 23:01:48 In an activity/remote service setup, does it make more sense to use Messenger+Parcellable or Intents+Bundles? Feb 06 23:02:20 canadiancow|work, i meant other than mine Feb 06 23:02:28 oh someone else fixed them? Feb 06 23:02:33 SimonVT, solved one Feb 06 23:02:42 You're welcome! Feb 06 23:03:00 I managed to solve the other after tracing a myriad of callbacks and abstractions related to action modes Feb 06 23:03:25 fuck stupid people are stupid Feb 06 23:03:28 i cant deal with this Feb 06 23:03:31 i need to start my own company Feb 06 23:03:33 and not hire anyone Feb 06 23:03:35 canadian cow is canadian Feb 06 23:03:40 and a cow Feb 06 23:03:44 yea Feb 06 23:03:45 totally Feb 06 23:03:52 Canuck Cows, LLC Feb 06 23:04:01 man i must have been drunk when i wrote this line Feb 06 23:04:13 it was basically: boolean xIsA = (x == a) || (some crazy other shit) Feb 06 23:04:30 nice variable name Feb 06 23:04:38 thanks JakeWharton Feb 06 23:04:42 knew you'd like it Feb 06 23:04:43 can't wait until someone changes that to (y == a) in the future :) Feb 06 23:04:48 LOL Feb 06 23:05:09 haha Feb 06 23:05:36 Easy fix for that, yIsB = x == b Feb 06 23:06:22 hi JakeWharton Feb 06 23:07:14 Thanks for your great libraries :) Feb 06 23:07:27 https://plus.google.com/108967384991768947849/posts/DcsFABkyuYM :o Feb 06 23:08:30 Xperimental, you're welcome. Keep an eye out for ActionBarSherlock v4 in the next week or two Feb 06 23:08:39 ooooh Feb 06 23:08:48 FragmentActivity extends MapActivity???? Feb 06 23:08:49 :( Feb 06 23:08:57 eh? Feb 06 23:08:59 wabz, implemented that as soon as I read it earlier on an app I use Feb 06 23:09:01 looking forward to it... Feb 06 23:09:04 canadiancow|work, i'll make you a one-off Feb 06 23:09:09 every time? Feb 06 23:09:16 err... every release? Feb 06 23:10:04 sed -i 's/extends Activity/extends MapActivity/g' path/to/FragmentActivity && mvn package && git reset --hard HEAD Feb 06 23:10:14 <3 Feb 06 23:10:15 i'll put that in a appease_the_cow.sh Feb 06 23:10:20 <3333 Feb 06 23:11:11 google will have something out eventually Feb 06 23:11:16 'twas alluded to Feb 06 23:11:54 I have a port of the open street map Android SDK to work with fragments you know... Feb 06 23:12:05 i'd consider that Feb 06 23:12:07 maybe Feb 06 23:12:08 MAYBE Feb 06 23:12:11 but for now Feb 06 23:12:13 im facking tired Feb 06 23:12:14 well it's from a year ago Feb 06 23:12:16 and going le home Feb 06 23:12:17 probably needs updated Feb 06 23:12:17 to have a nap Feb 06 23:12:20 THEN FIRE ZE MISSILES Feb 06 23:12:30 o/ Feb 06 23:12:32 Is it safe to just try-catch the "View not attached to window manager" exception that occurs when I rotate the device as Im trying to dismiss a dialog (splashscreen)? It seems to work fine, but it feels weird. Feb 06 23:13:36 I think you want to look into managed dialogs as it sounds like you're currently leaking them Feb 06 23:14:12 Well, I did not have this problem pre-ICS. I just saved the state when I rotate the device. In ICS, however, it doesnt work Feb 06 23:15:22 Are you using showDialog/dismissDialog like you should? Feb 06 23:15:54 or well, you should use dialogfragment, but in case you're not.. Feb 06 23:16:16 hello Feb 06 23:16:41 SimonVT: Well, I just call show() and dismiss() basically. Feb 06 23:17:01 SimonVT: Checking if the dialog is null and stuff also. Feb 06 23:17:05 That's doing it wrong Feb 06 23:17:56 As JakeWharton said, managed dialogs.. that means showDialog/dismissDialog Feb 06 23:17:56 SimonVT: Aha, they have updated the dev pages! Feb 06 23:18:19 Or, dialogfragment Feb 06 23:18:20 Before they basically wrote that you should use show() and dismiss(), like, some months ago. Feb 06 23:18:25 chip2n: You should probably call the dialog's dismiss() in the onPause method. Feb 06 23:18:36 Ill look into both, thanks alot! Feb 06 23:18:47 VonRath: Ye, thanks for the tip <3 Feb 06 23:18:59 * VonRath is late to the party. Feb 06 23:19:01 No, he shouldn't Feb 06 23:19:42 Does anyone have any tips on how to implement an escape timer -? Feb 06 23:20:10 wut Feb 06 23:20:12 I was thinking of alarm manager, but sure if that the right way to go... Feb 06 23:20:18 SimonVT: DialogFragment is for >11 only? Would be sweet to have my app compatible with gingerbread and lower also :> Feb 06 23:20:20 *not sure.. Feb 06 23:20:21 escape from what? Feb 06 23:20:30 hi, anyone experienced with drivers development :) ? Feb 06 23:20:34 chip2n: There's a fragment support package in the sdk Feb 06 23:20:35 SimonVT, spurious alarm alerts Feb 06 23:20:37 SimonVT: Did I miss something? Were you referring to me when you said "No, he shouldn't?" Feb 06 23:20:44 Yea, VonRath Feb 06 23:20:51 heh, alright. Feb 06 23:21:04 SimonVT, Im making an alarm app, the user needs some time to escape after they press the ARM button Feb 06 23:22:28 So i was wondering if anyone had any tutorial urls or pointers please Feb 06 23:23:46 LoL Feb 06 23:23:50 Eh, if you want to schedule something in the future, alarmmanager is probably fine Feb 06 23:24:13 Does anybody know any great/helpful beginner tutorials, I know the basics, but want some more knowledge in the field. Feb 06 23:24:35 SimonVT, thanks Feb 06 23:24:50 Syloq, read the book thinking in java Feb 06 23:26:39 the useful version of TiJ is not free though Feb 06 23:26:46 (the one from Java 5) Feb 06 23:26:48 Thanks pfn. Feb 06 23:27:04 I'll purchase if I have to. lol Feb 06 23:27:17 well, he has the free one online Feb 06 23:27:40 hmm, bad nick complete Feb 06 23:27:47 Slylingual, 3e is free, 4e is current Feb 06 23:27:56 but 3e is a perfect resource for the budding android developer Feb 06 23:27:59 im assuming by Bruce Eckel, correct? Feb 06 23:28:03 http://www.mindview.net/Books/TIJ/ Feb 06 23:28:05 it doesn't cover generics, but you can pick that up easily Feb 06 23:28:06 Slylingual, yes Feb 06 23:28:07 this is too old Feb 06 23:28:14 g00s, it doesn't matter Feb 06 23:28:24 it covers java 1.4 topics which are all still applicable Feb 06 23:28:39 Thanks pfn and g00s Feb 06 23:28:46 it just doesn't mention stuff like generics, and any 1.5+ specific apis Feb 06 23:28:53 I guess that includes new concurrency constructs Feb 06 23:28:55 yeah Feb 06 23:29:12 but seriously, if you know how to do concurrency basics without the java.util.concurrent stuff, using the latter is super easy Feb 06 23:30:41 JakeWharton: have you seen ron_frown lately ? Feb 06 23:31:16 Hi, what's a good class to use to make custom touch listeners? I want to touch different areas of the map to open their respective activity. Feb 06 23:32:11 hmm, I don't suppose I can use fastboot to dump a system image Feb 06 23:32:54 that would be handy.. Feb 06 23:33:35 g00s, he'll be in Feb 06 23:33:40 i talk to him on gchat mostly now Feb 06 23:33:52 pfn, use that nandroid backup thing? :F Feb 06 23:34:04 That dumps /system as an .img Feb 06 23:35:05 SimonVT, yeah, I know, I'm just too lazy to boot up cwm or something Feb 06 23:35:12 pfft :p Feb 06 23:35:19 speaking of lazy Feb 06 23:35:28 i don't feel like programming tonight Feb 06 23:35:37 so take a break and hit up some bars Feb 06 23:35:46 all my friends moved away Feb 06 23:35:54 and I don't like my work friends enough Feb 06 23:36:00 JakeWharton, you're moving soon anyway Feb 06 23:36:11 JakeWharton, make new friends in SF Feb 06 23:36:24 JakeWharton, any guess on where you want to live yet? Feb 06 23:36:30 forever alone ;O Feb 06 23:36:34 heh Feb 06 23:36:52 have some applications into a few places downtown Feb 06 23:36:58 if there was hockey i'd go out alone Feb 06 23:37:09 but alas, no hockey tonight Feb 06 23:40:32 Hockey? You canadian? Feb 06 23:40:58 <-- Canuck Feb 06 23:41:22 My condolences Feb 06 23:41:35 ;o Feb 06 23:41:38 My App won't set default Preference values. I use PreferenceManager.setDefaultValues in the onCreate method of the main activity still the preference is not set properly. Feb 06 23:42:02 The onSetInitialValue method is also not called ever unless I use persistInt() first. Feb 06 23:42:23 I can't set up the default content of preferences right after install. Feb 06 23:46:40 haha Feb 06 23:47:26 JakeWharton: hi, I sent you a pull request for 9OA Feb 06 23:48:18 I have a couple more things brewing - I implemented the optimized invalidate in AnimatorProxy, although been annoyed by some weird behavior of matrix transforms Feb 06 23:49:10 fpillet, oh! yeah I saw it this morning or whenever it was Feb 06 23:49:16 i'll get it pulled and a new release tonight Feb 06 23:49:26 thanks Feb 06 23:49:45 cool (no hurry on my side though, I bundled your classes in my code as I'm experimenting with a few more things) Feb 06 23:50:09 driftyoda: I must say, my extremely large penis makes my sexual life miserable. I can only get inside as far as the tip of my penis in most women. I have to find severely obese women in order to even get half-way in. Feb 06 23:50:18 yeah the library targets a specific use case and for others can be very inefficient Feb 06 23:50:49 fair enough, it's very cool from you to make it available already Feb 06 23:50:50 hopefully with some others' experience it'll become hardened and more practical Feb 06 23:50:55 I put it to good use Feb 06 23:51:00 awesome Feb 06 23:51:17 In particular, I was previously using multiple PropertyValuesHolder in ObjectAnimator, but this doesn't work with the way you're proxying single properties, I'll have to fix that Feb 06 23:51:31 JakeWharton: Found out why the animation in ActionBarView was not being cleared ? Feb 06 23:52:06 SimonVT, the compat animation never clears Feb 06 23:52:35 it uses a subset of NineOldAndroids which retains the animation on the View forever Feb 06 23:52:46 Alright Feb 06 23:53:06 it's the only (easy) way to allow for that kind of animation and explicitly setting things like alpha and translation Feb 06 23:54:35 I do something similar in our product … Even though you mention we shouldn't be using AnimatorProxy.wrap() directly if using ObjectAnimator, I use it anyway, as it's an elegant way to pipe and keep all property changes. I ran some tests and didn't see any reason for it to conflict Feb 06 23:55:29 There are a couple more hurdle with AnimatorProxy though - if you start wrapping before the view gets attached to its parent, AnimatorProxy never sees the parent Feb 06 23:55:44 yeah Feb 06 23:55:46 It's on my fix list too Feb 06 23:55:56 in ActionBarSherlock the parent isn't cached Feb 06 23:56:11 yeah actually not caching the parent may be the best way to do it Feb 06 23:56:31 So about this optimized invalidate, if you're willing to discuss it for a minute Feb 06 23:56:55 https://github.com/JakeWharton/ActionBarSherlock/blob/4.0-wip/library/src/com/actionbarsherlock/internal/nineoldandroids/view/animation/AnimatorProxy.java#L87 Feb 06 23:57:01 sure Feb 06 23:57:09 that was a long term goal for me but not needed for my implementation Feb 06 23:57:31 So I factored out the code in applyTransformation() that deals with the matrix Feb 06 23:58:11 Before and after a change, I compute two rectangles for the view then apply the transform to obtain an invalidate rectangle, and I invalidate the union of both Feb 06 23:58:25 It's a gross approximation, but sufficient to restrict the update area Feb 06 23:58:37 awesome, that's exactly what I was thinking Feb 06 23:58:54 The trouble I have is that when I mapRect() the rectangle through the matrix with a scale applied, it doesn't work as expected Feb 06 23:59:21 The rectangle grows appropriately but translation doesn't occur in the right direction Feb 06 23:59:49 Now I'm not sure I understand matrix transforms well enough, but your code seemed to be doing the correct setup (moreover, it works when displaying) Feb 07 00:00:37 Hi everyone, I am learning to program in android and am having a hard time finding an example of attaching onclicklisteners to a table layout. Feb 07 00:00:43 I manually (using the graphical layout) created a table with 4 rows of images and want to add an onclick listener to them. I could do this by hand but because there are a lot of images it would be very time consuming. Does anyone have any examples? Feb 07 00:01:19 Yeah the scale and transformation was straightforward Feb 07 00:01:31 metap0d, learn to use loops Feb 07 00:01:31 rotation was the only thing I had to experiment with to get to match 3.0+ Feb 07 00:01:45 except that if you use this very same matrix to mapRect() the view rectangle, you don't get the correct result Feb 07 00:02:36 I'm not sure why yet - I'll push the code in a branch if you want to look at it Feb 07 00:02:58 in the meantime, I implemented a barebones solution that handles scale & translation separately Feb 07 00:03:13 and only uses the matrix for rotation transforms, but I don't like it Feb 07 00:06:07 yeah absolutely Feb 07 00:08:18 fpillet: Before and after a change, I compute two rectangles for the view then apply the transform to obtain an invalidate rectangle, and I invalidate the union of both << that's the way the framework does it Feb 07 00:08:45 romainguy: ah good, I hadn't checked the framework sources about this Feb 07 00:08:49 but it makes sense Feb 07 00:08:53 and the framework uses mapRect() Feb 07 00:08:57 ohh Feb 07 00:09:22 I'll have a look. I don't know what I missed which produces rects off to the right and down Feb 07 00:10:00 JakeWharton's transform setup looked perfectly fine to me, so I made a mistake somewhere Feb 07 00:12:34 Does the download counter in the Developer Console work correctly? It seems to be a bit off Feb 07 00:12:59 eclaesson: it's "eventually consistent", I think Feb 07 00:14:14 who changed git? Feb 07 00:14:24 p_l|backup: eventually == takes a darn time to update? Feb 07 00:15:04 eclaesson: when the changes sync themselves Feb 07 00:16:33 Does anybody know if the actual framebuffer dimensions change when the orientation changes, or does it keep its height / width, and just change in the UI? Feb 07 00:16:52 IanWizard: apps don't use the framebuffer directly Feb 07 00:17:05 and they do get a new surface with new width/height on orientation change Feb 07 00:19:24 romainguy, yeah, maybe I shouldn't have asked in -dev. it is the framebuffer that I'm interested in, I didn't know if it changes its dimensions. Feb 07 00:19:59 git repos synced with dropbox for a few months does some strange things... Feb 07 00:20:59 why do you sync it with dropbox... Feb 07 00:21:03 weird Feb 07 00:21:15 do that I can work across all of my computers and at work without pushing to a central repo Feb 07 00:21:18 *so Feb 07 00:21:21 sounds like a pita Feb 07 00:21:28 hi, i'm developing my firs android application. i need icons. i like the icons google use in its applications. does anyone know if there is some google icon package out there? Feb 07 00:21:33 easier to setup a central repo... Feb 07 00:21:39 not really Feb 07 00:21:42 it's easier to do nothing Feb 07 00:21:46 and have them synced automatically Feb 07 00:21:55 <3 teh dropbox Feb 07 00:22:30 oh hey, i didn't know romainguy visits this chat :) /hi Feb 07 00:22:43 while i get what ur saying about the ease of dropbox, id prolly just go and setup a googlecode repo or something and just be done with it if i had a project worth keeping track of lol Feb 07 00:22:53 capcook: There are the standard icons in you android-sdk folder. In platfomrs/XXX iirc Feb 07 00:22:54 all my projects are on GitHub Feb 07 00:23:01 but I don't want to push everytime I want to switch a computer Feb 07 00:23:08 nor am I always ready to commit Feb 07 00:23:15 badz2363, well, if it's private code, typically wouldn't want that Feb 07 00:23:35 same, I use rsync for this Feb 07 00:23:35 right, well whichever repo you like :) Feb 07 00:23:37 eclaesson: thank you Feb 07 00:23:51 you should copy those icons to your local /res folder tho Feb 07 00:24:00 JakeWharton: but as far as comitting, thats the beauty of rollback Feb 07 00:24:23 it's a public repo Feb 07 00:24:26 i can't rollback Feb 07 00:25:19 plus then i'd have to commit half-finished code whenever I wanted to change computers which would fail the build server and all kinds of crap Feb 07 00:25:36 easier to just do nothing and let a daemon sync the filesystems Feb 07 00:25:55 put your local git repo in a dropbox folder Feb 07 00:26:06 push into dropbox Feb 07 00:26:10 JakeWharton: I pushed my test changes to AnimatorProxy's invalidate to the experimental branch on my repo Feb 07 00:26:11 so you commit and push into the dropbox repo Feb 07 00:26:19 pfn: Yeah! Feb 07 00:26:20 and the dropbox repo is configured to push to github Feb 07 00:26:22 (weird, GitHub doesn't show it yet, but it's there) Feb 07 00:26:22 i dont know much about github so that might be my fallpoint. you can't rollback a file in your repo? Feb 07 00:26:31 fpillet, GitHub is behind Feb 07 00:26:33 well, git also has branches for this Feb 07 00:26:36 they're backed up Feb 07 00:26:48 tbws, i already do that, which is how this convo started Feb 07 00:26:50 * pfn hasn't quite figured out how to merge branches in git... Feb 07 00:27:01 git merge branch Feb 07 00:27:05 done Feb 07 00:27:09 I guess I haven't done it to see, heh Feb 07 00:27:10 :D Feb 07 00:27:13 :d Feb 07 00:27:14 :D Feb 07 00:27:15 it's a DAG, you can't really mess it up Feb 07 00:27:26 but I'm a bit nervous about putting my code on dropbox's services Feb 07 00:27:37 especially since the security used to be less than impressive Feb 07 00:27:46 eclaesson: can i use those icons? what's the license? Feb 07 00:28:21 pretty much half the appeal of git is cheap local branching, you definitely should be utilizing them Feb 07 00:28:39 capcook: Yes, you can use them, in both non-commercial and commercial apps as far as i know. Honestly, i don't really know what license they are released under Feb 07 00:28:48 JakeWharton: I'll look at this matrix issue tomorrow with a fresh eye. You'll get a pull request when I can get this working right Feb 07 00:28:56 But id do a wild guess on some creative commons Feb 07 00:29:01 fpillet, ok cool, make sure it's against the dev branch Feb 07 00:29:06 eclaesson: thanks Feb 07 00:29:11 only because i'm lazy and like one-click merges on GitHub :) Feb 07 00:29:12 oh right Feb 07 00:29:16 will do Feb 07 00:29:23 and yes, you're right. I'm that lazy too Feb 07 00:29:46 damn, GitHub is really backed up Feb 07 00:30:20 https://twitter.com/#!/github/status/166676209420353536 Feb 07 00:31:20 yeah this will get better … in the meantime, I'm off. Thx for merging the request Feb 07 00:38:05 hmm, I wonder if enyo would be an interesting framework to use inside of phonegap Feb 07 00:39:33 all i heard was phonegap and threw-up in my mouth Feb 07 00:40:00 ...says the guy who is using it at his work :) Feb 07 00:40:28 so that's why you're quittin' Feb 07 00:40:29 heh Feb 07 00:40:29 oh dear Feb 07 00:41:09 well considering I am one of two devs... we can't really afford to write 4-5 mobile apps Feb 07 00:41:15 s/am/was/ Feb 07 00:41:32 hello, for very simple basic 2d games, which is recommended, canvas or opengl? Feb 07 00:41:34 I'm willing to bet when I leave they'll never get done and it'll just stay as a mobile webapp Feb 07 00:41:51 hkhalid: canvas Feb 07 00:42:00 the enyo webapp demo looks so slow Feb 07 00:42:07 name sounds familiar Feb 07 00:42:09 thanks MDijkstra , your name reminds me of mdk for dreamcast Feb 07 00:42:17 heh Feb 07 00:42:27 bah chrome froze Feb 07 00:42:36 it's the first letter of my first name plus my family name Feb 07 00:43:02 of course dijkstra would sound familiar, heh Feb 07 00:43:07 yeah Feb 07 00:43:10 wrote a report on him in college Feb 07 00:43:32 *you Feb 07 00:43:42 ? Feb 07 00:43:54 dijkstra is a pretty common last name in the netherlands, though Feb 07 00:44:14 i would show you, but it appears my freeze is related to unity Feb 07 00:44:17 might not be the smartest nick to use in CS-related channels ;) Feb 07 00:44:25 I used a method to encode a YUV image to RGB .. Now I have my pixels in an int[] ... How can check if each pixel is less than a certain threshold ? Feb 07 00:44:57 CVirus: loop through it, or if you want performance that's not horrible Feb 07 00:45:11 use a vector-based method Feb 07 00:45:43 MDijkstra: How can I extract the ARGB components ? Feb 07 00:46:10 that depends on how they are encoded Feb 07 00:47:01 I don't think ints are a wide enough datatype to be able to encode 4 channels in 16-bit (or 24-bit) precision Feb 07 00:47:13 *int is Feb 07 00:47:24 eh? Feb 07 00:47:38 note that I have no idea how big ints are on java Feb 07 00:47:45 I'll go google now :p Feb 07 00:47:45 ints are 32bit of course Feb 07 00:48:20 well, 31bit, kinda Feb 07 00:48:24 is there a way to define an id in a xml value file? Feb 07 00:48:40 yes Feb 07 00:48:59 grantland, why do you want to define a static id value? Feb 07 00:49:42 Feb 07 00:50:26 and yeah, you can define it in an xml file under values/ Feb 07 00:50:48 CVirus: but how did you convert the data? Feb 07 00:52:03 SimonVT pfn thanks! Feb 07 00:53:07 pfn: what I meant was that the RGB format used determines if there's one int per channel or whether multiple channels 'share' an int Feb 07 00:56:28 and now google music isn't working Feb 07 00:56:37 never a dull moment living life on the bleeding edge Feb 07 00:57:42 Hi people. How could I get a reference on child activities from within a TabActivity? Feb 07 00:59:09 Beket: don't know, but tabactivity is kind of deprecated Feb 07 00:59:19 you're encouraged to switch to fragments Feb 07 00:59:21 more like very much deprecated Feb 07 00:59:37 (where incidentally, what you want to do is easy to accomplish) Feb 07 00:59:58 yes, I've read it in the docs, but I'm okay with it as I develop for 2.x Feb 07 01:00:02 mm Feb 07 01:00:51 fragments are available on 1.6+ through the Android Support Library, FYI Feb 07 01:01:28 I know, I just don't like them. Is it possible to get away with FragmentActivity+TabHost/TabManager? Feb 07 01:01:40 no Feb 07 01:01:42 (Assuming that I use the support library) Feb 07 01:02:06 yes :p Feb 07 01:02:17 :p Feb 07 01:02:21 I event hink the tabactivity docs have an example Feb 07 01:02:28 All I want is to set a delegate from my mian tabactivity to a child activity Feb 07 01:02:34 ok wil look at it Feb 07 01:04:01 ah yes, here it is Feb 07 01:04:45 I wonder how many occult bugs that code has Feb 07 01:04:54 will try it :) thanks Feb 07 01:06:21 Hi, what do you recommend to subversion with eclipse: subversive or subclipse? Feb 07 01:06:31 Descra, either one works fine Feb 07 01:06:37 Or is better to use something tortoiseSVN? Feb 07 01:06:47 man, i had to use SVN for a project a week or two ago Feb 07 01:06:50 holy crap Feb 07 01:06:52 never again Feb 07 01:07:02 JakeWharton, it s god! Feb 07 01:07:10 lol, it isn't that bad, stop trollin Feb 07 01:07:10 do you develop alone? Feb 07 01:07:16 ive used subclipse with ease in the past Feb 07 01:07:29 no I develop with thousands of other users on open source projects Feb 07 01:07:52 Oh, how do you organize? Feb 07 01:07:55 svn is terrible Feb 07 01:08:02 git or hg or darcs are the way to go Feb 07 01:08:09 well I use git, but any DVCS will do Feb 07 01:08:11 darcs if you're a haskell fan Feb 07 01:08:22 hg if you're a python fan Feb 07 01:08:26 and git for just about everyone else Feb 07 01:08:29 subversion filled a very needed gap, at one time... Feb 07 01:08:46 trolls Feb 07 01:09:59 because we aren't apologists for the glaring shortcomings of a dated version control system? Feb 07 01:11:00 No, because of the fact that it isn't terrible. It's not the best by any means, but most of the time it solves the problem. Haters love to hate I guess. Feb 07 01:11:13 re: SVN - all i'll say on the matter is it probably wouldn't still be around if it was so bad Feb 07 01:11:30 are you kidding? tell that to the COBOL programmers Feb 07 01:11:33 well, moving .svn up to the root directory of the wc is a pretty huge improvement Feb 07 01:11:36 if they've actually done that Feb 07 01:11:50 how about the telephone and power grids Feb 07 01:12:00 that fact that airlines still use "highways" in the sky Feb 07 01:12:13 there are thousands of examples of glaringly bad systems still in widespread use Feb 07 01:12:31 granted those changes are a bit harder to make than SVN -> DVCS Feb 07 01:12:47 yea, because how are you going to overhaul a system that big and important? Feb 07 01:12:58 one step at a time Feb 07 01:13:05 because not doing it is the bigger crime Feb 07 01:13:32 can someone help me with a custom status bar? Feb 07 01:13:47 we all might be able to Feb 07 01:13:49 ask away Feb 07 01:14:37 well i'm making a launcher resembling another os, and i need a custom statusbar with no drag-out and battery icon, etc Feb 07 01:14:57 i'm wondering which kind of view i should take, and if i should use a canvas or not Feb 07 01:15:05 *layout Feb 07 01:15:47 the status bar is part of the system UI and cannot be modified from within the scope of a launcher Feb 07 01:15:48 so disable the status bar from your app Feb 07 01:16:00 i.e. request full screen mode Feb 07 01:16:05 and draw it yourself Feb 07 01:21:23 so I have editTexts that aren't recognized by findViewById, but only in my one activity. Any idea of why this is? Feb 07 01:21:41 pfn, i'm allready running in fullscreen mode, but i wonder what view and layout i need? my concept is as follows: http://bayimg.com/bAmFIAadh Feb 07 01:22:13 giant_g2: you only finvViewById() what you setContentView() Feb 07 01:22:16 can* Feb 07 01:22:35 I set content as that xml file Feb 07 01:22:53 xiqxiq, so make a linearlayout that has all those pieces Feb 07 01:23:31 oh wait i'm so dumb lol Feb 07 01:23:42 you're right, i can set the linear layout to a specific height, right? Feb 07 01:25:20 giant_g2: perhaps the views aren't constructed at the time you call findViewById() ? Feb 07 01:25:23 when I import my android project I keep getting: Unable to resolve target 'android-8'. how do I fix this? Feb 07 01:26:00 install Android 2.2 from SDK Manager Feb 07 01:26:05 or change the version it's trying to compile with Feb 07 01:26:17 I have this in my manifest: Feb 07 01:27:03 zerkz sup man Feb 07 01:27:05 seems the API's aren't installed after all. thx Feb 07 01:30:31 JakeWharton: "highways" in the sky stopped being *utterly necessary* only recently, and even then only inland Feb 07 01:31:12 basically, *very* bad choice :) Feb 07 01:31:15 (for an example) Feb 07 01:41:16 it's outdated nonetheless, though... whether that was yesterday or 10 years ago Feb 07 01:41:25 it was for sake of argument anyways Feb 07 01:41:34 that example won't be changed for many, many moons Feb 07 02:04:22 Android styling.... ugh Feb 07 02:04:29 even just copying it from the platform is a PITA Feb 07 02:05:49 everytime I press alt+tab: [ 1109.731708] compiz[1948]: segfault at 6a2 ip 00007f0b5b517565 sp 00007fff1a33b260 error 4 in libunityshell.so[7f0b5b41b000+225000] Feb 07 02:06:01 lol Feb 07 02:06:18 hurrah compiz and unity Feb 07 02:06:29 sometimes it restarts... sometimes i'm left without a window manager Feb 07 02:06:33 JakeWharton, sure is, they're all private resources, ugh Feb 07 02:06:51 I switched to kde :p Feb 07 02:07:13 i'm pretty sure that's a step in the wrong direction :o Feb 07 02:07:20 i need to install Gnome 3 or something Feb 07 02:07:41 actually i'll probably be switching to a mac soon :( Feb 07 02:07:56 if you spend a few days playing with kde config you can eventually get it how you want Feb 07 02:08:36 I have a strange philosophy of enjoying things that 'just work' without fiddling, and thus I'm on unity Feb 07 02:08:47 yeah, i like unity Feb 07 02:08:55 it's just being annoying at the moment Feb 07 02:09:09 I like that approach much better as well, but too many things seemed broken on unity Feb 07 02:09:21 esp. with focus follows mouse Feb 07 02:09:23 oh man... droid 2 car mount for 3.50... oh but it won't work with my sedio case Feb 07 02:09:30 focus follows mouse?!? Feb 07 02:09:42 i've never had that Feb 07 02:09:45 the only way to compute! Feb 07 02:09:57 oh you do that by choice... Feb 07 02:10:03 that's something I don't use, it's a pretty offbeat thing. I'd understand why would unity have troubles though Feb 07 02:10:10 and I hope to get a droid 4 this year Feb 07 02:10:24 why not just wait another two months and get the 5 Feb 07 02:10:29 http://smartphones.itechdeals.com/ any of you other droid 2 users Feb 07 02:10:40 well it won't be happening until like oct Feb 07 02:10:50 I want a charging dock for gnex damnit Feb 07 02:10:56 one that actually takes advantage of the 3 buttons on the side Feb 07 02:11:01 same Feb 07 02:11:02 er, pins Feb 07 02:11:06 not out yet :-( Feb 07 02:11:14 mrenouf, inorite Feb 07 02:11:35 or if it is, only in europe? if you browse samsung uk site you can find it Feb 07 02:11:43 my galaxy note updated to some new samsung release yesterday, listviews are much smoother now... Feb 07 02:12:10 i got my gnex from UK anyways, why not the dock Feb 07 02:12:20 stupid Verizon "exclusivity" period means nothing convenient until TMobile comes online Feb 07 02:12:32 JakeWharton i cant seem to get the latest code to build Feb 07 02:12:43 using eclipse? Feb 07 02:12:44 maybe i just forgot how eclipse works Feb 07 02:12:50 yea there we go Feb 07 02:13:08 Android 4.0+ & Java 1.6 Feb 07 02:13:16 could you make me an updated compat lib with maps? :) Feb 07 02:13:29 abs4.0 only builds on eclipse? Feb 07 02:13:34 no Feb 07 02:13:39 i just assumed that's what he was using Feb 07 02:13:42 noooo do not extend MapView for everything Feb 07 02:13:43 ahh Feb 07 02:13:46 BAD Feb 07 02:13:51 i structure my Maven dirs in the standard Android layout for convenience Feb 07 02:14:15 standard android layout? Feb 07 02:14:22 src/ & res/ Feb 07 02:14:25 JakeWharton: ./appease_the_cow.sh Feb 07 02:14:44 normal Maven would be src/main/java/ and src/main/resources/ Feb 07 02:14:49 JakeWharton, ah, none of that src/main/java bullshit Feb 07 02:14:50 good Feb 07 02:14:54 yes Feb 07 02:14:59 because the folder name makes a HUGE difference Feb 07 02:15:07 haha Feb 07 02:15:34 but where do you put python unit tests then? ;-) Feb 07 02:15:59 once ADT supports resources in .jars I can switch back to the sane folder structure Feb 07 02:16:16 *really* hoping the new build stuff is up soon. Feb 07 02:16:19 right now I have a test/ folder in root with the JUnit stuff Feb 07 02:16:40 ahh, just meant the maven way would be src/python/test , etc Feb 07 02:16:55 its just that 99% of projects have only java and no tests, so it seems silly to some Feb 07 02:17:07 that was me, about a year ago Feb 07 02:17:42 then then I saw the light when I was working on something with java and antlr stuff with tests for both and then a Maven-generated site Feb 07 02:17:47 and I saw the light Feb 07 02:17:53 however, I *really* wish you could tell ADT that resources, or manifest files are in some other place Feb 07 02:17:54 and I repeated sentences Feb 07 02:17:56 mrenouf, tests go under the tests directory parallel to src Feb 07 02:18:04 IntelliJ lets you specify paths Feb 07 02:18:21 oh adt runs python tests now? Feb 07 02:18:33 and adjacent to Java ones in the same dir? Feb 07 02:18:35 and python tests? eh? Feb 07 02:18:36 no, no mixing two lines of though here Feb 07 02:18:41 jake jake jake JakeWharton Feb 07 02:18:43 *thohgt Feb 07 02:18:46 gah Feb 07 02:18:46 COW Feb 07 02:18:48 python tests against java web services or something maybe Feb 07 02:18:57 er, i meant ant Feb 07 02:19:01 [21:14:25] JakeWharton: ./appease_the_cow.sh Feb 07 02:19:02 whatever that stupid XML crap is called Feb 07 02:19:05 most of an integration test than unit testing, though Feb 07 02:19:14 s/most/more Feb 07 02:19:15 APPEASE ME Feb 07 02:19:47 I CAN'T Feb 07 02:19:49 DUTY CALLS Feb 07 02:19:54 http://xkcd.com/386/ Feb 07 02:19:56 ok how do i do it myself Feb 07 02:20:06 mvn package Feb 07 02:20:07 done Feb 07 02:20:10 package what Feb 07 02:20:13 nothing Feb 07 02:20:16 that will do everything Feb 07 02:20:19 no i mean Feb 07 02:20:25 wheres the compat lib Feb 07 02:20:39 it'll show up in plugins/support-lib/target/ as a .jar Feb 07 02:20:48 hold on Feb 07 02:20:50 i'm 99% there Feb 07 02:20:55 that's what she said Feb 07 02:21:23 you have to add the maps dependency and stuff Feb 07 02:21:29 i wouldn't want to inconvenience you Feb 07 02:21:58 i used sed on my moms website last night Feb 07 02:22:05 it pissed me the fuck off that ihad to change something in >9000 places Feb 07 02:22:09 for it to update on every page Feb 07 02:22:33 then today at work Feb 07 02:22:37 there was layout-mdpi/something.xml Feb 07 02:22:38 and -hdpi Feb 07 02:22:40 and -ldpi Feb 07 02:22:41 and -xhdpi Feb 07 02:22:51 the only diffs were dp values in margins Feb 07 02:23:30 lol Feb 07 02:23:43 someone not know how dip's work? Feb 07 02:24:00 and/or Android resources Feb 07 02:24:02 someone not know how anything works Feb 07 02:24:03 I'm having a problem where I set the content view to a layout but then it doesn't recognize any of the views in that layout. Any ideas? Feb 07 02:24:17 and then its the whole "IT WORKS, DON'T WASTE TIME MAKING IT BETTER" mentality Feb 07 02:24:25 which, unfortunately, is the case everywhere i've ever worked Feb 07 02:25:24 anyone know if something is going on with github? i'm getting a 'fatal: the remote end hung up unexpectedly' when trying to push my commit Feb 07 02:26:01 badz2363, they sound like they're overloaded at the moment Feb 07 02:26:12 thanks pfn Feb 07 02:26:20 badz2363, follow @github on twitter Feb 07 02:26:23 http://abstrusegoose.com/432 email that to everyone in your office , canadiancow Feb 07 02:26:39 canadiancow, you want this emailed? Feb 07 02:26:48 sure Feb 07 02:26:51 or anything'd really Feb 07 02:26:57 whatev's easiest <3 Feb 07 02:27:10 well t0mless, there's always the "other people's code" aspect Feb 07 02:27:18 but theres enough actual crap that i can overlook it Feb 07 02:27:37 ok i'll start pasting the hex dump in here Feb 07 02:27:39 just copy to notepad Feb 07 02:27:42 and then save as a .jar Feb 07 02:27:45 i saw an O(n^2) algo where O(n) would have worked Feb 07 02:27:51 and it wasnt like a better way of doing it Feb 07 02:27:53 canadiancow, awesome Feb 07 02:27:55 they could have just removed the inner loop Feb 07 02:28:49 sent Feb 07 02:28:50 didn't test Feb 07 02:29:04 Is there PDF version of developer.android.com? I really find it more helpful than some books and would be nice to read it on bus. Feb 07 02:29:09 you better not have sent it to my zynga addy Feb 07 02:29:35 that'd be one hell of a PDF Feb 07 02:30:04 maybe not the whole thing, but the new training modules should be Feb 07 02:30:11 well, not the whole developer.android.com, just the guide :) Feb 07 02:30:13 appease-the-cow-4.0.0-SNAPSHOT.jar Feb 07 02:30:13 lol Feb 07 02:30:49 I would go with the new android training stuff, some of the guides and examples are either buggy, out of date or just not great Feb 07 02:30:49 xbb_, use some kind of offline reader, website mirroring software Feb 07 02:30:50 wget -m Feb 07 02:30:51 i sent it to markpincus@zynga.com Feb 07 02:31:13 reading through android training didn't seem very great Feb 07 02:31:19 I think the dev guide pages are still much more useful Feb 07 02:31:29 they serve as both a reference and overview of what everything is Feb 07 02:31:45 you realize the docs are already included in the SDK, right? Feb 07 02:31:57 I am talking about this http://developer.android.com/guide/index.html is dev guide something different? Feb 07 02:32:12 yep Feb 07 02:32:13 xbb_, if it's under the dev guide section, then that's what it is Feb 07 02:32:18 https://github.com/nicolargo/glances#readme Feb 07 02:32:20 mrenouf, yes. but on my commute all I have is le tablet Feb 07 02:32:21 looks cool Feb 07 02:32:23 check your adk path Feb 07 02:32:29 ok Feb 07 02:32:33 SDK_PATH/docs/guide Feb 07 02:32:43 ah Feb 07 02:32:45 so just tar it up and stick it on your tablet, Feb 07 02:32:46 checking... Feb 07 02:32:50 its made for local browsing Feb 07 02:33:03 if you dont have it you need to d/l with SDK tool Feb 07 02:33:08 nice, never noticed that before Feb 07 02:33:23 mrenouf, you a genius! Feb 07 02:33:32 not that I ever read offline, though... Feb 07 02:33:43 you're offline? Feb 07 02:33:50 I accidentally a word... Feb 07 02:33:50 when!? Feb 07 02:34:30 im JakeWharton, my expandables arent expanding on my tablet Feb 07 02:34:34 or my phone Feb 07 02:34:42 on what API Feb 07 02:34:42 mrenouf, far too often for my tastes ;-) Feb 07 02:34:45 i liked it better when you couldnt back-collapse Feb 07 02:34:47 14 and 15 Feb 07 02:34:49 they worked before Feb 07 02:34:56 that's because they use the native shit now Feb 07 02:34:59 and have to be proxied Feb 07 02:35:04 i'm surpsied they work at all :) Feb 07 02:35:18 so by "fixed my bugs", you mean "took out the feature that has the bug" Feb 07 02:35:20 awesomesauce Feb 07 02:35:24 it'll work on pre-14 Feb 07 02:35:26 :P Feb 07 02:35:28 maybe Feb 07 02:35:33 lemme grab my nexus one Feb 07 02:35:44 if I had a sample that used them it would be easier to test Feb 07 02:36:15 samples/demos/src/com/actionbarsherlock/sample/demo/ExpandableActionItem.java Feb 07 02:36:16 GO Feb 07 02:37:07 hold on im like doing six things Feb 07 02:37:13 i told my mom id help her with her site like in december Feb 07 02:37:16 and...yea Feb 07 02:37:23 DO SEVEN Feb 07 02:37:41 mulitasking is a myth Feb 07 02:37:43 i dont get File.mkdir() ... how does it know what the new dir's name should be? Feb 07 02:37:49 JakeWharton of ABS fame-- awesome work sir Feb 07 02:37:59 xorgate, it's the name of the File, duh! Feb 07 02:38:06 storm717, thanks! Feb 07 02:38:21 o_O but i get the File from Environment.getExternalStorageDirectory() Feb 07 02:38:36 and there i wish to create a new dir Feb 07 02:38:49 xorgate, then you need to create a new File object with the appropriate directory name Feb 07 02:38:58 xorgate, new File(Environment.getExternalStorageDirectory(), "my-dir").mkdir() Feb 07 02:38:59 because if Environment.getExt... returns /sdcard, and you say File.mkdir() Feb 07 02:39:01 you just get /sdcard Feb 07 02:39:10 which isn't a new directory Feb 07 02:39:20 weird.. Feb 07 02:39:23 ok i'll try that :) Feb 07 02:39:34 not so weird Feb 07 02:39:51 and yes, java's File API is the suck Feb 07 02:40:15 * pfn shrugs Feb 07 02:40:22 very much suck Feb 07 02:40:23 half the methods throw checked exceptions, the other half return a boolean Feb 07 02:40:39 use a language that doesn't honor checked exceptions :p Feb 07 02:41:04 Java7 where are you? I want my NIO2! Feb 07 02:41:14 <3 python's io Feb 07 02:41:28 open('whatever') as f: Feb 07 02:41:30 data = f.read() Feb 07 02:41:49 huh, never used the 'as' keyword Feb 07 02:41:51 neat Feb 07 02:42:08 i forgot a 'with' Feb 07 02:42:10 usually just f = open('f') Feb 07 02:42:15 how can I fix an error in Eclipse that says "no grammar constraints defined(DTD or XML schema) for the document" it's giving that to me in one of my xml files for an android layout Feb 07 02:42:18 well, with open foo as f: Feb 07 02:42:22 that way you get auto-resource management Feb 07 02:42:27 i.e. f is closed when the block is done Feb 07 02:42:38 same as try-with-resources in java7 Feb 07 02:42:39 oooh 'with' yep Feb 07 02:42:46 yep Feb 07 02:43:16 thanks for reminding me of another thing I cant have yet either Feb 07 02:43:35 * pfn points to scala as the answer Feb 07 02:43:46 * mrenouf *facepalm* Feb 07 02:43:59 * JakeWharton scratches Feb 07 02:44:25 now you have f(n) problems Feb 07 02:44:29 :-) Feb 07 02:46:02 i need to write my less-ish script for Android styles Feb 07 02:46:03 giant_g2, no guarantees, but http://www.google.com/search?gcx=w&sourceid=chrome&ie=UTF-8&q=%22no+grammar+constraints+defined(DTD+or+XML+schema) Feb 07 02:46:04 def with(o: { def close() }, f: { def close() } => ()) = try f(o) finally { o.close() } Feb 07 02:46:13 ew Feb 07 02:46:15 something like that would be usable maybe Feb 07 02:46:24 Jake, is there any way to add ABS into PreferenceActivity? Feb 07 02:46:25 Ok...nevermind, Eclipse was just fucking with me. Damn thing just decided to work for no reason Feb 07 02:46:35 * giant_g2 scratches his head Feb 07 02:46:39 Gentle, there's a preference activity plugin with v3.x and v4 has it baked into the library Feb 07 02:46:40 with(new FileInputStream(...), { f => doStuffWith(f) }) Feb 07 02:46:49 hmm, that doesn't quite do what I'd expect, oh well Feb 07 02:46:53 but anyway, wouldn't even need that Feb 07 02:47:01 stop... ahh the horror Feb 07 02:47:24 just def with(o: { def close() }, f: => ()) = try f finally { o.close() } Feb 07 02:47:26 that's better Feb 07 02:47:39 kinda Feb 07 02:47:40 plugin? Feb 07 02:47:49 anyone know of any good android opengl tutorials other than what's on android.com ? Feb 07 02:47:50 Gentle, http://abs.io/download Feb 07 02:47:50 meh, still don't have the syntax right for doing that, oh well Feb 07 02:48:15 oh, awesome, thanks Feb 07 02:48:31 er Feb 07 02:48:34 yeah +cat Feb 07 02:48:46 nice nick complete job :p Feb 07 02:48:49 heya JakeWharton Feb 07 02:48:53 i pressed tab Feb 07 02:49:00 would it work with beta version? Feb 07 02:49:01 JakeWharton, yeah, you have xchat setup wrong Feb 07 02:49:13 JakeWharton, set it to last-talked and set nick_completion_amount = 999 Feb 07 02:49:22 Gentlecat, it's baked into v4 betas Feb 07 02:49:30 com.actionbarsherlock.app.SherlockPreferenceActivity Feb 07 02:49:57 yeah i haven't done any config Feb 07 02:50:06 JakeWharton, er, /set completion_amount 999 Feb 07 02:50:12 JakeWharton, and then just tab once :p Feb 07 02:50:42 JakeWharton how is the proxying going? Feb 07 02:50:53 works great except for your case Feb 07 02:50:58 /set completion_amount 999 Feb 07 02:51:06 pfn, say something Feb 07 02:51:11 JakeWharton, yeah Feb 07 02:51:17 pfn, still gets pfefferz first Feb 07 02:51:18 p gets pfn Feb 07 02:51:21 JakeWharton i am making a demo btw Feb 07 02:51:24 gimme 5-10 Feb 07 02:51:24 JakeWharton, you need to set last-talked order Feb 07 02:51:32 yay! it works Feb 07 02:51:58 JakeWharton, /set completion_sort 1 Feb 07 02:52:20 nice! thanks for the tip! Feb 07 02:52:21 aha! Feb 07 02:52:25 yes, thanks Feb 07 02:52:35 why is that not the default?! Feb 07 02:52:40 mrenouf, don't ask me Feb 07 02:52:41 xchat sucks Feb 07 02:52:43 I don't use it Feb 07 02:52:56 now i'm going to break my muscle memory of tabbing a bunch of times for people :) Feb 07 02:53:04 they all suck as far as I can tell Feb 07 02:53:07 I'm just forced to use it on occasion when my shell box crashes Feb 07 02:53:19 JakeWharton, irssi + bnc is my general solution Feb 07 02:53:30 i have/had irssi set up as a bnc on my solaris box Feb 07 02:53:36 didn't like it as a client Feb 07 02:53:44 I use xchat and a proxy usually Feb 07 02:53:53 irssi when I'm at a computer Feb 07 02:53:57 and qicr when I'm out Feb 07 02:54:13 why the hell don't you bump the version number of that Feb 07 02:54:24 it's like 0.0.0.0.0.0.1aaaaaa0.0.1.a Feb 07 02:54:37 -pre1 Feb 07 02:54:38 it's just 0.01X where X is a letter Feb 07 02:54:51 I'll bump it once it's kind of feature complete Feb 07 02:55:04 i.e. when it's in a real beta phase Feb 07 02:55:38 i operate under the notion that anything that's public and being used should be 1.0 Feb 07 02:56:15 bump the minor numbers for new features or minor API changes and major versions for major API changes Feb 07 02:56:27 and the build can be whatever, bugfixes, etc. Feb 07 02:56:54 not criticizing you Feb 07 02:57:06 indeed Feb 07 02:57:06 i just laughed when I saw 0.0.1v or whatever Feb 07 02:57:22 some people follow semantic versioning religiously Feb 07 02:58:00 I used to do the 0.X thing I found that my code would rarely ever hit 1.0 because there's always one more thing to do Feb 07 02:58:41 I should be Meld-ing... Feb 07 02:58:57 these Android styles aren't going to un-muck themselves Feb 07 02:58:58 http://semver.org/ Feb 07 02:59:01 yeah Feb 07 02:59:02 I have plenty of apps that are 1. oh and greater Feb 07 02:59:03 not a fan Feb 07 02:59:39 plus their naming crap after the X.Y.Z is crazy **** ENDING LOGGING AT Tue Feb 07 02:59:58 2012