**** BEGIN LOGGING AT Sat May 21 02:59:58 2016 May 21 03:10:16 <_xor> Newbie here. Is there a way to NOT have to specify a startup activity in the manifest? I guess it can probably just be left out? May 21 03:10:37 <_xor> I'd like to have a main startup class from which I can launch the initial activity. May 21 03:12:33 why would you need a startup class? May 21 03:12:53 you can do initializations in a class which extends Application class May 21 03:13:41 _xor, ^ May 21 03:15:02 <_xor> Yup, that's true. May 21 03:15:06 <_xor> I'm just messing around. May 21 03:15:43 <_xor> I'd like to dynamically determine the startup activity without having to launch another activity to do so. May 21 03:15:54 anyhow, I think the launcher requires the main activity to know which to launch May 21 03:15:59 humm May 21 03:16:26 I have never done that, people usually employ Splash screens for the very reason May 21 03:16:42 <_xor> Sure, but it seems odd that if you derive from Application, the System would have to assume that the app will take care of launching a given activity. May 21 03:16:57 <_xor> True. This isn't for a splash screen though. May 21 03:17:58 a good question indeed, I will see if I can find something, might be useful in future May 21 03:17:59 :) May 21 03:19:00 <_xor> I'm messing with it now. May 21 03:19:20 <_xor> There's onCreate, but read the docs on it. It could work, but it's right in saying that it's meant for lazy-loading and not really this. May 21 03:26:02 uh what May 21 03:27:48 Splash screens are an app smell in my opinion May 21 03:28:02 <_xor> They generally are. May 21 03:28:28 It's the developers saying "Sorry we can't show you anything meaningful for at least two seconds so here's a cute picture why we make you suffer because we are lazy developers" May 21 03:28:58 Remove the splash screen and design your app so you can show something to the user under 2 seconds. Not the end of the world May 21 03:29:10 Looking at you Starbucks App, which takes five seconds to show me a barcode May 21 03:29:13 CedricBeust were you at i/o again today ? May 21 03:29:22 Yeah May 21 03:29:33 CedricBeust what piqued your interest today ? May 21 03:29:49 Went to machine learning sessions for the most part. At least the ones I could get in May 21 03:31:12 nice May 21 03:31:50 <_xor> Machine Learning is interesting as fuck. May 21 03:34:35 CedricBeust surprised there were no tensorFlow sessions for Android May 21 03:34:53 although, i guess it builds with bazel and thats kinda pita May 21 03:35:30 <_xor> Ok, another dumb question. I just reorganized a project to have sub-directories for various types of classes. It's not compiling now because it says it can't find the R class. I'm guessing it's because when the classes were put into different subdirs, AS refactored the package names to include the subdirs. May 21 03:35:54 <_xor> I'm wondering if I should just put them all under one namespace/package in my app. May 21 03:58:42 https://gist.github.com/alex88/b33d189b9b9268422ab4d97fa4c52fed I've this activity and layout, why the loginButton is null in the onCreate function? May 21 03:59:31 oh easy one, had to change the extended class May 21 04:01:03 g00s: Tensorflow for Android? May 21 04:01:11 CedricBeust yeah it works on Android May 21 04:01:19 but its kinda pain to set up May 21 04:01:29 Didn't know that, not sure what the point is though May 21 04:01:36 Hopefully at least not for training May 21 04:02:05 i have many ideas already, not sure if / when i'd get to them May 21 04:02:12 here you go https://jalammar.github.io/Supercharging-android-apps-using-tensorflow/ May 21 04:03:09 this is one of those scenarios, wish i had a first class to the metal language like swift to use on android May 21 04:03:24 i mean, yeah c++, but ugh May 21 04:03:30 Interesting May 21 04:06:43 "The model is read from the file and fed into TensorFlow when the app starts up. " so in this case, seems like no training in app May 21 04:06:57 Yeah that makes sense May 21 04:10:09 CedricBeust accelerate training with hints :D http://imgur.com/NQQVXKK May 21 04:11:37 hm this is a tough one, flower or cat? http://i.imgur.com/udjvkkk.jpg May 21 04:30:40 what you advice as a simple network library to make simple json post/get? May 21 04:30:52 is google's volley a good one? May 21 04:32:53 alex88 retrofit is popular May 21 04:34:51 g00s: kk thank you, I'll check which one I like more May 21 04:35:22 seems pretty nice and minimal May 21 04:54:02 g00s: as a non java developer as I am, I was wondering reading the retrofit docs, there are no complete examples, no documentation (except Javadoc), do you guys just go through javadoc or search for example online to get started with a library? May 21 04:55:13 alex88 i haven't used that one personally, not sure where the docs are May 21 04:56:08 kk gotcha May 21 04:59:13 alex88, May 21 04:59:29 there are examples May 21 04:59:32 wait let me link you May 21 05:00:01 alex88, here you go https://github.com/square/retrofit/tree/master/samples/src/main/java/com/example/retrofit May 21 05:00:02 paresh: there's a samples folder in the git repo, I've also found other examples online May 21 05:00:07 yea May 21 05:00:11 the sample folder :) May 21 05:00:22 that was all I needed to get started May 21 05:00:44 my questions were mostly to understand how java people starts to understand a new library.. if they just go through the javadoc, since to me it's kinda hard to understand by just reading that May 21 05:01:12 alex88, samples mostly (like every other language, I would assume) May 21 05:01:38 as when I used to do C, I would look at others code to get a gist of new techniques and sample codes to learn about new libraries May 21 05:02:22 paresh: gotcha, thank you May 21 05:03:02 alex88, what language did you switch from? May 21 05:03:29 (if you don't mind me asking) May 21 05:03:45 paresh: php, ruby, now learning elixir May 21 05:03:49 just doing a sample app for a demo May 21 05:03:58 :o nice May 21 05:04:01 need to setup just login, a list activity, a detail activity and a notification May 21 05:04:14 php is really mature language, so is ruby and java May 21 05:04:43 I tried to do that in react-native, but I didn't like the result, so I'm trying to go native :D May 21 05:04:43 I have no knowledge of elixir May 21 05:04:50 :o May 21 05:05:09 paresh: I just started using it for this demo so I have a real-case application to develop May 21 05:05:10 after all those articles I thought react native was really good May 21 05:05:16 I haven't tried it myself yet May 21 05:05:59 oh it is, but I got stuck doing svg rendering which on android was doable only with a damn slow webview May 21 05:06:07 so why not native? i can learn something new May 21 05:06:12 alex88, if you want to learn more, ud853 is a good place to start May 21 05:06:35 weird I thought react-native was a native app May 21 05:06:41 paresh: good to know, thank you.. only problem is that I want to have something working by Monday :D May 21 05:06:44 not a webview like cordova(phonegap) May 21 05:06:48 paresh: oh it is, you can implement your own stuff May 21 05:06:59 you can also integrate native things May 21 05:07:01 alex88, ud853 first 2 lessons will get you something working :) May 21 05:07:09 3,4,5 are icing on top May 21 05:07:47 good luck with your app :) May 21 05:07:49 honestly, I tried to import volley now :D and android studio isn't seeing the packages, the gradle dependency downloaded an aar file May 21 05:07:52 thank you man :D May 21 05:08:08 personally I hardly know anyone who uses volley May 21 05:08:12 everyone uses retrofit May 21 05:08:13 :d May 21 05:08:41 sure it is quite weird for newbies because of the whole annotation thing May 21 05:08:54 but once you get used to it, it really is syntactic sugar May 21 05:08:55 :D May 21 05:09:45 ok, let me give it another try lol May 21 05:09:59 I've created a library module in the project to keep things separate May 21 05:13:14 so to generate a response like https://gist.github.com/alex88/d12fde7640f6e5685c46d364f232850b I need to create a class for the main response and one for the nested user class? May 21 05:14:03 yes May 21 05:14:51 alex88, https://github.com/pareshchouhan/HackAnotherDay/tree/master/app/src/main/java/com/futuretraxex/hackanotherday May 21 05:14:56 check model and network folder May 21 05:15:00 and the code inside them May 21 05:15:10 It's written to work against this API http://hdn.futuretraxex.com/ May 21 05:15:17 :) May 21 05:15:20 hope you find it useful May 21 05:15:23 paresh: wow, pure gold, thank you! May 21 05:16:17 but, GsonConverterFactory is GSON, is Json? May 21 05:16:25 s/is GSON// May 21 05:16:42 yes Gson is a library which convers JSON to Java objects May 21 05:17:00 https://github.com/google/gson May 21 05:17:24 oh that one, right May 21 05:20:25 if you got any doubts feel free to ask me May 21 05:20:26 :) May 21 05:20:57 just got another one, and to call this service, you wrap the request in an asynctask? May 21 05:21:05 yes May 21 05:21:13 if you do it on UI thread, android will complain about it May 21 05:21:18 so https://github.com/pareshchouhan/HackAnotherDay/blob/master/app/src/main/java/com/futuretraxex/hackanotherday/network/FetchPostsTask.java May 21 05:21:31 yes May 21 05:21:46 see line 51 to 56 May 21 05:21:52 mmhh ok, I think that should be done in the app context, the async task.. kk.. brb with the results :D May 21 05:22:01 that's a network call to fetch JSON data and convert it into java objects May 21 05:22:55 though AsyncTask has some issues May 21 05:23:02 which you will eventually realize May 21 05:29:01 paresh: i've a module called mobile with the mobile app and another called api, how do I put api as dependency of mobile to import classes" May 21 05:29:03 ? May 21 05:29:24 compile project(':api') there we go May 21 05:29:28 yes May 21 05:29:32 build.gradle May 21 05:29:46 was missing the project() May 21 05:35:45 paresh: I'm a little bit stuck, https://gist.github.com/alex88/241408a575b37c50f5a466381c2be6e6 May 21 05:36:03 my questions are May 21 05:36:36 1) where should I call onLoginSuccess? Inside the login task? or make the task throws IOException and do the try catch in the login function May 21 05:37:02 2) how can I check in case of non 2xx response the status, to know if there's an auth error or a network error May 21 05:42:16 alex88, the whole blog post is pretty good https://futurestud.io/blog/retrofit-2-simple-error-handling May 21 05:42:38 paresh: awesome ty! May 21 05:42:50 a bit complex May 21 05:43:00 but if you don't need error handling in demo May 21 05:43:09 you can skip the non 2xx response status May 21 05:43:31 oh there's a whole list of posts, seems very nice May 21 05:43:43 paresh: yeah I'll just catch everything that's not 200 May 21 05:45:16 oh so IOException is on network error, otherwise I just need to response.isSucccessful May 21 05:54:37 mmhh I've this error https://gist.github.com/alex88/072a1012120080883f48fed47da460fe (attached also my gradle files), I've tried to add May 21 05:54:56 java version 1.8 as http://stackoverflow.com/a/37294741/690839 but it requires build tools version 24 which are not stable yet May 21 05:55:48 oh, nvm, I had to add that to the api gradle, now it seems to work May 21 05:55:56 or at least, loading bar is psinning :D May 21 06:02:04 paresh: hope this is the last one, https://gist.github.com/alex88/5161ce8376ccad1dd766cf049bde1989 May 21 06:02:44 when I click on the login button I see the debugger hits the new LoginAsyncTask() line, then the Api.getInstance().doLogin() line May 21 06:03:05 and in the meantime the app crashes with java.lang.IllegalStateException: Cannot execute task: the task is already running May 21 06:03:10 however I'm not calling it twice May 21 06:05:19 AsyncTask as inner class is a really bad idea (just saying - not related to your problem) May 21 06:06:50 danijoo_: I've put it there to access login callback methods, let me see how I can extract it May 21 06:07:54 alex88, if its an inner class like yours, it holds a reference to the outer object under the hood (to access variables). May 21 06:08:18 if the task is still there while your activity gets destroyed, you are leaking memory from the activity May 21 06:08:30 danijoo_: since the task can be executed only one, is that a big problem? otherwise how should I work? intents? May 21 06:08:36 oh I see, yeah memory leak is no good May 21 06:10:13 one approach would be to have activity as variable in the LoginAsyncTask May 21 06:10:26 when your acitivty gets destroyed you set that variable to null May 21 06:11:20 btw your Illegalstateexception: You call asyncTask.execute twice in line 52 ;) May 21 06:11:25 execute().execute() May 21 06:12:05 omfg May 21 06:12:32 ^^' May 21 06:12:50 * alex88 facepalm May 21 06:17:40 execute returns the task? wow May 21 06:21:33 that makes this one liner possible: May 21 06:21:35 myAsyncTask = new MyAsyncTask().execute() May 21 06:22:11 anyway, login works! :D May 21 06:22:13 thank you guys May 21 06:22:26 nwo time to store the login token in a good way to use it later May 21 06:35:57 I've these styles/manifest https://gist.github.com/alex88/b00f3e624cf6b35c8e5e78f22cfc394e why when I open the TimelineActivity I don't see the action bar? May 21 06:36:28 before that I had this.requestWindowFeature(Window.FEATURE_NO_TITLE); in the login activity onCreate but I find the styles way cleaner May 21 06:48:14 found it, had to extend RoboActionBarActivity May 21 07:29:35 alex88, I was afk :( May 21 07:29:45 hey guys! May 21 07:29:47 aww May 21 07:29:51 also SharedPreferences is best way to store those tokens May 21 07:31:37 paresh: np man :D May 21 07:31:40 yeah using that now May 21 07:31:50 I implemented also another api call to list some entities May 21 07:32:08 now trying to understand recyclerView and cards coming from the support library May 21 07:32:14 would be perfect with the layout we need May 21 07:48:53 wow it works May 21 07:49:08 now I've just to understand how to style something like a card May 21 07:49:41 https://plus.google.com/communities/105113874753230740413 May 21 07:49:51 seems quite a few people are upset at how I/O went this year... May 21 07:50:41 long lines, bad food, too little shade, no hands-on with new stuff since none of it will be ready until later this year, and no decent swag May 21 08:03:38 is there a way to programmatically change a border color to a relative view? May 21 08:03:59 Online I find only examples about setting a drawable as background, but I can't programmatically change the color with that May 21 08:05:01 how do you set the bordercolor? May 21 08:08:16 danijoo_: usually in the drawable May 21 08:08:36 the solution I've found is this https://gist.github.com/alex88/d1b47475d2572e547d08bc64c254d405 but it draws all the borders May 21 08:08:39 I need just the left one May 21 08:09:08 what do you mean with left one? May 21 08:10:30 left part of the border? May 21 08:10:42 yeah, just the border on the left, not all the 4 borders May 21 08:10:47 like border-left in css May 21 08:10:55 not possible that way May 21 08:11:24 yeah I've found that too :D May 21 08:11:34 you can change the drawable May 21 08:11:43 and not use gradient for that. May 21 08:11:51 but a static image or vector or whatever May 21 08:11:53 the drawable you mean the xml? May 21 08:12:15 you could use 2 pngs instead May 21 08:12:18 and swap them May 21 08:12:32 or 9.png or whatever you want :) May 21 08:12:59 other option is to create an horizontal view, first element has 1 px width, full height and a background May 21 08:13:13 no that sucks May 21 08:13:19 since the color is set by the server, sent in the json, I can't use unlimited pngs May 21 08:13:42 views are heavy. dont abuse that for such a thing May 21 08:14:07 eh I know, but pngs are not an option May 21 08:17:30 alex88, maybe you can find something usefull in ShapeDrawable or LayerDrawable May 21 08:17:41 im not experienced with them May 21 08:17:59 kk thank you for the advice May 21 08:18:45 one thing I can think of is creating 2 drawables as shape in xml. one for the left border and one for the rest. Than you can apply the color filter only on the left one to colorize it May 21 08:19:04 and finally combine them in a layerlist that gets set as background May 21 08:19:44 danijoo_: that's foreign language to me man :D May 21 08:20:21 Sometimes you just need to create a custom drawable May 21 08:21:32 but don't worry guys, for the demo, the border view is more than enough May 21 08:27:33 it works perfect, now last part, display an svg from a string :D May 21 08:42:18 if on an imageview I do image.setImageBitmap() and I set a bitmap with a size, why, since the imageview has layout_width="match_parent" and layout_height="wrap_content" May 21 08:42:24 the imageview has still width/heigth=0? May 21 08:52:15 alex88: no idea May 21 08:52:31 I didn't pay attention in Android class May 21 08:52:41 alex88, did the layout pass run? May 21 08:52:53 lo May 21 08:52:54 lol May 21 08:53:11 Mavrik: layout pass? anyway, seems that I had to enable software rendering May 21 08:53:11 The views (obviously :) ) have sizes set only after they've been laid out. May 21 08:53:23 That's a silly solution :P May 21 08:53:40 docs fault :P http://bigbadaboom.github.io/androidsvg/use_with_ImageView.html May 21 08:54:16 Ugh. May 21 08:54:39 yeah I haven't found any other libraries May 21 08:55:16 not big issues tho http://imgur.com/m9PnZW9 :D May 21 08:55:20 at least I see the svg May 21 08:55:54 I've the ratio so I can calculate the height of the imageView by its width inherited by the parent and the ratio May 21 08:56:52 Can't you use VectorDrawables? May 21 08:57:00 SVGs will be ass slow on most devices. May 21 08:57:04 Especially with software rendering. May 21 08:57:51 Mavrik: you mean convert svg to drawable? May 21 08:58:20 those offline conversions? May 21 08:59:19 btw svg is already converted to a drawable May 21 09:02:11 http://imgur.com/Ppn4GI1 now I've just to scale them correctly, fitXY nor center doesn't work May 21 09:10:15 ok the problem is that the bitmap created is as big as the original svg, but it should be created larger May 21 09:10:24 which doesnt' create problems since the svg is scalar May 21 09:10:35 but at the time I render the svg the imageView has width 0 May 21 09:10:44 since it's not already there May 21 09:14:38 alex88, you tell the imageview to match the size of the image May 21 09:14:45 but since image is scalar, it can be any size May 21 09:14:48 thats the problem May 21 09:15:09 one of the 2 components needs a defined size. either the image or the view May 21 09:15:37 danijoo_: I think that svg creates a bitmap of 400, which is the default svg width, imageView doesn't scale it to go more than 100% of scale May 21 09:16:16 play with the scale settings :> May 21 09:16:25 http://stackoverflow.com/a/25069883/690839 says "if the intrinsic width of src is smaller than parent width will center the image horizontally" May 21 09:16:31 and I think that's what is happening May 21 09:16:39 problem is that I'm going to scale the bitmap May 21 09:16:46 so the raster, right? May 21 09:16:59 since if the bitmap is created from the svg for a width of 400, that's the raster width May 21 09:19:10 now I'm trying to see if the library svg view fixes the problem, but I can't get the context in RecyclerView.Adapter class May 21 09:33:31 well, I'll just put 1000 as width, calculate height by aspect ratio and I'm done May 21 09:33:33 :D May 21 09:33:41 2 May 21 09:34:13 hi gang May 21 09:39:30 hi May 21 09:39:38 sup Tim241 ? May 21 09:39:47 Tim241: doing anything interesting and or imporatnt tonight? May 21 09:39:54 who of you can programm? May 21 09:46:22 Nobody here, really May 21 09:49:06 Tim241: I get by May 21 09:49:19 ok May 21 09:49:24 Tim241: I havea piece of paper too May 21 11:21:25 Hello May 21 11:55:43 hello May 21 11:55:57 I'm developing a VPN client for my own protocol May 21 11:56:01 and everything works just fine May 21 11:56:06 however, I'm having performance problems May 21 11:56:10 getting 250-300 kb/s at most May 21 11:56:34 I believe this might have to do with the fact that FileInputStream always returns from read(), and never blocks May 21 11:56:50 and so I have to check if it returned 0, and wait for a bit to avoid busy looping etc. May 21 11:57:24 is there a way to make reading from the tun interface block until there's an actual packet May 21 12:02:09 anyone? May 21 12:05:42 fileinputstream? May 21 12:05:59 well socket's inputstream.read() would block May 21 12:06:33 might want to ask that in java too since its not strictly android related May 21 12:06:43 ##java May 21 12:07:29 oh, never mind, I did setBlocking(true) on the builder May 21 12:07:53 Ashiren, the fileinputstream I create from the file descriptor vpnservice gives me May 21 12:20:11 so after a few tests I realized that other VPN apps hit the same speed limit too(200-300 kb/s) May 21 12:20:19 I guess that means it's an Android sort of limitation May 21 12:20:21 sad May 21 12:27:40 or its your vpn provider ;) May 21 12:37:25 danijoo_, I use my VPS May 21 12:37:44 well, maybe it's the tun device on my VPS, but idk May 21 12:38:23 actually, it can't be because I get much faster speeds(close to saturating my connection) on my desktop so yeah, it must be Android May 21 13:05:35 Hello May 21 13:06:28 I was using Apache's HttpClient before. But now that it is deprecated, how could I send & receive json objects easily? May 21 13:06:53 Is android's volley library suitable for implementing REST apis? May 21 13:09:56 hello? May 21 13:14:50 I've heard of RetroFit for calling REST APIs, but I'm far from being an expert May 21 13:15:32 retrofit sure May 21 13:17:42 So volley is old? May 21 13:18:45 it doesn't get much development from what I've followed, and I hate networkimageview May 21 13:30:01 Yeah Volley is old. Use OkHttp or Retrofit if you want something higher level May 21 13:43:58 im getting tihs error: Attempt to invoke virtual method JSONArray JSONObject.getJSONArray(tring) on a null object reference May 21 13:44:06 http://ideone.com/qH5f1N for this code, can anyone tell me why? May 21 13:48:30 pretty evident that the jsonObject is null and when you try to call getJSONArray on a null object it blows up May 21 13:49:23 Ah yes, i believe bcos the json array im looking for is this json.getJSONArray("EventList"); May 21 13:50:04 however, my JSON output doesnt go [ "EventList" { "id":... etc May 21 13:50:17 it just goes straight from [{"id":... May 21 13:50:33 is there a way to add the "EventList", azgul ? May 21 13:51:29 Ah wait think ive got it May 21 13:53:04 Ah no, that wasnt it haah May 21 14:00:37 anyone know how i can fix it? May 21 15:12:54 looks like you are trying to parse a json array as a json object then May 21 15:19:38 oh, aha, oops forgot to mention. thats solved. in the end i put the wrong url to my json output May 21 15:19:39 ahah May 21 15:19:46 classic typo May 21 15:32:27 * dofidum is getting confused implementing View's onMeasure function... May 21 15:42:16 Some days ago someone asked what people inhere used for logging. Anything cool surfaced from that? Or is everyone using a combination of logcat and a homemade logger? May 21 15:42:48 I use https://github.com/JakeWharton/timber May 21 15:43:39 God dammit, yet another Jake Wharton library :). I didnt know about timber, will check it out, thanks May 21 15:45:09 ^_^ May 21 16:04:47 does the firebase stuff have anything like remote logging ? May 21 16:10:50 g00s, http://giphy.com/gifs/xT9DPl04nNfIDClaLu/html5 May 21 16:10:52 xd May 21 16:10:55 soon(tm) May 21 16:45:45 wasn't there a session on Transitions late Friday? i can't find it ... May 21 16:45:49 I know this isn't the right place to ask, but does anyone know if the frames in a GIF can have transparency? I am extracting frames from a GIF on android and saving them and I want to know if I can always save them as a JPG May 21 16:48:38 gif can has transparent May 21 16:50:24 Ashiren, reading up on it now. I'm not sure if each frame can have transparency or how I could determine that without looping through each pixel May 21 16:51:55 surf2b1 does each frame have its own palette table ? May 21 17:18:51 when I go to install my app it now says "prevents app from sleeping" except i never added a feature like this.. anyone know how to stop this? May 21 17:19:00 Hi! May 21 17:20:03 thornekey maybe some library added it to manifest May 21 17:20:15 Hm May 21 17:20:51 am only using Google Admob and facebook api May 21 17:21:06 no WAKE_LOCK? May 21 17:21:21 haha, Fb - all bets are off :) May 21 17:21:41 nope, Ashiren May 21 17:21:48 g00s, so facebook api is doing it? May 21 17:22:05 no idea, wouldn't be surprised though, fb stuff is usually shit May 21 17:22:24 hahah XD am just using it for the login May 21 17:22:51 how can I generate an ECDSA public keypair in android? any pertinent library? i'm trying to use spongycastle but it is not working out as seen here https://stackoverflow.com/questions/37344128/how-to-generate-same-type-of-ecdsa-keypair-in-java-as-generated-by-openssl May 21 17:23:05 The new Android Studio allows you to find what library added what permission May 21 17:23:54 thornekey: ^ May 21 17:24:52 oh, nice, how do i find that info? gradle? May 21 17:26:03 thornekey: the new Android Studio has a manifest analyser tool announced at I/O May 21 17:26:14 thornekey: so you'll need to be on AS Canary May 21 17:26:31 ok cool, ill update now :) thanks for ur info May 21 17:30:06 2b || !2b May 21 17:31:03 that is the question! May 21 17:34:27 anyone who is using roughike's bottom bar know how i can make it so that when i go back to the activity that the bar is in i can set which tab it starts on? May 21 17:35:17 thornekey you probably have to manage all that state yourself May 21 17:35:23 nope May 21 17:35:25 just found it May 21 17:35:30 mBottomBar.setDefaultTabPosition(0); May 21 17:35:32 :) May 21 17:35:43 well, thats only a part of it ... May 21 17:36:33 thats all i needed i meant May 21 17:36:40 not the when i go back bit May 21 17:51:49 do any of you guys use firebase? May 21 17:54:50 hello everyone :) it's me again, I've a problem with a recyclerView, https://gist.github.com/alex88/04a5a00c7b25ed7dd9b3de7e72d367cf this is my activity May 21 17:55:20 basically, when I tap on an item, the id and contents of that item are different than the id and contents of the item shown by the list view May 21 17:55:51 pfn, Mark Murphy updates his book continuously May 21 17:55:54 for example, I see "foo" in the title, when I tap on that item it gives me an element with an id which title is "bar" May 21 17:59:56 is it getting the correct card position? May 21 18:16:16 Ashiren: I think so, let me double check May 21 18:18:39 Ashiren: found the problem, the label was picking up the wrong value :/ May 21 18:18:41 sry May 21 18:26:12 Can I get okhttp to call one of my functions whenever it creates a socket? May 21 18:26:35 I guess you can use a socketfactory May 21 18:28:39 I have a horizontal scroll view that is being used as a selector with a pin in the middle. I would like the list to be able to scroll so that the first index spot, and list index spots can both reach the center. ANy tips? May 21 18:39:41 Ologn, not the physical book May 21 18:50:30 I have a query with the documentation on https://developers.google.com/android/reference/com/google/android/gms/auth/api/signin/GoogleSignInApi#constant-summary May 21 18:50:30 silentSignIn method says that "If you use the ID token expiry time to determine your session lifetime, you should retrieve a refreshed ID token, by calling silentSignIn prior to each API call to your application server. " Can someone please help me in understanding how to get the new token? In my case I always get expired token(i.e., the cached token) May 21 19:04:20 when i load an activity and then hit back to go back to the previous activity does it clsoe the one i was in? as in finish() May 21 19:05:38 yes. it will finish() May 21 19:06:37 cool, thanks :) May 21 19:10:04 hi all, im following a tut to write a simple slack bot and am trying to run it via node bin/bot.js May 21 19:10:16 Currently, the cursor just goes to a new line and has just been blinking May 21 19:10:28 should i expect a stacktrace somewhere or...? Whats going on? May 21 19:10:48 fucks sake May 21 19:10:50 wrong channel May 21 19:12:45 sort of offtopic, rxjava: i'm trying to iterate over time using this construct http://stackoverflow.com/a/31827109 May 21 19:15:30 the case is that repeatWhen would pass down the source, and the incremented date would be given after takeUntil and then i can do further operations May 21 19:16:46 how can i get events from the 'further operations' to the outer subscriber? May 21 19:17:09 or, is there any other way to do such a thing? May 21 19:17:16 guys ever heard of http://www.skillclub.io/topic/android? May 21 19:17:26 cool site May 21 19:26:57 im working in a Fragment class rn, and within that a getView method. Im populating a listview from that. And im trying to access onClick to start another fragment May 21 19:27:11 can you get normal android attributes from a attribute TypedArray in a custom View :S? May 21 19:27:23 however it doesnt seem to like getSupportFragmentManager May 21 19:41:05 thornekey, onClick? May 21 19:42:08 bitkiller, http://pastebin.com/fgamG8Wa May 21 19:46:39 How do you deal with deprecated methods that don't have a Compat thingy? Do you make your own, so you don't use the deprecated stuff? May 21 19:47:21 Depends on why they were deprecated. May 21 19:47:25 Which are you talking about? May 21 19:47:42 thornekey, what do you expect? what is the view of the onClick? if you expect to click a listview item and do something then you have to use onItemClick May 21 19:48:29 unless you are assigning the listener to an item's internal view May 21 19:48:52 Mavrik: https://developer.android.com/reference/android/net/ConnectivityManager.html getAllNetworkInfo and friends May 21 19:49:08 Some context, I need it to force stuff through WiFi May 21 19:51:18 Ah, yeah make your own compat. May 21 19:51:31 Since the new methods aren't available obviously May 21 19:53:50 Mavrik: ideally google would make it May 21 19:54:14 Ideally Google would write the whole app for us. May 21 19:54:22 But until then you'll manage an if statement :P May 21 19:55:00 Mavrik: I mean, this is part of Android May 21 19:55:07 why would you want someone else to do for you what you love to do yourself?? May 21 19:55:18 I don't love doing tbis May 21 19:55:20 this May 21 19:55:28 weird... May 21 19:55:38 maybe it's just me May 21 19:55:48 I don't think many people consider writing wrapper functions around OSs fun May 21 19:56:10 oh come on, that's trivial, and I wasn't talking bout that May 21 19:56:21 I was replying to Mavrik's whole app thing May 21 19:56:25 ah May 21 19:56:28 yes, that I like doing May 21 19:56:31 I dont May 21 19:56:44 like wrestling with a somewhat poorly designed OS :) May 21 19:57:32 it's the nature of the concept "OS" that makes it impossible to design well May 21 19:58:07 It's easy to do stuff better, but it takes more work. Writing a complete ConnectivityManagerCompat would make the experience better May 21 20:03:00 did once a wrapper for pkcs11 with an fsm, man it was fun May 21 20:03:12 Your complaining here is actually more text that the shim would be lines of code -_- May 21 20:03:28 Mavrik: doubt it May 21 20:03:28 adq, fsm? May 21 20:03:31 i believe most ppl writing wrappers find it fun May 21 20:03:59 Also, I don't have to maintain my IRC messages :) May 21 20:04:40 autrilla, lucky you! May 21 20:26:19 Mavrik, finite-state machine May 21 20:27:21 doh May 21 21:02:30 cyource: due to the advanced linting mechanism in Studio, I no longer recommend IDEA + Android plugin over AS May 21 21:03:02 spudowiar Common May 21 21:03:17 *come on May 21 21:03:58 ? May 21 21:03:59 spudowiar Now I have to get Android Studio again. May 21 21:04:06 Lol May 21 21:04:11 cyource: slow internet? May 21 21:04:25 * spudowiar sits back and downloads at over 50Mbps May 21 21:04:28 :) May 21 21:04:38 spudowiar No, not at all. Fibre optic all the way. May 21 21:06:16 cyource: then it'll take about 20 seconds to download May 21 21:06:21 cyource: and unpack May 21 21:07:21 spudowiar, yea, it's just that I CBA now. Maybe post-June10th May 21 21:18:36 Shouldn't calling unregisterReceiver from the receiver itself unregister it? May 21 21:20:27 what to do when someone "failed" to convert an optimus g (E977 instead of E975) into a nexus 4 and asks for your help? it will only boot 4.2 nexus 4 ROMs, it's volume buttons and gyro are reversed, back camera and possibly modem not working. I never used a non nexus before, sorry if I'm being a little too noob here. May 21 21:20:28 oops, never mind May 21 21:26:25 yangm, not the place for this May 21 21:26:29 try #android-root or #android May 21 21:26:32 yangm, try #android-root May 21 21:29:28 right May 21 21:29:50 This question may be a bit off-topic but: How do I make a simple REST service for my Android app? I want something written in Java that uses json over https. I've found this which seems doable, but what if I want to deploy on a could service? http://crunchify.com/how-to-build-restful-service-with-java-using-jax-rs-and-jersey/ May 21 21:30:49 Zta, look up dropwizard May 21 21:31:59 thanks May 21 21:33:00 use appengine May 21 21:33:01 Can it deploy to e.g. Google AppEngine? May 21 21:34:14 hi, i'm cross compiling using command: arm-linux-androideabi-gcc -static hello.c -o hello May 21 21:34:40 it errors saying fatal error: stdio.h: No such file or directory May 21 21:35:18 Zta, I don't know, dropwizard just runs its own jetty process to host itself on May 21 21:36:19 I don't use third party hosting services either, I just host it myself -.- May 21 21:37:15 Zharf: That's what I was planning to begin with, but while typing the question I though "Why not go cloud crazy!!". May 21 21:37:23 Thanks anyway, I'll look into drop wizard May 21 21:37:49 dropwizard is great if you plan on hosting it yourself at least May 21 21:37:58 no need to do complicated server setups May 21 21:38:06 just do some java code and run with java -jar May 21 21:39:11 Zta: arent you the guy that posted this on /r/androiddev May 21 21:42:13 bytefire: the NDK doesn't have those headers May 21 21:42:45 bytefire: or maybe it does, IIRC it didn't tho May 21 21:43:24 it does May 21 21:43:43 bytefire, your command is likely missing some weird flags May 21 21:44:46 orbyt_: I don't think so! May 21 21:47:15 spudowiar: Zharf: turns out i was using wrong compiler. using arm-linux-gnueabi-gcc instead compiles alright May 21 21:47:35 yep May 21 21:47:40 NDK indeed does have stdio.h :D May 21 21:47:53 would be kinda useless without that ;) May 21 21:48:20 yeah May 21 21:48:38 bytefire: ah May 21 21:49:12 Mavrik: yeah I too was thinking about the Android ABI, not the GNU one May 21 22:39:37 what's the "right" way to configure something like a backend endpoint in an android app? May 21 22:39:55 to use something in development, something else in production etc? May 21 23:19:33 someone ever tried to connect a wear emulator to an android emulator? May 21 23:19:45 I've tried this way http://stackoverflow.com/a/25506889/690839 but nothing, still connecting May 21 23:23:38 nvm now it works May 21 23:28:27 anyway, examples on google shows that for wear devices they create the notification in the app, but what happens when the notification is sent from outside? should I intercept it? May 21 23:32:09 https://imgur.com/XehqML8 I cloned a git repository and when I try to compile it, I get 2400+ errors. May 21 23:32:47 Why is that? May 21 23:33:00 because it has 2400 errors :) May 21 23:33:08 It downloaded all libraries and files May 22 00:05:42 hey, curious if anyone knows a good digital signature library. May 22 00:06:02 for people to write there signature in using their fingers/stilus May 22 00:35:16 Question: Why is this: https://photos.google.com/share/AF1QipPVYAcYeBGUCOYEsBlbKQQt7S42B6g2nItdrp1pHUvNzdM_8Wm6YABm7msNCNyc1A?key=djFTU2NkUXNjcUtyUXdpbGdla2NhYm5xQ0ZzdEZB showing up when I'm connected to Wifi and attempting to connect to a direct device? May 22 00:35:48 because wifi direct takes over your connection May 22 00:36:03 can only be connected to one ssid at a tune May 22 00:37:06 But why can my Nexus 6p be connected to wifi and a direct device? May 22 00:37:45 pfn, ^ May 22 00:39:29 can it? May 22 00:39:33 Yes May 22 00:39:47 At least when I connect to the direct device, that message doesn't pop up May 22 00:40:10 oem does that then May 22 00:40:30 Why would an OEM do that? May 22 00:41:30 mrkirby153 wild guess, maybe their radio doesn't have the resources to do both May 22 00:41:43 Moto G 2nd edition May 22 00:41:50 But a ZTE speed could do both May 22 00:42:14 maybe it has to do with the chipset they used May 22 00:42:42 Any way to wirelessly debug while being connected to a direct device? May 22 00:42:54 Or do I have to join the direct network? May 22 00:43:09 I'm pretty sure 6p won't connect to wifi ap and ad-hoc at the same time May 22 00:44:36 I may be wrong, I'll test again May 22 00:45:06 lol buns.setOnClickListener( v-> v.setLegsStraight()) http://i.imgur.com/dHq9L4h.gifv May 22 00:57:23 pfn, It does May 22 00:58:03 Just tried it. Could connect over adb to my 6p while it was connected to a direct device May 22 01:05:55 and you're connected to adb by wifi? May 22 01:07:06 pfn, yes May 22 01:10:50 * pfn shrugs May 22 01:11:14 Maybe it can do simultaneous if 5ghz and 2.4 May 22 01:11:41 but I don't recall ever going direct without disconnecting May 22 01:15:54 then again, I rarely use it May 22 01:28:04 Say i have a bunch of drawables and want to get the drawable whose filename matches a string. Is the best way to do this a switch case? May 22 01:28:33 like can i do something that would equate to getResources.getDrawable(R.id. + string); May 22 01:28:40 ^obviously that is not valid code May 22 01:29:10 the string is always the filename May 22 02:08:32 I have a query with the documentation on https://developers.google.com/android/reference/com/google/android/gms/auth/api/signin/GoogleSignInApi#constant-summary May 22 02:08:32 silentSignIn method says that "If you use the ID token expiry time to determine your session lifetime, you should retrieve a refreshed ID token, by calling silentSignIn prior to each API call to your application server. " Can someone please help me in understanding how to get the new token? In my case I always get expired token(i.e., the cached token) May 22 02:15:35 Hi, I am trying to get my app to have variouis splash screen sizes for different devices. But for some reason when I reference @midmap/splashtest it is always selecting the mdpi image on all devices. May 22 02:15:44 What gives ? May 22 02:19:11 NeoFrontier just get rid of the splash screen, problem solved May 22 02:19:40 I am in love with my splash screen. May 22 02:19:47 I never get rid of it. May 22 02:20:03 are your users tho? ;) May 22 02:20:11 problem #2 : being emotionally attached to your code May 22 02:20:26 why is that a problem May 22 02:20:26 i love my code May 22 02:20:39 like, love love my code May 22 02:20:45 :/ May 22 02:21:03 lol May 22 02:21:09 guys guys. May 22 02:23:28 bit off topic but any desk recommendations May 22 02:23:49 bed. May 22 02:23:56 do what May 22 02:46:45 this i/o playlist is tedious as hell May 22 02:46:49 https://www.youtube.com/playlist?list=PLOU2XLYxmsILe6_eGvDN3GyiodoV3qNSC May 22 02:46:55 how do i find the ones nick butcher did May 22 02:48:04 funnly looking at the mobile web track, there was lots of stuff on 'offline first' progressive web apps May 22 02:48:13 i think this will sneak up on us :D May 22 02:49:22 also , sucks that the Android Fireside was not recorded - but the other ones are there ... May 22 02:49:34 seriously bummed about that, those are the best May 22 02:50:13 I thought they said that in the end pretty much everything was recorded - even the sessions that weren't billed as such May 22 02:52:13 shit, sounds like 'a window into transitions' wasn't recorded either May 22 02:52:27 Leeds i'm finding otherwise May 22 02:52:39 they already published the complete playlist ... May 22 02:57:10 possibly stuff which wasn't meant to be recorded will be published a little later May 22 02:57:58 it does sound like there were a lot of people pretty unhappy with how the event was run, and I got the impression that 'publishing all talks' was a rushed thing to make up for people not being able to get into a lot of sessions **** ENDING LOGGING AT Sun May 22 02:59:59 2016