**** BEGIN LOGGING AT Fri Jul 22 02:59:58 2016 Jul 22 03:54:05 Hey guys, trying to build an app with PhoneGap, but it's claiming I've got a malformed cofig.xml. I believe it is referring to this line Jul 22 03:54:11 Anyone able to point me in the right direction? Jul 22 03:59:12 What's phonegap? Jul 22 03:59:18 I get the error "Namespace prefix android for name on uses-permission is not defined" Jul 22 03:59:48 PhoneGap is a program/library? for creating web apps. You create them like you would a website and package them as an app. Jul 22 04:06:35 Nothing wrong with the XML? Jul 22 04:51:39 haha, i miss john stewart .... Jul 22 04:58:28 g00s: https://twitter.com/ditzkoff/status/756349545831882752 Jul 22 04:59:36 Leeds yes, that was it :D Jul 22 06:01:36 Using phonegap, I keep getting config XML is malformed. The line it is talking about is Anyone know a way around it? Jul 22 06:08:22 GhostChilli don't use phonegap ;) cha ... Jul 22 06:08:30 thanks Jul 22 06:12:49 where is this tag placed? should be outside Jul 22 06:15:10 Here is my config.xml http://hastebin.com/isotawatiy.xml Jul 22 06:15:15 The line is just near the bottom Jul 22 06:16:24 oh i thought in phonegap you have the AndroidManifest Jul 22 06:18:33 No, I don't think it uses it Jul 22 06:19:46 Can ayone tell me why it Jul 22 06:20:05 http://stackoverflow.com/questions/30042088/how-do-i-add-uses-permissions-tags-to-androidmanifest-xml-for-a-cordova-projec Jul 22 06:20:14 it seems it should be in Jul 22 06:20:17 why it´s so difficult to find up-to-date changelogs from Android related stuff. Such as the support library. 24.1.1 is out, yet this page isn´t updated yet: https://developer.android.com/topic/libraries/support-library/revisions.html Jul 22 06:20:32 because google Jul 22 06:20:35 Already been too often in this situation where I can find the changelog. Jul 22 06:20:36 oh Jul 22 06:21:27 So they´re simply not public yet? Or can I find them at an alternative site? Jul 22 06:22:09 dunno Jul 22 06:22:13 i just got used to this Jul 22 08:04:43 Man, the people who wrote the Android documentation are so making fun of the people who waste their time on these apps. On the achievements page: "Bored" - Play the games 10 times; "Really, really bored" - Play the games 100 times. This kind of humor is kinda refreshing. Jul 22 08:06:18 Sample app: "ButtonClicker2000". Jul 22 11:13:01 Is there a way to get a TextWatcher fomr the view the same way you get use getOnItemSelectedListener from a Spinner? Jul 22 11:20:27 Hi guys! I was wondering, is there any preferred way to structure up and android app? I'm most familiar with the MVC pattern but I've done some reading, and it seems like that is no the best solution for android. Some articles suggest the MVP pattern or a Clean Architecture pattern... Any recommendations? Jul 22 11:21:25 barq: unlikely. you should have your own reference to the TextWatcher before adding one to the view Jul 22 11:22:42 The idea was to remove it before setting a text via code and then setting the watcher again in order to suppress the listener from firing Jul 22 11:24:54 Hi Jul 22 11:25:04 is there some simple way to make a spinner have categories ? Jul 22 11:25:24 Like COMPUTERS non-selectable and then have DESKTOP LAPTOP TABLET etc Jul 22 11:32:37 Hi, I was trying to build a project for android on Linux but I am getting this error arm-linux-androideabi-g++: Command not found what I am missing? Jul 22 11:32:54 complete error /Android/android-ndk/toolchains/arm-linux-androideabi-4.8/prebuilt/linux-x86_64/bin/arm-linux-androideabi-g++: Command not found Jul 22 12:12:13 Hello, is this the right channel to ask about the android-studio? Jul 22 12:14:40 lg188: oui Jul 22 12:16:13 Hey guys Jul 22 12:16:17 How's everyone today? Jul 22 12:16:31 What you guys think of SO documentation? Looks like a good addition Jul 22 12:17:01 Yes Jul 22 12:17:10 It's great for catching up with new languages Jul 22 12:25:07 I think it'll help with Android dev too Jul 22 12:25:21 Better code examples will be there to be easily found Jul 22 12:25:32 The code examples will be better than the Android dev site Jul 22 12:26:43 So, I like lambda syntax, but I need to use 1.8 for that. I know how to fix it on "project" level, but I'd like 1.8 and jack to be my default Jul 22 12:31:45 I think I did the 1.8 right, but I have no idea how to edit the "default" gradle scripts Jul 22 12:31:56 Any ideas where to start on that? Jul 22 12:34:48 How do you handle back presses in a fragment? Jul 22 12:37:56 What's the xml tag again that allows me to have a view only be included in the heirarchy after I manually toggle it in code? Jul 22 12:38:01 For example, I'm on the first fragment which is created from the activity, how to I remove the fragment and go back to the activity layout? Jul 22 12:38:18 ViewStub Jul 22 12:38:21 that's it Jul 22 12:39:07 markyosullivan: Activities manage fragments, you don't go from fragment to activity, you go from Activity to Activity Jul 22 12:39:43 ViewStub? Jul 22 12:40:16 yiati: Yes that's true but if I have the user press back on the first fragment, it closes the application Jul 22 12:40:32 ViewStub was the answer to my question Jul 22 12:41:02 markyosullivan: Sounds fine, what do you want to achieve? Jul 22 12:41:27 instead of exiting the application, I want to return the user to the first layout which is the layout of the activity Jul 22 12:42:38 Wait a second Jul 22 12:42:41 markyosullivan: Override onBackPressed in the activity, and use the fragment manager to to move a different fragment https://developer.android.com/reference/android/app/Activity.html#onBackPressed() Jul 22 12:43:03 If I'm on the first fragment, I want to navigation to the previous activity Jul 22 12:43:04 e.g. Jul 22 12:43:16 I'm on Main Activity, first fragment within it Jul 22 12:43:18 back pressed Jul 22 12:43:26 I want to be back to the Login Activity Jul 22 12:44:14 markyosullivan Jul 22 12:44:28 so you're trying to return to the previous fragment? Jul 22 12:44:49 No sorry, I haven't explained this correctly, I misunderstood it myself Jul 22 12:44:53 Ok Jul 22 12:44:58 so what's the issue? Jul 22 12:46:10 markyosullivan: If the Login Activity is in the backstack then hitting back will go to the Login Activity. But it isn't in your case since you mentioned it closes the app. So you need to call startActivity(loginActivityIntent) in your MainActivitys onBackPressed Jul 22 12:46:12 I have two activities: MainActivity (has fragments within it) and Login Activity. If the user clicks back a couple times within the fragments of Main Activity, they'll eventually hit the first fragment and when they hit back on it, it closes the app instead of returning them to the Login aActivity Jul 22 12:46:35 hmm Jul 22 12:46:49 Is it possible to get the class name of the current fragment from FragmentManager? Jul 22 12:47:03 if it is, it makes it easy to handle Jul 22 12:47:18 onBackPressed -> check if first fragment -> send to Login Activity Jul 22 12:47:50 So as I understand it... Jul 22 12:48:23 Detect a back press. If it happens under the circumstances that cause the issue, try getFragmentManager().popBackStackImmedate(); Jul 22 12:48:55 Would popBackStackImmedate() go to the previous activity? Jul 22 12:49:02 It'll return to the last fragment Jul 22 12:49:22 I need it to switch to a new activity Jul 22 12:49:34 Hi, If I were to build the android sources for one of the Google phones would my master branch be able to download from the play store? Jul 22 12:50:00 maykyosullivan, try detecting a back press and then on that trigger simply start the login activity Jul 22 12:50:07 markyosullivan* Jul 22 12:50:16 markyosullivan: Track current view state in the Activity and then handle it in onBackPressed in the Activity Jul 22 12:50:39 BigZ: Would that not start the login activity for every back press? Jul 22 12:50:58 Not if you do a check to see the current activity Jul 22 12:51:07 that way it'll only happen in that circumstance Jul 22 12:51:21 Do you mean the current fragment? Jul 22 12:51:44 I don't know your code. If you're trying to revert from a fragment to an activity, then yes Jul 22 12:51:56 how do you find the current fragment? Jul 22 12:52:02 markyosullivan: The current fragment displayed is part of the current state Jul 22 12:52:44 That's an easily googleable question btw Jul 22 12:52:50 findFragmentById() and pass it the current fragment Jul 22 12:53:32 use that to determine your current fragment, if it is, then you do the onBackPressed and then start the login activity Jul 22 12:53:50 I've tried googling it but it looks like you have to enter the ID of the fragment Jul 22 12:53:53 which doesn't make sense Jul 22 12:53:59 or can you use the id of the fragment container? Jul 22 12:54:02 you can set an ID to a fragment Jul 22 12:54:26 fragTrans.replace(android.R.id.content, myFragment, "MY_FRAGMENT"); Jul 22 12:54:37 and then use that to get the current fragment Jul 22 12:55:26 ^ Jul 22 12:55:49 Or if you use the backstack, https://developer.android.com/reference/android/app/FragmentManager.html#getBackStackEntryCount() Jul 22 12:55:56 For the Google phones to build the latest master sources do I just download the hardware portions as talked about on the building page after the dependencies are installed on my system and build it like it talks about and will my custom built image have access to the play store? Jul 22 12:56:05 What SimonVT said too Jul 22 12:56:11 there's a million ways to do it Jul 22 12:56:13 nickgaw: Try #android-root, this channel is for app dev Jul 22 12:56:32 SimonVT: So if it's 0 then that means there's no fragments to go back to and it'll close the app? Jul 22 12:56:37 https://media.giphy.com/media/wErJXg1tIgHXG/giphy.gif Jul 22 12:56:41 Fragment currentFragment = getSupportFragmentManager().findFragmentById(R.id.flFragmentContainer); Jul 22 12:56:43 I tried this Jul 22 12:56:57 As long as there are backstack records, pressing back will pop one Jul 22 12:57:09 If there are none, the activity is finished Jul 22 12:57:31 SimonVT: He wants to override that to start a new activity Jul 22 12:57:46 or she Jul 22 12:57:47 idk Jul 22 12:57:47 That's the default behavior Jul 22 12:57:59 Should answer the question Jul 22 12:58:11 SimonVT: One that's not in the backstack Jul 22 12:58:38 What do you mean? Jul 22 12:59:32 markyosullivan said that currently when they press back on the current activity it leaves the app rather than going to an activity they want, so I'm assuming it's not in the back stack and startActivity needs to be called Jul 22 13:00:19 Although it does seem weird to go back to an activity that isn't in the back stack Jul 22 13:01:09 I'm just talking about the default backstack behavior (tells you how getBackStackEntryCount works as well) Jul 22 13:01:14 markyosullivan: Why would someone get to a login screen leaving the mainactivity of your app? Sounds weird, unless I'm missing something Jul 22 13:01:34 But yes, no reason to finish the login activity if it's supposed to be shown when pressing back Jul 22 13:01:54 SimonVT: That was perfect Jul 22 13:02:01 Great solution Jul 22 13:02:14 yiati: Yeah I'm going to prompt them if they wish to logout of the app Jul 22 13:05:40 Wait Jul 22 13:05:58 It seems getBackStackEntryCount returns 0 even if I'm on the 2nd fragment Jul 22 13:06:58 I think it might be cause I've always used addToBackStack(null) Jul 22 13:07:36 markyosullivan: Are you using getSupportFragmentManager() Jul 22 13:07:52 getFragmentManager() will possibly always return 0 Jul 22 13:08:32 Yeah using getSupportFragmentManager() Jul 22 13:09:36 Eh, is the only way to make a custom list items by making a custom adapter? Jul 22 13:09:44 kind of confused on the matter Jul 22 13:13:14 I have 2 linear layouts inside a horizontal linear layout. I want the first one to take the minimum width possible and the second to take the remaining space. What should i set the layout weights to get this effect? Jul 22 13:14:10 use one with wrap_content? Jul 22 13:14:38 so the first as wrap content then how does the second take the remaining space? Jul 22 13:14:52 By setting layout_weight >0 Jul 22 13:15:46 So on the first one I have weight 0 and wrap content for width then the second has 0dp width and 1 weight. Should that do it? Jul 22 13:16:03 Yep Jul 22 13:17:23 seems to make sense and looks to be working. thanks. I was missing the wrap content. I had the first one set to 0dp also. Jul 22 13:18:11 i'm curious about perf between using weights in a linearlayout vs contraintlayout. i would assume constraint layout would be slightly better? Jul 22 13:19:50 lg188: you could use ArrayAdapter Jul 22 13:20:11 LinearLayout is fairly efficient Jul 22 13:20:17 Don't know about ConstraintLayout Jul 22 13:21:00 alexfu: well, I'm still confused on how to implement it. I need a different layout than the regular one. But I have only one string Jul 22 13:21:02 maybe i'll write up an app that compares the two Jul 22 13:21:31 lg188: override getView Jul 22 13:21:40 and return whatever layout you want Jul 22 13:22:11 eh, that sounds even more confusing, but less work. I'll try that Jul 22 13:23:17 You can pass ArrayAdapter a layout and a textview id Jul 22 13:25:00 lg188: the basic workflow of adapters is that the view for a row in a list is created via getView. in getView you can inflate your own layout via inflater.inflate(R.layout.my_layout). You'll get a View back from the inflation process which then you can bind your data to. then finally, return your view. Jul 22 13:28:33 first of all, I have to override getView by making a new class or implementing it in my main, right? Jul 22 13:28:51 Or can I do it in a more simple way Jul 22 13:29:25 it's been a while since I wrote in Java, I'll admit, so I forgot some of the concepts related to classes Jul 22 13:31:09 lg188: you can create a new class that extends ArrayAdapter, or if you're super lazy, just instantiate it like.. new ArrayAdapter() { /* Override methods here */ };. I would NOT advise you to go with the second method. Jul 22 13:31:49 Why do you suggest not? Jul 22 13:32:00 Because it's confusing? Jul 22 13:34:42 adapters should be decoupled from activities/fragments as much as possible so they can be reused. if you instantiate it directly in your activity, you cant use it anywhere else and you are more likely to reference things in your activity from your adapter, thus creating a tight coupling between adapter and your activity. Jul 22 13:36:12 either way, the process is pretty straight-forward, subclass ArrayAdapter -> override getView Jul 22 13:36:58 Mhm you're right in this case I do have to reuse the adapter Jul 22 13:37:16 but heck that's a lot of typing work Jul 22 13:37:57 if you're afraid of typing, then programming is the wrong business to be in lol Jul 22 13:38:45 plus, IDEs can do most of the work for you these days. Jul 22 13:38:53 Afraid is not the word, but boilerplate code is a hell Jul 22 13:41:22 i mean, Android Studio does alot for you already.. auto-import packages, automatically write out methods you want to override... all you have to do really is to write out the implementation Jul 22 13:42:12 I'm doing something wrong then because I doesn't seem to add anything when I want subclass the arrayadapter Jul 22 13:42:28 it* Jul 22 13:43:25 lg188: in Android Studio, at the top menu aread, goto Code -> Override Methods. then select the one you want to override Jul 22 13:43:32 *area Jul 22 13:44:54 Allright, that helps a lot. Now it's still complaining about a missing constructor. Do I just override it? Jul 22 13:46:29 lg188: yes Jul 22 13:47:11 Hi all, is anyone able to help me work out what's causing an android.database.CursorIndexOutOfBoundsException? Jul 22 13:47:52 (44 lines without even changing anything, that is what I mean with bloat) Jul 22 13:48:51 lg188: yes, java is quite verbose. kotlin is much less so Jul 22 13:50:11 I'll look into it later. Sadly school only accepts Java for the exam Jul 22 13:51:10 sdousley: CursorIndexOutOfBoundsException happens when you try to access some data but the cursor is pointing to an invalid index Jul 22 13:52:48 alexfu: yeah, I thought that, I can't see anything obvious as to where it would be trying this. Jul 22 13:52:52 alexfu: the full message is: Jul 22 13:52:53 java.lang.RuntimeException: Unable to start activity ComponentInfo{co.uk.acceptacard.paya_merchant/co.uk.acceptacard.paya_merchant.ProcessSale}: android.database.CursorIndexOutOfBoundsException: Index 0 requested, with a size of 0 Jul 22 13:52:57 Thanks alexfu Jul 22 13:53:06 would that suggest it's in the onCreate() method? as it can't start the activity? Jul 22 13:53:41 sdousley: you'll have to post the entire stacktrace. use pastebin. Jul 22 13:54:08 alexfu: I can't seem to see the full stack trace in developer console, it just ends with "... 9 more" or is that the whole trace when it says that? Jul 22 13:54:21 sdousley: Your Cursor has 0 rows Jul 22 13:54:23 There's no data to get Jul 22 13:54:40 SimonVT: yeah, I'm just trying to work out which cursor that is hehe Jul 22 13:54:45 http://pastebin.com/jzEyypXL Jul 22 13:54:54 that's the stack trace as full as I can see it in developer console Jul 22 13:55:08 The Cursor at line Jul 22 13:55:48 aah, now i read the stack trace properly, I see a reference to one of my classes. Jul 22 13:56:34 OK, it's pointing to this line: return cursor.getString(2); Jul 22 13:56:36 And the "9 more" is the lines above the "Caused by" line Jul 22 13:56:44 Basically it's when exceptions wrap exceptions Jul 22 13:57:10 right :) Jul 22 13:58:15 so can I just wrap my return cursor.getString(2); in a try/catch? and return something in the catch if that key doesn't exist? Jul 22 13:58:39 It's not the key that doesn't exist, the Cursor is empty Jul 22 13:58:42 Your query returned 0 rows Jul 22 13:58:56 sdousley: you want to check if the cursor has rows BEFORE you access it Jul 22 13:59:10 You should never call getString if the Cursor is empty Jul 22 13:59:20 cursor has a getCount method Jul 22 13:59:46 The various move methods return false if the row it's moving to doesn't exist Jul 22 14:00:06 ok, so I currently have if(cursor != null, if I change that to if(cursor.getCount() > 0) that should resolve it? Jul 22 14:03:52 um Jul 22 14:03:57 sdousley: yes Jul 22 14:04:04 what about if (cursor != null && cursor.getCount() > 0) Jul 22 14:04:17 I'm not entirely sure how they are getting 0 rows in the app, they have to log in to get to that point, and that will set the value in the local SQLite db Jul 22 14:05:08 Ashiren: that sounds reasinable Jul 22 14:10:32 from that stack trace, would you say that the initial error is at ProcessSale.java line 107? that's where it's calling Config.getMerchantIdentifier() ? Jul 22 14:11:38 Wherever you query the Cursor probably Jul 22 14:13:00 I'm just trying to understand the trace. Line 18 of the trace suggests it's ProcessSale.onCreate line 107, which calls Config.getMerchantIdentifier from Config.java line 36 Jul 22 14:13:07 that is if I'm understanding the trace correctly? Jul 22 14:14:59 sdousley: that is correct Jul 22 14:15:03 sdousley: you read the stacktrace from bottom up. so bottom most line in the stacktrace is where it starts, then read up Jul 22 14:15:24 OK, that's what I was thinking. But that call to Config.getMerchantIdentifier, is nowhere near line 107 in ProcessSale.java Jul 22 14:15:47 which is the bit that is really confusing me hehe Jul 22 14:16:19 It is in the apk the user is using Jul 22 14:16:28 Check the version and make sure you're looking at the same thing Jul 22 14:17:21 yeah, I'm using the same version of the software. Jul 22 14:17:48 I'm completely unable to replicate the issue they're getting. I thoiught it might be when they haven't got sufficient things on their account Jul 22 14:18:01 but I've just tested with another member of staff's account, and it behaves as expected as well. Jul 22 14:19:11 I'll put the fix in, so it's if((cursor != null) && cursor.getCount() > 0)) Jul 22 14:19:19 and see if that stops the issue for this random user. Jul 22 14:21:31 Thanks for the help guys :) Jul 22 14:24:20 sdousley: if you use git, you could use the pickaxe feature of git log to find when a particular string had been added/removed Jul 22 14:24:35 i.e, git log -SConfig.getMerchantIdentifier Jul 22 14:25:13 alexfu: I do use git Jul 22 14:25:48 that should show you where Config.getMerchantIdentifier was added/removed (i.e. moved in your case) Jul 22 14:27:16 Aha, in a previous version, there was a Log.e for Config.getMerchantIdentifier on line 107 Jul 22 14:27:41 I went through and removed a load of Log. calls in a recent commit Jul 22 14:27:52 maybe after I had released the current version of the app Jul 22 14:28:18 yes, released v25 of the app on 14th July Jul 22 14:28:24 performed that commit 20th July Jul 22 14:29:09 Was there a way with ProGuard to remove all Log.x commands automatically Jul 22 14:29:34 not sure about proguard Jul 22 14:30:22 I've read about some things that it can do, but whenever I try to include it, it never seems to do anything Jul 22 14:30:54 Ah well, at least I found the issue, and have released a fix for it. Jul 22 14:31:28 now the one user who leaves useless crash messages "still won't work" can have the app work hehe Jul 22 14:32:18 oh yay, Android 7 is out soon, I guess I need to try and check the app works fine on there too Jul 22 14:35:06 sdousley: your comment on proguarding out log statements intrigued me. I did some research and I found this SO: http://stackoverflow.com/a/2019002 Jul 22 14:35:56 MarkyC: yeah, that's similar to what I've found in the past. Jul 22 14:36:05 Just never done any proguard, so not 100% sure about it hehe Jul 22 14:36:10 I think most wrap Log calls in a custom log class and use BuildConfig.DEBUG Jul 22 14:36:33 SimonVT: I was just about to suggest that as well Jul 22 14:36:34 SimonVT: ah, that makes sense, Jul 22 14:36:53 I just removed them all from the app, as they're not needed any more Jul 22 14:36:56 Then you can also do stuff like log in debug builds, send to e.g. Crashlytics on release builds Jul 22 14:37:04 though I think if I need to do any more testing, that might be something I do Jul 22 14:37:17 well, not BuildConfig.DEBUG per se, but wrapping Log, and using BuildConfig.LOG_LEVEL, so you can have different levels depending on your flavour Jul 22 14:37:36 yeah, and you can set those levels in build.gradle? Jul 22 14:38:24 whoa, AVD's are a lot quicker than last time I used them Jul 22 14:39:18 Timber is a good lib for changing log behaviors Jul 22 14:42:56 Quick google, and I came across http://www.acra.ch/ earlier Jul 22 14:43:12 has the AVD and VirtualBox problem been resolved? or will it never be fixed? Jul 22 14:43:34 alexfu: it's not resolved Jul 22 14:44:13 AVD and Virtualbox problem? Jul 22 14:44:27 sdousley: you can only have 1 running Jul 22 14:44:43 well, I have my Vagrant machine running (in Virtualbox) and the AVD was working fine. Jul 22 14:45:35 For me, I can't run Docker or the AVD will fail to start Jul 22 14:46:04 I might have actually read somewhere that it's Docker thats the problem... could be mis-remembering Jul 22 14:46:11 which sucks, because I develop the app on the emulator, and it calls a backend I have standing up on my local machine Jul 22 14:46:41 Yeah, most of my development I did on my Galaxy S3/4 Jul 22 14:46:45 cos the AVD's were so slow Jul 22 15:02:05 hello Jul 22 15:02:23 my android studio is freeze at Gradle:resolve dependencies:app_debugcompile Jul 22 15:02:32 what should i do? Jul 22 15:02:52 it is just running Jul 22 15:04:39 my android studio is freeze at Gradle:resolve dependencies:app_debugcompile Jul 22 15:07:36 my android studio is freeze at Gradle:resolve dependencies:app_debugcompile Jul 22 15:10:22 that question is super vauge. i can only come up with... restart gradle? stop gradle daemons (./gradlew --stop) and run again? restart computer? Jul 22 15:11:47 alexfu, about gradle work offline? Jul 22 15:11:58 you're using gradle offline? Jul 22 15:12:16 no now Jul 22 15:12:35 i mean should i change it to offline? Jul 22 15:12:57 probably not Jul 22 15:13:18 it takes me at least 15 minutes to solve Jul 22 15:13:45 i should wait 15 minutes for app-debug compile Jul 22 15:14:19 i am using tor proxy Jul 22 15:14:32 because i live at iran Jul 22 15:14:37 what is your idea? Jul 22 15:15:02 Should I connect users to their Google+ account by default or should I ask them first? Same with submitting highscores. Jul 22 15:15:22 always ask. Jul 22 15:15:28 ^ Jul 22 15:15:53 dragorn: but the Google Game thingy has an option to automatically sign in Jul 22 15:16:06 what should i do ? Jul 22 15:16:18 So it would be the user's choice if they sign in automatically or not Jul 22 15:16:32 alexfu, ?? Jul 22 15:17:38 Is it even possible to connect automatically? Isn't that kind of bypassing oauth? Jul 22 15:19:13 ResidentBiscuit: it's done it for me for all the games that I've tried Jul 22 15:19:28 ResidentBiscuit: and there is this option in the Game thing's settings Jul 22 15:19:51 Hmm I've never messed with play games or whatever it's called Jul 22 15:20:46 <_vaibhavingale_> How I can make a Surface view corners rounded? Jul 22 15:21:36 _vaibhavingale_: don't do that or Apple will sue you Jul 22 16:00:45 so I compile to the newest SDK, and it appears the SDK took the liberty of changing my color scheme on my app, including changing text on combo boxes to white text over white background... Jul 22 16:03:09 sadistic bastards Jul 22 16:03:16 ruining my nerves Jul 22 16:03:37 150 guys in the field right now trying to pick projects on a white on white scheme Jul 22 16:06:09 azv4 i had problems with latest support lib, colors changing, etc - try 24.1.1 if you're using it Jul 22 16:06:30 g00s, Looks like Im targeting Jul 22 16:06:32 23 Jul 22 16:07:13 Don't you have tests for that? O.o Jul 22 16:07:32 Mavrik, tests for what? Google randomly changing my color schemes? Jul 22 16:07:38 no, I dont have a test for that Jul 22 16:07:41 Yes. Jul 22 16:07:43 I was wondering what is the easiest way to see a bug report after its been captured on my android studio? Jul 22 16:09:05 Crash1hd, hmm, event log should have a clickable link or at least issue # Jul 22 16:09:33 g00s, how do I roll back from 24.1.2 to 24.1.1? Jul 22 16:09:44 I'm pretty new with this environment... Jul 22 16:09:45 azv4 i was talking about support lin Jul 22 16:09:48 *support lib Jul 22 16:10:29 Mavrik, hmmm what if it happened last night and I am just plugging the phone in now (it wasnt attached before) Jul 22 16:10:46 I just need to verify if it is my app related or not Jul 22 16:10:59 Crash1hd, what kind of bug report are you talking about really? Jul 22 16:11:04 Android Studio bug report? Jul 22 16:11:05 g00s, that is the SDK build tools? Jul 22 16:11:07 Application crash report? Jul 22 16:11:37 no the phone indicated a bug report was captured on my bosses phone Jul 22 16:11:51 Platform Tools? Jul 22 16:11:55 and it has our new application on it and he wants me to make sure that its related or not Jul 22 16:11:56 I dont see 'support libraries" Jul 22 16:12:02 Crash1hd, how would AS know anything about it. Jul 22 16:12:11 Use whatever crash reporting library you use to see the database. Jul 22 16:12:34 Mavrik, ahh ok :) thanks Jul 22 16:12:52 By default if you upload a report it ends up on Play Store (if it's published). Jul 22 16:19:26 hi, i am using Databinding, why my BR and ListItemBinding is not generated ? Jul 22 16:24:05 hi i have problem to integrate volley using gradle. anyone can help me? Jul 22 16:24:57 you probably shouldn't be using volley... Jul 22 16:26:39 yes, but is a old project that use volley cloning code, and works. i want to clean project using gradle to integrate volley Jul 22 16:29:33 i removed source and add compile 'com.android.volley:volley:1.0.0' in gradle Jul 22 16:29:38 but doesent see class Jul 22 16:29:41 need help Jul 22 16:31:25 I've actually done the same thing, but unfortunately it's on my work machine, which is shut down for the weekend - sorry Jul 22 16:39:06 How do I tell the user that there's been a network error with GoogleApiClient in a localized manner? Jul 22 16:52:17 Can someone tell me what the *:S does in this line --> adb -d logcat : *:S Jul 22 16:52:31 Or really, how do I get general, localized Dialogues? Jul 22 16:52:59 where do I go to change my combobox background colors? Jul 22 16:53:44 Why on Earth would simply targeting a newer SDK change the colors of my app! Jul 22 16:53:53 This is obnoxious Google! Jul 22 16:59:43 Guys uh Jul 22 16:59:50 Anybody uses ARToolKit? Jul 22 16:59:59 I'm trying to get my hello world thing to work, but it's never working Jul 22 17:00:44 Crash1hd: that's a logcat filter Jul 22 17:00:53 https://developer.android.com/studio/command-line/logcat.html#filteringOutput Jul 22 17:01:11 alexfu, thanks :) Jul 22 17:01:37 I cant seem to get it to just show me my application Jul 22 17:03:36 I do this adb -d logcat com.myexample.myapp:V *:S <-- and I get just --------- beginning of system Jul 22 17:03:36 --------- beginning of main Jul 22 17:03:36 if I remove *:S I get everything all apps? Jul 22 17:04:49 Crash1hd: are you sure your app is actually logging things? Jul 22 17:05:22 I use this Log.d(TAG, "No network provider is enabled"); <-- for example Jul 22 17:05:38 and private static final String TAG = "GPSService"; for the tag Jul 22 17:06:02 and are you sure that Log statement is actually hit? I personally dont use the filter feature of logcat, i just use grep Jul 22 17:06:04 I have also tried adb -d logcat GPSService:D but it shows everything too Jul 22 17:06:18 logcat -s Jul 22 17:06:49 adb logcat | grep GPSService Jul 22 17:06:51 I have some that are in onCreate like this Log.d(TAG, "onCreate Called") <-- they show up in the android studios logcat Jul 22 17:06:53 you can't logcat by package name Jul 22 17:08:19 him if I do | grep GPSService it works? so I am confused why wouldnt the later work? Jul 22 17:08:56 Crash1hd: you almost had it with adb -d logcat GPSService:D.. you just need to add *:S to the end of that Jul 22 17:09:26 that will suppress all messages, EXCEPT for GPSService logs Jul 22 17:09:28 ok I guess thats why I was wondering what the *:S does? Jul 22 17:11:00 Crash1hd, adb -h logcat Jul 22 17:11:36 pfn, thanks :) Jul 22 17:22:05 Has anyone else had the newest SDK just completely destroy their color scheme in their app? Jul 22 17:22:54 sorry, no Jul 22 17:23:01 pretty sure there is going to be a job opening up Jul 22 17:23:08 for someone who can do android dev Jul 22 17:23:12 among other things Jul 22 17:23:16 like maybe in about 5 minutes Jul 22 17:23:20 get your resumes ready Jul 22 17:23:32 and someone call the amber lamps, I think this is the big one Jul 22 17:24:07 azv4: which part of your theme is incorrect? Jul 22 17:24:53 alexfu, the text changed colors, the combo boxes now have white text on white background, the same combo boxes when a field is selected snap back to dark grey over slightly less dark grey Jul 22 17:25:15 I dont even know if the app used themes prior to this Jul 22 17:25:29 I can't even get the UI editor to load in this newest version of AS Jul 22 17:27:13 azv4: i would start looking at your themes Jul 22 17:27:29 alexfu, yes that is what I looked at, tried a couple, they all seem to behave the same way Jul 22 17:27:38 which leads me to think themes arent even implemented in this old app Jul 22 17:27:46 I jumped from SDK 5 to 24 Jul 22 17:27:55 so I imagine a bunch of stuff is going to be broken Jul 22 17:28:05 Im struggling with the terminology here too Jul 22 17:28:07 what does your themes look like Jul 22 17:28:18 in xml i mean Jul 22 17:28:18 there are a bunch, none of them seem to change much though Jul 22 17:28:23 I cant find the xml Jul 22 17:28:31 I can't find the UI definition files either Jul 22 17:28:54 you mean, layout files? Jul 22 17:29:05 if that's what Google calls them, yes Jul 22 17:30:17 i mean, jumping from 5 to 24 is pretty big. the whole directory structure is different now compared to API 5. Jul 22 17:30:33 you can search for your xml files... find . -name "*.xml" Jul 22 17:30:42 I found AndroidManifest.xml Jul 22 17:34:09 ok I actually went from 10 to 24, not 5 Jul 22 17:34:19 not sure I feel any better about that jump Jul 22 17:34:40 I just pulled from source control to try to revert whatever I borked and I cant even get the project to load Jul 22 17:34:42 this is a nightmare Jul 22 17:36:29 do people have any favoured methods of fast scrolling a recyclerview? Jul 22 17:37:03 azv4: 10 to 24, is still a big jump. i wouldnt even try importing an existing project that old. i would just create a new project in Android Studio and copy/paste all your file into the new project Jul 22 17:37:25 I have 150 customers in the field with a broken business app Jul 22 17:37:31 do you think that will be my fastest way? Jul 22 17:38:01 azv4: certainly more straight-forward IMO Jul 22 17:38:12 I have no idea how to do what you suggest though Jul 22 17:38:18 right now I appear to have the project open Jul 22 17:38:34 all the .java files have a red circle Jul 22 17:38:37 that doesn't seem good Jul 22 17:38:42 but honestly I haven't a clue what it means atm Jul 22 17:39:12 azv4: File > Close project, reset your project back to it's original state. Create a new project in Android Studio Jul 22 17:39:31 start there Jul 22 17:42:50 hi guys, so i've created this bluetooth device and i'm looking to create the android app to go with it. Would it be smart to create a dedicated Service to handle the bluetooth connection? Jul 22 17:43:04 probably Jul 22 17:43:17 alexfu, I'm pretty scared to try that, this project uses ant still, and we have a makesetup suite that compiles using ant Jul 22 17:43:23 so i can handle any parsing of data etc, and i can send to activities via broadcast notifications? Jul 22 17:43:31 Im afraid something in the project will be broken if I do this Jul 22 17:43:56 azv4: if you have version control, you can always rollback Jul 22 17:44:12 try it. if it doesn’t work, roll back Jul 22 17:44:40 the alternative is to keep using what you’re currently using, with older versions of stuff Jul 22 17:45:11 stupid customer bought new Note 5 phones, and some features broke when the apk runs on that phone Jul 22 17:45:12 azv4: or, just dont even bother converting it. just open the project in Eclipse Jul 22 17:45:39 cant blame customer for installing app on a new phone.... Jul 22 17:45:44 Hey all. Quick question -- for log tag Strings, is it better to do private static final String TAG = "ClassName" or private static final String TAG = ClassName.class.getSimpleName() ? Jul 22 17:45:45 sure I can Jul 22 17:45:52 doesn't fix the problem though! Jul 22 17:46:09 only if the original contract specified a certain device Jul 22 17:46:22 It did, but boss says hurry up and update this Jul 22 17:46:28 Alright so considering i have a service handling interface to bluetooth device, do I send and receive from this service through binding and broadcast notifications? Jul 22 17:46:35 are you getting paid for it? Jul 22 17:46:45 s73v3r, Im hourly Jul 22 17:46:52 i mean the company Jul 22 17:46:55 azv4 you might need to find android devs more up to date on whats going on ... Jul 22 17:46:56 we are inhouse devs in manufacturing Jul 22 17:47:20 this customer's owner is best friends with our owners Jul 22 17:47:25 we just do what they ask basically Jul 22 17:47:27 that’s never fun Jul 22 17:47:41 parco no need for binding, unless its in another process; broadcast notifications are probably not useful; use rxjava, eventbus (greeerobot) or something else Jul 22 17:47:43 "AndroidManifest.xml doesn't exist or has incorrect root tag Jul 22 17:47:50 your best bet is probably going to be just creating a new AS project, and copying the source files over Jul 22 17:47:53 azv4: since your project is so old, open it using Eclipse and fix the problem and worry about migrating the project to the new Gradle build system later Jul 22 17:47:57 g00s: whoa, i can honestly say ive never heard of that Jul 22 17:48:11 g00s, is that in the SDK? Jul 22 17:48:12 alexfu, the project was updated to Android Studio and ran stable Jul 22 17:48:18 and now it’s not Jul 22 17:48:30 I can load the version that was Jul 22 17:48:33 parco no; 3rd party. event bus has fallen out of favor, but its quick & easy to get up Jul 22 17:48:37 why not? Jul 22 17:48:38 but I changed the theme Jul 22 17:48:43 and it seemed to break many things Jul 22 17:48:58 g00s, would you happen to have one that would make my life easier when translating to iOS? Jul 22 17:49:35 is ANT no longer supported in latest AS? Jul 22 17:49:37 azv4: so, the project is using the new Gradle build system? Jul 22 17:49:40 parco: not really, because when you do iOS, you’re going to be doing different things Jul 22 17:49:45 alexfu, I don't think so Jul 22 17:49:54 azv4: I don’t know if AS ever really supported ant Jul 22 17:49:54 ant is dead in regards to android Jul 22 17:49:56 our makesetup still uses ANT Jul 22 17:50:15 is it doing anything significant, besides just building the project? Jul 22 17:50:21 that doesn't surprise me, the dev I replaced had a funny way of doing everything, and I mean everything completely wrong and left everything just barely working Jul 22 17:50:23 if not, then ditch it, and go to gradle Jul 22 17:50:25 s73v3r, I think only build Jul 22 17:50:47 I will need to modify the makesetup program, yet another program in an IDE I dont know in a languge I dont know Jul 22 17:50:51 sign, nothing is easy around here Jul 22 17:51:08 no, just ditch all that. Jul 22 17:51:12 "AndroidManifest.xml doesn't exist or has incorrect root tag" Jul 22 17:51:21 create a new AS project, and copy the source files over Jul 22 17:51:35 s73v3r, I have to use it to distribute the app I think, it wraps the APK for sideloading in some completely and utterly idiotic installer Jul 22 17:51:51 there is no installer for sideloading Jul 22 17:52:11 oh really? this moron I replaced wrote one, so you're going to have a hard time convincing me there isnt one lol Jul 22 17:52:17 the user downloads the APK or has it emailed to them, they click on it, and the system does it Jul 22 17:52:31 I’ve been doing this for several years. There isn’t one Jul 22 17:52:37 I just told you he wrong one Jul 22 17:52:42 wrote* Jul 22 17:52:44 and you’ve said he’s an idiot Jul 22 17:52:54 it just delivers it via http Jul 22 17:52:57 so youre right Jul 22 17:53:39 I'm amazed, so this rxjava basically replaces all interobject communication? Jul 22 17:53:48 not all Jul 22 17:55:14 so what's the latest, "hip" way of doing this, rxjava? Jul 22 17:55:27 ok, Im going to create a new project Jul 22 17:55:46 but Im unclear on the steps you are suggesting, am I just dragging and dropping the old project folder into a new project? Jul 22 17:56:19 parco think rxjava a series of tubes for async operations Jul 22 17:56:36 pretty much. maybe not the project folder itself, but the source files Jul 22 17:56:47 like event bus is 1:n, rxjava is like ugh, a -> b -> c -> d Jul 22 17:56:57 this is going to make a mess with the signatures and everything else Jul 22 17:56:59 oversimplifying ab but Jul 22 17:57:03 *a bit Jul 22 17:57:11 you might have some friction with source control Jul 22 17:57:24 but as long as you have the same keystore, you’ll be fine concerning signatures Jul 22 17:58:52 so am I rebuilding this in the folders? or in the AS UI? Jul 22 17:58:57 I still am not clear Jul 22 17:59:31 azv4: you can copy and paste in Android Studio or in your own file explorer, doesnt matter Jul 22 18:00:47 minimum SDK? Jul 22 18:01:05 that totally depends on what min SDK you want to support Jul 22 18:01:08 if I set minimum SDK to 23, and some customers on 15, it wont run if they update right? Jul 22 18:01:22 whats the original min sdk set to? use that Jul 22 18:01:29 I dont know... Jul 22 18:01:32 where can I find that? Jul 22 18:01:35 in the manifest? Jul 22 18:01:42 yea Jul 22 18:01:50 or gradle Jul 22 18:02:11 ok so its set to 4 lol Jul 22 18:02:15 g00s: i like that a lot, considering i hate global state management and the use of locking mechanisms. Does this type of programming have a name? Jul 22 18:02:31 Im going to bring it up to 4 Jul 22 18:02:33 I mean 14 Jul 22 18:03:12 I just told the customer to roll back his server using windows restore heh Jul 22 18:03:29 then pull the app off the app store then update using the http sideloader off his server Jul 22 18:03:33 that should pacify him Jul 22 18:03:43 assuming he can restore on his server without borking more stuff Jul 22 18:04:47 should I build a new manifest or bring in the old one? Jul 22 18:05:15 azv4: you can copy over the old one Jul 22 18:06:28 if Im just copying the old folders into the new project's folders, how is this a new project? Jul 22 18:06:34 which files do I want to leave behind? Jul 22 18:06:52 azv4: it's a new project because the directory structure is completely different Jul 22 18:07:07 but I just copied the old directory into the new one... Jul 22 18:07:54 I dont have the experience with AS to do this Jul 22 18:08:14 copy over just the *.java files from the old project into the new project Jul 22 18:08:21 not the entire directory Jul 22 18:08:24 I have a feeling you guys are going to hate me in less than 5 minutes Jul 22 18:09:42 care to remote in? Jul 22 18:11:14 the new project appears so different than the old project I just dont understand where to put these .java files Jul 22 18:11:33 it has created 3 com.foo.foo.foo listings under the java folder Jul 22 18:11:39 azv4: they should go into app/src/main/java Jul 22 18:12:42 Im getting so panic'd I can't understand simple things heh... Jul 22 18:12:49 I need to relax somehow Jul 22 18:14:57 azv4: when you created the new project in AS, did you select blank project, or some other template? Jul 22 18:20:10 anyone know how to clear the cache of the ringtones menu? Jul 22 18:21:10 s73v3r, new Jul 22 18:21:16 s73v3r, blank Jul 22 18:31:47 JakeWharton, can I extend picasso with my own way of retrieving a byte array for an image? :) Jul 22 18:32:42 ah, RequestHandler I guess, just need to figure out hw.. Jul 22 18:32:44 how* Jul 22 18:32:49 yes Jul 22 18:33:19 you can look at the built-in ones for reference Jul 22 18:33:40 no such thing as system restore in server 2008r2 bleh Jul 22 18:34:37 s73v3r, Im starting all over again, is it important to signing that I use the same "company domain"? Jul 22 18:34:54 i believe so Jul 22 18:35:56 I dont evne know what that is Jul 22 18:37:41 it’s in the manifest Jul 22 18:40:05 ok, new clean project created Jul 22 18:42:29 saved old manifest over the one generated by the new project Jul 22 18:44:56 are you sure I can overwrite the new generated manifest with the old one? Jul 22 18:45:06 I just tried, it just went back to the original one... Jul 22 18:46:57 what is the next step? Jul 22 18:47:35 you add your files to the project, and set it up like you had before Jul 22 18:47:48 yea I dont know how to do that Jul 22 18:48:00 not sure where to add the files to Jul 22 18:48:05 not sure if paths are important Jul 22 18:48:18 it’s pretty clear Jul 22 18:48:23 the manifest, I replaced the newly generated one with the old one, and it somehow just snapped back to the old one Jul 22 18:48:26 err the new one Jul 22 18:48:27 go read the documentation on AS Jul 22 18:48:36 so start from ground zero basically Jul 22 18:48:54 I wish I hadnt just wasted an hour or two trying to create a new project Jul 22 18:49:00 it isn't anything anywhere near straight forward Jul 22 18:49:03 and I have no idea how to do it Jul 22 18:49:08 and it didn't help me at all Jul 22 18:49:24 yes, it is Jul 22 18:49:32 it is quite straightforward, if you read the documentation Jul 22 18:49:38 what documentation? Jul 22 18:49:44 developer.android.com Jul 22 18:49:50 how to create a new project and move all items from old project to new project.com? Jul 22 18:50:13 you copy the files into it Jul 22 18:50:15 so I should just take a little break and read the entire AS documentation while 150 users in the field wait Jul 22 18:50:18 it’s really not hared Jul 22 18:50:19 hard Jul 22 18:50:30 copy what files, into where exactly, by what means? Jul 22 18:50:48 copy the source files into the new project, the same way you copy any other files Jul 22 18:51:00 and your users should still have their old devices Jul 22 18:51:02 these two projects have totally different folder structures... Jul 22 18:51:08 doesn’t matter Jul 22 18:51:29 it matters Jul 22 18:51:33 no, it doesn't Jul 22 18:51:36 copied the java files in Jul 22 18:51:39 they never show up in the project Jul 22 18:51:47 did you add them to the project? Jul 22 18:51:57 tried to find something to add files, all I see is New Jul 22 18:52:09 like i said, you need to read the documentation Jul 22 18:52:44 that doesn't have a single bit of help for this exact case Jul 22 18:52:58 for example, old project doesn't have three folders under src Jul 22 18:52:59 just one Jul 22 18:53:09 so what? Jul 22 18:53:11 it's as simple as Ctrl+C then Ctrl+V. you just have to know where to Ctrl+V Jul 22 18:53:22 I just found the right src folder Jul 22 18:53:26 the .java files are in there now Jul 22 18:53:45 what is the next item that needs brought in from old project? Jul 22 18:53:53 your keychain Jul 22 18:54:00 i mean keystore Jul 22 18:54:03 ok done Jul 22 18:54:11 and you’re going to need to set up gradle Jul 22 18:54:37 is the UI defined in the manifest? Jul 22 18:54:43 no Jul 22 18:54:53 you’re going to put the layout files in res/layotu Jul 22 18:54:55 layout Jul 22 18:56:31 Do I really need the old manifest then? I Jul 22 18:56:39 you need some things from it Jul 22 18:56:47 the list of activities/services/receivers Jul 22 18:57:08 think its better to copy and paste them into the new manifest? Jul 22 18:57:14 go ahead Jul 22 18:57:23 will the old manifest bork the project do you think? Jul 22 18:57:41 don’t know Jul 22 18:58:19 strangest thing, I replace the new with the old, open AS< and the old still loads... Jul 22 18:58:24 check paths, double check, all good, Jul 22 18:58:28 this is weird Jul 22 18:58:53 yea nevermind that, paths are different Jul 22 18:59:08 seems there is more than one androidmanifest.xml in this new project for some reason, at different paths... Jul 22 18:59:27 so next step is setup gradle Jul 22 19:11:08 I have about 1150 instances of "No resource found that matches the given name" Jul 22 19:11:26 every single .java files, and the manifest have red code Jul 22 19:12:14 did you bring your resource files over? Jul 22 19:13:02 no Jul 22 19:13:08 what is it called? Jul 22 19:13:26 do the full res folder? Jul 22 19:14:01 hmm, new project doesn't even have a res folder... Jul 22 19:14:51 oh there it is Jul 22 19:14:58 has a totally different internal structure Jul 22 19:15:44 azv4: yes, as i had mentioned before Jul 22 19:16:01 its a totally different folder structure Jul 22 19:16:09 I cant just drag and drop the highest level right? Jul 22 19:16:15 no Jul 22 19:17:10 the old has folders that dont even exist in the new project Jul 22 19:26:13 do you guys know of a walkthrough for this type of thing? Jul 22 19:26:28 that might not require a complete mastery of this IDE Jul 22 19:28:25 i dont think so. people post tips and tricks regarding the IDE but nothing in terms of a complete walkthrough Jul 22 19:28:54 so is this process even a thing? Or was it just an idea that s73v3r thought might be helpful but really had no idea what it entailed? Jul 22 19:32:55 i'm sure s73v3r knew exactly what it involved Jul 22 19:44:06 coordinatorlayout behaviours continue to baffle me Jul 22 19:45:11 yeah ... flexible, but docs don't really go into what its all about, beside a few examples of AppBarLayout or whatever Jul 22 19:45:21 Dave Smith has a good vide on it Jul 22 19:45:32 I don't want videos, they're useless Jul 22 19:45:47 they take too much time and it's hard to get back to a certain thing -.- Jul 22 19:45:47 well, then read the sources ;) Jul 22 19:46:00 do you play them on iphone? Jul 22 19:46:14 people just should stop with this making video tutorials for programming stuff Jul 22 19:46:18 it's ridiculous Jul 22 19:46:22 eeyup Jul 22 19:46:32 or at least they should write overview and source code Jul 22 19:46:42 yeah i agree, it was a recorded class Jul 22 19:47:05 Zharf, oh c'mon, don't be so old! You can't expect programmers to read! :P Jul 22 19:47:40 g00s, that's slightly excusable then Jul 22 19:47:54 the android team in general needs to institutionalize proper technical writing; it would be a culture shift. they would need somebody who's good at both tech writing to set up goals and somebody capable of culture change Jul 22 19:49:00 oh great, my view top somehow resets after I set it in onDependentLayoutChanged Jul 22 19:49:21 if you have children which do view gone / hide etc stuff goes wrong Jul 22 19:49:41 and i never found a remedy, i think sometimes CL doesn't dispatch something to the behaviors Jul 22 19:50:36 i continue my strategy in using most google APIs in the plainest and most boring sense possible to avoid corner case bugs ;) Jul 22 19:54:05 I guess I'll implement my own coordinatorlayout at this rate ;) Jul 22 19:54:22 Is it better to run bluetooth as a service or fragment? Jul 22 19:54:28 haha, good luck ;) Jul 22 19:55:09 I have the GPS running as a service :) just wondering about the bluetooth currently its inline but of course reruns on rotate Jul 22 19:55:26 i'd put both in the same service Jul 22 19:55:30 I don't get why this behavior works if the dependency is an imageview but not if it's the appbarlayout Jul 22 19:55:40 what's so special about appbarlayout Jul 22 19:55:56 Zharf not too much, but whats wrong ? Jul 22 20:00:36 I'm trying to position my views based on other views but I'm failing miserably :p Jul 22 20:02:38 seems like my behavior works for an imageview if it's height is wrap_content... not if it's 200dp or something Jul 22 20:03:58 sounds pebkac-y Jul 22 20:04:03 http://6cbba770458d6527.paste.se/ is pretty much what I have right now Jul 22 20:04:53 sure, it's me not understanding how this is supposed to work :p Jul 22 20:05:03 oh, you're making your own behavior ... yeah, i'd watch the smith video Jul 22 20:05:38 tell him to transcribe it for me Jul 22 20:05:54 you can pay for a class :) Jul 22 20:06:02 the existing behaviors are horrible, by the way Jul 22 20:06:09 g00s, why would you put them into the same service? why not have nice clean code separation Jul 22 20:06:55 Crash1hd yeah, thats kinda the problem with some of these components. Conceptually, you may want 2 services because they do different things - i'd have them seperate if their lifecycles (when started) are different Jul 22 20:07:15 but if the lifecycle is the same, like you are using GPS at the same time as BT, then i would put them in the same service Jul 22 20:08:00 is that due to a memory thing? Jul 22 20:08:04 my services tend to be very short, i have most of the code in some controller , state machine, or whatever - the service just babysits it Jul 22 20:08:07 cause they are going to have the same lifecycle Jul 22 20:08:25 I see my code changing the top of the view correctly but then I observe the top being changed to something much lower and it never hits my code in that time Jul 22 20:08:29 Crash1hd no - but services do add complexity, and if you have to coordinate 2 services its more hassle Jul 22 20:08:30 it confuses the hell out of me Jul 22 20:08:46 ahh :) I understand Jul 22 20:10:08 maybe it's doing something silly when it's measuring the view... Jul 22 20:12:48 hi how i can change the color of edittext when selected pré lolipop ? i dont need use accent Jul 22 20:21:12 I just love how google makes everything package private so you can't reuse anything without tricks or copying code Jul 22 20:30:15 does anyone know if you can access android studio “variables” from gradle? Specifically I want to get the user.token that defines the path that opens when you right click and “open in browser” ? Jul 22 20:32:05 Zharf open for extension, closed for modification :D Jul 22 20:32:11 or not open for extension haha Jul 22 20:39:04 hi. can activity be restarted/recreated in it's onDestroy() method? Jul 22 20:40:26 Have you considered just not finishing it? Jul 22 20:41:14 That question sounds funny :) Jul 22 20:43:00 just an academic interest Jul 22 20:43:41 or let's say, is there a way to cancel/stop the destroying flow Jul 22 20:43:47 no Jul 22 20:43:54 It's way too late by then. Jul 22 20:44:10 It makes no sense in UX either and in most cases onDestroy won't be called at all. Jul 22 20:44:17 even in onStop? Jul 22 20:45:09 if I call finish() it should definitely call onDestroy, right? Jul 22 20:45:31 There's no "definetly" with onDestroy(). Jul 22 20:45:54 Could you rather explain what are you trying to do, because I have a feeling you're approaching the issue in the wrong way :) Jul 22 20:46:01 onDestroy may or may not be called Jul 22 20:46:18 but after you finish, your activity is always destroyed Jul 22 20:47:42 Mavrik: just wondering if it's possible to create undestroyable activity)) Jul 22 20:47:59 No thank god. Jul 22 20:48:07 There is a kiosk API tho. Jul 22 20:48:19 Pointless, isn't it? Just click home Jul 22 20:48:59 yeah, but clicking home means activity stays in background, right? Jul 22 20:49:09 no, the OS might kill it Jul 22 20:49:16 why do you want an unkillable activity? Jul 22 20:49:17 for example when RAM is low Jul 22 20:49:36 cause I can’t come up with a reason for this that isn’t sketchy as fuck Jul 22 20:49:47 s73v3r, kiosk mode is common Jul 22 20:50:03 and the one I can, kiosk mode, has other, better ways of doing it Jul 22 20:50:12 So when RAM is low, you want to impose to the user the fact that your activity can’t be killed? Does that sound like an app you’d like to have on your phone? Jul 22 20:50:40 is onDestroy called only when system decides to kill your app when RAM is low? Jul 22 20:51:00 If your system decides to kill your app, onDestroy won't be called at all in most cases. Jul 22 20:51:01 That's when it's not called Jul 22 20:51:08 it is not specified when it is called, so don't rely on it being called in any particular circumstance. Jul 22 20:51:20 I see Jul 22 20:51:26 finish() and configuration changes calls it Jul 22 20:51:39 well,t hen it is specified then ;D Jul 22 20:51:59 SimonVT: so does finish() always call onDestroy or not? Jul 22 20:52:01 maybe it was finalize that wasn't, idk Jul 22 20:52:25 Intruder777: i haven't done any Android program for at least a year, so listen to SimonVT Jul 22 20:52:26 It does always. Unless Android kills the process between finish() and onDestroy() - then it does not Jul 22 20:52:41 However unlikely that is to happen Jul 22 20:53:10 But, just don't call finish() Jul 22 20:53:25 Configuration changes already re-create the Activity Jul 22 20:53:33 ah, no I understand what you mean by "there's no definitely" with onDestroy" Jul 22 20:53:36 *now Jul 22 20:54:31 assuming you aren't preventing configuration changes, anyway (many EGL games will do this.. nothing using the Android UI should, though I'm sure some stupidly does) Jul 22 20:55:36 and what about onStop(), is it guaranteed to fire up when you call finish()? Jul 22 20:55:56 It goes through the lifecycle as documented Jul 22 20:56:30 always (*not guaranteed to always happen) Jul 22 20:57:21 I was just looking at this answer at SO: http://stackoverflow.com/a/32508320 Jul 22 20:58:52 http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/5.1.1_r1/android/app/Activity.java#Activity.finish%28boolean%29 Jul 22 20:58:58 4637 if (false) Log.v(TAG, "Finishing self: token=" + mToken); Jul 22 20:59:02 *sigh* Jul 22 20:59:03 so looks like onStop() will be called unless finish() was done right in onCreate Jul 22 21:01:52 Makes sense, but I never looked into it Jul 22 21:03:21 "Cyanogen Inc. is undergoing major layoffs, may "pivot" to apps" Jul 22 21:03:49 :D Jul 22 21:03:51 That company. Jul 22 21:07:00 aw, moto g4 sounded good, i guess their update policy isn't so any more http://arstechnica.com/gadgets/2016/07/review-without-quick-updates-the-moto-g4-is-merely-good-not-great/ Jul 22 21:08:51 Costing about the same as Nexus 5X, this is a dumb purchase. Jul 22 21:31:55 adq http://www.gizmag.com/korg-tm50tr-tuner-metronome-tone-trainer/44504/ Jul 22 22:32:03 hello, i am unsure why onpostexecute is not executing Jul 22 22:32:10 onpostexecute is getting called Jul 22 22:32:28 even though doinbackground is called Jul 22 22:35:34 every result i found by searching is related to parameters, but parameter is correct Jul 22 22:40:45 it gets called Jul 22 22:40:47 you're doing it wrong Jul 22 22:40:49 end of story Jul 22 22:41:17 onpostexecute? Jul 22 22:41:19 no it doesnt Jul 22 22:41:29 not according to log.d Jul 22 22:43:35 missing @override with invalid method signatures Jul 22 22:45:33 no? Jul 22 22:45:42 i have override for onpostexecute Jul 22 22:45:55 if that was the case android studio would give me a warning Jul 22 22:45:59 or error Jul 22 22:46:03 * capella swing and a miss Jul 22 22:46:04 but i checked the params are right Jul 22 22:46:50 pastebin the class and depend on the kindness of strangers? Jul 22 22:48:39 http://pastie.org/private/z7iomw503h1tjoaiyy32qa Jul 22 22:48:57 even the debugger is not helpful because it never gets to onpostexecute Jul 22 22:56:57 ok i figured it out Jul 22 22:57:03 u need onpostexecute Jul 22 23:32:29 lolwut Jul 22 23:32:41 "onPostExecute doesn't work, you need onPostExecute" Jul 22 23:59:23 wha Jul 23 00:10:08 Gradle DSL method not found: 'android()' Jul 23 00:11:18 any reason? Jul 23 00:16:43 you didn't apply the android plugin Jul 23 00:16:46 already told you Jul 23 00:16:48 http://rea.tech/the-worst-thing-in-our-scala-code-futures/ Jul 23 00:16:58 hmm, that's a really good article (and has nothing to do with futures being bad) Jul 23 00:23:24 pfn: i didn't find android plugin in plugins list Jul 23 00:23:32 learn2gradle Jul 23 00:23:49 every project template ever has the android plugin applied already Jul 23 00:23:55 read it and apply it to your own project Jul 23 00:25:44 yes that's why I am confused. it is the sample project from android sdk. i don't know why this happened Jul 23 00:26:36 be specific, what sample project Jul 23 00:27:13 PdfRendererBasic1 Jul 23 00:27:39 the samples have fucked up gradle files Jul 23 00:27:41 file an issue Jul 23 00:28:19 how to apply android plugin? Jul 23 00:28:22 actually, no it doesn't Jul 23 00:28:28 Application/build.gradle is correct Jul 23 00:29:28 :Application:assembleDebug Jul 23 00:29:28 BUILD SUCCESSFUL Jul 23 00:29:28 Total time: 12.81 secs [pfnguyen@galactica PdfRendererBasic] $ Jul 23 00:29:35 works for me Jul 23 00:38:31 it seems android studio does not multi tasking. when downloading, everything else freezes. Jul 23 00:39:02 Hi, Where can I get the source for the platform tools from the android SDK? Jul 23 00:41:19 tools/base in aosp Jul 23 00:43:07 in my android-master checkout tools exist but not base? Jul 23 00:44:37 where is the show the welcome screen? Jul 23 00:45:09 cd .. Jul 23 00:45:52 If I cd into tools no base directory exists for the platform tools like adb and fastboot. Jul 23 00:47:48 pfn: now it tries build. but ..Error:(3, 5) No resource found that matches the given name (at 'cardBackgroundColor' with value '?android:attr/colorBackgroundFloating'). Jul 23 00:48:00 If I wish to download just the platform tools sources is this possible? Jul 23 00:48:29 pfn: i want to delete and re import the sample project. Jul 23 00:50:21 pfn: i forget how to import the sample project Jul 23 00:55:07 Is there a better channel for asking about where to get the platform tools source? Jul 23 00:59:40 pfn: re imported the sample project, still the same error. what android version are you using? mine is 23 Jul 23 01:02:38 pfn: sorry. my sdk version set to 21. set to 23 solved the problem Jul 23 01:03:33 pfn: Information:BUILD SUCCESSFUL Total time: 8.349 secs Jul 23 01:03:42 pfn: faster than you Jul 23 01:04:00 What are you building? Jul 23 01:04:43 > 8.349 secs Jul 23 01:04:43 :< Jul 23 01:04:51 My builds aways take nearly a minute Jul 23 01:04:53 I need moar ram Jul 23 01:06:51 OverCoder: it depends on project. i was just testing on sample project which is simple Jul 23 01:07:50 I was compiling Hello World juts now Jul 23 01:07:51 :P Jul 23 01:08:00 But with an AR library in there Jul 23 01:08:13 pfn: the emulator starts very very slowly. how to speed it up? Jul 23 01:08:32 OverCoder: how much is your ram? Jul 23 01:09:15 bq: you don’t. you use a device Jul 23 01:09:27 bq, 2GB :< Jul 23 01:09:36 bq, also install HAXM if you use Intel CPU Jul 23 01:10:40 s73v3r: my device doesn't show up Jul 23 01:11:09 OverCoder: mine 8GB. but it is almost full now. Jul 23 01:11:35 bq, that's my point :P Jul 23 01:11:39 I have 4GB swap right now \o/ Jul 23 01:11:46 The HDD is dying now Jul 23 01:13:30 OverCoder: 2GB seems too low for android dev Jul 23 01:14:31 s/too low/dead low/ Jul 23 01:14:42 I mean Chrome + Windows 10 = ~3GB Jul 23 01:14:50 So idk where should AS fit Jul 23 01:16:20 how to check HAXM is used or not? Jul 23 01:16:31 i use Intel cpu Jul 23 01:21:28 fuck. HAXM does not compatible with Linux Jul 23 01:22:02 so Linux platform suffers with slow emulator Jul 23 01:23:24 every platform has a slow emulator Jul 23 01:24:38 s73v3r: HAXM suppose speed up emulator on windows Jul 23 01:25:20 s73v3r: why my device does not show with studio? how to let it show Jul 23 01:26:11 hm.. does anyone have an idea why the following is happening to me?: I copied an android project I made to drive D: (Windows) and now it supposedly cannot find AndroidManifest.xml (it is searching within src-folder, but the AndroidManifest.xml is under app/src/AndroidManifest.xml) - does anyone know where to adjust this path? Jul 23 01:29:46 how to show real device with adb on linux? Jul 23 01:30:16 " Code that used custom Parcelable objects with AlarmManager that might have worked on older versions of Android will not work on Android N." Jul 23 01:34:54 AS is really a POS D: Jul 23 01:37:04 why haxm won't be enabled if i choose RAM less than a gb? Jul 23 02:37:54 Just learned about Uncle Bob. SO many videos. Anyone have any MUST watch videos from him? I need things to watch at bedtime! **** ENDING LOGGING AT Sat Jul 23 02:59:58 2016