**** BEGIN LOGGING AT Sun Apr 24 02:59:58 2016 Apr 24 03:19:03 What can make espresso so racy that it doesn't pick up a fully-rendered view and idling is off only after the view has been shown? Apr 24 03:41:54 Anyone ever done a custom kernel install on an android system before? Apr 24 03:42:44 sceadwian wrong channel Apr 24 03:43:15 What a decent one for it? Apr 24 03:44:05 What's a decent channel you'd suggest is what I meant. Apr 24 03:47:31 sceadwian android-root maybe Apr 24 03:48:56 that make sense =) Apr 24 03:49:10 Been so long since I've been on the IRC, feel like I'm 18 again =O Apr 24 04:09:50 Hmmm. Is it not possible to use subdirs to organize your drawables in an android project? Apr 24 04:10:00 for example drawable/status_icons/ Apr 24 04:10:34 it seems they are no longer found when I move them Apr 24 04:13:10 rowan7 not without some hacks Apr 24 04:13:41 which probably aren't worth the trouble Apr 24 04:20:40 g00s, OK. I'll make due. Thanks Apr 24 05:29:14 Is api level 10 a reasonable target if you're concerned with supporting most devices? Apr 24 05:36:51 thanks Apr 24 05:39:38 cipher__, Are you using android studio? Apr 24 05:39:48 rowan7, no. Apr 24 05:40:50 Ah, what are you using? Apr 24 05:42:33 rowan7, CLI build tools and vim, mostly. Apr 24 05:42:51 adb with an actual device Apr 24 05:42:55 That is a painful way to do it. haha. but to each their own Apr 24 05:43:21 rowan7, well, I don't find it any slower than using android studio tbh. Apr 24 05:43:29 api 10 is plenty to get "most devices" Apr 24 05:43:36 infact it gets almost all of them Apr 24 05:43:55 just google your question and you can see the market share below 10 is tiny Apr 24 05:44:12 rowan7, thanks. I'll target 10. Apr 24 05:46:23 cipher__, http://developer.android.com/about/dashboards/index.html Apr 24 05:46:47 <****> 8=100%, 10=100%, 15=97%, 16=95%, 17=87%, 18=77%, 19=74%, 21=40%, 22=24%, 23=5% Apr 24 05:47:01 you should target API 16 or above Apr 24 06:35:13 hello Apr 24 06:35:54 ohai Apr 24 06:44:34 i want to talk about a feature that would encrypt contact lists, text messages, emails, etc, when the screen lock goes up, and uses the lock password to decrypt. whole phone encryption doesn't protect data while the phone is in normal use Apr 24 06:45:31 i have enough knowledge to make the patch myself, unless it already exists. i'm curious if this has already been done, or whether it is practical Apr 24 08:40:19 any idea on why event.getSource(); return null? Apr 24 08:40:27 in accessibilityservice Apr 24 08:47:29 skin1980: some more information will get you a long way Apr 24 08:49:08 ok, i have and accessibility service and want to perform an action, BTW when i call in onAccessibilityEvent the event.getsource() it always return null Apr 24 08:49:44 Should i add something in OnServiceConnected? Apr 24 08:53:34 thepoosh: BTW thanks for your interest Apr 24 08:53:50 https://android.googlesource.com/platform/frameworks/base/+/refs/heads/master/core/java/android/view/accessibility/AccessibilityRecord.java#167 Apr 24 09:01:57 thepoosh: thanks but i don't undertstand whats wrong Apr 24 09:02:05 can u take a look pls http://pastebin.com/6H7m1byV Apr 24 09:02:14 i never dealt with this Apr 24 09:02:26 but it seems like your source node is null Apr 24 09:02:40 i understood that Apr 24 09:02:49 i don't understand why Apr 24 09:02:59 neither do I Apr 24 09:03:05 sorry, try stackoverflow Apr 24 09:04:13 ok thanks again Apr 24 09:04:59 1st link in google, does it help? https://stackoverflow.com/questions/33509285/accessibilitynodeinfo-nodeinfo-event-getsource-always-returns-null Apr 24 09:06:45 Ashiren: time for your [solved by...] post Apr 24 09:08:08 but is it solved? Apr 24 09:08:57 solved my issue Apr 24 09:10:53 good for you Apr 24 10:18:10 hey guys, if i wanted to inject some mock network dependencies for testing purposes would that be better done as a build type or product flavor? (or some other way)? Apr 24 10:23:54 i have a service that runs a thread every time for some jobs. the thread make some notifictions, i want to pass ContentIntent to notification so if user clicked the notification the main activity shows up. but i don't know how to do this! Apr 24 10:29:23 ehsanv: check out PendingIntents Apr 24 10:45:55 so... if I'm thinking of making a GLES-based game, would it be stupid to do this in pure Java? Apr 24 11:52:57 not at all, but try libGDX - it has some good utilities that'd speed things up for you Apr 24 12:33:09 hey Apr 24 12:33:25 how can I find out what keywords people search for when finding my app? Apr 24 12:33:28 I have no idea :O Apr 24 12:44:33 checking out the new emulator after a while of genymotion. how can i get the playstore on the emulator? my app uses google play games library Apr 24 12:52:56 Ashiren: and thepoosh tnx guys solved Apr 24 12:53:10 cool Apr 24 12:53:26 i missed some flags in service xml Apr 24 12:59:40 xorgate: https://stackoverflow.com/questions/20121883/how-to-install-google-play-services-in-a-genymotion-vm-with-no-drag-and-drop-su Apr 24 13:00:08 Ashiren: i mean getting it into the google emulator, not genymotion Apr 24 13:00:33 ah Apr 24 13:03:34 xorgate: you need to use the google play services emulator Apr 24 13:03:51 http://stackoverflow.com/a/11339755/1056359 Apr 24 13:03:57 my highest voted answer Apr 24 13:10:10 wlel i make an emulator with google apis on it Apr 24 13:10:21 but there's no play store on it Apr 24 13:41:54 within a service can i get the actual statusbar color? Apr 24 13:49:11 What do you mean by "get"? Apr 24 13:51:45 i want read the color of the statusbar barq Apr 24 14:45:56 I am not a developer of this app, but I have an app that, when I press the menu key, it's menu appears off screen. I am on the Android N Developer Preview, so that may be part of it. Is there anything short of recoding the app that can help get it back on screen? Apr 24 14:47:10 noahmg123: nothing you can do Apr 24 14:48:25 Napalm: thanks. I thought I could maybe do some stuff in the developer settings, but I also knew it probably would not be possible Apr 24 14:48:38 Hi, suppose I have an 2 activities, A and B, A loads some data and shows in GridView. On any item's click B is launched showing detail view of that item, with a button to bookmark it. Now if user bookmarks and presses back, what's a good way to update the said change activity A? Apr 24 14:53:19 onResume of A, reaload data Apr 24 14:53:25 Every time Apr 24 14:54:18 endofspacetime: would that work for you Apr 24 14:55:38 Isn't that too much work? What if user keeps clicking item and them clicking back, its a lot of unnecessady network request Apr 24 14:56:47 Oh I didnt realize it required a network request Apr 24 14:57:46 Gridview shows a bunch of Objects, the object has an isBookmarked member field Apr 24 14:58:13 When bookmarked, update that local object, then in onresume, check if any new local objects have isBookmarked set to true, then show it Apr 24 14:58:31 Then, if any new bookmarks, make a network request to sync it up Apr 24 14:59:19 endofspacetime: use startActivityForResult Apr 24 15:01:03 Can I use Tasker or a Terminal Emulator app to launch an activity? I found a tutorial but it did not work. Apr 24 15:01:41 endofspacetime: Activity A starts Activity B using startActivityForResult with a requestCode... Activity B uses setResult(RESULT_OK, data).. to hand data back to Activity A in onActivityResult() check requestCode is same and resultCode == RESULT_OK and then use data to update your local copy. Apr 24 15:02:30 noahmg123: yes, use the "am" command or an intent-url Apr 24 15:03:46 Napalm: am resulted in a permission denial. How would I do the second thing you mentioned? Apr 24 15:03:49 Napalm: Oo nice, didn't know about startActivityForResult. Thanks. Apr 24 15:22:30 I am implementing a TCP Client into my Android app. in my MainActivity I have a textview which shows the connection status of the client to the server. How can I set this textview from within the tcpclient class? Apr 24 15:22:46 or where would be the best way to set this? Apr 24 15:23:36 this is the tcpclient class http://pastebin.com/ReCwbBac Apr 24 15:25:01 is this in thread Apr 24 15:26:46 it will then jump to Log.v("TCP", "C: Error", e); Apr 24 15:26:54 and tell me this: Only the original thread that created a view hierarchy can touch its views. Apr 24 15:27:15 any network stuff should be in background thread Apr 24 15:27:51 to update UI use handler or activity's runOnUiThread Apr 24 15:28:03 this is my mainactivity http://pastebin.com/1HBv6CVH Apr 24 15:28:19 I tried runOnUiThread but tcpClient is a simple class Apr 24 15:28:29 runOnUiThread doesnt exist Apr 24 15:28:59 o.O Apr 24 15:29:12 it should Apr 24 15:29:48 so use handler Apr 24 15:30:11 more important, AsyncTask shouldnt be activity's inner class Apr 24 15:30:16 cannot find symbol method runOnUiThread() Apr 24 15:30:22 in tcpClient.java Apr 24 15:30:43 ... Apr 24 15:31:22 eh sorry, this isnt my code, just trying to make it work Apr 24 15:31:39 you basically want to change textView in OnMessageReceived :? Apr 24 15:32:39 well lets say I press connect, on bluetooth I would receive ACTION_ACL_CONNECTED and I could set the status there Apr 24 15:33:00 but using TCP I dont really get an acknowledgement when someone has been connected or disconnected Apr 24 15:33:12 so Im not sure where to set connected and disconnected Apr 24 15:33:30 I want to press connect, the client will connect to the server, and the status should then be set to connected Apr 24 15:33:47 make interface/listener for status onStatusChanged, make activity implement that in which you could use runOnUiThread or handler Apr 24 15:33:53 if I press disconnected or there is something wrong with the tcp socket making the client disconnect, then set status to disconnect Apr 24 15:34:01 then TcpClient would have setter/getter to the listener Apr 24 15:34:38 everytime something happens, just call mListener.onStatusChanged Apr 24 15:35:13 hmm ok I will try Apr 24 15:35:14 thanks Apr 24 15:36:54 Hmm, i guess this is the right place to ask instead of the android-root channel Apr 24 15:37:22 So, I am trying to compile my first kernel from source but I only end up having this error: Apr 24 15:37:33 Make sure target file is defined. Check the TARGET and GPU configs in Makefile and Kernel Config. Apr 24 15:37:42 I followed what the readme file says tho Apr 24 15:37:46 actually ROM specific things is for #android-root Apr 24 15:38:51 oh.. Apr 24 15:39:40 hmm...why isnt there a standard listener for this like with buttons? :( Apr 24 15:43:38 Ashiren could you point me in the right direction? never done listeners Apr 24 15:52:45 Bavilo: umm, then start with java tutorials >.> Apr 24 15:52:54 java interfaces Apr 24 15:58:26 :\ sadly no one can reply to me on android-root regarding my question. Apr 24 16:02:57 hahaha Apr 24 16:29:00 g00s: bacon pancakes! making bacon pancakes!! Apr 24 16:29:23 wyoung ! awesome .. Apr 24 16:31:04 jake is that you? Apr 24 16:31:17 Hahaha: :) Apr 24 16:32:13 “ Apr 24 16:32:13 Shmow-zow! Apr 24 16:32:21 g00s: bacon pancakes! making bacon pancakes!! take some bacon and put it in a pancake! bacon pancakes! that's what it's gunna make!! Apr 24 16:33:24 g00s: https://www.youtube.com/watch?v=ZVImfBMvXzE Apr 24 16:36:21 I use this code as base for my app, and addded a listview in the HomeFragment, and I have this code to get some nearbyusers, but how do I do so It loads the navigation menu at the side and top menu, to a new fragment a (UserProfileFragment) ? Apr 24 16:36:58 this code as base : http://www.androidhive.info/2015/04/android-getting-started-with-material-design/ forgot to add that link :) Apr 24 16:38:51 So if I have a list A, and that list has a set adapter, it stores a reference to that adapter right Apr 24 16:39:16 So if I also store refreence to that adapter in a different class, and update the data in it, the adapter attached to the list should be updated Apr 24 16:39:20 Since they ref the same item Apr 24 16:39:22 yeah just a sec ill paste it Apr 24 16:39:52 Jonathan-: I was asking a seperate question Apr 24 16:40:15 But go ahead Apr 24 16:40:33 http://paste.ofcode.org/9UNS2wjZYPBaCxBPvT5ZYR Apr 24 16:40:50 BACON PANCAKES!!!!!!11 Apr 24 16:43:36 drose379: so should I load it with Intent or? Apr 24 16:45:15 1 sec Jonathan- Apr 24 16:45:30 I also think I forgot the other link with my source from my HomeFragment: http://paste.ofcode.org/396suQNxXNvwJXNiR5AchqB Apr 24 16:46:36 drose379: okay :) Apr 24 17:03:26 if you do an addGeofences, with say 1 geofence, and before it had 5. will the previous ones be deleted? Apr 24 17:03:36 or do they stay until a deleteGeofences is called? Apr 24 17:05:18 kolobyte look at the sources ! Apr 24 17:08:42 g00s: seems that's my only choice. also tested it right now and it seems to add a new geofence, and not delete the others Apr 24 17:11:48 other question: is the best way to clear geofences to just restart the phone? Apr 24 17:31:57 hi, to track view's dimensions, it's ok to use view.onsizechanged? Apr 24 17:33:55 or is there any known source I could see for an application that deals properly with views? Apr 24 17:58:48 hi Apr 24 18:23:04 hey guys, i have a nested hashmap , which has about 1800 entries Apr 24 18:23:18 what kind of storage would you suggest Apr 24 18:23:21 suggest* Apr 24 18:24:29 anybody there? Apr 24 18:26:34 nady_007: ehm, sqlite is the easiest solution Apr 24 18:28:31 hashmap> Apr 24 18:28:38 this is the structre Apr 24 18:28:51 i need to pass the arraylist to views Apr 24 18:29:04 have no idea how to implement in sql Apr 24 18:29:13 any suggestions? Apr 24 18:29:15 nady_007: it depends on what you actually want to do, do you want to persist it? Apr 24 18:29:31 yes Apr 24 18:29:43 nady_007: you could just as well use some wrapper around sqlite that gives you an object oriented API Apr 24 18:29:54 nady_007: but it's easier to just do it manually Apr 24 18:30:17 could you point me to code samples? Apr 24 18:30:25 i 'm kind of new to everything Apr 24 18:30:34 http://developer.android.com/training/basics/data-storage/databases.html Apr 24 18:31:42 nady_007: the schema you need isn't complex, you could even trade simplicity for performance, since you only have 1800 rows anyway Apr 24 18:32:16 it's not like that Apr 24 18:32:28 i have five hierachy of navigation Apr 24 18:33:07 each click reduces hierarchy Apr 24 18:33:25 and dataset Apr 24 18:33:52 well, your HashMap> maps to quite a simple SQL schema Apr 24 18:36:14 nady_007: but I mean, depending on your needs you could just as well chuck it in a json file Apr 24 18:36:49 Is it possible to change a Spinner's drop-down animation? I've tried for hours -- everything I can think of (mainly things like setting `android:popupAnimationStyle` for the Spinner's `popupTheme`) -- and nothing changes the animation. Apr 24 18:37:05 Marshmallow's new drop-down animation makes my app-bar spinner feel slow. Apr 24 18:37:26 People on SO seem to think it's not possible. Apr 24 18:37:45 Not liking the idea of writing my own Spinner replacement. Apr 24 18:38:12 Does anyone know whether Android N bottom tab bar pattern will be/is already implemented in the design library? Apr 24 18:40:33 Maurits- probably show up some time next year Apr 24 18:40:42 hey TacticalJoke Apr 24 18:40:45 Hey, g00s. Apr 24 18:41:39 Actually, I guess the worst-case scenario would be writing my own Widget.Material.Spinner clone. Apr 24 18:42:23 TacticalJoke i think spinner does some nasty stuff figuring out where to anchor the view ... Apr 24 18:42:28 Ugh, I am lazy with Android lately. Way less motivated to spend seven hours tracking through framework source. Apr 24 18:42:33 not something i'd volunteer for :) Apr 24 18:42:43 Yeah, I was looking at Spinner.java and PopupWindow.java a lot. It doesn't look nice. Apr 24 18:43:11 one time, i tried putting a Spinner in a PopupWindow ... Apr 24 18:43:20 that didn't work out, lots of crappy abstractions Apr 24 18:43:24 special cases, one offs ... Apr 24 18:44:47 The kinda thing that makes people wake at 3am in terror. Apr 24 18:45:45 TacticalJoke: is that all spinners or just inside the toolbar? Apr 24 18:45:57 TacticalJoke the guy on coding horror is an android dev :) http://blog.codinghorror.com/assets/images/codinghorror-app-icon.png?v=0f1282ae51 Apr 24 18:45:59 my spinners don't animate in Marshmallow Apr 24 18:47:51 I don't use Toolbar or Actionbar, I made my own Toolbar with linear layout and put normal spinner in there Apr 24 18:48:08 lol Apr 24 18:48:20 shmooz well i bet that works back to froyo just nicely :) Apr 24 18:48:31 it works back to cupcake Apr 24 18:48:39 ill make toolbar with blackjack and hookers Apr 24 18:48:42 or ofrget the blackjack Apr 24 18:48:44 does anyone here use GitLab-CI? Apr 24 18:48:49 shmooz: All Spinners. Apr 24 18:48:57 shmooz: I recently set `minSdkVersion` to 21. :D Apr 24 18:49:19 Gawd, I hate when simple stuff is so complex (or impossible). Apr 24 18:50:20 g00s: I kinda dislike how he took that image from Code Complete. Apr 24 18:52:02 does anyone here use GitLab-CI, if so, how did you set up your gitlab-ci.yml and the Gitlab runner? Apr 24 18:52:02 If you Ctrl+F "what is the" on http://blog.codinghorror.com/about-me/, it'll be obvious what I mean. Apr 24 18:53:59 anyone tried running python on android? and installing modules? Apr 24 19:02:29 TacticalJoke you did minsdk 21 ? \o/ Apr 24 19:02:46 Yeah. Apr 24 19:03:09 Lets say im loading pages of data, I want picasso to start loading all of the images for that page even though they aren't on the screen. Apr 24 19:03:14 How can I achieve this? Apr 24 19:03:56 g00s: I decided that life was too short to care about <21. Apr 24 19:04:40 i'm sure sdk 21 will be the new kitkat soon enough Apr 24 19:05:24 It'd be handy if `minSdkVersion 23` were more feasible. A few useful attributes were introduced there. Apr 24 19:06:01 it will be feasible in about 2-3 years TacticalJoke :) Apr 24 19:06:48 thank you @Maurits.. Apr 24 19:07:05 g00s: Are you on 19? Apr 24 19:07:10 I was on 16. Apr 24 19:07:28 yeah 19, keep thinking i should go to 21 Apr 24 19:07:44 Have you released it yet? Apr 24 19:07:47 no Apr 24 19:08:08 Hmm, I guess it's tricky to justify `minSdkVersion 21` if you're looking to make money from it. Apr 24 19:08:15 TacticalJoke i'm also quite disinterested and find it hard to get motivated Apr 24 19:08:22 Yeah, I'm like that lately. Apr 24 19:10:09 I've been spending most of my free time pwning n00bs in chess lately. And getting pwned by lucky people. :D Apr 24 19:11:45 Just kidding; I'm terrible. Apr 24 19:11:54 Anyway, I gotta run. Have fun. Apr 24 20:34:34 anyone familiar with rxjava? Apr 24 20:34:39 i just started using it Apr 24 20:34:49 i created an observable and subscriber Apr 24 20:34:56 it now runs once as soon as i open my app Apr 24 20:35:06 how can i run the code multiple times? Apr 24 20:35:34 That's a very generic question :) Apr 24 20:36:32 yeah sorry, this is my observable http://pastebin.com/HnyHJvqZ Apr 24 20:36:37 and ill get my subscriber Apr 24 20:37:15 and this is my subscription Apr 24 20:37:16 http://pastebin.com/ruLevNV6 Apr 24 20:37:27 i think ive used it correctly so far Apr 24 20:37:40 Ugh. Apr 24 20:37:41 it all works, and the observable runs when i open my app Apr 24 20:37:55 Why are you catching the exception? Apr 24 20:37:59 but i what if i want to getData() later on? Apr 24 20:38:07 Just subscribe again. Apr 24 20:38:07 So i can see the error in the log cat? Apr 24 20:38:32 Just how are you going to see the error in logcat if you're silently eating it? Apr 24 20:38:41 Instead of letting RxJava properly propagate it. Apr 24 20:38:52 It goes against the point of RxJava and will make your debugging hell :) Apr 24 20:39:09 Wait I did Log.e. I thought that puts it in logcat? Apr 24 20:40:10 There's no Log.e in your code. Apr 24 20:40:33 Also it doesn't matter because you're still throwing away one of the most significant benefits of rxjava. Apr 24 20:40:47 So I have to create a new subscription every time I want to do getData()? Apr 24 20:40:59 For cold observables yes. Apr 24 20:41:42 How do I keep track of them all? Apr 24 20:41:53 So i can unsbscribe them if I need to? Apr 24 20:44:30 Also what is the benefit I am missing out? Apr 24 20:44:48 RxJava error handling Apr 24 20:45:00 And giving yourselves headaches by propagating nulls through chains Apr 24 20:46:29 Ah yeah I changed that Apr 24 20:46:54 Its a bit messy I'm just trying to understand rxjava Apr 24 20:47:17 Don't think im getting it Apr 24 20:47:28 It seems like a lot more effort compared to AsyncTask Apr 24 20:48:42 Hmm, RxJava isn't just a replacement for AsyncTask :/ Apr 24 20:49:06 Did you see the original Netflix talk? Apr 24 20:49:08 People recommended it Apr 24 20:49:36 No ive not seen it, i get the advantages of it Apr 24 20:49:40 Mavrik, do you have a link? Apr 24 20:51:28 Umm, don't remember the exact title. I think it's this one, but might be wrong: https://www.youtube.com/watch?v=_t06LRX0DV0 Apr 24 20:58:48 I have a button in my app that will execute my getData() method Apr 24 20:59:02 so i will need to create a new subscription in onClick Apr 24 20:59:13 but i need to manage lifecycle so they don't leak Apr 24 21:00:02 should i hold an array of all my subscriptions and then make sure they're all unsubscribed in onDetach? Apr 24 21:00:06 does that sound dumb? Apr 24 21:00:16 or is that okay? Apr 24 21:01:55 AKK9, there'a CompositeSubscription class for that Apr 24 21:02:02 you add your subscriptions to it Apr 24 21:02:11 and when you call unsubscribe it'll unsubscribe all of them Apr 24 21:02:21 There's also RxLifecycle that helps Apr 24 21:07:06 Mavrik: noice thanks Apr 24 21:07:08 Im still not sure if I fully understand when an object is eligable for GC in the dalvik vm Apr 24 21:07:17 Is there a simple answer? Apr 24 21:07:26 drose379, same as in any other GC language. Apr 24 21:07:30 When it has no references to it. Apr 24 21:07:49 So what if A references B Apr 24 21:07:52 when it is not reachable from a GC root Apr 24 21:08:06 So as long as A is alive, B will be alive too Apr 24 21:08:17 so object graphs that have cycles, but are not reachable are all eligible Apr 24 21:08:30 So activity A, object B Apr 24 21:08:34 drose379, if A is referenced from somewhere else. Apr 24 21:08:41 So how about this: Apr 24 21:08:46 Activity A, Object B Apr 24 21:08:49 B references A Apr 24 21:09:03 Yes? Apr 24 21:09:06 onStop in A is called Apr 24 21:09:13 A is set to null in B Apr 24 21:09:23 A is now eligable Apr 24 21:09:27 Is it? Apr 24 21:09:31 onStop() changes nothing. Apr 24 21:09:35 It's just a method. Apr 24 21:09:38 Im just saying what I did in onStop Apr 24 21:09:49 I set B's reference to A to null, in onStop Apr 24 21:09:50 The question is only one - is A referenced by something? Apr 24 21:10:03 No, cause B's reference to A is set to null when its destroyed Apr 24 21:10:03 Does the reference chain end up at something that's still referenced from a root. Apr 24 21:10:31 Does what Im saying sound right? Apr 24 21:11:13 Nothing references A, so its eligable Apr 24 21:11:22 Nothing references B, so its eligable Apr 24 21:11:27 So, both gone, as we want Apr 24 21:11:51 It's not about "nothing" referencing something. Apr 24 21:12:07 It's about not having *live* (referenced) objects referencing it. Apr 24 21:12:10 I thought something is eligable when nothing references it Apr 24 21:12:11 It's a tree. Apr 24 21:12:19 You can cut off a whole branch of objects. Apr 24 21:12:49 But yes, if nothing references an object, it'll get collected eventually. Apr 24 21:12:55 Maybe if I put this into comtext itll be easier to explain my situation / ask about? Apr 24 21:13:09 I guess. Apr 24 21:13:17 Its for MVP, Apr 24 21:13:22 I have Activity A, and Presenter B Apr 24 21:13:40 in onStop of A, is call _presenter.disconnect(), which sets the reference to A in the presenter to a NullView Apr 24 21:13:44 So A is eligable Apr 24 21:13:46 It'https://blogs.msdn.microsoft.com/abhinaba/2009/01/30/back-to-basics-mark-and-sweep-garbage-collection/ Apr 24 21:14:00 drose379, why would A be eligible? Apr 24 21:14:09 Are you sure presenter is THE ONLY reference? Apr 24 21:14:10 Because Presenter does not reference it anymore Apr 24 21:14:19 Yes Apr 24 21:14:20 Android after all keeps references to activities as well. Apr 24 21:14:34 Well, I personally am not going to leak it Apr 24 21:14:41 ok. Apr 24 21:14:44 If android is holding ref to it thats a dif store Apr 24 21:14:46 story* Apr 24 21:14:47 That's true. Apr 24 21:14:57 Ok, sweet Apr 24 21:15:04 So at least my path of thinking is correct Apr 24 21:15:10 With disconnecting the presenter Apr 24 21:17:05 Thanks for the help Mavrik Apr 24 21:19:33 Mavrik did that new Agera library have any redeeming qualities? Apr 24 21:19:56 It uses Android async constructs and it's significantly lighter than RxJava Apr 24 21:20:19 It's also slower and doesn't have operators so it's more of an async library than a functional stream processor. Apr 24 21:20:37 (Which seems to me to be the overkill part of RxJava as well. Operators need cleanup badly.) Apr 24 21:22:32 But yeah, pass :) Apr 24 21:22:42 :) Apr 24 21:26:22 What is the use of the Filterable interface? Apr 24 21:26:28 Bit confused about how it works Apr 24 21:26:44 Can i use databinding to bind to an interface? Apr 24 21:26:50 I tracked down the source of my Spinner-animation problem. It's exactly what my first instinct was: https://android.googlesource.com/platform/frameworks/base/+/master/core/java/android/widget/PopupWindow.java#255 Apr 24 21:27:25 What I don't understand is why `android:popupExitTransition` isn't available. What determines which attrs are private? In the framework attrs.xml, there's no difference between the public and private ones. Apr 24 21:28:37 The attrs is at https://android.googlesource.com/platform/frameworks/base/+/HEAD/core/res/res/values/attrs.xml#4531, but it's not in the "R.attrs" HTML page. Apr 24 21:28:45 attr* Apr 24 21:30:36 drose379: There are many uses of that interface. You'll have to ask a more specific question. Apr 24 21:31:00 I think I got it now, im using it for an AutoCompleteTextView adapter Apr 24 21:31:18 So it has to filter the first few letters of each word to show the correct options Apr 24 21:33:20 Ok for some reason I cant find Filter.FilterResults Apr 24 21:34:01 nvm Apr 24 21:34:46 the filterable interface just says that the implementing class can give you a Filter object with which you can make it return a subset of it's data based on a string criterium Apr 24 21:34:55 Right Apr 24 21:37:19 Thanks guys Apr 24 21:38:07 Should my filterable class store a list of items it is filtering through? Apr 24 21:38:09 I think yes? Apr 24 21:39:20 You need to consider that you need to be able to return the original data set if the filter is cleared Apr 24 21:39:54 I store that in the adapter Apr 24 21:40:55 the original adapter data will be replaced by your filtered data though, won't it? Apr 24 21:41:04 so you have to store the original and the filtered results Apr 24 21:41:15 Ah I see, ok Apr 24 21:41:33 Thanks Apr 24 21:52:12 how do I detect a sudden change in direction of swipe? Apr 24 21:52:59 what actual algorithm is behind swipe keys method of input anyways? Apr 24 21:54:51 is it just some algorithm that measures how long your finger exists over a button? Apr 24 21:56:17 swipe keys seems to take the brute force approach. Apr 24 21:56:37 whatever letters your finger went over is a potential letter in a word Apr 24 21:57:25 if it's not in the dictionary it won't suggest the word Apr 24 22:01:04 hrm i guess swipe vectors are not a realistic thing yet Apr 24 22:01:11 oh well. i'll roll my own Apr 24 22:01:32 it's going to have to work on the web to where mousdown + move is the same as swip Apr 24 22:11:01 hrm if i want to enter something that's not a real (yet) word like my name, it won't do it Apr 24 22:18:03 I can solve my Spinner issue using reflection (getting the inner PopupWindow instance and calling set(Enter|Exit)Transition). But it's such a horrible hack. Apr 24 22:19:05 Also, the complete lack of transition looks a bit weird. Apr 24 22:19:41 I guess I could set a faster transition. Still a horrible hack. Apr 24 23:00:41 Can anyone assist me in refreshing AsyncTask on a GCM push notification? Apr 24 23:02:32 zduffy: What are you trying to do? Apr 24 23:05:55 mentazoom: I have a JSON array I pull from a GET request, and would like the array updated when a GCM push notification gets recieved Apr 24 23:06:13 Im coming from an iOS/PHP background sorry Apr 24 23:09:08 Heres my doInBackground: http://pastebin.com/HSAKqGMh Apr 24 23:18:09 zduffy: i'm not pro by any means, but can't you just call asynctask at onMessageReceived? Apr 24 23:20:01 mentazoom: that sounds reasonable. Would I call the same asynctask that I have in my onCreate? Apr 24 23:20:13 Im calling new GetData(this).execute(); which is a class of asynctask Apr 24 23:20:41 yes and if it's a recyclerview you would need to update it too Apr 24 23:24:11 I'm trying to set up certificate pinning to connect to a service with a self-signed certificate. Rather than get the expected exception: javax.net.ssl.SSLPeerUnverifiedException: Certificate pinning failure! Apr 24 23:24:23 mentazoom: I have several activities, how would it know which one to push the data to? Apr 24 23:24:26 I'm instead getting this one: java.security.cert.CertPathValidatorException: Trust anchor for certification path not found. Apr 24 23:24:35 what am I doing wrong? Apr 24 23:25:48 kommunicate: try this? http://stackoverflow.com/questions/2642777/trusting-all-certificates-using-httpclient-over-https/6378872#6378872 Apr 24 23:28:29 zduffy: I'm little confused, if you do the right GET request then the right activity will have the right data Apr 24 23:29:27 mentazoom: I understand that. Can onMessageReceived be called in the activity I need the data to be on? Apr 24 23:32:14 no you can't call it by yourself Apr 24 23:32:49 zduffy: this is one of the sites I've been looking at -- the issue I had with that is that the SSLSocketFactory bits of code are now deprecated Apr 24 23:33:09 also seems a bit like I shouldn't have to set up a keystore if I'm pinning the certificate directly Apr 24 23:34:39 mentazoom: so something like this? public void onMessageReceived(String from, Bundle data) { new GetData(this).execute(); } Apr 24 23:35:06 yes Apr 24 23:36:15 try and see if it works Apr 24 23:36:52 mentazoom: I really appreciate your help. If this works I will buy you a coffee :) Apr 24 23:37:30 kommunicate: It appears this would be the only viable method, but I am probably wrong Apr 25 00:57:31 i'd like to write an app for both android and ios. i'm hoping to build the core app in c++ libraries and interface in the native language. is it recommended in android to interface with the c++ using jni or jna? Apr 25 00:58:24 Moult app or game? Apr 25 01:00:06 jug6ernaut: game, but not graphically intensive Apr 25 01:01:27 Moult i would say jni, i have never heard of jna tbh, but jni is definitely officially supported Apr 25 01:03:09 jug6ernaut: apparently jna is a less painful wrapper of jni in exchange for more call overhead Apr 25 01:03:25 jug6ernaut: but out of curiosity, why did you ask app or game? is the overhead really that large? Apr 25 01:03:48 no, just if your not doing a game i would say just develop standalone apps on both sides Apr 25 01:04:18 & the jni binding isnt complicated Apr 25 01:06:02 jug6ernaut: good point. yes, if i were doing an app, i'd say the local logic would be relatively simple, or i'd do a client+server api solution instead. Apr 25 01:06:10 jug6ernaut: ok, i'll do some homework and see how to use jni :) Apr 25 01:06:44 its gotten a lot easier lately now to with AS Apr 25 01:06:54 last time i did jni with android was in the eclipse days Apr 25 01:20:08 In case anyone knows the answer, I asked about the spinner thing on SO: http://stackoverflow.com/questions/36830566/why-cant-i-reference-the-attr-androidpopupentertransition Apr 25 01:20:38 I'm guessing the answer is something like "Because it's an implementation detail of Spinner", but I'm not sure about that. Apr 25 01:28:57 can I leverage google now's voice to text? Apr 25 01:29:39 Actually, the other PopupWindow stuff (e.g., the R.styleable stuff and some R.attr stuff) isn't private, so the "implementation detail" thing doesn't seem right. Apr 25 01:29:54 e.g., `popupBackground`. Apr 25 02:18:04 So it seems, according to Ian Lake's answer, that any framework attributes not in the R.attr documentation page are automatically considered private. Apr 25 02:25:37 TacticalJoke blogpost, startdate 107885673 Apr 25 02:26:03 captains logs :D Apr 25 02:26:10 Which blog post is that? Apr 25 02:26:19 funny thing is i almost never go to d.android.com any more Apr 25 02:26:29 google almost always as first hit takes mt to stack overflow Apr 25 02:27:07 Erm Apr 25 02:27:48 TacticalJoke the docs for attrs said 'needed improvement' like 5 years ago, they never improved it Apr 25 02:28:49 g00s: This is what I'm referring to: http://stackoverflow.com/questions/36830566/why-cant-i-reference-the-attr-androidpopupentertransition Apr 25 02:29:33 Hopefully they make those public. Then, I guess, I'll be able to fix this issue cleanly. Apr 25 02:30:15 TacticalJoke yeah annoying, some attrs for date time pickers are not public - so you can't theme them properly Apr 25 02:30:20 I kinda animations in general. They're all so slow and clunky. Apr 25 02:30:25 Yeah, it's obnoxious. Apr 25 02:30:31 kinda hate* Apr 25 02:30:44 I think some animations are well done, but most are just a pain. Apr 25 02:30:57 And the god-damn Spinner animations are making my lightning-fast app feel slow! Apr 25 02:31:00 In 23. Apr 25 02:31:22 They also interfere with ProgressBar animations. It's such a mess. Apr 25 02:31:47 The default activity-enter animation causes progress bars to stutter on opening (starting from 21). Apr 25 02:32:09 I had to disable secondary-activity animations when 21 hit, just so my ProgressBars wouldn't look ridiculous. Apr 25 02:32:56 TacticalJoke you know about public.xml right ? Apr 25 02:33:19 you guys are doing it wrong Apr 25 02:33:45 your minimum sdk should be 3 like mine Apr 25 02:34:03 Any recommendations for irc mobile apps? Apr 25 02:34:03 not 21! Apr 25 02:34:16 Ah, didn't know about that. Interesting. Apr 25 02:34:22 So that's what determines the publicness. Apr 25 02:34:54 TacticalJoke there is something similar for the support lib Apr 25 02:35:01 (but its not enforced atm) Apr 25 02:35:15 g00s: On that topic, I'm so glad I'm away from AppCompat. :D Apr 25 02:35:30 Android is a total mess in itself. Add AppCompat and it's mess upon mess. Apr 25 02:35:32 there is no escaping appcompat ! Apr 25 02:35:49 The only thing I'm missing, AFAIK, is day-night mode. Apr 25 02:36:00 Is there anything else? Apr 25 02:36:04 that fucking thing doesn't work right anyhow Apr 25 02:36:06 I mean AppCompat v7. Apr 25 02:36:21 Yeah, I remember reading your recent Reddit comment about that. Apr 25 02:36:47 my app has day and night, it was tricky to implement Apr 25 02:37:08 i think they should take all the android devs and re-assign them to other duties, they seem burned out and just in a rut Apr 25 02:37:55 then form a new team, assign the campus chef as leader. probably work out better Apr 25 02:38:08 I hope they nuke the whole thing and start over. Imagine how awesome and productive we could be with a whole new SDK. Apr 25 02:38:20 TacticalJoke like swing? hahaha Apr 25 02:38:23 Imagine if, instead of Activity and Fragment, we had something that was pure simplicity. Apr 25 02:38:47 plain old C with inline ASM like the good old days Apr 25 02:38:59 that's what I'd like Apr 25 02:39:29 I didn't enjoy high-level programming in C. :s Apr 25 02:39:32 that's what you needed to make things fast enough Apr 25 02:39:42 C++ was a freaking dog's dinner. Apr 25 02:40:08 shmooz yeah inline asm will work great for x86, arm, mips, and risc-v Apr 25 02:40:14 in the DOOM days C++ wasn't fast enough to make games Apr 25 02:40:24 Expert-programmer aliens would think (1) we are dumb and (2) we are irrational. Apr 25 02:40:40 shmooz yeah but today c++ is one of the goto languages for performance critical stuff Apr 25 02:40:43 And they would be correct. Apr 25 02:40:52 and c++ from doom days is quite different than c++ today Apr 25 02:41:20 if i only could know one language it would be c++ Apr 25 02:41:25 g00s: I would love if the Swift rumour were true. Let's start over. :D Apr 25 02:41:35 TacticalJoke would be nice :) Apr 25 02:42:06 I wouldn't mind if it was QT and C++ for both mobile and desktop multi platforms Apr 25 02:42:09 Even simple animations on Android are slow, even on high-end devices. The whole system feels bad.. Apr 25 02:42:10 .* Apr 25 02:43:42 shmooz: Does your app look at the time on app start and determine which theme to use? Apr 25 02:44:21 TacticalJoke: no, but it does have dark and light theme, so that wouldn't be hard to implement Apr 25 02:45:00 and I claim my app is the only media player that can change themes while playing media Apr 25 02:45:12 all others have to stop or exit and restart and shit Apr 25 02:45:38 How are you changing theme? Apr 25 02:45:46 Setting the colours manually? Apr 25 02:45:48 in settings the user can choose Apr 25 02:46:18 TacticalJoke: it's both manual and from xml Apr 25 02:47:06 I have to create different png's for the images Apr 25 02:47:28 If you joined the minSdkVersion 21 master race, you could use vector drawables. :D Apr 25 02:47:31 TacticalJoke honestly, if they started again, i don't think the end result would be better Apr 25 02:47:46 set colors on stuff that allow me in code Apr 25 02:47:48 i think the problem is a product of their culture Apr 25 02:47:50 g00s: I guess it'd be a bit better, but there'd still be awful stuff, yeah. Apr 25 02:49:39 shmooz should do it. It'd be the fastest mobile OS ever. :D Apr 25 02:51:13 I guess one problem is that doing a good job requires taking time. Today's culture seems to be about releasing bad stuff quickly. Apr 25 02:51:59 yeah apple is having sw quality issues too Apr 25 02:52:09 although, mostly bugs, their tech and apis seems pretty nice Apr 25 02:52:19 in other words, they still have taste Apr 25 02:57:39 This is interesting: https://android.googlesource.com/platform/frameworks/base/+/15d48a16f645509cb0c6a1f3abf52ddd233cd8b5 **** ENDING LOGGING AT Mon Apr 25 02:59:58 2016