**** BEGIN LOGGING AT Wed Mar 04 02:59:58 2015 Mar 04 03:01:11 g00s__, err, let me see :P. I'm new with all this. Mar 04 03:01:42 keniobats its in your build.gradle Mar 04 03:02:48 g00s__, it only says com.android.tools.build:gradle:1.1.0. Mar 04 03:02:57 Is that? Mar 04 03:02:59 keniobats change that to 1.1.2 Mar 04 03:03:13 ok Mar 04 03:03:19 i use 1.1.+ Mar 04 03:03:50 then you will have to sync your gradle things Mar 04 03:03:57 in android studio Mar 04 03:05:37 g00s__, it seems to be upgrading all, i'll be back to you in a minute Mar 04 03:06:41 g00s__, Error:failed to find target android-9 : /Users/keniobats/Downloads/sdk, i'll check my sdk config Mar 04 03:09:34 Trying to enable disk caching in OkHttp but it doesn't seem to be working. Mar 04 03:09:44 Here are the response headers for a reddit-post-listing response: http://pastebin.com/nRcAJiTK Mar 04 03:10:00 I've tried setting "cache-control" to "max-age=60". I'm also reading the entire response. Mar 04 03:10:34 Peace out TacticalJoke Mar 04 03:10:38 Later. Mar 04 03:10:52 (Response caching is working fine for images in Picasso, though.) Mar 04 03:11:06 Is OkHttp not liking reddit or something? Mar 04 03:19:56 TacticalJoke: huh, you actually get ratelimit headers, for some reason I don't get them through either the normal endpoint or oauth Mar 04 03:20:07 not sure about okhttp though Mar 04 03:20:15 Is it because you're not logged in? I'm not sure. Mar 04 03:20:29 Then again, with OAuth 2 I think I'd expect rate limits regardless. Mar 04 03:20:39 yeah that's what they were saying in that channel Mar 04 03:21:12 can any view have an adapter? Mar 04 03:22:06 only adapterview subclasses i would think? Mar 04 03:24:39 Just cloned a copy of LatinIME. Any way someone could help me build this in Android Studio? Mar 04 03:24:56 damien5314: Are you using something other than OkHttp? Just curious. Mar 04 03:25:26 g00s__, it seems to work :D, thanks a lot!, I was struggling with this. Mar 04 03:26:44 TacticalJoke Mar 04 03:26:55 i use retrofit which has that i think Mar 04 03:27:07 haven't really configured okhttp at all though Mar 04 03:30:18 keniobats cool Mar 04 03:33:28 hi Mar 04 03:33:46 I need an IOS/Android developer and UI designer Mar 04 03:34:19 no soliciting Mar 04 03:34:30 what's the usual rate ? Mar 04 03:39:57 Using Picasso, I'm getting an OutOfMemory error (seen in onImageLoadFailed) every other time I load this image: . Is it typical to get OOMs in such cases? (I'm new to Picasso.) Mar 04 03:40:07 every other time = one in two times Mar 04 03:40:44 damn. i'm hungry Mar 04 03:42:03 hesperaux: http://www.reddit.com/r/foodporn Mar 04 03:42:14 Dem donuts tho. Mar 04 03:42:42 dude this is evil Mar 04 03:46:15 one day ill learn how to make a half decent UI, until them I'm stuck to making shitty apps Mar 04 03:46:53 i can wire everything together, it just ends up looking like shit :/ Mar 04 03:47:37 DadFoundMy: Pics? Mar 04 03:48:52 yeah one sec Mar 04 03:50:04 TacticalJoke, that one line is a whole sentence Mar 04 03:51:37 Which line? Mar 04 03:53:10 TacticalJoke: these are screens from my current project. I have even began to think about UI other than super basic elements, but i dont even know how I can possibly make it look "nice" http://imgur.com/a/CSdq8 Mar 04 03:53:34 like i plan on make it fit material design patterns, but even still i feel as though its too "basic" Mar 04 03:55:08 I like the simplicity, personally Mar 04 03:55:13 Minimalism FTW. Mar 04 03:55:35 If you switched to AppCompat and made that bottom button a floating action button, that'd give it some nice polish. Mar 04 03:55:53 DadFoundMy: http://www.google.co.uk/design/spec/components/buttons.html#buttons-floating-action-button Mar 04 03:56:07 I hate those action buttons Mar 04 03:56:15 Mar 04 03:56:16 TacticalJoke: yeah tomroow my plan is to "materialize" the app. Im going to add most of the buttons to the actionbar and have one FAB for adding an assignment Mar 04 03:56:19 I hate them most of the time, but here they seem to make sense. Mar 04 03:56:45 i hate them when there overused, but i like them for 1 action that is used a lot Mar 04 03:56:56 like gmail uses is nicely for composing a email Mar 04 03:57:06 I don't like the one in gmail, even Mar 04 03:57:07 and in this case users will be adding assignments very frequently Mar 04 03:58:03 DadFoundMy: I guess you could add a little padding. Maybe remove those ListView dividers? Mar 04 03:58:06 the worst example of it is Sync for Reddit. Has one on the sreen at all times to make a post or comment, but 90% of users just view reddit Mar 04 03:58:09 Make padding more consistent. Mar 04 03:59:01 TacticalJoke: i plan on making the padding consistent with material design, i feel like without the dividers it would look really jumbled Mar 04 03:59:06 maybe ill try it without though Mar 04 03:59:19 DadFoundMy, perhaps if you used a card type object instead of a list item Mar 04 03:59:38 There are examples here without dividers that look good: http://www.google.co.uk/design/spec/components/lists.html Mar 04 03:59:39 the view that is inflated (either by recyclerview or listview) can have its own style and separation from the other items Mar 04 03:59:45 hesperaux: oo thats a good idea i hadnt even considered Mar 04 04:00:35 TacticalJoke: yeah i think it would actually work if i add an ImageView to each view which i was planning on doing already Mar 04 04:01:17 DadFoundMy: Yeah, I think a good design principle (at least on Android) is to focus on the content while keeping UI elements really simple, so that the content stands out on its own. Mar 04 04:01:47 don't add images unless they belong there and provide useful info, going with what TacticalJoke just said Mar 04 04:02:05 If all android phones runs on vanilla android, it would be just great. Mar 04 04:51:19 Is there a simple way of getting the Content-Type header from a Picasso download? (The only way I can think of involves request interceptors.) Mar 04 04:52:00 s/request/response/ Mar 04 05:00:32 weird, Date&TimePicker extend AlertDialog, NumberPicker extends LinearLayout. none ever do what i want :| Mar 04 05:10:32 I had fun tinkering w/NumberPicker once :) Mar 04 05:10:40 YES!!!! I'm going to be a speaker at DroidCon!! \O/ Mar 04 05:11:08 MikeWallaceDev what about ? Mar 04 05:11:15 capella who won :D Mar 04 05:11:37 Your talk "An Introduction to the Spanned family of classes" has been selected by our team for Droidcon Montreal 2015 \o/! Mar 04 05:11:45 g00s__ I did eventually ... I souped it up inside a dialog box with some extra stuff Mar 04 05:12:01 capella screenshot or it didn't happen Mar 04 05:12:10 nice MikeWallaceDev Mar 04 05:12:14 I might have that ... Mar 04 05:12:30 thanks g00s__ Mar 04 05:12:32 :) Mar 04 05:13:35 Grats MikeWallaceDev Mar 04 05:13:49 thank CedricBeust_ :) Mar 04 05:14:01 g00s__ https://bug917736.bugzilla.mozilla.org/attachment.cgi?id=806566 something like this Mar 04 05:14:06 are you in France now CedricBeust ? Mar 04 05:14:12 No Mar 04 05:14:18 oh. Mar 04 05:14:38 I might be getting a 3 month contract in Paris... I should find out soon Mar 04 05:17:58 g00s__ also this ... http://arstechnica.com/security/20...ipples-https-crypto-protection/ Mar 04 05:17:59 "... both the Android and the Windows versions of Firefox are immune to the attack. " Mar 04 05:18:58 capella does that require a patch to the underlying OS - is it openssl again ? Mar 04 05:19:08 once more, Moz wins the internet \o/ take *that* google, and your "no gsoc for mozilla" Mar 04 05:19:15 g00s: hmmm? Mar 04 05:19:19 yeah i saw that Mar 04 05:19:29 to fix freak is that patching openssl ? Mar 04 05:19:34 It's an https export cert bug Mar 04 05:20:24 Thanks to Bill Clinton and his "Let's cripple encryption to people we export to" Mar 04 05:21:31 The key problem is that OpenSSL and Safari both contain bugs that cause them to accept "RSA export-grade keys even when the client didn't ask for export-grade RSA." Mar 04 05:21:51 yep Mar 04 05:22:50 "If you're using Android on your device, you should use Chrome instead of the Android browser until a patch for it has been released." Mar 04 05:23:04 let the android updates begin ! \o/ Mar 04 05:23:13 *silence* Mar 04 05:24:00 talking about FREAK? Mar 04 05:24:03 Just get Fennec Mar 04 05:26:18 the last time i got fennec it crashed Mar 04 05:26:36 and it put that stupid thing on my lock screen :) Mar 04 05:26:59 no more fennec for a while. i think chrome is ok Mar 04 05:27:44 its almost as if android hates web browsers Mar 04 05:28:06 it's in the manifesto Mar 04 05:28:10 i keep getting the 'process limit exceeded' thing in chrome, and its janky Mar 04 05:28:17 AndroidManifesto.xml! Mar 04 05:28:22 lol Mar 04 05:28:23 haha Mar 04 05:28:24 capella: The Firefox Hello thing worries me a little. I'm concerned they're heading in the wrong direction. Mar 04 05:28:42 isn't that just a website ? Mar 04 05:28:42 Firefox Hello? The phone thing? Mar 04 05:28:57 Yeah, the video/call thing. Mar 04 05:29:00 i thought it was just a website that uses webrtc Mar 04 05:29:05 g00s: Oh, maybe. Mar 04 05:29:51 Yah, Moz has made a few confusing moves in the last year ... that EME thing is weird Mar 04 05:30:27 But everyone else is doing it ! :/ Mar 04 05:32:14 And yahoo search ?? Mar 04 05:32:41 on desktop i just put in ddg Mar 04 05:34:04 Damn, I've got to stop over-conceptualizing my code ... I wind up taking out half the stuff I prep up in the beginning to get it past the reviewers Mar 04 05:34:27 I want Firefox to destroy Google Chrome on desktop, but I don't see it happening. ;| Mar 04 05:34:42 Just a simple, slim browser. Mar 04 05:34:49 Terminal Mar 04 05:34:53 Crush! Kill! Destroy! Mar 04 05:35:08 curl Mar 04 05:35:28 "Lost in Space" reference nobody here ever heard of :p Mar 04 05:35:45 Mss Piggie ? Mar 04 05:36:11 Not PIGS in Space XD Mar 04 05:36:20 oh Mar 04 05:36:22 where they can indeed fly Mar 04 05:36:41 Though I absolutely love the Muppets :D Mar 04 05:38:39 hmmm. i need to let a user select a sampling duration between 2 seconds and 1 day. with log scale its still many choices Mar 04 05:39:07 (17 items) Mar 04 05:39:44 How many items do you want? Mar 04 05:39:45 wonder if i should leave it as items in listpreference or make some numberpicker Mar 04 05:40:42 well they need to be able to choose between those intervals (2 sec , 1 day) Mar 04 05:40:57 2s, 5s, 10s, 20s, 30s, 1min ... etc Mar 04 05:41:22 AHHHHHH Mar 04 05:42:28 so either listpreference or custom preference with numberpicker + 3-way radio group for units (s, min, hours) Mar 04 05:42:29 No matter what I do, OkHttp won't cache reddit listings. Mar 04 05:43:34 from what i understand, seekbar kinda of things aren't recommended for log scales Mar 04 05:43:57 usability wise, that is Mar 04 05:48:02 omh NumberPicker is 2600 lines of code :O Mar 04 06:02:25 Meh, not too bad for Java Mar 04 06:22:01 Are there any docs on the Browser database? http://developer.android.com/reference/android/provider/Browser.html Mar 04 06:30:36 OkHttp appears to be creating a cache (I checked with "adb shell"), but it's not using it (if I set "Cache-Control: only-if-cached" on the request then I get a 504). What could be causing this? Mar 04 06:31:25 I'm making sure I'm reading a full response and making sure that the response has "Cache-Control: max-age=99999". Mar 04 06:39:10 httpClient.getCache().getHitCount() always returns 0. Mar 04 06:40:51 Do I need to do anything special with the reading? I'm just using "responseBody.byteStream()" and parsing through that. Mar 04 07:18:15 StrictMode doesn't warn me about File.mkdirs. Is that not blocking? Mar 04 07:20:46 TacticalJoke: Maybe too fast? Mar 04 07:21:06 hey, how do you create circle icons like in gmail? Mar 04 07:21:16 TacticalJoke: I tend to trust strictmode Mar 04 07:21:28 joroci: create a bitmap and mask it Mar 04 07:22:06 CedricBeust: Oh, speed is a factor? Interesting. Mar 04 07:22:33 joroci: https://github.com/hdodenhof/CircleImageView Mar 04 07:24:18 thanks thepoosh Mar 04 07:24:22 np Mar 04 07:28:09 Hmm, is it okay to say "new com.squareup.okhttp.Cache(...)" on the main thread? It seems to do file IO. ;o Mar 04 07:28:33 StrictMode doesn't have a problem with it, and as far as I can see Picasso does it, but the code looks like IO code. Mar 04 07:34:31 hey anyone have exp with GCMS? Mar 04 07:34:50 google cloud messaging service, not gas chromatography mass spectra Mar 04 07:34:55 I'm gettin HTTP/1.1 401 Unauthorized Mar 04 07:35:08 Tricknology_: What about it? Mar 04 07:36:21 http://pastebin.com/i65dJKvx Mar 04 07:37:03 google is returning 401 Mar 04 07:38:05 maybe my ip is not whitelisted? Mar 04 07:38:19 By default it should be for all ip's Mar 04 07:38:44 Make sure you're using the URL fot HTTP and not XMPP maybe? Mar 04 07:39:20 https://android.googleapis.com/gcm/send Mar 04 07:39:24 obviously double check your key Mar 04 07:39:38 if i can connect to the console... Mar 04 07:40:00 can you? Mar 04 07:40:36 Also are you sending a push with registration_ids in it? Mar 04 07:40:40 https://play.google.com/apps/publish/ Mar 04 07:40:45 (probably not the problem or you wouldn't be getting a 401 though) Mar 04 07:40:51 registration id's? Mar 04 07:41:02 you mean the gcm reg id's? Mar 04 07:41:36 The call you're making is to send pushes to devices Mar 04 07:41:41 yes Mar 04 07:41:49 the json payload should contain the registration_ids of these devices Mar 04 07:42:02 I can get a dump of it Mar 04 07:42:07 Im pretty sure it's there Mar 04 07:43:26 Again, probably not the problem but I'm not sure what the GCM servers would send back if you send an empty payload Mar 04 07:44:03 http://pastebin.com/WS3TKMnQ Mar 04 07:44:36 uuh Mar 04 07:44:44 i might see the problem.. Mar 04 07:44:44 ids* Mar 04 07:44:57 {"data":[{"alert" Mar 04 07:45:08 { Mar 04 07:45:08 "data": { Mar 04 07:45:08 "title": Mar 04 07:45:13 you misspelled registration_ids (plural) Mar 04 07:45:14 oops.. Mar 04 07:45:17 ah god Mar 04 07:46:27 Let's if that caused the 401 Mar 04 07:46:29 I only want to send to one device at a time Mar 04 07:46:30 let's see* Mar 04 07:46:46 I alo think it's because data's object is an array? Mar 04 07:46:49 If you're sending the same data, use one push. Otherwise, use multiple pushes Mar 04 07:46:55 Yes that too Mar 04 07:47:12 I am, this is one push, a list to one device.. next push is next device with a different list Mar 04 07:47:17 Amazing so many people use JSON arrays, I see this idiocy in stupid APIs all the time Mar 04 07:47:46 PSA: If you ever write an API, never return a JSON array, always return a JSON object with an array inside Mar 04 07:48:30 That's a good PSA Mar 04 07:48:54 I can think of one place where I do that but I dont see a reason why not, beacuse the method that calls it packs it up right away Mar 04 07:49:57 The main reason is backward compatibility. If one day you want to return something with a different shape, you're screwed if you were returning an array Mar 04 07:50:05 lol@using append Mar 04 07:50:13 If instead you return { data: [...] } then you can now return { datav2: ... } Mar 04 07:50:21 true that Mar 04 07:50:26 I think I'll go change that Mar 04 07:50:31 and you're not breaking anyone any more Mar 04 07:52:39 thanks Mar 04 07:52:51 breaking my code though Mar 04 07:52:53 lol Mar 04 07:53:01 Last time it breaks :) Mar 04 07:54:33 there Mar 04 07:54:34 hahha Mar 04 08:00:46 closer.. but still 401 Mar 04 08:01:44 {"data":{"alert":"bogeys","bogeylist":{"bogeylist":[]}},"registration_ids":["APA91bHX6D7y_XyG1 Mar 04 08:02:44 If your API key is correct (triple check that), check the registration_id then Mar 04 08:02:51 (although again, I don't think you'd get a 401 if it was bogus) Mar 04 08:03:38 Also check the dashboard and make sure your app is enabled for GCM Mar 04 08:03:54 app is not on store yet.. that might be a problem Mar 04 08:04:23 u think it might be? Mar 04 08:04:34 No Mar 04 08:04:42 You can sign it up for GCM before being in the store Mar 04 08:06:23 ip changed :/ Mar 04 08:07:11 Don't whitelist a specific IP, too much margin to screw you over during dev time Mar 04 08:07:24 range with *? Mar 04 08:07:36 I forget the exact syntax, look it up Mar 04 08:07:39 whitelist ALL THE THINGS Mar 04 08:07:51 0/255 Mar 04 08:09:12 nvm Mar 04 08:10:21 Hey. Is it possible to send notificaiton from BEACON to the device? Mar 04 08:10:26 Or rather, activate my app (when near BEACON) , for a while - make a request - then send notification to device from the app depending on the request ? Mar 04 08:11:42 25$ for a dev account, now that sucks. Mar 04 08:11:58 hahaha thats the funniest thing i've heard all day Mar 04 08:12:17 sorry, I think it's cheap. It's lifetime, unlimited apps Mar 04 08:12:24 Apple is 199/yr Mar 04 08:12:30 I am trying to earn money, not spend my budget on it. :/ Mar 04 08:12:37 Tricknology_: 99$ Mar 04 08:12:44 ah well still Mar 04 08:12:46 Look at it as an investment Mar 04 08:12:54 1/4 the price for a lifetime sub Mar 04 08:13:11 ** Mar 04 08:13:23 I need to get a credit card first. Mar 04 08:13:42 you can get a visa gift card Mar 04 08:14:20 bluesm what do you mean BEACON? Mar 04 08:17:32 He ment bacon. Mar 04 08:20:52 thought so Mar 04 08:20:55 HTTP/1.1 401 Unauthorized :( Mar 04 08:22:46 http://pastebin.com/vK86WUDH Mar 04 08:25:45 a lifetime subscription to bacon? Mar 04 08:25:48 where do I sign up? Mar 04 08:26:02 Pig farmer application________________X Mar 04 08:28:40 HA Mar 04 08:28:43 I got it... Mar 04 08:29:11 @CedricBeust. at some point the GCMids were going into a database, with prepared statements Mar 04 08:29:35 wait neverming... Mar 04 08:29:40 it was the api_key Mar 04 08:29:54 ond one had a "-" in it. new one doesnt.. new one works Mar 04 08:29:58 old* Mar 04 08:44:13 TacticalJoke you there ? Mar 04 08:48:16 Yeah. Mar 04 08:50:52 oh, i think it was bad study on refactoring. nm Mar 04 08:58:05 I'm curious anyway if you still have the link. :) Mar 04 08:58:25 I just spent hours reading the Picasso and the OkHttp source. I'm surprised by how small Picasso is (I had assumed it was gonna be huge). Mar 04 09:04:42 TacticalJoke http://developers.slashdot.org/story/15/03/03/2229212/study-refactoring-doesnt-improve-code-quality Mar 04 09:07:01 i need to write a test for a service and i have test scenarios of two instances of same service but on two different applications Mar 04 09:07:02 Weird. "Not easier to analyze and change but maybe more maintainable" sounds contradictory. Mar 04 09:09:33 testing a service is different than testing two services Mar 04 09:17:48 I wish Slashdot would redesign their site. Mar 04 09:17:56 Turns out that we don't like in 1995 anymore. Mar 04 09:18:18 Okay, 1997. Mar 04 09:23:55 TacticalJoke +1 Mar 04 09:24:35 agreed! Mar 04 09:25:04 It's a shame, because they have good content. Mar 04 09:25:04 napster: ! Mar 04 09:25:16 morning fellas Mar 04 09:29:52 morning. morning Mar 04 09:29:57 hihi Mar 04 09:32:41 hi] Mar 04 09:34:02 oh, it's the wrong time of the day Mar 04 09:36:43 Good Morning Angels Mar 04 09:37:16 every morning I think about developing an app that attracts millions of users. every evening I throw away the dream for the next day. Mar 04 09:41:40 I need killer app ideas fellas... killer ideas Mar 04 09:42:48 so I have a bunch of private variables for my views in a fragment that I define in OnCreateView(). would OnResume() a better place to Mar 04 09:42:55 ..do that? Mar 04 09:43:13 probably not Mar 04 09:43:24 teegee, then they'll get redefined on every resume call Mar 04 09:43:31 unless thats what you want Mar 04 09:43:55 no Mar 04 09:45:15 I'm trying to figure out why my app crashes when the screen rotates. I know that this causes a destroy and recreate Mar 04 09:45:31 and i'm getting null pointer exceptions Mar 04 09:45:46 pastebin code + stacktrace Mar 04 09:46:01 teegee: why not in onStart? Mar 04 09:46:53 What is the effect of activity's life cycle on Volley? Mar 04 09:48:15 andot: once a request makes it in to the RequestQueue it will runn unless cancelled Mar 04 09:48:42 even if the activity is destroyed? Mar 04 09:48:47 and if the callbacks are created from within the Activity they will be held by the queue until the request finishes Mar 04 09:49:56 thepoosh: It's my first app, I followed an example. that's why :) Mar 04 09:50:32 thepoosh can volley be used for long running tasks? Mar 04 09:50:51 andot: it's a bad idea Mar 04 09:50:58 you should read their use-case Mar 04 09:51:29 maybe try retrofit with RxJava Mar 04 09:52:24 here's the class that throws the error: http://pastebin.com/7k5Vu14T and the logcat output: http://pastebin.com/b12TYh7t Mar 04 09:53:04 first time the screen rotates, all is well. but the second time i get the null pointer in saveInputs() Mar 04 09:54:31 at de.mugiri.lambdanu.FragmentTabAbs.saveInputs(FragmentTabAbs.java:254) Mar 04 09:54:38 what happens in line #254 Mar 04 09:54:44 this isn't a fragment, so I'd have to extend Parcelable and save its state? Mar 04 09:55:04 thepoosh ok I will try that. One last question: can any one of retrofit or volley be used to download audio files(".mp3")? Mar 04 09:55:27 254: SharedPreferences.Editor editor = pref.edit(); Mar 04 09:55:37 prefs is null Mar 04 09:55:43 exactly :) Mar 04 09:56:23 it's defined in onCreateView() Mar 04 09:57:14 it shouldn't be defined there Mar 04 09:57:25 onStart or onCreate are the places to define this Mar 04 09:57:49 i'll put it in onstart Mar 04 10:01:49 should I also fill my edittexts and spinners in onStart()? Mar 04 10:03:30 here's the fragment class: http://pastebin.com/whLfbJQX Mar 04 10:07:00 Google Play Services require Google Play installation right? Mar 04 10:07:33 Looking at using location API vs some cargo code Mar 04 10:12:58 teegee: the place to initialise members is onStart or onCreate, the place to fill information in views is onViewCreated or onCreateView Mar 04 10:18:13 alright folks, is there any way to change the background color of a button in a backcompatible way Mar 04 10:24:20 thepoosh: it doesn't seem to call onStart() when I rotate the screen back from horizontal to vertical Mar 04 10:26:56 oh boo, appcompat doesnt support buttons. wtf Mar 04 10:27:10 is that because it's resuming the instance it created earlier? Mar 04 10:28:00 hey anyone know how I can do this... http://stackoverflow.com/questions/28852050/how-to-create-a-horizontal-list-view-android Mar 04 10:30:39 lol. Mar 04 10:30:48 “Only some of the most common widgets have been updated so far.” - EXCEPT BUTTONS! Mar 04 10:31:54 also, onCreateView() executes before onStart(). I find it wasteful to find all my views in onCreateView() so I can populate them and then find them again in onStart() just to save them in private variables Mar 04 10:38:49 knapper_tech: Fused Location Provider is part of AOSP, it should be possible to use it if you don't want to depend on Play services (which will have to be installed to use your app, yes) Mar 04 10:39:48 without Play services, normally you only have GPS but the user may install another network location provider. but FLP abstracts that away and gives you the best location Mar 04 10:43:27 teegee: when configuration changes the entire lifecycle is called Mar 04 11:20:09 i really wana discuss testing on android specifically service, and i have a service which needs to be tested against another as they commuinicate through intents Mar 04 11:21:19 http://developer.android.com/tools/testing/testing_android.html Mar 04 11:23:10 regan: i went through this Mar 04 11:23:20 i went through the source code of the testing as well... Mar 04 11:23:36 i wanna talk to someone who have written some of this stuff Mar 04 11:23:51 anda how do i run the same service twice, can i test it in different applicaiton domains? Mar 04 11:24:18 is there a way to write a test which tests behaviour of two applicaitons Mar 04 11:26:10 um, I don’t think services work like that a service is a service and dalvik just pushes stuff at whatevers registered and accepting… I think. I am confuse by what you are attempt and its way to late at night Mar 04 11:26:47 hello, how will i prevent proguard from removing this public boolean onMenuOpened(int featureId, Menu menu) {} Mar 04 11:27:27 isn;t there something in the documentation on proguard which says exclude this class. Mar 04 11:27:30 Hello! I have class com.example.test.MyClass. Proguard remove it. I trying to protect using "-keep class com.example.test.MyClass" but it doesn't help! Please help :( Mar 04 11:29:29 Hi Guys, how do you make a button always on the right side? what property? thanks! Mar 04 11:29:32 thepoosh: I worked it out. I called a method of my fragment in onStop() of my MainActivity. By the time MainActivity.onStop() got called, fragment was already part destroyed and the members reset to null Mar 04 11:29:52 night Mar 04 11:30:24 yes Mar 04 11:30:30 that is how things work Mar 04 11:30:32 afk Mar 04 11:35:21 RecyclerView, I am setting my OnClickListner in the HolderView, on the view it's constructor is provided. Mar 04 11:35:27 But the onClick is never being fired Mar 04 11:35:30 any idea why? Mar 04 11:45:06 gnight Mar 04 11:45:52 and thanks for the help Mar 04 11:48:03 testing is a virtue Mar 04 11:54:01 I'm looking for simple code examples to read mifare tags... sgestions? Mar 04 12:01:08 My project is using OkHttp 2.2, and Picasso seems to be using OkHttp 2.1. Is there a way to fix this? Mar 04 12:03:21 RecyclerView, I am setting my OnClickListner in the HolderView, on the view it's constructor is provided. But the onClick is never being fired. any idea why? Mar 04 12:06:19 SheikhAman: there might be a child that catches the onClick event Mar 04 12:06:39 or maybe there is a clickable:false Mar 04 12:06:44 anyone have used some testing suite? i need to test installing uninstalling mutliple apk's... Mar 04 12:07:35 good idea Mar 04 12:07:39 spotted a view which did that Mar 04 12:07:42 checking for it now Mar 04 12:12:21 thepoosh, it worked man! Mar 04 12:12:26 :P Mar 04 12:12:38 thepoosh, I wasted 2 hours figuring out and reading stuff Mar 04 12:12:39 pheww Mar 04 12:12:40 Thanks! Mar 04 12:12:45 np Mar 04 12:19:36 Hi Guys, whats wrong with this code http://pastebin.com/94SRuNFw ? I get NullPException on line 9 and 23 Mar 04 12:20:37 It's line 10, right? Mar 04 12:21:33 TacticalJoke: I think No,. Mar 04 12:22:01 not on line 9 Mar 04 12:22:27 there is nothing to cause NPE on line 9 Mar 04 12:22:41 anyone has ever written tests? Mar 04 12:22:52 lemonxah: thanks for the tip Mar 04 12:23:10 AndroidNewb: Is there a ListView with the ID 'listView' in activity_main.xml? Mar 04 12:23:32 if that is the issue then the NPE is on line 10 :) Mar 04 12:23:34 TacticalJoke: No, I think I found the problem. Your Right! Mar 04 12:24:53 Where do I have to put all my buttons and ListView, is it on the activity_main or fragment_main? Mar 04 12:25:05 because I put it on my fragment main Mar 04 12:25:15 JakeWharton: Are you online? Mar 04 12:25:33 AndroidNewb: Depends on whether you want them on the fragment. Mar 04 12:26:23 every since the Android IDE force us to use Fragment, My Android skills is confused XD Mar 04 12:26:36 It doesn't force you to use fragments. Mar 04 12:26:48 Some people never use fragments. Mar 04 12:26:59 Don't use fragments unless you have a very good reason to. Mar 04 12:27:12 (IMO.) Mar 04 12:27:35 also dont use fragments if you dont know why you want to use them and how they work Mar 04 12:28:36 thanks for the tip guys, but I want to be an Android pro :( Mar 04 12:29:01 AndroidNewb, they problem is Mar 04 12:29:29 you are switching in a fragment and then you are calling findViewById for r.idl.listView Mar 04 12:29:36 is that listview in your fragment? Mar 04 12:29:45 I don't see the connection between using fragments here and being a pro. Mar 04 12:29:47 if so you need to do this populateListVIew in the fragment Mar 04 12:29:54 What is fragments aren't appropriate here? Then a pro wouldn't use them. Mar 04 12:29:57 just kidding. I'll use fragments when I'm experienced already Mar 04 12:29:58 if* Mar 04 12:30:27 ok, thanks, I'll internalized that Mar 04 12:30:56 cause you are trying to get a view that is on the fragment from the activity and you cant do that Mar 04 12:31:07 well .. it can be done in a way but it shouldn't be done Mar 04 12:31:46 lemonxah: Ok, Got it! Mar 04 12:31:59 but soon I'll be like you guys. Mar 04 12:32:16 working now AndroidNewb ? Mar 04 12:32:44 lemonxah: yup, let me just recheck. Mar 04 12:33:50 problem now, is that it's not showing the text array in the listview Mar 04 12:35:28 show all the code Mar 04 12:35:33 the entire fragment Mar 04 12:35:37 and the entire activity Mar 04 12:35:52 lemonxah: ok, give me 3mins Mar 04 12:38:04 lemonxah: ActiviyMain http://pastebin.com/94SRuNFw notes.xml http://pastebin.com/p8YrL6W3 activity_main http://pastebin.com/GzYtcDi4 Mar 04 12:40:46 Android look at the first pastebin Mar 04 12:40:58 why are you addinga PlaceholderFragment? Mar 04 12:41:01 what are you doing with t? Mar 04 12:41:12 if you just want to populate a listview so that you can see it Mar 04 12:41:22 you have a listview in your activity_main called listviewB Mar 04 12:41:35 so you can have the populateListView() back in the main activity Mar 04 12:41:40 lemonxah: It is just default code androids puts Mar 04 12:41:52 and change line 9 to read findViewById(R.id.listviewB) and that should work Mar 04 12:41:59 take it out AndroidNewb :) Mar 04 12:42:08 take out that part that whole if Mar 04 12:42:20 ok2x. Mar 04 12:43:05 lemonxah: it worked! humble begginings Mar 04 12:43:14 I mean good start for me Mar 04 12:43:33 :P Mar 04 12:43:36 happy coding Mar 04 12:43:44 thanks! :) Mar 04 12:44:00 nobody really writes tests to his code Mar 04 12:44:15 i do Mar 04 12:44:23 but i use scala test :) Mar 04 12:48:39 What the best resource for getting buttons and other images for an app? Mar 04 12:48:52 for example the search button in this view https://developer.android.com/training/basics/actionbar/adding-buttons.html Mar 04 12:49:46 DadFoundMy, look at androido asset studio Mar 04 12:49:54 https://google.github.io/material-design-icons/ Mar 04 12:49:59 https://github.com/google/material-design-icons/releases Mar 04 12:50:10 http://romannurik.github.io/AndroidAssetStudio/ Mar 04 12:50:35 then go to Generic icon generator and pick one from the clipart Mar 04 12:50:45 or if you want actionbar ones Mar 04 12:51:00 http://romannurik.github.io/AndroidAssetStudio/icons-actionbar.html Mar 04 12:51:16 Isn't that old now? It's talking about Holo and action bars. Mar 04 12:51:29 The new material icons are smaller, I think. Mar 04 12:52:01 TacticalJoke, takea look at them though Mar 04 12:52:06 its using the new resources Mar 04 12:52:12 and its only images Mar 04 12:52:13 ahh thanks for those Mar 04 12:52:22 how do I controll z order of fragments in a fragment transaction? Mar 04 12:52:27 i was sitting here thinking i would need to design my own :D Mar 04 12:52:29 so you can gave it any way you like them Mar 04 12:53:32 cezium, what are you trying to do? Mar 04 12:53:50 2 fragments aren't supposed to be overlayed ontop of eachother Mar 04 12:53:58 the replacing fragment should go on top of the replaced Mar 04 12:54:16 that is how it works allready Mar 04 12:54:43 when doing a replace 1 fragment is hiden and the other one shown Mar 04 12:55:01 show me your code that is not working Mar 04 12:55:39 the code is working Mar 04 12:55:40 are you talking about animation z order? Mar 04 12:55:53 yest Mar 04 12:55:56 *yes Mar 04 12:56:13 it’s just that the replaced fragment is drawn on top of the new fragment during the animation. Mar 04 12:56:46 are you using custom animations? Mar 04 12:57:08 The oposite would look better for the effect I’m trying to achieve Mar 04 12:57:14 yes Mar 04 12:57:41 if it is custom then you can change the slide in and slide out effects Mar 04 12:58:15 TacticalJoke: stupid question how do i get those icons out of that webpage and into my drawable folder? Mar 04 12:58:28 im looking at the google github material design ones Mar 04 12:59:51 I think you have to click one of the downloads here: https://github.com/google/material-design-icons/releases Mar 04 13:00:12 oh alright thanks Mar 04 13:01:04 lemonxah: android:zAdjustment only works for window animations Mar 04 13:01:04 cezium, you can try Mar 04 13:01:05 android:zAdjustment Mar 04 13:01:10 yeah Mar 04 13:01:15 so you are doing fragment ones Mar 04 13:01:18 hmm Mar 04 13:01:20 i forgot Mar 04 13:02:00 I guess I can settle for a simpler slide in/out animation and move on. Mar 04 13:02:17 http://stackoverflow.com/questions/25506713/flip-animation-in-android-for-a-fragment-transaction-setting-a-z-index-or-a-ca Mar 04 13:02:22 there is a flipping animation Mar 04 13:02:31 if you want something different Mar 04 13:02:40 next issue is that the custom animation for popping the fragment of the backstack is lost if the device is rotated. Mar 04 13:03:06 yes that is a big problem which made me not use different animations for going in or out Mar 04 13:03:18 i never spent time on it to fix it Mar 04 13:08:41 Hi, android's internal dns-resolver or dns-client supports DNSSEC, or not ? can a browser extension use local dns resolver to check website conneciton's is dnssec verified+authenticated, or not ? can browser check used-SSL/TLS-cert is DANE/TLSA dns record verified+authenticated or not ? Mar 04 13:09:21 For any imgur.com/foo URL, it seems we can go straight to the image using i.imgur.com/foo.jpg. Hmm. Mar 04 13:09:34 It's always .jpg, as well. Mar 04 13:11:25 by default Google Android uses Google's DNSSEC supported Public DNS Servers ? or does it use the DNS servers pulled out from Network adapter's DHCP conneciton ? Mar 04 13:11:32 TacticalJoke: what if it's an album? Mar 04 13:12:29 It seems to have either /gallery/ or /a/ in it, as far as I can see. Mar 04 13:12:49 I might end up just using the imgur API. But for now this is useful. Mar 04 13:14:21 https://api.imgur.com/endpoints Mar 04 13:14:40 tErik, from the network's DHCP Mar 04 13:15:23 lemonxah, thanks, thats is answer of my 2nd question, shown/posted in above/early. Mar 04 13:15:40 Yah. Mar 04 13:15:42 Hello, any way to view apps from your region in play store ? Mar 04 13:17:05 vegetablesalad19, programatically? Mar 04 13:17:37 no, sorry, perhaps not the right place for this question, but this is only android chanell I'm at Mar 04 13:17:49 there is #android try there Mar 04 13:18:13 just in play store, I'm sure I did see it loong time ago Mar 04 13:18:19 ok thanks Mar 04 13:45:24 hey guys Mar 04 13:47:34 why am I getting the unknown sources error when trying to install a signed APK on my device? Mar 04 13:47:53 Hi. I'm trying to make a Service that registers for activity recognition updates through the Google API. Does it *have* to be an IntentService, or can it be a regular one? My problem is that onHandleIntent is never called. Mar 04 13:48:41 I think I've always had the unknown sources option enabled on the devices I've ever tested on Mar 04 13:48:57 thought it was something that can be bypassed simply by signing the APK, apparently it can only by bypassed if the apk is coming from the store Mar 04 13:53:24 is there a reason why getPosition() of ArrayAdapter always returns 0? Mar 04 13:54:27 getItem() returns object corresponding to the index passed, but getPosition always returns 0, also remove() also only removes the first item. Mar 04 13:59:13 sorry about the stupid formatting http://pastebin.com/NL3xd8n4 Mar 04 14:03:28 razzledazzle: Where is 'getPosition()'? Mar 04 14:04:30 TacticalJoke, actually, that was just a test, I wanted to remove the item that was dismissed, and only the first one would get removed, ended up checking getPosition() and it always returned 0. Mar 04 14:05:34 amazing thing is, getItem() returns the correct item, while getPosition() or remove() fails to operate on the correct item with the provided reference Mar 04 14:07:02 If ArrayAdapter.getPosition returns 0, that means it found the item at the first index. Mar 04 14:07:20 Why even bother, though? Mar 04 14:07:27 Just use the List directly. Mar 04 14:09:14 razzledazzle: I got disconnected. Not sure whether you saw my messages. Mar 04 14:09:32 My TL;DR is "It's probably better to ignore these ArrayAdapter methods. They're not very useful". Mar 04 14:09:49 In fact, it's probably better to ignore ArrayAdapter completely in any non-trivial case. Mar 04 14:10:39 Well, in any case where you have something more than a very simple list. Mar 04 14:10:58 TacticalJoke, thank you! Apologies for my stupidity, never thought about using the list directly. Will try it now. Mar 04 14:12:11 http://i.imgur.com/aSPQjsU.png Uhh... Mar 04 14:12:12 Here's an example: Under the hood, ArrayAdapter.getPosition says this: "return mObjects.indexOf(item);" Mar 04 14:12:28 The iconView does ignore ALL of my paddings Mar 04 14:12:31 removeViewAt() under ListView failed though. Mar 04 14:12:53 Why would it do that? Mar 04 14:14:19 Moter8, if you're trying to create some space to the left of the ImageView, why not use margin? Mar 04 14:14:58 that works, wat Mar 04 14:16:23 tried restarting AS, changing API level, still nothing Mar 04 14:16:34 the text view has proper padding Mar 04 14:21:49 Moter8: Padding is inside the view, not outside. Mar 04 14:22:11 It's 30dp wide and you've given it 50dp of padding. The 50dp doesn't really take effect. Mar 04 14:22:23 It's just not wide enough. Mar 04 14:22:41 The TextView padding takes effect because it's wide enough. Mar 04 14:23:23 If you click the TextView you should see that it goes all the way to the left. Mar 04 14:23:30 Even when the iconView is set to wrapcontent x wrapcontent it has no padding? Mar 04 14:24:11 I think i understand "Padding is inside the view, not outside." Mar 04 14:24:14 the rest, not so much Mar 04 14:24:19 I guess there is no content to wrap. Mar 04 14:24:31 yep, it is empty Mar 04 14:24:43 Make the width match_parent, set an image source, and vary leftPadding. You'll see the image moving. Mar 04 14:25:09 But the ImageView will not move. Mar 04 14:25:10 Ahh thanks Mar 04 14:25:14 >.< Mar 04 14:27:03 God, the Twitter app is terrible. Mar 04 14:27:08 Struggles with basic stuff like YouTube links. Mar 04 14:27:20 Click YouTube link --> browser opens --> YouTube opens. Srsly? Mar 04 14:27:28 It's like they're complete novices. Mar 04 14:31:58 TacticalJoke, but it should work right? I mean it should return the correct position or even remove the correct item, its deal with Java lists, what is the problem.. Mar 04 14:32:07 *dealing Mar 04 14:34:18 getPosition should find that exact list item, yeah. Mar 04 14:34:23 But it has to be the exact same instance. Mar 04 14:34:30 so, I just came on board to this new company and they have posted stuff to google play Mar 04 14:34:37 the person in charge of that is no longer here Mar 04 14:34:44 what can I do to track back what the account was? Mar 04 14:36:57 ok, this is serious Mar 04 14:37:13 my app's domain is being appended with ".debug" even after signing it for release Mar 04 14:38:04 DammitJim, hmm, if you even lost the keystore then you are $%&§ed already Mar 04 14:38:11 because you cant put out updates to the existing apps Mar 04 14:38:20 I have a copy of the keystore Mar 04 14:38:25 Ah, I see Mar 04 14:38:39 Nobody knows the account used? Mar 04 14:38:42 Seems strange Mar 04 14:39:44 you don't understand... this place is CRAZY! Mar 04 14:40:02 the last guy left in bad terms... we only have the keystore because of some random backup that some dude made Mar 04 14:54:59 of course my fucking package is going to have .debug appended to it Mar 04 14:55:06 I've set it to do so in the applicationId Mar 04 14:59:26 what I don't get though, is that why is it falling into the debug condition when I'm signing for release Mar 04 14:59:53 what other way will I be able to get the non .debug version if not by signing the APK with my own key for release Mar 04 15:02:02 nevermind Mar 04 15:02:18 every tutorial I found about Authenticator doesn't work out of the box and every sample I found are damn huge to see the step by step to implement Authenticator :/ Mar 04 15:06:31 Hi. I'm trying to make a Service that registers for activity recognition updates through the Google API. Does it *have* to be an IntentService, or can it be a regular one? My problem is that onHandleIntent is never called. Mar 04 15:34:28 What does this mean? LogCat: W/dalvikvm( 1962): VFY: register1 v7 type 17, wanted 5 Mar 04 15:53:32 Is there a way to keep my view from automatically changing from "Expressions" (where I can see the value of my variables) to the debug screen (which doesn't show me what I want to know). This is in Eclipse Mar 04 15:54:40 Yello, is it possible to see the daily app launches your app has Mar 04 15:54:44 or daily activity somehow in the googl eplay dev portal? Mar 04 15:55:50 Bantalon, no. the store only tracks installs Mar 04 15:55:57 you need analytics if you want that. Mar 04 15:56:11 Google Analytics or any of its alternatives Mar 04 15:56:54 hi Mar 04 15:56:56 danijoo: does that work retroactively? Mar 04 15:57:00 or is it activated by default so you can see? Mar 04 15:57:47 i have no way of knowing Mar 04 15:57:52 if whether or not my iap is the one that's failing Mar 04 15:57:56 or my app is just not working for some users Mar 04 15:57:57 or something Mar 04 15:58:12 my app used to generate a stable revenue all of last year, but now these past months it has dropped significantly Mar 04 15:58:21 not sure if its daily activity just has dropped Mar 04 15:58:24 or if there's something else messing about Mar 04 15:58:32 no excessive crash reports etc tho Mar 04 16:00:21 Is there a modern idiom that can be used to have a bottom tab bar that also keeps the state of each tab's corresponding fragment. I'm looking at creating something similar to Instagram's tab bar, where if I leave a tab and go back, it shows me where I left off. Mar 04 16:00:53 Can I use a Toolbar and FragmentPagerAdapter here? Is there something else? Mar 04 16:01:22 so god damn strange, prior to 27th of jan this year I got a lot of inapp purchases for two of my most popular games Mar 04 16:01:34 then, after that, they suddenly stopped completely Mar 04 16:02:23 Bantalon: look into Google Analytics or Fabric/Crashlytics. These don't work retroactively, so the earlier you implement your reporting, the better Mar 04 16:02:34 darn, alright thanks MarkyC Mar 04 16:02:38 will need to find a way to figure htis out though Mar 04 16:02:44 will try creating a new google account though and see if i can iAP myself Mar 04 16:04:59 Bantalon: I like Crashlytics (Fabrics) crash reporting (if the IAPs are crashing your apps). Otherwise, check the response code, and maybe log it if it's anything other than OK Mar 04 16:05:11 it's strange though Mar 04 16:05:16 3 of my apps seems to have stopped iaps completely Mar 04 16:05:17 after 27th jan Mar 04 16:05:25 while regular app purchases of some of my other apps seems to still work Mar 04 16:05:56 maybe there was a deadline i didn't meet that i needed to upgrade something? Mar 04 16:06:00 to kepe iaps working after 27th of jan? Mar 04 16:06:12 didn't get an otification about suhca thing anywhere though Mar 04 16:07:13 Bantalon: So you need to figure out if your users simply aren't clicking the buy buttons, or the result is USER_CANCELLED/ITEM_UNAVAILABLE/DEV_ERROR, or there's a crash Mar 04 16:07:36 I see Mar 04 16:07:49 and I need some analytics to check that+ Mar 04 16:08:05 there is nothing in my merchant reports at all Mar 04 16:08:22 but I don't think it's that people don't push the buy button, because prior to jan 27th i was getting a few inapps on all 3 apps consistently for 2 years Mar 04 16:08:25 and then abruptly, nothing Mar 04 16:08:29 I have a request. Is there is anyone that is a working developer that is willing to give about 30 minutes of their time to answer some questions on their career for my school speech project? Mar 04 16:08:45 or less time? Mar 04 16:09:52 ah, MarkyC: had a friend check it out Mar 04 16:09:55 and he got this error: "Error: this app uses a billing version that is no longer supported" Mar 04 16:09:55 :) Mar 04 16:09:57 NICE! Mar 04 16:11:04 TacticalJoke, figured the problem out, sharing solution just in case, equals was badly overriden. Mar 04 16:12:05 *equals() Mar 04 16:24:15 W/FileUtils﹕ Failed to chmod(/storage/emulated/0/MyApp/data): android.system.ErrnoException: chmod failed: EPERM (Operation not permitted) Mar 04 16:24:54 SQlite writing to database with getExternalStorageDirectory() causes this error Mar 04 16:25:08 what could be the problem guys ? Mar 04 16:25:24 sci-fi, missing WRITE_EXTERNAL_STORAGE? Mar 04 16:25:26 Why does the emulator go into slow-mo everytime its got to scale down an image? Mar 04 16:25:35 WHY! >:O Mar 04 16:26:13 Mavrik:read and write permissions are given Mar 04 16:26:19 also this not crashes my app Mar 04 16:26:25 also Mar 04 16:26:30 Error log but not causes crash Mar 04 16:26:47 that also makes sense since external storage usually doesn't have permission support Mar 04 16:28:31 what should i do bro ? ive been searching for 3 days and lack of information Mar 04 16:33:37 ignore it because it's not a problem? Mar 04 16:34:08 that. or stop storing a DB to external storage. Mar 04 16:37:53 Mavrik:i should keep some datas if user clears data Mar 04 16:37:58 any idea to do that Mar 04 16:38:09 uh, don't keep data if the user wants to clear data Mar 04 16:39:29 backend if you really want backup Mar 04 16:39:40 nothing on the users device Mar 04 16:40:41 i.e. don't try to circumvent what the user wants Mar 04 16:46:51 im using a viewPager with a fragment,so i have created the onStart method in which i want to load the data from the database before the onCreate, but it crashes . this is my code http://pastebin.com/y848dMMx Mar 04 16:49:40 Every time it crashes there's a stack trace.. Read it to find out why Mar 04 16:51:10 SimonVT: there isnt thats the problem Mar 04 16:51:28 There is Mar 04 16:51:44 SimonVT: the logcat gives nothing Mar 04 16:52:01 You probably have some filter, or something Mar 04 16:58:13 I'm using OkHttp 1.2 with Picasso 2.5. Picasso seems to be using OkHttp 1.1. Does that seem right? If so, is there a way to force it to use OkHttp 1.2? Mar 04 16:58:18 I'm guessing this is a class-path-ordering thing. Mar 04 16:59:38 I have the OkHttp dependency ahead of the Picasso dependency, but it doesn't seem to help. Mar 04 16:59:54 You mean 2.2? Picasso works fine with 2.2 Mar 04 17:00:07 Oops, sorry, yeah. 2.2. Mar 04 17:00:11 And Picasso appears to be using 2.1. Mar 04 17:00:50 there's always a stack in logcat Mar 04 17:00:57 you're reading logcat wrong Mar 04 17:01:01 adb logcat -s AndroidRuntime Mar 04 17:01:08 My main evidence is running through with the debugger and seeing that it's Cache.init is calling DiskLruCache.open instead of DiskLruCache.create. Mar 04 17:01:17 I use picasso 2.4 and okhttp 2.2 Mar 04 17:01:17 -it's Mar 04 17:01:29 Would be strange if picasso 2.5 downgrades to okhttp 2.1 Mar 04 17:01:37 Yeah. Mar 04 17:01:51 Another thing is that my version of Picasso depends on OkHttp 2.1 in pom.xml. Mar 04 17:03:54 Gradle won't/can't include both 2.1 and 2.2 Mar 04 17:04:13 So if you've added okhttp 2.2 as a dependency, that's all picasso can use Mar 04 17:04:29 can anyone help with "un-bricking" a Nexus 10? :-) Mar 04 17:04:49 i attempted to flash Android 5.0.2 onto it via the images and instructions at: https://developers.google.com/android/nexus/images Mar 04 17:04:51 jonp: Try #android or #android-root Mar 04 17:04:57 ah. thanks. Mar 04 17:15:03 What's the advantage of using an IntentService compared to gluing something onto the App? Mar 04 17:15:36 Looks like a lot of pipes for not much water in most of the use cases I'm seeing. Mar 04 17:15:39 SimonVT: Ah, I guess it is using 2.2. I got confused and thought that this changeset was part of 2.2: https://github.com/square/okhttp/commit/ea565b2e30e15cd52ddfc2ddc6db4ea8f1c3de88 It seems that this changeset hasn't been released yet. Mar 04 17:16:07 Thanks. Mar 04 17:18:28 Got a decent enough explanation out. I'd like to find a motivating use case. Moving to simple async for now. Mar 04 17:24:00 knapper_tech: This talks about it: http://developer.android.com/guide/components/processes-and-threads.html Mar 04 17:24:18 I think a key theme is that a service is unlikely to be killed by Android. It has a high priority by default. Mar 04 17:24:37 "Because a process running a service is ranked higher than a process with background activities, an activity that initiates a long-running operation might do well to start a service for that operation, rather than simply create a worker thread—particularly if the operation will likely outlast the activity." Mar 04 17:25:56 TacticalJoke, every time I've done geocoding, I got results back fast enough that I was quickly burning through my server's rate-limit. Am I missing something on Android or is geocoding basically "fast" compared to Activity life? Mar 04 17:26:46 I was just looking at some Google code and decided I might as well work through my first IntentService while I was at it, but it does seem silly for geocoding. Mar 04 17:27:07 From what I've seen, it's not common for an activity to be destroyed as soon as it goes into the background. And, even if it is destroyed, I don't think that necessarily means any running thread will stop. Mar 04 17:27:15 I'm minded to just use the App context Mar 04 17:27:34 The system can also restart your service and re-deliver intents if it kills your process while your service running.. If you simply start a thread, you'll have to handle that manually Mar 04 17:28:12 In my case, I'm not losing any work done if the Application gets blown away yet Mar 04 17:28:31 Then you probably don't need a Service Mar 04 17:31:52 If I want to use DiskLruCache in my app, and my app is already using OkHttp, is it sensible to use DiskLruCache from OkHttp? I'm guessing not because it's in a subpackage called 'internal', but it's slightly tempting. Mar 04 17:32:33 I guess otherwise I can depend on com.jakewharton:disklrucache:n. Mar 04 17:33:30 Noone's going to hurt you if you use it.. It's just not a part of the stable API, so they can do with it whatever they want Mar 04 17:33:36 Okay. Mar 04 17:33:51 It might go away in 2.2.1, for all you know Mar 04 17:33:55 Unlikely, but yeah.. Mar 04 17:34:00 Ya. Mar 04 17:34:16 Might be better to just copy it out into your own package, then you know it's stable Mar 04 17:35:05 man, Google releases material design icons that are gray Mar 04 17:35:14 while they use all the icons in a white fashion Mar 04 17:35:31 why the fuck would you do that when you know that everybody else who's going to use those icons is going to be trying to copy YOUR design Mar 04 17:35:45 jesus fucking christ on a grass field Mar 04 17:35:59 the logic! Mar 04 17:36:20 Odaym: wat? Mar 04 17:36:32 Odaym: They change colour at run time when on a toolbar. Not sure about other places, though. Mar 04 17:36:37 You can pick the colour. Mar 04 17:36:45 why would they do that! they just have them in white! Mar 04 17:37:49 Wat? Mar 04 17:43:56 nothing man I just have these bursts Mar 04 17:44:07 isnt based on anything reasonable Mar 04 17:47:03 im trying to use viewPager with FragmentStatePagerAdapter and a fragment, how can i load the data from database before the fragment creating.? Mar 04 17:48:26 Hey quick question.. I have a logging class that dumps various information into a text file. Problem is, getFilesDir() requires a context, which means I can't locate the application path from any non-activity classes I create. Is there any way to retrieve the internal storage path without passing in a context? Mar 04 17:49:01 pass the context to that function Mar 04 17:49:07 lol that username Mar 04 17:50:23 Odaym: what about static classes?. Mar 04 17:50:40 nonstatic cannot be accessed from static, error Mar 04 17:51:02 you're doing something wrong Mar 04 17:51:06 for sure Mar 04 17:51:15 never had that problem Mar 04 17:51:18 blndidiot: There are lots of ways of doing it. I guess the best way depends on the details in your case. Mar 04 17:51:38 Eh, looks alright. Mar 04 17:52:53 why are you making a static class? Mar 04 17:53:01 just wondering Mar 04 17:54:50 Odaym: Well.. let's say I have a static class called Helper.java and inside is a function getAgeFromBirthdate(). Inside getAgeFromBirthdate, I make the simple calculations but want to log any errors that might occur inside my Logging class. My logging class requires a context in order to use getFilesDir(), but Helper.java is not an activity class, it just has some general purpose functions in it Mar 04 17:55:13 then dont make a static class Mar 04 17:55:27 make the function a member function belonging to an object of your Helper class Mar 04 17:55:35 you easily pass context to it then Mar 04 17:55:45 there is no reason that any of your methods should be static Mar 04 17:55:58 Why not have a global static instance of your logging class? Mar 04 17:56:33 It could have a constructor taking a File. Perhaps in Application.onCreate you could instantiate it, passing getFilesDir() or something. Mar 04 17:56:38 I am new to java so I am sure there are smarter ways to do this. I will look into your suggestions and see if I can come up with something Mar 04 17:56:49 look only for the working way, then Mar 04 17:57:23 Odaym: Are you saying methods should never be static? Mar 04 17:57:43 * Odaym is not accountable for anything that he says Mar 04 17:57:57 I just don't see why a method should be static when it could be a member function.. Mar 04 17:58:13 sure its easier to type it when using it..but..what's that account for Mar 04 17:58:19 clean separation is nice Mar 04 17:58:42 the details of it I am ignorant of, but the outer result is that I dont face such problems as being sectioned off from the whole code not being to interact with Context Mar 04 17:58:55 It doesn't make sense to require all methods to be tied to an instance. An example is static factory methods. Mar 04 17:59:01 Consider LayoutInflater.from. That's a static method. Mar 04 17:59:07 yes of course, but his case I mean Mar 04 17:59:36 Oh, true. People often overuse utility methods when they should be using a real class. Mar 04 17:59:50 cause I've seen that error, we all have Mar 04 17:59:53 s/methods/classes/ Mar 04 17:59:53 Is it bad practice to do what I describe with my Helper class? Used for just simple general purpose calculations and such without the need to instantiate something? Mar 04 17:59:55 that situation rather Mar 04 18:00:27 you want simple and easy and no-need-to-instantiate code, but look at the problem you have, you cant use context Mar 04 18:00:31 Helper classes can be great, but whenever I create one I stop and wonder whether I should instead be making a class with real (instance) methods. Mar 04 18:00:37 youre going to run around and devise something else to do it, therefore creating complexity again Mar 04 18:01:03 well you cannot run around and devise anything, you must pass context Mar 04 18:01:11 Well, I didn't see this coming when I set it up. As mentioned, new to java and just looking for ways to improve how I'm doing it Mar 04 18:01:14 blndidiot: Helper doesn't sound like a good class name, to be honest. Mar 04 18:01:17 It's very general. Mar 04 18:01:25 its just a couple of changes Mar 04 18:01:30 not wow Mar 04 18:01:33 TacticalJoke: Just an example, that's not the name of my class Mar 04 18:02:29 I guess I'd say that if there is a person who has a birth date, and you're getting the age from that, it might make sense to have a Person class with a calculateAge method or something. Mar 04 18:02:49 Ok I see Mar 04 18:02:57 That just seems like overkill Mar 04 18:03:08 Overkill in what way? Just curious. Mar 04 18:03:25 Memory, having to instantiate a class just to return a simple calculation result Mar 04 18:03:37 premature optimization Mar 04 18:03:44 number 1 fault of all programmers Mar 04 18:03:47 now I understand that quote Mar 04 18:03:47 haha Mar 04 18:03:50 It depends on your code. If you have a bunch of data and methods relating to a person spread all over the place, the code will be hard to reason about. Mar 04 18:03:51 lol Mar 04 18:03:57 But tying it all together in a Person class will make everything nicer. Mar 04 18:03:59 you so caring of the memory, you kind programmer you Mar 04 18:04:09 you are so aware of your memory footprint, you good citizen you Mar 04 18:04:22 Not sure if snarky .... Mar 04 18:04:25 I'd worry about the instantiation of a single object only in extremely tight loops. Mar 04 18:04:35 Gotcha Mar 04 18:04:46 I will reconsider my design of this, thanks guys Mar 04 18:05:06 there is a thin line between what you know and what you don't know. and that thin line is drawn the moment you ask yourself "doesn't this seem too much? I mean I know I could go that way but is it good?" Mar 04 18:05:10 means you dont know what to do Mar 04 18:05:21 blndidiot: Computers are extremely fast. Most of the time, anything you write will not only be fast enough but perhaps even too fast. Mar 04 18:05:26 pretty coo' Mar 04 18:05:56 Readability and changeability are #1 in the vast majority of cases, I think. Mar 04 18:06:00 Or #1 and #2. Mar 04 18:07:18 Good call Mar 04 18:07:19 thank you Mar 04 18:07:29 Hey, im having a slight problem, i'm using an intent to capture a photo, but it appears that on lollipop, it doesnt returns the photo that was just taken… Anyone ever seen/solved that ? Mar 04 18:07:38 I get kind of overly anal about performance sometimes i think Mar 04 18:07:46 yes it does return it, Im working right now on that h3bus Mar 04 18:07:56 see Taking Photos Simply demo on Google docs Mar 04 18:08:03 doesn't work on S3 though, guaranteed Mar 04 18:08:08 blndidiot: I'm like that. I think the best antidote is to do real profiling. Mar 04 18:08:15 You learn just what is fast and what is slow. Mar 04 18:08:27 yea exactly instead of theorising Mar 04 18:08:37 A lot of the things I assumed were slow were extremely fast. A few things I assumed were fast were quite slow. Mar 04 18:08:46 Odaym: you mean that you have the same problem ? I'm trying to find a solution, but so far no luck… Mar 04 18:08:59 I don't have the same problem, I have the same functionality and it's working Mar 04 18:09:04 so easy Mar 04 18:09:12 do this, it works http://developer.android.com/training/camera/photobasics.html Mar 04 18:10:25 Odaym: you tried that on android 5 ? Mar 04 18:10:33 yes I have N5 Mar 04 18:10:37 works on N5, not on S3 Mar 04 18:10:47 allright, sounds good, ill try that Mar 04 18:10:49 the demo project as is, that is Mar 04 18:10:55 try that first to see how it should work Mar 04 18:10:57 then do it Mar 04 18:11:13 lawyer up, hit the gym Mar 04 18:16:23 any of you set up analytics and protect it from accidental/intentinonal misuse of your tracker id? Mar 04 18:17:28 I guess theres a chance that someone tries to set up their id but uses mine so my data get corrupted Mar 04 18:19:30 Quacked: give it a weird name Mar 04 18:19:47 give what a weird name? Mar 04 18:20:01 your tracker id Mar 04 18:20:26 or something very unique Mar 04 18:20:47 uhm, you cant change the tracker id? Mar 04 18:20:58 not the id, the name of the id Mar 04 18:21:27 How are you concerned about someone else using yours? Are you making a library that people use, and you want to track for it? Mar 04 18:22:55 say I have the tracker id UA-111411-1 and someone sets up a new GA tracker for their own app and tries to use their id UA-111141-1. Mar 04 18:23:04 but they mistype it Mar 04 18:23:12 and flood my account with spam Mar 04 18:24:50 I guess it would also be possible for someone to make an app that loops through tracker ids and floods accounts Mar 04 18:25:03 doubt it Mar 04 18:25:09 I would like to make my android app comunicate with my PC through bluetooth, I don't want any root permission stuff. What's the easiest way ? Who would be the bluetooth host / client ? Mar 04 18:25:31 yiati, could be google has some spam protection but still Mar 04 18:26:02 accidental use of someone elses tracker id would be quite annoying Mar 04 18:26:13 Quacked: I haven't done analytics in a while, but I'm pretty sure there's a way you link your app to the analytics Mar 04 18:26:25 Quacked, so this worry is moot Mar 04 18:26:43 I accidentally used the wrong id for the wrong app and got screeviews that shouldnt have been there Mar 04 18:27:13 which can never be removed Mar 04 18:30:42 blusky: http://developer.android.com/guide/topics/connectivity/bluetooth.html Mar 04 18:31:45 thx Mar 04 18:32:58 Does removing a videoview from the viewhiearchy stop its playback? Mar 04 18:36:57 The current SDK download says it targets 5.0. Everyone's actually *running* 4.x. Any thoughts on this point for a new dev? Mar 04 18:38:09 lasserix: i think it does, though it should be easy to test :) also, check the source. probably there's something when it gets detached from the window. Mar 04 18:38:41 Baylink: "target" is "compile against this API". it's not "will only run on this API". Mar 04 18:39:06 Does it tell you when you're using "newer version only" calls at edit time? Mar 04 18:39:16 yeah, it'll warn you if you try to use an API that doesn't exist in your minSDK version. Mar 04 18:39:46 Ok; I'm new enough that doesn't tell me what you want it to: my SDK version would *be* 5.0, there, no? Mar 04 18:40:49 hi Mar 04 18:41:17 lets be more specific :) your gradle file / your application has a "min SDK" and a "target SDK", and the device has an "OS version". when you choose a target SDK, it means you want to run _as if_ your app was built at the time that that SDK existed (sometimes you'll get fallback compatibility behavior if it's lower than the OS version, but don't worry Mar 04 18:41:17 about that for the most part) Mar 04 18:41:24 after you have installed your application are the resources still loaded from the apk zip file? Mar 04 18:41:43 err, I have a TextView which I’ve jimmyed to act like an editText. Say it takes a first name and displays the short version of it (Jefferson becomes Jeff) but I want the textView to resize when the name changes.. Mar 04 18:41:44 Baylink: min SDK is the _required_ minimum OS version for your app, nothing more. Mar 04 18:41:44 Ah. So you *set* "minSDK" for a project. Mar 04 18:42:00 the problem is that I have a few other textviews in the same layout, with fravity in the XML Mar 04 18:42:18 when I change the layoutparams programmatically to wrap_content, it blows away all the other layouts Mar 04 18:42:28 as if I did match_parent.. Mar 04 18:42:42 Baylink: so if you set min = 16, target = 21, you'll be able to run on 16 through 21, and it'll warn you if you try to use e.g. APIv19 calls, because your code could be running on a device with a v16 OS, and actually executing that call will crash. Mar 04 18:42:46 set width to 0 and the view disappears but the others are there.. any ideas? Mar 04 18:42:59 good morning vietnam ! Mar 04 18:43:14 isn't it like, evening there or something? Mar 04 18:43:23 minSDK is the lowest version of Android you want to support Mar 04 18:43:32 Got it. Ok; thanks, groxx. Longtime coder but Android newbie, here; I will probably come back and ask some more stupid questions. :-) Mar 04 18:43:35 and how much appcompat headache you’re willing to deal with ^.^ Mar 04 18:43:43 JesusFreke android is my vietnam :) Mar 04 18:43:51 g00s: a common typo Mar 04 18:43:55 Baylink: if you set min = 16, target = 18, you'll still run on 16 through 21, but you can't use APIv19 features (because they don't exist in 18, which you've targeted), and you _might_ get "behave like APIv18" compatibility behavior on v19+ OSes. Mar 04 18:43:57 love the smell of Android in the morning Mar 04 18:44:05 ^ Mar 04 18:44:25 the android key is right next to the vietnam key, afterall Mar 04 18:44:27 heh Mar 04 18:44:38 I always target current version, minSDK is whatever I need it to be to get everything working nicely Mar 04 18:44:44 Well, my target app is pretty uncomplicated, so... Mar 04 18:44:56 and we have plenty of Napalm here too Mar 04 18:45:05 My target hardware platform shouldn't be running anything older than 4.0 Mar 04 18:45:09 you could go down to < 11 if you want… Mar 04 18:45:12 Baylink: then in general you're probably best setting target = the newest version available, and min = whatever you're willing to go down to. Mar 04 18:45:15 haha Mar 04 18:45:17 oh then 11 is good, Mar 04 18:45:19 :) Mar 04 18:45:26 you’ll get 3.0 and all the fun fragment stuff Mar 04 18:45:31 4.0 is 11? I thought it was higher than that. Mar 04 18:45:40 11 is honeycomb, 3.0 Mar 04 18:45:43 Ah Mar 04 18:45:45 Ok. Mar 04 18:45:52 long live gingerbread! Mar 04 18:45:58 godspeed Mar 04 18:46:04 donut FTW Mar 04 18:46:07 let it burn Mar 04 18:46:14 Can any application access all the resources of any other application through PackagaManager? Are there any restrictions? Mar 04 18:46:22 nobody has honeycomb devices, pointless minsdk Mar 04 18:46:23 4.0 is 14 Mar 04 18:46:24 I'll need "display a string", "respond to a button", "get input from a keypad", and some multicast UDP packet stuff. Mar 04 18:46:30 8 or 14 Mar 04 18:46:41 haha, I have minsdk at 11 Mar 04 18:46:43 And timers. Lots of timers. Mar 04 18:46:51 when I moved from GB there were 2 complaints Mar 04 18:46:59 myke: dont say that.. you might have someone come and assassinate you Mar 04 18:47:03 Baylink: since you're just starting, start with the tutorials on the developer.android.com site (do the beginning ones, sample some others if relevant), and also the API guides (again do the fundamentals, sample others as relevant). they're very likely the best source of info. Mar 04 18:47:08 gingerbread is the devil Mar 04 18:47:16 ^ Mar 04 18:47:21 honeycomb was only on tablets Mar 04 18:47:26 like the soom maybe? Mar 04 18:47:26 Hey, Napalm Mar 04 18:47:28 xoom Mar 04 18:47:31 hai Mar 04 18:47:36 I tend to learn better the other direction, groxx: I need context. I start with a working sample app, and figure out how it got there. Mar 04 18:47:37 I think there were only a coupl Mar 04 18:47:57 I don't need to learn how to *program*, just how to program *android* Mar 04 18:48:14 Baylink: you'll miss a lot of details about e.g. the normal application lifecycle, and we get LOTS of questions in here that would be answered if people would just RTFM on the basics. Mar 04 18:48:27 Listen to him Baylink Mar 04 18:48:31 Understood. Mar 04 18:48:34 I’ve been there. still do that Mar 04 18:48:36 and yeah, the developer.android.com stuff assumes you can write java, it's Android-specific. Mar 04 18:48:48 I learned that way and I’m still suffereing consequences Mar 04 18:48:52 Odd that that approach is ok in programming, but we don't tolerate it in actual schools, eh? :-) Mar 04 18:49:09 :) Mar 04 18:49:15 Schools teach you the fundamentals, no way a class can teach you all of Android Mar 04 18:49:19 you need to learn how to program before you can program android Mar 04 18:49:21 I'm a pretty good maintenance programmer, I can rewrite in languages I don't know. Java is one such language. Mar 04 18:49:25 even the Android class I took was kind of a joke Mar 04 18:49:39 I learned liek 2 new things Mar 04 18:49:54 But 25 years of practical programming has to be good for something, I figure... Mar 04 18:49:58 once you've done the basics (really, they're worth it), then yeah, hack your way through things. there are sample projects in the SDK (you may also want to download the v17 samples, though they're Eclipse-only) if you do better with reading existing stuff. Mar 04 18:49:59 oh yeah Mar 04 18:50:06 but still read the docs Mar 04 18:50:13 I will. Mar 04 18:50:19 or jsut go through tuts Mar 04 18:50:25 i'm taking the coursera android class, and seem to know answers to the questions that come up over and over on here Mar 04 18:50:26 There are just too damn many starting points. Mar 04 18:50:35 https://developer.android.com/training/index.html Mar 04 18:50:36 definitely Mar 04 18:50:36 yeaaah Mar 04 18:50:43 sure you can just read the docs and learn it all, but most ppl won't Mar 04 18:50:52 lol ^ Mar 04 18:51:09 I think there are about 2 people in here who can/do that Mar 04 18:51:11 hence the very-beginning stuff with "training" and "api guides". e.g. the top category in each, since it covers app structure and behavior. Mar 04 18:51:14 It's been my experience that Just Reading All The Docs does *not* in fact ever teach you It All. Mar 04 18:51:28 no Mar 04 18:51:32 Having had to rewrite many of the docs in my day... Mar 04 18:51:46 OMG, I sound like I have a lawn. Mar 04 18:51:49 but say you want to write an app that has button functionality.. cool go tohe button tuts, start there Mar 04 18:51:53 Baylink: lol Mar 04 18:51:59 the android docs are comprehensive tho Mar 04 18:52:08 well, usually Mar 04 18:52:08 then you want those butons to do HTTPPost, then go to that tut Mar 04 18:52:12 etc Mar 04 18:52:13 I will remember to look before asking. Mar 04 18:52:13 I use mViewPager.getCurrentItem() to find out what tab I have in focus. But I also use a SherlockDialogFragment, and if I have the dialog open and exit the app, when I start the app and see the dialog, mViewPager.getCurrentItem() will tell me that the fragment is in focus. Any way I can find what is really shown? Mar 04 18:52:24 at least give it a go, google is your friend Mar 04 18:52:34 At least I understand the "top half/bottom half" pattern, coming from extensive Unix. Mar 04 18:52:47 tricknology: http anything is a lot harder in android than other platforms Mar 04 18:52:55 Baylink: one advantage to Android dev at least: the vast majority of the system is open source. and it's usually pretty readable. Mar 04 18:53:00 And I did find an apache licensed app close to my stamping ground, so... Mar 04 18:53:03 since no networking on ui thread Mar 04 18:53:22 myke I don;t think it’s much harder than okhttp Mar 04 18:53:33 Baylink: abso-frickin'-lutely huge, but generally readable :) Mar 04 18:53:35 okhttp isn't stock Mar 04 18:53:35 Well, down into the trenches I go, folks; thanks for the tips. Mar 04 18:53:35 especially if you already program on the backend Mar 04 18:53:40 I know it isn't Mar 04 18:53:43 good luck o/ Mar 04 18:53:55 I will need it. Mar 04 18:54:05 You got this Mar 04 18:54:15 check out vogella too, it’s a decent resource Mar 04 18:54:30 Baylink ^ Mar 04 18:54:48 I'd seen that go by, yes; I will. Tnx Mar 04 18:54:48 http://www.vogella.com/tutorials/Android/article.html Mar 04 18:55:08 decent if it fits your topic almost exactly, IMO. otherwise they generally seem far too light on the "why" for my taste :( Mar 04 18:55:13 it’s a nice overview, but no sub for the docs, np Mar 04 18:55:24 I think the world needs a site with short, to-the-point examples of how to do various things. Mar 04 18:55:29 also.. grep “EditText” in google Mar 04 18:56:03 “grep ‘component’ “ in google. You’ll get the source code of whatever component if you’re wondering how it works Mar 04 18:56:27 and stackoverflow of course Mar 04 18:56:41 Yes; that Vogella overview looks to be about the right altitude for me. Mar 04 18:56:43 most of my wtf questions have answers on SO Mar 04 18:56:55 StackO only if I can tolerate the attitude. Mar 04 18:57:03 and SO answers link to good articles Mar 04 18:57:22 i <3 SO, but some of the comments and answers are ridiculous Mar 04 18:57:23 The thing about the Vogella articles is that they touch on so many topics. Mar 04 18:57:25 Baylink: you're on irc... Mar 04 18:57:47 TacticalJoke, Are you sayign that there are “holes” kind of? Mar 04 18:57:55 lol Mar 04 18:58:02 at least this ins’t ##Java Mar 04 18:58:11 true Mar 04 18:58:50 I don;t go there unless i’m deprate. RTFM all day Mar 04 18:59:02 ##java regulars seem out of touch Mar 04 18:59:05 Most of the people on IRC, myke, aren't as self-important as most of the people I see on SO. Mar 04 18:59:11 They can be pretty helpful, but they are so quick to insult people's intelligene. Mar 04 18:59:13 like "always ise java 8!" Mar 04 18:59:15 intelligence* Mar 04 18:59:26 because no one has old jres or uses android Mar 04 18:59:46 They've gone the same direction as Metafilter did. I'm user 706 there, but I haven't bothered with the place in 6 or 7 years. Mar 04 19:00:14 The best SO questions are the "Closed as not constructive ones". Mar 04 19:00:17 Just because someone else's usecase seems useless to you, that isn't justification to diss them. Mar 04 19:00:21 Exactly. Mar 04 19:00:24 They're the ones with 600 upvotes and countless Google hits. Mar 04 19:00:46 TacticalJoke is right Mar 04 19:00:47 It feels like SO is the first time the world has seen 200 dictators in a tiny space. Mar 04 19:01:09 constructive" ones * Mar 04 19:01:09 The worst on SO is seeing that a question you want to know was closed as "Stupid, Not a Valid Question, etc" Mar 04 19:01:18 that someone else asked Mar 04 19:01:20 if you add pictures to your apk as resources are they extracted from the APK after installation or they just stored in the apk on the phone after installation? Mar 04 19:01:34 well SO has very strict rules on questions Mar 04 19:03:15 any of you set up analytics tracking of a viewpager with fragments? Mar 04 19:03:25 I cant find examples on how to do that Mar 04 19:04:12 Quacked: What do you want to track? Mar 04 19:04:33 screenviews really Mar 04 19:04:51 hoping to use the auto tracking feature GoogleAnalytics.getInstance(this).reportActivityStop(this); Mar 04 19:05:05 ChrisUK: http://stackoverflow.com/questions/5607652/android-apk-resource Mar 04 19:05:10 but not sure thats possible with fragments Mar 04 19:06:39 myke: thanks, so only the dex file is removed from the zipped apk file the rest of it remains compressed on the storage? Mar 04 19:07:19 ChrisUK: your pics should be in /data/data/appname Mar 04 19:07:44 all of it is put elsewhere Mar 04 19:07:49 Quacked: Isn't that just spying on people? Mar 04 19:08:11 myke: so the contents of the apk are decompressed on install? Mar 04 19:08:19 ChrisUK: yes Mar 04 19:08:24 TacticalJoke, tracking what tab in the viewpager theyre on? Mar 04 19:16:28 myke: I have read a few times that the APK is used at runtime Mar 04 19:17:30 No, the apk is not decompressed Mar 04 19:17:37 so's are unpacked Mar 04 19:17:44 Resources are still read from it Mar 04 19:17:55 Simon: yes that is what I read Mar 04 19:18:38 s; Mar 04 19:18:58 so only the code files are installed directly onto the local storage? Mar 04 19:19:35 From what I've gathered there are no access limits on Resources, is that right? Mar 04 19:20:01 Any applications can read all the Res from any other Mar 04 19:20:19 Yeah Mar 04 19:20:56 I believe data/app/ is readable by everyone Mar 04 19:21:27 SimonVT: isnt that pretty inefficient if you have alot of resources to read Mar 04 19:21:33 having to extract them from a zip file Mar 04 19:24:27 That you have to read from disc is probably more of a bottleneck Mar 04 19:24:30 And there's zipalign Mar 04 19:24:39 And the fact that resources are cached in memory Mar 04 19:24:55 And that resources are usually quite small Mar 04 19:26:55 well the resources in this case are large texture files Mar 04 19:27:04 for an OpenGL app Mar 04 19:28:23 but as you say Mar 04 19:28:34 given the type of storage zip might be more efficient Mar 04 19:28:37 since it reduces read time Mar 04 19:32:05 so the AssetManager class will automatically decompress the files for you? Mar 04 19:33:00 You'd probably put those in assets, and load them on a thread Mar 04 19:33:14 At least if it takes any significant amount of time Mar 04 19:34:01 Ha.. Not reading the docs will cause you to miss out on cool things like textview.append() Mar 04 19:34:42 hi my domain is test.github.io how can I put it in this form com.example.hello for my Android app? Mar 04 19:34:55 um Mar 04 19:34:59 whas is your project name Mar 04 19:35:03 package name rather Mar 04 19:35:07 check your manifest Mar 04 19:35:28 my project name is test Mar 04 19:35:30 package="com.your.domain.here" Mar 04 19:35:50 io.github.test I think it should be Mar 04 19:36:53 do you own the domain github.io? Mar 04 19:36:59 if not I would suggest that you use another package name Mar 04 19:37:11 I dont own that domain Mar 04 19:37:13 com.kingme.test Mar 04 19:37:20 althoughkingme is probably taken Mar 04 19:37:29 this will help you in the future.. use the same package Mar 04 19:37:34 can it be io.github.test.test? Mar 04 19:37:38 like my personal one is com.drawingboardapps.package Mar 04 19:37:50 it can be.. but for the reasons explained above I wouldn't Mar 04 19:38:27 if your package has the same name as another on Google Play I don’t think you can upload it. Mar 04 19:38:39 I have a module named library, and in it's build.gradle file I have"apply plugin: 'maven'" which I think makes a task called "install" but when I do ./gradlew install it tries to install to a device. I'm building a library if that means anything. How can I get my library building into the local maven repository Mar 04 19:38:49 I own the domain test.github.io Mar 04 19:39:15 KingMe: Doesn't GitHub own it? Mar 04 19:39:17 oh I said you don’t Mar 04 19:39:27 i though you said... Mar 04 19:39:33 KingMe: I dont own that domain Mar 04 19:39:46 github uses github.io but u can get ur own domain like.github.io Mar 04 19:39:56 oh ok then cool Mar 04 19:40:02 I don't think I'd risk it, personally. Mar 04 19:40:08 I wouldn’t either Mar 04 19:40:45 you can’t change package name in the future if your app is on google play.. meaning you have to delete the apk and reupload under a new package Mar 04 19:40:56 Package names don't have to be related to sites. That's just convention. Mar 04 19:41:08 ^ Mar 04 19:41:23 doesn’t _have_ to be.. but it’s nice Mar 04 19:42:08 you can have it abba.cabbage.dabbage if you want.. as long as it’s unique enough you’re in good shape Mar 04 19:42:24 io.github.test I woudl think belongs to github Mar 04 19:42:31 the app Mar 04 19:42:33 what if I get a free wordpress domain like wordpress.example.com Mar 04 19:42:52 Those are all subdomains not domains Mar 04 19:42:53 Wouldn't it be example.wordpress.com? Mar 04 19:43:11 can subdomain be used for android app? Mar 04 19:43:12 a domain is what you get from godaddy for liek 14.95/yr Mar 04 19:43:31 I'm not sure, KingMe. Maybe, or maybe it could lead to an app take-down for "impersonation". Mar 04 19:43:39 actually .. $0.99 right now Mar 04 19:43:50 ^ that is your biggest concern ^ Mar 04 19:43:53 The Google bots are quick to take stuff down. Mar 04 19:44:09 then all the people who had your app suddenly can’t find it and no longer get updates.. not sure if the app uninstalls Mar 04 19:44:37 kingmeapps.com is available for 17.00/year Mar 04 19:44:47 if you don’t take it i might cause it sounds sweet Mar 04 19:44:53 I'm just using my-initials.project-name (both are pretty unique, so I don't have to disambiguate further). Mar 04 19:45:01 com.kingmeapps.test Mar 04 19:45:33 then if you ever build a website and host it there, people in the know will know to go to kingmeapps.com Mar 04 19:45:48 thanks alot for the help Simon Mar 04 19:45:56 well google allows more than 3 . so I thought subdomains work Mar 04 19:46:01 I’ve found some pretty cool webpages and git repos that way Mar 04 19:46:14 because I liked someone’s app and they had their domain as their package name Mar 04 19:46:30 I hope google allows more than 3.. I have one with 4 Mar 04 19:46:39 not published yet though.. hopefully this weekend. Mar 04 19:46:48 (if anyone would liek to aplha test) Mar 04 19:46:56 why 4? u use sub domain? Mar 04 19:46:57 more like load test Mar 04 19:47:04 KingMe: You missed the point. Mar 04 19:47:16 com.domain.app.frontend Mar 04 19:47:20 com.domain.app.backend Mar 04 19:47:54 Just do it this way and you should have no problems in the future.. all we’re saying Mar 04 19:48:17 you can make it up, just make sure it’s unique and you use the same one throughout your projects Mar 04 19:48:36 something.here.* Mar 04 19:48:52 where * = whatever.. text, superapp, pokemonpokedexapp Mar 04 19:49:37 there is a lot of new TLD these days so I need to be safe Mar 04 19:50:38 doesnt matter, jsut use the same one Mar 04 19:50:43 com, net, gov, io Mar 04 19:51:01 but be smart about it, that’s all Mar 04 19:51:30 someoen could rip your package name off io.github.test.this Mar 04 19:51:42 then you could petition to have it removed because it’s unique Mar 04 19:51:51 well you probably couldnt in that case Mar 04 19:52:13 com.kingmeapps.test.this you could if you owned com.kingmeapps.. or had a bunch of apps in the store with package com.kingmeapps Mar 04 19:52:25 /line Mar 04 19:53:12 com. is not required right I can just put pe. if I dont have a domain? Mar 04 19:53:42 yes you can put whatever you want Mar 04 19:53:56 a-z though Mar 04 19:54:44 does it affect marketplace seo if u dont use com. ? Mar 04 19:55:02 noobody knows :p Mar 04 19:55:04 still no release notes for the new sdk tools Mar 04 19:55:06 but i dont think so Mar 04 19:55:57 search engine optimization? Mar 04 19:56:09 my guess is no Mar 04 19:56:26 if so there are many other more highly weighted factors so you wouldn’t notice Mar 04 19:56:33 u can find apps using com.etc so I maybe google gives the edge to people with there own domain Mar 04 19:57:25 jsut read this: http://stackoverflow.com/questions/8075162/what-should-be-the-package-name-of-android-app Mar 04 19:57:51 if you’re worried about SEO and you have a website, or plan to in the future, I would suggest you follow that Mar 04 19:58:15 otherwise your apps may become decoupled from your site in terms of SEO if they are unlinked by other methods Mar 04 19:58:42 question about GridLayout... Mar 04 20:00:01 I have six columns and twelve rows, but I'm trying to get it to scale the cells in order to make them fit the layout. I was thinking layout_gravity="fill", but that doesnt seem to work :/ Mar 04 20:02:55 iirc gridlayout is a pain Mar 04 20:03:20 tricknology, it seems to work well, but the cell sizing is kind of unpredictable Mar 04 20:03:46 yeah Mar 04 20:03:49 Can I see a apps package name? Mar 04 20:03:53 I was using TableLayout, but gridlayout is a bit simpler to use Mar 04 20:04:01 I forgot how I got it to work, I don’t have the source on this computer Mar 04 20:04:08 I had 2 rows of 3 buttons Mar 04 20:04:10 damn Mar 04 20:04:16 sizing was a pain Mar 04 20:05:11 http://stackoverflow.com/questions/10347846/how-to-use-the-gridlayout-to-fit-screen-size Mar 04 20:05:12 that help? Mar 04 20:06:27 Is there a way to make the Wathces in AS debug persistent so i dont have to define them all every time I run the debugger? Mar 04 20:06:39 magic seems to be in “gridLayout.addView(view, params);” Mar 04 20:06:47 where params == Gridlayout.LayoutParams Mar 04 20:06:55 I do remember doing it programmatically Mar 04 20:07:28 drinfernoo ^ Mar 04 20:14:16 tricknology, I might just use nested linearlayouts lol Mar 04 20:14:30 lol Mar 04 20:14:50 sometimes you either have to suffer and learn, or say F-it and do it the way you know works Mar 04 20:14:56 the struggle is real Mar 04 20:17:12 Is there any was I can create an array of EditText objects, just like I'd create an array of, say, strings? Mar 04 20:17:59 TechGeek01: EditText[] myArray. I doubt this is the actual approach you want though Mar 04 20:18:02 Instantiate a lot of edittexts, add them to an array? Mar 04 20:20:43 hey, i cant get preview to work in android studio on api16. It keeps saying "rendering problems Couldn't resolve resource @style/Widget.Holo.Light.TimePicker" Mar 04 20:21:15 Well, I have a list of EditTexts, and I need to both access them to set values to them (it's a form, so to edit an entry, I pull data from a database), and later get whatever the user changed that value to. Mar 04 20:21:44 what hapend with padding when background color is set for buttons? Mar 04 20:22:00 list.add(new EditText(context)) Mar 04 20:22:16 yiati: Shows as "Cannot resolve constructor" with EditText[] someName = new EditText(VALS) Mar 04 20:22:39 or EditText et = new EditText(context); et.setText(string); list.add(et) Mar 04 20:22:48 you cant do that haha Mar 04 20:22:49 hey droids, could someone help me with creating this custom view?: http://i.imgur.com/OTyi7sY.png It is comprised of 4 images (in a square grid, the images are represented by grey squares in my example). Over top of the middle, there is a play button. Mar 04 20:22:59 EditText’s constructor takes context only Mar 04 20:23:01 I thnk Mar 04 20:23:25 Should I use a GridView to host the 4 images? Or should I place 4 ImageViews in a RelativeLayout? Mar 04 20:23:31 use a List, TechGeek01 Mar 04 20:23:35 TechGeek01: That's not how you instantiate a View Object Mar 04 20:23:44 you probably just want to use findViewById Mar 04 20:23:48 List list = new List(); Mar 04 20:24:01 list.add(editText) Mar 04 20:24:08 MarkyC, you could create a drawable. Mar 04 20:24:08 Argh. So I could individually set them to variables, but not to an array? Mar 04 20:24:24 them == what? Mar 04 20:24:38 tricknology: I'm talking about an array of data, as in [1, 2, 3, 4], not an adapter Mar 04 20:24:41 quinnjn: the 4 images in my example will be loaded dynamically (from the net) Mar 04 20:24:46 YOu can use a lsit Mar 04 20:24:48 list Mar 04 20:24:49 The EditText views Mar 04 20:24:55 it woul ebe asier if you didn’t knwo how many you had Mar 04 20:25:02 ^ Mar 04 20:25:51 I would really only use a List or ArrayList there Mar 04 20:26:04 adding/removing is much easier Mar 04 20:26:10 iteration is a breeze Mar 04 20:26:12 Well, problem is, they're not in any particular order Mar 04 20:26:16 doesnt matter Mar 04 20:26:23 well your list will be in whatever order you put them in Mar 04 20:26:46 MarkyC, that is fine. When you create the drawable pass in 4 urls, and invalidate the drawable when they're loaded Mar 04 20:26:48 Right, but they won't necessarily all be one after another Mar 04 20:26:59 you’re goign tohave to develop some logic for that then Mar 04 20:27:10 maybe use setTag() or getTag() Mar 04 20:27:16 editText.setTag() Mar 04 20:27:23 There might be separators in between clumps, or perhaps even have clumps of them in different elements, so they might not even all have the same parent Mar 04 20:27:43 I’m confused as to what you’re doing Mar 04 20:27:45 only you know Mar 04 20:27:48 quinnjn: Ahh, you mean an XML drawable, correct? Not a simple picture in the drawable-_dpi folder? Mar 04 20:27:49 I'm not looking to manipulate the field itself Mar 04 20:27:51 Just the values Mar 04 20:27:53 but those are some tools you can use Mar 04 20:28:05 I;m confused man Mar 04 20:28:37 MarkyC, a custom drawable but not XML. Check this out for a sample: http://stackoverflow.com/a/2968815/1473536 Mar 04 20:28:40 But since I need to refer to each of the 15 more than once, I don't want to waste space typing out "(EditText) findViewById(R.id.scout_form_field2)" three or four times in the code Mar 04 20:28:52 In order to get a value or set a tag or something Mar 04 20:29:26 I want to be able to put them in an array and be able to do something like formAnon[2] Mar 04 20:29:28 I have this datepickerfragment. how can I access the datepicker to set the spinners and calendar view? Mar 04 20:29:29 Instead of (EditText) findViewById(R.id.scout_form_field2) Mar 04 20:29:31 Is this in the same class? Mar 04 20:29:33 do it globally Mar 04 20:29:47 Right now it's all in the same class, yes Mar 04 20:30:00 MarkyC, try load a async picture with that sample using picasso or similar. Mar 04 20:30:45 private EditText[] formAnons = new EditText((EditText) findViewById(R.id.scout_form_field1), (EditText) findViewById(R.id.scout_form_field2), ...); Mar 04 20:30:49 formAnaon[2] assumes that you already know the order… no? Mar 04 20:30:50 But that doesn't work Mar 04 20:31:01 Not nevessari;y Mar 04 20:31:08 lolol Mar 04 20:31:12 let me edit that for you Mar 04 20:31:24 The IDs are just arbitrarily numbered to 15, since there are 15 of them Mar 04 20:31:36 EditText[] formAnons = new EditText[] {(EditText) findViewById(R.id.scout_form_field1), (EditText) findViewById(R.id.scout_form_field2), …}; Mar 04 20:31:48 I think that’s how you want it Mar 04 20:32:22 Well that was freakin stupid of me Mar 04 20:32:26 Lolol Mar 04 20:32:29 heh, it happens Mar 04 20:32:38 Sometimes you gotta have that second set of eyes to debug Mar 04 20:32:39 I forgot a break; yesterday in my switch/case Mar 04 20:32:45 most def Mar 04 20:32:47 Llol Mar 04 20:32:54 I wish you would have posted that earlier though Mar 04 20:32:57 pastebin is our friend Mar 04 20:32:58 I'm on a high school robotics team Mar 04 20:33:04 And this app is for scouting for us Mar 04 20:33:05 oh nice Mar 04 20:33:18 best of luck Mar 04 20:33:30 It's the end of our season. Mar 04 20:33:48 But my backup programmer left me to work on CAD for a few months a while ago, and there was a few month span where I had to debug my own code. Mar 04 20:33:50 XD Mar 04 20:34:09 Everyone debugs their own code haha Mar 04 20:34:10 How can I pass a view from an adapter to an activity? Mar 04 20:34:16 Will the view represent the same thing? Mar 04 20:34:21 there is QA who uses your app and catches bugs Mar 04 20:34:59 AKK9: That doesn't sounds like a good idea :D Mar 04 20:35:17 Well, to be fair, I'm the only one that "knows" Java (I've been learning as I go), so the QA is me while I'm home and sitting in front of Android Studio Mar 04 20:35:41 that heppens, I was the only one who knew Java/Android in our competition Mar 04 20:35:57 yiati, I'm using recyclerview and I want to launch an activity in the onclick listener which I assign in the recyclerview adapter. Mar 04 20:36:03 took 6 months and everyone dropped out but I won the competition solo Mar 04 20:36:07 I hate Java with a passion, because it's just kinda finnicky. Mar 04 20:36:10 Lol Mar 04 20:36:40 I heard the "Saying Java is great because it works on all platforms is like saying anal sex is great because it works on all genders" joke a while back Mar 04 20:36:53 quinnjn: I'm not sure I follow. That looks to just draw a rectangle. I'm familiar with downloading and setting images, my particular issue is with creating that type of layout, where 4 images are arranges in a square, with another image overlayed on top Mar 04 20:37:00 But anyway, one of our mentors gives me shit all the time, and says he has a task I'm probably gonna hate Mar 04 20:37:03 yiati, but I can't do any of the things to launch an activity from the adapter. Mar 04 20:37:19 He brought up the app, and then I whined about having to work with Java, and he laughed a little. Mar 04 20:37:25 MarkyC, hold on i'm testing this theory Mar 04 20:37:39 AKK9: Make a listener for the activity to implement and pass to the adapter Mar 04 20:38:05 So he was laughing because he didn't have to work with Java, and if I get it done by tomorrow night, I can rub the completed app in his face for getting it done in a week Mar 04 20:38:41 quinnjn: I had two (possibly wrong) ideas before coming to this channel: a gridview (but how do I overlay the 'play' button on top?), and a relativelayout (how do I force squareness?) Mar 04 20:38:45 yiati, a listener for what? Mar 04 20:39:22 AKK9: To tell the listener that you want to launch an activity Mar 04 20:39:34 relativelayout with a bunch of LinearLayout rows Mar 04 20:39:48 relativelayout can overlay voews Mar 04 20:39:51 views Mar 04 20:39:58 yiati, oh yeah well the adapter has a reference to the activity, so I just call a method on the activty to launch the activity Mar 04 20:40:00 that bit is okay Mar 04 20:40:07 But the bit im having trouble wit Mar 04 20:40:25 tricknology: I assume you're addressing my question? How do I enforce the squareness when using a RelativeLayout? Mar 04 20:40:27 is that I want to use ActivityOptions.makeScaleupAnimation Mar 04 20:40:32 yes Mar 04 20:40:44 But that method needs the View to scale up from. Mar 04 20:41:11 yiati, and I'm not sure how to provide the view if it's being claled from the adapter. Mar 04 20:41:15 AKK9: The activity already has access to all views it displays Mar 04 20:41:28 findViewById Mar 04 20:41:37 swuareness with a relativelayout is accomplished by ising listview rows having orientation=horizontal Mar 04 20:41:46 then relative those rows together Mar 04 20:41:54 yiati, yeah but the view is in the recyclerview Mar 04 20:42:07 the thing that is being clicked is in the recyclerview Mar 04 20:42:18 i want it to scale up from that Mar 04 20:42:44 Okay make a listener, and pass the view as a parameter in it Mar 04 20:45:53 MarkyC works, generating a gist Mar 04 20:46:17 Napalm i have no i dea how to email dave smith about that ble concurrency bug :| Mar 04 20:47:47 Hmm, so my code compiled fine, but, tricknology, there was a NullPointerException thrown where I declared that EditText array you fixed Mar 04 20:48:49 MarkyC, https://gist.github.com/quinnjn/28163372ac19c4903b13 Mar 04 20:49:44 that will load a image url using picasso into your drawable and redraw it with the bitmap. This should be a good start point for your req. Mar 04 20:50:53 quinnjn: Ahh, so I just change the offset of the draw when I need to add the next 3 images Mar 04 20:50:59 Also, tricknology, or whoever else can fix what he had with "EditText[] formAnons = new EditText[]{(EditText) findViewById(R.id.scout_form_field1), ...);" Mar 04 20:51:05 MarkyC, you betcha! Mar 04 20:51:25 I'm away for a half hour or so, so mention me, and I can find the red message when I get back Mar 04 20:51:47 TechGeek01: http://jakewharton.github.io/butterknife/ Mar 04 20:51:50 quinnjn: like (assuming firstPicture.width is the width of the first picture) canvas.drawBitmap(secondPicture, firstPicture.width, 0, paint); Mar 04 20:52:02 quinnjn: thank you very much Mar 04 20:52:14 TechGeek, eh? Mar 04 20:52:26 Okay, never mind, I don't have to go anywhere Mar 04 20:52:29 on that line? Mar 04 20:52:39 @InjectViews({ R.id.first_name, R.id.middle_name, R.id.last_name }) Mar 04 20:52:41 List nameViews; Mar 04 20:52:43 Yeah. Right on the first declaration line Mar 04 20:52:56 that’s a nice trick yiati Mar 04 20:52:56 MarkyC, maybe. You're prob better off getting the bounds and then using that, figure out equal quadrants and resize the bitmap to fit in that quadrant Mar 04 20:53:16 tricknology, you need Butterknife to do it, but yes it's nice Mar 04 20:53:43 I think one of the things you’re trying to find is retunring null Mar 04 20:53:48 are these views in XML? Mar 04 20:53:51 MarkyC, check out Bitmap.createScaledBitmap(..) and onBoundsChange(Rect bounds) to do that Mar 04 20:55:03 can you pastebin your stacktrace TechGeek01? Mar 04 20:55:09 nulls will instantiate http://ideone.com/TYSzeo Mar 04 20:55:18 maybe that’s not the line you think.. Mar 04 20:55:33 stacktrace is the red stuff in LogCat Mar 04 20:56:31 tricknology, yeah Mar 04 20:58:00 Has anyone ever seen like reusing a complicated view hiearchy in a view pager? Mar 04 20:58:07 so that it doesn't have to be reinflated Mar 04 20:58:23 yeah Mar 04 20:58:27 tricknology: http://pastebin.com/gUTP2v1c Mar 04 20:58:33 tricknology: where? Mar 04 20:58:57 I don’t remember :( Mar 04 20:59:10 IRC there was some Visibility stuff going down Mar 04 20:59:55 Tricknology: Are you afk? =) Mar 04 21:00:02 I’m here Mar 04 21:00:06 ahh there is a horizontal listview Mar 04 21:00:16 maybe i can use a gridview Mar 04 21:00:34 at org.bdrobohackerz.robohackerzscouting.ScoutFormActivity.(ScoutFormActivity.java:18) Mar 04 21:00:41 msg nickserv identify bluball91 Mar 04 21:00:44 line 18 is that edittext[] ? Mar 04 21:00:47 ignore that Mar 04 21:00:53 lol fail Mar 04 21:01:18 Do you guys recommend Eclipse or Android Studio to do Android development? Mar 04 21:01:23 AS Mar 04 21:01:31 it’s the new standard so might as well get onboard, esp if you’re new Mar 04 21:01:42 I started working on Android development a few years back, and have since stopped, and back then there was no viable alternative besides Eclipse. Mar 04 21:01:48 tricknology: Got you. Mar 04 21:02:09 yeah same here. But I’m still on Eclipse, moving to AS is too time consuming for me ATM Mar 04 21:02:28 tricknology: Is there a huge learning curve? Mar 04 21:03:00 no Mar 04 21:03:10 use AS Mar 04 21:03:18 does anyone here know about android studio or is there a better place to ask? Mar 04 21:03:38 miketo: do you have a question? Mar 04 21:04:22 miketo: https://www.youtube.com/watch?v=cyfbRz4ObFY&t=12s Mar 04 21:04:24 yes, i asked a bit ago. i cant get the preview to work for api16 (among other things) Mar 04 21:04:55 Line 18 is the declaration, yes Mar 04 21:05:25 Had to AFK for a bit, sorry about the wait, tricknology Mar 04 21:05:47 miketo do you have that installed? Mar 04 21:05:52 jaana, i don't understand ^^;; i assumed that anyone here would know, but there were no responses. Mar 04 21:06:08 lasserix, yep. removed and reinstalled actually Mar 04 21:06:14 miketo: I was just being silly. A lot of people here know about AS, just ask away Mar 04 21:06:29 try taking those thigns otu of the list.. I know you didn’t want to do that.. but comment out line 18 and do it the old school way Mar 04 21:06:31 tricknology: To be exact, line 18: EditText[] formAnons = new EditText[]{(EditText) findViewById(R.id.scout_form_field1), Mar 04 21:06:49 EditText et1 = (EditText)findViewById(R.id.et1) Mar 04 21:07:40 then do EditText[] texts = new EditText[]{et1,et2,et3…etn} Mar 04 21:07:48 re run and see if it fails in the same spot Mar 04 21:08:24 my _guess_ is that its failing because it can’t findViewById(R.id.whatever) or that somehow R.id.whatever is retunring null to findViewById() Mar 04 21:08:30 try cleaning your project Mar 04 21:08:39 exp after changes to XML Mar 04 21:09:17 He probably has that as a class member Mar 04 21:09:22 So, calling findViewById before onCreate Mar 04 21:09:42 here's image of failed render (TimePicker) http://picpaste.com/pics/rend_problem.1425503355.png Mar 04 21:10:28 i've invalidated cache/restarted also Mar 04 21:10:36 miketo, that looks like the viewgroup is to small to hold the buttons Mar 04 21:11:03 Same spot Mar 04 21:11:14 The new line 18 failing is "EditText et1 = (EditText) findViewById(R.id.scout_form_field1);" Mar 04 21:11:18 danijoo, what. did you read the message on the screen? if i change api to 21 it shows correctly (ish) Mar 04 21:11:30 TechGeek01: Pastebin your code Mar 04 21:11:55 Hmm. Could it have something to do with me setting visibility to gone Mar 04 21:11:56 ? Mar 04 21:12:02 No Mar 04 21:12:13 Pastebin your code Mar 04 21:12:24 XML or Java? Mar 04 21:12:36 Java, since that's what's failing Mar 04 21:13:03 miketo, whats your api level before u change it? Mar 04 21:13:14 http://pastebin.com/nftnBD2y Mar 04 21:14:33 21. tools:21, compileSdkVersion 21, minSdkVersion 16, targetSdkVersion 21 (default project settings use appcompat-v7:21.0.3) Mar 04 21:15:01 then R.id.scout_form_field1 is null Mar 04 21:15:11 TechGeek01 post your xml plx Mar 04 21:15:24 xml and java then ha Mar 04 21:15:36 its weird it would let you compule and then null out on findViewById() Mar 04 21:15:36 miketo, what happens if you set compileSDK to 19 Mar 04 21:15:59 I’m goign to lunch, cya in a bit Mar 04 21:16:00 also, is this only a bug in the preview or an actual one? Mar 04 21:16:03 TechGeek01: You're calling findViewById before onCreate Mar 04 21:17:16 Ah hah. That would do it Mar 04 21:17:17 danijoo, i don't have 19 installed. i have sdk for 16,17,21 and build-tools for 17,21 installed Mar 04 21:18:21 miketo, only in preview or does it also bug on real device Mar 04 21:18:47 That would definitely do it.. your XML is not inflated yet so it doesn;t knwo where to look Mar 04 21:18:57 Anyone seen a snapping recycler view? Mar 04 21:19:41 danijoo, it works fine on device (although on-device render is significantly different from any available preview) Mar 04 21:19:58 Hi SimonVT ! Mar 04 21:20:15 miketo, well then i cant really help you. my usual advice is to not trust the preview :P Mar 04 21:20:19 sry Mar 04 21:20:53 SimonVT: Can I PM you ? Mar 04 21:25:04 Is it important? Mar 04 21:25:23 SimonVT: Nah. Mar 04 21:25:52 Then I'd rather go to bed :) Mar 04 21:25:57 SimonVT: Sorry for disturbing, drop me a note when you have some spare time for "non-technical" disscussion. Mar 04 21:25:58 danijoo, can you (or anyone else) tell me where to find the error log for this error (it says on screeen "9 similar errors not shown", presumably there's a log somewhere) Mar 04 21:26:15 SimonVT: You've helped me to create Android Prototype arond 1.5 years ago. Mar 04 21:27:03 Did you make millions? Mar 04 21:27:34 SimonVT: You won't guess. Mar 04 21:27:56 SimonVT: (I hope you are platform agnostic, but I've become iOS developer) Mar 04 21:28:25 SimonVT: And we have fully working version of the app in AppStore Mar 04 21:31:25 hi all, what would you guys recommend for asynchronous loading of rapidly changing data? I am currently using AsyncTask Loaders, but the data seems to reset them before they finish delivering the result Mar 04 21:32:03 bluesm: you have abandoned us? D: Mar 04 21:32:19 hat kind of data Mar 04 21:32:23 bluesm: how's iOS treating ya? I went the other way :) Mar 04 21:32:50 its just data im storing in maps Mar 04 21:33:10 i have to combine several cursors and store it as just a datatype I defined a class for Mar 04 21:33:24 where do you get it from? database, website,.... ? Mar 04 21:33:58 getting it from a database, but its not sql Mar 04 21:34:03 groxx: Have you been here about 1.5 year ago ? Mar 04 21:34:07 cloudant sync-android Mar 04 21:34:37 im wondering what kind of data could change faster than async task to a database... Oo Mar 04 21:34:53 bluesm: nope. been doing android for a couple years now, but only recently lurking in here. Mar 04 21:36:04 so the database is json backed, and some of the queries create several cursors I have to go through and compute data from, so even though the data is changing at like 1 Hz, it sometimes beats the loader Mar 04 21:36:35 if the data in the database changes at 1Hz, you might want to change your app design.. Mar 04 21:36:54 and maybe only put it into database when the app goes pause Mar 04 21:37:03 danijoo: Have you heard about "realm.ios Database" Mar 04 21:37:17 danijoo, what would you suggest as an alternative? Mar 04 21:37:45 bluesm, yes i have Mar 04 21:38:39 danijoo: Could it be solution for fast changing data ? Mar 04 21:38:46 is onCreateOptionsMenu required if I don't want a menu? Mar 04 21:38:53 Matulis, depends on what kind of data it is and what you need it for. maybe only query for it every few seconds and not for every change Mar 04 21:38:59 bluesm, I am already using cloudant sync-android Mar 04 21:39:31 for example to get locations on a map, do a query every 5 seconds or when the user scrolled the map a specific amount Mar 04 21:39:57 danijoo, unfortunately data needs to be refreshed as soon as available Mar 04 21:40:36 data is a list of currently visible objects being scanned Mar 04 21:40:51 Matulis, does it have to be cloud based? Mar 04 21:41:28 i dont have much experience with this :/ Mar 04 21:41:29 danijoo, so its not really "cloud based" right now data is read from a server and synced to the tablet, which then updates its views with teh new data Mar 04 21:42:06 so essentially the problem can be simplified to assuming the database is local, since the syncing is not the current delay Mar 04 21:42:18 open a socket and receive data Mar 04 21:42:28 or use XMPP which is a protocol made for that Mar 04 21:42:37 "Mike Ey, Microsoft HoloLens designer, killed in hit and run" ohhh maaannnnn Mar 04 21:42:38 or some similar protocol Mar 04 21:42:41 local databases should be much faster than 1Hz Mar 04 21:43:03 for queries or syncing? Mar 04 21:43:10 queries Mar 04 21:43:18 that too. Mar 04 21:43:35 should be a question of milliseconds, not seconds Mar 04 21:44:14 danijoo, yeah i should probably optimize my queries Mar 04 21:45:54 benchmark and find the bottleneck! Mar 04 21:46:35 yeah, will do! thanks for the help Mar 04 21:47:36 weird so fragmentstatepageradapter fragment's onattach is called before oncreate? Mar 04 21:48:04 lasserix, thats normal behaviour Mar 04 21:48:10 onAttack is always called before onCreate Mar 04 21:48:21 Attach* Mar 04 21:49:08 lol Mar 04 21:49:24 lasserix, http://developer.android.com/images/fragment_lifecycle.png Mar 04 21:49:53 oh Mar 04 21:50:08 so fragmentstatepager always destroys fragments more than 1 away from the current? Mar 04 21:50:36 lasserix, are you sure you dont want FragmentPagerAdapter instead of FragmentStatePagerAdapater? Mar 04 21:50:50 if you dont know the difference, you want the first one Mar 04 21:51:13 Napalm: Yo! Mar 04 21:51:25 yo Mar 04 21:51:32 I cant figure out how to get my top-level LinearLayout to actually fill the entire screen. It leaves some space at the top and the bottom. Mar 04 21:51:33 Napalm: Can I PM ? Mar 04 21:51:42 if you want Mar 04 21:52:03 newbQ: match_parent Mar 04 21:52:27 lasserix, StatePager is for things like an ebook reader where you constantly have to destroy and recreate frags because of large datasets Mar 04 21:52:46 Guys, is there a way to view the contents of my apps SQLITE db on my phone? Mar 04 21:52:48 Is it possible to add a custom view inside a RecyclerView by typing the data inside a dialog box and then displaying the added views by category,time,date,etc ? Mar 04 21:52:51 thats why it destroys them Mar 04 21:52:55 yiati: it has match_parent. http://pastebin.com/k9Ea3V1R Mar 04 21:52:57 right Mar 04 21:53:00 Or can I only access the info with queries Mar 04 21:53:02 lasserix: yeah, it saves their state and then destroys them. when it recreates them it'll give them the saved instance state bundle. Mar 04 21:53:06 at what point does a dataset become large? Mar 04 21:53:20 when you OOM :) Mar 04 21:53:25 so the pages i have have REALLY complicated view hieararchies Mar 04 21:53:35 i want to recycle them but cant figure that out yet Mar 04 21:53:49 newbQ: Are you confusing the padding as margins, if not then are you sure that's the root layout Mar 04 21:53:49 imthinking snapping recycler view might be better just use it horizontally Mar 04 21:54:00 lasserix, i wont you statepager unless the number of fragments is "undefined large" Mar 04 21:54:12 like a book of x pages Mar 04 21:54:26 or if your fragments hold a lot of data, but you want to save their current state. e.g. say each fragment is a "view" into a large dataset, and you have multiple datasets. you can get rid of the data when the fragment is destroyed, but the saved instance state (the current view / filter / whatever) will be saved so you can recreate it. Mar 04 21:55:32 yeah thats why i was thinking of using it Mar 04 21:55:45 each page just has a really large view hiearchy Mar 04 21:55:52 yiati: I'm sure its the root layout. I'm not sure how to use the padding/margins. those were the defaults so I havent touched them Mar 04 21:56:25 newbQ: try getting rid of the top and bottom padding in that layout at least to see if it's doing what you expect after that Mar 04 21:56:59 after removing them, the layout still doesnt fill the screen top to bottom Mar 04 21:57:14 newQ: Also some reading, http://stackoverflow.com/a/4619943/1229735 Mar 04 21:57:35 if i do "new AsyncClass().execute("");" while AsyncClass is a seperate java-class which extends AsyncTask, will the created object be garbage collected if the task is finished? Mar 04 21:57:59 newbQ: Then either 1) The margin/padding/height is being modified elsewhere, or 2) That isn't the root layout Mar 04 21:58:25 adkins, yes, if you dont have memory leaks Mar 04 21:58:39 adkins, yes. why do you care? Mar 04 21:59:00 newbQ: If you are on a rooted device you can check out the hierarchyviewer too, http://developer.android.com/tools/help/hierarchy-viewer.html Mar 04 21:59:02 it's handy Mar 04 21:59:08 because i am a careful person ;) i dunno, just wondering Mar 04 22:00:05 yiati: not on root. deleting the padding and setting top and bottom margin to negative values seems to be working Mar 04 22:00:06 if you dont hold references from in that class from outside, it will get gc'ed Mar 04 22:00:19 danijoo: gdrc thx Mar 04 22:00:24 newbQ: That's not solving your problem though, that's a hacky fix Mar 04 22:00:46 You need to figure out where that padding/margin/differentheight value is so you can be aware of it Mar 04 22:01:25 newbQ: Btw you can use hierarchyviewer on an emulator Mar 04 22:01:25 Welcome back, tricknology. How was lunch? Mar 04 22:01:27 danijoo: what if i do that again while the old task is not finished? Mar 04 22:01:37 Was satisfying Mar 04 22:01:43 i think you can call execute only once Mar 04 22:02:22 at least you should only do it once :) Mar 04 22:03:25 danijoo: well it seems it can only be called once, so i dont care if i might call it twice ;) Mar 04 22:04:01 yiati: I dont have any other places where padding or margin are used in that XML file. will it be changed in the manifest or somewhere else? Mar 04 22:04:57 danijoo: docs say an exception will be thrown if its called twice.....do i neeed to catch that to not get an error/crash? Mar 04 22:05:10 adkins, just dont call it twice lol Mar 04 22:05:47 danijoo: well it gets called on gps position change..... Mar 04 22:05:59 I have a question is it possible to do this : What i want is to pop up a dialog or some box where i can input text, and add that text on a textView inside a cardView on a recyclerView. ( Hope you understand me. XD) Mar 04 22:06:01 lasserix: it may be worth it, but do you need to save the state? e.g. if they move like 5 pages away, would they expect to come back to exactly the same thing, or would reloading it from scratch make sense? Mar 04 22:06:04 adkins, make sure its not called on the same instance of the task Mar 04 22:06:19 i probably dont need to save state in that case Mar 04 22:06:28 if you do new AsyncTask().execute(), its two different instances Mar 04 22:06:36 mostly i am just trying to figure out how to recycle the view hierarchy Mar 04 22:06:50 I wish textView had a deleteEnd() method so i didn’t have to substring :( Mar 04 22:07:14 danijoo: dont get it.....why two? Mar 04 22:07:18 So what i need is a name, time, another name and small 3 letter text. Mar 04 22:07:33 adkins, because you are creating two different objects of type AsyncTask Mar 04 22:07:54 if you have a car class and do new Car() 2 times, you have two different cars, not the same car tice Mar 04 22:07:56 Anyone ? xD Mar 04 22:08:03 basic java stuff Mar 04 22:08:15 what Nightwalkerkg? Mar 04 22:08:26 I typed it 2 sec ago. xD Mar 04 22:08:28 danijoo: i didnt know you were talking about the case it gets called twice Mar 04 22:08:35 i see.. use a DialogFragment Mar 04 22:08:39 customized Mar 04 22:08:43 then, of course, two Mar 04 22:08:48 I tihnkg you can addView() Mar 04 22:09:41 Ok, thanks Mar 04 22:09:41 this should help you get started Nightwalkerkg http://stackoverflow.com/questions/13257038/custom-layout-for-dialogfragment-oncreateview-vs-oncreatedialog Mar 04 22:09:41 So, I'm using an SQLite DB from I can't remember what site, but anyway, what's the best way to encode an array into a string to store into the DB? Mar 04 22:09:56 JSONArray.join() and .toString()? Mar 04 22:10:09 jsut toString() should be fine Mar 04 22:11:12 danijoo: i dont understand: "make sure its not called on the same instance of the task" Lets say i call it in MainActivity. You mean i have to make sure its not called twice in MainActivity( the same instance) ? Mar 04 22:12:04 And then to make an array from the string, it's JSONarray(STRING)? Mar 04 22:12:56 yeah Mar 04 22:13:04 but make sure yo escape the jsonobject Mar 04 22:13:24 Hey guys I know someone here told me not to buy a laptop that has a max of 8GB of RAM Mar 04 22:13:30 Where at? Mar 04 22:13:35 Do you think 12GB is enough? Mar 04 22:13:38 VALUES ("'+jsonobject+'",... Mar 04 22:13:49 adkins, you asked me about exceptions if you call execute twice Mar 04 22:13:54 depends on how you execute your sql Mar 04 22:13:55 and I said dont do that Mar 04 22:14:00 call it once per isntance Mar 04 22:14:10 drose 8is not enough Mar 04 22:14:12 if you do new AsyncTask().execute() , thats once time Mar 04 22:14:16 12 is ok but make sure its expandible Mar 04 22:14:21 and does it have a SSD? Mar 04 22:14:34 if you hold a reference to your asynctask object and call it twice on that instance, its two times (->exception) Mar 04 22:14:57 Yes tricknology it has a 256GB SSD Mar 04 22:15:10 Do you think thats enogh to run Windows and Linux Mint side by side Mar 04 22:15:22 12 yeah Mar 04 22:15:25 danijoo: i`ll do it ;) Mar 04 22:15:34 if you can get 16 do it, but 12 is fine Mar 04 22:15:45 at least let it be upgradeable Mar 04 22:16:00 none of that 1-stick stuff. lenovos sometimes have 1 stick of 8, and that’s the limit, 8 Mar 04 22:16:14 I think mine has 1 stick of 4 which is the base Mar 04 22:16:23 then I was gonna go with 8 so another stick of 4 Mar 04 22:16:24 does it have another slot? Mar 04 22:16:29 oh ok Mar 04 22:16:35 then cool, later you can get another stick of 8 Mar 04 22:16:37 tricknology: http://pastebin.com/bKdHKfz6 Mar 04 22:16:39 Its the New ThinkPad T450s Mar 04 22:16:45 That's the DBAdapter I'm using Mar 04 22:16:46 You heard of it? Mar 04 22:16:55 RAM prices are liek stock btw, theyll be cheap some months, expensive the others Mar 04 22:16:57 db.getMatch() to query Mar 04 22:17:15 And db.saveMatch() or .updateMatch() to save Mar 04 22:17:38 Sorry, .insertMatch, not .saveMatch Mar 04 22:18:53 ah Its been a minute since I’ve used contentvalues Mar 04 22:18:59 not sur ewhat happens under the hood Mar 04 22:19:01 try just using a string Mar 04 22:19:09 tricknology what is SoDIMM Mar 04 22:19:15 when talking about RAM Mar 04 22:19:31 means you need 2 Mar 04 22:19:32 Just smaller ram Mar 04 22:19:38 Oh ok Mar 04 22:19:46 Cause it says for the 12GB option: Mar 04 22:20:01 4GB Base + 8GB (1 SODIMM) Mar 04 22:20:07 or is that the SIMM that you require 2 Mar 04 22:20:13 notebooks usually have sodimm Mar 04 22:20:23 simmi spairs then Mar 04 22:20:25 its just the name for the modules that are smaller Mar 04 22:20:27 dimm is singular Mar 04 22:20:36 For escaping my JSONArray, then, if I escape when I store, and unescape when I pull it back out, I should be good then, right? Mar 04 22:20:40 Ok, got it Mar 04 22:20:56 Thanks guys Mar 04 22:21:02 Just try is as a regular string ifrst Mar 04 22:21:15 my only concern is that it will think your “ are terminating the string Mar 04 22:21:15 Without escaping? Mar 04 22:21:18 yeah Mar 04 22:21:23 Android should be smart enough Mar 04 22:21:33 it’s usually for when you build your own execute statements Mar 04 22:21:49 i gotta put the irc down Mar 04 22:21:55 If I were to use whatever delimeter JSON uses (commas?) Mar 04 22:22:02 see ya tricknology Mar 04 22:22:09 Then would it split weird? Mar 04 22:22:27 try and see :) Mar 04 22:22:28 Or would it know which were from data and which to split into the array at? Mar 04 22:22:40 It uses commas, though, correct? Mar 04 22:22:46 my guess is since you’re inserting a string, it will escape it for you, no matter what is in there Mar 04 22:22:50 danijoo: but if i dont hold any reference, just like i said ( new AsyncClass().execute(""); ) i dont need to bother if i already did this before and do it again before last time is finished right? if it gets called twice, i have to seperate objects and whichever is done gets garbage collected Mar 04 22:22:51 try to SQLInject yourself Mar 04 22:22:55 I bet it uses prepared statements Mar 04 22:22:56 Oh, and JSONArray(c.getString(3)); Mar 04 22:23:02 yeah Mar 04 22:23:08 adkins, yes Mar 04 22:23:10 thats the constructor Mar 04 22:23:15 c.getString is how we pull cells from the DB, so it's a string Mar 04 22:23:18 it can throw JSONException though Mar 04 22:23:21 yeah Mar 04 22:23:24 danijoo: and i dont call execute on the same object twice, so its all good Mar 04 22:23:30 It tells me "method call expected" Mar 04 22:23:31 yes Mar 04 22:23:32 if you set the col to TEXT Mar 04 22:23:37 Hey what if I want to run a rawQuery() without selection args? Mar 04 22:23:45 danijoo: thanks for confirmation ;) Mar 04 22:23:50 then drose379, you build the statement yourself Mar 04 22:24:05 use PreparedStatment for anythign coming in from the outside Mar 04 22:24:14 you dont want to be SQLinjected Mar 04 22:24:24 Im using it to select everything from the inside Mar 04 22:24:29 http://www.w3schools.com/sql/ Mar 04 22:24:36 sqlinjection in android? Mar 04 22:24:47 No i know SQL, but I want to do a SELECT * Mar 04 22:24:52 And that does not require a where Mar 04 22:24:55 can you sqlinject if you use sql.execute()? Mar 04 22:24:56 i havent tried Mar 04 22:25:03 no it doesn't Mar 04 22:25:18 So therefore I cannot provide the selection args Mar 04 22:25:29 db.rawQuery("select * from table",null); Mar 04 22:25:34 drose379, SELECT * FROM table Mar 04 22:25:35 tricknology: Wait what? Mar 04 22:25:39 null will suffice if you read the docs Mar 04 22:25:53 TechGeek01, don’t worry Mar 04 22:25:56 I have some Java background. I want to get into Android development, and just downloaded Android Studio, which is a bit overwhelming atm. What is the best way to learn/get settled into android dev Mar 04 22:25:58 Im on the docs Mar 04 22:26:11 prolifagency, docs and tutorials Mar 04 22:26:16 try android tutorials and vogella Mar 04 22:26:37 profligacy: https://developer.android.com/training/basics/firstapp/index.html Mar 04 22:26:50 How do I create the JSON array, then? Is it just JSONArray(String)? Mar 04 22:26:50 JesusFreke: thanks Mar 04 22:27:10 yiati: it was the weightSum that was screwing it up. Mar 04 22:27:17 so tricknology I can only use null if I read the docs? Mar 04 22:27:19 google android books with filetype:pdf Mar 04 22:27:21 And how would that be declared? Mar 04 22:27:50 sorry drose379, i pointed you in the wrong direction. you want to use rawWuery Mar 04 22:28:06 Oh, I see Mar 04 22:28:08 I was joking Mar 04 22:28:08 db.rawQuery(“SELECT * FROM tablename”,null); Mar 04 22:28:11 ;-) Mar 04 22:28:14 Right Mar 04 22:28:26 You said "Null will suffice if you read the docs" Mar 04 22:28:35 Saying I should read the docs myself Mar 04 22:28:45 Then I jokingly said "I can only use null if I read the docs" Mar 04 22:28:47 I misremembered. Thought that if you pass null for selectionargs it would owrk Mar 04 22:28:53 gotcha Mar 04 22:28:57 :P Mar 04 22:28:59 haha :D Mar 04 22:29:00 Thanks Mar 04 22:29:08 I have an app with 2361 unique users and only 42 active users, no one ever sends feedback on the app despite the feedback button… what to do…? Mar 04 22:29:39 if I have an IAB test account, how can I delete my purchase (basically a refund, or clearing it on google's side so I can test purchasing again) Mar 04 22:29:54 i never send feedback if everything works okay Mar 04 22:30:41 everything works okay but 42 users active out of 2361 seems like people abandon it quickly. Mar 04 22:30:42 TechGeek01, you do: JSONArray jary = new JSONArray(); Mar 04 22:30:51 jary.put(string); Mar 04 22:30:53 regan whats the app Ill test her out Mar 04 22:30:53 JSONArray dataVals = new JSONArray("JSON_String"); Mar 04 22:30:57 Unhandled exception Mar 04 22:31:02 No quotes TechGeek Mar 04 22:31:02 lol nooo Mar 04 22:31:06 profligacy: commonsware Mar 04 22:31:06 Your passing a string in Mar 04 22:31:12 Dont want to do that Mar 04 22:31:17 matt_j, in your google wallet (developer account), you can do a refund Mar 04 22:31:21 Well yeah, right Mar 04 22:31:22 profligacy: http://commonsware.com/ Mar 04 22:31:24 it then takes 1-2 hours Mar 04 22:31:36 if your string is an arry then you do JSONArray dataVals = new JSONArray(string) Mar 04 22:31:59 And that's a string we pass in, correct? Mar 04 22:32:07 if you want to build one from scratch using strings use the other ones I put up there ^^ Mar 04 22:32:09 JsonParser().parse(string).getAsJsonArray() if you use gson :) Mar 04 22:32:16 The string has to be a JSONArray Mar 04 22:32:20 drose379: all my apps can be found on my web site… actually I am building a new web site.. www.pymblesoftware.com.au/new.html Mar 04 22:32:29 liek if you did mJSONArray.toString() Mar 04 22:32:34 of if you got it from a db Mar 04 22:32:53 Ill check it out regan Mar 04 22:33:03 JSONArray jary = new JSONArray(c.getString(“myJSONArray”)) Mar 04 22:33:15 Thanks, that sire is still under construction. Mar 04 22:33:21 It's calling an unhandled exception on the new JSONArray pary Mar 04 22:33:23 s/sire/site/ Mar 04 22:33:36 Here techgeek01 Mar 04 22:33:37 Even though the variable we passed in will be a JSON array Mar 04 22:33:37 http://developer.android.com/reference/org/json/package-summary.html Mar 04 22:33:51 dump it and make sure it is Mar 04 22:33:54 ro debug it Mar 04 22:33:57 or debug Mar 04 22:34:14 you can think it is, but it’s something else Mar 04 22:34:28 This is before we compile, though, which is weird Mar 04 22:36:55 danijoo: oh cool Mar 04 22:39:10 hey guys shouldn't the application class be automatically created with a new project or is it manual? Mar 04 22:40:15 trisme, manually Mar 04 22:40:23 because if is optional to have one Mar 04 22:41:03 ok thanks danijoo, what's the purpose of that class? Mar 04 22:41:22 usally holding stuff :) Mar 04 22:41:51 you can easily access it from everywhere in the app so its nice for stuff like singeltons Mar 04 22:42:10 aah cool Mar 04 22:42:11 MyApplication.getInstance().getMyDatabaseManager() for example Mar 04 22:42:25 or global variable like boolean shoudShowAds Mar 04 22:43:58 Anyone used salvage by jake wharton? Mar 04 22:51:42 so Cursor.getString(int) returns the value of a column, not a row? Mar 04 22:52:19 I dont get that, isnt everyone looking for the value of a row Mar 04 22:53:40 and what if I have multiple rows returned to me and I want to loop over them Mar 04 22:53:46 drose379, the cursor is a pointer, pointing to a single row Mar 04 22:53:47 I dont see a method in cursor for that Mar 04 22:53:58 hmm Mar 04 22:53:59 int hat row, you can get value of columns by position Mar 04 22:54:05 or move to the next row Mar 04 22:54:17 So: Mar 04 22:54:26 "Select * from subject_info" Mar 04 22:54:28 a cursor is something like a list iterator for databases Mar 04 22:54:38 (subject_info has 2 columns) Mar 04 22:54:55 Cursor cursor = rawQeury(query) Mar 04 22:55:12 Does anyone else have problems with step debugging in Android Studio? Mar 04 22:55:21 s73v3r, nope Mar 04 22:55:22 if (cursor.moveToFirst()) { getvalues Mar 04 22:55:58 I'm using Windows, and I'll hit the step over button, and it'll just hang, like it got disconnected or anything Mar 04 22:56:04 this is using Genymotion as the target Mar 04 22:57:59 same setup for me, and it works fine on 2 machines Mar 04 22:58:22 ohh danijoo so I could use moveaToNext() to look at the next row Mar 04 22:58:35 drose379, yeah. like list iterators ;) Mar 04 22:58:43 Thanks :D Mar 04 22:59:05 hey all Mar 04 22:59:26 s73v3r: anything specific in the code that it hangs up on, the debugger can get funky for some java features like ternaries Mar 04 22:59:36 question mark Mar 04 23:00:05 getting a substring of a string? Mar 04 23:00:59 s73v3r, somethings debugger loses connection for me, but thats really rare Mar 04 23:02:47 its a shame that you cant use intellij ultimate features in android studio Mar 04 23:02:50 :( Mar 04 23:07:32 can't you use IntelliJ Ultimate for Android Dev? Or does it lag Android Studio too much? Mar 04 23:07:50 what plugins would you have to install? Mar 04 23:08:22 hey Mar 04 23:08:49 yiati, huh, debugger doesn't get funky for ternary operator Mar 04 23:08:50 s73v3r, you can but for example it does not have the gradle 1.1 experimental junit stuff Mar 04 23:09:06 Norrin, built in sqlite browser Mar 04 23:09:11 Yeah, I was on IDEA before AS came out. Mar 04 23:09:19 It was great, but I heart AS Mar 04 23:09:26 why? Mar 04 23:09:33 AS has nothing compelling vs. IDEA Mar 04 23:09:36 with intellij ultimate, you can directly open the apps sqlite database *on the device* over adb Mar 04 23:09:39 wouldn't vanilla intellij need some plugins to speak to devices? Mar 04 23:09:41 Does anyone know how to install gradle plugin in android studio? Mar 04 23:09:45 Norrin, no Mar 04 23:09:51 vanilla intellij comes with android support Mar 04 23:09:51 New to android studio. Mar 04 23:09:59 android studio = intellij - everything exception android Mar 04 23:10:19 pfn, i especially miss that sqlite feature from ultimate :) Mar 04 23:10:21 perlsyntax, AS should be ready to go Mar 04 23:10:31 ah Mar 04 23:11:08 MikeWallaceDev,mmm must be doing something wroung:) Mar 04 23:11:19 must have :) Mar 04 23:11:25 and if something of the fancy new stuff comes to AS, it usually takes some time until its in intellij EAP Mar 04 23:11:27 perlsyntax, android studio comes with gradle plugin Mar 04 23:12:16 i talking about the one on github. Like testfaily gradle Mar 04 23:12:47 lol i hope i don't sound like a fool. Mar 04 23:13:52 no idea what testfaily gradle is Mar 04 23:14:03 Mcan i paste the link? Mar 04 23:14:07 sounds like a gradle plugin Mar 04 23:14:12 yep is it Mar 04 23:14:21 you can just add it to your build.gradle then Mar 04 23:14:30 lol Mar 04 23:14:39 it has a step by step on its github pag Mar 04 23:14:40 e Mar 04 23:14:45 just follow it >.< Mar 04 23:14:54 org.json.JSONException: Value ["GPS","We","","","","","","","","","","","","",""] at 0 of type java.lang.String cannot be converted to JSONObject Mar 04 23:15:05 i thought i had to inport it into android studio. Mar 04 23:15:12 silly me Mar 04 23:15:29 TechGeek01, this is not a valid jsonobject, its a jsonarray ;) Mar 04 23:15:51 thanks danijoo Mar 04 23:16:09 I literally pulled that off of a StackExchange answering how to convert a JSONArray to a String array Mar 04 23:16:16 Care to help? Mar 04 23:16:26 loop over it Mar 04 23:16:58 .getString? Mar 04 23:17:02 String[] myString = new String[jsonArray.size()] Mar 04 23:17:35 What's better, .size() or. length()? Mar 04 23:17:53 for(int i = 0; i < jsonArray.size(); i++) myString[i] = jsonArray.get(i).toString(); Mar 04 23:17:59 something like that should do the trick Mar 04 23:18:26 TechGeek01, I think one is just a synonym for the other. Mar 04 23:18:35 read the documentation Mar 04 23:19:21 That, Umm. Mar 04 23:19:29 That put the whole array into one field Mar 04 23:20:04 no Mar 04 23:20:04 Instead of Fields 1 and 2 being "GPS" and "We", field is Mar 04 23:20:30 ["GPS","We","","","","","" ...] Mar 04 23:21:14 formAnons[i].setText(jsonArr.get(i).toString()); Mar 04 23:21:36 Same as yours, but it gets the EditText.setText() and pulling value all in one go Mar 04 23:22:27 DAMN YOU TRICKNOLOGY AND YOUR BIPOLAR PING TIMES! Lol /s Mar 04 23:25:48 O.o Mar 04 23:28:07 TechGeek01, this looks like the first element of your array is an array holding this GPS We .... stuff Mar 04 23:28:34 Hmm Mar 04 23:28:51 attach a debugger and check it Mar 04 23:29:53 Saving, we have matchData[i] = formAnons[i].getText().toString() Mar 04 23:30:11 i dont know what all those arrays are. Mar 04 23:30:26 matchData is a string array Mar 04 23:30:40 formAnons is the list of EditTexts Mar 04 23:30:57 What does that have to do with your JSON? Mar 04 23:31:12 thats the question ^^ Mar 04 23:31:17 It doesn't, but the string stored into the DB is Mar 04 23:31:18 String jsonArr = new JSONArray(Arrays.asList(matchData)).toString(); Mar 04 23:31:47 TechGeek01, what are you trying to do Mar 04 23:32:15 that line of code is just nonesense.. You parse an array to a list to a jsonarray and then make a string of it Mar 04 23:32:24 huh what Mar 04 23:32:28 yeah, what does that line do Mar 04 23:33:07 The number of form fields may change in the future, so to make it easier for others to change, we compress all 15 form fields into a JSON array into one DB field Mar 04 23:33:08 that looks like the inconvenient way to make a json string i ever seen Mar 04 23:33:30 Indeed. Mar 04 23:33:31 its like making a foto of your desktop, print it out, scan it in and send it via mail instead of sending a screenshot Mar 04 23:33:36 String jsonArr = new JSONArray(Arrays.asList(matchData)).toString(); was taken directly off of StakcExchange Mar 04 23:33:57 Not to mention losing all form position data by stuffing all that into an array. Mar 04 23:34:05 Not to mention... why the heck store JSON in a DB? O.o Mar 04 23:34:35 Well, stop copying random crap that you don't understand from SE. Mar 04 23:35:00 what I would do is: create an empty json object Mar 04 23:35:16 and for every field, add a new key:value pair to it Mar 04 23:35:36 {"formField1": "value1", .....} Mar 04 23:35:54 or just use the db structure (being a column/value) for that :P Mar 04 23:36:05 wait, its for a db? Mar 04 23:36:11 Yeah Mar 04 23:36:16 >.< Mar 04 23:36:24 why even bother about json then Mar 04 23:36:45 use columns, thats what rational databases are build for Mar 04 23:37:18 if the number of fields change, alter your database accordingly Mar 04 23:37:32 has anyone encountered the "android.system.ErrnoException" while debugging before? Mar 04 23:37:41 I keep getting it when I try to step debug in my app Mar 04 23:37:57 Because I can't be bothered with trying to teach 10 other people that may be modifying this app after I leave the team (our HS robotics team whose app this is for) how to use databases, I'm avoiding having to tweak it every time the number of fields we want changes Mar 04 23:38:38 Are you serious? Mar 04 23:38:38 Hell, they'll barely know how to modify the XML part of it after I teach them 5 times Mar 04 23:39:05 Unless I can get everyone to agree upon a fixe number of form fields Mar 04 23:39:15 Dude. Mar 04 23:39:25 You're writing bunch of complicated pointless crap. Mar 04 23:39:32 Just to avoid an ALTER TABLE call sometime in the future? Mar 04 23:40:02 if the team cant handle the modification after you are gone, they are simply the wrong persons to do it Mar 04 23:40:04 At what point did you think serializing and deserializing data and handling possible structure changes will be easier than just doing a simple insert? Mar 04 23:40:08 and shoudnt touch it at all Mar 04 23:43:10 Fair point Mar 04 23:51:44 hey all. Mar 04 23:51:54 I think I found a bug in Android 5.0 Mar 04 23:52:03 You fixed your bipolar ping issues! Mar 04 23:52:25 tricknology_: what's the bug? Mar 04 23:52:56 if your app use used editText.setInputType(InputType.TYPE_NULL) and you hide the app with the home button, your keyboard no longer works anywhere Mar 04 23:53:10 I need to test mroe and isolate it to exactly that btu.. it happens to me every time Mar 04 23:53:25 Well. I'd say that's a pretty nasty bug\ Mar 04 23:53:34 yeah have to exit my app Mar 04 23:54:04 aah no even with the app exited.. Mar 04 23:54:10 it’s Messenger Mar 04 23:54:21 XD Mar 04 23:54:23 Nice Mar 04 23:55:05 weird.. I’m ognna have to try and reporduce it.. Mar 04 23:55:42 there was stil text in the edittext of the messenger, but it wouldnt let me append to it or delete text from it Mar 04 23:55:54 it would gain focus and setselection, and pop up keyboard Mar 04 23:56:00 but no input.. Mar 04 23:56:10 only when I work on this app.. Mar 04 23:57:31 Hmm Mar 04 23:58:15 Question Mar 04 23:58:26 is there, using IabResult, any way to know how much the item cost? Mar 04 23:58:36 I know it returns the sku, etc Mar 05 00:07:37 tricknology_: that's normal i believe Mar 05 00:08:21 for that to cross over into other apps? Mar 05 00:08:31 liek Google’s SMS Messenger? Mar 05 00:09:07 that probably not ;p Mar 05 00:09:17 hopefully I can isolate it Mar 05 00:09:25 I can’t make it happen every time but I’ve seen it happen a few times Mar 05 00:11:38 tricknology_: if you ever figure it out, I'd be curious :| happens to me too, in most apps. Mar 05 00:11:46 rare, but omg annoying when it happens Mar 05 00:12:21 <3 developer options >> show layotu bounds Mar 05 00:12:27 omg groxx, I’m not crazy! Mar 05 00:12:39 it’s hella annoying :( Mar 05 00:12:51 back a bunch usually cures it.. but wtf Mar 05 00:14:34 yeah. I've wondered if it's related to how we do input in our app... but then it happens in others. maybe we're all just making the same mistake? and then the cross-app behavior could just be buggy keyboard (definitely exists, I get keyboard up over e.g. photo gallery or recent-apps with some regularity) Mar 05 00:15:00 oh weird, I haven’t gotten that. Mar 05 00:15:29 bugs FTW Mar 05 00:15:38 the app I am developing has its own keyboard, and so I set inputType(TYPE_NULL). but that shouldn’t “leak” across applications Mar 05 00:15:55 but then again, it doesn’t happen all the time Mar 05 00:16:02 Does removeVIew(v) invoke onViewDetachedFromWindow for v? Mar 05 00:16:11 OOH just got it Mar 05 00:16:50 messenger is open in background with some text in the field. (has been for abotu 10 mins) my app has the textView with the inputType NULL Mar 05 00:17:19 delete a bunch of characters until nothing in the TV but the view still has focus Mar 05 00:17:26 go back to messenger app, boom Mar 05 00:17:53 back button or sending the incomplete text solves it Mar 05 00:20:04 Anyone have link to full view lifecycle diagram? Mar 05 00:20:13 if it was detatched from a window… that’s kinda vague Mar 05 00:20:20 lasserix for activity or fragment? Mar 05 00:20:26 view Mar 05 00:20:27 aah haha Mar 05 00:20:29 https://github.com/xxv/android-lifecycle Mar 05 00:20:32 star it yo Mar 05 00:20:56 google led me to this: https://plus.google.com/+ArpitMathur/posts/cT1EuBbxEgN Mar 05 00:21:04 view! Mar 05 00:21:14 _entire_ Mar 05 00:21:14 no ondetatch Mar 05 00:21:27 does removeView cause onDetach to be called? Mar 05 00:22:38 yeah, it's certainly a simpler lifecycle :| Mar 05 00:23:03 yeah Mar 05 00:23:12 can you read Japanese? Mar 05 00:23:14 http://www.ecoop.net/memo/archives/android_lifecycle_of_view.html Mar 05 00:23:18 hehe saw that Mar 05 00:23:20 I had a hypothetical question and was wondering what folks think. Let's say we have two SDKs - SDK1 which is not owned by me, and SDK2 which is a SDK I have. Would it be possible to extend SDK1 by adding it to SDK2 and then handling all of the SDK1 calls within SDK2 along with the extended functionality? Would there be any negative implications from something like that? Mar 05 00:23:21 lol Mar 05 00:23:22 google can! Mar 05 00:23:23 what is that one state? Mar 05 00:23:50 the red one? Mar 05 00:23:59 tricknology_: hehe yeah Mar 05 00:24:03 I don’t know katakana L( Mar 05 00:24:11 thammond: you want to make a wrapper? lots of people do that. Mar 05 00:24:26 oblivion maybe Mar 05 00:24:42 pretty much. I'm fairly new to android though so I wasn't sure if there'd be any gotchas. Mar 05 00:24:58 most of the katakana is just "activity" Mar 05 00:25:17 ah. and "event" Mar 05 00:25:41 alas I never learned enough + have forgotten too much kanji Mar 05 00:26:38 tryign to OCR it.. Mar 05 00:27:02 アクティヒ”ティヵ丶ら肖ー」ー夢余されブこ時 Mar 05 00:27:02 まブこ~まアクティヒ'テイ終了時 Mar 05 00:27:29 when over dream Yosa is blanking this Mar 05 00:27:31 アクティヒ”ティ = "activity" Mar 05 00:27:34 thanks google.. Mar 05 00:27:54 Kairi? Mar 05 00:28:43 when activity is over Mar 05 00:28:44 ha Mar 05 00:29:17 “when activity is over” is what the red bubble says Mar 05 00:30:14 last one says pie table chemical composition Mar 05 00:30:34 I think he’s making a chemical composition pie table Mar 05 00:31:29 what, like the periodic table table? http://www.theodoregray.com/PeriodicTable/ Mar 05 00:31:39 lol no Mar 05 00:31:45 chemical composition of a mixture Mar 05 00:31:50 x/100 Mar 05 00:32:03 or could be elemental composition of a chemical Mar 05 00:32:08 if that was chinese i could probably help :D Mar 05 00:33:01 you were wrong side of the Japan Sea. Mar 05 00:33:19 whats wrong with my irc client? http://prntscr.com/6ctkwx Mar 05 00:33:32 haha Mar 05 00:33:33 danijoo: can't handle japanese charactes Mar 05 00:33:36 you don’t have Japanses font Mar 05 00:33:41 ah ^^ Mar 05 00:33:58 ∫ç√Ω≈çåƒß© Mar 05 00:34:00 can you see those? Mar 05 00:34:10 yes Mar 05 00:34:13 your client is all "アクティヒ”ティ"??? -> (╯°□°)╯︵ ┻━┻ Mar 05 00:34:13 hm.. Mar 05 00:34:16 danijoo: do you even unicode bro? Mar 05 00:34:21 groxx, cant see that Mar 05 00:34:29 not even flip table? Mar 05 00:34:37 danijoo: http://cl.ly/image/0r4247110a1V Mar 05 00:34:45 dude.. waht kind of nintendo ds- linux are you running? Mar 05 00:34:51 http://prntscr.com/6ctlgf Mar 05 00:35:00 ଘ(੭*ˊᵕˋ)੭* ̀ˋ ɪɴᴛᴇʀɴᴇᴛs Mar 05 00:35:03 lol Mar 05 00:35:05 So, anyone want to tell me how to disable proximity sensor on hammerhead? I've found the sensors.so file for other platforms, but not for hammerhead. Mar 05 00:35:07 actually its windows 8.1 Mar 05 00:35:13 the build.prop mod doesn't work. Mar 05 00:35:16 font packs pro Mar 05 00:35:18 no idea whats wrong with that :D Mar 05 00:35:20 bro* Mar 05 00:35:26 everything Mar 05 00:35:27 danijoo: did you fuck with your fonts? Mar 05 00:35:30 danijoo: http://cl.ly/image/2l2W1T2H062S Mar 05 00:35:32 yeah. should get them :p Mar 05 00:35:38 you don’t get japanese by default on windows Mar 05 00:35:44 wtf Windows Mar 05 00:35:46 really? Mar 05 00:35:47 you have to download language packs or some crap Mar 05 00:35:48 im new to windows. thats why maybe :D Mar 05 00:35:58 that renders for me, and I didn't install japanese fonts Mar 05 00:36:03 enjoy your free windows 10 Mar 05 00:36:06 i just got interessted because you where talking about chemical compositions Mar 05 00:36:09 geomyidae_: same Mar 05 00:36:17 thats why i wanted to know what this strange icons are :p Mar 05 00:36:18 I am on Threshold though so ymmv Mar 05 00:36:24 i didnt have to install my chinese fonts eiterh Mar 05 00:36:31 yeah, fix ur fonts, so you can see the awesomeness that is ಠ_ಠ Mar 05 00:36:45 http://mintywhite.com/customize/fonts/download-windows-fonts-megapack-1003-free-fonts/ Mar 05 00:36:50 maybe this will help me :p Mar 05 00:37:48 maybe its not windows, but the irc client Mar 05 00:38:16 could be that too. might be mangling UTF8 Mar 05 00:38:23 HexChat Mar 05 00:38:26 i dont know how to type mandarin on this virtual machine :D Mar 05 00:38:50 or whatever the IRC spec delivers ¯\_(ツ)_/¯. it should be UTF8 regardless. Mar 05 00:39:20 any way to get the width of text in a textview? Mar 05 00:39:45 There are many symbols which may not be supported by the main font you selected to use in HexChat, especially Asian glyphs and special characters, like a peace sign. In this case, you’ll see “lego blocks” instead of them. Mar 05 00:39:46 To circumvent this, you need to have alternative fonts for glyphs not supported by your current font. Mar 05 00:39:59 need to install fonts. hmpf Mar 05 00:40:04 yeah Mar 05 00:40:09 welcome to windows Mar 05 00:40:14 tip of the shitberg, randy Mar 05 00:40:28 ^^' Mar 05 00:41:05 i use it since 3 month now. Nobody told me it comes without a single fully utf-8 compatible font lol Mar 05 00:42:03 i don't know that there's any fully utf-8 compatible fonts in existence Mar 05 00:42:23 that'd be one huge font Mar 05 00:42:36 myke, the faq on hexchat suggests some that cover most of it Mar 05 00:42:46 http://unifoundry.com/unifont.html being one of them Mar 05 00:43:02 groxx, give me some more of that to see if it works now! Mar 05 00:43:30 ᕙ(⇀‸↼‶)ᕗ Mar 05 00:43:39 aaand it doesnt :D Mar 05 00:43:46 should restart irc maybe :p Mar 05 00:44:12 previously, you could stick the windows install disk in, and install fonts from that. dunno what to do with win8 Mar 05 00:44:33 groxx, i dont even have a drive for those Mar 05 00:44:44 built that machine without one ^^ Mar 05 00:45:15 if you want to try a different IRC client, I remember liking Nettalk when I used to use windows: http://www.ntalk.de/Nettalk/en/ Mar 05 00:45:16 disks are sooooo 2010! :D Mar 05 00:45:31 barbs: irssi masterrace Mar 05 00:46:00 still dont work. fuck that. i cant japanse anyways Mar 05 00:46:09 lol, I never got into irssi Mar 05 00:46:40 jirc seems like an appropriate client for this channel Mar 05 00:47:22 I read that as "jerk" in my head Mar 05 00:47:27 got manarin working woo Mar 05 00:47:27 ...is that why it's appropriate? Mar 05 00:47:31 danijoo_: 你受中文吗 Mar 05 00:48:07 it doesnt want to work though Mar 05 00:48:10 DadFoundMy, not working, and thats bad Mar 05 00:48:20 because ill start learning mandarin next month (seriously) Mar 05 00:48:27 I see it working in hexchat here Mar 05 00:48:59 danijoo_: you wont be learning characters for a long time it shouldnt matter Mar 05 00:49:17 danijoo_: i barely know any characters after living in china, and learning for several years Mar 05 00:49:34 barbs: that's why it's called that Mar 05 00:49:38 Does android Wear have a standard way to launch apps on the phone? Mar 05 00:50:01 Ankhwatcher: you mean launch an app from your watch onto your phone? Mar 05 00:50:06 no Idea, I’m not going to be an early adopter.. Mar 05 00:50:18 tricknology_: why $30 g watch ftw Mar 05 00:50:26 sooooo happy with it Mar 05 00:50:28 I know I can send a message to my phone app and launch an app that way, I'm just wondering if there is a built in way Mar 05 00:50:28 I would think it would be through an intent.. Mar 05 00:50:39 LA G watch? Mar 05 00:50:47 do you use intents for that' Mar 05 00:50:48 ok. well ill just do a unicert I course at university. so i guess it will be all in pinyin Mar 05 00:50:53 use an intentfilter Mar 05 00:51:03 look up how to open an app from another app Mar 05 00:51:07 + intent filter Mar 05 00:51:15 tricknology_: yeah i got a lg g watch for $80 plus $50 google play credit on cyber monday Mar 05 00:51:22 best purchase of the year for me Mar 05 00:51:22 where the hell did you find an LG G watch for $30? Mar 05 00:51:24 apple should have bought rolex ;) Mar 05 00:51:31 oooh damnit Mar 05 00:51:35 I missed out hard Mar 05 00:51:43 tricknology_: the play store had them, best buy, and groupon all for the same price Mar 05 00:51:54 whoops Mar 05 00:51:59 how thick is that mug? Mar 05 00:52:00 tricknology_: i thought i wouldnt wear it much, but i have used it every single day since getting it Mar 05 00:52:03 I have girly writsts Mar 05 00:52:22 Dimensions: 5.5”x3.5”x2.5” Mar 05 00:52:24 tricknology_: im a 5 ft inch lanky 16 year old. im sure your wrist are bicky Mar 05 00:52:26 2.5”?! Mar 05 00:52:34 5ft8in ** Mar 05 00:52:36 Should I set a textview from the xml or the java? Mar 05 00:52:37 do they mean cm? Mar 05 00:52:49 wherever you want davinci Mar 05 00:52:56 XML will yell at you and tell you to use @string tho Mar 05 00:53:03 whoch you can set in strings.xml Mar 05 00:53:07 YungDaVinci: do it in xml unless you have to do it in java Mar 05 00:53:15 tricknology_: the stock band goes pretty small, but i got a metal one for it anyway Mar 05 00:53:21 ill take a pic of how it looks one sec Mar 05 00:53:37 no I mean the depth Mar 05 00:53:39 from back to face Mar 05 00:53:45 I got a metal band from amazon for mine, even with all the link's removed it is still too big lol Mar 05 00:53:55 long sleeves an issue? Mar 05 00:54:10 Ended up going into a watch shop to get one Mar 05 00:54:11 I wear a citizen ecodrive.. that’s as big as I can get Mar 05 00:54:13 MXfive: which one? Mar 05 00:54:14 I have a g watch for dev and a 360 for wearing Mar 05 00:54:15 stilletto would be perfect Mar 05 00:54:16 chinese language pack - 300 mb Mar 05 00:54:24 LG G Watch R, I'll link the strap Mar 05 00:54:24 just lol Mar 05 00:54:30 you liek the 360 better? Mar 05 00:54:39 http://www.amazon.co.uk/Ritche-Stainless-Steel-Bracelet-Straight/dp/B00DKYC7TK/ref=sr_1_3?ie=UTF8&qid=1425516871&sr=8-3&keywords=lg+g+watch+r Mar 05 00:54:39 hell yes Mar 05 00:54:42 Ankhwatcher: how do you like the 360? i honestly think i would prefer the g watch just for the battery life Mar 05 00:54:42 what do tou think og the new huynang? Mar 05 00:54:46 thats more than the last windows I used was in size Mar 05 00:54:49 I want a flavor flav smart clock Mar 05 00:55:06 I would die with low batt life Mar 05 00:55:09 tricknology_: the huiwei one? Mar 05 00:55:11 lol @ smooz Mar 05 00:55:21 I get a good 30 hours on the LG watch, just charge it every night and you won't even think about it Mar 05 00:55:24 my g watch last like 2.5 days with screen always on Mar 05 00:55:34 huiwei* Mar 05 00:55:40 I'd like to see the Huawei one irl Mar 05 00:55:42 yeaaaah boyyyy Mar 05 00:55:47 1k price tag tho Mar 05 00:55:51 and it charges pretty fucking quick so i just charge it in the morning b4 school Mar 05 00:55:52 if they were thinner I’d be down Mar 05 00:56:01 watches today are liek zack morris phones Mar 05 00:56:03 I've seen a G Watch R irl, it's kind of big and clunky Mar 05 00:56:04 What is the easiest way to customize the appearance of a ClickableSpan on click? Basically, I need to add some kind of highlight or something while you click that goes away after you move your finger Mar 05 00:56:05 90’s shoulderbag moble Mar 05 00:56:12 tricknology_: it looks good, but is the final version out for purchase yet? Mar 05 00:56:14 not that big and clunky's necessarily bad Mar 05 00:56:21 no DadFoundMy Mar 05 00:56:34 it is if you have kindergartner wrists Mar 05 00:56:49 or wear long sleeves that are supposed to fit over your watch Mar 05 00:57:11 tricknology_: then i dont know for sure if it will look like that in release. the 360 looks very different in renders than production Mar 05 00:57:46 engineering vs cost vs deisgn Mar 05 00:58:13 my 360 was getting repaired for a while, I wore the G Watch while it was getting fixed Mar 05 00:58:15 yeah the HuaWei watch is also photoshopped in the pictures to make it look less digital Mar 05 00:58:25 tricknology_: here is a pic of it on my wrist, although the angle makes it look larger than it is http://imgur.com/Up3EYZz Mar 05 00:58:39 when i got it back I noticed that it was harder to get a sleeve over than the G Watch Mar 05 00:58:40 but it does look like the best looking one so far Mar 05 00:58:58 Ankhwatcher: i find it pretty difficult to get a dress shirt sleve over it Mar 05 00:59:00 s73v3r: hmm. not sure about easiest, but this looks likely to work: http://stackoverflow.com/questions/7142378/how-can-i-use-ontouchlisteners-on-each-word-in-a-textview/7292485#7292485 Mar 05 00:59:45 g'night folks Mar 05 00:59:47 I'm beat Mar 05 00:59:57 nigt night Mar 05 00:59:58 s73v3r: basically, the problem is that spannables don't have pressed states / backgrounds. so you'll have to tell it when to change, and probably make your own Span to simplify things. Mar 05 01:00:02 i honestly thought i wouldnt wear mine a lot and thought it would look dumb and nerdy, but it seriously blends pretty well, and looks like any other watch Mar 05 01:00:33 I still think your wrist is bigger haha Mar 05 01:00:39 DadFoundMy: you'll regret ever having wore it in a few years when they have slimmer cooler ones Mar 05 01:00:45 s73v3r: I found that via http://stackoverflow.com/a/20905824 which might also be useful Mar 05 01:00:57 shmooz: i paid $30, ill just get another if i really wanty Mar 05 01:01:14 I have a custom span. Problem is, I don't know when it becomes unclicked Mar 05 01:01:17 for $30 i'd get one too Mar 05 01:01:28 schmooz ^ exactly Mar 05 01:01:34 I'd get one too, but I wouldn't trust to put it on me ;) Mar 05 01:01:39 I’d def get one for $30 Mar 05 01:01:43 not $300 though Mar 05 01:01:51 shmooz: reword that please haha Mar 05 01:01:55 either plastic will poison me, or it will explode and blow off my arm Mar 05 01:01:56 I wouldnt keep the batt charged Mar 05 01:01:56 shmooz: afraid of the wrist cancer? Mar 05 01:02:09 i dont think i would spend any more than $150 for any watch Mar 05 01:02:19 even then its pushing it Mar 05 01:02:26 check out the citizen stilletto Mar 05 01:02:30 and say that again Mar 05 01:02:30 excpsecially first gen Mar 05 01:02:41 that already sounds to me like "why would you even $150". I don't get that much use out of a watch. Mar 05 01:02:45 (i like it, just giving you shit0 Mar 05 01:03:11 i cant see any uses in watches to be honest Mar 05 01:03:14 I'll let the guineapigs continue their experiments for a little more Mar 05 01:03:22 but thats just me i guess Mar 05 01:03:30 danijoo_: people dont wear watches for function, they wear it for looks Mar 05 01:03:36 yeah. Mar 05 01:03:54 i can see why people would spend 1000+ on a watch, i just never would Mar 05 01:03:58 I think this is about my limit for watch thickness: http://itechfuture.com/wp-content/uploads/2014/11/sonyeink.jpg Mar 05 01:04:12 I think im just too yound for wearing a watch because of style. have to hit the 30s first :p Mar 05 01:04:14 groxx: meh too thick Mar 05 01:04:25 danijoo_: im 16 and wear it haha Mar 05 01:04:26 DadFoundMy: yeah, but you'd get used to it Mar 05 01:04:47 DadFoundMy, exceptions for every rule. Im just not that type of guy that would fit to one Mar 05 01:04:52 I'm trying to implement http://www.reamaze.com/api in Google Script, as I'm trying to have it update the number of "conversations" from the API periodically, and email users when the amount of conversations has surpassed a certain amount. Anyone mind taking a look/helping? Thanks! Mar 05 01:04:57 its the style for a lot of kids to wear those huge casio watches so it isnt too far out of place Mar 05 01:05:28 I can’t wait until smartwatches are this thin: http://images.newiceberg.ru/images/chasy/more/52d8764200432.jpg Mar 05 01:05:35 even mechanical watches are hard to get that thin Mar 05 01:05:40 I think this is the thinnest Mar 05 01:05:55 DadFoundMy: every time I see things like that I just think of this http://www.starpulse.com/Music/Flavor_Flav/gallery/Flavor-Flav-cc04/ Mar 05 01:06:02 JustBerry, what is google script? Mar 05 01:06:07 tricknology_: agreed, i dont need them to be supperrr thin, but i just want them to look like a normal watch Mar 05 01:06:10 lol Mar 05 01:06:21 i get you Mar 05 01:06:26 danijoo_: http://www.google.com/script/start/ Mar 05 01:06:30 groxx: i want a pocket smart watch.... wait Mar 05 01:06:36 why is there a KFC ad in that link with flava-flav? Mar 05 01:06:38 #racist Mar 05 01:06:40 DadFoundMy: lol Mar 05 01:06:46 JustBerry, wrong channel then Mar 05 01:06:56 danijoo_: Where should I go then Mar 05 01:07:16 no idea but this is mostly java/android Mar 05 01:07:24 half the reason i like the watch is the ammount of conversations it starts/ the number of #'s it has gotten em :D Mar 05 01:07:41 DadFoundMy: so, also google glass? Mar 05 01:07:41 im idling 4/7 in here and didnt even now that something like google script existed ^^ Mar 05 01:07:53 danijoo_: google apps script is java... Mar 05 01:08:04 ok then just.. my bad ^^ Mar 05 01:08:20 although it says its js, not java ;) Mar 05 01:08:21 a few days ago i was talking to a girl and she noticed the watch. I told her it recieves texts and she watned to try it so i gave her my number and she sent one. then she pulled the whole "make sure you save the number" routine... lg g watch == best wingman Mar 05 01:08:42 DadFoundMy, haha. well played Mar 05 01:08:42 groxx: meh google watch just loopks sooo out of place Mar 05 01:08:47 danijoo_ It still interhits a number of things from java tho Mar 05 01:09:15 JustBerry, so what? java also inherits stuff from c++, would you call it being c++? Mar 05 01:09:56 if I could make a watch I would use 3D screen to really make it look analog Mar 05 01:10:08 haha DadFoundMy, that’s pretty smoth Mar 05 01:10:13 can you run tinder on that thing too? Mar 05 01:10:14 shmooz: they exist Mar 05 01:10:17 swipe left, swipe right Mar 05 01:10:19 JustBerry, maybe you find someone in here using g script, but the chance is low Mar 05 01:10:23 danijoo_: That's not the point. I just came to see if any Google (Android) developers would know Google Apps Script. Is it really that hard to understand. What's the issue? Mar 05 01:10:35 tricknology_: probably, but tinder for high schoolers is for the reallllly desperate people Mar 05 01:10:37 i guess there are even more scala and kotlin devs than gscript devs in here Mar 05 01:10:40 danijoo_: Any place I could go then - been searching around multiple channels for quite some time now Mar 05 01:10:46 DadFoundMy: that wouldn't stop me ;), I just need investments Mar 05 01:11:28 I must be retarded not to have thought of using the watch to get numbers. Weekend plans sorted... Mar 05 01:11:45 JustBerry, i dont know about an irc channel. Maybe this is the right one but I dont think you find answers for such niche topics Mar 05 01:11:49 good luck though Mar 05 01:12:02 danijoo_: Yeah, thanks anyway. Any other place I could go (non-IRC) Mar 05 01:12:12 danijoo_: I'm really looking for ideas Mar 05 01:12:25 JustBerry, hm.. Mar 05 01:12:27 MXfive: i have a thoery that my watch gets me all the grillz. It's probably just a coencince but i met my girlfriend the day i got my watch Mar 05 01:12:28 DadFoundMy I guess you’re right.. but out here in LA.. it’s legit Mar 05 01:12:31 danijoo_: Where could I find/ask people who know GS Mar 05 01:12:31 maybe they have a mailing list Mar 05 01:12:39 danijoo_: Who Mar 05 01:12:49 the g script folks Mar 05 01:13:37 JustBerry, or g+ Mar 05 01:13:38 https://plus.google.com/communities/102471985047225101769 Mar 05 01:14:32 DadFoundMy I will report back with my findings Mar 05 01:15:21 danijoo_: Thanks, I'll try that. I appreciate it. Mar 05 01:16:41 where can I find a decent UI designer? Mar 05 01:17:03 frege, literally a designer, or a program? Mar 05 01:17:12 both Mar 05 01:17:13 frege: the internet probably Mar 05 01:17:26 Android/IOS dev and designer Mar 05 01:17:29 that's what I need Mar 05 01:17:50 any freelancer portal Mar 05 01:18:07 frege: well i dont think your supposed to solicit yoruself but im theres probably a single android dev in here some where Mar 05 01:18:15 *im sure Mar 05 01:18:41 frege, you have a million dollar idea that just needs to be coded? :p Mar 05 01:19:06 lol Mar 05 01:19:17 btw for your own safety, dont use the word "iOS" in here ^^' Mar 05 01:19:54 quick someone find the better call saul gif about million dollar diea that was on /r/programmerhumor Mar 05 01:20:01 If you do have a $1dollar idea, then I am 100% a developer. You can even use the iOS word around me... Mar 05 01:20:06 shit Mar 05 01:20:11 $1million Mar 05 01:20:18 I'm going to bed now Mar 05 01:20:26 * DadFoundMy raises pitchfork over the use of iOD Mar 05 01:20:32 * MXfive backs into a corner Mar 05 01:20:57 MXfive, the problem with those guys usually is. They want to ay you 100$ to code, design and deliver their 1mio dollar idea ^^ Mar 05 01:21:53 "there are limitless ammount of idea, execution is the hard park" -Ahbraham Lincoln Mar 05 01:21:59 -Micheal Scott Mar 05 01:22:03 DadFoundMy, https://gfycat.com/SadFondHoneycreeper ? Mar 05 01:22:17 you mean that one? Mar 05 01:22:28 yup thats the one Mar 05 01:23:16 i personally dont think there is such thing as a 1 million dollar app. Sometimes its just luck Mar 05 01:23:25 >Sometimes Mar 05 01:23:31 take flappy bird, and crossy road for example. Mar 05 01:23:40 its filling a niche at the correct time Mar 05 01:23:43 except for games Mar 05 01:23:45 even with the perfect app, there is a large amount of luck involved Mar 05 01:23:50 crossy roadd Mar 05 01:23:57 DadFoundMy, there's a lot to a million-dollar anything. You can have the most revolutionary thing in the world but without execution, nobody will find it Mar 05 01:24:24 my computer science teacher's million dollar idea is litterly the game mastermind Mar 05 01:24:37 FUCKK YEAH SNOWW DAY TOMROROWWWW Mar 05 01:24:58 Apple nor Google have app discovery figured out yet either. Mar 05 01:24:59 DadFoundMy, did you tell him its already invented? Mar 05 01:25:15 danijoo_: yup, he even recruited one of my friends for the iOS version Mar 05 01:25:30 DadFoundMy, LOL Mar 05 01:25:31 and is solociting our AP class to come up with his "algroithms Mar 05 01:25:41 xD Mar 05 01:25:44 the one i came up with in less than 5 minutes is the one he used Mar 05 01:25:50 hes not the smartest man Mar 05 01:26:00 How old is he? Mar 05 01:26:04 30ish? Mar 05 01:26:10 maybe less Mar 05 01:26:32 He sounds pretty desperate and delusional Mar 05 01:26:34 DadFoundMy: I can't wait for Flappy Road Mar 05 01:26:43 gn8 guys. time to sleep! Mar 05 01:26:43 He encourages my buddy to stay up 40 hours straight coding iOS apps, and thinks im wasting my time learning C and python and not spending all my time working on my app Mar 05 01:26:51 danijoo_: cya Mar 05 01:27:21 DadFoundMy, wtf.. What year are you in? Mar 05 01:27:30 Im a junior Mar 05 01:27:52 kindergarden Mar 05 01:27:53 hes a pretty intelgent guy, just knows nothing about programming other than java syntax Mar 05 01:28:00 * MXfive Googles what that is to a Brit Mar 05 01:28:12 he thinks the highest level of computer science is making apps Mar 05 01:28:40 https://i.imgur.com/dG63wZf.png Mar 05 01:28:45 juniors are typically 16-17 Mar 05 01:28:51 luckily most kids in the class see past his bullshit Mar 05 01:28:55 tricknology_: yup 16 Mar 05 01:29:25 c is for cookie Mar 05 01:29:35 next semester he is teaching an android development class. There are no prerequisites at all and is ecouraging people to take it as their first programming class Mar 05 01:29:59 last year he tried to teach our intro to programming class the android sdk without even teaching classes/objects Mar 05 01:30:09 haha wtf Mar 05 01:30:11 tbh Mar 05 01:30:17 thats how I more or less started Mar 05 01:30:21 tricknology_: it didnt go well at all Mar 05 01:30:21 fiddled with Ruby a little Mar 05 01:30:33 then went and made an Android prototype app Mar 05 01:30:35 Same here.. i mean I taught myself Android for the most part Mar 05 01:30:37 didn’t knwo Java Mar 05 01:30:38 what about html Mar 05 01:30:42 only had taken PASCAL Mar 05 01:30:46 is that a bad place to start Mar 05 01:30:50 little HTML when I was in 5th grade.. Mar 05 01:30:55 didn't know what an object was until I was 2 solid weeks in and almost finished Mar 05 01:30:55 tricknology_: Turbo PASCAL? Mar 05 01:31:01 yeah but here I am.. (still asking noob questions) Mar 05 01:31:03 i mean you dont need to know java but i think you should atleast have an understanding for classes and such Mar 05 01:31:05 yeah haha Mar 05 01:31:10 +1 Mar 05 01:31:18 I had zero OOP experience Mar 05 01:31:20 he didnt even try to teach classes as he went he just kind of told us what to do and didnt teach it Mar 05 01:31:31 he still does that with some stuff Mar 05 01:31:37 That's not good Mar 05 01:31:47 most kids in our AP level class dont know the differenc between an instance variable or a method Mar 05 01:31:57 kek Mar 05 01:32:08 everyone who understands that stuff has learned it on their own/ has their own projects Mar 05 01:32:44 one kid who doesnt understand that stuff made a chess game without a single class or method. everything is in the main method (except for his swing classes) Mar 05 01:32:57 he's a smart teacher Mar 05 01:32:57 oh god Mar 05 01:33:10 he is currently at 2000 lines of code without even being close to have it working Mar 05 01:33:10 this isnt college level thank god Mar 05 01:33:19 tricknology_: AP is college level :D Mar 05 01:33:42 I would be like the teacher from that movie whiplash and throw chairs at you guys Mar 05 01:34:44 yeah but.. are you going to a college and takign the course or is it a Highschool teacher teaching you college level material? Mar 05 01:35:44 tricknology_: the latter, he didnt even take any comp sci courses in college btw Mar 05 01:36:01 at the end of the year you take a test and can test out of the college courses Mar 05 01:36:02 DadFoundMy: Kind of lol Mar 05 01:36:24 DadFoundMy: Difference between instance variable or method? LOOOOL Mar 05 01:36:41 yeah I know how AP works.. Mar 05 01:36:48 but that’s a damn disservice he’s doing Mar 05 01:36:57 tricknology_: :D didnt know if you were eu Mar 05 01:37:09 because you’ll start at the 102 level where everything is expected Mar 05 01:37:19 nah USA! USA! USA! Mar 05 01:37:20 JustBerry: yup, for example arrayList.size() or array.length Mar 05 01:37:41 DadFoundMy: loooool Mar 05 01:37:50 bad teachers need to eat too, DadFoundMy you should just learn this stuff yourself Mar 05 01:38:08 shmooz: oh i obviously have, but a ton of the kids in the class havent Mar 05 01:38:13 we don't need no stinkin teachers Mar 05 01:38:32 ok im outie 500 Mar 05 01:38:40 i learned more from a single java book then i did from any of his stuff that ive takin for 3 years Mar 05 01:38:43 tricknology_: seeya Mar 05 01:38:45 we don't need no education Mar 05 01:39:00 HEY TEACHER! LEAVE THE KIDS ALONE! Mar 05 01:39:38 lol I’ll be back online in an hour.. from home haha Mar 05 01:39:43 (nolifeontheweekdays) Mar 05 01:40:20 trick your not supposed to text and drive. Thers nothing about irc'ing and driving! Mar 05 01:45:48 not sure how on topic this is for here but i have an android project that uses gradle. i am trying to generate usable eclipse project files but the classpath is only generated with JRE_CONTAINER set. anyone hit this issue before? Mar 05 02:12:00 Trick whats up? Mar 05 02:32:12 omfg. is there any arrangement of events that lets you build a sane layout that handles rotation with an orientation listener? I need to catch 180 flips. Mar 05 02:32:25 Tricknology: Are you back at the base? =) Mar 05 02:32:37 I am Mar 05 02:32:45 groxx what do you mean? Mar 05 02:32:52 I had some trouble with orientation myself once Mar 05 02:33:23 you want to reinflate another view? Mar 05 02:33:38 or same layout but in portrait? Mar 05 02:33:52 depending on orientation vs layout listener ordering and, I dunno, moon position, sometimes I get impossible screen rects. it'll go from (p x, p y) to (l x, p x), to (l x, l y) Mar 05 02:34:43 I want to handle it myself, and keep a view at the same relative position, regardless of orientation Mar 05 02:35:50 but if I use e.g. a percent of window height, I get intermittent insane values, or orientation changes that don't change the window dimensions until much later Mar 05 02:37:01 are layout listeners just not reliable maybe? would I have better luck doing all this inside a custom view so I can at least run inside the layout pass? Mar 05 02:38:32 I've learned some terrifying details about view tree observers in the course of all this, since apparently untimely window changes (like for hardware acceleration) will orphan observers without any way to unregister Mar 05 02:40:40 groxx they only had about 7 years to get it right ... Mar 05 02:42:43 is gradle integrated into eclipse? Mar 05 02:44:03 I've gotta spend like a day or two logging all this stuff ;_; already wasted days trying to build something reliable, finding bugs, patching, etc. hopefully something sane is possible. Mar 05 02:51:28 DadFoundMy: i don't think gradle does incremental compiles yet Mar 05 02:54:05 bankai_ http://digg.com/video/sheldon-and-dolly-playing-chase Mar 05 02:54:24 hahaha awww Mar 05 02:55:14 i think that ones destined to become a TMNT **** ENDING LOGGING AT Thu Mar 05 02:59:59 2015