**** BEGIN LOGGING AT Sun Jun 10 03:00:03 2012 Jun 10 03:07:55 I've been trying to follow this guide to set up an android build environment: http://source.android.com/source/initializing.html. Unfortunately, this happens: http://pastebin.com/1JsNBqFt. Why is this? Thanks in advance. Jun 10 03:07:59 I'm using Ubuntu. Jun 10 03:17:41 fully_human: ask in ##linux or #ubuntu. These issues aren't related to android development but to linux administration. Jun 10 03:18:07 also the official 'platform channel' is #android Jun 10 03:18:18 and you might have luck asking in #android-root Jun 10 03:36:38 lulz, anti-joke -- boy: "Knock knock!" grandmother: "Who's there?" boy: "Brian!" grandmother: "Brian who?" *Brian holds back his tears as he realizes his grandmother's alzheimer's is getting worse.* Jun 10 04:01:35 http://www.frodobooth.com/wp-content/uploads/2012/05/602x469x8885.jpg.pagespeed.ic.egOb-KSaOM.jpg Jun 10 04:03:22 nice Jun 10 04:04:34 Can anyone help me debug? I can make myself get a force close, and in my logcat it says it's because i'm trying to use a recycled bitmap, but it doesn't say in what class and I can't figure out why Jun 10 04:07:15 Nvm I got it. Jun 10 04:09:01 damn, that's uncanny pragma- Jun 10 04:09:33 can decide if I want to go into work or not Jun 10 04:09:41 access to a whiteboard would be of great convenience right now Jun 10 04:11:03 …and food and drinks Jun 10 04:25:36 Can you have a toggleButton in a widget? Jun 10 04:48:50 Someone willing to help me with my widget? Jun 10 04:56:56 Is there a way (or particular API I should look at) to control Google Talk from my Android App - for example, to programmatically begin a google talk voice chat Jun 10 04:59:29 hey all, is it possible to flash a whole recovery/rom using adb, or is fastboot required? adb sees my device but fastboot doesn't. (sorry if this is the wrong spot to ask) Jun 10 05:00:58 #android-root Jun 10 05:02:04 asked there, no answer in there thought I'd ask quick in here just in case someone awake was in here... Jun 10 05:02:35 thanks tho Jun 10 05:03:06 le sigh Jun 10 05:03:09 concurrency troubles Jun 10 05:08:54 whenever I have concurrency problems, I just move everything to one thread to fix it Jun 10 05:10:08 considering what i'm doing is distributed and asynchronous that would be the exact opposite of what I should do Jun 10 05:10:21 JakeWharton: i was joking :) Jun 10 05:10:30 whew Jun 10 05:10:38 i almost broke out into a cold sweat Jun 10 05:10:43 heh Jun 10 05:11:38 that last 30 days graph on Google Play looks made up Jun 10 05:11:59 vs my flurry statistics... something doesn't jive Jun 10 05:12:34 QubeZ: Google stats etc. aren't realtime Jun 10 05:13:10 I'm wondering why it looks different throughout the day, is it updatedl ike very 4 hrs or something? Jun 10 05:13:37 possible Jun 10 05:17:04 I need to start learning animations Jun 10 05:17:06 badly Jun 10 05:17:10 i'm trying to write actors on Android without a library, HandlerThread and Handlers work really well but where I'm falling short is how to make this work across a pool of HandlerThreads. Jun 10 05:17:13 anyone have ideas? Jun 10 05:17:43 I guess this is why you use a library :( Jun 10 05:18:55 In a WidgetView is there any way to get the current imageViewSource of a ImageButton? Jun 10 05:19:04 I'd use an Executor but there's far too much object creation involved and I don't really want to write my own recyclers Jun 10 05:19:05 I'm trying to make a toggle but it isn't working :s Jun 10 05:19:35 T-Dub|DlolPics: look at the built-in power control widget for toggles Jun 10 05:19:54 I can't find any supported toggles Jun 10 05:19:56 I already looked Jun 10 05:20:03 the only one I can find (toggle button) isn't supported Jun 10 05:20:13 Google said imageButton is my best bet Jun 10 05:22:13 creating a toggle from scratch shoul dbe super easy Jun 10 05:23:23 Well the widget class doesn't save variables Jun 10 05:23:44 I was just going to do if(boolean) { boolean = false code }else{ boolean = true other code } Jun 10 05:24:07 but it always returns whatever value I specify in the initalizing, and doesn't actualy become false (if I set it to be true) Jun 10 05:26:57 ron_frown: no matter how many times I press the button it says "beastmode is now ON" http://pastebin.com/3Mgvj0gm Jun 10 05:27:04 What am I doing wrong :s? Jun 10 05:27:56 assuming only one widget will exist, for starters Jun 10 05:29:06 :o? Jun 10 05:39:41 http://stackoverflow.com/questions/10966595/how-to-make-a-toggle-button-for-a-widget-android Jun 10 06:10:32 hi could somebody help me with this? I'm trying to get the relative layout to take 80% of the screen and the imagebutton to take 20% of the screen, android layout _weight doesnt seem to work. It looks fine in the preview but not in either my emulator or device https://www.dropbox.com/s/azfcl6u718js5l5/number_picker_fragment.xml Jun 10 06:11:47 you need weightSum Jun 10 06:12:03 that's done automatically Jun 10 06:12:03 in your first LinearLayout Jun 10 06:12:07 oh Jun 10 06:12:10 then I got no idea Jun 10 06:12:11 gl Jun 10 06:12:11 as the sum of all child weights Jun 10 06:12:12 :P Jun 10 06:13:29 hmm...any other ideas? Jun 10 06:15:27 heres the screenshot of how it looks on emulator and how it looks in the preview hi could somebody help me with this? I'm trying to get the relative layout to take 80% of the screen and the imagebutton to take 20% of the screen, android layout _weigths doesnt seem to work. It looks fine in the preview but not in either my emulator or device https://www.dropbox.com/s/azfcl6u718js5l5/number_picker_fragment.xml Jun 10 06:15:34 oops Jun 10 06:15:50 sorry heres the link of the screenshot https://www.dropbox.com/s/6brbzkqob0d4mkt/Image%20012.png Jun 10 06:29:30 JakeWharton is there a value I can put in android:updatePeriodMillis to make it never update? Jun 10 06:29:44 i've never done widgets Jun 10 06:30:08 Damn it Jun 10 06:35:03 Hello Jun 10 06:35:11 Hello, im planning to make a simple 2d game and i have no idea where to start when it comes to graphics. Any ideas where i can start? Jun 10 06:36:11 I have some links, I've never done it myself but sec Jun 10 06:36:37 widgets are like the one part of android I havent bothered with myself either =) Jun 10 06:36:54 http://code.google.com/p/cocos2d-android/ Jun 10 06:36:59 I don't know if its 2d Jun 10 06:37:02 But it's an engine Jun 10 06:37:17 There is also andEngine Jun 10 06:37:38 Oh ok. Jun 10 06:37:43 http://www.youtube.com/watch?v=RSS1zh45Fts&feature=g-vrec OMG Jun 10 06:37:45 Im sure its 2d because its cocos2d. Jun 10 06:37:48 skip to 4 minutes if you get bored Jun 10 06:37:51 haha yeah good point Jun 10 07:22:41 any DIY project to extend Androids with other sensors? (e.g. temperature) Jun 10 07:24:33 AFK? Jun 10 07:24:34 err Jun 10 07:24:35 ADK* Jun 10 07:24:48 i have a temp sensor hooked up to mine Jun 10 07:25:27 canadiancow: there is a new proguard, if you care Jun 10 07:25:42 in tools, or just in general Jun 10 07:25:46 in general Jun 10 07:25:53 (4.8) Jun 10 07:27:16 we'll see if it's included in r20 or r21. if not, i'll see if it's worth managing separately Jun 10 07:27:20 but for now, im fucking drunk Jun 10 07:27:28 hehe Jun 10 07:28:22 i hope you wore a rubber Jun 10 07:28:25 i hear drunk gets around Jun 10 07:28:51 nah we werent in bed that long Jun 10 07:28:58 and there were too many other people aroudn for her Jun 10 07:29:08 i was ok with it, but...cant force myself on pretty little women Jun 10 07:29:31 and im not as drunk as you were on may 4 Jun 10 07:30:09 which is obvious, considering i've now answered Utopiah's question, and had a conversation with both you and g00s Jun 10 07:30:42 well question is, why don't you have an alcometer sensor w/ your Android then Jun 10 07:31:20 probably hook one up to an ioio board Jun 10 07:31:46 a wat? Jun 10 07:31:49 alcometer? Jun 10 07:31:59 like...breathalyzer? Jun 10 07:32:18 that actually requires a fair bit of hardware, so i leave the attachment in my car Jun 10 07:32:24 which is the only place it really matters Jun 10 07:32:46 did you make/assembled the temp sensor? Jun 10 07:32:51 no Jun 10 07:32:54 gogole gave them out Jun 10 07:33:03 http://developer.android.com/guide/topics/usb/adk.html Jun 10 07:33:18 oh yeah, i remember those Jun 10 07:34:06 uh perfect, thanks Jun 10 07:43:08 i have an image on my dashboard, when user taps it... I turn it black/white to show its been tapped -- for this I have two images but they take up a lot of space. Does it make sense to tint the image programatically or leave the large image? Jun 10 07:43:17 sweet, big nerd ios ebook is 9.99 today Jun 10 07:43:43 g00s: link? Jun 10 07:43:58 QubeZ: http://www.informit.com/ Jun 10 07:44:01 see top right Jun 10 07:44:16 it just came out like 2 mos ago :) Jun 10 07:44:28 nice... i'll have to grab that -- I've been writing iOS for like 1 month now Jun 10 07:47:34 QubeZ: i don't know if it was for yesterday or tomorrow … get it right away if you want it Jun 10 07:47:44 there is usually an hour or 2 of slop Jun 10 07:47:53 its still $9.99 Jun 10 07:50:12 ordered Jun 10 07:50:16 :) Jun 10 07:51:11 oh man, im trying to shave another 100k off my apk Jun 10 07:52:38 its 2.9 m, wow ! Jun 10 07:52:58 QubeZ: use a ColorMatrixFilter Jun 10 07:53:04 JakeWharton: googling Jun 10 07:53:15 found: http://stackoverflow.com/questions/3373860/convert-a-bitmap-to-grayscale-in-android Jun 10 07:53:20 oh my google-fu Jun 10 07:53:29 g00s: is that pretty good? 2.9M Jun 10 07:53:38 my app is 357 K :) Jun 10 07:53:56 anything over 7-8M is the danger zone Jun 10 07:54:22 To Do Mapr actually does a lot of cool things now -- I think 2.9M isn't bad at all for that Jun 10 07:54:27 but trying to shave it down Jun 10 07:54:35 we use 5M as our target Jun 10 07:54:40 QubeZ: lots of graphics assets ? Jun 10 07:54:52 using proguard ? Jun 10 07:55:04 g00s: ya, the tutorial screen in the beginning (5 images) takes up 1M itself Jun 10 07:55:08 so not much I can do about that Jun 10 07:55:11 :O Jun 10 07:55:13 pngcrush? Jun 10 07:55:15 g00s: yup, proguard Jun 10 07:55:16 yeah Jun 10 07:55:22 used pngcrush on the images already Jun 10 07:55:28 :O :O Jun 10 07:55:34 nice Jun 10 07:55:37 i think... but I thought the build process already crushes it? Jun 10 07:55:49 i think it does now Jun 10 07:56:11 we do them all ourselves since we can use specific settings Jun 10 07:56:15 yea because i compared the png resource from my png crush result and the results were negligible Jun 10 07:56:26 but im trying to figure out how to get the tutorial screens small... then app could be under 2M Jun 10 07:56:39 seems like an arbitrary thing to optimize Jun 10 07:56:44 make the experience the best it can be Jun 10 07:56:55 true Jun 10 07:57:12 i mean, be mindful of it, but don't go out of your way to make the APK smaller Jun 10 07:58:10 i actually got a really good review a few days ago... made my day =) Jun 10 07:58:22 nice Jun 10 07:58:25 that's always a good feeling Jun 10 07:58:35 user review... im trying like hell to get the app reviewed but fail on that front Jun 10 07:58:47 submitted recently to the Friday App Review on Google+ Jun 10 07:58:49 we'll see how that goes Jun 10 07:59:04 if you polish the app enough it'll get noticed Jun 10 07:59:05 Going to add ABS in the next build Jun 10 07:59:27 nice :) Jun 10 07:59:29 My main focus is... never ever let it crash... ever. Jun 10 07:59:41 so here's the review that made me feel good abotu the stability: Jun 10 07:59:42 The ui is very refined and the app is very well-behaved. It also has great features. The only thing missing is location-based alerts. It would be nice to be able to get an alert when you are in a specified range of a destination. Keep up the great work! Jun 10 08:00:02 try little-fluffy-location-library Jun 10 08:00:15 QubeZ: are you going to switch to abs? Jun 10 08:00:15 i'm pretty sure it has geofencing events baked in Jun 10 08:00:25 writing a well-behaved app is very improtant to me Jun 10 08:00:27 g00s: yes Jun 10 08:01:02 i'd like for us to open source our geofencing implementation but it's far too specialized and has external dependencies on things like the Guava EventBus Jun 10 08:01:10 so it probably won't happen Jun 10 08:01:50 i should probablyput my guava eventbus on github Jun 10 08:01:59 if i can figure out how to use git still :P Jun 10 08:02:22 i will never write an app without an EventBus and Guice Jun 10 08:02:36 so elegant Jun 10 08:02:47 i had to change the eventbus a bit. i needed ordered receivers Jun 10 08:02:53 g00s: I started with git for my TDM iOS port and well... still new to it but less headaches than svn Jun 10 08:03:11 its weird getting used to the fact that in git, commit is just local... you have to then push all your commits later to your server Jun 10 08:03:16 s/server/repo Jun 10 08:03:24 DVCS <3 Jun 10 08:03:37 even when I was forced to use SVN i used git-svn Jun 10 08:03:50 thankfully that was a few years ago and I eventually got them to switch to GitHub Jun 10 08:03:52 i managed to f up my repo in only a few commits, so i took it to someone i knew knows git well and he told me i should just start over :| Jun 10 08:04:19 i only had a few commits so no biggie Jun 10 08:04:41 I was intimidated by ABS at first but it's very easy Jun 10 08:04:49 so i wonder if this fluffy thing is like reto's blog example Jun 10 08:05:03 Based on the concepts in, and some code adapted from, android-protips-location by Reto Meier, from his blog post A Deep Dive Into Location. Jun 10 08:05:12 it is very intimidating Jun 10 08:05:28 no geofencing but adding that will be easy for me based on what i've built so far Jun 10 08:05:36 oh cool Jun 10 08:05:47 I did a bunch of live coding demos of porting pure ICS apps to use ABS in a talk I gave Jun 10 08:05:53 the changes were so minimal it was ridiculous Jun 10 08:06:20 i think what makes actionbar intimidating for me, is i only have a froyo phone. i can play with ics in the emu, but i really haven't gotten a good feel for it Jun 10 08:06:40 do you not use any apps? Jun 10 08:06:44 i rarely see an app without one Jun 10 08:06:50 i use the google apps Jun 10 08:06:54 i don't think they use abs though Jun 10 08:07:04 no, they use their own, but it's still an action bar Jun 10 08:07:06 but no, i don't have anything downloaded to the phone from the market Jun 10 08:07:41 really? why? Jun 10 08:07:55 i download as many apps as possible so I can see what they're doing an do it better in the Square apps Jun 10 08:08:22 alright im out Jun 10 08:08:25 night guys Jun 10 08:08:32 see ya Jun 10 08:08:41 see ya Jun 10 08:09:49 g00s: you should also put some excerpts regarding using the event bus there :) Jun 10 08:10:10 indeed Jun 10 08:10:24 but - from experience, i've found ti hard to reuse event busses Jun 10 08:10:47 there always seems to be something - in the way its dispatched (different threads?) that makes it difficult to abstract Jun 10 08:11:15 i should put it up anyhow Jun 10 08:11:19 we imposed the restriction that all events must be dispatched and received on the main thread Jun 10 08:11:27 i'm waiting for a bug to be patched in the existing one Jun 10 08:11:38 why don't you fix it yourself? Jun 10 08:11:56 i did, but the semantics might not be the same as their patch. i have to see Jun 10 08:12:08 maybe reconcile Jun 10 08:12:28 that's the beauty of forking libraries Jun 10 08:12:35 don't have to bother waiting for upstream Jun 10 08:12:42 Guava has a ridiculously slow development churn Jun 10 08:12:52 mine takes a handler, that gets the dispatched events ( i dispatch on a different thread) Jun 10 08:13:09 you don't @Subscribe things? Jun 10 08:13:15 yeah i do Jun 10 08:13:35 i changed the code quite a bit, to cache the reflection results Jun 10 08:13:58 and i added an unregister listener - i don't think they had that at the time Jun 10 08:23:15 Handlers are effectively actors except you can spread them across a thread pool Jun 10 08:23:24 or at least I can't figure out how to without multiple instances Jun 10 08:24:36 I guess that wouldn't be the worse thing in the world since the pools would be relatively small Jun 10 08:25:05 but then the queues aren't distributed Jun 10 08:25:12 sheeeeeeeeeeeit Jun 10 09:08:22 has anyone use actors on Android and if so, which libraries did you use? Jun 10 09:08:54 I basically need threaded actors and Handler/HandlerThread isn't cutting it Jun 10 09:26:36 hey, guys Jun 10 09:34:03 quick question regarding audiotrack. is getPlaybackHeadPosition() the head alsa (or whatever) reads _now_ or what the speaker outputs? Jun 10 09:34:05 http://developer.android.com/reference/android/media/AudioTrack.html#getPlaybackHeadPosition() Jun 10 09:34:24 can anyone suggest why any intent spawned with this function has an empty bundle (when checked in onCreate)? http://pastebin.com/wwQTxnqq Jun 10 09:56:12 Is Android built hardfp by default? Jun 10 10:06:36 ah yes, lets request item -1 from a listadapter, that makes perfect sense Jun 10 10:07:24 where are info files stored in android ? Jun 10 10:13:22 im finding more and more reasons to scrap my current dialog code and go with the damn support package to get dialogfragments Jun 10 10:13:36 homie: What are info files? Jun 10 10:19:01 blah.info for example which resides normally in /usr/share/info Jun 10 10:19:05 on linux systems Jun 10 10:19:38 i have found a man-pages app, but don't know where to get info files or say where to put mine.... Jun 10 10:23:18 I create a Spinner with ArrayAdapter adapter = new ArrayAdapter(context, android.R.layout.simple_spinner_item, items);spn = new Spinner(context);spn.setAdapter(adapter); No I want to get the actual selected string. Can I save do this? selected=items[this.spn.getSelectedItemPosition()] Jun 10 10:23:29 items is an String-Array Jun 10 10:25:22 I ask me, if the order in the string-array is the same as in the ArrayAdapter. Jun 10 10:27:19 yep it should be Jun 10 10:27:31 only should? Jun 10 10:28:14 i havent seen anything explicitly guaranteeing it, but it works for me, and if you consider the majority of non-specialised collections preserve order, your likely to be fine Jun 10 10:28:55 I use just a array of strings to diplay the list. Jun 10 10:29:02 you need to be able to specify which order you want the spinner items to be displayed, that order is provided when you pass the array/list into the adapter Jun 10 10:29:21 i would file that under common sense Jun 10 10:29:37 you mean the adapter can do sorting? Jun 10 10:30:00 no i mean the data structure you provide to the adapter is sorted by you, and it uses that sorting for display Jun 10 10:30:25 there is no sensible reason why it would arbitrarily re-order it without you requesting it to do so Jun 10 10:31:07 ok, that is important, cause there can be an * in the list. For deleting things, it would not be fine, if you get the asterix by fault. Jun 10 10:32:25 fernext, i have a button which launches a single-option dialog, one of those options is a "custom" entry, i put that at the end of the list Jun 10 10:32:31 my default is the current value Jun 10 10:33:02 * robb_www mimicing the way Wysie's contact app works (unsure of spelling) Jun 10 10:33:11 oh, I just found the adapter.getItem() methode Jun 10 10:33:32 yer you can override them if you want, ive added some filtering operations that way Jun 10 11:13:51 phew.. Jun 10 11:13:54 now that was a night out Jun 10 11:15:14 hungover? Jun 10 11:15:22 yeh! Jun 10 11:15:26 i made the classic mistake Jun 10 11:15:27 sounds great :P Jun 10 11:15:30 7 shots in a row Jun 10 11:15:32 ouch Jun 10 11:15:34 i forgot half the night Jun 10 11:15:51 im not even sure where we went Jun 10 11:15:56 lol and my gf has left already Jun 10 11:16:13 a few months back we started the night with vodka shots in a similar fashion, im still not sure whether i stole the kebab i found on my desk the next morning Jun 10 11:16:24 lol Jun 10 11:16:35 i woke up with some weedin my pocket lol Jun 10 11:16:41 curious Jun 10 11:17:06 im not feeling too much horror so i think it went ok Jun 10 11:17:10 lol Jun 10 11:17:42 damn it why does every client ask for ios and android versions of everything, cant they do one at a time Jun 10 11:18:28 and they never want to pay sensible prices Jun 10 11:21:57 this film is truly awful Jun 10 11:22:07 which Jun 10 11:22:19 "confessions of a teenage drama queen", i know.. Jun 10 11:22:25 loool Jun 10 11:24:59 on the other hand "black balloon" was brilliant Jun 10 11:26:00 i really enjoyed limitless Jun 10 11:26:19 gaz`: They as because they don't know better and the fact that they might get an "Ok, we'll see what we can do." answer? Jun 10 11:26:23 ask* Jun 10 11:26:55 yeh Jun 10 11:27:00 im just sick of doing it Jun 10 11:27:26 ever consider those ugly-looking cross platform frameworks? Jun 10 11:27:41 hehe im waiting for one to mature a bit right now Jun 10 11:27:43 codenameone.com Jun 10 11:28:33 finally one that doesnt rely entirely on HTML5 and JS Jun 10 11:28:41 yeh Jun 10 11:28:51 j2me basically Jun 10 11:29:04 and the cloud builds the ports Jun 10 11:29:06 which is awesome Jun 10 11:29:25 what is awesome? :D Jun 10 11:29:35 *shudder* @ "the cloud" Jun 10 11:29:41 the cloud doing the work instead of u needing to set it all up and have a mac etc Jun 10 11:29:49 :p Jun 10 11:30:31 i dislike "the cloud", but then i also disliked "AJAX" when it first arrived Jun 10 11:30:46 I dislike the cloud Jun 10 11:30:54 I want a computer, not a dumb internet terminal :( Jun 10 11:30:57 whats wrong with the cloud Jun 10 11:30:59 ah Jun 10 11:31:01 its overused Jun 10 11:31:23 i just want to avoid the pain of getting it all set up Jun 10 11:31:41 for example, mendeley and lastpass, i will never use either of them, and the only reason is they force cloud computing on you Jun 10 11:32:05 its marketed as a feature of the services, but certainly not one that I want Jun 10 11:32:30 if i wanted to share my files between multiple devices, i would use my server, or at a stretch my (already existing) dropbox account Jun 10 11:33:52 hehe Jun 10 11:34:03 well to me its a handy blackbox, if it works, Jun 10 11:35:03 i dont disagree that there are valid uses, but it seems overly popular to set up new cloud services rather than using existing infrastructure Jun 10 12:11:50 adapter = new ArrayAdapter(context, android.R.layout.simple_spinner_item, items); This is how I create a spinner for choosing between different Strings. No I want to make it possible to choose betwwen the strings and typing in new one. Is there a simple way to do this or have I write my own SpinnerAdapter? Jun 10 12:15:14 Hello has anyone here used cocos2d before? Jun 10 12:15:16 I get this error :/ Jun 10 12:15:16 projectile.setPosition(20f,winSize.height / 2.0f); Jun 10 12:15:20 Code ^ Jun 10 12:15:30 projectile.setPosition(20f,winSize.height / 2.0f); Jun 10 12:15:32 sec. Jun 10 12:15:41 The method setPosition(CGPoint) in the type CCSprite is not applicable for the arguments (float, float) Jun 10 12:40:13 I wondered, is anyone using Eclipse 4.2? Jun 10 12:57:45 Hey guys Jun 10 12:58:06 Anyone use cocos2d? Jun 10 12:59:21 olimol: I don't. But from the error you pasted, you're trying to pass two floats to a function that only accepts parameters of the type CGPoint. Jun 10 12:59:52 And don't you mean cocos2d-x? Jun 10 13:00:18 yay, rendering problem with Dialog is still present in FragmentDialog, this is annoying Jun 10 13:01:33 Yeah Jun 10 13:01:36 um Kak Jun 10 13:01:37 Its ifne Jun 10 13:01:38 fine Jun 10 13:01:39 i fixed that Jun 10 13:01:52 setPosition(ccp(float, float))? Jun 10 13:01:56 Yeah :) Jun 10 13:02:00 Worked it out. Jun 10 13:02:06 But now, theres a new error Jun 10 13:02:09 if (CGRect.intersects(projectileRect, targetRect)) Jun 10 13:02:12 There is no intersects. Jun 10 13:02:21 would it be containsRect? Jun 10 13:04:05 Sorry, can't help you with that. Jun 10 13:06:39 No worries Jun 10 13:06:40 Thanks anyway Jun 10 13:06:41 :) Jun 10 13:08:02 anyone dealt with a FragmentDialog holding a dynamically resized multi-line EditText? the dialog window seems to be increasing by 2x the change in height required by the EditText Jun 10 13:08:23 basically the more lines i have, the more empty space in the dialog Jun 10 13:12:02 i have a tab widget. when i start the activity that contains the tab widget, is there any way i can specify which current tab to start? Jun 10 13:12:26 from the intent Jun 10 13:13:07 setCurrentTab(int) Jun 10 13:38:07 grrr, wrap_content everywhere and the dialog is much larger than it needs to be Jun 10 13:46:08 Anyone use pontiflex or aarki? Jun 10 13:58:01 I want to modify the SMS app. Is this at all possible, with a rooted phone? Jun 10 14:16:50 guys, how to scroll ListView to the bottom of last item? Jun 10 14:17:29 .setSelection(adapter.getCount() - 1) scrolls to item top. Jun 10 14:18:37 adapter? shouldnt it be your data? (array/cursor) Jun 10 14:18:56 it's my arrayadapter Jun 10 14:19:36 try an actual number instead adapter.getCount() - 1 and see if it works Jun 10 14:19:47 for the sake of testing of course Jun 10 14:20:02 makes more sense to use adapter as the adapter is feeding the listview, and adapter need not necessarily provide access to all elements initially fed to it Jun 10 14:20:07 Well. I can say how it will work: it'll scroll to the bottom of las item, Jun 10 14:20:23 last* Jun 10 14:20:27 top of^ Jun 10 14:21:14 I'm using adapter as an adapter for this listview, of cause. Jun 10 14:21:35 And after data change I want to scroll listview to the bottom. Jun 10 14:23:07 If last item has really big height, than .setSelection() will scroll to this item's top side. Jun 10 14:23:17 http://stackoverflow.com/questions/3606530/listview-scroll-to-the-end-of-the-list-after-updating-the-list looks relevant Jun 10 14:23:33 oh i see i missunderstood your question.. Jun 10 14:23:36 That is not my case. Jun 10 14:23:40 yep :) Jun 10 14:38:03 RelativeLayout any idea how to align two views, one top + above the other, and the other bottom, such that the top view takes any remaining space Jun 10 14:38:34 setting view1 to alignTop and above view2, and setting view2 to alignBottom, forces the parent wrap_content to be much higher than actually necessary Jun 10 14:43:54 seems alignParentBottom stretches the parents height :/ Jun 10 14:44:17 meh, will try TableLayout Jun 10 14:44:51 robb_www: I'd fiddle around with aligning the views to each other, or to the container Jun 10 14:45:36 what im trying to achieve is really simple, the top view contains a multi-line EditText , i just want to make sure that when this layout is used in a dialog the buttons in the 2nd view dont go off the bottom of the screen Jun 10 14:46:19 yes, I understand that... might want to use a linearlayout instead, if it's just two views on top of each other? Jun 10 14:46:38 well, viewgroups, but yes essentially Jun 10 14:48:55 with LinearLayout when the EditText at the top gets too high the buttons clip off the bottom still :/ Jun 10 14:50:05 + the dialog window doesnt resize correctly when the EditText increases its height Jun 10 15:02:21 anyone have a recommendation for an app that shows your physical android device as a window on the computer and lets you use a mouse and keyboard with it? Would be really helpful while dev'ing Jun 10 15:02:54 i use android x86 in a VM personally Jun 10 15:03:40 robb_www, yea, I do the same, but would be nice to have a physical device also Jun 10 15:13:37 blah this is a massive waste of time, ill just leave the dialog taller than it needs to be Jun 10 15:14:00 all i wanted was to emulate a damn BorderLayout :P Jun 10 15:15:44 Can I pasue the activity as long a dialog is displayed? Jun 10 15:23:01 the problem is this. A method is called short before another activity is startet. The methode sometimes displayes a dialog with some informartions, but will disappear when the next activity starts. Jun 10 15:45:55 is this freenode? Jun 10 15:47:37 yep Jun 10 15:47:42 kk ty Jun 10 15:49:50 hate sundays, this is the end of my holiday until september Jun 10 15:50:21 I want to download only a part of the android source... Is this possible using the repo tool, or does it have to be a full copy? Jun 10 15:52:31 or is this channel only for app development? Jun 10 15:52:45 ... I'm an idiot, never mind me Jun 10 15:52:46 only app development Jun 10 15:53:04 is there a channel more appropriate? Jun 10 15:53:30 I don't see how that's not a relevant developer question Jun 10 15:53:33 #android-root has been recommended to people in the past Jun 10 15:53:51 GeeksOnHugs: channel topic says "Android application development!" Jun 10 15:54:05 geeks *shrug* well anything related to the core OS is likely to be better understood by the people working on custom roms Jun 10 15:54:14 thats true Jun 10 15:55:09 on the other hand, the part that I want to get is the packages, which could qualify as apps :P Jun 10 15:56:14 fair enough, i cant help personally Jun 10 15:56:29 well I'll try #android-root. Thanks :) Jun 10 16:18:51 anyone here do android devel only from command line? Jun 10 16:19:30 I440r: ant is your friend Jun 10 16:19:55 thats not the issue. i need a way to single step my code and im not converting to eclipse or idea Jun 10 16:20:59 the equivalent for command-line developers would be printf debugging... Jun 10 16:21:14 no theres jdwp too Jun 10 16:21:20 i just need pro help setting that up Jun 10 16:22:01 once you've figured out... please blog about it :) Jun 10 16:22:36 i dont blog lol Jun 10 16:23:42 write a tech report then :P Jun 10 16:24:18 lol Jun 10 16:31:41 http://codeseekah.com/2012/02/16/command-line-android-development-debugging/ Jun 10 16:32:49 I440r: man, that was fast! Jun 10 16:34:30 i type fast! wouldilietoyou(tm) Jun 10 16:35:08 its not helping though, it assumes your application is already running and you can attach to it. my application wont run, it dies, thats why i need to debug it Jun 10 16:37:29 your app sounds as useful as my own Jun 10 16:37:46 out of interest whats it do? Jun 10 16:37:51 im a pro at writing broken code Jun 10 16:37:52 my app? Jun 10 16:37:59 its an RPG game Jun 10 16:38:02 i write everything right the first time, its meant to crash Jun 10 16:38:06 tile based. like ultima 3/4 Jun 10 16:38:26 but im going to do it so thers NO freeking typing anything Jun 10 16:38:31 <3 tile based RPGs, was very unimpressed when zelda went 2D Jun 10 16:38:33 went 3D^ Jun 10 16:38:41 "where is the princess" so i can gorescue her! Jun 10 16:38:52 the princess is in another castle~ Jun 10 16:38:52 always in another castle >.< Jun 10 16:38:53 its called RetroRPG lol Jun 10 16:38:58 damnit hackkitten :P Jun 10 16:39:02 :3 Jun 10 16:39:08 lolcats Jun 10 16:39:54 currently working on my first app, its a BibTeX reference manager, so far ive got the parsing / browsing done, but editing is a pain Jun 10 16:41:12 请问手机 system/app 目录下的apk们有什么用? Jun 10 16:41:13 android.os.Debug.waitForDebugger() yay just put that in my app :) Jun 10 16:41:30 i dont think anyone here can read that zhangxaochen Jun 10 16:41:37 ok Jun 10 16:41:55 where are you from Jun 10 16:41:59 usa Jun 10 16:42:02 zhangxaochen: 这频道是讲英语的 Jun 10 16:42:09 maybe im wrong :) Jun 10 16:42:10 thx, maxagaz Jun 10 16:42:38 that looks like traditional chinese, not simplified Jun 10 16:42:46 wouldnt simplified be easier on a keyboard? Jun 10 16:43:07 it's simplified Jun 10 16:43:20 you speak chinese? Jun 10 16:43:20 heh not from where im sitting heh but ok Jun 10 16:43:31 i know VERY FEW words, i cant read any Jun 10 16:44:06 haha.. Jun 10 16:44:17 * hackkitten just started learning Mandarin Jun 10 16:44:23 :) Jun 10 16:45:17 could you tell me the function of the apks in folder "system/app" Jun 10 16:47:04 zhangxaochen > on the device's side? Jun 10 16:49:56 could anyone tell me the functionality of the apks in folder "system/app" Jun 10 16:50:38 those are your system apps Jun 10 16:51:06 I mean, are they merely backup for the softwares? or those are really in use each time the system boots? Jun 10 16:51:18 they're used Jun 10 16:51:23 delete one and find out :) Jun 10 16:51:40 also apps that are put there dont have to request root permissions, i dont believe Jun 10 16:51:49 before they can execute them* Jun 10 16:52:28 they're like a jar file, kinda Jun 10 16:54:49 then could I say the installation of an app is just send the package to data/app or system/app? Jun 10 16:55:12 yareally? Jun 10 16:55:18 some parts get unpacked with it Jun 10 16:55:22 but not all of it Jun 10 16:55:45 at least with data/app ones Jun 10 16:56:47 if you stick another apk though under /system/app it should show up next time you reboot though Jun 10 16:57:04 if you give it proper permissions and such (file perms) Jun 10 16:57:46 so you mean i could install an app just by pushing it to folder system/app or data/app? Jun 10 16:58:09 for system apps yes, but user apps that may not work Jun 10 16:58:39 you can use adb to install them as well, or pm on the terminal emulator if you want Jun 10 16:59:40 ive never moved an app to /data/app manually so cannot say what the results would be of that. just tried before with /system/app Jun 10 16:59:58 hmm, how can I update a page in ViewPager? Jun 10 17:00:17 user apps are generally given their own userspace on android so it might cause problems if you simply just move it there Jun 10 17:00:35 sandbox i mean* Jun 10 17:01:30 but maybe not, it might not create that until they run the first time. the permissions for every app under /data/app are generic Jun 10 17:01:44 just part the system group/user Jun 10 17:02:21 though if youre asking, then you must have a rooted phone so just try it and see :) Jun 10 17:03:23 i moved a calculator to system/app , and nothing seems to change Jun 10 17:11:39 thx for your help, yareally.another question. does anyone knows how can i remove the "slide to unlock" module from the system? Jun 10 17:12:00 slide to unlock module? Jun 10 17:12:18 i think pressing the power button to unlock is enough Jun 10 17:13:05 that's kind of an android-root or one of the rooting channel questions. however, some ROMs out there supply a way to disable the unlock screen. I suppose you can take the patch from them Jun 10 17:13:42 android-dev is mostly android application development discussion Jun 10 17:19:36 ok, thx Jun 10 17:19:48 yareally: but the power button can easily be pressed by accident in a pocket or the like Jun 10 17:20:14 im aware and it's not a feature for me :p Jun 10 17:20:21 it's for zhangxaochen :p Jun 10 17:20:29 oh oops Jun 10 17:20:31 CM9 you can disable the lockscreen though zhangxaochen Jun 10 17:20:46 is cm9 out? Jun 10 17:20:54 is it available for thunderbolt? Jun 10 17:21:04 for the thunderbolt? no lol Jun 10 17:21:15 for certain devices there are "unstable" nightly builds Jun 10 17:21:19 thought they were going to be supporting it Jun 10 17:21:21 oh Jun 10 17:21:36 im not aware of anyone on the CM team working on the thunderbolt right now for cm9 Jun 10 17:21:41 if they are, it's news to me Jun 10 17:21:49 since slayher, the guy that was working on it is MIA Jun 10 17:22:27 there's been no commits to the cm9 repositories or gerrit for mecha as far as ive seen Jun 10 17:23:40 you mean on some certain roms we can disable the lockscreen function, yareally? Jun 10 17:24:50 yes Jun 10 17:25:12 there's a method to do it. dunno where you should look for it though in the source if you care to find it though. Jun 10 17:28:50 Hey there! Jun 10 17:28:51 hello Jun 10 17:29:39 I'm trying to use JakeWharton 's ActionBarSherlock, but I'm having troubles setting the theme. Jun 10 17:29:59 I mean, I have to set the application theme to Theme.Sherlock, but I don't know how to do that. Jun 10 17:30:41 I have ActionBarSherlock included as a library project and my activity extends SherlockActivity, but I don't know what exactly to do about the android:theme element in my manifest. Jun 10 17:32:32 How to set my app to a theme that is included in another library project? Jun 10 17:37:08 hi there I was looking for some reference for conversion of Speech to strings I got this link on searching http://developer.android.com/resources/articles/speech-input.html Jun 10 17:37:30 RedNifre: why don't you look at the sample abs demos that are part of the abs source? Jun 10 17:37:42 oh wait, that would be too obvious and common-sense. Jun 10 17:37:49 you're obviously smarter than that. Jun 10 17:38:06 Oh, didn't notice those. Jun 10 17:38:49 can u plz point me to some more reference examples about the same Jun 10 17:39:08 Ah, I think I see where my problem is Jun 10 17:39:10 https://github.com/android/platform_bionic/blob/master/libc/stdlib/locale.c Jun 10 17:39:22 That's one hell of a kludge... Jun 10 18:20:08 I created an developer account and paid but when I visit the play.google.com/apps/publish/ home it keeps redirecting me to signup Jun 10 18:22:29 oh.. I see. It did it under my other account, although I logged out and into another one -- it did that logout/in only for the payment section. Oops. Jun 10 18:28:04 Ologn: haha nice Jun 10 18:28:25 Anyone know why a TextView doesn't get centered if I add it to a Layout dynamically? (but does if I add it statically to the xml) Jun 10 18:37:41 uni are you sure your setting the layout params? Jun 10 18:38:14 robb_www should I? I though setting the parameters to the container in the xml would be enough? Jun 10 18:38:58 for some reason thought you were writing the layout dynamically also, nevermind srry Jun 10 18:39:13 * robb_www procrastinating, need to review a paper :/ Jun 10 18:41:37 i got some weird shit going on here, my app looks to see if theres a database file in its /data/data/com.foo.bar/databases/ directory. if there isnt one it copies the one from resources out to that dir. i can see the file is there by running adb shell and cd'ing into that directory Jun 10 18:41:50 yet when the code goes to open that file i get an exceptiion Jun 10 18:43:34 sqlite exception e = null wtf Jun 10 19:06:20 ok why would i be able to copy an asset out to /data/data/foo.bar.bam/ but then not be able to open it Jun 10 19:06:49 i can adb shell in and SEE the fucking thing Jun 10 19:21:44 so whats a good reason for an app to need access to an sd card? Jun 10 19:21:54 i thought you can already get local storage in /cache ? Jun 10 19:23:10 it would move data out to sdcard Jun 10 19:23:21 thers more storage there and if all apps used /cache it would fill up Jun 10 19:23:35 external storage is better for large data Jun 10 19:23:57 also you can store preferences or settings out there and a factory reset wont remove them Jun 10 19:24:35 having access to /sdcard/ is fine for the most part Jun 10 19:25:23 it seems a little wrong though, since you get access to the entire sd card not just an app-specific portion of it Jun 10 19:25:38 yup Jun 10 19:25:48 most apps create a dir for their use Jun 10 19:25:57 amd u can tell the ones that dont. never saw one that didnt tho Jun 10 19:26:50 how can you tell? Jun 10 19:27:24 looking :) Jun 10 19:29:12 personally i woud just get addons detector Jun 10 19:29:27 and read what it says about each apps addons Jun 10 19:30:43 whats the piint? Jun 10 19:30:48 whats the point* ? Jun 10 19:31:01 it will tell you when you have something that is REALLY bad Jun 10 19:31:09 like air push addons Jun 10 19:31:09 like what? Jun 10 19:31:28 why is it really bad? Jun 10 19:32:14 it is spam in your notification bar. it is known to have pushed false updates to google play Jun 10 19:32:17 its malware Jun 10 19:32:27 go keyboard has it too Jun 10 19:32:47 hmm i see Jun 10 19:33:09 how would i block it though? Jun 10 19:34:02 in other words whats the advantage of knowing an app is using a "really bad" add-on? to uninstall it right away? Jun 10 19:34:21 yes Jun 10 19:34:31 that's the general idea :) Jun 10 19:34:49 sounds interesting Jun 10 19:34:49 i see Jun 10 19:35:06 is there a way to loop over the sharedpreferences? Jun 10 19:35:11 so I can list all the items Jun 10 19:35:17 what firewall are you guys using, droidwall? Jun 10 19:50:17 <[twisti]> is there a list or some other resource of how much texture memory i can reasonably expect devices to have ? Jun 10 19:56:21 [twisti], I've read some HTC allows up to 1024 pixels width Jun 10 19:56:38 hey!!!heyhggyhjhjghgjhjghjgghgjghjhghjhjgjghgh Jun 10 19:56:54 winegoddess: stfu, you're a cat, you don't belong on the computer. Jun 10 19:57:53 <[twisti]> fdelapena: i mean amount Jun 10 19:57:59 I don't know Jun 10 20:08:59 BTW, I'm trying to include android/log.h from NDK but it does not work. Everything else works fine (STL, etc.). I'm using android-12, NDK says there is log.h for android-9 and android-14, is that the problem? Jun 10 20:09:44 it says no such file or directory, and I'm trying to include it in local .mk, and trying to add to the $PATH this folder, but no luck Jun 10 20:11:30 I'm using pelya stuff for compiling something SDL-based, it compiles ok but without android/log.h Jun 10 20:12:33 hello all Jun 10 20:33:31 i need help Jun 10 20:33:46 installing the market on a sdk Jun 10 20:36:54 adb install it? Jun 10 20:46:13 i keep getting a error Failure INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES Jun 10 20:48:59 edwardthefma: try #android-root. it's against market tos to do so and will not be well received here in general. Jun 10 20:49:26 also you probably meant 'avd' and not 'sdk' Jun 10 20:50:52 lol Jun 10 20:51:33 well i only want the market so can can keep up with developing theams that work with go luancher Jun 10 20:51:38 lancher Jun 10 20:51:59 i understand that you want the market. we don't discuss that topic here though. sorry. Jun 10 20:52:08 ok Jun 10 20:52:23 XD who hear plays mincraft Jun 10 20:52:38 nobody with a job Jun 10 20:55:24 lol Jun 10 20:57:46 tried to use the "alignWithParentIfMissing" attr on a RelativeLayout child to reduce nesting, but it didn't seem to work Jun 10 20:57:50 anyone use this one before? Jun 10 20:58:08 I ended up removing the attempt and nesting instead :( Jun 10 20:58:29 edward, i did for a while, but not for ages (didnt like the introduction of magic) Jun 10 20:59:04 readme, i had a horrible time earlier trying to deal with relativelayout :( Jun 10 20:59:19 I've used em a million times... but this one attribute is a dusty corner Jun 10 20:59:25 alignParentBottom in a dialog stretches the dialog height Jun 10 20:59:48 maybe you could offer some advice there , if you dont mind taking a look at my layout? Jun 10 20:59:52 paste it Jun 10 21:00:21 robb_www: yes, thats how its supposed to work Jun 10 21:00:58 it's a recursive definition if your parent has wrap_content and your child has alignparentbottom Jun 10 21:01:06 http://pastebin.com/uxBEPNkk Jun 10 21:01:54 what i wanted was a dialog where an EditText can resize, until the height is such that it would push the buttonbar off the bottom of the screen, so i align the buttonbar to the bottom Jun 10 21:02:08 not quite what i wanted, but its OK at the moment Jun 10 21:02:22 of course when i try a test case for my problem Jun 10 21:02:26 it's not reproducable :) Jun 10 21:02:51 which attribute are you asking about Jun 10 21:02:57 where did you put the alignParentBottom Jun 10 21:03:39 "@+id/LinearLayout2" Jun 10 21:03:51 although yuizy has just clarified that its to be expected Jun 10 21:04:00 I think you should use a LinearLayout for the outer layout Jun 10 21:04:23 you can use gravity to stick the children of the bottom LinearLayout to the bottom Jun 10 21:04:32 and you can take up arbitrary ratio of the screen using weights Jun 10 21:04:38 will it not be forced off the bottom if the EditText tries to resize? Jun 10 21:04:51 do you want it to be bumped off the bottom? Jun 10 21:04:54 no Jun 10 21:04:54 and hidden? Jun 10 21:05:01 no, it won't Jun 10 21:05:14 hmm ok, ill give that a try now, thanks for the hint Jun 10 21:05:27 use wrap_content for anything that should grow to fit the size of its content Jun 10 21:05:37 *nod* Jun 10 21:05:50 then for any children that need to take up the remaining space, layout_height="0dp" layout_weight="1" Jun 10 21:08:14 yer used that one before, just not quite familiar with gravity, i assumed gravity for a linearlayout only applied to how items were layed out within the layout Jun 10 21:08:53 setting gravity to bottom for the buttonbar linearlayout does allow the buttons to clip off the bottom of the dialog still :/ Jun 10 21:10:00 ok so im reading two bytes and constructing a short. when hte bytes are 0xff and 0xff the short becomes 0xfeff Jun 10 21:10:01 why? Jun 10 21:10:59 robb_www: the gravity only effects the behavior of the child INSIDE the parent LinearLayout Jun 10 21:11:06 if you set the gravity of a LinearLayout to bottom Jun 10 21:11:17 all the children in it will cling to the bottom, regardless of how big it is Jun 10 21:11:52 readme quite, so when the linearlayout has no space because the EditText has increased its height, having added extra lines, it clips Jun 10 21:12:01 Jun 10 21:12:22 oh, I see Jun 10 21:12:34 set it to wrap_contnet Jun 10 21:12:37 wrap_content* Jun 10 21:12:47 which part? Jun 10 21:13:27 aha! Jun 10 21:14:04 the problem was having the EditText in a LinearLayout which didnt hold the horizontal ButtonBar LinearLayout Jun 10 21:14:24 all solved (FINALLY), thanks very much, i probably wouldnt have bothered looking at it again otherwise Jun 10 21:14:36 hello Jun 10 21:16:46 im interested in exchanging data between a web server and my android app. I know I need to use a REST service. My question is though, what kind of web hosting does my domain need and what type of database will I have to set up? Jun 10 21:20:39 why does (((short) 0x00ff) << 8) | (short) 0x00ff) equal 0xfeff ? Jun 10 21:20:40 wtf over? Jun 10 21:24:01 uaeHamed: what you want to do is store the data on the web server as JSON Jun 10 21:24:20 then POST to it from your Android app Jun 10 21:26:51 Thanks Jabo. Jun 10 21:27:22 So I need a domain + webhosting that supports JSON? Jun 10 21:27:37 yep Jun 10 21:27:50 basically AJAX and JQuery Jun 10 21:27:59 uaeHamed: http://www.copterlabs.com/blog/json-what-it-is-how-it-works-how-to-use-it/ Jun 10 21:28:30 robb_www: got mine to work as well Jun 10 21:29:15 apparently alignWithParentIfMissing cannot use layout_alignParentX.. not sure how it chooses what side of the aprent to align to when the anchor is missing, but I think it bases it off what you used, i.e.layout_above seems to map stuff to the bottom of the parent Jun 10 21:29:37 so my very complicated layout currently uses no nesting :) Jun 10 21:37:52 hi I have a quick question (i hope)... Jun 10 21:38:06 I'm building an app for API 11 and there is ONE API 14 call I want to use. It's not a required thing, but I want to include it in the apk but have it only happen if the app is installed on api 14. .otherwise it can just be ignored.. is there any easy way to achieve that? Jun 10 21:38:26 when I try to complie with the call in there for 3.0 it won't .. and when I complie for 4.0 it won't install on 3.0 devices obviously Jun 10 21:38:55 why wouldn't it install on a 3.0 device... obviously? Jun 10 21:39:25 because the call i'm using doesn't exist yet Jun 10 21:39:49 yep, you're another one of those guys that knows everything, right? Jun 10 21:40:09 wow no need to be a jerk.. i'm just asking a question Jun 10 21:40:13 clearly I don't know. since I'm asking Jun 10 21:40:25 use reflection Jun 10 21:41:15 readme, what are you working on if you dont mind me asking? Jun 10 21:42:05 Jabo: Thanks for the link, its very useful. Im wondering, how will I set up this web server? Obviously I need to buy a domain with some web hosting capability, but after that ? Jun 10 21:43:18 itslennysfault: I've dealt with too people who talk about their problems using qualifiers as if they know exactly why its happening. Jun 10 21:44:10 I have one line of code it's essentially actionbar.setLogo (I'm using it to set the logo dynamically based on what page the user is on) ... I'm just afraid that that line of code will cause an error when executed on 3.0 since it didn't exist. Jun 10 21:44:27 I was just wondering if there is a try() catch kinda thing I can do so it won't cause an error Jun 10 21:44:34 Or with people demanding instruction on how to implement a "solution" to their problem that actually has nothing to do with their problem. Jun 10 21:44:54 candide! Jun 10 21:45:07 candide: xy Jun 10 21:45:07 The XY problem: You want to do X, but don't know how. You think you can solve it using Y, but don't know how to do that, either. You ask about Y, which is a strange thing to want to do. Just ask about X. Jun 10 21:45:40 Anyone here using ProGuard on app that is in Play Store ? Jun 10 21:46:12 Do you use some setting to get unique function names Jun 10 21:46:33 bit annoying to read crashlogs when half of the functions in a class are named 'a' Jun 10 21:46:50 I guess it makes it hard to read for crackers too but ... Jun 10 21:47:02 obfuscation is dumb Jun 10 21:47:21 ok. Jun 10 21:47:26 uaeHamed: http://www.hunlock.com/blogs/AJAX_for_n00bs Jun 10 21:47:45 pragma-: nice input, anyone else? Jun 10 21:47:46 uaeHamed: and read the documentation here http://jquery.com/ Jun 10 21:47:55 * pragma- smiles cheerfully. Jun 10 21:50:09 proguard generally doesn't obfucate all of it anyways, but given enough time anyone that knows enough about programming can reverse it and figure out what the app does Jun 10 21:50:19 especially in java Jun 10 21:50:41 which is basically how craft bukkit are able to provide server-mods for minecraft, which is obfuscated Jun 10 21:51:29 the obfuscation I had seen in Android applications was very easy Jun 10 21:51:31 yareally: well same applies to anything, doh Jun 10 21:51:40 especially since you can't obfuscate externals Jun 10 21:51:42 of course, but it's very easy to do in java, compared to c++ Jun 10 21:51:42 the irony of the whole thing is if you don't obfuscate your shizzle, then crackers don't find it a challenge or even a necessary target to troll Jun 10 21:51:49 <[twisti]> proguard generally brings your stuff to a point where only people who could rewrite your app on their own can do anything with the decompiled output Jun 10 21:51:53 reversed android java is a bit harder to read than reversed java java, but either is readable enough Jun 10 21:51:56 aolin: it's harder to do so in non-JVM systems Jun 10 21:52:06 well slower Jun 10 21:52:08 not harder Jun 10 21:52:12 but if you do obfuscate, you are just asking trolls to try to crack it and then when they succeed, they'll troll the shit out of your servers to reap the glory Jun 10 21:52:13 and iirc .NET includes support for encrypted bytecode by default Jun 10 21:52:16 * pragma- nods. Jun 10 21:52:43 aolin: harder. JVM leads to quite rigid code structure Jun 10 21:52:47 so how on earth are you expected to keep, for example, dropbox API keys secret? Jun 10 21:52:47 just keep the bank vault unlocked and wide open all the time and no theives will bother to rob it! Jun 10 21:52:50 mot sure I follow Jun 10 21:52:50 * pragma- wise. Jun 10 21:52:59 I should not obfuscate because? Jun 10 21:53:11 it'll make it harder to debug your app? Jun 10 21:53:11 the dropbox example projects include wonderful lines like "write your key here.. but dont EVER do this in real life, you should protect your key.. somehow" Jun 10 21:53:25 and it's not overly useful Jun 10 21:53:40 oh, you can obfuscate if you want. Dunno if it will help you with anything, other than the ability of obfuscator to strip unused code Jun 10 21:53:49 like say you want to get a log cat from a user, it's not going to be as nice to read Jun 10 21:54:18 well it atleast protects some parts of my code Jun 10 21:54:28 s/log cat/stacktrace/ Jun 10 21:54:37 protects from whom? those that really want it will get it Jun 10 21:54:42 maybe low hanging fruit won't Jun 10 21:54:44 * p_l used to read obfuscated code without problems Jun 10 21:54:52 this is supposed to be an open source community ffs :P Jun 10 21:54:52 or they'll have to wait until someone dles does Jun 10 21:54:57 grep usually was enough of a tool (for Android, at least) Jun 10 21:54:59 else* Jun 10 21:55:02 * pragma- reads the ioccc winners while eating his breakfast. Jun 10 21:55:31 * pragma- also does perl. Jun 10 21:55:34 well atleast it's not obvious how to crack it when it's obfuscated Jun 10 21:55:45 if you're worried about some big company like zynga stealing your next amazing game, they'll do it whether you obfusicate or not Jun 10 21:55:52 aolin: what do you think I did with the obfuscated code? :P Jun 10 21:55:54 lol, zynga. Jun 10 21:56:09 yeah, i cite them since they did :) Jun 10 21:56:12 ill obfuscate my code by writing it all in forth. ha! pwned Jun 10 21:56:31 yareally: canadiancow|work here thinks he's some sort of CEO at zynga Jun 10 21:56:37 oh yeah? Jun 10 21:56:48 he's also very socially awkward :) Jun 10 21:56:53 haha Jun 10 21:56:55 funny Jun 10 21:56:57 I mean what's the point using all these google lisence servers etc if you don't bother even to obfuscate? Jun 10 21:57:18 google drm has been cracked multiple times anyways Jun 10 21:57:20 for apps Jun 10 21:57:25 whats the point in using DRM at all? anyone determined enough will get your apk Jun 10 21:57:37 aolin: as it happens, you can't obfuscate the parts that call LVL, because you need to reference external symbols... Jun 10 21:57:39 man my head hurts Jun 10 21:57:41 you could say the same about security guards in shops Jun 10 21:57:55 yep but its still using 20 minutes vs. 5 hours vs. paying 2 euros Jun 10 21:57:57 * Ge0rG provides his paid app as a free download from the homepage, and still has 70% paid users Jun 10 21:57:58 infact, you could say the same about most encryption algorithms Jun 10 21:58:21 users want convienace more than anything and drm can make that harder to provide Jun 10 21:58:45 will* Jun 10 21:58:51 I have an app that does absolutely nothing but announce that my app has moved to a different package name and opens a market:// link to it... Jun 10 21:58:54 whether one uses it or not, it's up to them, but i generally think it's not worth it Jun 10 21:58:57 (since I renamed my app) Jun 10 21:59:07 lol Jun 10 21:59:08 and people KEEP downloading that redirector and 5-starring it and keeping it installed Jun 10 21:59:13 pragma, i would pay good money for that app Jun 10 21:59:17 how many of you have paid apps in Play Store? Just curious because this discussion has odd twist :) Jun 10 21:59:38 i Jun 10 21:59:43 I'm going to unpublish it on monday L/ Jun 10 21:59:45 :/ Jun 10 21:59:54 i'm not going to keep my doors unlocked when I leave home even though I know the windows are very easy to break Jun 10 22:00:08 I have Jun 10 22:00:18 i lock my doors, because it's harder to file an insurance claim if you tell them the burglers just walked in Jun 10 22:00:32 yareally: you can just tell them that you had your doors locked. Jun 10 22:00:32 not so much because it's overly safer Jun 10 22:00:43 well that works until you file a police report Jun 10 22:00:51 and the cops ask how they got in when they're at your place Jun 10 22:00:58 they /might/ have picked the lock, maybe Jun 10 22:01:00 the burglars unlocked the doors when they left. Jun 10 22:01:09 * hackkitten kicks Eclipse in the shins for being difficult again Jun 10 22:01:36 obviously the burglars aren't going to crawl back out the broken window Jun 10 22:01:42 they'll just carry your tv out the front door... Jun 10 22:01:44 true you could lie, but that's also a felony Jun 10 22:01:59 anyway I do have c++ part in my app, I'll have some crack proofing there too. But it will never be 100%, that was never the point Jun 10 22:02:01 man-made laws. Jun 10 22:02:27 it's just hard enough ... so cracking it does not come for free Jun 10 22:02:41 sounds sensible Jun 10 22:02:53 dissambling c++ is not overly fun Jun 10 22:03:08 well I've done reverse engineering windows binaries for work Jun 10 22:03:13 it's not that hard Jun 10 22:03:15 windows is mostly C Jun 10 22:03:17 just slow Jun 10 22:03:19 the police lie all the time. Jun 10 22:03:20 c is far easier Jun 10 22:03:55 yareally: I meant windows executables not windows per se Jun 10 22:04:00 ah okay Jun 10 22:05:16 is it still common to have copied+cracked+malwared apps uploaded to play store Jun 10 22:05:46 of course Jun 10 22:06:06 http://thedroidguy.com/2012/06/android-malware-ddspy-acts-as-gmail-and-steals-user-data/ Jun 10 22:06:11 how do you get rid of them if your app is uploaded ? Jun 10 22:07:31 report them to google Jun 10 22:08:00 personally, I ascribe to darwin's theory and let the morons that install malware die off Jun 10 22:08:15 lost your credit rating? see ya! Jun 10 22:08:30 better luck next life! Jun 10 22:08:32 sounds like a good rationale to me Jun 10 22:09:43 if I were king of the world, I would first demand that all safety and warning labels and signs be removed and torn down Jun 10 22:09:54 that would be my first and foremost mandate. Jun 10 22:11:27 why would you want to modify the environment to make it more hostile? Jun 10 22:12:13 its only as hostile as your lack of common sense Jun 10 22:12:44 you mean that social construct based on the experience of your peers? Jun 10 22:13:13 some of the same peers you may be killing off Jun 10 22:14:20 dont know about you but I rely on stupid people to do mundane tasks on a daily basis, I wouldnt necessarily expect the world to be a better place without them Jun 10 22:14:28 you don't need to watch other people do stupid things to know not to do them yourself. when you first see fire, if your first instinct is to try to thrust your hand into it then I'm more than happy to see that moron get killed off... Jun 10 22:14:57 you use your own common sense to approach things with a degree of caution and to test how far you can go with things Jun 10 22:17:15 when you first see fire, if its controlled i dont see why you would have any fear response Jun 10 22:17:46 you don't need fear to stop you from doing stupid things. Jun 10 22:17:59 but you need to understand the risk to exercise caution Jun 10 22:18:23 you simply just don't run around like a moron touching everything you see as if it might be a soft pillow... you approach things gingerly and slowly and examine it carefully from angles before you touch it Jun 10 22:18:28 you might even poke it with a stick or throw a rock at it Jun 10 22:18:37 lol Jun 10 22:19:01 some of the things are less obvious Jun 10 22:20:13 on the opposite side of the same coin -- those little FCC approved radiation stickers on your phones? yeah, I still wouldn't sleep with them near your head. Jun 10 22:20:24 no Jun 10 22:20:35 no FCC here :) Jun 10 22:20:37 strange, i have no fear of mobile phones Jun 10 22:23:02 I have nomofobia Jun 10 22:23:27 no-mobile-phone phobia Jun 10 22:23:31 that's like when phone runs out of battery and no charger around Jun 10 22:23:50 or it gets stolen and it takes a while to get a new SIM etc Jun 10 22:24:04 god forbid you can't play angry birds on a pay phone! Jun 10 22:24:09 had a phone stolen once, was enraged Jun 10 22:24:52 yeah or play spotify until 4pm drunk in foreign country, and then realize in the morning that you counted on the battery lasting whole trip :) Jun 10 22:24:59 happened to me last weekend :) Jun 10 22:25:01 i dont care too much if i dont have access to my phone, but being without an internet connection for more than a day is a very strange experience Jun 10 22:25:02 4am Jun 10 22:25:43 robb_www: well I don't care too much about the phone part either Jun 10 22:25:55 robb_www: it's the social media etc that I can access Jun 10 22:26:21 email, RSS, web browsing, i only check facebook a few times a day if im bored Jun 10 22:26:22 oh noes, you won't be able to let people know that the foreign food is disturbing your bowel movements! Jun 10 22:27:33 pragma: no, not really, but I can't stalk all the girls that are out-of-my-league but still somehow friends in facebook Jun 10 22:28:21 I got 99 friends on facebook and ain't but a one in real life Jun 10 22:28:50 (for dubious value of real) Jun 10 22:29:10 need to irc less then Jun 10 22:29:23 too many inception/matrix/philosophy books/etc Jun 10 22:29:51 well maybe they're your friends then Jun 10 22:30:20 friendship is an illusion. people are ultimately defined by their personal selfish needs when the moment counts. Jun 10 22:31:23 I'm sure you're a blast to hang out with :) Jun 10 22:31:33 I'm the life of the parties Jun 10 22:32:07 because I can actually have fun, and not worry about which social circle I'm standing near or in Jun 10 22:32:45 nihilism isnt particularly useful Jun 10 22:32:53 nihilism is freedom Jun 10 22:33:13 there are many flavors of nihilism, you know... not all of us want to see the world burn Jun 10 22:33:28 for example, its easy to argue that everyone is selfish, but it is still "good" for them to selfishly act in a way that others perceive as altruistic Jun 10 22:33:30 * pragma- is just indifferent to it. Jun 10 22:33:44 social circles ... right ... we're all prisoners of our social circles .... lol Jun 10 22:33:48 altruism is a useful concept there.. denying altruism by semantics is pointless Jun 10 22:34:09 sure, I do some good things so some people will do some good things for me, that's selfish. Jun 10 22:34:37 but what is useful about deciding that other people do good things for selfish reasons? Jun 10 22:34:49 I don't concern myself with affairs of other people Jun 10 22:36:16 I'm not saying that I'm a psychopathic unemotional theif that would upend people's lives for my benefit... unless I was desperate. Jun 10 22:36:22 unempathetic Jun 10 22:36:30 heh, i didnt think you were Jun 10 22:36:44 although i suppose its reassuring to hear it :P Jun 10 22:36:59 honestly, I do think I'd be more likely to let myself starve to death than to steal bread from a happy family. Jun 10 22:37:12 i think you're just trying to justify why you don't have more friends Jun 10 22:37:12 unless that family were well-fed Jun 10 22:37:27 I don't want friends... they limit my worldly experiences. Jun 10 22:37:39 right. Jun 10 22:37:45 I have far more fun meeting strangers and having a blast with them Jun 10 22:37:59 but once someone starts to care about me to the point where they start suggesting I live differently... Jun 10 22:38:06 and they're not your friends after 1 hour? Jun 10 22:38:13 aolin: hope not! :) Jun 10 22:38:27 i have a large number of acquaintances, but maybe 20-30 friends, of which 5 or so i would consider close Jun 10 22:38:34 well they probably are until you start talking :) Jun 10 22:38:41 * pragma- chortles. Jun 10 22:39:46 robb_www: if you had a wedding, how many of your friends would you invite (if there wasn't added cost) Jun 10 22:40:44 id probably invite around 50 people that I can call friends. ..but close friends are a few Jun 10 22:40:44 honestly no idea Jun 10 22:41:01 yer, it would be more than that 30 Jun 10 22:41:19 partly because work colleagues end up assimilated into the friendship group Jun 10 22:46:07 reviewing a paper, i want to suggest its accepted, but have some fairly harsh criticism that needs addressing, not sure how to avoid coming off as a prick :/ Jun 10 23:17:43 does RandomAccessFile.readByte() advance the file pointer on read? Jun 10 23:23:06 I could watch this all day http://www.youtube.com/watch?v=m8GYZttNqwc Jun 10 23:25:56 I find this one fascinating too with the spanish subtitles: http://www.youtube.com/watch?v=uUvOssCeCqw Jun 10 23:43:45 http://www.youtube.com/watch?v=IrznmH3XZQ8 Jun 10 23:47:45 ok so im looking at a binary file on my pc that i have in my apps /data/data directory, my app is reading bytes out and im looking at the current file offset it just read from. the byte it read is (like all the ones previous to this) 0x00. the byte within the file is 0x2d Jun 10 23:47:50 http://www.youtube.com/watch?v=Bt2HtG014Tc Jun 10 23:48:01 am i using RandomAccessFile.readByte() wrong? Jun 10 23:48:12 how tf do you use that wrong Jun 10 23:48:49 i did a seek() followed by a bunch of readsand im not getting the data from the file Jun 10 23:53:13 hi Jun 11 00:20:08 How can I change views when using ViewPager? I inflate some xml's with widgets in them. Place it in ViewPager in my activity - Can I access widgets from my activities class? Jun 11 00:23:55 anyone know how to ask intellij's XML editor to stop rendering the preview layout? Jun 11 00:24:08 I've got a complicated enough layout that it's actually causing the editor to lag significantly Jun 11 00:24:12 and it's very annoying Jun 11 00:28:38 off to sleeps, got a new student to supervise tomorrow morning which should be interesting Jun 11 00:28:46 gnight readme, and thanks again for earlier Jun 11 00:29:13 readme: just collapse the pane Jun 11 00:31:21 I thought that didn't do the trick last time. I'll give it another shot Jun 11 00:31:26 maybe the lag isn't caused by the rendering Jun 11 00:37:41 I need help with adding a notification to the notification from within a widget Jun 11 00:37:45 Anyone work with this at all? Jun 11 01:01:05 I have a sound that plays in my AppWidgetProvider Jun 11 01:01:13 Do I need to release my sound? Jun 11 01:01:30 Because I don't think there is a onPause method or anything..? Jun 11 01:45:34 are there any long-standing implications of keeping threads around for a long time beyond pure memory usage? Jun 11 01:45:56 threads that are just sitting on .wait() calls Jun 11 01:47:56 Hey guys :) Jun 11 01:48:10 I've been trying to add score all day today for my game Jun 11 01:48:16 but.. it hasnt been working Jun 11 01:48:25 Whats the most effective way to add it? Jun 11 01:49:21 Hey kaspuh, ever made a score counter? Jun 11 01:51:19 your question is so vague I can only reply "with the + operator". please provide more detail Jun 11 01:54:27 um Jun 11 01:54:30 Ok, i know that Jun 11 01:54:40 but how can i update it onto the label in the other class? Jun 11 01:54:47 i know where to update it Jun 11 01:55:02 but, for some reason it wont let me update the label from another class Jun 11 01:55:54 JakeWharton :) Jun 11 01:56:08 is that class "Android 101"? :) Jun 11 01:56:35 :o? Jun 11 01:56:44 The class is the main Activity Jun 11 01:56:45 lol Jun 11 01:57:09 we're about 20% to the required information we need to help you Jun 11 01:57:58 mmk. Jun 11 01:58:01 one moment Jun 11 02:00:39 Ok. Jun 11 02:00:40 http://pastebin.com/t32WCV78 Jun 11 02:00:54 I need it to update the text inside the updateLives function Jun 11 02:01:02 from the activity class Jun 11 02:02:10 better description? Jun 11 02:05:06 JakeWharton <3 Jun 11 02:10:35 When I change orientation on the emulator from portrait to landscape and back to portrait, it doesn't show my portrait layout Jun 11 02:10:41 does anyone know what would cause this? Jun 11 02:11:32 there's no code in the activity other than setContentView in onCreate and I've simply put a layout in layout-land and layout. do I need to use layout-port? Jun 11 02:12:24 no Jun 11 02:12:37 does it rotate back or stick to landscape at 90 degrees? Jun 11 02:12:38 oh my fucking god Jun 11 02:12:41 i hate dialogfragments Jun 11 02:12:52 worst. idea. ever. Jun 11 02:12:54 JakeWharton: it gets stuck after I switch it to landscape by hitting 9 Jun 11 02:13:12 i'm pretty sure that's just emulator flakiness Jun 11 02:13:16 :| Jun 11 02:13:18 try toggling back and forth again Jun 11 02:13:38 canadiancow|work: they work wonders here. you're holding it wrong Jun 11 02:13:41 goddern emmeraters Jun 11 02:15:36 I made a killer layout with intellij today Jun 11 02:16:00 barely any nesting, works on all screen sizes.. except tablets will need a better solution because it doesn't make use of all the space.. it does work, though. Jun 11 02:16:16 can switch so easy between the previews.. that is horribly broken in eclipse Jun 11 02:20:38 JakeWharton, did you see my previous message? Jun 11 02:27:35 Hey guys, could someone help me fix something up? Jun 11 02:30:41 What do you need Jun 11 02:30:57 Uhm, if you scroll up you will see my message :) Jun 11 02:31:01 Its a bit long. Jun 11 02:32:23 textViewVar.setText("the text"); Jun 11 02:32:45 TextView textViewVar = (TextView)findViewById(R.id.textViewId); Jun 11 02:34:03 What if its in the activity thing? Jun 11 02:34:04 Class Jun 11 02:34:11 activity.label ? Jun 11 02:34:14 uh? Jun 11 02:34:23 Do you pass a context? Jun 11 02:34:45 I see your problem Jun 11 02:35:16 RemoteViews views = new RemoteViews("package.name.com", R.layout.YOURLAYOUT); Jun 11 02:35:25 and there should be a method inside that to change text Jun 11 02:35:34 Oh ok. Jun 11 02:35:36 Thanks. Jun 11 02:35:53 views.changeTextOrSomethingLikeThat(R.Id.OfTextView, "text"); Jun 11 02:35:56 something along those lines Jun 11 02:37:02 views.setTextViewText(R.id.blah, "text"); Jun 11 02:40:07 Thanks TDub Jun 11 02:40:09 Ill work it out :) Jun 11 02:40:16 k, gl. Jun 11 02:40:25 If you pass a context to the class it would make it easier Jun 11 02:40:34 anything that gives you an error just add the context Jun 11 02:40:44 context.findViewById(blah) Jun 11 02:40:46 type thing Jun 11 02:40:53 Alright Jun 11 02:40:56 assuming the Context variable is called context Jun 11 02:41:28 public int updateLives(int lives, Context context) Jun 11 02:41:30 type thing Jun 11 02:41:42 and just send updateLives(5,this); Jun 11 02:41:54 Ill bbl **** ENDING LOGGING AT Mon Jun 11 02:59:58 2012