**** BEGIN LOGGING AT Tue Feb 09 02:59:59 2016 Feb 09 03:00:29 congratulations android dev world your dev tools are supposedly only like 5yr behind the competition now Feb 09 03:00:54 I got a neat litle bluetooth device Feb 09 03:01:08 relating to teledildonics? Feb 09 03:01:30 http://www.amazon.com/gp/product/B016B2BG62?psc=1&redirect=true&ref_=oh_aui_detailpage_o00_s01 Feb 09 03:01:49 25 bucks, its pretty nice especially for the price Feb 09 03:02:56 * capella googling teledildonics Feb 09 03:03:27 aaaaand I bet you didnt know there was a term for that... am i right? Feb 09 03:04:48 cheap bluetooth headsets sound like shit Feb 09 03:05:20 teledildonics takes the IOT way past smart fridges Feb 09 03:05:26 pfn: do you have one you like? Feb 09 03:05:38 I did research, all of them had negative reviews basically Feb 09 03:05:55 so I impulse bought this one Feb 09 03:07:24 I use a jawbone era Feb 09 03:07:31 have for a few years, it works ok Feb 09 03:07:43 need to replace it soon since jawbone eol'd this one a while ago Feb 09 03:07:50 I was considering that one Feb 09 03:08:06 those ear clip on ones don't seem very comfortable Feb 09 03:08:17 and you like a spaceman Feb 09 03:08:36 the braggi dash sound absolutely awesome Feb 09 03:08:38 I want thos Feb 09 03:08:46 http://www.bragi.com/ Feb 09 03:09:25 don't know how it works for phone calls, though Feb 09 03:09:36 expensive Feb 09 03:09:46 yeah I want it for calls while driving Feb 09 03:09:47 but it does bone conduction, so maybe it's good Feb 09 03:10:16 I used headphones forever, it works but the wire flops around and makes noise Feb 09 03:12:25 can you connect to two bluetooth devices simultaneously Feb 09 03:12:35 of different types Feb 09 03:13:44 I also have this one for connecting to my car stereo: http://www.amazon.com/recommend-iClever-Hands-Free-Multi-Point-Activation/dp/B00GJFGE0K/ref=sr_1_1?ie=UTF8&qid=1454987589&sr=8-1&keywords=himbox Feb 09 03:14:35 it would be nice to send media to the car stereo, phone calls to the headset Feb 09 03:14:45 you can do that Feb 09 03:14:52 those are 2 different device profiles Feb 09 03:15:32 sweet I've got to try it out Feb 09 03:18:07 the instruction manual on these cheap chinese electronics are hilarious Feb 09 03:19:00 "Don't make the headphone touch water with its non-waterproof" Feb 09 03:32:48 time to get rid of rxjava out of keepshare Feb 09 03:35:38 hi. need some quick help Feb 09 03:35:49 just downloaded Studio. when the installation completed it asked to download android v6.0 Feb 09 03:36:00 but i dont have interent data left. what to do ? will i not be able to use android studio now ?? Feb 09 03:36:08 THANKS Feb 09 03:36:56 get to mcdonalds and download the rest Feb 09 03:37:09 you need the SDK and assorted tools to do anything, yes Feb 09 03:37:13 so you need the additional data Feb 09 03:37:27 are you downloading this on mobile data? Feb 09 03:38:54 pfn: why rid of rxjava Feb 09 03:39:05 because it does nothing for me Feb 09 03:39:43 Means Feb 09 03:39:53 What were you trying Feb 09 03:40:31 I heard its good for reactive programming Feb 09 03:40:54 nothing, was just using it to adapt EditText -> TextWatcher -> a callback stream Feb 09 03:41:14 oh, I guess i use it in my fingerprint manager Feb 09 03:41:15 :( i just cannot download the addidional data at the moment.. what to do. sad Feb 09 03:41:51 Are there any cons of event driven programming(Otto event library)? Feb 09 03:42:20 oh I see planning to use rxjava in next project Feb 09 03:42:35 falcom, nothing wrong with event driven, but eventbus libraries like otto are too loosely coupled Feb 09 03:42:43 Use RxJava instead Feb 09 03:42:51 too many people remove @Subscribe'd functions because they're marked as unused by ide Feb 09 03:43:06 then you also have reflection overhead if you have a lot of events Feb 09 03:43:24 in java, I would use eventbus because it's so goddamn convenient Feb 09 03:43:29 too much boilerplate in rxjava Feb 09 03:43:33 JakeWharton for event driven programming Feb 09 03:43:40 smorgasbord, you'll have to go somewhere you can download the rest, because it's useless without it Feb 09 03:44:19 dragorn, thanks. . will try. closing. THANKS all as well. Feb 09 03:54:05 RxJava is nice, but yeah, require some boilerplate sometimes Feb 09 03:54:31 looks nicer with java8, scala, kotlin Feb 09 03:55:59 scala :S :S Feb 09 04:02:00 * loke`` just started doing Android with Kotlin. It's a bit nice, but it's no Common Lisp Feb 09 04:10:04 kotlin? Feb 09 04:11:12 Kotlin, Jetbrains language Feb 09 04:17:45 wyoung: ? Feb 09 04:18:04 rx is a bit nicer with lambdas. much cleaner Feb 09 04:18:05 what's wrong with scala? :) Feb 09 04:18:06 pieces029: ah ok Feb 09 04:18:33 gordon_: A lot of things, there is a presentation by one of the developers explaining them Feb 09 04:18:55 yeah, I've seen that Feb 09 04:19:24 gordon_: granted, it has its uses, although I would rather use jython than scala if I need something to interact with Java Feb 09 04:19:54 minor issues Feb 09 04:20:40 jython? lol Feb 09 04:20:51 nothing's wrong with scala Feb 09 04:21:16 I guess he's talking about previous dev of scala, dont remember who that was Feb 09 04:21:37 paulp Feb 09 04:22:11 a, yeah Feb 09 04:23:27 and yeah, sure, there's ugly spots in implementation, there's ugly spots in every language in existence Feb 09 04:23:31 pfn: jython <3 although scala with play! is funky Feb 09 04:23:33 scala community tends to be perfectionist Feb 09 04:23:40 so they bitchmoan about everything Feb 09 04:57:30 I'm trying to make a material designy transition from a NetworkImageView (from Volley) in one activity to another. The transition occurs, but the new activity doesn't display an image. Is is not possible to do this with NetworkImageViews? Feb 09 05:24:33 the image needs to be ready in order for the transition to occur Feb 09 05:42:48 I have a button that is horizontally centered at the bottom of a relative layout. What is the most idiomatic way to create an animation that modifies the Y coordinate of this button until the button reaches the center of the screen? Feb 09 05:50:45 button.animate().y Feb 09 05:52:55 pfn: Right. But how can I calculate the vertical center of the screen? Feb 09 05:53:04 do some math, and calculate it Feb 09 05:54:06 pfn: Thanks. Feb 09 05:56:10 nice! SublimeText 3 has a new build out \o/ Feb 09 05:56:36 how is it android related... Feb 09 05:56:50 It's my favorite editor Feb 09 05:56:58 Including java, c++, javascript, etc Feb 09 05:56:58 and ? Feb 09 05:57:41 writing java in sublime seems like masochism to me, but use whatever you want, still not related Feb 09 05:58:30 Mozilla still trying to get me to use intelliJ now that we support it, but ST3 wfm :) Feb 09 05:58:46 I'm one step ahead of the VIM guys XD Feb 09 05:59:04 I wonder.... Feb 09 05:59:55 wow ST3 is still alive ? Feb 09 06:00:17 i think atom grabbed all the good ideas and is executing faster though Feb 09 06:00:36 capella surprised, since you're a big JS guy, you aren't using atom and hacking plugins Feb 09 06:01:11 Meh, not "bug js guy", just that part of Gecko I do that the other pure-Java guys won't for Fennec Feb 09 06:01:42 Actually getting into the JNI stuff lately Feb 09 06:06:53 " Not only is Odersky hardly involved in any Scala compiler work these days, he also took with him all the previous top scalac contributors with him to work on Dotty." Feb 09 06:07:01 wow / d'oh Feb 09 06:08:28 oh so odersky wants to replace scalac with dotty Feb 09 06:09:11 bah, Rust will kill Feb 09 06:09:13 :) Feb 09 06:10:12 capella not even in the same space ... rust seems like a systems language Feb 09 06:10:29 unless they write jrust or something :D Feb 09 06:11:28 heh - my point was more like I don't see the need for more and more new languages ... I still hear how Java is dead Feb 09 06:12:31 Besides, Samsung iir is behind Rust and supporting Servo browser dev. including the Android version Feb 09 06:12:46 It's not Samsung that's behind Rust Feb 09 06:12:53 * capella hadda toss that in before gordon yelled Feb 09 06:13:20 ugh java is so primitive Feb 09 06:13:43 Levite: jdk8 includes a free javascript engine! Feb 09 06:13:48 it's name is Nashorn Feb 09 06:13:56 we can't use java 8 with android yet right? Feb 09 06:14:20 Levite: i'm okay with you using java 8 with android Feb 09 06:14:34 Levite: I'll allow it too Feb 09 06:14:36 You can use some part of Java 8 with Android with Retrolambda Feb 09 06:15:00 i'm needing something like swift's extensions Feb 09 06:15:09 Then use Kotlin Feb 09 06:15:29 java8 still not supported with android Feb 09 06:15:46 may be when google team port from jdk to openjdk Feb 09 06:16:01 still not clear whether thats openjdk 7 or 8 Feb 09 06:16:21 what about rxjava Feb 09 06:16:38 its giving you access of lamda expression Feb 09 06:16:54 No, that's what Retrolambda does Feb 09 06:17:12 rxjava doesn't give you lambdas Feb 09 06:17:24 ugh, refinancing and mortgages is such a pain in the ass Feb 09 06:17:25 my bad ;) Feb 09 06:18:20 pfn kotlin only for front end correct? Feb 09 06:18:30 huh? Feb 09 06:18:40 No, Kotlin works everywhere and especially well on Android Feb 09 06:19:25 ya I am asking specially for android only Feb 09 06:20:41 using retrolambda is really hack to me Feb 09 06:20:51 so if using retrolambda, I'd rather use kotlin or scala Feb 09 06:21:20 Same, I'd rather use Kotlin that Retrolambda. As for hack.. yes, I guess it is, but processing bytecode is a pretty solid technique Feb 09 06:21:29 gordon can I ask you why? Feb 09 06:21:33 retrolambda is a perfectly fine technique Feb 09 06:21:40 but lambdas alone aren't enough to make java worth using Feb 09 06:21:49 g00s, troll post Feb 09 06:21:53 pfn: the same as using other language Feb 09 06:22:06 martin odersky + 2 phd researchers isn't "the bulk of the scalac developers" Feb 09 06:22:14 dastan: because boilerplate is taking my soul to different world slowly Feb 09 06:22:28 hahaha Feb 09 06:22:58 while kotlin is marketed as better java Feb 09 06:23:07 scala is more popular with functional programmers Feb 09 06:23:13 use whatever works better for you Feb 09 06:24:31 ya you are right gordon but I looking for pros and cons Feb 09 06:24:40 so according to that I will use Feb 09 06:25:08 but anywhy I will do some code then only I will know Feb 09 06:25:38 anyone knows pros cons so he can save my time :) Feb 09 06:26:19 well, it's not like diving into scala for 10 minutes will let you know all the features Feb 09 06:26:33 especially when not changing language but paradigm Feb 09 06:26:55 unless you know haskell or some other fp language Feb 09 06:27:04 k got you Feb 09 06:27:12 "FP" Feb 09 06:27:34 there is no "" in FP Feb 09 06:27:43 ;D Feb 09 06:27:55 there's always something, even if it's Unit Feb 09 06:27:58 scala lets you use it as a better java and make the transition slowly, though Feb 09 06:27:58 :P Feb 09 06:28:11 unlike many FP languages Feb 09 06:28:38 learnt something thx gordon and pfn Feb 09 06:28:49 (y) Feb 09 06:29:40 Making the transition slowly literally, i.e. waiting for compilations to end ;) Feb 09 06:30:05 "It's not that scalac is slow, it's just letting you make the transition slowly" Feb 09 06:34:02 the compiler isn't that slow Feb 09 06:34:10 especially if you aren't taking advantage of all the features Feb 09 06:34:18 basic java++ compiles quickly Feb 09 06:34:35 I know, just being silly Feb 09 06:34:43 it's basically when you throw in all the complex types and whatnot that make it much slower Feb 09 06:39:36 Is there a best practice for accessing the controls of an activity from inside a view? For example, I have a WebViewClient, and I want to show a retry button, defined in MainActivity, when the onReceiveError() callback is called. Feb 09 06:40:12 I'm guessing I need to add the button to the context, but I'm not sure if that is the idiomatic way. Feb 09 06:41:24 view shouldn't know anything about anything higher in the hierarchy Feb 09 06:41:42 use a listener Feb 09 06:42:28 Levite: So the onReceiveError() fires an event, and the listener shows the button? Feb 09 06:43:00 yeah the listener is an interface. webview tells it's listener (activity) that an error was received, activity toggles button Feb 09 06:44:36 Levite: Awesome. Thanks. Feb 09 06:47:51 is there a way to put a listview inside a fragment and somehow pass the context into the custom adapter class? Feb 09 06:50:01 ideally the adapter shouldn't need access to the context Feb 09 06:50:18 but you could just define it in the fragment itself if you wanted to be lazy Feb 09 06:52:25 its not unusual to pass a context (or even the hosting Activity) to an adapter Feb 09 06:52:42 after compiling android with gradle, I will never say that doing the same with sbt is slow Feb 09 06:52:44 never Feb 09 06:52:58 ideally you just pass it a view or a resource id + inflater Feb 09 06:53:08 the adapter for a listview requires a context object to call the inflater object, I tried calling getActivity().getApplicationContext() inside the fragment but it returns null which is unusual Feb 09 06:53:25 oohhhhh jeez I am stupid Feb 09 06:53:32 Nevermind Feb 09 06:53:36 I realized the mistake Feb 09 06:55:20 ah yeah if you're just using a listadapter it's easy Feb 09 06:55:34 gordon_: Do you have that project that's slow to build with Gradle available on Github? I'd like to try to build it with Kobalt Feb 09 06:56:24 not now Feb 09 06:56:29 I used to have one Feb 09 06:56:35 my company's project Feb 09 06:56:52 damn, I was reading a lot of internet that time... Feb 09 06:57:17 now they gave me i7, 4cores + ht and 16gb of ram Feb 09 06:57:24 so even gradle cannot stop me Feb 09 06:57:30 unless... Feb 09 06:58:23 https://gyazo.com/3ac98f4bd93d7b69db8db5db22eb6672 Feb 09 06:58:34 please guide, thanks Feb 09 06:58:36 gradle 2.11 is out, don't see much interesting though Feb 09 06:58:51 "This time it's really faster. We think." Feb 09 06:59:00 smorgasbord: try once again ? Feb 09 06:59:12 CedricBeust actually , they didn't mention speed at all - ide model improvements Feb 09 06:59:35 presumably xav is working with them, maybe some fruit :D Feb 09 06:59:52 Xavier has been working with them since day one as far as I know Feb 09 06:59:54 well Feb 09 07:00:19 gradle's new logo is an elephant Feb 09 07:00:24 that would be funny if android's complexity spilled into gradle too Feb 09 07:00:34 seems like everything with elephant is.. troublesome Feb 09 07:00:38 *complex build requirements Feb 09 07:00:43 Oh I have a great idea for a logo for Kobalt: a rabbit. Feb 09 07:00:47 gradle, hadoop and... php Feb 09 07:00:51 php is the best example ;) Feb 09 07:01:07 gordon_ you mean fromt the beginning ? Feb 09 07:01:17 CedricBeust erm, i think RabbitMQ has that one :D Feb 09 07:01:20 smorgasbord: no, download Feb 09 07:01:23 ah right Feb 09 07:01:27 quick question, why didn't they use C++ as the language of choice for developing android applications? Feb 09 07:01:33 I think the fastest animal is a falcon, maybe I'll pick that Feb 09 07:01:42 gordon_ how to ? Feb 09 07:01:47 harsukh: do you want 10 android developers ? :D Feb 09 07:01:58 anwyas cancelled. Feb 09 07:02:00 harsukh: That's a very long and complex question Feb 09 07:02:21 I still dont understand why people got to iphone and obj-c Feb 09 07:02:25 it's horrible language Feb 09 07:02:31 (said java dev) Feb 09 07:02:39 CedricBeust: Php has a Phalcon framework. Not sure if the logo is indeed a falcon. Feb 09 07:02:39 ;D Feb 09 07:02:40 There's Swift now so Obj-C is going to slowly disappear Feb 09 07:03:01 from devs here... dont go for swift with existing project Feb 09 07:03:06 yeah and major push now to swift-ify the APIs Feb 09 07:03:06 or you gonna have bad time Feb 09 07:03:25 It wasn't pretty a year ago but it's getting very close to production ready Feb 09 07:03:43 alsono idea Feb 09 07:03:45 maybe Feb 09 07:03:54 no interest in iphones Feb 09 07:04:03 or other iStuff Feb 09 07:04:59 It's interesting that both mobile platforms now have very similar languages (Kotlin and Swift), which makes it easy for developers to switch from one to the other Feb 09 07:05:07 Of course you could argue the real difficulty is the API, not the language Feb 09 07:05:16 but it helps that the two languages are so close to each other Feb 09 07:05:32 gordon_ i pressed then cancel below.. but i see the download resumed... so now what to do ? https://gyazo.com/bde708528f817cbc1273b735678205bb Feb 09 07:10:38 CedricBeust: it doesn't help when they differ in tiny behaviour changes. Feb 09 07:10:46 Even between other platforms. Feb 09 07:11:30 Yeah that can be unsettling but I still think it's better than the alternative (e.g. having to switch from Java to Objective C) Feb 09 07:11:35 can I convert a java project to kotlin piece by piece or does it have to be all at one time? Feb 09 07:11:48 if by chance it is going to cancel out in the end, then it would be really sad.. Feb 09 07:12:10 "ab".split("") for example gives you ["", "a", "b"] on Android, but ["a", "b"] on all other languages. Feb 09 07:12:17 i want to use lambdas like now Feb 09 07:12:21 Even in Oracle Java. Feb 09 07:13:47 Levite: You can do it class by class, mixed projects work fine. You can also copy Java code and when you paste it, it gets automatically converted to Kotlin Feb 09 07:13:59 "@".split("@") gives you [] in Java and on Android, but ["", ""] in other languages — split("@", -1) does the same. Feb 09 07:14:26 It's seriously annoying to work with these tiny detail issues. Feb 09 07:14:53 Because they lead to hard to find bugs, unless you have proper unit test. Feb 09 07:14:55 *s Feb 09 07:16:02 i wish they had just copied swift whole hog Feb 09 07:16:22 Seems like Kotlin is a bit older than Swift so that seems unlikely Feb 09 07:16:25 minor differences like "fun" vs "func" are annoying Feb 09 07:16:46 I'm not worried about discrepancies that the compiler will catch Feb 09 07:17:26 Something else I hate: Java's collections remove(object) vs. remove(int) Feb 09 07:19:31 https://gyazo.com/555af550906c84d740652618ba2c8d83 could someone guide ? Feb 09 07:19:44 https://gyazo.com/b327253789d3edc76f057560bf5221a4 sorry ^ <-- this one Feb 09 07:23:08 Start a new Android Studio project? Feb 09 07:26:02 Im implementing an infinite scroll for my recyclerview, so when i get to the end I do another api call. I know that im only getting 20 items from the api, but when i add them into my list and use notifyDataSetChanged, the new size is reporting that 40 were added Feb 09 07:26:07 any idea why that may be? Feb 09 07:27:12 40 were added or 40 in overall Feb 09 07:27:12 smorgasbord: try later Feb 09 07:27:27 orbyt_ are you implementing getItemId in your adapter and have you set hasStableIds? Feb 09 07:27:38 or, try offline mirror Feb 09 07:28:26 http://developer.android.com/sdk/index.html#Other Feb 09 07:28:29 here's the bundle Feb 09 07:29:05 Ashiren: says 40 were added, so it jumps from 20 to 60 overall Feb 09 07:29:15 but i know the api only returned 20 Feb 09 07:29:24 Levite: no im doing neither of those Feb 09 07:29:34 Levite: what does that do? Feb 09 07:29:51 I need to send push notifications from a web server to an Android app… do I need to create a boot time service and poll the server are there tutorials on this… I mean if say gmail is not running you still get email notifications right...? Feb 09 07:29:53 it makes sure identical items get replaced Feb 09 07:30:19 orbyt_: so how does adding items code looks like Feb 09 07:30:28 Levite: the items shouldnt be doubling in the first place Feb 09 07:31:03 regan: there is already a service doing that, you can register with it. Look into GCM Push Notifications. Feb 09 07:31:23 * regan googles GCM Push Notifications and wanders off Feb 09 07:31:33 orbyt_ what does your getItemCount look like Feb 09 07:32:02 Ashiren: so in the infinitescroll listener i have an abstract loadMore() method that gets called, and the fragment listens for that and fires another api call for the next page Feb 09 07:32:28 Ashiren: then when the results return, I send them into the adapter through the fragment via an onDataLoaded() method Feb 09 07:32:55 once their in the adapter i use items.addAll(newitems) and then notifyDataSetChanged Feb 09 07:33:06 Levite: its mItems.size() as normal Feb 09 07:33:37 and youre sure onDataLoaded is called once and its 20 items Feb 09 07:33:44 you've checked that the list size is correct? Feb 09 07:35:22 Ashiren: yes its called once per api call Feb 09 07:35:43 Levite: after the new api call, its doubles to size to 60 Feb 09 07:35:49 or just patebin all the stuff Feb 09 07:35:52 when it should be 40 Feb 09 07:36:17 and newitems is really new or cleared before you add items to it Feb 09 07:36:57 doesn't sound like an issue with recyclerview Feb 09 07:37:04 yah just pastebin it Feb 09 07:39:05 Alright let me try and narrow down the issue for a few mins, thanks guys Feb 09 07:47:17 @ Ashiren & Levite, figured it out. Had a method where I was basically extracting the returned objects into other objects, and had a List as a sort of buffer, so the items were just being added. list.clear() did the trick lol. Thanks guys Feb 09 08:05:31 Hey, I'm trying to include 2 jar files into my project, both jar contains only classes.dex files. how can I import it? Feb 09 08:06:05 when I just compile them I receive: com.android.build.api.transform.TransformException: com.android.builder.packaging.DuplicateFileException: Duplicate files copied in APK classes.dex Feb 09 08:24:42 how I can set tor for http proxy in android studio?(is it possible that http proxy use form tor?) Feb 09 08:26:36 ??? Feb 09 08:29:43 from android studio / Feb 09 08:32:01 ?????? Feb 09 09:12:57 Mornin happy android people Feb 09 09:14:08 what about me Feb 09 09:17:03 Hello, I'm using OpenGL and I would like draw the map of the 'game'. Should I use vertices by specify the rectangle which takes all the screen or it's already done by default ? Feb 09 09:25:34 ##OpenGL Feb 09 09:26:49 barq: Thanks. Feb 09 09:34:42 can someone please show me an example of where they used Grid-View or Grid Layout Feb 09 09:41:30 Can Wifi-Direct be turned on Programatically ??? Feb 09 09:45:00 Can Wifi-Direct be turned on Programatically ??? Feb 09 09:46:40 Can Wifi-Direct be turned on Programatically ??? Feb 09 09:47:59 #g25 Feb 09 09:48:24 Can Wifi-Direct be turned on Programatically ??? Feb 09 09:49:37 android-developers.blogspot.com/2011/11/new-layout-widgets-space-and-gridlayout.html Feb 09 09:52:18 terminator25: dont spam. also http://bfy.tw/4ADV Feb 09 09:52:23 barq: Can you tell me how to do it ? Feb 09 09:53:46 Why are you highlighting me? Feb 09 09:54:09 hello guys, which web dev framework in your opinion comes the closest in terms of performance compared to native ? Feb 09 09:54:40 been hearing about Appgyver as well Feb 09 09:54:52 barq: Simply :D Feb 09 09:54:56 first of all, am i in the right forum to discuss about that ^ ? Feb 09 09:55:41 its for android developing, so yes Feb 09 09:55:55 but we mainly focus on native (java) here Feb 09 09:56:05 tamarind, honestly most of them are pretty good, but you lose some finegrained control Feb 09 09:56:25 and the number of helpful posts on stackoverflow might be lower ;) Feb 09 09:56:32 Troffel: thanks for replying, "loose some finegrained control" - like ? Feb 09 09:56:49 Ashiren: thank you Feb 09 09:58:10 Ashiren: i am not a core programmer, have done one or two in the past and now completely away from programming. From this situation i want to put up an app quick (and ugly) Feb 09 09:58:20 which can be improved later with professionals Feb 09 09:58:21 tamarind, I'm by no means an expert. But I've tried playing Xamarin for instance, fancy custom stuff might be tricky. I had some challenges with styling / animating. But itwas a while ago :) Feb 09 09:58:30 what ways do you guys suggest ? Feb 09 09:58:44 Troffel: thank you Feb 09 09:58:50 * tamarind googles xamarin Feb 09 09:59:04 Xamarin is for C# Feb 09 09:59:22 well if you want quick ugly crossplatform, then something like that could be useful. But if you just need android, Java isn't that slow d: Feb 09 09:59:29 Practically, if you wish to make good Android apps, you have no choice but to use Java or Kotlin or Scala. Feb 09 10:00:23 tamarind, and for Xamarin specifically, support was lousy d: Feb 09 10:00:37 / help from support forum Feb 09 10:01:32 hmm Feb 09 10:01:43 Any good way of figuring out how much heap you're still allowed to allocate? Feb 09 10:02:07 With or without crashing the app :P ? Feb 09 10:05:32 cart_man: gridLayout I believe is a good fit for login screen Feb 09 10:05:45 justjanne: practically if i wish to make good cross platform apps ? Feb 09 10:05:55 Mavrik: try it and watch the memory monitor? Feb 09 10:05:56 Troffel: oh Feb 09 10:06:03 vigilancer: I actually need to fit 9 or more ImageBUttons into 9 slots Feb 09 10:06:09 tamarind: there is no simple way to make cross platform apps. Feb 09 10:06:12 justjanne, uh. Feb 09 10:06:13 cart_man: gridView - anywere you do not want to mess with recycleview Feb 09 10:06:26 The best bet might be react-native, tamarind Feb 09 10:06:27 justjanne, how does that help me in writing an algorithm that needs to know how much it can allocate? :P Feb 09 10:06:32 "Hi user, please connect your phone to DDMS." Feb 09 10:06:34 ;) Feb 09 10:06:40 Mavrik: well, Android won't tell you. Feb 09 10:06:41 justjanne: thanks will look for it now Feb 09 10:08:08 I have used reflections to achieve to turn on Wifi-Direct programatically as in http://stackoverflow.com/questions/8571566/can-i-turn-on-wifi-direct-from-code-on-android-api-14-ics but ended up in Exception like NoSuchMethodFound "enablep2p" Feb 09 10:09:05 terminator25: 'cause it's missing maybe Feb 09 10:09:46 vigilancer: Then how to achieve it by programatically Feb 09 10:10:36 that's different one :) can't say Feb 09 10:11:01 vigilancer: Why ???? Feb 09 10:11:12 why what Feb 09 10:11:24 there is some book like bible for android dev? Feb 09 10:16:54 vigilancer: Why can't u say ? Feb 09 10:35:14 luvenfu: d.android.com Feb 09 10:35:20 terminator25: because don't know Feb 09 10:35:35 terminator25: Show your code. Feb 09 10:36:30 hi! Feb 09 10:36:56 how long does it generally take ? https://gyazo.com/01021b016f7e5e2b18fb391fff32dbf1 Feb 09 10:37:00 barq: i found a good book Feb 09 10:37:10 i have been waiting for 5minutes. Feb 09 10:39:14 Wich book did you find? Feb 09 10:39:21 barq: head first Feb 09 10:39:39 It's 2011 Feb 09 10:39:45 A bit deprecated most likely Feb 09 10:39:59 Ah there's a 2015 update Feb 09 10:40:10 oh Feb 09 10:40:37 yeah, i'm reading 2015 update Feb 09 10:42:36 smorgasbord: hey mate, this isn't a restaurant, just ask Feb 09 10:43:00 ..have been waiting for 10 minutes. how long does it generally take ? i already asked luvenfu Feb 09 10:43:27 indexing indexing indexing..... luvenfu Feb 09 10:43:59 smorgasbord: your question is not clear Feb 09 10:44:21 smorgasbord: how may I assist you in writing a clear question today? Feb 09 10:45:16 luvenfu justjanne i want the indexing to get finished. please see the screenshot Feb 09 10:45:25 how long does it take ? Feb 09 10:45:38 depends on your system and project. Feb 09 10:45:59 Insufficient data for a meaningful answer. Feb 09 10:46:42 smorgasbord: click in the index bar Feb 09 10:49:28 Hey, maybe anyone has solved this issue before, so I'm going to ask: js there a simple way to find out if a fling is going to end outside of the set of messages, and automatically add content for that? Feb 09 10:49:36 smorgasbord: what appear now? you will see the background tasks are pendent. Feb 09 10:53:37 as i see here, this index problem occurs when you create a new project, in my machine with 4gb of memory and celeron it lates 5 minutes. Feb 09 10:55:40 On my machine it's almost 6 seconds. Feb 09 10:56:04 But I only have a 2012 i5 and only 10GB RAM in my Dev machine. Feb 09 10:57:11 a new project should take more than a few seconds on any machine.. Feb 09 10:57:34 danijoo_: you mean good machines Feb 09 10:57:41 Guys Feb 09 10:57:53 Is there any Android studio for ChromeOS? Feb 09 10:58:18 also do you recommend me getting a ChromeOS? Feb 09 10:58:36 barq: Code snip available at Gowtham333/snip.java Feb 09 10:58:58 luvenfu, and average machines ;) Feb 09 10:59:28 OverCoder, https://www.quora.com/Can-I-install-run-Android-Studio-on-Chromebook Feb 09 10:59:40 seems to be possible Feb 09 10:59:57 but I doubt the experience is as good as deving on other OSs Feb 09 11:00:54 danijoo_: hmmm, yeah, the index problem just happens in first new project after open android studio. Feb 09 11:01:40 luvenfu, yep. after a project is imported it only has to be indexed once. the data is then stored somewhere Feb 09 11:01:50 cache Feb 09 11:03:37 terminator25: ridiculous that you are pinging me on two channels Feb 09 11:05:48 danijoo_: let me try and time it ;) Feb 09 11:06:08 justjanne, luvenfu i think an ssd helps a lot with that Feb 09 11:06:38 danijoo_: Feb 09 11:06:40 lol Feb 09 11:06:40 ah, yeah, I have an SSD, but automatically store my android projects in a ramdisk Feb 09 11:07:03 like, on boot, load from SSD to ramdisk, every 5min or on shutdown write back to SSD Feb 09 11:07:07 as SSD was too slow for me Feb 09 11:07:23 that might explain the speed differences, lol Feb 09 11:07:28 ok, danijoo_, tell me how i can boost android emulator, it just load the screen but the phone appears black screen Feb 09 11:07:31 yeah maybe .. Feb 09 11:07:43 luvenfu: just wait. It takes about 30sec. Feb 09 11:07:57 justjanne: i mean in my machine :) Feb 09 11:07:59 or, if you use the old one, without SSD or ramdisk, a few min Feb 09 11:07:59 luvenfu, check if your CPU supports virtualization and if its enabled in BIOS/EFI Feb 09 11:08:04 and that, too Feb 09 11:08:10 and if you enabled HAXM or KVM Feb 09 11:08:11 and install HAXM if supported. and use x86 images Feb 09 11:08:22 project open now Feb 09 11:08:33 but wait.. you asid this is a 4gb machine, luvenfu ? Feb 09 11:08:44 danijoo_: ye Feb 09 11:08:48 project loaded, synced, built and indexed now Feb 09 11:09:09 the project build normally, only emulation is appearing black Feb 09 11:09:18 justjanne, note to self: create a ram disk.. Feb 09 11:09:33 danijoo_: this was without ram disk. Feb 09 11:09:35 luvenfu, 4gb might be too low for AS + emulator. Feb 09 11:09:42 lol Feb 09 11:09:43 with ramdisk is faster than these 40sec Feb 09 11:10:04 justjanne, but a fresh project, wasnt it? Feb 09 11:10:07 nope, Feb 09 11:10:21 a project with 6 subprojects, 3 annotation processors, and 30k LOC ;P Feb 09 11:10:23 danijoo_: how much memory do you have? Feb 09 11:10:27 http://i.imgur.com/txHv0OU.png Feb 09 11:10:34 https://github.com/justjanne/QuasselDroid-ng Feb 09 11:10:43 luvenfu, 16 Feb 09 11:10:47 :o Feb 09 11:10:58 I need to upgrade soon, looking at 32GB Feb 09 11:11:01 currently only have 10 Feb 09 11:11:01 justjanne, not bad. Feb 09 11:11:22 danijoo_: the magic of: Linux, with no services running in background except IRC and a webbrowser. Feb 09 11:11:26 rich people, gimme a memory please Feb 09 11:11:38 memory is cheap Feb 09 11:11:40 luvenfu: around 2013 it was down to 40EUR for 8GB Feb 09 11:11:41 hey trump Feb 09 11:11:43 i tend to have a ton of stuff open :/ Feb 09 11:12:02 ok Feb 09 11:12:14 like AS, chrome with 20 tabs, 2 emulators and irc, skype... Feb 09 11:13:39 celeron is a good processor? Feb 09 11:14:11 sorry for offtopic Feb 09 11:14:13 " Celeron is a brand name given by Intel Corp. to a number of different IA-32 and x86-64 computer microprocessor models targeted at budget personal computers." Feb 09 11:14:39 so no :p Feb 09 11:14:40 danijoo_, hmm, gotcha Feb 09 11:15:48 > Chrome with 20 tabs Feb 09 11:15:51 and 16GB is enough? Feb 09 11:15:52 lol Feb 09 11:16:02 justjanne, barely :/ Feb 09 11:16:30 I use firefox with lazy-loading tabs by default Feb 09 11:16:44 I can open a million tabs, but they only load as soon as I navigate to them first Feb 09 11:17:07 and if I can’t find a tab, the omnibar will suggest you to switch to a tab if you enter part of the name or URL Feb 09 11:17:20 which makes it a lot more convenient for me Feb 09 11:17:29 people, just by a mac and be happy Feb 09 11:17:38 i was on a mac for years Feb 09 11:18:05 if this would be a sole working computer, i'd have a mac again Feb 09 11:18:07 a mac can’t help with hardware issues like "not enough ram" Feb 09 11:18:27 but its also an entertainment machine so mac isnt an option for me Feb 09 11:18:29 especially when it ends up being "you can't put more ram in" Feb 09 11:20:09 yeah Feb 09 11:20:14 the old power macs were okay Feb 09 11:20:18 the current ones... :/ Feb 09 11:20:32 I switched from Linux to mac back in... hmm... 2001 I think. I stopped somewhere around last year after I reliased that OSX is the only operating system ever ro have become quantifiably _worse_ for something like 5 releases in a row. Feb 09 11:21:03 famous developers use mac machines and i don't know why Feb 09 11:21:05 I’m currently on arch linux with KDE Plasma and on Kubuntu (Desktop + Laptop) and on Fedora with KDE Plasma (Nexus 7) Feb 09 11:21:25 luvenfu: well, they are nice machines. I’ll probably end up buying one, too. Feb 09 11:21:33 but still they aren’t perfect. Feb 09 11:21:34 even linux uses mac Feb 09 11:21:53 Linus uses a Chromebook Pixel, or who do you mean? Feb 09 11:21:54 luvenfu: The hardware is good. Feb 09 11:22:02 right Feb 09 11:22:23 The operating system has becoming worse and worse, but it's been doing so slowly so I think a lot of developers still using it is usffering from the builing frog effect. Feb 09 11:22:29 for most people/devs its because with mac you have an OS that is widely supported and doesnt require that much config and work as linux. and you have a real bash shell and not that crappy windows powershell/msys/cygwin Feb 09 11:22:36 I mean boiling frog Feb 09 11:22:38 yup. Feb 09 11:22:45 mac is far better than windows for devs still, Feb 09 11:22:49 i have a dream that android studio one day will run in the lands of raspberry pi Feb 09 11:22:53 and it’s a simple Just Works™ system Feb 09 11:23:05 the hardware is middling, though well executed in its sometimes good, sometimes mediocre design Feb 09 11:23:15 justjanne: Mac App Store is single worst App Store ever, though Feb 09 11:23:22 having used several of them Feb 09 11:23:29 p_l, have you seen the windows app store? :P Feb 09 11:23:33 danijoo: yes Feb 09 11:23:38 I rate it higher than MAS Feb 09 11:23:52 at least on Windows 10 Feb 09 11:24:00 I rate them both as superfluous Feb 09 11:24:09 I dont need app stores on desktops.. Feb 09 11:24:26 danijoo: that's separate thing - I just wanted to install Xcode... Feb 09 11:25:16 developer.apple.com/downloads has xcode DMG Feb 09 11:25:29 heh - it's not something I would know, not being a mac user Feb 09 11:25:40 so I had the first-hand experience of going through MAS Feb 09 11:26:05 Me neither, found out after having to deal with the MAS to download xcode Feb 09 11:26:09 didn’t like one company have 90% of windows apps? Feb 09 11:27:13 as someone still studying, i can say my university has arround 90% windows XP apps :D Feb 09 11:27:13 no idea. But even without installing anything, MAS was *visibly* slower than Windows Feb 09 11:27:32 and 10% windows 95 Feb 09 11:28:07 the best pc to run windows is a mac Feb 09 11:28:20 no, i meant, Feb 09 11:28:29 well, first Macbook Pros were ideal Vista machines if you had internal-only builds Feb 09 11:28:31 90% of apps in the windows store are from one company Feb 09 11:28:55 they developed a toolkit to drag-and-drop build apps, Feb 09 11:28:58 then build templates, Feb 09 11:29:03 justjanne, i never did a close look into it.. Feb 09 11:29:07 and released of each app millions of versions Feb 09 11:29:15 if i need a program, i google it and download it -_- Feb 09 11:29:35 VIDEO PLAYER: mp4 Feb 09 11:29:38 VIDEO PLAYER: wmv Feb 09 11:29:43 lol Feb 09 11:29:43 VIDEO PLAYER: mpeg Feb 09 11:29:47 VIDEO PLAYER: webm Feb 09 11:29:53 one for every different codec combination Feb 09 11:29:56 video, audio, etc Feb 09 11:30:03 justjanne, 1$ each? :P Feb 09 11:30:04 document readers, one for every file type Feb 09 11:30:05 yes Feb 09 11:30:09 wow Feb 09 11:30:09 they have like 60'000 apps Feb 09 11:30:47 since windows 10 it got a lot better Feb 09 11:30:57 people spent lots of money in iphone and apple products and tim cook shot a blurred image with his hardware, android wins! Feb 09 11:33:47 even on android so many shit apps are existing... Feb 09 11:50:08 When catching an OutOfMemoryError my Activity freezes. Is there any way to finish the Activity in this case even though the process is already out of memory? Feb 09 11:50:42 barq, try a gc :/ Feb 09 11:51:02 barq, catch(OutOfMemoryError e) {System.gc() } Feb 09 11:51:16 But remember not to do any new, or create any new objects, or run any functions that do so Feb 09 11:51:21 i remember facebook using this somewhere Feb 09 11:51:44 maybe it was fresco Feb 09 11:54:22 Does dumpsys do a heap dump as well? Feb 09 11:55:08 Android Studio has a heap dump button with graphical view, btw Feb 09 11:55:22 just go into the memory graph and click the heap dump button next to the garbage collect button Feb 09 11:56:14 Yes, but I can't reproduce the error, only happens in production. Feb 09 11:56:39 So maybe I could catch the OOM and trigger a gc for future analysis. Feb 09 11:56:55 barq, try setting a lower heap in the emulator to reproduce it Feb 09 11:57:01 something like 32 or 64 mb Feb 09 12:05:06 Um, this might not be possible but: Feb 09 12:05:52 Is there any way I can have an ActionBar button, that when hold, show a sheet that contains some options, user drags his finger without lifting it to the item he wants to chose and the lifts, the item gets selected Feb 09 12:05:56 Is that possible? Feb 09 12:06:03 Something exactly like the spinner in Ubuntu Feb 09 12:07:28 why hold? :o Feb 09 12:08:21 Because this will be used as a switch between fragments, and this must be as fast and fluent as possible Feb 09 12:08:36 I thought of using the navigationbar for that but it doesn't seem right, using that could be better somehow Feb 09 12:09:09 you should use mechanisms android users expect Feb 09 12:09:20 Right, like what? Feb 09 12:09:22 ie tabs, navbar, spinner.. something light that Feb 09 12:09:27 well I'm pretty sure you can do it if you do it manually from scratch, but what danijoo said... Feb 09 12:09:37 It's an IRC client, and the switch is server switched, the tabs are used for switching channels Feb 09 12:09:56 id go with a navbar for that Feb 09 12:10:01 switcher* Feb 09 12:10:11 hmm Feb 09 12:10:13 or a second tablayout Feb 09 12:10:23 or a spinner : Feb 09 12:10:26 :´D Feb 09 12:10:29 -.- Feb 09 12:10:32 * OverCoder thinks and decides Feb 09 12:10:34 Thank you :> Feb 09 12:10:51 i´d do spinner i think Feb 09 12:10:54 OverCoder: that's like windows 3.1 menu's where you have to keep holding Feb 09 12:11:13 shmoooz, lol idk about Windows 3.1 Feb 09 12:11:28 danijoo, hm, ActionBar spinner? Feb 09 12:11:30 Seems neat Feb 09 12:12:13 danijoo: I can't run the app with the emulator. Any way to set this when running it on the device? Feb 09 12:12:32 barq, Feb 09 12:12:33 no Feb 09 12:12:44 the heap size is something thats built in the OS Feb 09 12:13:22 Can I prevent orientation change at fragment level ? Feb 09 12:13:33 Is that possible ? Feb 09 12:13:34 suhas_sm, no. only on activity level Feb 09 12:13:42 hmm. ok thanks :) Feb 09 12:15:00 is it possible to use the same gradle file/project to compile both an android lib and a desktop/jvm lib ? Feb 09 12:16:06 emilsp, a jvm lib can be used in an android app, so you could just compile it as jvm all the time and use it in all projects Feb 09 12:16:42 danijoo: Can I not change dalvik.vm.heapsize? Feb 09 12:16:52 but if I start with an android lib project, then I can't just build the same thing for jvm, right ? Feb 09 12:17:48 barq, you mean in prop file? Feb 09 12:17:52 yes Feb 09 12:18:12 danijoo, um, I want to ask you something Feb 09 12:18:14 no idea if this is possible. you should ask in root Feb 09 12:18:50 danijoo, When one switches between channels/server, probably the shown text is going to be replaced, should I use fragments for that purpose? note that I want to have swipable tabs Feb 09 12:19:22 (Because I haven't used fragments ever because I always found it hard to use D:) Feb 09 12:19:50 OverCoder, so you want to use a viewpager for the channel fragments? Feb 09 12:20:12 i guess you could update the adapter then. Feb 09 12:20:16 or replace it Feb 09 12:20:18 I don't even know what's a ViewPager, I'll just google that and the usage of it Feb 09 12:20:40 So you think I might not need fragments? Feb 09 12:20:49 ViewPager is for fragments Feb 09 12:21:00 hm Feb 09 12:21:36 its the view element that enables the swipe you describedd Feb 09 12:21:55 Gotcha Feb 09 12:22:15 setprop would work Feb 09 12:22:32 barq, i hope this is not your private phone :p Feb 09 12:23:37 Irreverisble damage incoming Feb 09 12:31:17 nah, not irreversible Feb 09 12:31:23 you can always JTAG it and reflash it Feb 09 12:35:37 I want a name a function which hide a layout .. lets says InfoLayout. I am confused what to name the function .. showsInfoLayout(boolean flag), showInfoLayout(boolean flag), disableInfoLayout(boolean flag) ? Feb 09 12:36:05 please suggest, whats the normal practice ? Feb 09 12:36:29 showInfoLayout() Feb 09 12:36:33 and hideInfoLayout() Feb 09 12:36:51 or setHideInfoLayoutVisible(boolean visible) Feb 09 12:36:55 setInfoLayoutShown(boolean) :p Feb 09 12:37:06 aah this seems right Feb 09 12:37:18 setter #faceplam Feb 09 12:37:18 thanks Feb 09 12:53:29 i'm extending Fragment and it says it cannot cast it? SlidingTabsFragment mFragment = (SlidingTabsFragment) getFragmentManager().findFragmentByTag("FirstFragment"); ? Feb 09 12:54:26 Twirl, there are different versions of fragments. support and native Feb 09 12:56:31 which one should i use? Feb 09 12:57:02 support Feb 09 12:57:08 Which Android versions are you supporting? Just one or more than one? Feb 09 12:57:32 always use support Feb 09 12:57:43 v4 support? Feb 09 12:57:44 Unless you are developing for one specific api version Feb 09 12:57:52 alright Feb 09 12:58:01 barq, then also use support Feb 09 12:58:07 Why? Feb 09 12:58:22 less bugs + viewpager Feb 09 12:58:50 You don't have to use support everywhere Feb 09 12:59:21 sup danijoo Feb 09 12:59:23 I don't need AppCompatActivity Feb 09 12:59:56 hey thepoosh ! Feb 09 13:00:06 I heard you did it into android weekly recently? Feb 09 13:00:40 with the whole watch update? Feb 09 13:01:21 it's weird, still getting the same message Feb 09 13:01:36 it went away when i changed the import to Fragment instead of support Feb 09 13:01:42 Twirl, try getSupportFragmentManager() Feb 09 13:01:54 that worked Feb 09 13:01:59 ty Feb 09 13:03:25 barq, support fragments are less error phrone and tools like viewpager arent available without support library. Thats the reason why nearly everyone uses them even if they support 16+ Feb 09 13:03:40 What if you only support api 18 Feb 09 13:03:48 Still dev with 23 and use support? Feb 09 13:04:02 23? what 23? Feb 09 13:04:06 api Feb 09 13:04:15 what has that to do with support? Feb 09 13:04:42 support fragments are less error prone than api 18 fragments? Feb 09 13:04:47 yes Feb 09 13:05:26 every bug that was discovered in fragments after api 18 released and got a fix is fixed in support Feb 09 13:05:32 but is not fixed in stock 18 Feb 09 13:12:38 danijoo: do you deal with build.gradle? Feb 09 13:13:23 thepoosh, only if i have to Feb 09 13:13:38 it seems like something got Fed up for us Feb 09 13:13:47 after creating a wear app Feb 09 13:13:51 and merging it Feb 09 13:14:15 im not really familiar with wear :/ Feb 09 13:25:41 sometimes I want to punch our designers Feb 09 13:26:04 vertical list of horizontal lists in a viewpager seems like a very usable idea Feb 09 13:26:21 so nexus 6p is keeping my app data accross reinstalations, this means uninstall and install again keeps the app data Feb 09 13:26:24 supwiththat? Feb 09 13:26:38 android 5 didnt do that Feb 09 13:26:41 afaik Feb 09 13:26:42 jvrodrigues, it's tied to the google account Feb 09 13:26:57 account syncing Feb 09 13:26:58 Zharf: is that some new functionality? Feb 09 13:27:02 not really Feb 09 13:27:11 I have never seen this happen Feb 09 13:27:14 it's been expanded with some features every now and then Feb 09 13:27:21 jvrodrigues, thats an android 6 features Feb 09 13:27:28 aahh Feb 09 13:27:32 app data now gets automatically backuped to the cloud Feb 09 13:27:36 can you point me to the documentation please? Feb 09 13:28:11 I just made an blank ignorant look at my boss while he was testing the app and it kept data between installations Feb 09 13:28:52 no sorry Feb 09 13:28:59 but iirc it can be disabled in settings Feb 09 13:29:30 How can i update the pages in my PagerAdapter from outside of it? I have it inside my Fragment Feb 09 13:29:49 jvrodrigues: I suspect http://developer.android.com/training/backup/autosyncapi.html Feb 09 13:30:36 good read Leeds ,thanks Feb 09 13:30:37 Anyone knows how to update the pages in the PagerAdapter from the outside? Feb 09 13:31:31 you're welcome :) Feb 09 13:31:34 @overriding public Object instantiateItem(ViewGroup container, int position) {... is the place in the PagerAdapter to update the page, but how to do it from the outside? Feb 09 13:32:47 I'm updating the fields in the view from the Fragment but outside of the PagerAdapter class i'm extending and it doesn't update the view, idk if its because of that tho Feb 09 13:33:12 Twirl, you're doing what now? Feb 09 13:33:49 Zharf: trying to update a page from the PagerAdapter class I'm extending Feb 09 13:34:34 Looks like InstantiateItem in the PagerAdapter class (that is inside the Fragment class) is in charge of setting the view/updating it Feb 09 13:36:20 but idk how to do it form the outside because i have to wait until asynctask is done to update it Feb 09 13:37:59 Maybe i should fetch the data and then initialize the fragment Feb 09 13:38:17 but it's what i've been trying to do Feb 09 13:39:18 on processFinish, SlidingTabsFragment mFragment = (SlidingTabsFragment) getSupportFragmentManager().findFragmentByTag("FirstFragment"); mFragment.myUpdateMethod(data); //it won't update the view Feb 09 13:39:59 probably because of the PagerAdapter class inside the Fragment is not being notified or something Feb 09 13:40:50 get the fragment by id Feb 09 13:41:09 from fragment manager Feb 09 13:41:58 viewpager.setCurrentItem() seems to call onPageSelected on not-yet initialized fragment :s Feb 09 13:42:03 is this intended behavior Feb 09 13:42:52 http://pastebin.com/raw/01Lzgttw Feb 09 13:43:13 danijoo: isnt the same to get it by tag? Feb 09 13:43:24 also, i think the fragment is ok, the problem is with the PagerAdapter Feb 09 13:43:49 danijoo: that's the whole fragment, i'm calling the method at teh end updateFragment when AsyncTask is done Feb 09 13:44:29 Twirl, you need to get it by the id the viewpager assigns to it Feb 09 13:44:40 viewpager does not assign tags Feb 09 13:45:47 so, i need to get the ViewPager ID from outside the Fragment or Inside of it? Feb 09 13:46:23 the question has been askt million times on stack overflow. google it :) Feb 09 13:51:00 getting the fragment by the viewpager id is a terrible idea Feb 09 13:51:10 it depends on an implementation specific detail Feb 09 13:51:11 its not Feb 09 13:51:24 building a list of fragments in instantiatePage is better Feb 09 13:51:31 no its not ^^ Feb 09 13:52:00 lists causes fragments to not be recycled properly Feb 09 13:52:07 http://stackoverflow.com/a/15261142/857853 Feb 09 13:52:21 that's why you do destroyItem as well, as here Feb 09 13:52:38 why should this be better then the id? Feb 09 13:53:00 because it's not implementation defined? they could change the way viewpager generates ids at any point Feb 09 13:53:10 viewpager is support lib Feb 09 13:53:14 yes Feb 09 13:53:18 but it's still implementation detail Feb 09 13:53:31 and depending on implementation details is not something you should do in proper software design Feb 09 13:53:36 you know which supp lib version you use so you know the implementation Feb 09 13:54:21 its bad software design that there is no method for that in the base adapter in first place imo Feb 09 13:54:22 the fact that you know it is not relevant, it's hacky Feb 09 13:54:39 but then, ViewPager is a terrible component Feb 09 13:55:11 FragmentPageAdapter should have something like getItemAtPosition(int) imo Feb 09 13:55:34 that simple uses the itnernally assinged id Feb 09 13:56:07 it has getItem(position) (?) Feb 09 13:56:18 Ashiren, that doesn't do what you think it does Feb 09 13:56:20 Ashiren, that does create a new fragment each time and doesnt return the old Feb 09 13:56:35 it's poorly designed Feb 09 13:58:06 nyoro~n Feb 09 14:09:18 Twirl, what is R.id.recycler_view_1? Feb 09 14:09:42 Twirl, to me it seems like you're crossing responsibility boundaries Feb 09 14:09:47 Zharf: the recyclerview that i'm trying to render Feb 09 14:10:05 Zharf: i'm trying to implement the solution you gave from SO Feb 09 14:10:31 if it's in a fragment, you shouldn't access it through activity's findViewByid Feb 09 14:10:45 let each fragment handle their own view and tell them to update their internal stuff Feb 09 14:10:51 don't access them from outside directly Feb 09 14:11:16 alright, that has to be done when AsyncTask is done Feb 09 14:12:06 How can I include https://android.googlesource.com/platform/frameworks/opt/colorpicker in my android studio project? Feb 09 14:12:47 Twirl, call a method on the activity with the data and let that pass that data to the fragment that wants it, or use an eventbus Feb 09 14:13:13 yes that's what i've been trying to do Feb 09 14:13:15 Twirl, http://developer.android.com/training/basics/fragments/communicating.html Feb 09 14:13:55 Zharf: are you sure about that? shoulnd't I try with the solution you gave from SO? Feb 09 14:14:13 Twirl, it's part of the solution, but the problem isn't what you think it is Feb 09 14:14:59 I'm not sure about what my problem is tbh, i know that there are no errors and that the elements are being updated but the changes don't show in the view/fragment/pager/adapter w/e Feb 09 14:15:09 how to do gradle > offline ? thanks Feb 09 14:15:55 Twirl, you're modifying fragment's content from outside the fragment's knowledge, you're very likely to end up in conflicts, follow the fragment communication guide and replace the articlefrag instance with the fragment from the pageradapter that the stackoverflow solution gives you access to Feb 09 14:16:33 the pageradapter doesn't need to be notified of changes unless you change the fragments it contains to something completely different Feb 09 14:16:44 which is my case Feb 09 14:16:58 i guess? Feb 09 14:17:11 smorgasbord go to settings->Build,Execution,Deployment->Build Tools->Gradle and select Offline work. Feb 09 14:17:21 k checking Feb 09 14:17:39 Zharf: it's showing the inflated view with the empty values, but it's not showing the recyclerview with the data from the asynctask Feb 09 14:17:56 Zharf: i'm going to try combining the SO answer with the doc you gave me Feb 09 14:18:17 michanga file edit view......... help Feb 09 14:18:23 no settings in this list ^ Feb 09 14:18:28 yeah ok, you're not actually using fragments in the viewpager -.- Feb 09 14:18:59 well, get the view from the pageradapter and use findviewbyid on that, not the activity Feb 09 14:19:26 and you still don't need mViewPager.getAdapter().notifyDataSetChanged(); Feb 09 14:19:31 smorgasbord under File Feb 09 14:19:50 your pageradapter is pretty much static, only thing that would do is purge all your changes Feb 09 14:19:53 michanga checking. android studio hangs i think Feb 09 14:19:58 since it'd create the views again Feb 09 14:19:58 on my machine it's fifth option Feb 09 14:20:52 Zharf: i'm not sure how to do that when asynctask is done in MainActivity Feb 09 14:20:55 thanks michanga it was below help though. THANKS again. Feb 09 14:21:08 Twirl, you already have updateFragment, right? Feb 09 14:21:30 smorgasbord no problem! Feb 09 14:21:33 that is in the Fragment but outside the PagerAdapter Feb 09 14:21:41 can i P Feb 09 14:21:51 M you ? created a mess in here already Feb 09 14:22:15 Zharf: also, idk if that is not part of the problem, idk if it's doing what it's supposed to do Feb 09 14:22:17 Twirl, yes, so build a list of the Views you have in the PagerAdapter like they build a list of the Fragments in the SO answer Feb 09 14:22:41 smorgasbord sure! Feb 09 14:22:48 Twirl, I assume R.id.recycler_view_1 is in R.layout.prod_row, is this correct? Feb 09 14:22:57 nope Feb 09 14:23:07 sigh Feb 09 14:23:09 prod_row is the row of items to be inflated Feb 09 14:23:12 michanga hi Feb 09 14:23:12 your project is really confusing :p Feb 09 14:23:15 the pattern or w/e Feb 09 14:23:32 tell me about it Feb 09 14:23:33 Twirl, sorry but none of that makes any sense Feb 09 14:24:16 the recyclerview is inside the in the activity_main Feb 09 14:24:39 i figured i had to put it there because it was working without it Feb 09 14:24:54 so it should work Feb 09 14:24:58 Twirl, can you be a little more high level about what you want to achieve Feb 09 14:25:17 a recycler view in a sliding tab Feb 09 14:25:23 with a "list" of items Feb 09 14:25:28 pretty simple Feb 09 14:25:31 so multiple lists in tabs? Feb 09 14:25:37 yea Feb 09 14:25:47 but i already have my project like this and everything works Feb 09 14:25:51 except for that Feb 09 14:26:35 I don't see how it could work if your list isn't actually in the tabs but the activity Feb 09 14:26:41 its also showing the text form prod_row as default, it instantiates the fragment wit the pager or w/e but it doesnt update it when asynctask is done Feb 09 14:27:23 it's inside the FrameLayout Feb 09 14:27:35 generally what you would do is have an activity with tablayout and a viewpager, the viewpager adapter would be a FragmentPagerAdapter which would contain fragments which contain a list each Feb 09 14:28:27 the list could be a recyclerview? Feb 09 14:28:31 yes Feb 09 14:28:55 recyclerview is essentially a better listview :) Feb 09 14:29:03 well, i got this project from google examples i'm adopting the ideas from it Feb 09 14:29:37 that was after implementing everything without the sliding tabs Feb 09 14:30:05 and it works but i just dont know how to update when asynctask is done Feb 09 14:31:01 Zharf: can't i just do it this way? Feb 09 14:31:21 with the answer from the SO? Feb 09 14:31:25 I don't know, I would have to see the whole codebase to understand the problem Feb 09 14:31:46 you're not doing it the expected way so I'm a little lost :p Feb 09 14:31:58 haven't actually used a plain PagerAdapter in like 4 years I think Feb 09 14:32:01 well i got it from the google examples Feb 09 14:32:31 which examples Feb 09 14:33:02 http://developer.android.com/samples/SlidingTabsBasic/index.html Feb 09 14:33:04 this project Feb 09 14:33:13 i downloaded it and it works and i used the ideas from it Feb 09 14:35:56 and pretty much what i changed is trying to put a recyclerview on the pages/tabs with items from the asynctask when it's done, inflating my prod_row instead but that is also what the recyclerview uses as row, so that could be a problem, idk Feb 09 14:37:35 in the project they update the tabs on the instantiateItem from the PagerAdapter, i tried putting my asynctask there but it won't wait until it's done it just kept going so it wouldnt update the view when it was done either, (idk if that was the problem but i suspect it was) Feb 09 14:37:58 it doesn't make any sense if your recyclerview isn't in the pageradapter Feb 09 14:38:16 since that's what the viewpager slides around Feb 09 14:38:25 alright Feb 09 14:39:00 so, i put my recyclerview adapter in there? Feb 09 14:39:59 I'm using android studio and trying to put three 9 components in 3 lines each contain TextView, TextEdit and Seekbar all in one GridLayout .. which property should put each three in one level without having to add sublayout? Feb 09 14:40:08 no, the views that are inside the pageradapter (as instantiated in instantiateItem) should contain a recyclerview, you can give those recyclerviews each their own adapter which defines what their content is Feb 09 14:40:14 I wonder how old this example is Feb 09 14:41:34 alright let me try it Feb 09 14:44:03 interesting Feb 09 14:44:40 so, i created a new layout with a linear layout and put the recyclerview on it Feb 09 14:45:01 then on instantiateItem from the pageradapter i inflated it Feb 09 14:45:45 but still doesn't show anything Feb 09 14:46:13 put a textview in the linearlayout as well to see if you get something Feb 09 14:46:27 I'll be off for a moment, got to catch a bus Feb 09 14:46:44 yes i get something Feb 09 14:47:34 probably the recyclerview is not being updated after the asynctask is done? Feb 09 14:47:42 I got it thanks Feb 09 14:49:43 Zharf: it's pretty much the same as before, i could see the text in the layout i was inflating in the PagerAdapter instantiateItem Feb 09 14:50:29 Zharf: let me show you my activity main Feb 09 14:52:02 I have a layout which says above layout 2 in relative layout which itself is above layout 3. If I make layout gone, apps is crashing I guess layout 1 is not able to find layout 2. How should I handle this Feb 09 14:52:07 I have a layout which says above layout 2 in relative layout which itself is above layout 3. If I make layout gone, apps is crashing I guess layout 1 is not able to find layout 2. How should I handle this? Feb 09 14:54:00 Zharf: http://pastebin.com/raw/2pA6kAV2 Feb 09 14:55:13 why do you have closed folds there Feb 09 14:55:35 it has irrelevant stuff that it's working or styling Feb 09 14:56:48 the crucial part i think its that i'm assigning the fragment a tag "FirstFragment", then passing it on processFinish from AsyncTask Feb 09 14:57:22 yeah that's fine Feb 09 14:57:36 alright, so I'm having an issue with the PagerView. Can it not be used in a fragment to have other fragments as pages? Feb 09 14:57:40 but i should select the View from the Fragment ? Feb 09 14:57:51 because the Fragment has a PagerAdapter? Feb 09 14:58:05 that could be the problem Feb 09 14:58:24 each tab has a "page" and that's what i need to update? Feb 09 14:58:35 no that's not the problem Feb 09 14:58:52 the updateFragment method is wrong? Feb 09 14:59:24 yes, it should get the relevant view corresponding the correct page from the pageradapter Feb 09 14:59:35 yea that is something i dont know how to do Feb 09 14:59:37 then get the recyclerview from that view Feb 09 15:00:16 in instantiateItem put the view in your own list as well as the container you add it to Feb 09 15:00:21 HACKhalo2, I would really really avoid doing that :) Feb 09 15:00:34 I think it could be done but childfragmentmanager handling will kill you. Feb 09 15:01:06 Mavrik, meh, I do that all the time Feb 09 15:01:31 Doesn't make it any less silly :P Feb 09 15:01:45 I don't see the sillyness Feb 09 15:02:07 just give the adapter a childfragmentmanager as ctor parameter Feb 09 15:02:53 Mavrik: issue is, I can't get the tabs to populate Feb 09 15:03:16 and I really don't want to use more then two or three activities Feb 09 15:04:13 Zharf: that is the first thing i tried to do but how to do that when asynctask is done? Feb 09 15:04:21 that is the problem Feb 09 15:04:37 Twirl, no, you've already done it at that point Feb 09 15:04:43 Zharf, *shrug* I tend to avoid buggy pieces of code that may cause issues. Feb 09 15:04:55 Writing to custom views doesn't hurt any more and they have less issues. Feb 09 15:05:03 Twirl, the adapter should then contqin a list you can access Feb 09 15:05:41 Zharf: so in the instantiateItem, I inflate the view with the recyclerview Feb 09 15:05:57 and then? Feb 09 15:06:12 container.addView(view); // ViewGroup Feb 09 15:06:15 yep, and put that in a list, like they do with fragments in the SO answer Feb 09 15:06:44 a list of View items? Feb 09 15:06:48 yep Feb 09 15:07:02 alright let me try it Feb 09 15:07:23 might need to be a sparsearrqy rhough since it may not csll them in order, or it may skip some Feb 09 15:07:36 like in the SO answer Feb 09 15:07:47 SparseArray registeredViews = new SparseArray(); Feb 09 15:07:50 sorry about the typos, I hate these onscreen keyboarss Feb 09 15:07:58 u on the bus? Feb 09 15:08:03 yeah Feb 09 15:08:06 lol Feb 09 15:08:25 i can't read on a bus i would throw up Feb 09 15:09:18 you should be able to access that list from updateFragmwnt Feb 09 15:09:51 after that use findViewById on the view and update the recyclerview Feb 09 15:10:35 but don't call notifyDataasetChanged on the PagerAdapter Feb 09 15:11:12 Is there anything good on doing TDD with Android? Feb 09 15:11:18 for android, even Feb 09 15:12:44 could somebody help me in getting regional language font to work on my oneplus x? Feb 09 15:13:06 I have copied the ttf file to /system/fonts and renamed it to the name specified in /system/etc/fonts.xml and fallback-fonts.xml... but it doesn't show up on my keyboard Feb 09 15:13:09 Zharf: final RecyclerView recycler_view_1 = (RecyclerView) getActivity().findViewById(R.id.recycler_view_1); // here? Feb 09 15:13:13 gpy91: #android Feb 09 15:13:21 autrilla, okay Feb 09 15:13:47 yeah, do the find on the view, not the activity Feb 09 15:14:13 got to switch to another bus, be back soon Feb 09 15:18:09 back Feb 09 15:19:13 Zharf: alright, i'm not sure how to get the view from there, do i make it public static? Feb 09 15:19:35 oh nvm Feb 09 15:19:46 get it from thr pageradapter Feb 09 15:22:08 Zharf: omg Feb 09 15:22:17 Zharf: it worked, you are a genius Feb 09 15:22:55 next time do it with fragmentpageradapter and you'll be far better off Feb 09 15:23:47 Zharf: thank you, i've been trying to do this for like a whole day Feb 09 15:24:03 there was no way i could figure it out on my own tho Feb 09 15:24:37 it's not very complicated once you hsve an image in your head about the view hierarchy Feb 09 15:25:18 using fragmentpageradapter would allow for easier capsulation for each tab though Feb 09 15:25:36 yea that's the next step, now i need to add more tabs Feb 09 15:26:14 but i guess i can just updateFragment and pass it the id of the second view and that's it? Feb 09 15:26:51 page position I guess Feb 09 15:27:01 yea, nice, gonna try it out Feb 09 15:27:03 thank you Feb 09 15:27:29 note that the page might not have been instantiated yet Feb 09 15:28:11 which is where the encapsulation (or lack of) issues might start to pop up Feb 09 15:29:05 well the example from google uses a getCount() and you just put the amount of pages you want in the return Feb 09 15:29:40 yes, but viewpager by default only instantiates the current view and the views right next to it Feb 09 15:30:45 if you have two views you won't have problems, if you have more, you should build a solution to cache the data and set it when the view is instantiated Feb 09 15:31:05 yea but i still have to wait for asynctask Feb 09 15:31:11 yep Feb 09 15:31:34 alright i'm going to try with the FragmentPagerAdapter Feb 09 15:33:06 you'll still have similar issues, if you're loading data and you want to use that data later, you should cache it somehow Feb 09 15:33:45 but fragments allow for nicer control Feb 09 15:40:05 okay, i guess it wont be that complicated to change it? Feb 09 15:40:25 i will have to read a little about fragments i guess Feb 09 15:40:52 because i have the ViewPager in the view Feb 09 15:41:00 in the layout Feb 09 15:41:08 no that remains the same Feb 09 15:44:07 https://guides.codepath.com/android/ViewPager-with-FragmentPagerAdapter Feb 09 15:44:35 (didn't read but it seems decent from first glance) Feb 09 15:45:12 Twirl: you just have to change your ViewPager adapter Feb 09 15:46:06 (and move some logic) Feb 09 15:46:10 probably Feb 09 15:56:46 so the recommended way to unregister from GCM is to hit up your app server and tell it to stop sending notifications, right? Feb 09 15:56:55 android:text="Hello World!\nHow are you?" Feb 09 15:57:04 please guide. newline Feb 09 15:57:40 does it not work smorgasbord? Feb 09 15:58:12 missingno no. .. should i save it prior to running ? Feb 09 15:58:24 Hey! Question: Is it possible to GIVE applications permissions (I have root etc. etc.) Feb 09 15:58:39 Hey! Question: e.g I want to make an app debuggable or give it a custom permission Feb 09 16:03:07 esvee: you can only give your own applications permissions Feb 09 16:04:03 with root, or debuggable, adb grant Feb 09 16:04:15 of course, you can't grant restricted permissions Feb 09 16:06:53 https://bpaste.net/show/bf3ce97e27fd in this how to make it in two lines. Feb 09 16:06:54 Hello Feb 09 16:06:57 World! Feb 09 16:08:03 smorgasbord: uh. either a new line char or two textviews? Feb 09 16:08:24 oh.. will try and reply. Feb 09 16:19:02 i have a question: How can I change the actionbar titles for my fragments? Feb 09 16:19:09 I saw this on stackoverflow: Feb 09 16:19:16 http://stackoverflow.com/questions/15560904/setting-custom-actionbar-title-from-fragment Feb 09 16:19:23 but what exactly is 'YOUR_CUSTOM_ACTION_BAR_TITLE' supposed to be? Feb 09 16:23:48 NOT an English speaker? Feb 09 16:30:18 Controless, its your title.. Feb 09 16:30:50 lol yeah im dumb, figured it out haha. thanks Feb 09 16:42:14 Hello, do you guys have any workarounds for https://code.google.com/p/android/issues/detail?id=172347 ? I want to keep some shared run configurations within the repository but android studio just deletes them while opening the project... Feb 09 16:44:08 Is NDK support still so bad in AS that the docs refer to Eclipse? http://developer.android.com/ndk/guides/setup.html Feb 09 16:45:12 There's no stable C++ support in AS. Feb 09 16:45:31 S: Feb 09 16:45:48 Any news on when they plan on supporting this? Feb 09 16:48:11 soon (tm) Feb 09 16:50:48 pfn: btw, my new advanced editor for the IRC client: https://dl.kuschku.de/videos/device-2016-02-09-174926.mp4 Feb 09 16:51:31 justjanne, this looks pretty nice Feb 09 16:51:38 how do you switch? swiping up? Feb 09 16:51:50 yup Feb 09 16:53:49 cool, doesn't look very material Feb 09 16:53:51 :p Feb 09 16:54:14 well, it follows exactly the guidelines in color, ripple color, animation type and speed, fade, etc ;P Feb 09 16:56:22 no wonder it doesn't look material ;-) Feb 09 16:58:50 ugh, I want to get rid of rx, but want to do it piecemeal, starting with rxandroid, but I'm too lazy to implement the UI thread scheduler Feb 09 17:01:08 Hi! I'm doing some research on the Email Android app and can't find what I'm looking for. Feb 09 17:01:14 I have a Samsung device and when I setup the email app to use Exchange, my "Mobile Device ID" starts with "SEC" followed by a 12 char Hex or by "S" followed by an 14-char HEX Feb 09 17:01:19 I've been running this phone for a long time (~Jan 2014) Feb 09 17:01:24 My understanding is that when I setup an email account for the first time (something) stored that SECXXXXXXX into the deviceName file and that file has been used since then. Feb 09 17:01:27 not #android-dev Feb 09 17:01:29 Any idea where that DevceName came from? I've been crawling various versions of the code for the last two days without any luck... or you might know someone who could help me on that.... Feb 09 17:01:47 ? Feb 09 17:15:27 Hello. Feb 09 17:17:10 davor051, Hello. Feb 09 17:18:53 Hi, are you in a mood for a short story? Feb 09 17:19:39 davor051 as long as its in java Feb 09 17:20:24 It is about my journey of getting into Java in a few couple of months Feb 09 17:20:33 *android development Feb 09 17:20:39 eh, write a blog about it Feb 09 17:21:09 It has a simple request at the end of somebody with more expirience than mine Feb 09 17:21:44 I am not shure if what I did was enough android-java like code Feb 09 17:22:19 I started to get into android development just few months ago Feb 09 17:25:39 I came with C++/C# background and proffesor ad my university keeps telling me that I write Java like C++ Feb 09 17:26:07 if you have a c# background, java would look like java Feb 09 17:26:11 because c# is basically a better java Feb 09 17:26:17 let me guess, initialize constants in a static block? -.- Feb 09 17:26:33 for C# he told me the same :D Feb 09 17:26:50 then you don't come from a c# background :P Feb 09 17:27:30 his complaints were mainly on naiming of my classes and variables Feb 09 17:27:56 and not doing things modular Feb 09 17:28:11 that doesn't sound like doing it like c++ Feb 09 17:28:11 I worked on modularity mainly trough past few weeks Feb 09 17:28:16 that just sounds like inexperience Feb 09 17:29:27 i've heard 'your c++ looks like c' but never before 'your java looks like c++' haha Feb 09 17:29:34 yeah, right now I am working on getting more expirience on modular programming, and I am not shure if what I did was modular completely Feb 09 17:29:53 and I don't want to go to his place just to hear same thing Feb 09 17:30:06 modular bla bla... Feb 09 17:30:13 considering java was originally modeled to look somewhat like c++ Feb 09 17:30:16 g00s, try debugging Java that looks like C :P Feb 09 17:30:52 that tends to be easy since it's so simple... Feb 09 17:30:56 yeah, its like C++ without Multiple inheritance and operator overloading Feb 09 17:30:58 no abstractions anywhere Feb 09 17:31:05 davor051 you can do worse that see this https://vimeo.com/43612849 Feb 09 17:31:24 read uncle bob SOLID principle (clean code) and see video on clean architecture Feb 09 17:31:29 (as an ideal) Feb 09 17:32:25 davor051 i recommend these 2 books http://www.amazon.com/Clean-Code-Handbook-Software-Craftsmanship/dp/0132350882 Feb 09 17:32:47 and http://www.amazon.com/Growing-Object-Oriented-Software-Guided-Tests/dp/0321503627 Feb 09 17:33:25 davor051 and there is that old saying from peter norvig, it takes 20 years to learn how to program Feb 09 17:33:46 nice, 15 more to go Feb 09 17:33:48 :D Feb 09 17:34:41 so do some research into SOLID and Clean Architecture, that should give you a good start Feb 09 17:35:13 will do Feb 09 17:35:58 davor051 you can use scala and your prof won't say it looks like C++ any more Feb 09 17:36:14 :P Feb 09 17:37:09 lol, these guys on reddit advising a dev to use firebase, when he has a static list of flowers in database Feb 09 17:38:59 shmooooz haha, from reto "NOTE: If your dev device is running Gingerbread or Honeycomb, it might be time to consider investing in an upgrade." Feb 09 17:39:37 pfn wth does this mean "We’ve improved dx to use a quadratic algorithm to merge pre-dex’d files " Feb 09 17:40:05 it's O(n^2) instead of whatever it was before Feb 09 17:40:39 * pfn still doesn't understand why anyone would pre-dex when targeting pre-21 Feb 09 17:40:44 there is absolutely no speed improvement Feb 09 17:40:56 well, maybe with a new O(n^2) algo, it'll be faster Feb 09 17:41:15 although, I understand there's probably a pre-dex motivation from the jack/jill movement Feb 09 17:45:13 huh Feb 09 17:45:19 Now that's the wierdest thing ever Feb 09 17:47:39 ? Feb 09 17:48:33 > Annotation processing is not supported. Feb 09 17:48:41 Okay, Jack is automatically disqualified Feb 09 17:48:48 * pfn shrugs Feb 09 17:48:52 annotation processing sucks :P Feb 09 17:53:34 Hey is there a way I can use TabLayout without needing a ActionBar ? Feb 09 17:57:57 yes? Feb 09 17:58:29 better question is how do you use it that requires an actionbar? -.- Feb 09 17:59:09 Zharf: i've been trying to style the tabs but all i managed was to change the background color Feb 09 17:59:42 tried adding cart_man, tablayout has nothing to do with actionbar Feb 09 18:00:30 Twirl, you should also look into using TabLayout rather than whatever it was that the example you looked at used Feb 09 18:00:47 pfn this is interesting. https://www.reddit.com/r/programming/comments/44um2l/fear_uncertainty_and_doubt_in_scala_land/cztb6zx Feb 09 18:00:48 Zharf: ViewPager Feb 09 18:00:57 so is dotty like a mid-course correction then ? Feb 09 18:01:02 Twirl, no you used SlidingTabLAyout orwhatever Feb 09 18:01:06 and https://guides.codepath.com/android/Google-Play-Style-Tabs-using-TabLayout Feb 09 18:02:15 pfn: Its just every dam tutorial and video about Tab Layout has actionBar in it Feb 09 18:02:16 yea i've been reading that Feb 09 18:02:41 Twirl you can make TabLayout the child of Toolbar and forego the title Feb 09 18:02:48 forgot to add the tabLayout the viewpager Feb 09 18:02:54 g00s: that would be nice Feb 09 18:02:55 that still gives you ability to have overflow Feb 09 18:03:03 g00s, it's just a stupid fud article, odersky is a professor at epfl, dotty is a dot calculus research project Feb 09 18:03:16 pfn not that article, the comment is from the guuy working on dotty Feb 09 18:03:30 not the guy, but a guy Feb 09 18:04:04 indeed Feb 09 18:04:09 but it sounds like good news, if the new dialect fixes some things and is simpler i'd be interested in checking it out again Feb 09 18:04:18 it doesn't make anything simpler Feb 09 18:04:21 and there's nothing to fix Feb 09 18:04:26 nothing that mere mortals care about Feb 09 18:04:39 all the "bugs" in scala are from complex uses of types Feb 09 18:05:23 this was interesting "Dotty internal design is a lot less JVM centered" Feb 09 18:05:46 well cool, i'll keep watching it Feb 09 18:08:12 Twirl, did you manage to use fragmentpageradapter Feb 09 18:08:28 Zharf: nope, i've been trying to style the tabs Feb 09 18:09:58 dotty will allegedly make it easy to support android Feb 09 18:10:05 TASTY -> dex backend Feb 09 18:10:17 * pfn shrugs Feb 09 18:10:28 what is the difference between a PageTitleStrip and a PageTabStrip? Feb 09 18:10:37 one is a title label, one is a tab Feb 09 18:10:45 cart_man, and tutorials are meaningless Feb 09 18:10:53 cart_man, tutorials have nothing to do with how things can or should be done Feb 09 18:11:38 pfn: You are right... I started out with TabHost and TabWidgets.. turns out after all the reading that just about all of it is depricated ...GREAAT Feb 09 18:11:47 So wasted all the time and now I have to get things done asap Feb 09 18:12:10 Zharf: tabLayout.setupWithViewPager(viewPager); // viewPager doesn't have an adapter attached, do i have to put this somewhere else? maybe after updateFragment ? Feb 09 18:13:29 do it after viewpagewr has an adapter Feb 09 18:13:39 viewpager.setAdapter(...); tablayout.setupWithViewPager(viewpager); Feb 09 18:13:49 Right now I have a tab that scrolls the text outside of the View(Screen) ... What do I do to make all the text remain inside the screen? Feb 09 18:18:17 Zharf: yea it's SlidingTabsLayout Feb 09 18:20:39 I snoozed and irssi notifier woke me up and almost made me throw my laptop across the room Feb 09 18:21:01 I keep falling asleep watching these videos on youtube Feb 09 18:22:00 g00s: Feb 09 18:22:07 i noticed you around... Feb 09 18:22:10 hey thepoosh Feb 09 18:22:46 weekly was extra weak Feb 09 18:22:57 should change the name to Android Weakly Feb 09 18:23:20 lol or Kotlin Weekly Feb 09 18:23:54 I liked it Feb 09 18:23:55 :p Feb 09 18:24:08 lamers Feb 09 18:24:12 they should just call it Android Hipster Weekly Feb 09 18:24:23 LOL Feb 09 18:24:31 MVP, Part 32 Feb 09 18:24:31 Kipster Feb 09 18:25:28 thepoosh were you guys using one of those sliding up panels, or bottom sheets ? sorry if i asked before Feb 09 18:25:30 g00s: gotta tell you thoug, I've been listening to Uncle Bob a lot lately Feb 09 18:25:37 he's a bright guy Feb 09 18:25:44 yeah he's always entertaining Feb 09 18:25:50 g00s: still use a bottom slideup drawer Feb 09 18:26:10 hate it though when he spends 30 minutes talking about moon orbit and then only gets through 20% of his tech stuff Feb 09 18:26:24 it's just the first 5 minutes Feb 09 18:26:30 to let everybody in Feb 09 18:26:39 lol i've seen a few where he goes on for at least 20 min Feb 09 18:26:41 but it was kinda "WAT?!" Feb 09 18:26:47 that is not SOLID Feb 09 18:27:14 thepoosh do you guys organize your java packages by layer or feature/module ? Feb 09 18:27:24 layer like (ui / service / db) Feb 09 18:27:31 we try Feb 09 18:27:38 but there're some issues now Feb 09 18:27:41 after 3 years Feb 09 18:27:51 well, g00s, considering that you’d want to reuse the layers in different apps, Feb 09 18:27:52 try what ? Feb 09 18:27:56 it’d make sense to do that Feb 09 18:28:24 justjanne: listen to clean architecture talk by Uncle Bob Feb 09 18:28:29 you might change your mind Feb 09 18:29:23 well, thepoosh, I *have* to use 99% the same code in my model of my android app, and in a desktop app, and on a server Feb 09 18:29:29 yeah i'm probably going to move from layer -> module, my UI package has like 30 fragments / activities Feb 09 18:29:38 writing it again and again is useless. Feb 09 18:30:09 justjanne thats pretty interesting, but even in the same app - you might want different models for the same abstraction (bounded contexts) Feb 09 18:30:17 like CQRS Feb 09 18:30:36 but yeah if you plan on reusing a layer, hmm Feb 09 18:30:41 Well, the models all have a standardized set of interfaces, which can be reused Feb 09 18:30:49 I can implement different models for the same interface Feb 09 18:30:54 stuff that's cross-cutting can be cross-cutting Feb 09 18:30:57 organize by what makes sense Feb 09 18:31:06 not by strict rules Feb 09 18:31:13 which sense? Feb 09 18:31:21 that sense ! Feb 09 18:31:31 6th sense Feb 09 18:31:35 your sense is not my sense Feb 09 18:31:43 you get it after the 4th beer Feb 09 18:31:53 I generally like to organize my packages by feature/module Feb 09 18:32:11 organize them by alphabet Feb 09 18:32:23 idea does that for me Feb 09 18:32:56 danijoo lol, thats what visual sourcesafe used to do Feb 09 18:32:59 pfn: the claim is that most people make sense of the strict patterns so unless you are writing by yourself keeping to pattern is recommended Feb 09 18:33:08 g00s: so, in the end, I organize by layer, and in each layer I organize by feature. Feb 09 18:33:30 except in one layer, inside that I organize by the rough type. Feb 09 18:33:30 justjanne, sound like one class per package :p Feb 09 18:33:39 Nah, average is 30 Feb 09 18:34:21 thepoosh, eh, architect it up front to have the proper rules Feb 09 18:34:29 justjanne: the "clean code" sample app went and made a module out of each layer Feb 09 18:34:31 but organizing by feature when you need to have cross-cutting concerns doesn't work Feb 09 18:34:42 * pfn has ~200 packages in this one project... Feb 09 18:34:47 "Primitive types" "Primitive Serializers" "Compound Types" "Compound Serializers" "Auto-RPC Compound Types" "Auto-RPC Compound Serializers" "Auto-RPC RPC interfaces" "Auto-RPC RPC implementation" "Auto-RPC business logic" Feb 09 18:35:04 as we have to serialize/deserialize everything over the network, Feb 09 18:35:16 justjanne have you messed around with flatbuffer ? Feb 09 18:35:22 support RPC – or rather RMC (method) – on dozens of objects, etc. Feb 09 18:35:28 g00s: nope. Feb 09 18:35:40 Just having to support a qt-datastream based RPC protocol. Feb 09 18:35:40 does marshmallow have issues with Checkbox.setChecked? Feb 09 18:35:42 i have to make a decision soon between that or protobug grr Feb 09 18:35:54 haven't seen any problems with setChecked Feb 09 18:35:55 we are using protobufs Feb 09 18:36:08 wondering what's happening Feb 09 18:36:11 g00s: hah, have fun. I spent from november to january writing my own complete layer for that. Feb 09 18:36:28 on our marshmallow devices, a listview is not listening to setChecked Feb 09 18:36:32 (as I can use neither flatbuffers nor protobuf, as they have different implementations) Feb 09 18:36:35 probably the drawable Feb 09 18:36:35 if i can extract a primitive from protobuf with 0 allocations, i'll use that - but i heard conflicting information about that. Feb 09 18:36:41 i mean flatbuffer Feb 09 18:36:51 live with allocations until you have issues otherwise Feb 09 18:36:59 well, you can extract a primitive from my buffer with one allocation: the one for the primitive Feb 09 18:37:05 Java’s Native IO makes that easy. Feb 09 18:37:07 well i'm doing 10s of thousands of these Feb 09 18:37:12 so i have to be careful i think ;) Feb 09 18:37:16 eh, I doubt it Feb 09 18:37:36 justjanne any chance using the netty bytebuffer stuff ? Feb 09 18:37:51 pfn: I got, after switching from copying java6 IO to java7 noncopying NIO, connection time down to half of what it was before. Feb 09 18:37:52 HALF. Feb 09 18:37:57 20sec -> 10sec Feb 09 18:38:07 (and later another 5sec down with other tricks) Feb 09 18:38:33 (from "app opened" to "50 channels loaded, initialized, backlog loaded, all users with whois data loaded, etc") Feb 09 18:38:34 optimize when necessary Feb 09 18:39:01 that’s another problem, when you don’t plan for optimizations, you might end up rewriting half of your code Feb 09 18:39:14 you might Feb 09 18:39:21 I rarely have to rewrite much code as a result of optimization Feb 09 18:39:28 i'm drawing about 30 graphs each in a listview so this is an area i have to be careful Feb 09 18:39:35 RV Feb 09 18:39:42 hm Feb 09 18:40:04 sure, you might replace the nonoptimal component Feb 09 18:40:06 and that takes some code Feb 09 18:40:17 Yeah, in my case, rewriting 15k LOC. Feb 09 18:40:23 to go from copying to noncopying IO ;P Feb 09 18:40:52 is there a way to use android studio to diff two copies of a project Feb 09 18:40:52 pfn, justjanne: https://github.com/android10/Android-CleanArchitecture Feb 09 18:41:12 more specifically I want to see a diff of certain files, 5 or so Feb 09 18:41:41 g00s: my app runs on cupcake! and I have newer devices but I like my gingerbread one best Feb 09 18:42:12 15k loc, yuck Feb 09 18:42:17 they ruined it after kitkat with their crappy material design crap Feb 09 18:42:24 the entirety of my apps are no more than like 5k Feb 09 18:43:28 hah. I got 25k LOC just in the backend layer. This stuff is complex, automagically parsing properly the mode prefixes, all 4 types of channel modes, or handling properly cases where users, for which rpc calls are issues, don’t exist yet, takes a lot of code. Feb 09 18:43:43 Question: What do you think of embedding the navigation drawer on 10" devices? Feb 09 18:43:55 justjanne embedding ? Feb 09 18:44:05 like, in the view hierarchy plain include. Feb 09 18:44:24 ah, yeah thats normal for large devices Feb 09 18:44:29 Like Google suggests doing on 13"+ devices, but also on 10" devices Feb 09 18:44:57 justjanne, nah, just means you have way too many loc :P Feb 09 18:45:16 just remove the newlines Feb 09 18:45:41 Well, pfn, every bit of duplicate code is already in annotation processors. Feb 09 18:46:01 let's look the guidelines: https://www.google.com/design/spec/patterns/navigation-drawer.html#navigation-drawer-behavior Feb 09 18:46:29 "Permanent navigation drawers are always visible and pinned to the left edge, at the same elevation as the content or background. They cannot be closed" < make sense probably, since lot of huge space Feb 09 18:46:43 but then it's ridiculous if you have only few items in the drawer Feb 09 18:46:53 space optimization is horrible Feb 09 18:47:40 "There's a whole lotta universe out there" -- Material Design HQ. Feb 09 18:47:51 dark matter Feb 09 18:48:04 adq: we’re talking about 50+ items in the drawer ;P Feb 09 18:48:05 man, material design is crazy flat but it hits performances much more than previous UI they made Feb 09 18:48:06 thats what pushes all those animations around :D Feb 09 18:48:11 I abuse it as a channel list for an IRC client Feb 09 18:48:13 and it's now a hell to theme it Feb 09 18:48:17 despite how simple & flat it is Feb 09 18:48:20 go figure.. Feb 09 18:48:36 i've got more in my bag, but 'nuf Feb 09 18:48:57 i wish they were more thorough in porting stuff to appcompat, like the date / time / number pickers Feb 09 18:49:12 yeah i've read your complaint yesterday about theming datetimepicker Feb 09 18:49:13 looks like i'm going to have to use this dumbass library Feb 09 18:49:29 WTF is this? https://material-design.storage.googleapis.com/publish/material_v_4/material_ext_publish/0Bx4BSt6jniD7ME1wX3RpSkNmSUU/patterns_navdrawer_behavior_permanent5.png Feb 09 18:49:39 > Example of a permanent, floating drawer in card Feb 09 18:49:49 a float drawer lolol Feb 09 18:49:51 floating* Feb 09 18:50:20 yeah, on tablet i see a lot of designs where every area is a floating card Feb 09 18:50:21 btw, is there any library implementing persistent navigation drawers on Android? Feb 09 18:50:38 so ... in mobile where their may just be a 1px divider, now there is huge padding between cards like that Feb 09 18:50:41 the type that stays open/closed until press of a button Feb 09 18:51:08 probably justjanne, i don't know one but i would look on github or https://android-arsenal.com/ Feb 09 18:51:10 justjanne you're responsible for opening / closing yourself anyhow Feb 09 18:51:18 not sure what you mean there Feb 09 18:51:24 g00s: the persistent drawer resizes the rest of the content Feb 09 18:51:29 curious anyone know a way to force a token refresh from GCM? Feb 09 18:51:30 closed: content has 100% of window Feb 09 18:51:43 opened, the content and drawer are next to each other – you can use both Feb 09 18:52:51 seriously, there are times where I get the feeling that no one ever read or used the guidelines. Feb 09 18:52:57 on the other hand, they change so often... Feb 09 18:53:07 justjanne: which guidelines? Feb 09 18:53:15 that’s the joke. Feb 09 18:53:19 can someone clarify for me what is the meaning of "Google developer advocate" title? Feb 09 18:53:35 smacko: the material design guidelines: http://www.google.com/design/spec/material-design/introduction.html Feb 09 18:53:46 ahh gotcha Feb 09 18:54:52 anyone? Feb 09 18:55:07 confused with "advocate" thing Feb 09 18:57:00 what I’m reading on various forums says the lag between pushing a first app to google play and having it widely available in the store is realistically a few hours (i.e., not days). Feb 09 18:57:09 Does that jive with people’s experience? Feb 09 18:57:30 thats not true todays Feb 09 18:57:34 first release of app takes longer Feb 09 18:57:42 ah, Ok.. Feb 09 18:58:35 how much longer is good to expect? Feb 09 18:58:51 x20 Feb 09 18:59:26 20 hours, or do you mean “20 x a few hours” —> several days Feb 09 18:59:29 ? Feb 09 19:00:14 i think its somewhere between a few hours and 1 or 2 days Feb 09 19:00:19 more if you get rejected first Feb 09 19:00:26 then its weeks ^^ Feb 09 19:00:38 really? Does the first rejection really push you out that far? Feb 09 19:00:53 I’m not sure why I might get rejected, but that would be a concern. Feb 09 19:01:47 google support only answers every 2 days, thats why it pushs you out that far ;) Feb 09 19:02:40 ugh. I guess I should have a pretty careful look over the guidelines. My impression was that rejection from google was less of a problem than from Apple (and I’m not sure that even Apple does an especially careful job of enforcing). Feb 09 19:03:28 I don’t guess it’s a large problem in practice, is it? Anything major to be aware of that I wouldn’t glean from just reading the guidelines? Feb 09 19:04:02 juste read them Feb 09 19:04:54 duboisj: don’t even dare to tell users that things outside of the Play Store exist. Don’t implement payment or update checking outside of it. Don’t tell users about other stores. Don’t ever include any content that could be classified kinda NSFW by some prudes, or ever link to a page that links to a page with such content. Feb 09 19:05:43 hmm... Feb 09 19:06:06 also if you have copyrighted content in your app, have written permission by hand Feb 09 19:06:11 worse, Feb 09 19:06:15 you will get rejected for it and will have to show it Feb 09 19:06:18 justjanne: do you have experience with something along the “tell people about things outside the play store” that has caused you trouble Feb 09 19:06:30 duboisj: not me personally, but it’s in the ToS Feb 09 19:06:40 I recently read the ToS and decided to rant about them in here Feb 09 19:06:54 this is an lgpl app, but we’ve been doing this for a long time and we’re good about complying with source distribution requirements. Feb 09 19:06:55 (I’m not a Google Play dev yet, cause no credit card) Feb 09 19:07:02 ok Feb 09 19:07:53 duboisj: you may not link to any other way for users to download the app itself, or any other place that distributes apps. If you just link to the source, that might be okay, but there have been rumors about people getting banned for linking to github when their github linked over to amazon Feb 09 19:08:30 for one of my open source apps I link to the page about the project, which has the source but no APKs. Never had a problem, yet. Feb 09 19:08:30 I take it that downloadable content for your own app tends to be OK? Feb 09 19:08:48 the ToS doesn’t say anything about that. Feb 09 19:08:56 only alternative app distribution methods Feb 09 19:09:09 duboisj, only if users paythrough gp for it Feb 09 19:09:29 I guess I’ll have to see. Feb 09 19:10:08 if it’s free, it should be no issue. Feb 09 19:10:28 as always, if any money doesn’t go to google play, you’ll get banned Feb 09 19:10:49 unless you’re whatsapp, in that case, Google Play will integrate your payment services directly instead Feb 09 19:11:38 Ok. These are all things I’ve thought about before, but it’s a good reminder. Feb 09 19:11:46 Thanks. Feb 09 19:20:49 anyone try root tools? Feb 09 19:21:21 rdnt: I think it’s traditional to point you at the channel topic. Feb 09 19:21:27 People don’t tend to want to discuss those here. Feb 09 19:22:01 no answer in #android-root for a couple of days Feb 09 19:22:22 yeah, that channel seems to be less active Feb 09 19:22:32 still, this isn’t a root channel Feb 09 19:23:07 rdnt: those root kiddos may hang out more on website forums, e.g., xde-develpers.com Feb 09 19:23:20 (I shouldn’t say kiddos, but … people) Feb 09 19:23:39 xda* Feb 09 19:23:46 ;) Feb 09 19:24:27 ahh, xda. Where people pretend that a forum post is a suitable replacement for project management Feb 09 19:27:44 s73v3r noticed that too Feb 09 19:29:33 anyone else have a problem with aapt timing out or returning nonzero Feb 09 19:29:52 this project was building 30 mins ago. I changed nothing, tryed to perform a rebuild and now it keeps failing Feb 09 19:30:19 clean it Feb 09 19:30:56 rebuild performs a clean and then a build Feb 09 19:31:04 clean is the first task run Feb 09 19:31:18 clean it manually Feb 09 19:31:31 with right click -> delete Feb 09 19:31:43 and invalidate Feb 09 19:34:04 asd Feb 09 19:34:18 Anybody recognize this error? -> v Feb 09 19:34:20 http://pastebin.com/vKYNN86R Feb 09 19:34:56 yep Feb 09 19:34:58 cart_man: did you set a LayoutManager? Feb 09 19:35:04 ^ Feb 09 19:35:21 recyclerView.setLayoutManager(new LinearLayoutManager(this)) Feb 09 19:35:26 where this has to extend context Feb 09 19:35:28 justjanne: Hmmm.... Feb 09 19:35:30 no I did not Feb 09 19:35:41 But when does one need that though? sometimes it works without one Feb 09 19:35:56 you always need one. Feb 09 19:35:57 always. Feb 09 19:37:13 danijoo: delete what exactly Feb 09 19:37:26 crossing my fingers, looks like this build is going further than previously Feb 09 19:37:59 RustyShackleford, build folder Feb 09 19:38:40 justjanne: ViewPager is a recyclerView right? Inherits at least? Feb 09 19:38:52 unknown. Feb 09 19:38:55 also, bbl, dinner. Feb 09 19:39:41 cart_man, no.. Feb 09 19:39:50 pfn: found the checkbox issue, it was the good old "no default or xxxhdpi drawable" Feb 09 19:39:53 dammit! Feb 09 19:40:24 That is strange though Feb 09 19:40:44 cart_man, those 2 are not related at all Feb 09 19:40:46 danijoo: Because I do not have a recyclerView in my Intent anymore and also not in the Layout used by that intent Feb 09 19:40:56 still giving me that error Feb 09 19:41:04 well, i was wrong Feb 09 19:41:16 you use the word intent very wrong.. Feb 09 19:41:24 it makes absolutly no sense in that context Feb 09 19:43:46 you keep on using that word Feb 09 19:43:55 i don't think it means what you think it means Feb 09 19:44:10 hi all Feb 09 19:44:14 thepoosh, maybe its INTENTional? :p Feb 09 19:44:16 hi Feb 09 19:44:17 i need help with my android studio Feb 09 19:44:21 oh myyy Feb 09 19:44:25 snooky: ? Feb 09 19:44:26 :D Feb 09 19:44:38 lol Feb 09 19:45:00 Error:(26, 0) Supplied String module notation 'itextpdf-5.5.8.jar' is invalid. Example notations: 'org.gradle:gradle-core:2.2', 'org.mockito:mockito-core:1.9.5:javadoc'. Open File Feb 09 19:45:10 thats my problem Feb 09 19:45:52 danijoo: The activity has no trace of a RecyclerView in it but I get that error. Feb 09 19:46:23 what have android studio for a problem? Feb 09 19:46:30 snooky: to compile a file into it, Feb 09 19:46:33 snooky: build.gradle Feb 09 19:46:39 click on open file Feb 09 19:46:40 Use compile files('name.jar') Feb 09 19:46:51 You used compile 'name.jar' Feb 09 19:47:38 yes Feb 09 19:49:31 thanks Feb 09 19:54:24 danijoo: If I had a recyclerView and I remove it... is there something else I should remove somewhere that perhaps gets generated for the recyclerView ? Feb 09 19:54:52 i dont know your code Feb 09 20:06:19 cart_man: like, you have RecyclerView myRecyclerView = findViewById(R.id.something), and then later you do view.removeView(myRecyclerView)? or whatever the remove view call is? Feb 09 20:06:48 s73v3r: Nope I have no RecyclerView in my Activity whatsoever Feb 09 20:07:12 s73v3r: I have had this problem before but I can not remember how I managed to solve it Feb 09 20:07:13 so you had it in the layout, and then now you deleted it? Feb 09 20:07:21 s73v3r: Yes Feb 09 20:07:40 in the XML and in the Java source Feb 09 20:07:42 should be fine. I don’t think there’s anything that gets added to the layout file with a recyclerview Feb 09 20:08:17 s73v3r: yea this does not make sense... although there are other people who have had he samer error without a recyclerView anywhere Feb 09 20:08:21 cart_man, as always.. show yout stacktrace and the code. Feb 09 20:08:35 Although they where using ViewPager Feb 09 20:09:09 In Dagger 2, where are these @inject methods, constructors supposed to be called? Are they supposed to be called at all? Feb 09 20:11:19 oh snap, this dagger-created factory class! Didn't even notice earlier Feb 09 20:11:46 is that it? Feb 09 20:15:44 danijoo: -> http://pastebin.com/dgMvFn2F Feb 09 20:17:44 the trace doest point to anything within your app :/ Feb 09 20:19:58 There's a RecyclerView in the Fragments supplied by NewsPagerAdapter Feb 09 20:20:02 danijoo: Exactly Feb 09 20:20:19 danijoo: It just traces to Android code... its very confusing Feb 09 20:20:30 cart_man, SimonVT might be right Feb 09 20:20:44 hes a smarter guy than me Feb 09 20:25:35 danijoo: Are you by any chance the person in the Android videos? Feb 09 20:26:14 _THE_ android videos? Feb 09 20:28:15 shh those are forbidden Feb 09 20:34:10 when you type self instead of this it means something's wrong Feb 09 20:45:06 what is the deal with aapt? Feb 09 20:45:16 I always get complaints, but usuall it will press on Feb 09 20:45:19 not today Feb 09 20:45:36 fix the error then Feb 09 20:45:58 RustyShackleford maybe it broke its toe also Feb 09 20:46:52 misformed xml Feb 09 20:47:16 aapt doesn't press on in the case of malformed xml Feb 09 20:47:20 forgot I rebased. Someone push their code with including the closing quote Feb 09 20:48:21 hey g00s how you doing Feb 09 20:48:32 hi gdrc Feb 09 20:49:24 anxiously awaiting all the new goodies in AS 2 :D Feb 09 20:49:32 (once they are stable of course) Feb 09 20:49:32 just use the beta Feb 09 20:50:00 g00s, beta is already danijoo-approved. use it! Feb 09 20:50:04 oh yay Feb 09 20:50:14 There goes a day of debugging bitmap rendering. Feb 09 20:50:14 danijoo you approved it for human consumption ? Feb 09 20:50:25 Just to find out Android wants premultiplied alpha in it's color pixels :/ Feb 09 20:50:40 g00s, yeah ! Feb 09 20:51:01 * g00s not buying it Feb 09 20:51:03 :D Feb 09 20:51:12 its a trap!: D Feb 09 20:51:27 g00s, so you're waiting for 2.1 essentially? :P Feb 09 20:51:38 i guess .. :) Feb 09 20:51:55 should also consider using a computer from this decade Feb 09 20:51:57 g00s: actually it feels much better today Feb 09 20:51:59 but the improvements all look pretty exciting Feb 09 20:52:01 g00s: well, android studio is a good ide but the build time is slow as fuck as always Feb 09 20:52:10 Hi, is it smart for me to install android studio 2 beta or should I wait for final release? Feb 09 20:52:11 then don't build with gradle :P Feb 09 20:52:14 there's also instant run Feb 09 20:52:19 davor051, smart to install now Feb 09 20:52:29 it's not useful Feb 09 20:52:29 I'm using one crutch to help me walk around but the swelling is way down. I can move it without pain, but can't put weight on it Feb 09 20:52:37 instant run sounds plenty useful Feb 09 20:52:50 off we go Feb 09 20:52:51 :D Feb 09 20:52:57 maybe when it works properly Feb 09 20:53:00 yep, it takes a good minute to upload the apk to your device Feb 09 20:53:05 * pfn shrugs Feb 09 20:53:09 properly working instant run would be super useful Feb 09 20:53:11 * pfn doesn't use instant run Feb 09 20:53:22 but my builds show up on device within 10 seconds, generally Feb 09 20:54:41 regardless of how stupidly big the apps are Feb 09 20:55:47 pfn: really? That seems very optimisitic Feb 09 20:55:54 or however its spelled :p Feb 09 20:56:03 I don't gradle, not an issue Feb 09 20:56:13 do you android studio? Feb 09 20:56:17 no Feb 09 20:56:35 how do you dev then? eclipse still? Feb 09 20:56:38 no Feb 09 20:56:44 gradle is good shit man. I like it Feb 09 20:56:57 https://www.youtube.com/watch?v=LJLLyua0bYA Feb 09 20:57:00 AS is okay Feb 09 20:57:18 is gradle-plugin 2.0 what xav referred to as 'plugin NG" during last I/O tools talk ? Feb 09 20:57:36 sounded like they were rewriting it in java Feb 09 20:58:16 as I've understood it, instant run takes like 15 seconds in the worst-case scenario Feb 09 20:58:19 which is absolutely acceptable Feb 09 20:58:21 * pfn shrugs Feb 09 20:58:23 super cool Feb 09 20:58:42 does that only work for xml resources? Feb 09 20:58:45 or also java code? Feb 09 20:58:49 RustyShackleford, pay attention to the video Feb 09 20:59:00 :P Feb 09 20:59:29 I see. yeah I closed it about halfway through Feb 09 20:59:33 it does work for java Feb 09 20:59:42 and kotlin, and scala, etc. Feb 09 20:59:46 eclipse had a hot swap debugger Feb 09 20:59:46 unlike instant run Feb 09 21:00:01 you could change the definition of a method Feb 09 21:00:18 but if you edit the method signature, add a new method, etc. it couldn't handle your new code Feb 09 21:00:21 you had to rebuild Feb 09 21:00:45 As far as I know, I’ve only ever seen Instant Run for Java. It will require work in each individual language to make it work on non-Java. Feb 09 21:01:17 jaana, yeah. and it doesnt seem google will do this. I fear the languages will have to change Feb 09 21:01:41 jrebel supports kotlin, don't they? Feb 09 21:01:46 yes Feb 09 21:01:47 Well, each language is going to have to do their own work to get IR to work Feb 09 21:01:52 scala too iirc Feb 09 21:02:10 instant runs bytecode analysis just seems to suck Feb 09 21:02:24 but they wont adjust it since officially theres only java support Feb 09 21:02:44 I'll see what they do when they release 2.0 and then adapt Feb 09 21:02:48 do you guys use groovy at all? Feb 09 21:02:52 groovy sucks Feb 09 21:03:02 I like python for scripts, but my work laptop is all locked down, no admin Feb 09 21:03:09 so i've been using groovy Feb 09 21:03:40 its kinda neat. If you're familiar with java its a really easy language to work with Feb 09 21:03:42 you can also jrunscript on the jvm Feb 09 21:03:52 RustyShackleford, why do you let people do that to you :( Feb 09 21:03:54 and get nashorn on java8 or rhino on java7 and older Feb 09 21:04:04 are clean builds faster in AS2? Feb 09 21:04:17 probably not Feb 09 21:04:20 no. Feb 09 21:04:25 incremental builds are though Feb 09 21:04:36 the amount of work to build an apk doesn't change Feb 09 21:04:50 According to Google blog post they are tho :P Feb 09 21:04:52 i've seen that, that is the only thing why I wanted to install 2 Feb 09 21:04:56 Mavrik: they pay me to suffer like this so... Feb 09 21:05:07 davor051, you clean build all the day? Feb 09 21:05:14 nope Feb 09 21:05:17 I bring it up with my manager often that we should upgrade the dev hardware Feb 09 21:05:18 from time to time Feb 09 21:05:20 Mavrik, perhaps in very narrow use-cases Feb 09 21:05:23 get something less locked down Feb 09 21:05:31 and physicial devices!!! Feb 09 21:05:37 Pretty sure JetBrains will work on Instant Run shortly after 1.0. As for Scala, I’m guessing pfn is our last, best hope. Feb 09 21:05:46 I'm very much looking forward to the improved emulator that 2.0 promises Feb 09 21:05:49 they require us at the university to do clen build Feb 09 21:05:59 New emulator is nice. Feb 09 21:06:12 They stabilized it and it's now finally fast enough. I actually prefer it to Genymotion. Feb 09 21:06:20 jaana, yeah i wouldnt wonder if they dont already work on it Feb 09 21:06:27 It says thet new emulator is faster than running it on an device Feb 09 21:06:41 davor051, pushing the apk to the device is faster yes Feb 09 21:06:42 jaana, I get suitable performance as-is, so that's that Feb 09 21:06:48 Mavrik: that is awesome Feb 09 21:06:55 like I said, turnaround <10 seconds is acceptable for me Feb 09 21:06:58 I hate this emulator sooo much Feb 09 21:07:01 pfn: admit it, you’re just scared of looking into Scala bytecode :) Feb 09 21:07:12 jaana, it's all java byte code in the end Feb 09 21:07:21 Not all bytecode is equal Feb 09 21:07:25 I'm just not interested in building in gradle Feb 09 21:08:33 Instant Run is unrelated to the build too though. Writing an sbt plug-in for it is probably trivial, the hard part is adjusting the bytecode Feb 09 21:08:37 so I'm not going to instant-run for that reason, like I said, I'll consider porting it out once 2.0 is released Feb 09 21:08:39 tool* Feb 09 21:09:25 right now, even incremental compile is broken for kotlin Feb 09 21:09:27 its pretty bad Feb 09 21:09:35 kotlin doesn't incremental compile Feb 09 21:09:48 Kotlin only has incremental compilation on IDEA, not on build tools Feb 09 21:10:09 but kotlinc is relatively fast Feb 09 21:10:12 the pain should be minimal Feb 09 21:10:13 What I mean is incremental java compilation is broken with kotlin Feb 09 21:10:19 shouldn't be Feb 09 21:10:22 the java compiler will delete built kotlin classes Feb 09 21:10:28 see https://youtrack.jetbrains.com/issue/KT-10733 Feb 09 21:10:28 lolwut Feb 09 21:11:02 if it sees a class file without out the corresponding java file, it assumes its deleted and delete the class Feb 09 21:11:04 oh, it's the gradle android plugin Feb 09 21:11:07 yep Feb 09 21:11:13 super annoying.. Feb 09 21:11:17 borked Feb 09 21:11:18 :P Feb 09 21:11:34 and we all know how fast google is with fixing things like that :p Feb 09 21:11:50 yay, I hope you're glad you're using gradle ;-) Feb 09 21:11:59 That is pretty bad Feb 09 21:12:03 and feel grateful that they wrote it just for you ;-) Feb 09 21:12:53 Can you add ingame payments later? i mean publish a game for free and then add things like buy to get hints for a level? I want to get my game out as soon as possible and then i can add moneymaking stuff if it gets popular. Feb 09 21:13:04 S_J, yes Feb 09 21:13:10 but you wont be able to make it a payed app Feb 09 21:13:21 you can add in-app payments to free apps Feb 09 21:14:32 ok but you cant all the sudden charge for it? but what you could do is add annoying adds and then launch an app without adds that they have to pay for? Feb 09 21:15:29 Like MyGameFree and MyGame where MyGameFree has ads and ingame paid for stuff and MyGame you pay for and then there is no ads(but perhaps still ingame stuff) Feb 09 21:15:33 yes Feb 09 21:16:26 yes. its easy to make users uninstall and never look at your game again :p Feb 09 21:19:24 If they're not paying, f them :P Feb 09 21:20:02 getting paid is overrated Feb 09 21:20:24 as an independent android developer, I've made pocket change :-/ Feb 09 21:20:45 by stealing some phones from store Feb 09 21:22:08 So how much users do you need to make money? i Feb 09 21:22:21 from ads alone? Feb 09 21:22:23 Depends. Feb 09 21:22:24 S_J, millions Feb 09 21:22:25 :) Feb 09 21:22:40 not that much if your app is https://play.google.com/store/apps/details?id=com.richpeoplesclub.amethyst Feb 09 21:22:47 Yeah, millions sounds about right. Feb 09 21:22:59 Depending on what you're showing, but everything pays rather bad these days Feb 09 21:23:12 it really depends on if they come back Feb 09 21:23:17 lol http://i.imgur.com/aIWz8Gy.gifv Feb 09 21:23:25 if its an app the user uses daily, you need less Feb 09 21:23:36 g00s, lol :D Feb 09 21:23:48 thats how the selvie got inventet Feb 09 21:24:03 those people are also users :P Feb 09 21:24:08 well i could buy that app, download and pirate it, and then refund Feb 09 21:24:17 profits Feb 09 21:24:19 Anyone have experience with writing custom lint rules? I have gone through this https://github.com/googlesamples/android-custom-lint-rules) and written/compiled a custom rule, but now I want to try it out in AndroidStudio, and i can't figure out how to get the rule to be checked. Feb 09 21:26:48 android studio probably doesn't load custom lint rules Feb 09 21:27:12 mmmm. that is too bad Feb 09 21:27:16 would be helpful Feb 09 21:27:23 ok night Feb 09 21:36:03 is there a way to overload the system to see if it kills an app? like the monkey tool thing but um different Feb 09 21:36:28 just kill it Feb 09 21:36:42 i want to see if the system kills it under heavy load Feb 09 21:36:49 it does Feb 09 21:36:58 this $25 bluetooth works like a charm Feb 09 21:37:13 god blesss the chinese and their cheap electronics Feb 09 21:37:28 rdnt: Do you just want to see what happens when you are killed for memory pressure? Feb 09 21:37:28 does the system kill it's own services under heavy load? Feb 09 21:37:29 adb kill [options] Feb 09 21:37:41 its* Feb 09 21:37:43 rdnt, what is an own service? Feb 09 21:37:59 like wifimanager for instance Feb 09 21:38:03 you might write something that allocates a ton of memory. A native app with a big malloc or somesuch. Feb 09 21:38:23 rdnt, thats not a java service Feb 09 21:38:24 I’m pretty sure I have seen, e.g., the launcher die Feb 09 21:38:42 yeah me too :D Feb 09 21:38:47 or just run chrome and open some tabs :D Feb 09 21:39:07 there are some callbacks you can register for that will ostensibly warn you. I haven’t found them to be a lot of use. Feb 09 21:39:15 yeah. launcher have an equal right to die Feb 09 21:39:28 but they are rarely far enough behind in the backstack for that to happen Feb 09 21:40:11 launcher dies as a result of memory pressure all the time Feb 09 21:40:20 i.e., I remember the warnings sort of going from zero to sixty pretty fast. Whichever warning said ‘you are little low on memory’ was very quickly followed by ‘the memory situation ie extremely dire!’ Feb 09 21:40:24 all those times when you press home and you just see your wallpaper by itself: your launcher died Feb 09 21:40:38 and that second warning would happen a million times before my foreground app was killed. Feb 09 21:40:49 R.I.P com.android.launcher Feb 09 21:41:02 duboisj, good to know Feb 09 21:41:42 it made it difficult to make good use of them, b/c the “extremely dire” warning wasn’t allwas immediately followed by death. Feb 09 21:42:02 duboisj, whats the problem? Feb 09 21:42:58 it’s been a while since I experimented, but I recall having a hard time actually knowing when my activity was likely to get killed from memory pressure. Feb 09 21:43:33 because I’d get the ‘you might be killed because of memory pressure’ warning so often that the warning itself wasn’t a particularly reliable indicator. Feb 09 21:43:57 i just assume any time you're not the foreground activity it's likely Feb 09 21:44:30 It was my foreground activity being killed. Feb 09 21:44:48 ha, wow. what POS device was this? :) Feb 09 21:45:24 It tended to happen on the 1GB devices. So, yeah, more RAM was the answer. :) Feb 09 21:45:31 huh Feb 09 21:45:41 the manual for chinese electronics is usually hilarious Feb 09 21:45:47 What were you doing you ran out of memory on 1GB device on foreground activity?! Feb 09 21:46:06 Well, running a native app that took up a bunch of memory. Feb 09 21:46:09 duboisj, it's funny how quickly 1 gig devices were insufficient, tho my problem was rarely with foreground Feb 09 21:46:14 (a windows d3d game running under wine ;0 ) Feb 09 21:46:18 ... Feb 09 21:46:27 that's... wow. that's sure a thing you did. Feb 09 21:46:39 yes. without swap it’s really not tenable Feb 09 21:47:00 wine + android?! Feb 09 21:47:20 I’m not sure how well 2GB will hold up, but things have calmed down a lot now. Many of the current devices have that much. Feb 09 21:47:39 yes. I’m hoping it’s availble soon! :) Feb 09 21:51:36 anyone guess why google remove MyTracks from Play ? Feb 09 21:51:52 first they closed sourced it, and now i guess its done for. but why O.o Feb 09 21:52:09 i wonder if they don't like the idea, of an app in the foreground recording GPS as battery waster ? Feb 09 21:53:44 tons of apps use gps Feb 09 21:54:07 maybe too much geocoding? Feb 09 21:54:11 or reverse Feb 09 21:54:26 ll Feb 09 21:54:36 does google fit do pretty much the same thing ? Feb 09 21:55:11 yeah i guess endomondo does that too Feb 09 21:55:24 lots of sports tracking apps do Feb 09 21:56:30 i'm not familiar with mytracker Feb 09 21:57:01 does webview catch 500 errors? Feb 09 21:57:01 g00s: it was a cool app Feb 09 21:57:16 I used it sometimes, to track my bike ride Feb 09 21:57:54 I didn't know it was gone Feb 09 21:58:03 is it more efficient to keep gps on or turn it on every 15-30 seconds? Feb 09 21:58:14 I would guess the latter Feb 09 21:59:15 i wonder if these apps like endomondo, map my run, use GMS location or raw GPS APIs Feb 09 21:59:33 kind curious, these days, what the state of the art way of doing this general thing is without wasting battery Feb 09 21:59:35 I thought the GPS api was fun Feb 09 21:59:45 never finished my speed camera app Feb 09 21:59:54 waze already does it, better too probably Feb 09 22:00:27 there was that blog post a couple years ago about getting location using both sources Feb 09 22:01:58 Has anyone implemented GCM lately? I'm super confused as to why Google services are creating a notification on my behalf now when the app is in the 'forgeround'. Feb 09 22:02:17 I am trying to use it and am kinda anxious about it Feb 09 22:02:37 great, the device emulator is completely broken Feb 09 22:02:41 also is that thing? creating a notification /for/ you? Feb 09 22:03:22 do you guys use keep? Feb 09 22:03:33 yeah Feb 09 22:03:41 the way it handles notifications is kinda screwy Feb 09 22:03:47 its a decent app, but I wish it was better Feb 09 22:03:57 i like OneNote better, keep is ... pretty simple Feb 09 22:04:17 don't you have a windows phone? Feb 09 22:04:35 Keep is more like a todo list app, exactly what I'm looking for Feb 09 22:04:45 OneNote is more like a notebook Feb 09 22:05:04 you could put a whole semester's notes in OneNote Feb 09 22:05:08 it works on android too Feb 09 22:05:11 and OS X Feb 09 22:06:56 I use EverNote and NixNote on Linux (an EverNote client) Feb 09 22:07:00 GCM creates a notification for you if the app isn't running, otherwise you get a callback in one of your receivers (or services) Feb 09 22:07:14 I guess this is to make it mesh better with iOS pushes? Feb 09 22:07:25 Since iOS doesn't let you invoke a callback until the user opens the notification? Feb 09 22:07:44 When I implemented C2DM on Android a few years ago, it was always a callback, you had to make a Notification / PendingIntent Feb 09 22:07:48 What. Feb 09 22:07:50 Now, Google Services does some magic Feb 09 22:07:58 GCM doesn't create anything for you. Feb 09 22:08:03 Yes it does Feb 09 22:08:03 wtf Feb 09 22:08:04 the android emulator just crashed, after using over 9GB of RAM Feb 09 22:08:04 despite being configured to use only 1GB Feb 09 22:08:23 justjanne, new or old one? Feb 09 22:08:25 Yes, GCM can make a default message Feb 09 22:08:27 You send a 'notification' payload with a title and body and the user 'may' get a notification in their notification center Feb 09 22:08:29 plus 3GB of RAM being used by the emulator config tool Feb 09 22:08:30 wtf Feb 09 22:08:37 just the config tool Feb 09 22:08:40 achuinard, yep. Feb 09 22:08:40 danijoo: new Feb 09 22:08:46 I should switch back to the old Feb 09 22:08:55 MikeWallaceDev: And do you think this is to make things more consistent with iOS? Feb 09 22:08:57 at least that one worked without constantly crashing or eating memory Feb 09 22:08:59 never experienced that Feb 09 22:09:07 achuinard, no thought on that. Feb 09 22:09:11 justjanne still uses HAXM, which sucks :( Feb 09 22:09:18 I’m on linux Feb 09 22:09:21 it uses KVM here Feb 09 22:09:23 which is neat Feb 09 22:09:23 the new one works flawlessly here right now (on haxm) Feb 09 22:09:27 MikeWallaceDev: Do you have any idea what the 'icon' param should point to on my device? Feb 09 22:09:31 achuinard, ah. Feb 09 22:09:32 Is it 24x24? Feb 09 22:09:39 as a base mdpi? Feb 09 22:09:39 It's obviously optional. Feb 09 22:09:46 If you use data payload you still have full control. Feb 09 22:09:47 what color should it be? Feb 09 22:10:10 Mavrik: Yes, but if you don't use the notification payload and you want to reuse GCM for your iOS app, your data payload won't trigger until the user actually opens up the app Feb 09 22:10:15 Not sure what I'm using... Let me look Feb 09 22:10:28 achuinard, ? Feb 09 22:10:38 ugh. For once that I shut down AS :D Feb 09 22:10:40 achuinard, or use different serverside implementations for iOS and android.. Feb 09 22:10:43 (I'm using data payload on several apps and it works just fine.) Feb 09 22:10:50 have to do some PHP... Feb 09 22:11:05 Mavrik: But does it send an iOS push when the iOS app isn't running? Feb 09 22:11:23 We don't use GCM for iOS. Feb 09 22:11:26 danijoo: yea, total pain in the ass, GCM supposedly added iOS support and i'm using their device group messaging - what a bunch of crap to have to use another solution Feb 09 22:11:27 They have their own API. Feb 09 22:11:41 Yea well I was surprsied that GCM supports iOS Feb 09 22:11:54 is there even any way to reliably send push on both of the walled garden ecosystems, iOS and Android post-M? Feb 09 22:11:59 But it sounds cool beacuse my user has a Samsung tablet and iPhone and I can send 1 push to 1 GCM key and it'll be on both Feb 09 22:12:02 achuinard, its not like million lines of code to change the gcm message.. Feb 09 22:12:07 justjanne: Yes! GCM! Feb 09 22:12:13 achuinard, can't really answer your question. I'm using a two color icon resource that has multiple sizes Feb 09 22:12:28 achuinard: without transmitting any actual content through any US server. Feb 09 22:12:36 push was never guaranteed to arrive, let alone in a timely manner, at least with GCM Feb 09 22:12:41 justjanne, not anymore. Feb 09 22:12:49 MikeWallaceDev: But is it 24x24 base? Feb 09 22:13:03 justjanne, I mean you can still do it on Android but users will have to whitelist your app Feb 09 22:13:10 don't know, three sizes. Which one is the notification actually using?? Feb 09 22:13:27 MikeWallaceDev: Are you using the icon param on your GCM app server when you send your push payload? Feb 09 22:13:28 justjanne, USA is totally a safe harbour, dont you know? :p Feb 09 22:13:46 achuinard, oh, no. Doing it all by hand Feb 09 22:13:49 sorry Feb 09 22:14:16 MikeWallaceDev: So you always let your onMessageReceived get invoked (and Android will invoke it even if app is not running at all?) Feb 09 22:14:30 MikeWallaceDev: Then you make your own NotificationCompat object and send it to the NotificationManager? Feb 09 22:14:48 achuinard, yep Feb 09 22:14:55 and yep Feb 09 22:15:05 And are you doing anything with iOS pushes anywhere on this app server? Feb 09 22:15:11 Just using the APNS REST API and handling that yourself? Feb 09 22:15:11 fuck no. Feb 09 22:15:12 :D Feb 09 22:15:39 iOS and Android have different UX anyway for pushes Feb 09 22:15:44 So makes sense to send different payloads. Feb 09 22:16:16 Well it sounds like GCM needs to let me give slightly different params for the iOS devices and the Android devices Feb 09 22:16:26 And let GCM figure out who's on what platform and send the appropriate push Feb 09 22:16:39 Because I don't think you can have your 'onMessageReceived' callback in iOS automatically triggered even ewhen the app isn't running Feb 09 22:16:42 Like you can with Android Feb 09 22:16:52 Mavrik, achuinard , in my case, I send just the UUID of the object I want to display and then retrieve via REST. So that can be implemented in two totally different ways Feb 09 22:17:22 achuinard, hence : "fuck no" :D Feb 09 22:18:05 ok... I'm off to PHP land for a while... Have a great day peeps! Feb 09 22:18:13 MikeWallaceDev, I don't like to waste battery / data. Feb 09 22:18:24 So usually all the data required for notification is included in the push. Feb 09 22:18:48 I'm pushing bitmaps :) Feb 09 22:19:06 No comment. Feb 09 22:19:17 achuinard: Yes, you can Feb 09 22:19:26 well, I'm not pushing bitmaps. I'm pushing the UUID... Feb 09 22:19:46 achuinard, even though I'm not sure what the issue is Feb 09 22:19:46 s73v3r: I'm trying to figure this out. I feel like I don't want Android to make a notification for me, but I still want iOS to show a notification for me. Feb 09 22:19:51 Your server pushes the payload. Feb 09 22:19:59 Hey, quick one for you all : Free PHP IDE? PHPStorm is great, but I can't afford it right now... Feb 09 22:20:13 On Android, since I can always get onMessageReceived invoked, even when the app isn't running, I'll build that notification myself Feb 09 22:20:26 you can do the same thing on iOS Feb 09 22:20:27 Your server knows which device is which? O.o Feb 09 22:20:28 But on iOS, they don't let you run any code 'remotely' unless the app is specifically running Feb 09 22:20:40 the app is woken up when it receives a notification Feb 09 22:20:43 because ios sucks :P Feb 09 22:20:52 MikeWallaceDev isn't there the community version of phpstorm? Feb 09 22:20:54 that's free? Feb 09 22:20:56 no, because achuinard hasn’t actually read the docs Feb 09 22:20:57 s73v3r: ahhh well maybe I'm not understanding then Feb 09 22:21:04 s73v3r: I have read them extensively Feb 09 22:21:17 Taios, I would love that, I didn't see that. Feb 09 22:21:31 https://developers.google.com/cloud-messaging/downstream Feb 09 22:21:33 then you would know that iOS will wake your app up when receiving push notifications. Feb 09 22:21:37 Oh actually, it may be just intellij idea they have a free version. However, intellij idea is just the collective of all the ide's Feb 09 22:21:53 "Implement AppDelegate application:didReceiveRemoteNotification: to handle messages received when the client app is in in the foreground or when the message is collapsible" Feb 09 22:22:04 Taios, I thought IntelliJ was Java only? Feb 09 22:22:11 just not taylored to look as pretty for webdev, but it's basically the same. Feb 09 22:22:13 Nope :) Feb 09 22:22:15 MikeWallaceDev: PHP plugin Feb 09 22:22:23 Yep ^^ Feb 09 22:22:29 MikeWallaceDev, intellij is the base for all ides Feb 09 22:22:38 base yes. Feb 09 22:22:39 s73v3r: that line makes me think that didReceiveRemoteNotification will not trigger unless the app is running Feb 09 22:22:44 that’s the call you receive when the system receives a push notification. Feb 09 22:22:54 so I can add the pHP plug-in to intelliJ? Feb 09 22:22:58 if you install all plugins used for php storm, you will have php storm Feb 09 22:23:05 unless they’re not piggybacking on the iOS push notification service Feb 09 22:23:05 yep =) Feb 09 22:23:09 MikeWallaceDev, are you a student? Feb 09 22:23:19 "When in the background, apps receive the notification payload in the notification tray, and only handle the data payload when the user taps on the notification" Feb 09 22:23:31 danijoo, I was. In 1985. Does that count? :D Feb 09 22:23:32 "When in the foreground, your app receives a bundle with both payloads available" Feb 09 22:23:37 but in normal cases, you get woken up to handle the notification Feb 09 22:23:45 "On iOS, GCM stores the message and delivers it only when the app is in the foreground and has established a GCM connection" Feb 09 22:23:47 MikeWallaceDev, not for the free jetbrains ide I fear :p Feb 09 22:23:52 hahahaha Feb 09 22:24:03 s73v3r: however - "If you want to send messages consisting of only custom key/values to an iOS device when the app is in the background, set custom key/value pairs in data and set content_available to true" Feb 09 22:24:09 honestly, then that sounds like google is doing some funky things with push, and i would avoid their system Feb 09 22:24:14 you could argument with ´im still a student in my heart´ and see how far it gets you :p Feb 09 22:24:26 ok, I'm going to go try this. Thanks peeps! Feb 09 22:24:31 s73v3r: If I set content_available to true then maybe the iOS callback is invoked? Feb 09 22:24:37 phpstorm? you want what? yuck Feb 09 22:24:37 it is Feb 09 22:24:51 pfn, any other suggestions? I'm open Feb 09 22:25:07 you can also send a notification that will just set badge count, play a sound, or put a notification in the tray, without you having to do anything Feb 09 22:25:07 anything other than php Feb 09 22:25:11 danijoo: I now sent a formal complaint to the Unabhängiges Landeszentrum für Datenschutz Kiel, you might have heard of them before, they’re the data protection agency that sues (and wins against) facebook about every 6 months. Feb 09 22:25:28 justjanne, about what? Feb 09 22:25:41 about GCM’s monopoly situation in Marshmallow, Feb 09 22:25:46 pfn, well the server's in PHP, so that's no help :P Feb 09 22:25:47 and the data privacy implications Feb 09 22:25:50 s73v3r: Yea and it seems Google Play services is letting you replicate this behavior on iOS now - namely auto-creating a push and putting it in the android notif center Feb 09 22:25:51 sent a formal complaint Feb 09 22:26:08 justjanne, why is that a privacy implication? safe harbour? Feb 09 22:26:11 achuinard: That’s been part of the iOS system for a while Feb 09 22:26:11 replicate on Android* Feb 09 22:26:18 Typo Feb 09 22:26:24 ahh. Feb 09 22:26:28 Android, I always thought was you had to make the push yourself, but now GCM does some magic for you to simulate that Feb 09 22:26:32 so you don’t have to write code for the basic thing? Feb 09 22:26:43 danijoo: Safe Harbour is one issue, but also having to transfer any private message content in a way that third parties might read. Feb 09 22:26:52 No, you can say 'title', 'body', etc. and then GCM will send an actual notification to the device Feb 09 22:26:56 ^ Feb 09 22:27:01 that feature is an issue. Feb 09 22:27:09 For the user to click and launch your app with the data in the intent Feb 09 22:27:14 and having to rely on it during doze, for example. Feb 09 22:27:47 safe harbour will be renamed to privacy shield and nobody will care anymore :/ Feb 09 22:27:56 danijoo: their job is to protect citizen from this shit, if they find a way to sue, they will sue. Feb 09 22:28:09 im sure they will try Feb 09 22:28:18 And maybe Google will change their approach after an international arrest warrant against the CEO is issued. Feb 09 22:28:20 Facebook did. Feb 09 22:28:28 and im sure it will be as successful as killing safe harvour Feb 09 22:29:06 maybe, maybe not. Feb 09 22:29:08 which just gave us a renamed act with same conditions Feb 09 22:29:17 well, maybe, maybe not. Feb 09 22:29:22 there is no way the US would comply with such a warrant unless there was good reason Feb 09 22:29:24 the ECJ will surely strike that down, too. Feb 09 22:29:53 s73v3r: no, but the same warrant also authorizes them to seize 10% of their global revenue to enforce compliance. Feb 09 22:29:57 that *does* hurt. Feb 09 22:30:29 10% is the cap for any action the EU can do to enforce compliance, that’s why you always hear it in Antitrust and data privacy cases. Feb 09 22:30:54 Anyway, I sincerely hope we can find a better solution than what we have now. Feb 09 22:31:24 thing is there is no monopol in gcm Feb 09 22:31:30 well, with doze, there is. Feb 09 22:31:49 people are free to sell/build/create GPS free phones that use another server Feb 09 22:31:51 service* Feb 09 22:31:59 no, they aren’t. Feb 09 22:32:03 they are Feb 09 22:32:06 no, not this discussion again Feb 09 22:32:08 android is open source Feb 09 22:32:12 s73v3r, you are right. Feb 09 22:32:14 ill stop Feb 09 22:32:20 But none of the Android manufacturers may produce such devices. Feb 09 22:32:37 s73v3r: so are you pretty familiar with content-available flag on iOS? Feb 09 22:32:43 justjanne: Amazon does Feb 09 22:32:50 one plus does Feb 09 22:32:52 achuinard: in that I’ve used ti before Feb 09 22:33:07 aanyways. good night everyone Feb 09 22:33:15 s73v3r: so it sounds like you won't get the push sometimes if content_Available is true - like if the user rebooted the device and never relaunched your app since reboot? Feb 09 22:33:16 amazon has had extreme issues finding an OEM that does NOT produce GPS devices, so they could produce AOSP devices. Feb 09 22:33:59 achuinard: I believe so Feb 09 22:34:17 s73v3r: did you setup a local notification when using content-available true? Feb 09 22:34:17 pfn, just in case it interested you, it seems custom lint rules can be used in AS 1.4+ https://groups.google.com/forum/#!msg/adt-dev/LS9QRtMGnws/DNSUktxNAQAJ Feb 09 22:34:23 no Feb 09 22:34:30 I still have not gotten mine to work, but it can be done Feb 09 22:34:48 toolbar.setElevation(0); makes everything disappear on the toolbar Feb 09 22:34:57 how can i remove the border from the bottom? Feb 09 22:36:11 interesting Feb 09 22:36:33 didn't know you can search through irssi buffers :3 Feb 09 22:36:57 does WebView do anything strange if there's a 500 response received? Feb 09 22:39:07 really, if i remove the attribute or set it to 0 the toolbar goes away Feb 09 22:40:00 because you have another view with higher elevation Feb 09 22:40:15 truckcrash, only semi, since I don't use AS Feb 09 22:40:56 pfn, What do you use? Feb 09 22:41:45 pfn: well, it should be the menu right? it doesn't have any elevation set Feb 09 22:42:53 truckcrash, intellij Feb 09 22:43:24 Twirl, that's because whatever appears in its place has an elevation set Feb 09 22:43:38 z-ordering is determined by elevation on v21+ Feb 09 22:45:14 pfn: where? i can't see any elevation set Feb 09 22:45:38 how would I know, I'm not clairvoyant, you haven't shown any code Feb 09 22:46:09 you saying i can't read my code or something? Feb 09 22:46:30 oh no, not again Feb 09 22:47:08 yes Feb 09 22:47:12 I absolutely am Feb 09 22:47:22 it should say something like elevation something Feb 09 22:47:35 why would i copy paste something so you can proof read it Feb 09 22:47:48 /ignored Feb 09 22:47:49 waste of time Feb 09 22:50:36 pfn: what do you use instead of AS? Feb 09 22:51:41 intellij Feb 09 22:51:52 oh right I think we had this conversation Feb 09 22:53:47 :D Feb 09 22:55:29 I'd like to implement OnFragmentInteractionListener in a 'generic' way such that my activity implements a single interface which applies to several fragments. Is this possible? Feb 09 22:55:31 what intelliJ features do you use that aren’t in Studio? Feb 09 22:56:44 porjo yeah, it can be a mess - i have 7-8 listeners on one activity ... Feb 09 22:57:40 g00s, so not possible then? Feb 09 22:57:55 i've been thinking of ways around it past few days Feb 09 22:58:03 if i come up with something good i'll share Feb 09 22:58:14 if you come up with something good, share :D Feb 09 22:58:37 s73v3r, working with non-android projects Feb 09 22:58:56 rx, or observer pattern Feb 09 23:00:45 is there a good statistic for me to measure wrt to GCM working properly Feb 09 23:01:01 like, percent messages sent successfully Feb 09 23:01:19 or number of SERVICE_UNAVAIlABLE errors returned from play services Feb 09 23:01:38 not sure what would be the most useful Feb 09 23:01:50 plus I am lacking on historical data to compare with Feb 09 23:08:10 rx seems kinda pita for that sort of thing. maybe in kotin with those data classes, otherwise you're also making little wrapper classes to pass multiple arguments Feb 09 23:09:04 well, it's java Feb 09 23:09:07 stop using java Feb 09 23:10:01 rx is about the best you'll get for generic observer pattern in java Feb 09 23:16:06 do it in just about any other language and you'll have tons of options for an expressive observer Feb 09 23:39:23 are breakpoints compiled into classes? I somehow have breakpoints in a library I'm including and it keeps breaking on them, and I have no idea how to remove them Feb 09 23:54:23 Does anyone know if it's possible to use more than one instance of MediaCodec with only one SurfaceHolder? Feb 09 23:54:45 Is it true that Android will only show notification actions on the topmost notification? Feb 09 23:58:56 Is there a way to remove the "static underline" of EditText views without setting the background-property? Feb 09 23:59:20 by setting the background property, you lose the default padding which is unfortunate Feb 10 00:22:51 breakpoints are not compiled in Feb 10 00:23:01 grekkos, list breakpoints -> delete them Feb 10 00:38:03 uh, weird - AS stopped recognizing a new file as java, even with .java extension Feb 10 00:38:18 when i open it, nothing highlights Feb 10 00:38:26 file association get messed up ? Feb 10 00:39:59 super weird. Under file associates, Text, Registered pattern is "FooFragment.java" how the hell could that happen Feb 10 00:43:10 Mongolians in the system. Feb 10 00:44:09 no, just regular AS Feb 10 00:44:19 :') Feb 10 00:55:34 meh, blew the driver in my sub Feb 10 00:55:43 cheap $20 replacement... Feb 10 00:58:03 sub woofer? Feb 10 01:03:17 yeah Feb 10 01:05:05 just my computer speakers Feb 10 01:05:11 they're stupid old Feb 10 01:05:45 http://www.anandtech.com/print/486/ Feb 10 01:10:08 Can a single SurfaceHolder not be configured twice by MediaCodec? Feb 10 01:10:52 "configure twice"? Feb 10 01:11:33 like, I have a SurfaceHolder in an activity. I then pass it to two instances of ExoPlayer, which use MediaCodec configure Feb 10 01:12:16 every time, I get "native_window_api_connect returned an error: Invalid argument (-22)", unless I add another SurfaceHolder for the other instance of ExoPlayer Feb 10 01:12:29 i don't know :s i'm using SurfaceHolder but only surfaceview iirc Feb 10 01:13:21 I'm getting the SurfaceHolder from the SurfaceView Feb 10 01:13:52 so i control fps of drawing, lock & unlock canvas, and in between i draw in the canvas it Feb 10 01:27:08 should it be OK to get a Google API Client in a Service ? (like, LocationServices.API) ? Feb 10 01:27:23 i know some like Nearby Messages specifically check that you do this from an Activity or Fragment Feb 10 01:27:35 * g00s gives Google finger Feb 10 01:29:20 g00s: hawt Feb 10 01:34:09 hey - good morning.. does anyone know on how to configure my build.gradle to give me details on what deprecated methods it has discovered? Feb 10 01:34:31 divStar: I think you're looking for android linter Feb 10 01:34:47 I want to see why I keep getting "Recompile with -Xlint:deprecation for details." Feb 10 01:35:03 (I am using Android Studio) Feb 10 01:35:49 how come when i add google-servcies in my build.gradle and then sync i get resource errors because of a "." in a filename? Feb 10 01:35:54 when it works fine without it Feb 10 01:37:50 divStar; not sure how to do that on every gradle build, but you can def run it from the CLI Feb 10 01:38:44 well I don't need it on each build.. I just want to do it on demand.. wouldn't mind typing a command or something.. Feb 10 01:40:15 `./gradlew tasks` will let you find the command that does that for you Feb 10 01:45:29 smacko - thanks! I ended up creating a separate analyzation profile and inspecting code with only that one Feb 10 01:48:55 cool, where did you do that, within android studio? Feb 10 01:49:50 yup Feb 10 01:50:10 under settings > editor > inspections Feb 10 01:50:46 there I have copied the profile, deactivated everything on the copy, searched for "deprecated" and enabled everything that was filtered.. Feb 10 01:51:07 ahh Feb 10 01:51:30 Currently I'm running the linter one file at a time. Feb 10 01:52:07 I also read you can configure it to run with every build if you like and have the build fail if the linter returns a certain level of warnings etc. Feb 10 01:52:08 took over a small but messy code. running for the whole project gave me a near heart attack Feb 10 01:52:22 hehe Feb 10 01:52:49 and I'm a n00b to android Feb 10 01:52:52 I have copied a "NumberPickerHorizontal" class from the net (have not tested it yet, but looks good) Feb 10 01:53:08 cause there is no way to have a horizontal number picker out of the box Feb 10 01:56:26 damn 3AM .. gotta go to bed or work tomorrow will kill me >.< Feb 10 01:57:11 but before that I wanna see if my changes are at least present Feb 10 01:57:43 don't it's a trap Feb 10 01:57:48 :-) Feb 10 01:57:58 >.< it is because you said so ;_; Feb 10 02:21:54 yay it works roughly as supposed... Feb 10 02:22:24 forgot to call "setContentView" and was going crazy as in "where the hell is my content" :D Feb 10 02:22:38 anyway.. good night! Feb 10 02:35:52 Hello Everyone. I have BTLE question. Feb 10 02:38:39 I am writing app to connect to Microchip BTLE with my app. I can discover the device and I can get sockets by calling createInsecureRfcommSocketToServiceRecord() on device with UUID. I get socket and it is not null. When I try to call connect it blocks for couple seconds then I get IOException with message "read failed, socket might closed or timeout, read ret: -1" Feb 10 02:38:59 I am not paring with this device. Feb 10 02:39:26 Guma createInsecureRfcommSocketToServiceRecord is for br/edr Feb 10 02:39:59 Also I found another app in Store that I used to verify that I could connect. It is called "nRF Master Control Panel" Feb 10 02:40:20 what is br/edr Feb 10 02:40:29 its not BTLE :D Feb 10 02:41:12 Aha. So what should I do when I found device after scan? Feb 10 02:41:34 Guma there are BLE docs ... Feb 10 02:41:48 and even an example in SDK manager / samples Feb 10 02:42:01 what am I doing wrong. I did try to follow tutorial on Android website for BTLE Feb 10 02:42:18 Ok I will check SDK Manager Feb 10 02:42:56 Are you referring to some specific BLE docs? Android Tutorial site? Feb 10 02:43:55 the sample is android-23/connectivity/BluetoothLeGatt Feb 10 02:45:40 g00s . Ok will check it out now. Feb 10 02:58:58 can someone help me with this error progaurd error: http://pastebin.com/d6XzHNAa Feb 10 02:59:03 My paste has the error, proguard-project.txt, build.gradle and dependencies Feb 10 02:59:48 The odd thing is that it compiled just fine the first time... I've tried gradle sync and clean project.. dunno what else **** ENDING LOGGING AT Wed Feb 10 02:59:59 2016