**** BEGIN LOGGING AT Tue Mar 07 03:00:03 2017 Mar 07 03:19:21 what's the best way to set a default value for a PreferenceActivity programmatically? the default value will vary based on device... Mar 07 03:25:29 can one run API22 apps on a API25 tablet? or does one need to recompile for each api version? Mar 07 03:30:41 anybody? Mar 07 03:31:46 of course you can Mar 07 03:39:09 Thank you bankai_ Mar 07 04:19:29 SDK tools 25.3.1 is in the stable channel Mar 07 05:14:36 hi guys Mar 07 05:15:08 Does anyone know similar kinda https://github.com/alibaba/vlayout libraries for android ? Mar 07 05:38:35 Leeds the ant scripts have been removed in the latest sdk tools ! Mar 07 05:39:36 you're gonna have to go gradle at last :) Mar 07 05:39:55 or not upgrade.. Mar 07 05:42:24 lol Mar 07 05:43:13 ever... Mar 07 05:44:16 i hope you have good backups, its not like build-tools where you can go get older versions Mar 07 05:44:19 there's only one app I'm really doing anything on right now, and I've already converted that Mar 07 06:09:36 hm they broke out the emu into its own package Mar 07 08:12:00 hi, i am using fcm to generate notifications from one device to another device,the notifications are working when i create them using the firebase console but they are not coming when i generate them using another device. Mar 07 08:12:21 i am using server key for php backend Mar 07 08:12:33 but still no progress Mar 07 08:51:04 * raoul11 thepooshes thepoosh Mar 07 09:03:45 hi hi Mar 07 09:26:28 sup thepoosh Mar 07 09:27:19 raoul11: meh, been better Mar 07 09:27:29 por que Mar 07 09:27:38 thepoosh: beer app coming out nicely Mar 07 09:27:59 noice Mar 07 09:28:02 layouts? Mar 07 09:28:13 not yet, model so far Mar 07 09:28:34 thinkin bout the apiclient, whether to use it as a singleton or a service Mar 07 09:47:20 hey , I am trying to decide on a restful web service , which one is most popular for android Mar 07 09:47:25 any suggestions Mar 07 09:48:43 erm... that seems to be too vague a question to make sense... Mar 07 09:49:05 are you looking for hosting, or a server-side framework, or a client-side library, or... Mar 07 09:49:20 clientside Mar 07 09:49:42 so you're looking for an Android library for doing REST calls? Mar 07 09:50:26 yes , the one that is popular enough Mar 07 09:50:33 retrofit. Mar 07 09:51:09 thanks , I will have a look Mar 07 09:53:15 hi Leeds Mar 07 09:53:35 evening raoul11 Mar 07 11:02:12 I have a json object like so: https://gist.github.com/Syzygy2048/37242f94075b799bec85a7329c842dda is there a simple way to let this deserialize automatically without having to write custom deserializers? The JsonElement itself can be deserialized using gson.deserialize(jsonElement, SomeClass.class) Mar 07 11:05:32 Nevermind. I guess I just have to adjust my model accordingly. Mar 07 11:08:39 Nevermind the nevermind. The model already looks like this: https://gist.github.com/Syzygy2048/37242f94075b799bec85a7329c842dda Mar 07 12:00:35 How long does it usually take from publishing an app for the first time to it actually showing up on the google play store? Mar 07 12:00:47 couple of hours Mar 07 12:01:07 Ah, thanks Mar 07 12:02:01 could be even about 48 hours Mar 07 12:04:07 Hi all, I'm looking for some advice on my final year project. It's on the topic of Android security, more specifically I'll be looking at the security of custom ROMs vs stock ROMs and developing an app to test with. Mar 07 12:05:17 From what I can tell using custom ROMs on the sdk emulator is difficult and not very common (most support for it seems out of date). Does anyone here use the sdk emulator with custom ROMs? Mar 07 12:05:54 I have a json object like so: https://gist.github.com/Syzygy2048/37242f94075b799bec85a7329c842dda is there a simple way to let this deserialize automatically without having to write custom deserializers? The JsonElement itself can be deserialized using gson.deserialize(jsonElement, SomeClass.class), but the whole thing won't deserialize... Mar 07 12:24:52 Syzygy_, I don't see anything wrong with that Mar 07 12:26:42 Syzygy_, except if you're using gson then you should use @com.google.gson.annotations.SerializedName, not @com.fasterxml.jackson.annotation.JsonProperty Mar 07 12:27:23 that could be it. thanks, I'll try that. Mar 07 12:27:36 Syzygy_, why are you mixing jackson and gson anyway? -.- Mar 07 12:27:45 I refactored from android annotations to retrofit2 Mar 07 12:28:04 and am currently fixing everthing that does not work. e.g. that. Mar 07 12:29:56 before that it was a mix of old retrofit and AA... Mar 07 12:31:27 Seems like that was the cause, thank you. Mar 07 12:43:59 Does gson have something like jacksons @JsonSubTypes for polymorphism or do I need my own deserialyzer again? Mar 07 12:49:56 I have imported a project but get "Cannot resolve symbol" on some things like MarkerOptions, Marker, LatLng. I have downloaded Google Play Services on the SDK and have run clean and rebuild but it still doesn't work. What can I do? Mar 07 12:50:14 Syzygy_, it doesn't Mar 07 12:50:22 you need to add the libraries you want to your gradle file Mar 07 12:50:25 Zajt: Mar 07 12:50:50 tx: Well what library should I add there if I want google maps things? Mar 07 12:51:12 Zajt: https://developers.google.com/android/guides/setup Mar 07 12:51:22 pick and choose which services you will actually need Mar 07 12:51:26 for maps, com.google.android.gms:play-services-maps:10.2.0 Mar 07 12:51:52 if you are using location services too: com.google.android.gms:play-services-location:10.2.0 Mar 07 12:52:11 Zharf, alright, custom deserialyzer it is then. Mar 07 12:56:20 tx: I added the maps there, I had the play-services already but it didn't solve the problem :/ Mar 07 12:56:36 did you sync gradle? Mar 07 12:57:27 tx: yes and I have rebuilded again Mar 07 12:57:42 paste me your dependencies block Mar 07 12:57:47 on hastebin.com or whatever Mar 07 12:58:25 tx: http://pastebin.com/56VrMKG2 Mar 07 12:59:58 you're getting this problem in the IDE Mar 07 13:00:00 or during run-time Mar 07 13:00:20 in the IDE, it says "cannot resolve symbol MarkerOptions" for example Mar 07 13:00:26 Do you want to check through teamviewer? Mar 07 13:01:24 what happens if you highlight one of the red unknown classes (like MarkerOptions) in your code Mar 07 13:01:28 and press alt+enter Mar 07 13:01:34 does it ask you if you want to import it? Mar 07 13:02:23 tx: they are already imported Mar 07 13:02:39 how'd you manage to do that? copy and paste? :P Mar 07 13:02:45 or manually typed it in? Mar 07 13:03:32 also, lastly.. Mar 07 13:04:02 nah, I imported a project. No copy and paste Mar 07 13:04:10 it's weird Mar 07 13:04:48 do you want to check through teamviewer? Mar 07 13:04:57 I guess. Mar 07 13:26:23 I'm trying to make a transparent notification bar and hide the SupportActionBar. Hiding the SupportActionBar moves my whole layout up... not sure why. Can I avoid this? e.g. not using getSupportActionBar.hide() but instead something like setVisibility? Mar 07 13:26:57 I mean, it moves the layout up to far when I set FLAG_TRANSLUCENT_STATUS too Mar 07 13:31:59 if you use a translucent status bar Mar 07 13:32:09 it will move your layout up so that there is something behind the bar! Mar 07 13:32:12 makes sense yeah? Mar 07 13:32:51 what is it supposed to do when you remove it? Mar 07 13:32:56 display a void of nothingness? :p Mar 07 13:45:43 tx, it moxes it up too far, out of view Mar 07 13:45:49 moves Mar 07 13:46:06 but now found a better way to do it with setSystemUiVisibility Mar 07 13:46:30 which behaves as expectey Mar 07 13:46:34 anotheryou, if it moves your whole layout, it's probably because getSupportActionBar.hide() set its visibility to GONE instead of INVISIBLE Mar 07 13:46:37 expected.... sorry Mar 07 13:46:41 or remove it from the hierarchy Mar 07 13:47:31 the setSystemUiVisibility wroks nice now, just having problems setting everything back to normal :) but I guess I'll figure out the correct defaults Mar 07 13:47:41 either you have to make your toolbar transparent, or you have to provide a placeholder with the same size, or you have to simply toggle its visibility to INVISIBLE Mar 07 13:48:00 no, I want the layout to expand Mar 07 13:48:06 it just moved it twice or something Mar 07 13:48:13 it was quite a bit out of screen at the top Mar 07 13:50:24 heya, what solution would you guys use to persist data until it has been sent to a server? I need the data to persist over the lifetime of the app, amount of data is 18 bytes every 10-30 seconds Mar 07 13:50:52 erhm, I mean, the data needs to persist even if the app crashses Mar 07 13:55:37 luceat_adam, sharedpreference or a simple file you write or a database Mar 07 13:57:32 yeah, I'm leaning towards a database, maybe with a queue interface so I can peek and pop the head of the queue, question is though if there is any good and simple library to use rather than write it myself Mar 07 14:00:09 mayb try persisting in a service? Mar 07 14:05:50 raoul11 the persisting will happen in the service, but just in-memory persistence is not good enough in this case as services may be killed, battery run out etc Mar 07 14:07:06 when I return from fullscreen via setSystemUiVisibility(View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN) my actionbar is in overlay mode, why? Mar 07 14:08:15 i mean View.SYSTEM_UI_FLAG_FULLSCREEN, not the layout one Mar 07 14:44:15 Do anyone know what can be wrong if I get "cannot resolve symbol Them.appcompat.light" in styles.xml? Mar 07 14:49:22 anyone familiar with Android VectorDrawable XML? Mar 07 14:49:24 Is there an easy way to match or pair my Retrofit2 Call and Response? Mar 07 14:50:10 I can see there's call.getRequest().tag() but that Tag doesn't seem easy to set. Mar 07 14:51:12 benlue: you're making it by yourself? Mar 07 14:52:22 raoul11, how can i convert .png files to Android VectorDrawable XML Mar 07 14:52:39 well Mar 07 14:52:43 The thing is that I have this service interface Call> getImageUrls ( @Param("profileId") String profileId ); And if I fire multiple of these, I don't know which response goes to which profileId (because the response doesn't contain a profileId but only the List of Urls). Mar 07 14:52:43 thats the wrong way about it Mar 07 14:52:55 you want to convert svg file to vectordrawables Mar 07 14:53:09 png to svg will just look dirty Mar 07 14:53:39 if you do have axx to the svg, use this site: http://a-student.github.io/SvgToVectorDrawableConverter.Web/ or the built in converter Mar 07 14:53:44 raoul11: Do you know why I get cannot resolve symbol on these three: https://puu.sh/uyawp/3ce8d0df02.png ? I have restarted android studio, installed SDK's, rebuilt, tried many things Mar 07 14:53:48 and dump the contents insinde a drawable.xml Mar 07 14:54:31 Zajt did you import this project, or a fresh start? Mar 07 14:54:34 imported it Mar 07 14:54:38 from where? Mar 07 14:54:41 from git Mar 07 14:54:46 mayb its not AS compatible Mar 07 14:54:56 It would be cool if I could have this interface: Call> getImageUrls ( @Param("profileId") String profileId, @Tag String tag ); and then call service.getImageUrls(profileId, profileId) and the I could do onResponse( Call<> call, Response<> response ) { String profileId = call.getRequest().getTag(); ... Mar 07 14:54:59 built with some weird eclipse setup Mar 07 14:55:22 But ... it would be even better if our backend guy would return sufficient data... =) Mar 07 14:55:45 chain your response to the actual call Zta77 ? Mar 07 14:57:21 ahhh raoul11 thx for information. Quick and dirty, its recommend to create an svg file instead of png Mar 07 14:57:35 Zajt, more importantly, does it run? Mar 07 14:57:50 theres some converters of png to svg out there, but they all suck Mar 07 14:58:00 because I came across so many false positive with AS.. Mar 07 14:58:02 you'd be better off using a proper svg Mar 07 14:58:17 i solved it now adq Mar 07 14:58:20 and use that site i linked for the vectordrawable Mar 07 14:58:26 changed to an earlier classpath in build.gradle Mar 07 14:58:39 ok Mar 07 14:58:47 right now i got this one unresolved: http://imgur.com/a/ZQYzX Mar 07 14:58:48 :') Mar 07 14:58:53 of course it runs and works fine Mar 07 16:11:30 I want to make a color drawable with padding... I can use inset drawable to accomplish this but is there a way to do that before API 21? Mar 07 16:12:11 mmh Mar 07 16:14:17 hmm, I'm not sure if lint lied to me but it's not complaining about it being since API21 anymore Mar 07 16:20:20 greets Mar 07 16:31:22 damn.. so you're simply not getting a game or other apps done by being lazy. It's hard work, it's most likely a lot of art and it's testing and hard work? Mar 07 16:43:15 Hey guys, what can cause this error to happen? http://pastebin.com/M3mm39GD Tomorrow everything worked. It happens when i build and run the app from Android studio(Physical device as run device) Mar 07 16:46:21 But this is only happening if i am running from Studio. If i build a debug app and manually install it, it works. Seems to be a problem with the apk slices Mar 07 16:49:38 how is called the "title bar" in a app?, where is icon app, title and some buttons.... ? Mar 07 16:57:54 toolbar Mar 07 16:58:52 or formerly actionbar Mar 07 17:02:19 thank you Mar 07 17:20:09 I can't set a negative margin for overlapping, right? it will crop my element with the negative margin so it's not truely beneath what comes next Mar 07 17:42:09 hi all - desperate and out of my depth here - need help urgently and might need to do a screen share to articulate the issue - anyone know their way arounnd BLE & back ground services and just some good old Logic .. Mar 07 17:47:25 anyone ? Mar 07 17:49:24 No one wants to get involved without knowing the specifics. tl;dr ask a complete question Mar 07 17:49:52 Roughy: - OK - thanks - I will try - Mar 07 17:52:52 Create a stackoverflow post if the question is longer than a few lines Mar 07 17:53:01 So I have the BLE shower ( don't ask) I can' conneect to it use BLE services and Have to poll it every second to get feedback data from it (ex Did someone adjust temp on it manually) then adjust hte app UI accordingly. THats all fine - what I need to do is once I connect I want to 1st check if the shower is currently ON . If it is ON then send a specific message to the user -> and stop the interrogation 0 Mar 07 17:57:23 Your message might have been too long Mar 07 17:57:29 "and stop the interrogation 0" <- stops here Mar 07 17:59:57 It seems to be getting itself into a twist and I've tried adding a counter for each tik and saying IF counter ==0 n shower.IsAlreadyON but that worsk sometimes other times but I can't understand why its failing on others. - seesm like its todo with background services or timer ticks running awawy Mar 07 18:01:06 Anyone would probably have to have a look at the code to figure that out Mar 07 18:06:02 It's kind of impressive the degree to which the CIA ignored presidential directives with respect to not hoarding 0days for weaponization Mar 07 18:06:05 @#$@# Mar 07 18:06:12 How do Ihide and show Android Soft keyboard from an Accessibility Service? Mar 07 18:06:19 I hide* Mar 07 18:18:16 Roughy: yeah 0 I know - how can I facilitate that ? Mar 07 18:18:44 Dump the code in a repo, pastebin etc Mar 07 18:21:13 can we get BluetoothGattCharacteristic from BlueToothDevice Mar 07 18:28:10 Roughy: here's one attempth - I tried putting it in here - BUT line 14 is running if if the shower is off (ie: It should actually turn on ) Mar 07 18:28:14 http://pastebin.com/a6wgibZx Mar 07 18:31:33 Have you confirmed that showerValues.IsOff and interactionCount are the expected value? Mar 07 18:32:43 I can't really comment on the overall logic without the rest of the code, e.g. how interactionCount is being decremented and such Mar 07 18:32:43 Roughy: .IsOff yes - the counter seems to doing its own thing Mar 07 18:33:18 when do you intialize interactionCount Mar 07 18:34:00 on class instancte s73v3r as well as on teh start of the timer interaction Mar 07 18:34:16 what do you initialize it to? Mar 07 18:34:22 0 Mar 07 18:34:26 ok. Mar 07 18:34:39 and do you ever see it going into the else block? Mar 07 18:35:12 http://pastebin.com/FATej8ab line 7 and by mistake again in line 12 - Mar 07 18:36:39 s73v3r: Yes on the first ON then OFF (using the app) it worsk as expected - then I switch the shower ON manually while the app is OFF - its OK then if I ON..... OFF from the app it seems almost pot luck as to what happnens next - Mar 07 18:52:43 what is onCharacteristicChanged < in BLE - is it what is returned from devie ? Mar 07 19:38:45 the update to android studio screwed everything and now my resolution doesn't look right. I tried to delete everything from user/local/android-studio and do a clean reinstall but it's still looking the same Mar 07 19:38:54 is there another place android-studio stores files? Mar 07 19:39:08 what are you on? Mar 07 19:39:20 ubuntu Mar 07 19:39:55 I'll probably roll with it to see if itll work but the update failed miserably last time and it came back up looking messed up Mar 07 19:40:07 yet it still says it updated Mar 07 19:46:12 is there a translation of Display.getRotation to Activity.setRequestedOrientation? Mar 07 19:46:26 how hard would it be to make an app that graphs/visualises data from a sensor? Mar 07 19:46:58 like, a temperature/pressure/humidity sensor Mar 07 19:47:05 could a beginner do it? Mar 07 19:47:10 I want to temporarily lock screen orientation to the user's current configuration Mar 07 19:47:27 Enthralled, sure, not very difficult Mar 07 19:47:56 are there ready packeges for graphing stuff in android? Mar 07 19:48:03 or would i have to use some library Mar 07 19:48:16 library = ready package Mar 07 19:48:36 yeah, i meant like standard stuff already build into android SDK Mar 07 19:48:50 built* Mar 07 19:49:34 no Mar 07 19:50:13 ok, thanks pfn Mar 07 19:51:30 I guess just set orientation no-sensor and restoring the previous value Mar 07 19:56:26 My emulator has no sound. Is this affecting anyone else here? Mar 07 19:56:53 I can't say it bothers me at all. Mar 07 19:57:34 I don't really need it at the moment but if I decide to implement sounds into my app this is going to be an issue Mar 07 19:58:27 never noticed, never checked for sound on emulator Mar 07 19:59:34 I've had sound before, I know that much Mar 07 20:41:47 Hey guys, how can I get text string from a URL and display it in a textview? Mar 07 21:01:10 where are you getting it from? Mar 07 21:22:51 ugh, why do I keep getting RESULT_CANCELED when I do ACTION_GET_CONTENT and go to photos from the file browser... Mar 07 21:23:26 it returns data properly if I pick from anywhere else, but from photos and it goes canceled... Mar 07 21:27:28 pfn, probably the whatever app handles your photo picking doesn't set result? Mar 07 21:28:12 it's the default ACTION_GET_CONTENT handler (saf browser, basically) -> if I go into drive and select, it returns ok, if I pick from internal storage, it's ok, but if I pick from photos, it returns canceled... Mar 07 21:37:06 s73v3r: My own site Mar 07 21:37:24 It will be plain text generated by php Mar 07 21:37:36 so just give that to the textview Mar 07 21:51:30 Can someone point me in the right direction ... I want to learn to code for android apps I know I can download Google's development platrform but are there any others options worth bothering with ... my Java experience is very limited but I have many years of coding in other languages Mar 07 21:51:41 s73v3r: I am not sure how... This is what I have... http://pastebin.com/q6A0FVKJ I made it using sample code i found online, but it doesn't seem to work Mar 07 21:51:46 which I know doesnt really help but im not new to the idea of programming Mar 07 21:53:09 donavan01: just stick with the default Mar 07 21:54:23 lankanmon: i don’t know what that’s trying to do Mar 07 21:54:56 s73v3r: Well the main thing that I have is the try, catch in the middle Mar 07 21:55:19 so you’re loading the Google homepage? Mar 07 21:55:28 the reset is because it wouldnt let me run a web call in the main activity so I triend creating an async activity Mar 07 21:55:39 s73v3r: Just a sample Mar 07 21:55:44 you can’t do web calls on the main thread Mar 07 21:55:59 s73v3r are there any other tools I should get to help me along editors or anything Mar 07 21:56:13 donavan01: just stick with the default Mar 07 21:56:23 when you are ready for the other tools, you’ll know Mar 07 21:56:32 donavan01: Get AndroidStudio it has averything you need including a package manager Mar 07 21:57:54 s73v3r & lankanmon ... thanks for advice I was pretty sure that was the case but I just wanted to check Mar 07 21:58:11 dude, a simple google search would have yeilded the same info Mar 07 21:58:47 s73v3r: By thecond theread, it means a different java activity right? Mar 07 21:58:56 no Mar 07 21:59:26 oh, I was going off of http://stackoverflow.com/questions/6343166/how-to-fix-android-os-networkonmainthreadexception Mar 07 21:59:39 then how do i make the second thread? Mar 07 21:59:46 AsyncTask does that Mar 07 22:00:13 can I have the asynctask ont he same java file as long as it is not in the main activity? Mar 07 22:00:38 it could be in the main activity as well Mar 07 22:00:40 s73v3r ... it would have given me opinions written by possibly biased views I wanted to ask acutally coders what to use I have been tpying with the idea for a long while now and never pulled the trigger so I have read a lot of articles on the subject but never just directly asked anyone ... I wasnt trying to avoid doing the leg work Mar 07 22:00:46 but I wouldn’t recommend having it in the same java file Mar 07 22:01:10 donavan01: your question has been asked and answered a thousand times Mar 07 22:01:41 s73v3r: oh I will see then Mar 07 22:01:56 but I’m still not sure what you’re trying to accomplish Mar 07 22:02:04 you read in google.com, and then what? Mar 07 22:02:43 Well the actual url will be http://lknnet.com/api/weather/ Mar 07 22:03:18 I want to put that text in a textview and update every 30min Mar 07 22:03:22 thats all Mar 07 22:03:57 you’re gonna have to look more into how to do web calls Mar 07 22:04:32 basically, you’re going to fire off your web task on a background thread, do the call, then send the result back to the main thread, where it can be put into the textview Mar 07 22:05:04 i got Android Studio 2.3 and got same error when try to run app --> Unable to detect adb version, adb output: /home/ramdom/Android/Sdk/platform-tools/adb: 3: /home/ramdom/Android/Sdk/platform-tools/adb: Syntax error: Unterminated quoted string Mar 07 22:05:05 I just dont understannd how to get the mainthered to run the async task Mar 07 22:05:18 read the documentation Mar 07 22:05:22 it tells you how Mar 07 22:05:28 yeah I will Mar 07 22:05:38 i downgrade platform-tools as article says but same error. I am using Ubuntu and 32bits computer Mar 07 22:05:47 stop using a 32bit computer Mar 07 22:05:54 android development requires a 64bit computer Mar 07 22:08:33 s73v3r ... I have read a number of different blogs ... some of the wiki on the studio and SDK and looked into a few WYSIWYGs and the docs for them Mar 07 22:10:21 a few years back I was helping out with porting a version of gingerbread over to a LG P505 so I have dabbled with the studio before but never made an acutal app Mar 07 22:11:21 pfn: there is not reason to buy another computer because my computer is ok Mar 07 22:11:42 Akuw: it’s ok, but it can’t build Android apps Mar 07 22:11:42 but it isn't Mar 07 22:11:52 it's not ok for developing android apps Mar 07 22:12:23 pfn: forget it Mar 07 22:12:47 you don't have to buy another computer, just add 32 bits Mar 07 22:12:52 Akuw: BTW, is ur system old? because it may be a new system with a 32bit os... In which case all you need is 64bit OS Mar 07 22:13:04 you can find 32 bit sticks on amazon Mar 07 22:13:20 actually is a 32bis cpu Mar 07 22:13:24 most everything in the last 5ish years is 64bit... Mar 07 22:13:54 pfn: Yeah I haven't used a 32bit device in a while Mar 07 22:14:01 i just download platform-tools_r23.0.1-linux.zip now i fix problem Mar 07 22:14:19 but i am getting Error:java.util.concurrent.ExecutionException: java.lang.RuntimeException: AAPT process not ready to receive commands Mar 07 22:20:15 what i think, if you can't or don't want to help, just don't say nothing Mar 07 22:20:22 because is not helpfull Mar 07 22:23:11 it is helpful, it's a non-interesting problem that you're not going to get any support on Mar 07 22:23:16 the sooner you're out of here, the better Mar 07 22:23:34 Akuw: do you have any documentation that shows that the tools support 32 bit systems? Mar 07 22:24:03 thanks again for the help everyone ... have to reboot Mar 07 22:24:16 go back to an old version of android dev tools that support 32 bit systems Mar 07 22:24:23 android studio 2.3 does not Mar 07 22:31:38 so.. Mar 07 22:31:45 is it better to do this or to just try catch? Mar 07 22:31:47 links != null && links.getChildGenres() != null && links.getChildGenres().getHref() != null Mar 07 22:32:30 I don’t know which would be better, but that’s probably what I’d end up with Mar 07 22:32:46 the issue with Try/Catch is that the variables would be scoped to the Try/Catch block Mar 07 22:32:57 unless you declare them outside, and provide defaults in the Catch Mar 07 22:33:13 use kotlin and the various ?.let crap Mar 07 22:34:23 that would be ideal Mar 07 22:34:48 otherwise, comparing them separately, and handling the separate error cases would be better Mar 07 22:38:32 pity it's shitty java Mar 07 22:38:52 too bad ? doesn't compose in kotlin... Mar 07 22:39:05 but I guess there's some sort of forall thing Mar 07 22:39:27 oh, I guess kotlin can just do links?.getChildGrens()?.getHref()? or something Mar 07 22:42:48 huh.. that's interesting Mar 07 22:42:58 not sure if I'm ready to make the jump to Kotlin just yet Mar 07 22:43:02 specing out a new API Mar 07 22:43:22 If it’s perfectly OK that those things are not there, make them Optional Mar 07 22:43:39 not my API Mar 07 22:43:40 if they are required to be there, do something gracefully, or just crash Mar 07 22:43:47 oh yea that's the plan Mar 07 22:43:53 just wondering which is /faster/ Mar 07 22:44:02 try/catch is not faster Mar 07 22:44:13 exception handling is slow Mar 07 22:44:13 i don’t think it matters Mar 07 22:44:21 it matters Mar 07 22:44:24 try/catch or checking 3 places, which is actually way more calls than the 3 there Mar 07 22:44:27 exception handling is slow, but only when you’re handling the excepti8on Mar 07 22:44:40 generating and catching exceptions causes the stack to be filled in Mar 07 22:44:41 it's slow Mar 07 22:44:41 i wouldnt handle it, just eventBus that it failed and continue on Mar 07 22:44:49 especially if it's not an exceptional condition Mar 07 22:44:56 ah I see Mar 07 22:45:00 the exception would still be generated Mar 07 22:45:01 (something catches the exception at some point) Mar 07 22:46:16 if it's something that runs relatively rarely, not a big deal, if it's occurring often, not something you want to be doing casually Mar 07 22:46:25 are there any good libs to visualize a HashMap? Mar 07 22:46:40 serialize to json, and prettyprint it Mar 07 22:46:49 haha Mar 07 22:46:54 touche Mar 07 22:46:58 Hey everyone, I just posted an app to the google play store last night, and I know for a fact that I have some users since there are multiple reviews, but the install count on the developer console has yet to update. When, on average, can I expect to see how many users I have? Mar 07 22:47:09 BasedGob, updates about daily Mar 07 22:47:11 i mean, in an AndroidView Mar 07 22:47:30 serialize to json, pretty print it, and put it in a TextView Mar 07 22:47:31 or something that will display nodes Mar 07 22:47:38 haha you made my day Mar 07 22:47:40 pfn: Ah ok, thanks Mar 07 23:01:33 So to the Rxers here, are relays/subjects considered a code smell? Mar 07 23:13:57 what's the best way to set a default value for a PreferenceActivity programmatically? the default value will vary based on device... Mar 07 23:38:07 Hey all, quick off topic question. I've talked a few times here about a desktop chat app i've been building (think IRC/Slack). Many functions in the app can be accomplished by typing commands into the chat input (eg, '.logout'). I currently have a sidebar that allows users the change chat rooms. What are your thoughts on removing the sidebar and allowing people to change rooms only through the chat input as another command? Mar 07 23:38:26 Do you think that would be a bad UX? Mar 07 23:38:49 that sounds awful Mar 07 23:39:02 Elaborate? Mar 07 23:39:13 You'd rather have a sidebar? Mar 07 23:39:18 yes Mar 07 23:39:22 because then I can see it Mar 07 23:39:44 hiding something behind a command that has to go into the chat input means I’ll probably never find it Mar 07 23:40:04 Well, you'd likely still have to search the sidebar, as there are (will be) a large number of rooms. Mar 07 23:40:25 but I can see it Mar 07 23:40:38 i know it’s there Mar 07 23:41:35 Hmm ok, I didn't think there would be such opposition, interesting. Also, as I mentioned most of the functionality is through commands, so you can assume a user knows how to issue a command. Mar 07 23:41:56 i would not assume that Mar 07 23:42:00 especially when it’s new Mar 07 23:42:53 Would likely be a "new user" flow that would show when you first start typing. I get your point though. Mar 07 23:43:11 It just takes up SO much space, for so little functionality. Mar 07 23:43:50 make it collapsable. but I wouldn’t remove it altogether Mar 07 23:44:13 although, looking at my slack window, i don’t think it takes up that much space Mar 07 23:44:35 I think another reason i'm interested in going the command route is due to the novelty, nearly every chat app has a sidebar for channels. Mar 07 23:45:02 Maybe theres a reason for that though.. Mar 07 23:45:19 yeah. don’t not include the command stuff, but don’t make it the only way to do something Mar 07 23:45:54 Yea, that's a good compromise, thanks for the input. Mar 07 23:46:29 you need to have both ways to do it, optimally Mar 07 23:47:55 pfn Perhaps so. Mar 07 23:55:42 Hmm.. is it possible to write a file inside a unitetest? Mar 07 23:56:00 I'm getting ENOENT Mar 07 23:56:53 you can create a temporary file/dir that's created/destroyed for the life of your test, for those odd times where you can't avoid doing IO Mar 07 23:58:20 have a look at org.junit.rules.TemporaryFolder Mar 07 23:58:57 oh Mar 07 23:59:07 snap.. well what I'm doing isn't really in the scope of the test.. Mar 07 23:59:16 I'm just traversing an API and wantt o dump the JSON Mar 07 23:59:26 but logcat has a limit. Mar 07 23:59:30 I guess I'll just log one line at a time Mar 08 00:00:37 webservice API? Mar 08 00:02:10 yeah I guess? Mar 08 00:02:16 it's REST Mar 08 00:02:35 break your code out and test it in the JVM then, it'll be much faster and easier Mar 08 00:02:58 nah Mar 08 00:03:04 it's just this one thing I need it for Mar 08 00:03:22 and I already have the code in Android. No need to move it to another place and maintain it both places Mar 08 00:07:29 Hi Mar 08 00:08:52 I'm trying to find out if anyone has found a way to unlock the moto z force Mar 08 00:09:11 try #android-root or XDA Mar 08 00:09:13 what's the topic say? Mar 08 00:10:50 oops lol, sorry Mar 08 00:11:05 I read that wrong Mar 08 00:11:20 thanks I'll try over there Mar 08 01:05:42 how to reference a .aar in the newest Android studio Mar 08 01:06:54 i don’t believe that changed Mar 08 01:08:50 I don't know how. Some old posts say prior to 0.4.4, do a certain way, newer ones say modify the build file. I'm looking for some gui friendly way to do it Mar 08 01:09:08 I don tthink there is a gui friendly way? Mar 08 01:09:15 do modify the build.gradle file Mar 08 02:23:45 orbyt_ its fine to have expert things like a chat UI, but the pedagogical vector has to be there at least initially. you can make it so users can disable it Mar 08 02:25:36 Expert things? Mar 08 02:32:28 expert modes Mar 08 02:46:07 is there a way to add padding to images in glide? Mar 08 02:54:58 How can I pass content from asynctask to main activity? Mar 08 02:55:14 i cant set text to text view directly from async **** ENDING LOGGING AT Wed Mar 08 03:00:01 2017