**** BEGIN LOGGING AT Fri Jun 17 02:59:58 2016 Jun 17 03:01:03 how do i completely remove every trace of android studio on windows, i think it takes too much disk space so i want to start fresh and reinstall just latest Jun 17 03:01:26 And reinstalling will make it take less disk space? Jun 17 03:01:35 presumably yes Jun 17 03:01:44 o_O Jun 17 03:01:52 what is confusing you Jun 17 03:02:17 poua: open up the external sdk manager and remove everthing you dont want.. Jun 17 03:02:27 i have some files for version 1.5 then files for version 2.1 Jun 17 03:02:41 i wanna remove all traces of it Jun 17 03:02:43 then remove the old 1.5 files Jun 17 03:02:43 everything Jun 17 03:02:53 there seems to be a lot of folders Jun 17 03:02:58 poua: go to your home directory and remove it Jun 17 03:03:04 dunno why everything isnt neatly inside one folder Jun 17 03:03:06 poua: like what? Jun 17 03:03:08 it is Jun 17 03:03:18 1 folder for program, 1 folder for your data Jun 17 03:03:19 simple Jun 17 03:03:29 what about all these folders starting with a . Jun 17 03:03:45 those are the data folders i spoke of Jun 17 03:03:52 looks like you have folders for older versions Jun 17 03:04:04 they arent in one folder Jun 17 03:04:10 they are all over user folder Jun 17 03:04:17 nothing neat about it Jun 17 03:04:18 like what? Jun 17 03:05:01 like this... my user folder http://i.imgur.com/w95TgFf.png Jun 17 03:05:15 all those . files are not android Jun 17 03:05:23 that's why i ask Jun 17 03:05:28 only the Android ones Jun 17 03:05:28 since i dont know which are which arent Jun 17 03:05:29 lol Jun 17 03:05:40 and .gradle is the gradle compiler ofc Jun 17 03:05:50 the rest are for other apps on your computer Jun 17 03:06:17 you can remove .AndroidStudio1.5 Jun 17 03:06:17 hmm, so then 3 folders to remove, 1.5 2.1 and gradle? Jun 17 03:06:27 yes if you want to completly remove it Jun 17 03:06:40 yes i already uninstalled from program files now im cleaning traces Jun 17 03:06:47 this will ofc mean you will loose all your settings Jun 17 03:06:57 didnt have any important settings Jun 17 03:07:05 ok Jun 17 03:07:35 why did apps start doing this in user folder Jun 17 03:07:39 this is so messy Jun 17 03:08:02 They always have Jun 17 03:08:13 nope, this is structure from linux Jun 17 03:08:25 windows uses program files and then appdata in user folder Jun 17 03:08:29 yes, but they always have Jun 17 03:08:30 not like this Jun 17 03:08:41 appdata is just a sub-directory.. set these to hidden then Jun 17 03:08:47 thats all they are Jun 17 03:08:48 yes and everything is inside Jun 17 03:08:55 not scattered like this in user folder Jun 17 03:09:27 It's probably because only the most recent versions of windows have made the users home dir directly accessible to the user Jun 17 03:09:50 but agreed that open-source apps should detect when they are on windows and use a sub-dir from app-data Jun 17 03:10:16 it's horrible habbit just leaving files whereever you wish Jun 17 03:10:38 put them neatly inside your folder where it was already supposed to go :) Jun 17 03:10:54 im guessing i should delete AndroidStudioProjects folder too Jun 17 03:11:19 i have some test i started, not needed anymore Jun 17 03:11:48 sure, sounds fine Jun 17 03:12:33 alright thanks for info Jun 17 03:14:46 np Jun 17 03:18:47 hmm i had 12gb free now i have 39gb free Jun 17 03:18:49 nice Jun 17 03:18:55 didnt know android took so much space Jun 17 03:20:16 *studio Jun 17 03:21:28 poua: dont think an AS install should take THAT much space. it was probably managing the sdk from within its' own folder structure Jun 17 03:22:00 wait a sec Jun 17 03:22:20 i just deleted .AndroidStudio1.5 and .AndroidStudio2.1 folders and they are back Jun 17 03:22:40 poua, those are automatically created settings folders Jun 17 03:22:49 created by what Jun 17 03:22:55 probably don't take up much space Jun 17 03:22:56 i dont have studio installed anymore Jun 17 03:23:06 oh well then you didn't actually delete them? Jun 17 03:23:15 or you deleted same named files in another folder? Jun 17 03:23:20 if i didnt that would be just bizarre Jun 17 03:23:34 Or if you used wildcards like *Android* for your delete command, it may have skipped the dot files Jun 17 03:23:42 maybe im getting senile -.- Jun 17 03:23:54 or maybe your filemanager doesn't let you delete files/folders that start with a dot :D Jun 17 03:24:19 well they are gone now, lets see if they return lol Jun 17 03:24:35 does your install of android studio on windows take 30gb? Jun 17 03:25:29 poua: you could get one of those disk analyzer tools to check where the bulk of the space is being used. Jun 17 03:25:45 poua, I'm in Linux, but android studio takes up like half a gig Jun 17 03:25:49 poua: i still think 30GB is super excessive unless the SDK stuff is there too Jun 17 03:26:11 yes SDK was there Jun 17 03:26:15 poua, and each android project takes about 45MB Jun 17 03:26:15 poua: like the emulator system images etc. Jun 17 03:26:16 do you not use SDK? Jun 17 03:26:21 poua: ok yeah that explains it Jun 17 03:26:41 poua: i do but it sits in its' own directory /opt/android-sdk Jun 17 03:26:44 poua, and the Android folder, which contains the SDK is 2.2G Jun 17 03:26:45 im on osx Jun 17 03:28:00 install bundle is only 1.2gb Jun 17 03:28:08 but when it unpacks it gets huge Jun 17 03:29:19 depending also on devices you set to emulate i think Jun 17 03:29:50 poua: and it will only get bigger as you dl more system images for emulators, sdks, documentation etc... Jun 17 03:30:06 that's why i wanted to remove all old files Jun 17 03:30:21 poua: you can use the sdk manager for that Jun 17 03:30:37 poua, oh yeah I do remember downloading system images till my disk was full, then I deleted everything and just downloaded one system image LOL Jun 17 03:30:38 im noob for this i dunno which Jun 17 03:30:50 so best is to remove everything then install latest with default settings Jun 17 03:30:58 poua: my AS install is 512MB and my seperate SDK dir is 8GB, but I have every android platform I think. Jun 17 03:31:17 poua, yes if easy to do. Are you running 64 bit OS? Jun 17 03:31:18 yeah, that's still far cry from 30gb i had it take Jun 17 03:31:19 poua: sounds to me like you had loads of VM Images Jun 17 03:31:25 poua: well everything in the sdk manager is organised by the version of android it correlates to (except the build-tools, tools etc) Jun 17 03:31:53 thanks for all the help guys Jun 17 03:40:29 Anyone happen to know the API to use for keylogging? Jun 17 03:43:10 wat Jun 17 03:43:58 Lewoco you want java.nsa.keylogger class :) Jun 17 03:46:18 anyone know the realm engineering blog url off the top of their head? Jun 17 03:57:20 I saw an article a couple weeks/months back about realm where they talked about their architecture. Anyone remember it or have a link saved? Jun 17 03:59:58 * g00s yawns Jun 17 04:01:24 * Ping_2_Ur_Pong googles Jun 17 04:03:53 I'm beginning to think it isn't possible to log keystrokes short of providing my own virtual keyboard. Jun 17 04:04:22 lol that sounds pretty shady Jun 17 04:04:23 Which the user wont appreciate if they already have some other virtual keyboard they would prefer to use. Jun 17 04:04:42 Also I assume it wont work for real physical keyboards/keystrokes. Jun 17 04:05:16 https://realm.io/news/jp-simard-realm-core-database-engine/ if anyone is interested Jun 17 04:05:42 Kind of weird that the accessibility API doesn't allow you to capture keystrokes. Jun 17 04:05:47 Lewoco: you want to log all key strokes on a device? Jun 17 04:05:55 Ping_2_Ur_Pong, Yeah. Jun 17 04:07:44 Actually I don't really even care what key they pressed, I'm more interested in when they pressed a key (any key) and how often. Jun 17 04:08:17 thats sounds like a huge security issue, of course not Jun 17 04:09:06 Lewoco: what exactly are you trying to do? Jun 17 04:09:36 perhaps there is another way, because without writting your own keyboard you're stretching into an area, that seems like it should not be doable. Jun 17 04:11:07 Ping_2_Ur_Pong, On Windows/Mac I have an application that monitors the foreground application and how many keystrokes the user types into it. Works great. Jun 17 04:11:22 Ping_2_Ur_Pong, I was hoping to do the same thing for Android. I think it may not be possible. Jun 17 04:12:06 you want to know how many key strokes the user types into your application or on the device in general? Jun 17 04:12:17 Ping_2_Ur_Pong, Device in general. Jun 17 04:23:33 new install is below 5gb Jun 17 04:25:04 anyone have an idea how to fix this error? ... http://pastebin.com/u49VYnLc Jun 17 04:59:06 poua don't forget, the gradle caches will get big too Jun 17 04:59:31 seems that default install doesnt install any image so im getting AVD error Jun 17 05:00:09 pepperoni did you include appcompat ? Jun 17 05:05:41 if I use a GridLayoutManager with a RecyclerView, can I independently scroll columns? Jun 17 05:06:42 really trying to avoid nested recyclerviews or a ViewPager of lists Jun 17 05:08:24 kotlin in action 50% off today Jun 17 05:08:48 RustyShackleford no Jun 17 05:09:15 its pissing me off how long I've spent on this lol Jun 17 05:09:24 paralyzed, not sure what to do Jun 17 05:09:33 both possibilities above are legit though Jun 17 05:09:53 google analytics uses viewpager in recyclerview Jun 17 05:10:06 iosched does something, forgot which Jun 17 05:11:28 haha this is so cool. Each thread I spawn gets a CPU. Since my tablet is a quad core, the first thread can use at most 25% of total CPU. If I spawn another thread, it can use another 25%. But they all run under the same JVM, so a System.exit(0) cleanly closes out all threads. This way I can run my render thread at full power without impacting other things. Jun 17 05:11:28 problem I have with those implementations: how the heck are you supposed to implement dragging between different lists? Jun 17 05:11:54 snapping the view out of its parent list/recyclerview Jun 17 05:11:56 And the UI is still perfectly responsive even with two worker threads pegging their respective CPUs Jun 17 05:12:31 jesseg wut Jun 17 05:12:39 System.exit() is not an option for android apps Jun 17 05:13:18 g00s, oh I finally got it working. System.exit(0) works though. and right nice too. Cleanly terminates the whole JVM for that app. Jun 17 05:13:41 RustyShackleford probably easier than writing your own GridLayoutManager which is more complicated than the existing GridLayoutManager :P Jun 17 05:13:59 jesseg again, its not something any android app should use - google it Jun 17 05:14:14 if you are using System.exit(), you are screwing up big time Jun 17 05:14:24 seconded Jun 17 05:14:33 g00s, oh yeah I know google's stance on allowing a user to terminate an app and I disagree. Jun 17 05:14:51 ok whataver Jun 17 05:14:53 g00s: not even sure what that is, i'll go look Jun 17 05:15:19 I keep asking about my fricken trello clone here Jun 17 05:15:20 If I know I'm done with an app, it serves no purpose taking up memory till the OS has to kill it when it needs its memory. That's why people's phones get so bogged down they have to reboot them Jun 17 05:15:27 can't find anybody who knows lol Jun 17 05:15:40 jesseg ok than Jun 17 05:15:41 guess I'll have to read the docs myself :( Jun 17 05:15:46 *then Jun 17 05:17:59 what am I supposed to do about the shadow$_monitor_ member added to android.util.Pair screwing up my .hashCode()/.equals()? can't use pairs as a key because they'll never equate Jun 17 05:18:31 map key* Jun 17 05:18:45 lol Jun 17 05:18:55 make your own Pair class in 5 lines of code Jun 17 05:19:13 g00s: i blew my res folder away to get past it, i'm doing a native app Jun 17 05:19:13 use AutoValue , i haven't but afaik it makes hashcode for you Jun 17 05:19:31 jesseg: it would require some pretty in depth knowledge of your app/ android internals to do that safely. youre liekly preventing a shitload of lifecycle from taking place Jun 17 05:19:36 sure, but adding a hidden member to Object that universally screws up this functionality sounds like an awful idea Jun 17 05:20:16 tuples in java suck anyhow Jun 17 05:20:27 fuck that thing Jun 17 05:20:47 okay, tuples suck, but i'm sure this bites in plenty of other areas Jun 17 05:21:02 i don't see many people complaining on google about it though so whatever? i really don't know what to think of this haha Jun 17 05:22:10 plus it's more than five lines of code to reimplement pair, because the very reason to reimplement is to reimplement .hashCode() which sort of makes me reimplement .equals() Jun 17 05:22:27 teasp00n, I would be interested in hearing any specific examples. What I do know of android internals is that each app runs in its own Java Virtual Machine (JVM) which runs as a linux process under a user ID unique to that app. Most apps run in a single JVM, and for those, closing the JVM completely closes the app and frees all dynamic resources. But yeah, close files, tcp connections, and databases first. Maybe ask user to confirm. But there's good c Jun 17 05:22:27 oding and bad coding. Jun 17 05:22:38 and having a declaration, and two regular members... i don't want to push the definition of a line of code haha Jun 17 05:32:25 it's not a jvm. Jun 17 05:32:27 which sort of makes me reimplement .equals() Jun 17 05:32:34 pfn, what is it then? Jun 17 05:32:56 err ... error on that last Jun 17 05:32:58 a dalvik vm Jun 17 05:33:24 anyone have thoughts on this error ... http://pastebin.com/w5QQJFtE Jun 17 05:33:41 pfn, LOL OK I stand corrected. But for the purpose of my point, that fact is irrelevant. Jun 17 05:34:28 pfn, are you sure dalvik is not a java virtual machine? Jun 17 05:34:55 It is a virtual machine, and it interprets java... Jun 17 05:35:09 it doesn't interpret java Jun 17 05:35:47 translate then? lol Jun 17 05:35:52 we're splitting bits here. Jun 17 05:36:49 also ART really isn't a virtual machine either Jun 17 05:38:29 well call it execution, translation, interpretation or whatever you want. The fact is, it is a virtual machine which slurps in java bytecodes. :D Jun 17 05:39:20 What is the default keymap on Windows? Is it Default or Default for XWin? I suppose XWin is for Linux. Jun 17 05:40:26 jesseg its .. not a virtual machine. ART is ahead of time compiled Jun 17 05:40:49 although i guess maybe android 6 things get interesting, isn't there JIT again lol Jun 17 05:42:28 jesseg: not saying you're wrong or what you're suggesting wouldn't work. just cautioning you against it as I would consider that to be a pretty hairy thing to be doing programmatically :p Jun 17 05:42:51 g00s, well pfn just says it was a vm, I don't care what we call it :) the point is it takes java bytecode and, one way or another, executes it either with JITC or interpretation or who knows what. But, unless otherwise configured from XML files specifically, all the parts of the app run inside the one linux process. Jun 17 05:42:59 teasp00n, ahh ok. Thanks :) Jun 17 05:43:51 jesseg: it doesnt take java bytecode btw, dalvik vm runs dalvik bytecode which is generated by some part of the build process taking the java bytecode as an input Jun 17 05:44:33 jesseg: but again that part of the android platform has changed quite a bit in recent times so im not sure how it all fits together not (ART, jack, jill...) Jun 17 05:44:39 now* Jun 17 05:44:41 it doesn't take java bytecode Jun 17 05:44:57 doesn't run rather Jun 17 05:45:06 as teasp00n describes Jun 17 05:46:06 okay, good, i was wrong, android.util.Pair doesn't use the shadow$_monitor_ GC member for .hashCode(), my issue was Long and Integer not being equal through .equals() i think Jun 17 05:47:37 teasp00n, pfn well I don't know. This article here says Dalvik is a virtual machine that runs java bytecode that's been compiled into the Dalvik Executable format, which I think is kind of like tar. Jun 17 05:48:01 article is wrong, obviously Jun 17 05:48:44 jesseg: even if it was correct at time of writing it wouldnt reflect that state of things 6+ Jun 17 05:48:55 ahh Jun 17 05:48:59 i think thats when ART became default.. Jun 17 05:59:50 Is there a keystroke to indent or unindent a selected block of code? Jun 17 05:59:54 in AS Jun 17 06:18:09 Is there any way to bypass the usb computer connection exclusion set of MTP versus PTP so it can mounted as a file system? Jun 17 07:02:26 lasserix: you can change it by selecting in your notification where it says connected to USB Jun 17 07:08:55 Hi all. I'm looking for the difference between Parcelable and Serializable. I'm going to use Parcelable for the performance. But now the question. Does somebody know a solution to make something which works for all classes? Like I don't want do create that code in all my classes if it's possible Jun 17 07:09:11 like a general solution to make classX be Parcelable Jun 17 07:15:55 some Parcelel libraries Jun 17 07:16:25 then mostly you put annotation @Parcel to class to make it parcelable Jun 17 07:16:39 i.e. https://github.com/johncarl81/parceler Jun 17 07:18:45 Ashiren, wow! Thanks Jun 17 07:24:54 firebase api is worse than Parse api Jun 17 07:25:52 how do you get .apk files from google play so that you can use them on android emulator? Jun 17 07:28:36 JyZyXEL: There are a few websites which offer APK downloads directly from the Play Store Jun 17 07:28:59 apkpure.com seems to offer play store as an .apk download Jun 17 07:28:59 You can find them by Googling for 'apk downloader' Jun 17 07:29:20 Not sure about the security of those apks though Jun 17 07:29:34 if you try to use the emulator itself to download .apk files, it immediately crashes :p Jun 17 07:29:36 best practice to refer to the application class: onCreate or onResume? Jun 17 07:29:38 They are not from the original source, they could be tampered with Jun 17 07:30:30 also, should it be refered with: getApplicationContext() or getApplication() ? reading mixed views bout it Jun 17 07:35:00 pduin: looks like apkpure has their own app manager apk that can be used to install and upgrade other apks Jun 17 07:35:29 Worth a try, I think. Strange that the emulator crashes on an APK download though. Jun 17 07:35:50 no, the Browser crashes Jun 17 07:37:29 raoul11: if you need Application use getApplication() Jun 17 07:37:41 you can use it in onCreate as well Jun 17 07:37:47 k Jun 17 07:45:51 any espresso experts about? :) I have a viewpager with a recycler view in each (they all have the same resource ID), and I can't seem to come up with a matcher that wont result in AmbiguousViewMatcherException Jun 17 07:46:07 so, trying to understand analytics better: lets say i wanna record a "wrong answer" (category), inside "level name" (label) and also include "the question" (label) Jun 17 07:46:26 is it possible with analytics sdk to include all 3? Jun 17 07:54:49 Hi all, sorry X-post from #android but : on Mac OSX I used the Android SDK manager to download the google-play-service package but I can't find the .jar in ~/Library/android-sdk-macosx/extras/google/google_play_services Jun 17 08:31:09 ncls: why do you need the jar? Jun 17 08:31:42 FrancescoV: I'm working with Titanium and some modules, including one for Google Analytics Jun 17 08:32:17 ncls: can't you use a gradle dependency? Jun 17 08:32:20 it seems to be in conflict with another one (for push notifications), and I want to try to replace the google-play-services.jar in Google Analytics module lib folder to see if it solves the problem Jun 17 08:33:30 I don't think so, I've never used gradle Jun 17 08:33:48 the modules are already pre-made with their libs and all Jun 17 08:34:52 I see, sorry but I have no experience with Titanium Jun 17 08:35:04 FrancescoV: it's ok, thanks for your help Jun 17 08:35:16 can I use gradle to just download a jar and see if it works ? Jun 17 08:39:00 ncls: did you check this path? http://stackoverflow.com/a/21097859/1723525 Jun 17 08:39:41 here are the docs for setup: https://developers.google.com/android/guides/setup#add_google_play_services_to_your_project Jun 17 08:40:28 FrancescoV: yes but I don't see any "libproject" directory Jun 17 08:41:07 ncls: are you sure you haven't the android sdk on 2 places on your pc? Jun 17 08:41:48 see the SDK Path, on top of Android SDK Manager Jun 17 08:44:25 that's the one Jun 17 08:44:50 amazing, updated yday emulator system image, now its painfully slow Jun 17 09:43:44 Why I can't find mobile uncle in the google play? Jun 17 09:49:42 anyone knows how to install unsigned apks? i keep getting error while parsing Jun 17 09:50:20 You can't Jun 17 09:59:05 Does anyone has a n MTK device ? Jun 17 10:16:59 can anyone offer advice on how to keep my app idea from being stolen? Jun 17 10:18:29 frib: do it well, stay ahead of the clones Jun 17 10:19:38 Leeds, by "stay ahead" you mean attract more users before others do? Jun 17 10:20:26 I should wait until I have a fully polished product before publishing right Jun 17 10:20:28 attract more users, add more features, whatever Jun 17 10:25:30 meh Jun 17 10:25:42 if he waits for polishing his product hell wait forever Jun 17 10:26:09 sometimes (often) its better to publish unfinished product with bugs than not publish at all Jun 17 10:26:09 if it's such an easy idea to copy... come up with a better idea, if you don't think you can implement it better Jun 17 10:31:15 Hey guys Jun 17 10:32:38 oh, he quit, I didn't notice :) Jun 17 10:35:08 I have completed the course Object Oriented programming, which used Java. Now I want to look into android-dev, and I am trying to set-up my environment properly. I have installed JDK 1.8.0_92 (64bit) and the Android SDK's using SDK Manager. I opened a new module in IntelliJ IDEA (IDE), which should be a proper skeleton android application (that's w Jun 17 10:35:08 hat I think). But now when I try to compile it, Gradle cannot find my Java Home? This is where I am at now: http://prntscr.com/bhh630 Jun 17 10:35:34 Does this look OK or am I switching things up here? Jun 17 10:35:36 aukeroorda: why not Android Studio? Jun 17 10:35:49 Because I also use intelliJ for Java development Jun 17 10:35:57 non-android* Jun 17 10:36:51 Or is that not really important? Is Android Studio a lot better for beginners? Jun 17 10:37:34 you're making things harder for yourself than they need to be if you don't use it Jun 17 10:38:25 Hmm, how does that compare to that I am used to IntelliJ, and not at all (yet) to android studio? Easy switch or? Jun 17 10:38:41 It might indeed be easier to switch to Android Studio, but I don't know that Jun 17 10:39:05 well, it's more that AS comes all setup and integrated, and all the docs pretty much assume you're using it Jun 17 10:39:23 also, windows... Jun 17 10:39:48 use Intellij, it is better than switching and using Android Studio :) Jun 17 10:40:07 use vim, it's just better Jun 17 10:40:20 but keep studio there for rare occasions, like to add SVG file from stock library Jun 17 10:40:31 mates Jun 17 10:40:41 I mean New -> Vector assets Jun 17 10:41:06 for beginner stuff use android studio so far Jun 17 10:41:09 Leeds, harder? how? -.- Jun 17 10:41:12 best you can do is to use android shit software as less as possible Jun 17 10:41:17 Oke, but is my error something that takes a lot to fix or? I found http://stackoverflow.com/questions/29356796/intellij-gradle-plugin-the-supplied-javahome-seems-to-be-invalid but I already use the 64bit version Jun 17 10:41:18 maybe youll see whats also nedded for idea to work Jun 17 10:41:46 aukeroorda: welcome to android Jun 17 10:42:03 Ai ai ai Jun 17 10:42:04 soon you'll discover that I'm not kidding calling it shit Jun 17 10:44:36 aukeroorda, windows I assume? Jun 17 10:44:44 aukeroorda, are you running idea.exe or idea64.exe? Jun 17 10:45:18 64 bit Jun 17 10:45:30 so the second yeah, I checked my tskmngr Jun 17 10:45:39 Sup Dudes, Dudettes and players to be named later Jun 17 10:45:51 aukeroorda, ok, have you set up SDKs in IDEA? Jun 17 10:46:52 Zharf: Yeah, like this: http://prntscr.com/bhhc1f Jun 17 10:47:12 ok, hmm Jun 17 10:47:38 I'm building an SDK to support V1 and V2 of a peripheral. I want to return a single list of our peripherals and have the most painless way for the developer to determine which version they have. Jun 17 10:47:52 I guess you've made sure that your JAVA_HOME is set up properly too Jun 17 10:47:53 Anyone suggest a good way to do this? Jun 17 10:48:49 Zharf I am pretty sure I have not. I used the Android SDK Manager to download the android SDK, but I think I have never typed a JAVA_HOME variable Jun 17 10:49:28 but I have been using those JDK's, and those require the JAVA_HOME to be set as well? Jun 17 10:50:10 nooot so sure about that Jun 17 10:50:44 Oke, hmm Jun 17 10:50:53 I will look into that first, then. Jun 17 10:51:25 open a console and type in 'set JAVA_HOME', what does that tell you Jun 17 10:51:58 Environment Variable JAVA_HOME not defined, oi oi oi Jun 17 10:55:18 Oke, now when I write 'set JAVA_HOME' I get: JAVA_HOME=C:\Program Files\Java\jdk1.8.0_92 Jun 17 10:55:21 Seems, ok to me Jun 17 11:01:10 Zharf, o wow. I never saw that there was a difference between Project SDK and Module SDK. : / Jun 17 11:01:51 hi guys, would an app be able to create a keylayout file in /data/system/devices/keylayout if those directories don't exist yet? External Keyboard Helper Pro doesn't seem to work 100% for me Jun 17 11:02:49 adb shell doesn't have the permissions without root Jun 17 11:15:52 Zharf: Thanks man, got it all working it seems Jun 17 11:16:07 \o/ Jun 17 11:19:40 Hmm, I now see that you can also create a new project without Gradle. For starters, go with Gradle or not? I have no clue whatsoever what gradle does at the moment. Jun 17 11:33:51 Do I use Android Modules like Java classes? Or do people in general just use a single or a few modules for their application? Jun 17 11:35:19 i mostly use 1 module Jun 17 11:35:31 module is like your own library Jun 17 11:49:20 I have 4 modules Jun 17 11:49:42 dont use them if you dont have too ;) Jun 17 11:50:38 gordon_: Oke, so for me (first time trying my hand at this), just keep it at a single module Jun 17 11:50:46 ye Jun 17 11:50:47 s Jun 17 12:14:39 Hi i have some architecture questions that i would love to get some input on. I am trying out the new data bindings library and trying to follow the MVVM. Where do you usually put stuff like starting a new activity or showing a dialog. Should that be located in the Activity/Fragment pass that in as a listener interface to the ViewModel and where would you suggest putting stuff like making network calls etc? Jun 17 12:20:05 Does someone knows how to remove the circle from a radiobutton in android 4.4.4 ? I'm setting background to null, it's working fine in 5.0 or upper. But not in 4.4.4 Jun 17 12:28:39 hi ppl. it seems that i cant find the url to download adt for linux Jun 17 12:29:00 i accept the agreement and then it throws me to the frontpage Jun 17 12:30:22 gordon_: Do you know which packages I have to install to get an older renderer? I only have 24 in my dropdown, and that is too new, so I would like to install the previous renderer. Do I need all 14 packages for that? Screenshot to show my situation: http://prntscr.com/bhihcu Jun 17 12:33:29 no Jun 17 12:33:36 you can only get newest one Jun 17 12:33:52 and use appcompat to have same look everywhere Jun 17 12:34:54 Hmm, oke Jun 17 12:52:49 Ha, this is really cool already! Jun 17 12:54:35 hmm, chome OS has play store now? Jun 17 13:01:33 fellas, how to auto genrate the app indexing api ? Jun 17 13:01:42 using Mac, and latest android studio Jun 17 13:02:10 when i highlight the class name and right click then choose Generate i do not see app indexing api ? Jun 17 13:03:13 SparseBooleanArray, y u no have .toggle(int index) ? Jun 17 13:04:02 Do you people normally run/debug on your physical phone or is that just a gimmicky feature that I shouldnt bother with? Jun 17 13:04:50 You can cover a lot of testing using just an emulator Jun 17 13:04:51 almost always Jun 17 13:05:02 I prefer it. Jun 17 13:05:15 For something like a camera barcode scanner app it's nice to have an actual device Jun 17 13:05:16 I use emulation for other API versions. Jun 17 13:05:29 Ah, I see Jun 17 13:05:58 Not sure if you can set a certain performance level on an emulator, but an actual device will help you find performance bottlenecks a bit faster I guess Jun 17 13:06:02 Yeah I really like toggling those checkboxes even haha Jun 17 13:06:12 Hmm yeah Jun 17 13:06:32 Well, making a lightweight info app, so I think that will almost always be ok Jun 17 13:44:12 Could you give me some help on this ? I'm trying to remove the RadioButton circle on android 4.4.4 http://stackoverflow.com/questions/37882492/how-to-remove-radiobutton-circle-in-android-4-4-4 Jun 17 14:18:34 hithere Jun 17 14:19:54 I have an class which act upon globally set condition Jun 17 14:21:12 this class has method method(String someString); where someString is always created and only if condition is not fulfilled method will not use this string Jun 17 14:21:41 I would like to this string creation / execution be done only if condition is true Jun 17 14:22:33 fe in pythone there were exec("some command"), is there something in "android JAVA"? Jun 17 14:38:47 I am trying to import a project into a new project. When i use the file>new>import project command it opens another instance of android studio instead of importing the older project. Any ideas what i need to change? this just started happening yesterday. Jun 17 14:58:45 hi, im trying to use grennis' Expandable Recycler View ( https://github.com/grennis/ExpandableRecyclerView ) but it keeps saying cant resolve ExpandableRecyclerView when i to use it and i cant see any import options for that component and ive synced the project. anyone know if im doing something wrong? Jun 17 15:02:24 hi Jun 17 15:03:06 i do "ObjectAnimator.ofFloat(cardViewHolder.card, "translationX", cardViewHolder.card.getMeasuredHeight(), 0).setDuration(1000).start();" inside onBindViewHolder. why card animate onscroll but not on start? Jun 17 15:03:18 i need animation on start Jun 17 15:03:34 I am trying to import a project into a new project. When i use the file>new>import project command it opens another instance of android studio instead of importing the older project. Any ideas what i need to change? this just started happening yesterday. Jun 17 15:04:36 xan_IT: its not that simple.. onBindViewHolder can be called multiple times and at anytime. Jun 17 15:05:06 xan_IT: post your adapter code and perhaps I can advise Jun 17 15:08:21 http://pastebin.com/HbdvBFg5 Jun 17 15:08:46 Napalm on create must be called to bind data. but animation doesent start Jun 17 15:11:04 I have a user that got this dialog: http://imgur.com/T2mrG5J (missing the set button), from this code: http://pastebin.com/LEeSgMTG but I don't understand why? Can somemone help me out? Jun 17 15:11:34 By the way, I know the XML is messy with extraneous below and besides entries. I'm working on removing them now. Jun 17 15:13:39 difference between a expandable list view and expandable recycler view? Jun 17 15:13:41 Napalm ? Jun 17 15:20:08 xan_IT: sorry, had to reboot Jun 17 15:20:34 xan_IT: So your trying to make the cards animate up and into the screen as they appear? Jun 17 15:21:52 Napalm yes Jun 17 15:22:21 yea, thats not the way to do that Jun 17 15:22:27 i want to animate in "oncreate" recycle Jun 17 15:22:28 gimme a moment Jun 17 15:22:37 thz Jun 17 15:22:44 xan_IT: do you want the other animations? like delete? Jun 17 15:22:50 no Jun 17 15:23:15 i also tryed to put animate in onCreateViewHolder Jun 17 15:23:20 but not works Jun 17 15:23:54 then override the DefaultItemAnimator on the RecyclerView Jun 17 15:24:06 you can do that either when you set your Adapter or from your adapters Jun 17 15:24:12 https://developer.android.com/reference/android/support/v7/widget/DefaultItemAnimator.html Jun 17 15:24:21 just override animateAdd Jun 17 15:24:44 you need to add a listener to your animation and call the dispatchFinished method in onAnimationEnd() Jun 17 15:24:51 where i add animator to recycle? Jun 17 15:25:07 there is a example? Jun 17 15:25:16 onAttachedToRecyclerView Jun 17 15:25:18 in your adapter Jun 17 15:25:33 recyclerView.setItemAnimator() Jun 17 15:26:17 this is so confusing Jun 17 15:28:55 recyclerView.setItemAnimator(new DefaultItemAnimator()); Jun 17 15:29:29 anyone know why ExpandableRecyclerAdapter cant be resolved using this-> https://github.com/grennis/ExpandableRecyclerView Jun 17 15:34:11 Napalm not works Jun 17 15:34:24 xan_IT: your doing it wrong then Jun 17 15:34:29 because I know it works Jun 17 15:34:33 pastebin Jun 17 15:34:36 yes :D Jun 17 15:34:48 wich animation has defaultitemanimator? Jun 17 15:35:00 for on enter Jun 17 15:35:20 what? Jun 17 15:37:11 when i set adapter with list, starts add animation? Jun 17 15:37:25 yes Jun 17 15:37:41 seams not :( Jun 17 15:37:51 i just do recyclerView.setItemAnimator(new DefaultItemAnimator()); Jun 17 15:38:03 but i see that DefaultItemAnimator is used as default Jun 17 15:38:14 i need to enable animation? Jun 17 15:42:34 Napalm ? Jun 17 15:43:17 why are you setting the default item animator? Jun 17 15:43:19 its already set to that Jun 17 15:43:36 yes, so? Jun 17 15:43:39 i said create your own and override animateAdd Jun 17 15:43:47 a sorry Jun 17 15:43:48 [16:24] just override animateAdd Jun 17 15:43:48 [16:24] you need to add a listener to your animation and call the dispatchFinished method in onAnimationEnd() Jun 17 15:44:27 but default animator has animation in animateAdd Jun 17 15:44:30 not? Jun 17 15:45:05 thats why your override it and do your own Jun 17 15:45:50 Napalm ok but if i want to use default animation? Jun 17 15:46:01 xan_IT: then you dont have to do anthing Jun 17 15:46:07 its the "default" Jun 17 15:46:14 but i dont see any animation Jun 17 15:47:03 when default animation works just override add. ok understand Jun 17 15:47:14 but now default animation doesent works Jun 17 15:47:16 why? Jun 17 15:47:20 Napalm ? Jun 17 15:47:56 Napalm http://pastebin.com/kLkZuzmq Jun 17 15:49:00 o7 Jun 17 15:53:08 xan_IT: and? Jun 17 15:53:19 no animation at all Jun 17 15:54:04 yes it has animations Jun 17 15:56:09 Ctrl+Click on your DefaultItemAnimator and look at its animateAdd function Jun 17 15:56:58 I’m listening for `Intent.ACTION_MEDIA_BAD_REMOVAL`, which works, but it seems to take a moment for Android to realize that it’s unavailable. If I call `Environment.getExternalFilesDirs` afterward, the SD path shows up in the results, unless I wait a bit like with the debugger Jun 17 15:57:15 why the heck am I not seeing the drawable folder used to store images for android apps, in AndroidStudio, though i can see it in the file manager Jun 17 15:58:22 xan_IT: the default fades the view in over 120ms (12th of a second) Jun 17 15:58:28 so very quick Jun 17 15:59:01 Does anybody know what kind of alternatives I have to make sure my app knows the media has been removed? Jun 17 16:00:07 hassoon: wrong location? bad variant selection? weird build script? lots of reasons Jun 17 16:00:08 what device makes sd card easily removable? Jun 17 16:00:17 they all seem to be located near the sim which is a pita to take out... Jun 17 16:01:04 Napalm: ah after copying an image file into the drawable folder, the latter appeared in the left section of the project's folders, seems like empty folders aren't shown or something Jun 17 16:02:43 hassoon: correct, the Android view does not show them. go into Project or Project Files view. Jun 17 16:03:19 Napalm: yeah i've been in the Project Files view already Jun 17 16:04:24 hello, im using firebase auth, and trying to get error code but, i can see error code on runtime, but can't see on compile time Jun 17 16:04:31 any way to run this method ? Jun 17 16:05:03 pfn: I’m testing on a Samsung Jun 17 16:05:06 You cna just pop it out Jun 17 16:05:18 Samsung tablet Jun 17 16:06:09 sci-fic: erm.. pastebin your runtime stack-trace Jun 17 16:06:38 why does DownloadManager.Request append file extensions on some devices but omits it on others? Jun 17 16:08:19 http://paste.ubuntu.com/17436583/ Jun 17 16:08:33 Napalm: i need zzbFj variable :D Jun 17 16:08:59 do you? Jun 17 16:09:03 to me the exception says it all Jun 17 16:09:08 FirebaseAuthInvalidUserException Jun 17 16:09:33 "FirebaseAuthInvalidUserException thrown if the user account corresponding to email does not exist or has been disabled" Jun 17 16:09:34 from the docs Jun 17 16:09:54 "FirebaseAuthInvalidCredentialsException thrown if the password is wrong" Jun 17 16:10:43 yep , i just wonder how i can get this runtime result or i can ? Jun 17 16:11:08 you need to run the program to get the result yes Jun 17 16:11:14 the ide wont tell you Jun 17 16:11:15 because in compile time , there is no such method like exception.getErrorCode(); Jun 17 16:11:55 can i do that with reflections or something ? seems possible ? Jun 17 16:12:50 anyway, i'm going to compare exceptions then :D Jun 17 16:17:27 Happy Friday! Jun 17 16:17:52 scorche: its called a try/catch Jun 17 16:17:58 sci-fic: Jun 17 16:18:00 ^ Jun 17 16:26:41 So question: What would be the best way to refresh an item in a list view on a regular basis? I could have the ViewHolder manage it by repeating a postDelayed runnable, but that seems like it would be annoying to disconnect on lifecycle changes. Jun 17 16:27:00 Now that I think about it it seems like it would make the most sense to have the activity/fragment maintain the data and replace the item Jun 17 16:31:25 lol http://i.imgur.com/sKILs5Z.gif Jun 17 16:34:10 lel Jun 17 16:34:14 in a meeting rn Jun 17 16:34:19 sent cto this: https://dl.dropboxusercontent.com/u/25009451/ProgrammerInterrupted.png Jun 17 16:34:23 fuck meetings Jun 17 16:43:51 any idea on how to get rid of those pseudo-errors in generated directory when using annotations? Jun 17 16:44:39 ^ android studio marks as errors, but it runs ok Jun 17 16:50:31 orbyt_: reminds me of something i did a long time ago https://gist.github.com/slightfoot/6312466 Jun 17 16:53:22 Napalm: what is that supposed to be lol Jun 17 16:53:39 its what it says it is, a comment stripper Jun 17 16:53:51 good mornin Napalm Jun 17 16:53:52 orbyt_, that is the same when working from home and the kids didn't go to school Jun 17 16:53:54 thats called a state machine based from a state table Jun 17 16:54:20 good afternoon g00s Jun 17 16:54:29 bitkiller_: well no kids here so (▀̿Ĺ̯▀̿ ̿) Jun 17 16:54:45 but i'd rather be with the kids than company meeting Jun 17 16:55:06 bitkiller_ work for SF company, problem solved Jun 17 16:55:23 g00s: ? Jun 17 16:55:32 do sf companies have less meetings or somethin... Jun 17 16:55:43 they say they do Jun 17 16:55:48 seems like average googler is in their 20s Jun 17 16:56:01 and it’s probably a rip on SF tech workers being kids Jun 17 16:56:06 g00s, and then have no meetings and no time with the kids Jun 17 16:56:23 average google employee is 29 Jun 17 16:57:46 hi Jun 17 16:58:02 why my EditText have this border? https://postimg.org/image/yr05bdhrr/ Jun 17 16:59:11 t0th_-_: update your Android Studio and then do a clean build of your project. Also make sure your using the latest version of the Android Gradle Plugin Jun 17 16:59:26 and don’t use that site. it was nothing but ads Jun 17 16:59:28 t0th_-_: its a bug in InstantRun/AAPT compiling resources Jun 17 16:59:29 use imgur Jun 17 16:59:33 Napalm, just typing. have they solved that bug? Jun 17 16:59:41 i remove the instantrun Jun 17 16:59:46 they solved it ages ago Jun 17 17:00:03 t0th_-_: you mean you've turned it off. plus i said AAPT Jun 17 17:00:08 well, i have recompiling a project with some latest alpha gradle plugin Jun 17 17:00:16 ^ i have it Jun 17 17:00:29 2.2alpha something Jun 17 17:00:50 ah platform-tools 24 final is out Jun 17 17:01:01 turned back to 2.1 Jun 17 17:01:51 use is 2.1 Jun 17 17:01:54 *I use Jun 17 17:01:56 i back to 2.1.0 Jun 17 17:01:58 testingo... Jun 17 17:02:25 https://code.google.com/p/android/issues/detail?id=210312 Jun 17 17:03:11 ^ someone said it's fixed in 2.2alpha4 Jun 17 17:03:33 lol sdk manager fucked up installin platform tools Jun 17 17:03:45 * g00s nukes from orbit Jun 17 17:05:17 g00s got a github account? Jun 17 17:05:29 Napalm no Jun 17 17:05:58 * g00s embarrassed Jun 17 17:06:03 working here with 2.1.0 Jun 17 17:06:04 http://github-awards.com/users/slightfoot Jun 17 17:06:15 looks like a got a high ranking Jun 17 17:07:39 so david karnok is lead dev now for RxJava (officially). and seems he is replacing some of the internals with Spring Reactor, interesting ... Jun 17 17:09:41 congrats Napalm :) Jun 17 17:13:22 you dont have a github? Jun 17 17:13:24 ....why Jun 17 17:13:52 i thought it would be going the way of sourceforge already ... Jun 17 17:14:09 well they are pivoting to enterprise, will be interesting Jun 17 17:14:17 can't make money from all you freeloaders :D Jun 17 17:15:24 went see bitbucket yesterday. they are fully in enterprise mode Jun 17 17:15:38 Napalm so , i see API 24 SDK here, but no API 24 sources. only 23 sources, hmm Jun 17 17:17:32 g00s: yea, thats because the API is finialized.. in other words no more changes. but the source behind can change for bug fixes during this final preview build. Jun 17 17:18:29 yeah makes total sense, but i guess now AS 'Go to Implementation' won't work right ? Jun 17 17:19:07 when it decompiles, its really seeing if there are sources first and uses them otherwise uses fernflower (which is obvious, results are totally different) Jun 17 17:20:59 g00s: it should work. if your device is < APIv24 Jun 17 17:21:02 since they fixed that bug Jun 17 17:21:17 so now when debugging it finds the right API version of the sources Jun 17 17:21:24 g00s: oh what.. you mean during editing Jun 17 17:21:29 yea. possibly that wont work. Jun 17 17:21:49 :( Jun 17 17:21:58 i'll try Jun 17 17:22:31 man, i really really hope google finds a way to put GMS + support libs into some real on line repository, downloading these repos fucking sucks Jun 17 17:22:56 i couldn't even get that done on the spotty shitty library wifi Jun 17 17:24:06 jump, failed Jun 17 17:24:10 yup, failed Jun 17 17:24:12 I'm having trouble with AS telling me that it can't find the Sdk Jun 17 17:24:28 I have the sdk, and local.properties has the correct location Jun 17 17:24:38 yet.. it still says it can't find the Sdk Jun 17 17:24:49 snapfractalpop: edit the setting not local.propertiues Jun 17 17:25:06 Napalm: which setting? Jun 17 17:25:22 search you settings for SDK Jun 17 17:25:28 you'll find "android sdk location" box Jun 17 17:25:29 :P Jun 17 17:26:54 Napalm: but that box is correct in the main settings Jun 17 17:27:07 /home/myusername/Android/Sdk Jun 17 17:27:40 whats the error your seeing? pastebin.. or screenshot Jun 17 17:27:54 Error:SDK location not found. Define location with sdk.dir in the local.properties file or with an ANDROID_HOME environment variable. Jun 17 17:28:01 sorry Jun 17 17:28:04 holy shit this is confusing https://medium.com/@Sserra90/android-themes-an-in-depth-guide-f71f9db6e5bf#.x1w43jca7 Jun 17 17:28:05 I should have pastbined Jun 17 17:32:00 g00s: erm, watch this https://www.youtube.com/watch?v=TIHXGwRTMWI Jun 17 17:32:23 snapfractalpop: this is on Linux right? Jun 17 17:32:29 Napalm saw that video, was pretty basic Jun 17 17:32:30 snapfractalpop: check the permissions of the files Jun 17 17:32:56 snapfractalpop: it says "SDK location not found" which is essentially the same as "cannot access it" Jun 17 17:32:58 yeah, linux Jun 17 17:33:05 ok.. Jun 17 17:33:07 alright, so maybe i need to ditch my fragments and look at something like Conductor Jun 17 17:33:08 I'll check permissions Jun 17 17:33:12 snapfractalpop: I suggest you drop it in /opt/android-sdk or somethnig Jun 17 17:33:15 idk how they would have changed Jun 17 17:35:39 Napalm have you tried any of those alternatives to fragments yet ? Jun 17 17:35:57 yea, a few.. not Conductor.. but then again.. i just made my own Jun 17 17:36:11 its not exactly complicated Jun 17 17:36:19 permissions seem ok.. owner/group = me, d = 775, f = 664 Jun 17 17:36:49 I'm thinking of just nuking AS and redownloading it Jun 17 17:37:46 snapfractalpop: did you try doing a recursive update? Jun 17 17:38:08 on permissions? Jun 17 17:38:11 I'll try that now.. Jun 17 17:39:43 https://developer.android.com/reference/android/view/ViewPropertyAnimator.html#translationX(float) where is starting point? Jun 17 17:40:11 xan_IT don't the docs say :P Jun 17 17:40:26 say nothing Jun 17 17:40:35 lol of course Jun 17 17:40:53 using that animation is from left to final position Jun 17 17:40:59 i want to came from right Jun 17 17:41:02 need help Jun 17 17:41:15 Hi there, just dealt with saving state with squareup/flow, if someon's interested in this library usage - you're welcome to ask any questions :) Jun 17 17:41:49 Napalm: still no luck Jun 17 17:41:55 macbook just looking at Conductor :D Jun 17 17:42:16 >g00s what is "Conductor" ? Jun 17 17:42:29 i think its a newer kind of flow / mortar Jun 17 17:42:45 made by squareup ? Jun 17 17:42:47 solved Jun 17 17:42:49 thz to all Jun 17 17:42:52 macbook nope Jun 17 17:43:19 snapfractalpop, i had some problem in linux. think it was related with the jdk used Jun 17 17:44:21 oh, i prefer using only their stuff, for me it's quite enough to add rx, retrofit and flow to make ordinary client-server apps, and optionally ButterKnife Jun 17 17:44:44 forgot - of coarse retrolambda ^_^ Jun 17 17:45:21 bitkiller_: were you ever able to sort it out? Jun 17 17:45:51 snapfractalpop, well, looking at my shell history, heven't found anything relevant Jun 17 17:46:03 only export ANDROID_HOME ... Jun 17 17:46:18 hm.. Jun 17 17:46:21 snapfractalpop, everything if fine here Jun 17 17:46:26 maybe I'll try that Jun 17 17:47:05 /opt/android-sdks owned by root:root Jun 17 17:47:54 the same for /opt/android-studio Jun 17 17:47:56 >>bitkiller_ not actually enogh, in AS you sometimes also have to put system variables Jun 17 17:48:18 ssry for offtopic, but how to answer to someone ? Jun 17 17:49:30 bitkiller_: seems to have fixed that error! Jun 17 17:49:32 thanks Jun 17 17:49:36 now on to all the others.. Jun 17 17:49:38 hha Jun 17 17:52:01 any ideas on how to "fix gradle wrapper and re-import project"? Jun 17 17:56:42 i think it's related to gradle version Jun 17 17:57:02 but, i use default wrapper Jun 17 17:57:41 Could you give me some help on this ? I'm trying to remove the RadioButton circle on android 4.4.4 http://stackoverflow.com/questions/37882492/how-to-remove-radiobutton-circle-in-android-4-4-4 Jun 17 17:58:49 snapfractalpop, check some setting releated in settings->build, etc Jun 17 17:59:42 bitkiller_: ok Jun 17 18:00:20 I'm also using default Jun 17 18:00:40 I don't know if the project I'm importing is using something else? Jun 17 18:02:18 hi Jun 17 18:02:46 i have a fragment, can i put a viewpager and tab inside ? Jun 17 18:03:10 snapfractalpop, i would also check the gradle plugin version defined in the build.gradle Jun 17 18:05:04 wviana, have you tried setButtonDrawable(null)? Jun 17 18:05:05 bitkiller_: I don't see anything there.. Jun 17 18:05:19 but I do see something called gradle-wrapper.properties Jun 17 18:05:20 are you in the app/build.gradle? Jun 17 18:05:50 it's the one in the project root dir Jun 17 18:05:57 hm.. ok Jun 17 18:06:03 I see classpath Jun 17 18:06:09 in dependencies Jun 17 18:06:55 ...com.android.tools.build:gradle: Jun 17 18:07:22 that one says 2.0.0 Jun 17 18:07:33 I tried changing it to 2.2.0-alpha3 Jun 17 18:07:42 because it did that on it's own once.. Jun 17 18:07:55 but this time it didnt' automatically do that.. Jun 17 18:08:54 no idea then Jun 17 18:09:13 I have kind of an odd problem. When using PropertyAnimator to move a view down the screen, if "show layout bounds Jun 17 18:09:14 bitkiller_: I'm already doing it. In 5.0 it's working just with it. In 4.4.4 it still showing the circles. Jun 17 18:09:22 is enabled, the bounds never move Jun 17 18:09:23 remove gradle dir and try again Jun 17 18:09:46 why is that? Jun 17 18:10:30 ok Jun 17 18:11:02 wviana, what about this: https://code.google.com/p/android/issues/detail?id=62839 Jun 17 18:30:48 i'm kinda lost reading the Conductor docs, i guess i've been too brainwashed by fragments. Anyone have a good blog ? Jun 17 18:36:13 there was one posted to /r/androiddev a month or so ago, i think Jun 17 18:51:16 Hello Jun 17 18:52:28 hello Jun 17 18:52:30 I am setting String in SharedPreferences in one activity, started another activity, and the same String preference does not have the new value. What is happening? Jun 17 18:52:59 I need some help with rooting my nexus 5x Jun 17 18:53:09 try #android-root Jun 17 18:53:16 I'm trying to pull logs from a system app, does ALogcat do the same thing as puling logs using android dev tools? Jun 17 18:53:31 Also is ADB bundled with android studio? Jun 17 18:53:39 it’s bundled with the SDK Jun 17 18:54:08 deadmund, how are you setting and retrieving the string? Jun 17 18:54:13 thanks s73v3r Jun 17 18:57:01 lut4rp: code: http://pastebin.com/S6zUheXD Jun 17 18:57:41 lut4rp: I'm using SharedPreferences and Editor and getString / puString and commit() etc Jun 17 18:57:57 hi Jun 17 18:58:03 how i can do this http://imgur.com/uhHytbZ in my menu? Jun 17 18:58:15 I obtain an instance to SharedPreferences using getPreferences(MODE_PRIVATE) in the oncreate of each of these activities. Is that a problem? Jun 17 19:00:23 deadmund: have you tried using commit() instead of apply()? also.. how are you getting the SharedPreferences object? Jun 17 19:00:36 aj Jun 17 19:00:43 deadmund: why not use the default one? Jun 17 19:01:17 SharedPreferences shared = PreferenceManager.getDefaultSharedPreferences(this); Jun 17 19:01:17 I think you mean apply() instead of commit() Jun 17 19:01:22 no i dont Jun 17 19:01:29 apply is async and commit is sync Jun 17 19:01:41 they are already using commit Jun 17 19:02:42 i didnt see his pastebin Jun 17 19:03:06 t0th_-_: thats called a Spinner, but a picture witha icon is not very helpful in asking what exactly you want Jun 17 19:03:14 deadmund: still there? Jun 17 19:03:30 Napalm: The default one? Jun 17 19:03:41 deadmund: yea, i pasted code Jun 17 19:03:48 I'm using getPreferences(MODE_PRIVATE) to get the prefrences Jun 17 19:04:16 I just figured it out on my end. I was using getPreferences but I need to use getSharedPreferences and give the same name. Jun 17 19:04:18 deadmund: yea, no real difference except if you have different file names.. defaultSharedPrefs uses your package name Jun 17 19:04:23 (name is required for getSharedPreferences) Jun 17 19:04:43 deadmund: thats why you use the default :D Jun 17 19:04:47 haha Jun 17 19:04:48 :D Jun 17 19:04:48 anybody try gradle-experimental? how is that going ? Jun 17 19:05:17 Napalm: You're not understanding. If I use getPreferences (without passing a name) the bug occurs. If I use getSharedPreferences() then the bug goes away. Jun 17 19:05:31 If I use getPreferences and don't pass any name* Jun 17 19:05:38 yes i understand fine Jun 17 19:06:23 its because you are using two different preference files Jun 17 19:06:40 that is why you should simply always use PreferenceManager.getDefaultSharedPreferences(this); for app wide preferences Jun 17 19:07:12 Activity.getPreferences(int) as the function says is "Retrieve a SharedPreferences object for accessing preferences that are private to this activity." Jun 17 19:07:21 not to be shared between activities Jun 17 19:07:28 I am an idiot. Jun 17 19:07:37 How do you handle username and password for your heroku code? you HAVE to store it in the repo right? since you use git to push to heroku... Jun 17 19:07:39 Thanks! Jun 17 19:08:39 deadmund: to be honest though, i'm not sure why you would use sharedprefs for that Jun 17 19:09:08 I could just pass it to the activity? Jun 17 19:09:32 I want to keep track to tell the user "last time you choose A!" which, in this application, implies they should this time choose "b" Jun 17 19:09:44 deadmund: looks to me like setting it as an intent.putExtra("day", "b") Jun 17 19:09:50 would be better Jun 17 19:09:51 dfsf: I wouldn’t do that Jun 17 19:10:44 s73v3r: i know it is generally a bad idea but do you know heroku? you push your repo to it, so how would you not store it? Jun 17 19:10:53 i don’t know heroku, sorry Jun 17 19:11:01 you might look for a heroku channel Jun 17 19:11:27 presumably if you’re pushing to heroku, then it’s set up as a remote? Jun 17 19:11:35 in which case, you wouldn’t store the credentials in the repo Jun 17 19:11:50 they’d be stored in your git config, just like the credentials to github or bitbucket Jun 17 19:13:34 Napalm: yeah, thanks for the tip! :) Jun 17 19:13:42 https://bpaste.net/show/59debbdcc7d6 trying to figure out what's causing the 06-15 00:59:44.978 15151 15151 E AndroidRuntime: Caused by: java.lang.NullPointerException: Attempt to invoke interface method 'java.util.Iterator java.util.List.iterator()' on a null object reference Jun 17 19:13:46 s73v3r: i wasnt being clear. what i mean is the user and pw for the database, not for heroku itself Jun 17 19:14:09 ahhh. that I wouldn’t know Jun 17 19:14:27 i have to imagine there’s another way to do it besides storing them in the repo, but I don’t know what it is Jun 17 19:15:41 anyone have experience with firebase yet? I am curious about the advantages of using it over realm, specifically for offline storage. Jun 17 19:16:08 bitkiller: That pretty much the same problem. Still no solution. :( Jun 17 19:18:03 shit, i updated to platform-tools 24 final and AS keeps hanging on gradle syncs, wtf Jun 17 19:18:34 hmm... I haven't had that problem yet Jun 17 19:18:42 kill AS and then restart see if the issue persists Jun 17 19:19:31 i have a few times Jun 17 19:19:55 nuked ~/.gradle too Jun 17 19:20:05 and ~/.gradle Jun 17 19:20:21 and the gradle console is totally blankl Jun 17 19:20:28 nothing shows up at all Jun 17 19:21:14 SDK manager only has platform tools 24, so i can't roll back Jun 17 19:22:44 have to reinstall previous by hand. i had to do it when it stopped supporting 32bit linux without a notice Jun 17 19:26:16 oh man this is weird, command line 'gradle clean' hangs on configuring classpath , W T FFFF Jun 17 19:28:07 might need to reinstall the OS :/ Jun 17 19:28:19 OS? Jun 17 19:29:02 'cause of plat-tools update? Jun 17 19:36:00 Configuring > 0/8 projects > root project > Resolving dependencies ':classpath' Jun 17 19:36:06 the end. wtf Jun 17 19:41:49 Could not GET 'https://repo1.maven.org/maven2/com/android/tools/build/gradle/maven-metadata.xml' Jun 17 19:42:03 Connect to repo1.maven.org:443 [repo1.maven.org/151.101.20.209] failed: Operation timed out Jun 17 19:42:18 anybody else having problems connecting to maven repo ? Jun 17 19:42:38 but thats fucking lame it would hang the whole IDE, assmunches Jun 17 19:44:21 can anyone hit this url from browser and let me know what happens https://repo1.maven.org/maven2/com/android/tools/build/gradle/maven-metadata.xml Jun 17 19:45:59 g00s, it's ok. xml content Jun 17 19:46:16 thanks bitkiller Jun 17 19:56:01 After changing my project to buildTools 23, I'm getting duplicate definition of library class when running proguard. Do you know something about it ? Jun 17 20:01:42 bitkiller VPN was messings things up Jun 17 20:03:33 I found something about -injars and -libraryjars in proguard-project.txt , But I don't have such file. Do you know something about it ? Jun 17 20:09:41 nexus 6 vs nexus 6p? Is it worth the price diff? Jun 17 20:12:01 It looks like something about my change into buildTools 23. Jun 17 20:18:39 wow, it's raining Jun 17 20:19:43 isn't there a build tools 24 now Jun 17 20:19:51 What do I do when Gradle Build works forever, than stopped and now it's stopping forever. Jun 17 20:20:46 wviana lol is it hanging ? Jun 17 20:21:10 yep Jun 17 20:21:27 wviana using VPN by any chance? I just had that problem, shutting off VPN solved it Jun 17 20:21:40 its like the internets broke Jun 17 20:21:50 g00s: No, just try build a couple time just some minutes before. Jun 17 20:22:09 g00s: Was working fine Jun 17 20:22:23 wviana yeah me too, just stopped working about an hour ago Jun 17 20:22:30 really ? Jun 17 20:22:32 i thought it was becuase i updated platform-tools Jun 17 20:22:42 g00s: So did I Jun 17 20:22:56 platform tools is independent of gradle Jun 17 20:23:05 g00s: But I did it into 23, what about u ? Jun 17 20:23:09 yeah i couldn't figure out how that would impact Jun 17 20:23:18 the gradle plugin doesn't depend on platform-tools Jun 17 20:23:22 wviana, post your proguard-rules Jun 17 20:23:38 Hello? Jun 17 20:23:48 wviana try from command line of course, with -debug - see if gradle ivy resolvers are hanging contactiing maven repo Jun 17 20:24:17 can't I kill gradle from terminal ? Jun 17 20:24:43 wviana can you hit this from curl / browser https://repo1.maven.org/maven2/com/android/tools/build/gradle/maven-metadata.xml Jun 17 20:25:03 It appears that screen rotations interrupt touch events. Eg. user touches down (event received for that), user rotates screen, user removes finger (event not received) Jun 17 20:25:16 Is there a way around this? Jun 17 20:25:30 HactarCE probably handle configuration changes yourself Jun 17 20:25:55 I already have android:configChanges="orientation|screenSize" and it's very helpful Jun 17 20:26:04 What else do I add to that list? Jun 17 20:26:14 why do you care about finger presses persisting through rotation? Jun 17 20:26:23 well maybe a game i guess Jun 17 20:26:24 doesn't make sense, unless it's a game Jun 17 20:26:30 It's not absolutely vital... (not a game though) Jun 17 20:26:36 in that case, you can just use onTouch Jun 17 20:26:41 I am creating a speedcube timer Jun 17 20:26:56 The user must hold down their finger for half a second, then release to start Jun 17 20:26:59 (to start timer) Jun 17 20:27:12 so block rotation changes while the touch is occurring Jun 17 20:27:18 that's possible? Jun 17 20:27:22 that would be excellent! Jun 17 20:27:33 Thank you. :) Jun 17 20:28:10 yes, setOrientation Jun 17 20:28:41 setRequestedOrientation, block it while touching, unblock it while done Jun 17 20:28:52 g00s: I killed gradle. Android Studio said I builded successfully. Please Jun 17 20:31:40 Would setRequestedOrientation(SCREEN_ORIENTATION_UNSPECIFIED) unblock? Jun 17 20:32:38 or SCREEN_ORIENTATION_SENSOR? Jun 17 20:33:10 NOSENSOR Jun 17 20:33:15 oh, unblock, _SENSOR Jun 17 20:33:59 ah ok Jun 17 20:34:10 Using NOSENSOR will turn off the sensor but leave the current orientation then? Jun 17 20:34:20 so there's no need for getReqOrientation? Jun 17 20:34:51 depends, sometimes it goes to device-default orientation Jun 17 20:35:00 Eh, I'll mess around with things a bit Jun 17 20:35:37 Thank you very much for the help. :) Jun 17 20:36:02 but yeah, doesn't make sense for touch events to persist through rotations because position of touch point changes after rotation Jun 17 20:36:10 which is just downright odd if you're tracking Jun 17 20:36:47 SCREEN_ORIENTATION_LOCKED worked like a charm :) Jun 17 20:36:58 true, I suppose you're right Jun 17 20:39:06 I am slightly confused by how Activities interact, is only one Activity active at any time? Jun 17 20:40:15 Yes Jun 17 20:40:37 Well, only one is visible at a time Jun 17 20:41:18 So, in terms of Java variables, when do static variables get initialised when part of an app on Android :S? Jun 17 20:42:48 I have no clue... probably at first run of the given activity? Jun 17 20:43:01 You could test that, I suppose Jun 17 20:43:14 Make a few activities, have a static variable call a function that prints something to stdout Jun 17 20:49:22 How do people normally manage app-global resources (in my case a MIDI device) when you are switching between Activities? How do you decide to release the resource? Jun 17 20:50:13 dofidum well, don't put it in an activity Jun 17 20:50:22 you can put it in a Singleton Jun 17 20:50:31 g00s, does that Singleton live forever :S? Jun 17 20:50:37 if it needs to work when no activities are shown, you can put it in a service Jun 17 20:51:09 and just start the service when it starts doing things, and then stop the service when (1) its idle and (2) your UI is not shown Jun 17 20:51:19 see ComponentCallbacks2 Jun 17 20:52:02 g00s, it doesn't need to work when there are no activities, I am just not sure when to release (or reclaim) the resource... Jun 17 20:55:45 g00s, maybe I need an Application? (hadn't heard about this class before) Jun 17 21:09:57 Hello! :D Jun 17 21:10:03 HactarCE, regarding static variables: http://stackoverflow.com/questions/1944369/android-static-object-lifecycle Jun 17 21:10:34 Ah, neat to know. ;) Jun 17 21:10:39 Hello, Ventura2! Jun 17 21:10:49 how could I have 2 different apps, one with advertisement and another without, but without having to modify all the time the code Jun 17 21:11:00 :D that should be awesome!ç Jun 17 21:11:18 sorry my english Jun 17 21:11:39 I don't know for sure, but I would guess you design a layout with an advertisement which can have its visibility set to "gone" and the layout will still function Jun 17 21:11:45 Ventura2, make two flavors Jun 17 21:11:46 then some in-app purchase? Jun 17 21:12:44 oh, thanks mavrik I didn't know that word Jun 17 21:12:54 I think I found something. https://developer.android.com/studio/build/build-variants.html Jun 17 21:15:01 hi Jun 17 21:15:15 Ventura2, yes, that's it. Jun 17 21:16:12 Hello can I ask something about my Dual Sim phone ? It doesn't keep the settings for the two differen ringtones when I reboot it. Could anyone help me? Jun 17 21:39:14 no Jun 17 21:39:18 wrong channel Jun 17 21:39:22 go away Jun 17 21:41:03 :D Jun 17 21:41:20 jackbrown didn't we tell you yesterday, wrong channel ? Jun 17 21:41:46 we don't change topics on Friday Jun 17 21:43:08 lol Jun 17 21:51:12 hrm, so i get Conductor Controllers, but not much else. docs suck Jun 17 21:51:31 sample isn't a replacement for describing how stuff works Jun 17 21:53:11 wait, we don’t change topics on fridays? Jun 17 21:53:17 I wanted to talk about ponies :( Jun 17 21:57:20 s73v3r Pony hour is after Unicorn hour on Sunday afternoon Jun 17 21:57:48 eeyup Jun 17 21:57:57 oh. I don’t log on outside of work, so I wouldn’t know Jun 17 21:59:14 s73v3r Unicorn hour gets pretty crazy, especially when Charlie is here Jun 17 22:04:13 my gradle is keep running for ever :( When it runs I'm getting errors. I was in buildTools 22, updated into 23, Now when build into release proguard is giving errors. I tried to add useLibrary 'org.apache.http.legacy' into build.gradle and also add some -dontnote android.net.http.* into my proguard file. But When gradle don't indefinitely I got errors. Jun 17 22:09:41 Is there a way to force a layout (and its children) to not intercept touches (programmatically) Jun 17 22:09:42 ? Jun 17 22:10:10 Because when using an "Animation" rather than "Animator" the objects *real* position stays the same, though it visually moves Jun 17 22:14:23 I should probably change my question, seeing as "Animations" appear to be obsolete Jun 17 22:14:55 so fix the errors Jun 17 22:16:18 New question: How do I animate something to slide off the edge of the screen using Animators? Is it even possible? (bottom edge, in case anyone was wondering) Jun 17 22:16:27 Hi guys. I noticed that very often AS, after I open some project I didn't open for some time shows me popup warning "unregistered vcs root detected" and I have options to add root or ignore or something third. I mean, why? Why is it unregistered everytime? Jun 17 22:18:56 because AS doesn't assume that each project has it's own git. For some reason. Jun 17 22:19:17 if it's a project you've opened before, it's probabyl only because it recreated all the project data for it Jun 17 22:19:28 perhaps b/c of a major AS ugprade. Otherwise it's a per-project setting Jun 17 22:20:28 What if I have a proguard.config instead of a proguard-project.txt ? Jun 17 22:23:44 Hello everyone Jun 17 22:23:55 I would like to implement an image slider like the one in the Google Play Store. Jun 17 22:24:10 Does anyone know if there's any implementation around there or a component I could use to achieve this? Jun 17 22:24:16 viewpager Jun 17 22:24:20 By image slider I mean.. Jun 17 22:24:25 The slideshow Jun 17 22:24:33 Ranguro: Viewpager Jun 17 22:25:01 https://developer.android.com/training/animation/screen-slide.html Jun 17 22:26:08 What about the icons? s73v3r where do I get the icons used in the Google Play Store viewpager? Jun 17 22:26:36 they’re just dots Jun 17 22:27:10 Oh Jun 17 22:27:23 so you can make your own images Jun 17 22:27:51 Yes.. Jun 17 22:27:56 but I would like to follow a standard Jun 17 22:28:00 last time I had to do something like that, I used JakeWharton’s ViewPager Indicator library, but for some reason I heard that was out of fashion Jun 17 22:28:03 there is no standard Jun 17 22:28:07 it’s a dot Jun 17 22:28:49 And if I wanted to add tabs Jun 17 22:28:53 That would be another viewpager Jun 17 22:29:02 I mean like the same tabs Jun 17 22:29:35 There's one tab that says: Apps and Games Jun 17 22:29:38 that would probably be something like this: https://developer.android.com/training/implementing-navigation/lateral.html Jun 17 22:29:40 and the other one Entertainment Jun 17 22:29:56 but those would be different viewpagers Jun 17 22:30:04 I see Jun 17 22:30:14 Well it's okay Jun 17 22:30:22 I'm not so sure yet if I want those in my app Jun 17 22:32:10 I And finally I guess that the apps that are shown in the play store Jun 17 22:32:16 they are a Recyclerview with a Cardview Jun 17 22:32:27 using HorizontalLayoutManager Jun 17 22:32:34 yuppers Jun 17 22:32:59 It's a good practice to try to decompose the apps that google develop :P Jun 17 22:33:49 Is the whole activity inside of a Scrollview? Jun 17 22:34:18 probably Jun 17 22:34:20 I mean because you can keep scrolling through it while it keeps loading content Jun 17 22:34:33 maybe a custom scrollview Jun 17 22:34:35 and it doesn't sound to me that you should be adding all that stuff inside of a Listview Jun 17 22:34:49 maybe even a recyclerview Jun 17 22:35:14 Hmm Jun 17 22:35:22 Yes it's a recyclerview I think Jun 17 22:39:19 That fetching while you scroll... is that feature enabled through a cursor adapter? Jun 17 22:39:27 s73v3r: Jun 17 22:39:46 i don’t think it’s specific to a cursor adapter Jun 17 22:39:57 SyncAdapter? Jun 17 22:40:05 you just determine the cutoff value for when to fire off a new load Jun 17 22:40:09 it doesnt matter what ur using Jun 17 22:40:13 yeah, pretty much, Jun 17 22:40:45 you can create a custom layoutmanager, which will determine how many cells to build in adavance Jun 17 22:42:03 I see.. Jun 17 22:42:18 I thought it was related to a specific adapter. Jun 17 22:42:38 adapter has nothing to do with it Jun 17 22:42:47 it's all in your data model Jun 17 22:43:09 and some view detection for finding when you hit the end of your current data Jun 17 22:44:53 Ok, I'm fine then Jun 17 22:45:00 I'll do some research about it. Jun 17 22:45:13 Thank you guys! Jun 17 22:47:02 Check out Nick Butcher’s Plaid app on Githug Jun 17 22:47:05 Github Jun 17 22:47:14 Let me see Jun 17 22:47:14 githug Jun 17 22:47:17 haha Jun 17 22:48:45 Ok I'm following and I'll check it when I arrive home. Jun 17 22:50:19 how is progressbar.setVisibility(GONE) being called but the view is still visible Jun 17 22:50:24 thats makes no sense Jun 17 22:55:02 http://prntscr.com/bhqak2 Jun 17 22:55:05 view isnt null Jun 17 22:55:19 that log statement is being called, but the progress bar is still visible Jun 17 23:02:51 Hi all. Quick question, what's the best audio format to use for small notification sounds that will be played with MediaPlayer? Should I just encode my audio files as .mp3 and be done with it, or is there a faster alternative? Jun 17 23:03:08 If it makes a difference, the files will be stored in res/raw, not assets Jun 17 23:16:52 does anyone know of a way to run my android app on the emulator and have the crash reports sent up to the google play dev console? Jun 17 23:17:03 do all I need to do is run the emulator with the google play services installed? Jun 17 23:18:15 orbyt_: your probably making it visible again. Jun 17 23:18:59 liuwenhao: save as mp3 to raw, above 128kbit is probably not worth it. 64kbit is fine. Jun 17 23:20:01 liuwenhao: Uri soundUri = new Uri.Builder().scheme(ContentResolver.SCHEME_ANDROID_RESOURCE).authority(getPackageName()).path("/raw/" + sound_name).build(); Jun 17 23:20:08 NotificationCompat.Builder builder = /*...*/; builder.setSound(soundUri, AudioManager.STREAM_NOTIFICATION); Jun 17 23:20:12 that should do you fine Jun 17 23:20:56 sleepster: it might if you set the installer to com.android.vending Jun 17 23:20:57 Thank you @Napalm, that's perfect Jun 17 23:21:05 sleepster: see the adb shell pm command Jun 17 23:21:43 sleepster: https://developer.android.com/studio/command-line/shell.html Jun 18 00:02:01 Well... this is a mess Jun 18 00:02:39 I'm using an Animator on one of my controls to have it "slide" off the screen and back on at certain times Jun 18 00:03:15 To support screen rotation and stuff, it uses Jun 18 00:03:16 getBottom() to get the screen height and bases translation values off of that Jun 18 00:03:28 only problem: rotation can happen during the animation Jun 18 00:03:44 How do I tell the Animation to do something when it completes? Jun 18 00:05:09 HactarCE: the view gets destroyed when a rotation happens so its not normally a problem Jun 18 00:05:40 HactarCE: but you can add a listener to an Animator so that you know when it starts/updates/ends or gets cancelled Jun 18 00:05:51 1. But I need to handle rotations separately so that other data doesn't get wrecked (but this is data that *shouldn't* stay persistent through restarts of the app) Jun 18 00:05:58 2. I'll try that thanks. :) Jun 18 00:08:11 HactarCE: 1. thats why you have callbacks for that Jun 18 00:08:21 ? Jun 18 00:08:43 onRetainCustomNonConfigurationInstance and getLastCustomNonConfigurationInstance Jun 18 00:09:04 HactarCE: its also why you have onSaveInstanceState Jun 18 00:09:44 HactarCE: when an app gets restated its state Bundle is blank Jun 18 00:09:47 well null Jun 18 00:10:00 Sorry, you're still way over my head Jun 18 00:10:26 HactarCE: ok in your onCreate of your activity you get the savedInstanceState bundle Jun 18 00:10:33 I do? Jun 18 00:10:37 you can save variables into that in onSaveInstanceState Jun 18 00:10:41 Ah, ok Jun 18 00:10:51 so they persist across config changes like rotation Jun 18 00:10:56 you should always do this Jun 18 00:11:02 OH Jun 18 00:11:05 because a config change is not just because of rotation Jun 18 00:11:44 Do I just set arbitrary values like "String savedInstanceState.important_string = string_I_want_to_keep"? Jun 18 00:11:55 yes Jun 18 00:11:59 ah thank you :) Jun 18 00:12:07 onSaveInstanceState() gives you a Bundle called outState Jun 18 00:12:36 you can call outState.putString("name_key", "string_i_want_to_keep"); Jun 18 00:12:48 then in your onCreate you will get that bundle back Jun 18 00:12:56 ok Jun 18 00:13:03 if(savedInstanceState != null) myString = savedInstanceState.getString("name_key"); Jun 18 00:13:23 onRetainCustomNonConfigurationInstance and getLastCustomNonConfigurationInstance Jun 18 00:13:36 So I should create an @Override onSaveInstanceState() with those "outState.putString(key, value);" statements? Jun 18 00:13:40 these work in a similar way but let you keep any object that can contain others Jun 18 00:14:04 but you have to be careful not to keep objects that reference even indirectly the previous activity context Jun 18 00:14:18 So no gui widgets or anything Jun 18 00:14:19 so things like an View or Adapter would be bad choice Jun 18 00:14:24 gotcha Jun 18 00:14:33 but if you have your own model objects Jun 18 00:14:48 that are basically just bags of primitive objects and lists Jun 18 00:14:50 then thats fine Jun 18 00:15:01 Does this savedInstanceState stuff happen when the app is reopened, or only when the app stays open but the activity is recreated for other reasons? Jun 18 00:15:10 as long as those objects dont then refer to Views and the like. even in listeners or callbacks. Jun 18 00:15:23 all those should be nulled out or removed. Jun 18 00:15:31 no Jun 18 00:15:50 savedInstanceState will be set to non-null when the activity is being recreated Jun 18 00:16:03 now if you background an app with home button Jun 18 00:16:11 it will go into a stopped state. Jun 18 00:16:33 eventually it will be destroyed and your onSaveInstanceState will be called Jun 18 00:17:04 if you then bring back that background task in the recents app.. it will recreate your Activity with that bundle Jun 18 00:17:10 Excellent! Jun 18 00:17:12 but your application was not killed Jun 18 00:17:16 right Jun 18 00:17:22 if your application was swiped away out of recents Jun 18 00:17:28 then the bundle will be null again Jun 18 00:17:35 ok Jun 18 00:19:04 Should I use onRetainCustomNonConfigurationInstance and getLastCustomNonConfigurationInstance, or the outstate stuff? Jun 18 00:19:08 I'm not really clear on the different Jun 18 00:19:15 s/t/ce Jun 18 00:20:20 i suggest you use the outState bundle Jun 18 00:20:26 ok Jun 18 00:20:57 And I do all that in my own "@Override onSaveInstanceState()" definition? Jun 18 00:23:30 Ah, found an SO question on the subject. Jun 18 00:23:36 Thank you very much, Napalm. :) Jun 18 00:23:50 np Jun 18 00:30:50 does animateLayoutChanges apply to to siblings and parents of the layout as well Jun 18 00:31:01 missingno: no Jun 18 00:31:13 missingno: only direct children. Jun 18 00:31:15 sweet Jun 18 00:31:18 thanks Napalm Jun 18 00:31:42 missingno: but, if the size of the view changes.. then the views around will also move as part of standard layout Jun 18 00:32:03 ah that is probably what is happening Jun 18 00:32:04 missingno: https://github.com/slightfoot/android-material-comments < i use it here for great effect Jun 18 00:32:20 the email addresses in the animated gif Jun 18 00:32:32 and the text moves around from the animateLayoutChanges Jun 18 00:42:57 hi, is there a way to do a reverse GPS coords so it returns to a city, state? Jun 18 00:43:16 Darkclaw66: You can probably use the Google Maps API. Jun 18 00:43:31 Great! How can I have it return city, state? Jun 18 00:43:42 Darkclaw66: ofc, Reverse Geocoding Jun 18 00:43:58 Call the api function with the params and have it return Jun 18 00:44:07 Darkclaw66: https://developers.google.com/maps/ Jun 18 00:44:12 I am at the API page. it shows many fields. which ones would correctly return the city? Jun 18 00:44:19 LunarEclipse120: no Jun 18 00:44:49 Napalm: What? Jun 18 00:45:01 its built in Jun 18 00:45:06 Oh cool Jun 18 00:45:10 https://developer.android.com/training/location/display-address.html Jun 18 00:45:21 Oh I see Jun 18 00:45:26 https://developers.google.com/maps/documentation/geocoding/start?csw=1#geocoding-request-and-response-latitudelongitude-lookup Jun 18 00:45:28 Google searches are nice Jun 18 00:45:29 https://github.com/googlesamples/android-play-location/blob/master/LocationAddress/app/src/main/java/com/google/android/gms/location/sample/locationaddress/FetchAddressIntentService.java Jun 18 00:45:30 exactly Jun 18 00:45:33 example Jun 18 00:45:43 that's really what I am looking to use but my question is which field correlates to the city Jun 18 00:46:53 is it locality? Jun 18 00:47:09 it can be Jun 18 00:47:10 Darkclaw66: It is one variable with the whole address from what I see. Jun 18 00:47:19 or it could also be "Mountain View" for example Jun 18 00:47:30 that's the challenge I'm facing. Jun 18 00:47:35 https://developer.android.com/reference/android/location/Address.html Jun 18 00:47:43 Ah nevermind Jun 18 00:47:46 Darkclaw66: getAddressLine() Jun 18 00:47:49 Darkclaw66: make your request and see Jun 18 00:48:09 Darkclaw66: i think its getSubLocality Jun 18 00:48:43 interesting Jun 18 00:49:32 I think it is getAddressLine() and the params say the line you want Jun 18 00:49:52 Napalm has the right idea Jun 18 00:50:08 https://developer.android.com/reference/android/location/Address.html#getAddressLine(int) Jun 18 00:50:13 LunarEclipse120: it doesnt work like that Jun 18 00:50:18 thats just a line Jun 18 00:50:21 Oh ok Jun 18 00:50:22 but you dont know what that line is used for Jun 18 00:51:09 The example is using a for loop to add them together Jun 18 00:51:45 LunarEclipse120: sure, but thats not what he wants Jun 18 00:51:49 Oh nevermind Jun 18 00:51:49 Napalm: is this API built into the device or does it require an API call to Google maps? Jun 18 00:51:54 Darkclaw66: getLocality() Jun 18 00:52:00 Darkclaw66: built into the device Jun 18 00:52:02 its part of android Jun 18 00:52:06 read the tutorial Jun 18 00:52:08 It says in the GitHub Jun 18 00:52:16 https://developer.android.com/training/location/display-address.html Jun 18 00:52:25 and the sample app Jun 18 00:52:25 https://github.com/googlesamples/android-play-location/blob/master/LocationAddress/app/src/main/java/com/google/android/gms/location/sample/locationaddress/FetchAddressIntentService.java Jun 18 00:53:03 im not coding it, just researching Jun 18 00:53:04 Napalm: So I am a noob; would the getLocality() function fit his purpose? Jun 18 00:53:11 well there you go Jun 18 00:53:25 LunarEclipse120: he only wants the city Jun 18 00:53:27 working with developers to get an issue resoled Jun 18 00:53:44 here is some context on the issue Jun 18 00:54:07 need to translate gps cords to pass to a weather api company but their autocomplete api doesn't accept cords Jun 18 00:54:10 Napalm: It says "// getLocality() ("Mountain View", for example)" Jun 18 00:54:19 What it returns is the city Jun 18 00:54:24 they only accept query on the name of the location (e.g. city, state) Jun 18 00:54:41 the issue is around the world, it's not clear cut passing a city and state Jun 18 00:54:41 LunarEclipse120: Darkclaw66: i think its getSubLocality Jun 18 00:54:57 so there might be instances where that can be null Jun 18 00:55:07 I see but the github page says otherwise. Jun 18 00:55:57 LunarEclipse120: they are just example comments, read the docs Jun 18 00:56:09 Darkclaw66: yea, so you fall-back to the next in the chain Jun 18 00:56:17 that's what I am thinking to do Jun 18 00:56:24 Darkclaw66: until you are left with country Jun 18 00:56:30 Darkclaw66: thats what I do Jun 18 00:57:02 the challenge is that only having country level will break the app Jun 18 00:57:24 the weather api really needs a city and state Jun 18 00:57:40 I guess that's just an exception in that case, need to display an error message Jun 18 00:58:18 Napalm: I am if they are looking at the city for example, like Denver then the getLocality() would be the right thing Jun 18 00:58:18 just to confirm though (excuse my ignorance), I thought reverse geo-coding requires a key from Google Jun 18 00:58:32 Hmm, I wonder why AudioSource.DEFAULT works for built in mic but refuses to run the AudioRecorder if I have a plain old wired 4-terminal headset plugged in. Jun 18 00:58:40 Darkclaw66: no it deosnt Jun 18 00:58:44 doesnt, its part of Android Jun 18 00:59:32 jesseg: what version of Android.. i had some weird issues with that and it turned out to be a bug in marshmellow Jun 18 01:00:35 Napalm, 4.2.2 in my case. 5.01 does not exhibit the same behavior. On the 4.2.2, the external mic works fine if I plug it after launching ip; but if mic is plugged in at launch, audioRecord says it cannot get the requested input option 1 or whatever Jun 18 01:00:55 *launching APP.. not IP. Jun 18 01:01:22 jesseg: could be a mic sharing issue Jun 18 01:01:28 some of those on older android versions Jun 18 01:01:55 Napalm, oh, like my manifest needs to specifically request permission for the mic, not just to record audio? Could be. Jun 18 01:02:42 Napalm: I am interested to test what value is returned using getSubLocality(). What is a quick dirty way to see it? Jun 18 01:02:46 Darkclaw66: http://hastebin.com/bahenunaho.java Jun 18 01:02:56 thats what i used in the end for my needs Jun 18 01:04:07 jesseg: perhaps, but you should also add the uses-hardware manifest tag. but i was thinking about if another app, like the launcher is using the mic and then your app tries to access the mike before the launcher has releae Jun 18 01:04:12 released it, then it will fail Jun 18 01:04:16 can I run that from linux? Jun 18 01:04:26 honestly I am not a developer but I am savvy Jun 18 01:04:27 the mic was like the camera api.. only one app at once Jun 18 01:05:06 if I gave you the gps cords, would you be able to let me know the sublocality? Jun 18 01:05:31 Darkclaw66: there is no easy way. but you can use the google api to get the same response on their site Jun 18 01:05:37 Napalm, thanks, I'll try that. It is odd that the built in mic works no problem. Jun 18 01:06:19 using the google maps API doesn't quite align with the fields though Jun 18 01:06:26 Darkclaw66: whats the lat/lng Jun 18 01:06:34 administrative_area_level_1, administrative_area_level_2 Jun 18 01:06:46 yea it does Jun 18 01:06:54 Address has those Jun 18 01:08:04 anyway Jun 18 01:08:12 oh I see! Jun 18 01:08:23 Darkclaw66: anyways, whats the lat/lng you want tested? Jun 18 01:08:44 I see the same fields now, I was just not looking right Jun 18 01:08:55 ok Jun 18 01:11:09 it seems the safest is to use "locality, administrative_area_level_1 ? Jun 18 01:11:49 yea, which is getAdminArea i believe Jun 18 01:11:55 whatever you feel is right Jun 18 01:12:17 i went with sub-locality, locality, > admin-area Jun 18 01:16:31 would administrative_area_level_2 translate to sub-locality? Jun 18 02:13:11 Hi folks, i am wondering whats the best way to have a +/- UI widget on android that looks like it fits material design? Like for changing a numerical value like temperature or something Jun 18 02:13:30 Material design doesn't seem to have such a thing and only shows examples of date and time pickers as that dial thing Jun 18 02:13:56 sylon: Maybe a square fob with a line in the middle, then the plus and minus symbols on the sides? Jun 18 02:15:34 LunarEclipse120: interesting, you mean floating action button? Jun 18 02:15:37 sylon there is a number picker too, but no backport to material Jun 18 02:16:09 sylon: Yes, like the rest of them. Jun 18 02:16:11 but there are some 3rd party libs, because somebody has to when google drops the ball Jun 18 02:16:44 I wasn't aware it could be a square. never seen it in any apps i use! Jun 18 02:17:15 I was thinking of 2 small FAB's for + and - vertically aligned Jun 18 02:17:41 That might work too Jun 18 02:17:53 I was thinking of making the icon and just adding animation effects Jun 18 02:18:01 But good for you for sticking with Material Jun 18 02:20:05 g00s: yeah i really need to look into how to wrap third party libraries. Since I use Xamarin, i have kind of neglected them and just been using C# libraries that work with mono, but I know Xamarin has a way to wrap a .jar library Jun 18 02:25:33 for apps that store data locally (either sqlite or file storage) Whats the recommended way of backing it up? or do you just not bother and let android take care of it? Jun 18 02:26:05 for when user factory resets phone / switches to new device Jun 18 02:26:20 without having a cloud service for my app Jun 18 02:27:52 What? If they factory reset their phone and you dont have a remote db then ofc its gonna be gone lol Jun 18 02:29:03 orbyt_: yeah I know but without building an app specific remote db what's the best way to handle that case? Jun 18 02:29:20 like use dropbox api/google drive api, maybe firebase or something else Jun 18 02:30:54 oh, that's an interesting idea. Wonder if there's some easy-to-use library that basically does 'backup/restore-to-cloud-storage'. Jun 18 02:31:41 sylon on Android 6 your apps data automatically gets backed up to gdrive Jun 18 02:31:59 oh, is that right? Nice Jun 18 02:32:13 the backup apis before that absolutely sucked Jun 18 02:32:30 so nobody used them, hence google decided to do it themselves Jun 18 02:32:35 g00s: i know but it happens automatically and only when user is on WIFI and plugged in and if they haven't turned it off, so its not reliable. and i think default is something like 2am or something Jun 18 02:32:45 I'd rather do something where my app does the backup Jun 18 02:33:12 i think the automatic one is great for backing up your shared preferences etc, data that isn't a big deal if lost but its nice to have remembered Jun 18 02:33:31 but for critical app data e.g. if i was building a todo list app, I wouldn't trust it, i'd want my own method Jun 18 02:34:06 It also makes me wonder a bit how they manage (potentially) app-private stuff (keys and so forth.) They are expecting devs to disable it from the manifest I guess? Jun 18 02:34:46 yes you are meant to disable it Jun 18 02:37:56 I guess the other advantage is not needing to have the user jump through yet another identity/auth thing; unless the app is already just using the google identity. Nice, thanks for the info around the new backup thing Jun 18 02:40:13 kbs: have you looked at how WhatsApp does its backup, it seems to use google drive and does nightly explicit backups instead of relying on android's own backups Jun 18 02:41:41 I didn't know that (don't use it either) but that's quite interesting. So it drops an OAuth permission at some point so it has read/write access to GDrive? Jun 18 02:43:03 I can see (at least, until 23+ is more ubiquitous) some feature like this might be nice, especially if it had some way to protect the backup data as well Jun 18 02:43:31 s/feature/library **** ENDING LOGGING AT Sat Jun 18 02:59:58 2016