**** BEGIN LOGGING AT Thu Oct 09 03:00:00 2014 Oct 09 03:00:02 Yeah, that's not really a valid argument. Oct 09 03:00:15 the only diff between java and C# in this regard is that java has checked exceptions that any library developer can catch and throw an unchecked exception if they so choose Oct 09 03:00:18 "The concern I have about checked exceptions is the handcuffs they put on programmers. You see programmers picking up new APIs that have all these throws clauses, and then you see how convoluted their code gets, and you realize the checked exceptions aren't helping them any. It is sort of these dictatorial API designers telling you how to do your exception handling. They should not be Oct 09 03:00:18 doing that." Oct 09 03:00:20 whoever was askinga bout method count in Intellij get the metrics reloaded plugin Oct 09 03:01:07 That's a key issue with checked exceptions: the API designer is telling the client how to code. It's a weird coupling that causes headaches. Oct 09 03:01:17 yeah. Oct 09 03:01:18 Since when does the API writer tell the client which exceptions he/she should handle? Only the client knows. Oct 09 03:01:41 I mean you could just wrap it in uncheck if you wanted. Oct 09 03:01:47 Outside of the lib Oct 09 03:01:49 I do that from public methods. Yeah. Oct 09 03:01:59 I think it's nice to know when I'm using a library though. Oct 09 03:02:48 Checked exceptions are great when you can handle them right now. It's just when they need to bubble up the stack that you get the "throws FooException, BarException, BazException" headache. Oct 09 03:03:09 Many people just end up writing "throws Exception". Oct 09 03:03:16 Then you lose any benefit. Oct 09 03:03:16 TacticalJoke nobody does that Oct 09 03:03:21 Some people do. Oct 09 03:03:34 those people are ignorant Oct 09 03:03:40 and have no business writing software Oct 09 03:03:49 I don't necessarily agree. Oct 09 03:03:50 http://en.wikibooks.org/w/index.php?title=Java_Programming/Checked_Exceptions&action=edit§ion=1 Oct 09 03:04:01 They could do that and then document the exceptions in an appropriate place. Oct 09 03:04:22 JacobTabak: +1 Oct 09 03:04:23 The idea that every method that throws an exception *has* to document, right there and then, every exception that it throws is hugely limiting. Oct 09 03:05:34 When I first came to Java, I thought checked exceptions were amazing. Then I started using them... Oct 09 03:05:35 i don't mind explicitly ignoring exceptions in certain parts of my code that i don't care about Oct 09 03:05:48 Do you use SneakyThrows or similar? Oct 09 03:06:08 i'm talking about ORM stuff primarily Oct 09 03:06:55 and no, i don't use that Oct 09 03:07:35 i don't mind checking for null in some cases Oct 09 03:07:38 i am wondering if this debate is more or less nerdy than say, startrek versus starwars Oct 09 03:08:13 has anyone written an api ? Oct 09 03:08:16 ironically i'm about to throw an uncehcked exception Oct 09 03:08:21 Aren't we writing APIs all the time? Oct 09 03:08:28 well good code is Oct 09 03:08:34 but i mean an actual api that is used as such Oct 09 03:08:53 Not really. I've always focused on apps. Oct 09 03:08:55 i got some github stars does that count Oct 09 03:09:25 plus i contribute to lots of open source Oct 09 03:09:32 omg Oct 09 03:09:35 JacobTabak: Which unchecked exception are you throwing? :D Oct 09 03:09:38 just saw a commit message "Added the Bottom Button Bar Back Button" Oct 09 03:09:42 what a mouthful Oct 09 03:09:50 TacticalJoke stuff for invalid parameters Oct 09 03:09:53 Okay. Oct 09 03:09:59 It'd be fun if those were checked. lol Oct 09 03:10:03 g00s Oct 09 03:10:04 heh Oct 09 03:10:52 anyone know how to fix this issue? http://pastebin.com/MBJLnuZd Oct 09 03:11:04 i am running tests via Maven/Teamcity Oct 09 03:11:13 just added Sugar ORM and thats broken it Oct 09 03:11:16 STUB! Oct 09 03:11:28 are you using robolectric? Oct 09 03:11:32 yes Oct 09 03:11:38 are u running from the IDE or CLI? Oct 09 03:11:50 CLI Oct 09 03:11:52 from team city Oct 09 03:12:08 it works in the IDE Oct 09 03:12:09 but it happens locally from cli right Oct 09 03:12:43 are you using gradle to run the tests? Oct 09 03:12:52 maven Oct 09 03:13:04 i thought maven was a dependency manager Oct 09 03:13:10 how can you run tests with maven Oct 09 03:13:16 i guess im not the right guy to ask Oct 09 03:13:29 mvn does both, build/dependency Oct 09 03:14:40 so does it happen locally? Oct 09 03:17:31 yea its also failing locally Oct 09 03:17:51 all tests just return Stub! Oct 09 03:17:54 not sure what it means Oct 09 03:18:29 i think it means its trying to use android platform code Oct 09 03:18:43 but if i run the tests in studio they work Oct 09 03:18:45 maybe its because of the support lib dependency in sugar? Oct 09 03:19:29 hmm Oct 09 03:25:04 why does it even have that dependency? Oct 09 03:25:07 i cant see it used anywhere in the lib Oct 09 03:25:41 JacobTabak: maven is build system Oct 09 03:26:03 yea i did some homework after i realized i was ignorant Oct 09 03:26:16 before gradle some people were using it to build android Oct 09 03:26:22 but now... I geuss gradle will be better Oct 09 03:26:27 *guess Oct 09 03:26:43 sadly ive worked on many projects built with maven Oct 09 03:26:58 it got official support and if you dont have lib in maven central, then you can just put jar in lib/ folder Oct 09 03:27:01 just not thinking when i said it Oct 09 03:27:10 personally I like maven Oct 09 03:27:14 but not with android Oct 09 03:28:18 android is kinda special ;) Oct 09 03:28:49 and dont know why but I feel like many people just dont write tests on android Oct 09 03:29:08 gordon_ because its a pita Oct 09 03:29:34 starting an emulator takes 10 minutes, robolectric is a hack Oct 09 03:29:49 now you can run them on genymotion Oct 09 03:29:58 and have it turned on all the time Oct 09 03:30:02 so it runs like... 3 seconds Oct 09 03:30:53 hey Napalm Oct 09 03:30:58 hey Oct 09 03:30:59 if buck is that good, you can run them faster Oct 09 03:31:09 g00s: just saw a commit message "Added the Bottom Button Bar Back Button" Oct 09 03:31:13 lol Oct 09 03:31:25 mouthful indeed Oct 09 03:31:26 and someone is cooking pretty good in the neighborhood Oct 09 03:31:35 gordon_ without CI tests are pretty useless Oct 09 03:31:52 g00s: we it me and you that looked into night and not-night qualifiers? Oct 09 03:33:17 JacobTabak: nobody said that you cannot have your own CI server with genymotion turned on? ;) Oct 09 03:33:55 well, i did answer your question, didn't i? Oct 09 03:34:13 you: "and dont know why but I feel like many people just dont write tests on android" me: "because it's a PITA" Oct 09 03:34:54 Napalm yes Oct 09 03:35:09 turns out you can call updateConfiguration on ActivityManager Oct 09 03:36:53 Some people have reported a bug regarding onPrepareOptionsMenu: https://code.google.com/p/android/issues/detail?id=24231 Oct 09 03:36:59 And http://stackoverflow.com/questions/12886751/jelly-bean-not-calling-onprepareoptionsmenu-when-opening-the-menu-for-the-firs . Oct 09 03:37:09 JacobTabak: yes, I know, I know Oct 09 03:37:13 Napalm i don't see updateConfiguration on ActivityManager Oct 09 03:37:19 just saying what can be done Oct 09 03:37:28 g00s: check IActivityManager Oct 09 03:38:40 hm yeah its in there Oct 09 03:39:13 g00s: its how setRequestedOrientation works Oct 09 03:39:28 g00s: and android.Manifest.permission.CHANGE_CONFIGURATION Oct 09 03:40:50 Napalm hm, so do you have to call that with reflection then ? Oct 09 03:41:08 perhaps not Oct 09 03:41:17 just looking into it Oct 09 03:42:44 I wish they would fix javadoc for dependencies in AS Oct 09 03:43:21 it would be nice if there was some way to say: show me all the methods that take, or return, an object of this type Oct 09 03:44:59 Do you think calling invalidateOptionsMenu entails many CPU cycles? Oct 09 03:48:36 doubt it Oct 09 03:48:37 hey all, trying to get preferencelist value from another activity (not preferenceactivity). However .contains() returns false on both the value and the preference key. How can I get the value of such list? Oct 09 03:48:52 Not sure I am being quite clear enough Oct 09 03:49:47 SASDOE your question was alarming … Oct 09 03:49:54 :) Oct 09 03:50:16 As in incomprehensible? Oct 09 03:51:02 SASDOE do you know how preferences work ? Oct 09 03:51:39 I think so. Well no not really but I've managed so far Oct 09 03:52:11 StingRay_: So I need to implement on prefrenceChange and store the key then? Oct 09 03:52:30 I dont use preferenceActivity crap… Oct 09 03:52:41 so no idea what a mess of stuff that has :) Oct 09 03:52:55 Ok, I'll keep digging. Thanks! Oct 09 03:55:32 SASDOE are you using getDefaultSharedPreferences() ? Oct 09 03:56:00 wo this looks cool , for sharing photos! http://www.getxim.com/ Oct 09 03:57:25 looks like loads of others I have seen Oct 09 03:57:43 funny how all of them now have rounded icons/photopics Oct 09 03:58:05 1 day all the apps I notice switched Oct 09 03:58:10 freaky really Oct 09 03:58:41 the only other app I've seen that works like this is Nokia Photobeamer Oct 09 04:01:54 g00s: no getSharedPreferences with correct key Oct 09 04:02:07 SASDOE use getDefaultSharedPreferences Oct 09 04:05:01 anyone here? Oct 09 04:05:24 no Oct 09 04:05:36 g00s: :( looks like a no-go Oct 09 04:05:53 Napalm DH strikes again ! Oct 09 04:06:02 DH? Oct 09 04:06:09 dianne H Oct 09 04:06:15 hahaha Oct 09 04:06:16 :) Oct 09 04:06:30 i'm convinced she's got a goose plush toy at her desk, which she stabs regularly Oct 09 04:06:43 "android.permission.CHANGE_CONFIGURATION" Oct 09 04:06:56 it works apart from the fact, i cant get the permission Oct 09 04:25:36 Okay, this sucks. My 4.0.4 device (with a hardware menu button) requires invalidateOptionsMenu to be called if the menu has no items at first. Oct 09 04:25:43 Or else the menu doesn't work. Oct 09 04:28:34 Napalm hm, have to try setting night mode, and then calling Activity.recreate() ... its been a while, not sure what we've tried Oct 09 04:31:49 maybe android:configChanges="uiMode" Oct 09 04:45:34 g00s: you can do that. remember my example. https://gist.github.com/slightfoot/c508cdc8828a478572e0 Oct 09 04:58:17 JakeWharton: http://stackoverflow.com/questions/6080094/use-of-onprepareoptionsmenu-on-android-3-0 Oct 09 04:58:27 I found that. lol Oct 09 05:01:06 JakeWharton: Would you recommend calling invalidateOptionsMenu for *all* menu changes, or just for (always visible) action buttons? Oct 09 05:22:55 is this a blank page for anyone else? http://www.truiton.com/2013/05/android-fragmentpageradapter-example/ Oct 09 05:26:23 ya Oct 09 05:26:50 well, very long blank page Oct 09 05:26:53 lasserix click in the page Oct 09 05:27:05 maybe you have a special hosts file or ABP like me :) Oct 09 05:29:28 Has anybody done a detached autoCompleteTextView before? i want to show the results of the actv in another view in my activity... like a customised format... anybody have any pointers? Oct 09 05:31:45 http://corner.squareup.com/2014/10/advocating-against-android-fragments.html Oct 09 05:34:36 heh code quality == (wtf / minute) Oct 09 05:35:17 i had that posted on the wall at work Oct 09 05:35:37 Fall it's just a filter couped adapter…the output can be a listView anywhere if you want Oct 09 05:35:48 coupled* Oct 09 05:50:11 damn, my vpn client has a memory leak Oct 09 05:50:17 so it needs to be a ListView? no wonder I was trying to assign it just to a normal RelativeLayout (sorry, I've only been doing Android dev for a little bit) Oct 09 05:51:38 Fall thats not what I said Oct 09 05:53:06 what I said was TextInput > filter + adapter > results … an autocompleteTextView thingy is all of that in a collection Oct 09 05:53:23 well you assign an adapter, it creates popup view with results etc Oct 09 06:00:59 ahhahahahahahahahahaha Oct 09 06:01:07 its amazing how many hours i waste Oct 09 06:01:20 well, i finally have my robolectric tests running in intellij, gave up on android studio Oct 09 06:01:32 so many stupid workarounds required Oct 09 06:03:31 better than debugging my tests with log statements though Oct 09 06:03:31 StingRay_: Ahh, I see. Thanks for the insight Oct 09 06:04:08 ok Oct 09 06:04:14 Back to crappy solutions Oct 09 06:04:29 so that moment when you finally get the debugger working, and realize your bug Oct 09 06:04:30 So I have a null pointer error Oct 09 06:04:36 I can very easily solve it. Oct 09 06:04:36 man, this was a crazy bug Oct 09 06:04:54 However, the code where I can solve it isn't mine Oct 09 06:05:03 what is the best crappy approach here? Oct 09 06:05:22 Agamemnus try to get a better understanding of how the authors of the code intended you to use it Oct 09 06:05:32 .... Oct 09 06:05:39 That's not a solution. Oct 09 06:05:42 ?? Oct 09 06:05:46 you are probably passing an invalid parameter Oct 09 06:05:55 I'll elaborate. Oct 09 06:05:59 wait : Oct 09 06:06:07 first you have to tell me Oct 09 06:06:10 if you can find the bug here Oct 09 06:06:19 Where Oct 09 06:06:21 that i solved in 3 seconds after i got the debugger working Oct 09 06:06:22 int bytesToWrite = Math.min(bytes.length, maxBytesToWrite); Oct 09 06:06:34 maxBytesToWrite = Long.MAX_VALUE Oct 09 06:06:40 its so obvious Oct 09 06:06:41 when i point that out Oct 09 06:06:42 lol Oct 09 06:06:56 ok, so let's see Oct 09 06:06:59 wait what Oct 09 06:07:12 maybe you need to flip the lines? Oct 09 06:07:47 sorry it wasn't clear Oct 09 06:07:53 maxBytesToWrite was assigned elsewhere Oct 09 06:08:30 the bug is Math.min takes ints not longs Oct 09 06:08:38 I see Oct 09 06:08:44 Ok... Oct 09 06:08:50 (int)Long.MAX_VALUE = -1 Oct 09 06:08:53 So here's the situation. Oct 09 06:08:59 so no bytes were ever written.. Oct 09 06:09:03 Remember the content provider earlier? Oct 09 06:09:05 such a stupid bug. Oct 09 06:09:06 yes. Oct 09 06:09:09 i'm just upset Oct 09 06:09:15 I am using a tabview and I want to set the size of the actionbar to a custom size. here is my style.xml file http://pastebin.com/2m6KwygW Oct 09 06:09:17 no warning or anything Oct 09 06:09:20 :( Oct 09 06:09:29 It's declared by a Cordova .java file. Oct 09 06:09:37 Well Oct 09 06:09:41 It's not declared, sorry Oct 09 06:09:46 It's run by it. Oct 09 06:10:06 So the .java file runs the content provider and gets the zip file contents into a URI Oct 09 06:10:09 Clear so far? Oct 09 06:10:45 I mean, the content provider gets the zip file contents into a URI. The APK expansion zip file. Oct 09 06:10:46 i don't really get how the .java file 'runs' the content provider Oct 09 06:10:56 It executes a function in the content provider Oct 09 06:11:08 contentResolver.openAssetFileDescriptor(uri, "r"); Oct 09 06:11:44 That runs the "openAssetFile" function inside the content provider Oct 09 06:12:02 write, this is all android platform code Oct 09 06:12:04 "openAssetFile" opens the ZIP file Oct 09 06:12:18 right* Oct 09 06:12:28 Ok, so the zip file is now open and mapped to a URI. Oct 09 06:12:39 After that, the Cordova plugin functions are run. Oct 09 06:13:07 And the Cordova plugin functions take a specific XML file and get data regarding the main version number of the zip file. Oct 09 06:13:15 And then they send that to the content provider. Oct 09 06:13:26 But, of course... the zip file was already opened. Oct 09 06:13:40 So the plugin function is useless at this point. Oct 09 06:13:42 Clear so far....? Oct 09 06:14:16 is the XML file in or out of the zip file Oct 09 06:14:23 The XML file is in res/ Oct 09 06:14:25 ok Oct 09 06:14:26 sec Oct 09 06:14:47 It specifies what the filename of the zip file should be.. but it does this after the zip file is already opened. Oct 09 06:14:57 So it's late to the party. Oct 09 06:15:13 I am using a tabview and I want to set the size of the actionbar to a custom size. here is my style.xml file http://pastebin.com/2m6KwygW but it is not working,help. Oct 09 06:15:27 can you just run have the plugin functions run first? Oct 09 06:15:30 Wait yer turn, I've been at this for 2 days :P Oct 09 06:15:48 JacobTabak: no, I can't make them run any sooner. It's the way Cordova works Oct 09 06:15:54 However. Oct 09 06:16:06 I did manage to "fix" it. Oct 09 06:16:16 Here's what I did: Oct 09 06:16:46 shadej1 you're applying the theme to your activity right? Oct 09 06:16:55 When openAssetFile() is run, it tries to open the zip file. But I added a boolean to tell it NOT to open the zip file until the plugin function starts running. Oct 09 06:17:16 JacobTabak: yeah, Oct 09 06:17:24 So, openAssetFile() returns "null". Oct 09 06:17:28 The first time around. Oct 09 06:17:34 shadej1 i've never done that, not sure, sounds like a bad idea Oct 09 06:17:50 Agamemnus isnt this a library that many people use ? Oct 09 06:17:54 why are you the only one w/ a problem? Oct 09 06:17:55 And the second time (after the plugin runs), it also opens the zip file, after feeding the correct version number to the ContentProvider Oct 09 06:18:15 Very few are using i Oct 09 06:18:16 it Oct 09 06:18:32 Do you understand now Oct 09 06:18:36 I have a null pointer: Oct 09 06:18:38 JacobTabak: what is the bad idea? changing the size of the action bar? Oct 09 06:18:42 yes Oct 09 06:18:48 Agamemnus you are probably the only one here that uses Cordova Oct 09 06:18:53 Agamemnus dont use poorly supported libraries Oct 09 06:18:55 I'll paste some code Oct 09 06:19:12 why we need CTS test in android? Oct 09 06:19:15 shadej1 if you can find one successful app that does it, i'll take back my words Oct 09 06:19:18 what is CTS Oct 09 06:19:29 https://source.android.com/compatibility/cts-intro.html Oct 09 06:19:32 kanupatar to beat OEMs into submission, and to make sure they pass tests :) Oct 09 06:19:52 g00s: sorry Oct 09 06:19:56 because Samsung Oct 09 06:20:17 oh man, samsungs profits were down 60% Oct 09 06:20:26 http://pastebin.com/QM55Z7ck Oct 09 06:20:35 JacobTabak, take a look at that Oct 09 06:20:38 no! Oct 09 06:20:43 Fine Oct 09 06:20:44 Don't Oct 09 06:20:45 Ok Oct 09 06:20:50 g00s: ? Oct 09 06:20:53 So the problem is: Oct 09 06:20:56 is there an easy way to convert a long to Integer.MAX_VALUE int if it's over Integer.MAX_VALUE? Oct 09 06:21:05 ie, without writing an "IF" Oct 09 06:21:13 Does Java have ternaries? Oct 09 06:21:23 yes but thats ugly Oct 09 06:21:40 In Javascript, you can put it in a clamped array Oct 09 06:21:40 Math.max Oct 09 06:21:43 er, min Oct 09 06:21:48 Nope Oct 09 06:21:59 JacobTabak: the music player in android 4.2.* Oct 09 06:22:16 JacobTabak: what if you convert the other integer to a long? Oct 09 06:22:22 oh yea jake thats good Oct 09 06:22:35 java.hasTernaries() ? "Yes" : "No" Oct 09 06:22:59 i just spent so much time trying to figure out this bug in my robolectric unit test Oct 09 06:23:01 that i couldn't debug Oct 09 06:23:20 because of stupid tooling Oct 09 06:23:25 Ok, so my question on the null pointer error is: can I catch a null error inside the function that's about to give a null pointer? Oct 09 06:23:46 Like some sort of crazy callback. Oct 09 06:24:22 i think you know the answer to that Oct 09 06:24:27 :[ Oct 09 06:24:31 ok fine Oct 09 06:25:06 g00s: sorry, I am waiting :( Oct 09 06:25:17 kanupatar what were you waiting for ? Oct 09 06:25:27 Agamemnus what you should do is a) log an issue for the project b) find a sample project that does the same thing Oct 09 06:25:32 g00s: that CTS stuff Oct 09 06:25:34 and see if they're doing something differently Oct 09 06:25:36 sure, sure Oct 09 06:25:39 they are. Oct 09 06:25:50 g00s: any extra effort needed for CTS tests? Oct 09 06:25:50 They avoid the issue by duplicating variables Oct 09 06:25:54 kanupatar you can google what it is - i've never had to pass it :) Oct 09 06:26:11 whether the android 4.4 pass all cts tests? Oct 09 06:26:22 i think you need to pass CTS in order to get play services Oct 09 06:27:01 g00s: ^^ Oct 09 06:27:02 kanupatar if you need to pass CTS, best that you contact goofle Oct 09 06:27:13 g00s: :( Oct 09 06:27:30 and good luck contacting google :) Oct 09 06:27:38 Is there a way to set a ProgressBar horizontal style dynamically? I want to change the color of the default ProgressDialog. Oct 09 06:28:09 surf2b1 you can give dialogs their own theme Oct 09 06:28:29 override progressdialog, and set the theme there Oct 09 06:28:40 did you guys see this from the other day? http://www.bbc.com/news/business-29516806 Oct 09 06:28:45 samsung, etc Oct 09 06:29:26 g00s to be expected Oct 09 06:29:26 JacobTabak: I want to do it for the default ProgressDialog (library project and don't want resources). I can get the ProgressBar after I call show() like this: ProgressBar bar = (ProgressBar) theProgressDialog.findViewById(android.R.id.progress); Oct 09 06:29:58 surf2b1 you're going to have to override progressdialog Oct 09 06:30:23 to use a custom progressbar Oct 09 06:30:54 you can set all the attributes in code without xml, but you need to extend progressbar Oct 09 06:31:35 StingRay_ dunno. but it could also be because of Lee Kun Hee's health Oct 09 06:31:37 how can i make JVM(robolectric) tests automatically kill any existing running tests when they start? Oct 09 06:31:42 in intellij Oct 09 06:32:00 my AS just hard crashed man, whoaa Oct 09 06:32:18 g00s congrats, thought you were on IJ ? Oct 09 06:32:20 i can still hear the pieces falling Oct 09 06:32:30 os x crash reporter, yey Oct 09 06:32:43 StingRay_ no, i use gradle Oct 09 06:32:53 well the newest gradle stuff from google Oct 09 06:34:52 JacobTabak: Well, it is possible without extending ProgressDialog. I called bar.setProgressDrawable(mContext.getResources().getDrawable(R.drawable.progress_horizontal)); and it worked. I guess I can't set the color and need a resource/drawable. Oct 09 06:35:28 surf2b1 yeah you'er going to find a lot of the stuff is set in code by reading xml and not exposed with a public interface Oct 09 06:35:36 reading theme Oct 09 06:40:06 JacobTabak, I did submit some PRs Oct 09 06:40:16 Hopefully they will accept, but I'm not optimistic Oct 09 06:40:25 But Crosswalk probably will, though. Oct 09 06:41:18 (Crosswalk is a system for Cordova that bundles a specific Chromium browser in an apk) Oct 09 06:41:30 if you forgot Oct 09 06:43:12 btw, anyone have any idea what "use -source 7" means in the context of building an APK? It's using 1.5, but I have 1.8 installed. And it doesn't like my switch with strings. Oct 09 06:46:03 g00s: os x lol Oct 09 06:49:09 Agamemnus: source is the java level of source code, target is the bytecode level you are targeting. Both should be at 7 and you should be using JDK 8 to build. Oct 09 06:49:32 Sure, I get that. Oct 09 06:49:36 Not sure where to set it. Oct 09 06:50:04 Depends on build system Oct 09 06:50:12 Hi Oct 09 06:50:53 How to make action bar right-to-left? Oct 09 06:51:04 JakeWharton: do you have any experience with that facebook's build system 'buck' ? Oct 09 06:51:21 I have opinions on it Oct 09 06:51:52 I'm well versed in how it works and the changes they've made, but I've never used it. Oct 09 06:52:45 JacobTabak: well, it is possible. http://pastebin.com/jb6fFty0 http://i.imgur.com/HQT8DP2.png?1 Oct 09 06:53:30 ha nicely done Oct 09 06:53:36 you just want to add a color filter? Oct 09 06:54:02 I just want to change the color of the progress Oct 09 06:54:09 JakeWharton: wanna share some of that opinions? ;) Oct 09 06:55:33 gordon_: it eschews features for speed which is a well-known bad practice in all software development. It does this because it's solving a Facebook scale problem that Facebook and few others have. Oct 09 06:56:06 miracast is supported in android4.4 ? Oct 09 06:56:11 so it's better to stay with gradle ? Oct 09 06:56:17 they made optimizations to SDK tools which they refuse to upstream Oct 09 06:57:10 itant Oct 09 06:57:12 At DroidCon one of the buck developers said in response to that fact that the way Facebook would enable everyone to have faster dexing is by switching them all to buck rather than contributing patches upstream Oct 09 06:57:12 it's ant Oct 09 06:57:30 great... Oct 09 06:58:11 "if enough people use buck maybe they'll make it the official build system!" Oct 09 06:58:12 Both Gradleware and Google are focused on features with the understanding that speed comes later. The Gradle 18 month roadmap has a lot of speed and efficiency related things on it. Oct 09 06:58:43 the exopackage concept seems like one of the better parts Oct 09 06:58:49 Buck is based on Google's Blaze which is great, they just aren't executing it very well Oct 09 06:59:11 well, I will stay with gradle then Oct 09 06:59:29 I'll point out that everything buck solves would be fixed by a simulator! Oct 09 06:59:45 what simulator ? Oct 09 06:59:47 #seemyblogpost Oct 09 06:59:56 JakeWharton: Does square use multipe dex files? With how many library projects and the amount of code I'm sure it is pretty close to the dex limit.. Oct 09 07:00:16 surf2b1: we're nowhere close. 60% on the biggest app Oct 09 07:00:28 gordon_: #seemyblogpost Oct 09 07:00:35 JakeWharton that's after proguard? Oct 09 07:00:42 or repackaged libs Oct 09 07:00:50 or just no dingleberries Oct 09 07:00:52 JakeWharton: with pleasure ;) Oct 09 07:01:29 JakeWharton: I dont think google is going to make one Oct 09 07:01:47 We don't use proguard Oct 09 07:02:15 what about method limit ? Oct 09 07:02:54 some other 3rd party tool then? Oct 09 07:02:56 What about it? I said we're at ~60% Oct 09 07:03:00 No Oct 09 07:03:04 Nothing Oct 09 07:03:32 gordon_: method limit = multiple dex files. If he is at 60% then he is very safe Oct 09 07:03:41 do you have facebook login? google login? Oct 09 07:03:53 eh... Oct 09 07:03:59 wish we were safe :) Oct 09 07:04:03 JacobTabak: no Oct 09 07:04:07 ah Oct 09 07:04:14 i went over last night when i put dagger-compiler on 'compile' Oct 09 07:04:15 how ironic Oct 09 07:04:32 Because it pulls in Guava which is 13k Oct 09 07:04:53 went down to gms 4.0.x and i'm safe for now Oct 09 07:05:31 We did hit the limit a year ago. 35k methods from protos. We wrote our own proto runtime and code generator which dropped it to 11k Oct 09 07:05:38 what do you use for obfuscation? Oct 09 07:05:39 But library projects tend to push that limit count up fast. For instance, using ActionBarSherlock (don't use it now) would have two R classes. It would copy all the fields and make your count go way up if you didn't rename the library's package name. Oct 09 07:05:46 JacobTabak: nothing Oct 09 07:05:58 :O Oct 09 07:06:17 i suppose you can't rely on security through obfuscation so why bother eh Oct 09 07:06:38 Yep. That's our take on it. Oct 09 07:07:31 while you're semi paying attention, do you run robolectric tests with intellij? Oct 09 07:07:45 Yes Oct 09 07:07:49 are there any good workarounds for manually editing the iml all the time Oct 09 07:07:56 i have to add android.jar and reorder stuff every 5 min Oct 09 07:08:10 Yes. Search " blundell robolectric" Oct 09 07:08:17 Stop using those stupid hacks and plugins Oct 09 07:08:19 separate module Oct 09 07:08:23 thing? Oct 09 07:08:23 Right Oct 09 07:08:29 i tried that briefly Oct 09 07:08:35 but i was mashing my face for many hours on other things Oct 09 07:08:38 i didnt watn to invest too much time Oct 09 07:08:43 i'll check it out, thanks for the suggestion Oct 09 07:09:33 The first party Robolectric plugin is bad news. I fought them on it (since we're core contributors) but they just wanted something that worked now and worked for their use cases rather than for the good of everyone. Oct 09 07:09:49 does blundell's solution not use the robolectric plugin? Oct 09 07:10:01 it must, right? Oct 09 07:10:10 Nope Oct 09 07:10:13 ohh Oct 09 07:10:26 Just a java module and normal test source set and JUnit Oct 09 07:10:52 There's nothing special beyond stealing the classpath from the app module Oct 09 07:11:07 Going to sleep. Oct 09 07:11:14 nite Oct 09 07:14:24 How do I get the layoutparms of an arbitrary viewgroup? Oct 09 07:14:52 Ie i have a viewpager, i want to add a relative layout to the container from instantiateItem, how do I get the appropiate layoutparams for the container? Oct 09 07:15:39 you give a view the layoutparams of its parent Oct 09 07:15:45 it doesnt matter what type the view is Oct 09 07:16:48 so for this case use ViewPager.LayoutParams Oct 09 07:17:33 and mind your isDecor on that Oct 09 07:23:14 On my Fedora dev machine 64 bit image starts as a black screen. Anyone able to get it working on Linux. Oct 09 07:24:07 donniezazen the emulator? Oct 09 07:24:17 JacobTabak: Yes. Oct 09 07:24:37 donniezazen yes ... try different configurations with cpu, gpu emulation, etc Oct 09 07:24:45 some configs just dont work together Oct 09 07:25:04 JacobTabak: I am doing that gpu host doesn't seem to make any difference. Oct 09 07:25:14 donniezazen try different screen sizes, etc Oct 09 07:25:17 also try genymotion Oct 09 07:26:03 JacobTabak: Genymotion isn't going to have 64 bit image for a while. Oct 09 07:26:23 JacobTabak: I am talking about recently released 64bit image of Android L Preview. Oct 09 07:26:30 JacobTabak does it work over network ? Geny Oct 09 07:27:05 What's the method to override when I need to do some dimension calculations for a custom view Oct 09 07:27:15 previousily I was using onMeasure, but I assume there is something better Oct 09 07:27:31 like in viewgroup, there is onFinishLayout --> is there something equivalent for views? Oct 09 07:27:42 how can I get a list of radioButtons in an android.widget.RadioGroup? Oct 09 07:28:14 Nivag iterate through the children Oct 09 07:28:26 Someone add this to channel's topic --> Search " blundell robolectric" :) Oct 09 07:28:41 radioGroup.getChildCount(), radioGroup.getChildAt() Oct 09 07:28:57 csst0111 what can we add to the topic for this 'java.lang.UnsupportedOperationException: ugh, this doesn't work still?' Oct 09 07:29:05 at least i know what to google Oct 09 07:29:17 i think all exceptions should be ridiculous unique things that are easy to search for Oct 09 07:29:45 ahh onFinishInflate Oct 09 07:44:34 Argh onFinishInflate is not it,... when implementing customview / compound control, when's the best time to do calculations for dimensions related to drawing? Oct 09 07:46:14 after super.onlayout Oct 09 07:49:05 lasserix if you were waiting for a view to measure and you weren't extending it, you'd use a layoutchangedlistener, if you're extending the class just do it in onlayout Oct 09 07:50:39 also lasserix the value calculated in onMeasure shouldn't be used... see the documentation for getMeasuredWidthAndState(): "This should be used during measurement and layout calculations only. Use getWidth() to see how wide a view is after layout." Oct 09 07:50:46 so just override onLayout and then call super then do my calculations? Oct 09 07:50:56 you can do your calculations before super.onLayout Oct 09 07:50:57 yeah yeah i know how to do onMeasure Oct 09 07:51:07 ok Oct 09 07:51:10 so onLayout Oct 09 07:51:12 yep Oct 09 07:51:18 errg i wish they had added a callback for this Oct 09 07:51:21 they do ! Oct 09 07:51:26 onLayoutChangeListener Oct 09 07:51:29 since onlayout is called several times Oct 09 07:51:55 theres also onSizeChanged Oct 09 07:52:09 JacobTabak: Thanks, I was intending to do exactly that, but I had managed to confuse myself - fortunately you nudged me in the right direction! Oct 09 07:52:31 np Oct 09 07:53:45 bai sleep time Oct 09 07:54:07 which is better to use onSizeChanged or onLayoutChanged Oct 09 08:10:51 Dat quit message lol Oct 09 08:12:24 hey guys, I am getting an error Can't create handler inside thread that has not called Looper.prepare() in a method call that starts threads and waits for them to complete. Do I need to put that method inside an async task? Oct 09 08:15:49 put a method that starts threads and then wrap that in a thread using async ? that dont sound like a good idea Oct 09 08:16:37 SASDOE also use google… it's probably quite a google'able thing :) Oct 09 08:16:41 I wouldn't have though so. Then how come i'm getting this error? Oct 09 08:16:47 SASDOE: Check out HandlerThread http://developer.android.com/reference/android/os/HandlerThread.html You could probably do a simple fix by creating your handler on the UI thread. Oct 09 08:22:35 Thanks Oct 09 08:23:34 hello Oct 09 08:24:40 I used ViewFlipper to make a slideshow with gesturedetector. now the second view appears after the swipe is done. how can i make the second view slide into the screen from right edge as i swipe and then when i unpress the screen it slides in (if you know what I mean) ? Oct 09 08:26:05 the effect is somewhat demonstrated in the video here http://androidbeing.info/q/what_is_android_viewflipper.html - after half of it is played Oct 09 08:28:17 viewpager does what you want Oct 09 08:31:10 Zharf: um hm yeah, but is there someway to have the same effect in viewflipper since i already used that to code my slideshow and it'd also bea nice learning thing ? Oct 09 08:31:53 no clue off the bat, haven't used viewflipper in like 4 years Oct 09 08:38:19 Zharf: so you've always used viewpager? Oct 09 08:39:32 If I wanted all activites in my app to always be in same task and always have this task one deep, would I use singleTop|singleInstance for launchMode for each of them? Oct 09 08:40:11 shmoon, no, but I also didn't use viewflipper very much back in the days Oct 09 08:47:50 good morning Zharf :) Oct 09 09:05:38 since there is no way to set wifi to not connect automatically for previous networks Oct 09 09:06:04 if I programatically disable a network, will it become enabled after a reboot? Oct 09 09:07:22 I have a splash screen activity (that is the launcher activity in my manifest). But when I hit the back button (or back in the action bar), I do not want to goto the splash screen but a different activity Oct 09 09:27:46 vedu: use finish(); after you start your main activity on the splashscreen activity Oct 09 09:28:33 Mrdarknezz: yes I used that. Now I want to set a parent activity to navigate to instead Oct 09 09:38:13 vedu, use taskstackbuilder Oct 09 09:38:45 Zharf: yes looking into that only Oct 09 09:39:07 anyone using rxandroid? im trying to figure out whether i can just grab a text observable from an edittext Oct 09 09:42:33 Can someone explain why I get a NullpointerException from this code: http://pastie.org/9633737 Oct 09 09:42:54 I'm trying to show a toast from my DebugFunctions-class Oct 09 09:43:02 From another class Oct 09 09:43:16 prolly mcontext = null Oct 09 09:43:44 try instead DebugFunctions.this Oct 09 09:43:48 Oh, sorry. mContext should be this Oct 09 09:44:35 Replacing mContext with DebugFunctions.this didn't work Oct 09 09:48:32 are you sure mContext is not null? try pass in getApplicationContext() instead... Oct 09 09:51:06 the_fog: mContext.getApplicationContext() didn't make any difference, and I also tried with this and DebugFunctions.this (DebugFunctions extends Activity) Oct 09 09:51:55 jwanglof not mContext.getApplicationContext() Oct 09 09:52:03 jwanglof: you never initiliaze mContext Oct 09 09:52:20 try just getApplicationContext() on it's own Oct 09 09:52:30 you can just do this since its activity class Oct 09 09:52:31 mContext is null here it seems Oct 09 09:52:59 tho you shouldn't be extending Activity arbitrarily Oct 09 09:53:00 Same thing Oct 09 09:53:20 So I should use mContext for the Toast? Oct 09 09:53:21 ahh Oct 09 09:53:28 why are you extending Activity? Oct 09 09:53:38 no Oct 09 09:53:44 he's starting another activity Oct 09 09:53:48 then calling debug function toast Oct 09 09:53:56 but since it has not been loaded, it is null Oct 09 09:54:06 so drop extends Activity Oct 09 09:54:12 and just make your method like Oct 09 09:54:38 public static void logdebug(Context context) { Toast.makeText(context, "blah", Toast.LENGTH_LONG).show() } Oct 09 09:55:29 jwanglof: why are you extending activity? Oct 09 09:56:10 lasserix: To make Toast work in that class =P I knew it wasn't a good way to do it but it worked before Oct 09 09:56:17 thats terrible Oct 09 09:56:27 why aren't you just passing context to this class or method? Oct 09 09:57:07 Mostly because some classes doesn't have a context. But I guess I can use MainScreen as context when that happens? Oct 09 09:57:17 O_O Oct 09 09:57:17 here i fixed it for you http://pastie.org/9633792 Oct 09 09:58:46 don't extend activity arbitrarily Oct 09 09:58:49 it doesn't even work Oct 09 09:58:53 because you have to load the activity Oct 09 09:58:59 which is what you do in the manifest Oct 09 09:59:11 but since this is not an activity, you can't Oct 09 10:00:24 Ok =) Oct 09 10:01:05 you should also read developer tutorial docs Oct 09 10:01:15 maybe even take a class on java? Oct 09 10:01:40 ^ Oct 09 10:01:46 This is like a day 1 mistake Oct 09 10:02:00 lasserix: That worked. Odd though, tried it before but didn't work then Oct 09 10:02:16 yeah because you were probably passing mContext when it was null Oct 09 10:02:32 jwanglof: you should really read developer tutorial docs Oct 09 10:02:46 jwanglof: probably brush up on youur java too Oct 09 10:03:28 I guess. Been a while since I did anything Android but it's been working out well until now Oct 09 10:03:43 i hope you haven't released an apps on the store! Oct 09 10:03:46 But we have a deadline on tuesday so I guess after that =) Oct 09 10:03:49 Nope Oct 09 10:04:14 How can I add a java library dependency to an android app? Oct 09 10:04:30 NightRa: many ways you using eclipse or android studio? Oct 09 10:04:46 Android Studio (through Intellij) Oct 09 10:04:47 but the same way you add a java dependency to a java project Oct 09 10:05:04 usually you can just incldue it as a depdency in the build.gradle file Oct 09 10:05:09 With gradle I suppose Oct 09 10:05:10 is it on maven central repo? Oct 09 10:05:18 I guess so Oct 09 10:05:27 yes Oct 09 10:05:28 right click on your project in the project window Oct 09 10:05:32 choose Open Module Settings Oct 09 10:05:50 Click on module that you want to add the dependency too (called app probably) Oct 09 10:05:59 goto dependencies tab Oct 09 10:06:08 click the green add button on the right hand side Oct 09 10:06:22 pick library Oct 09 10:06:27 you can chose from Maven Oct 09 10:06:30 and try searching for it Oct 09 10:06:38 or if you have the jar select java and navigate to the jar Oct 09 10:16:08 Can a viewgroup animate one of its child views outside of its clip bounds? Oct 09 10:23:18 hello Oct 09 10:24:39 heloo how tos end data from one device to another device Oct 09 10:24:49 without using any server or GCM service Oct 09 10:25:51 I need to display an zommable imageview. Do you think is it better create png or svg? Oct 09 10:26:14 min2: wifi direct? Oct 09 10:26:34 my devices are very far from each other Oct 09 10:27:12 then you need a server of some sort Oct 09 10:27:21 Hello. Any idea to achieve this: (screenshot: http://i.imgur.com/lUgidJ6.png) ? I already tried RelativeLayout but I'm having issue with the alignment of TextViews. Any idea or some pattern? Oct 09 10:27:44 without server isn't possible to achieve this Oct 09 10:28:34 you can't communicate between two random devices somewhere on the internet without *something* to mediate, or at least to arrange the connection Oct 09 10:28:35 is it possible to create client and server a android device to achieve this solution Oct 09 10:29:27 yes i agree Oct 09 10:29:36 the server has to be at a known location Oct 09 10:30:01 you can use ad hoc discovery on local networks, but not globally across the internet Oct 09 10:31:31 Or you message ips arround :p Oct 09 10:31:32 ohhh Oct 09 10:31:47 then user A has to call user B and ask for his IP to connect :P Oct 09 10:32:02 danijoo: still need a server of some sort to carry the messages Oct 09 10:32:09 what if i send the ip through message Oct 09 10:32:16 once Oct 09 10:32:36 and then connect the peer to peer to connection between each other Oct 09 10:32:49 it's a bootstrap problem - once you've managed to send a single message, somehow, you can (potentially) do direct communication - but you can't send that first message without a server Oct 09 10:32:50 lnoskhen: should be working with relative layout Oct 09 10:33:13 suppose i am sending message through SMS programamtically at once Oct 09 10:33:26 in which i am sending IP of the device Oct 09 10:33:31 to another device Oct 09 10:33:59 when another device will able to get the ip then he will make the peer to peer to peer connection with it Oct 09 10:34:22 possible? Oct 09 10:34:27 you can potentially do that... two issues: SMS isn't necessarily free, particularly if it's international... and mobile devices very commonly don't have routable IP addresses Oct 09 10:35:33 do they fixed Oct 09 10:35:59 or changed frequently on network changed as i google i found that on network changed IP get changed Oct 09 10:36:07 yeah you might run into problems since its possible that the IP is behind NAT or changes frequently while not in WIFI Oct 09 10:36:13 and of course, the address can change - particularly if a user is moving between wifi and cell data Oct 09 10:36:42 then GCM works internally Oct 09 10:36:56 how he pushes the data to particular device Oct 09 10:37:11 may be he uses some IP Oct 09 10:37:16 or something else Oct 09 10:37:30 GCM works by maintaining a persistent connection *from* the device *to* the server - which is obviously at a well-known location Oct 09 10:37:34 danijoo: ohhh.. thanks :) Oct 09 10:37:53 id go with GCM Oct 09 10:38:08 yes device id Oct 09 10:38:10 shared hosts for starting are cheap nowadays Oct 09 10:38:45 but if you have your own server, you need to run your own messaging system, on the device and on the server Oct 09 10:39:02 yes with server it is quite easy Oct 09 10:39:12 on the server yes, but on device you need it anyways Oct 09 10:39:24 as i am planning to replace mms mechanism through peer to peer Oct 09 10:39:36 and I think its a lot easier to implement message system for direct communication then for some sockets and ip/wifidirect Oct 09 10:40:06 replace direct comm. with gcm Oct 09 10:40:09 it's much easier to use GCM, unless you have an actual reason not to Oct 09 10:40:26 cant it possible through hybrid apps Oct 09 10:40:47 but the issue with the well-know location Oct 09 10:41:35 hybrid apps? Oct 09 10:41:49 using somekind of websocket or something else Oct 09 10:42:01 why dont you want to use gcm? Oct 09 10:42:01 oh, I assumed you were talking about Android apps Oct 09 10:42:05 could you use gcm for multiplayer in games? Oct 09 10:42:27 I can use GCM or any third party server Oct 09 10:42:28 lasserix: gcm might be not fast enough for that Oct 09 10:42:33 ah Oct 09 10:42:38 but i dont want Oct 09 10:43:05 yeah, you could use it for turn-based games, but not real-time Oct 09 10:43:21 something like a board game should work Oct 09 10:45:04 can we say that its not possible Oct 09 10:45:20 due to well-known application Oct 09 10:45:44 due to no well -known location in mobile device Oct 09 10:46:00 in global network Oct 09 10:47:12 er... flibble Oct 09 11:05:38 I seriously detest social media shit in apps, but sadly clients always want something like Facebook or Twitter integrated, right now I've got a Twitter share URL I parse it to an Uri and use it in an Intent, it brings up a chooser intent and lists all possible Tweet apps which properly fill in the fields I want filled in Oct 09 11:06:18 Now my question, I can't seem to find anything about a callback back to the app it came from whether a Tweet has been sent or not, is there such a thing and would I need to add a Twitter SDK of some sort to my app to make it work? Oct 09 11:16:26 vedu: Sorry I was at lunch Oct 09 11:16:29 vedu: Parent activity? Oct 09 11:17:12 Mrdarknezz: problem solved :) Oct 09 11:17:17 vedu: great Oct 09 11:17:26 parent activity defiend in manifest Oct 09 11:20:40 does greenrobot eventbus support to specify an instance to deliver events instead a global/thread diffusion Oct 09 11:23:22 how to pass referrer id to Google Play Store from Applinks ? Oct 09 11:24:33 kamol, https://developers.google.com/analytics/devguides/collection/android/v2/campaigns#campaign-params Oct 09 11:26:09 cliffreich, you can have multuple instances yes Oct 09 11:26:38 i mean Oct 09 11:26:42 VnM: I am using Applinks, and dont’ know how to pass referrer from Applinks to Google play Oct 09 11:27:44 i have two instance of the fragment, so they both would have same subscriber. there is a way to pick the receiver based on the instance? i know you can easily compare, but still want to be sure Oct 09 11:28:11 the same fragment* Oct 09 11:29:27 to avoid both fragment receiving the same data Oct 09 11:29:36 kamol, can't you just put the URL in the al:android:url property? Oct 09 11:30:03 and to avoid a manual comparison of the right instance Oct 09 11:36:40 Does the system invoke finish(), too or is it just an API call for developers? Oct 09 11:36:50 VnM: I am trying, but it doen’t work http://pastie.org/9633977 Oct 09 11:40:34 kamol, is it opening the market though and not registering the referrer bit or is it not even opening the market? Oct 09 11:41:59 it opens Google Play in the browsers. However the link doens’t work in FB status anylonger Oct 09 11:42:42 VnM: maybe intead of market, should I use just play.google.com url? Oct 09 11:43:00 Yeah you can try https://play.google.com/store/apps/details?id=org.kamol.shopobrol&referrer=utm_source%3DApplinks%26utm_campaign%3DQMmYSI6QQJ Oct 09 11:44:22 liek this http://pastie.org/9633983 ? Oct 09 11:44:36 Yeah give it a shot Oct 09 11:47:26 VnM: let me try Oct 09 11:51:25 VnM: it works in browser and it works in FB status :) hahaha Oct 09 11:52:09 let me release my app to google play store and I will be able to test if refferer is passing through Oct 09 11:52:17 VnM: thank you ! Oct 09 12:42:05 I have an AutoCompleteTextView that uses an ArrayAdapter containing several Integers. How can I get the AutoCompleteTextView to show all items in the Dropdown, even if I have typed in digits that do not match the digits of other entries? Oct 09 12:48:28 the case companion library from google has drawable-xxhdpi and drawable-xxhdpi-v11 Oct 09 12:48:33 xxhdpi didnt exist until api 16 Oct 09 12:49:21 hey Oct 09 12:50:03 hey Oct 09 12:50:39 downloading x64 android l emulator ;) Oct 09 12:53:59 congrats Oct 09 13:02:46 How to do a zoomable svg fragment? imageview? webview? Oct 09 13:19:52 Im having trouble searching this without a name for it. What's the action bar menu that isn't the overflow menu called? ( http://developer.android.com/design/patterns/app-structure.html ) Oct 09 13:20:15 sorry, bad link.... Oct 09 13:20:26 http://developer.android.com/design/media/app_structure_gmail.png that one Oct 09 13:21:25 nevermind. dumb question Oct 09 13:21:43 is there a way to translate what the id is in the public.xml Oct 09 13:21:51 for example.. 0x7f090123 Oct 09 13:36:46 Akkord93: what do you mean with "translate"? Oct 09 13:38:03 the actual value of it? Oct 09 13:47:13 how do activities retain states even after back button pressed Oct 09 13:47:31 I recently deleted an older sdk and downloaded one fresh. Now in one of my apps all holo theme materials are gone. Why is this? Oct 09 13:47:45 I did update the sdk using the sdk manager. Oct 09 13:50:22 uh, how do I tell Gradle tests to use a certain connected device? Oct 09 13:57:21 cliffreich__, savedinstancestate Oct 09 14:22:49 mornin Oct 09 14:45:32 What emulator do you guys use for phone apps' development? Oct 09 14:48:48 hey all Oct 09 14:50:10 hey skrite Oct 09 14:52:50 sheikhaman: genymotion is a good option Oct 09 14:54:05 Already using it, just wanted to know what other folks are using :) Oct 09 14:59:25 hello! How can I make my android application notice interrupts generated by an underlying block device? is there any service/daemon i should subscribe? Oct 09 15:01:08 hey all, does java have a native way to handle JSON or do i need to import a library from somewhere? Oct 09 15:01:43 Android has org.json package to handle JSON, skrite Oct 09 15:02:00 juajua, interrupts from underlying block device as in? Oct 09 15:02:08 thanks sheikhaman! Oct 09 15:02:25 Please elaborate, I am a little illiterate when it comes to such things :D Oct 09 15:02:33 My Pleasure, skrite Oct 09 15:02:35 :) Oct 09 15:04:01 BluetoothSocket.getOutputStream -> The output stream will be returned even if the socket is not yet connected, but operations on that stream will throw IOException until the associated socket is connected. Oct 09 15:04:11 umm Oct 09 15:04:12 sheikhaman: what you mean with "as in"? Oct 09 15:04:21 BluetoothSocket.getOutputStream Oct 09 15:04:25 The output stream will be returned even if the socket is not yet connected, but operations on that stream will throw IOException until the associated socket is connected. Oct 09 15:04:49 I'm getting NullPointerException instead, is this a known bug? Oct 09 15:05:01 juajua, I didn't understand your question, it meant that basically Oct 09 15:06:23 sheikhaman: ah ok :) I'll better explain Oct 09 15:06:43 I managed to port Android to a development board Oct 09 15:07:07 with a hardware implemented Sobel Image Filter Oct 09 15:07:22 what I want to do now Oct 09 15:07:29 is an android application Oct 09 15:07:35 that load an image Oct 09 15:07:44 process that image with the filter Oct 09 15:07:52 and the reload the frame Oct 09 15:08:34 have you got any advice? Oct 09 15:08:52 Hi! Is it possible to have a view that's visible in release builds but not debug builds? Oct 09 15:10:28 Peetz0r: yes Oct 09 15:11:01 if(BuildConfig.DEBUG) initView(); Oct 09 15:11:13 then initView() will only run if its a debug build Oct 09 15:11:28 different question, is it possible to check if an app is signed, and which key is used, in the app itself? Oct 09 15:11:46 Peetz0r: You can only check if its signed as debug i think Oct 09 15:11:52 so that an app can say "this version is built by Peetz0r" or not Oct 09 15:12:06 juajua, that thing you just told is scaring me out brother :P Oct 09 15:12:08 no i dont think this is possible Oct 09 15:12:13 I am afraid I don't know anything about that :-/ Oct 09 15:12:23 I should learn android internals Oct 09 15:12:42 gordon_, all the best :) Oct 09 15:12:50 what a pity :\ Oct 09 15:13:01 sheikhaman: that might be interesting Oct 09 15:13:05 I have been reading "Embedded Android" Oct 09 15:13:19 Peetz0r: ok it seems to be possible Oct 09 15:13:45 see http://stackoverflow.com/questions/8682731/retrieve-the-apk-signature-at-runtime-for-android Oct 09 15:13:54 I learn a few thinks, but i miss something Oct 09 15:14:31 especially when it comes to hardware interrupt Oct 09 15:14:49 danijoo: thanks! Oct 09 15:14:56 np Oct 09 15:18:07 so, is there any service that is able to notify me when the sobel filter finish? Should I modify the ISR? Oct 09 15:21:39 juajua, I so wish I could help, but with my most recent experiment with a RaspberryPi and GStreamer/ffmpeg/avconv on it, its like a nightmare :P Oct 09 15:22:07 does anybody know a more detailed api level distribution chart then the one on https://developer.android.com/about/dashboards/index.html ? Oct 09 15:22:38 sheikhaman: Don't worry :D good luck with your projects Oct 09 15:22:44 :) Oct 09 15:22:56 danijoo, check if Flurry has something? Oct 09 15:23:15 also, I am working on something which will collect such data from devices.. will it be useful to developers? Oct 09 15:23:35 well i know my own distribution but Im looking for a more global one Oct 09 15:24:38 because Im currently thinking on increasing minApiLevel from 9 to either 11 or 14 Oct 09 15:24:55 but I think it'll be 15. Oct 09 15:24:57 14* Oct 09 15:25:57 hmmm..! Oct 09 15:31:30 Hi everyone. I'm trying to get a ViewPager going with a FragmentPagerAdapter. every guide I see on how to do this says that in the adapter's getItem() method, you should call WhateverFragment.newInstance(), in which they all recommend you instantiate a new WhateverFragment(). Oct 09 15:31:42 why is this? it seems wasteful to keep instantiating new fragments all the time. Oct 09 15:32:08 like I'm expecting there to be a FragmentManager.getFragmentByTag() somewhere, but it never seems to show up in these guides. why is that? Oct 09 15:34:44 s1gmab3ta: thats what the fragmentpageradapter is doing Oct 09 15:35:38 getItem() will only be called once. the fragment is then kept internally and getItem wont be called again for this frag Oct 09 15:39:30 so is it expected that you not call getItem() in your own code? Oct 09 15:39:40 i.e. unlike ListAdapters and such Oct 09 15:42:54 s1gmab3ta: no Oct 09 15:43:36 in the internal code, the adapter will check if there is a fragment (findFragmentByTag), it it finds one, it uses it, if it doesnt find one, it calls getItem() Oct 09 15:44:20 danijoo, right, but that makes it sound like if I were to want to make some sort of change to one of those fragments, I should not get the fragment using getItem, because that might break things Oct 09 15:45:20 s1gmab3ta: you should never call getItem by hand. This wont work because you would initialize a new fragment that has nothing in common with the one that the viewpager is displaying (and so your changes wont have any effect) Oct 09 15:45:38 danijoo, okay, that makes sense. thanks Oct 09 15:45:45 Are you trying to find a fragment out of the adapter? Oct 09 15:45:52 theres a hacky workarround for that Oct 09 15:46:43 i am indeed, and I think i've seen the hacky workaround you mention. i just didn't know why people were bothering with it. the "don't call getItem()" part was the link I was missing; I thought I was doing something else wrong Oct 09 15:47:12 well, really the don't call getitem() part and the "because fragmentpageradapter only calls getitem once" part :) Oct 09 15:47:46 the workarround includes the tags the adapter is setting Oct 09 15:48:17 lets say you have 4 fragments in your adapter Oct 09 15:48:35 i do. lucky guess. :) Oct 09 15:48:43 My Edittext while unfocused is not showing an underline Oct 09 15:48:44 the tag of fragment1 would then be "android:switcher:PAGERID:0" Oct 09 15:48:46 i using holo theme Oct 09 15:48:50 why is this? Oct 09 15:49:05 When it is focused it shows the blue underline Oct 09 15:49:10 the last number is the fragment position like it would be in a list Oct 09 15:49:20 pifon2, what is the background color of the view the edittext is in? Oct 09 15:49:23 PAGERID is the id of the viewpager. you can get it by calling viewpager.getId() Oct 09 15:49:25 White Oct 09 15:49:29 s1gmab3ta, Oct 09 15:49:34 pifon2, like FFFFFF white? Oct 09 15:49:42 yes Oct 09 15:49:48 pifon2, I'm all out of ideas :/ Oct 09 15:49:57 Guys, i'm implementing reset to default button inside PreferenceActivity/Fragment. For example user checks CheckBox and then resets SharedPreferences to default, but GUI still shows to him that this CheckBox checked (While it's not in SharedPreferences). I need to update GUI explicitly in this case? Oct 09 15:50:04 danijoo, makes sense Oct 09 15:50:09 FragmentManager.findFragmentByTag("android:switcher:" + mPager.getId() + ":" + fragmentNumber); Oct 09 15:53:25 danijoo, do you have any idea at which stage of the lifecycle this happens? like I construct my PagerAdapter in Fragment.onCreateView(), but in onResume() I am doing this getFragmentByTag nonsense to find out what icon to show in the tab for the fragment, and the instantiation hasn't happened yet. Oct 09 15:54:15 are you having that viewpager inside of a fragment or in an activity? Oct 09 15:54:38 inside of a fragment Oct 09 15:54:48 oh.. that makes things more complicated Oct 09 15:55:28 are you using the correct fragment manager? Oct 09 15:55:28 "that makes things more complicated" should be the slogan of Fragments :) Oct 09 15:55:37 because it must be childfragmentmanager then Oct 09 15:56:10 correct as in getSupportFragManager vs getFragManager? Oct 09 15:56:20 nope. Oct 09 15:56:37 The usual fragmentmanager does not support nested fragments. like a fragment inside a fragment Oct 09 15:56:54 for your viewpager, you have to use getChildFragmentManager() then Oct 09 15:56:56 ah, I see. i had not heard of getChildFragManager before. lemme give it a shot. Oct 09 15:57:21 this one is then responsible for the fragments inside your fragment and is the one you should use to search by tag and for the adapter Oct 09 15:57:44 danijoo, stands to reason then that it's also the one I should pass to my adapter? Oct 09 15:57:53 yes Oct 09 15:59:41 no dice. the problem is definitely that getItem()s have not been called yet when I try to get the existing fragments Oct 09 16:04:00 in the android tutorial, there is posted a line "public class HttpExampleActivity extends Activity" but i am getting an error "Activity cannot be resolved to a type" in Eclipse. Oct 09 16:04:01 s1gmab3ta: it only calls it if you make the fragment visible +/- 1 Oct 09 16:04:27 skrite, organize imports? Oct 09 16:04:31 so if you have 10 fragments, at the beginning its only called for fragment 0 and 1 Oct 09 16:04:47 once you switch to fragment 1, it will call it for 2 and so on Oct 09 16:05:01 do i need to import the MainActivity into another class in the same package? Oct 09 16:06:00 skrite, it sounds like you need to import android.app.Activity into the file you're working in Oct 09 16:06:30 ah, ok s1gmab3ta, thanks Oct 09 16:06:41 danijoo, it hasn't called getItem for any of them at all yet (I have a log call placed in getItem) but it's good that you bring that up because I forgot about that Oct 09 16:07:06 hm so they arent visible yet Oct 09 16:07:15 i dont know when exactly they are called. Oct 09 16:07:43 my guess is after onCreateView() Oct 09 16:07:52 never used a pager inside of a fragment unfortunatelly Oct 09 16:10:01 the great fragment debate still tops /r/androiddev :) Oct 09 16:12:32 hm, looks like new sdk tools are out Oct 09 16:15:10 How to do a zoomable svg fragment? imageview? webview? Oct 09 16:15:15 lol Oct 09 16:16:13 do i split on “^” or “\\^”? Oct 09 16:16:56 mcmaur: what are you using to show the svg? Oct 09 16:17:02 oh god, new NDK is all kinds of broken Oct 09 16:17:10 g00s, well it's worth debating Oct 09 16:17:23 Fragments are awful API which pretty much has no replacement :/ Oct 09 16:17:32 Mavrik yeah i think it is too (worth debating) Oct 09 16:18:16 back when romainguy was still here, we got into a debate about the idea of fragments in general Oct 09 16:18:40 i get the impression that sdk implemented an idea that wasn't very well thought out, and didn't have much dogfooding Oct 09 16:19:23 the whole android framework design would need an overhaul.. All those fragments and supportlibraries are just a gigantic patchwork of stuff. Oct 09 16:19:44 And it gets worse which each new api version. Oct 09 16:19:45 kinda like how some people think swift might be immature, because not enough large apps have been written in it to really know how well it holds up Oct 09 16:19:56 g00s, sadly that's what I think about pretty much most new APIs Oct 09 16:20:10 it's like the Google team never actually ever uses the APIs they churn out Oct 09 16:20:16 lol Oct 09 16:20:22 that is for sure Oct 09 16:20:36 I’m still waiting for the longpress swipe left to remove. Oct 09 16:20:47 from a list Oct 09 16:20:49 pretty much most new APIs after 4.x or so are clunky and not well thought out Oct 09 16:20:57 apparently you can have one or the other, not both Oct 09 16:21:28 tricknology, can't you implement it yourself? Oct 09 16:21:42 I Oct 09 16:21:52 I’ve looked into it and apparently there is some conflict Oct 09 16:22:04 with the pull to refresh Oct 09 16:22:27 i want pull to refresh and swipe left to delete Oct 09 16:22:30 danijoo, I actually love support libraries Oct 09 16:22:40 support libs are the only fresh meat we get ! Oct 09 16:22:49 i use stuff when it goes in the support lib Oct 09 16:22:50 they make implementing stuff way easier - compare that with iOS and mandatory fuckup of everything every minor revision Oct 09 16:23:04 our iOS codebase is ridden with #define statements for minor iOS revisions Oct 09 16:23:31 g00s, they should probably just decouple the APIs in support lib and update them via store :P Oct 09 16:24:00 I still want to see the person who authorized making Play Services the "library-to-end-them-all" of bloat Oct 09 16:24:19 yeah Oct 09 16:24:31 those need to be broken out into smaller things Oct 09 16:25:22 pieces029 now i'm using an imageview but i was showing a png Oct 09 16:25:38 i would also like to have more control over minSdk. for example, I would like to say requires 4.4.4 but won't work on 4.4.3 Oct 09 16:25:49 I'm doing startActivityForResult in a fragment, but it seems like onActivityResult is never called Oct 09 16:25:57 well this has made for an interesting thread http://www.reddit.com/r/androiddev/comments/2iodnx/advocating_against_android_fragments/ Oct 09 16:26:13 setResult is called in the activity Oct 09 16:26:24 even though, the Square approach they're advocating there is also kinda clunky Oct 09 16:26:45 mattblang yeah, thats what we've been talking about. the square piece is a good first shot. i'm not convinced either way, but the pro-fragment group isn't really coming up with good arguments either Oct 09 16:26:48 Mavrik yeah Oct 09 16:27:32 g00s, Mavrik it is funny to see the two opposing viewpoints both being at equal upvotes at the very top Oct 09 16:28:22 g00s, Mavrik I feel like in every discussion about fragments I've seen, it was about 50/50 Oct 09 16:28:25 Mavrik: clunky how? Oct 09 16:28:41 also, somewhat frustrating, is that the non trivial apps are becoming more closed / aosp stuff being abandoned. so when google experiments with new design patterns in code we don't get to see it Oct 09 16:29:15 i always thought architects specifically have a vision on how their apis shoule be used Oct 09 16:29:29 (and evolved, for that matter) Oct 09 16:32:06 g00s I wish that the AOSP would evolve more with the community. I do believe, correct me if I'm wrong JakeWharton, that OkHttp is being integrated right? What about stuff like Retrofit, Event buses, dependency injection, some of the awesome third party widgets (pull to refresh has now been integrated on both Android and iOS, but there are many others) Oct 09 16:32:33 OkHttp has powered Android's HttpURLConnection since KitKat Oct 09 16:32:46 JakeWharton oh cool Oct 09 16:33:01 Hello everyone ^-^ Could someone tell me how I can turn the custom created keyboard in a "global" IME? All I could find on the web is about keyboards that only work in there own application. Oct 09 16:33:51 mattblang i wouldn't want to see those tools integrated, they're too high level Oct 09 16:34:06 yeah, they work fine as-is Oct 09 16:34:34 and then we wouldn't have the issue of people assuming something is the correct approach because it's in the sdk Oct 09 16:34:40 JacobTabak, g00s yeah, but when someone starts doing Android they are considering the official API to be holy grail probably. I know I was like that. Then I realized, holy crap their are way better ways of doing this. Could have saved a ton of time Oct 09 16:34:45 when in reality there are lots of viable ways to do things Oct 09 16:34:54 some better htan others, some immature and rushed into the platform Oct 09 16:34:57 i would like to see google be more proactive at expanding UI widgets to the support library though; kinda like a power-pack Oct 09 16:35:22 mattblang so then someone will come up with abetter way to do something and then we'll be stuck with the one in the sdk Oct 09 16:35:25 g00s: they suck at deprecating things so that wouldn't work out well Oct 09 16:35:25 i don't do any custom stuff, too much hassle for a single person like me working on an app Oct 09 16:35:27 because it's canonical now Oct 09 16:36:31 g00s: Amen to the “no custom stuff”. Oct 09 16:36:32 g00s i guess when you write several apps and haev to do something unique in several of them Oct 09 16:36:39 i dunno Oct 09 16:36:41 i think its best the framework engineers know how the community is using their apis, and at least make sure they don't put something out that breaks our techniques - but they probably have different concerns than us, or even non-android api designers Oct 09 16:36:58 what about fragmentswitcher and stickyrecyclerheaders? Oct 09 16:37:01 i mean Oct 09 16:37:05 sometimes you need custom stuff Oct 09 16:37:12 because it just doesnt exist Oct 09 16:37:19 and you're solving the same problem in every app you write Oct 09 16:37:50 JacobTabak sure; it comes down to how many people are on your team to write and test custom stuff, risk taken on using external libs, etc. what you are willing to manage Oct 09 16:38:03 g00s i just open source the stuff Oct 09 16:38:12 the community helps Oct 09 16:38:19 if theres a demand for it Oct 09 16:38:45 amen. Oct 09 16:38:50 yeah, but open source isn't a sufficient litmus test to whether a library should be adopted. i guess where i'm coming from is mission critical IT systems, our process used in selecting libraries for those, etc Oct 09 16:39:07 g00s it depends on the scope of what you're doing Oct 09 16:39:10 Have someone here used Google Endpoints and implemented an Android client? I’ve followed their “helloendpoints” tutorial but getting an exception when trying to get the authenticated greeting. Oct 09 16:39:36 we used a number of indicators /metrics to judge the health of a project. for example, how active it was, how many bugs were open, how quickly those bugs were being fixed, etc Oct 09 16:40:16 nobody got fired for making bad decisions - unless they weren't backed up by date :) Oct 09 16:40:18 *data Oct 09 16:40:42 but if you picked out a library that brought the system down, didn't follow the process, heads rolled Oct 09 16:41:56 yea g00s i come from a differnt planet Oct 09 16:42:57 right now i'm not in that IT environment. but still, i see a lot of startups have substantial teams working on their android products. often 5 - 10 people. i'm just one person, and i have to deal with everything and find it usually overwelming. so i just stick to the simplest stuff Oct 09 16:43:36 and that makes me wonder, maybe google doesn't feel the pain of their bad API design decisions - becuase no matter how much extra work they make them, they can throw more resources at it Oct 09 16:44:22 i think twitter has dozens of engineers working on their android client Oct 09 16:44:48 seriosuly, WTF. its just a messaging app. but why ? is a robust and polished app such a pita you need dozens of people ? Oct 09 16:45:19 g00s I will say this, when I started learning fragments for making our app tablet optimized, I had such a hard time implementing Master-Detail. I'm not sure why. I am super comfortable with fragments now, but at the time it was so frustrating because it seems like such a simple idea. But that is the first thing I started doign with fragments, so I was learning fragments, so not totally fair to be mad at master-detail I guess lol Oct 09 16:45:39 g00s I think maybe it was all the edge cases, and the number of ways to do it. Oct 09 16:46:58 mattblang yeah i agree; i argues to romain that there needed to be some better glue / DSL ... something, to tie the information architecture of the app together with these fragments at a higher level. as is , too much sillyiness with (did i just rotate, is that fragment loaded, if not than maybe i should show it, etc) Oct 09 16:47:10 just horrible , horrible state management which becomes opaque and messy as hell Oct 09 16:47:37 g00s yeah, definitely. now that I am comfortable with fragments I am starting to like them I think. but man, I went through some frustrating times Oct 09 16:48:04 the twitter app is far from robust or polished Oct 09 16:48:06 g00s times where I felt so stupid. then Reddit and this IRC room made me feel better when I realized I wasn't the only one having trouble Oct 09 16:48:59 nor is it worked on by "dozens" Oct 09 16:49:28 stop being such an app snob Oct 09 16:49:32 the twitter app is bad ass Oct 09 16:49:34 JakeWharton there was a twitter blog last week that described their team, it implied dozens. i'll have to find it but maybe you are right there and know firsthand Oct 09 16:49:45 remember when it uses those quick actions for acting on items? Oct 09 16:50:00 yeah. so intuitive Oct 09 16:50:34 remember when they promised to open source the twitter app? Oct 09 16:50:44 thats when it was from google Oct 09 16:50:53 i guess they xferred ownership to writter Oct 09 16:50:57 *twitter Oct 09 16:50:59 hahah ayeah i remember that Oct 09 16:51:02 im still bitter Oct 09 16:51:07 ha Oct 09 16:51:18 afaik they completely rewrite it anyhow Oct 09 16:51:43 i remember, that talk 'rest on android' and thinking, holy shit i need to see how this is done! Oct 09 16:51:45 wait ... Oct 09 16:51:46 wait .. Oct 09 16:51:51 years go by ... Oct 09 16:52:16 but back then, the community knowledge, patterns, and libraries were not as mature as now Oct 09 16:52:52 yeah Oct 09 16:52:55 Any idea how to render a svg file in a GPL project? Oct 09 16:52:58 it was pre-square Oct 09 16:53:11 Syzygy_ just a guess, you have to call startActivityForResult on the fragment, not the activity. Oct 09 16:53:31 fragment.startActivityForResult(intent, code) Oct 09 16:53:42 Any idea how to render a svg file in a GPL project? Need it zoomable too Oct 09 16:54:16 niftynei, i'm doing it in the fragment, I had to implement a call chain so that the activitys onActivityResult calls my fragments onActivityResult Oct 09 16:54:16 http://sdtimes.com/scaling-android-development-evolution-twitter-app/ Oct 09 16:54:24 If I wanted to start doing testing for our Android app, what is a good starting point? Oct 09 16:54:40 "In the past nine months, the Twitter for Android team has grown rapidly from a staff of twelve to dozens" Oct 09 16:54:43 (which calls another fragments onActivityResult because i'm dealing with nested fragments, but it works now) Oct 09 16:55:02 mattblang i've spent 3 days so far, and i still think i've got a good 3 more Oct 09 16:55:22 g00s: do they have other apps? not just the main public messaging app... Oct 09 16:55:24 JacobTabak are you using the built in testing, or third party libraries? Oct 09 16:55:30 Leeds not sure ... Oct 09 16:55:37 mattblang the built in testing wont' get you anywhere Oct 09 16:55:38 right on. yeah, i've done that before. Oct 09 16:55:38 maybe one for 200 character limit Oct 09 16:55:46 Vine, for example Oct 09 16:55:47 experimental, in the works Oct 09 16:55:52 heh, no idea Oct 09 16:55:52 JacobTabak so any suggestions on where to start? Oct 09 16:55:57 there are 2 routes Oct 09 16:55:59 do you want unit tests Oct 09 16:56:02 or ui tests Oct 09 16:56:22 niftynei, only problem now is that the result code is 65539 and that's slightly off the 3 I think it should be Oct 09 16:56:26 JacobTabak can you not hvae both? Oct 09 16:56:32 mattblang they're entirely separate beasts Oct 09 16:56:51 JacobTabak what would your suggestion be for the first one to start on Oct 09 16:57:16 JacobTabak I've really neglected learning unit, integration testing on my previous projects. Trying to rememdy that now with this Android project I am on Oct 09 16:57:18 depends what you have a need for Oct 09 16:57:28 mattblang do you have complex business logic that needs to be tested? Oct 09 16:57:38 or do you just want to have something that cliks around in your app and make sure it doesnt crash doing different things Oct 09 16:57:44 busines logic is definitely easier to test Oct 09 16:57:47 Syzygy_: fragments use the upper 16 bits of an int for their result code Oct 09 16:57:50 JacobTabak ahh , yeah, definitely business logic. hitting a REST interface, populating a local DB Oct 09 16:58:00 or maybe it's the lower 16 bits and 0xFFFF0000 for the rest Oct 09 16:58:10 JakeWharton, is that different from activitys result code? Oct 09 16:58:19 it's the same mechanism Oct 09 16:58:29 ok Oct 09 16:58:33 i mean request code btw Oct 09 16:58:34 so you probably want to start with robolectric ... but bad news is there's no source of truth for how to do it Oct 09 16:58:34 i'm just saying when you startForResult from a fragment it ORs the 0xFFFF0000 to it Oct 09 16:58:41 i should write a twitter client that uses compression Oct 09 16:58:47 get a few celebrities on it Oct 09 16:58:54 it'll blow up Oct 09 16:58:56 mikedg: gzip tweets Oct 09 16:58:59 tehres lots of fragmented blog posts, third party gradle plugins, and other dependencies Oct 09 16:59:03 then i can bitch and moan about the key limits Oct 09 16:59:10 60% more character capacity Oct 09 16:59:13 Gzeet Oct 09 16:59:23 yeah strip out all the vowels Oct 09 16:59:34 JacobTabak so say I went the unit testing approach for business logic. you mentioned the built in API is not good (which I already knew from past readings). any suggestions for a framework to look at? Oct 09 16:59:52 boo Oct 09 16:59:56 JakeWharton, I'm not quite sure how doing that is usefull. so basically I can't do requestCode == MY_FINAL_STATIC_INT_REQUST_CODE? even though I believe it has worked before Oct 09 17:00:07 you can inside of a fragment Oct 09 17:00:10 mattblang tehre's really nothing wrong with starting by writing your tests in ApplicationTestCase that gives you access to context Oct 09 17:00:18 but the issue is you have to run the test on a device or emulator Oct 09 17:00:34 and there's no good CI solution for that, so your tests will get negelected and be meaningless Oct 09 17:01:01 JakeWharton, I'm doing it inside of a fragment, but it still doesn't seem to work Oct 09 17:01:02 so our solution is to use robolectric, and i'm still working out the details on that Oct 09 17:01:27 for example mattblang i haven't been able to debug the tests in android studio, i can only run them via CLI... so now i'm working on restructuring the project and moving to intellij so i can debug the tests Oct 09 17:06:03 Any idea how to render a svg file in a GPL project? Need it zoomable too Oct 09 17:08:45 Hi, is there a way to get the size of the action bar with tabs in xml? I have an activity with the action bar overlaid Oct 09 17:13:40 who not just get tie size of the screen? Oct 09 17:13:43 why* Oct 09 17:19:12 i can't get blundell's robolectric demo to work :| Oct 09 17:19:33 http://pastebin.com/eV7ikfhq Oct 09 17:19:34 read the docs? Oct 09 17:34:23 how do i stop minifying javascript on debugging chrome for android? Oct 09 17:35:13 it's impossible to debug with minified js ;/ Oct 09 17:39:08 don't feed it minified js Oct 09 17:42:41 i have a pretty long view I need to make. Is this a viable plan on how to do it? (screenshot from the ios version) https://www.evernote.com/shard/s41/sh/4b9f8767-cd64-4290-a93c-fb55166b4d62/7ac9702a05b2aa26dbc573894762c298 Oct 09 17:43:43 Hi everyone Oct 09 17:43:52 good evening Oct 09 17:44:05 Ashiren to you too Oct 09 17:45:40 So I'm making an app which needs to get the user's lat and longitudes, and then fetch some locations from a web api and show them on the google map fragment Oct 09 17:46:55 the web api returns the lat/longs of the objects in question Oct 09 17:47:29 should I directly set the markers on the map using the said coordinates Oct 09 17:47:31 ?? Oct 09 17:47:37 I'm not very confident Oct 09 17:48:01 in my gradle tasks, i have this robolectric task: robolectric:testClasses - Assembles classes 'test'. [app:compileDebugJava, app:zipalignRelease, robolectric:classes] Oct 09 17:48:15 eggie5: It's pretty straight forward Oct 09 17:48:17 i'm trying to figure out why it's doing zipalignRelease Oct 09 17:48:19 i dont want that. Oct 09 17:48:45 DarkSlay3r: so do you agree w/ my plan/picture? Oct 09 17:49:53 it's very iOS... Oct 09 17:50:00 But i think it's workable Oct 09 17:50:41 you won't have a nice time using linear layout though... Oct 09 17:50:48 relative is more like what you want Oct 09 17:52:35 DarkSlay3r: ok, i can do relative, and then for lists w/ dynamic length i'll do a listview (embedded) Oct 09 17:53:00 DarkSlay3r: Will I have to wrap my relative layout in a scrollview to get scrolling action? Oct 09 17:53:12 Ok, i take it you are new to android Oct 09 17:53:28 has anyone read this, recommend it, or something like it? http://www.amazon.com/Social-Machines-Connected-Products-Customers/dp/1118471687 Oct 09 17:53:35 play around with it a bit rather than trying to work out all the problems now Oct 09 17:53:43 you'll learn as you go along Oct 09 17:54:19 eggie5 also, you may want to look at recyclerview but thats kinda beta atm Oct 09 17:55:34 g00s: i'll check that out (looks like L only) Oct 09 17:56:09 what about instead of an outer linear/relative layout make it an outer listview Oct 09 17:56:19 it will be available on others too, it does work on non-L its just packaged that way for the moment Oct 09 17:56:27 and then insert the static content using addHeaderView Oct 09 17:58:20 g00s: ahh RecyclerView looks like how ios forces you to implement a listview Oct 09 17:58:22 Hi! I am trying to write some code for an IMU but since I don't have it with me, I thought I could use my phone as one, I have written some code that sends the acceleration data from my phone to my computer but I can see that the acceleration is processed by Android (Az for example is consistently 9.8). Is there a way to get the raw values? Oct 09 18:00:16 but anyways, looking for advice on how to implement this layout: https://www.evernote.com/shard/s41/sh/4b9f8767-cd64-4290-a93c-fb55166b4d62/7ac9702a05b2aa26dbc573894762c298 Oct 09 18:02:46 eggie5 hm, i suck at this but ... i think the whole thing needs to be a listview Oct 09 18:02:47 onto: it's not processed.. that's the acceleration due to gravity. Oct 09 18:03:01 that's the actual measured value.. Oct 09 18:03:03 eggie5 look at something called cwac-mergeadapter Oct 09 18:03:18 so each section will use a different adapter Oct 09 18:03:39 'make this drink' will be another adapter Oct 09 18:03:53 it all gets funneled into one big adapter :) Oct 09 18:03:57 god i hate listview Oct 09 18:04:00 JesusFreke: I understand that, but I would like to get the raw hardware values (For example my IMU gives a range between -2^7 to 2^7 - 1) Oct 09 18:04:42 ahh, ok. Yeah, I guess there might be a layer in there that converts the values from the chip to standard units Oct 09 18:04:55 but, afaik, it's not exposed to apps :) Oct 09 18:05:02 JesusFreke: I see :( Oct 09 18:05:18 you might be able to poke at some device nodes or something.. but my guess is that you wouldn't have access Oct 09 18:05:36 onto if your laptop has BLE maybe you can look into a TI SensorTag :) Oct 09 18:05:51 then you won't need to do the android part Oct 09 18:06:04 onto: why do you want the raw values? Oct 09 18:06:23 g00s: It does not :( Oct 09 18:06:41 onto well you can get very cheap USB / BLE sticks but ;) Oct 09 18:06:43 well, that's easy to fix :) Oct 09 18:07:41 JesusFreke: I want to use my IMU (which I do not currently have) for inertial navigation, I want to use the IMU in the phone to "mock" my IMU, so that I can change some parameters and have it work with my IMU. Oct 09 18:08:10 onto: could you convert the values yourself? Oct 09 18:08:46 JesusFreke: I could scale them, yes. Oct 09 18:09:43 As far as I know, there's no processing that happens on the data, other than that conversion. No low pass filter or anything like that Oct 09 18:09:47 not positive though Oct 09 18:10:51 JesusFreke: I think it's just a scaling (or perhaps there is some bias removal) so hopefully the data is still representative of the original hardware values. Oct 09 18:11:00 yea Oct 09 18:11:11 ... I hope :p Oct 09 18:11:14 hehe Oct 09 18:11:40 note: if you really want the data, you should be able to get it on a rooted device Oct 09 18:12:16 JesusFreke: I do have a rooted device! Oct 09 18:12:39 Is there a /dev/accelerometer? :p Oct 09 18:12:51 it's probably not called that, but likely yes :) Oct 09 18:12:56 i bet different phones do different things to the data Oct 09 18:13:15 this sounds like one of those painful areas on android Oct 09 18:13:15 g00s: Yeah, that would make sense since different IMUs have different bias Oct 09 18:14:36 perhaps one of the /dev/i2c-* Oct 09 18:14:39 onto: the kernel source for your device should be available, so you should be able to find the driver for the accelerometer stuff Oct 09 18:14:49 and figure out how to interface with it Oct 09 18:15:13 but, this is straying into #android-root territory :) Oct 09 18:15:43 I'm going deeper in the rabbit hole ... I got here from #android :p Oct 09 18:15:50 onto lol! Oct 09 18:15:51 Not sure if I should continue Oct 09 18:16:07 onto #android-root will send you to #android-bluepill Oct 09 18:16:40 guys, anyone know why my robolectric testClasses task is running proguard/packagin for releaes? how can i stop that Oct 09 18:17:03 mattblang: I don't get the reference :( Oct 09 18:18:47 heres the task description: robolectric:testClasses - Assembles classes 'test'. [app:compileDebugJava, app:zipalignRelease, robolectric:classes] Oct 09 18:18:59 i need it not to run zipalignRelease Oct 09 18:25:18 Hi, is it bad style to set an object of a own class as a tag on a view? How much does object size influence the efficiency of the app? Oct 09 18:29:06 whats the best way to add a twitter handle to your app's Play description? do you just put it as http/twitter/etc, or do you put it as the website in the desciption ? Oct 09 18:29:27 g00s: https://github.com/commonsguy/cwac-merge seems pretty promising Oct 09 18:30:15 eggie5 pretty likely recyclerview will be generally available in the next few weeks or so, if you can wait Oct 09 18:30:33 you can always grab it now and hack it into your project, or set targetSdk=20 Oct 09 18:30:52 g00s: recyclerview is just a listview type implementation that handles memory better, isn't it? Oct 09 18:31:04 g00s: recycles cells that are off the screen Oct 09 18:31:17 g00s: I really just hope they'll get AndroidStudio out of beta Oct 09 18:32:00 eggie5 i haven't played to omuch with it, i hear its 'listview 2" Oct 09 18:32:05 eggie5 http://www.reddit.com/r/androiddev/comments/2il7ud/psa_the_old_workaround_for_using_support_v7/ Oct 09 18:32:11 in case you need to wrangle it a bit Oct 09 18:32:57 yeah, what I need is layout that can support static content views with listviews inbetween Oct 09 18:33:19 i just dont know what kind of container to put it in Oct 09 18:33:22 DarkSlay3r its fine; crashes a bit but hasn't been a show stopper Oct 09 18:33:35 a larger listview to hold the views Oct 09 18:33:44 or a linearlayout/relativelayour Oct 09 18:33:51 hopefully google will expand the docs for it :) Oct 09 18:34:01 DDMS Oct 09 18:34:13 It's horrible to use there... Oct 09 18:34:21 Hi! Are there any ways to get Bluetooth Low Energy (BLE) working in Android 4.2? Specifically on an Samsung Galaxy Tab Lite (SM-T110), or in general? Oct 09 18:34:24 Plus it's a battery hod Oct 09 18:34:28 hog** Oct 09 18:34:39 jost yeah, with Samsungs BLE apis possibly Oct 09 18:34:45 but not androids Oct 09 18:35:23 g00s: ok, do you know an app that works? I've tried some, but they don't seem to work Oct 09 18:35:39 jost well they have a hard time working on 4.4.4 too so ... Oct 09 18:35:59 JakeWharton (using blundell's template) adding my app module as a dependency on my test module adds the 'zipalignRelease' task to the 'testClasses' task dependencies. this forces 'testClasses' to run proguard and sign which won't work because signing credentials won't be on my CI server. did you run into this issue? Oct 09 18:36:27 no, we don't have signing configured for our release builds Oct 09 18:36:33 lol what Oct 09 18:36:45 we don't use gradle to sign our release builds Oct 09 18:36:45 you always have these bombs you drop Oct 09 18:36:55 that i'm so not prepared to deal with Oct 09 18:37:01 how do you sign them? Oct 09 18:37:08 cli? Oct 09 18:37:12 hells no Oct 09 18:37:23 gradle plugin + remote service + ldap&OTP Oct 09 18:37:44 shiettt... do you have a link that would explain that, or do you have a simpler suggestion for my issue? Oct 09 18:37:59 JacobTabak tough is the path following the jedi masters Oct 09 18:38:11 indeed it is Oct 09 18:38:18 it doesn't really matter what we do Oct 09 18:38:27 why does that solution require the zipalign task to run? Oct 09 18:38:32 i have no clue Oct 09 18:38:39 well that's what should be fixed Oct 09 18:38:39 but if you added a signing config to blundell's template Oct 09 18:38:47 it fails if the credentials aren't there Oct 09 18:39:17 oh because it specifies a dependency on the apk via the compile project() crap Oct 09 18:39:22 that can be changed Oct 09 18:39:26 any hints? Oct 09 18:40:32 one sec Oct 09 18:41:32 wonder how long it takes to sync android tree ;) Oct 09 18:41:34 tasks.findByName('compileJava').dependsOn(':app:compileDebug') Oct 09 18:41:37 maybe Oct 09 18:41:41 i'm just guessing Oct 09 18:42:02 and then remove that compile dependency on the app Oct 09 18:42:10 i'll give it a shot Oct 09 18:42:12 thanks! Oct 09 18:42:25 has anyone seen this before ? Error:Configuration with name 'default' not found. Oct 09 18:42:29 the applicationVariants.toList().first() is wrong Oct 09 18:42:36 you should be grabbing the variant you want Oct 09 18:42:52 which is probably debug, but also probably is first Oct 09 18:42:59 JacobTabak: may I ask what are you doing? ;) Oct 09 18:43:05 this began to occur in another users branch after they added a module Oct 09 18:43:06 yeah, it is, this stuff is very hard to understand for me because i can't attach a debugger Oct 09 18:43:18 gordon_ using blundell's robolectric template Oct 09 18:43:28 a Oct 09 18:43:30 have fun ! Oct 09 18:43:52 JakeWharton btw the applicationVariants.toList() part doesnt' cause an issue Oct 09 18:43:58 it's just the 'compile androidModule' that adds the dependency Oct 09 18:43:58 i know, but it's dumb Oct 09 18:44:02 i know Oct 09 18:44:05 btw Oct 09 18:44:08 can anyone tell me Oct 09 18:44:22 why gradle plugin always checks all app variants ? Oct 09 18:44:32 "checks"? Oct 09 18:44:35 even if I specify task like assembleDevelopmentDebug Oct 09 18:44:48 because the project config is an immutable model Oct 09 18:44:55 it has to build the whole thing before it executes anything Oct 09 18:45:03 eh... Oct 09 18:45:09 great Oct 09 18:45:29 that's why I need to wait 1 minute each time before run app.. Oct 09 18:45:36 use the daemon Oct 09 18:45:40 try --configure-on-demand Oct 09 18:45:42 add --parallel Oct 09 18:45:54 I got daemon in gradle.proporties Oct 09 18:45:57 and parallel too Oct 09 18:46:14 it takes about 5-7 sec to check if stuff is up to date for me Oct 09 18:47:03 JakeWharton it worked... thank you so much - tasks.findByName('compileJava').dependsOn(':app:compileDebugJava') Oct 09 18:47:14 i'll try to spread the good word, but seems like nobody else ran into it Oct 09 18:47:32 Ha, nice Oct 09 18:47:39 I'll have to update our stuff to that Oct 09 18:48:28 actually after a rebuild i'm running into some other issues :\ Oct 09 18:48:41 but i think i know where to start to fix them Oct 09 18:51:08 JacobTabak: are you trying to use robolectric plugin ? Oct 09 18:51:14 no Oct 09 18:51:43 you don't need it with this method Oct 09 18:52:01 any ideas about this error? "Error:Configuration with name 'default' not found." Oct 09 18:53:40 what is strange is when the module was added it pulled the source under the app folder and created a copy at the project folder Oct 09 18:53:52 JacobTabak: I'm currently using robolectric but still need to wait for full gradle build each time Oct 09 18:54:00 so it takes like 1 minute to run Oct 09 18:54:07 why do you need to do that? Oct 09 18:54:30 that's what the task does Oct 09 18:54:36 will show you tomorrow ok ? Oct 09 18:54:38 I mean today Oct 09 18:54:45 time difference Oct 09 18:55:02 do you do ./gradlew test ? Oct 09 18:55:18 probably Oct 09 18:55:23 i dont remember nw Oct 09 19:09:13 Hey are there any other good books on Android besides Big Nerd Ranch? Oct 09 19:10:38 mark murphys book is good Oct 09 19:10:41 but hes a bit of a dick Oct 09 19:11:21 he's system emailed me after the fact that my subscription was about to expire and to get the books while i still can Oct 09 19:11:51 and he had updated it like a day after that Oct 09 19:12:52 hey guys, I'm writing build.gradle to package a library project Oct 09 19:13:12 is there a way to sign the .jar distribution? Oct 09 19:13:28 or what is rather what's the best practice? Oct 09 19:15:54 i had the early commonsware books, meh. i don't have that subscription any more :) Oct 09 19:16:08 maybe its improved a bit and i should check it out again Oct 09 19:16:33 my laptop folds like a book, and the contents are the entire internet Oct 09 19:17:32 lol ok Oct 09 19:17:45 I'll check our Mark Murphys book. Oct 09 19:17:51 *out Oct 09 19:18:40 g00s: its a very good reference Oct 09 19:19:01 wait, I have to subscribe for a book? Oct 09 19:19:02 mikedg did he change the chapter headers from jokes to something useful ? Oct 09 19:19:18 Can't I just buy the entire thing? Oct 09 19:19:52 well it updates frequently Oct 09 19:19:55 you get a year of updates Oct 09 19:20:21 after X years or XK copies an edition goes creative commons Oct 09 19:20:29 hey guys anyone have experience with exceptions/causes? Oct 09 19:20:30 what happens after a year? Do I still keep the digital copy of the book? Oct 09 19:20:43 yes Oct 09 19:20:47 you just cant get new updates Oct 09 19:22:27 psobko: everyone. Oct 09 19:23:56 ah cool. Thanks. Sounds like a good deal then :D Oct 09 19:24:00 Thanks! Oct 09 19:26:10 I'm writing an API client using Volley and Jackson with DataBind. Every response I get back from the server can potentially have one of 3 errors which I want to handle in the response listener. I'm wondering if I should create 3 new exception classes or if there's a better way of handling each error? I'm coming from Obj-C where I would have a custom error class with the 3 error codes and switch through those. Oct 09 19:27:18 Custom error classes seem to be fine Oct 09 19:32:55 hmm ok, would it be possible or make sense to extend a base exception class and pass the extended class as a cause? Oct 09 19:49:11 JakeWharton FYI http://pastebin.com/dU2AfukA problem solved Oct 09 19:49:35 remove 'compile', add 'evaluationDependsOn' out of dependencies Oct 09 19:49:36 Anyone know how to hide action bar tabs without hiding the actionbar? Oct 09 19:50:35 .setNavigationMode Oct 09 19:51:13 thanks Oct 09 19:51:20 JacobTabak: i still don't think that's right Oct 09 19:51:27 it works after a clean Oct 09 19:51:39 on my dependency muddled project Oct 09 19:52:10 the javaCompile.classpath and javaCompile.outputs.files add a dependency on app:compileJavaDebug Oct 09 19:52:28 which I believe solves the problem that he was trying to solve with the 'compile(':app')' Oct 09 19:52:41 as far as I can tell, all compile(:app) was doing was forcing gradle to evaluate that project first Oct 09 19:52:44 indeed Oct 09 19:52:46 also true Oct 09 19:53:17 what are your doubts? Oct 09 19:53:54 you shouldn't have to do that test crap at the bottom Oct 09 19:53:59 oh Oct 09 19:54:05 i just copied that from his sample project Oct 09 19:54:15 i was gonna tweet it to him just so he was familiar with the rest of it Oct 09 19:54:20 (blundell) Oct 09 19:54:30 but yeah i have no clue if thats necessary or not Oct 09 20:08:10 the scanForTestClasses thing at the bottom is necessary http://stackoverflow.com/questions/14814837/gradle-test-fails-with-error https://issues.gradle.org/browse/GRADLE-1682 Oct 09 20:10:59 wow, amazon is opening up its first brick and mortar store Oct 09 20:12:26 so apple, microsoft, amazon all have stores ... where is google :) Oct 09 20:12:51 there's a google store... Oct 09 20:12:55 on campus. :) Oct 09 20:12:57 haha Oct 09 20:22:47 JacobTabak: that should be able to be fixed by setting the -bootclasspath when java is invoked to run the tests Oct 09 20:23:27 hm seems like it would be easier to configure in build.gradle, or do you feel otherwise? Oct 09 20:23:46 er, what? Oct 09 20:24:04 how do you set -bootclasspath when running the tests? Oct 09 20:24:13 sometimes you run them from cli / ci / IDE Oct 09 20:24:19 can you do it in one place to handle all those cases? Oct 09 20:24:31 yeah, same as all the other changes we're making Oct 09 20:24:38 just have to find the flag on whatever task Oct 09 20:25:01 hm, may be too much for me to chew on right now Oct 09 20:25:11 because i'm not following Oct 09 20:26:28 So did anyone read that "advocating against fragment" post on the square blog yesterday? Oct 09 20:26:32 i did Oct 09 20:26:47 haha Oct 09 20:27:50 I'm still wondering where all the lifecycle management logic would go if there aren't any fragments Oct 09 20:28:05 like registering/unregistering listeners or stuff, all in one activity? Oct 09 20:29:35 listeners for what? Oct 09 20:30:00 sensors maybe, or even like registering/unregistering on the event bus Oct 09 20:31:43 I can explain in 30. Got a meeting and current ly on mobile Oct 09 20:32:37 i'm not really sure how to handle this UI situation. i want to allow the user to connect to multiple BT devices, in the case of BLE it should be easy for n < 4 i'm thinking. but the limit is not knowable, and it would be poor if the user selected the 5th and the other dropped their connections Oct 09 20:32:58 Cool JakeWharton, will wait Oct 09 20:33:00 i think it basically depends on the user's device Oct 09 20:38:39 g00s, I know what you mean.. I get problems sometimes with too many paired devices Oct 09 20:38:52 not with BLE Oct 09 20:39:14 but sometimes I hit btAdapter.getDeviceName() and it returns the wrong device Oct 09 20:39:31 wow, thats bad :| Oct 09 20:39:43 yeah.. a device that is off, even Oct 09 20:39:50 just paired still Oct 09 20:40:07 not sure if it’s as a result of too many devices or what Oct 09 20:40:27 its probably just same ol - shitty buggy android code Oct 09 20:40:47 as the days go on you seem more and more convinced of that lol Oct 09 20:41:02 you would think… it’s google. they should be geniuses over there Oct 09 20:41:23 well, maybe even a pack of geniuses doesn't guarantee awesome Oct 09 20:41:30 maybe it’s a weird dimension.. if they hire me everything will be golden Oct 09 20:41:32 ;-) Oct 09 20:41:54 psuch Oct 09 20:41:58 psych* Oct 09 20:42:05 there should be a method on the BT adapter like int getMaxConnections() Oct 09 20:42:30 depends on the hw the oem uses. so google can't define it Oct 09 20:44:39 yeah.. Oct 09 20:44:47 I was looking around.. most docs say 7 BT devices.. Oct 09 20:44:49 tricknology for BLE there is https://code.google.com/p/android/issues/detail?id=68538 Oct 09 20:45:00 physics tells me that there is only so much bandwidth and power Oct 09 20:45:05 yeah but what about BLE + rfcomm connections ? Oct 09 20:46:29 and that patch is only for the number of registered devices in the service, witho no idea what the controller can physically handle Oct 09 20:46:38 I don’t knwo enough abotu BLE, unfortunately :( Oct 09 20:47:05 any way to monitor the performance of the BT chip? Oct 09 20:51:59 is there another channel for android studio support? Oct 09 20:52:15 I am trying to open up a project, should I use Open or Import project? Oct 09 20:52:38 there are no iml files in folder Oct 09 20:52:53 Also, when opening projects to you open the project or the app folder? Oct 09 20:52:55 you would typically open a project if it was already an idea/AS project. Or import it if it isn't. Oct 09 20:53:03 I think you can open either Oct 09 20:53:24 there is also a directory based project layout, where the project files are in a subdirectory. Oct 09 20:53:29 You can also open build.gradle or pom.XML files Oct 09 20:53:34 so there's no top level .iml or .ipr or anything Oct 09 20:53:44 porn.xml O.O Oct 09 20:53:58 hehe Oct 09 20:54:05 Maven's weird like that Oct 09 20:54:25 also what is strange is they imported a module, it made a copy at the project level (without src) and another copy under the app folder with (src) Oct 09 20:54:46 this is a project that was created using an earlier AndroidStudio Oct 09 20:55:38 I think that's typically fine. It should be able to upgrade the project, if needed Oct 09 20:55:56 if you've never written an android app before, would you start with studio or eclipse? Oct 09 20:56:01 then I get errors like "Unfortunately you can't have non-Gradle Java modules and Android-Gradle modules in one project." Oct 09 20:56:44 can't find AndroidManifest.xml on the project folder Oct 09 20:58:48 https://www.irccloud.com/pastebin/rIsPvNdx Oct 09 21:02:07 cool gadget http://www.gizmag.com/ampy-is-a-small-movement-powered-usb-charger/34192/ Oct 09 21:05:41 says RFComm supports 30 channels waiting / 7 active Oct 09 21:05:44 g00s Oct 09 21:06:37 tricknology where ? Oct 09 21:07:19 bluecove-users Oct 09 21:07:20 https://groups.google.com/forum/#!topic/bluecove-users/jMORkqrqBeU Oct 09 21:08:06 tricknology yeah but thats only a theoretical max Oct 09 21:08:17 you're lucky to get 2 working rfcomm channels Oct 09 21:08:56 BLE should be either max 4 or 7 from the code Oct 09 21:09:05 depending on the version of android, haha Oct 09 21:09:42 anyone know of a good example of handling media playing in a service? Oct 09 21:10:01 MediaPlayer in a service* Oct 09 21:39:08 Hey guys inside my Android Studios emulator, when the app does launch.. I am getting Google Play services update error (here http://prntscr.com/4umx9q). Any clue how to fix this? And yes I am creating a google maps fragment and trying to use it in my main activity Oct 09 21:39:40 hey! you ! over tere using fragments ! Oct 09 21:39:53 cnap you are using features from a version of the services that are not available ? maybe Oct 09 21:40:10 cnap look at what version the emu has Oct 09 21:40:16 I have no clue, I am very new to Android. In buiild.gradle I have this compile 'com.google.android.gms:play-services:5.0.89' Oct 09 21:40:35 oh its Android L Oct 09 21:41:04 ok let me try with Android 4.4 and API 20 Oct 09 21:42:42 Anyone here with a tablet that can do me a favor? Install my game, take a screenshot and send me? Oct 09 21:43:16 Oh in earlier version I am getting this http://prntscr.com/4umz3d :S Oct 09 21:44:01 troned use emulator Oct 09 21:46:19 StingRay_, for some reason 7" and bigger wont boot for me Oct 09 21:46:39 i tried with and without haxm and it is not working Oct 09 21:47:14 make sure you scale it to fix display Oct 09 21:47:56 fit* Oct 09 21:50:19 i mean the simulator does not even boot, i dont even see the android bootup sequence Oct 09 21:50:24 it is just black Oct 09 21:52:32 ha sure Oct 09 21:52:36 troned pm me Oct 09 21:52:36 troned: What OS? That's the same issue I have. Oct 09 21:53:04 I have a tab 2 7 Oct 09 21:53:30 I meant for the emuloator. Oct 09 21:53:42 Check out Genymotion. I have found it way more user friendly. Oct 09 21:54:36 cnap, you need to install play services on your emulator is teems Oct 09 21:54:45 seems* Oct 09 21:54:56 oh yeah that's a thing you have to do too. Oct 09 21:55:07 tricknology: how to do this? from sdk manager? Oct 09 21:55:12 well, no you use the google api image Oct 09 21:56:03 I have installed google play services from SDK manager etc Oct 09 21:59:49 argh. Really hard to get help at Android-root... :-/ Oct 09 21:59:56 pieces029, well ubuntu but i had the same problems on Windows 8 Oct 09 22:00:29 Hi folks. I want to build a function to asynchronously spider a FlashAir SD card over HTTP. From a threading perspective, what would you recommend? I’ve considered using an executor with Futures. Oct 09 22:01:40 I don’t want too many stopped threads. Oct 09 22:02:51 how do i cache responses when the server doesnt support cache Oct 09 22:02:57 Has anyone ever compiled the source? Can you give me a hand? Oct 09 22:03:20 troned: I'm on fedora, and can only get the wear emulator to start. Oct 09 22:03:29 MikeWallaceDev…yay!…. erm… WRONG channel Oct 09 22:03:32 !! Oct 09 22:03:51 oh, I know, officially, I didn't ask a question :D Oct 09 22:04:12 but root isn't helping, and I need help :-/ Oct 09 22:04:20 stupid root Oct 09 22:04:24 :) Oct 09 22:04:27 :D Oct 09 22:04:28 If you were getting the error "You must call removeView() on the child's parent first" what would you do to debug it? Oct 09 22:04:49 pieces029 no need to debug really Oct 09 22:04:56 answer is there Oct 09 22:05:13 I mean I know what the problem is, but I have no idea where it is comming from... Oct 09 22:05:25 pieces029, funny that you mention, I'm on Fedora and can only get the Wear emulator to start too. (and genymotion) Oct 09 22:06:02 pieces029, you are trying to add the same child view twice Oct 09 22:06:08 pieces029 well it tells you the line, catch it and see what the view is when the exception fires Oct 09 22:06:27 not all that hard even in a mess of dynamically assembled screens Oct 09 22:06:37 None of the lines point to my code. Oct 09 22:06:41 pieces029, view.getParent().removeView(view) Oct 09 22:06:43 line numbers* Oct 09 22:07:18 then you are passing an already parented view to something that doesn't want it to have a parent ? maybe ? Oct 09 22:07:59 I mean all I am doing is opening an activity that attaches a fragment ot it. If i skip attaching the fragment it works so there is definatly an issue there. but what is really strange is this worked before and I didn't (I don't think) touched any code in there. Oct 09 22:08:11 MikeWallaceDev: You can't get genymotion to work on fedora? Oct 09 22:08:40 yes, I can Oct 09 22:08:47 oh ok. Oct 09 22:09:02 you said (and genymotion) must have read that wrong. Oct 09 22:09:42 I can get the Wear emulator to run (and genymotion) Oct 09 22:10:03 same here. Oct 09 22:10:20 I let the android emulator run for hours and it just sat there. Oct 09 22:11:25 yeah, very annoying Oct 09 22:12:49 If this was the correct channel, I would post this question : my vp8_asm_enc_offsets.asm file is corrupt. somehow ads2gas.pl is not compiling it correctly. I've searched for vp8_asm_enc_offsets* but there are 5 of them, which is the input to ads2gas? But it's not, so I wont. Oct 09 22:14:33 Lol what is that error comming from? Oct 09 22:15:08 don't know, that's why I want to know what the input file is, so that I can trace it Oct 09 22:15:34 the output file is filled with color codes! (you know, escape 13 ] ) Oct 09 22:16:49 HAXM if you ahve an intel comp Oct 09 22:16:56 CPU* Oct 09 22:17:03 speeds things right up Oct 09 22:17:21 I used to boot the emutor in 2-3 mins.. now it’s less than 45s Oct 09 22:19:03 HAXM doesn't support linux Oct 09 22:26:59 Ok guys in case some of you remember my problem.. i created an emulator which targets API 19 Oct 09 22:27:04 and now maps are being show fine Oct 09 22:32:11 My app plays multiple audio streams at once from multiple mediaPlayer objects. It works fine on every physical device I've tested, but I'm getting reports from a beta tester that on his phone (Sony Xperia Z Ultra) the sound is super choppy if he plays more than once sound at once. Can anyone suggest what might be causing that? The hardware is more than fast enough to be able to run the app properly Oct 09 22:38:08 what is the new function relative to addPreferencesFromResource from PreferenceActivity class which seems to be deprecated? Oct 09 22:39:22 oh yeah, i forgot about this http://www.javaworld.com/article/2824562/open-source-tools/google-asks-supreme-court-to-decide-android-copyright-case.html#jump Oct 09 22:49:46 I schedule a runnable with a handler in my background service. It works fine when the activity that created the service is still alive, the runnable never executes if the activity no longer exists. Can anyone explain why this is? Oct 09 22:50:07 is there a way to animate though layers? i dont want to modify my layers Oct 09 22:50:41 d0de did you bind to it ? Oct 09 22:51:00 yep Oct 09 22:51:47 d0de than its being destroyed Oct 09 22:52:31 so if you need to do work independent of activity being bound, you have to use startService Oct 09 22:52:40 g00s, but the service still exists - it still logs stuff Oct 09 22:52:49 oh weird, nm. no idea then Oct 09 22:53:30 when I start my activity, I check to see if the service exists - if it doesn't, I create it, and if it does I bind to it Oct 09 22:56:41 does anyone have any experience with the SeparatedListAdapter? Oct 09 22:56:49 giving me a lot of headaches with scrolling :( Oct 09 22:57:02 crashes with nullpointers inside the getView() method Oct 09 22:57:54 is that the sharky one ? maybe you can use cwac-mergeadapter instead Oct 09 23:16:22 Where should I handle the event when user clicks the default Settings button? Oct 09 23:18:05 I see that everyone says to handle it inside onOptionsItemSelected but doesnt work for me Oct 09 23:18:26 oops figured i think lol wrong class Oct 09 23:21:10 what does the "convertView" parameter returned in a getView method do/mean? Oct 09 23:25:59 hey guys Oct 09 23:35:29 one thing is for sure. whatever a nexus device does with BLE, a samsung device seems to do differently Oct 09 23:35:43 fml Oct 09 23:36:14 sometimes the nexus device does the sane thing, sometimes the samsung Oct 09 23:36:54 for example, on nexus startDiscovery reports classic & le devices, on samsung only classic (seems logical) Oct 09 23:39:13 when i receive a X-Cache: MISS answer from a server all the time it means that the resource can't be cached? Oct 09 23:46:11 There's a part of my code where I set the content view with setContentView() - is there a way I can compare the current root view with the one I'm setting to see if they're the same, so I can avoid setting it if they are? Oct 09 23:47:40 kinda sad that google released a new app on ITunes while the android state is still "coming soon".. Oct 09 23:48:39 what new app Oct 09 23:51:09 is iTunes an OS ? Oct 09 23:51:57 So the back button of the android goes to previous activity Oct 09 23:52:21 If I'm running a web IN the app, is there a way to have the back button go to previous page of the web rather than the app itself? Oct 09 23:52:43 Lencl: yes, you override onBackPressed() Oct 09 23:53:49 ah I see **** BEGIN LOGGING AT Fri Oct 10 00:03:14 2014 Oct 10 00:03:18 it caches based on http headers Oct 10 00:03:54 it's nothing to do with retrofit Oct 10 00:04:06 it uses the same rules that a browser or anything conforming to the spec does Oct 10 00:05:05 there are no cache-control headers or expires headers in that response Oct 10 00:05:38 oh Oct 10 00:06:01 so, as i thought, cant easyly cache any server response Oct 10 00:06:24 the server doesnt want you to cache it if it doesnt give those headers Oct 10 00:07:18 your solution is probably to add some logic to determine whether or not to make the request in the first place Oct 10 00:07:26 based on your apps caching rules Oct 10 00:08:51 You can add the caching header yourself if you're confident it's the right behaviour Oct 10 00:09:42 f2prateek when would you do that? Oct 10 00:10:12 and why would that be better than separating than implementing your caching logic at the place where you make the requests? Oct 10 00:10:18 No idea, just that its possible Oct 10 00:11:48 do you mean like creating a custom http client? Oct 10 00:11:58 i can't imagine that would be a good idea Oct 10 00:14:40 I've seen something like this http://stackoverflow.com/a/23503804/1431669 Oct 10 00:15:06 There probably exists something similar for okhttp too Oct 10 00:15:33 Again I've never had to use it, just pointing out that it exists Oct 10 00:15:49 that's adding request headers though Oct 10 00:18:34 Oh my bad, feel like I've seen a similar solution for responses though Oct 10 00:22:08 Maybe this is useful http://stackoverflow.com/a/23996674/1431669 Oct 10 00:29:53 hi guys is possible implement street view of my room in android app? Oct 10 00:30:22 and when i tap in the door show a toast? Oct 10 00:31:34 I usually tap my toaster for that Oct 10 00:31:36 if you start a mediaPlayer in a new thread, as the docs say you should, how to you control it from the main thread? Do you need to implement an interface? Oct 10 00:31:42 best part about genymotion 2.3 is that you can now distinguish between the app and the emulator icons Oct 10 00:31:56 d0de you use prepareAsync and then use the prepare callback Oct 10 00:32:03 you dont need to worry about threading it yourself Oct 10 00:32:12 its like setOnPreparedListener Oct 10 00:32:19 is possible? Oct 10 00:32:26 JacobTabak, but what about other operations? Like, pausing, changing volume etc. from the main thread? Oct 10 00:32:41 yes d0de you can do that from the main thread Oct 10 00:32:53 preparing is the only thing that needs to be done async Oct 10 00:33:00 there is anyone can help me? Oct 10 00:34:10 JacobTabak, what about local media that you can play without calling prepare()? Oct 10 00:34:20 you need to prepare local media Oct 10 00:35:03 huh - what happens if you don't? I realize that I haven't done that, but I haven't noticed any problems Oct 10 00:36:26 d0de: there is possible... implement stret view of my room in android app? and when i tap in the door show a toast? Oct 10 00:37:48 d0de if you don't prepare ahead of time there will be blocking Oct 10 00:38:42 JacobTabak, thanks, that's v helpful Oct 10 00:39:18 JacobTabak, could that cause audio stuttering Oct 10 00:39:20 ? Oct 10 00:39:28 it shouldn't Oct 10 00:41:11 ah :\ Oct 10 00:45:36 anyone get google apps (gmail, google play) working in genymotion 2.3 (one that came out on oct 7) Oct 10 00:47:43 I have multiple activities, i want only one activity on the task stack, (ie so the backbutton will always quit) no matter how many I start, what's the launchmode flag config to do this? Oct 10 00:48:13 "singleInstance|singleTop" ? Oct 10 00:49:14 should just have 1 Oct 10 00:50:11 lasserix there's no default config for this Oct 10 00:50:37 can you have heading elements in listviews, to indicate grouping? Oct 10 00:50:42 you'll have to override onbackpressed Oct 10 00:51:10 JacobTabak: what? Oct 10 00:51:12 like this lacx https://github.com/timehop/sticky-headers-recyclerview ? Oct 10 00:51:16 i have launcher Oct 10 00:51:23 when i start a new activity, what launch mode do i use? Oct 10 00:51:34 singleTop|singleInstance? Oct 10 00:51:47 back will always end the current activity, it will never end the activity that launched it unless you have custom code Oct 10 00:51:55 yeas thanks JacobTabak X) Oct 10 00:52:06 lacx thats for recyclerview, check out stickylistheaders Oct 10 00:52:08 for listview Oct 10 00:52:18 ok nice one cheers Oct 10 00:52:38 forget about backpressed, i want the activity is start to take the place of the activcity on the activity task stack Oct 10 00:53:15 call finish() on the first activity Oct 10 00:53:19 before startactivity() Oct 10 00:53:52 ugh that destroys all the state Oct 10 00:53:57 there is a way to do this with launchmode Oct 10 00:53:57 hey JacobTabak, is there a simple (and basic, no frills, just a diff bg col for eg) way to do it? dont really wanna use extra libs as its for an exercise Oct 10 00:54:18 store it statically Oct 10 00:54:22 :P Oct 10 00:54:35 onSaveInstanceState => sSaedState = bundle Oct 10 00:54:39 thats a horrible idea Oct 10 00:59:14 Where should I handle the click of a Preference like button ? Oct 10 00:59:38 in the button code? Oct 10 01:01:44 xD Oct 10 01:01:58 Well the button is defined inside the xml and I just create the fragment of settings Oct 10 01:02:18 which has that Log out button.. i tried with onOptionsItemSelected inside my Settings Activity class Oct 10 01:02:25 but it doesnt receive the event it seems Oct 10 01:09:23 Hello. Is this possible (screenshot: http://i.imgur.com/jEuMMX7.png) ? Any idea? Oct 10 01:09:59 do you guys a book on 2.3 and 3.0 is too old to learn on? Oct 10 01:11:59 thats subjective, but if you are only targetting 3.0 and less than sure Oct 10 01:12:10 why not read current? Oct 10 01:12:50 DadFoundMy a book on 4.4 would be too old to learn on Oct 10 01:13:26 lnoskhen https://github.com/timehop/sticky-headers-recyclerview ? Oct 10 01:13:40 whatitis: my cs teacher gave me this book. are there thaat many differences in jellybean and up that i should consider buying another Oct 10 01:13:58 DadFoundMy you'd be better off using online courses Oct 10 01:14:05 depends on your needs Oct 10 01:14:13 there are several free ones Oct 10 01:14:18 with video lectures, assignments etc Oct 10 01:14:19 JacobTabak: link? Oct 10 01:14:33 https://www.coursera.org/course/android Oct 10 01:14:44 whatitis: i know java and just would like to learn android, and plan on making some apps Oct 10 01:15:10 this one is offered in collaboration with google https://www.udacity.com/course/ud853 Oct 10 01:15:14 you can access the course materials for free Oct 10 01:15:42 JacobTabak: ohh. .thanks :) Oct 10 01:15:44 JacobTabak: is it too late to start the coursera or can i view past lessons? Oct 10 01:15:50 DadFoundMy i'm sure its not too late Oct 10 01:15:56 android has many subjects. decide an app, then learn. you dont need to know it all. just what you need Oct 10 01:16:00 DadFoundMy they've also ahd other sessions (i took that one for fun, and I thought it was quite good) Oct 10 01:16:10 you may not be able to participate in the peer grading Oct 10 01:16:12 if you'er late Oct 10 01:16:20 i started a linux coursera, but school/moving to china got in the way of that Oct 10 01:17:59 dadfoundmy, if you always have internet. SO & android docs are my # 1 gotos to learn. if offline the sdk has the docs on harddrive you can browse Oct 10 01:19:22 feels so good, spent the last 3 days setting up my project for testing Oct 10 01:19:30 now i can actually just write tests and not think about getting sht to work Oct 10 01:27:31 those request headers for cached resources only work if the response was cached at some point Oct 10 01:27:34 whoops i was scrolled Oct 10 01:43:29 AS 0.8.12 Oct 10 01:43:32 yea just read that Oct 10 01:43:52 no upgrade Oct 10 01:43:55 and Oct 10 01:44:05 i just did all this work to get intellij set up :P Oct 10 01:44:15 wat no update ? Oct 10 01:44:19 http://tools.android.com/recent/androidstudio0812released Oct 10 01:44:25 you need to do a clean install Oct 10 01:44:27 (again) Oct 10 01:45:16 JakeWharton "Prefer XML editor" Oct 10 01:45:45 Woot Oct 10 01:45:52 thats a nice thing Oct 10 01:45:52 Finally. Death to design view. Oct 10 01:45:58 and tools: namespace completion! Oct 10 01:46:01 i logged that bug huuu Oct 10 01:50:42 "We've found and fixed several significant bugs in the patching mechanism." ha, thats great Oct 10 01:52:41 You know what's crazy? Android Studio has yet another release, focusing on minor features, while this show-stopper still isn't fixed: https://code.google.com/p/android/issues/detail?id=65186 Oct 10 01:52:58 It's the definition of bike-shedding. Oct 10 01:53:17 given the id, or instance, of a RadioButton - how does one get its name? Oct 10 01:55:04 Nivag: What do you mean by "name"? The text it's displaying? Oct 10 01:55:45 where's the update Oct 10 01:56:02 my android studio is not finding it Oct 10 01:56:17 http://tools.android.com/recent/androidstudio0812released Oct 10 01:56:21 o ya Oct 10 01:56:23 clean install Oct 10 01:56:26 I think you have to do it manually. Oct 10 01:56:28 Yar. Oct 10 01:56:48 TacticalJoke: yes - I want to log the name of the button selected in a more user friendly fashion Oct 10 01:57:09 Nivag: The text it's displaying isn't really its name. I guess you can use "getText". Oct 10 02:00:33 TacticalJoke i'm running unit tests! Oct 10 02:00:50 \o/ Oct 10 02:01:02 Yes. lol Oct 10 02:01:16 I thought of you as I came in here. Oct 10 02:01:33 i only struggled for 3 days to get it working Oct 10 02:01:39 but now that its working , i am happy Oct 10 02:01:40 I wonder whether android-unit-test is worth considering. Hmm. Oct 10 02:01:43 That's cool. Oct 10 02:01:50 I'm putting off starting a new project because of this. :/ Oct 10 02:01:59 I wanna start the project in Android Studio. Oct 10 02:02:15 https://github.com/JCAndKSolutions/android-unit-test Oct 10 02:02:26 "A Gradle plugin to add unit testing to the Android's plugin. Prepared for Robolectric." Oct 10 02:05:36 TacticalJoke: thanks! grrrrrr............ casting is your friend RadioButton button = (RadioButton) pGroup.getChildAt(index); Oct 10 02:08:30 :) Oct 10 02:09:08 I don't know whether it's a good idea to start my new project in Eclipse and then import it into Android Studio when Android Studio has JVM unit testing. Oct 10 02:09:12 Whenever that is. Oct 10 02:09:47 I know they've done work on some Eclipse-to-Android-Studio functionality. Oct 10 02:13:10 you like to do everything yourself so i won't tell you what to do Oct 10 02:13:46 I do everything by myself after seeking as many opinions as possible. :D Oct 10 02:13:51 I do take your advice to heart, JacobTabak. Oct 10 02:14:08 who's opinion gave you the idea to use eclipse Oct 10 02:14:20 I think the only times I've disagreed were when we were talking about the ownership of AsyncTasks and the use of checked exceptions. Oct 10 02:14:27 Google's did, ages ago. Oct 10 02:15:02 The implied opinion from their web pages, anyway. Oct 10 02:16:00 TacticalJoke: what are you gonna make ? Oct 10 02:16:42 it better be like the biggest thing ever Oct 10 02:17:09 The best Reddit client ever. Oct 10 02:17:29 If it's not the best, I won't even bother releasing. Or your money back. Oct 10 02:17:34 not another one! Oct 10 02:17:44 It's another Reddit client, but not another good Reddit client. Oct 10 02:17:47 Calling getHeight on a view includes its top/bottom margins? Oct 10 02:17:52 Because there are no good Reddit client. *audience gasps* Oct 10 02:17:55 clients* Oct 10 02:18:23 TacticalJoke: just use intellij Oct 10 02:18:23 TacticalJoke: I dare you! Oct 10 02:18:41 lasserix: Yeah, was thinking 'bout that. Oct 10 02:18:49 I guess the move from IntelliJ to Android Studio would be easy. Oct 10 02:18:55 Though it doesn't use Gradle. Hmm. Oct 10 02:19:11 it does Oct 10 02:19:13 you just talk and talk Oct 10 02:19:16 shmooz: It'll be good with no ads. Oct 10 02:19:18 you just make an android application using gradle Oct 10 02:19:20 And free. Oct 10 02:19:24 Maybe open-source; not sure. Oct 10 02:19:29 (sigh) Oct 10 02:19:30 this guy. Oct 10 02:19:33 JacobTabak: I don't just talk. Oct 10 02:19:41 I've been in this game for many years. Oct 10 02:19:45 Just not the Android game. Oct 10 02:20:08 you have a bad habit of making statements that just aren't true Oct 10 02:20:14 Such as what? Oct 10 02:20:34 [21:19:02] Though it doesn't use Gradle. Hmm. Oct 10 02:20:37 I think what happens is that people assuming that because I am an Android n00b I must be a programming n00b. Oct 10 02:20:43 And they assume that some things I say are wrong. Oct 10 02:20:51 do i need to setup LVL licensing thing for a free app or thats just for paid/inapp purchase apps Oct 10 02:21:24 Oh, interesting. I thought it didn't support Gradle the last time I checked. Oct 10 02:21:48 it also supports java unit tests Oct 10 02:21:59 How do I get layoutparams on a view if i dont know parent type? Oct 10 02:22:03 and you can open a project in intellij, close it, open it in android studio, and do it over and over again Oct 10 02:22:04 Nice. Oct 10 02:22:10 That's awesome. Oct 10 02:22:24 Are any file-system changes made when you do that? Oct 10 02:22:24 lasserix didnt we just talk about this? Oct 10 02:22:36 no Oct 10 02:23:00 well i'm happy to talk about it with you if you give a little more context to the question Oct 10 02:23:11 Is Gradle fast or slow in IntelliJ? Oct 10 02:23:26 I need to measure a height of a listview, i need to subtract margins from this value, how can i get the margins of this value? Oct 10 02:23:28 TacticalJoke did you have 4G ram ? Oct 10 02:23:32 I know that Gradle is (or was, a few months ago) slow as anything on its own (i.e., outside of an IDE). Oct 10 02:23:34 Yeah, g00s. Oct 10 02:23:34 maybe that was somebody else Oct 10 02:23:38 TacticalJoke: same Oct 10 02:23:46 TacticalJoke using eclipse now ? Oct 10 02:23:49 Yeah. Oct 10 02:23:53 you'll feel pain Oct 10 02:23:55 Eclipse is fine with 4G. Oct 10 02:23:57 Okay. lol Oct 10 02:24:12 Everyone on SO seems to say that Eclipse uses loads of RAM and IntelliJ/AS don't. Oct 10 02:24:13 guys, do i need to setup LVL licensing thing for a free app or thats just for paid/inapp purchase apps Oct 10 02:24:15 lasserix margins aren't included if you call getHeight() of a view, only padding Oct 10 02:24:20 Does getHeight() include margin top and bottom? Oct 10 02:24:24 yeah Oct 10 02:24:24 TacticalJoke idiots everywhere ! Oct 10 02:24:25 so if you just call getHeight() on the view, you'll be fine Oct 10 02:24:27 so how do I get them? Oct 10 02:24:28 True. Oct 10 02:24:28 lol Oct 10 02:24:45 i'm saying you shouldn't need to subtract margins Oct 10 02:24:48 because they're not included Oct 10 02:24:50 in getHeight() Oct 10 02:25:06 TacticalJoke i'm running AS, but i barely have enough mem for chat and FF Oct 10 02:25:14 How much RAM do you have? Oct 10 02:25:19 and i need to purge caches often. 4G Oct 10 02:25:22 Okay. Oct 10 02:25:27 mac tho Oct 10 02:25:33 maybe windows is better Oct 10 02:25:39 How are you purging the cache? Oct 10 02:25:44 I guess that's a MacOSX thing. Oct 10 02:25:45 on mac? # purge Oct 10 02:25:50 OS X* Oct 10 02:25:51 $ purge Oct 10 02:25:52 Okay. Oct 10 02:26:19 after that the first minute is painful since there are no caches Oct 10 02:26:35 lol Oct 10 02:26:36 i guess i need a new machine :( Oct 10 02:26:49 it would be fine gradle + vim :) Oct 10 02:27:09 lasserix, if your margins are in /res/ you can just get them when you need em Oct 10 02:28:37 ahh this is for someone lse Oct 10 02:28:40 So I'm guessing there's not an enormous difference between IntelliJ with ADT and AS. Oct 10 02:28:40 i dont know how they'll do it Oct 10 02:28:46 so i need to do in code so it'll be robust Oct 10 02:29:21 tell them todo it right& use dimens or whatnot Oct 10 02:30:43 TacticalJoke what are you talking about "intellij with ADT" Oct 10 02:31:34 lol Oct 10 02:31:46 I thought they still called it "the ADT plugin" in IntelliJ. Oct 10 02:34:11 do you still think that Oct 10 02:34:35 JacobTabak: Do you think that "who's" is synonymous with "whose"? Oct 10 02:36:47 It is not possible to update UI from a background thread? Oct 10 02:37:09 SASDOE no, use activity.runOnUiThread() Oct 10 02:37:10 runOnUiThread or some such. Oct 10 02:37:16 JacobTabak: who's opinion gave you the idea to use eclipse Oct 10 02:37:52 i don't blame you for taking your victories where you can Oct 10 02:38:02 Nah, I'm pointing out that it's easy to nit-pick. Oct 10 02:38:13 I stored your error in my mind and didn't remark on it... until you remarked on mine. Oct 10 02:38:30 SASDOE: what they said. you can't update ui from any thread but the ui thread, but you can use runonUiThread(new Runnable() { ... stuff }); Oct 10 02:38:53 oh ok so not only are you an expert on these things you've never used, but you're not interested in being corrected when you make an incorrect assumption Oct 10 02:39:06 Great thanks all Oct 10 02:39:11 yet you think its relevant to the conversation to correct my grammar Oct 10 02:40:29 Your goal is not to teach: it's to be right. I was doing the same back to you. Anyway, this feel like kindergarten stuff now. Oct 10 02:41:00 i was trying to help you understand that android studio and intellij are literally the same software Oct 10 02:41:16 did you guys test AS 0.8.12 for me yet ? i wanna know if its stable :D Oct 10 02:41:36 g00s: i stopped updating AS a while ago when it broke all my shit, again, and I dind't have time to deal with it :P Oct 10 02:42:04 ha, that has a tendency to happen :) Oct 10 02:44:55 g00s: yeah it does, I just didn't have time to deal with it Oct 10 02:45:01 So could the AS devs copy the JVM-unit-test thing from IntelliJ to AS? Oct 10 02:46:25 considering they make money on one and not the other, i don't know if I'd count on it Oct 10 02:46:28 ohh ram just imploded Oct 10 02:47:16 TacticalJoke you can do it in android studio right now it's just a pain Oct 10 02:47:21 because AS dumbs down the UI Oct 10 02:47:38 and reorders dependencies in a way that breaks tests Oct 10 02:47:41 every time gradle syncs Oct 10 02:47:44 Oh. Oct 10 02:48:01 dragorn do you think it should be feasible to do bluetooth classic discovery at the same time as LE scan ? should be different radios, but maybe the controller can't meat all the hard real time requirements. i'm wondering what i should expect Oct 10 02:48:10 g00s: no idea Oct 10 02:48:29 Wow, the IntelliJ people have a video about unit-testing Android apps on the JVM. And it just auto-played and freaked me out. Oct 10 02:48:43 wheres this video? Oct 10 02:49:16 g00s: i'd be surprised if it could handle it Oct 10 02:49:42 yeah, i should prepare for the worst probably Oct 10 02:50:34 http://youtu.be/J946hLBHgGQ Oct 10 02:51:48 Hmm, the example ends up being about instrumentation testing. Oct 10 02:51:53 Though he talks about JVM testing at first. Oct 10 02:52:07 I don't think I'll ever do instrumentation testing. It's so horrible. :[ Oct 10 02:52:38 The docs paint it as some wonderful thing that Google spent time on. Oct 10 02:58:49 Wow, IntelliJ seems to support TestNG out of the box. **** ENDING LOGGING AT Fri Oct 10 02:59:59 2014