**** BEGIN LOGGING AT Tue Mar 10 02:59:58 2015 Mar 10 03:00:26 pfn: https://github.com/MarioAriasC/funKTionale Mar 10 03:00:42 Nowhere near as extensive obviously given Kotlin's lack of support for HKT but a good start Mar 10 03:05:15 CedricBeust i think kotlin M11 was due this week ? Mar 10 03:08:02 what i wonder is whether google would move away from java entirely - how jack & jill could be the first pieces required in that transition, etc Mar 10 03:08:34 pfn: ic, thank you Mar 10 03:13:45 http://www.fiercedeveloper.com/story/localytics-high-end-android-phones-offer-40-better-app-engagement-iphone-6/2015-03-09 Mar 10 03:15:08 g00s: Dumb question, but what’s meant by “app launch”? Mar 10 03:15:27 g00s: There's probably 0% chance of that, give or take 0.0% Mar 10 03:15:31 g00s, not really possible unless google is willing to completely ditch the old ecosystem Mar 10 03:15:33 yeah probably need to see the paper - not sure if its "# unique apps launced" or what Mar 10 03:15:44 ie break backward compatibility for all of Android Mar 10 03:16:18 basically, when google says they're shutting android down Mar 10 03:17:42 g00s: How do you count multiple launches of the same application, esp if the application is still resident in memory? Mar 10 03:18:15 The paper doesn’t seem to provide much guidance as to what counts as a launch. Mar 10 03:18:55 ok report is http://info.localytics.com/blog/top_of_the_line_android_phones_show_40_percent_higher_engagement_than_iphones Mar 10 03:20:51 "Localytics examined the average app launches for different devices. ", hmm - still not clear oh well Mar 10 03:22:01 Hello. I have ScrollView in my navigation drawer and each time I toggle or open the drawer, the ScrollView jumps to its bottom. What is the reason and how to prevent it? SO and google search were fruitless. Mar 10 03:22:38 creitve: cant you post at least the layout xml? Mar 10 03:22:44 Disappointing when reports like this aren’t transparent with their methodology. Mar 10 03:22:49 a moment Mar 10 03:22:58 jfpoole: they will never be. Mar 10 03:23:41 im soo close to finishing my first app. so many tiny little things to polish up :/ Mar 10 03:23:55 abara: I’ve seen some that are pretty reasonable. Mar 10 03:24:54 jfpoole: if you want to see this way it will be. nothing on this world happens without a reason. Mar 10 03:25:40 jfpoole: the fact is Apple is just went full retarded on every Update. Mar 10 03:25:51 ? Mar 10 03:26:15 jfpoole: this kinda explain the possible reason about the article. Mar 10 03:27:05 abara: http://pastebin.com/mT8rtcr7 Mar 10 03:27:08 jfpoole: Plenty of things in this world happen without a reason :) Mar 10 03:32:35 creitve: dude, what android:overScrollMode="never" do? Mar 10 03:33:24 abara: idk, but I've added it just now and already removed it. It was a mistake, it doesn't affect the problem Mar 10 03:33:43 oh Mar 10 03:33:56 ah Mar 10 03:34:09 sorry, no, it wasn't that Mar 10 03:34:30 apparently, it disables the animation of overscrolling Mar 10 03:35:09 That rubber-like feedback at the beginning and at the end of the list Mar 10 03:36:23 It also isn't the cause. The problem is when the drawer is opened, the scrollview scrolls to the bottom by itself (jumps), but if you scroll it there and close the drawer, it reamains scrolled, when you reopen it Mar 10 03:36:39 Thank you for looking into this Mar 10 03:39:44 creitve: .-. Mar 10 03:39:50 creitve: problem solved? Mar 10 03:41:23 abara: no, I was clarifying. Mar 10 03:41:28 it still stands Mar 10 03:42:12 by "it wasn't that" I meant it wasn't that thing that I've added and removed by mistake Mar 10 03:42:24 creitve: mate, i think you already have found this answer, but afaik you need to scroll to top on the "oncreate" method. Mar 10 03:42:37 groxx! it works! the fragments backstack thing! ty Mar 10 03:43:10 tksko: glad to hear it :) Mar 10 03:43:43 abara: This didn't have to be found, it is an option, but it is a dirty-ish hack. I don't want it twitch up and down on different platforms. I want to find the reason. Mar 10 03:43:50 i dont need to maintain the stack anymore :D Mar 10 03:44:05 the only problem i had was on the onCreateVieew of the fragment..... Mar 10 03:44:22 when the fragment is resumed.. i need to remove the view first from the parent Mar 10 03:46:04 creitve: i understand. just to clarify. what you want is to open the drawer and not have the scrollviews scrolled to bottom Mar 10 03:46:05 ? Mar 10 03:46:17 Yes. Mar 10 03:46:44 It jumps there by itself, if it isn't at that position already. Mar 10 03:47:26 creitve: if i'm not asking too much, can you post the Fragment code and upload a screenshot of the drawe on it's openned? Mar 10 03:48:22 is it possible to recover or to know the current displayed fragment? from the manager? Mar 10 03:49:43 abara: I'm afraid stripping it of confidential info would take too much time :-) Sorry about that and thanks again, I will try to find something else for now. Mar 10 03:50:12 tksko: yes. you can set a TAG name when adding the fragment, and save this tag over a class attribute. then getByTag Mar 10 03:50:18 something like that Mar 10 03:50:28 http://stackoverflow.com/questions/9294603/get-currently-displayed-fragment Mar 10 03:50:46 i was reading that post actually Mar 10 03:51:53 so rxjava is kinda awesome Mar 10 03:51:59 simplifies so many things Mar 10 03:52:16 * CedricBeust nods Mar 10 03:52:30 creitve: I see :/ really sorry about the not helping at all. but as the final tip. check if the drawer is really calling "oncreateview" because if not so the scrollview is not being purged so it can hold the position. i'm asking that because i'm not using drawe for now, so i dont know much about it Mar 10 03:54:48 abara: Solved it! It appears that something, likely inside nested listview was catching focus, and the scrollview was scrolling to it as a descendant. I added android:descendantFocusability="blocksDescendants" to the scrollview's parent and it is fixed. I might remove the focus later if I find it. Mar 10 03:55:00 CedricBeust: so how did you get op/ who are you?just curious Mar 10 03:56:05 creitve: i see. i didn't talked about that because the xml do not contain any widget which would gain focus on changing views. Mar 10 03:56:27 creitve: i've read about this on some links too. Mar 10 03:56:33 i think the fragments.get(count-1) its enough Mar 10 03:56:40 i just need to check when count is 0 Mar 10 03:56:54 tksko: great :) Mar 10 03:59:53 holy shit Mar 10 04:00:03 why is it called metal music? because metal is harder than rock Mar 10 04:00:09 * desmin88 just died from this realization. Mar 10 04:00:36 Jeepers Creepers Mar 10 04:00:44 desmin88: Bribed a few people Mar 10 04:00:53 CedricBeust, i figured as much. Mar 10 04:03:39 diamond rock doesn't have that sound Mar 10 04:03:42 desmin88: Is it though? Mar 10 04:04:05 >.> Mar 10 04:10:37 Should I use SugarORM, ORMLite, GreenDAO, something else or standard Android SQLite helper methods? Mar 10 04:11:15 I am using Retrofit so it would be nice to use a ORM Mar 10 04:11:29 There's SQLBrite too (more recent, not sure how battle tested it is) Mar 10 04:12:34 i went with a simple sqlitedatabaseopenhelper class for jsut a simple keyvalue store that needs to be scalable more than sharedprefs Mar 10 04:12:48 CedricBeust: I will look at that too, any others I should investigate? I would really prefer something that is JPA compatible or can use JPA POJOs to generate what ever efficient non-annotation object the library uses Mar 10 04:13:08 sqlbrite has no orm components Mar 10 04:13:15 ok Mar 10 04:13:32 JPA like? Now that's ambitious Mar 10 04:14:02 :) Mar 10 04:14:33 Only because I use it on the server end, it would be nice to share a library of POJOs and Retrofit services ;) Mar 10 04:14:46 Yeah you don't need to sell me on the goodness of JPA :) Mar 10 04:15:14 i find it hard to believe you would want the exact same data in the exact same schema on the mobile app as on the backend Mar 10 04:15:23 Yeah my thought too Mar 10 04:15:48 Never really felt the need for an ORM on Android. Helpers, yes (especially Rx helpers) Mar 10 04:15:56 Obviously using JPA on an Android would be slow (unless a library used JNI components) but something that can convert JPA objects to something more efficient to run under Android would be nice Mar 10 04:16:26 JakeWharton: Not exactly the same, but there are commonalities to warrant it Mar 10 04:16:27 Annotation processors could take away the need for reflection, I'm not worried about that, more about the scope of JPA Mar 10 04:17:14 sleep time Mar 10 04:17:16 nn Mar 10 04:17:21 see ya Mar 10 04:17:23 <3 Mar 10 04:18:33 Should the gradle-retrolambda build script go in your app build.gradle or your project build.gradle? Mar 10 04:19:11 err module vs project Mar 10 04:23:41 desmin88 you can look at mvstore for native java k/v store. might be overkill Mar 10 04:23:54 http://www.h2database.com/html/mvstore.html Mar 10 04:23:59 i actually was looking at that Mar 10 04:27:03 Trying to learn rxjava + android, i'm wanting to utilize it in an adapter to heavily process some text on a new thread then set it on the ui thread - http://pastie.org/10013793 Mar 10 04:27:11 how can i account for things like the view not existing anymore? Mar 10 04:27:25 rxjava? Mar 10 04:28:19 desmin88 is fromHtml that expensive ? Mar 10 04:28:38 might be premature un-optimization :) Mar 10 04:28:54 this is more a testing example but it can be Mar 10 04:29:36 well, subscribe() returns a subscription. you can create a CompositeSubscription to add all your subs too. then in onStop unsubscribe the comp sub Mar 10 04:31:06 cool, thanks Mar 10 04:32:46 desmin88: LifecycleObservable and AppObservable can help by handling some configuration changes and all, but you need to unsubscribe manually Mar 10 04:33:22 i'm waiting to for jake to bless that stuff before i use it :) Mar 10 04:33:33 so far, it seems kinda weird Mar 10 04:33:52 It is a bit weird, I'm cautious in how I introduce it in our code base Mar 10 04:34:29 compositesubscription i think is the way to go, it will help with my callbacks from before orientation changes adding data to the new view Mar 10 04:35:13 I'd refresh then rotate only to have two sets of the same data be popped up Mar 10 04:39:14 It's cool android studio, I'll wait while you do a bunch of shit before building Mar 10 04:39:40 what is it doing? Mar 10 04:39:49 fafnir: Yeah my builds have become much slower then they used to be on Eclipse too :( Mar 10 04:40:30 Are you both using gradle daemon/parallel? Mar 10 04:40:37 might help a bit Mar 10 04:40:51 It's just the first build after launch reall Mar 10 04:42:18 Yeah, eclipse was cool, build something quickly to test over and over Mar 10 04:43:26 i miss that from eclipse. keep doing builds and finding compiler errors - stuff i would have fixed in eclipse from the error markers Mar 10 04:43:50 i do need to figure out how to have it report all things and not stop at the first Mar 10 04:43:51 Yeah it's mystifying to me that AS doesn't have a Problems view Mar 10 04:44:02 which results in many many compiler / build cycles and waste of time Mar 10 04:44:43 Yup, can't believe it's 2015 and I press a "Build" key 100 times a day Mar 10 04:44:48 hadn't done that with Eclipse in a decade Mar 10 04:45:00 it sucks when you dont get any errors until you actually open up the class file Mar 10 04:45:02 or what have you Mar 10 04:45:25 sometimes i open up the class file and there are error markers without there being errors :| Mar 10 04:45:30 i mean java file Mar 10 04:45:40 yup Mar 10 04:46:03 IDEA is so good in so many areas, it's mystifying they never brought that part up to Eclipse's level Mar 10 04:48:37 @g00s, that annoys me Mar 10 04:48:45 Why are those error markers all over Mar 10 04:48:47 what the hell aS Mar 10 04:48:57 Its to my understanding that if you unsubscribe a compositesubscription, it cant be used again? Mar 10 04:49:05 correct Mar 10 04:49:10 it goes to a terminal state Mar 10 04:52:02 ugh, fragment lifecycle. Mar 10 04:53:13 whats the appropriate callback if i want to unsubscribe all on rotation - onstop, then recreate it in oncreateview? Mar 10 04:53:44 i typicllally do onStop Mar 10 04:57:37 danke Mar 10 05:00:54 I miss how easy it was to find the simple syntac errors in eclipes, i just spent way to long looking for a missing semicolon Mar 10 05:01:46 anyone use android sdk cli only? not usign android studio or eclipse Mar 10 05:02:54 hot damn rxjava is just eliminating so much code for retrofit Mar 10 05:03:34 akar: You're asking for pain Mar 10 05:03:39 akar: Yup. Mar 10 05:03:55 i think thats against the geneva conventions Mar 10 05:04:09 Pfft. Mar 10 05:04:12 CLI is l33t. Mar 10 05:04:25 vim all the way! Mar 10 05:04:32 i hate vim elitists Mar 10 05:04:36 hmmm.. so better use android studio or eclipse.. Mar 10 05:04:43 just android studio Mar 10 05:04:52 Meh, I can use VIM but I wouldn't want to live in it Mar 10 05:04:57 Studio is (sadly) the standard. For now. Mar 10 05:05:04 ^ yup Mar 10 05:05:17 just curious about gradle wrapper, every time "android create project" i never see my gradle wrapper Mar 10 05:05:39 CedricBeust: what do you mean for now? Mar 10 05:06:14 desmin88: Maybe Google will change their mind again and go back to Eclipse. They already did it once after all :) Mar 10 05:06:38 but this time google is partnered with jetbrains Mar 10 05:06:56 is there a way to get total line count in android studio? I'm curious to see how many lines of code I've written Mar 10 05:06:57 they work on android studio/intellij together iirc Mar 10 05:07:01 CedricBeust: why go back to eclipse? Mar 10 05:07:07 or can I get line count from GitHub? Mar 10 05:07:08 Nothing stopping them from working on both IDE's Mar 10 05:07:25 thats true but would they want to split the developers or unify?> Mar 10 05:07:52 Supporting two IDE's would be more unifying than supporting just one and abandoning the other Mar 10 05:08:02 hmm Mar 10 05:08:17 i wouldnt call it abandonment Mar 10 05:08:31 theyve been pushing android studio for over a year now and are slowly phasing out adt Mar 10 05:08:58 but i see what you mean Mar 10 05:09:00 a team from eclipse is picking up adt and going forward Mar 10 05:09:09 I wouldn't say they are slowly phasing out Eclipse, they just flat out stopped supporting it overnight Mar 10 05:09:24 as google often does Mar 10 05:09:33 spring cleaning Mar 10 05:09:36 :D Mar 10 05:09:42 Sometimes it's justified, I'm not convinced this was the case here though Mar 10 05:11:11 i think they wanted a shiny new dedicated IDE to promote Mar 10 05:11:14 how is the kotlin story for eclipse ? Mar 10 05:11:45 seems to exist https://github.com/JetBrains/kotlin-eclipse Mar 10 05:12:46 not sure how official it is Mar 10 05:13:19 Commits from a few days ago Mar 10 05:15:36 hey guys! is there anyway to use pagertabstrip outside viewPager? Mar 10 05:16:13 just regular action bar tabs? Mar 10 05:17:19 yep Mar 10 05:17:32 so just add a tab to actionbar Mar 10 05:18:26 hum. ok then Mar 10 05:19:19 hey guys im getting "W/GooglePlayServicesUtil( 2292): Google Play services is missing." in my logcat when i try to run app Mar 10 05:19:38 i have imported them properly into source so it is compiling Mar 10 05:19:45 any ideas? Mar 10 05:20:27 ginseng: already tried search SO? Mar 10 05:20:30 on* Mar 10 05:20:54 ginseng: can you open google play on that device? Mar 10 05:21:10 abara: Literally all you need to do is actionbar.addtab Mar 10 05:21:47 google play is just a set of relevant libraries, right? Mar 10 05:21:55 or can i open it directly in emulator? Mar 10 05:22:30 akar, I used to, and still do Mar 10 05:23:11 pfn: you dont use android studio nor eclipse? Mar 10 05:24:31 desmin88: i'm using toolbar. so not Tab class for now! Thanks for answer anyway :] Mar 10 05:25:41 abara: you could setActionBar(toolbar) then use it in that way Mar 10 05:26:33 g00s: CompositeSubscription + rxjava simplified everything. Before I would callbacks returning from retrofit from before a list refresh, orientation change, or sorting change Mar 10 05:26:46 Now I just unsubscribe all and recreate whenever I switch those Mar 10 05:27:34 desmin88, can develop with or without ide, don't particularly care, and I use neither of those Mar 10 05:27:55 interesting Mar 10 05:28:01 when you do use an ide which do you use? Mar 10 05:29:34 ide editors drive me nuts Mar 10 05:30:14 i edit outside the ide and use the ide for build-run-debug and sometimes code problem detection if it's not obvious what i did wrong Mar 10 05:30:42 Use the IDE to edit, it's much more suited to edit code than a text editor Mar 10 05:30:53 desmin88, intellij Mar 10 05:31:00 ah Mar 10 05:34:28 ideavim Mar 10 05:36:35 makes using an ide bearable Mar 10 05:36:37 nah, learn your IDE Mar 10 05:37:04 bah, this stupid issue follows me everywhere. I'm getting data added to my list set when it shouldnt be Mar 10 05:37:07 to nobody's surprise i'm sure, i spend most of my time looking at my code :| Mar 10 05:37:15 contemplating, thinking Mar 10 05:37:34 To abstract, or not to abstract? Mar 10 05:37:38 haven't needed to sort a square rectangle of text in a while :) Mar 10 05:37:51 (that is the question) Mar 10 05:38:37 JesusFreke heh, i hate those "i'm almost doing the same thing twice, i should abstract this ... but its different enough to be weird / painful" Mar 10 05:39:22 g00s: welcome to programming Mar 10 05:39:31 :) Mar 10 05:39:36 CedricBeust: i use emacs Mar 10 05:39:49 java mode is plenty fine Mar 10 05:40:19 kjeldahl also uses emacs. Leeds uses vim Mar 10 05:40:49 I'm calling unsubscribe on my compositesubscriptin, yet i'm still receiving data from them after, hmm. Mar 10 05:40:52 once i have a lot of files, dirs i become completely unproductive navigating that in emacs / vim Mar 10 05:41:03 emacs is an ide, longer ago than i care to admit i was taught how to run gdb in a shell inside emacs, and breakpoints/crashes would jump back to the line in the source code in the other frame Mar 10 05:41:44 myke google should have just built ChromeOS on emacs Mar 10 05:41:46 g00s: i actually spent the last few weeks hacking around with fzf and various bits of elisp code to make that suck less Mar 10 05:42:02 i have a pretty decent workflow even with android's deep project trees Mar 10 05:42:55 and if i ever want code completion there always CEDET Mar 10 05:43:43 also eclipse crashes less than infrequently when i make heavy use of its edit panes Mar 10 05:45:18 the ide's have an understanding of the project which i find helpful, for example autoecomplete for theme attributes Mar 10 05:45:38 g00s: not a vim user but i talk to a bunch in another channel, vim also has lots of solutions for project navigation Mar 10 05:46:02 a friend from uni suggested http://batsov.com/projectile/ for emacs Mar 10 05:46:07 i wasn't kidding about emacs being an ide Mar 10 05:46:25 emacs was the original ide Mar 10 05:54:38 ide? more like: os Mar 10 05:56:27 g00s: I have an issue with compositesubscription. Say I do mCompositeSubscription.add(...) in a scroll listener. After I clear/unsubscribe that composite subscription on a refresh to prevent any callbacks from before the refresh, it just gets added back to composite subscription and i get the callback anyway Mar 10 05:57:34 Basically, my app lets you switch from two data sets which just resets the adapter/scroll listener. But I keep getting callbacks from the old adapter, ive bene on this problem for so long now and cant figure it out. Mar 10 05:57:58 not sure, you'll have to think through the events. CS works, there must be something wrong with the timing Mar 10 05:58:12 hey guys which is better genymotion or standard emulator Mar 10 05:58:23 ginseng: a device Mar 10 05:58:28 lol Mar 10 05:58:37 <-- iphone user Mar 10 05:58:42 g00s: I've stepped through the debugger and the callback is somehow adding posts still. Mar 10 05:58:44 ginseng: get a device Mar 10 05:59:11 ginseng a good one is a nexus, or cheaper maybe moto E 2nd gen Mar 10 05:59:26 desmin88 did you use to do bukkit dev? Mar 10 05:59:31 yes. Mar 10 05:59:59 desmin88 also, your Observable should check to see if its subscribed before onNexting stuff Mar 10 06:00:11 hmm Mar 10 06:00:13 i'm sure its pebkac :) Mar 10 06:00:25 learning curve is steep, take your time Mar 10 06:00:31 hehe Mar 10 06:04:53 looking at the docs there doesnt appear to be some sort of operator i can use Mar 10 06:06:58 yeah, thats one thing i like SublimeText for ... browsing code Mar 10 06:07:13 desmin88 open up an ST window on the rxjava sources and read over them Mar 10 06:07:15 a lot Mar 10 06:07:33 * g00s loves that little preview strip Mar 10 06:07:48 yeah, it's neat, but I don't actually use it much Mar 10 06:07:52 * desmin88 will attempt to fix this and report back Mar 10 06:07:55 (the preview strip) Mar 10 06:12:28 welp Mar 10 06:14:44 g00s: ? Mar 10 06:14:54 thepoosh don't get in trouble now Mar 10 06:14:55 Hey guys.. What's a good free resource for learning android apps like the xml options and the android specific libiraries Mar 10 06:15:02 working from home Mar 10 06:15:30 gotta get weechat working in an AS console Mar 10 06:15:33 g00s: we got mentioned in the techcruch presentation of the apple watch Mar 10 06:15:34 :D Mar 10 06:15:40 lol Mar 10 06:15:49 then it will look like a log Mar 10 06:15:49 thepoosh link ? Mar 10 06:16:00 sec Mar 10 06:17:07 http://techcrunch.com/2015/03/09/what-your-favorite-apps-look-like-on-apple-watch-plus-new-ones/ Mar 10 06:20:54 thepoosh ah nice, do you guys have an android wearable part ? Mar 10 06:21:07 g00s: what other possible reason do you think it could be? theres no way it cant be from the other observable from before the refresh of items Mar 10 06:21:18 android has playing full videos from watch Mar 10 06:24:46 I'm hesitant to post code because i hate being spoonfed but if anyone thinks they can identify my problem, please do so: http://pastie.org/10015521 (code terrible because its been through so many fix attempt iterations) Mar 10 06:25:21 desmin88 there has to be a patron saint for android ailments Mar 10 06:25:41 actually Mar 10 06:25:50 funny you brought it up - isodor of seville Mar 10 06:26:09 not specifically android but computers/programmers none the less Mar 10 06:26:16 maybe remove the clear Mar 10 06:27:20 "AndroidObservable.bindFragment" yeah, i dont know how those work Mar 10 06:27:50 swing and a miss, i get the new data when i switch plus the next page of data that would be loaded in the previous set to be shown Mar 10 06:27:56 man AS seems to really struggle with imports on static inner classes Mar 10 06:28:24 phix: fwiw I'm reasonably happy with greendao. it's a bit weird, but reasonably understandable and performant. just watch out for the not-thread-safe caches - turn them off entirely, or be crazy careful. Mar 10 06:32:25 g00s: I removed clear and the androidobservable, but still no cigar. Mar 10 06:32:37 desmin88 i don't know, sorry :* Mar 10 06:32:45 knee deep in my own crap Mar 10 06:34:01 do you think its because in my onscrolllistener i have a reference to mCompositeSubscription, which although i unsubscribed previously it just adds itself again to it? Mar 10 06:35:59 yep. Mar 10 06:36:00 son of a bitch Mar 10 06:39:10 groxx: ok cheers, I have decided to start with ORMLite and see where to go from there. Mar 10 06:40:35 phix: let me know what you think! I haven't tried that one yet. Mar 10 06:46:08 so far so good Mar 10 06:46:45 g00s: also got picked up by CNBC Mar 10 06:47:22 \o/ Mar 10 06:49:08 whats the party here ? Mar 10 06:57:44 g00s: So there was no good solution, I just set a field in my old adapter on refresh that tells the scroll listener to not update anymore. Mar 10 06:58:32 could it just check if the subscription is not subscribed ? Mar 10 07:00:09 How would I check that? Mar 10 07:01:38 if (subscription.isSubscribed()) Mar 10 07:04:53 How do I know the working directory for an AsyncTask running in an activity? Mar 10 07:05:01 g00s: the composite subscription? Mar 10 07:05:04 Specifically trying to figure out where to place game.zip when running this: https://github.com/alanwoolley/CorsixTH-Android/blob/master/src/Java/uk/co/armedpineapple/cth/SDLActivity.java#L523 Mar 10 07:05:34 im out of my depth Mar 10 07:13:50 g00s: i dont want to bother you but i dont see where i would check that or how it would help? Mar 10 07:21:13 if you mean checking if the compositesubscription is unsubscribed before i add to it, that doesn't work because at this point theres a fresh one Mar 10 07:30:45 setting the onscrolllistener to null also worked Mar 10 07:44:15 Regarding my use of emacs for Android development, the following is a bit old but possible still relevant for Android/Emacs newbies. https://github.com/mariusk/android-with-emacs Mar 10 07:44:42 hey folks. notifications in my app open on all other phones but fail to do so on samsung phones. i am on kitkat. any pointers? Mar 10 07:44:59 Hello! Mar 10 07:45:24 hi Mar 10 07:45:37 gdust: it's a known issue actually Mar 10 07:45:47 happens to Facebook and sometimes also to gmail Mar 10 07:45:56 try upping your requestCode Mar 10 07:46:28 i saw a SO answer once saying that there are many reserved requestCodes and that devices might ignore some Mar 10 07:46:32 thepoosh: ok. thanks, this has been eating me for a few days. Mar 10 07:47:36 it happens on facebook as well Mar 10 07:47:40 at least to us Mar 10 07:48:56 Anyone knows how I can use android.R.layout.simple_list_item_1 in customAdapter? Mar 10 07:49:08 Point me to its xml maybe? Mar 10 07:49:22 or how to populate it Mar 10 07:50:27 Found it! http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/4.0.1_r1/frameworks/base/core/res/res/layout/simple_list_item_1.xml/ Mar 10 07:50:34 Long url, sorry Mar 10 07:51:37 thepoosh: it really is weird eh! Mar 10 07:51:46 well, what can you do Mar 10 07:52:42 thepoosh: what do you mean by upping the requestCode? Mar 10 07:56:20 to something over 1024 Mar 10 07:56:25 not sure it will help Mar 10 07:56:28 but worth a try Mar 10 07:56:53 think about it as ports in a system Mar 10 07:57:01 the first 1k is reserved to system Mar 10 08:00:23 Can someone tell me if this [https://dpaste.de/cm0e] is right or not? My app crashes after using that adapter. Traceback: https://dpaste.de/Nr21 Mar 10 08:08:18 thepoosh: ok on it. Mar 10 08:15:25 How do I scroll a listview so that the item is in the top of the list? Mar 10 08:17:10 the item I want to make vissible that is Mar 10 08:19:52 cezium: mListView.scrollToPosition or smoothScrollToPosition Mar 10 08:20:32 thepoosh: this only makes the item vissible (not putting it in the top of the list). Mar 10 08:20:52 you want to move it to a different location in the listview? Mar 10 08:20:57 this is done via the adapter Mar 10 08:21:29 No, I want to scroll the listview so that the item is displayed in the first visible position of the list. Mar 10 08:22:18 so what is the issue? Mar 10 08:22:36 calculate how many items are showing, then scroll to the item + offset Mar 10 08:29:49 The item height is not fixed. Mar 10 08:34:41 cezium: get the height of the item? Mar 10 08:34:59 thats the offset part Mar 10 08:39:41 thepoosh: adding "android:exported=true" to the manifest solved it but i am perplexed as ever. Mar 10 09:19:31 hello everyone Mar 10 09:19:36 Hi DeadRinga Mar 10 09:19:39 DeathCode * Mar 10 09:19:49 hey yes Mar 10 09:20:08 so i was just wondering where i can practice my app making skills. what are the resources for learning it? Mar 10 09:20:19 i only made a very simple calculator so far Mar 10 09:20:22 i'm good with java though :) Mar 10 09:20:32 i use android studio Mar 10 09:21:24 practice them at home Mar 10 09:21:36 yes yes. any website for practice problems? Mar 10 09:21:38 make or copy other apps Mar 10 09:21:46 i'm very proficient in math and java Mar 10 09:21:54 remake whatsapp Mar 10 09:22:02 build in your own custom analytics Mar 10 09:22:04 try to make an openGL es 2.0 (targets at api 10 ) app Mar 10 09:22:06 :P Mar 10 09:22:10 and teach me Mar 10 09:22:13 remake whatsapp in opengles Mar 10 09:22:20 what is opengles? Mar 10 09:22:34 create a 3d model of the data created by user conversations Mar 10 09:22:37 there you go thats talking to the gpu Mar 10 09:22:57 i want to know exactly who says what and where if the words "nsa" or "terrorist" are used Mar 10 09:23:43 opengl is the counter part of directx is probably easyest to explain Mar 10 09:24:32 i can make a whatsapp thing but i will have to learn a lot first Mar 10 09:24:43 do i need to set up a server? Mar 10 09:26:03 DeathCode; yes Mar 10 09:26:13 but if you are proficient in java, it shouldnt be a problem. Mar 10 09:26:17 where can i do that? Mar 10 09:26:22 i dont want to pay for one :P Mar 10 09:26:44 but thats to show your question is really broad what do you want to learn etc formost what is your goal Mar 10 09:27:18 host it urself? Mar 10 09:27:22 er..i dont have any specific app goals is mine Mar 10 09:27:25 in mind* Mar 10 09:27:27 a quick app to try and make a buck ? that will probably not work especialy if you ask basic questions like needing to manage your service you want to provide Mar 10 09:27:27 its 2015 Mar 10 09:27:42 i dont even care about money Mar 10 09:27:43 my other dev machine is a datacenter Mar 10 09:27:46 im not that level yet Mar 10 09:28:00 idk how to use html to write webpages and stuff Mar 10 09:28:09 then don't make it over complex and don't make something that you need to have a active service with Mar 10 09:28:35 ok Mar 10 09:28:40 i guess im beginner Mar 10 09:28:42 but at one point Mar 10 09:28:47 i do want to learn all that tho Mar 10 09:29:22 best place to learn is to dig in to the documentation and some examples Mar 10 09:39:47 ok thanks :) Mar 10 09:42:09 any good ideas on how to do a gradle build inside an aosp build (android-10). Mar 10 09:43:54 Morning All Mar 10 09:44:36 morning Mar 10 09:46:04 What does src_pd stand for in AOSP app sources? Mar 10 10:08:14 hi guys, am i correct that a remoteview can only have one pending intent? Mar 10 10:26:36 asperon, you mean an OnClickPendingIntent? Mar 10 10:27:22 is that possible to ndk-build > some.txt ? it only > 1 line T_T Mar 10 10:27:39 danijoo, yes, i build my remoteview using a couple of remoteviews, but i cant seem to assign different onclickpendingintents to them Mar 10 10:35:23 since when can we instantiate collections implicitly Mar 10 10:35:33 without specifying the object class Mar 10 10:55:39 Does anyone have AOSP Camera2 apk? Mar 10 11:02:35 https://github.com/johncarl81/parceler Mar 10 11:02:41 that's all I have to write to make the class parcelable? Mar 10 11:02:45 really? Mar 10 11:04:54 how to get output of ndk-build to txt file? Mar 10 11:05:15 Odaym, maybe yes if you use that library Mar 10 11:05:21 without, its much more Mar 10 11:06:42 yes I know Mar 10 11:06:58 usually I write them myself with the dest and the in and the whole thing Mar 10 11:07:05 describeContents and whatnot Mar 10 11:07:59 yeah Mar 10 11:08:03 parcels suck :( Mar 10 11:08:24 man look at this https://github.com/JakeWharton/hugo Mar 10 11:08:43 amazingness is coming out of my ears Mar 10 11:08:55 I mean I could've done that but I didn't Mar 10 11:10:04 :D Mar 10 11:11:07 wow Mar 10 11:11:10 that hugo library Mar 10 11:11:50 pro, bro Mar 10 11:12:16 checking this https://github.com/keyboardsurfer/Crouton Mar 10 11:12:25 seems ugly honestly Mar 10 11:12:39 ya Mar 10 11:12:50 that one is pretty underwhelming Mar 10 11:13:58 this https://github.com/chrisjenx/Calligraphy Mar 10 11:14:05 well that one's famous Mar 10 11:14:23 "Custom fonts in Android an OK way." Mar 10 11:14:24 ah Mar 10 11:14:34 whats wrong with setting typeface from assets? Mar 10 11:14:56 usually you have to create a view that extends the Button or the EditText, have a Typeface class, have attributes that say that this custom class element in XML can be typefaced Mar 10 11:14:57 etc.... Mar 10 11:14:59 hell Mar 10 11:15:50 jvrodrigues, the problem with "just setting it" is that you cant just load the asset in every textview Mar 10 11:16:00 because then youll end up with OOM error Mar 10 11:16:44 Hello Mar 10 11:16:53 aloha! Mar 10 11:16:54 How can I compile libsuperuser from command line? Mar 10 11:17:04 Any ideas? Mar 10 11:17:13 for loading a font? are you guys targeting indian android users? Mar 10 11:17:31 just set a global reference to a typeface object and pass it around :s Mar 10 11:17:33 but yea Mar 10 11:17:37 danijoo, aloha Mar 10 11:17:41 i agree that it has some purpose Mar 10 11:17:52 jvrodrigues,well. thats what the library makes easy for you Mar 10 11:18:01 specially in buttons and edittexts, didnt really thought about it Mar 10 11:18:08 loading the fonts and using them. of course you can do it on your own Mar 10 11:18:16 but thats 1000 lines of unneccessary code Mar 10 11:19:01 is there a soft limit to how many alarms you should use? Mar 10 11:19:56 not that i know. Mar 10 11:23:36 what do you guys use for HTTP? Mar 10 11:23:59 I tried OkHTTP with OkIO yesterday, it works of course but I have no idea what to think of it Mar 10 11:24:11 Ion? Mar 10 11:25:17 retro? Mar 10 11:25:47 hey all. i am calling a url and displaying it in a webview. but file dialogs for uploading file won't open. how do i work on it? Mar 10 11:27:00 how can i disable spinner items on certain conditions ? Mar 10 11:27:02 retro html 1.0 Mar 10 11:28:19 i read a comparison between networking libraries some company made, asynctask, ion, okhttp, volley and retrofit Mar 10 11:28:34 turns out retrofit performs faster in all the tests they made Mar 10 11:28:36 s9iper1, just remove them from the adapter and notifydatasetchanged() Mar 10 11:28:59 jvrodrigues, do you have a link? Mar 10 11:29:16 im trying to find it Mar 10 11:29:22 im sure i bookmarked it Mar 10 11:29:24 im wondering why retrofit should be faster than okhttp since it uses okhttp (if present) Mar 10 11:29:32 but i have a few hundred bookmarks to go through Mar 10 11:30:08 haha ok Mar 10 11:30:11 its not that urgent ;) Mar 10 11:30:56 Odaym, If i need to connect to a REST service, im using retrofit. If its just 1 or 2 network calls, im going with plain OkHTTP Mar 10 11:33:34 let me check Mar 10 11:34:20 sup lolli’s :) Mar 10 11:34:40 i am still on 4.0 Mar 10 11:34:47 :( Mar 10 11:34:51 :D Mar 10 11:36:38 I just have to remove the "-w" in the flash-all.sh to disable wiping right? Mar 10 11:36:53 <_Exclusive> AsyncTask, first is doInBackground, and last is the return to PostExecute? But what is the middle one? Mar 10 11:37:18 _Exclusive, Progress Mar 10 11:37:25 <_Exclusive> Ahh, thanks. Mar 10 11:38:08 Guys, how to get dynamically 'Class.this' for dynamic class? Mar 10 11:38:10 not hardcode Mar 10 11:43:18 do you have a reference to "this" ? Mar 10 11:43:41 like an instance of it Mar 10 11:46:24 what if i want to test some of my code, but i don't need to actually run the application Mar 10 11:46:46 Nick-S, unit tests? Mar 10 11:46:51 ya Mar 10 11:47:02 run unit test ^^ Mar 10 11:47:04 well danijoo it's a Microsoft web service Mar 10 11:47:04 can i do it within the same project as the app? Mar 10 11:47:10 .ws extension Mar 10 11:47:23 Nick-S, sure. android supports unit tests Mar 10 11:47:30 reached with a URL that ends with .asmk Mar 10 11:47:31 just add a class? what about structure? its not like maven that i do it under test/ Mar 10 11:47:32 .asmx* Mar 10 11:47:43 Nick-S, its exactly like maven Mar 10 11:48:00 danijoo: where do i create the test class? Mar 10 11:48:21 danijoo: can i do it within the same project? Mar 10 11:48:22 Nick-S /src/test/ for the experimental unit test features Mar 10 11:48:31 or /src/androidTest/ for android test Mar 10 11:48:41 first one only with android studio though Mar 10 11:48:48 danijoo: i don't have src/main like main Mar 10 11:48:56 danijoo: experimental? Mar 10 11:49:07 danijoo: oh.. Mar 10 11:49:12 unfortunately i am in eclipse Mar 10 11:49:25 and i don't want an android test Mar 10 11:49:25 then you can only do androidTests Mar 10 11:49:38 or use a library like robolectric Mar 10 11:49:39 eclipse still has advantages over android studio? Mar 10 11:49:48 jvrodrigues, dont ask! Mar 10 11:49:58 haha "its my boss" Mar 10 11:50:16 i wanna move android studio very much but it is not a right moment to do it Mar 10 11:50:27 its possible that eclipse still has advantages Mar 10 11:50:45 so i will have to run on the device? Mar 10 11:50:57 Nick-S, or robolectric Mar 10 11:51:04 i use android studio because its a lot easier to alt-tab between it and webstorm/phpstorm Mar 10 11:51:28 so i create a test project, and base it on my app? Mar 10 11:51:43 Nick-S, never used robolecric sry :/ Mar 10 11:53:14 I have a listview which can have either a list item or seperator. How should I decide in array adapter's getItemViewType if its a list item or seperator? Whats the standard practice? Mar 10 11:53:22 danijoo: yes, I have Mar 10 11:53:49 woozly, then you can just do yourObject.getClass() Mar 10 11:53:58 danijoo: oh... thank you! Mar 10 11:54:03 ^^' Mar 10 11:54:47 astroduck, you could pass it a List instead of List Mar 10 11:55:14 and if(list.get(position) instanceof String) its one, else its the other view type Mar 10 11:57:37 danijoo: robolectric looks nice what is it used exactly for? Mar 10 11:58:25 running androidTests in the javaVM instead of on the device Mar 10 11:58:44 its like a gigantic mockup library for the android framework Mar 10 12:01:06 I don' understand why generateChecksum is not the default for the maven install plugin. It's a pain in the arse. Mar 10 12:01:08 whats the pitfalls? Mar 10 12:01:42 Nick-S, that you rely on an external library that has half implemented mock methods Mar 10 12:02:07 in most cases it works but it has some points where it behaves different than actual android Mar 10 12:02:48 danijoo: i have to test the behaviour of two services sending intents to each other Mar 10 12:02:56 danijoo: will it work? :) Mar 10 12:03:11 i dont use it and never did Mar 10 12:03:21 i cant tell Mar 10 12:05:30 Oh, I see, it does generate them, but it's the 'isntall' task so they go into ./m2/repository .... they don't go into target/ like I expected. Mar 10 12:11:46 danijoo: i am thinking to bypass the need of the jvm and write plain junit tests Mar 10 12:11:56 danijoo: for some of my code at least Mar 10 12:12:19 Nick-S, I think you mean bypass android, dont you? Mar 10 12:12:28 because java needs a jvm to run :p Mar 10 12:12:29 danijoo: yes Mar 10 12:12:33 haha Mar 10 12:12:34 yaa Mar 10 12:12:40 thats what robolectric does.. Mar 10 12:25:38 Hi, I am saving images on Android in the debug mode. But I can not find the images with MTP at my computer. Mar 10 12:26:05 03-10 13:23:30.687: I/de.tu_darmstadt.fsr.headtracker(2911): trying to save image:/data/data/de.tu_darmstadt.fsr.headtracker/files/out.png Mar 10 12:26:05 03-10 13:23:30.687: I/de.tu_darmstadt.fsr.headtracker(2911): trying to save image-status:true Mar 10 12:26:15 03-10 13:23:52.468: I/de.tu_darmstadt.fsr.headtracker(2911): file-exists?:true Mar 10 12:26:23 *ignore the time-stamp Mar 10 12:26:46 I also tryed the external storage directory, but I never get my files visible. even not on an other computer Mar 10 12:26:53 I run my app in the debuggin mode Mar 10 12:27:39 tu darmstadt.. Mar 10 12:27:42 thats my university Mar 10 12:27:45 lol Mar 10 12:28:02 :) we can have a coffee if you like! Mar 10 12:28:25 im at the lichtwiese (chemistry student) Mar 10 12:28:32 danijoo: basically i could put my tests anywhere? no? Mar 10 12:28:35 you are computer science? Mar 10 12:28:40 I am at Lichtwiese right now too. Maschienenbau - FSR 5th floor Mar 10 12:28:52 oh. :D well. im at home :p Mar 10 12:28:55 yes I am computer scientist. Mar 10 12:30:00 tokam, about the MTP problem. Its a know bug that if you write a file its not immediatly updated and visible in MTP Mar 10 12:30:21 see https://code.google.com/p/android/issues/detail?id=38282 Mar 10 12:30:43 lol how many of the people here are german? Mar 10 12:30:47 as a workaround you have to reboot the app or force a rescan Mar 10 12:31:00 thanks :) Mar 10 12:31:15 app = phone * Mar 10 12:31:23 app reboot wont work :/ Mar 10 12:31:32 you can get a free coffee here ;) Mar 10 12:31:59 haha. Im like 40 km away from darmstadt atm :( Mar 10 12:32:16 When will you be here? Mar 10 12:32:22 2 weeks :p Mar 10 12:32:23 Must I always reboot the phone? Mar 10 12:33:06 tokam, you can also force an sd card rescan with an app Mar 10 12:33:12 like this: https://play.google.com/store/apps/details?id=com.bero.sdrescan&hl=en Mar 10 12:33:20 tokam, em Mar 10 12:33:26 you're saving image to the internal storage Mar 10 12:33:30 which doesn't shot up on MTP ever. Mar 10 12:33:41 (unless the path in your paste is wrong) Mar 10 12:33:46 oh. didnt see that Mar 10 12:34:13 I am working on the Epson BT-200 and tried both: Environment.getExternalStorageDirectory() Mar 10 12:34:13 Mavrik, is right. MTP only shows /sdcard Mar 10 12:34:20 and getFilesDir() Mar 10 12:34:37 For Environment.getDataDirectory() I could not save files! I got a false. Mar 10 12:34:38 tokam, also unless you tell the media scanner you created an image file Mar 10 12:34:44 tokam, it won't show up on MTP or galley. Mar 10 12:34:47 I created a folder with my app. Mar 10 12:34:47 *gallery Mar 10 12:35:06 It was not possible to rename an other folder to the name of the folder I tryed to create with my app Mar 10 12:35:12 but this folder was not visible too Mar 10 12:35:18 hi, I have retrieved an api authentication token via a RESTful call. Is there are way I can automatically pass this token to my other activity in my project automatically (or use a static object?)? or do I need to add in the token manually everytime I open an activity via an intent (with the set / get extras method)? Mar 10 12:35:29 s/are/a/ Mar 10 12:35:38 I can not download the app for sdcard rescan because I do not have google play but I could execute code! Mar 10 12:35:57 phix interfaces + observer pattern Mar 10 12:36:14 jvrodrigues: ok, google knows about that?? :) Mar 10 12:36:18 should know Mar 10 12:36:24 or do you have a link? Mar 10 12:36:28 if you want a more indepth explanation Mar 10 12:36:31 is really simple Mar 10 12:36:33 tokam, http://developer.android.com/reference/android/media/MediaScannerConnection.html#scanFile(java.lang.String, java.lang.String) Mar 10 12:36:53 that method tells the Media scanner to scan a file (make it show up in MTP) Mar 10 12:37:10 amazing you seem to be a good android dev. thanks Mar 10 12:37:34 after the phone reboot all my files are visible Mar 10 12:37:51 ... Mar 10 12:38:02 tokam, is this for a thesis? :) Mar 10 12:38:29 just create an abstract interface, expand it to create whichever interfaces you want; extend your application class; create a Map that links a specific interface to a collection of objects that implement that interface Mar 10 12:38:59 phix, most apps use the AccountManager Mar 10 12:39:14 phix, so when authentication token is retrieved, it's stored in accountmanager account Mar 10 12:39:22 and other activities can just freely check if account exists. Mar 10 12:39:30 also has added value of showing up on a central location for the user Mar 10 12:39:54 MediaScannerConnection.scanFile(this, new String[]{ image_out.getAbsolutePath() }, null, null); Mar 10 12:39:58 that's correct? Mar 10 12:40:29 danijoo: bachelor thesis - i develop an android camera based head tracking system for the epson bt-200 to be used in a flight simulator Mar 10 12:41:21 the AccountManager doesnt really trigger an event Mar 10 12:41:33 but you can use an intent for that i guess Mar 10 12:42:08 why would you trigger an event Mar 10 12:42:20 you have to check for proper credentials when activity starts/resumes anyway Mar 10 12:42:24 i wouldnt know, ask him, wasnt it what he wanted Mar 10 12:42:30 to notify the main activity that he has a token Mar 10 12:42:34 :S Mar 10 12:42:38 there's no need for notification. Mar 10 12:42:59 AccountManager.getAccountsByType().size() > 0 Mar 10 12:43:05 AccountManager.getAuthToken() Mar 10 12:43:22 tokam, sounds interessting. Mar 10 12:44:40 the work arround with the media scanner function call did not work. Mar 10 12:44:49 hm. Mar 10 12:45:07 it should :/ Mar 10 12:45:21 it's not a workaround. Mar 10 12:45:24 i just called that function and nothing else. Mar 10 12:45:24 You're probably using it wrong. Mar 10 12:45:36 (13:39:54) tokam: MediaScannerConnection.scanFile(this, new String[]{ image_out.getAbsolutePath() }, null, null); Mar 10 12:48:12 is that correct? Mar 10 12:48:52 no idea, check what the values are. Mar 10 12:48:56 check if you give proper file extension Mar 10 12:49:00 check if your mime type is ok Mar 10 12:49:04 check for return status of the scanner. Mar 10 12:49:16 anyone know how i could render a portion of a vector graphic? trying to create a tile provider, but i only have one vector image Mar 10 12:49:28 I gave null for mime-type Mar 10 12:49:38 Optional array of MIME types for each path. If mimeType is null, then the mimeType will be inferred from the file extension. Mar 10 12:49:55 Yes. Read that again. Mar 10 12:50:03 And verify that inferred mimetype is correct. Mar 10 12:50:33 maybe my error is that I gave it an image not a folder Mar 10 12:51:19 Yes, that's also possible Mar 10 13:19:08 Mavrik: what is AccountManager? and is it available in gingerbread or support library? Mar 10 13:19:58 Added in API 5, hmmm Mar 10 13:20:03 that is good :) Mar 10 13:22:21 AccountManager is for ... managing accounts Mar 10 13:22:30 :x Mar 10 13:27:04 Why does the createCaptureSession call fail here?: http://pastebin.com/v5LfCbc5 I end up in onConfigureFailed, and the log shows an error saying "E/Legacy-CameraDevice-JNI﹕ LegacyCameraDevice_nativeDetectSurfaceDimens: Could not retrieve native window from surface." Mar 10 13:37:26 danijoo: i got this annoying message: Failed to launch test Mar 10 13:38:20 using ant? or gradle Mar 10 13:51:42 anyone proficient with the Facebook SDK? Mar 10 13:52:30 <_genuser_> hey guys, what's going on? Mar 10 13:58:42 can anyone tell me why the Facebook SDK would say “ACESS_TOKEN_REMOVED” even though the AccessToken instance has an accfess token that is confirmed working in the OPen Graph sandbox? http://i.imgur.com/8BPCY1T.png Mar 10 14:03:35 mulletinc, in logcat? Mar 10 14:04:21 whatitis, yeah, when it stops on my breakpoint and the sessionState is open Mar 10 14:04:41 http://stackoverflow.com/questions/18307535/accesstoken-tokenaccess-token-removed-in-facebook-android-sdk it's a security thing Mar 10 14:04:52 My previous comment refers to that the SDK will NOT log your access token in logcat for security purposes, which is why you're seeing ACCESS_TOKEN_REMOVED (rather than the real access token). Mar 10 14:04:56 one of the comments Mar 10 14:06:03 ahh, I see. well that sorts that. problem is when I call Request.newGraphPathRequest(session, "/me/picture?redirect=false", new RequestGraphUserPhotosCallback()).executeAsync(); Mar 10 14:06:55 I get there error: {HttpStatus: 400, errorCode: 2500, errorType: OAuthException, errorMessage: An active access token must be used to query information about the current user.} Mar 10 14:07:14 400 = bad request -> server does not understand that url Mar 10 14:07:37 so your token is not valid Mar 10 14:10:42 but it’s a brand new token from the session that has just been opened Mar 10 14:10:49 doesn’t make sense. Mar 10 14:33:53 Right, worked it out after hours working on it. I was using this line to request the picture after getting the user: Request.newGraphPathRequest(session, "me/picture?redirect=false", new RequestGraphUserPhotosCallback()).executeAsync(); Mar 10 14:35:39 because it wasn’t sending the pricture with the response. turns out you can set which fields you want using the .setParams(Bundle) method on the Request instance. My thoughts are that you need to set the “accessToken” param in any request you make that’s not a MeRequest. I assuemd because I was passing teh session object to the request it woulkd Mar 10 14:35:44 use it, but apparently not. Mar 10 14:42:57 does anybody have a good tutorial for installing android on qemu with the network working? Mar 10 14:45:10 danijoo: i am using adt Mar 10 14:45:20 danijoo: eclipse... Mar 10 14:48:02 cant help u with that Mar 10 14:48:28 Hi, I have native android executable and libraries which were written using a text editor and compiled with Android.mk files inside a complete Android source tree. I want to debug something in this code. I have a development computer, and a device which is connected to it using adb via network (I can't use USB in this setup). What tools do I need in order to debug the native executable and libraries? Until now I have only debu Mar 10 14:48:36 dio over adb. Mar 10 14:50:07 I'm taking a peek at the shimmer-android lib that Facebook released. Check out createBitmapAndGcIfNecessary (https://github.com/facebook/shimmer-android/blob/master/shimmer-android/src/main/java/com/facebook/shimmer/ShimmerFrameLayout.java#L946) Mar 10 14:52:39 Woot! "a new debugger which automatically shows variable values in place in the editor" - http://tools.android.com/recent/androidstudio12preview1 Mar 10 14:54:27 oooo that is so cool Mar 10 14:55:47 I wouldn't recommend upgrading, though. Maybe install alongside. I upgraded and had issues (e.g., unit testing wouldn't work anymore), and I ended up having to go back to 1.1. Mar 10 14:56:13 quinnjn, this looks so wrong to my eyes >.< Mar 10 14:56:24 danijoo, ikr! Mar 10 15:03:55 I'll make the question short. Is it possible to debug a C/C++ daemon on Android using Android Studio? (If not, I'll fallback to Eclipse ADT) Mar 10 15:12:16 SoleSoul, no support for ndk in studio at all Mar 10 15:12:56 use ndk-gdb Mar 10 15:13:05 So a buddy and I released an app, he did iOS and I did Android, except his has taken off and mine has been slow progress Mar 10 15:13:35 pfn: Thanks. Where should I start for instuctions? Mar 10 15:13:48 SoleSoul, google for ndk-gdb Mar 10 15:17:56 pfn: I think I don't see NDK mentioned in the native daemon. Is it possible that it is a simple C/C++ application? (I know it compiles to Linux also). In this case, is my choice of tools wider? Mar 10 15:18:28 choice of tools would be non-existent Mar 10 15:19:24 build gdb for android, attach locally Mar 10 15:19:28 not a happy scenario Mar 10 15:19:31 pfn: Are you talking seriously? :) This might be a problem Mar 10 15:20:21 I guess you can use gdbserver Mar 10 15:22:35 I'm reading about your suggestions to understand their implications Mar 10 15:25:00 Anyone familiar with syncadapter or accounts? Mar 10 15:26:33 pfn: gdbserver is starting to look like a good option. Android has it installed and I can connect a serial cable. I'll try to make it work. Thanks a lot! Mar 10 15:41:04 anyone here using Jacoco with Robolectric? Mar 10 15:41:47 Lazydough: I'm not familiar with them, but I know that you are unlikely to get an answer unless you ask the actual question. Mar 10 15:44:20 i really wish those tests would work Mar 10 15:44:28 Which tests? Mar 10 15:44:44 i have an app and i wanna unit test it i am using eclipse, i create a test project Mar 10 15:45:04 It's easy in Eclipse. It's also easy in Android Studio. Mar 10 15:45:12 I'm trying to add an account to AccountManager.addAccountExplicitly(), it returns false but with no more info, tried using the debugger but it stops at compiled code, the documentation says it will return false if account already exists, account is null, or some other error occured. In this case it is "some other error" Mar 10 15:45:13 it asked me which project i selected Mar 10 15:45:15 thewhat? Mar 10 15:45:23 how does it know where are my tests? Mar 10 15:46:11 Nick-S: Gotta add a dependency from the test project to the Android project. Mar 10 15:46:25 yes it exists Mar 10 15:46:37 how does it know where are the tests Mar 10 15:47:26 Which test framework are you using? JUnit 4? Mar 10 15:49:56 your tests are in your tests directory Mar 10 15:52:17 Hi! Small question about permissions & architecture Mar 10 15:52:56 we're building a product that will deal a lot with a user's calendar. There will be an adroid app (main point of interaction) and servers that will do stuff and change the calendars Mar 10 15:53:25 Therefore I feel like I have to (1) use WRITE_CALENDAR and READ_CALENDAR on the android app (2) do the oauth2 dance for the server to be granted access Mar 10 15:53:30 what is a good way to regulary get images with opencv from an android camera without displaying them? Mar 10 15:53:33 Is that right? Is there a way to unify the operations? Mar 10 15:54:13 Or I'll have to (1) make users download the app with the 2 permissions (2) do the oauth2 dance inside a webview in the app? Mar 10 15:54:28 but processing them Mar 10 16:02:14 TacticalJoke: sorry i am using junit3 the one bundled with the android framework Mar 10 16:03:42 Nick-S: All you have to do is create a plain Java project, add some unit tests, add a dependency on your Android project, and run the unit tests. Mar 10 16:04:12 On a side note, it's better to switch to Android Studio now (which makes unit testing even more convenient, among other things). Mar 10 16:06:32 Hi all, long time ago. Does anybody know the right way to get the minute NumberPicker of a TimePicker? Mar 10 16:09:42 FrancescoV, TimePicker.getCurrentMinute() ? Mar 10 16:11:29 quinnjn, I need the NumberPicker, I guess getCurrentMinute doesn't return a NumberPicker Mar 10 16:11:45 why do you need the numberpicker? Mar 10 16:11:58 what about 2 numberpickers? Hour and Minute. That is what i've done in a past project IIRC Mar 10 16:12:50 quinnjn, I use a timeInverval like (0 - 15 - 30 - 45 minutes) Mar 10 16:13:07 sounds like you'd be better with a list of choices then Mar 10 16:13:50 it's already working fine, exept for a specific device. The code works for like 6 months but now It crashes for one user/device Mar 10 16:15:48 is it a samsung? haha Mar 10 16:15:56 blacklist that users phone it its not galaxy ^^ Mar 10 16:17:28 nop, alcatel Mar 10 16:17:49 see my comment : Mar 10 16:17:51 :p Mar 10 16:20:55 nice one. Maybe that's the best (easiest) option Mar 10 16:21:13 hi there, I successfully implement authenticator so I can now add an account using Account Manager, but now I don't know how to get the data that was stored Mar 10 16:21:16 whats the error you get on that device? Mar 10 16:21:40 any idea how to recuperate the data ? Mar 10 16:23:40 what data Mar 10 16:24:13 well, it's a NPE. Stupid actually. You can get the minute NumberPicker of a TimePicker using by getting the childViewAt(x) etc. But looks like this doens't work for that device. It's not clean code but it was the only option to make it work (months ago) Mar 10 16:24:42 maybe its a good idea to work arround the picker then Mar 10 16:24:47 and use sth else Mar 10 16:25:36 that's what I was thinking too, for that one device, there's no minute interval. Maybe I must show a toast with 'use a Galaxy to get the minute intervals' Mar 10 16:27:00 or use something like an edittext Mar 10 16:27:07 or idk Mar 10 16:27:36 is there an android equivalent the to Apple's Foundation Framework Reference? Mar 10 16:28:51 what is this Mar 10 16:28:56 then i tell u ^^ Mar 10 16:30:11 danijoo, the code https://bpaste.net/show/2878a419e04e Mar 10 16:30:33 and this is what I want to get intent.putExtra(AccountManager.KEY_ACCOUNT_NAME, accountName); Mar 10 16:31:28 FrancescoV, or convert to two NumberPickers :P Mar 10 16:31:34 danijoo: well, let's say you're looking for info on the NSString class for Objective-C. You head one over to the Foundation Framework reference, and it telss you everything about it like it's super class it's properties,mthods etc. It's the go to thing for anything IOS/OSX related Mar 10 16:32:07 rhllor, oh. you mean the docs for the framework? Mar 10 16:32:18 yes Mar 10 16:32:21 i guess Mar 10 16:32:24 like... http://developer.android.com/reference/android/app/Activity.html Mar 10 16:32:58 danijoo: perfect, thanks Mar 10 16:33:00 :) Mar 10 16:33:08 yw Mar 10 16:34:29 zoraj, you can just query the account manager for your data, cant you? Mar 10 16:35:20 believe me, I do search on google to do so, but I didn't found Mar 10 16:35:50 quinnjn, true. But it's sad that you can't get the NumberPicker of a TimePicker like: myTimePicker.getMinutePicker() Mar 10 16:36:35 zoraj, AccountManager.getAccounts() is not what you need? Mar 10 16:36:51 or getAccountByType Mar 10 16:36:58 minutePicker.setMinValue(0); Mar 10 16:36:58 minutePicker.setMaxValue(59); Mar 10 16:36:58 … Mar 10 16:37:00 minutePicker.getValue(); // 0-59 Mar 10 16:38:23 TacticalJoke: sorry i was addressing another problem Mar 10 16:38:47 TacticalJoke: i did all that i have in my manifdest as well which is pointing to packge of the tested app Mar 10 16:39:11 TacticalJoke: still i get Failed to launch test Mar 10 16:39:18 TacticalJoke: where is it looking for the test Mar 10 16:40:20 danijoo, and how can I get what I put here intent.putExtra(AccountManager.KEY_ACCOUNT_NAME, accountName); Mar 10 16:40:36 intent.getExtra() Mar 10 16:46:31 i wanted to save some data to google cloud how can i do that which api i should use? Mar 10 16:47:03 what data? Mar 10 16:47:07 and what cloud? Mar 10 16:48:00 does navigateUpTo from the support lib have bugs? i’m not getting any activity started! Mar 10 16:48:30 Nick-S: Sorry, I can't recall how to do instrumentation testing in Eclipse. Mar 10 16:48:33 I hardly did it, really. Mar 10 16:48:39 s/can't/don't/ Mar 10 16:48:57 samskiter: Are you specifying the parent activity correctly? Mar 10 16:48:58 samskiter, http://imgur.com/jacoj Mar 10 16:49:23 TacticalJoke: using both methods in the manifect Mar 10 16:49:32 danijoo: no stacktrace for nothing happening Mar 10 16:49:55 TacticalJoke: i.e both the meta-data and parentActivityName = “blah" Mar 10 16:49:58 samskiter, code then Mar 10 16:50:21 danijoo, hahaha Mar 10 16:50:49 <[twisti]> i dont know if there are proguard-literate people here, but im trying to get a class to both a) have its name flattened (from sdf.sfds.fsdfsdf.sdfdsf.sd to Aa or whatever) and b) not be slurped up by shrinking. ideas ? Mar 10 16:51:32 <[twisti]> i tried "-keep,allowoptimization,allowobfuscation @com.stuff.client.core.packets.Packet public class *" but it doesnt get obfuscated Mar 10 16:51:55 [twisti], do you have -dontobfuscate in your manifest? Mar 10 16:52:04 <[twisti]> i dont, the other classes get obfuscated fine Mar 10 16:52:34 <[twisti]> this class is only used through reflection, so proguard thinks it can optimize it away, thats why it needs special treatment Mar 10 16:53:00 you cant really obfuscate reflected classes Mar 10 16:53:09 because you need to know their name at runtime Mar 10 16:53:23 ^ Mar 10 16:53:30 <[twisti]> thats fine, i know its name Mar 10 16:53:42 not when its obfuscated ^^ Mar 10 16:53:59 * [twisti] points at adaptclassstrings Mar 10 16:54:00 because roguard will change its name to something weird like a.a.b.a Mar 10 16:54:06 <[twisti]> thats the goal, yes Mar 10 16:54:10 how do you want to call that with reflection Mar 10 16:54:12 <[twisti]> but its not doing that right now Mar 10 16:54:13 danijoo Mar 10 16:55:01 [twisti], but for the problem that proguard strips your class away, the syntax is: Mar 10 16:55:01 <[twisti]> its part of my annotation processor Mar 10 16:55:08 i want to build an app that store ur sms to google drive , cloud or some thing first u tell me where should i store that and than which api i use Mar 10 16:55:16 danijoo Mar 10 16:55:21 -keep class my.class.packacke.and.name { *; } Mar 10 16:55:40 [twisti], ah :) Mar 10 16:55:45 that makes sense then Mar 10 16:56:02 <[twisti]> so "-keep,allowoptimization,allowobfuscation class @com.stuff.client.core.packets.Packet { *; }" Mar 10 16:56:24 hm. i never tried keep with obfuscation to be honest Mar 10 16:56:48 danijoo: https://gist.github.com/samskiter/43d8396d6262a73ffbd7 Mar 10 16:56:50 <[twisti]> ah, no, that syntax isnt right, it doesnt like the 'class' word there Mar 10 16:56:51 but -keep should make proguard keep "unused" classes/mmethods Mar 10 16:57:14 <[twisti]> the keeping part isnt the problem, thats working fine, the problem is that the keeping also is preventing obfuscation Mar 10 16:57:35 [twisti], it might be that those two just dont work together Mar 10 16:57:36 its a brand new project, essentially following the guide here: http://developer.android.com/training/implementing-navigation/ancestral.html Mar 10 16:57:37 i dont know Mar 10 16:57:46 do you really have to obfuscate them? Mar 10 16:58:12 <[twisti]> its all my network protocol, so yeah, thats pretty much the only part that i really care about to be obfuscated Mar 10 16:58:19 samskiter, https://developers.google.com/drive/ Mar 10 16:58:46 danijoo: errrrmmmm? Mar 10 16:59:10 ups. wrong person :D Mar 10 16:59:25 s9iper1, https://developers.google.com/drive/ Mar 10 17:00:08 samskiter have you checkts upIntent if its correct? Mar 10 17:00:32 I'm working with a shitty API whose JSON response includes fun keys like presenters[0], presenters[1], up to an unknown number of entries. Is there a way to write a custom parser that puts these items into lists? Mar 10 17:00:42 *Using GSON/Retrofit Mar 10 17:01:06 explodes, custom deserializer Mar 10 17:01:13 danijoo thanks Mar 10 17:01:13 and handle it manually Mar 10 17:01:14 danijoo: it looks ok. the only slight strangety is there is a forward slash before “./HomeScreen" Mar 10 17:01:25 Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] cmp=blah/.HomeScreen } Mar 10 17:01:51 although “homescreen” doesn’t catch the launcher intent Mar 10 17:02:16 hm Mar 10 17:03:24 danijoo: it’s the same both with and without navutils actually Mar 10 17:04:02 but i shouldnt have to put the main/launcher action/category on the activity to make up work Mar 10 17:04:55 have you checked if the intent works when you use it without navutils Mar 10 17:05:01 just startActivity() Mar 10 17:05:11 (to check if its the intent or the method thats wrong) Mar 10 17:05:22 also, is there anything in the logcat, like a warning? Mar 10 17:05:52 startactivity works Mar 10 17:07:08 android generated the following comment: // Handle action bar item clicks here. The action bar will Mar 10 17:07:09 // automatically handle clicks on the Home/Up button, so long Mar 10 17:07:10 // as you specify a parent activity in AndroidManifest.xml.” but it doesnt Mar 10 17:08:54 an no i see nothing in logcat Mar 10 17:08:57 is robolectric single threaded? Mar 10 17:09:15 robolectric and/or junit Mar 10 17:09:40 samskiter, wait.. Mar 10 17:09:42 i have some callbacks that refuse to get called until all testcases have run. even though the TCs have long sleeps in them Mar 10 17:09:44 norrin you can spawn threads on junity, if that’s what you mean Mar 10 17:09:44 your manifest is wrong Mar 10 17:09:53 ah no . it isnt Mar 10 17:10:12 no idea srt Mar 10 17:10:18 and have to got Mar 10 17:10:29 samskiter, well the library under test uses threads. but they refuse to run until after the TCs have ru Mar 10 17:10:30 run* Mar 10 17:11:34 samskiter sorry only read half your problem, do you set your own toolbar in the activity that should have the up button? Mar 10 17:11:53 danijoo: I see that a deserialization would be used, but to replace foo[0] foo[1] with List seems like a bigger hack Mar 10 17:11:58 Memorion: i on’t believe so. just using generated classes Mar 10 17:12:20 Norrin: you all your test cases get run in parallel i believe. in separate instances Mar 10 17:12:36 danijoo: It would seem like I would need to write the entire deserializer for each object and then put the custom array stuff as a slapped-in patch Mar 10 17:12:37 samskiter do you get the arrow or doesn't it show up? Mar 10 17:12:50 Memorion: i get the material style back button Mar 10 17:12:54 samskiter, thanks Mar 10 17:13:13 Norrin: https://gist.github.com/samskiter/568cdb071ea8c4688a51 Mar 10 17:13:24 i used that to wait for callbacks Mar 10 17:13:47 samskiter ok, because I had to do getSupportActionBar().setDisplayHomeAsUpEnabled() with my own toolbar Mar 10 17:15:08 Memorion: no just using the actionbaractivity Mar 10 17:15:42 samskiter sorry, different problems then Mar 10 17:16:09 samskiter, so await is needed for callbacks to run? Mar 10 17:16:47 Norrin: yea you basically spin on the thread and wait for the BG ones to finish up Mar 10 17:17:20 so i just set 30 seconds, which is more than enough for my async things to finish off Mar 10 17:18:10 samskiter, what class i that signal? sorry, i do very little java Mar 10 17:18:18 is* that signal Mar 10 17:18:55 Norrin: shouldn’t that be obevious from the assignment of a “new CountDownLatch” ? Mar 10 17:19:12 import java.util.concurrent.CountDownLatch; Mar 10 17:19:42 Norrin: ah, and sorry, when you get your callback, you need to do signal.countDown(); Mar 10 17:19:43 samskiter, gotcha lol. it was thrown off by the class not being before the identifier Mar 10 17:19:45 to free the latch Mar 10 17:19:57 yes its a class variable, because you need to access it from your callbacks Mar 10 17:20:02 instance variable8 Mar 10 17:20:03 * Mar 10 17:23:08 hey all. I have a GLSurfaceView that I render various things on. What's a common way to 'layer' multiple GLSurfaceViews together? Mar 10 17:23:54 ie - I want a core layer and a overlay layer Mar 10 17:26:28 samskiter, ah gotcha Mar 10 17:26:35 thought I was missing some java-ism Mar 10 17:26:45 ac_slater_, you probably shouldn't. Mar 10 17:26:54 Mavrik: oh? Mar 10 17:27:02 I think it's actually possible to stack two surfaceviews. Mar 10 17:27:09 But it was horribly buggy last time I tried. Mar 10 17:27:17 They surfaceviews are special snowflakes :) Mar 10 17:27:29 Mavrik: makes sense. I really just need a 2d layer atop of my GLSurfaceView Mar 10 17:27:40 not really sure what approach to take Mar 10 17:27:52 hmm Mar 10 17:28:09 ac_slater_, usually you render it on top of rendered 3d frame Mar 10 17:28:12 in the same surfaceview Mar 10 17:28:12 The Wikipedia people are suing the NSA: https://blog.wikimedia.org/2015/03/10/wikimedia-v-nsa/ Mar 10 17:28:14 that's for HUD right? Mar 10 17:28:27 wow, just started an emulator for the first time in ages Mar 10 17:28:31 this shit is crappy Mar 10 17:28:44 thepoosh: What have you been using? Devices only? Mar 10 17:28:54 TacticalJoke: I read that a couple times as "NASA", and was confused Mar 10 17:28:56 I use the emulator only about 1% of the time. Mar 10 17:28:58 devices 99% and genymotion for the rest Mar 10 17:29:02 groxx: :D Mar 10 17:34:12 Mavrik: yea it's like a HUD Mar 10 17:36:10 got a unit test question, can anyone help? Mar 10 17:36:49 dont ask to ask Mar 10 17:36:51 not without the question Mar 10 17:36:55 sure Mar 10 17:37:04 Bryan792: just ask. if nothing else, the actual question might trigger someone's keywords. Mar 10 17:37:42 I'm trying to run unit tests using gradle 1.1 on a submodule in AS, but the mockable jar is not included in the classpath Mar 10 17:38:07 When I import the submodule as its own project in AS, it gets included Mar 10 17:38:15 why is there a difference ^ Mar 10 17:38:22 TacticalJoke: i have a report on a bug on api 15 and i'm not at work Mar 10 17:38:28 so I have to create an emulator Mar 10 17:38:30 :( Mar 10 17:38:45 <[twisti]> it would be so nice if it was easier to test my proguard config Mar 10 17:39:38 just build Mar 10 17:39:39 and fail Mar 10 17:39:41 or not Mar 10 17:44:14 Mavrik: so, since you seem to have explored this, what's the common way to do this? The android drocs for `2d graphics` are KINDA clear for drawing on a SurfaceView. Is that what you would do? Mar 10 17:44:36 um Mar 10 17:44:52 s/drocs/docs Mar 10 17:44:55 I don't know what you're doing or what do you have Mar 10 17:45:00 So hard to give you advice :/ Mar 10 17:45:19 Mavrik: true, goal: Draw 2d shapes on GLSurfaceView... API 17-18. Mar 10 17:45:51 the usual way is to use opengl itself to render things on Mar 10 17:45:57 I see. Mar 10 17:46:04 or you can just use a normal android view over the surface iew Mar 10 17:46:10 and render that Mar 10 17:46:15 interestingf Mar 10 17:46:19 ac_slater_: why can't you just draw it on the GLSurfaceView? Mar 10 17:46:25 it was buggy on older devices, but it should be fast enough Mar 10 17:46:38 JesusFreke: the guy doing the overlay stuff doesnt know OpenGL and doesnt want to Mar 10 17:46:45 ah :) Mar 10 17:46:50 fair enough, I guess Mar 10 17:46:53 anyone in here been able to get Jacoco to work with Robolectric? Mar 10 17:46:54 JesusFreke: yea kinda sucks Mar 10 17:46:54 ac_slater_, throw a custom view over the glsurfaceview and draw on its canvas Mar 10 17:47:06 Mavrik: that's what I was looking for Mar 10 17:47:07 thanks mate Mar 10 17:47:18 Jacoco keeps telling me i have 0% coverage when using w/ Robolectric test runner Mar 10 17:47:20 ac_slater_, do setZOrderOnTop(false) on the GLSurfaceView Mar 10 17:47:36 ac_slater_, and if your updates to the covering view aren't too frequent it'll be just fine Mar 10 17:49:16 Mavrik: I do have the Z order set. And my update interval is 10hz .. ie - 10 updates / second Mar 10 17:49:28 I could do 5 actually Mar 10 17:49:49 should be fast enough I guess :) Mar 10 17:50:41 Mavrik: we'll see ;). And my `throw a custom view on top` ... you mean via the normal view hierarchy? Mar 10 17:50:49 s/my/by Mar 10 17:51:08 ac_slater_, yeah Mar 10 17:51:15 great thanks Mar 10 18:00:00 <[twisti]> goddamn, -adaptresourcefilenames looked like the solution to all my troubles, but its too narrow Mar 10 18:09:49 is someone using cwac-camera here ? I've got a working code, but sometime, the camera "blink" / "reset" Mar 10 18:09:53 any idea why / how ? Mar 10 18:09:58 (nothing in logcat when that happens) Mar 10 18:17:06 Hi, I would like to ask for some help in this case http://stackoverflow.com/questions/28951736/pull-from-bottom-view-like-google-maps Mar 10 18:18:08 [twisti]: which problems are these? /me has curiosity Mar 10 18:18:47 whats the best way to make an animation that is depedent on a swipe position varaiable? Mar 10 18:21:41 lasserix: er. is it not by default? Mar 10 18:21:52 usually you do like animation.start Mar 10 18:22:06 i need it to be like @pos offset x -> setalpha y Mar 10 18:22:15 so basically i think best way is to subclass a textview Mar 10 18:23:53 <[twisti]> groxx: it can rename files according to obfuscation (sdf.sdfsd.Dfdsf.class turns to a.a.X, sdf.sdfsd.Dfdsf.properties turns to a.a.X.properties), but only if its files in the directory the classes are in, whereas i have /META-INF/annotations/sdf.sdfsd.Dfdsf files Mar 10 18:24:04 <[twisti]> theres no good reason for that restriction that i can think of Mar 10 18:26:22 [twisti]: dunno. is /meta-inf/annotations a standard format (ie, part of the java spec)? or just a convention? if it is, that does seem like an odd restriction. Mar 10 18:27:22 When I animate an scale-up with overshoot (like a pop) the view gets clipped when it momentarily exceeds 100% in size. Adding padding and margin doesn't prevent this. What to do? Mar 10 18:27:34 lasserix: ah, oops. I read that as "independent". personally, I've just combined the swipe-handling logic with alpha-setting (so 'set swiped offset; set alpha;'). not particularly pretty, but simple. Mar 10 18:28:58 This is for a view pager, Mar 10 18:29:16 whats really frustrating is onPageSelected is fired in the middle of onPageScrolled Mar 10 18:29:49 Zta: hmm. does it work if you .setClipChildren(false) on the parent view? otherwise all I can think of is to make sure that the layout doesn't depend on its size, and just scale up the whole view :( also, you can temporarily change view rendering order if that simplifies things. Mar 10 18:30:45 lasserix: are you fading things in the viewpager (e.g. like 4.4's app list pages), or fading other, related views? Mar 10 18:30:52 other Mar 10 18:30:56 text in title bar Mar 10 18:30:58 crap Mar 10 18:31:02 which is not in the view pager Mar 10 18:31:03 yeah Mar 10 18:31:11 groxx: android:clipChildren="false" on parent doesn't help =\ Mar 10 18:31:14 and i need current title out AND current title in Mar 10 18:31:23 which are two different animations Mar 10 18:31:53 tbh, with viewpager, I suspect the correct answer is to subclass / copy it and modify it. there should be _some_ way to get the current offset during an animation, and run a callback / .invalidate() a view. Mar 10 18:32:04 oh there is Mar 10 18:32:11 pagechanghedinterface Mar 10 18:32:27 yuckers Mar 10 18:32:28 could it be modeled as a page-indicator? some of those are reasonably fancy, and follow the actual page position. Mar 10 18:32:40 dunno what's involved there though Mar 10 18:32:48 maybe Mar 10 18:33:44 i think i can do this Mar 10 18:33:48 hopefully it won't break Mar 10 18:34:01 so this: http://stackoverflow.com/q/25920448/1056359 Mar 10 18:34:07 anyone aware of it? Mar 10 18:34:17 stackoverflow: yes Mar 10 18:34:27 groxx: :P Mar 10 18:34:28 thanks Mar 10 18:34:29 oh, yes, I've seen that. Mar 10 18:34:46 any thoughts? Mar 10 18:34:50 <[twisti]> groxx: its not a standard place, but -adaptresourcefilenames takes a file filter as a parameter, so its clearly INTENDED to be used on arbitrary places, its just restricted to a root thats too low Mar 10 18:35:41 thepoosh use android studio? ;p Mar 10 18:35:56 it's going to happen after this version is released Mar 10 18:36:01 but for now... Mar 10 18:36:12 thepoosh: not really :( as they sorta hint at, it feels like it mostly happens with somewhat-odd stopping points (like on a thrown exception, not on a breakpoint) Mar 10 18:36:25 nope Mar 10 18:36:34 thepoosh: one thing that occurs to me now though is that it could maybe possibly be related to the invisible devices in the device picker. is there a column you can resize? Mar 10 18:36:37 appens on breakpoints Mar 10 18:37:05 i'm debugging the only device connected Mar 10 18:37:16 both on Nexus 6 and OPO Mar 10 18:37:23 4.4 and 5.0.1 Mar 10 18:37:30 Guys, Im trying to update from 1.1 canary to 1.2 canary Mar 10 18:38:04 thepoosh: I don't think it has happened to me often enough to actually be something worth investigating, sorry :( typically it's just a one time "wtf D:" -> unplug device -> try again -> works. Mar 10 18:38:08 But it asks me for a config dir, which is apparently ~/.AndroidStudioPreview, but there is only ~AndroidStudio and ~/.AndroidStudioPreview1.2 Mar 10 18:38:20 :S Mar 10 18:38:33 http://stackoverflow.com/a/24540367/3991578 nevermind i guess Mar 10 18:39:42 ya, everyone that updated this morning had to point to their config file again Mar 10 18:39:54 at least on my team :) Mar 10 18:40:45 Why would you use canary versions in a company/business? Mar 10 18:40:57 Eh, kinda depends I guess. I wouldnt do it Mar 10 18:41:06 because it's fun! Mar 10 18:41:26 Oh, the errors look different now Mar 10 18:41:28 The release notes seem to suggest not updating. Mar 10 18:41:35 Instead running 1.2 alongsid.e Mar 10 18:41:38 alongside.* Mar 10 18:41:58 ^ yeah. I'm doing that just now. if they actually recommend it, I assume it's for a good / worrying reason :S Mar 10 18:42:09 Yeah, I couldn't get unit testing working in 1.2. Mar 10 18:42:24 crap. running out of memory already D: Mar 10 18:42:29 Wouldn't recognise my test directory as a test directory. Mar 10 18:44:53 Anyone have that code for getting a handle to the toolbar's title textview? Mar 10 18:45:33 recursively walk the view hierarchy, looking for a view with getText().toString().equals("the title") ! Mar 10 18:45:51 not shady in the least :| Mar 10 18:46:00 is your name Nikola? Mar 10 18:46:20 not last I checked. I don't have my birth certificate on hand though, so ¯\_(ツ)_/¯ Mar 10 18:46:34 My file encoding now is windows-1252 Mar 10 18:46:39 Shouldnt it be UTF-8? Mar 10 18:46:42 http://stackoverflow.com/a/28104500 Mar 10 18:46:45 Moter8: kill it with fire Mar 10 18:47:09 another CWAC Camera question, I can't use the front-camera, tried useFrontFacingCamera, but it seems it's never called Mar 10 18:47:14 lasserix: lol, nope. toolbar / actionbar / whateverbar is just generally a PITA Mar 10 18:47:24 Wouldn't it be better to use a custom TextView in that case? Mar 10 18:47:25 I am wondering if i should subclass toolbar to do this animation stuff or just use an actual textview inside the toolbar Mar 10 18:47:27 groxx, huh? Mar 10 18:47:29 I haven't tried, though. Mar 10 18:47:30 what is correct sensor (even on cheap devices) to read roatation left-right and up-down device-wice Mar 10 18:47:33 ? Mar 10 18:47:40 Moter8: it's possible it doesn't matter for your characters, and it's just inferring, based on the OS defaults Mar 10 18:47:41 seems like all my files are windows-1252 encoded. never looked before at it though Mar 10 18:47:42 groxx: Yeah, it always manages to be so. Mar 10 18:48:00 quasist: left right can be done with compas, up down is accelerometer (which can also be done with left right) Mar 10 18:48:06 They just need to create simple, focused APIs and we'll all be happy. Mar 10 18:48:35 I mean left-right like car wheel Mar 10 18:48:49 oh thats all accelerometer then Mar 10 18:48:51 Moter8: in preferences, search for "encoding". there are a couple things there. any not UTF-8? Mar 10 18:48:52 and up-down like you put telephone screen down to table Mar 10 18:49:14 lasserix: what animations? Mar 10 18:49:21 quasist: you are actually look for pitch and roll Mar 10 18:49:26 YES Mar 10 18:49:35 groxx, ah: http://i.imgur.com/dTVkrz0.png Mar 10 18:49:39 which can be one with accelerometer Mar 10 18:49:39 <-bad english user Mar 10 18:49:41 Seems to be it. Strange Mar 10 18:49:47 I created the project with AS 1.1 Mar 10 18:50:25 myke: need a viewpager scroll to function a animation on the toolbar title text (for outgoing page, text needs to translate + fade out, for incoming page, text needs to scale + fade in) Mar 10 18:50:28 Moter8: dunno. UTF-8 here, but macs default to that in most places (and/or I've changed a system-wide toggle somewhere) Mar 10 18:50:38 My files are all using UTF-8. Mar 10 18:50:43 accelerometer shows strange stuff on my g19... exactly what i look for (x,y, but Z=0 evrytime) but on phones there is a fully vector(x,y,z) Mar 10 18:50:46 argg! Mar 10 18:51:19 I'm gonna wait till 1.2 RC or something (and then import my project, thereby allowing Android Studio to create project files anew). Mar 10 18:51:49 quasist: ahh im sorry accel alone is not enough Mar 10 18:52:32 but on my ydplis g19 it shows enogh... Mar 10 18:52:59 but not on phones... Mar 10 18:53:11 quasist: http://www.reddit.com/r/androiddev/comments/1av1la/ Mar 10 18:53:30 quasist: yeah there is a reason i forget specifically but you have to combine compass + accel Mar 10 18:54:38 i am NDK user T_T Mar 10 18:54:50 http://www.sensorplatforms.com/understanding-orientation-conventions-mobile-platforms/ Mar 10 18:55:20 can you access the sensor stuff natively? Mar 10 18:55:23 if not just feed it down Mar 10 18:58:00 accel sensor shows different stuff for different devices... Mar 10 18:59:47 people, i have service and in onCreate method a do start some other threads. But sometimes OS decides to kill and shit it all, an onDestroy method not called. Mar 10 19:00:12 so what happens with all that threads that were created in onCreate methods& Mar 10 19:00:14 ? Mar 10 19:00:31 and shit Mar 10 19:00:35 quasist: sad to say that that's somewhat expected. accel / compass data has inconsistent quality on android :( Mar 10 19:01:15 groxx: got that anim/overshoot/clip working. Don't know what I did, though... Mar 10 19:01:17 quasist: I mean, first make sure it's not your code. but it's entirely possible it's just weird/wrong/faked. Mar 10 19:01:23 because after OS restarts service, it calls onCreate again and all that threads and shit created again Mar 10 19:01:51 I just want to read 2 axis "relative" rotation of device... Mar 10 19:02:02 quasist: http://gameovenstudios.com/bounden-on-android-delayed/ found it! Mar 10 19:03:04 quasist: it sounds like you want the gyroscope sensor Mar 10 19:03:43 quasist: it measures rotational acceleration Mar 10 19:04:14 as far as I know - my devices miss one Mar 10 19:04:15 hmm. maybe not acceleration. looks like it's the rotational rate Mar 10 19:04:26 ondroed, maybe it's the shit causing the issue :) Mar 10 19:05:14 hello, I just installed Android Virtual Device Manager. Any recomended docs to add devices? I namely want to add Samsung Galaxy S4 and S5 and want the virtual specs to be configured correctly Mar 10 19:05:34 android/sensor.h have only enum {ASENSOR_TYPE_ACCELEROMETER = 1,ASENSOR_TYPE_MAGNETIC_FIELD = 2,ASENSOR_TYPE_GYROSCOPE = 4,ASENSOR_TYPE_LIGHT = 5,ASENSOR_TYPE_PROXIMITY = 8}; Mar 10 19:05:51 ToAruShiroiNeko: gsmarena.com has lots of details for lots of phones, I'd probably copy from there. Mar 10 19:06:43 ToAruShiroiNeko: they won't have samsung-specific OS tweaks though. you may have to download samsung AVDs if you want to get the full experience. Mar 10 19:07:50 no I am not looking for something to specific Mar 10 19:07:53 quasist: yes.. there's there constant for the gyroscope Mar 10 19:08:03 I am just getting started on android apps Mar 10 19:08:18 right now my main goal is to have a basic app running to start playing with it Mar 10 19:08:24 I saw this on reddit the other day: they're working on multiple constructors for Kotlin (M11 release): https://youtrack.jetbrains.com/issue/KT-2095 Mar 10 19:08:51 JesusFreke, I tried gyro apps on my device - they all did not worked properly Mar 10 19:08:51 Sounds like great news for Android people looking at Kotlin. Mar 10 19:09:01 \o/ Mar 10 19:09:08 (.) (.) Mar 10 19:10:44 there is a gyro app that asks you to toss your phone as high as you can Mar 10 19:10:52 what happens with additional threads after OS kill service and onDestroy not called? Mar 10 19:10:55 exit Mar 10 19:11:25 ondroed, there are no threads anymore Mar 10 19:11:29 because the process was killed. Mar 10 19:11:33 ondroed: if the OS is doing the killing, then your process just gets killed whenever. everything stops, immediately, no matter where it was. Mar 10 19:11:59 ToAruShiroiNeko: Which app does that? Mar 10 19:12:39 ok Mar 10 19:12:44 Reminds me of those "Put your iPhone in the microwave" leaflets. Mar 10 19:12:44 http://newsfeed.time.com/2013/08/09/send-me-to-heaven-app-throw-your-phone-in-the-air-to-score-points/ Mar 10 19:12:56 well that reflection code no work Mar 10 19:13:03 "Maybe have a back-up phone handy. Or two" Mar 10 19:13:07 Seriously... Mar 10 19:13:52 Wow, that sounds stupid. Mar 10 19:13:59 I can totally imagine people putting it in a catapult and retrieve it with a parachute :p Mar 10 19:14:02 The phone Darwin awards. Mar 10 19:14:46 dildo-app... Mar 10 19:14:53 groxx ahh love that which way is north graphic Mar 10 19:15:05 hey all Mar 10 19:15:06 haha I had that idea Mar 10 19:15:09 there's also the app that begins shouting when it detects that the phone is falling Mar 10 19:15:49 that helps how? Mar 10 19:16:17 i wish app was http://www.youtube.com/watch?v=x-7osIds_RU scream Mar 10 19:16:18 Is it like this? http://www.dailymail.co.uk/news/article-2248824/Airbag-dropped-smartphones-invented-Amazon-patents-airbag-air-jet-mobile-phones.html Mar 10 19:16:25 nope Mar 10 19:16:37 so it just shouts Mar 10 19:16:41 wonderful :) Mar 10 19:16:41 sound makes pressure so the falling is slower? Mar 10 19:17:15 Ashiren even if speaker is facing the floor it wouldnt have the impact to prevent damage from the... impact Mar 10 19:17:16 thats not how gravity works Mar 10 19:17:18 found http://bibleapps.com/judges/15-14.htm while duckduckgoing for the app. seems legit. Mar 10 19:17:37 attach magnets to your phone, that will prevent damage Mar 10 19:17:45 ToAruShiroiNeko: brilliant game xD Mar 10 19:17:47 you will lose all your data though :p Mar 10 19:17:56 huh? Mar 10 19:18:13 flash drives can get damaged by magnets too? I knew HDD can Mar 10 19:18:29 lets find out Mar 10 19:18:29 That true. Mar 10 19:19:31 any electronics can be wiped with a strong enough magnet Mar 10 19:19:48 can you wipe a lihght bulb? Mar 10 19:19:56 (you probably can, meh) Mar 10 19:19:57 only once Mar 10 19:20:07 and you can totaly power light bulbs wirelessly Mar 10 19:20:36 well, a big alternating magnetic field could change its bit to the "on" state. and a really powerful one could permanently set it to the "off" state, saving your data from NSA snooping. Mar 10 19:20:49 nah Mar 10 19:20:55 NSA makes a copy anyways Mar 10 19:21:07 they have worlds largest porn archive probably Mar 10 19:21:19 * groxx pictures them running a whole bunch of duplicate lightbulbs to copy my lightbulb Mar 10 19:21:20 why else would they need a building sized server Mar 10 19:21:23 Anybody know a java REPL for windows/android studio? Mar 10 19:21:29 Once Kotlin has multiple constructors and annotation processing, and once it hits 1.0, will there be any serious reason to avoid using it? Mar 10 19:21:49 We'll think of something. Mar 10 19:21:52 :D Mar 10 19:21:59 Moter8: kinda sorta. start up an app, hit a breakpoint, open the "expressions" window. there's a multi-line mode that's sorta repl-like. Mar 10 19:22:10 TacticalJoke well, one reason is 'its not from google' Mar 10 19:22:20 and nobody knows wtf google is doing Mar 10 19:22:24 probably not even google Mar 10 19:23:13 since their own tools barely work, its takes courage to go off the beaten path Mar 10 19:23:25 groxx, will try that out. | apparently there is a jetbrains plugin for it. hm. Mar 10 19:23:38 True. Mar 10 19:25:24 if you could completely avoid the google toolchain altogether, that might even be safer bet. but if you adopt something thats not google that has to work with googly bits / tools, well. Mar 10 19:25:29 Hm my breakpoint does nothing (it gets called though) eh Mar 10 19:25:30 I wish there were more Kotlin documentation. I can't find much info at all about M11. All I see is comments in issue trackers, forum posts, etc. Mar 10 19:25:56 well, i only heard m11 was coming out this week maybe so we'll have to wait :) Mar 10 19:26:51 http://i.imgur.com/WhNjJcO.png hmmm Mar 10 19:27:06 Oh. I have to click the debug one Mar 10 19:27:44 hmm Mar 10 19:27:57 looks like you can't use reflection to get textview title from support toolbar Mar 10 19:28:32 There are better ways to do that (better than using a char array), Moter8. Mar 10 19:29:00 Elaborate? I searched and stuff and only found this way Mar 10 19:29:17 As I was saying before, a StringBuilder is a mutable String. :) Mar 10 19:29:20 No need to use char arrays. Mar 10 19:30:28 Anyone ever had Android Studio completely lock up on them? Mar 10 19:30:41 No abnormal RAM/CPU usage Mar 10 19:30:48 Just locked up Mar 10 19:30:48 t0astt: I've had it happen while deploying to my device. Unplugging the device unfreezed it. Mar 10 19:30:56 unfroze* Mar 10 19:31:03 TacticalJoke, but I hugely dislike for loops :/ Mar 10 19:31:14 TacticalJoke: Just tried it. No luck. I was editing a layout Mar 10 19:31:20 It doesn't involve a loop. Mar 10 19:31:32 Every stringbuilder example I looked up had one Mar 10 19:31:45 I will look it up in the future, but not now :P Mar 10 19:32:00 loops are a core element of java Mar 10 19:32:10 Any language, really Mar 10 19:32:12 I'll just point out that char arrays / toUpperCase isn't all that likely to work on other languages. Mar 10 19:32:15 * groxx resumes lurking Mar 10 19:32:22 Yes, Im aware. Im using one and I kinda get the point of them now Mar 10 19:32:32 t0astt: well functional languaes disguise them as maps Mar 10 19:32:51 myke: I have yet to use a functional language :) Mar 10 19:32:55 groxx, prob. all languages begin their sentences with uppercase Mar 10 19:33:12 or do you mean coding languages Mar 10 19:35:07 Moter8: yeah, but char[] won't handle characters that have surrogate pairs (e.g. anything that doesn't fit in 16 bits in Java's UTF-16), some languages have no uppercase, and it may not be as easy as uppercasing the first character anyway. Mar 10 19:36:13 Moter8: Why do you need this "make the first letter upper case" thing, anyway? Mar 10 19:37:45 It's a sort of quiz app where people can post their own questions/answers. Mar 10 19:38:06 All questions should start with an uppercase and end with an ?; and I did just that Mar 10 19:38:22 Yeah letting users post stuff is prob not wise but meh Mar 10 19:38:27 works as an experiment Mar 10 19:39:32 by the way AS includes a REPL by default. It's groovy though: Tools > Groovy console. Mar 10 19:40:01 But apparently it's java compatible, I have no idea Mar 10 19:40:29 Moter8: Are all questions and answers going to be in English? Mar 10 19:43:45 Nope, spanish/catalan only. Mar 10 19:44:06 (eg western languages) Mar 10 19:45:30 http://android-developers.blogspot.com/2015/03/android-51-lollipop-sdk.html Mar 10 19:46:59 "The org.apache.http classes and the AndroidHttpClient class have been deprecated in Android 5.1." Mar 10 19:48:09 Moter8: BTW, you should srsly learn about StringBuilder. It's a fundamental Java thing you need to know. Mar 10 19:49:22 g00s: fffuuuuuu.... yet more useful stuff being added to read_phone_state. and the same permission lets you see who you're calling. WHYYYY Mar 10 19:50:23 TacticalJoke are you using AS 1.2 or 1.1 ? Mar 10 19:50:31 1.1. Mar 10 19:50:36 oh oh Mar 10 19:50:38 Had to reinstall. lol Mar 10 19:50:48 i thought i would wait to see how things went :) Mar 10 19:51:18 I wanted to try to falsify your hypothesis. Mar 10 19:51:32 I'm running 1.2 in parallel now. it started up fine, then had an error, and seems to be working so far :) Mar 10 19:52:36 when they say expect bugs then you know its going to be bad Mar 10 19:53:28 "This is a stable release" --> "Expect bugs". "Expect bugs" --> "Expect Hell". Mar 10 19:54:20 g00s: yeah, hence "in parallel". it's rare that they warn so explicitly. Mar 10 19:54:43 TacticalJoke you had to do a fresh install right ? Mar 10 19:54:50 I wish they'd updated their release notes before I updated. I wouldn't've touched it with a barge pole. Mar 10 19:54:53 oh nm, they did have patches Mar 10 19:54:58 Yeah. Mar 10 19:55:28 it will probably be ready around I/O or afterwards, based on what Tor was saying the other week in a interview Mar 10 19:55:28 which makes sense if you e.g. have a "stable" install and a "canary" install Mar 10 19:57:58 A cool thing about not checking in IntelliJ files is that we can have them auto-generated every time we update Android Studio. Mar 10 19:58:49 I actually like deleting them and re-importing my project every time I change AS version (at least for significant changes). Mar 10 19:59:04 yup. I remain convinced that *.gradle files are the only way to go. Mar 10 19:59:07 My projects don't have baggage. :D Mar 10 20:01:17 hm "VersionUtils.isAtLeastL()" is pretty cool, but AS still complains about something I call in an if statement that's checked :( Mar 10 20:03:38 Isn't that an internal class, memorion? Mar 10 20:03:45 "return Build.VERSION.SDK_INT >= 21;" Mar 10 20:03:56 is in support v7 Mar 10 20:04:26 I wonder if it wouldn't complain if it used .VERSION_CODES.LOLLIPOP Mar 10 20:04:37 lint probably doesn't know about that yet Mar 10 20:05:04 android.support.v7.internal.VersionUtils Mar 10 20:05:31 memorion: https://android.googlesource.com/platform/frameworks/support/+/master/v7/appcompat/src/android/support/v7/internal/VersionUtils.java Mar 10 20:06:14 yeah, but it's public so why not use it? Mar 10 20:07:20 The "internal" naming suggests that it's not intended to be used by us. It could be unstable. Mar 10 20:07:42 https://a.pomf.se/xyvqup.mp4 argg!! Mar 10 20:08:08 ok, the falcon pro guy just talked about it in his talk so I didn't really think about it Mar 10 20:09:03 I'm guessing you'll be fine; just being pedantic about the general 'internal' thing. Mar 10 20:09:46 yeah, if I use the normal check lint doesn't complain so that's nice anyway Mar 10 20:09:52 nicer* Mar 10 20:11:21 As far as I know, that's generally a blacklist, though. It complains only when they've specifically targeted something. Mar 10 20:11:36 Moter8: it's because it can fall through to the next thing. Mar 10 20:11:49 material pocket casts update! Mar 10 20:11:55 add a break in the default case, it'll probably stop complaining. Mar 10 20:12:16 Moter8: also, since you're handling every case, try making the variable final - that'll give you an error if you assign twice, which highlights problems like this. Mar 10 20:12:22 it does. ugh Mar 10 20:12:25 you are a wizard Mar 10 20:12:42 heh i wonder if appcompat is compat with 22 :) Mar 10 20:12:52 gotta ask :D Mar 10 20:13:11 I sorta wish there was a "switchWithImplicitBreak" construct :| I enjoy fallthrough, but it's verbose for the rare times you want it, and switch statements are kinda nice sometimes. Mar 10 20:13:45 Much better is something like this: switch (x) { case foo, bar: doFirstThing(); case baz: doSecondThing(); } Mar 10 20:13:49 The C switch syntax is stupid. Mar 10 20:14:00 groxx, you mean inside my method's constructor or where Mar 10 20:14:05 I cant seem to make the enum final Mar 10 20:14:17 `final GameModeConstants.GameModes gameMode`? Mar 10 20:14:17 TacticalJoke: yeah, I like ruby's approach. it's the same as "===", so you can say "case 1..5: whatev" Mar 10 20:14:28 Though it's kinda understandable in a low-level language such as C. Mar 10 20:14:32 Yeah, that's nice. Mar 10 20:14:33 Moter8: change "Intent intent;" to "final Intent intent;" Mar 10 20:14:52 Kotlin can do that, groxx. Mar 10 20:14:59 As well as the comma thing. Mar 10 20:15:02 TacticalJoke: also "case /^a/: useStringThatStartsWithA" Mar 10 20:15:06 http://kotlinlang.org/docs/reference/control-flow.html Mar 10 20:15:11 Oh, that's nice. Mar 10 20:15:28 groxx, doesnt seem to change much Mar 10 20:15:36 Still needs the default case Mar 10 20:15:38 1..5 becomes a Range object, /^a/ is a Regexp (WHY THE P???), and both define "===" Mar 10 20:16:17 Moter8: yeah. even if you handle all enum values in a switch, because you might some day extend the enum and run against old code, you still technically need a default case. Mar 10 20:17:00 A nice thing about Kotlin 'when' statements (basically 'switch' statements) is that they can take arbitrary expressions. You can say stuff like this: when { foo -> handleFoo(); bar -> handleBar(); else -> handleEverythingElse() } Mar 10 20:17:07 >.< I see. It makes sense, but Id like it prettier Mar 10 20:17:08 Avoiding if..else if..else. Mar 10 20:17:58 Moter8: yeah, same :) personally, I dream of a language where, since the method takes a specific enum, you can just say "aMethod(.THE_ENUM_VALUE)" instead of "aMethod(TheEnum.THE_ENUM_VALUE)". Mar 10 20:18:36 e.g. "setVisibility(.GONE)" Mar 10 20:18:39 Is it normal to build a separate layout for portrait and landscape mode, like how you would make an xml for phone and an xml for sw720dp ? Mar 10 20:18:42 why are there so few android studio tutorials especially for games? do people use unity3d over android studio? Mar 10 20:19:00 I'm reading http://developer.android.com/guide/practices/screens_support.html to try to answer that but the portrait/landscape part isn't clear to me Mar 10 20:19:02 kuyo: probably because android studio doesn't yet support NDK Mar 10 20:19:39 would i be better of learning unity then Mar 10 20:20:30 CanyonMan: values/layout/the_layout.xml <- used as the default. values/layout-sw720dp/the_layout.xml <- used for all devices >= 720dp on all sides. the best-matching values/whatever-constraint/ thing is used. Mar 10 20:20:56 CanyonMan: see also: http://developer.android.com/guide/topics/resources/providing-resources.html Mar 10 20:23:06 is there a channel for unity Mar 10 20:23:35 #unity3d #unrealengine Mar 10 20:23:57 kuyo: better learning unity: dunno. maybe? unless you're familiar with building games from scratch, it may be best, it does a lot for you. Mar 10 20:24:28 https://www.google.de/design/spec/layout/metrics-keylines.html#metrics-keylines-keylines-spacing are tgese keylines defined as dimensions somwhere? Mar 10 20:24:39 [10:35:55] Norrin, android update project -g -v 1.1.2 ... Mar 10 20:24:42 pfn, didn't work Mar 10 20:24:49 memorion: not afaik Mar 10 20:25:04 how do you migrate from maven to gradle? Mar 10 20:25:05 groxx ok, thanks Mar 10 20:25:07 so I'm creating some edit fields during run time and trying to set their id's so I can pull info from them later on in the program Mar 10 20:25:27 nevermind realized the answer as I was typing Mar 10 20:25:28 haha Mar 10 20:25:41 "maven translates directly" - no idea what that's supposed to mean Mar 10 20:25:42 Hey, is there a way to make a TextView format a number content with grouping seperator? 1024 -> 1,024 ? Mar 10 20:26:09 danijoo, ideas? Mar 10 20:27:11 viran, http://developer.android.com/reference/java/text/DecimalFormat.html is what you are looking for, I believe Mar 10 20:27:45 & http://stackoverflow.com/questions/14186657/how-to-format-numbers-on-android Mar 10 20:27:52 Moter8: I deal with numbers bigger than double so that will not work for me, I have a String without formatting, just need to add the commas to it Mar 10 20:28:17 Oh. Mar 10 20:28:23 String builder? Perhaps? Mar 10 20:29:23 viran: like a BigInteger? it probably still works: http://developer.android.com/reference/java/text/DecimalFormat.html#format%28java.lang.Object,%20java.lang.StringBuffer,%20java.text.FieldPosition%29 Mar 10 20:29:24 yeah, if everything else fails Mar 10 20:29:26 there's always all this noise in here about migrating from maven "just works" when no one else seems to think so Mar 10 20:29:26 http://stackoverflow.com/questions/7719495/migration-from-maven-2-3-to-gradle Mar 10 20:29:32 maybe BigDecimal Mar 10 20:29:35 and format Mar 10 20:30:13 yeah, that's an option Mar 10 20:31:07 some for/while loopery should be fine to do it, and if you want it properly then possibly stringbuilder Mar 10 20:31:13 huh Mar 10 20:31:39 groxx: so I COULD have both a portrait and landscape for each resolution if I WANTED and it would find it? Mar 10 20:31:53 CanyonMan: yeah Mar 10 20:31:57 yeah, it all happens inside a getView() of a list adpter :/ Mar 10 20:32:00 CanyonMan: or, lemme check. depends on precedence. Mar 10 20:33:00 I see what ou mean about the properties Mar 10 20:33:08 which you can specify orientation in there if you want Mar 10 20:33:44 CanyonMan: yeah, i think that should work. -sw720dp will take precedence over -land, but if you have both -sw720dp-port and -sw720dp-land it'll work. Mar 10 20:33:53 ok yeah Mar 10 20:34:00 ok yeah i get it Mar 10 20:34:12 that's the EXACT thing I was asking. It would be -sw720dp-port and -land Mar 10 20:34:20 ok great, thanks $1,000,000.00 Mar 10 20:34:41 I really do read documentation. I just get kind of lost sometimes in it Mar 10 20:35:16 CanyonMan: if you make / have an AVD description (no need to have the full image, just the hardware spec), you can use the layout preview thing to view it on different devices / orientation, to make sure it's working like you'd expect Mar 10 20:35:33 CanyonMan: otherwise, that "providing resources" page describes the algorithm in detail, so you should be able to predict if it'll work or not. Mar 10 20:36:03 It's not too bad doing it on the actual tablet. I found out the hard way my laptop can't run the virtualization/hxm or watever it is and the qemu based arm is just toooooooooooooooo slow Mar 10 20:36:07 CanyonMan: and yeah, there's a lot of things that are useful, hard to find them all / prioritize. Mar 10 20:36:20 lol, yeah, no haxm sucks Mar 10 20:36:36 tiny emulators work acceptably, like a 320x240 device :) Mar 10 20:37:36 Tell me if I asked this before, but what's a good resource for learning app Dev? Should I have prior Java experience? Mar 10 20:39:16 yes Mar 10 20:39:44 pardelkat, Im learning since 1.5 months and it wasnt too difficult to get into Mar 10 20:40:11 What do you recommend I do to learn java Moter8? Mar 10 20:40:12 watched teamtreehouse videos, they introduce you java first for ~4-5h and then start with android Mar 10 20:40:17 You don't need prior Java experience. Mar 10 20:40:26 why java when there ndk... Mar 10 20:40:26 Oh don't you have to pay for that? Mar 10 20:40:34 But of course learning Java is basically require. Mar 10 20:40:40 required* Mar 10 20:40:48 it's 9/mo for me, it was free for 14 days Mar 10 20:40:52 you can skip java by NDK Mar 10 20:40:53 well worth it for me, anyway. Mar 10 20:40:58 quasist, eh Mar 10 20:40:58 pardelkat: The Oracle tutorials are good. Mar 10 20:41:05 Moter8 ^_^ Mar 10 20:41:13 pardelkat, there are also free resources out there, of course. Mar 10 20:41:19 quasist: You should use Java for normal app development. Mar 10 20:41:44 Norrin, there's nothing to migrate, create an default build.gradle, and it's done Mar 10 20:41:46 java is always slow Mar 10 20:41:48 Norrin, you don't seem to do that... Mar 10 20:41:50 do you think this 720p is the best notation ? probably ... as opposed to like ldpi mdpi Mar 10 20:41:54 java isn't slow Mar 10 20:42:10 bridging jni constantly is slow, however Mar 10 20:42:12 * jaana eyes quasist Mar 10 20:42:15 Hi, Iam trying read serialized "String []". first I have tried to read it from /assets, but I got "java.io.FileNotFoundException: This file can not be opened as a file descriptor; it is probably compressed", so I was looking for solution and found some hint with "R.raw" and /raw dir from http://stackoverflow.com/questions/5795410/android-java-deserializing-a-file-on-the-android-platform . Problem is that AS keep saying "Cannot resolve symbol raw". Mar 10 20:42:16 Any idea what to do with it? Mar 10 20:42:21 pfn, create how? done? it magically does everything my pom does? Mar 10 20:42:34 Norrin, do you do custom build steps in your pom? if not, it just works Mar 10 20:42:51 Norrin, and create it using any number of means, including creating a new android project and just copying build.gradle Mar 10 20:43:13 but since you refuse to create it, you can't be helped Mar 10 20:43:22 pfn, can you link me software renderer that runs fine on my 4.0 toaster phone? Mar 10 20:43:23 pfn, create how..... Mar 10 20:43:29 now you did just answer NOW Mar 10 20:43:33 android create project -g -v 1.1.3 Mar 10 20:43:33 but didn't before Mar 10 20:43:47 create, migrate, whatever, all the same thing Mar 10 20:43:47 that just seems wrong. i have a project already Mar 10 20:43:52 Can I make apps without internet? I don't have it right now. Mar 10 20:43:56 in short, there is no migration. the only option is to start over Mar 10 20:43:57 create a new project, to get a default build.gradle Mar 10 20:44:24 but i guess i can try that. Mar 10 20:44:31 pardelkat, yup you can Mar 10 20:44:43 the next part would get getting AS to realize that project now is "gradle" instead of "maven" Mar 10 20:44:46 (how are you on irc without internet is the other question tho) Mar 10 20:44:46 Norrin, otherwise, just copy a build.gradle out of any existing project out there Mar 10 20:44:56 Moter8: I think he was being sarcastic Mar 10 20:45:06 I dont think he was Mar 10 20:45:06 no, i just C junkie... Mar 10 20:45:35 can't believe they realized this crap without a migration tool Mar 10 20:45:44 and then require it Mar 10 20:45:54 pardelkat, but first you have to download android studio, the java sdk, android sdk, lots of stuff basically. Mar 10 20:46:16 And installing 3rd partyy libraries without internet is doable but meh Mar 10 20:46:16 just SDK+NDK and your vim/emacs Mar 10 20:46:38 CanyonMan: only thing I can say is "it depends" :) sw720dp means that the device has to be 720dp or larger on _both_ sides though, which I think means it'll only apply to reasonably large tablets. Mar 10 20:46:41 Norrin: I don't see how converting from Maven to Gradle would be difficult. Mar 10 20:46:48 Surely it's a 10-minute job in the worst of cases? Mar 10 20:47:04 Moter8: I have all that Mar 10 20:47:06 TacticalJoke, saying that over and over again does nothing as to solving how to do it Mar 10 20:48:06 daang. fast internet is nice. downloaded all of AOSP in less than an hour. Mar 10 20:48:07 now i will create a dummy project to get a gradle and then google peice-mill how to get it to do everything my pom does but that's exactly what i was trying to avoid Mar 10 20:48:33 unless it magically reads my pom, or there is a migration tool, it's not going to "just work" Mar 10 20:48:46 I'd much *rather* do it manually, than to rely on some automated tool that could fail and cost me even more time. Mar 10 20:49:06 Norrin, you have never said wtf your pom that does that's magical Mar 10 20:49:10 copy your dependencies, and you're done Mar 10 20:49:13 but you refuse to communicate Mar 10 20:49:19 so, yeah, I'm not talking to you anymore Mar 10 20:49:38 waaaaaaa Mar 10 20:49:39 or even try for that matter Mar 10 20:49:50 pfn, build and release. deployment. test goals. everyting you typically do with a pom..... Mar 10 20:50:11 then the gradle plugin does that by default already Mar 10 20:50:20 you, again, have shown nothing special about your pom Mar 10 20:50:23 so it knows where my nexus server is.... Mar 10 20:50:26 drop in a plain build.gradle, add your dependencies, and now it works Mar 10 20:50:28 add resolvers then Mar 10 20:50:30 it knows my nexus password... Mar 10 20:50:31 really, not fucking hard Mar 10 20:50:37 add your password shit, not fucking hard Mar 10 20:50:42 HOW Mar 10 20:50:45 takes 30 minutes to google Mar 10 20:50:51 and you're done migrating Mar 10 20:50:53 but you refuse to try Mar 10 20:51:03 "gradle add resolver" Mar 10 20:51:07 "gradle repo password" Mar 10 20:51:09 if anyone interested - code for mytopic http://pastie.org/10017010 Mar 10 20:51:09 google every fuckking line. if you would have just said that i would have known what you intented Mar 10 20:51:12 Norrin: http://gradle.org/docs/current/userguide/maven_plugin.html Mar 10 20:51:15 "it just works' is a fucking lie Mar 10 20:52:04 “it just works if you’re smart enough" Mar 10 20:52:16 also probably http://gradle.org/docs/current/userguide/artifact_dependencies_tutorial.html Mar 10 20:52:31 The plugin user guide shows how to set up a build.gradle. You'll have to be specific as to what doesn't work if you want help Mar 10 20:52:31 http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Basic-Project Mar 10 20:54:07 I'll check those out Mar 10 20:55:15 Norrin: there's also http://lmgtfy.com/?q=gradle+nexus => http://stackoverflow.com/questions/13210037/how-to-use-sonatype-nexus-with-gradle-to-proxy-repsitories which looks relevant though simplified Mar 10 20:56:37 am i the only one who things the gradle docs on tools.android.com is better than the mishmash of stuff on the official site? Mar 10 20:56:44 s/things/thinks Mar 10 20:57:00 The official Gradle documentation is a novel. Mar 10 20:57:06 its like they tried to simplify it but just made it far worse Mar 10 20:57:12 g00s, you mean the OnePageWikiEverything(tm) ? Mar 10 20:57:22 I'd just like a javadoc :/ Mar 10 20:57:24 yeah i didn't say it was great ... Mar 10 20:57:29 or groovydoc or whatsis Mar 10 20:57:44 you can download a zip file for the DSL but ... it wasn't too enlightening Mar 10 20:57:55 g00s: for specific stuff, sure. once you escape that though, you're pretty much at the mercy of Gradle, volumes 1 through 137 Mar 10 20:58:22 i meant official site, like d.android.com not gradle.org Mar 10 20:58:41 but yeah, how the heck did they approach almost zero information density with so many pages :| Mar 10 20:58:56 that takes skill actually Mar 10 20:59:25 the gradle site, that is Mar 10 20:59:45 g00s: ooooh. I haven't read the d.android.com gradle stuff in detail yet. it doesn't really provide enough info to solve things it doesn't directly address though, the tools.android.com ones are way better there. Mar 10 20:59:56 groxx yeah thats what i mean Mar 10 21:00:02 the fact that class autocomplete doesn't work in .gradle files annoys me as hell Mar 10 21:00:17 having to look up every method on a class is like programming in vim ;/ Mar 10 21:00:17 some autocomplete works. slow though. Mar 10 21:00:43 Yeah, it's amazing how little info the gradle.org guide has. I thought it'd be some awesome reference but it's so boring. Mar 10 21:00:55 It actually reminds me a lot of a religious text: pages and pages of rambling about gawd-knows-what. Mar 10 21:01:02 yeah, gradle.org task documentation is actually useful though Mar 10 21:01:13 TacticalJoke yeah its like, omg i just read 10 pages and don't know any more than i did before Mar 10 21:01:16 the android plugin doesn't even have all properties/variables documented :/ Mar 10 21:01:59 finding how to extract output dir / artifact name / etc. means digging to boatload of SE questions :/ Mar 10 21:40:23 In Eclipse I can right-click on my Android project > Android Toold > Add Support Library. This downloads android-support-v4.jar and puts it in my libs folder. But how do I get android-support-v7.jar? Mar 10 21:41:27 hello everyone, running on a Galaxy S5 G900V (Verizon) and on 5.0 (L). I compiled a build of LatinIME from AOSP and it is my understanding that there is no way to transfer over the dependant library “libjni_latinime.so” to the “/system/lib/“ folder on the device w/o having root. Well, I can’t root because I’m on 5.0. Am I screwed to the point where I will have to do a factory reset and go backwards before I can get my custom Mar 10 21:41:27 keyboard to install or is there any way to get this library onto my device without having to root it? Mar 10 21:42:50 I wish that the LatinIME.apk would just carry and install the library for me, but that doesn’t seem plausible. Even if it was, I wouldn’t know where to look. I’m running out of places/things to google Mar 10 21:43:13 burmat try #android-root and maybe someone sends it to you Mar 10 21:43:34 well with everything said, I really have no other reason to root my phone Mar 10 21:43:46 so I was hoping the general dev community might have a solution before I headed over to root Mar 10 21:44:33 burmat https://android.googlesource.com/toolchain/benchmark/+/honeycomb/android_build/eclair/out/target/product/passion/obj/lib/libjni_latinime.so does that work? Mar 10 21:44:49 I mean, I have a copy of the apk (which runs fine on an emulator) and I have a copy of the *.so file (again, which transfers fine on the emulator). Just want everything to run on my phone Mar 10 21:45:23 sorry, should have been more clear. I have a copy of libjni_latinime.so, just no way to get it on my device.. Mar 10 21:46:09 if you have the source of the keyboard can't you bundle the .so inside the app? Mar 10 21:46:27 i guess my question comes down to whether or not rooting my device is the only way to get the .so file to my /system/lib/ dir Mar 10 21:46:52 memorion: that’s I guess where I’m stuck. If you *can* bundle it inside the app, how the hell do you do that haha Mar 10 21:47:21 I was psyched to see everything else go so smoothly and then I saw libjni_latinime.so and assumed it would already be on my device. now i’m stuck Mar 10 21:47:26 never assume anything I suppose Mar 10 21:47:36 if it's a gradle project put it in the jniLibs folder I think Mar 10 21:48:52 but I don't know if you have to do something extra in the source to use that instead of looking for the system provided one Mar 10 21:49:22 exactly, and because i’m not building it in android studio (using make), I don’t know how to include it Mar 10 21:49:27 to be completely honest Mar 10 21:49:47 and there are resources online to help you build from source and everything, just no help when it comes to including the *.so file you are going to have to use with it Mar 10 21:50:30 hey guys - quick question, I'm trying to use Genymotion with Android Studio since I was having trouble with the built in virtual emulator. Mar 10 21:50:38 and rooting it is fine and all, I get it. I just feel like I shouldn’t have to. especially when I am not going to need root for anything else at the moment and I would have to factory reset (which would really blow) Mar 10 21:51:03 I went to Plugins > found Genymotion, installed it, I now have the Genymotion icon in Android Studio, but when I click on it - it wants the Genymotion install folder?? Mar 10 21:51:08 burmat, look at how https://github.com/syncthing/syncthing-android does it, maybe? They have a linux script to build go binaries and include them in the build.gradle etc Mar 10 21:51:17 burmat I'm pretty sure what you want is possible, but I can't tell you more than I already did Mar 10 21:51:38 memorion: thanks for your suggestions, i appreciate it Mar 10 21:51:43 Moter8: I’ll dig into that now Mar 10 21:52:09 Moter8 burmat I think the .sh script only builds the dependency and gradle just includes it, it doesn't build the whole project Mar 10 21:52:25 <_genuser_> DARN WORK VPN! Mar 10 21:52:27 <_genuser_> doh Mar 10 21:52:36 yeah yeah Mar 10 21:52:44 <_genuser_> stupid thing prevents even the disabling of wifi adapters. Mar 10 21:52:44 the sh sets up go and builds the binaries. as I said. Mar 10 21:52:56 Insanity Wolf: minSdkVersion 22 Mar 10 21:53:10 Moter8 yes, but that's not was burmat needs Mar 10 21:53:36 yeah, i don’t think this will work. damn. Mar 10 21:53:54 Moter8 his binary is built already he just needs to figure out how to include it Mar 10 21:53:58 how has no one posted a how to for this yet.. Mar 10 21:54:24 can anyone assist me with getting Genymotion set up with Android Studio? Mar 10 21:54:34 burmat do you know how the app is normally built? Mar 10 21:55:10 robocane you can just start the genymotion app and android studio recognizes the running emulators, never used the plugin sorry Mar 10 21:55:21 then he shall look at the build.gradle file. Mar 10 21:55:34 memorion - back up a step, so just download Genymotion on it's own? Mar 10 21:55:37 Moter8 he said the project isn't built with gradle Mar 10 21:55:42 robocane yes Mar 10 21:55:50 damn, I missed that, sorry Mar 10 21:55:50 so to be honest, all i did was git the master branch, make my modifications to packages/inputmethods/LatinIME/* file, and run “make LatinIME” Mar 10 21:56:06 burmat show the make file Mar 10 21:56:12 memorion: alright i'll try that and let you know Mar 10 21:56:29 memorion: or is it even better to just test the app on my phone? Mar 10 21:57:07 support library 22 Mar 10 21:57:08 robocane depends, usually I test layout changes on genymotion because I can see on my second monitor Mar 10 21:57:46 memorion: as in, you want to see the make file? Mar 10 21:57:55 burmat yes Mar 10 21:58:27 robocane plus you can test devices different from your own Mar 10 21:58:42 lol it doesn't look like they did much of anything Mar 10 21:59:00 Hey, anyone know how to easily stop clicks from coming through a transparent overlay (relativeLayout) Mar 10 21:59:01 memorion: gotcha, downloading the actual program now (not the plugin) Mar 10 21:59:02 ? Mar 10 21:59:06 memorion: http://pastebin.com/yiXiMX3w Mar 10 21:59:19 it’s long and idk what i’m looking for Mar 10 21:59:24 so excuse my ignorance Mar 10 21:59:26 robocane and I just installed the plugin Mar 10 21:59:36 I have the transaprent over some buttons.. clicking the transparent will transfer the button clicks to the buttons instead of doing nothing, or clicking the relativelayout Mar 10 21:59:37 hi all, I'm testing a wifi printer (Canon iP110) on a 3g/wifi device running lollipop and I was hoping to be able to be connected to the wifi printer and 3g at the same time, using 3g for data. is this something that android.net.ConnectivityManager.requestnetwork() should be used for and is there a way to make a WebView use the requested network? Mar 10 21:59:45 do I set relativelayout to clickable?.. hmm maybe I’ll try Mar 10 22:00:33 Hmm, they added TextAppearance_AppCompat_Button. Though I dunno whether it really means much. Mar 10 22:00:39 yes. that is what I should do. Mar 10 22:01:17 I love the documentation: http://developer.android.com/reference/android/support/v7/appcompat/R.style.html#TextAppearance_AppCompat_Button Mar 10 22:01:28 EionRobb: requestNetwork, afaik, though I haven't used it before. Mar 10 22:01:40 Then again, to be fair, there's not really much they can say. Mar 10 22:02:18 Zta: depends on the v7 lib. if it has resources, there's no jar, because jars can't hold the resources. https://developer.android.com/tools/support-library/setup.html Mar 10 22:02:52 Zta: Use Android Studio! Mar 10 22:02:58 (Unless you're doing NDK development.) Mar 10 22:03:30 burmat sorry I'm not really familiar with makefiles, I looked through it but I also didn't see an obvious way to include .so dependencies Mar 10 22:03:40 yeah me either Mar 10 22:03:50 burmat do you have a link to the full project? Mar 10 22:04:11 i’m seeing references to “dictionary_service_name” in the manifest, i’m wondering if I can just change it to a lib that is already on my phone and call it a day Mar 10 22:04:24 memorion: how long should it take the emulator to start? Mar 10 22:04:34 several minutes Mar 10 22:04:37 robocane emulator or genymotion? Mar 10 22:04:44 emulator is really slpw Mar 10 22:04:44 genymotion* sorry. Mar 10 22:04:54 it’s literally raw AOSP down to the LatinIME.java file Mar 10 22:05:10 robocane relatively fast but I the first start may be longer Mar 10 22:05:15 I have my tweaks in there and that’s it. When I run a make on it, everything compiles just fine Mar 10 22:05:19 ok seems to have made progress, it changed from blank black screen to showing the android logo Mar 10 22:05:26 at least its doing something - i was worried it didnt work/froze Mar 10 22:05:38 burmat the whole keyboard is one file? Mar 10 22:05:45 oh no, sorry Mar 10 22:05:57 does that Intel haxm acceleration matter if im using genymotion? or is it only for the built in emulator? Mar 10 22:06:08 robocane only for the built in one Mar 10 22:06:13 memorion: https://android.googlesource.com/platform/packages/inputmethods/LatinIME/+/master Mar 10 22:06:20 okay good - since I had an error installing it anyway! Mar 10 22:06:53 memorion: my edits are contained to this single file: https://android.googlesource.com/platform/packages/inputmethods/LatinIME/+/master/java/src/com/android/inputmethod/latin/LatinIME.java Mar 10 22:07:23 also, i've been thinking of getting more familiar with my dual booted Linux Mint partition, - im assuming everything plays nicely on Lin Mint? Mar 10 22:08:08 Hi, i am using this library for my navigation drawer :https://github.com/mikepenz/MaterialDrawer it works fine but when i click on the hamburger icon nothing happens, i can swipe from the left to get the drawer. How do i enable the hamburger icon to open the drawer ? Here is my code. http://pastebin.com/M7CZRJCp Mar 10 22:08:28 robocane: dunno about that one in particular, but you may need to add a usb filter. and not sure which versions have haxm / something equivalent (intel's haxm site has info on alternatives). but in principle afaik it all works. Mar 10 22:09:49 memorion: hmm still loading - ill give it some time, but maybe ill just use my phone to test progress of my first app Mar 10 22:10:11 robocane how powerful is the machine your using? Mar 10 22:10:42 quadcore AMD (albeit it older) 16 gigs of ram, SSD for just my os and few essential programs (which I have all android stuff on) Mar 10 22:10:54 also how large is the emulated device? trying to emulate a huge phone / tablet can take a shockingly long time without haxm. Mar 10 22:10:57 burmat downloading now, maybe it's easy the build it with gradle but I don't have too much hope Mar 10 22:11:04 it’s not Mar 10 22:11:07 don’t waste your time Mar 10 22:11:29 WAY too many dependancies.. I tried with gradle first and it through so many errors I just downloaded the entire branch Mar 10 22:12:00 but with that said, if you are able to do it I will probably be happy and hell Mar 10 22:12:08 as** Mar 10 22:12:11 haha, not and Mar 10 22:12:46 Fixed the problem. Mar 10 22:15:37 https://en.wikipedia.org/wiki/Wikimedia_v._NSA Mar 10 22:15:46 maybe not the right room for this, but: does anyone know why "ls" would fail with "ls: .: Invalid argument" ? if I go into a subfolder and "ls .." it works fine. Mar 10 22:16:05 was working fine, broke after finishing `repo init -u aosp-stuff`. Mar 10 22:18:29 burmat yeah, lots of erros but probably not impossible Mar 10 22:18:41 def not impossible, but a headache for sure Mar 10 22:21:10 burmat sorry, I'm giving up, but good look finding a solution! Mar 10 22:21:28 memorion: thanks, i really appreciate it Mar 10 22:21:43 Is it a requirement that everything posted on /r/Android be inaccurate? Mar 10 22:21:52 probably Mar 10 22:22:47 alright got it Mar 10 22:22:48 * /r/Andriod Mar 10 22:22:51 Get it? Mar 10 22:24:06 Man, it'd be so easy to make an awesome reddit client for Windows or something. Mar 10 22:24:13 So many keyboard shortcuts could be invented. Mar 10 22:24:25 TacticalJoke do it. univeral apps = WP, desktop Mar 10 22:24:41 and there is probably less competition too Mar 10 22:24:56 The thing is, the site is pretty good on desktop, so I'd have little motivation. Mar 10 22:25:03 Though it'd be cool to write apps for WP one day, maybe. Mar 10 22:25:06 reddit site is good ? Mar 10 22:25:07 lol Mar 10 22:25:19 it looks and acts like its from the early 90s Mar 10 22:25:20 Okay, it's not great. Just not as terribly awful as on Android. Mar 10 22:27:40 memorion: its painfully - im just going to try using my Moto X (physical phone) to test it - Have you ever done that before with a phone? I have enabled Dev options and usb debugging Mar 10 22:27:57 most people use devices to test and not emulators Mar 10 22:28:21 i wonder how emulator runs on my atom cpu nettop Mar 10 22:28:27 it shouldnt Mar 10 22:28:44 robocane if you're on window you might need usb drivers or something otherwise go for it Mar 10 22:28:45 Yeah, devices all day long. Mar 10 22:28:52 yep thats my roadblock now Mar 10 22:28:54 Most of the time I connect wirelessly to my device. Mar 10 22:29:06 apparently I need the usb drivers...i guess from Motorola if it matters Mar 10 22:29:18 Personally, I open the emulator only to check that my latest shenanigans still work on 5.x. Mar 10 22:29:55 Wow, what an idiot I am. An inner class of my fragment sent out an event that was listened for in that same fragment. Mar 10 22:30:32 That is, to stop my swiperefreshlayout from refreshing. i can just access it directly :p Mar 10 22:30:56 is there a way to read the original device orientation? is this a phone, or a chineese JXD-style? Mar 10 22:31:15 "original"? Mar 10 22:31:32 is it a phone? or a psp-clone Mar 10 22:32:33 hm. dunno. Mar 10 22:32:59 by some arguments there isn't one, since it's largely user-specified. e.g. tablets don't have a specific orientation, and they can be locked in any. Mar 10 22:33:24 why do you need to know? Mar 10 22:33:34 to swat accelerometer axises... Mar 10 22:33:37 *swap Mar 10 22:34:01 on my g19 they ok... on phones i need to swap roll and pitch Mar 10 22:34:02 cant you just get the current orientation Mar 10 22:34:19 i need roll+pitch for camera orientation Mar 10 22:34:39 getDisplay().getOrientation() ? Mar 10 22:34:42 i dont think default orientation matters Mar 10 22:34:44 just get the current Mar 10 22:35:01 s/getOrientation/getRotation/ Mar 10 22:35:10 I use NDK Mar 10 22:35:23 that doesnt matter? Mar 10 22:35:30 ¯\_(ツ)_/¯ JNI? Mar 10 22:35:35 glue Mar 10 22:35:51 i use ndk+sdk and vim as ide Mar 10 22:35:52 are you gradually shortening your sentences to provide us with less info about what you want Mar 10 22:36:17 translation: "I'm a masochist" D: Mar 10 22:36:29 no.. i am just old Mar 10 22:36:36 ctags at least? Mar 10 22:36:41 or something? Mar 10 22:37:28 I think my vim have some code highthights Mar 10 22:38:22 Anyone looking for paid work? I need a graphics designer and a mobile website developer, pm me Mar 10 22:38:42 quasist: I'd assume that either a) there's an NDK equivalent of Display (because it seems fairly important), or b) you can just use JNI. Mar 10 22:38:58 Kareesh: note the topic Mar 10 22:41:44 usually google releases something and lags providing release notes, this is the first i've seen them do the opposite Mar 10 22:42:02 groxx, NDK can vs Mar 10 22:42:07 I mean vim Mar 10 22:42:09 also support lib 22 doesn't fix any bugs ? Mar 10 22:42:42 and when you have 2 displays - cool to have vim on one, and logcat in other Mar 10 22:43:06 woah. Android Studio 1.2 FTW. collapsing a multi-line to a single line by deleting the left whitespace + hitting backspace one more time to kill the newline -> automagically adds spacing in front of my cursor to match my formatting prefs. Mar 10 22:43:29 groxx how is 1.2 ? Mar 10 22:43:43 g00s: marginally quicker? haven't done much with it yet. Mar 10 22:44:05 groxx reasonably stable for you ? Mar 10 22:44:13 I still have the "whole editor flashes white when scrolling" problem, so alas that's not solved Mar 10 22:44:27 g00s: too early to tell. superficially though, yes. Mar 10 22:44:31 who's enjoying AS 1.2 and SDK 22? Mar 10 22:44:32 API* Mar 10 22:44:32 groxx you on linux ? Mar 10 22:44:37 osx Mar 10 22:45:46 mac users are gay? Mar 10 22:46:03 ^^ wut? <_< Mar 10 22:46:10 some? not sure how that's relevant Mar 10 22:46:43 https://encyclopediadramatica.se/Apple Mar 10 22:47:38 well, guess who found his way into my ignorelist Mar 10 22:48:16 happy to be there Mar 10 22:49:05 the hell is this guy doing Mar 10 22:50:14 http://tools.android.com/recent/androidstudio12preview1 Mar 10 22:50:16 ive told myself im going to finish my app the past 4 nights, lets see if it comes true tonight Mar 10 22:50:24 go finish it then Mar 10 22:50:25 there is no more real changelog anymore Mar 10 22:50:43 pfn: do it for me please Mar 10 22:50:51 why Mar 10 22:50:59 adq: well, there's the intellij 14 + 14.1 changelog Mar 10 22:51:02 I charge $500/hr Mar 10 22:51:18 I have a view, and I want its background to be a circle with color #55FFFFFF, what would be the easier way ? should I draw a PNG img, or is it possible with drawable xml ? Mar 10 22:51:19 yeah this time because they switched to intellij14 Mar 10 22:51:23 adq, it's also an alpha release Mar 10 22:51:25 but what about AS and the issue in google code Mar 10 22:51:31 issueS sorry :3 Mar 10 22:51:32 sheit $500, might as well fix my fragments on my own Mar 10 22:51:33 pfn: can I reverse-hire you? code your stuff for you, for $500/hr? Mar 10 22:52:07 programers like whores... Mar 10 22:52:08 i'm cheaper 499$/hr Mar 10 22:52:12 ^ Mar 10 22:52:33 where 499$ is rupees? Mar 10 22:52:35 or rubles? Mar 10 22:52:38 :p Mar 10 22:52:41 >_< Mar 10 22:52:41 :) Mar 10 22:52:48 <--- russian Mar 10 22:52:50 ugh, seriously, what's the syntax for ignore command >_< Mar 10 22:53:13 depends on your client, most are /IGNORE nick Mar 10 22:53:16 mactards are bad IRC users Mar 10 22:53:24 Anybody have an idea on how to handle a CompositeSubscription, where an inner class (a scroll listener) has a reference to the sub and adds a subscription to it, even when I unsubscribe and create a new compositesub to attempt to stop that scrolllistener from subbing Mar 10 22:53:30 interesting, rupees and rubles are practically the same exchange rate Mar 10 22:53:39 so weird Mar 10 22:53:46 rupee is a zelda currency Mar 10 22:54:10 So even when I unsubscribe and create a new compositesubscription, my old scroll listener still has a reference to the new one and will add to it anyway Mar 10 22:54:18 zelda must be Indian Mar 10 22:54:31 link dies in majora mask Mar 10 22:54:39 YOU RUINED IT Mar 10 22:55:05 and he dies in beginning in the game Mar 10 22:56:20 g00s: my old scroll listener having a reference to the comp. sub. was the issue, but as usual the problem with android is you dont know the best way to solve it Mar 10 23:00:12 test Mar 10 23:01:43 Link dies almost every time I play any Link-related game. Mar 10 23:01:58 I did manage a 3-heart run of ocarina of time with only 1 death though :) Mar 10 23:02:23 textual looks good! No more Xchat! Mar 10 23:03:36 last TAS on OOT (18 minutes~) was hot Mar 10 23:04:50 I don't usually enjoy TAS :| though the mario reprogramming was impressive. Mar 10 23:08:07 test Mar 10 23:08:15 ok I guess it works Mar 10 23:15:32 anyoen knwo how to stop the keyboard from lagging the uI when animating views? Mar 10 23:15:45 view animates as keyboard is animating.. Mar 10 23:15:55 (besides butting a timer on it) Mar 10 23:16:06 any obscure tricks? Mar 10 23:18:29 tricknology: I wish. if you find one, let me know :| Mar 10 23:19:43 aah so you’ve seen the choppiness as well? This is happening on 5.0, I thought they “fixed” that Mar 10 23:20:26 they need project butter parts 2, 3, and 4 Mar 10 23:20:31 it could be that I just have too damn much going on.. adjusting layout params, animating 3 viewgroups, changing visibility, and rearranging focii Mar 10 23:20:41 ^^ Mar 10 23:21:09 i stayed on 4.4.4 - i keep reading lots of negative stuff about 5.0 and performance Mar 10 23:21:12 I might suggest trying some of the different windowSoftInputMode values though. if you can get away with a non-resizing layout (so no actual layout events while the keyboard appears), it might work? Mar 10 23:21:13 http://developer.android.com/guide/topics/manifest/activity-element.html#wsoft Mar 10 23:21:42 otherwise I assume the jank is coming from layout events + a bunch of redrawing Mar 10 23:22:46 g00s, your mind is gonna blow after you switch to 5.1 Mar 10 23:23:15 5.0 was for crash test dummies using nexus so i assume 5.1 is really 5.0 final Mar 10 23:23:30 love when you spend a couple hours getting somethig to work then a minor detail comes along and ruins the entire thing Mar 10 23:23:42 that plus the world couldn't possibly wait till March for the next Android version Mar 10 23:23:45 lasserix: aint that just the greatest Mar 10 23:23:56 groxx, My layotu doesn’t allow the view to auto resize when the keyboard comes up.. I am doing that manually Mar 10 23:24:00 g00s: I'm still on 4.4.4 with my Nexus 7 2013 too Mar 10 23:24:08 Well.. I’m not now and it’s still choppy Mar 10 23:24:15 yeah i have N7 2013 also Mar 10 23:24:23 lasserix, that’s right where I am now Mar 10 23:24:31 Also love when you spend lots of time improving something, then find there was a bug from before that could affect the improvement you just made but it seems to be working fine :P Mar 10 23:24:33 It skips in the same manner everytim Mar 10 23:24:49 g00s: and I don't leave it plugged in anymore, because you said it's causing battery to die Mar 10 23:25:05 shmooz yeah ... don't let it get below 40% though Mar 10 23:25:10 Or when you spend lots of time redesigning a UI and you have a meeting and they go and change everything Mar 10 23:25:33 g00s: that's about what I do :) Mar 10 23:25:39 shmooz hopefully at I/O they announce another budget nexus tablet Mar 10 23:25:44 is the android:onClick tag more efficient that setting onClickListeners or is it the same? Mar 10 23:26:01 BY PANTECH! Mar 10 23:26:11 that’s a good question, DadFoundMy Mar 10 23:26:12 g00s: I don't know, everyone is saying 'tablets are dead' Mar 10 23:26:23 schmooz, depends on the market Mar 10 23:26:34 well yeah if phones are 6", 7" is kinda hmmm Mar 10 23:27:17 DadFoundMy, should be the same since it would be compiled into the same code(??) Mar 10 23:27:36 g00s: will it go to 5.1 from 4.4.4 using OTA ? Mar 10 23:27:52 Afzal: thats what i was thinking, but im going to search it Mar 10 23:27:54 g00s I'm hoping for a really nice cheap small Huawei Nexus phone Mar 10 23:28:23 google forgot that Nexus was supposed to be cheap with the Nexus 6 Mar 10 23:28:27 a new nexus 5 would be awesome even though im not up for a new phone for a while and i love my m8 Mar 10 23:28:33 shmooz oh i don't know , i hope i dont have to go from 4 > 5 > 5.1 :| Mar 10 23:28:44 shmooz: to be fair nexus's havent been like that forever Mar 10 23:29:02 only really the toro, 4, and 5 were cheap Mar 10 23:30:19 Samsung S6 is gonna be sweeeeet Mar 10 23:30:23 for anyone whose curius android:onClick and onCLickListener have the same performance and are compiled the same way: http://stackoverflow.com/questions/21319996/android-onclick-in-xml-vs-onclicklistener Mar 10 23:30:24 DadFoundMy: I would assume it's marginally less efficient, since it has to use reflection to find the method on your activity. in code doesn't have to do that. Mar 10 23:30:50 groxx: good point but i bet its nothing noticable Mar 10 23:30:58 exspecially in terms of android Mar 10 23:31:01 no, very likely not Mar 10 23:31:45 I wanna get ahold of that MST Mar 10 23:32:15 as far as the xml-compilation: it compiles them into a more efficient binary format, but it's still interpreting things at run-time. there's overhead, but also likely not noticeable. Mar 10 23:34:46 DadFoundMy, they're not compiled the same way Mar 10 23:35:12 pfn: in what way are they different? Mar 10 23:35:20 does anyone know if there's a way to mark a class as "requires APIvX"? I mean specifically _not_ @TargetApi, since that doesn't show lint warnings when accessing from non-@TargetApi methods. Mar 10 23:37:02 DadFoundMy, and android:onClick is very bad practice Mar 10 23:37:02 DadFoundMy, why would you trust a random stackoverflow? Mar 10 23:37:02 and yeah, guy's answer is wrong Mar 10 23:37:07 DadFoundMy, android:onClick uses reflection, no compile Mar 10 23:37:31 DadFoundMy, some java basics Mar 10 23:37:38 why is it bad practice? A lot of the google tutorials use it Mar 10 23:37:52 google tutorials? Mar 10 23:38:08 google android tutorials Mar 10 23:38:09 it fucks up reusability, it's loosely typed with no compile-time safety Mar 10 23:38:32 what google tutorials point out using android:onclick... anyway, tutorials are never examples of best practices Mar 10 23:39:37 I'll use onClick if I'm not setting anything else on the button, keeps the code clean and no findViewById... Mar 10 23:39:52 pfn: http://developer.android.com/guide/topics/ui/controls/pickers.html Mar 10 23:40:00 shwoing the time picker Mar 10 23:40:40 yteah, tutorials suck Mar 10 23:40:44 hehe Mar 10 23:41:11 DadFoundMy, I have to agree with pfn here : tutorials don't mean best practice. Mar 10 23:41:29 A tutorial is meant to teach you a concept Mar 10 23:41:54 I agree and am in no place to defend anything having to do with the android sdk here Mar 10 23:42:11 will probably do some more research to see if its bad practice in all cases Mar 10 23:42:38 It's not. Mar 10 23:42:46 for readability sake it seems like bad practice because there can be onClick functions you dont really see right away Mar 10 23:42:56 The thing is to get all the information and make your choices Mar 10 23:43:22 DadFoundMy, not really, the onClick method is still there... Mar 10 23:44:01 MikeWallaceDev: true, but if you have a large class that might not be onvious right away, of course some good comments will fix that Mar 10 23:44:28 how would it be obvious by not using onClick?? Mar 10 23:44:59 you could use a butterknife @onclick Mar 10 23:45:10 MikeWallaceDev: keeping all listeners together. For example in most of my activities i have a helper method setListeners() where i set all my listeners Mar 10 23:45:16 pfn brought up some good examples of when not to use onClick, readability isn't one of them... Mar 10 23:45:44 DadFoundMy, I put all my onClicks together... even steven :D Mar 10 23:46:00 touche :D Mar 10 23:46:07 MikeWallaceDev: you soley on onClick? Mar 10 23:46:11 *use Mar 10 23:46:12 nope. Mar 10 23:46:21 I make choices. ref above Mar 10 23:46:22 :) Mar 10 23:46:47 hey guys can anyone help me with the MediaCodec Encoder/Decoder? http://developer.android.com/reference/android/media/MediaCodec.html Mar 10 23:46:59 If I'm not setting anything else on my button, just the listener, then I will use onClick. Mar 10 23:47:16 <_genuser_> hello people. Mar 10 23:47:17 but that's me. Mar 10 23:56:44 ginhinio: I think you've been asking in here for a bit? what's the problem, and would checking the ExoPlayer source code be relevant? https://github.com/google/ExoPlayer Mar 10 23:58:18 groxx: yeah there are not too many people who have acomplished this Mar 10 23:59:02 I don't think exoplayer has sample code of encoding tho Mar 10 23:59:08 that's the hard part Mar 10 23:59:36 ginhinio: what's the problem that you're having though? Mar 11 00:00:48 I just can't get the ecoder to work I've tried everything. all code on the web is broken in some way. Mar 11 00:01:26 encoder* Mar 11 00:02:20 So according to the docs ive read so far, fragments should never talk to each other directly, but rather interact via their activity. Fair enough, but in my code this is turning into a lot of "proxy functions" in my activity that dont really do much but call another function. ie: http://pastie.org/10017282 Mar 11 00:02:27 is this really the recommended way? Mar 11 00:02:43 surely there must be cleaner design pattern Mar 11 00:04:05 groxx: Mar 11 00:04:19 bane of my existence: - Invalid layout param in a LinearLayout: layout_alignParentRight Mar 11 00:04:26 why can’t it be? :( Mar 11 00:05:20 oops. asked my question and then got d/c'd not sure if it actually showed up. Hope it's ok to repost Mar 11 00:05:21 So according to the docs ive read so far, fragments should never talk to each other directly, but rather interact via their activity. Fair enough, but in my code this is turning into a lot of "proxy functions" in my activity that dont really do much but call another function. ie: http://pastie.org/10017282 Mar 11 00:05:25 ginhinio: "can't get it to work" isn't anything anyone can build off though. do you have error messages? what are you trying to encode, into what format? Mar 11 00:05:29 is this really the recommended way? Mar 11 00:05:48 tricknology: that's a RelativeLayout attribute only, that's why Mar 11 00:06:18 it's ok when there are one or two, but getting a lot of these "proxy functions" is cluttering my activity Mar 11 00:06:26 I know it is, groxx, but it would be nice if I could get those attrs in LinearLayout Mar 11 00:06:38 so I could use weight as well Mar 11 00:06:39 tricknology: layout_gravity="right"? Mar 11 00:06:53 most viewgroups can do gravity. Mar 11 00:07:06 pretty sure I tried that.. Mar 11 00:07:18 (like 90% of RelativeLayout code I've seen can be handled with a FrameLayout :\ ) Mar 11 00:07:57 I should really use a framelayout Mar 11 00:08:09 I have such a mess of views that all just happened Mar 11 00:08:22 pickleball_: in a way. the main reason is that fragment _changes_ are asynchronous. so if you do any kind of call directly between fragments _assuming_ that fragment B is in a particular state, you may be surprised. Mar 11 00:08:35 pickleball_: if your layouts are static, I'd say meh, just call directly. it's a lot of boilerplate. Mar 11 00:08:36 happens when you don’t know what your UI is going to look like before you begin.. Mar 11 00:08:52 Why is my app crashing and logcat giving me a one line stack trace? Mar 11 00:09:12 How are names for libs chosen? I'm getting "java.lang.UnsatisfiedLinkError: dlopen failed: could not load library "/home/james/Projects/EmbeddedExample/app/src/main/obj/local/armeabi-v7a/libcompany-nlp-sdk.so" needed by "libmaluuba-dialogue-jni.so"; caused by library "/home/james/Projects/EmbeddedExample/app/src/main/obj/local/armeabi-v7a/libcompany-nlp-sdk.so" not found" . Obviously it should be looking for that in ./ - how do I change Mar 11 00:09:14 that? Mar 11 00:09:23 tricknology: yeah, and then your existing code has a kind of momentum on its own, and it's hard to hit delete :( Mar 11 00:09:51 lol, what worked is wrapping the button in a relativelayout and setting the relativelayout’s gravity to right.. then setting layout_alignParentRight=“true” in the child (button) Mar 11 00:10:04 grozz, exactly Mar 11 00:10:07 :S Mar 11 00:10:19 groxx* it would take another day jsut to fix that. Mar 11 00:10:23 wrapping a single button in a relative layout? Mar 11 00:11:51 screw framelayout, AbsoluteLayout FTW ! Mar 11 00:12:00 groxx: yeah sure http://pastebin.com/LzZ2aYkV right now I get a IllegalStateException Mar 11 00:12:10 that I also have no idea how to fix Mar 11 00:12:14 lol Mar 11 00:12:44 on line 84 and 85 Mar 11 00:15:09 ginhinio: IllegalStateException makes it sound like a) the encoder has a state machine behind it, and b) you're not following its rules correctly. Mar 11 00:15:47 groxx hmm I see Mar 11 00:16:05 but what about the rest of the code Mar 11 00:16:09 is that correct? Mar 11 00:16:36 ginhinio: http://developer.android.com/reference/android/media/MediaCodec.html describes the sequence Mar 11 00:16:46 ginhinio: at the very least, it seems like you're not calling .start() on the encoder Mar 11 00:17:17 IllegalStateException is just a generic error that people use Mar 11 00:17:24 it's unlikely to be tied to a specific state machine Mar 11 00:17:35 JesusFreke: yeah, but with codec engines? Mar 11 00:18:07 Back again. hopefully on a more stable connection this time. Sorry groxx I appologize if I am asking you to repeat yourself, but when you were talking about the fragments being in potentially different states, were you refering to the states of the fragment lifecycle oncreate, oncreateview, etc? Mar 11 00:18:30 and the framework tends to use it with state machines, I don't encounter them very often elsewhere. Mar 11 00:19:50 picklefail: the lifecycles should be predictable, but _what_ fragments exist (and are actually visible on screen) can be difficult to guarantee if you're changing them at runtime. personally, it feels to me like that's the reason they recommend not calling between fragments directly. Mar 11 00:21:06 ah, ok, but if my application has a single activity, and always shows two specific fragments, it is safe to let them call each other? Mar 11 00:22:53 picklefail: yeah, probably. as far as I'm aware, "static" fragments like that should work like you expect - if you have one, you have both (though if you try to call between them in e.g. onCreateView, one will be created before the other. so don't do that.). BUT fragments complicate things - I hope it's that simple, but verify it yourself. Mar 11 00:23:35 groxx. indeed. thanks. Mar 11 00:23:43 picklefail: If they are always inside the same activity, yes, although you might want to consider having them talk to each other through the containing activity. Just don't make them static. Mar 11 00:24:33 yeah, I should probably not use the word static :) "non-changing" fragments. Mar 11 00:24:59 like, you're not swapping fragments in and out at runtime. Mar 11 00:25:02 CedricBeust: thanks. Did you happen to see my original question? I just find my main activity is filling up with clutter of "proxy functions" and am wondering if there is a cleaner way to construct my app Mar 11 00:25:18 groxx: yep. understood Mar 11 00:25:31 groxx: it now just crashes the app with no error Mar 11 00:25:35 if I have a camera app where it has a camera preview and then shows the image taken, does it make sense for me to have a camera preview activitiy and and image showing activiy? or should I just change the image view in the “camera activity’ when the image is taken? Mar 11 00:25:57 whats the best object to save a time from a TimePickerDialog? Time or Calendar, or netiher? Mar 11 00:25:58 picklefail: an alternate approach is to use an event bus of some kind. it has plusses and minuses, but at least it means little / no Activity boilerplate. Mar 11 00:25:59 picklefail: No I didn't see that question Mar 11 00:26:56 groxx: ok great. that'll be something for me to look into. ive never used one before Mar 11 00:27:24 picklefail: Otto is a pretty common one around here, reasonably simple to set up too. Mar 11 00:29:02 Oh yeah. sounds familiar actually. I'll start there. Mar 11 00:29:29 groxx: oh wait no still illegalStateException after the encoder.start() Mar 11 00:29:49 ginhinio: what's the full stack trae? Mar 11 00:31:14 groxx: http://pastebin.com/Y259ax0p Mar 11 00:41:40 ginhinio: dunno. I assume you're calling encoder.start() before .getInputBuffers()? seems like it's probably being used correctly, but I'd have to dive into it a lot deeper than I can do right now :\ Mar 11 00:42:10 yeah I'm calling encoder.start() before getInputBuffers Mar 11 00:45:08 aauw :/ I've been stuck on this for like 2 weeks Mar 11 00:46:36 ginhinio: do you know if it matters that it's created on a different thread than it's started on? Mar 11 00:47:35 groxx: no I don't I'm really new to java Mar 11 00:48:54 do you guys see support lib 22 in sdk manager ? Mar 11 00:48:57 ginhinio: seems like ya picked a hard project to start on with a new language :| Mar 11 00:50:28 g00s: nope. 22 sdk and build tools, but no support lib update Mar 11 00:50:33 yeah It's not really for learning purposes tho It's just that I've been left to do a part of the project I'm not specialized in Mar 11 00:50:48 groxx huh weird, somebody on reddit said they had it Mar 11 00:51:22 ginhinio: tbh I'd probably start by doing it all on the same thread. _generally_ things aren't threadsafe unless they specifically state that they are. Mar 11 00:51:55 hmm alright Mar 11 00:52:13 ginhinio: also, might help to read the source, find out where those errors are coming from: Mar 11 00:52:13 http://androidxref.com/5.0.0_r2/search?q=&defs=MediaCodec&refs=&path=&hist=&project=abi&project=art&project=bionic&project=bootable&project=build&project=cts&project=dalvik&project=developers&project=development&project=device&project=docs&project=external&project=frameworks&project=hardware&project=libcore&project=libnativehelper&project=ndk&project=package Mar 11 00:52:13 s&project=pdk&project=prebuilts&project=sdk&project=system&project=tools Mar 11 00:52:16 whups. Mar 11 00:52:26 http://is.gd/c1yTfU Mar 11 00:52:26 wow what was that :) Mar 11 00:52:47 apparently it adds a ?project= for each AOSP sub-project selected :| Mar 11 00:53:32 gotta get out of the habit of cmd-v + immediately hit enger. Mar 11 00:53:35 lol groxx grepcode :P Mar 11 00:53:52 grepcode is pretty nice, yeah. but it also loads incredibly slowly D: Mar 11 00:54:20 also, does grepcode include the C files? /me does not remember Mar 11 00:54:39 * JesusFreke misses google code search :( Mar 11 00:55:12 JesusFreke there was google code search? I just use filetype now Mar 11 00:55:25 yeah, it was shut down a few years ago Mar 11 00:55:29 but it was awesome Mar 11 00:55:46 super fast searches over a huge corpus of open source apps Mar 11 00:58:10 ginhinio are you running this in an emulator by any chance? Mar 11 00:58:34 Afzal: no on my samsung phone Mar 11 00:58:53 g00s: huh. documentation for v22 won't install. don't suppose you've had that problem? Mar 11 00:59:52 5.1 is v22? oh dear Mar 11 01:00:39 this is the same question i asked 4 hours ago but i walked away from it, re-read the docs, and I'm freakin confused again. Mar 11 01:00:43 http://developer.android.com/guide/practices/screens_support.html Mar 11 01:00:44 ginhinio try catching the two exceptions in http://developer.android.com/reference/android/media/MediaCodec.html#start() Mar 11 01:00:55 Anyone know any good icon pack i can use for my app ( navigation drawer, settings, etc ) ? Mar 11 01:00:59 What I don't get is: is layout-sw720p-land considered valid ? Mar 11 01:01:27 CanyonMan, sure Mar 11 01:01:34 CanyonMan, and dp, not p Mar 11 01:01:41 oops yeah that was a typo Mar 11 01:01:43 how do you guys like joda-time? Mar 11 01:01:48 I LOVE JODA TIME Mar 11 01:01:53 It's a great library Mar 11 01:02:00 im about to try it out Mar 11 01:02:13 It's great for formatting, and it has nice wacky features Mar 11 01:02:20 Afzal: alright Mar 11 01:02:23 do you hold dates in their too or only times? Mar 11 01:05:05 oh wait Mar 11 01:05:22 is this 'available qualifiers' in the create new layout resource actually answreing this question for me by only letting me pick valid sthff? Mar 11 01:06:04 probably? Mar 11 01:06:43 It doesn't show 'smallestWidth' or 'swXXXdp' though as one of valid qualifiers. I can choose orientation though. Mar 11 01:07:09 oh yes it does Mar 11 01:07:11 wow i'm dumb Mar 11 01:07:13 aahahahahaa Mar 11 01:07:16 awesome sauce Mar 11 01:07:30 CanyonMan: :) I was just about to say "mine does", but yea. Mar 11 01:07:57 ok. Enlightment. Mar 11 01:08:01 CanyonMan: fwiw you can also just make the folder + file in the right location and it'll auto-detect it. Mar 11 01:08:24 sometimes complaining helps. Mar 11 01:08:50 I forget if it's joda time that does this, I have something on my xmpp bot that you can ask it "How many seconds until the day after easter in 2018" and it will tell you Mar 11 01:08:55 Maybe that's something on top of joda Mar 11 01:09:25 joda time plugs into jackson with spring amazingly too. Mar 11 01:10:56 so the one that's in 'layout' is just the default Mar 11 01:10:57 the one at the root Mar 11 01:11:35 I'm not really sure how big that one is for ... it seems to default to a portrait nexus 4 Mar 11 01:13:38 groxx hm didn't install docs, seems like offline mode didn't work well anyhow Mar 11 01:13:57 Square screens Mar 11 01:14:02 Who the hell has a square screen! Mar 11 01:14:13 face it, if you can't get to SO - its game over - so i see no point in having offline docs :D Mar 11 01:14:17 CanyonMan: yeah, I wonder if they're targeting the Blackberry Passport or something. Mar 11 01:14:23 CanyonMan: watches? Mar 11 01:14:23 I got my nexus player Mar 11 01:14:25 CanyonMan: though it's possible that's just for the watches Mar 11 01:14:27 at first i was like wow best thing ever Mar 11 01:14:30 but it's not very android like Mar 11 01:14:34 Maybe if it had a real launcher Mar 11 01:14:50 but out of the box it's kind of like a google salesman Mar 11 01:20:01 so last stupdi qeustion then i will shut the heck up about this Mar 11 01:20:07 when it starts up an activity Mar 11 01:20:13 it tries to find the layout that fits BEST Mar 11 01:20:22 then ONLY if it doesn't find one that fits better will it pick the one in just layout/ Mar 11 01:20:31 Is that right? so the one in 'layout' is really just the layout of last resort Mar 11 01:20:38 I have created a navigation drawer, but when i open click on a section inside a navigation drawer to open the activity i can't open navigation drawer from the new activity. Do i need to make a navigation drawer inside each activity ? This is the library : https://github.com/nightwalkerkg/MaterialDrawer and this is my MainActivity http://pastebin.com/52FCTtB0 Mar 11 01:21:25 this sounds silly, but how can I check to see if one object is an instance of a specific class? I thought instanceof was the ticket, but I think I'm using it wrong Mar 11 01:22:12 i.e. if (classA.getClass() instanceof classB)... Mar 11 01:22:36 instanceof is but Mar 11 01:22:44 you're not comparing objA instanceof classB Mar 11 01:22:53 You did a .getClass() Mar 11 01:23:03 you do: if ( someObject instanceof SomeClass ) Mar 11 01:23:10 gotcha Mar 11 01:24:39 http://stackoverflow.com/questions/3949260/java-class-isinstance-vs-class-isassignablefrom take a 15 sec glance at that too and stuff it in your noggin for future use Mar 11 01:24:44 CanyonMan: layouts: yep. layout/ is the last resort. Mar 11 01:25:27 CanyonMan: the same goes for all other resources, though specifically are "merged", in that the "find the best one" operates on the _name_, not the _file_. Mar 11 01:25:38 yeah Mar 11 01:25:45 CanyonMan: e.g. you can have raw-hdpi/, xml-land/, etc Mar 11 01:29:16 i guess i should support phones Mar 11 01:29:31 I already said i want 4.4 or later or forget it, because i want the chromium webview Mar 11 01:30:09 though you know maybe before i make that decision I hsould see how well my angular/d3 stuff works on the older webview Mar 11 01:36:24 ok so I found out how to change my font finally in Android Studio (since I thought the default wasn't readable) Mar 11 01:36:41 It seems it changed it for my Java, but my XML ones won't change Mar 11 01:36:48 Is that normal? Mar 11 01:36:52 Just set up AS on my macbook pro in yosemite, getting an error with the jvm and robovm, is that an issue resulting from using the apple JRE? Mar 11 01:38:15 robocane: afaik the "code" editor and the "xml" editor are actually separate components. tl;dr: yes. Mar 11 01:38:51 fafnir: what's the error? Mar 11 01:39:11 groxx: okay gotcha, is it possible to change it on the XML side? I see in the Settings There is Appearance > Colors and Fonts > Fonts == thats where I changed the font since there is a dropdown "Primary font Mar 11 01:39:48 groxx: and then I see under the Fonts at this level (Appearance > colors and fonts > fonts) there is a tab for "xml" but it's more about the coloring of the syntax, and no font option Mar 11 01:40:22 robocane: hm. maybe I'm just remembering from Eclipse. not sure. Mar 11 01:40:31 whoops, robovm is an ios thing, silly me Mar 11 01:40:39 i here does not equal square root of minus one!!! Mar 11 01:40:46 robocane: there's also an "appearance" thing (just search for "font") that has "override default fonts" that might work. I think that changes the UI elements though. Mar 11 01:40:55 sorry, wrong channel Mar 11 01:41:32 robocane: also, didja try setting a secondary font? Mar 11 01:41:46 i didn't since i figured that was if the font i chose didn't work Mar 11 01:41:55 which it seems like it did work since it applied to the java editor Mar 11 01:42:01 though I would expect that the main font thing would work. dunno. restart the IDE? Mar 11 01:42:34 hm you know what? i tried taht Mar 11 01:42:38 and it didn't work Mar 11 01:42:47 tried it again after repicking the font Mar 11 01:42:50 and it seemed to have done the trick Mar 11 01:43:31 magical fix? Mar 11 01:43:33 setContentView(R.layout.activity_home); <--- that's the part that picks which activity_home ? Mar 11 01:43:41 it always is. Mar 11 01:43:59 CanyonMan: yeah. there's quite a lot between that call and things appearing on screen, but it's in there. Mar 11 01:45:20 So I'm getting an error on a command that used to work fine Mar 11 01:45:31 It's a db.query(), but it's syntactically correct Mar 11 01:45:37 It errors when I run it. Mar 11 01:46:02 TechGeek01: with what error? Mar 11 01:46:06 If the error tells me the line number that failed, is there any way to find out more info on exactly what in the query went wring? Mar 11 01:46:15 With AS Mar 11 01:46:27 I refer you to our topic: http://imgur.com/jacoj Mar 11 01:47:24 hello? Mar 11 01:47:54 groxx: We're having a discussion ... on Imgur? Mar 11 01:48:02 So that guy (in that cartoon) has quite a unibrow. Mar 11 01:48:11 TechGeek01: :| there's more to the error message than just the line number that failed. what is it? Mar 11 01:48:36 Hang on a sec Mar 11 01:49:32 I should probably just start using "|:{" when people don't post stacktraces Mar 11 01:50:07 http://pastebin.com/S9DDGdps Mar 11 01:50:14 That's quite the unibrow, yes Mar 11 01:50:41 TechGeek01: `Caused by: android.database.sqlite.SQLiteException: no such table: settings` <- there's your problem Mar 11 01:51:18 Well dammit. I swear to God, I created that shit Mar 11 01:51:49 :) Mar 11 01:51:53 I was on a laptop at the time. Side scrolling on a touchpad on a 5 year old laptop that barely runs AS *cringe* Mar 11 01:52:26 the fact that a table is missing makes me think you've got a faulty onCreate / onUpgrade in your sqliteopenhelper? Mar 11 01:52:53 It was a fail on my part Mar 11 01:52:57 groxx can you confirm something for me in sdk manager? my list gets kinda corrupted Mar 11 01:53:17 I wrote all the shit to create it, I just failed to actually implement it Mar 11 01:53:27 g00s: ya Mar 11 01:53:44 groxx ok , open sdk manager. scroll to the bottom , you should see extras folder open Mar 11 01:53:55 yup Mar 11 01:54:04 ok scroll all the way to the top and open sdk 21 folder Mar 11 01:54:16 already open, if that matters Mar 11 01:54:19 then scroll back down ... my extras dissapears Mar 11 01:54:41 groxx really? api 22 is open by default, not 21 Mar 11 01:54:41 funky Mar 11 01:54:57 g00s: all folders where I have something installed are open by default Mar 11 01:55:12 ok , then just open up one that isn't and scroll to the bottom Mar 11 01:56:31 g00s: ah hah. if I scroll slowly, it does bite off the bottom elements Mar 11 01:56:58 i always find the craziest stuff Mar 11 01:57:40 that's a pretty good one :) Mar 11 01:57:41 i notice though, that the # of elements cut off == the number of elements in the opened folder Mar 11 01:58:05 its like the items in the widget is getting trampled Mar 11 01:58:31 g00s: yeah, I see the same thing. I'm only losing 6, but same behavior. Mar 11 01:58:46 so its not just me :D Mar 11 01:59:09 g00s: or I'm a figment of your imagination Mar 11 02:10:22 Why wouldn't a recyclerview item with height/width set to match_parent not take up all the space? Mar 11 02:10:42 Trying to get a progress bar to be centered vert/horiz. Mar 11 02:13:27 So I'm trying to .query a database table, and I'm saving the table lookup to a cursor Mar 11 02:13:43 weird proguard keeping a class that is not implementing Serializable Mar 11 02:13:56 If that cursor isn't null, it should have data, and I should be able to c.moveToFirst() on it Mar 11 02:14:01 but remove the line that keeps classes that implement Serializable fixes it :/ Mar 11 02:14:32 Apparently, when I do this with one particular table, it yells at me for trying to do c.getString(0) after I move to first Mar 11 02:15:21 Stacktrace tells me it's erroring because there is 0 length to take an index of 0 from, but if there is a length of 0, the cursor should equal null Mar 11 02:15:27 Should it not? Mar 11 02:17:28 Fixed it Mar 11 02:21:50 Hmm. Any guesses here? http://pastebin.com/rTCJhd0s Mar 11 02:22:21 Leaked window, alert dialog disappears as soon as it's created Mar 11 02:22:26 Not a fatal exception though Mar 11 02:23:38 Can someone take a quick look at my recyclerview item here: http://pastie.org/10017482 I want it to be displaying in the exact center of the entire recyclerview, not centereed in the top Mar 11 02:23:46 desmin88: I would think that recyclerview ignores match_parent for vertical, since it's essentially meaningless in that context Mar 11 02:24:30 hmmph Mar 11 02:24:45 if you only had one subview, it could make sense, but recyclerview is intended for multiple - how do you rationally handle e.g. 5 match_parent views at once, that should be laid out after each other? Mar 11 02:25:11 wtf proguard not keeping anything with serializable >_< Mar 11 02:25:20 desmin88: tbh I'd just hide / not create the recyclerview until you have the data. stick it all in a framelayout, and give the progress bar layout_gravity="center". Mar 11 02:26:18 so complicated for what should be simple shit Mar 11 02:26:27 that's awfully simple Mar 11 02:26:35 way simpler than recyclerview Mar 11 02:27:23 in an endless scroll it is difficult Mar 11 02:27:36 when i intend for this progessbar to be displayed also at the end of the list as new data is loaded Mar 11 02:27:41 or centered where there is none Mar 11 02:35:53 Does anyone know how I can turn on speakerphone through adb and not do it via a keyevent so it works on all android phones? Mar 11 02:37:04 i know I can navigate through the menu and do it, but id rather try to find a way to call it which I have been unsucessful in so far Mar 11 02:52:10 groxx, it is the only subview, so why isnt it matching to parent? Mar 11 02:52:55 desmin88: because the parent view controls that, not the subview? they could build that in, sure, but it would increase the complexity of the LayoutManager. **** ENDING LOGGING AT Wed Mar 11 02:59:58 2015