**** BEGIN LOGGING AT Tue Feb 17 02:59:58 2015 Feb 17 03:01:08 g00s: i dunno, would have to have a play.. but i gtg.. talk more about it tomoz if you want Feb 17 03:03:42 pretty hard getting toolbar to look nice < lollipop Feb 17 03:03:48 Anyone feel like looking over an ERD I made for my app's database backend? Feb 17 03:13:34 Levite using the framelayout way, presumably with toolbar and spinner as direct children, how would i align my spinner with the toolbar actions ? Feb 17 03:14:01 i always think what i'm doing should be so easy :) Feb 17 03:14:13 the spinner is in the top row? Feb 17 03:15:08 Wouldn't the spinner still be a direct child of the toolbar? Feb 17 03:15:09 no, just wondering how i'd align it - sure it won't be perfect without work Feb 17 03:15:21 you mean align it vertically with the menu items? Feb 17 03:15:32 ooh, ok the spinner is in the toolbar Feb 17 03:15:45 and the title is just your own thing floating in the framelayout with the toolbar Feb 17 03:15:48 using the padding aproach the height stays the same so it should just work Feb 17 03:16:21 toolbar seems to act just like a linearlayout Feb 17 03:17:13 right Feb 17 03:17:34 making it a child of the toolbar positions it correctly Feb 17 03:19:48 Levite so how does one do this ? Feb 17 03:19:50 http://android-developers.blogspot.com/2014/10/material-design-on-android-checklist.html Feb 17 03:20:02 i was under the impression, that the tabs were *in* the toolbar Feb 17 03:20:50 maybe they are just sitting below it ? Feb 17 03:21:26 toolbar doesn't let you put things at the bottom of it Feb 17 03:21:47 ah good to know. now i wont wrestle with it trying :) Feb 17 03:23:40 you might take a look at this https://github.com/ksoichiro/Android-ObservableScrollView Feb 17 03:23:45 they have a viewpager example with tabs Feb 17 03:24:48 yeah, that top right one - thanks Feb 17 03:26:26 looks like they're sticking the tabs in a linearlayout Feb 17 03:26:45 i needed a tighter spacing between the toolbar content and the tabs though which is why I went in another direction Feb 17 03:26:48 Levite still looking for the file, do you have the link ? Feb 17 03:27:00 like this https://github.com/ksoichiro/Android-ObservableScrollView/blob/master/observablescrollview-samples/res/layout/activity_viewpagertab.xml Feb 17 03:27:33 ahh, ok thanks Feb 17 03:28:40 You can put stuff at the bottom of a Toolbar (e.g., see ), but it will have a gap on the left if you have a navigation icon and a gap on the right if you have a menu. Feb 17 03:28:58 So, as far as I can tell, you would need something separate underneath the Toolbar to achieve those tabs. Feb 17 03:30:11 yeah it looks crappy Feb 17 03:30:14 On a side note, I wish that guy would stop confusing it's/its, your/you're, etc. Drives me crazy. Feb 17 03:30:44 TacticalJoke: its obvious your crazy Feb 17 03:31:07 I read "has special handling for it's minimum height" as "has special handling for IT IS minimum height". Feb 17 03:33:03 sheesh, i get so confused with app:theme and whats overlaying what with this contextwrapper or that Feb 17 03:33:47 Yeah, that stuff is unnecessarily complicated, IMO. Feb 17 03:34:06 The overlay thing seems to be simply about showing pure white or pure black icons/whatever on a Toolbar. Feb 17 03:34:23 how often do the SDK tools get updated Feb 17 03:34:29 I feel neglected Feb 17 03:34:37 i haven't seen any updates in a while Feb 17 03:36:02 I think you can avoid the overlay thing entirely if you set "android:textColorPrimary" and "colorControlNormal" to a particular colour. Feb 17 03:36:17 As far as I remember, using that overlay thing simply sets those two to either white or black. Feb 17 03:36:37 What is the best UI widget to use for taking in a duration of time (for example 30 minutes). Just a EditText with input type set to number? Feb 17 03:37:00 depends on its purpose Feb 17 03:37:24 I've never tried it, but how about these: http://developer.android.com/guide/topics/ui/controls/pickers.html Feb 17 03:37:28 if it's something they'll be setting frequently a custom button dialog would be best Feb 17 03:38:54 if it's a "set occasionally" thing then a timepicker works fine Feb 17 03:38:55 i dont think the time picker allows getting rid of am/pm ... am i wrong? Feb 17 03:39:09 which would make it unsuitable for durations Feb 17 03:39:43 yeah you have to monkey with it to remove the ampm Feb 17 03:40:00 Oh. Ya, I misread the question. Feb 17 03:40:31 these things were implemented by interns maybe Feb 17 03:41:39 How about NumberPicker? Feb 17 03:41:48 http://developer.android.com/reference/android/widget/NumberPicker.html Feb 17 03:42:31 but is there an easy way to jump to an arbitrary value? Feb 17 03:42:34 Though its coupling with the current theme sounds weird. Feb 17 03:42:49 TacticalJoke: That might work. Didn't know such a widget existed. Feb 17 03:43:03 It seems to involve an EditText at some point. Feb 17 03:43:34 the app "Beautiful Timer" has one of the better duration picking controls I've seen Feb 17 03:43:36 You know what's crazy? We don't get to see the widget on those widget reference pages. Why couldn't they show it. Feb 17 03:43:40 jerkface03 what i've done in the past, kinda lame, is have logarithmic scale: 1min, 2min, 5min , 10min, 20min, 30min, 1hr ,etc in a listview Feb 17 03:43:42 I know! Feb 17 03:43:47 I always thought that was ridiculous Feb 17 03:44:00 you have to resort to Google Images Feb 17 03:44:03 Yeah. Feb 17 03:44:19 Almost every class should have an example, and every UI widget should have a screenshot. Feb 17 03:44:38 and i think each ecample in the material spec should have a xml snippet Feb 17 03:44:49 Yeah, that'd be something. Feb 17 03:44:51 the eclipse graphical xml thing lets you preview them, dunno if AS has something similar Feb 17 03:45:05 The material spec right now is "Check out this awesome design. Good luck actually implementing it". Feb 17 03:45:11 my expectations are just based on all the apis and frameworks i've used before android - they are really lacking Feb 17 03:45:20 Yeah, in AS you can even preview while typing the XML. Feb 17 03:45:39 didn't matter if it was roguewave c++ libraries, seems back in the day the docs were just amazing Feb 17 03:45:41 apple doesn't have screenshots in their docs, but they also have an awesome WYSIWYG layout builder Feb 17 03:45:45 Same here, g00s. Feb 17 03:45:56 I spent most of my development life on Windows, and documentation was always brilliant. Feb 17 03:46:01 Even for Win32 and MFC and so on. Feb 17 03:46:18 and MS Press would have plenty of authoritative books too Feb 17 03:46:32 i remember the 2 volumes of MFC i had to read X.x Feb 17 03:46:35 Yeah, like Ivor Horton. :D Feb 17 03:46:40 God, I hated MFC. Feb 17 03:46:46 Petzold, etc yeah Feb 17 03:46:59 Haha. I remember that name. Feb 17 03:47:20 I'm so glad I found Delphi when I did. Way nicer than VC++ back then. Feb 17 03:47:33 Borland never got the popularity they deserved. Feb 17 03:47:41 i remember when vc++ didn't even have templates :| Feb 17 03:47:49 for a looong time Feb 17 03:47:58 I vaguely recall that. Feb 17 03:48:02 way longer than borland Feb 17 03:48:26 but they got herb sutter, and things came around Feb 17 03:48:50 I used to be a totally loyal Borland guy. I even used Borland C++ 5, I think. Feb 17 03:48:56 i.e., not Borland C++ Builder. Feb 17 03:49:10 And it had its ugly icons and everything. :D Feb 17 03:49:24 (I mean the IDE.) Feb 17 03:49:44 i think at this point, google figures - the important apps will be by companies, maybe with android teams of 2-10 and they can tough it out with poor docs Feb 17 03:50:43 I always hated C++, though. It was just a mess. So glad there were other options (e.g., Delphi and C#). Feb 17 03:51:26 i guess on WP you can use C++, C#, and F#. iOS would be C/C++,obj-c,swift. each platform tools officially support those options Feb 17 03:51:40 android is way behind there, just java and gimped c++ via ndk Feb 17 03:51:47 c/c++ Feb 17 03:52:19 welcome to the "beta is good enough" world Feb 17 03:52:21 i'm just waiting for everything to get folded into chrome Feb 17 03:52:23 Oh, man, if we could use C#. Feb 17 03:52:27 It's not perfect, but it's so nice. Feb 17 03:52:39 i was reading about c# 6 exception filters Feb 17 03:52:41 Simplicity and power. Feb 17 03:53:14 Java is simplicity and power. C# is power. Feb 17 03:53:20 if i was doing WP i'd try F# Feb 17 03:53:24 Do you think you'd use them much, g00s? Feb 17 03:53:25 hehe Feb 17 03:53:34 To be honest, I'm not very excited about new C# features. Feb 17 03:53:38 In general. Feb 17 03:53:55 C# 6 stuff seemed like syntactic sugar, but nice things Feb 17 03:57:24 This is an interesting post by Eric Lippert about functional programming: http://stackoverflow.com/a/2835936 Feb 17 03:57:38 name sounds familiar Feb 17 03:57:54 He did a lot of work on the C# compiler, I think. Feb 17 03:59:24 Very famous guy in the ms and language world Feb 17 04:01:00 I was surprised to see him so openly anti-functional. When I used to hang around in the C# world, all of the big names were talking about how they were gonna move to F#. Feb 17 04:01:09 And how it was just a matter of time. Feb 17 04:02:06 We're slowly on the way where people recognize that functional is very, very far from the silver bullet fans have been depicting Feb 17 04:07:00 deuteros__ are there any features missing from kotlin that you wish it had ? Feb 17 04:07:25 i guess they used to have tuples but took them out :( Feb 17 04:07:51 Higher kinded types would be nice but I think they cross the threshold that makes Kotlin appealing Feb 17 04:08:59 interesting Feb 17 04:09:44 Ceylon is a better language for more advanced features like HKT, Kotlin is in a very good place as it stands Feb 17 04:10:56 deuteros__ does ceylon have a good tooling story ? Feb 17 04:17:40 "A train carrying more than 100 tankers of crude oil derailed in southern West Virginia on Monday" ... why do these thing keep happening in west virginia :|} Feb 17 04:18:07 "sending at least one tanker into the Kanawha River, igniting at least 14 " Feb 17 04:44:11 JakeWharton: I think you handled it last time, but: OkHttp has a bunch of spam wiki pages :| they're visible in the "pages" dropdown thing. Feb 17 04:44:19 ok Feb 17 04:44:21 i'll lock it Feb 17 04:45:58 groxx: fixed. thanks. <3 wiki's a git repos Feb 17 04:46:25 heh. yeah, it's a good idea :) Feb 17 05:01:48 g00s: I don't have much practical experience with Ceylon but they are developing their Eclipse plug-in in lockstep with the language, like JetBrains is doing with Kotlin, so I'm reasonably optimisti Feb 17 05:02:11 something the Typesafe people still don't know how to do Feb 17 05:17:25 Whats the best way to get the value of a clicked check box? Feb 17 05:20:40 Im guessing checkbox.getText() would work Feb 17 05:22:26 checkbox.isChecked ? Feb 17 05:22:44 would I pass a method in there? Feb 17 05:22:50 or would that return a boolean Feb 17 05:24:01 drose379 wut O.o Feb 17 05:24:09 Nevermind :) Feb 17 05:50:52 meh, when i do extended height toolbar with no child views, the title is too close to the bottom, maybe 2dp from the edge Feb 17 06:07:17 padding it Feb 17 06:07:23 s/padding/pad/ Feb 17 06:23:10 Has anyone ever had to work with Appcelerator Titanium? Is it as soul-draining as it sounds for a person experienced in native development? Feb 17 06:23:38 heh Feb 17 06:23:48 I'm pretty sure I'm about to be offered a job using that and I'm not sure whether it's even worth taking, other than that fact that it gets me into a place I want to be (geographically) Feb 17 06:24:23 Or is it something I should be able to deal with for 1-2 years until I can find a better thing? Feb 17 06:25:10 Might as well tell my recruiter up-front that I'm not interested if it's too bad. Feb 17 06:26:58 Then again, I know I could excel at the job because Javascript is fucking easy and I'd be able to work out bugs faster since I know native dev. Feb 17 06:27:19 I think the company is actually looking for someone to do Titanium who already has native experience. Worth 60K? Feb 17 06:33:24 that's for you to decide Feb 17 06:34:10 JavaDog you'l have to change your nick to TitaniumDog Feb 17 06:34:27 JavaScriptDog Feb 17 06:35:12 Let me tell you what happened today Feb 17 06:35:36 After 4 attempts to schedule an introductory interview with a company, I finally had one scheduled Feb 17 06:36:08 They included a hangouts video invite with the calendar invitation once it was confirmed. Feb 17 06:36:12 So I had that running too Feb 17 06:36:30 No call at the scheduled time. Great. Feb 17 06:36:44 Get an email saying "hey your phone was busy when I called at the scheduled time" Feb 17 06:36:49 nooooo it was not Feb 17 06:36:59 JavaDog: please take this to another channel Feb 17 06:37:13 I've gotta get it out, man. This shit kills me Feb 17 06:37:24 Get it out somewhere else? Feb 17 06:37:57 eh, fine, whatever. But you'll miss out on the ability to circlejerk about corporate america with me. Feb 17 06:38:21 Go to #java-talk, your rant will be very welcome Feb 17 06:38:38 haha, I'll keep that in mind next time I have a rant Feb 17 06:42:17 Anyone have an idea why my app closes after being in the bg for a long time? Feb 17 06:42:49 AndreYonadam: The OS does that Feb 17 06:43:33 unless it is foreground service Feb 17 06:45:59 deuteros__: Is there anyway I can keep it running Feb 17 06:46:23 I think a service can start it up again with an intent Feb 17 06:46:39 But I don't think that's a good way to do it since it could possibly interrupt what's already happening Feb 17 06:46:52 I tried to retain the state for that activities manifest Feb 17 06:46:55 *in the manifest Feb 17 06:47:17 There are ways to have the OS restart it right away and depending on the OS, to keep it running all the time. Not very recommended, thoug, it's not a friendly behavior Feb 17 06:47:52 AndreYonadam you'll have to save / restore state to be a good citizen Feb 17 06:47:54 AndreYonadam: What does your app do? Feb 17 06:48:00 deuteros__: I need to check the GPS location compared to something constantly in a listener which is currently in my activity. Feb 17 06:48:05 Do you think I can do that in a service? Feb 17 06:48:15 AndreYonadam: "constantly"? You sure about that? Sounds like a battery killer Feb 17 06:48:25 deuteros__: There is an interval Feb 17 06:48:31 Any Android Studio users getting "No Android facet found for module error"? Feb 17 06:48:40 But I still need to check it in the bg Feb 17 06:50:10 deuteros__: Do you think a service would be fit to do so? Feb 17 06:50:38 AndreYonadam: Read the Service section, the foreground part. However, I still think it's not appropriate to do this for your case Feb 17 06:52:16 Yeah I'm gonna take a look at it. I don't think there are any similar options that would give me the same solution unless I only do checks when the app is open. Feb 17 06:52:52 AndreYonadam: Also I suggest you take a strong look at the battery consumption of your app, pretty sure it would cause most users to uninstall it very quickly because of the battery drain Feb 17 06:54:42 deuteros__: Yeah. I did some research on GPS use and battery drain. I tried using the network which was extremely inaccurate. I'm going to try to give users options though. Or maybe look at ways to minimize the drain while using the gps unit. Feb 17 07:26:12 heya guys, is there a way to prevent the DrawerLayout to show the fragment view with a different animation? like i wanted the navigation drawer to fade in rather than slide from the sides. Feb 17 07:39:53 so 5.1 devices are out in the wild, but no announcement, emu images, etc ... Feb 17 07:40:24 hopefully uts not much of a change, so no announcement was warranted O.o Feb 17 07:57:58 good morning world Feb 17 08:00:25 hey lemonxah hows it going Feb 17 08:00:33 ag its going ok Feb 17 08:00:40 bored of working for this place Feb 17 08:01:28 bleh .. so i am keeping an eye out here for helping ppl and looking over stackoverflow Feb 17 08:01:34 how are you doing? Feb 17 08:02:29 hm ok. writing this nasty parser for a protocol /embedded/ in bluetooth low energy Feb 17 08:02:44 sounds like more fun than i am having :) Feb 17 08:03:09 lemonxah you can fun++ by playing with kotlin :) Feb 17 08:03:45 not for this place though that was personal project Feb 17 08:03:48 this place is super boring Feb 17 08:11:57 <_genuser_> getView(position, arg1, arg2) for BaseAdapter checks if mValues[position].endsWidth("unsupported") and sets the StrikeThru flag on a textbox. Feb 17 08:12:15 <_genuser_> odd thing is for one item, this condition isn't true and it still ends up setting the strikethru flag. Feb 17 08:12:50 <_genuser_> anybody seen this kinda odd behavior before. If I comment out the strikethru line, all strikethrus disappear so it's definitely this line causing it. Feb 17 08:13:21 _genuser_, are you reusing views? ie. convertView? Feb 17 08:13:44 you are reusing the same view as previous ones if you are using convertView Feb 17 08:13:59 and the textbox in that view will allready have the strike thru value set Feb 17 08:14:09 you have to reset all values on the textbox before setting them Feb 17 08:15:12 <_genuser_> lemonxah: I suppose so. I'm only inflating a new one is convertView is null. Feb 17 08:15:24 yes then that is the issue Feb 17 08:15:44 the first few while there is no views for the viewcontainer to re-use they will all work Feb 17 08:15:52 <_genuser_> "one", "two", "three (unsupported)", "four", "five" Feb 17 08:15:54 but as soon as the viewcontainer starts reusing views Feb 17 08:16:03 <_genuser_> and it _always_ set's the flag on item 1 and 3. Feb 17 08:16:05 then you have to reset the values Feb 17 08:16:15 please show the code Feb 17 08:16:36 there is no way to tell you whats wrong without code really just speculations Feb 17 08:16:41 <_genuser_> I think let me clear the textbox and if it doesn't fix it, I'll pastebin it. Feb 17 08:16:54 <_genuser_> yeah, you're right, without code it's just speculation. Feb 17 08:17:57 <_genuser_> first, I disable re-using views. Feb 17 08:18:08 clear the setting fo the stikeThru before you try set it Feb 17 08:18:24 <_genuser_> yep, thats was it. I'll re-enable re-using views and clear the textbox first. Feb 17 08:19:10 <_genuser_> thanks for the quick help. I was logging this and seeing that the if wasn't run and wasn't sure it was still striking thru. Feb 17 08:19:33 sure no worries Feb 17 08:20:26 glad i could help :) Feb 17 08:21:59 <_genuser_> :) Feb 17 08:43:13 its like this channel died Feb 17 08:47:09 lemonxah have you messed with rx before ? Feb 17 08:47:17 rxjava? Feb 17 08:47:22 not really Feb 17 08:47:24 yes Feb 17 08:47:50 did a little bit of reactive extensions in .net a few yeaers ago but i doubt i would be able to recall it all that well Feb 17 08:50:11 g00s, does that not have the same flaws as AsyncTask does on android? Feb 17 08:50:26 i mean if you declare the observer in that code what happens on config change? Feb 17 08:51:03 lemonxah do you remember how the async mqtt client worked ? Feb 17 08:51:19 yeah kinda Feb 17 08:51:47 they had this stupid limit, i think 10 - when you published but the client couldn't keep up it threw an exception Feb 17 08:51:52 max in flight thing Feb 17 08:51:58 yes Feb 17 08:52:25 i was trying to convince the paho guys they needed to implement something like rx backpressure , like those operators - block, drop, etc Feb 17 08:52:38 but what they have now is idiotic Feb 17 08:53:04 i haven't even used the new paho lib yet Feb 17 08:54:09 its behavior in that regard is the same Feb 17 08:56:52 so i am going to need to do a mqtt client soonish for work is there something else that you would recommend? Feb 17 08:56:55 in place of paho? Feb 17 08:58:22 not really. what will you use it for ? Feb 17 08:58:36 replacement for googles notifications Feb 17 08:58:49 replace gcm ? Feb 17 08:58:52 yeah Feb 17 08:59:19 on an operating system that doesn't have gcm Feb 17 08:59:19 hm. i dont't think you're going to be able to get it as tuned as GCM wrt power consumption Feb 17 08:59:28 oh, so not android Feb 17 08:59:31 yeah gonna try at least Feb 17 08:59:34 it is android Feb 17 08:59:39 just not with gapps Feb 17 08:59:42 oooh thats right Feb 17 09:00:04 well, fb did that but they made some modifications to the protocol Feb 17 09:00:41 yeah i might do the same thing but i didn't want to make a new mqtt client straight away while testing and playing with it Feb 17 09:01:25 but i might end up writing a client and server(modified) Feb 17 09:02:10 wonder if facebook opensourced their thing Feb 17 09:04:17 i dont think so Feb 17 09:05:13 lemonxah i recall they had to tune by carrier also, each one had different tcpip idle drop Feb 17 09:05:39 fun days ahead Feb 17 09:05:48 i dont mind struggling to get stuff done when its interesting Feb 17 09:42:27 Morning All Feb 17 09:45:49 hi Feb 17 09:46:03 how can we be of assistance Feb 17 09:46:52 lemonxah: are you asking me? Feb 17 09:47:13 yeah Feb 17 09:47:15 I'm here every day ;) Feb 17 09:47:22 was just making sure ") Feb 17 09:47:29 cause i am bored .. hehe Feb 17 09:47:41 if I come across anything I'll let you know :p Feb 17 10:02:04 lol Feb 17 10:03:07 ? Feb 17 10:05:17 Anyone familiar with using downloadManager.request addRequestHeader? My main goal is to like request.addRequestHeader("If-Modified-Since", dateFormat.format(file.lastModified())); to check if file had been modified since a date Feb 17 10:05:57 Unsure what to do at this point if anyone has some docs or example for what I am trying to accomplish Feb 17 10:20:58 Hi , I am Using openCV to detect people in a image , but it detect face only when someone is watching the camera , can i detect people who are not watching to camera as well as people , I want to count people in a image Feb 17 10:23:27 hi all, my accelerometer z axis is off by factor -1, how do i fix this? Feb 17 11:17:01 Hi all, is it possible to use a PagerTitleStrip for 'fixed' tabs? Feb 17 11:17:50 should be able to Feb 17 11:18:02 having a "fixed" array Feb 17 11:18:52 lemonxah, there not fixed if I use something like this http://developer.android.com/training/implementing-navigation/lateral.html#PagerTitleStrip for only 2 tabs Feb 17 11:19:22 what do you mean fixed? as in fixed length and order? Feb 17 11:19:27 or fixed as in they look like tabs? Feb 17 11:20:25 fixed like this: http://material-design.storage.googleapis.com/publish/v_2/material_ext_publish/0Bx4BSt6jniD7bVBGcHYzNWtPT00/components_tabs_usage_mobile1.png Feb 17 11:21:42 those are tabs yeah .. i dont think you would be able to do that no Feb 17 11:22:20 there is a tabstrip that kind of works like that Feb 17 11:22:26 and it will move along with more Feb 17 11:22:56 like if there are 4 it will show the first 3 like that but then scrolling to the right you will only see the forth one once you hit the the third one Feb 17 11:24:05 trying to remember the library name ... Feb 17 11:25:32 FrancescoV, https://www.youtube.com/watch?v=Uywh_BBikY4 that is what it worked like Feb 17 11:25:37 that is what i used for it Feb 17 11:25:42 i mean i used it for Feb 17 11:26:59 Thanks! Feb 17 11:28:03 is that what you are looking for ? Feb 17 11:30:52 oh FrancescoV the thing i used wasn't a title strip it was sliding tabs :( soz .. http://www.pushing-pixels.org/2013/05/09/android-bits-and-pieces-sliding-tabs-madness.html Feb 17 11:31:56 hey, is there any way to force a generic param to be an interface. Feb 17 11:32:18 im getting “interface expected here” when trying to use a generic Feb 17 11:33:11 lemonxah: it helped me but it's for a little demo app, maybe there will be more than 2 taps and sliding tabs will be great Feb 17 11:33:27 ok cool Feb 17 11:33:54 samskiter, show the code please :) pastebin Feb 17 11:36:45 lemonxah: http://pastebin.com/Tkd4Dbsd Feb 17 11:36:57 i get “interface expected here” on “Listener” ? Feb 17 11:37:12 so how do i restrict “Listener” appropriately Feb 17 11:39:20 there shouldn't be anything there samskiter Feb 17 11:39:24 its a static method Feb 17 11:39:45 evening Feb 17 11:39:49 Hi guys Feb 17 11:39:54 lemonxah: the static isn’t the problem Feb 17 11:40:16 Can you recommend me any database library to develop easy and faster all local database stuff? Feb 17 11:40:18 i need to restrict my “Listener” generic to be an interface Feb 17 11:40:25 yeah but there shouldn't go anything in there you are not using the type in that example that you gave Feb 17 11:40:44 How to make a bitmap serializable? Feb 17 11:40:47 I found this Feb 17 11:40:48 http://stackoverflow.com/questions/5871482/serializing-and-de-serializing-android-graphics-bitmap-in-java Feb 17 11:40:50 lemonxah: so how do i stop the error “interface expected here” on line 3 Feb 17 11:40:52 but how to use it? Feb 17 11:41:45 lemonxah: the param after the ‘&’ must be an interface. so my [WHAT GOES HERE?] needs to restrict listener to be an interface. surely this is possible? Feb 17 11:43:02 samskiter, it needs to be an interface int he bounded type parameters Feb 17 11:43:10 concrete types and interfaces Feb 17 11:43:24 so Feb 17 11:43:36 the Interface you specify there cant be a generic type Feb 17 11:43:43 as i understand it Feb 17 11:43:47 but let me test this Feb 17 11:44:08 i've got a button defined in my xml fragment. The fragment is loaded from a Fragment class myFragment. How can I define a button.onClick() to direct to a method in the myFragment class rather than a class in MainActivity? Feb 17 11:44:39 I tried setting the tools:context to ".myFragment" but that didn't do it Feb 17 11:46:42 oh, I have to overwrite the onClickListener? Feb 17 11:46:51 yes samskiter you cant have a generic type in the bounded type params Feb 17 11:47:40 lemonxah: thanks. that’s crappy Feb 17 11:47:59 not really you just have to change the design a bit Feb 17 11:48:16 just use a base listener interface which others extend Feb 17 11:50:33 lemonxah: that won’t really give me what I want. Want to make sure than an activity instantiating this object implements and interface Feb 17 11:50:36 crappy doo Feb 17 12:00:27 Hey Feb 17 12:00:32 hi Feb 17 12:01:28 If I wanted to capture all http data sent/received by facebook messenger on an android device, what would be the simplest way to accomplish that? I have the emulator up and running at the moment and I noticed the tcpdump option which is great, but I don't seem to have access to the play store and I don't wanna download a random .apk from somewhere. Feb 17 12:02:13 there are a few genymotion emulaters with gapps installed Feb 17 12:02:17 you could use one of those Feb 17 12:02:43 thanks Feb 17 12:02:45 ^ Feb 17 12:57:38 In downloadManager request addRequestHeader("If-Modified-Since", dateFormat.format(file.lastModified())); Feb 17 12:57:43 how to catch the response Feb 17 13:00:18 gn8 Feb 17 13:17:15 Hey guys, did anyone actually succeed in making MediaPlayer and MediaRecorder work simultaneously? Feb 17 13:17:48 I tried setting the audiosource: MIC - didn't work Feb 17 13:18:17 tried without setting the audiosource - didn't work Feb 17 13:18:28 the thing that doesn't work is MediaPlayer Feb 17 13:36:31 would using generic playing-card graphics be targeted by google's strike policy? Feb 17 13:43:34 what are generic playing card graphics? Feb 17 13:43:45 i bet 99% of the graphics for playing cards are somehow copyrighted Feb 17 13:47:23 generic's probably the wrong word, something from opengameart.org Feb 17 13:50:26 Hey guys, have anyone actually succeed in making MediaPlayer and MediaRecorder work simultaneously? Feb 17 13:50:34 maybe from the different processes? Feb 17 13:52:34 Tbone139, if you dont infridge some rights, it should be ok Feb 17 13:52:44 but you never know what the ban-algorithms do :p Feb 17 13:55:34 I have a bad feeling it runs an image-search across all uploaded games without discretion, maybe I'll tweak it a little Feb 17 13:55:35 thanks Feb 17 13:56:03 noboy knows ^^ Feb 17 14:04:50 i am using AsyncTask to get data from web and save it in DB.. there is null pointer exception in this code but i cannot apply try and catch or add any clouse in method. so what can i do now ? here is the code http://paste.ubuntu.com/10273709/ Feb 17 14:08:01 s9iper1: why can't you use try/catch block? Feb 17 14:08:37 also you could check for null before calling a method Feb 17 14:10:33 corentin, when i click on it it doesnt give me a option to add try catch block. Feb 17 14:11:47 s9iper1: why not checking for null before calling a method on the variable which triggers the null pointer exception Feb 17 14:12:14 s9iper1: also you might want to return from the method when a catch block is entered Feb 17 14:13:14 ok Feb 17 14:38:24 Hi everyone, I'm trying to keep this kind of layout http://fr.tinypic.com/view.php?pic=fokjvd&s=8 in landscape mode but I get this instead http://fr.tinypic.com/view.php?pic=2j2g6f7&s=8 Feb 17 14:38:31 any advice on how I should do this ? Feb 17 14:42:02 Ok nvm I did it :) Feb 17 14:47:52 can somebody show me json array request post params with volley ? Feb 17 14:48:09 anyone has a working example ? i tried everything on the web Feb 17 14:52:31 JakeWharton: are you still using mortar and flow? Feb 17 14:55:57 Is there a way to get this autocorrection away? http://i.imgur.com/bo48fcF.png Feb 17 14:56:32 there's inputType textNoSuggestions but that hides all suggestions as it says Feb 17 15:01:03 i have a problem with android studio its just appear now. logcat is comming off and on and when i compile the code android studio is not sending apk to mobile and i have seen this error E/android.os.Debug﹕ failed to load memtrack module: -2 Feb 17 15:01:14 Couldn't load memtrack module (No such file or directory) Feb 17 15:12:09 does support toolbar have elevation by default on lolipop? Feb 17 15:16:17 mrpyo, why dont u test it? Feb 17 15:17:36 don't have lolipop device, and my computer is too crappy to run emulator... Feb 17 15:27:57 i think it is. not sure though Feb 17 15:35:50 So I was told to put my sqlite database in my assets folder. So I created a new folder called 'assets' in 'src/main' and made a 'databases' folder in the assets folder. Am I doing things right? Feb 17 15:39:39 hi there Feb 17 15:42:11 Hi ^^ Feb 17 15:44:22 I have a sort of conceptual question how I could implement an idea. Feb 17 15:45:25 I want to make some kind of app for a field trip. Now I though about displaying content defined in a level description file (some xml document) which my app downloads beforehand. Feb 17 15:46:26 my level activity would then parse the downloaded xml file, and in onCreate() it would dynamically create the view elements (textviews, imageviews, buttons) Feb 17 15:48:03 How could I implement some sort of "navigation"? For example, a button labeled "next stop" or something should display new content... my idea so far would be to start the same activity with an intent once more. I would put some "page identifier" in the intent extra and in onCreate() i would specifically only parse what matches this "page identifier" Feb 17 15:48:56 but this additional activity gets added on the activity stack, and somehow this whole idea doesn't feel quite right... has someone a different idea how to approach this? Feb 17 15:49:10 JakeWharton - Apologies for the potentially moronic question. When using a TabPageIndicator and applying a style to it, is there a way to stop the truncation of the title text within the indicator? It is currently cutting off long titles and elipsizing (if that is a word) them. Feb 17 15:56:57 cetchmoh: I tend to just update the info on the same activity instead of starting a new intent. :) Feb 17 15:57:26 Kake_Fisk: uh... right... but... Feb 17 15:57:55 Kake_Fisk: I would have to somehow destroy my views Feb 17 15:58:04 Kake_Fisk: then parse, then create new view elements Feb 17 15:58:43 Kake_Fisk: I wouldnt know how to destroy my currently active views... any pointer? Feb 17 15:59:00 cetchmoh, why dont u update them instead of destroy them? Feb 17 16:00:01 danijoo: example - "page 1" has some multiple choice question, requiring 4 buttons (answer options). if the user selects the correct answer, the next page would present a different question, requiring an input textbox and just 1 button Feb 17 16:00:29 this sound like a usecase for fragmentpager if you ask me Feb 17 16:00:45 ahhh... finally something new I can read about ;) Feb 17 16:01:16 cetchmoh, it lets you define "pages" and you can go from one page to another Feb 17 16:01:39 sounds just like my use case ;) Feb 17 16:03:56 might require lots of reading if you are new to android though. Feb 17 16:04:13 You need ViewPager, Adapters, Fragments... Feb 17 16:04:41 I just finished the udacity course on android development... but I can handle some reading ;) Feb 17 16:04:58 you need it anyways sooner or later :p Feb 17 16:05:06 good point :D Feb 17 16:12:21 How do I use this statement in my code "import android.content.pm.PackageParser;"? You have to be a system app to use that (I think) and so I'm guessing that PackageParser is left out of the SDK? Feb 17 16:16:21 reflection Feb 17 16:16:26 is how you use it Feb 17 16:16:38 but not recommended Feb 17 16:18:11 ah, ok. I am testing different methods of installing side-loaded apks. Feb 17 16:18:58 you cannot side load apk without the permission prompt Feb 17 16:19:00 period Feb 17 16:19:07 not without adb Feb 17 16:19:14 I signed my app with the platform key Feb 17 16:19:38 I control and build the hardware Feb 17 16:19:40 Ok, platform signed app is different story Feb 17 16:27:28 in that case, though, you should be building in the android tree and have access to all the private api Feb 17 16:30:21 I came up with another method that we're going to use: We use a thin shell of an app that is never updated. It downloads a dexed jar containing our real application. We use reflection to start from a known entrypoint. That jar is capable of downloading a new version of itself. Feb 17 16:31:58 We include a working jar inside the assets for the shell for the first run. We also start a background service that periodically checks a URL specific to each device allowing us to provide an IfAllElseFails.jar Feb 17 16:34:17 the advantage is that it allows us to kind of mirror our current embedded linux pattern where we have "currrent" and "previous" versions of the app and can detect if an upgrade is bad and rollback easily Feb 17 16:37:25 I parse a JSON file at the start of my application and create an arraylist from the parsed data. Now i want that arraylist to be available globally as long as the application exist. First I thought of creating object of class which extends Application through ApplicationContext and dump my data in that class through the use of getters and setters but still there is no guarantee that the... Feb 17 16:37:26 ...data will be available and i have to check for NPE. What is the simple way to this? Feb 17 16:38:51 pget, if you get the data *every* time the app starts you can be sure its not null Feb 17 16:39:07 because if app is destroyed and it gets null, it gets recreated then Feb 17 16:43:27 If I am working in a class and I pass ClassName.this to a listening actiivty, will it get an instance of the current class, or a new instance of the class? Feb 17 16:43:52 how do you pass it? Feb 17 16:44:01 ClassName.this Feb 17 16:44:08 through a bundle? Feb 17 16:44:12 danijoo does ApplicationContext guarantee that the data will not be destroyed if app is running low on memory? Feb 17 16:44:21 pget, no Feb 17 16:44:28 it can be destroyed Feb 17 16:44:34 recreate it if app restarts Feb 17 16:44:35 Just passed it though a method Feb 17 16:44:54 drose379, then its the same. like it would be in normal java Feb 17 16:45:16 So it will have all the current fields and everything? not a new instance? Feb 17 16:45:51 why should it be a new instance if you pass it through a methid> Feb 17 16:45:53 method Feb 17 16:46:06 Just making sure Feb 17 16:46:33 btw you can test it with a toString() Feb 17 16:47:02 The class instance? Feb 17 16:47:03 danijoo what if app is not restarted and data is destroyed implicitly through garbage collection? Feb 17 16:47:20 drose379, yeah. Feb 17 16:48:07 danijoo thats why i have to check for NPE Feb 17 16:48:12 pget, I dont understand. There are 2 possibilities after app is paused. a) it just resumes (everything will be available) and b) app gets recreated (make sure to recreate all data in this case) Feb 17 16:48:26 danijoo_ what would it show? Feb 17 16:48:29 as a string Feb 17 16:50:12 a unique id. if the object would be something else, it has another id Feb 17 16:50:19 danijoo why would the app be paused? Are you saying the app pauses if garbage collector kicks in? Feb 17 16:50:21 Ah ok, thanks Feb 17 16:50:38 pget, no. but if user pressed the home button Feb 17 16:50:58 to quickly check his whatsapp or whatever Feb 17 16:51:31 danijoo_ can you take a look at a tiny bit of code for me? Feb 17 16:51:43 sure Feb 17 16:52:20 danijoo that's a completely different scenario. What I am simply asking is how can i make my arraylist globally available throughout the life of application? Feb 17 16:52:39 danijoo_ would this be the proper way to copy one array to another? http://pastie.org/9957172 Feb 17 16:53:09 pget, I just got here, but one answer to your last question would be to put it in an Application class Feb 17 16:54:52 drose379, this works. but there is also System.arraycopy(...) that does that for you ;) Feb 17 16:55:02 :D Feb 17 16:55:08 Thanks haha Feb 17 16:55:26 yw :) Feb 17 16:55:26 MikeWallaceDev i just explained that in my earlier question. There is a possibility that the data will not be available if app is running low on memory. Feb 17 16:56:06 huh Feb 17 16:56:08 No, I really don't think so. Feb 17 16:56:15 pget, your data won't be garbage collected as long as it's referenced Feb 17 16:56:28 pget, if you app gets low and is destroyed, you recreate it in restart, dont u? Feb 17 16:56:38 if you woudnt, it woudnt be available in first place Feb 17 16:56:44 exactly Feb 17 16:57:29 heya folks. i'm finding myself lost and pretty frustrated picking / taking pictures and attaching them to an email. it seems everywhere i look there are different solutions posted and i can't determine which one is appropriate for my application or even which one works! Feb 17 16:57:34 I didn't look into this, but I don't see why Android would kill the Application object and not the process Feb 17 16:58:14 It doesn't. Feb 17 16:58:24 I didn't think it would... Feb 17 16:58:34 It also won't just dereference and delete things you're using. Feb 17 16:58:38 The process would be basically empty Feb 17 16:58:41 It'll kill the whole process first. Feb 17 16:58:55 That's like Java JVM deciding to just randomly delete your objects to get memory. Feb 17 16:58:55 :D Feb 17 16:58:56 right Feb 17 16:59:00 Wouldn't make sense ;) Feb 17 16:59:12 danijoo i see now where you are getting. Thanks, that solve my problem. Feb 17 17:01:38 on action_pick ... i'm aware that i pass in where the user is to pick from. in my case i am creating the intent with: new Intent(Intent.ACTION_PICK, android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI); ... I am waiting for the result... in my onActivityResult() i get the returned Uri via data.getData(), i pass that exact Uri (in an arraylist) to the email intent via i.putParce...ArrayListExtra(Intent.EXTRA_STREAM, uris) Feb 17 17:01:53 the selected photo shows up in my email, but the email often does not send. Feb 17 17:02:44 and what is the error with the email? Feb 17 17:03:23 they get stuck in the outbox Feb 17 17:04:58 MikeWallaceDev: that's the thing... i don't see an error associated with the email except a really annoying one telling me that for EXTRA_TEXT i should be putting an ArrayList instead of a string. Feb 17 17:05:08 kinda sounds more like an email problem... unless the email isn't liking the Uri Feb 17 17:05:40 so put an ArrayList instead of a String :P Feb 17 17:06:30 right, but when i put an arraylist the text doesn't show up Feb 17 17:06:30 ! Feb 17 17:06:41 i think it is with the email not liking the uri Feb 17 17:08:32 but... in my searches to resolve this i've found a ton of different ways to handle the uri ... or find the "true" uri (mostly in regards to ACTION_IMAGE_CAPTURE) ... but i would think that what is documented here http://developer.android.com/reference/android/content/Intent.html#ACTION_PICK should be sufficient Feb 17 17:08:49 I ust put a Uri that starts with file:// in STREAM Feb 17 17:09:03 and the mail program has to have access to that file! Feb 17 17:09:18 is your image in your private folders? Feb 17 17:09:28 ah, indeed. Feb 17 17:09:39 womp womp Feb 17 17:09:47 so i've thought that it might have something to do with the mail program lacking access to the file... Feb 17 17:10:08 hello Feb 17 17:10:57 well... the Intent is launched with android.provider.MediaStore.Images.Media.EXTERNAL_CONTENT_URI ... which would make me believe that it is coming from a public place Feb 17 17:12:04 and therefore i should be able to just pass on the returned Uri to the email intent... but... alas... i'm consistently having a multitude of emails stuck in the outbox (with apparent image attachments) Feb 17 17:16:24 Hey guys, I need to make a string array, and I dont know how many items will end up in it after a loop Feb 17 17:16:32 So can I do String[] arrayName; Feb 17 17:16:44 Then inside the loop just do arrayName[i] = value? Feb 17 17:16:52 Or will I get an error because its not instantiated Feb 17 17:17:46 no Feb 17 17:17:53 use a List Feb 17 17:18:30 So List listName = new List Feb 17 17:18:36 Then I can add to that inside the loop? Feb 17 17:19:22 List listName = new ArrayList Feb 17 17:19:53 ArrayList is an interface right? Feb 17 17:20:03 drose379: List is an interface, you can't instantiate an interface (i.e. = new List()) Feb 17 17:20:10 ArrayList is not an interface Feb 17 17:20:37 ArrayList is the class? Feb 17 17:20:38 List listName = new ArrayList<>(); Feb 17 17:20:52 Ok, and its better to use a List over an Array? Feb 17 17:20:54 List is the interface, ArrayList is an implementation of List. http://docs.oracle.com/javase/7/docs/api/java/util/List.html Feb 17 17:21:21 On the left hand side yes, it's better to be more general Feb 17 17:21:23 How would you best check if a Cursor returned by rawQuery is empty? Feb 17 17:21:34 Thanks guys Feb 17 17:21:55 Kake_Fisk, if (cursor.moveToFirst()) Feb 17 17:22:12 uu, nice. Thanks Feb 17 17:23:38 I'm looking for a view/library that works like a viewpager. I need it to be in xml (no fragments). 2 pages i what I use, Do you have any suggestion? Feb 17 17:24:20 for 2 pages? Isn't there a ViewSwitcher class? Feb 17 17:26:10 If I just use List.add(value) Feb 17 17:26:22 Does it add the location for me automatically? (0,1,2) ? Feb 17 17:26:38 drose379, why dont you read the api docs? ;) Feb 17 17:26:45 :/ Feb 17 17:26:55 yep, those are simple Java questions Feb 17 17:27:14 I know, thats why im just running them by you guys quickly Feb 17 17:27:29 I know I prob shouldnt Feb 17 17:27:48 MikeWallaceDev: does it support sliding? Feb 17 17:27:55 we're not google :) Feb 17 17:28:04 I know, my bad gusy Feb 17 17:28:06 guys* Feb 17 17:28:10 yoavst, drose379, why dont you read the api docs? ;) Feb 17 17:28:21 ViewAnimator that switches between two views, and has a factory from which these views are created. You can either use the factory to create the views, or add them yourself. A ViewSwitcher can only have two child views, of which only one is shown at a time. Feb 17 17:28:27 not a single word about sliding Feb 17 17:28:28 I don't even remember if the class exists :D Feb 17 17:28:37 yoavst, you can make custom sliding animation of course Feb 17 17:28:43 no animation Feb 17 17:28:46 sliding like viewpager Feb 17 17:28:56 thats an animation. Feb 17 17:28:59 -_- Feb 17 17:29:24 draging* Feb 17 17:30:04 I can use a viewpager, but only If I cannot find something easier for this Feb 17 17:30:15 you can implement that. but i think its much easier to use viewpager Feb 17 17:31:17 I'm working on a small calculator (for LG Quick Circle, I've got 350dpX350dp screen size), so I don't have a place to put next button Feb 17 17:32:00 yoavst, whats against a viewpager? Feb 17 17:32:09 I have a shared textView Feb 17 17:32:19 put it outside of it Feb 17 17:32:24 and page the rest Feb 17 17:33:23 has someone tried to setup gradle 1.1 junit tests in intellij? seems to not be possible until it updates, is it? at least I cant find that "experimental" switch in the settings that is in AS Feb 17 17:33:38 Are they views or fragments? if they are only two views, you could even look into a LinearLayout... Feb 17 17:35:54 MikeWallaceDev: two linearlayouts Feb 17 17:36:03 Later guys Feb 17 17:36:09 later Feb 17 17:36:11 Thanks for the help Feb 17 17:36:31 no problemo. :) Feb 17 17:48:04 > Feb 17 17:48:14 > Feb 17 17:48:51 :) Feb 17 18:03:38 if I want to have a button that has rounded edges, that means I need like, 4 xml files minimum, right? 1 for the button drawable, 3 shapes (all pretty much the same except for the solid color) Feb 17 18:04:25 and if I want to have the same button but with different colors, that's 4 xml files per color Feb 17 18:04:28 shekibobo, you could also do all those shapes in a single xml if you dont care about reusing them Feb 17 18:04:36 or do something like color overlays Feb 17 18:04:44 but in general, you are right Feb 17 18:04:55 or render button manually with a drawRoundedRect Feb 17 18:08:46 so if I wanted to have, say, a pill-shaped button, but that could be different color themes, a subclass would probably be better than xml theming it? Feb 17 18:15:14 shekibobo, xml styles can have parent style Feb 17 18:15:31 but can a shape have a parent shape? Feb 17 18:23:56 shekibobo: you'd probably just define the color as @color/whatev, and change the color by theme (or do you use attrs for that? /me forgets) Feb 17 18:26:01 well, say if I set a button to use a shape selector for it's background. There's not a way to give that button a color-statelist background without overriding the shape background, right? Feb 17 18:27:35 you can use colorfilters Feb 17 18:27:59 or .. well. whats wrong with multiple xmls ? :p Feb 17 18:28:18 I think I'm at least a bit more comfortable putting all the shapes in one file and using a different one for each different button type I need to make Feb 17 18:28:24 but I'm curious about color filters Feb 17 18:30:40 shekibobo: use layer drawables, and you can put all of that in a single file iirc Feb 17 18:32:23 shekibobo: hm. maybe I'm not following. you want a reusable multi-color rounded-rect button, with pressed / etc states? and is the color selected by the current theme, or by something else? Feb 17 18:34:06 I'd like to just have a shape that I can use, and then give it a color statelist for its color. That way I have a shape that is consistent, but the colors can be whatever Feb 17 18:34:43 and then I might have a rounded_button_redish, rounded_button_grayish, rounded_button_greenish drawables that just use the shape and the color statelist I give it Feb 17 18:34:59 just doesn't seem like android lets you do that Feb 17 18:35:15 or else I'm just approaching it wrong Feb 17 18:37:51 ah. afaik no, which is a bit sad for programmer purposes :| a lot of the xml-drawable grand-idea seems to be that it's something you can give to a different process, which can still render it consistently, so options are pretty limited. Feb 17 18:44:27 is there an easy way to track down what is pointing to me missing resource? Right now I know I am missing hello_world but I can't find it referenced in my code. I'm using Eclipse's error log and there is no goto line number for it Feb 17 18:45:07 Mittendeep: probably do a project-wide search, since it may be in xml Feb 17 18:46:37 Mittendeep: or, I think if you build the project, the xml file will show up as having an error in it. I forget where exactly eclipse shows build problems, aside from the file tree. Feb 17 18:46:58 It only crashes at runtime Feb 17 18:47:02 ah, joy Feb 17 18:47:16 yeah, just search for the string. ctrl-H iirc Feb 17 18:47:19 I can get around it by adding it back in string.xml, but I don't want to do it =( Feb 17 18:48:00 Mittendeep: you need to do a clean build, thats all Feb 17 18:49:05 I don't remember it being _quite_ that bad about building xml, that you have to clean after removing things, but eclipse / the eclipse plugin does have a few holes in its build process :| Feb 17 18:49:59 Yeah, I really want to use android studio but my professor insists on eclipse and the ADT plugin. Feb 17 18:50:19 Anyone know why a folder I have created on my phone won't show up in Windows Explorer unless I reboot my phone? Feb 17 18:50:23 ah, for school. that's not too surprising :) Feb 17 18:51:40 Tomaz^W: on some phones, you need to trigger a media scan for the USB connection to show new files / folders. I don't know if that's the cause here, but it seems like there's a decent chance it's related. how are you creating the folder? Feb 17 18:52:09 Through code, using NDK and mkdir( "path", 0770 ) Feb 17 18:52:39 basically creating the /some_external_apth/Android/data/my_package_name/files/ Feb 17 18:53:32 Tomaz^W: I would try this first, personally: http://viralpatel.net/blogs/android-trigger-media-scanner-api/ Feb 17 18:53:42 Tomaz^W: there may be an alternate way, that's just high on the google list for me :) Feb 17 18:53:52 cool, I'll try it Feb 17 18:53:54 thanks Feb 17 18:54:38 So what I could do then, is instead of rebooting, I could take a photo, that should trigger a media scan for entire external mem, or jsut the cam folder? Feb 17 18:55:28 you're putting photos in your /external/android/data/package/files ? I think you can tell it to scan a folder + subtree, but I've never had to build something that does this :| Feb 17 18:55:29 Hey all Feb 17 18:55:43 Bundle == Parcelable HashMap on steroids? Feb 17 18:55:53 Tomaz^W: do you want the photos to appear in other photo apps, or just in yours? Feb 17 18:56:03 nah, it was just an idea to trigger the scan without having to code it on, or reboot phone Feb 17 18:56:11 not photo related at all Feb 17 18:56:15 woah my app isnt ugly AF, im amazed. Feb 17 18:56:31 Tomaz^W: if it's just for dev purposes, you can generate broadcasts via `adb shell pm broadcast `, though I always forget the syntax Feb 17 18:56:38 hmm Feb 17 18:56:42 yes it's for dev only Feb 17 18:57:18 Tomaz^W: ah, sorry. `adb shell am broadcast ` Feb 17 18:58:43 Wait, why aren't there parentheses after the `length` on that char[]? Look, that's wrong, there are parentheses after the `length` on this String! That must be new! Feb 17 18:58:47 - My IT teacher. Feb 17 18:59:08 :| Feb 17 18:59:51 I had to show him the relevant part in the JLS to convince him that I might be right... that this /is/ valid code. Feb 17 18:59:57 Espresso says: Error performing 'load adapter data' on view 'with id: is <2131296368>'. without any other description, any tips? Feb 17 19:00:06 The espresso code is: onData(anything()).inAdapterView(withId(R.id.userList)).atPosition(0).perform(scrollTo(), click()); Feb 17 19:00:26 Is there a guidline on when using tabs? Feb 17 19:01:21 Eg I have like weather forecast app. tabs could be high level such as Regions, Predicted, Local ... or tabs could be one level lower if a user has selected n regions, it could do each Region as a tab, (though that could be unbounded but might be 10-20 usually) Feb 17 19:02:25 lasserix: since they're always visible, I tend to think of them as "use when you want to encourage browsing between tabs". Feb 17 19:03:44 Does a Cursor object contain the result. In that case, which member keeps the result? Feb 17 19:04:05 a cursor is like an iterator Kake_Fisk Feb 17 19:04:35 Kake_Fisk: it does, if the result is small enough to fit inside a single "window" (~1mb I think?). if not, it'll have to pause and load more when you exhaust the window. Feb 17 19:05:28 mWindow didn't contain anything that looked like my result :/ Feb 17 19:05:52 Kake_Fisk, what are you trying to do Feb 17 19:06:14 I'm trying to inspect my results returned from a database query Feb 17 19:07:18 guys notice? http://forums.makingmoneywithandroid.com/advertising-networks/20018-google-new-app-approval-process.html Feb 17 19:07:28 Kake_Fisk: you can get the names of the columns and getString() on any of them - personally I write a small 'dumpCursor' method when I need it. Feb 17 19:07:51 Kake_Fisk: you can use that in the debugger too, just add a watch variable = "dumpCursor(c)" Feb 17 19:08:22 it may break your app when you resume, since it'll change the state of the cursor, but meh. Feb 17 19:08:51 g00s, finally. Feb 17 19:08:53 good decision Feb 17 19:12:59 nice https://www.infinum.co/the-capsized-eight/articles/you-think-your-app-is-ready-for-publishing-well-think-again Feb 17 19:14:02 groxx nice philosophy Feb 17 19:14:43 anyone with exp with rx java, how long would it take for someone who understand the concepts and essentially artitectes their apps in that way to embrace rx java and start using in a project? Feb 17 19:14:54 g00s, so basically "spy on your users as much as possible and waste their battery" :P Feb 17 19:15:39 Mavrik you dont have crash reporting or anayltics ? that omiision was my biggest mistake - but i'm sensitive to everyone's privacy too, so analytics can be disabled Feb 17 19:15:57 I have crash reporting Feb 17 19:16:11 I don't have "following every tap and every entry" anymore because it was mostly useless Feb 17 19:16:23 and did bad stuff with battery Feb 17 19:16:40 and I avoid using multiple crash/analytics frameworks because they do bad stuff to users phone when they fight :) Feb 17 19:17:38 lasserix: it took us an extra month to build the library AROUND RxJava to make it usable for our purposes Feb 17 19:18:39 sounds like you shouldn't be using it then :) Feb 17 19:18:43 lasserix it can have a steep learning curve. i would start out with some isolated uses-cases , instead of trying to rx-architecture the whole app Feb 17 19:19:12 g00s: dat login explanation :E such visibility, wow Feb 17 19:19:32 groxx what was that ? Feb 17 19:19:50 g00s: number 7's photo Feb 17 19:20:12 g00s: ah, #6 Feb 17 19:20:37 ok, I'm really stupid and cant figure out the right property to tweak on my GridView to have the added TextViews to be vertically centered and equally spaced Feb 17 19:21:07 Do you see anything wrong with my database query code? http://pastebin.com/4bnuS5du Feb 17 19:21:12 groxx 50% grey on 49% grey :) Feb 17 19:22:00 Anyone know where the android screen cast binaries can be obtained? Feb 17 19:22:00 ok now i'm regretting posted that Feb 17 19:22:07 or how I can project android screen to desktop? Feb 17 19:22:46 It may be important to say that the query works in my database manager Feb 17 19:23:11 g00s: it's a "# things you wish you knew before X" article. regret follows sharing with almost 100% consistency. Feb 17 19:24:14 Kake_Fisk: you probably want getString(0). is it reaching that point, or is it failing earlier? Feb 17 19:24:33 It returns "Woof" :( Feb 17 19:26:08 I also double checked that the codepoint is a valid record Feb 17 19:26:08 Kake_Fisk: you're certain you have the data in the database? e.g. you've pulled the device's database and tried it in a separate app? Feb 17 19:26:22 Ohh, I haven't tried that Feb 17 19:26:23 nice timing :) Feb 17 19:26:25 ah Feb 17 19:26:27 That might be the problem Feb 17 19:26:41 Anyone know how to project android screen to desktop or video screen? Feb 17 19:27:36 Kake_Fisk: also, out of curiosity, what's the codepoint? an integer? Feb 17 19:28:35 yepp Feb 17 19:29:34 Oh, and I'm not sure if I can pull the database if I'm on a non rooted device Feb 17 19:29:56 Kake_Fisk: there are a few ways. is it in internal storage? Feb 17 19:30:56 It's in the default storage space. I don't know which one that is, but I assume internal. "/data/data/PACKAGE_NAME/databases/" Feb 17 19:30:57 Kake_Fisk: I'd need to double check that it works, but iirc you can `adb shell run-as your.package cat path/to/file.database > local_file.database` Feb 17 19:30:59 Anyone know an app I can use to project my android screen to a desktop/laptop? Feb 17 19:31:14 Anyone know where the source for espresso2 is? Feb 17 19:31:21 I'll try Feb 17 19:31:29 Kake_Fisk: I forget if that has issues though Feb 17 19:31:42 Do you know if I can execute these commands directly in Android Studio or if I need to open adb? Feb 17 19:33:40 Kake_Fisk: on an emulator you can get to them through DDMS (the Android Device Monitor button in the main toolbar). not sure how to do it on a normal device though :| Feb 17 19:34:45 The external DDMS application has all these features, but I have yet to find them in AS. But I'll open up the external one then ^^ Feb 17 19:37:12 bleh. cat isn't working for me, at least. does "select * from emoji" find any rows? Feb 17 19:37:27 Oh, that's cleber Feb 17 19:38:33 groxx: try chmod instead, to make it world-readable Feb 17 19:38:44 how can you change highlight color of selected item in SlidingTabLayout (not indicator color, but highlight color on touch)? Feb 17 19:38:52 and then you should be able to adb pull Feb 17 19:38:54 groxx: That worked :D Feb 17 19:39:22 Kake_Fisk: also, android studio has one killer feature over Eclipse while debugging: there's an "evaluate expression" button that'll let you write multiple lines of code and then execute them. quite a lot easier to iterate on things, like to try a dozen queries without rebuilding -> reinstalling -> etc. Feb 17 19:39:43 Oh, sounds nice! Feb 17 19:44:08 JesusFreke: I like that idea, but i get 'remote object X does not exist' Feb 17 19:44:42 groxx: hmm. you might need to set +x on the directory too Feb 17 19:45:04 I figured it out groxx. It was my fault :| Feb 17 19:45:36 JesusFreke: interestingly, it's already world-executable Feb 17 19:45:51 Kake_Fisk: ha, well at least it's fixable :) Feb 17 19:45:56 Kake_Fisk: mind if I ask what it was? Feb 17 19:46:18 groxx: maybe one of the parent directories isn't? Feb 17 19:46:53 JesusFreke: probably. run-as + chmod can't change the /data/data intermediates though Feb 17 19:46:56 As I'm not super into these database handlers in Android, my database handler didn't update if it already existed Feb 17 19:47:04 So I had an old version uploaded Feb 17 19:48:31 Kake_Fisk: ah, was it not readable then? Feb 17 19:48:56 It was readable, but didn't contain that one record I tested up against Feb 17 19:49:02 That's why SELECT * worked Feb 17 19:49:13 ah, lol, makes sense Feb 17 19:49:55 But thanks a lot for helping :) Feb 17 19:50:17 Kake_Fisk: np :) Feb 17 19:50:26 It's extra hard when you are not sure if your code is supposed to work or not ;) Feb 17 19:50:50 yeah, definitely doesn't help Feb 17 19:51:22 fwiw, in case you weren't aware: only ever make a single sqliteopenhelper, and reuse it. otherwise you can get competing upgrades, which will cause one to fail, possibly crashing your app. Feb 17 19:52:11 it's intended to be used as a singleton anyway, they're just not super-painfully-explicit about it in the docs (last I saw) Feb 17 19:54:25 http://higherperspective.com/2015/01/introverts.html Feb 17 19:55:00 On Android Studio, is it possible to create a launch configuration that will use a specific device instead of getting the dialog with the list of connected devices? Feb 17 19:56:36 jaana: I would assume so, but there's a checkbox for that purpose in the list Feb 17 19:56:39 Napalm http://www.bravenewgeek.com/a-look-at-nanomsg-and-scalability-protocols/ Feb 17 19:56:59 groxx: Don’t assume :) Doesn’t seem to be possible, I don’t see a way to customize adb with -s for a launch config so far Feb 17 19:57:24 jaana: I'll check in a couple minutes. afk at the moment Feb 17 19:58:32 groxx: thanks Feb 17 19:59:21 jaana: There is a checkbox which reads "Use same device for further launches". It's listed as an option for my build configuration so I assume it's build configuration specific? Feb 17 20:00:15 I think this should dynamically have all elements take up one row in the grid, but nothing is displayed. any ideas? "gridView.setColumnWidth(gridView.getWidth()/gridView.getNumColumns());" Feb 17 20:01:01 this is after I set the adapter Feb 17 20:01:58 janna: err launch configuration. sorry Feb 17 20:02:03 hello, im trying to use GestureDetector it doesnt detect at all http://pastebin.com/kacz0cyt Feb 17 20:02:21 how can i make it detect? Feb 17 20:04:19 xdaimon: that’s not what I want, I have multiple devices connected, I want to launch configurations that will go directly to a specific device, not always the last one I used Feb 17 20:05:24 I fixed it. I had the stretchMode set incorrectly Feb 17 20:08:09 jaana: that is intriguingly difficult. weird. I suppose CI servers just build, and add a script to install + run for specific devices? Feb 17 20:09:34 jaana: I mean, at worst it seems you could `./gradlew assembleDebug && adb -s device install build/outputs/app-debug.apk && adb -s device shell am broadcast ` Feb 17 20:09:58 john67: you have to override onDown and return true Feb 17 20:09:59 groxx: Yeah but then I need to attach manually from AS, which defeats the purpose Feb 17 20:10:16 jaana: yeah. not ideal for a large number of reasons :) Feb 17 20:11:20 jaana: dunno. I'm not familiar enough with the whole system to know what to do :\ maybe you can make a script like the above that's used as a run configuration though? Feb 17 20:12:15 groxx: I don’t see such an option, sadly, that launch dialog is ridiculously small, not a lot of tweaking possible Feb 17 20:15:37 https://lh3.googleusercontent.com/-2JtSqfxswIA/VLs3RKQW__I/AAAAAAAAMUw/K4UI_TR2O3k/w493-h740-no/SQL%2BQuery%2BExecuted%2BSuccessfully.jpg Feb 17 20:15:39 LOOOL Feb 17 20:16:49 https://lh5.googleusercontent.com/-sD5OMCbc6pI/VLeuDF5tPVI/AAAAAAAAMO8/uyq4XRJ1TyA/w506-h638/Singleton%2BDesign%2BPAttern%2BMeme%2BJava.png Feb 17 20:19:49 groxx: i have overide onDown with a true return, but nothing changes http://pastebin.com/7NWkSqHH Feb 17 20:23:36 I am looking to build an app where I have to mix 4-5 individual sound tracks. ANy example available for mixing multi track audio or playing multiple sounds together in Android ? I used soundpool but results are disappointing Feb 17 20:24:36 john67: how are you using it? Feb 17 20:25:54 groxx: this is the code , http://pastebin.com/7NWkSqHH . u are talking about the onDown ? Feb 17 20:26:40 john67: I mean how are you using that gesture detector? you need to feed it touch events or it won't do anything Feb 17 20:26:51 jaana: i believe the launch configuration's "previous device" is specific to that launch configuration. Have you tried setting "Use device for future launches" and selecting the desired device for separate launch configurations? Feb 17 20:28:00 xdaimon: I think you're right about that, but if the list of devices changes it gives you the list again :/ Feb 17 20:28:17 ahhh. that could be annoying Feb 17 20:28:19 hello all Feb 17 20:28:35 <---- ##noob alert## Feb 17 20:29:13 groxx: i just it to display next and prev with the Toast depending on the gesture , i call it in side the fragment. is that what you mean? Feb 17 20:29:20 xdaimon jaana: maybe it's stricter if you choose "use device" in the run configurations editor? afk again, and only one device on hand, or I'd test it out Feb 17 20:31:54 hi Feb 17 20:31:59 looking through this kotlin project https://play.google.com/store/apps/details?id=io.sweers.palettehelper Feb 17 20:32:04 pretty much reads as Java Feb 17 20:32:20 who can help me about usb device adb driver. Feb 17 20:32:23 who can help me about usb device adb driver. Feb 17 20:33:16 root@a-X550CL:/home/a# adb devices Feb 17 20:33:17 List of devices attached h...s... Feb 17 20:33:35 i cant see my device on adb Feb 17 20:37:43 Anyone got good recomendations of material design app with nav drawer + tabs? Feb 17 20:38:08 anyone know the default android drawable for items like listview items? Feb 17 20:38:58 like, I want it white, but with the built in states it would have + ripple if available... Seems like it'd be a built-in drawable somewhere Feb 17 20:39:03 shekibobo, android.r.layout.simple_list_item_1 Feb 17 20:39:16 lasserix i guess you know about iosched already right ? Feb 17 20:39:31 groxx: im feeding the touch event, but it does nothing , Feb 17 20:40:45 g00s, you mean that I/O has been announced? Feb 17 20:41:07 iosched 2014 app on github Feb 17 20:41:41 be amazed, at how much code accomplished so little though ;) Feb 17 20:42:33 http://stackoverflow.com/a/13375461/3991578 Feb 17 20:42:36 Ah, I see Feb 17 20:42:46 So I totally didn't think about id names on some of my recyclerview list items and now I have duplicate ID's that keep renaming each other when I change one. How do I fix this? Feb 17 20:43:17 fix them by hand Feb 17 20:43:34 Oh god. That's going to be a lot. I'll do that though Feb 17 20:43:40 Is there any special naming convention you recommend? Feb 17 20:43:50 no Feb 17 21:06:31 https://github.com/bluelinelabs/LoganSquare - Screaming fast JSON parsing and serialization library for Android. Feb 17 21:06:32 looks good Feb 17 21:06:35 g00s: check it out Feb 17 21:07:21 Napalm cool Feb 17 21:08:34 so much boilerplate passing activity intent to fragment arg bundle :( Feb 17 21:08:49 i dont get why the gesture detect doesnt work . when fling from left to right nothing happens . plus there is no error in my code http://pastebin.com/7NWkSqHH . why doesnt it work? Feb 17 21:09:04 Napalm use any 0mq yet ? Feb 17 21:09:16 g00s: yeah :( I've seen an annotation processor or two that generates intent / bundle-builders so you have stronger types and convenience methods, but it's still pretty boilerplatey Feb 17 21:09:21 g00s: nope, i got that article you sent me on my reading list Feb 17 21:09:43 Doesnt Butterknife do it? Feb 17 21:10:12 Napalm: dang, nice find. that's exactly what I've been thinking an android json library _should_ be. Feb 17 21:10:47 groxx: yea, i might write a Retrofit converter for it later. Feb 17 21:10:53 hey yall. i'm trying to distribute a test *unsigned version of my application for testing. i'm having problems with it not installing on devices and i'm not sure how to resolve. am i wrong to think that it is possible to install an unsigned .apk if you select the option to allow it in the device's security options? Feb 17 21:11:17 that LoganSquare library is a half-assed annotation processor Feb 17 21:11:24 it just delegates to normal Jackson parsing Feb 17 21:11:29 same as the instagram one Feb 17 21:11:39 :'( Feb 17 21:12:00 pablq: it needs to be signed. so just sign it with a debug cert. Feb 17 21:12:13 Napalm: thanks Feb 17 21:12:18 does GridLayout allow changing row and column number at runtime? Feb 17 21:12:57 JakeWharton: definitely :'( inducing. alas. well, maybe it'll be enough of a starting point to eliminate jackson entirely :| Feb 17 21:13:02 in a later project. Feb 17 21:13:11 Napalm what i have been doing is passing binary blobs over mqtt and using ragel to parse, i dont think it gets any better Feb 17 21:13:36 grammar is expressed as ebnf mostly, parser is generated, binary format is compact Feb 17 21:13:58 but then again, i get the same binary blobs from the devices so i use the same representation :D Feb 17 21:18:51 g00s g00s g00s Feb 17 21:18:59 hey JacobTabak :) Feb 17 21:19:03 allo Feb 17 21:20:06 JacobTabak how are things at timehop Feb 17 21:20:15 bretty good ! Feb 17 21:20:21 goin out to nyc in a few Feb 17 21:20:38 you just missed all the snow :) Feb 17 21:20:59 ha we get enough of it in wisconsin Feb 17 21:21:29 snow and cheese Feb 17 21:28:46 I miss the cheese :'( Feb 17 21:29:05 can I merge resources from another apk into my running application? or replace my resources with that apk file's resources? Feb 17 21:30:40 sr105: in a way. you can use the package manager to get the other apk's context, and you can get resources from that instead of yours. Feb 17 21:31:15 The other apk isn't installed. Feb 17 21:31:49 sr105: ah. not sure then. Feb 17 21:32:00 I'm loading a Fragment from an apk lib and it uses the running App's inflater instead of the one it would use if run normally Feb 17 21:32:25 just trying to figureout how to get it to use the resources from its own apk file Feb 17 21:32:43 and do it in an "android" manner Feb 17 21:46:46 anyone have any suggestions on how to make a "draggable" edittext? I'm having a surprising amount of pain getting drags to work _and_ taps to allow editing. Feb 17 21:48:47 Is there a public set of JavaDoc for https://android.googlesource.com/platform/tools/idea somewhere? Feb 17 21:52:48 is anyone using ndk-gdb with an android studio project? Feb 17 21:55:45 Anyone have a good example of using tabs but also having an action bar where the action bar action icons relate to the stuff underneath the tab bar (as opposed to having yet another toolbar stacked undearneath the tabbar underneath the actionbar) Feb 17 21:56:15 heh Feb 17 21:56:48 lasserix i think the tabs have to go under the toolbar. i couldn't get it working making them a child of toolbar Feb 17 21:57:12 well if you have like action bar / tabs / toolbar its kind of a lot of stacking Feb 17 21:57:27 oh you have 3 layers Feb 17 21:58:35 i guess i'd have toolbar + tabs as primaryColor (is that it?) and then the toolbar in the tab, as regular background (white) Feb 17 21:59:37 toolbar uses another view, you can use that for level 3 Feb 17 21:59:44 i forgot what its called, one sec Feb 17 22:00:09 ActionMenuView Feb 17 22:00:29 is using a constant tab bar at the bottom a really bad idea? Feb 17 22:00:34 that's the way the designers want to go Feb 17 22:00:40 like ios ? Feb 17 22:01:13 lasserix, slap them with a Nexus. Feb 17 22:01:29 I find it slightly awkward with the soft nav buttons, since they're so close. but I don't personally think they're as bad as they've been portrayed. Feb 17 22:01:36 yeah Feb 17 22:01:44 supporting evidence: facebook uses it. Feb 17 22:01:47 well the problem is you don't really want to stack action bar + tabs + toolbar Feb 17 22:02:02 or put what should be in that toolbar in the actionbar Feb 17 22:03:50 groxx, if you've ever seen less tech-savvy users use those Feb 17 22:03:52 it's horrible Feb 17 22:03:56 the bars, are too damn high ! Feb 17 22:04:00 "Why did my app suddenly close?" Feb 17 22:04:16 "Because you pushed the home button." "But I wanted to open the wall!" Feb 17 22:04:17 Mavrik: I see them do the same thing, by reaching for the top edge, and bumping things on screen with the meat of their palm Feb 17 22:04:38 thats a pretty meaty palm then Feb 17 22:04:39 I see that WAY more often, actually Feb 17 22:05:07 mhm Feb 17 22:05:08 phablet + one-handed use does make it a lot more likely Feb 17 22:05:14 but I blame that on 5" screens really Feb 17 22:05:41 and the fact that we still use phone-style layouts on tablets Feb 17 22:05:55 instead of teaching users that phablets are two-handed devices Feb 17 22:06:37 well, on the flip side they're teaching us that phablets are one-handed devices despite our wishes, and we're not building in sane things like palm rejection. Feb 17 22:06:40 i dont get why the gesture detected doesnt work this is the my code http://pastebin.com/VBHRGmm3 Feb 17 22:09:34 Picasso will memory cache images originally loaded from disk? Feb 17 22:11:23 lasserix: I think so. or if not, it's a one-time setup to make a memory lru cache. Feb 17 22:11:26 lasserix: memory first I thought Feb 17 22:17:35 lasserix: yes Feb 17 22:23:33 Mavrik ok, this one is better :) http://blog.ubertesters.com/know-users-truly-love-app-9-crucial-kpis/ Feb 17 22:28:48 dammit man! cannot understand RESTful service :( Feb 17 22:45:54 ls Feb 17 22:46:57 Hello, I have been googling for an answer.... All my http calls were succeeding, now I have one function that's not returning passed the .execute() call. Feb 17 22:51:39 StephanDev: what .execute call Feb 17 22:52:47 how do i create a deep copy of a drawable? Feb 17 22:52:52 yiati, DefaultHttpClient's Feb 17 22:53:13 I think I might know why. Feb 17 22:55:02 lasserix: What kind of drawable? Bitmap> Feb 17 22:55:04 ? Feb 17 22:55:11 figured it out Feb 17 22:55:14 but yeah Feb 17 22:55:35 cool Feb 17 22:57:13 Nope Feb 17 23:01:00 yeah weird, it ws working earlier, now my http calls just freeze Feb 17 23:01:49 HttpClient client = new DefaultHttpClient(); client.execute(post); ... times out on the .execute() Feb 17 23:03:07 If you want to mess with a raw HTTP client check out http://square.github.io/okhttp/ instead Feb 17 23:05:27 I don't even know what to think when Android Studio thinks my RecyclerView is a TextView lol Feb 17 23:11:07 t0astt: hit 'make project'? Feb 17 23:11:18 I assume that's a layout preview thing? Feb 17 23:11:30 groxx: It still thought it was a TextView. I had to close AS and reopen it for it to properly detect it Feb 17 23:11:38 lolwat Feb 17 23:11:44 i know Feb 17 23:11:49 i was like c'mon AS you're smarter than that Feb 17 23:12:26 god my university's CAS is so slow >_< Feb 17 23:12:46 I've been waiting for the login to go through for 3 minutes already Feb 17 23:23:38 back Feb 17 23:23:54 something I do often in android is : t1.setText("Text 1"); and then duplicate the line for other 3-4 views and go through each line to change t1 to t2, t3, t4, t5 Feb 17 23:24:32 same for animating, set listeners, etc. Is there a better way ? Feb 17 23:25:00 ( since all of them are of the same type ) . Of course i'm asking for AS Feb 17 23:25:18 s/better/faster Feb 17 23:25:19 my java process is taking up 666 mb :O Feb 17 23:25:28 * g00s knew it all along Feb 17 23:25:48 g00s: is it a java 6 process? Feb 17 23:25:59 in fact yes Feb 17 23:26:05 apple java :) Feb 17 23:26:29 ⊙﹏⊙ Feb 17 23:27:02 how do you tell the system to not kill your activity on rotation change? Feb 17 23:27:09 definitely a sign of the apocalypse Feb 17 23:27:14 i still dont get why the gesture doesnt work on my app this is my code . in case there is an error http://pastebin.com/VBHRGmm3 Feb 17 23:27:20 have you guys noticed that AS doesn't save xml code formatting options when changed? i have to keep restting them each time i start AS Feb 17 23:27:21 s73v3r onConfigurationChanged Feb 17 23:27:25 s73v3r: add configChanges to the activity in the manifest Feb 17 23:27:30 and then you set some flags in them manifest Feb 17 23:27:37 to every activity? Feb 17 23:27:52 there’s not a way to apply it globally? Feb 17 23:27:58 well, if you need to make adjustements to the layout Feb 17 23:28:02 s73v3r: probably. but don't rely on it for stability, because there are other kinds of config changes. Feb 17 23:28:12 yeah in the manifest you have to add it to every activity Feb 17 23:28:13 actually, I want the app to be locked in portrait Feb 17 23:28:16 s73v3r: fragments also have a .setRetainInstance(true/false) method that'll do kinda the same thing Feb 17 23:28:32 s73v3r: ah. there's an orientation option in the manifest too. Feb 17 23:28:38 you can do that with android:screenOrientation Feb 17 23:28:47 is that also per activity? Feb 17 23:28:49 and as usual you can do that all in code as well. Feb 17 23:28:50 yes Feb 17 23:29:47 at least, I think you can at runtime in code. you may have to change things through the package manager though.... hm. Feb 17 23:30:58 s73v3r: for orientation specifically, afaik setRequestedOrientation will work. never used it though. Feb 17 23:32:04 but will that still allow the activity to be killed? Feb 17 23:34:22 Is there anything special about cardview, ie can I instead just take a 9.png and use that and give the appearance of cardview with adding an entire another layout parent? Feb 17 23:35:57 I asked myserlf the same question lasserix Feb 17 23:36:37 s73v3r: given the rest of android's lifecycle (e.g. leave the app -> process dies -> resume app), you essentially can't guarantee that. or, the cost is likely higher than is worth it (having the activity never save state, for instance) Feb 17 23:36:57 CardView uses elevation property on L for shadows and falls back to a custom shadow Feb 17 23:36:57 * implementation on older platforms. Feb 17 23:37:02 s73v3r: and even if you handle orientation, you can still get restarted if the language changes, or they go into car mode, or a variety of other reasons. Feb 17 23:37:49 lasserix, it's just a small class... Extension of FrameLayout Feb 17 23:37:50 https://android.googlesource.com/platform/frameworks/support/+/refs/heads/master/v7/cardview/src/android/support/v7/widget/CardView.java Feb 17 23:38:07 MikeWallaceDev: my problem is i have a scrollview with 7 custom views, some are just ll with textviews, some are viewpagers with images, viewpagers with listviews, etc etc... in a viewpager total in can be laggy moving from side to side Feb 17 23:38:19 trying to figure out best way to optimize this view Feb 17 23:38:30 right now each "section" i've cut into a custom class Feb 17 23:38:35 so the only way to fix my problem is to properly save state upon config change? Feb 17 23:39:11 CardView doesn't seem very expensive Feb 17 23:39:21 s73v3r: probably. embrace it. it's a useful part of the framework. Feb 17 23:39:44 it really, really isn’t Feb 17 23:40:00 sure it is. do you want to allow your app to resume after the process has died? Feb 17 23:40:26 i’m just fine with the app restarting, because odds are the user has been signed out by then already Feb 17 23:40:44 not really. small device + a game = use app -> switch to game -> switch back, your app may have to be restarted Feb 17 23:41:01 i just don’t want to have to do all this extra shit because the phone went on it’s side, especially because it’s supposed to be locked to portrait Feb 17 23:41:10 as soon as the user leaves the app, we sign them out Feb 17 23:41:14 s73v3r: setRequestedOrientation should help that. Feb 17 23:41:16 financial data Feb 17 23:41:44 ah. if that's a "left for any reason, always log out" thing, you may very well want to avoid saving state for the sensitive activities Feb 17 23:42:10 yup Feb 17 23:42:43 that's awful practice... Your app can go in the background for all kings of reasons... Including getting a phone Feb 17 23:43:01 Your users will kill you if they answer the phone and are then logged out Feb 17 23:43:15 again, sensitive financial data Feb 17 23:44:18 your app, do what you want Feb 17 23:44:44 it’s not my requirement Feb 17 23:45:24 s73v3r: there's also a "secure" flag of some kind you can set, so your activity doesn't get screenshotted for the recent apps list. that might only work on ~kitkat+ though. Feb 17 23:46:32 completely different question: Currently in Android Studio, when I try to debug stuff, the variables view will not show the method parameters on the first line of the method. If I can step down to the second line, i can see them. But not on the first line. How do I fix this? Feb 17 23:46:53 I had that same bug Feb 17 23:47:00 s73v3r: I think that's a gradle plugin 1.0.0 bug, 1.0.1 fixes it Feb 17 23:47:01 don't know if it still does it Feb 17 23:47:10 or, at least, in theory Feb 17 23:47:36 ii’ll check Feb 17 23:47:49 you’re talking the gradle android plugin, right? Feb 17 23:48:54 yeah Feb 17 23:57:30 Riddle me this: My app compiled and worked. Something (must have) happened. Now it can't find one of my classes from a shared library. The library is in the project view. Removing the import line will then prompt me to include the correct class name! From the correct package. Compile again: error, cannot find symbol class: MyContentProvider. WTH? Feb 17 23:57:34 wow Feb 17 23:57:39 so i figured out what it was that was stupid as hell Feb 17 23:58:03 2 hours and its cause of the utf-8 string on my stringentity Feb 17 23:58:08 I cleaned and even synchronized... Feb 17 23:58:54 AH!! minifyEnabled true. Feb 17 23:59:57 wait, what? I'm in debug mode. Feb 18 00:00:30 im trying to use the GestureDetector with the fragments . i have the gesture Class in the onCreateView,it doesnt work .should be in something else? Feb 18 00:01:07 I'm using that right now john67 , should work fine Feb 18 00:01:18 did you remember to forward your touches? Feb 18 00:01:56 WTH?? why would minifyEnabled interact with my debug build? Feb 18 00:02:44 MikeWallaceDev: i dont get you? how Feb 18 00:02:54 how what? Feb 18 00:03:48 MikeWallaceDev: forward the touches Feb 18 00:04:05 public boolean onInterceptTouchEvent(RecyclerView rv, MotionEvent e) { m_detector.onTouchEvent(e); return false; } Feb 18 00:04:37 MikeWallaceDev: no, havent done this Feb 18 00:04:51 ... extends Fragment implements RecyclerView.OnItemTouchListener Feb 18 00:06:01 let me try Feb 18 00:08:57 Has anyone else had a problem with emulators not starting? They were starting fine a few days ago but now they stay at 100% cpu usage and never end up loading (even after an hour) Feb 18 00:09:33 replaceits, default answer in this channel: use genymotion Feb 18 00:09:44 ah thank you Feb 18 00:09:56 :p Feb 18 00:09:59 nnp Feb 18 00:13:56 im happy my emulators always start unless theres a config problem =P Feb 18 00:14:11 ultimately just got myself some new devices though hehe Feb 18 00:15:55 I haven't had a problem for about a year, they just stopped working all of a sudden lol Feb 18 00:17:17 I'd try creating new virtual devices if that happened. Feb 18 00:18:16 I did, tried a bunch of different configs. Android on linux has always been a bit finicky for me Feb 18 00:18:35 I'm on Linux... Feb 18 00:18:48 Usually works perfectly. But today AS is mad at me. Feb 18 00:19:05 I must have kissed its sister or something Feb 18 00:19:29 And now genymotion wont load the virtualbox engine, this isn't my week lol Feb 18 00:19:43 MikeWallaceDev: You opened eclipse, didn't you? :) Feb 18 00:19:45 MikeWallaceDev: is there a simple way to do that? Feb 18 00:20:09 JesusFreke, we were just talking, honest! Feb 18 00:20:17 to do what?? :D Feb 18 00:20:46 MikeWallaceDev: for the gesturedector Feb 18 00:20:54 Geez man, I gave you all the code. What's your address? I'll go type it in for you. Feb 18 00:21:02 :D Feb 18 00:21:04 MikeWallaceDev: lol Feb 18 00:21:10 guys what do you call that notification kinda message thing that some apps use to show something and then it fade away. E.g. something when your battery is low you phone can just pop this message and then it fades way Feb 18 00:21:31 seriously john67 , did you add the implements listener line I sent ? Feb 18 00:21:39 yeah Feb 18 00:21:56 then your listener should be called... Feb 18 00:22:22 I mean, your framework should be working, it's probably your gesture details that are screwy Feb 18 00:25:08 oki Feb 18 00:29:39 john67, here is a snippet of my code, this should help Feb 18 00:29:41 http://tinyurl.com/omgzk3f Feb 18 00:30:10 Could someone help me figure out where to find meaningful info in my LogCat tab for my application? Is there a way to see line numbers and basic stuff like that? Feb 18 00:30:19 It's not the real code, it's been simplified to show you an example, so if something does look right, it's probably not :) Feb 18 00:30:50 Mittendeep, logcat is what it is, just read... Feb 18 00:31:05 pidcat might help you limit the noise Feb 18 00:31:43 Sooo much noise =( Feb 18 00:31:53 you can find it on GitHub, Jake Wharton has a version, and I have a fork of it Feb 18 00:32:23 Mittendeep: What info are you looking for? Feb 18 00:33:06 You can use tags (e.g., 'Log.i("CustomTag", "Foo is null");') and in Android Studio you can text-search LogCat. Feb 18 00:34:24 I have to use Eclipse and ADT for class. I was hoping I could grab some useful info other than all this ZygoteInit stuff. Feb 18 00:36:24 What useful info were you hoping to find? Feb 18 00:37:09 A line number or else debug info that wasn't so verbose and useless at the same time. Feb 18 00:38:07 read up the logcat, that should all be there in your exception output Feb 18 00:39:18 MikeWallaceDev: it changes nothing Feb 18 00:43:00 It is a null pointer, something is trying to check a null object's length on creation. I can't remember exactly what I had done so I just ended up undoing a bunch of stuff. Feb 18 00:44:47 You'll see a line number in an exception stack trace. Feb 18 01:14:01 So there may be some legal issues with redistributins a certain .jar. Is there a way to build a lib that references classes in that .jar without ordering and exporting the .jar? Feb 18 01:14:34 basically forcing the dev to DL the .jar themselves Feb 18 01:14:37 Mittendeep: Wai? Feb 18 01:15:03 tricknology that violates play tos anyhow Feb 18 01:15:15 all updates have to happen from play Feb 18 01:15:28 This is a litlte far removed from play Feb 18 01:15:57 I mean by the time it gets to play the developer wil have included the jar Feb 18 01:16:08 I just don’t want to pack the two together and distribute it in one fat jar Feb 18 01:16:12 the gesture doesnt work, i have try every thing Feb 18 01:16:15 tricknology: From what I’ve heard, that’s kinda how building with android is handled. Your app links against a shim jar, and the real stuff is on the phone Feb 18 01:16:15 is there anything like cwac-merge for recyclerview? i found one gist which seems half baked Feb 18 01:16:18 TacticalJoke: I was looking for a way to filter join/leaves from the channel using HexChat, I think I found a plugin though. Feb 18 01:16:39 <_genuser_> anybody implement a gallery where you keep swiping the picture left or right to go up or down the list? Feb 18 01:16:47 Just want jar A and jar B, Jar A requires Jar B to function correctly but Jar A should compile without Jar B Feb 18 01:17:16 s73v3r, I figured it was possible just tryign to figure otu the best wayt o do it Feb 18 01:17:37 right now I’m doing it with Libararies Feb 18 01:17:53 <_genuser_> shim! Feb 18 01:17:57 and adding references to other projects Feb 18 01:18:35 btu when it comes time to export library A, I don’t want .jar B in there Feb 18 01:18:59 maybe I’m not explaingin myself correctly.. it’s late Feb 18 01:19:26 I get exactly what you want. I just don’t know how to do it :( Feb 18 01:19:52 essentially you want to be able to treat jar B as a shared library, and not export it Feb 18 01:22:41 I've got a weird requirement. I need a way to inject a String from an app into a shared module. The shared module is a ContentProvider, but I need the app to determine it's authority. (Simple: I want to create many apks, with identical CPs, but different authorities) Feb 18 01:22:44 does anyone know why the ndk is distributed as an executable .bin file on linux, while the sdk is a plain zip? Feb 18 01:22:45 Any ideas? Feb 18 01:23:25 an intent param? Feb 18 01:23:53 MikeWallaceDev gradle lets you do that Feb 18 01:24:02 how g00s ? Feb 18 01:24:22 MikeWallaceDev: i think i should use swipe pager Feb 18 01:24:24 I have to put it in the app gradle, not the shared module gradle... Feb 18 01:24:26 its better Feb 18 01:24:42 MikeWallaceDev look up placeholder support Feb 18 01:24:50 I already have that Feb 18 01:24:54 g00s, Feb 18 01:25:09 http://tools.android.com/tech-docs/new-build-system/user-guide/manifest-merger#TOC-Placeholder-support Feb 18 01:25:12 ah, nm Feb 18 01:25:31 God, I'm tired too.... sigh Feb 18 01:25:38 the authority part already works Feb 18 01:25:47 it's the URI part that doesn't Feb 18 01:26:18 the CP is declared in the manifest, with the correct authority (using placeholder) Feb 18 01:26:37 but then , in the CP, I don't know the authority so that I can create a UriMatcher Feb 18 01:26:58 Unless I can reference that placeholder from code too? Feb 18 01:30:47 Nope. Feb 18 01:37:22 <_genuser_> if anyone needs a heater for winter, buy a surface pro 3 Feb 18 01:38:07 =P Feb 18 01:39:43 _genuser_ it works better than the nexus 9 ? Feb 18 01:41:05 <_genuser_> g00s: are you asking or telling? if you're asking, I don't know. I don't have a nexus 9. Feb 18 01:41:27 n9 gets hot too Feb 18 01:41:46 <_genuser_> main reason for SP3 was Manga Studio and other drawing apps so I could use the digitizer and pen pressure sensitivity. Feb 18 01:42:01 ahh Feb 18 01:42:31 <_genuser_> this thigns gets so hot that the fan goes very loud. you drain battery power % per minute at that point. so 7 hours, right! it will be gone in about an hour. Feb 18 01:42:59 <_genuser_> if you can buy an external fan that blows on it and you dock it, it will probably perform well. Feb 18 01:42:59 oh my doesn't sound right :( Feb 18 01:43:31 <_genuser_> but in a lap while using it as a drawing tablet, it's super hot. and of course the CPU then throttles to 700MHz. Feb 18 01:43:43 <_genuser_> and interwebs is full of people complaining about sp3. Feb 18 01:44:03 <_genuser_> some units get so hot, they show a thermometer and shut down. you can't start them again until they cool off. Feb 18 01:51:02 Is there are problem with a ContentProvider's UriMatcher not being static? Feb 18 01:56:26 _genuser_: yeah, stuff like that keeps me from wanting a surface. they're impressive in a lot of ways, but they're under-powered for their screen, and have issues with heavier use. Feb 18 01:57:37 _genuser_: I have a wacom pad, but I gather the ntrig digitizers are more accurate e.g. at the edges? don't suppose you've tried both / have any opinion on the SP3's digitizer behavior? Feb 18 01:57:47 i have to applaud MS for trying though. i think they are more interesting than google in that space , tablets, etc Feb 18 01:58:19 g00s: Google makes tablets too, you know :) Feb 18 01:58:27 yes i have one, but its a toy Feb 18 01:58:52 <_genuser_> groxx I have the the wacom cth-480 (think they call it bamboo now) Feb 18 02:00:15 Just a quick question. is there a nice way to combine buffer from a audio file to a microphone buffer. Feb 18 02:00:27 sort of likea mix-down as such . Feb 18 02:02:09 <_genuser_> groxx: at the exterior .25-.5 inch, I feel the pen kinda goes off on the ntrig (sp3). top left corner being the most inaccurate. but mostly that's covered by toolbars. Feb 18 02:03:39 <_genuser_> groxx: on sp3 using wintab drivers. on the desktop (wacom) using tablet pc drivers, lol. Feb 18 02:05:19 _genuser_: funky Feb 18 02:05:40 is there a way to programatically dismiss the soft keyboard? Feb 18 02:06:26 <_genuser_> groxx: overall, the wacom tablet has that resistance they claim makes you feel like you're on paper. but all it does is burn the nib faster. I prefer the smooth feel of the sp3 glass, tbh. Feb 18 02:06:39 <_genuser_> groxx: when drawing on real paper, don't mind the paper feel. Feb 18 02:07:06 burn the nib? Feb 18 02:07:15 they actually wear out? Feb 18 02:07:52 _genuser_: yeah, you get used to either. and I call BS on "like paper". Feb 18 02:08:43 <_genuser_> groxx: do you have a cintiq or just the non screen tablet? Feb 18 02:08:50 _genuser_: a while back I tried using a slab of hard acrylic as a backing for drawing. I love it. Feb 18 02:09:06 _genuser_: intuos 3 :) and mostly gathering dust. Feb 18 02:09:59 <_genuser_> groxx: wouldn't mind a cintiq because of the extra external buttons, etc. but those are expensive. Feb 18 02:10:00 _genuser_: I kinda dove into coding, and love it, but it does mean my artistic half is pretty neglected. Feb 18 02:10:22 _genuser_: yeah. have you seen the intuos 3 + iPad screen mods? Feb 18 02:11:10 <_genuser_> groxx: no, I haven't. those'd be cool. guess I was liking the 13" cintiq so you could just sit around the house and do it. the 24" ones aren't exactly the type you drag in front of your tv, lol. Feb 18 02:12:16 _genuser_: yeah. I've been curious about them, but the prices are ridiculous. Feb 18 02:13:19 iPad mod is on my to-do list though. it's about $200 total, and then you get a huge resolution. Feb 18 02:13:41 <_genuser_> yep, that's why I'm hoping sp3 can get their act together. Feb 18 02:13:47 plus way thinner glass Feb 18 02:15:26 <_genuser_> don't even know why wacom has two lines, just make the one and be done, lol. why do screen and no screen. Feb 18 02:15:30 <_genuser_> other than money, of course. Feb 18 02:17:24 _genuser_: at least they haven't gone the Dell route, with infinity lines with confusing and overlapping naming schemes. Feb 18 02:18:40 <_genuser_> groxx: heh. also it gives us n00bs a way to do digital art. Feb 18 02:18:46 <_genuser_> "art" being subjective here. Feb 18 02:20:01 _genuser_: haha, totally :) I'm a few years out of my art minor now. definitely just "art" for me. Feb 18 02:20:53 I mostly like the wacom surfaces, it's just weird that they haven't dramatically dropped in price in ever. Feb 18 02:21:24 the screen/surface disconnect never bothered me Feb 18 02:22:40 <_genuser_> groxx: it didn't bother me either when it was my only unit. but after the sp3, I went back to it, and it was disorienting. Feb 18 02:23:05 <_genuser_> and the feel of it was quite harsh. and I had the thought that I'm scratching off the nib and it's being wasted. Feb 18 02:36:54 would it be bad form to add a string to my db that is just an arrayList.toString()? Feb 18 02:37:16 then i would parse the string back because i know the data structure Feb 18 02:49:24 how can I set the status bar programmatically from my Activity? I am able to call it on a DrawerLayout, but I need to call it on a detail activity Feb 18 02:49:46 DadFoundMy: why dont you just serialize it into a BLOB column. Feb 18 02:49:58 also, sorry if any of you missed me lol I've been gone while we had our first baby! :) Feb 18 02:50:12 drinfernoo: what? Feb 18 02:50:21 which what? Feb 18 02:50:27 wat? Feb 18 02:50:33 drinfernoo: wat. wat. wat. status bar? Feb 18 02:50:43 indeed Feb 18 02:50:53 the color of it Feb 18 02:55:22 I'd like to change it programmatically Feb 18 02:56:22 drinfernoo: do you mean the ActionBar? Feb 18 02:57:09 no, I've got that covered Feb 18 02:57:20 using a Toolbar, you can do that with setBackgroundColor Feb 18 02:57:29 I'm talking about the android system status bar Feb 18 02:57:48 drinfernoo: you can only set that on Lollipop Feb 18 02:57:50 which is usually set by your theme's colorPrimaryDark, but I want to change t at runtime Feb 18 02:58:04 I am targeting lollipop Feb 18 02:58:55 getWindow().setStatusBarColor(0xFF330033); // color val Feb 18 02:58:59 I will have to have a fallback, since I'm minSdk=15, but I'll work that out Feb 18 02:59:20 cool I couldn't figure out where setStatusBarColor came from Feb 18 02:59:24 whats the best way to get an applications context from a class? Feb 18 02:59:44 DadFoundMy: which class? Feb 18 02:59:47 in this case a class that extends SQLiteOpenHelper **** ENDING LOGGING AT Wed Feb 18 03:00:00 2015