**** BEGIN LOGGING AT Thu Dec 04 02:59:59 2014 Dec 04 03:01:23 Groxx: Something like this? String sql = "UPDATE myTable set NameColumn = null"; db.execSQL(sql)? Dec 04 03:03:43 TacticalJoke http://phandroid.com/2014/12/03/google-news-weather-gains-dark-theme-option-in-latest-update-will-more-google-apps-follow-suit/ Dec 04 03:03:55 my app has light / dark theme Dec 04 03:04:11 someone might be able to see it some day heh Dec 04 03:05:43 Nice. :D Dec 04 03:05:51 What kind of app are you working on, if you don't mind my asking? Dec 04 03:07:03 I can understand Mr. Wharton's mini-rant about Reddit-app themes, since many Reddit apps just try to look good. They seem to give little thought to actual usability. In my case, the themes will be minimal (probably just light/dark, as you say), just for the sake of differing taste. Dec 04 03:07:04 its a weather app Dec 04 03:07:21 tastes* Dec 04 03:08:01 yeah, i dont understand the whole theming thing myself. not like i have desktop FF purple, chrome blue, AS monokai ... Dec 04 03:08:37 i guess a few people like that on mobile. now if you could apply the theme across all apps, thats different i guess Dec 04 03:08:46 Personally, I see a Reddit client as like a code editor: you spend hours every day looking at it. It has to look just right. :D Dec 04 03:08:48 i think jasta worked on that for tmo Dec 04 03:08:56 it got sucked up into CM Dec 04 03:09:04 Yeah, that'd be cool. Dec 04 03:09:11 hours a day looking at reddit? wat Dec 04 03:09:32 I don't read Reddit much lately, but there have been times in the past where I've read threads for hours. Dec 04 03:09:38 your app needs to limit that, to say 20 minutes, and tell them to get off their ass Dec 04 03:09:41 lol Dec 04 03:10:37 ./r/AskReddit is good to get lost in. I'm also partial to /r/AdviceAnimals, /r/cringe, /r/cringepics, /r/trashy, and so on. Dec 04 03:10:51 ./r/funny is so bad lately. It's literally 13-year-olds. Dec 04 03:11:01 i look at /r/earthporn once in a while Dec 04 03:11:04 Yeah, that's nice. Dec 04 03:11:10 ./r/waterporn is great, along those lines. Dec 04 03:12:12 ./r/funny is now posts like "Hay guise, imagine if it rained lemon juice. We'd all get stingy eyes! lolol" (+3479) Dec 04 03:12:25 I hate having to type that period. Stupid mIRC. Dec 04 03:13:32 Now that I think of it, I might just have a "light theme" and a "dark theme". That's way easier than juggling five different themes. Dec 04 03:13:41 And then I can make sure each theme is really good to look at. Dec 04 03:16:06 i keep trying to rx all the things and getting into big trouble :( Dec 04 03:16:19 in the beginning, just here and there ... now getting more ambitious :) Dec 04 03:16:27 really forces you to think about the flow of data in your app Dec 04 03:16:36 I've never tried anything like that. I should look into it. Dec 04 03:16:56 Confucius backs me up on the theme thing: "Life is really simple, but we insist on making it complicated." Dec 04 03:26:59 Looking for a builder to help. Dec 04 03:28:10 Aww, awesome. I've refactored away my God class. Dec 04 03:28:16 My app is now an atheist. Dec 04 03:29:24 Haha! Dec 04 03:30:35 Can anybody help with an error I get when attempting to build? Dec 04 03:31:59 I probably can't, but your chances of getting help rise enormously if you just ask. :) Dec 04 03:33:00 Lol I don't know how I'm supposed to ask. I been trying to figure this thing out for days and no google search in the world has helped. Dec 04 03:38:03 What does it relate to? Dec 04 03:39:45 It's related to a samsung admire SCH-R720. It's an old phone but I got it for free lol. I set up a build env and got the source from git hub for the device tree, vendor tree, and kernel. Dec 04 03:40:39 when I run brunch it tells me threes no profile even though it gets listed in a menu Dec 04 03:40:46 I'll paste the error if you want Dec 04 03:42:17 N maybe you can help me understand it more. Dec 04 03:44:03 Is this some kind of ROM question? I don't really know much about that, and I'm not sure what the best channel is. Dec 04 03:44:54 yes it is, and no this isn't the right place for it Dec 04 03:44:59 Yeah it's related to building a rom from source. I've done it before for another device but this time I can't get it to go. Dec 04 03:45:01 Hi, is there a way I can uninstall some stuff from the Android SDK Manager? I'm running out of space on my desktop (really small hard drive) and I'm getting a new laptop soon, so I'm trying to remove what I can from here if I don't need it Dec 04 03:45:12 FUUUUU. Excuse me guys. Dec 04 03:45:19 I'm sorry Dec 04 03:45:34 I did it again. smh. Dec 04 03:45:34 laspahr_mint17: Yeah, you can check items and select to remove them. Dec 04 03:45:44 geofferey: Are there forums for that? Dec 04 03:45:51 I feel like I've seen forums for that kinda thing. Dec 04 03:45:55 but that removes them, and they can't be downloaded again correct? Dec 04 03:46:00 Obvsly not that exact query, though. :D Dec 04 03:46:23 laspahr_mint17: I think they can be downloaded again. Dec 04 03:46:42 Okay, and really I guess it doesn't matter anyway :) thanks! Dec 04 03:47:25 I'm not sure what forums there are. I always read go to irc but I can't find any good ones. Dec 04 03:47:37 I'm not even sure there is a good place on irc now lol Dec 04 03:48:09 I'm pretty sure there isn't a good place on IRC - but that doesn't mean the answer is to go to the wrong place Dec 04 03:48:11 I'm so stupid I clicked the wrong tab cause this one is right by cyanogen-dev Dec 04 03:48:16 Is this one? http://forum.xda-developers.com/ Dec 04 03:52:11 is there an apk where things like android.app.Activity live? Dec 04 03:55:18 I don't think the framework components get packaged into an APK. Dec 04 03:55:19 Why do you ask? Dec 04 03:55:20 Leeds do you know the difference between libreoffice fresh / still ? O.o Dec 04 03:56:32 TacticalJoke: i'm working on something and wondered about loading those (dex)classes to help do what i want Dec 04 03:56:49 Oh, gawd, I'm gonna have the most painful rebase/merge. Dec 04 03:57:26 One of my lines isn't quite happy that I've changed basically every file it's touched. Dec 04 03:58:07 Niya: Are you not writing an app? Dec 04 03:59:54 TacticalJoke: no. i'm working with apks and the framework outside of a device =) Dec 04 04:01:20 This is awesome. I now have Comment, CommentListing, CommentListingDownloader and Post, PostListing, PostListingDownloader. Dec 04 04:01:32 Consistency is so satisfying. Dec 04 04:02:03 =D Dec 04 04:33:36 The builder pattern is pretty neat. Dec 04 04:33:45 I think I prefer it to named parameters. Dec 04 04:33:50 Though it is more verbose. Dec 04 04:49:59 its been so long since i wrote a proposal / bid heh, i hate getting janked out of 'writing code' Dec 04 04:50:16 * g00s wishes real world would stop pestering him Dec 04 04:51:03 i want to change what's in a Spinner based on what value topicSpinner is selected by my id always = 0. where am i going wrong? http://pastie.org/9759653 Dec 04 04:51:22 * g00s hates spinner, runs Dec 04 04:55:16 String selected = "topic_" + topicSpinner.getSelectedItem(); Dec 04 04:55:26 What does topicSpinnder.getSelectedItem() return? Dec 04 04:55:31 Spinner* Dec 04 04:58:09 TacticalJoke it returns topic_{Mathematics|Biology|English|Chemistry|...} Dec 04 04:59:55 errm, Mathematics|Biology|... based on whatever the topicSpinner has selected Dec 04 05:10:18 sevenTwo: Try logging stuff with Log.i(). Dec 04 05:12:51 TacticalJoke i did that's how i could tell you what the values were. i just trimmed it down so it's more readable Dec 04 05:16:37 sevenTwo: You're looking for "topic_Foo" when the data uses "topic[s]_Foo". Dec 04 05:16:59 omg Dec 04 05:20:41 TacticalJoke damn. the id still comes out to be 0 (ie. not found). is there a better way to grab the dataset? i mean, i can always throw all that crap into a hashmap but i wanted to keep that stuff separated from the application code Dec 04 05:22:14 I guess you could create some kind of "database" class that loads all those arrays. It then provides access to them based on an index. Dec 04 05:22:40 Your Activity then just says "whateverDatabase.getBiologyTopic(someIndex);". Dec 04 05:24:23 The database/whatever class can be given a Context on which to call getResources and so on. Dec 04 05:26:11 Note that you could make your life simpler by using plain Java arrays, but I don't know whether that's a good idea or not in your case. Dec 04 05:27:00 i think if i just stick some sort of hashmap into the activity class, it's probably the easiest way Dec 04 05:28:20 thanks Dec 04 05:30:16 hi Dec 04 05:30:40 it seems that the bufferedinputstream has not the available method even though there is on the android develoipper guide Dec 04 05:37:35 Hi all Dec 04 05:38:37 I have settings page which pops up with a list if information.I have kept them under Dec 04 05:39:49 Among the list of info I have an About Application link. On clicking on it another settings page should appear. So I should be having a second ? Dec 04 05:53:26 so quiet :) Dec 04 05:53:33 https://www.youtube.com/watch?v=m-MoL1ON2hM Dec 04 05:53:37 not any more \o/ Dec 04 05:54:10 (this is better than gangnam style) :D Dec 04 05:57:43 so in my SharedPreference object I specifiy a prefs file to open and read/write to/from. How does one link that to the PreferenceFragment that auto does all that magic? Dec 04 06:04:03 pfn: hello, I know where is the problem for error. But I want to know why I get only one line of error when application is running on device and why I get full stack error message when application is running on emulator. http://paste.ubuntu.com/9362779/ Dec 04 06:04:07 I guess you can't make the PreferenceFragment work on any random sharedprerences file. Dec 04 06:04:53 pfn sorry, this question is not only for you Dec 04 06:05:53 ugh, nm. the docs cover this. Dec 04 06:16:51 for material theme where does cancel button go for a dialog? Dec 04 06:17:17 like should i do CANCEL CONFIRM at bottom or CONFIRM at bottom and some kind of X icon towards top right? Dec 04 06:17:35 did they switch it again ? Dec 04 06:17:37 hehe Dec 04 06:17:43 ive seen both Dec 04 06:17:48 but not sure for a dialog what to do Dec 04 06:17:50 hahahaha Dec 04 06:17:55 if dialogs even exist in material design? Dec 04 06:18:05 i've been using floating activities Dec 04 06:18:21 like aren't they something more sublime, a slightly floated window with a seamless transition to the UI below Dec 04 06:18:24 yeah Dec 04 06:18:37 a floating activity in an activity? Dec 04 06:18:46 its just a theme thingy Dec 04 06:18:49 they do it in iosched Dec 04 06:19:00 for dialog? Dec 04 06:19:14 oh no, i think they still use dialogs for a few things Dec 04 06:19:21 like yes / no :) Dec 04 06:19:32 yeah Dec 04 06:19:56 so the material design compat library is some new views and a lot of api related to animation/transitions? Dec 04 06:20:03 *new views = widgets Dec 04 06:20:07 how to insert data into the settings window dynamically.Like how to display user id and last logged in information in the settings? Dec 04 06:20:24 whose settings? Dec 04 06:20:52 no new widgets in appcompat Dec 04 06:21:01 no animations either Dec 04 06:22:12 app settings.The one which uses Dec 04 06:22:13 do the animations i see in material theme be part of the new api ? Dec 04 06:22:14 some stuff is implemented internally as subclasses Dec 04 06:22:20 of course Dec 04 06:22:38 these are only avail for 5.0 + ? Dec 04 06:23:42 of course Dec 04 06:25:34 so animation transitions emulating whats avail for api 5.0 + has to be manually done if i am trying to support the same theming on older devices? Dec 04 06:25:48 anyone know if 2.3 < is legitimatly dead now? ;p Dec 04 06:26:01 heh, not according to ravioli Dec 04 06:26:12 argh, i mean -- i'd still have to do it manually on 4.x ? Dec 04 06:26:42 yes, you would do it manually Dec 04 06:26:49 wonderful Dec 04 06:26:50 ie, don't bother Dec 04 06:26:54 :D Dec 04 06:27:10 why waste effort on it Dec 04 06:27:18 lasserix i keep finding weird bugs in appcompat, i hope your ass doesn't depend on it Dec 04 06:27:20 cause i like responsive, flowing UI Dec 04 06:27:28 then run 5.0 Dec 04 06:27:32 easy Dec 04 06:27:32 its still in its early stages. fine for hobby stuff Dec 04 06:28:06 weird bugs or doing it wrong? Dec 04 06:28:18 5.0 is not even on android dashboards Dec 04 06:28:19 I should try toolbar, but I have no reason Dec 04 06:28:24 weird bugs. in tracker. discussed by many Dec 04 06:29:00 the thing is the material design philosophy makes it fairly easy implement design Dec 04 06:29:02 I have experienced no bugs in appcompat so far, but I haven't tried toolbar yet Dec 04 06:29:41 I've encountered corner cases where programmatically creating widgets doesn't tint them, but that's to be expected Dec 04 06:31:25 hi, is there a way to implement timer with progresss bar? Dec 04 06:33:40 no never Dec 04 06:34:05 that would violate laws of physics and causality--what are you? trying to destroy the structure of spacetime? Dec 04 06:34:45 lasserix i do that all the time Dec 04 06:35:00 g00s but it's not working! Dec 04 06:35:47 this GCM info is worth its weight in gold https://blog.pushbullet.com/2014/02/12/keeping-google-cloud-messaging-for-android-working-reliably-techincal-post/ Dec 04 06:36:05 the kind of stuff sometimes missing from the docs that leaves you in tears Dec 04 06:49:38 Why I can't see Log.w, Log.d and Log.v meassages in logcat when app is running on device? Dec 04 06:56:17 slani there is a level filter Dec 04 06:56:19 make sure its not e Dec 04 06:56:21 or whatever Dec 04 06:56:40 also sometimes i have to switch tabs in the logcat before it'll start showing to the start-up/default filter Dec 04 07:07:09 In an XML file I have two buttons that are not visible at the same time (set to visible/invisible programmtically). I'd like for both buttons to be at the same place in the layout, but the second one is underneath the first. How can I correct this? Dec 04 07:08:30 is there a guideline for padding margin for mateiral? Dec 04 07:09:06 ahh nm http://www.google.com/design/spec/layout/metrics-keylines.html#metrics-keylines-keylines-spacing Dec 04 07:09:59 Oh, should use GONE not INVISIBLE. Dec 04 07:13:26 too many new things i am coming across Dec 04 07:16:54 wow, the numbers are in : iphone 6 sold so well, apple got suge share jumps in US, australia, UK, japan Dec 04 07:16:56 is material design based on a fibonacci aspect ratio? Dec 04 07:19:14 check it! http://postimg.org/image/bbgx6sdpn/ Dec 04 07:19:43 conspiracy is afoot! the illiuminati and reptiles are trying to brain wash us by redefining our technologically interface aesthetics!!! Dec 04 07:21:14 lasserix i dunno, you saw the icon for AS right ? kinda looks like freemasons but without the square Dec 04 07:21:31 lasserix i think you should submit this to alex jones Dec 04 07:21:35 hehe Dec 04 07:22:07 here i fixed it http://postimg.org/image/yo7c0362n/ Dec 04 07:22:10 who is alex jones? Dec 04 07:23:52 conspiracy theory guy Dec 04 07:25:06 ah Dec 04 07:25:34 https://github.com/SiegenthalerSolutions/QuantumPaper Dec 04 07:30:41 really terrible example screenshot Dec 04 07:35:50 oh no, Holo everywhere lives ! Dec 04 07:38:50 g00s: have I told you about my encounter with aws? Dec 04 07:39:10 thepoosh no Dec 04 07:39:41 they updated to their API version 2.* Dec 04 07:39:53 and the documentation forgot to add too many relevant things Dec 04 07:39:54 https://github.com/aws/aws-sdk-android/issues/23 Dec 04 07:39:57 like that Dec 04 07:40:04 took 4 hours to find Dec 04 07:40:07 assholes! Dec 04 07:40:11 does bufferedreader read ahead of the input stream ? Dec 04 07:41:00 Marlinski: that's what the docs say Dec 04 07:41:03 http://developer.android.com/reference/java/io/BufferedReader.html Dec 04 07:41:24 I have an inputstream in, and a bufferedreader r wrapping around (in), if I read say 10 bytes out of 20, and then try to read the 10 remaining with inputstream, is it fonna work ? Dec 04 07:41:28 :) Dec 04 07:41:44 maybe I should mark and reset first Dec 04 07:41:55 yeah Dec 04 07:42:01 its not dump'n'flush Dec 04 07:42:03 its buffered Dec 04 07:42:58 hmalright Dec 04 07:45:47 hey Dec 04 07:46:27 if I have a listview inside a viewpager, and I populate this listview with images loaded by picasso, and I skip loading every other image Dec 04 07:46:47 then picasso will load images into the imageview I didn't want to load anything into Dec 04 07:47:06 either call cancelRequest or pass null as the URL on the ones you don't load things in to Dec 04 07:47:26 why does it happen though? Dec 04 07:47:31 because the views are recycled Dec 04 07:47:58 how does that work? Dec 04 07:48:24 A view is passed to one item, then not used, then passed to another, then used and both gets images loaded into them? Dec 04 07:49:23 http://android.amberfog.com/wp-content/uploads/2010/02/listview_recycler.jpg Dec 04 07:49:34 I am using android kitkat on a vm and I want to transfer files from my computer, is there anyway to do that ? ( its orcale vm virtualbox ) Dec 04 07:51:31 JakeWharton: what is the actual difference between holder pattern and the new RecyclerView? Dec 04 07:51:41 Hercules: adb pull Dec 04 07:52:23 thepoosh: Can u please guide me the steps for doing it ? Dec 04 07:52:36 Searching for its from yesterday. Dec 04 07:52:39 it* Dec 04 07:53:14 JakeWharton: thanks man! Looks like a valuable blog for a new android dev =) Dec 04 07:53:30 i've never seen the blog before, just searched for the image Dec 04 07:54:14 thepoosh ? Dec 04 07:54:32 Hercules: don't nudge it's not pollite Dec 04 07:54:34 http://forum.xda-developers.com/showthread.php?t=2141817 Dec 04 07:54:59 if I said something wrong sorry Dec 04 07:54:59 oh okay. can you recommend any? stackoverflow, github and android dev pages have been my main resources so far. But if I just wanna learn about random cool stuff they're too specific Dec 04 07:55:02 Hercules: http://developer.android.com/tools/help/adb.html#copyfiles Dec 04 07:55:26 I am still of 14 , so doesn't know english well, still learning cause english isn't my native language Dec 04 07:55:38 i have a silly question. i just created a new project in android studio 0.8.1.4 but i can't find the layout xml file which is usually in the res directory. where did it go? Dec 04 07:55:39 fuck Dec 04 07:55:46 respect man Dec 04 07:56:01 thepoosh: traditional view holder is tightly coupled to presentation. RecyclerView tries to decouple them more. Dec 04 07:56:28 hmmm, I saw a blogpost talking about complete decoupling with custom views Dec 04 07:56:32 what say you? Dec 04 07:56:47 that would be more coupling Dec 04 07:56:53 i created a google play service activity. doesnt that come with a screen? Dec 04 07:57:09 crap. ive been using android studio for 2 years Dec 04 07:57:13 wtf Dec 04 07:57:21 nubnub: it hasn't existed for 2 years, so... Dec 04 07:57:36 JakeWharton: since it began then Dec 04 07:57:47 may 2013 seems like the first release Dec 04 07:57:55 yes, at Google I/O Dec 04 07:57:57 JakeWharton: he wrote that it's proper MVC because the View part is purely in the view Dec 04 07:58:20 you could easily have been using IntelliJ IDEA for a decade, though Dec 04 07:58:43 well, i used eclipse before that and good riddance Dec 04 07:58:55 what a POS that was Dec 04 07:58:56 it has it's advantages Dec 04 07:59:30 JakeWharton: this -> http://blog.xebia.com/2013/07/22/viewholder-considered-harmful/ Dec 04 07:59:40 anyway, does a google play services activity not come with a layout xml file? Dec 04 07:59:42 i'm not against custom views Dec 04 07:59:47 but that post is stupid Dec 04 07:59:51 hmmmm Dec 04 07:59:52 view holder is not harmful Dec 04 07:59:55 mmmmkay Dec 04 07:59:58 stupid click-baity title Dec 04 08:00:04 yeah Dec 04 08:00:08 but I read it through Dec 04 08:00:14 anyone? Dec 04 08:00:17 and in theory he had some sense in it Dec 04 08:00:36 its a good article, forget the clickbait Dec 04 08:00:45 i just said i wasn't against custom views Dec 04 08:00:45 oh right! Dec 04 08:00:52 it has nothing to do with view holder though Dec 04 08:00:55 g00s: brought it tom my attention Dec 04 08:00:57 from an inputstream, how can I first read an unknonwn number of char (that ends with CRLF) and then read a binary stream ? Dec 04 08:01:09 hence why it's a stupid article Dec 04 08:01:20 cause I used bufferedinputstream but it mess with the inputstream and I cannot properly the following bytes from the in Dec 04 08:01:20 it frames the whole value proposition wrong Dec 04 08:01:22 title is click bait but article provides nice introduction to using custom views Dec 04 08:01:33 that too Dec 04 08:01:38 I was thinking of a pushedbackinputstream but i am not sure Dec 04 08:01:39 *custom viewgroups/compound views Dec 04 08:01:52 or i should just say, compound views Dec 04 08:01:53 lasserix: I always treated custom views as things that mess with drawing on the screen Dec 04 08:01:53 Hello everyone Dec 04 08:01:59 yeah Dec 04 08:02:02 compound views is what i mean Dec 04 08:02:06 yep Dec 04 08:02:15 it set me strait Dec 04 08:02:18 turlando: hi Dec 04 08:02:41 JakeWharton: do you use flow for handling view stack? Dec 04 08:02:44 no Dec 04 08:03:14 do you have any generalized method set for doing that? Dec 04 08:03:19 But it was mentioned that you guys stripped out fragments and went with different root (using views instead) Dec 04 08:03:29 i was trying to make a kind a wrapper for add/removeView (at least to handle back) Dec 04 08:03:33 Will these internal libraries be released? Dec 04 08:03:44 maybe Dec 04 08:03:50 flow was already released despite my best efforts to kill it Dec 04 08:03:54 I think i read this in the advocating fragments blogpost Dec 04 08:03:55 heh Dec 04 08:04:35 lasserix: our backstack is just a Deque where Entry is just a Parcelable (think: url) + SparseArray (view state) Dec 04 08:04:37 If you have an internal library which handles view navigation instead of using fragments, please release Dec 04 08:04:38 ;( Dec 04 08:04:48 kevel1: no, it's written exactly for my use case Dec 04 08:04:49 JakeWharton: ahh thanks Dec 04 08:04:56 generalizing would be hard Dec 04 08:05:08 ༼ つ ◕_◕ ༽つ Give Dec 04 08:05:10 the fragment API is an abomination because it's over-generalized Dec 04 08:05:10 aw Dec 04 08:05:12 ok.jpg Dec 04 08:05:13 :( Dec 04 08:05:30 hmmm Dec 04 08:05:40 kevel1: i was thinking about for my own purposes just doing an extended relative layout as the root, with a hashmap tag->view and an interface (present(Bundle viewargs)) for transitioning Dec 04 08:05:40 JakeWharton: also it's kinda over complicated because of that Dec 04 08:05:45 I'm trying to implement a PreferenceScreen in order to save settings in a SQLite database and not in SharedPreferences, but I can't get it save settings. I overrded onPreferenceChange() and it correctly gets the values, but when I have to get them back they are always to the default values. I do't understand if is an implementation problem or I messed up with the Helper. Somebody could help me? (Code is coming) Dec 04 08:06:06 i swear some people like to wait to post until a conversation is a foot Dec 04 08:06:07 ;p Dec 04 08:06:17 lasserix, i'm also looking at doing something similiar to avoid using fragments Dec 04 08:06:27 kevel1: if i get it working ill post it up Dec 04 08:06:46 i tried doing something the other day but turned out i jumped too far ahead and had to start over Dec 04 08:07:00 turlando: be WAAAY more specific Dec 04 08:07:03 lasserix, i got it working similiar to Flow, except trying to make it a bit easier and less coding having to be written to do shit Dec 04 08:07:06 what exactly is not working as it should Dec 04 08:07:13 flow is too contextual for me Dec 04 08:07:16 trying to not add additional shit Dec 04 08:07:35 add views. transition between views. done. Dec 04 08:07:39 lasserix, yes, I know, but there would be so much code to post that I don't know wgere to start Dec 04 08:07:41 where* Dec 04 08:07:48 add / remove also if needs be Dec 04 08:07:51 turlando: what exactly means "not save" Dec 04 08:07:59 so google play services doesnt come with a screen. whats the logic behind that? Dec 04 08:08:04 do you know if you created an sqlite db? Dec 04 08:08:07 project* Dec 04 08:08:12 was the table created? was the table created as necessary? Dec 04 08:08:18 can you read from the table? Dec 04 08:08:39 has anyone seen SimpleContentProvider for storing data? I recommend it Dec 04 08:08:44 It ties in quite nicely with the content resolver Dec 04 08:08:45 why are you overriding onPrefrences and then using an sqlite database? Dec 04 08:08:59 lasserix, when I go back to the fragment that should get the settings I get default values. I use the db with other tables (but with other Helpers) and just works fine Dec 04 08:09:11 And it handles all the SQL table creation, insertions, deletes, etc for you Dec 04 08:09:22 why are you bothering with the preference layer if you are depositing all this into a sqlite db? Dec 04 08:09:25 well, sorry to trouble youi. Dec 04 08:09:55 https://github.com/xxv/SimpleContentProvider Dec 04 08:10:16 nubnub we didn;t mean to snub you Dec 04 08:10:26 oh nubnub you took it too personally Dec 04 08:10:30 lasserix, feel like cringing? https://github.com/xxv/android-lifecycle/raw/master/complete_android_fragment_lifecycle.png Dec 04 08:10:35 clicketh the linketh. Dec 04 08:10:58 lasserix, I'm using a PreferenceFragment in order to write just the PreferenceScreen xml for the layout (Preferences are set to be not persistent so I can manipulate them manually and get set them to a SQLite datbabase) Dec 04 08:10:59 yeah lets nest it baby Dec 04 08:11:12 I did this before but it seems I'm doing something wrong this time Dec 04 08:11:19 turlando: my guess is you need to reference the same preferences object Dec 04 08:11:35 but since you are not diskwriting them (commiting not whatever the other command is) when you release them Dec 04 08:11:42 you don't get the same one back, hence its empty Dec 04 08:12:09 ie you do like preferencesbynameA.commit then getpreferences("A") but its not saving it in the map for some reason Dec 04 08:12:18 can't you just fire off sqlite in onpreferencechangedlistener? Dec 04 08:12:41 or write it to a field preference object and use that when you need to write it Dec 04 08:12:48 *assign it to and Dec 04 08:12:52 lasserix, can I show you the class and the Helper? Dec 04 08:13:38 kevel1: I just threw up in my mouth a little Dec 04 08:14:13 you can try if you like Dec 04 08:14:15 kevel1 cool, gotta look at that SimpleContentProvider Dec 04 08:14:41 kevel1: https://github.com/SimonVT/schematic Dec 04 08:15:49 SCP features list is a little bloated Dec 04 08:15:56 lasserix, this is the helper class http://pastie.org/private/a9tdts2hccflxd2kkxp3pg | this is part of my PreferenceFragment http://pastie.org/private/fvfgzpok3iomv151bguava in which setDefaults(), setValues() and setListeners() are called in sequence inside onCreate() Dec 04 08:16:13 the last 4 features are standard facts about content providers ;p Dec 04 08:17:13 lasserix, this is the class for the ProfilePreference model http://pastie.org/private/i9dcgxzyrtubzbxvtcq2lw Dec 04 08:17:33 turlando: line 21 in profilepreferenchelper which way does the swtich flow? Dec 04 08:18:15 lasserix, sorry, I didn't understand. which switch flow? Dec 04 08:18:48 Consts.C_PROFILE_PREFERENCES_PROFILE_ID + " = ? AND " + Consts.C_PROFILE_PREFERENCES_KEY + " = ?", Dec 04 08:18:48 new String[] { String.valueOf(profileId), key }, Dec 04 08:19:54 i can't see anything that should be wrong with it really Dec 04 08:20:02 did you verify you are writing anything into the table? Dec 04 08:20:36 lasserix, there is a east way to inspect the database inside the IDE or I have to pull by myself the database from my device? Dec 04 08:20:44 just do a get row count Dec 04 08:20:49 see if you write anything Dec 04 08:20:58 with DDMS you can Dec 04 08:21:00 inspect Dec 04 08:21:04 believe you can adb pull Dec 04 08:21:20 if in debug mode Dec 04 08:21:23 lasserix, launching DDMS then, just a sec Dec 04 08:21:31 you have to pull the database Dec 04 08:21:48 a feature google should have had, 5 years ago Dec 04 08:22:44 lasserix, i prefer scp Dec 04 08:22:56 you can create your provider paths like basic REST uri's Dec 04 08:23:02 because it will handle foreign key creation? Dec 04 08:23:06 which is rather convenient Dec 04 08:23:11 yes it can Dec 04 08:23:41 you can do that with schematic Dec 04 08:23:52 ../user/{id}/interaction/ Dec 04 08:23:58 and super easily with annotations Dec 04 08:24:09 is so much nicer than getting all interactions, by user id, in the selection args of a cursor Dec 04 08:24:13 or query Dec 04 08:24:15 w/e Dec 04 08:24:27 lasserix, I can't really find anything related to sqlite inside the DDMS Dec 04 08:24:36 yeah Dec 04 08:24:39 goto the file browser Dec 04 08:24:50 then goto data/data/your.package.space/databases Dec 04 08:24:51 Oh right, I could have used the shell then lol Dec 04 08:24:54 and look for the db table Dec 04 08:25:04 no i believe you have to do something special in shell Dec 04 08:25:06 but i could be wrong Dec 04 08:25:20 the fact its DDMS means it knows its debugging your app so you can read access that folder Dec 04 08:25:33 don't know if shell will know that so you might not have read access Dec 04 08:25:41 with specifying some command Dec 04 08:26:01 lasserix, I have root access enabled for ADB but it won't let me go inside dara Dec 04 08:26:02 data* Dec 04 08:26:29 su Dec 04 08:26:32 adb shell su Dec 04 08:26:35 grant Dec 04 08:26:37 then you can Dec 04 08:26:38 lasserix: NO Dec 04 08:26:45 why not run-as packagename Dec 04 08:26:45 SU Dec 04 08:26:49 ? Dec 04 08:26:49 ahh Dec 04 08:26:51 thats how you do it Dec 04 08:26:57 yeah that's what i was saying Dec 04 08:27:01 you can just su too Dec 04 08:27:03 A-HA!!! Dec 04 08:27:20 " don't know if shell will know that so you might not have read access Dec 04 08:27:20 with specifying some command" Dec 04 08:27:25 hehe Dec 04 08:27:30 thanks thepoosh Dec 04 08:27:34 np Dec 04 08:27:35 lasserix, su - returns me 255 Dec 04 08:27:48 oh you rooted but didn't install superuser utils? Dec 04 08:27:55 or busybox? Dec 04 08:28:12 lasserix, it returns me 255, not binary not found Dec 04 08:28:13 turlando: forget su Dec 04 08:28:21 turlando: http://stackoverflow.com/questions/22703254/copying-files-in-adb-shell-with-run-as Dec 04 08:28:23 use adb shell run-as Dec 04 08:28:51 err http://stackoverflow.com/questions/9017073/is-it-possible-to-see-application-data-from-adb-shell-the-same-way-i-see-it-moun Dec 04 08:31:04 i have an app which establishes a bluetooth connection, if the connection state changes i want to inform the user with a notification, what is the best practice for in app notifications, should i use toast or system notifications? Dec 04 08:31:20 whats your app do? Dec 04 08:31:32 sh: can't create /sdcard/nw.db: Permission denied Dec 04 08:31:32 sh: can't create /sdcard/nw.db: Permission denied Dec 04 08:31:55 running inside as-app Dec 04 08:32:06 it reads information of a bt serial device Dec 04 08:32:11 run-as* Dec 04 08:33:21 turlando: you need to do it in download or something like that Dec 04 08:33:25 why not just pull Dec 04 08:33:36 turlando: adb shell Dec 04 08:33:40 run-as packagename Dec 04 08:33:46 cd ./databases Dec 04 08:33:51 thepoosh, same error :| Dec 04 08:33:54 chmod +r * Dec 04 08:33:59 then pull to computer Dec 04 08:34:13 sweet unix perms Dec 04 08:34:14 chmod the db files Dec 04 08:34:22 and then pull them Dec 04 08:34:48 thepoosh, they are already readable for the user Dec 04 08:34:57 and the group too Dec 04 08:35:07 -rw-rw Dec 04 08:36:27 I'm the only one who feels like writing more workarounds than actual code while coding on Android? :| Dec 04 08:36:50 (IE: changing separator color for dialogfragments) Dec 04 08:37:13 How can set a system wide font in my app? I tried to set it in my "AppTheme" but I could only select the defaults. How can I use something like Font Awesome Dec 04 08:40:04 vedu load font resource as application class singleton, subclass all et and t's to use it? Dec 04 08:40:26 unless you can modify an xml theme in code at runtime Dec 04 08:40:55 any news on T-mo's android L ? Dec 04 08:41:34 wrenny: what do you mean? Dec 04 08:41:45 turlando: you're really not. Android is not a pleasant environment, but hopefully it'll get better as it matures =) Dec 04 08:41:50 lolipop release Dec 04 08:42:12 ugh, i don't understand samsung's tablet lineup. so fucking confusing, whats the difference between all this crap ? Dec 04 08:42:27 i get the notes are pen input Dec 04 08:42:29 it's been available for a while on some of their devices Dec 04 08:42:37 On the Nexus 5 and shipped on their 6's. Dec 04 08:42:39 c03 from a developer point of view it seems that new apis ease 1 thing and break 13 Dec 04 08:42:43 vedu check out leocadiontines answer http://stackoverflow.com/questions/4395309/android-want-to-set-custom-fonts-for-whole-application-not-runtime Dec 04 08:43:01 lasserix, seems that the problem is the Helper Dec 04 08:43:12 this I know... I mentioned T-mo Dec 04 08:43:13 sqlite> select * from profile_preferences; Dec 04 08:43:13 1|1|only_on_headphones|true Dec 04 08:43:17 it should be false Dec 04 08:43:17 intrigueing please go on! Dec 04 08:43:41 well Dec 04 08:43:46 it could be anything really at that point Dec 04 08:43:53 your helper is writing incorrectly Dec 04 08:43:58 your setter is piping incorrectly Dec 04 08:44:07 your preference is confused about its assignments Dec 04 08:44:08 ;p Dec 04 08:44:32 but at least you're writing something! and of the same cardinality you're expecting! Dec 04 08:44:39 lasserix, I'm thinking about trying that .net thing for android :| Dec 04 08:44:53 its a waste Dec 04 08:44:56 its not that hard Dec 04 08:44:59 just debug it Dec 04 08:45:32 start in your preferences fragment for that value which was wrong Dec 04 08:45:45 and step through until you write it and the problem should present itself Dec 04 08:46:15 if you guys had to choose samsung tablet to test on, what would it be ? Dec 04 08:46:21 g00s slightly better than this https://www.youtube.com/watch?v=hz2MPcsZJcM Dec 04 08:46:42 g00s are you going to be making stuff that works with tvs? Dec 04 08:47:31 and by tablet are you going for big or for moderatly big? Dec 04 08:47:52 don't care about the size, more by popularity Dec 04 08:49:13 galaxy tab Dec 04 08:49:23 lasserix, I put false as default value in the xml and deleted all data for the application, now it is always on false, so the problem is not setDefaults() nor onPreferenceChange(), but setValues()... Dec 04 08:49:54 g00s http://readwrite.com/2013/04/12/samsung-dominates-list-of-top-android-tablets Dec 04 08:50:03 galaxy tab S, tab 4, or tab pro ? Dec 04 08:50:07 jesus those idiots Dec 04 08:50:12 hehehehe Dec 04 08:50:33 BTW, just for reference, I found this script really handyhttp://stackoverflow.com/a/12914297 Dec 04 08:50:39 turlando: actually this is the first thing i said Dec 04 08:50:42 ops, linking again http://stackoverflow.com/a/12914297 Dec 04 08:50:47 which way does the if on line 21 flow Dec 04 08:51:00 lasserix, sorry lol, I lost it trough the chat Dec 04 08:51:05 Plus I just woke up Dec 04 08:51:20 Ohhh Dec 04 08:51:44 oh Dec 04 08:51:49 now it is actually obvious i believe the problem Dec 04 08:51:55 but it is line 21 Dec 04 08:52:04 If there is not entry in the db with that profileId and preference key then it will do an insert, else it will update the present entry with the new value Dec 04 08:52:17 lasserix that was 2013 :P Dec 04 08:52:24 g00s oops Dec 04 08:52:36 its only gotten more confusing now ! Dec 04 08:52:37 Or this is what I wanted Dec 04 08:52:58 10 tips for a backend web getting into android dev -- GO! Dec 04 08:53:22 buy a nexus Dec 04 08:53:36 make sure you know java Dec 04 08:53:36 done! Dec 04 08:53:59 done! (ish, my groovy's a bit weak and I've done mainly work with getty) Dec 04 08:54:06 come up with some simple ideas that would be relatively easy to do as a web, ie, make a business card app or hang man game or soundboard and code them up Dec 04 08:54:08 and learn robo-guice from the get-go Dec 04 08:54:10 notice there was not ... profit part Dec 04 08:54:13 or prepare yourself to write boilerplate! Dec 04 08:54:38 people actually use roboguice? that looked like turd Dec 04 08:54:39 yeah think about reusability from the start and save yourself _a lot_ of time Dec 04 08:54:41 that makes sense (the web -> android) idea Dec 04 08:54:51 bookmark this website https://android-arsenal.com/ Dec 04 08:55:08 g00s: ? Dec 04 08:55:10 if you did web design not just dev familairize yourself with the design principles Dec 04 08:55:28 c03 ! Dec 04 08:55:31 :) Dec 04 08:55:39 jalcine: do everything on this http://developer.android.com/training/basics/firstapp/index.html before you ask about stuff you'd find on that Dec 04 08:55:43 please elaborate g00s Dec 04 08:55:59 that's the kind of links I'd need Dec 04 08:56:03 i just didn't see anything useful in roboguice Dec 04 08:56:07 n00b-purifying questions :) Dec 04 08:56:19 thanks lasserix, c03 and crew Dec 04 08:56:21 jalcine: the best thing you can do is pick a project within your ability, do it from start to finish, move on to something more complex and keep doing this till you feel competent Dec 04 08:56:34 sounds like regular dev work then Dec 04 08:56:41 yeah Dec 04 08:56:45 start with and fly into display: flex Dec 04 08:56:55 you use nix or doze? Dec 04 08:57:14 oh i guess i should also mention get familiar with platform tools and adb Dec 04 08:57:34 nix Dec 04 08:57:39 g00s: skipping boiler-plate, reducing code-size and claryfying code? =) Dec 04 08:58:31 lasserix, that if statement looks fine to me. if there is not such entry it will insert it, else it will update the present one Dec 04 08:58:34 adb, android and fastboot I'm okay with Dec 04 08:59:02 turlando: well debug it then Dec 04 08:59:52 jalcine: then onto http://developer.android.com/training/basics/firstapp/index.html Dec 04 09:00:34 and if you want good source to look at http://square.github.io/ and https://github.com/google/iosched Dec 04 09:02:57 lasserix, could the problem is the get() method? cursor.moveToFirst() returns always true maybe? How can I get if there is >0 entries on the db? Dec 04 09:03:26 found it, getCount(), obviously Dec 04 09:04:32 line 21 Dec 04 09:04:35 :) Dec 04 09:05:43 lasserix, lol I seem dumb Dec 04 09:06:40 lasserix: I might be pinging you quite often in the near future :) Dec 04 09:06:42 lasserix, changed it to if (cursor.getCount() > 0) { cursor.moveToFirst(); ... and still nothing Dec 04 09:06:43 hope you have a gittip Dec 04 09:06:49 in the get I mean Dec 04 09:07:36 turlando: can you use the debugger? Dec 04 09:07:39 I tried to save a file in ExternalPublicStorage in the DIRECTORY_PICTURE, seems to have been working but I cannot see ,y file once mounted Dec 04 09:07:58 Marlinski: yeah once its mounted you can't Dec 04 09:08:03 lasserix, an actual debugger or putting Log.d here and there? Dec 04 09:08:08 actual debugger Dec 04 09:08:20 you can solve this problem in time Dec 04 09:08:25 lasserix, never used a Java debugger, I'm fine with gdb Dec 04 09:08:33 lasserix: I meant I want to actually see the image from my file browser once mounted Dec 04 09:08:49 yeah on some phones you cant since it is mounted Dec 04 09:08:52 lasserix: but even though the file has been written; I donùt see it in Picture folder Dec 04 09:08:57 browser on destkop / or on phone? Dec 04 09:09:20 lasserix: oh ! Dec 04 09:09:31 lasserix: it appears on my phone, not on my desktop Dec 04 09:09:47 so I have to stop my application to see it ? Dec 04 09:09:57 turlando: are you using wrong query method overload? Dec 04 09:10:07 i feel like there's more arguements there than you need for that query Dec 04 09:10:17 Marlinski, what do you mean on your desktop? O.o Dec 04 09:10:21 Marlinski: i think it has to do with the mounting Dec 04 09:10:48 Mavrik: once phone is "mounted" on my desktop Dec 04 09:10:57 mounted as a drive Dec 04 09:11:42 turlando: nm that's not it Dec 04 09:11:44 lasserix, sorry for the bother, can you be more specific? Dec 04 09:11:58 i was thinking maybe you had args in wrong place or something Dec 04 09:12:06 Marlinski, yes? You don't see file appear immediately after creation? Dec 04 09:12:26 from the phone file browser I can see the files Dec 04 09:12:33 but not from the Desktop file browser Dec 04 09:12:47 hmm maybe it has to do with the fact that I forgot to happen the file extension Dec 04 09:12:52 .jpg Dec 04 09:13:01 lasserix, mmm sure? I don't see args problems... Dec 04 09:13:09 turlando: also you should be using try / finally for your cusor db operations ie try { cursor c = db.query } finally { c ? null : close | Dec 04 09:13:14 now that it is mounted as a media device instead of USB device probably it fails to detect fileds Dec 04 09:13:16 i said nm Dec 04 09:13:24 Marlinski, that's the usual behaviour Dec 04 09:13:30 you're not going to see new MTP files until cache gets updates Dec 04 09:13:33 *updated Dec 04 09:13:45 did you register your new image with mediascanner? Dec 04 09:14:18 turlando: btw you have a strange table form Dec 04 09:14:36 well nm i take that back to each other own schema Dec 04 09:14:44 Mavrik: nop Dec 04 09:14:49 Mavrik: at least not yet :) Dec 04 09:14:55 lasserix, strange from which point of view? Dec 04 09:15:00 Mavrik: any usefull link about that ? Dec 04 09:15:19 lasserix, given that I'm not a Java monster, I've never seen the finally construct :| Dec 04 09:15:41 Time to learn it then. Pretty much all languages have it. Dec 04 09:16:03 turlando: do the ids or keys changebtw? Dec 04 09:16:15 or i should ask are you sure they dont Dec 04 09:16:47 lasserix, in my mind they shoud not. The only thing updating should be the value field Dec 04 09:17:45 right Dec 04 09:17:46 well Dec 04 09:17:51 use a debugger and solve this problem already Dec 04 09:17:58 you can manually do so Dec 04 09:18:05 with log and ovveride to string on preference object Dec 04 09:18:09 lasserix, could you link me some reference to the debugger? Dec 04 09:18:16 and verify you're not getting junk or setting junk Dec 04 09:18:24 what dev enviromenta re you using? Dec 04 09:19:00 i mostly use intellij for android now and it has a debugger built in Dec 04 09:19:38 lasserix, I'm using Android Studio (so intellij i think) on ArchLinux Dec 04 09:20:02 oh Dec 04 09:20:06 then set a breakpoint Dec 04 09:20:10 and just go RUN->Debug Dec 04 09:20:19 then make sure View->Debugger is open Dec 04 09:20:22 then step through Dec 04 09:20:31 Oh, perfect, thanks a lot Dec 04 09:20:55 yeah Dec 04 09:21:29 you know the table is being written so it's something probably in the preferences not picking up correct or line 21 Dec 04 09:22:02 jalcine: no but you're the second person to ask that so i should, good luck! Dec 04 09:22:35 hey, when good advice is given, it should be paid in the one thing most people understand :) Dec 04 09:25:58 lasserix, it seems fine on the debugger too lol Dec 04 09:26:04 Hi guys Dec 04 09:26:06 I must be wrong Dec 04 09:26:54 I just created a new android project using navigation drawer template. Now, I want to use the new toolbar instead of the ActionBar, si I've followed this steps: http://goo.gl/1xsVU1 Dec 04 09:27:38 but now, when I try to run my just created app, it crashes on the NavigationDrawerFragment class, at this line: getActionBar().getThemedContext() Dec 04 09:27:44 its a null pointer exception Dec 04 09:28:02 any idea about to fix it or a good tutorial to use toolbar with navigation drawer? :( Dec 04 09:30:42 you guys in rainy areas need this http://www.gizmag.com/new-nubrella-wearable-umbrella/35049/ Dec 04 09:32:28 Now I have to go, thanks everyone, expecially lasserix for the extreme patience, have a nice day Dec 04 09:42:49 g00s what's this a way to guarantee your kid gets beat up after school? ;p Dec 04 09:43:28 is there a library to manipulate JFIF ? Dec 04 09:43:37 or should I parse the header myself :) Dec 04 09:48:47 Can I trust BuildConfig.DEBUG? Dec 04 09:50:17 Morning all Dec 04 09:50:19 kevel1: yes Dec 04 09:51:36 Ankhwatcher, if i recall correctly, back when building with ant, sometimes debug would be true in release builds Dec 04 09:51:46 I really can't afford for that to happen Dec 04 09:52:23 I want to implement something like what JakeWharton has done for Square Cash/Money where debug type builds have extra debug views and feedback Dec 04 09:52:24 kevel1: check the gradle docs Dec 04 09:52:44 which reminds me Dec 04 09:53:16 JakeWharton, you covered some of this in a talk about dagger. Was there any code examples for something like this released? Dec 04 09:53:46 If not, what was your design behind this? different build flavors for debug and release? Dec 04 09:53:53 Please shed some light :D Dec 04 10:10:58 hi i want to ask if i can convert an application mvc to libraray in android ? Dec 04 10:11:39 yassine2014, explain further? Dec 04 10:13:41 i want to make the application yaaic https://github.com/pocmo/Yaaic like a library in other projet Dec 04 10:14:03 yo used the irc command Dec 04 10:15:13 what for? Dec 04 10:15:26 you can add it as a dependency Dec 04 10:16:38 yes but the problem how i can used the classes besause the project is free complicated Dec 04 10:16:39 ? Dec 04 10:16:58 is very complicated Dec 04 10:20:06 can we put our FAB anywhere or is it supposed to go at the top? Dec 04 10:20:17 man i feel ridicilous for asking that Dec 04 10:24:16 lasserix: it's usually in the bottom right Dec 04 10:24:19 not in the top Dec 04 10:24:35 oh Dec 04 10:25:35 lasserix: https://github.com/MaTriXy/FloatingActionButton-1/raw/master/art/demo.gif Dec 04 10:25:37 like this Dec 04 10:25:39 i have an imageview in my main activity. IF a user loads the app and IF the user is "logged in", I want the view to display a logo thats downloaded after logging in. I have my logo downloader as an external ASyncTask. Can I edit my main activities UI from there? Dec 04 10:25:56 ahh Dec 04 10:26:05 oh hello lasserix. been a while. Dec 04 10:26:15 hello Dec 04 10:26:22 from onPre and onPoseExecute only Dec 04 10:26:55 onPostExecute Dec 04 10:26:56 but the asynctask is called from my menu activity, not the main. I think onPre and onPost would affect THAT activity Dec 04 10:27:02 no Dec 04 10:27:06 those are called on UI thread Dec 04 10:27:21 and UI thread can vast among all activities? Dec 04 10:27:22 however you get the reference to the async task to the activity / whatever is up to you Dec 04 10:27:27 no Dec 04 10:27:31 sorry xD Dec 04 10:27:32 but its the only one allowed to touch the UI Dec 04 10:27:52 there are a couple of ways to do it Dec 04 10:28:09 but the simplest is pass the activity as a weak reference to the async task Dec 04 10:28:26 and in onPostExecute do like if (mActivity.isShowing()) { updateLogo } Dec 04 10:29:27 thank you as always for your input, this makes a lot of sense. Going to google up passing activities. I... didnt know you could. Dec 04 10:30:20 sure you can Dec 04 10:30:28 contexts sure Dec 04 10:30:31 you can also wrap the functionality as an interface Dec 04 10:30:33 done that a few times Dec 04 10:30:38 and have the activity implement the interface and pass the interface Dec 04 10:30:49 that way you restrict what the async can do to the activity (just run the interface methods) Dec 04 10:30:55 interfaces... only have experience making a JS interface to interact with some web content Dec 04 10:33:46 ok my main activity calls my preference activity which calls my login activity which calls my logo downloader asynctask Dec 04 10:34:07 ahh Dec 04 10:34:08 oops Dec 04 10:34:13 what i'd do is pass the imageview Dec 04 10:34:15 to the async task Dec 04 10:34:23 hold it in a weakreference Dec 04 10:34:45 is there a way to pass it straight from main to logoDL? or do I have to pass image view to pref, then to login, then to async? Dec 04 10:36:33 http://pastebin.com/db9E0B4z Dec 04 10:36:53 umm Dec 04 10:36:59 you could make the async a non-static class Dec 04 10:37:06 just make sure to cancel it if the activity is stopped Dec 04 10:37:12 and clear any references Dec 04 10:40:01 thanks this is a big help Dec 04 10:59:40 is there a player that can play normal videos, youtube and vimeo? Dec 04 11:00:11 I know the youtube player, but it doesn't play videos when I have the link of an mp4 file let's say Dec 04 11:00:22 same with VideoView, it doesn't play youtube videos Dec 04 11:05:41 Hello all. I have customized a button. Just changed the background, parent is "Widget.Button". But now all buttons appear smaller, and the captions of the buttons are smaller, too. Why? How can I make a custom button, exactly behaving like the default button, but with another background? Dec 04 11:08:23 because android is strange :P Dec 04 11:08:37 you have to make a drawable with borders etc Dec 04 11:08:41 for each color Dec 04 11:09:36 I have copied the original Android drawables and just changed the color. That works, but why is the caption text smaller now? Dec 04 11:10:38 Mattx, ExoPlayer? Dec 04 11:12:55 Mavrik, have you tried it? is it good? Dec 04 11:13:16 It's the player Google uses in YouTube app Dec 04 11:13:24 I have posted on Stackoverflow, if anyone has a clue: http://stackoverflow.com/questions/27292101/android-custom-button-is-smaller-without-reason Dec 04 11:13:26 Haven't tried it, but the feature list looks impressive, compatibility as well. Dec 04 11:14:18 Mavrik, I didn't get it. YT app in android doesn't use the Youtube API? Dec 04 11:14:23 I mean, the Youtube Plater Dec 04 11:14:36 No. :P Dec 04 11:17:01 Are material activities essentially just stacks of cards? Dec 04 11:17:31 paper lasserix, PAPER Dec 04 11:17:35 STACKS OF PAPER Dec 04 11:17:46 1dp thick paper Dec 04 11:17:47 there is no library of mechanical paper or whatever it is Dec 04 11:17:53 that dude during google IO made it very clear that its paper Dec 04 11:17:57 there is a library for cards Dec 04 11:17:59 the guy with the massive sideburns Dec 04 11:18:32 i can just imagine he probably got stoned out of his mind and had the eureka moment: "its .. its... KINETIC PAPER! EUREKA" Dec 04 11:18:34 lasserix, Material is a design concept. Dec 04 11:18:40 no Dec 04 11:18:42 its more Dec 04 11:18:42 You won't get a library for what is aestetics. Dec 04 11:18:44 its a philosophy Dec 04 11:18:57 http://core0.staticworld.net/images/article/2014/06/google_io_material_design_touch-100315132-large.jpg Dec 04 11:18:59 that guy. Dec 04 11:19:01 yeah but why can't i have some library to implement shadow/height dividers? Dec 04 11:19:21 ios wood and leather was a philosophy too Dec 04 11:20:07 don't take advice on UI design from a guy who chose a beard like that Dec 04 11:20:39 KekSi, but, but that, but that guy knows whatsup. Dec 04 11:20:43 check at those burns Dec 04 11:21:24 the length of your burns are correlate with your ability for good design Dec 04 11:21:29 and maan those burns Dec 04 11:21:36 he might aswell be one of the bad guys in the hunger games movies :/ Dec 04 11:23:10 looooool Dec 04 11:26:03 May Duarte be ever in your favour. Dec 04 11:38:56 argh fuck them developers Dec 04 11:39:11 release new design concept that is only avail on .001 % of devices Dec 04 11:41:07 O.o Dec 04 11:41:11 Works fine on 4.0.4 for me. Dec 04 11:41:21 ? Dec 04 11:41:31 Material apps. Dec 04 11:43:51 you mean you've designed material themed apps for 4.0.4 and everything works fine? Dec 04 11:52:22 hey, want to do a quick refresh of the visible views of a list_view without invalidating it, as that was making it run like shit. problem is, I can get the indexes of the visible list view items, but I need info from the list_adapter to update them, how can I find that from the index of the list view? are the indexes of them both always the same? Dec 04 11:58:00 anyone online? Dec 04 11:58:06 Is there a way to show a layout int the context of a custom view in AS/Intellij ? Dec 04 11:58:30 dont think so, mh? Dec 04 11:58:54 smellymoo, listview has a getFirstVisibleItem method. Dec 04 11:59:04 danijoo, don't get your question Dec 04 11:59:21 smellymoo, it will give you the position of first item (child) visible on the listview Dec 04 11:59:25 update only those. Dec 04 11:59:38 Mavrik, yes, using it, but that get's a view, want to access the underlying array Dec 04 11:59:40 there's at least 15 code snippets that show that on SO :P Dec 04 11:59:53 smellymoo, which array? Dec 04 12:00:08 Lets say you have a custom compound view (something that extends LinearLayout for example), and in that view you inflate an xml into that cusom view. Now Im editing this xml and want to see how it would look in my customview Dec 04 12:00:38 I can choose an activity in the preview screen to see how my layout would look in a given activity, but not in a view Dec 04 12:00:59 Mavrik, so I have written the code to get the visible items, but it is giving me the views... I need to access the array, that the array_adapter is using to make the list_view Dec 04 12:01:41 smellymoo, stop using ArrayAdapter Dec 04 12:02:05 because it's obviously not good for your usecase anymore Dec 04 12:02:20 extend BaseAdapter and you'll have full control over your data and positions Dec 04 12:03:31 Mavrik, will it be a headache to change to baseadapter? I released I should have used that originally, but porting it might be a pain. Dec 04 12:03:42 smellymoo, you need to add like... 10 lines of code? :P Dec 04 12:03:52 your own ArrayList field and I think like 2 methods Dec 04 12:04:35 smellymoo, just change the definition and you'll see what AS tells you Dec 04 12:05:31 Mavrik, ok, sounds splendid... will do it (when I feel less lazy!)... AS? Dec 04 12:05:41 android studio Dec 04 12:06:20 Eclipse, but yes, think it will help :D Dec 04 12:06:33 thanks Mavrik :D Dec 04 12:14:15 http://www.ustream.tv/nasahdtv Dec 04 12:14:19 t minus 3 minutes Dec 04 12:16:39 very easy to port to baseadapter Dec 04 12:19:10 Mavrik, lasserix, but wait, when I convert it to baseadapter, how do I then go from list_view.getFirstVisibleItem to the underlying data in the array? Dec 04 12:19:32 smellymoo, getfirstvisibleitem gives you "position" Dec 04 12:19:40 same as you get in getView and everywhere else in the adapter :) Dec 04 12:19:53 usually you map position == index in your own array Dec 04 12:20:31 ^^ Dec 04 12:20:32 Mavrik, so then I don't need to change to baseadapter, can I not use the position as the index of the array? Dec 04 12:21:03 smellymoo: its easy to convert Dec 04 12:21:06 (probably should change to baseadapter anyway, but just saying) Dec 04 12:21:20 you just do firstVisible gives you position typically that position maps to the index of the underlying data set Dec 04 12:22:14 right, so I don't need to change to baseadapter, just leave it as the slightly modified arrayadapter and be done with it ;D Dec 04 12:23:12 or is there a performance improvement from using a more fundamental class? Dec 04 12:24:18 smellymoo, there's a usability improvement Dec 04 12:24:25 because ArrayAdapter is really for the most basic tutorial use-cases Dec 04 12:24:37 and you'll have bunch of same problems because it's hiding it's datastructure from you Dec 04 12:24:46 the sooner you get used to using BaseAdapter the better for you :) Dec 04 12:24:52 arrayadapter is fine if you only want that but later you're going to want to do x y z and you'llhave to change Dec 04 12:25:33 ok, of cause you are both right ;) Dec 04 12:26:15 well it depends what u wanna do with ur adapter Dec 04 12:26:58 ive seen some people implement whole baseadapters connecting to a contentresolver etc when they could of just used a cursoradapter Dec 04 12:27:15 view the docs, and then see what extends what, see what u could use Dec 04 12:27:20 cause they fools Dec 04 12:28:23 Is there a way to show custom completions in an EditText? Dec 04 12:30:54 sure Dec 04 12:31:41 Is there a special keyword that would help me with the search for that? Dec 04 12:32:59 no Dec 04 12:33:02 so my custom code for my arrayadapter: @Override public View getView(int pos, View convert_view, ViewGroup parent) ... can I call this to refresh all the visible items? (instead of invalidating) Dec 04 12:33:06 what do you mean "in"? Dec 04 12:33:27 you can anchor a spinner and populate completions that appear in a floating list under the edittext Dec 04 12:33:32 but inside the edittext makes no sense Dec 04 12:34:55 smellymoo: you must call notifyDataSetChanged() Dec 04 12:35:31 smellymoo: you never call getView Dec 04 12:35:31 danijoo, nah, that's what I want to avoid. Dec 04 12:35:40 the listview calls it to populate its children Dec 04 12:35:49 smellymoo: thats the only way to redraw all list items Dec 04 12:35:56 you implement it to supply the children of the listivew Dec 04 12:36:20 danijoo: you can also reset the adapter Dec 04 12:37:05 ok, so I want to update a small thing in the visible items, and notify change was to processor intensive. Dec 04 12:39:06 you have to Dec 04 12:39:09 there's no other way Dec 04 12:39:28 and if you implement it correctly, as long as you are not calling it a bajillion times is fine Dec 04 12:41:03 nah, seems like a shit system. so I will write a function that loops through the visible, and only changes the 1-2 that need changing out of them. Dec 04 12:42:03 tried it that way, for when an image for the avatar for a person has been downloaded it shows it in the chat list, but it slowed it down so much calling it each time an image was downloaded made the app shit. Dec 04 12:45:06 smellymoo, look at using Picasso Dec 04 12:45:27 You cache the user avatars Dec 04 12:45:34 you want to scale them after download also Dec 04 12:48:35 smellymoo: if you are d/l thumbnails use a library Dec 04 12:48:40 cause you'll want lazy loading Dec 04 12:48:43 and caching Dec 04 12:48:54 which is not difficult, but using a library will make life easier Dec 04 12:49:07 launch! Dec 04 12:49:11 http://www.ustream.tv/nasahdtv Dec 04 12:50:17 hmm Dec 04 13:23:13 lasserix: thanks for advice. But I did'n know that I need enable logging on Huawei phone :D . Here I found a solution http://stackoverflow.com/questions/11778896/huawei-ideos-logcat-not-responding Dec 04 13:54:01 have anyone used exoplayer? I can't find any info on how to play youtube videos on it Dec 04 13:54:49 Mavrik, it seems it is in fact possible to play them, thanks Dec 04 14:00:47 smellymoo: you figure out your problem? Dec 04 14:02:41 what would cause this. Dec 04 14:02:43 12-04 08:00:41.715 W/System.err(16948): java.lang.SecurityException: Requires SET_ANIMATION_SCALE permission Dec 04 14:02:59 lasserix, writting some code to do it optimally (looping through the visible views, added boolean for loaded, then check which imageview to update) Dec 04 14:03:12 oooo Dec 04 14:03:18 premature optimization is root of all evil Dec 04 14:03:29 you are using arrayadapter yet you are worried about optimization? Dec 04 14:03:38 Your priorities are confused sir. ;p Dec 04 14:04:20 lasserix, as it is just too shit using notifyinvalid or what ever... yeah... priorities are definitely wrong ;). Dec 04 14:04:20 and unless you are calling this function 12 times a second Dec 04 14:04:27 just use notifyDataSetChanged Dec 04 14:04:37 seriousily, just use it Dec 04 14:04:50 dont waste your time doing whatever you think it is optimizing it Dec 04 14:04:56 lasserix, did use it, and it was shit, slowed down my app sooooo much. Dec 04 14:04:56 you're likely just introducing overhead and bugs Dec 04 14:05:09 then can you post your code you were probably using it incorrectly Dec 04 14:05:11 oh Dec 04 14:05:14 you use array adapter huh? Dec 04 14:05:16 well duh Dec 04 14:05:21 that's why its slow as hell Dec 04 14:05:30 *sigh* Dec 04 14:05:35 fml. Dec 04 14:05:50 look Dec 04 14:05:56 im stuck in a brainstorming mood Dec 04 14:05:59 post up your array adapter Dec 04 14:06:03 ill write a base adapter for you Dec 04 14:07:21 hey lasserix fundamentals question: activities. Can 2 activities be nested together? Can I make my preferences class an inner main activity class? (prefs only called in main) Dec 04 14:08:24 :). very kind :). but I will port it to base adapter, later, looked, it's not hard, specially as I extended arrayadapter... but that isn't the problem, it's the ineficiancy of reloading everything when I only want to reload one imageview. Dec 04 14:09:30 smellymoo Dec 04 14:09:38 where does the images come from? Dec 04 14:09:46 Jesperhead: no Dec 04 14:10:05 Jesperhead: you can do something like have ActivityA extend ActivityB then only register B in your activity Dec 04 14:10:12 then A can handle one set of shit and B another Dec 04 14:10:23 ok this affects my prior issue. Dec 04 14:10:48 smellymoo: are you trying to implement a lazy loading for thumbnails in your listview rows? Dec 04 14:10:56 bc the imageview is in activityA, and the logoDownloader is like activity D or E Dec 04 14:11:20 (ie id have to pass the iv as an intent extra, which is a nono) Dec 04 14:11:35 why? Dec 04 14:12:21 jesper Dec 04 14:12:21 the logoDownloader is called from the login activity which is called from the preferences activity. Dec 04 14:12:32 does the logo change per user? Dec 04 14:12:36 yes Dec 04 14:12:46 okay Dec 04 14:12:57 so when you finish logging in it goes back to the activitya? Dec 04 14:13:11 so we have the Main, go to prefs, go to login, after logging in, logo Dls and returns to main activity Dec 04 14:13:20 and user* Dec 04 14:13:30 just FYI that's terrible user flow if that's what they ahve to do everytime Dec 04 14:14:03 how do you mean? Dec 04 14:14:36 i have autodirects for the user if the tap anything without being logged in Dec 04 14:14:42 if they( Dec 04 14:15:58 fucking internet blows fuck' Dec 04 14:16:05 fucking internet blows fuck' Dec 04 14:16:07 activityDorE { private void onFinishLoggingIn(String username, String somedownloadkey) { getSharedPreferences("USERFO").putString(username).putString(somedownloadkey).putBoolean("USERHASLOGGEDIN", true); } Dec 04 14:16:09 lol Dec 04 14:16:16 Jesperhead: you follow me? Dec 04 14:16:21 in your loggin activity, dump the info into shared preferences Dec 04 14:16:25 with a flag Dec 04 14:16:35 then in onCreate or whatever in activity A check if the flag has been set Dec 04 14:16:42 in onCreate or onResume or whatever Dec 04 14:16:54 can't be onCreate unless you finish it before going to log in activity Dec 04 14:17:19 but put the info you need for the d/l in shared preferences in the log in activity and then check if its there in the activity a at which point you can download it Dec 04 14:17:21 check for the file Dec 04 14:17:35 oh Dec 04 14:17:38 much more rational then having a downloader for a bitmap in an activity that has nothing to do with the bitmap Dec 04 14:17:40 so download it in the main activity Dec 04 14:17:45 right Dec 04 14:18:12 or download it to cache directory Dec 04 14:18:18 put the string of the path into the cache directory Dec 04 14:18:28 yes i want to save it. clears on logout Dec 04 14:18:29 err string of bitmap into shared preferences Dec 04 14:18:34 no need to dl each time Dec 04 14:18:38 and main activity just check if string is there Dec 04 14:18:41 if it's there load it Dec 04 14:19:14 smellymoo: since you seem overwhelmed what are you trying to do specifically? Dec 04 14:22:21 swap out the thumbnail in your listview rows? Dec 04 14:22:30 from someting you download or something from disk or what? Dec 04 14:23:35 lasserix_, I normally code in c++ or another non-shit language, so making my first app, so fighting the stupidity of android implementation of java. Dec 04 14:23:43 but anyways to answer your question you don't have to notifydatasetchanged if you are just swapping an imageview bitmap resource--you can pass the imageview and just call setImageResouce when you have the bitmap, you just have to be careful to make sure you cancel the operation when proper to do so Dec 04 14:23:58 hey now java isn't a shit language Dec 04 14:24:08 ehm, java isn't shit.. Dec 04 14:24:12 with modern compilers it can even be faster than c++ Dec 04 14:24:17 android way of using it is. Dec 04 14:24:38 a lot of people like to say that but i doubt many of them could come up with something that has made it this far Dec 04 14:24:49 the android framework is immature, yes Dec 04 14:25:09 also, some things are shit, somethings are better, like everying... for example .equals() = shit. Dec 04 14:25:15 smellymoo: anyways elaborate on what you are trying to do: i guarantee you I've already done something very, very similar. Dec 04 14:25:39 sure but those are just semantics and every language has their eccentric bullshit points Dec 04 14:26:18 but seriousily, what specifically are you trying to implement? Dec 04 14:26:30 it's chat, for a website that doesn't have an app, 2 possible images for each user, that is all. anyway, nearly finished my fix. Dec 04 14:26:41 mind posting your fix? Dec 04 14:27:18 since you have taken this long to implement what i presume you are trying to make work, it would probably be useful to have some comments since you are unfamiliar with getting this java shit on your hands so to speak ;) Dec 04 14:27:45 I'm getting my hands covered in java shit right now Dec 04 14:27:50 I love it Dec 04 14:28:00 and don't worry someone has already copyrighted and patented the very code you are writing Dec 04 14:28:13 kkkkkk Dec 04 14:28:50 smellymoo: are the images something you have to download? Dec 04 14:29:42 are you hesitant to talk about it because it's for pornhub? Dec 04 14:30:35 lasserix_, lol, yup, download, ok, testing my new code... nah, was just coding. Dec 04 14:30:43 okay Dec 04 14:31:00 so you can actually do that very easily by putting an async task inside getview and passing your imageview to the async task Dec 04 14:31:05 just be sure to cancel the async task Dec 04 14:31:23 when the list changes, and pause it when scrollign Dec 04 14:31:47 mind posting your code so i can critique your shit? Dec 04 14:32:19 lasserix_, well, it uses an asynch task now... but not in getview, as that is not when it's needed. Dec 04 14:32:30 or more accuratly, see how you managed to do it Dec 04 14:32:50 which bit? the fix? Dec 04 14:32:57 make sure you set the pool size of the async task to a low number Dec 04 14:33:04 you don't want 12 async tasks firing off Dec 04 14:33:09 yeah the fix i guess Dec 04 14:33:26 where would be best to post it? Dec 04 14:33:31 pastebin? Dec 04 14:34:50 btw here's an example of what you're trying to do https://github.com/thest1/LazyList/tree/master/src/com/fedorvlasov/lazylist Dec 04 14:35:00 with a memory cache and everything! Dec 04 14:35:59 fucking launch got scrubbed fucking space Dec 04 14:39:06 lasserix_, http://pastebin.com/VxVCpmQw Dec 04 14:40:18 yeah so basically you shat so hard your colon fell out of your ass and you looped it around your waist to make it work alright Dec 04 14:40:42 you essentially took what you are supposed to do in getView and for ALL views shoved it into onPostExecute ;p Dec 04 14:41:11 so can i ask what happens when you navigate to this activity containing this list and then press the home button? Dec 04 14:41:13 does it crash? Dec 04 14:42:11 so Dec 04 14:42:14 just so you are aware Dec 04 14:42:26 the getView method of base adapter is called by the listview when presenting its visible children Dec 04 14:42:31 ie, that's what line 3 is Dec 04 14:43:13 doInBackground you download all the avatars? Dec 04 14:44:54 the onpostexecute is for when it has downloaded an image. Dec 04 14:45:29 yes Dec 04 14:45:31 that's obvious Dec 04 14:45:42 but what i dont get is Dec 04 14:45:46 you are downloading multiple? Dec 04 14:45:54 since you are iterating through the list? Dec 04 14:46:30 sometimes, on init it downloads multiple, when a new message by a previously unseen person it downloads 1. Dec 04 14:46:39 oh man Dec 04 14:46:46 your code makes me very sad Dec 04 14:46:55 and makes my insides hurt a little :P Dec 04 14:47:02 lol Dec 04 14:47:10 so this is liable to crash you know that right? Dec 04 14:47:22 because? Dec 04 14:47:38 if i navigate to the list containing activity, and for some reason the download doesn't happen fast, and then press the home point Dec 04 14:47:43 *home or back button Dec 04 14:47:56 the list/activity is liable to be null or otherwise non-referencable Dec 04 14:48:16 ... it checks for that elsewhere. Dec 04 14:48:26 if you say so Dec 04 14:48:34 lol Dec 04 14:48:56 so.... Dec 04 14:49:00 if you just do Dec 04 14:49:15 thread t = new thread(new runnable { download all the files } } Dec 04 14:49:20 you can pass the activity Dec 04 14:49:22 and then do Dec 04 14:49:39 runOnUIThread(new runnable (iterate on children changing bitmap ie lines 3-30) Dec 04 14:49:48 you can skip using the async task Dec 04 14:50:03 the bad thing about async task is on < 11 api it'lll start 20 + threads Dec 04 14:50:16 *it can start up to Dec 04 14:52:23 ... woman being annoying (brb) Dec 04 14:52:26 but this is like so wrong i feel like you are Roman Polanski Dec 04 14:55:24 ah ha! saved by the random paper thought i was out of em phew Dec 04 15:02:14 lasserix_, think my app is 18+ api. Dec 04 15:03:09 lasserix_, on older than ics Dec 04 15:03:11 not hc Dec 04 15:03:33 not that it matters anymore Dec 04 15:04:59 does android studio come with adb? Dec 04 15:05:35 no Dec 04 15:05:46 but it comes with bda Dec 04 15:06:13 smellymoo you should really, really, really not do what you are doing. that's just horrible implementation of what you want done. Dec 04 15:06:34 lasserix_ whats bda Dec 04 15:06:36 like hacky in a way you would code if you wanted to really offend coworkers Dec 04 15:06:49 bondage declarative android Dec 04 15:07:26 I have an activity with a listadapter that request a task to be perform asynchronously and then calls a callback method of the adapter when it finished. but from the time it finishs, the activity may have been destroyed. What are the best practice to this example ? also the adapter keep a reference to the activity (to do activity.runonuithread to refresh the view) and the adapter is also kept in reference by the task to be performed which me Dec 04 15:08:18 it's a command line interface for android but themed as you are the dominator and you have to roll play you have the android, a real android, tied up and you are "instructing" it to do what you want Dec 04 15:08:33 you might want to watch the episode of diary of a call girl when she learns the ropes of s&m Dec 04 15:08:53 luist sorry your name inspired it--AS comes with ADB Dec 04 15:09:03 its part of the platform tools just make you add android and adb to your path Dec 04 15:09:40 Marlinski: use a weakreference in your async task and make your async task that has a cancel method which you activity calls in onStop Dec 04 15:09:57 lasserix_, like that idea, bondage domination terminal. make it :D Dec 04 15:10:26 lasserix_: :P Dec 04 15:10:27 Marlinski, I use messagebus for that Dec 04 15:10:30 Marlinski: your adapter has the same lifetime as the activity that hosts it ("true enough" here tho some people may argue not technically, but for this discussion its true) Dec 04 15:10:32 Marlinski, see EventBus or Otto libraries Dec 04 15:10:33 lasserix_: okay thanks… prob just not on path Dec 04 15:10:46 Marlinski, basically, send a message for some task to be done and then the task sends a message with results Dec 04 15:10:48 Marlinski: what you want to worry about is keeping a reference to the activity/context/adapter in your async task Dec 04 15:10:56 the answer to memory leaks us loose coupling Dec 04 15:11:03 is Dec 04 15:11:03 Marlinski, and you register to the bus in onResume and deregister in onPause Dec 04 15:11:16 no more issues with orientation change, restarts, etc ;) Dec 04 15:11:27 as pfn says - loose coupling :) Dec 04 15:11:44 Mavrik: yeah I already use EventBus Dec 04 15:11:49 but not for this peticular one Dec 04 15:11:54 oh problem solved Dec 04 15:12:07 hmm ok Dec 04 15:12:09 will do that Dec 04 15:12:20 after i go out for a smoke and to walk the cat im going to rewrite that adapter logic smellymoo because it truely pains me Dec 04 15:12:32 I was quiet happy with my callback design though :p Dec 04 15:12:39 need to rewrite this part hurgh Dec 04 15:12:43 * pfn ♥ his event 🚌 Dec 04 15:12:43 :) Dec 04 15:12:53 lasserix_: make sure you don't drop ashes on the cat Dec 04 15:12:57 Yes, bus design made so much stuff easier Dec 04 15:13:08 Mavrik: yeah I use it a lot, very nice Dec 04 15:13:16 I have a feeling 90% apps without landscape support don't have it because they don't know how to handle that usecase :P Dec 04 15:13:33 one thing though Dec 04 15:13:46 https://github.com/pfn/qicr/blob/master/common/src/com/hanhuy/android/irc/IrcManager.scala#L117 Dec 04 15:13:56 Mavrik: my adapter still needs a reference to the activity to do runonuithread Dec 04 15:14:06 so easy ;-) Dec 04 15:14:06 Marlinski, why? Dec 04 15:14:15 onEventMainThread :) Dec 04 15:14:36 anyone know if there's an issue with android:widgetLayout (on a SwitchPreference in this case) not working on some devices? Dec 04 15:14:41 Mavrik: cause the task is performed by another thread which will call post() which will call onEvent and this thread cannot update the view Dec 04 15:14:46 without an exception Dec 04 15:14:54 Marlinski, name your method onEventMainThread Dec 04 15:14:59 and the code will be executed on main thread. Dec 04 15:15:07 dayum didn't see that Dec 04 15:15:12 neat :D Dec 04 15:16:11 hmm but I am not completely satisfied with EventBus Dec 04 15:16:13 let me tell you why Dec 04 15:16:28 the task I request is a simple sql request to the database Dec 04 15:16:55 so the event is going to be something like "QueryFinishEvent" Dec 04 15:17:07 *shrug* Dec 04 15:17:15 if I register for this event I will receive a lot of event not at all related Dec 04 15:17:19 Honestly I don't put any such logic in adapters due to such issues :) Dec 04 15:17:39 I like my adapters dumb and do data logic in fragments/activities that own the views/adapters Dec 04 15:17:46 the adapter ought to perform this query in order to print the list Dec 04 15:17:50 hmm Dec 04 15:17:55 the problem remains the same Dec 04 15:18:11 if the view disappear, I will have a null exception when callback Dec 04 15:18:22 if use EventBus I will receive a lot of unrelated query result Dec 04 15:18:35 which will turn into implementing a transactionID of some sort Dec 04 15:20:19 but I don't really have the choice though Dec 04 15:20:51 anyway, thank you Mavrik and lasserix_ Dec 04 15:21:05 appreciate your help Dec 04 15:22:40 smellymoo: how do you know which ids to download or can you get by downloading them all ? Dec 04 15:23:34 Marlinski: can't you implement a filter on your query callback? Dec 04 15:24:35 lasserix_: actually I could check that my activity is null yes Dec 04 15:24:42 java.util.concurrent.TimeoutException: java.util.concurrent.ThreadPoolExecutor.finalize() timed out after 10 seconds Dec 04 15:25:10 and I got 10 lines in the stack trace with none of them relating to my app D: Dec 04 15:25:43 deadlock in shutdown? Dec 04 15:26:25 g00s you around? Dec 04 15:26:38 http://pastebin.com/4pZptDuE how am I supposed to fix this? D: Dec 04 15:29:06 anyone know the style for the default ListView divider? Dec 04 15:29:12 or resId Dec 04 15:30:20 mattblang, you can possibly look it up via view hierarchy Dec 04 15:30:59 Syzygy__ via view hierarchy? with a breakpoint after I get a handle to it? Dec 04 15:31:26 no, via the device monitor Dec 04 15:32:34 Syzygy__: are you calling shutdown on your threadpool prior to this? Dec 04 15:33:02 lasserix_, I have no idea where in my app this happens. Dec 04 15:33:07 lasserix_, I am making an app, for a website that is out of my control, and the coders that made that website make me angry like I make you, so they are truly terrible. Dec 04 15:33:09 mattblang, http://madcoda.com/wp-content/uploads/2013/01/ddms_inspector.png Dec 04 15:33:09 Syzygy__: are you calling shutdown on your threadpool prior to this? Dec 04 15:33:28 hahah smellymoo oh ok i understand now Dec 04 15:33:43 are you interested in learning as little android for now then? Dec 04 15:34:03 Syzygy__: you are not using a threadpool? Dec 04 15:34:27 lasserix_, possibly somewhere in my app, I didn't code any threadpools in Dec 04 15:34:29 mattblang: http://stackoverflow.com/questions/5289536/android-listview-default-divider-styles-attributes Dec 04 15:34:33 lasserix_, non of how there website functions is right in any way. they even manage to fuck up JSON. so yeah, makes me look like a java coding pro. Dec 04 15:34:50 Syzygy__: ahh. hmm Dec 04 15:35:04 lasserix_ you're a good man, I don't care what they say (my grandfather used to say that, lol) Dec 04 15:35:06 I'm sure this gets asked all the time, but, if I'm an experienced Python developer who wants to start with Android, should I be using Android Studio, Eclipse, something else? Dec 04 15:35:26 Syzygy__: damn that is a tough one, no idea on how to recreate its conditions or is it intractably nondeterministic? Dec 04 15:35:37 lasserix_, this is from a crashlog i got from one of my users. Dec 04 15:36:00 arbitraryuser: how much fidelity do you have for the command line? android studio or intellij if you are not viming it up Dec 04 15:36:03 lasserix_, nope, also, no threadpools in my app D: (didn't check all libs yet though) Dec 04 15:36:15 (I'm finding Android studio really hard to get going with - Mostly gradle build failures, paths not right etc etc) Dec 04 15:36:24 Syzygy__: hmm using any third party libraries? Dec 04 15:36:29 lasserix_, plenty Dec 04 15:36:35 lasserix_: I'm agnostic. Quite like a decent IDE in my old age ;) Dec 04 15:36:36 Syzygy__, http://stackoverflow.com/a/24173605 may be related to your issue Dec 04 15:36:59 arbitraryuser: try to keep it simple enough to not get caught up with gradle, or read up on gradle. if you are going for learning android focus on the actual coding for now Dec 04 15:37:16 arbitraryuser, android studio is considered standard for android by now, eclipse used to be. personally i prefer android studio but it comes down to your personal preference Dec 04 15:37:27 arbitraryuser: using eclipse to start off is definatly a stepbackward at this point Dec 04 15:37:44 Documentation should be coming for the android gradle plugin, that will be nice Dec 04 15:38:08 thanks VnM I'll look into that Dec 04 15:38:18 eventually you'll want to know how to use gradle because it can make dealing with the automated benefits of pre-compiling script logic very easy to do complicated projects Dec 04 15:38:19 lasserix_: I'd love to, but I can't even build because of "Failed to find: com.android.support:support-v4.20.+" Dec 04 15:38:38 maybe you left it by the lighter? Dec 04 15:38:48 do you need the support library? Dec 04 15:38:54 currently downloading various things with the SDK manager, but honestly makes me feel like I complete noob. Dec 04 15:39:02 lasserix_: I don't know ;) What is the support library? Dec 04 15:39:13 com.android.support:support-v4.20.+" Dec 04 15:39:16 arbitraryuser, go into the sdk manager and download it (if you need it at all, otherwise remove from the gradle file) Dec 04 15:39:18 arbitraryuser: did you verify you had downloaded it with the sdk manager? Dec 04 15:39:43 arbitraryuser, support library takes care of stuff like backwards compatibility Dec 04 15:40:16 where do I find this in the SDK manager? (/me screenshots to make sure we're talking about the same thing) Dec 04 15:40:19 arbitraryuser: so as the android apis evolved, there arose the lack in earlier apis the newer coding apis and data structures of the newer apis, the support library contains the equivalent code sets so you can "backport" more easily Dec 04 15:40:25 arbitraryuser, last category Dec 04 15:40:47 (extras) Dec 04 15:41:04 Ah, Android Support Library (says 21.0.2) is Installed Dec 04 15:41:07 can anyone give insight on this error java.lang.RuntimeException: Failed to resolve attribute at index 6 Dec 04 15:41:17 for instance, later on there arose what's called a viewpager, which is when you can swipe left and right between pages on the device's screen. since earlier apis didn't have this, google made a support library to make it available to the earlier apis Dec 04 15:41:19 you might also want the support repository Dec 04 15:41:45 arbitraryuser: yeah and so you need to go back in time or switch it to 21.0.2 and not 4.20.+ Dec 04 15:42:05 repository = source code, library = binaries? Dec 04 15:42:12 in gradle you can specify variability in an incremental release by setting it to .+ Dec 04 15:42:26 thought it should span more than just incremental releases, but guess not Dec 04 15:42:39 chrisryn, your app couldn't resolve an attribute at index 6. one would assume a failed access to an element in some sort of container Dec 04 15:42:40 arbitraryuser: have you used git? Dec 04 15:42:55 lasserix_: I live in it ;) Dec 04 15:44:29 oh so you should know what a repo is ! Dec 04 15:45:04 (It feels like this should be something really trivial that AS should be able to say "Hey, you're missing this, click here to download" Dec 04 15:45:51 lasserix_: yeah, I'm just querying whether the name "repository" in this context indicates the source code version, ala linux -sources Dec 04 15:46:57 arbitraryuser, it sometimes does Dec 04 15:47:40 libraries managed by maven (which you can import using gradle as well) are also in repositories, no raw code Dec 04 15:47:51 shit launch! Dec 04 15:48:11 ahha nm damn cgi on the small screen Dec 04 15:48:27 what's the single sentence description of what gradle is? Dec 04 15:48:51 prosaic build scripting language Dec 04 15:49:10 So Chef/Puppet kinda Dec 04 15:50:14 yeah probably Dec 04 15:50:36 Gradle is build automation evolved. Gradle can automate the building, testing, publishing, deployment and more of software packages or other types of projects such as generated static websites, generated documentation or indeed anything else. Dec 04 15:51:28 gradle can make your life much easier in the fragmented world of android development Dec 04 15:52:02 lasserix_: +1 Dec 04 15:52:04 So what's happening now is just a very basic gradle build script running and saying 'hey, you're missing this library', but at some point if I got serious about android dev I would use it to do more powerful stuff? Dec 04 15:52:46 and more! Dec 04 15:52:55 actually it makes importing libraries very very nice Dec 04 15:53:36 why is it constantly downloading stuff? What is it actually downloading? Dec 04 15:53:51 gradle-2.1-all.zip etc? Dec 04 15:54:10 or is it basically just downloading "gradle" Dec 04 15:54:18 arbitraryuser: downloading? Dec 04 15:54:37 Gradle: Download https://.... Dec 04 15:54:39 what happens when the phone is tilted ? the activity is destroyed then created ? Dec 04 15:54:47 status bar at the bottom of AS. Dec 04 15:55:06 and this is the first run of RC2 Dec 04 15:55:42 and at the top "Gradle Project sync in progress" Dec 04 15:56:07 arbitraryuser: Are you downloading a lib? Dec 04 15:56:22 No... I just launched AS Dec 04 15:56:36 arbitraryuser: Haven't seen that in my AS Dec 04 15:56:43 arbitraryuser: its downloading dependencies Dec 04 15:56:58 Ah Dec 04 15:56:58 or running processes related to the build system particularly encoding its cache Dec 04 15:57:03 Mrdarknezz: I'm on 2mb internet... maybe it happens in yours but you just don't see it ;) Dec 04 15:57:41 gradle project sync is binding inter-component linkages Dec 04 15:58:15 i could be wrong but this would include something like linking references in XML files (layouts) to their usages in java code Dec 04 15:58:28 it definatly includes updating references to libraries used in code Dec 04 15:58:32 http://stackoverflow.com/questions/16580873/android-studio-stuck-at-gradle-download-on-create-new-project (see 50mb on first startup) Dec 04 15:58:49 (see "a download progress bar wouldn't hurt anyone") Dec 04 16:00:05 arbitraryuser: Ah i'm on fiber :P Dec 04 16:01:17 Mrdarknezz: yeah, I'm in South Africa... we have fiber rolling out to some neighbourhoods now, but most of us are on DSL or 3G. Dec 04 16:02:07 Are there any good Android Dev podcasts? Dec 04 16:04:20 https://www.irccloud.com/pastebin/7EcOt8SI Dec 04 16:04:44 ^^ some guidance would be appreciated... I need to know where to poke. Dec 04 16:05:35 (maybe it's because the project was created with an old version of AS, creating a new blank app now) Dec 04 16:08:28 do any of the event buses system use a broadcast receiver at application class? Dec 04 16:08:49 arbitraryuser: in build.gradle you have the like 'runProguard' but it changed to 'minifyEnabled' Dec 04 16:09:05 arbitraryuser: just remove the line for now Dec 04 16:09:11 arbitraryuser: you can add proguard later Dec 04 16:10:32 such a polite renaming Dec 04 16:11:40 Proguard is a java optimizer and obfuscator to make your code pontentially have a smaller footprint and slightly harder to reverse engineer Dec 04 16:16:30 is there a way to enable usb debugging on a device from the host? or at least make a request and make the popup appear on the device Dec 04 16:21:16 lasserix_, so turns out two of my libraries use threadpools. facebook and mopub-sdk (i believe it's related to ads) Dec 04 16:21:52 Does anyone know of an article that explains in depth the restarting of services based on return value of onStartCommand (like, with actual examples)? Dec 04 16:24:09 Yeah so you're fucked Dec 04 16:24:20 Well, you can post that to both facebook and mopub-sdk Dec 04 16:24:25 http://stackoverflow.com/questions/12150213/how-to-handle-timeoutexception-with-executorservice-and-futures Dec 04 16:24:35 here's something of why its happenning, if you know about callables and all Dec 04 16:25:28 Sounds like something someone forgot to handle, but meant to Dec 04 16:26:20 yeah no idea :/ Dec 04 16:27:30 when i plug my tablet, it does not pop the debugging screen automaticaly, unlike my phone for example. how can i pre-identify the device so it will ask automatically? Dec 04 16:27:51 hi guys and bots Dec 04 16:27:52 :) Dec 04 16:28:04 dobur ve4er Dec 04 16:28:18 Dobra da e Dec 04 16:28:43 I am looking to display text vertically (rotated on 270 degrees) Dec 04 16:29:19 but there is a problem - the text cuts exactly as the width of the parent screen Dec 04 16:29:24 any suggestions? Dec 04 16:30:30 text cuts exactly as the width? Dec 04 16:30:43 https://www.dropbox.com/s/fg1o1c5z3qdmi18/androidstudiokakness.PNG?dl=0 <--- Is this because I am still downloading SDK files? Dec 04 16:31:38 yeah could be fiddle with the options at the top af that screen below the menu bar Dec 04 16:32:30 Syzygy__: any way to trace the can't resolve attribute on index 6 error Dec 04 16:33:10 plenty. breakpoints, log output would be your best bets Dec 04 16:33:20 java.lang.RuntimeException: Unable to pause activity {com.my.stuff.MainActivity}: java.lang.IllegalArgumentException: Both context and applicationId must be non-null Dec 04 16:33:29 that's also a good one :/ Dec 04 16:34:43 @all: hello people Dec 04 16:35:27 i got an the oauth2.0 access token using GoogleAuthUtil after a successful login through plus apli client Dec 04 16:36:04 is there a way of getting the 'expires_in' value using some google api? or only through a https request? Dec 04 16:52:01 when i plug my tablet, it does not pop the debugging screen automaticaly, unlike my phone for example. how can i pre-identify the device so it will ask automatically? Dec 04 17:10:18 do you know how to include in an AAR several libraries (jar) from mavenCentral ? I mean without copying manually in a libs/ dir Dec 04 17:11:30 what if my vendor is not in the USB Vendor IDs list? Dec 04 17:11:45 luist, for Ubuntu? Dec 04 17:11:58 Mavrik: my host with adb is OS X Dec 04 17:12:04 blues-man, just add them to dependency? Dec 04 17:12:06 Mavrik: but i can use ubuntu too Dec 04 17:12:15 uh Dec 04 17:12:27 Why do you need that for non-Linux machines? Dec 04 17:12:51 Mavrik, yes but compile alone won't put them in the aar, I guess I miss something as export = true Dec 04 17:13:22 Mavrik: i want to recognize the device im developing for? Dec 04 17:13:46 luist, ah, check out dmesg. Dec 04 17:13:51 after you plug it in Dec 04 17:13:58 the USB ids are usually blurbed there Dec 04 17:14:09 blues-man, ah, you want to make a fatjar Dec 04 17:14:23 Mavrik: when i plug the usb maybe? Dec 04 17:14:35 blues-man, I haven't found a Android/Gradle compatible plugin for making fatjars sadly :/ Dec 04 17:14:50 Mavrik, a fataar :) Dec 04 17:15:23 I used maven-shade-plugin with maven, but all Gradle stuff relies on "java" plugin which isn't used when Android projects are compiled :/ Dec 04 17:15:28 I'll probably have to roll my own Dec 04 17:15:39 When the days will have 40 hours. Dec 04 17:15:44 I see Dec 04 17:15:46 lol Dec 04 17:17:18 so basically it should be done manually copying jars before build, kind of tricky Dec 04 17:18:10 blues-man, remember, those libs can collide with your users Dec 04 17:18:18 so I just have source pulled in because I want to rename packages Dec 04 17:18:58 Hi, I'm having some trouble getting ADB to recognize my Nexus 7.. Could I get some help? I need to upgrade to 5.0.1 via factory image3 Dec 04 17:19:02 image* Dec 04 17:19:06 yes Mavrik source pulled is the only way in this scenario Dec 04 17:20:20 I'm on Windows XP if that helps anything.. Dec 04 17:27:34 blues-man: was that directed towards me, or towards another conversation? Dec 04 17:29:24 laspahr, I don't see your nickname in my first and latest sentence since you joined channel, as far I can see Dec 04 17:29:53 okay, wasn't sure :) Dec 04 17:31:34 Wow, the Reddit website is so buggy. Gets confused about 'prev' and 'next'. Dec 04 17:31:54 TacticalJoke: it's all relative, y'know Dec 04 17:32:50 Relative confusion: accidentally dating a first cousin. Dec 04 17:33:16 laspahr, np :) Dec 04 17:33:34 Or, as Reddit would put it, "accidentally". Dec 04 17:37:44 bleepy, mhm, Maven has "maven-shade-plugin" which solved that issue Dec 04 17:37:48 bah Dec 04 17:37:52 he's gone Dec 04 17:37:58 Hey guys, I added notifications to my app and they were working before, but they stopped. The notification still pops up, but when I click it, it doesn't bring me to the activity. Dec 04 17:38:11 Any idea what could have happened? Dec 04 17:42:41 is there a way to make a button in a custom list view item defer clicks to the 'OnItemClick' callback of the parent listview? Dec 04 17:43:06 bonus, without actually knowing it's in a listview Dec 04 17:43:42 I'm not sure, shekibobo, but IMO it makes more sense for the Activity to subscribe to the Adapter's "fooClick" event (and the Adapter takes care of making sure that the view's click fires the fooClick event). Dec 04 17:43:47 Generally. Dec 04 17:45:14 shkibobo adapter is non-static inner class of the activity booya. Dec 04 17:45:42 The grammar in the Android documentation is so bad: "The view will scroll such that the indicated position is displayed." Dec 04 17:45:47 It will such scroll? Dec 04 17:46:06 Something will Dec 04 17:46:29 would have to say yes Dec 04 17:46:35 It has to be either "The view will be such that" or "The view will scroll so that". Dec 04 17:46:40 if the view will scroll then the indicated position id displayed Dec 04 17:47:08 (reading the such that as if this were latex) Dec 04 17:47:27 shekibobo: adapter is non-static inner class of the activity booya. Dec 04 17:48:17 Mavrik: how about this line: USBMSC Identifier (non-unique): 0123456789ABCDEF 0x1662 0x948b 0x231, 2 Dec 04 17:56:02 Hmm, myListView.smoothScrollToPosition(N); is scrolling so that position N is showing at the bottom, not at the top. People on SO are suggesting that it should show N at the top. Weird. Dec 04 17:57:43 In fact, it seems to be almost random. Dec 04 17:57:53 Should I avoid ListView.smoothScrollToPosition(int)? Dec 04 17:59:22 any one have experience porting an app Dec 04 17:59:40 is there a way to remove the OptionsMenu from a toolbar that is in a DialogFragment? Dec 04 17:59:43 chrisryn: "Porting an app" could mean anything. Dec 04 18:00:10 porting an app from a stock rom to a non stock rom Dec 04 18:02:00 TacticalJoke, either you're at the end of the list Dec 04 18:02:07 TacticalJoke, or the position calculation is messed up Dec 04 18:02:11 do you have different sized items? Dec 04 18:02:16 Yeah, different sizes. Dec 04 18:02:28 ListView.setSelection works fine. Dec 04 18:02:32 That's probably the issue then :/ Dec 04 18:02:37 Though I don't know whether I want to set a selection. Hmm. Dec 04 18:02:42 Check out the source of how ListView determines position. Dec 04 18:03:01 K. Dec 04 18:03:14 it get's the position according to the current visible item and the adapter Dec 04 18:04:15 TacticalJoke: http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/4.2_r1/android/widget/AdapterView.java#61 Dec 04 18:05:03 TacticalJoke: no it should work Dec 04 18:05:27 derp Dec 04 18:05:54 *sigh* My god most of Android user and dev communities out there are utter shite Dec 04 18:06:01 you could build something yourself using pointToPosition and smoothScroll(++) Dec 04 18:06:53 Yeah, I might end up subclassing ListView. Dec 04 18:07:12 ListViewWithFunctioningSmoothScrolling Dec 04 18:07:45 TacticalJoke: what's the issue? I feel like I came in late Dec 04 18:09:03 ListView.smoothScrollToPosition isn't consistent. ListView.setSelection works, but I'm not sure whether I want to set a selection. Dec 04 18:09:28 In the future, with dual-pane layouts, I might want to use the selection mechanism so that the user can see a highlighted item. Dec 04 18:09:40 hmmmm Dec 04 18:09:57 Or is it better for an adapter to handle the "currently selected position"? Dec 04 18:10:05 smoothscroll is a problem because it does some of the measurements on the fly Dec 04 18:10:14 and it messes up the scroll Dec 04 18:10:29 Ya. Dec 04 18:11:17 you can always set a definitive size to all the list item layouts Dec 04 18:11:26 it should make it easier Dec 04 18:12:11 Oh, I can't do that. Dec 04 18:12:18 The list has to be variable height. :) Dec 04 18:12:22 The items have* Dec 04 18:12:29 like most lists Dec 04 18:12:31 :S Dec 04 18:12:54 I was tasked to port to material design today, I'm changing stuff in a weird way Dec 04 18:13:13 porting some fragments into DialogFragments Dec 04 18:13:42 now i need to show a DialogFragment and set a toolbar to it, but hide the options menu Dec 04 18:13:49 no idea how to do taht Dec 04 18:13:50 that Dec 04 18:14:24 I'm guessing Toolbar doesn't consider the overflow-menu button to be a normal View that can be hidden? Dec 04 18:14:33 I've not tried Toolbar yet. Dec 04 18:14:40 is the d.android.com documentation settled ? i still read stuff thats holo-ish but not material like http://developer.android.com/design/patterns/actionbar.html Dec 04 18:14:50 "Layout Considerations for Split Action Bars" Dec 04 18:14:53 lol Dec 04 18:14:55 can I run infinite loop test on gradle ? Dec 04 18:15:04 d0no Dec 04 18:15:07 g00s: no Dec 04 18:15:19 thepoosh such a clusterfuck Dec 04 18:15:24 yep Dec 04 18:15:38 gordon_: do you mean the turing halting problem? Dec 04 18:15:44 if os, the answer is always no Dec 04 18:15:48 *so Dec 04 18:16:14 something like guard Dec 04 18:16:20 So I have a list of items. The user can click "Load More" at the bottom to load more items. I'm hoping to scroll down a little when the new items are loaded. Dec 04 18:16:25 To be honest, I don't know how far to scroll down. Dec 04 18:16:38 It'd be weird to scroll so that the old items are now completely invisible. Dec 04 18:16:41 that doesn't make much sense Dec 04 18:16:58 scroll the height of the listview Dec 04 18:17:14 and use an interpolator Dec 04 18:17:15 smoothscroll to the lastVisibleItem + 1 Dec 04 18:17:15 http://forums.gradle.org/gradle/topics/smart_testing Dec 04 18:17:20 I guess I might end up having to do something like that. Dec 04 18:17:22 I lke 'planned' 3 years ago. Dec 04 18:17:28 thepoosh: I'm not sure that's a good idea. Hmm. Dec 04 18:17:32 Because it's confusing, right? Dec 04 18:17:32 ? Dec 04 18:17:36 All the old data goes invisible. Dec 04 18:17:43 I think it makes sense to keep one or more item from the original data. Dec 04 18:17:57 whhat does infinite loop test mean, gordon_ Dec 04 18:17:58 will check infinitest in intellij Dec 04 18:18:02 So that they get the sense of "Okay, here's our new position". Dec 04 18:18:07 of course, the whole idea of scrolling after you load more data without the user doing it himself is weird Dec 04 18:18:16 NimbusBP1729: something like ruby's guard Dec 04 18:18:28 does anyone know where do i add a new Vendor ID to use with adb on Mac OS X? The correspondent to /etc/udev/rules.d/XX-android.rules on linux Dec 04 18:18:31 Right now (without scrolling), it's kinda annoying. Dec 04 18:18:33 g00s: nothing about infinite loop Dec 04 18:18:43 Because you have to click "Load More", wait, and scroll. Dec 04 18:18:52 I could just have auto-load-more on scroll, but I kinda like this idea. Hmm. Dec 04 18:19:01 TacticalJoke: so smooth scroll to the newest old item Dec 04 18:19:20 Yeah. (Though smooth scrolling doesn't seem to work properly.) Dec 04 18:19:28 it will if it's there Dec 04 18:20:08 It's inconsistent. If I try to smooth-scroll to position 26 from a button, it scrolls in all different places depending on the current scroll position. Dec 04 18:20:17 scrolls to* Dec 04 18:20:24 well, yes and no Dec 04 18:20:48 if you say that you want a visible item to be the first visible item, it shouldn't be inconsistent Dec 04 18:21:06 ListView.setSelection works fine, BTW. Dec 04 18:21:10 I just don't want to set a selection. Dec 04 18:21:31 yeah, it's not nice Dec 04 18:21:44 I guess I can just figure out how ListView.setSelection does it, and copy that. Dec 04 18:21:50 Minus setting the selection (assuming that's possible). Dec 04 18:22:50 Hmm, it might be worth looking at how the framework remembers the ListView position on orientation change. Dec 04 18:22:55 Because that surely doesn't set a selection. Dec 04 18:23:47 http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/4.2_r1/android/widget/AbsListView.java#4626 Dec 04 18:23:54 there is a scroller Dec 04 18:24:17 Yeah. Dec 04 18:24:22 there are several additional variables you can pass in Dec 04 18:24:48 Hmm, on orientation change, it seems to remember the Top of the first item. Dec 04 18:27:43 g00s: our bosses determined that the Q4 goal for the Android team is to be featured Dec 04 18:27:55 so now we slave until new year's eve Dec 04 18:28:02 thepoosh i'm not following Dec 04 18:28:23 they came over: "we need to be featured!" Dec 04 18:28:32 "everything needs to be material" Dec 04 18:28:41 "you need cool toolbars and what not" Dec 04 18:28:48 TacticalJoke: why not just scroll height of the listview? Dec 04 18:28:51 "you have 4 weeks, go!" Dec 04 18:28:56 thepoosh material isn't even on the newest version dashboard Dec 04 18:29:06 you guys are ruining your holidays for 0.11% users Dec 04 18:29:08 lasserix_: I might end up doing that. lol Dec 04 18:29:09 TacticalJoke: or more specifically, height of listview - height of lastvisible row Dec 04 18:29:16 or half height of last row Dec 04 18:29:26 g00s: I know, but google won't feature us unless we do it Dec 04 18:29:33 lol Dec 04 18:29:34 g00s hehe Dec 04 18:29:59 oh fuck Dec 04 18:30:00 christmas Dec 04 18:30:06 they told us what we should do Dec 04 18:30:14 lasserix_: that's why I'm jewish Dec 04 18:30:14 thepoosh just put a higher actionbar and add some padding, call it a day for now Dec 04 18:30:21 nope Dec 04 18:30:36 they use the hierarchy Viewer Dec 04 18:30:43 we actually had fake actionbars Dec 04 18:30:47 hehe Dec 04 18:30:50 and they told us we cannot be featured Dec 04 18:31:03 fucker Dec 04 18:31:05 s Dec 04 18:31:05 roflmao Dec 04 18:31:10 i hate you Dec 04 18:31:30 you need to remember who makes the rules there buddy :) Dec 04 18:31:39 we got an outsourced Android specialist, who's around since before google bought the android project Dec 04 18:32:10 google bought the android project ... ? Dec 04 18:32:16 In modern Android UIs developers should lean more on a visually distinct color scheme for toolbars than on their application icon. The use of application icon plus title as a standard layout is discouraged on API 21 devices and newer. Dec 04 18:32:21 where's the docs to set the attributes for that? Dec 04 18:32:30 google acquired android, duh Dec 04 18:32:47 thepoosh, which app? Dec 04 18:32:53 * pfn needs more featured apps Dec 04 18:32:56 pfn yeah, you're not paying attention ;) Dec 04 18:32:58 pfn: glide Dec 04 18:33:08 good thing last app I worked on launched before google gave a shit about material Dec 04 18:33:16 thepoosh so google bought hte android glide app ? Dec 04 18:33:22 g00s, android project = aosp Dec 04 18:33:31 google bought android.com is what he means Dec 04 18:33:48 yes Dec 04 18:34:15 ok "we got an outsourced Android specialist, who's around since before google bought the android project" didn't make sense to me, because i thought that guy was new Dec 04 18:34:25 makes sense to me Dec 04 18:34:29 maybe you should learn english better Dec 04 18:34:37 pfn maye you should fuck yourself Dec 04 18:34:43 on a daily Dec 04 18:34:44 and quit being a dick to everyone Dec 04 18:34:52 to everyone? nah, just you Dec 04 18:34:55 of Dec 04 18:35:02 lol Dec 04 18:36:34 dont make us take the colored chaulk away you two Dec 04 18:38:16 lasserix_: Is there an easy way to measure the height of one of the list items? Dec 04 18:40:43 getHeight? Dec 04 18:41:08 aye Dec 04 18:41:25 yay!!! Dec 04 18:41:32 racecar Dec 04 18:42:47 real eyes realize real lies. Dec 04 18:43:35 TacticalJoke, not until it's laid out Dec 04 18:45:42 Ugh. ListView.scrollBy doesn't seem to work properly. Dec 04 18:45:49 I know it's View.scrollBy. Dec 04 18:45:59 (Unless "properly" allows for the list to be randomly blank at the bottom.) Dec 04 18:46:19 TacticalJoke, setSelected Dec 04 18:46:28 don't use scrollBy Dec 04 18:46:43 Hmm. Will that cause issues if I want to allow for persistent selections (in tablet mode) later? Dec 04 18:47:02 I'll probably use setChecked[Whatever] for that, but the name 'selected' makes me worry a little. Dec 04 18:48:44 or there's an ensureItem visible kind of call Dec 04 18:48:46 I forget what it is Dec 04 18:51:18 Hmm, can't find something like that. Dec 04 18:51:24 I guess I need to figure out what ListView considers a "selection". Dec 04 18:51:29 I guess it has to do with that touch-mode thing. Dec 04 18:51:59 Because it seems independent from something being "checked"> Dec 04 18:52:00 .* Dec 04 18:52:27 It always confuses me when forget is in present tense when saying "I forget what it is". Somehow that doesn't make sense to me. Dec 04 18:53:02 marrrk: Why? Dec 04 18:53:21 Actually, I kinda see your point. Feels like it should be "I've forgotten". Dec 04 18:53:39 It's just because you wouldn't say it like that in German, I think. Dec 04 18:53:43 no, because "I forgot" feels much more natural Dec 04 18:53:54 because in the act of forgetting, it has already happened Dec 04 18:54:02 so it feels natural to say "I forgot" rather than "I forget" Dec 04 18:54:09 at least from a logical perspective Dec 04 18:54:30 I guess it's "I forgot and therefore I (currently) can't recall". :D Dec 04 18:54:34 It seems like it is happening right now, but there is "I am forgetting" for that in english I guess. Dec 04 18:54:38 TacticalJoke, right Dec 04 18:54:49 I think "I forget" is an Americanism. Dec 04 18:54:50 but common usage is "I forget blah blah" Dec 04 18:55:03 Not many British people say that, I think. Dec 04 18:56:03 British people say other silly things. Dec 04 18:56:41 does anyone know where do i add a new Vendor ID to use with adb on Mac OS X? The correspondent to /etc/udev/rules.d/XX-android.rules on linux Dec 04 18:57:41 I guess "I forget" implies regularity: "I forget to set my alarm every day". Dec 04 18:58:15 Though I think "I forgot" implies a one-time event that's no longer relevant: "I forgot to set my alarm, and then I woke late". Dec 04 18:58:17 "implies regularity" :p Dec 04 18:58:31 But "I've forgotten" suggests that the forgetting is still relevant. Dec 04 19:21:06 Okay, the setSelection thing seems to work well. Dec 04 19:21:13 And it seems to be totally independent of setItemChecked. Dec 04 19:22:05 On the general topic, I don't know what to do about tablets. Dec 04 19:22:10 I'm not a fan of dual-pane modes. Dec 04 19:22:22 Do you folks read Reddit on your tablets? If so, do you like dual-pane stuff? Dec 04 19:22:55 (My market research is basically asking you people questions. :D) Dec 04 19:25:43 this company would like a widget on the bottom of the screen like the iOS Tab bar (used in ios for navigation). i havent seen this on an android app in a long time. would you guys puch back on this ? Dec 04 19:25:55 *push Dec 04 19:26:12 Is that like the Blackbery Messenger thing? Dec 04 19:26:15 Blackberry* Dec 04 19:26:24 In fact, BlackBerry. Dec 04 19:27:13 hm its kinda like Android tabs but at the botton. that frees up the top though for other lateral navigation. i actually like it better, but its not android Dec 04 19:27:47 basically global navigation goes at the bottom for iOS if i recall Dec 04 19:28:16 Yeah, it would feel very un-Android-y. Dec 04 19:31:49 * g00s ponders signing up for ninjamock Dec 04 19:33:07 Okay, this idea of scrolling after the user touches "Load More" sucks. Dec 04 19:34:40 I might have to throw away the whole "Load More" thing for pagination. Dec 04 19:35:10 wow totally fell asleep on my keyboard to wake up a millions lines from line 23 and with my keyboard assistance turned on Dec 04 19:35:21 lol Dec 04 19:35:28 TacticalJoke: why not height? Dec 04 19:35:41 also why are you using load more button? Dec 04 19:35:48 if you have scroll down action Dec 04 19:35:53 plus bottom of listview Dec 04 19:35:57 automatically load more? Dec 04 19:35:58 While you were asleep, I concluded that ListView.setSelection was the best and that my whole idea was bad. Dec 04 19:36:05 g00s, show them a nexus Dec 04 19:36:06 Yeah, I think I might auto-load-more. Dec 04 19:36:15 you can also use onScroll to compute velocity Dec 04 19:36:25 Really? Hmm. Dec 04 19:36:25 g00s, and ask them how do they think they'll press buttons there without accidentally pressing home Dec 04 19:36:27 and just "throw" the listview down depending on the velocity Dec 04 19:36:39 which is the natural thing to do Dec 04 19:36:43 I kinda thought "Load More" would be neat, but it's actually tedious. Dec 04 19:36:48 yeah Dec 04 19:36:52 never make an extra step for the user Dec 04 19:36:54 Though I'll use "Load More" for the "More comments" thing. Dec 04 19:36:57 Ya. Dec 04 19:37:06 it should just be auomatic "pull to refresh" but instead of pull.. Dec 04 19:37:18 a continous action with the default swipe down listivew Dec 04 19:37:32 sure Dec 04 19:37:58 Right. I guess I need to determine how many posts from the bottom we should start loading more posts. Dec 04 19:38:22 you can use velocity so it is intuitive Dec 04 19:39:00 How do you do that with onScroll? Dec 04 19:39:50 onScrollStateChanged Dec 04 19:39:58 if idle->scrolling Dec 04 19:40:08 get absolute offset or whatever Dec 04 19:40:28 then in onTouch Dec 04 19:40:37 Mavrik ah good point ! Dec 04 19:40:43 grab sample delta Dec 04 19:40:49 Ah, onTouch. I see. Dec 04 19:40:51 of vertical displacement and time Dec 04 19:40:59 and now you have velocity Dec 04 19:41:01 Yeah, I might end up doing that. Thanks for the idea. :) Dec 04 19:43:26 I'm looking forward to implementing the "pretend we have more list items than we do" thing, using a circular buffer (I think). Dec 04 19:43:38 So that only N items are kept in memory at a time (the rest would have to be re-downloaded). Dec 04 19:44:09 That'd definitely justify auto-download-more, on a side note. Dec 04 19:45:54 ugh Dec 04 19:46:03 that would make me give you a star less Dec 04 19:46:15 why aren't you caching that info yo? Dec 04 19:46:44 Hmm, I guess I could. Haven't thought much about caching yet. Dec 04 19:47:35 The thing is, at least with my Reddit use, I so rarely want a cache of posts. I want caches of images, though. Dec 04 19:47:47 Posts are so... temporary on Reddit. Caching them feels weird. Dec 04 19:48:35 Same with comment listings, I think. Dec 04 19:48:41 Though I dunno. I'll probably cache all the things. Dec 04 19:49:27 I'll definitely do the savedInstanceState thing, so that if the app is killed while running in the background and you had a nice tree of collapsed comments, it all comes back. Dec 04 20:00:30 kjeldahl just noticed kawa 2.0 released Dec 04 20:00:46 lasserix_: Okay, I think you have a point there. If the list has simply moved them out of memory, it seems justified to cache them. Dec 04 20:02:47 Damn it, yet another idea for an app and me with no coding capabilities. Dec 04 20:04:24 You need to either acquire coding abilities or stop thinking of apps. Dec 04 20:05:29 I'm 30. Been trying to learn coding for over a decade. Dec 04 20:05:32 I can't do it. Dec 04 20:05:38 And the latter option is not gonna work either. Dec 04 20:05:57 What have you tried? Just curious. Dec 04 20:06:47 basic, c, c++, php, java, cobol Dec 04 20:06:49 The thing about programming is that some frameworks are murder, while others are so easy. Dec 04 20:06:49 And a few others. Dec 04 20:06:59 I just can't wrap my head around the very concept of it. Dec 04 20:07:05 It's not learning the syntax. Dec 04 20:07:10 That's easy. Dec 04 20:08:11 So what is it? Dec 04 20:08:23 And this is (in theory) a simple app, really. It's basically a folder that's always open. You can put shortcuts or widgets in it, resize it on your homescreen and scroll in it. Like a launcher page in a launcher page. Dec 04 20:08:50 That's what I'm looking at making. Dec 04 20:09:18 Cause sometimes you want to have more content on a homescreen that can fit. Dec 04 20:09:37 So a scrollable home-screen page, basically? Dec 04 20:09:50 Yeah. Dec 04 20:10:24 Hmm, I wonder whether such a thing already exists. Dec 04 20:10:32 That would be great. Dec 04 20:10:39 this damn ratingbar. only response on Stack said they tried it with no problems. I tried it on a coworker's computer, and it didn't work. Tried it in a new project, still didn't work... https://stackoverflow.com/questions/27251621/custom-ratingbar-styles-only-show-one-dot-other-weird-behavior Dec 04 20:12:24 IceBone: Someone on Google said this does it: https://play.google.com/store/apps/details?id=com.ss.launcher&hl=en Dec 04 20:12:32 No idea whether they're right. Dec 04 20:12:45 Yeah, but this is a launcher. Dec 04 20:13:20 I wonder whether it's possible to create this without replacing the entire launcher. I dunno. Dec 04 20:13:26 Like, could a widget do it? Dec 04 20:14:29 Well, the actual folders in the google now launcher don't, it would seem. Once you get to 16 items (4x4 grid), it stops. If you have root, you can enable infinifolders in nova launcher, for instance. Dec 04 20:16:15 What I really want is a god damn usable contacts widget. Dec 04 20:16:41 But nobody seems to be interested in making one of those. They're all crap. Dec 04 20:16:55 Unfortunately, much of Android is like that. Dec 04 20:17:00 I want to bring an activity back to the front. How do I do this, AND get the new intent that was fired off to do so? Dec 04 20:17:04 You can have 300 X apps, and they can all suck. Dec 04 20:17:08 Where X = anything. Dec 04 20:17:49 This is the closest to it: https://play.google.com/store/apps/details?id=com.gmail.yuyang226.contactswidget&hl=en Dec 04 20:17:58 But the design is from ICS. Dec 04 20:18:05 Not even JB. Dec 04 20:18:08 s73v3r: I think setting singleTop and using onNewIntent are the solution. Dec 04 20:18:36 onNewIntent is a method on Activity? Dec 04 20:18:52 correct Dec 04 20:19:01 Yeah: http://developer.android.com/reference/android/app/Activity.html#onNewIntent(android.content.Intent) Dec 04 20:19:19 thanks, I'll give that a try Dec 04 20:21:10 IceBone: Maybe you could pay/encourage someone to make one. Dec 04 20:21:15 Though I have no idea about its feasibility. Dec 04 20:21:23 Yeah, not easy finding people. Dec 04 20:21:35 Have you tried #android, in case someone knows of such a widget (I doubt it, but still). Dec 04 20:21:58 I hang in there all the time. :D Dec 04 20:22:03 Okay. lol Dec 04 20:22:15 You're more researched than I'd guessed. Dec 04 20:22:25 I always assume the worst. lol Dec 04 20:23:18 Yeah, I'm not surprised. Dec 04 20:23:30 I don't know anything about widgets; otherwise I'd give you a run-down on the feasibility. Maybe someone in here knows about them. :) Dec 04 20:29:05 Whenever I think "ListView", I heard Romain Guy's accent. Dec 04 20:29:40 whic is like, listvoo Dec 04 20:29:41 And when I think "Gradle" I hear Xavier Ducrohet's. Dec 04 20:30:06 LizVoo and Graeddle. Dec 04 20:33:36 Actually, it's more like LiizVoow and Graydel. Dec 04 20:35:42 weird-talkin furriners. Dec 04 20:41:32 TacticalJoke / IceBone : Google shows several widgets that do this. Are they just not the kind of design you want? It seems like a pretty easy thing to make. Dec 04 20:41:45 Example? Dec 04 20:42:54 https://play.google.com/store/apps/details?id=com.vcmdev.android.people&hl=en Dec 04 20:43:32 First result for 'contacts widget' Dec 04 20:43:37 Oh, that. Dec 04 20:44:22 Haven't tried that one, tbh. Dec 04 20:44:28 Didn't want to give money for something that might not work. Dec 04 20:44:50 But with google play's new refund period, I'll give it a go. Dec 04 20:45:54 Sure Dec 04 20:46:06 But yeah - this looks like something very easy to build to your liking Dec 04 20:46:12 If you decide to go down that path Dec 04 20:46:25 bobobospes: Is it just a case of using a GridView? Dec 04 20:47:42 can anyone give me any information on the ARM translation tool? is this a commercial product or is it free? i have googled for it but all i cant see any REAL information about it Dec 04 20:47:53 0x01000000 = 1? Dec 04 20:47:56 :-/ Dec 04 20:48:18 tricknology, i dont think so but 0.99999999.... is 1 :) Dec 04 20:48:35 well this doc seems to think so Dec 04 20:48:37 hi Dec 04 20:48:39 TacticalJoke, basically just piecing together an AdapterView (ListView/GridView/etc) and the contact provider Dec 04 20:48:39 http://www.media.mit.edu/pia/Research/deepview/exif.html Dec 04 20:48:42 and it makes sense Dec 04 20:48:48 because there is only 0 1 and 3 Dec 04 20:48:50 2* Dec 04 20:50:12 bobobospes: that's almost good enough, but its rendering is bad. No antialiasing. :D Dec 04 20:50:14 I'm picky, I know. Dec 04 20:51:07 so nobody here knows what the arm translation tool is? Dec 04 20:51:18 And I can't refund it. Dec 04 20:51:21 I thought it was 2 hours! Dec 04 20:51:22 i have some arm code i need to run under genymotion which is x86 only Dec 04 20:51:33 Oh... wait... I've already purchased this before it would seem. Dec 04 20:51:42 I didn't get an email from the play store. Dec 04 20:51:42 lol Dec 04 20:51:54 how can I change drawer button background using Toolbar? Dec 04 21:01:28 oh lord Dec 04 21:01:37 don't name your ImageViews "image" in code Dec 04 21:01:40 makes text search a bitch Dec 04 21:26:04 hmm Dec 04 21:26:17 Why are my images getting stretched even when the scaleType is centerInside? Dec 04 21:38:54 matt_j, is the image set in batckground or in src? Dec 04 21:39:05 background stretches to fit regardless Dec 04 21:39:33 oh, I'm sorry Dec 04 21:39:36 It's an imageview Dec 04 21:39:42 not using backgrounds Dec 04 21:41:24 Hmm... is everything set in xml? Dec 04 21:41:50 the image is being set by a url image loader Dec 04 21:43:11 Can't help without seeing code, but my first reaction is that it's most likely setting background instead of src Dec 04 21:44:30 In dealing with MotionEvent objects, I sometimes get getPointerCount returning something > 1 on events which aren't ACTION_MOVE. Is that normal? Dec 04 21:44:43 I thought only ACTION_MOVE types would do that. Dec 04 21:45:18 hey guys, i want my app to start if booting the phone is completed and if, after that, the phone is connected to ac power. I`m not sure what is the best way to do it: start a service, which has the OnPowerReceiver-BroadcastReceiver implemented or Dec 04 21:45:19 is it even possible to implement the onPowerReceiver Broadcast within the BootCompletedReceiver so that i dont need a service running all the time.....some hints? Dec 04 21:46:38 adkins don't have either; have a boot completed receiver that enables your power connected receiver Dec 04 21:47:05 sarbs: ok seems like what i want......how do i enable the powerReceiver? Dec 04 21:47:20 and probably a boot started receiver that disables it, or something.. since you shouldn't rely on shutdown events to disable it Dec 04 21:48:05 https://developer.android.com/reference/android/content/pm/PackageManager.html#setComponentEnabledSetting(android.content.ComponentName,%20int,%20int) Dec 04 21:49:23 with that you can enable or disable components that you've declared in your manifest. disabled receivers won't respond to the event, so all you've gotta do is disable your power receiver when you don't want it, and enable it when you wanna start listening again Dec 04 21:51:55 sarbs: thank you, i think i`ll handle it....."and probably a boot started receiver that disables it, or something.. since you shouldn't rely on shutdown events to disable it" i dont understand though....what should boot started receiver disable? the onAC-Receiver? why should i disable it if i enable it AFTEr boot ? Dec 04 21:52:57 adkins component enabled settings are (i believe) persisted across reboots, so if in the manifest you say enabled="false", and then you enable it after the first boot completes, when you boot the phone the second time it will still be enabled prior to boot_complete Dec 04 21:53:27 it won't be disabled again until you explicitly disable it, or the package is reinstalled Dec 04 21:54:43 reboots only? or shutdown and turn on again also? Dec 04 21:54:55 same thing Dec 04 21:54:59 ok Dec 04 21:55:19 i don't think android makes a distinction between a soft and a hard reboot Dec 04 21:55:27 there's a framework restart, which is different, but that's a whole 'nother can of worms and isn't relevant Dec 04 21:59:30 disableing the onBootcompleted-Receiver at StartUp ONLY if i dont want it anymore in the future right? Dec 04 22:01:32 sarbs?`just wanna make sure i understood correctly since it doesnt make sense to stop the BootCompletedReceiver at Start if i still want it ;) Dec 04 22:03:17 nono, sorry. actually it appears as if my idea has a flaw in it; there doesn't seem to be any boot notification other than BOOT_COMPLETED Dec 04 22:04:16 i was imagining there was a BOOT_STARTED or something intent that you could use to mark the start of "disable power connected receiver" time, and then boot completed would mark the end of "disable power connected receiver" Dec 04 22:04:28 however it doesn't appear that that will work. Dec 04 22:05:50 sarbs: can i not just always use the BootcompletedReceiver and read from sharedPReferences if i want the onPowerconnected - Receiver or not and enable/disable it ? Dec 04 22:06:50 you can, but what i'm getting at is i don't see a reliable way using those methods to know that you *shouldn't* respond to power connected Dec 04 22:07:17 aka, no easy way to tell if power connected is enabled because you've just finished booting, or you finished booting a full power cycle ago Dec 04 22:07:29 making any sense? Dec 04 22:08:29 not 100% ;) Dec 04 22:09:12 if i receive BootCompleted and didnt enable onPowerReceiver yet, i havent enabled it yet...... Dec 04 22:09:15 hi Dec 04 22:09:20 say you've got some flag that determines whether or not you want to handle the POWER_CONNECTED event. that flag can be a shared pref, or it can be whether or not power receiver is enabled, whatever Dec 04 22:09:34 I'm trying to implement youtube search into my app Dec 04 22:09:35 or are you thinking if i enabled onPower before reboot it can still live? afaik it doesnt Dec 04 22:09:44 code sample here: https://developers.google.com/youtube/v3/code_samples/java?hl=ro#search_by_keyword Dec 04 22:09:52 but I neet all those com.google packages Dec 04 22:09:55 and I don't have them Dec 04 22:10:05 how do get them to my project? Dec 04 22:10:08 both of those examples of flags, are persisted across reboots. so, the first time i turn the phone on, it will be false before BOOT_COMPLETED comes across. once BOOT_COMPLETED is fired, i switch that flag to true. Dec 04 22:10:33 if i then turn the phone off, and turn it back on, BOOT_COMPLETED will *not* have fired yet, but that flag will still be true Dec 04 22:12:15 i think i just have rebootet without doin anythin in BootCompleted-Receiver and onPowerReceiver wasnt active. You probably mean if i enabled it like you suggested right (Component etc)? Dec 04 22:13:44 yes. if you don't want to need a service constantly living, onPowerReceiver will have to be a receiver defined in the manifest (not registered in code with a Context) Dec 04 22:15:37 s1k3s http://bit.ly/1ilUqxx Dec 04 22:16:05 sarbs, I found that api Dec 04 22:16:13 I dont need the player api, I need the data api Dec 04 22:17:04 aha you probably want https://code.google.com/p/google-api-java-client/wiki/APIs then Dec 04 22:18:40 sarbs: well,...i think i just start playing a lil. thx for the hint, i might be back ;) Dec 04 22:21:52 Android Studio 1.0 Release Candidate 3 Released Dec 04 22:22:14 adkins i can think of one way you might be able to accomplish it, but it's kind of hacky. have your BootCompletedReceiver create a PendingIntent that points to a service or receiver (whatever is appropriate for what you want to happen when you plug into AC). have your PowerConnectedReceiver create the _exact same_ PendingIntent (same action, data, type, class and categories, and requestCode), but specify FLAG_NO_CREATE. if you Dec 04 22:22:14 get a PendingIntent back, start that. if you *don't* get a PI back, then BootCompletedReceiver has not executed yet and PowerConnectedReceiver does nothing. Dec 04 22:23:45 PendingIntents are *not* persisted across reboots, but they *are* persisted beyond process death - this basically keeps the flag you need in memory (instead of on disk), but gives responsibility of it to system_process (which never dies.. if the flag was kept in your own memory, it would last only as long as your process) Dec 04 22:24:08 sarbs: ok thank you, i`ll save this info. havent done yet some of the stuff you were talking about....so need to study it Dec 04 22:24:19 ;) Dec 04 22:24:20 i've got a library i'm preparing to publish that uses that mechanism actually Dec 04 22:24:30 adkins cool, get back to me w/questions if you have any Dec 04 22:24:50 for (AndroidStudioRelease release : releases) { if (!release.supportsJvmUnitTesting()) { sigh(); }} Dec 04 22:25:06 TacticalJoke helluvalotta sighs Dec 04 22:25:08 sarbs: thx dude, really appreciate your awesome help Dec 04 22:25:10 :D Dec 04 22:25:46 public void sigh() { useEclipse(); } Dec 04 22:26:34 I'm itching to switch to AS after reading the IntelliJ tutorials. (The code-editing stuff looks nice.) Maybe one day. Dec 04 22:27:33 i use actual intellij Dec 04 22:27:40 Yeah, I guess I could just use that. Dec 04 22:27:55 it lags behind AS in the xml editor a little bit but beyond that the extra configurability afforded is WELL worth it. Dec 04 22:32:34 TacticalJoke heh Dec 04 22:32:37 The import com.google.api.services.samples cannot be resolved Dec 04 22:34:08 gradle plugin rc3 too Dec 04 22:34:19 s1k3s think about that one :) Dec 04 22:34:35 sarbs, they didn't include that jar Dec 04 22:34:59 yeah i know... think about that package name for a sec and why they might not have included it in the API Dec 04 22:35:24 .samples. Dec 04 22:35:37 that's weird Dec 04 22:35:51 is it not needed? Dec 04 22:37:42 hmm ok, the javadoc says the Builder uses something else Dec 04 22:46:08 sarbs, got it :D Dec 04 22:46:16 :D Dec 04 23:05:32 Hi Dec 04 23:05:52 I changed my Google Plus permissions screen to only ask for basic permissions Dec 04 23:05:57 It's a really small screen. Dec 04 23:05:58 But Dec 04 23:06:07 (It's just a Google screen now) Dec 04 23:06:36 2 questions: (1): any way to make this automatic? Just checking. (2) What's the typical accept/reject rate on these screens? Dec 04 23:20:35 ffs Dec 04 23:20:53 I restarted eclipse and now I get "The import com.google.api.services cannot be resolved" Dec 04 23:20:56 d'oh Dec 04 23:26:09 sarbs: i did a lil quick and dirty coding,......its already late here in germany and tired, but everything seems to work if i write to sharedPreferences while in MainActivity if i want or dont want starting my activity at powerConnected. I just check in BootCompleted whats in SharedPreferences and enabled/disable it explicitly. Dec 04 23:26:12 And i also check that in onResume of MainActivity and disable/enable it also so that it doesnt always get enabled when starting MainActivity since BroadcastReceiver is hardcoded in manifest. Maybe i`m still missing your point of "its not reliable" because i`m tired ;) but maybe its all good? Dec 04 23:26:29 oh jesus you're in germany? what's it like 1 or 2am over there? Dec 04 23:26:30 ...hope text didnt get cut off Dec 04 23:26:43 0:30 Dec 04 23:27:15 not that bad i guess Dec 04 23:27:31 kk Dec 04 23:27:45 when are you turning off the powerConnected receiver? Dec 04 23:28:48 i`m playing around in a seperated testingApp. i have just a button for enableing/disableing. it`ll be later in PreferenceActivity in the app its supposed to be in Dec 04 23:30:01 gotcha. if *i'm* understanding your situation correctly (and i might not be), you want the powerConnected receiver to be disabled every time the device turns on, until the BOOT_COMPLETE intent is sent Dec 04 23:30:37 using a SharedPreference, the only way to ensure that will be to disable the setting sometime chronologically before the device powers off Dec 04 23:31:07 but you can't reliably make sure that happens, since i could simply rip the battery out and the device would die before it had a chance to execute any "turn off powerConnected" code Dec 04 23:31:16 well i want my app to start if its connected to power and also if it hasnt started yet after reboot Dec 04 23:34:03 well i`m not sure if i`m getting you correctly ;) if i set "dont start app on ac power" in preferenceActivity and i havent stored it in SharedPReferences yet aand you rip the battery out,......yes, it will still start in ac power.... Dec 04 23:34:42 nah i think it's me that's misunderstanding, i hadn't considered an activity and i'm not sure what the overall workflow is. as long as it's workin like you want, awesome :) Dec 04 23:34:54 lol Dec 04 23:35:07 yes man, i guess so too Dec 04 23:35:11 funny Dec 04 23:35:13 just make sure when testing to think of not just "how is this supposed to work", but "how should it NOT work" and make sure to test those too Dec 04 23:36:41 well if i always disable it in onResume in my MainActivity in my App.......i cant see why it should still be enabled. do you see it?= Dec 04 23:37:54 Hello guys. I'm trying to get and set media volume. What's the range of value the set method accepts? Is it (0 to 100) or (0 to 1)? Dec 04 23:39:11 sarbs: if i disable it in onResume can something happen so that it will be enabled because its still registered in Manifest? Dec 04 23:40:24 that would make it so that it would only auto-start once, if i'm understanding correctly (unless the user switched it back on via a button or something after onResume) Dec 04 23:40:32 if that's what's desired then that's perfect Dec 04 23:40:51 most of my work involves services so i was thinking differently Dec 04 23:41:55 auto-start once per boot, i should clarify. BOOT_COMPLETED -> POWER_CONNECTED -> activity starts, disables onPowerConnected -> leave activity, disconnect and reconnect power -> POWER_CONNECTED -> no activity start Dec 04 23:44:02 BOOT_COMPLETED -> POWER_CONNECTED -> activity starts (if in SharedPreferences is set true); BOOT_COMPLETED -> POWER_CONNECTED -> activity starts not (if in SharedPreferences is set false); Dec 04 23:44:43 right.. what i'm thinking of is if i don't reboot the phone, but disconnect and reconnect the power.. do you want the activity to start again? Dec 04 23:45:48 well one has to live with that, if one wants that option Dec 04 23:46:35 buit user can select between: start app on bluetooth connected OR power connected, OR dont autostart. Dec 04 23:46:57 so i`m not penetrating ;) Dec 04 23:47:48 haha sounds good Dec 04 23:47:53 yeah i think i was just confused as to the use case Dec 04 23:48:16 yes probably, i guess its my bad, pretty uncommon ;) Dec 04 23:48:25 i should have clarified more Dec 04 23:49:09 thx a lot man, never got that much help in here. Dec 04 23:49:41 gotto rush into bed now Dec 04 23:50:49 sarbs: so good night ;) Dec 04 23:51:03 cya tomorrow Dec 04 23:52:34 sarbs: yes cya Dec 05 00:01:44 anyone around? Dec 05 00:03:45 nope Dec 05 00:05:29 I'm here Dec 05 00:05:40 run! Dec 05 00:05:47 Drop everything Dec 05 00:06:21 i`m still around.....well off right now, but i had to laugh really loudly because of the name "ProLoser". thank you for that ProLoser, just awesome. ;) see you guys! Dec 05 00:15:11 hai Dec 05 00:15:13 anyoen? Dec 05 00:17:43 I am getting java.lang.ClassCastException: android.widget.LinearLayout$LayoutParams cannot be cast to android.widget.AbsListView$LayoutParams when attempting to add a fragment dynamically. Everything works fine when adding it statically. Dec 05 00:18:15 I have created a gist to look at the code with the stacktrace of the exception which includes the line numbers Dec 05 00:18:16 java.lang.ClassCastException: android.widget.LinearLayout$LayoutParams cannot be cast to android.widget.AbsListView$LayoutParams Dec 05 00:18:27 https://gist.github.com/shercoder/26815678bceb45b8fa7e Dec 05 00:19:45 Hi Dec 05 00:20:03 I have a private WebView object in my activity Dec 05 00:20:10 but I am worry about it Dec 05 00:20:22 it may be null in some cases Dec 05 00:20:48 when activity destroyed, stopped, ... Dec 05 00:20:58 what should I do? Dec 05 00:21:03 make it static? Dec 05 00:21:10 anyone know how hard it is to make an app that gets IMEI and sends to server? Dec 05 00:22:08 KingInTheNorth_: Have you learned Java Programming Language? Dec 05 00:22:28 I don't know if you're given the IMEI. I know at one time you could get it, but that might have changed Dec 05 00:22:41 you are Dec 05 00:23:06 MalekAlrwily: I do not Dec 05 00:23:14 tbh am gonna hire someone prob Dec 05 00:23:36 wut Dec 05 00:23:40 If it's easy to get from the SDK, then it would be extremely easy to send it to the server Dec 05 00:25:47 It feels like the compiler should complain about public constructors in abstract classes. Dec 05 00:25:52 But it doesn't. Dec 05 00:26:07 has anyone tried Dec 05 00:26:16 adcolony? Dec 05 00:26:21 i am so jaded Dec 05 00:26:26 i don't want to try Dec 05 00:26:41 Agamemnus: The way you break sentences into multiple posts is annoying. :p Dec 05 00:27:23 :( Dec 05 00:27:25 It's nice when I make a specific type of class using Android Studio and it puts in a punch of prewritten code with heaps of things that are depreciated Dec 05 00:27:48 I have "private WebView webView;" in my activity, but what happen when activity destroyed? Dec 05 00:28:29 MalekAlrwily: I guess the WebView gets destroyed. Dec 05 00:28:46 (I say "I guess" because I've not yet used WebView, and maybe it has magical powers.) Dec 05 00:29:08 TacticalJoke: When activity restoring it's state, will it be null? Dec 05 00:29:16 Morning all. I've got a question for you: I'm using a Notification Listener Service, which is declared in the Manifest. I'm wondering if there's any way to write/use different 'versions' of the service depending on the API level.. So, perhaps a parent 'service' class which directs to a subclass depending on API level. Dec 05 00:29:29 MalekAlrwily: The framework might restore its state. I'm not sure. Dec 05 00:29:36 The framework restores the state of many Views. Dec 05 00:30:07 TacticalJoke: Thank you, I will try and see Dec 05 00:30:43 i don't get it Dec 05 00:31:03 it's like no one uses ads Dec 05 00:31:08 Ads suck. Dec 05 00:31:18 They do not. Dec 05 00:31:37 I spent $7 today so far. And made $.55. Dec 05 00:31:47 Their purpose in life is to annoy us into giving up money. Dec 05 00:31:49 Anyone able to invest 30-60mins of their time and make a project that gets the imei of an phone and sends to a server? Dec 05 00:31:57 or anyone wanna help me? http://developer.samsung.com/technical-doc/view.do?v=T000000103 Dec 05 00:32:06 Has anybody ran into the following exception while working with ListFragment and adding it dynamically: https://gist.github.com/shercoder/26815678bceb45b8fa7e Dec 05 00:32:35 java.lang.ClassCastException: android.widget.LinearLayout$LayoutParams cannot be cast to android.widget.AbsListView$LayoutParams Dec 05 00:32:41 KingInTheNorth_: if you are using it for user tracking, it is better to use the app platform instead Dec 05 00:33:03 since you don't want to track devices, you want to track users Dec 05 00:33:05 ideally Dec 05 00:33:15 I am not. Just need the IMEI specifically Dec 05 00:33:31 I see. Dec 05 00:33:52 iamshercoder: paste the line here Dec 05 00:34:07 I don't know Dec 05 00:34:16 maybe you can post the question on stack overflow Dec 05 00:34:26 if you want to hire someone, i suggest elance Dec 05 00:34:29 who? Dec 05 00:34:30 MalekAlrwily: getListView().setAdapter(mCampaignAdapter); Dec 05 00:34:31 me? Dec 05 00:34:36 yes Dec 05 00:34:50 wont it be offtopic? :$ Dec 05 00:35:29 iamshercoder: then what is the next stack trace element? Dec 05 00:35:37 iamshercoder: I've had that exception before. Hmm. Dec 05 00:36:05 In my case, it occurred when trying to return a view that hadn't just been inflated. Dec 05 00:36:11 I forget the exact details. Dec 05 00:36:31 MalekAlrwilly: Caused by: java.lang.ClassCastException: android.widget.LinearLayout$LayoutParams cannot be cast to android.widget.AbsListView$LayoutParams Dec 05 00:36:32 at android.widget.ListView.clearRecycledState(ListView.java:515) Dec 05 00:36:33 at android.widget.ListView.resetList(ListView.java:501) Dec 05 00:36:34 at android.widget.ListView.setAdapter(ListView.java:444) Dec 05 00:37:12 It needs the layout params for a ListView but it's not getting them, for some reason. Dec 05 00:37:22 iamshercoder:http://stackoverflow.com/questions/11492678/android-classcastexception-on-layoutparams-from-linearlayout-to-abslistview Dec 05 00:37:43 this question helped me before Dec 05 00:38:00 It works if I add the fragment statically. It only gives this exception when attempting to add the fragment dynamically. Dec 05 00:38:36 brb Dec 05 00:39:13 so no one can help? -_- Dec 05 00:40:02 no one can help Dec 05 00:40:09 confirmed Dec 05 00:40:45 \-_- Dec 05 00:40:48 fk Dec 05 00:40:52 MalekAlrwily: In that example, the item layout only contains only one item, whereas in my case I have multiple views in item Dec 05 00:41:12 I have an Android 5.0 device, build LRX21P, connected via USB to a windows computer. It's charging. However, it doesn't show up in adb devices. Tried adb devices, adb kill-server adb devices, unplug device adb kill-server plug in device adb start-server adb devices, and it's not showing up. Dec 05 00:42:02 iamshercoder: i don't think it is different Dec 05 00:46:06 MalekAlrwilly: If I loose the root tag for item layout then it complains about having multiple root tags because I have two TextViews in that layout Dec 05 00:46:15 *lose Dec 05 00:49:33 yo Dec 05 00:49:45 pm me anyone who wants info on a project Dec 05 00:58:49 hey guys, I'm building an alarm clock app -- when the alarm plays back -- how to disable the nav bar? Dec 05 00:59:04 I can hide it but the stock alarm clock works differently Dec 05 00:59:38 can I do somethign like “while c in string[index:] != ‘\x00’”? Dec 05 00:59:49 I mean I know that line is incorrect but is there something like it that is not a for loop? Dec 05 01:00:05 http://en.wikibooks.org/wiki/Python_Programming/Loops does not have what I’m looking for Dec 05 01:00:11 Hmm, AbsListView has public constructors. Dec 05 01:00:20 Isn't it more sensible for abstract classes to have protected constructors? Dec 05 01:00:34 oops, wrong room lool Dec 05 01:02:32 I hope Java doesn't know you're messing with Python on the side. Dec 05 01:06:45 KingInTheNorth_ check title - no advertising jobs Dec 05 01:10:21 is there anyway to have the xml visual and code view open at the same time in eclipse? Dec 05 01:12:15 tricknology, what you want is fundamentally a for loop... Dec 05 01:12:29 tricknology, and python has for comprehensions that sound like what you want Dec 05 01:12:59 yeah I just got it figured out.. learning new languages I kind of make up weird stuff Dec 05 01:13:04 tricknology, https://docs.python.org/2/tutorial/datastructures.html#list-comprehensions Dec 05 01:13:06 or silly ways to do things Dec 05 01:13:33 c for c in string if c != null Dec 05 01:13:36 that’s waht I want Dec 05 01:13:46 thanks Dec 05 01:16:16 What do you folks think about the idea of declaring all classes public (not package-private) to ease mainenance? Dec 05 01:16:44 I guess it's not ideal in a public API, but outside of that it seems kinda handy. Dec 05 01:17:58 Does anyone else have a bunch of trouble with the logcat going completely quiet? I often have to reconnect my device, or restart adb, and sometimes neither seem to help. Dec 05 01:20:26 timusus yeah, usually if my laptop goes to sleep adb gets borked Dec 05 01:21:16 [adb kill-server && adb devices] seems to fix it for me. Dec 05 01:21:19 For me, and I'm not exaggerating - sometimes it will be every single time I 'run' my app Dec 05 01:21:35 Weird. I get it only occasionally. Dec 05 01:22:09 Also, often the log is there, but I have to turn the automatically generated filter off Dec 05 01:22:20 Hello all, for some reason, I can not seem to get that ADB RSA message to pop up on my phone when I try to connect in Debug mode... My phone won't authorize my PC. It works fine on any other computer... Anyone know where to look? Dec 05 01:22:28 timusus: are you on windows ? Dec 05 01:22:38 I'm not here to complain.. just, fuck! Sometimes I have to quit everything, close the emulator, restart adb. Dec 05 01:22:40 Yes, on Windows. Dec 05 01:22:46 lol wut, AS rc4 Dec 05 01:22:50 TenCashMan: Windows? Try changing the USB mode to PTP. Dec 05 01:23:22 maybe he needs to install more stable usb drivers Dec 05 01:23:30 On device? This problem is even more prominent in the emulator(s) Dec 05 01:23:32 g00s: IDEA 14.0.1. Dec 05 01:23:37 But thanks for all the tips. Dec 05 01:23:40 I get "Page not found", g00s. Dec 05 01:23:43 It's windows, sorry for leaving that out. freeone3000, I've tried that, I tried removing all keys from my device, I tried manually copying the keys, I tried stopping the server on my PC and restarting Dec 05 01:23:43 Just looked on /r/androiddev. Dec 05 01:23:48 timusus: try looking for the newest USB driver for you device and install that Dec 05 01:23:49 I just don't know what else to try Dec 05 01:23:50 freeone3000 is rc4 based on 14.0.1 ? Dec 05 01:23:57 Oh - I realised your comment was for someone else. Dec 05 01:24:05 OK, I'll do that. Dec 05 01:24:13 It'd be funny if they said "After all the complaints, we've decided to implement NDK development and JVM unit testing". Dec 05 01:24:16 Hence RC4. Dec 05 01:24:36 TacticalJoke what if - unit testing is AS 2.0 :D Dec 05 01:24:51 I totally expect that. :) Dec 05 01:24:56 TenCashMan: that happens on ADB not on USB connect, so it could be as someone has said, a driver problem (windows), it could be a permission problem (linux) if you didn't install the udev rules Dec 05 01:25:14 TenCashMan: or it could be a usb cable problem (if you havne't used that same cable on another computer for debug mode) Dec 05 01:25:17 g00s: Ah, no, it looks like Android Studio never made the leap to 14. Dec 05 01:25:43 I've tried removing the drivers and reinstalling. I'm gonna reinstall my android SDK (Oh boy..) and try reinstalling the drivers again to give me a clean slate Dec 05 01:25:55 (Which, interestingly enough, *does* support NDK and Java unit testing. In community.) Dec 05 01:26:26 gladly i don't need NDK Dec 05 01:26:29 It used to work fine before I updated to 5.0 Dec 05 01:26:45 Waht is this format? @\r\x03 Dec 05 01:26:47 TenCashMan: Sure it's still in PTP mode? Dec 05 01:26:58 I've put it in and out multiple times to test if it would work Dec 05 01:26:59 I mean I know it’s 200.. maybe Dec 05 01:27:01 TenCashMan: I don't know much of anything about the windows side of the driver problem Dec 05 01:27:01 tricknology: Gunna need another byte at minimum. Dec 05 01:27:17 dragorn, thanks for trying to help anyhow :P Dec 05 01:27:39 Can anyone help me send a string that contains an IMEI to a server? I know hwo to get the IMEI Dec 05 01:27:51 Oh I think I am messing up here.. it is a rational and I am diving incorrectly Dec 05 01:27:54 TenCashMan: but the key prompt is when adb connects, not when it connects to USB, so it makes sense if you have a driver problem that you're not getting that far Dec 05 01:27:58 freeone3000: Does IntelliJ 14 support JVM unit testing when Gradle is the build system? Dec 05 01:28:02 thanks freeone3000 Dec 05 01:28:20 I'm sure it's a driver problem or a version mismatch or something, but I don't know where to look to fix it Dec 05 01:28:52 Can anyone help me send a string that contains an IMEI to a server? I know hwo to get the IMEI Dec 05 01:29:12 probably Dec 05 01:29:35 TacticalJoke: Yes. Dec 05 01:29:45 Wait, it maybe working now... it doesn't say unauthorized anymore Dec 05 01:29:49 TacticalJoke the angels are singing ! Dec 05 01:29:56 or narwhals Dec 05 01:30:17 TacticalJoke: One of the new features in 14 is that you get the same submenu when running tests natively, through maven, or through gradle, including "debug this test" and "run this test again" and "re-run failing test" context menu options. Dec 05 01:30:41 freeone3000: Hmm. Does this mean we can expect this in Android Studio soon? Dec 05 01:30:47 If so, the angels really are singing. :) Dec 05 01:30:53 TacticalJoke: Whenever they move to IDEA 14, sure. Dec 05 01:31:07 TacticalJoke or maybe we're hearing the siren song Dec 05 01:31:14 Having used Android Studio, I'm still not sure what it adds over IDEA CE. Dec 05 01:31:15 you never know with android :) Dec 05 01:33:12 Alright it works now. If anyone was interested, the problem was that I didn't have access to my Users (C:\Users) folders where my .Android folder is and subsequently my authentication keys. This was a problem due to dual booting and using one OS to search the other OS's partition I believe Dec 05 01:33:15 freeone3000: yeah, I just stick with IDEA Dec 05 01:33:29 freeone3000, ditto Dec 05 01:33:54 not to mention, scala support is about nonexistent in studio Dec 05 01:34:00 and that will never change Dec 05 01:34:08 haha Dec 05 01:35:08 So if I were to use IntelliJ today I could create an Android project using Gradle and easily create and run JUnit 4 JVM unit tests, right? Dec 05 01:35:16 TacticalJoke: Yes. Dec 05 01:35:19 Interesting. Dec 05 01:35:33 Not necessarily "Easily" with Gradle... Dec 05 01:36:14 What? Gradle's manual is only 1,000 pages long. ;D Dec 05 01:36:22 TenCashMan: test { filter { includeTestsMatching "*Test" } } Dec 05 01:37:34 Hmm. What if I use a weird naming scheme (I don't, but just curious). Dec 05 01:40:14 just a shower thought, if AS doesn't even support scala maybe that indicates how much google cares about it Dec 05 01:40:27 freeone3000: In Eclipse, it Just Works[tm]. No need to worry about naming and stuff. Isn't the same possible in IntelliJ? Dec 05 01:40:58 TacticalJoke: IDEA syncs its internal state from your gradle build. If it builds with gradle, intellij can understand it. Dec 05 01:41:03 TacticalJoke 1000 pages with 10 pages of useful information Dec 05 01:41:06 Howdy. Where would be a good place for an employer to reach out for decent Android devs to hire? Dec 05 01:41:15 g00s: I was gonna post something to /r/showerthoughts earlier: In respect to the creator of the telephone, phones with OLED screens should be called Bell Curves. Dec 05 01:41:32 But I don't have the motivation. Dec 05 01:42:00 freeone3000: Ya. Just wondering if there's a way to do it without requiring that "*Test" thing. Dec 05 01:42:19 TacticalJoke: Of course, yeah. See the gradle manual. Dec 05 01:42:52 (I don't know gradle that well, and had to pull up the manual for that example. Maven it'd start with maven-surefire-plugin and go for another 50 lines.) Dec 05 01:44:24 i think its pretty funny AS comes bundled with JavaFX plugin but not scala Dec 05 01:45:10 Hmm, this plugin says "Android Studio (and Intellij 14) IDE support for Android gradle unit tests": https://github.com/evant/android-studio-unit-test-plugin Dec 05 01:45:22 If IntelliJ 14 supports it already, wouldn't they say "This isn't needed in IntelliJ 14? Dec 05 01:47:33 I don't mean to be all doubtful. Guess I just don't wanna lose another six hours trying to get it all working. :D Dec 05 01:47:37 It was about six hours last time. Dec 05 01:47:49 Plus 572 units of stress. Dec 05 01:49:10 TacticalJoke: are you installing AS ? Dec 05 01:49:14 Nah. Dec 05 01:49:20 Was considering IntelliJ, though. Dec 05 01:49:29 you can run them all Dec 05 01:49:55 Yeah. Just wanna wait till I'm certain that JVM unit testing is supported. Then I'll spend a day (or whatever) learning the new IDE, and I guess another day converting my project. Dec 05 01:50:03 and import from one to another Dec 05 01:50:05 Maybe learning won't take that long. I dunno. Dec 05 01:50:18 Ya. Dec 05 01:50:28 it's basically the same crap to me Dec 05 01:50:47 but the pro's seem to like intelliJ more Dec 05 01:51:06 The code-generation tools look really good in IntelliJ. Dec 05 01:51:17 I think the refactoring isn't really better than that of Eclipse, now. Dec 05 01:51:48 But stuff such as "Convert if..then to expression using ternary operator" isn't possible in Eclipse, I think. Dec 05 01:52:15 I like typing it all by hand Dec 05 01:52:27 That's so slow, though, for big refactorings. Dec 05 01:52:52 Let's say that you're refactoring an entire system of classes. Automation makes your life a million times easier (and faster). :) Dec 05 01:52:57 I don't use layout editors either Dec 05 01:53:13 Yeah, the layout thing isn't great. I just use that as a preview. Dec 05 01:53:46 I dunno, I can hit Ctrl - F and search around pretty fast Dec 05 01:54:42 I had to do a little iOS development for a paper, damn storyboards are nice Dec 05 01:55:05 layout editors can be decent Dec 05 01:59:53 I can't trust layout editors, I guess from past experiences Dec 05 02:12:48 shmooz: so then how do you preview your code? Dec 05 02:15:31 DadFoundMy: I hit the build button Dec 05 02:15:58 or Run button Dec 05 02:16:19 shmooz: oo and run it through the emulator or adb? Dec 05 02:16:29 I use code editors just not the layout editor part Dec 05 02:16:37 i guess its because im so new to xml stuff that most of my code is guess and check when doing layouts Dec 05 02:16:57 adb on devices Dec 05 02:25:10 When using LatLngBounds, if the user Dec 05 02:25:54 if the user's getMyLocation is null, whatever values I give CameraUpdateFactory.newLatLngBounds, it zooms in way way too much.. Dec 05 02:26:13 Using Google Maps API v2. Any ideas? Dec 05 02:29:10 "Constructor call must be the first statement in a constructor" Dec 05 02:29:12 God dammit, Java. Dec 05 02:37:39 wooooo pick em challenge4eeee coinnnn wooo Dec 05 02:54:02 I'm on OSX, my friend is on Linux. He has a bad internet connection. He wants to get started with Android. He has android studio, but no sdk or platform or emulators. Are these things that I can drag from my mac onto usb then back onto his linux machine? Dec 05 02:57:14 eghdk_ if he has a bad internet connection, can he still read SO? because if not ... its pretty rough going Dec 05 02:57:28 and the offline docs kinda suck too Dec 05 02:57:55 g00s: Yeah he can. It's just apparently his connection is intermitenent. So his download keeps failing. ya know? Dec 05 02:58:15 eghdk_ yeah, i had that problem at the library Dec 05 02:58:38 So you think the sdk platforms are the same and the emulators? Dec 05 02:58:56 you probably can put those on usb **** ENDING LOGGING AT Fri Dec 05 02:59:58 2014