**** BEGIN LOGGING AT Fri Dec 19 02:59:59 2014 Dec 19 03:00:23 i wouldn't make my cat wear it all the time but Dec 19 03:00:25 that's cool Dec 19 03:01:10 ahh Dec 19 03:01:13 someone already did it! http://www.gizmag.com/one-fast-cat-exercise-wheel/32962/ Dec 19 03:01:22 my dad and i were actually going to do that one Dec 19 03:01:56 heh Dec 19 03:02:41 cool next pay check Dec 19 03:05:42 amazing 250 for one looks super easy to diy Dec 19 03:08:36 It's hard to find colours that go with black, grey, and white. ;| Dec 19 03:08:57 olive Dec 19 03:08:57 If the background is (almost) black, that is. Dec 19 03:10:49 TacticalJoke: http://www.google.com/design/spec/style/color.html Dec 19 03:11:03 also look at fonts Dec 19 03:11:14 they have recomendations for using alpha channel Dec 19 03:11:22 Thanks. I'd forgotten all about that. Dec 19 03:17:22 TacticalJoke: http://www.materialui.co/colors Dec 19 03:20:36 This too: http://www.materialpalette.com Dec 19 03:20:50 (not very useful for your black background problem tho) Dec 19 03:21:52 So, if I want to introduce a little colour to my dark theme, can I just pick and choose there? Dec 19 03:21:58 If I want to introduce blue, say. Dec 19 03:22:02 Just pick from the blues? Dec 19 03:25:08 idea is you pick primary Dec 19 03:25:15 then darker complement Dec 19 03:25:26 but in reality just pick something off that that you like Dec 19 03:25:33 unless you are going for material theme Dec 19 03:26:30 I'll probably end up using something material-like. Dec 19 03:26:43 I actually like YouTube's new look. First "material" app I just like the look of. Dec 19 03:27:58 so I'm starting a new app. I wonder which API versions to target? Dec 19 03:27:58 wow this eprof tool looks cool Dec 19 03:27:59 http://mobileenerlytics.com/eprof.php Dec 19 03:28:09 dale 4.0 and up Dec 19 03:28:13 I'd rather not screw around with the support library Dec 19 03:28:21 4.0 and up Dec 19 03:28:24 will I need it for ICS and newer? Dec 19 03:28:24 RustyShackleford: Math.min(15, desiredTarget); Dec 19 03:28:32 you'll probably want the compat library tho Dec 19 03:28:35 yeah Dec 19 03:28:45 Wait, that should be Math.max. Dec 19 03:28:52 maybe it's not confusing like it was in the past Dec 19 03:29:20 I remember needing to write different code if you're using the support library, versus when you don't include the support library Dec 19 03:31:32 the main flaw of all blogs is the lack of archive site index, just a simple list of titles Dec 19 03:31:42 RustyShackleford: nah its much better Dec 19 03:31:49 RustyShackleford: how did you last app go? is it in the store? Dec 19 03:32:13 no i never released it Dec 19 03:32:33 ph :( Dec 19 03:32:35 it was mostly just an experiment. It needed some polish before I'd release it Dec 19 03:32:37 give up? Dec 19 03:32:38 ahh Dec 19 03:32:44 i know that Dec 19 03:32:51 so it would tell you when the trains for my city will arrive Dec 19 03:32:54 buit now you are back with another billion dollar idea? Dec 19 03:33:02 then the city made a mobile site that was much nicer than my ap Dec 19 03:33:06 RustyShackleford: If you target 15+, you should be okay, I think. Dec 19 03:33:30 lasserix_: my city has a ton of speed cameras and red light cameras. I'm going to warn drivers Dec 19 03:33:52 i probably won't charge anything. I'd rather have people use it Dec 19 03:34:02 and personally, I never buy android apps Dec 19 03:35:32 heh Dec 19 03:43:47 RustyShackleford i'm one step ahead - i don't even download android apps :) Dec 19 03:44:25 r0adkll, if only everyone versioned properly, it's still a bad practice, inconsistent builds with behavior changing from one build to the next, is bad Dec 19 03:48:30 TacticalJoke: feature you got to include i 1.0 http://www.reddit.com/r/androiddev/comments/2pmumz/i_want_an_app_that_reads_out_loud_the/ Dec 19 03:49:02 damn, leaving my device plugged in for the last few months seems to have fucked its battery Dec 19 03:55:54 Oh, gawd, what an idea. Dec 19 03:56:02 i wish all these devices had a preference that let you specify a range to charge the battery Dec 19 03:56:04 Being woken up to Reddit post titles. Dec 19 03:56:11 like keep it in 40% - 80% range Dec 19 03:56:17 Yeah, my laptop has that. Dec 19 03:56:20 I don't let it go over 80%. Dec 19 03:58:17 Why did you leave it plugged in for months? Dec 19 03:59:02 i dont use my android device for anything but dev, so its just plugged into the computer. my carry device is a lumia 521 Dec 19 03:59:32 why does the android sdk take so damn long to download Dec 19 03:59:45 i grabbed only like 15 packages Dec 19 03:59:51 you kids with your fast speed connections are so impatient Dec 19 03:59:53 been running for over an hour Dec 19 04:00:43 i can download a Steam game in like 40 mins Dec 19 04:00:55 but this is maxing out at 50 KiB/s Dec 19 04:00:56 Android likes you to feel the pain from the beginning. Dec 19 04:01:07 A gentle introduction. Dec 19 04:01:27 I'm kidding; it's not *that* bad. Dec 19 04:01:38 It's probably way less bad than when you last did Android stuff. Dec 19 04:01:50 g00s: is the battery replacable ? Dec 19 04:01:51 i read an article about performance once. it was saying that users don't mind slow processes as long as the whoel process is slow. Inconsistencies create frustration Dec 19 04:02:04 shmooz 2013 n7 :( Dec 19 04:02:29 there are kids in africa that have to wait an hour for a picture to load, now stop your whining! Dec 19 04:02:48 lasserix: Did you notice how there's not one colour in my app? lol Dec 19 04:02:52 Apart from the icon. Dec 19 04:03:30 g00s: the battery is pretty easy to replace on a N7 2013, youtube has demos Dec 19 04:04:17 g00s: btw I have the same device and leave it plugged in most of the time Dec 19 04:04:33 I hate leaving my phone plugged into my computer. :/ Dec 19 04:04:40 I haven't noticed a big drop in battery yet, but I hardly use it enough to Dec 19 04:04:43 It's my day-to-day phone. Dec 19 04:05:37 shmooz interesting, it doesn't look like you can take it apart but ok, good to know. i notice when i read a kindle book today. barely got through it Dec 19 04:06:03 g00s: yeah it's one of the easiest devices to do that with Dec 19 04:06:23 the back pops out and the battery is not soldered in, so you can just yank it out Dec 19 04:06:46 well there is a cable plugged into the battery that you have to pull out Dec 19 04:10:34 "Gently insert a plastic opening tool" Dec 19 04:10:44 gonna have to buy one of those :) Dec 19 04:11:12 once it popped off when I was trying to remove the gel tpu case off it Dec 19 04:11:27 it's very easy to open the back Dec 19 04:11:49 i found guides for the first n7, i'll look a little more for 2nd gen Dec 19 04:12:30 lasserix: Adding a view type for "load more comments" seems to have helped performance a little. Dec 19 04:12:50 Which would be understandable (since they have a static height, in practice). Dec 19 04:13:27 Though it could simply be the placebo effect. Dec 19 04:18:29 I don't know what to call something. In a Reddit comment listing, you get comments and those "load more comments" things. I'm calling the former Comments and the latter Placeholders. Dec 19 04:18:41 Since I have to hold onto these things (e.g., in a List), I've created a supertype CommentOrPlaceholder. Dec 19 04:18:46 But it's ugly. lol Dec 19 04:19:05 I guess I should just invent a term. Dec 19 04:19:16 call it a fwhugugad Dec 19 04:19:35 TacticalJoke: https://www.youtube.com/watch?v=s-WTbGupxbk Dec 19 04:20:01 Or perhaps I could create an Either type à la Haskell. Dec 19 04:20:01 FFS, this download isn't done yet? Dec 19 04:20:52 MJCD: I don't know what that is. ;o Dec 19 04:21:34 I'm unable to understand this version http://developer.android.com/reference/android/os/Message.html#obtain(android.os.Handler, java.lang.Runnable) Dec 19 04:22:16 shmooz this looks like a serious pain ! https://www.youtube.com/watch?v=IG6A_RBX-v0 Dec 19 04:22:27 212 n7 seemed easier Dec 19 04:22:27 It called the runnable, not the Handler.handleMessage when I do msg.sendToTarget or even handler.sendMessage(msg) Dec 19 04:23:39 I guess I could use CommentListingItem (Comment, Placeholder). Dec 19 04:24:02 Calling something CommentOrPlaceholder is ridiculous. Dec 19 04:24:16 g00s: it could be worse, on other's the battery is soldered in Dec 19 04:25:43 shmooz do you trust any places to do the repair for you ? Dec 19 04:26:06 lol Dec 19 04:26:08 if you are paying for it Dec 19 04:26:09 g00s: yes, there are some small corner stores here that have experienced people Dec 19 04:26:13 and they are a registered business Dec 19 04:26:14 if they fuck it up Dec 19 04:26:16 you can sue them Dec 19 04:26:18 so... Dec 19 04:26:37 Suing takes a lot of time, effort, and money. Dec 19 04:26:48 shmooz: just take it to one of those small cell phone stores where they fix stuff too Dec 19 04:27:02 hello me, its me again :) Dec 19 04:27:14 oops Dec 19 04:27:31 no Dec 19 04:27:35 the point isnt that you have to sue them Dec 19 04:27:37 caused by: shmoozOverflowException Dec 19 04:27:39 the point is, because you can Dec 19 04:27:40 TacticalJoke: RootComment and ExtendedComments or something Dec 19 04:27:42 they have insurance ;) Dec 19 04:27:42 yeah I meant g00s Dec 19 04:28:32 g00s reverse deposit: they fuck up your device you have the cash to get anew one ;p Dec 19 04:29:17 shmooz sounds like you just get an event triggered when the message is handled Dec 19 04:29:54 MJCD: That doesn't always work out in real life. Dec 19 04:30:03 TacticalJoke: it really does. Dec 19 04:30:17 its kind of the whole point of consumer protection laws. Dec 19 04:30:28 the only thing is if they arent really a registered business. Dec 19 04:30:31 which does happen. Dec 19 04:30:36 but is easy enough to check Dec 19 04:30:49 and if they lie or misrepresent themselves in any way, that's fraud. Dec 19 04:31:00 so you don't really need to check into it any more than what they tell you Dec 19 04:31:03 or how they appear Dec 19 04:31:05 There are countless cases of people being messed around with by registered businesses and having little or no way to respond. Dec 19 04:31:28 There's a TV show over here Watchdog that tries (and often fails) to help people like that. Dec 19 04:31:33 and there's avenues to resolve such things. you can only go so far with legal protections. Dec 19 04:31:46 like Download.com owned by CNET Dec 19 04:32:02 they add little trojans to everything downloadable there Dec 19 04:32:20 Yeah, that used to be legit. Not sure what happened. Dec 19 04:32:27 uhh Dec 19 04:32:30 there's not trojans.. Dec 19 04:32:33 there's adware Dec 19 04:32:36 very different. Dec 19 04:32:55 yeah Trojans by a registered corporation = adware Dec 19 04:33:09 the core difference being you consent to adware being installed and they dont really do anything except present you with ads Dec 19 04:33:24 where as trojans are actually malicious Dec 19 04:33:31 and without consent Dec 19 04:33:38 if you don't like it, don't use it. that's your choice. Dec 19 04:33:39 more like they prey on you to not read of the Installation dialogs and hit Next Dec 19 04:33:56 lol "OH NO I CANT PROTECT MYSELF SO THUS THEY ARE BAD" Dec 19 04:34:01 grow up. Dec 19 04:34:15 no, you and them need to grow up Dec 19 04:34:20 "I SHOULDNT HAVE TO DO ANYTHING FOR MYSELF" Dec 19 04:34:25 "PLEASE BIG BROTHER PROTECT ME" Dec 19 04:34:30 "BUT DONT INVADE MY PRIVACY" Dec 19 04:34:32 lol Dec 19 04:34:34 its going to be okay Dec 19 04:34:55 I'm guessing we have a teenager in the room. Dec 19 04:35:00 channel Dec 19 04:35:08 ^ Dec 19 04:35:21 MJCD: that would be you Dec 19 04:35:43 heh. Don't you have some lack of protecting yourself when consenting to legal agreements to be doing somewhere? Dec 19 04:36:10 "I DONT UNDERSTAND HOW LEGAL AGREEMENTS WORK SO THUS YOU ARE A TEENAGER" Dec 19 04:36:16 yeah we all read the small writing when installing stuff right ? Dec 19 04:36:17 Seems legit. Dec 19 04:36:29 how stupid of me Dec 19 04:36:34 Small writing? Its usually a screen that shows you whats being installed, with screenshots, dedicated only to that purpose. Dec 19 04:36:40 They aren't allowed to hide it in the EULA Dec 19 04:36:49 everyone falls for that Download.com stuff and then they call me to go clean their computers Dec 19 04:36:58 "Everyone" Dec 19 04:37:05 just about Dec 19 04:37:07 MJCD: Weird how you went from "The legal system (big brother) will protect you" to "Lawl; you guys want big brother to protect you!!!". Dec 19 04:37:23 TacticalJoke: Consumer protection is very different. Dec 19 04:37:26 Because you go to them. Dec 19 04:37:43 He is essentially wanting the government to police the actions of private enterprise proactively. Dec 19 04:37:51 "No, don't run your business like that. Run it how we say." Dec 19 04:37:58 "Because people can't protect themselves." Dec 19 04:38:07 This is entirely against the purpose of responsible government Dec 19 04:38:17 yeah, you should have better protection from corporations, it's all your fault Dec 19 04:38:31 Infact half the population is up in arms about exactly such interference in their personal lives. Dec 19 04:38:49 so... no answer ? :P Dec 19 04:39:00 every individual no matter how naive or young , should know how to protect themselves by reading tiny writing that was meant to be hidden Dec 19 04:39:07 shmooz: Right. When you see a screen "Do you want to install the ask toolbar?" and it makes you click yes.. That's on you. Dec 19 04:39:19 with a font size of 6 pts Dec 19 04:39:35 ... Your hyperbole is extraordinary. Dec 19 04:39:42 I'm out of this discussion. Dec 19 04:39:51 can you lot take it elsewhere, please Dec 19 04:39:56 that means you read all the agreements and policies in softwares ? Dec 19 04:40:00 i just click checkbox and click OK Dec 19 04:40:12 ya elsewhere :D I've an android question! Dec 19 04:40:33 MJCD: the fact is, majority of people get sent to download.com when they want something, and majority are furious when that something that was supposed to be fine if they got it elsewehere is behaving very much like a trojan with ads Dec 19 04:41:06 Nobody reads the small-print. Dec 19 04:41:15 Blaming people for not reading the small-print is dumb. Dec 19 04:41:21 and they trust a big corporation like CNET to not behave that way Dec 19 04:41:31 http://malwaretips.com/blogs/wp-content/uploads/2013/01/ask-installer.jpg Dec 19 04:41:32 Even if everyone read it, almost nobody would understand it. Dec 19 04:41:37 ^^ The supposed "small print" Dec 19 04:41:42 We aren't talking EULA's here. Dec 19 04:41:45 Get a grip. Dec 19 04:42:54 shmooz do you think i could send it to asus for a new battery ? Dec 19 04:43:10 g00s: I bet if you asked nicely, they'd do it Dec 19 04:43:20 well, even if i had to pay Dec 19 04:43:21 why bother if you're just going to leave it plugged in all the time ? :P Dec 19 04:44:50 bankai_au I got lazy, usually i leave it unplugged Dec 19 04:47:54 hey, got some quesitons regarding espresso if anyone has a min Dec 19 04:48:16 i dig that espresso is event drive, so i dont have to use robotium's waitFor…() etc. but how do i integrate that with wanted to test the state of other things? Dec 19 04:48:40 like say i want to click around on my app, and along the way make sure that some analytics were sent Dec 19 04:48:48 espresso makes the clicking and view assertions super easy Dec 19 04:49:06 but righ tnow all i can do is just sleep and wait, checking the analytics manager until i see the analytic pop up Dec 19 04:49:20 event driven* Dec 19 04:54:04 Hmm, I don't understand this. For every Adapter.getView call my ListView makes, it makes *two* Adapter.getItemViewType calls. Dec 19 04:54:10 One before getView; the other fater. Dec 19 04:54:12 after* Dec 19 04:54:38 And it's not my code causing the second call. Dec 19 04:54:46 i did it Dec 19 04:55:56 All for the same position. Dec 19 04:55:58 What's going on? Dec 19 04:56:22 maybe its obsessive compulsive :) Dec 19 05:01:05 I wonder anyone interested in developing Android using CLI Dec 19 05:01:06 ? Dec 19 05:01:09 TacticalJoke: its looking in the pool Dec 19 05:01:12 its creating from scratch Dec 19 05:01:13 what's a good public site for posting apk's to show someone ? Dec 19 05:01:18 hence two calls Dec 19 05:01:47 zhchang you mean, like using edlin ? Dec 19 05:02:26 yeah Dec 19 05:02:29 something like that Dec 19 05:02:45 editor + cli tools Dec 19 05:03:03 but I would prefer vim Dec 19 05:03:36 yeah, vim is probably better than edlin. maybe Leeds can help Dec 19 05:04:12 what is Leeds? Dec 19 05:04:14 zhchang: is your computer too slow to run an IDE ? Dec 19 05:04:25 my ide crashes like 3 times per day Dec 19 05:04:33 forced me to get rid of it. Dec 19 05:04:54 zhchang which ide ? Dec 19 05:04:57 and with vim, i feel more free Dec 19 05:05:00 Eclipse... Dec 19 05:05:19 hm, well i guess try Android studio Dec 19 05:05:38 THe project I am working on got tooooooo many dependencies to import to Android Studio Dec 19 05:05:54 lasserix_: From looking at AbsListView.java, I think it should be calling only once in any case. Hmm. Dec 19 05:05:55 I wonder would Google dump support for ANT any time soon? Dec 19 05:06:12 zhchang they probably did already Dec 19 05:06:25 not like anyone is adding features to it Dec 19 05:06:26 you mean like it is deprecated? Dec 19 05:06:39 pretty much yeah Dec 19 05:06:45 darn, I depend too much on ANT Dec 19 05:06:54 maybe time to switch to gradle Dec 19 05:06:55 ant sucks Dec 19 05:07:32 well, I build a set of tools that make ANT building and debugging easier Dec 19 05:07:32 i thought the guy who wrote ant repented Dec 19 05:07:41 ohhhhhhh.... Dec 19 05:07:45 that is not a good news Dec 19 05:07:55 can someone give me a hand with an issue i'm having with my simcard? Dec 19 05:08:17 what is the issue you are having? Dec 19 05:08:22 zhchang anyhow, learn gradle. if you have tools around ant, you can do that with gradle too as plugins or tasks, etc Dec 19 05:08:35 my sim card is saying it's not detected Dec 19 05:08:39 but i'm getting a list of network operators Dec 19 05:08:40 zhchang: anyway there are probably tutorials that show you how to use CLI to do it Dec 19 05:08:56 but it won't let me register with them Dec 19 05:09:20 thanks guys Dec 19 05:09:26 northofskepty please read the topic Dec 19 05:10:04 heyrgr Dec 19 05:11:23 I'm making an app which needs to call an api server to perform functions. I have been granted an application key, which I need to store within the app somehow. Is there a secure way of doing this, other than hard coding it into the binaries? Dec 19 05:11:52 Okay, I think I know what it is. Dec 19 05:11:54 https://code.facebook.com/posts/1419122541659395/introducing-conceal-efficient-storage-encryption-for-android/ Dec 19 05:12:05 It's calling once for getView and stuff and then once more for measuring. Dec 19 05:12:09 Or something. Dec 19 05:12:16 I'm surprised, in any case. Though one call would be enough. Dec 19 05:12:57 TacticalJoke: some things need more than one call and one picosecond ;) Dec 19 05:14:50 TacticalJoke: I could show you my apk, I got it to start without crashing again, but it's like half done so a lot of actions will still mess it up Dec 19 05:15:17 Sure. :) Dec 19 05:15:28 Want me to PM you my e-mail address? Dec 19 05:15:34 ok Dec 19 05:15:48 this should be interesting Dec 19 05:24:51 I'm unable to understand this version http://developer.android.com/reference/android/os/Message.html#obtain(android.os.Handler, java.lang.Runnable) Dec 19 05:24:56 It called the runnable, not the Handler.handleMessage when I do msg.sendToTarget or even handler.sendMessage(msg) Dec 19 05:28:12 it obtains the message from the handler? Dec 19 05:28:33 did you send the message back to the handler you obtained it from? Dec 19 05:29:47 hah i'm thinking about being a lyft/uber driver for a short period of time Dec 19 05:29:51 anybody tried it? Dec 19 05:30:32 uber drivers all seem to use iphones... Dec 19 05:31:10 uber seems morally bankrupt, screw those guys Dec 19 05:31:58 uber, airbnb .. wouldn't be taking off if not for the desperation economy Dec 19 05:32:07 Leeds: right i don't think ububer has a driver app for android Dec 19 05:32:47 I suspect uber hate depends a lot on where you are Dec 19 05:33:11 g00s: debateable. If you're really broke, you aren't taking cabs Dec 19 05:34:29 i read something terrible about uber every day. this is from today http://bits.blogs.nytimes.com/2014/12/18/uber-driver-in-boston-area-charged-with-rape/?_r=1 Dec 19 05:34:50 here, their regular service is significantly more expensive than a regular taxi - but probably the most convenient way to get a nicer-than-taxi car on demand. they got a little confused last weekend - I took a promotional ride in a nice Porsche for free, and they made a charitable donation in my name to thank me :) Dec 19 05:35:58 Leeds i guess thats better than getting raped Dec 19 05:36:47 yeah, two problems with that story: it's cherry-picking, and it's full of unclear "posed as the driver" which makes it seem like he wasn't actually the driver they'd sent Dec 19 05:37:39 the india one or boston ? Dec 19 05:38:18 there really seems to be an ongoing narrative of "raped by uber driver", which feels almost orchestrated to me - because nobody was every robbed, raped, ripped off by a regular taxi driver? Dec 19 05:38:45 http://www.reuters.com/article/2014/12/08/us-india-rape-uber-idUSKBN0JM0CE20141208 Dec 19 05:38:54 Leeds: Yeah, some investigative journalists found some evidence of that taking place Dec 19 05:39:02 Taxi drivers posting such things to protect their industry. Dec 19 05:39:19 It's not perfect by any means, but it's not really any worse either. Dec 19 05:39:47 RustyShackleford if you need a new vehicle, beware of http://valleywag.gawker.com/uber-and-its-shady-partners-are-pushing-drivers-into-su-1649936785 Dec 19 05:40:15 but this is my favorite http://money.cnn.com/2014/11/18/technology/uber-unethical-peter-thiel/ Dec 19 05:41:27 i've never heard anything bad of lyft the company Dec 19 05:41:37 "Peter Thiel, who is also an investor in Uber competitor Lyft" Dec 19 05:41:47 yeah, first sentence Dec 19 05:42:03 so not exactly dispassionate investigative reporting Dec 19 05:42:22 well, he saw first hand how uber was screwing lyft drivers with fake calls, etc Dec 19 05:42:24 meh, lots of business going on... some dirty... but the service seems to work Dec 19 05:43:20 "Airbnb is about empowering people who own homes to sublet money, make a little bit on the side," - Airbnb, which he's also invested in, has become just as much of a regulation/tax-dodge as uber is Dec 19 05:43:47 airbnb is far more dodgy Dec 19 05:43:50 imo Dec 19 05:43:53 a car is a car. Dec 19 05:43:58 your home is immobile Dec 19 05:44:46 RustyShackleford you may also want to read http://www.buzzfeed.com/johanabhuiyan/what-uber-drivers-really-make-according-to-their-pay-stubs#.gbp2mwzR Dec 19 05:45:10 anyway, AFAIK they only use registered/licensed drivers here - it's not really a 'sharing' thing - it's more of a marketplace/middleman Dec 19 05:46:35 the thing is in most countries, taxi's are regulated to control supply to supposedly meet demand Dec 19 05:46:49 these companies largely come from those companies acting through monopolies Dec 19 05:46:57 to treat customers as though they have no choice Dec 19 05:47:13 and must use their services, or the services of some other company that will as much treat them like garbage. Dec 19 05:47:24 I myself here in AU have waited upwards of an hour and a half for a taxi Dec 19 05:47:36 that then charged me nearly $50 to go about 10km Dec 19 05:47:50 to buy plates to run a taxi here can cost upto 100 grand Dec 19 05:48:03 they haven't issued a taxi license in Hong Kong for *20 years* Dec 19 05:48:05 because there's a finite amount - the drivers can sell them for pretty much whatever they way Dec 19 05:48:13 wow, that's crazy Dec 19 05:48:35 another problem with uber is privacy, they tracked rides of users who went somewhere, and then left the same place the next morning (Th, F, S) and called those "rides of glory". Dec 19 05:48:49 but they took down that blog post heh Dec 19 05:51:07 so like Fb, Twitter, and all those other shitty SF companies they are tracking you and selling the data Dec 19 05:51:40 Yeah.... But who cares. Dec 19 05:52:01 They make money to power a great service we all love. Dec 19 05:52:09 Using anonymised data. Dec 19 05:52:24 no data is anonymized Dec 19 05:52:27 And hell, id go so far as to say that I *like* the ads on facebook Dec 19 05:52:29 yes, ofcourse it is. Dec 19 05:52:30 :| Dec 19 05:52:32 next time I have a dirty night out, I'll get the bus home Dec 19 05:52:36 Have you even read their privacy policy? Dec 19 05:52:53 MJCD: within the company? I doubt it Dec 19 05:52:56 It's ALL anonymized, no names are EVER associated with any data given to anybody buying any data. Dec 19 05:53:04 Within the company, who cares. You are their customer. Dec 19 05:53:14 All companies do such research. Dec 19 05:53:22 Even hardware supply chains that have customer accounts. Dec 19 05:53:34 that's what g00s was referring to, within the company - their staff having fun with their data Dec 19 05:53:43 What's wrong with a company looking at your needs as a customer to provide you with more relevant services? Dec 19 05:53:52 MJCD they let job applicants look at the daya Dec 19 05:53:58 *data Dec 19 05:54:02 I'd say like 50-80% of all ads I see on facebook are actually for things that I have SOME interest in. Dec 19 05:54:08 Which for me, is fantastic. Dec 19 05:54:37 They have no vested interest in analysing anything to do with me specifically by hand. And if they do, they're more than welcome to. Dec 19 05:54:48 Why would I post anything I would consider confidential on facebook. Dec 19 05:55:01 MJCD: my problem with that is they get so repetitive, and they have the same bad habit of showing ads for things I've already bought as Google do Dec 19 05:55:06 It's like being mad that the postman knows where you live. Dec 19 05:55:19 Leeds: Yeah sure, but its still better than the alternative. Dec 19 05:55:34 Ads are a fact of life. Dec 19 05:55:42 Unless you're ready to pay for every site you use that is. Dec 19 05:55:46 Which, ofcourse, nobody is. Dec 19 05:55:54 And if they are.. There's always sites like Yammer. Dec 19 05:59:36 in the meantime, RustyShackleford has already carried two fares today and made $0.30! Dec 19 05:59:40 g00s: 21:41 g00s: i've never heard anything bad of lyft the company Dec 19 05:59:52 the same article from valleywag has something bad :P Dec 19 06:00:17 Lyft is just as hungry, if not as cunning as Uber. In May, the company convinced drivers to pay $34,000 for "tricked-out" Lyft-branded Ford Explorers in order to launch a luxury service to compete with Uber. Five months later, Lyft canceled the service, leaving drivers with a weak bailout offer: Lyft will help sell the trucks or give drivers a $10,000 bonus, subject to income tax. Dec 19 06:04:13 RustyShackleford you gotta choose between crap and crap Dec 19 06:05:07 uber doesn't anonymize the data. complete history of the rider can be accessed by employees Dec 19 06:05:22 so take what happened with sony, apply that to uber .. woohoo Dec 19 06:05:23 how about double the sleazy... buy a groupon voucher for uber? :) Dec 19 06:05:52 http://www.groupon.com.au/deals/gold-coast/uber-hq-1/719373433 Dec 19 06:07:14 Leeds how is that groupon app going ? Dec 19 06:07:21 which I could well end up using to get to an airbnb rental... Dec 19 06:08:06 g00s: I have no idea what my boss is doing... in the past couple of weeks, he's pitched to a major international airline, and had someone else pitch to a student union on his behalf Dec 19 06:08:42 I believe he's in Canada right now, but I'm not 100% sure Dec 19 06:09:44 Leeds now is a good time to move to Russia and get paid in lithuanian nails Dec 19 06:09:57 or canadian acorns Dec 19 06:10:29 every day you could get a raise ! Dec 19 06:11:23 my major currency watch at the moment is the Yen... it's fallen by over 1/3 since the first time I went to Japan, and by about 9% since I last bought them in October! Dec 19 06:11:50 will be back in Japan in just over a month... then in Oz a month after that :D Dec 19 06:12:05 Does anyone use app annie? Dec 19 06:12:22 I don't see a way to get keyword stats other than the US and Japan. Dec 19 06:12:33 and yet Dec 19 06:12:36 "we currently only support the following countries, Australia, China, Germany, Japan, United Kingdom, Canada, France, Italy, Russia and United States" Dec 19 06:12:57 maybe they didn't understand my email. Dec 19 06:13:08 Maybe they meant they only support apps from those countries. Dec 19 06:14:18 very strange Dec 19 06:19:13 this looks cool http://mobileenerlytics.com/eprof.php Dec 19 06:20:02 hehe Dec 19 06:20:23 lasserix_ have you used it ? Dec 19 06:20:41 no but i said the same exact thing like 40 minutes ago Dec 19 06:20:57 i am wondering how they are able to correlate CPU usage to stack frame Dec 19 06:21:56 lasserix_ lol, we both read reddit :) Dec 19 06:22:00 although the article about improving the app blah blah blah Dec 19 06:22:04 wasn't all that Dec 19 06:22:23 because its obvious to anyone who writes opengl don't call swapbuffers if you don't need to call swapbuffers Dec 19 06:22:31 I wish there were an easy-to-use timing profiler. Dec 19 06:22:46 even though the default opengl implementation automatically cycles swapbuffers but whatever ;p Dec 19 06:23:00 TacticalJoke: there is? Dec 19 06:23:07 you can press a button twice in DDMS Dec 19 06:23:14 * capella is about to play hot potato with an intermittent crash my code causes in someone elses service routine Dec 19 06:23:27 Yeah, but it's tedious. Dec 19 06:23:35 It's hard to use, etc. Dec 19 06:24:13 I used to use a C#/.NET profiler, and, gawd, it was easy and nice to use. Dec 19 06:24:29 You could see a list of methods; click one and get simple, easy-to-read details about how much CPU time it took. Dec 19 06:24:39 I feel lost in the Android version. Dec 19 06:24:51 Searching doesn't work, too. Dec 19 06:24:53 At least for me. Dec 19 06:25:05 yeah it is a bit of a pain Dec 19 06:25:10 someone should make a wrapper Dec 19 06:25:22 android monitor is awful. there are places in the UI the text is cut off an unreadable Dec 19 06:25:30 Is any of the Android tooling easy to use? Was just thinking. Dec 19 06:25:34 I can't think of a single thing that's easy to use. lol Dec 19 06:25:54 sdk manager is easy :D Dec 19 06:25:59 True. lol Dec 19 06:26:06 then its downhill from there Dec 19 06:26:41 looks like they haven't made it hard enough Dec 19 06:26:54 we got a billion apps on the store to compete with Dec 19 06:27:24 thats cause developers afraid to charge Dec 19 06:27:41 Not many of those apps are competition, though. :) Dec 19 06:28:06 i bet 90% of the apps on the store have no running code at all, just xml layout with a png Dec 19 06:28:14 hehe Dec 19 06:28:22 they have inline clickers Dec 19 06:28:26 that's it ;p Dec 19 06:28:29 :) Dec 19 06:28:57 come buttons next to the adds Dec 19 06:29:05 99% android app Dec 19 06:29:14 shmooz: Is your app gonna be ad-free? Just curious. Dec 19 06:29:21 yes Dec 19 06:29:39 somewhere in settings I'll put a chance to donate if they liked it Dec 19 06:29:56 Hmm. I think people have been banned for doing that, right? Dec 19 06:30:00 From the Play Store. Dec 19 06:30:08 I think you are not allowed to ask for donations at all. Dec 19 06:30:09 no donate? Dec 19 06:30:11 Could be misremembering. Dec 19 06:30:21 I think you can Dec 19 06:31:00 I think it would be the most respectable and least annoying way Dec 19 06:32:41 Careful, shmooz. I've seen so many posts like this: http://grokbase.com/t/gg/android-developers/123vf2vpke/my-app-was-suspended-for-a-donate-button-google-hasnt-responded Dec 19 06:33:14 you can accept donations now through play services Dec 19 06:33:21 this was added to 6.5 Dec 19 06:33:28 ok then maybe I'll just link to an external website for it in About... and then you can donate from that website Dec 19 06:33:30 donations for making them better ? ;) Dec 19 06:34:07 shmooz: I've heard about people getting banned for that, too. Dec 19 06:34:16 well what then? Dec 19 06:34:29 You have to do what g00s said, I think. Dec 19 06:34:32 Via Google Play itself. Dec 19 06:34:50 don't you guys agree that it's probably the less annoying way while leaving you a chance to get paid by people who liked it ? Dec 19 06:36:10 thanks g00s I'll look into to the details of that eventually Dec 19 06:39:16 TacticalJoke: anyway, if it does become an obstacle, I'll just release free without donate, no big deal Dec 19 06:40:31 TacticalJoke, it's not hard to use, click on click off, and look at the chart Dec 19 06:40:33 Okay. Just making sure you don't get banned. Seen so many apps getting banned for next to nothing. Dec 19 06:41:21 maybe I'll use the word Contribute, instead of Donate, so that it doesn't trip up the android police bots Dec 19 06:42:14 I dunno, man. I get the impression that *everything* financial has to go through Google somehow. Dec 19 06:42:24 Personally, I wouldn't even risk it, but it's your call. Dec 19 06:42:27 I may not even bother releasing through playstore, but release it from it's own website like the way xbmc does Dec 19 06:42:46 you would get banned trying to use paypal or something Dec 19 06:43:16 donate dogecoin :) Dec 19 06:43:27 I don't know what to call a "load more comments" node in a Reddit comment listing. I'm currently calling each a Placeholder (which is a terrible name). Dec 19 06:43:34 I guess I could use CommentPlaceholder, but it's kinda long. Dec 19 06:43:46 CommentStub Dec 19 06:43:50 lol Dec 19 06:43:55 Was just thinking of 'stub'. :) Dec 19 06:43:59 That could work. Dec 19 06:44:26 CommentOverflowStub Dec 19 06:44:28 I'll thesaurus.com 'stub' and 'placeholder'. Dec 19 06:44:40 But 'stub' is nice and short (and obvious enough, I think). Dec 19 06:46:45 can I use google maps in my app for free? Dec 19 06:46:53 or will they eventually require me to pay? Dec 19 06:47:29 isn't there a use limit for free accounts? Dec 19 06:47:58 Interesting fact: 'CommentStub' and 'Placeholder' have the same number of characters. :) Dec 19 06:48:01 Okay, not so interesting Dec 19 06:48:02 . Dec 19 06:48:21 It just looks awesome in my diffs. Dec 19 06:48:23 RustyShackleford: yes Dec 19 06:48:37 if you ger more than like 100k hits a month you have to pay Dec 19 06:48:39 Agamemnus: yeah i think it was that way before Dec 19 06:49:03 http://47hats.com/2009/07/14/google-maps-the-10k-gotcha/ Dec 19 06:49:08 "The key is free, you can use it with any of your applications that call the Maps API, and it supports an unlimited number of users." Dec 19 06:49:11 just found this Dec 19 06:49:30 lasserix_ thats 2009, is it still 10k ? Dec 19 06:49:35 i dont remember Dec 19 06:49:42 but you are cool to use it in paid android app Dec 19 06:49:44 not web app Dec 19 06:49:57 but after a certain number of hits you have to pay 10k for the yearly fee Dec 19 06:50:04 10k? Dec 19 06:50:09 jesus Dec 19 06:50:10 but by then you should be raking in 10k to pay for it yeah Dec 19 06:50:36 Usage limits only apply if your site or application generates 25,000 map loads or more each day, for more than 90 consecutive days. Dec 19 06:50:52 doh Dec 19 06:50:56 if your app is doing that 10k is the least of your worries Dec 19 06:51:11 i wonder how the osm stuff is going Dec 19 06:51:17 osm? Dec 19 06:51:23 open street map Dec 19 06:51:55 google maps and street view are Google's best projects IMO Dec 19 06:51:55 couple of problems, i don't think they have vectorized the tiles Dec 19 06:52:06 must have taken a remarkable about of work Dec 19 06:53:40 oh no satillete Dec 19 06:54:29 I love extracting classes. Gotta be one of the most satisfying refactorings. Dec 19 06:54:37 Because it tends to make code so much easier to read/change. Dec 19 06:57:19 anyone here using multidex ? Dec 19 06:58:56 guys, is there any tool or util to generate gradle build file for existing project? Dec 19 06:59:31 i mean, via CLI Dec 19 07:00:21 like android update project -p . Dec 19 07:00:32 will generate all build.xml and properties for ANT Dec 19 07:01:45 you can try gradle setupBuild, never used it Dec 19 07:01:58 doubt it works :) Dec 19 07:02:55 zhchang you like the cli, start typing mkdir -p ... Dec 19 07:03:43 gradle setupBuild, nice Dec 19 07:04:27 I mean, if there really isn't something similar that like what I described, it would be something I wanna add into my tool Dec 19 07:04:53 I have very nice tool build around ANT system, now thinking about migrating to gradle Dec 19 07:05:37 TacticalJoke: did you say you were an accountant? Dec 19 07:10:27 getParcelableArray is pita ).o Dec 19 07:12:18 i hate bundles Dec 19 07:18:36 google's new apps for Lollipop look great Dec 19 07:18:39 Oh, this is terrible (from /r/cringepics): http://i.imgur.com/QRiKG3K.png Dec 19 07:18:59 although I don't know how much I like the redesigned side drawer Dec 19 07:19:10 http://www.reddit.com/r/cringepics/comments/2pq1r1/looking_awfully_manly_lately/ Dec 19 07:23:20 zhchang, ant builds suck Dec 19 07:23:55 any reason to back that? Dec 19 07:23:55 android create project -g will create a gradle project Dec 19 07:24:20 i did it, but it is failing me for some reason, looking at it right now Dec 19 07:24:28 zhchang: tool around ANT.... Dec 19 07:24:30 but android update project does not support -g option Dec 19 07:24:33 what the heck Dec 19 07:24:36 it doesn't Dec 19 07:24:51 all new projects should only be gradle Dec 19 07:25:04 what about existing ones? Dec 19 07:25:10 so you should never need to update to get a gradle script Dec 19 07:25:23 existing must be migrated by hand Dec 19 07:25:27 hmmm Dec 19 07:25:52 although it should be pretty simple to create a gradle build for a typical ant build Dec 19 07:26:31 I m nervous whenever the word typical appears Dec 19 07:26:39 it should be automatic, but ant builds suck so much Dec 19 07:26:51 especially once you start adding libraries Dec 19 07:27:10 true story... Dec 19 07:27:19 typical = build.xml as created by android create or update Dec 19 07:29:09 now it clearer, thank you Dec 19 07:29:29 zhchang if your project is big, gradle offers some nice features like sub-projects Dec 19 07:29:31 I think I am gonna build another set of CLI development tool for gradle Dec 19 07:29:36 oh~ Dec 19 07:29:44 can you still use eclipse for android development? Dec 19 07:29:55 RustyShackleford it will stop working Jan 1, 2015 Dec 19 07:29:57 like, is the eclipse plugin still going to be maintained Dec 19 07:30:05 I'm everything is better than ant script... Dec 19 07:30:14 not by google. another group is picking it up RustyShackleford Dec 19 07:30:22 g00s: why ? Dec 19 07:30:48 because that group likes eclipse and wants to continue working on android in eclipse ;) Dec 19 07:30:56 They probably have massive projects, too. Dec 19 07:30:57 ah Dec 19 07:30:58 I'm guessing. Dec 19 07:31:13 better off migrating Dec 19 07:31:14 To be fair, I hear that Eclipse Mars is gonna be pretty good. Dec 19 07:31:26 Yeah, I'm gonna migrate (once Feature X is ready). Dec 19 07:31:27 RustyShackleford: you should use AS Dec 19 07:31:36 Eclipse build integration is terrible Dec 19 07:31:45 Hello everyone. I'd like to ask on what is the fastest way in Java's toolset to connect to PHP scripts on server in Android app? Dec 19 07:31:55 it makes no allowances for really working with a non ide build Dec 19 07:31:59 lol, another how do i connect android to php :D Dec 19 07:32:10 screwdriver! Dec 19 07:32:14 no, wait hdmi cable! Dec 19 07:32:32 but make sure you crossover that sh.t Dec 19 07:32:34 pfn: not using scala ide :> Dec 19 07:33:02 g00s what does that question even mean? like is the answer okhttp or what? Dec 19 07:33:08 Simplar: do you know what REST is ? Dec 19 07:33:09 One thing I dislike about Eclipse is how it's basically a collection of things. Dec 19 07:33:14 I like stuff that's *one* thing. Dec 19 07:33:16 Simplar uh, make you php thing expose rest interface, and then use Retrofit Dec 19 07:33:23 Collections of things are complicated. Dec 19 07:33:23 ... profit :D Dec 19 07:33:35 delete php -> profit Dec 19 07:33:51 TacticalJoke: time to switch to vim Dec 19 07:33:59 shmooz: emacs Dec 19 07:34:03 I used to be addicted to vim. Dec 19 07:34:05 * gordon_ let's the war begin Dec 19 07:34:05 Well, gVim. Dec 19 07:34:08 gordon_, no, I've stopped using eclipse for a few years now Dec 19 07:34:08 oh man, a new emacs book is coming out ! Dec 19 07:34:10 Maybe I could avoid PHP script, but I need it to connect to MySQL database on server. Dec 19 07:34:14 vim is the king Dec 19 07:34:15 I was crazy about it. So glad I got over that. :D Dec 19 07:34:27 TacticalJoke, no good vim setup for Eclipse is a deal breaker for me Dec 19 07:34:32 Simplar: I will ask again, do you know what REST is ? Dec 19 07:34:37 Ah. Dec 19 07:34:39 REST interface - yes. Dec 19 07:34:47 so what is the problem ? Dec 19 07:34:48 lasserix_: yeah I agree. I was just wondering what would happen to android/eclipse Dec 19 07:34:52 I use vim all the time, just not for android dev Dec 19 07:34:59 use json and ask the server Dec 19 07:35:12 you put okhttp and gson in your gradle build Dec 19 07:35:15 it iwll be easier Dec 19 07:35:39 Could've work with hostinger-based servers, right? Dec 19 07:36:09 does browser work there ? Dec 19 07:36:22 if so -> yes Dec 19 07:36:34 depends on what type of browser you talk about. Dec 19 07:36:41 internet browser :D Dec 19 07:36:46 if you ask if there's a website - yes :D Dec 19 07:36:49 yes it does ;D Dec 19 07:36:53 eh.. Dec 19 07:36:56 so android will work too Dec 19 07:37:08 so, I should use my php script Dec 19 07:37:18 which does a sqldb connection with PDO Dec 19 07:37:25 and pass queries through java Dec 19 07:37:26 right? Dec 19 07:37:50 sounds wrong Dec 19 07:38:11 you should make request to server with json Dec 19 07:38:11 pass queries through php, then? Dec 19 07:38:12 like Dec 19 07:38:13 pfn: what do you use now? vim with CLI ? Dec 19 07:38:23 json_encode? Dec 19 07:38:26 if I feel like Dec 19 07:38:26 www.myserver.com/users Dec 19 07:38:34 ideavim, shmooz Dec 19 07:38:38 and it should return json array of user object Dec 19 07:38:44 to android Dec 19 07:38:51 I see Dec 19 07:39:00 Simplar: I'm php hater so I dont know php that much Dec 19 07:39:05 hope it will die one day Dec 19 07:39:50 gordon_: if my php script takes <1ms to execute, it is not the source of app-freezing problem? Dec 19 07:40:01 Because before there were Webb and Runnables Dec 19 07:40:08 in Java Dec 19 07:40:27 it doesnt matter how much it takes Dec 19 07:40:38 you need to do it in background anyway Dec 19 07:40:45 with a timer? Dec 19 07:40:48 with asynctask / other library Dec 19 07:40:53 ahh Dec 19 07:40:56 true true Dec 19 07:41:10 have you ever read some tutorial ? Dec 19 07:41:13 ;) Dec 19 07:41:29 yes, I just got dizzy about problems of Java in Android Dec 19 07:41:41 what problems ? Dec 19 07:41:44 Like, if I find timer, it finds out that it bugs in Android Dec 19 07:41:52 and I need to use Runnable Dec 19 07:42:07 timer in android works just fine Dec 19 07:42:14 Runnable and Timer are for different purposes Dec 19 07:42:23 Runnable is for threads. Dec 19 07:42:47 which is kinda hinting there's an async operation :D Dec 19 07:43:19 Simplar, sounds like you need a service. Dec 19 07:44:27 FragmentActivity is confusing Dec 19 07:44:39 just avoid fragments Dec 19 07:44:44 do I need that class for API 15 and up? Dec 19 07:45:03 RustyShackleford: are you going to style it a la material? Dec 19 07:45:16 RustyShackleford: https://chris.banes.me/2014/10/17/appcompat-v21/ Dec 19 07:45:17 i don't understand the question Dec 19 07:45:46 https://www.youtube.com/watch?v=Q8TXgCzxEnw Dec 19 07:45:58 http://hgoebl.github.io/DavidWebb/jacoco/com.goebl.david/Webb.java.html Dec 19 07:46:15 Is that good for using in Android to call some web script? Dec 19 07:46:20 RustyShackleford: did you do holo design before? Dec 19 07:46:47 RustyShackleford: https://www.youtube.com/watch?v=gZz7nnx-sM4 Dec 19 07:46:50 i remember holo being a theme Dec 19 07:47:10 yeah so google introduced Material which is according to some people a way of life Dec 19 07:47:21 but anyways it's Lollipop's standard theme Dec 19 07:47:23 People on Reddit are crazy about material. Dec 19 07:47:24 I don't get it. Dec 19 07:47:31 watch those two videos Dec 19 07:47:32 You're right; it's like their way of life. Dec 19 07:47:37 Good enough Rusty :p https://d1u1p2xjjiahg3.cloudfront.net/63fe18c3-a059-4526-b953-401b70f0d572_l.jpg Dec 19 07:47:43 They spend hours every day thinking about it; talking about it. Dec 19 07:47:43 Simplar: what the hell is webscript.. Dec 19 07:48:03 alright let me watch those two videos Dec 19 07:48:08 Simplar: use this http://square.github.io/okhttp/ Dec 19 07:48:08 gordon_: it's http://www.myserver.net/myscript.php Dec 19 07:48:12 Material seems more like an end unto itself rather than a UI / skin change Dec 19 07:48:14 RustyShackleford: here's a text overview: http://android-developers.blogspot.com/2014/10/material-design-on-android-checklist.html Dec 19 07:48:35 Anyways one of the main things is the action bar has been modularized and it's called toolbar Dec 19 07:48:40 Simplar: make rest API Dec 19 07:48:50 if you used actionbar in your previous app you can use appcompat library (new support library) which has toolbar Dec 19 07:48:58 so we need the support library for anything older than lollipop now? Dec 19 07:49:05 gordon_: this okhttp seems much better than webb, thanks for the link :) Dec 19 07:49:11 its not support so much as it is called Compat Dec 19 07:49:25 RustyShackleford: if you want to do material-like design, read this: https://chris.banes.me/2014/10/17/appcompat-v21/ Dec 19 07:49:42 RustyShackleford: here's a text overview: http://android-developers.blogspot.com/2014/10/material-design-on-android-checklist.html <-- here is good overview of design principles for material Dec 19 07:49:56 theres some fancy UI like ripple effects on touch events Dec 19 07:50:04 and shmazzy animation transitions Dec 19 07:50:43 TacticalJoke: this material stuff is nice but it's just another fad that will look old one day like the old stuff looks old to us now ;) Dec 19 07:51:57 lasserix_: which dont work on pre-lollipop ;) Dec 19 07:52:08 the more expressive the fashion the more embarrasing it ends up being when out of style Dec 19 07:52:10 I mean ripple and animations Dec 19 07:52:51 lol Dec 19 07:52:54 shmooz: i like that Dec 19 07:53:01 Maybe material is the mods and rockers of 2014. Dec 19 07:53:13 Or one side. Dec 19 07:53:20 but even when it looks old, it won't be as bad as geocities websites of the 90s Dec 19 07:53:41 i think the new lollipop apps by google look excellent Dec 19 07:53:57 The only one I like so far is YouTube. Dec 19 07:54:04 The rest are pretty 'meh'. Dec 19 07:55:15 Has ART turned out to be much faster? Dec 19 07:55:38 not afaict Dec 19 07:57:00 shmooz: Are you gonna move to AS? Just curious. Dec 19 07:57:00 these material design guidlines aren't exactly simple :/ Dec 19 07:57:04 I will when they support JVM unit testing. Dec 19 07:57:11 it's suppose to optimize launch performance more than runtime performance Dec 19 07:57:15 looks like I will be reading, as opposed to writing code tonight Dec 19 07:57:28 RustyShackleford: What were you thinking of writing? Dec 19 07:57:48 TacticalJoke: I tried it a few times and it worked, I might get back to it Dec 19 07:58:08 I wish they had the resources of Microsoft. Dec 19 07:58:14 Imagine if Android Studio were another Visual Studio. Dec 19 07:58:18 I like the way I configured my Eclipse with the dark theme though Dec 19 07:58:20 It'd be awesome. Dec 19 07:58:36 shmooz: I tried darcula in AS but didn't like it too much. Dec 19 07:58:42 I use a dark theme for Eclipse too. Dec 19 07:59:01 the hard part was getting everything to be dark Dec 19 07:59:06 TacticalJoke: i've been planning this for a while. This app will run in the background while you are driving, and then alert you about speed cameras Dec 19 07:59:13 New versions of Eclipse have full darkness support (but it doesn't look great). Dec 19 07:59:35 i've got certain parts of this app more or less figured out Dec 19 07:59:42 RustyShackleford: Don't sat-navs do that already? Dec 19 07:59:49 do they? Dec 19 07:59:59 yeah on AS darkula is the best theme I saw, but it could even be darker Dec 19 08:00:01 darnit Dec 19 08:00:04 RustyShackleford even more noble is warning motorists of roadside stops Dec 19 08:00:23 i was driving through OK and police were just pulling over every third car Dec 19 08:00:27 RustyShackleford: Every sat-nav I've used beeps when a speed camera is nearby (at least here in England). Dec 19 08:00:33 I don't know about the US or wherever. Dec 19 08:00:38 going through people's shit on the side of the highway Dec 19 08:00:58 RustyShackleford: How are you gonna detect the presence of a camera? Dec 19 08:01:02 maybe now someone will know Dec 19 08:01:09 does anyone use multidex ? Dec 19 08:01:22 g00s: the problem is getting that data Dec 19 08:01:35 RustyShackleford there was one project, but they just shut down Dec 19 08:01:47 I found a list of speed cameras and red light cameras in my city, complete with address and GPS coordinates Dec 19 08:02:18 RustyShackleford soon it won't matter anyhow. to get a good rate on insurance you'll need a black box installed Dec 19 08:02:31 the naive way to do it is to warn motorists when they are, say a half mile from a speed camera Dec 19 08:02:41 RustyShackleford: A static list? Dec 19 08:02:45 Or a web service? Dec 19 08:03:33 TacticalJoke: static list. So I'm picturing some web crawler that runs on my VPS which will send me an email if that static list changes Dec 19 08:03:51 then I can include the new list in my app, and release an update Dec 19 08:04:11 i don't anticipate this data changing very frequently Dec 19 08:04:28 I see. Dec 19 08:04:54 even without my super useful app, Chicago didn't get nearly the amount of revenue they expected Dec 19 08:05:13 Sat-navs detecting speed cameras might be a UK thing; when I google that term it's all UK websites. Dec 19 08:05:16 Not sure, though. Dec 19 08:05:24 they anticipated $90 million by now, and they only got $43 million Dec 19 08:06:06 i mean, I'm all for safe traffic. But these politicians have revenue, and not safety in mind Dec 19 08:06:18 Yeah. Dec 19 08:06:42 Sat-nav makers over here say that they warn people about cameras because those cameras are designated unsafe areas. lolo Dec 19 08:06:43 lol* Dec 19 08:06:50 in ^ Dec 19 08:07:21 so a sat-nav is one of those dedicated gps units? Dec 19 08:07:23 RustyShackleford have you heard about our higway interdiction programs :) Dec 19 08:07:39 g00s: who is our? USA? Dec 19 08:07:41 Yeah. Dec 19 08:07:46 yeah Dec 19 08:07:58 g00s: no i haven't. explain? Dec 19 08:08:03 oh my Dec 19 08:08:32 http://www.washingtonpost.com/sf/investigative/2014/09/06/stop-and-seize/ Dec 19 08:09:22 RustyShackleford you need to make an app called White Asphalt :) Dec 19 08:09:41 (if you read, you'll know what i mean) Dec 19 08:10:14 "leading interdiction training firm based in Guthrie, Okla" Dec 19 08:10:21 that explains why i saw so much shit in OK Dec 19 08:10:32 heh Dec 19 08:11:21 of course IL is in this article too Dec 19 08:12:36 yeah this is depressing to read about Dec 19 08:12:39 go USA Dec 19 08:13:57 well here is another reason to never keep large sums of cash on you Dec 19 08:14:28 RustyShackleford but some of the training videos have surface too. its not just money, but they have a list of valuables to seize Dec 19 08:14:31 like iPhones Dec 19 08:14:37 probably not androids :D Dec 19 08:15:10 this is what happens when you have to many police to pay, tight budgets - they gotta get their $$ from somewhere :) Dec 19 08:15:48 one video was from a class given in NJ, its online somewhere Dec 19 08:16:27 too many police with too much power Dec 19 08:16:33 budgets have nothing to do with it Dec 19 08:16:40 they have tons of money Dec 19 08:16:54 the police department in my city has a f-k-g tank Dec 19 08:17:10 why? i have no idea. really. no idea Dec 19 08:17:13 what i read budgets are a big problem Dec 19 08:17:30 just bs put out to cover their asses Dec 19 08:17:50 A tank? Wow. Dec 19 08:17:58 do you see cops riding in dilapitated patrol cars? Dec 19 08:18:10 depends entirely on your location Dec 19 08:18:12 lasserix_ how do you think they paid for that ? Dec 19 08:18:17 cops have way too much power, they're also being militarized Dec 19 08:18:32 DoD money going to the police forces concerns me. :( Dec 19 08:18:45 no wonder they have adopted this bs of civil forfetuire or whatever it is Dec 19 08:18:47 idk i have a few cops in the family. I'd say I'm generally pro-police Dec 19 08:18:52 lasserix_ did you read radley balko's book ? Dec 19 08:18:54 i hate reading stuff like this :( Dec 19 08:19:00 the DoD being funded at the expense of education concerns me even more. Dec 19 08:19:11 https://www.youtube.com/watch?v=3kEpZWGgJks Dec 19 08:19:29 (fun trivia for americans! when was the last time we were invaded and NEEDED a full on defense force deployed?) Dec 19 08:19:36 pretty decent john oliver episode that touched on civil forfeituire and DoD providing police departments with armored vechiles Dec 19 08:19:47 RustyShackleford: im not saying all police are scum but seriousily, there is something very very very wrong with the institution Dec 19 08:20:15 my experiences with the police are very polar Dec 19 08:20:15 ok, if your house/wife/life are being threatened by hoodlums, i promise to NOT call the cops to come help you Dec 19 08:20:27 most of the time the police were friendly and professional Dec 19 08:20:38 but i've dealt with some total jerks also Dec 19 08:21:09 the idea of "peace officer" is gone Dec 19 08:21:23 its a joke really Dec 19 08:21:35 they have too much power and are apt to abuse it Dec 19 08:21:36 A lot of the American cops seem crazy to me. Dec 19 08:21:45 Our boys over here are, of course, totally sensible. Dec 19 08:21:51 (Okay, not totally.) Dec 19 08:22:00 But those TV shows... wow. Dec 19 08:22:12 which is the worst part because lets say you know a decent person who is a cop, the institution as it is will corrupt them and turn them into the kind of power abusive ahole who tazers a 70 year old man Dec 19 08:23:06 Yeah. I'd go so far as to say that humans can't deal with power. Dec 19 08:23:11 Humans become abusive when given power. Dec 19 08:23:20 Look at the Standford Prison Experiment, for example. Dec 19 08:24:00 Those given power became abusive and even sadistic (surprise, surprise). Dec 19 08:24:30 TacticalJoke: you must be like one of those old school conspiracy theorist freaks Dec 19 08:24:33 Even the researcher got drawn into it all and didn't stop the experiment. Dec 19 08:24:42 No, not at all. Dec 19 08:24:51 i mean there is some truth to what you're saying, but I'm with shmooz Dec 19 08:24:55 I'm just hugely cynical. Dec 19 08:25:02 any1 knows how i can change the color of a Button in a Widget while maintaining the default shape? "setBackgroundColor" makes it flat Dec 19 08:25:04 ok but admit you listen to a lot of Alex Jones then ;) Dec 19 08:25:24 RustyShackleford: A conspiracy theory? Search for Stanford Prison Experiment on YouTube and tell me what you think. :p Dec 19 08:25:28 I don't know who Alex Jones is. Dec 19 08:25:38 hey RustyShackleford I never said I wasn't on his side Dec 19 08:25:42 I'm the complete opposite of a conspiracy theorist, shmooz. I don't buy into nonsense like that. Dec 19 08:26:08 I agree with everything he's said Dec 19 08:26:29 and I believe it's worse than the most paranoid conspiracy would think it is ;) Dec 19 08:26:58 I'm more worried about those who *aren't* jaded by life yet. Dec 19 08:27:03 They have a lot to learn, IMO. Dec 19 08:27:17 hah i'm pretty cynical. Not as cynical as you folks I guess Dec 19 08:27:39 The fact is that humans are animals: primates, apes... monkeys, even. Dec 19 08:27:45 And give these primates power and they become abusive. Dec 19 08:27:55 It's a fact that can be (and has been) demonstrated over and over. Dec 19 08:28:01 so then give us a solution Dec 19 08:28:05 no animals don't make up bullcrap all the time, humans do Dec 19 08:28:17 Teach children to be kind to all sentient beings. Dec 19 08:28:20 i mean, it's a complicated issue with no clear solution Dec 19 08:28:22 humans sneakily plot on each other Dec 19 08:28:25 Develop medical cures for our violent/abusive tendencies. Dec 19 08:28:31 Stuff like that, I guess. Dec 19 08:28:32 49% of police in the united states "feel that the only way a criminal would receive any punishment was to punish the individual him/herself" Dec 19 08:28:47 When I installed Android Studio, I have set 1GB for the emulator.... That's not enough Dec 19 08:28:52 Where can I change this now? Dec 19 08:29:05 actually the solution just has a lot of parts, so it appears difficult. one you need to dismantle the prison industrial complex Dec 19 08:29:47 anyways we are getting waaayyy off topic here Dec 19 08:29:59 ahop: goto avd Dec 19 08:30:04 lets move this over to ##politics haha Dec 19 08:30:06 click on your device, edit it and change it Dec 19 08:30:16 but ahop STRONGLY recomended you download genymotion Dec 19 08:30:19 let's start with JFK and go all the way to 911 Dec 19 08:30:47 I suspect that people like conspiracy theories because they're fun. Dec 19 08:31:01 did you know 9/11 was an inside job Dec 19 08:31:02 the aliens are ruling the world , we never went to the moon, and the queen is a lizzard Dec 19 08:31:18 of course Dec 19 08:31:39 Imagine how fun it'd be if the reptilian thing were real. Dec 19 08:31:42 It's like movie stuff. Dec 19 08:31:47 It makes life interesting and thrilling. Dec 19 08:31:52 a-ha ! E/dalvikvm( 9466): LinearAlloc exceeded capacity (5242880), last=152 Dec 19 08:31:53 sounds like a south park episode Dec 19 08:31:54 it is, just like that TV show V Dec 19 08:31:57 I think that's why people are so drawn to conspiracy theories. Dec 19 08:32:03 so multidex wont help ya with that ;) Dec 19 08:32:17 They get really upset when you counter their claims, because that's just dashing their dreams. Dec 19 08:32:35 lasserix_ AVD? Dec 19 08:32:44 android virtual device manager Dec 19 08:33:13 well shouldn't there be many alien races more intelligent than us according probability if the universe is infinite ? Dec 19 08:33:20 ahop Tools -> Android -> AVD Dec 19 08:33:34 shmooz: not if we are living in a simulation Dec 19 08:33:44 I think there's a reasonable change of 'intelligent' things on other planets. Dec 19 08:33:45 lasserix_ oh yes thx! I now see 1GB, but cannot modify it :( Dec 19 08:33:49 It's not hard for evolution to get started, it seems. Dec 19 08:34:06 ahop: you have to stop the emulator first Dec 19 08:34:09 also get genymotion Dec 19 08:34:23 its a different emulator package with much better emulators Dec 19 08:34:45 lasserix_: and you have to stop the simulator, now find the switch Dec 19 08:35:08 how can i getApplication from my adapter? the way im trying ends up with having to force close the app: http://pastebin.com/LdQGtu54 Dec 19 08:35:17 take the red pill and break out of the matrix Dec 19 08:36:05 The simulation hypothesis seems like a good one. Few assumptions are involved. Dec 19 08:36:16 Though it's totally unfalsifiable. Dec 19 08:36:19 am I the only one who thinks the matrix wasn't that good? Dec 19 08:36:30 RustyShackleford: yes Dec 19 08:36:35 now get out before you get beat up Dec 19 08:36:41 TacticalJoke: except you still have to explain the world outside the simulation Dec 19 08:36:51 c03: psh. do you even lift bro? Dec 19 08:36:56 ;) Dec 19 08:37:01 Well, in some versions, there is no external world. Dec 19 08:37:21 DOES NOT COMPUTE Dec 19 08:37:27 aaearon: http://pastebin.com/ctvd3g6C Dec 19 08:37:58 Life could be like a computer game. The people you/I see are just images on the screen, etc. Dec 19 08:38:11 i'm doing a replace for some fragments and it has a flip animation and the animation runs but it doesn't "flip" the first fragment. the fragment stays where it is and the other one flips Dec 19 08:38:17 you're right it's unfalsifiable. But also unlikely Dec 19 08:38:23 weird thing is i do the exact same call earlier and it works fine. Dec 19 08:38:25 TacticalJoke: /r/outside Dec 19 08:39:07 so... which do you design first? Dec 19 08:39:13 a user interface, or the backend? Dec 19 08:39:33 backend Dec 19 08:39:37 Really depends. Dec 19 08:39:46 unfortunately lasserix i cant getTracker that way as getTracker is a method in my Application Dec 19 08:39:51 tac's answer is better Dec 19 08:40:16 RustyShackleford: Which way seems easiest? Dec 19 08:40:22 I think it's all about baby steps. Dec 19 08:40:41 perhaps both at the same time. I've identified three or so parts of this app Dec 19 08:41:01 but having the UI would help me confirm that the backend works right Dec 19 08:41:09 the interface lets you filter what you need the backend to be Dec 19 08:41:29 i stink at UI design Dec 19 08:41:42 and now i have to read pages and pages about Material Dec 19 08:41:46 aaearon: http://pastebin.com/v4peA1YC Dec 19 08:41:46 I mean you expect to see A and B and C in the interface so then you implement the backend to give it that Dec 19 08:41:56 RustyShackleford: It's important to have some "driver" for the back-end, IMO. Dec 19 08:42:05 Whether that driver be unit tests or the UI. Dec 19 08:42:15 Otherwise you're writing code that doesn't run for ages. Dec 19 08:42:36 Ideally, as soon as you write some code, it runs. Dec 19 08:42:48 i know how to write unit tests, but I'm unsure of how it works for android Dec 19 08:43:16 also I have a ListView with a BaseAdapter which acts as a chat, each row has a time stamp. when I create a row i see if that item in the list was from today, if it is then print the hour and minute, if from yesterday then month/day, etc. but when i do that instead of updating just that item it updates EVERY item in the list... so every item has the Dec 19 08:43:16 same timestamp Dec 19 08:43:22 aaearon: assuming you added the getTracker method to your application class Dec 19 08:43:25 I do need to drive around and create some kml files to test against. But can you use a kml file in a unit test? Dec 19 08:43:27 It's possible to run unit tests on the JVM (though it's hard if you're using AS {and will be so until they implement this functionality}). Dec 19 08:43:41 It's XML? Dec 19 08:44:11 similar i think. It's created by My Tracks to describe a path you took Dec 19 08:44:12 MartialLaw: you need to make your element set contain a date/time field Dec 19 08:44:16 Well, sure. Dec 19 08:44:31 MartialLaw: setting the time is not the responsibility of the adapter, Dec 19 08:44:43 You could have a unit test load a file. Dec 19 08:44:49 MartialLaw, uh, rows in listview are reused and updated everytime when data changes Dec 19 08:44:59 alright, i was going to do that either way i just thought i'd ask to save myself some work Dec 19 08:45:02 if you do what you described, you're setting date to today on everything :P Dec 19 08:45:18 TacticalJoke: well to test my LocationManager, wont I have to mock my location? Dec 19 08:45:38 RustyShackleford, you can mock OS calls Dec 19 08:45:49 aaearon: that work? Dec 19 08:46:18 Mavrik: yeah it does. Dec 19 08:46:27 mTracker = ((MarketApplication) mContext.getApplicationContext()).getTracker(MarketApplication.TrackerName.APP_TRACKER); actually did it for me when it came to being able to access getTracker Dec 19 08:46:40 aaearon: the first cast is incorrect Dec 19 08:46:52 im very tired and wish i wasn't at work but at home eating mac n cheese and sleeping Dec 19 08:46:59 yeah Dec 19 08:47:31 oh Dec 19 08:47:34 nevermind Dec 19 08:47:37 aaearon: nice Dec 19 08:47:51 kind of a weird casting but cool it works Dec 19 08:48:29 anyways you can cast mContext to Activity to get the method getApplication, which you'd have to cast to MarketApplication to getTracker method exposed Dec 19 08:48:36 which you did and simplified so nice Dec 19 08:49:01 sometimes the casting gets me turned around Dec 19 08:49:24 Is there any advantage to doing that over using static fields in some class? Dec 19 08:49:34 when that happens just write it out explicity ie cast everything line by line, then make the calls then go back and make it one line Dec 19 08:49:42 TacticalJoke: whaa? Dec 19 08:49:59 yeah--you dont get stuck with statics Dec 19 08:50:18 But is there a difference between something being static and something being an instance field in an Application subclass? Dec 19 08:50:37 yes Dec 19 08:51:08 zomg, this team america clip was so funny Dec 19 08:51:12 The only difference I see is that it's more tedious accessing fields of Application subclasses. Dec 19 08:51:25 As opposed to Globals.foo (or Globals.getFoo()). Dec 19 08:51:49 (Where Globals has a private constructor, etc.) Dec 19 08:52:26 lasserix_ wut? explains ! Dec 19 08:52:29 Of course, Application-subclass instance fields are just global variables. Dec 19 08:54:22 how many applications are there on your device? Dec 19 08:54:24 just one? Dec 19 08:54:54 ? Dec 19 08:57:42 i take that back that answer is no good one sec Dec 19 08:58:38 any hint to migrate from analytics v3 to v4 ? Dec 19 08:59:52 From hackbod: "Statics are statics -- they are global to the process. So their value will last for the lifetime of the process, which is usually much longer than an individual activity instance." Dec 19 08:59:54 https://groups.google.com/forum/#!topic/android-developers/PZXbCXliRbo Dec 19 09:00:17 (The last part is irrelevant, of course.) Dec 19 09:01:10 too bad hackbod stopped responding Dec 19 09:01:37 because they wouldn't be able to access the activities/other components? Dec 19 09:01:59 I meant the part about activities. Dec 19 09:02:56 For stuff like my OkHttpClient instance, I'm just putting it in a class called Globals. Dec 19 09:03:03 i dont see a direct reason but there was to be something relating to the fact the static field cant see the non statics Dec 19 09:03:07 Same with my application-global thread-pool. Dec 19 09:03:26 that wouldbe my guess anyways Dec 19 09:03:47 I guess your way can avoid having to pass a Context or whatever. Dec 19 09:03:55 ? Dec 19 09:04:11 i think aaearon was following a guide Dec 19 09:04:19 If you use only statics, you might have to pass a Context to it as some point. Dec 19 09:04:25 As opposed to subclassing Application and just using 'this'. Dec 19 09:04:38 s/to it/to some class/ Dec 19 09:04:41 yeah i was adjusting what i found in the google analytics guide Dec 19 09:05:04 I hate Context, though. It's a god object. Dec 19 09:05:07 It does everything under the sun. Dec 19 09:05:16 Quite a messy API. Dec 19 09:05:19 TacticalJoke: yeah static context is bit of a oxymoron Dec 19 09:09:04 Note that this will only work single-threaded. Add the synchronized Dec 19 09:09:04 keyword to the method and make the static data member volatile to make Dec 19 09:09:04 it safe for multi-threaded access. Dec 19 09:09:04 (a problem I ran into with WakefulIntentService, which is why this Dec 19 09:09:04 issue is fresh in my mind...) Dec 19 09:09:07 oops Dec 19 09:09:21 if you do lazy load of your singletons commonsguy says this when multithreading Dec 19 09:09:53 if its synchronized, it doesn't need to be volaile Dec 19 09:09:56 *volatile Dec 19 09:10:19 https://groups.google.com/forum/#!topic/android-developers/2i82mjoM46M Dec 19 09:10:28 not neces Dec 19 09:10:40 volatile just prevents context caching Dec 19 09:10:49 which is different from synchronized race condition Dec 19 09:11:33 I don't think synchonized methods are a good idea. Dec 19 09:11:41 Much better to use some lesser-scoped lock variable. Dec 19 09:11:54 I think C# purposely avoided synchronized methods. Dec 19 09:11:58 synchronized methods are fine Dec 19 09:12:16 They work, but it's easier to have deadlocks because the lock object is now 'this', which is accessible elsewhere. Dec 19 09:12:26 you can use ReentrantLock then Dec 19 09:12:29 for application not really a problem Dec 19 09:12:30 Hi, Im reading into an open source android project and releard android for that (5 years no java). Here I find that the fields of a non-static class are sometimes accessed as m_field, this.m_field, CLASSNAME.m_field, CLASSNAME.this.m_field. I wonder why one would use the classname here. Do you have any idea? Dec 19 09:12:58 That's just their coding convention. Not sure why. Dec 19 09:13:23 Though they don't use underscores. Dec 19 09:13:27 From what I've seen, anyway. Dec 19 09:13:30 Just mFoo. Dec 19 09:13:58 Sorry, I totally misread your question. ;o Dec 19 09:14:26 saulus: Can you give an example? Dec 19 09:18:59 man there are a lot of ways to do singletons http://www.journaldev.com/1377/java-singleton-design-pattern-best-practices-with-examples Dec 19 09:19:33 Do you like Singletons? I generally dislike them. Dec 19 09:19:41 everyone hates singletons Dec 19 09:19:50 Because they hide the initialization order. Dec 19 09:19:51 true dat Dec 19 09:20:04 and they are hard to unit test, etc etc Dec 19 09:20:07 not if they are enum Dec 19 09:20:07 Plus they make classes violate the SRP. Dec 19 09:20:19 Hi, Im reading into an open source android project and releard android for that (5 years no java). Here I find that the fields of a non-static class are sometimes accessed as m_field, this.m_field, CLASSNAME.m_field, CLASSNAME.this.m_field. I wonder why one would use the classname here. Do you have any idea? Dec 19 09:20:22 Yeah, unit testing becomes a pain. Dec 19 09:20:28 saulus: Please link to an example. Dec 19 09:20:43 TacticalJoke: the only class that does not violate SRP is object, and even then... Dec 19 09:20:46 saulus: Though I'm guessing it's nested classes. Dec 19 09:21:51 saulus: alllows you to reference it anywhere within that class without having to declare a reference of that class Dec 19 09:22:01 lasserix_: Imagine a class like this: public class Globals { private Globals() {} public static Foo foo = new Foo(); public static Bar bar = new Bar(); } Dec 19 09:22:07 Isn't that just extremely simple and obvious? Dec 19 09:22:17 As opposed to Singletons which hide all this. Dec 19 09:22:46 ? Dec 19 09:22:54 enum singelton Dec 19 09:22:58 is exactly that yo Dec 19 09:24:16 TacticalJoke: i am not seeing your point exactly, since it seems apples and oranges to me Dec 19 09:24:35 bar and foo have no guarntee they'll only be instanced once, which is the whole point of a singleton Dec 19 09:24:37 I guess I'm thinking of global state in general. Dec 19 09:24:43 I dont think its a singleton involved Dec 19 09:24:45 e.g. https://github.com/MirakelX/mirakel-android/blob/3b9c64f3ca01e8391724d8f9f90833af3c6751b6/helper/src/de/azapps/mirakel/helper/MirakelPreferences.java Dec 19 09:24:55 saulus: not to do with singleton Dec 19 09:25:05 But there are other places that correspond to my initial question Dec 19 09:25:05 okay. Dec 19 09:25:11 you are just referencing an enclosed class through the explicit this Dec 19 09:25:37 what is the "explicit this"? Never heard that. The classname? Dec 19 09:25:45 yeah Dec 19 09:26:03 im sure there is some techincal term but Dec 19 09:26:17 okay. But we agree then that this.m_, CLASSNAME.m_, CLASSNAME.this.m_ are all the same like m_. Dec 19 09:26:38 Hello. Dec 19 09:26:58 lasserix_: As a question Dec 19 09:27:23 I'm only second day of trying to develope small app and stuck at some strange in emulator. Dec 19 09:28:08 saulus: no Dec 19 09:28:20 hi Dec 19 09:28:28 this inside a nested class is not the same as this outside Dec 19 09:28:44 therefore CLASSNAME.this.m_ and this.m_ are not always the same Dec 19 09:28:52 On my onClick function i fetch data from url and put it to textView with setText(). It's work perfect on real device, but on emulator just nothing happen (connection to server is comlete with 200 code). Text just dont updated and no errors. Dec 19 09:28:58 lasserix_: okay. Makes sense. Any other differences known? Dec 19 09:29:14 dunno--thats why i said 'explicit this' Dec 19 09:29:25 okay, thanks a lot! Dec 19 09:29:32 swi: Maybe post something on http://pastebin.com/. Dec 19 09:29:56 TacticalJoke: something like what? Dec 19 09:30:51 If you can't decide what to post, maybe use Log to debug what's going on. Dec 19 09:31:12 swi use the debugger Dec 19 09:31:40 lasserix_: hm. will try :) just strange that it perfectly work on real device Dec 19 09:31:42 dont think he can post anything that will help, he needs to step through and see whats happening Dec 19 09:32:20 so TacticalJoke did you just make your executorservice static inside the application class? Dec 19 09:33:48 I made it static inside Globals. But, yeah, basically the same thing. Dec 19 09:33:56 how do you terminate it? Dec 19 09:34:01 err shutit down Dec 19 09:34:03 I don't. I don't think I can. Dec 19 09:34:13 Because there's no point at which I can say "The user has finished with my app now". Dec 19 09:34:13 lasserix_: I'd aksked a question to which you responded Dec 19 09:34:16 I'll show a code sample Dec 19 09:34:59 lasserix_: As far as I can tell, all I can do is let Android take care of it. Dec 19 09:35:12 Only Android can decide "This process needs to be killed now". Dec 19 09:36:57 how frequently is application.oncreate called? Dec 19 09:37:20 once Dec 19 09:37:50 once per? Dec 19 09:37:57 you have to kill off the app to get it run again Dec 19 09:38:16 Another situation is if you're using loads of memory and Android kills your process running in the background. Dec 19 09:38:23 meaning if i call finish on all activities/services it will ? Dec 19 09:38:41 I don't think so, lasserix_. Dec 19 09:38:57 if my app has one activity, and i finish it, oh Dec 19 09:39:00 You can finish all services and back out of all activities and your process should stay alive. Dec 19 09:39:00 that depends if android kills the app when all activities are out Dec 19 09:39:01 oh that's the right i remember now Dec 19 09:39:03 and I have no idea Dec 19 09:39:03 process is cached Dec 19 09:39:12 sometimes destroyed, sometimes not Dec 19 09:39:23 lasserix_: If you swipe it out of Recent Tasks, that kills it (from what I've seen). Dec 19 09:39:32 can someone help me with this https://gist.github.com/anonymous/c523f1ea55aa1efec35a ? Dec 19 09:39:33 But hitting back to the home screen shouldn't, in general. Dec 19 09:39:36 yeah when the process is EXPLICITLY stopped Dec 19 09:39:42 otherwise its just cached Dec 19 09:40:05 so is having a idling executorservice a good idea then? Dec 19 09:40:22 I'm not certain, but I guess so. Dec 19 09:40:22 *as a global ie living in the pplication class Dec 19 09:40:32 I just don't see any other option. Dec 19 09:40:47 ahh i guess the threads are waiting till notified anyways Dec 19 09:40:48 I asked in here, and people told me it was the best option (I forget who said). Dec 19 09:40:53 TacticalJoke: on my Nexus 7 when I swipe the processes to the right , they are still running when I check Apps->All Dec 19 09:41:09 shmoon whats up? Dec 19 09:41:18 shmooz ? shmoon? wtf? Dec 19 09:41:28 shmooz: Weird. I see that too. Dec 19 09:41:30 i haven't even begun to smoke tonight wtf Dec 19 09:41:45 which one of you brough the moon shine? Dec 19 09:41:48 Well, I see "Force Stop". Dec 19 09:41:58 that will stop it Dec 19 09:42:17 But in my experience swiping it away will cause Application.onCreate to fire the next run. Dec 19 09:42:17 is shmooz and shmoon the same entity? Dec 19 09:42:21 And all statics will be re-initialized. Dec 19 09:42:25 lasserix_: I asked a question previously, and you responded with another set of questions. So to avoid confusion I've create a pastebin https://gist.github.com/anonymous/c523f1ea55aa1efec35a Dec 19 09:42:27 No, lasserix_. lol Dec 19 09:42:27 lasserix_: no Dec 19 09:42:36 Nope, we're not same Dec 19 09:42:41 I think shmooz should sue shmoon for trademark violation. Dec 19 09:42:41 Although I like his nick Dec 19 09:42:49 Just kidding. :D Dec 19 09:42:51 which one of you brough the moon shine? Dec 19 09:42:54 me Dec 19 09:43:33 you got some serious threadception going on here Dec 19 09:43:43 lasserix_: you've had enough , no moonshine for you! Dec 19 09:44:37 we just need one more and we'll be the three shmoozes Dec 19 09:45:14 I am shmoot Dec 19 09:45:21 System.out.println(msg.obj); // This is never printed Dec 19 09:45:26 do you have to cast it as string? Dec 19 09:45:40 Log.d plx Dec 19 09:45:40 are you sure some nonsense hashcode is not being printed? Dec 19 09:45:47 Ashiren: shh Dec 19 09:45:48 nope, it's string already according to line 24 Dec 19 09:45:57 no Dec 19 09:46:00 you have to cast it back Dec 19 09:46:00 I can try casting to string wait Dec 19 09:46:04 and i msg.obj (its string) is empty it wont print Dec 19 09:46:05 an object != a string Dec 19 09:46:12 a string = object but obj != string Dec 19 09:46:19 msg.obj.toString() Dec 19 09:46:24 Leeds: oh I see what you did there, from guardians of the galaxy ;) Dec 19 09:46:25 sure Dec 19 09:46:26 why not simply msg.obj+" xxx" Dec 19 09:46:44 There's some big security issue with Git and Mercurial. Dec 19 09:46:46 Downloads available. Dec 19 09:46:46 Odd. Dec 19 09:46:55 even even Dec 19 09:46:57 http://stackoverflow.com/questions/27557021/are-remote-git-clients-vulnerable-to-cve-2014-9390-if-only-trusted-users-have-ss Dec 19 09:47:06 it mostly affects not-posixy systems Dec 19 09:47:18 the problem is that it doesn't entirely only affect them. :( Dec 19 09:47:30 Why is it affecting both Git and Mercurial? I haven't read yet. Dec 19 09:47:43 lasserix_: nope, not printed Dec 19 09:47:48 because they both use a magic directory name. Dec 19 09:47:50 shmooz: use debuger Dec 19 09:47:56 Ah. Dec 19 09:48:00 i am checking in adb logcat Dec 19 09:48:07 e.g. default on osx and windows is case-honoring-but-insensitive. Dec 19 09:48:21 so someone can commit .GIT/config and blow away your .git/config Dec 19 09:48:24 lasserix_: you mean the breakpoints thingie with debugger? Dec 19 09:48:59 (but other systems support case-insensitive filenames, too, which means everyone should update even if they don't think they need to. just in case.) Dec 19 09:49:11 Hmm, I see. Dec 19 09:49:28 anyway if you guys make the mistake of referring to one of us instead of the other, neither you nor we should bother correcting it :) Dec 19 09:49:32 like, what if your repo is on a fat32 sd card? :P Dec 19 09:50:06 yeah Dec 19 09:50:59 Oh, gawd, I hate waiting in for deliveries. :[ Dec 19 09:51:08 Amazon. Dec 19 09:51:25 i'm actually potentially affected by the cve on one rhel-clone system and i haven't seen that rhel is going to patch it. Dec 19 09:51:32 delivery guy: "he just got into shower. lets come!" Dec 19 09:51:35 lol Dec 19 09:51:50 Once the guy didn't even knock. Just put a "Sorry we missed you card" through the door. Dec 19 09:51:53 I ran out but missed him. Dec 19 09:51:59 I ha spent the entire day waiting. Dec 19 09:52:00 had* Dec 19 09:52:15 TacticalJoke: i had gse do that recently. Dec 19 09:52:17 Or some will knock but wait about five seconds. Dec 19 09:52:20 lasserix_: ya seems like handleMessage is never called Dec 19 09:52:26 as the debugger doesn't halt the program there Dec 19 09:52:28 lewellyn: technically, NTFS is case sensitive Dec 19 09:52:39 it's just the Win32 api that makes it insensitive Dec 19 09:52:54 rainy day, google courier stuck our bags in a puddle of water. didn't knock or ring the bell, nor did he honor the instructions of the dry place 50 feet away. Dec 19 09:52:56 It's so bad. Dec 19 09:53:02 Wow. Dec 19 09:53:06 Did you complain? Dec 19 09:53:28 Dream_Team: actually, it's usable both ways. i set my ntfs partitions to case sensitive via gpo, so i'm actually affected by the cve on linux, but not windows. :P Dec 19 09:53:39 TacticalJoke: yup. $15 order and $10 credit. Dec 19 09:53:44 Nice. :) Dec 19 09:54:01 went out to see what the mailman had left and there's a half dozen bags in the outlet of the rainspout. Dec 19 09:54:45 none of the contents were ruined, but it's kinda gross to think about eating food that was just in water that came down from the roof. Dec 19 09:54:52 shmooz yeah that is weird Dec 19 09:54:55 SO that shit Dec 19 09:55:17 We should all create the same names apart from the last character. Dec 19 09:55:22 To prevent people from being lazy typists. Dec 19 09:55:41 heh. i'm in a channel with like 4 people who all start with "le" Dec 19 09:55:47 that makes things fun Dec 19 09:55:49 lasserix_: you mean ask on SO ? :D Dec 19 09:55:53 yeah Dec 19 09:55:55 two of us are 8 characters. Dec 19 09:55:56 alright hehe Dec 19 09:55:59 lol Dec 19 09:56:28 ill join but only if we have names in the form of hexadecimal Dec 19 09:56:51 shmoon: alright what? alright you're gonna change your name to something else ?? Dec 19 09:56:57 i'll be 00h Dec 19 09:57:00 0xbadf00d Dec 19 09:57:11 no I was talking to laser Dec 19 09:57:15 Oops, that wouldn't make sense. Dec 19 09:57:27 * shmooz kicks shmoon in the n Dec 19 09:57:39 I think the newest shmoo? should change their name. :D Dec 19 09:57:53 Or find a way for all our clients to auto-complete backwards. Dec 19 09:58:00 And train our brains to do this. Dec 19 09:58:36 noomhs Dec 19 09:58:58 Maybe there could be an auto-complete system where you can type both the start and the end. Dec 19 09:59:00 TacticalJoke: you're just reversing the problem :D Dec 19 09:59:04 Like sh*n Tab. Dec 19 09:59:10 lol Dream_Team Dec 19 09:59:34 Dream_Team: but i didn't! Dec 19 09:59:42 ok can someone explain this uptimeMillis thing here http://developer.android.com/reference/android/os/Handler.html#postAtTime(java.lang.Runnable, long) , the method docs is this http://developer.android.com/reference/android/os/SystemClock.html#uptimeMillis() Dec 19 09:59:49 noomhs and zoomhs are way different! Dec 19 09:59:57 the runnable will be executed when if I pass SystemClock.iptimeMillis() ? Dec 19 10:00:24 i reversed it, ut i eliminated the problem ;) Dec 19 10:00:26 shmoon: instantly Dec 19 10:00:41 Dream_Team: does it return the current timestamp since epoch? Dec 19 10:00:48 No, the current MS since boot Dec 19 10:00:54 docs say milliseconds since boot (without sleep time) Dec 19 10:01:05 System.currentTimeMillis returns since the epoch. Dec 19 10:01:07 so postAtTime works with time since boot not epoch ? Dec 19 10:01:15 yes. Dec 19 10:01:16 aye Dec 19 10:01:19 TacticalJoke: I'm using hexchat and easier to type shm and type tab once to complete to him and twice to complete to me Dec 19 10:01:32 lewellyn: that works ! Dec 19 10:01:40 Yeah, but I'm almost always directing at you. lol Dec 19 10:01:51 I see, i read messages are sorted according to timestamps in the messagequueue - so I had expected that those timestamps are since epoch, apparently they are ince boot time withotu the sleep time ? Dec 19 10:01:52 shm + Tab + Tab Dec 19 10:01:58 shmoon you pulling a malcom x and stepping through the docs one entry at a time? Dec 19 10:02:05 I sometimes make the mistake of "sh + Tab". Dec 19 10:02:12 Then Ctrl+A, shm, Tab, Tab. Dec 19 10:02:14 It's so much. lol Dec 19 10:02:30 lasserix_: malcom x? Dec 19 10:02:40 Time spent in deep sleep will add an additional delay to execution Dec 19 10:02:44 TacticalJoke: you get Shrooms instead? :) (sorry for the spurious highlight. no need for you to scroll back to find why.) Dec 19 10:02:46 We need brain-to-computer input already. Dec 19 10:02:51 shadynastys Dec 19 10:02:53 That's who I get. Dec 19 10:02:53 lol Dec 19 10:03:06 he taught himself to read and write while in prison by starting at the beginning of the dictionary and moving one word a sequential time to the end Dec 19 10:03:11 And tabbing again doesn't help. Oh, I've tried that a lot. Dec 19 10:03:27 TacticalJoke: now shadynastys is going to have to scroll up to see why you highlighted. how rude. Dec 19 10:03:38 so the messages in the messagequeue are order by time since boot ? Dec 19 10:03:48 Doubly so. :p Dec 19 10:03:54 ;) Dec 19 10:04:02 no Dec 19 10:04:06 you started it! Dec 19 10:04:08 TacticalJoke: what irc client are you using ? Dec 19 10:04:09 its a queue Dec 19 10:04:18 mIRC. Dec 19 10:04:20 It sucks. Dec 19 10:04:25 But I can't find any good Windows client. Dec 19 10:04:32 I guess there's HexChat, but I'm not a huge fan. Dec 19 10:04:37 TacticalJoke: use hexchat it's better Dec 19 10:05:05 I wrote a Windows IRC client ages ago. No idea what I did with it. lol Dec 19 10:05:14 Kinda need it right now. Dec 19 10:05:17 shmoon did someone say the looper blocks while executing runnables? Dec 19 10:05:28 This was like 10 years ago; hence my uncertainty. Dec 19 10:05:36 TacticalJoke: irssi. done. :) Dec 19 10:05:52 Would I have to use something like Powershell? Dec 19 10:06:05 lasserix_: I think it does, it blocks when processing one message Dec 19 10:06:07 at a time Dec 19 10:06:10 use something like XShell with Envy Code R VS as the font (both are mere suggestions and free as in beer.) Dec 19 10:06:17 Okay. lol Dec 19 10:06:38 Are you a big FLOSS fan, lewellyn? You strike me as such. :) Dec 19 10:06:49 envy's a neat font. almost every different useful size looks different. and the VS version has bold as italic so you can pretend it's not a terminal ;) Dec 19 10:07:01 no. i just recommended not-putty ;) Dec 19 10:07:09 i'm a pragmatist Dec 19 10:07:10 shmoon yeah Dec 19 10:07:19 Yeah, same here. Dec 19 10:07:29 shmoon: http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/1.5_r4/android/os/Looper.java#Looper.loop%28%29 Dec 19 10:07:36 putty's bound to piss you off. xshell may not. Dec 19 10:07:40 pfn needs to write a windows version of his qicr client Dec 19 10:08:17 (xshell is only free for home/school use, but i suspect that's fine for your case.) Dec 19 10:09:01 if you've got the money, go with securecrt anyday :D Dec 19 10:09:21 This might sound lame, but I just prefer GUI IRC clients. Dec 19 10:09:31 And ones that are so easy to set up. Dec 19 10:09:44 (I know that the CLI/GUI distinction gets fuzzy.) Dec 19 10:10:58 that's why i recommended something you can set up to maybe fool yourself into liking :) Dec 19 10:11:11 the only gui I like is textbox for the chat list for the names, and tabs to switch windows Dec 19 10:11:53 other than that I don't like fancy gui stuff cluttering space Dec 19 10:12:14 Yeah, same here. Dec 19 10:12:42 ahh Dec 19 10:12:44 shmoon Dec 19 10:12:46 found the answer Dec 19 10:12:49 so no Dec 19 10:12:55 apparently it is not supposed to do anything Dec 19 10:12:58 buts thats weird Dec 19 10:13:22 oh no its not Dec 19 10:13:36 lasserix_: jdb refuse to me :D but i put some Log.d() in code and .. a get 200 response, but InputStreamReader.read() return empty buffer Dec 19 10:13:36 so basically Message.obtain(handler, runnable = handler.post(runnable Dec 19 10:14:05 lasserix_: alright Dec 19 10:14:16 going to spam for fun Dec 19 10:14:17 public void More ...dispatchMessage(Message msg) { Dec 19 10:14:17 91 if (msg.callback != null) { Dec 19 10:14:17 92 handleCallback(msg); Dec 19 10:14:17 93 } else { Dec 19 10:14:17 94 if (mCallback != null) { Dec 19 10:14:19 95 if (mCallback.handleMessage(msg)) { Dec 19 10:14:21 96 return; Dec 19 10:14:24 97 } Dec 19 10:14:26 98 } Dec 19 10:14:28 99 handleMessage(msg); Dec 19 10:14:30 100 } Dec 19 10:14:32 101 } Dec 19 10:14:37 woosh! Dec 19 10:14:40 * TacticalJoke waits for more. Dec 19 10:14:41 sorry Dec 19 10:14:48 so the msg.callback is the runnable Dec 19 10:14:52 this is the handler Dec 19 10:14:57 since the callback is not null it executes Dec 19 10:14:58 An IRC channel could have an interactive code-review session like that. Dec 19 10:15:07 handCallback calls the run method of the runnable Dec 19 10:15:08 "Just shout stop when you see an issue." Dec 19 10:15:21 but since its not null the handler doesn't get the handle the message Dec 19 10:15:26 maybe that's a bug!?! Dec 19 10:15:33 maybe it is upposed to handle the message Dec 19 10:15:40 and line 99 should be at line 100 Dec 19 10:15:54 hm Dec 19 10:16:34 oh no Dec 19 10:16:40 nah Dec 19 10:17:05 public static Message obtain (Handler h, Runnable callback) this is like a thoroughly useless method Dec 19 10:17:18 because if it DID send the message to be handled, the message is NOT EVEN empty Dec 19 10:17:27 it is just the runnable Dec 19 10:17:30 wonder why Dec 19 10:17:54 things we'll never know Dec 19 10:18:05 that's going to bother me at some point int he distant future Dec 19 10:18:20 the tick at the back of my mind that makes the shmoon trip go bad Dec 19 10:18:22 lo Dec 19 10:18:23 ;p Dec 19 10:18:57 so shmoon are you stepping through the api a method at a time or what? Dec 19 10:20:23 hm.. seems i get it. i use InputStreamReader.available() and seems it's not working in emulator at least, it return 0. Dec 19 10:20:26 an irc client with a built in pastebin would be nice, so you just paste it and it shows up in the pastebin tab Dec 19 10:20:37 Is there any way to get ALL response from http into string ? Dec 19 10:20:55 Ah HA! Dec 19 10:21:30 the point of that overload is to pass the messageto another process to do some system-wide function calls in a remote process via the runnable set as that messages callback Dec 19 10:21:57 which is something you'd do if you were building an os from scratchin the early days of doing it Dec 19 10:22:02 or so id imagine Dec 19 10:23:03 TacticalJoke: you and i should probably take a break from staring the computer screen Dec 19 10:23:04 heh Dec 19 10:23:07 actually im out Dec 19 10:23:15 fun investigation shmoon Dec 19 10:23:41 nisck lasserixzzz Dec 19 10:26:02 he's gone Dec 19 10:26:24 I'll look into interprocess communicaiton now (binder, apidl, messengets) :D Dec 19 10:26:30 aidl* Dec 19 10:40:27 swi: Which HTTP client are you using? Dec 19 11:08:21 Hi - I want to implement logging into my application (via communication with my server) but I am unsure how to do this securely. Does anyone know of a good tutorial that I could look at that explains how to set up a good authentication activity? Dec 19 11:13:55 DVass: yes Dec 19 11:14:41 TacticalJoke: HttpUrlConnection :) Dec 19 11:15:36 niru: mind sending me it, please? Dec 19 11:19:49 DVass: are you done with the place holders for username and password and the necessary buttons required? Dec 19 11:19:57 or do u need the ui part also? Dec 19 11:20:14 I am just using the default LoginActivity provided for the UI Dec 19 11:24:06 Hi, is possibile to run android x86 emulator at full speed in a vmware debian virtual machine? Dec 19 11:24:55 niru: I think I can manage the part where it communicates the server. I'm more confused as to how to check if it is authenticated, if authenticated to load different activity. if not, to stay on the login activity. and to also check whether the token received has expired and to request login once more if it has Dec 19 11:25:43 has anyone made a daydream? Dec 19 11:26:29 DVass: send the username and password to the server via a function like authenticate(uid,pwd) and the function should return something depending on the sent details Dec 19 11:27:30 TacticalJoke: I think I fixed the crash Dec 19 11:27:34 if its true then start a new intent or if false is returned stay on the same page with some pop up message Dec 19 11:29:23 DVass: you can get many example code while googling it may help in kickstart Dec 19 11:37:50 niru: and then for after they leave the app and open it again Dec 19 11:37:54 do i store the details of the user Dec 19 11:50:09 does anyone have any experience whatsoever with the slow torture that is integrating the twitter sdk? Dec 19 11:53:15 I'm trying to prevent my media app using the new NuPlayer on Android 5.x Dec 19 11:53:45 based on lines 63-68 of https://android.googlesource.com/platform/frameworks/av/+/master/media/libmediaplayerservice/MediaPlayerFactory.cpp Dec 19 11:54:09 do you think I get just do System.setProperty("media.stagefright.use-awesome", "true"); Dec 19 11:56:52 Does GoogleApiClient need to be connected for FusedLocationApi to work? I hate not having the src available... Dec 19 12:01:41 meh, seems it requires a connected GoogleApiClient :| Dec 19 12:02:30 i know you need it for the LocationClient Dec 19 12:02:42 but seriously though Dec 19 12:02:52 i spent way too much time in this darned twitter shit thing Dec 19 12:03:06 snowpong, yes, yes it does Dec 19 12:03:36 i seem to have pinpointed the problem to having two different twitter apps, one in fabric and another in twitter Dec 19 12:03:51 does anyone know how i can link the twitter sdk to the app in twitter and not in fabric? Dec 19 12:04:02 when i change the keys i get a crashlytics error Dec 19 12:04:19 "in twitter and not in fabric"? explain? :) Dec 19 12:04:20 this whole experience is honestly making me want to consider suicide Dec 19 12:04:27 i will Dec 19 12:04:38 ohh Dec 19 12:04:44 apps.twitter.com/app -> in this dashboard i have my application Dec 19 12:04:47 you mean the Parse thing sdk Dec 19 12:04:50 looking into making live android tv app but honestly can't find enough info to get started only stuff available on it is reference - https://developer.android.com/reference/android/media/tv/package-summary.html and basic overview - no detailed explationion or test apps - for live android tv apps anyway Dec 19 12:04:52 not the twitter API Dec 19 12:05:09 i needed to leave fabric and go there because i need to request the email and twitter doesnt allow that by default for some reason Dec 19 12:05:12 when i did that Dec 19 12:05:16 the keys generated by that app Dec 19 12:05:22 are different than the ones fabric generated Dec 19 12:05:32 which is absolutely straight up completely retarded Dec 19 12:05:59 its logic you'd expect from baboons throwing feces at the zoo Dec 19 12:06:12 hiw, i have this file /storage/emulated/0/App/offline/file.zip but when i try use it i have this error: java.io.FileNotFoundException: /storage/emulated/0/App/offline/file.zip , anybody can help me? Dec 19 12:06:12 now the whole fabric sdk that i installed in my project Dec 19 12:06:27 doesnt compile because when i change the keys to the ones i got permission to do stuff with Dec 19 12:06:42 arent the same as the auto-generated Dec 19 12:06:44 by fabric Dec 19 12:06:56 Haxxa, even with this: http://developer.android.com/training/tv/index.html ? Dec 19 12:07:18 t0th_-_, are you hardcoding that path? :) Dec 19 12:07:25 yes Dec 19 12:07:27 Mavrik click on building live tv apps and you'll see what I mean Dec 19 12:08:10 Haxxa, um, I'm seeing several TV-specific guides? Dec 19 12:08:24 Mavrik I thnk it might be one of those APIs in which is used mainly by Manufactures and close ties to google. Dec 19 12:08:30 including how to declare activity and how to use TV-specific themes and layouts? Dec 19 12:08:45 Mavrik not android tv apps but those which intergrate into the live tv app via tv framework api Dec 19 12:09:47 Mavrik your focusing on Android TV apps - I am looking at getting Live Tv intergration there is plently on how to build a standard android tv app Dec 19 12:09:57 so you want to modify another app Dec 19 12:10:00 that displays live tv? Dec 19 12:10:08 I doubt they're letting you do that. Dec 19 12:11:41 Mavrik no Google has an Api for manufactures and for devolpers to intergrate thier content into the android tv live tv app Dec 19 12:11:59 outlined here - Dec 19 12:12:01 http://source.android.com/devices/tv/index.html Dec 19 12:12:12 but it doesn't have any example code Dec 19 12:12:36 which might be because of early platform or because they want to keep code close to heart Dec 19 12:13:34 I don't see anything like what you're takling about there. Dec 19 12:13:56 I'm seeing just a documentation of a software stack used to ingest TV streams and integrate them on OS level - meant for manufacturers Dec 19 12:14:09 it does look like there are some content providers for TV data Dec 19 12:14:59 the only thing that's remotely close to what you're looking for is the TvProvider, which seems to be build just so that the HW (or software) TV stream sources can populate data about channels Dec 19 12:16:57 hiw, i have this file /storage/emulated/0/App/offline/file.zip but when i try use it i have this error: java.io.FileNotFoundException: /storage/emulated/0/App/offline/file.zip , anybody can help me? Dec 19 12:17:00 Mavrik you don't understand the Tv Framework API apps like HDHomerun when installed parse their video streams into the live tv app enabling them to be watched from their this is an open api which allows both hardware decoders and software apps to parse thier streams into the live tv app Dec 19 12:17:34 but there is very imited documentation on how to do this Dec 19 12:18:21 Haxxa, so you want to provide your own TV video stream, not just TV data? I see Dec 19 12:18:45 My mistake :) Dec 19 12:20:12 yes Mavrik (Not your mistake I was been very ambigous with my wording) I am working with TVheadend to intergrte their streams into the live tv app but I can't get any api information apart from the reference/overview which isn't enough to build an app of Dec 19 12:21:44 Whoa, this looks interesting: https://android-review.googlesource.com/#/c/118237/5/build-system/builder/src/main/java/com/android/builder/testing/MockableJarGenerator.java Dec 19 12:22:11 A class that creates a mockable JAR for Android stuff (avoiding the "Stub!" thing). Dec 19 12:22:53 Haxxa, wow yes, the documentation is totally non-existent :/ Dec 19 12:22:57 JakeWharton: You might also find that interesting. Pinging just in case. Dec 19 12:23:03 seems like you have to implement this: https://developer.android.com/reference/android/media/tv/TvInputService.html Dec 19 12:23:10 but not information about Intents you need to handle or not Dec 19 12:23:46 Here's the changeset: https://android-review.googlesource.com/#/c/118237/ Dec 19 12:24:26 Mavrik yer see my struggle - whats interesting is many apps are now intergrating into live tv app and been published on playstore - according to one of ther devs (HDHomeRum) they got help from google assistant Dec 19 12:24:46 ah :/ Dec 19 12:24:58 My Nexus is still stuck in mail so can't help you much at this moment Dec 19 12:25:34 Mavrik there is a way round using xbmc compilled with custom logo and theme and bypass live tv but really unofficial and my team is not in favour of that Dec 19 12:25:49 I guess I will have to wait in any case Dec 19 12:35:59 Anyone used FaceDetection from camera preview? Dec 19 12:37:30 Every phone I try it on the face id is -1, then what's the purpose of it? Dec 19 12:39:14 hi Dec 19 12:39:18 Maybe you don't have a face. Dec 19 12:39:21 (Sorry.) Dec 19 12:39:38 i have this situation http://pastebin.com/a6edyR7x , i have this file, but always i have "not exists" in my if Dec 19 12:39:46 TacticalJoke: That's probably it joker Dec 19 12:40:20 it is so basic Dec 19 12:40:30 hello some who has experience with orm lite? i have problem to persist a hashmap Dec 19 12:43:28 I can't believe how much effort they're putting into supporting JVM unit tests in a future Android Studio version. Dec 19 12:43:36 Even implementing first-class mocking support. Dec 19 12:45:38 hi Dec 19 12:46:43 I have an Object that is accessed by multiple Activities in one apk. When this apk call apk2 I need to pass the Object. What would a good way be to store the Object before apk2 is called? At the moment I am passing the Object from one Activity to the other in apk1. Dec 19 12:47:00 i see the error my file it is in /storage/emulated/legacy/storage/emulated/0/App/offline/file.zip and not in /storage/emulated/0/App/offline/file.zip , how i can make the Enviroment get the correct path? Dec 19 12:52:57 hello guys Dec 19 12:53:01 anyone alive? Dec 19 12:53:24 No, run, it's coming back Dec 19 12:54:14 u_u Dec 19 12:54:24 VnM: can you help? Dec 19 12:54:34 Would a class with static members be a solution? Dec 19 12:54:46 VnM: not now Dec 19 12:56:51 barq can't you just use a listener and a handler? Dec 19 12:57:05 How can i set onClick events on a ListView's item without make the ListView lose the onItemSelected event? Dec 19 12:57:34 VnM: A listener in multiple activities anf fragments? Dec 19 12:57:57 I was thinking a singleton enum might be better. Dec 19 12:58:15 abara, add the code you would put in onClick in onItemSelected? Dec 19 12:58:38 Ah yeah that's probably better barq Dec 19 12:59:42 VnM: can't. The "button" inside the listview's item is to call a popup, and the onItemSelected should be used to call other activity Dec 19 13:00:20 How long does it take for an app to be approved in the Amazon App Store? Dec 19 13:00:26 LocationRequest.PRIORITY_BALANCED_POWER_ACCURACY should still turn on the GPS / Location stuff right? It's not just passive waiting for other to query the location? Dec 19 13:00:41 Was wondering if I might be able to get an app out before Christmas Dec 19 13:00:51 VnM: Or just an object with static members. Dec 19 13:06:04 VnM: :/ Dec 19 13:06:24 abara, http://stackoverflow.com/questions/1709166/android-listview-elements-with-multiple-clickable-buttons/5320540#5320540 Dec 19 13:08:27 VnM: so there is no way to handle this situation with a ArrayAdapter? Dec 19 13:10:06 Maybe with the setTag() and getTag() methods, but custom adapter is you better bet Dec 19 13:11:25 i see the error my file it is in /storage/emulated/legacy/storage/emulated/0/App/offline/file.zip and not in /storage/emulated/0/App/offline/file.zip , how i can make the Enviroment get the correct path? Dec 19 13:12:03 VnM: even with set and get Tag i still need to implement the click listener Dec 19 13:12:17 the button on the item should raise a popup .-. Dec 19 13:30:00 stop. using. arrayadapter. when. you. have. to. do. anything. beyond. display. a. line. of. text. Dec 19 13:30:47 what is the best way to get getExternalStorageDirectory ? Dec 19 13:34:56 Mavrik: i'm ussing a customadapter with an arraylist holding the itens Dec 19 13:35:18 guys, is it possible to connect two devices via wifi? Dec 19 13:35:42 I need to transfer information from one device to another (> 100mb) Dec 19 13:35:54 without internet or router Dec 19 13:35:59 woozly: yeah Dec 19 13:36:01 can you do p2p Dec 19 13:36:09 or take the SD cards out? Dec 19 13:36:10 woozly: os a simple socket Dec 19 13:36:13 or* Dec 19 13:36:18 Wifi P2P Dec 19 13:36:31 sd cards cannot, but P2P sounds great Dec 19 13:36:38 but how to establish connection? without router? Dec 19 13:36:42 Is it possible? Dec 19 13:36:48 woozly: you can mount a ftp server Dec 19 13:36:57 woozly: like AirDrop Dec 19 13:37:05 Oh... nice! Dec 19 13:37:25 http://developer.android.com/training/connect-devices-wirelessly/wifi-direct.html is it? Dec 19 13:37:43 Oh.. yes. It is. Dec 19 13:37:45 Thank you guys. Dec 19 13:37:48 woozly, what version of android? Dec 19 13:37:51 4.2 Dec 19 13:38:18 I mean 4.4.2 Dec 19 13:38:20 =) Dec 19 13:38:20 tap and hold the folder or file Dec 19 13:38:25 then share via Dec 19 13:38:29 then Wi_Fi Direct Dec 19 13:38:45 but this is more of an #android question, I think Dec 19 13:38:52 Thank you, but I need to do it programmatically Dec 19 13:39:32 now, my problem if someone can help me. It seems that 4.2.2 changed some things vs 4.1.2... my 4.2.2 devices are automatically connecting to disabled or "turned off" networks that I had programmatically disabled Dec 19 13:39:37 does anyone know why? Dec 19 13:40:47 I'm going to post a pastebin if someone can help me, please Dec 19 13:46:46 is there something that resets the network interfaces when a device is woken up? Dec 19 14:27:55 Hello, does anybody in here have any experience on passing intent's extras from Fragment to Activity? I've googled and stumbled on some StackOverflow's discussion but mainly it discussed about throwing extras from Activity to FragmentActivity, not the other way around Dec 19 14:59:27 howdy Dec 19 14:59:43 anyone getting issues with adb and chrome when enabling port forwarding? Dec 19 15:00:42 it doesnt seem to work unless I launch the app with the adb command line, then kill the command line adb server and use chrome://inspect to setup port forwarding Dec 19 15:01:01 Ideally i'd like to start the android app and setup port forwarding all from the adb command line tol Dec 19 15:01:04 *tool Dec 19 15:13:00 I finally got my nexus 6 :D Dec 19 15:13:58 damn Dec 19 15:14:09 lost internet connection, hope i didnt miss anything Dec 19 15:16:14 man, this sucks Dec 19 15:27:59 ok im going Dec 19 15:34:36 Is Dagger 2 on Maven Central? I'm not seeing it Dec 19 15:35:24 I know the README says " Snapshot releases are auto-deployed to sonatype's central maven repository on a clean build with the version tag 2.0-SNAPSHOT" Dec 19 15:36:14 No luck at http://goo.gl/hEukLS Dec 19 15:38:43 Hmm guess not http://goo.gl/yo4cEH Dec 19 15:47:18 yiati, sonatype is a different website Dec 19 15:48:14 yiati, add this to your repository {} in gradle: maven { url "https://oss.sonatype.org/content/repositories/snapshots/" }, then you can use it as if i were on maven central Dec 19 15:51:23 I tried to run Watch Face Sample, but I don't see the sample faces available in Android Wear App. both my phone and watch are on 5.0.1. Can something point direction? Dec 19 15:51:42 is this is an unusual lifecycle scenario? My apop ha sa main activity that does login, then launches a top level activity that is similar to a list of documents. when you ope a document, a documenta activity launches that has a fragment manager. each fragment that could be displayed is a section of a document, which in turn has pages. think book/chapter/page Dec 19 15:52:16 the issue i have is if my app has a doc/section/page open and the app is put in background and then killed, Dec 19 15:53:01 when it is restarted it tries to open the app in the same state, but the firt thing to get opened is the fragment manager, but the activity isnt there Dec 19 15:53:42 but what it appears i see when trying to debug is the ragement manager is launched in its own thread, then the activity is launched Dec 19 15:53:57 so i have a race condition that almost always crashes Dec 19 15:55:19 so a fragment manager is launched but it's parent activity isnt there, so context is empty, getactivity is null, etc Dec 19 15:55:59 do i have to check for that on startup all the time, or can i know when im being restarted from a saved state inside a fragment? Dec 19 15:59:20 Syzygy__: Cool thanks Dec 19 15:59:45 I’m trying to use AsyncTask (fairly new to dev), should I be able to modify a TextView from onPostExecute? Dec 19 15:59:51 no problem Dec 19 16:03:31 <^-^guppie___> Is it possible to write an app that launches by default in Safe Mode? I know it's designed to not let that happen, but I'm working with a team on a kiosk mode app and need to disable safe mode / password protect safe mode without enabling the lock screen for non-safe mode use. Dec 19 16:06:56 Fight! Dec 19 16:13:34 acovrig, I don't see why not. To me it makes sense to update the text in a textview after something finished loading (or whatever your async task does) Dec 19 16:15:10 Is it possible to have a subclass be in a different file? (have AsyncTask be in a different file as opposed a class within a class in MainActivity.java)? Dec 19 16:15:44 Syzygy__: yea, I realized it wasn’t getting findViewById because it wasn’t a subclass of MainActivity… Dec 19 16:24:39 acovrig, sure, you just make it another class file. and if you need something from mainactivity accessible in the other class, there are quite a few ways todo it Dec 19 16:27:51 whatitis: how, my async class couldn’t resolve findViewById, but I copy and pasted it to be inside my MainActivity class and it works; how would I make the async class file a subclass of mainactivity? Dec 19 16:28:47 whatitis, do you have the async class as it's own unique class or is it an inner class? Dec 19 16:29:05 context.findViewById() should work. Dec 19 16:30:16 acovrig: One of my old favorites on creating an AsyncTask in a separate class file is http://stackoverflow.com/questions/9963691/android-asynctask-sending-callbacks-to-ui Dec 19 16:30:26 and http://stackoverflow.com/questions/15487807/android-development-having-an-asynctask-in-a-separate-class-file Dec 19 16:31:32 ive used it in its own Dec 19 16:31:48 ive made quite a few as seperate classes Dec 19 16:33:42 acorvrig, and any time I was touching views, id pass whatever view I wanted to constructor with a tag on the view. if at anytime the view was null, or if like lazy loading the views tag didnt match id just finish the asynctask Dec 19 16:35:23 hey y'all Dec 19 16:35:35 hey paula dean Dec 19 16:35:37 im curious about something, and I was hoping you all could help me figure it out Dec 19 16:35:40 rofl Dec 19 16:36:05 its probably just a rash, apply ointment and come back in two days Dec 19 16:36:07 does anyone here use vector graphics much in their apps? Dec 19 16:36:12 lol Dec 19 16:36:58 there maybe libraries for svg images I think. what kinda graphic do you need scaled? Dec 19 16:37:29 cause there are drawables and 9patch etc, depending on graphic Dec 19 16:37:43 well i mean, i use svg's a bunch in my app Dec 19 16:37:53 and im familiar with drawables and 9-patches Dec 19 16:38:01 i was just curious if anyone used them much Dec 19 16:38:20 I have a pretty sweet system with the android-svg library for handling icons Dec 19 16:38:30 and it makes your resource folder so much smaller Dec 19 16:38:49 especially when you need to use the same icon in different sizes/densities/colors Dec 19 16:39:07 ive just been surprised at how little people in the android dev community use vector graphics Dec 19 16:39:27 ah, im not one. you know there are qualifiers for the screen buckets and icon generators on android for creating the sizes Dec 19 16:39:42 yeah and ive used them quite extensively Dec 19 16:40:03 can you give an example of using vector or densities? Dec 19 16:40:14 yeah definitely Dec 19 16:40:25 so one example in my current app Dec 19 16:40:28 is that i have an intro screen Dec 19 16:40:35 with like a simple walk through of the app Dec 19 16:40:46 and the main focal point is a 200x200 dp icon Dec 19 16:40:54 which correlates to the icon in the navigation drawer Dec 19 16:40:59 which is like 48x48 Dec 19 16:41:19 so instead of having an m/h/xh/xx/xxx copy of both sizes Dec 19 16:41:30 I have a method in my application class Dec 19 16:41:38 ah I see, I got ya Dec 19 16:41:56 that takes a resource from R.raw and i just pass it a pixel value times the screen density Dec 19 16:42:20 and now i only have 1 vector file instead of 10 files Dec 19 16:42:29 png files* Dec 19 16:42:42 it doesn't seem like much for 1 or 2 things Dec 19 16:42:44 are you having issues, or you just getting a census of others like yourself? Dec 19 16:42:51 the latter Dec 19 16:42:57 cool Dec 19 16:43:05 because honestly Dec 19 16:43:10 if its something that people would be interested in using Dec 19 16:43:21 i know the android-svg lib isn't being supported anymore Dec 19 16:43:32 and i could create a more robust library for handling svg's in apps Dec 19 16:44:04 its your own custom library? IS THE raw file svg or png? Dec 19 16:44:41 has anyone here messed with the new camera API yet? especially with the nexus 6? Dec 19 16:45:48 laserix: the file svg Dec 19 16:45:52 is svg* Dec 19 16:46:03 cyonic, having a few more files was always worth having instead of performance penalty for SVG parsing and rendering Dec 19 16:46:05 at least in my apps Dec 19 16:46:16 interesting Dec 19 16:46:24 rasterization / decompression is so much faster than rendering SVGs, especially more complex ones Dec 19 16:46:41 i haven't experienced any performance issues except when poorly managing my resources Dec 19 16:46:43 plus, designers like it if they can improvise more :) Dec 19 16:46:55 cyonic, it's the usual dilemma Dec 19 16:46:55 my designer prefers svg's Dec 19 16:47:01 do you precompute resources Dec 19 16:47:06 yeah Dec 19 16:47:07 or do you push that to users phone Dec 19 16:47:16 very true Dec 19 16:47:33 hmm, even though, having a Gradle script that renders SVGs into drawable folder... could be pretty neat Dec 19 16:47:49 that would be interesting for sure Dec 19 16:48:03 im doing it in my activities/fragments Dec 19 16:48:15 i haven't even considered fucking with gradle scripts Dec 19 16:51:05 well you could just use an intent service and render alll of them to the phones specs on launch Dec 19 16:51:16 yeah for sure Dec 19 16:51:37 man, I've been developing for android for a year now, and I still feel like I know nothing Dec 19 16:52:56 pfn around? Your fix for using Return to enter statements in the sbt console doesn't work for me. Dec 19 16:53:11 Can you give me a hint as to what I might be doing wrong? Dec 19 16:54:29 marrrk, how are you using the fix? you installed a local build? Dec 19 16:54:38 I get this compilation error: Dec 19 16:54:56 [ERROR] class file for gnu.trove.TObjectHashingStrategy not found Dec 19 16:55:16 pfn: I downloaded your fork and am trying to build now. Dec 19 16:55:25 mvn package does the right thing for me... Dec 19 16:56:38 Hmm. Dec 19 16:56:52 Maybe install is too radical Dec 19 16:57:07 No, same problem. Dec 19 16:57:19 Is my command wrong? mvn -Didea.home="/Applications/IntelliJ IDEA 14.app/Contents" package Dec 19 16:57:55 maybe Dec 19 16:58:19 + 139.659.2 Dec 19 16:58:19 + C:/Program Files (x86)/JetBrains/IntelliJ IDEA 14.0.1 Dec 19 16:58:22 that's what I have mine set to Dec 19 16:59:06 marrk you doing cli? Dec 19 16:59:24 Hello guys. Dec 19 16:59:27 ( and girls ) Dec 19 16:59:29 marrrk, no Content Dec 19 16:59:52 in as, you can pick trove out of the list of dependences for maven central Dec 19 17:00:03 I have this new tablet but when I try adb shell it I get: error: insufficient permissions for device Dec 19 17:00:09 pfn: I think on OS X I need the content, otherwise I get this: The following artifacts could not be resolved: com.intellij:openapi:jar:110.187, com.intellij:extensions:jar:110.187, com.intellij:idea:jar:110.187, com.intellij:jdom:jar:110.187, com.intellij:util:jar:110.187, com.intellij:annotations:jar:110.187: Could not find artifact com.intellij:openapi:jar:110.187 at specified path /Applications/IntelliJ IDEA 14.app/lib/openapi.jar Dec 19 17:00:29 My other android device gives no problem on the same Ubuntu setup. Dec 19 17:00:32 marrrk, dunno then, I can give you my zip if you want Dec 19 17:00:42 So its something with the device ( my New one ). Dec 19 17:00:42 pfn: That migh be easiest, would be great. Dec 19 17:00:57 lasserix: What does that mean? What is a trove? Dec 19 17:01:22 you said this? [ERROR] class file for gnu.trove.TObjectHashingStrategy not found Dec 19 17:01:37 trove isa library that allows primitive based collections Dec 19 17:02:15 ok I will read all these google articles then. Dec 19 17:02:16 tsk. Dec 19 17:02:21 but thanks for listening :). Dec 19 17:02:42 Unknown0BC: make sure debugging enabled Dec 19 17:02:43 lasserix: I see. Dec 19 17:02:44 https://github.com/pfn/android-sdk-plugin/commit/9b1e7afe1c2474224ac162eb2dd9ae0599ffd54a Dec 19 17:02:46 heh, that wasn't so bad Dec 19 17:02:57 lasserix, yeah thats sure. Dec 19 17:03:05 unknown0bc, did you give your pc permission on your device, the rsa thing? Dec 19 17:03:07 marrrk, dunno why you'd be looking for trove... Dec 19 17:03:17 marrrk, sounds like your maven install fucked up, or you have gcj or something Dec 19 17:03:21 I certainly am not. Dec 19 17:03:21 whatitis, where do I do that ? Dec 19 17:03:29 I am merely looking for freedom. Dec 19 17:03:30 whatitis, on the device ? Dec 19 17:03:41 its kitkat Dec 19 17:03:53 But your zip worked perfectly, this is so nice. I just have to unlearn pressing shift cmd every time now. Dec 19 17:04:07 yea, screen pops up on device asking if youmwanna give permission to pc when plugged in Dec 19 17:05:14 whatitis, my device is not doing that. Dec 19 17:05:15 marrrk, yeah, it's annoying; but sometimes it's a little buggy, I haven't figured out why, the plugin stops accepting commands sometimes and need to re-open the project Dec 19 17:05:45 pfn: Reopen in IntelliJ or the sbt console? Dec 19 17:06:09 reopen the intellij project Dec 19 17:07:21 Unknown0BC: you read this? http://developer.android.com/tools/device.html Dec 19 17:07:45 particularly #3 Dec 19 17:11:26 I found the problem, for those interested: When kitkat is in USB storage mode adb is not going to work. Dec 19 17:11:32 thanks guys. Dec 19 17:11:44 now I can take an hour off. Dec 19 17:11:47 cheers ! Dec 19 17:11:50 \0 Dec 19 17:12:12 pfn: That sounds a bit annoying. But at least I know the workaround now. Dec 19 17:12:24 marrrk, doesn't happen too often Dec 19 17:12:32 I should figure it out some time Dec 19 17:12:34 * pfn shrugs Dec 19 17:13:53 oh yeah doh Dec 19 17:23:12 Is it okay to write a loop in a test? Dec 19 17:23:27 no never Dec 19 17:24:27 doing so will break the seal that binds cthulhu in the underworld unleashing cthulhu's wraith upon earth for all time Dec 19 17:24:51 Thought so. Dec 19 17:25:07 I'll stick to recursion then. Dec 19 17:25:40 why Dec 19 17:25:46 are you asking this question? Dec 19 17:26:03 Because the loop version is shorter. Dec 19 17:26:29 what does loops have to do with testing? Dec 19 17:27:10 Nothing really. I just try to avoid loops in general. Dec 19 17:33:02 im having a problem with my navigation drawer... when i try to put a LinearLayout in the drawer (so i can have more than just a ListView), i get a ClassCastException :( Dec 19 17:33:08 stack trace here: http://pastebin.com/ffmnKy6d Dec 19 17:33:24 layout xml here: https://github.com/drinfernoo/Cuber/blob/master/app/src/main/res/layout/activity_main.xml Dec 19 17:33:27 anyone know anything about flashing roms, rooting etc? Dec 19 17:33:44 activity here: https://github.com/drinfernoo/Cuber/blob/master/app/src/main/java/com/blango/cuber/BaseActivity.java Dec 19 17:34:03 drawer code here: https://github.com/drinfernoo/Cuber/blob/master/app/src/main/java/com/blango/cuber/NavigationDrawerLayout.java Dec 19 17:34:06 any ideas? Dec 19 17:34:21 Teeed, #android-root is the channel for that. Dec 19 17:34:28 Teeed, i know some, but you might be better off in #android-root Dec 19 17:34:31 lol Dec 19 17:35:29 yeah Dec 19 17:35:31 thank you a lot ;) Dec 19 17:35:34 drinfernoo: Put your LinearLayout inside the DrawerLayout Dec 19 17:35:41 it is Dec 19 17:35:46 check my XML Dec 19 17:35:57 damn, now when am I ever gonna build shit with java so I can try out retrolambda more, heh Dec 19 17:36:47 pfn: Is that so interesting? Dec 19 17:37:00 sure, why not Dec 19 17:39:38 Does it work on Android? Dec 19 17:40:06 yes Dec 19 17:40:11 that's kind of the point of dicking with it Dec 19 17:40:28 isnt retrolambda kind of hack? ;) Dec 19 17:40:46 There are no closures in Java 8, right? Dec 19 17:41:06 of course there are Dec 19 17:43:06 is it because its trying to open the drawer as the listview instead of the layout? Dec 19 17:44:18 why are you extending drawerlayout Dec 19 17:45:54 the error seems quite obvious Dec 19 17:46:03 closeDrawer(lvDrawer) but lvDrawer isn't a child of your drawer layout Dec 19 17:48:41 Cool, I thought there were only lambdas. Dec 19 17:53:07 kind of senseless to add lambdas but not closures around them Dec 19 17:58:17 there are a lot of things that are kind of senseless in Java Dec 19 17:58:57 Hmm, there are? :) Dec 19 18:05:50 How can I get a reference to a toolbar menu item that I initialized as stand alone? I usually do this in oncreateoptionsmenu where I have a reference to "Menu", but if I set it up stand alone calling inflatemenu in my main oncreate method I lose this ability. Dec 19 18:06:47 Toolbar has a getMenu method Dec 19 18:08:33 Ok thanks, ill look at that Dec 19 18:09:22 Is savedInstanceState null or does is it an empty bundle? Dec 19 18:10:37 marrrk: That's documented Dec 19 18:12:04 Ah you are right. It is null if there was no saved state in case you were wondering. Dec 19 18:13:17 marrrk, sorry i got disconnected. i havent figured that thing out yet, but j did try something different in my code... links are still good, new stack trace here: http://pastebin.com/FxBjS872 Dec 19 18:13:33 terrible code Dec 19 18:13:39 i cant figure out what its doing in drawerlayiut thats messing me up Dec 19 18:13:58 because you're doing closeDrawer on a view that isn't a child of the drawerlayout Dec 19 18:13:59 duh Dec 19 18:14:23 but im not Dec 19 18:14:25 I haven't had a look at the actual code, drinfernoo but I saw pfn give you some anser. Dec 19 18:14:38 I guess answer really doesn't need a w. Dec 19 18:15:11 but you ar3e Dec 19 18:15:15 I told you exactly the answer drinfernoo Dec 19 18:15:26 so which view should i be calling it on? Dec 19 18:15:37 er Dec 19 18:15:39 Error:Failed to find: com.android.support:appcompat-v7:21.+ Dec 19 18:15:46 if i call it on the linearlayout, it tells me it "isnt a sliding drawer" Dec 19 18:16:14 someone told me to do that yesterday but it doesn't seem to work. does that have to be a specific number? Dec 19 18:16:50 Rad-: Do you have the support library downloaded in the SDK Manager? Dec 19 18:17:46 drinfernoo, first, start off by not subclassing drawerlayout, that's flaw #1 Dec 19 18:18:02 second, only operate on direct descendants of drawer layout Dec 19 18:18:49 do you mean in my layout?? or in code? im directly operating on a linearlayout that is contained in my drawerlayout Dec 19 18:19:04 and everything that ive read says TO subclass drawerlayout Dec 19 18:19:19 drinfernoo: Why are you subclassing it? Dec 19 18:19:47 because all the guides i can find have told me to? lol Dec 19 18:20:01 am i not supposed to? Dec 19 18:20:34 no one ever says to subclass drawerlayout Dec 19 18:21:00 so should i just use drawerlayout, or start from scratch? Dec 19 18:21:10 @kroot: do you still work for Play? Dec 19 18:21:13 I don't understand what you are gaining from it. Dec 19 18:21:55 hello guys, Dec 19 18:22:07 I just updated my project to sdk 21 Dec 19 18:22:20 but facing issues Dec 19 18:23:37 http://pastebin.com/2yEWMdq1 Dec 19 18:23:42 this is the error I a facing Dec 19 18:23:45 am facing** Dec 19 18:23:49 any suggestions please Dec 19 18:23:52 i guess i did it so i could interact with my drawer from my activoty Dec 19 18:24:52 so i could setup toggles and add nav items and such Dec 19 18:25:48 guys I have updated everything Dec 19 18:26:02 android studio and all libraries Dec 19 18:26:20 good for you Dec 19 18:26:36 if everything works, you can get nobel prize for peace Dec 19 18:27:04 any suggestions? Dec 19 18:27:11 @ashiren Dec 19 18:27:25 drinfernoo: Are you declaring the DrawerLayout in the xml or programatically? Dec 19 18:27:33 in xml Dec 19 18:27:53 So how are you subclassing it then? Dec 19 18:27:54 neo3: do you have support library project referenced as well? Dec 19 18:28:14 yes Dec 19 18:28:17 hmm Dec 19 18:28:22 wait I will send my gradle snippet Dec 19 18:29:24 http://pastebin.com/DAtAhLUg Dec 19 18:29:26 see this Dec 19 18:29:36 updated with my gradle snippet in dependencies{ Dec 19 18:29:45 in build.gradle Dec 19 18:29:48 any help? Dec 19 18:29:49 on this Dec 19 18:29:53 I am clue less Dec 19 18:30:14 im using my own layout in the xml Dec 19 18:31:05 neo3: I haven't really used gradle but have you tried syncing/ Dec 19 18:31:30 yiati: i've been using the AUR instead of the SDK mnager Dec 19 18:31:43 drinfernoo: I would go with pfn's advice and try without subclassing. Dec 19 18:32:58 yiati: this thing maybe? https://aur.archlinux.org/packages/android-support/ Dec 19 18:35:27 Rad-: Looks like it. You do need to have the support library installed for it to find com.android.support Dec 19 18:37:56 and just do any manipulation with the drawer and fragments in my activity then? Dec 19 18:39:34 AS 1.0.2 Dec 19 18:40:44 hey guys, i`m not sure if this is a bad/good idea: putting shared functions (functions that more than one activites/classes use ) in application class and accessing/executing them through application-object. Dec 19 18:40:46 Searching the web a few say its ok/few say to not do it but couldnt find a reason yet why i shouldnt. What do you all say? and if you think one should not->why not? Dec 19 18:43:31 drinfernoo: Also as far as your crash goes it looks like you are trying to set the layout params of the DrawerLayout programatically? Dec 19 18:46:25 Looks like you could be trying to call myDrawerLayout.setLayoutParams(DrawerLayout.LayoutParams layoutParams) when you should be calling myDrawerLayout.setLayoutParams(LinearLayout.LayoutParams layoutParams) Dec 19 18:46:27 http://goo.gl/zZURa Dec 19 18:47:11 adkins: It’s easy to go overboard with it, and now your entire app depends on the application object Dec 19 18:47:39 Kind of tricky but the ViewGroup class you choose for myViewGroup.setLayoutParams() should NOT be the type of ViewGroup of myViewGroup, but of the container ViewGroup of myViewGroup Dec 19 18:47:41 depending on the nature of these methods, you might be better just making static Util classes Dec 19 18:50:43 s73v3r: what dou you mean by overboard exactly? should my app not depend a lot on the application object? why not? Can some activity be active but appObject be killed or something? Dec 19 18:53:01 Hi is this valid? float[] m=new float[16]; JSONArray ja= new JSONArray(m); Dec 19 18:53:50 it makes it hard to test your activities, and it makes it hard to reuse them Dec 19 18:56:00 s73v3r: can you give an example for that? i cannot see why it makes it harder to test an activity if it is accessing static functions in a util-class VS. accessing a function in application class Dec 19 18:57:15 panda81: Did you create a Java file and test it out? Dec 19 18:57:38 oops, sourcetree update broke all the things Dec 19 18:57:55 A static Utils class is far less likely to be storing state. Keeping a method on the Application object almost encourages this. Dec 19 18:59:29 yiati: I'm on a platform that I can't see compiler errors. This code doesn't work. If I do new JSONArray() without the argument, then no problem Dec 19 19:00:38 but I don't see what may be wrong. The doc is http://developer.android.com/reference/org/json/JSONArray.html#JSONArray%28java.lang.Object%29 Dec 19 19:00:44 Just out of curiosity, what platform can you develop on, and not see compiler errors? Dec 19 19:01:12 a Phonegap plugin Dec 19 19:02:24 Should still be able to open up a java file and try it out then right? Dec 19 19:03:02 you mean like with javac? Dec 19 19:03:11 sure Dec 19 19:03:48 Question regarding adapting application for multiple android versions. I have my main activity extending FragmentActivity from support lib so that I can display GoogleMap across whole screen and some controls on top of it. However for newer versions of Android I want to you the Flow/Drawer Layout will this cause problems ? Is there a way to keep compatibility ? Dec 19 19:04:07 s73v3r: thank you, my situation is: i have maany shared variables in application-class and a few shared functions. What you are saying gives me the impression that i should not store "states" in application class. Just to clarify: what do you mean by "state"? Dec 19 19:04:28 yiati: Guess I have to find the Android lib paths? JSONArray isn't standard java right Dec 19 19:04:52 panda81, right Dec 19 19:04:59 panda81, no Dec 19 19:05:04 it is standard java Dec 19 19:05:06 Since I will be extending FragmentActivity from support lib/package instead of Activity will I still be able to use the Drawer/Flow layout ? Dec 19 19:05:06 http://developer.android.com/reference/org/json/JSONArray.html Dec 19 19:05:18 like, application state. like i guess all those shared variables. their use should be minimized, as they are essentially global variables Dec 19 19:05:36 org.json.JSONArray extends java.lang.Object Dec 19 19:05:48 oh then I can use those online java compilers Dec 19 19:05:54 That too Dec 19 19:07:37 s73v3r: "their use should be minimized, as they are essentially global variables" why should be minimized? why should i not have too many global variables? Dec 19 19:07:56 how many are ok? how many are not ok? Dec 19 19:07:57 ;) Dec 19 19:08:09 hmm, first one I tried I get /tmp/java_kSAhIU/HelloWorld.java:7: error: package org.json does not exist Dec 19 19:08:11 import org.json.JSONArray; Dec 19 19:08:18 because they can change at any time. You have no idea what is going to be changing them or when Dec 19 19:08:49 panda81, this class is part of the android SDK, not of _standard_ java. Its part of javaee though Dec 19 19:08:55 holy hell Dec 19 19:09:01 what jsut happened? Dec 19 19:09:10 le split de net Dec 19 19:09:13 we have purged the nonbelievers Dec 19 19:09:19 panda81: sorry I was wrong it is not standard java Dec 19 19:09:19 ha Dec 19 19:09:34 panda81: it's org.json so json.org Dec 19 19:10:20 ok. Then most online compilers prob dont have it Dec 19 19:10:48 s73v3r: do you mean like: several activities access a application-class-variable and i have no control over when which function is when accessing it? Dec 19 19:10:55 yes Dec 19 19:10:56 I'll have to remember how to javac like 1997 Dec 19 19:11:00 panda81: Yep you can just do it locally Dec 19 19:11:14 although it doesn’t have to be an activity. Anything can access the application object Dec 19 19:11:29 How can I simulate my app being kicked out and resumed? Dec 19 19:13:35 And how do I set the notification bar colour to be transparent on L? Dec 19 19:13:48 hey, what’s the current best way to integrate Robolectric with Android Studio 1.0 Dec 19 19:15:02 s73v3r: so i assume its ok to use shared variables in application class if i can still overlook the use of them f.i. onCreate gects called writes to shared var, onResume reads from it (its ok because it comes afterwards) and so on? Dec 19 19:15:46 why does that have to be a shared variable? why can’t it live on the Activity? Dec 19 19:16:03 right, stupid example ;) Dec 19 19:16:17 Hi Dec 19 19:16:54 How I can get new sms (on receive) but after store to local database Dec 19 19:17:01 s73v3r: i write to a shared variable in preferenceactivity and read from it in Activity in onResume to adapt some settings Dec 19 19:17:54 you don’t need to hang the shared preferences off the application object Dec 19 19:17:55 I mean, I have receiver for android.provider.Telephony.SMS_RECEIVED, and on receive I can get message from extrafields (read pdu and etc) Dec 19 19:18:34 s73v3r: what do you mean= Dec 19 19:18:48 But I want to get message with new message id and some additional things, like thread_id and etc Dec 19 19:19:27 are you saving the preference in the SharedPreferences? If so, you don’t need to involve the Applicaiton activity Dec 19 19:19:27 Once I try use code like Cursor cursor = App.mContext.getContentResolver().query(Uri.parse("content://sms/inbox"), null, null, null, null); in receiver function I get previous SMS, not new Dec 19 19:21:03 I think, I get sms data before sms will be stored to local db. May be I wrong, but as shows my experiments it is true :) Dec 19 19:21:38 Jovi how do you know a new sms came ? Dec 19 19:22:24 g00s: I create BroadcastReceiver and configure in manifest intent filter for it Dec 19 19:22:58 hm. maybe it would be best to use a contentresolver on content://sms/inbox Dec 19 19:23:00 s73v3r: no, i dont mean sharedpreferences. I make some changes in PReferenceActivity, store these changes in sharedPReferences, yes, but in a variable in my application-class i write the information that changes happened f.i. BooleanRedesignActivity. If it is true i read in onResume of Activity the settings from sharedVariables... Dec 19 19:23:09 "on receive" event works. I can get sms from extra fields in intent Dec 19 19:23:12 oops, contentObserver Dec 19 19:23:33 If I supply a Comparator to an ArrayAdapter via sort(), will it stay sorted across mods via the Adapter? Dec 19 19:23:56 that seems far, far more complex than simply having your Activity look in the shared prefs Dec 19 19:23:56 Or must I call sort "manaully" between each mod and redisplay? Dec 19 19:24:07 *manually Dec 19 19:24:09 g00s: I think about it. It will work if device sleep? Or observer calls on device wakeup? Dec 19 19:24:22 no] Dec 19 19:24:53 g00s: now, If I get new sms, I get it immediately. It good for me Dec 19 19:25:32 ok. I should configure observer on "on receive" event :) Good way? Dec 19 19:25:34 StingRay` might now what the problem is Dec 19 19:28:26 Ihi Dec 19 19:28:29 oooh, nice https://code.google.com/p/android/issues/detail?id=65445 Dec 19 19:28:47 s73v3r: well i wouldnt say it is more complex, its about the same (1 line). I dont want to get hung on this example....my question is just: if i can overlook the use of shared-variables in applicaion-Class is it ok to use them? Dec 19 19:28:48 i should avoid accessing it from too many activities/classes, because it might give me false results. Would you confirm? Dec 19 19:28:51 i have this code, but the image is not showed, why? Dec 19 19:28:54 anybody can help me? Dec 19 19:28:56 pfn, soooo im not subclassing drawerlayout anymore, and im still getting the same classcastexception Dec 19 19:29:19 i called closedrawer on the drawerlayout Dec 19 19:29:26 told you, quit trying to close list view when it's not a child of your drawer Dec 19 19:29:29 it’s not an easy thing to get a concrete rule for Dec 19 19:29:37 why would you do something like that Dec 19 19:29:41 which is one of the reasons why they’re so iffy Dec 19 19:30:08 s73v3r: lol ;) damn. do you use them? Dec 19 19:30:13 what about the instances in which onCreate is not called, but onResume is? Like when returning from another activity, or the background? Dec 19 19:30:24 I try to use as few as possible, if any at all Dec 19 19:30:26 I assume it does, but just realized it might not. Dec 19 19:30:39 sweet! http://meta.stackexchange.com/questions/245731/help-us-test-the-stack-exchange-android-tablet-app?cb=1 Dec 19 19:30:47 try to keep your parts as self contained as possible Dec 19 19:31:12 i see Dec 19 19:32:04 the more loosely coupled they are, the easier it is to change the individual parts without having to worry about the rest of the app Dec 19 19:32:59 Guys still facing this issue after updating my libraries Dec 19 19:33:00 http://pastebin.com/DAtAhLUg Dec 19 19:33:06 any suggestions on this Dec 19 19:33:16 drinfernoo: Did you check out my message above about setLayoutParams Dec 19 19:35:02 I have updated my android project to L Dec 19 19:35:07 s73v3r: alright, thank you, very informative-talk. I`m gonna start with a utils class with shared static functions (just a few) and will do some refactoring regarding shared-vars in application-class Dec 19 19:35:21 neo3 hm, you don't need support if you have appcompat, but thats probably not it Dec 19 19:38:05 as in? Dec 19 19:41:12 yiati, i was disconnected :/ Dec 19 19:43:31 app is not able to fetch in some classes from the app Dec 19 19:43:35 any idea why so? Dec 19 19:44:39 this issue is being faced after I upgraded play services, support library Dec 19 19:44:43 :( Dec 19 19:52:04 pfn, whats it supposed to be called on? no matter which view i call it on, i get the same problem Dec 19 19:52:51 question: how do you guys prefer to create a custom view that has an XML layout? Dec 19 19:53:02 do you bother with to reduce nesting? Dec 19 19:53:10 is there a cleaner way? Dec 19 19:53:50 Hi, I'm making an app that displays nearby restaurants as a list but also as a map. I want the user to be able to quickly switch between the two views so I want the two views to be able to remember their respective state. Is there an easy to way to keep the state of these two views in memory? Would fragments work here? On a phone, the two views would never be visible at once. Dec 19 19:54:03 I usually and subclass one of the layouts Dec 19 19:54:13 linearlayout or frame most often Dec 19 19:54:17 zambo what about xml preview for linearlayout? Dec 19 19:54:29 do you use the tools: namespace and create a useless parent layout so the preview works? Dec 19 19:54:52 like this: https://code.google.com/p/android/issues/detail?id=61652 Dec 19 19:55:00 Sometimes - honestly I don’t always use the preview Dec 19 19:55:01 tools:showIn Dec 19 19:55:29 it's a critical tool for me. i'm looking for a clean way, without nesting, to create a custom view with an xml layout that doesnt' have unnecessary nesting Dec 19 19:55:33 spuz: Fragments would be your best bet Dec 19 19:55:41 or just plain views Dec 19 19:55:50 for a map, use a mapfragment Dec 19 19:55:59 otherwise you're writing a lot of boilerplate Dec 19 19:56:01 s73v3r, ok and should the two fragments be on the same activity? Dec 19 19:56:09 yes Dec 19 19:56:11 how would I be able to tell if the orientation is changing? I know I can set onConfigurationChanged.. but that is fater the fact.. Dec 19 19:56:11 ok thanks Dec 19 19:56:14 after* Dec 19 19:58:27 isChangingConfigurations () Dec 19 19:59:43 JacobTab_ I would definitely avoid nesting views, especially if your custom view appears in a listview or recycleview Dec 19 20:00:10 thanks :P Dec 19 20:00:20 is there even an android 3.0 or 3.2 anymore? Dec 19 20:01:32 not really Dec 19 20:01:59 there never really was lol Dec 19 20:02:25 good.. I’m thinking about changing API requirements to 13 Dec 19 20:02:33 change to 15 Dec 19 20:03:29 if you’re going to get rid of Gingerbread, why not go full on to Ice Cream Sandwich? Dec 19 20:04:01 JacobTak_ One dummy layout per view parent (LinearLayout, FrameLayout) with all of your custom views included could do the trick. I’m new to gradle/product flavors but you could probably use that (or possibly resource qualifiers) so that it doesn’t appear in your layout/folder (or at least the same layout folder as all your other layouts) or get included in your build Dec 19 20:04:13 just a little worried that some peopel will get bumped out.. a few days ago someoene called with a Gingerbread phone who was unable to locate our app in the store. minSDK is 3.0 Dec 19 20:04:22 not the cleanest but once you set it up it could work Dec 19 20:04:38 that;s why I asked about 3.0 and 3.2, s73v3r Dec 19 20:05:00 according to this there are no devices on 3.0: https://developer.android.com/about/dashboards/index.html Dec 19 20:06:13 There are no devices on 3.0 that Play has stats on :P (effectively the same thing) Dec 19 20:06:45 you should have said "Sorry, according to the official Google records your device does not exist. Call us back when you have something real." Dec 19 20:07:03 lol. almost did that with pantechs Dec 19 20:07:41 tricknology: actually, it likely means that there are so few devices that it's been dropped from the graph Dec 19 20:07:51 not that there are actually *no* devices Dec 19 20:09:27 Yeah I understand JesusFreke, for all intents and purposes zero though it could be considered insignificant. Dec 19 20:10:07 Hello! When setting app merchant account do I need to use my real address and name and that would be public at Google Play? Also, "Business name"? I don't have any business, I just want to distribute as an individual Dec 19 20:10:41 JesusFreke i really think there are no device. google ai probably sent a terminator back in time to supress the launch of all HC devices Dec 19 20:10:56 po box ice Dec 19 20:13:13 <_Auron_> it's such a huge relief to get a beta run complete for a project and then get to go home for vacation. omg Dec 19 20:13:39 yeah seriosily just sent apk to client myself :) Dec 19 20:13:49 apk friday!!! Dec 19 20:13:53 horray Dec 19 20:14:18 anyoen use wireless adb? Dec 19 20:14:24 (without root) Dec 19 20:14:26 sure Dec 19 20:15:55 g00s just chekced the Analytics on the app I am working on, it has been in the store just over a year. 107k total sessions, 9 of them were from HC. haha, interesting Dec 19 20:16:22 how does that even happen? Dec 19 20:16:27 hc? Dec 19 20:16:35 honeycomb Dec 19 20:16:39 3.x Dec 19 20:16:49 ah Dec 19 20:17:27 so 9 out of 107400ish Dec 19 20:18:40 wow Dec 19 20:18:57 thats like, sarah connor, her son, and a few friends Dec 19 20:19:06 loL!!@ Dec 19 20:19:57 HAHA Dec 19 20:21:21 Q: if a DB is open, and onDestory is called and the db is not closed should I expect an error? Dec 19 20:21:29 no Dec 19 20:21:38 don't close the db Dec 19 20:21:40 tho it will throw message in logcat Dec 19 20:22:07 ok thanks :) Dec 19 20:22:10 JacobTab_, I only use merge but never the preview Dec 19 20:22:17 how do people not use the preview Dec 19 20:22:18 i dont get it Dec 19 20:22:32 how not, it's mostly useless Dec 19 20:23:08 i think we disagree on that Dec 19 20:23:10 i haven't gotten preview in AS working yet for anything but the simplest views Dec 19 20:23:36 where i don't need preview :} Dec 19 20:23:47 i just pay a lot of attention to graphical detail... if i had to run the app to test every little thing i'd never finish Dec 19 20:24:09 I generally know the numbers I want to use Dec 19 20:24:22 previewing it doesn't really make me any faster Dec 19 20:24:38 well i guess that's great for you Dec 19 20:24:41 :D Dec 19 20:25:00 come on JacobTab_ you don't know your numbers ? Dec 19 20:25:03 lol Dec 19 20:25:09 @dimen/small, @dimen/medium, and @dimen/large Dec 19 20:25:11 those are my 3 numbers Dec 19 20:25:14 4 Dec 19 20:25:15 everything 4dp Dec 19 20:25:17 4 8 and 16 Dec 19 20:25:34 32sp for text Dec 19 20:25:40 i kid Dec 19 20:25:46 lol Dec 19 20:26:55 I wonder if braille has different fonts and font sizes Dec 19 20:27:00 liek is there a caps? Dec 19 20:27:05 but for material you multiply your dimens by at least 2 Dec 19 20:28:09 time to set up a dual n-back regime for memorizing material dimens Dec 19 20:28:23 i have a dimen file of all the dimensions the metrics webpage Dec 19 20:28:31 formaterial Dec 19 20:32:24 i have a dumb question; are there any devices where you can run apps side by side ? so that even if your app is in the foreground, the user could have done something in another app that effects the state of yours ? Dec 19 20:32:46 didn't samsung have something like that? Dec 19 20:33:13 i made an assumption on onStart() - if bt is enabled i assume it stays that way, because to change it you would probably have to leave the app Dec 19 20:33:18 JesusFreke maybe :| Dec 19 20:33:36 oh thats a bad example, because you can change it from the pull down thingy on the status bar Dec 19 20:33:43 yeah Dec 19 20:33:43 g00s: hmm. isn't there a toggle for it in the status pull-down thingy? Dec 19 20:33:45 yeah Dec 19 20:33:49 one of the apps has something that does that Dec 19 20:33:51 forget which Dec 19 20:34:02 g00s: hahaha. I love that we both used the same description Dec 19 20:34:09 one of the device manufacturers Dec 19 20:34:21 JesusFreke hehe Dec 19 20:34:50 i've seen event interrupt callbacks registered unregistered in onstop/onstart seems like it is the proper way to do it but is it necessary? Dec 19 20:34:57 Samsung has multi window Dec 19 20:35:07 or by not doing it are we leaking resources/ or something? Dec 19 20:35:57 lasserix any listeners i setup are usually in onStart, and removed in onStop Dec 19 20:36:08 yeah Dec 19 20:36:08 maybe except loaders when i used those Dec 19 20:36:12 i guess i will start doing that Dec 19 20:38:53 i like how my tracks has been updating for the past three days Dec 19 20:41:03 Hi all. Quick question: I have one advertisement on my main menu in the app I have building. Should I take this ad off the main UI thread? Will it make things smoother? Dec 19 20:44:12 prolly Dec 19 20:53:16 if it changes a view and isnt like a survaceview it has to be on the main thread I believe Dec 19 21:01:27 is it possible/feasible to run Android apps stand-alone on linux? Without emulator/VM, but with a lightweight player? Dec 19 21:02:45 afaik the closest to a "lightweight player" that exists is whatever ChromeOS is doing to run (a small number of?) android apps. but I have no idea if that's a general solution, or how far away it is from wider use. Dec 19 21:04:02 Groxx, when I googled I did indeed stumble upon this chrome thing. But, really? Should an android player/emulator be integrated into a web-browser? I think that's a weird idea to put it lightly Dec 19 21:04:59 agreed :) but Google seems to want to turn Chrome into a fully-fledged OS. Dec 19 21:05:25 Groxx, I have to think about emacs for some reason :P Dec 19 21:05:29 is it running in the browser, or on ChromeOS as a separate kind of process ? Dec 19 21:05:30 haha Dec 19 21:06:07 I found this guide to run android on any system with chrome installed. http://lifehacker.com/how-to-run-android-apps-inside-chrome-on-any-desktop-op-1637564101 Dec 19 21:06:14 g00s: no clue. haven't looked into it really. Dec 19 21:07:10 " This is still eight million kinds of broken " Dec 19 21:07:18 slightly more broken then usual Dec 19 21:07:41 VladolfPutler: is the problem just that the emulator is slow and annoying, or is there a different reason you don't want to use an emulator? Dec 19 21:09:32 Radther: interesting link, thanks :) Dec 19 21:11:43 Groxx, in the old days emulator was slow, but since some update a few years ago it's fast, and I can always use a Virtualmachine with x86 android. But it's just I like clean/lightweight/straightforward solutions Dec 19 21:12:08 I imagine something like a commandline tool "tool whatever.apk" Dec 19 21:12:15 and then a window would popup with the app Dec 19 21:12:22 but I don't know if something like that is even feasible Dec 19 21:12:29 yeah, understandable. just wanted to make sure it wasn't something easily(ish) solved like "use x86 + haxm" :) Dec 19 21:13:03 Groxx, there's no problem at all, just looking for improvements ;) Dec 19 21:15:28 tbh I think Android makes "lean simulator" difficult. loooots of system services, lots of apps that drop into the command-line / native code / use a library that has native code, etc. a restricted-feature-set one would be useful for some things though, like faster iteration on UIs. Dec 19 21:16:14 iOS's simulator is impressively good, but it's also a lot more constrained Dec 19 21:16:54 VladolfPutler MS makes an Android emu that is supposedly better than the Google one. i don't know hot to get it though, i think its for xamarin dev Dec 19 21:17:15 ooh, interesting Dec 19 21:17:16 Groxx: I would definitely kill for something that made UI iterations a little quicker. Dec 19 21:18:20 It's for the latest visual studio. http://blogs.msdn.com/b/visualstudioalm/archive/2014/11/12/introducing-visual-studio-s-emulator-for-android.aspx Dec 19 21:18:31 Radther: yeah, I hear ya :) I've been wondering how much work it would be to build something to enable runtime creation / modification of UIs -> provide a UI to inject code, tweak views, etc. Dec 19 21:19:08 Groxx: If you ever do build something like that I would definitely be first inline. Dec 19 21:21:16 "Slow. This is the number one complaint we’ve heard from Android developers." Dec 19 21:21:26 see, MS listens to developers :) Dec 19 21:22:14 I have heard a lot of good things about Microsoft developer support. Dec 19 21:23:06 when we had MSDN, it was great being able to call somebody and ask a question about an API Dec 19 21:23:23 i think we were allowed x support calls per month Dec 19 21:23:47 * g00s previous life win32 Dec 19 21:24:31 That does sound pretty cool. Documentation can certainly require some further explanation for it to make sense sometimes. Dec 19 21:31:58 heh. sounds like MS built a better emulator _period_. though arguably most of that belongs in DDMS (since, in Eclipse (does AS have this yet?) you can generate phone / location events) Dec 19 21:32:47 most of that sensor stuff seems like it belongs in a common source of some kind that emulators read from. though maybe the standard ones aren't capable of it. Dec 19 21:47:43 Just wondered what you guys think the best way to add animations to a listview is. I have tried adding an animation to an adapters getview method but every time the keyboard pops up the lsitview replays the animation again. Dec 19 21:57:14 Radther you might have better luck with recyclerview in that area Dec 19 21:57:16 Radther: subclass Listview use drawChild Dec 19 21:57:27 OR switch to recyclerview which has a dedicated animation component Dec 19 21:58:46 Unfortunatily switching to RecyclerView isn't possible as I'm using Realm for my data and that comes with a listview adapter that I'm using to get the data. Not sure how to use Realm with a Recycler view. Dec 19 21:59:59 Just don't play animations every call to getView Dec 19 22:02:01 SimonVT: What would be the best way to decide whether an animation should be played or not? Dec 19 22:03:47 That depends on when you want it to be played Dec 19 22:04:15 Radther: drawChild is specifically included to be overridden to do listview animations Dec 19 22:04:56 lasserix: I will look into that now. Seems like the best thing I have seen so far. Dec 19 22:05:25 SimonVT: I want it to play for all views on first launch and then when a new item is added play for the new item. Dec 19 22:06:05 So keep a list of items you've played an animation for, don't play for those again Dec 19 22:08:05 Radther: you can add an id to ids.xml R.id.listview_row_animation_played then in getview add true setTag(R.id.listview_row_animation_played, false) then in drawChild if ((Boolean)getTag(R.id.listview_row_animation_played) { // do animation; setTag(R.id...., false) } Dec 19 22:09:59 lasserix: Quite new to this and that is very helpful, thank you. Dec 19 22:11:00 actually they may not work Dec 19 22:11:02 sorry Dec 19 22:11:05 but something like that could Dec 19 22:11:22 you prolly have to use list in the adapter of boolean or whatever Dec 19 22:11:56 Ok. I will use drawChild as a starting point and see what else I can find to get it working. Dec 19 22:12:14 lasserix: drawChild sounds like an interesting approach I haven't tried. have any examples? Dec 19 22:12:42 I could stumble into something, but odds are I'd miss some problem on e.g. 2.3.5 Dec 19 22:13:02 https://www.google.com/webhp?sourceid=chrome-instant&rlz=1C1CHWA_enUS574US574&ion=1&espv=2&ie=UTF-8#q=making%20your%20own%203d%20list%20%e2%80%93%20part%201 Dec 19 22:13:13 the first three results Dec 19 22:13:33 nice. thanks Dec 19 22:13:49 will definitely give them a read Dec 19 22:14:16 Yeah, seems really helpful. Dec 19 22:14:47 SimonVT: would you happen to be the "simon vt" who made Schematic? Dec 19 22:15:17 Yep :) Dec 19 22:15:52 cool. I'm going to start diving deeper into code generation, and it seemed worth reading that repo (eventually, not to start :) ) Dec 19 22:16:21 have any recommendations? e.g. good sources for info, "don't read my repo, it's horrible", etc? Dec 19 22:16:24 That was my venture into code generation, very fun Dec 19 22:16:28 Groxx one tool that works great for code generation is antrl stringtemplate Dec 19 22:16:36 *ANTLR Dec 19 22:16:42 Nah, just read my repo Dec 19 22:16:45 It's really simple Dec 19 22:16:52 * g00s worked on compilers for 5 years Dec 19 22:17:52 g00s: is it relevant for annotation processors? I'm curious, but gotta get something done some day, so I've gotta prune my interests somewhere :) Dec 19 22:18:19 oh, i haven't done anything with annotations in a while Dec 19 22:18:35 Groxx: JakeWharton did a talk on annotation processors Dec 19 22:18:47 Very useful Dec 19 22:18:52 Semi-useful Dec 19 22:19:07 yeah, I watched it. helpful anyway :) Dec 19 22:19:21 Semi-gratuitous keynote animations Dec 19 22:19:45 GRATUITOUS AMOUNTS OF ENERGYYYYY Dec 19 22:19:56 and the example code for the processor seems way more sane than most videos I've seen. most of them do thing X and then spend 30 minutes explaining why you're forced to do it, when it seems like most of it is semi-automate-able Dec 19 22:20:39 well, speakerdeck doesn't recreate the animations anyway :) Dec 19 22:21:06 ugh, so many projects to try out this coming vacation Dec 19 22:21:08 damn you all! Dec 19 22:21:26 I poked into annotation processors a _little_ a year ago or so, but never got very far, and didn't spend enough time to totally grok the system. so now I'm doing that. Dec 19 22:21:29 making me want to look into annotation processors now Dec 19 22:21:32 haha Dec 19 22:21:45 yeah, the internet is horrible there Dec 19 22:22:37 Groxx what would you like to write ? Dec 19 22:23:35 the internet is horrible for learning them Dec 19 22:23:39 g00s: dunno yet. a lot of it has been written and is semi-widely-used now. Dec 19 22:23:42 looking at existing ones is the best way Dec 19 22:24:37 g00s: part of it is just wanting to understand how existing ones work, which might mean I get to use them at work, instead of doing everything by hand. we're a bit too far down the "nothing magical" side of development, and I'm convinced it's hurting our productivity, but it's hard to pull it back without being able to argue intelligently Dec 19 22:25:04 i think you can be very productive without magic Dec 19 22:25:20 definitely. but the signal to noise ratio wastes a lot of our time. Dec 19 22:25:55 Radther: oh that method would work just make to set the tag to true in getview ONLY when the convertview is false Dec 19 22:25:56 also fancier things sometimes reveal better approaches that can't be easily incrementally-improved twoards Dec 19 22:26:04 sure Dec 19 22:26:07 *convertview is false -> is null Dec 19 22:26:20 but i think codegen is a better approach than anything reflection or bytecode manipulation based Dec 19 22:26:36 yeah, definitely. you can read it, you can debug it, sane stack traces, etc Dec 19 22:26:36 there's zero magic but you are still afforded massive boilerplate reduction Dec 19 22:26:39 yep Dec 19 22:27:16 JakeWharton: since you're here, any opinion on using Parcel to marshal a Parcelable to its byte format so that it can be written to disk? obviously the structure of the object can't change while it's written to disk since unmarshalling it back would fail, but then I could just treat it as a cache invalidation. Dec 19 22:27:17 lasserix: Thanks. That makes sense, will try that in a minute. Dec 19 22:27:24 I wrote a test library to try it out and it's super fast Dec 19 22:27:31 and was surprised nobody else does it Dec 19 22:27:31 parcelable's byte format is an implementation detail Dec 19 22:27:39 the documentation specifically says not to do that Dec 19 22:27:39 it's more that we have e.g. plenty of things that would fall right into AutoValue's ideal uses, but we instead have incomplete and occasionally buggy implementations instead. Dec 19 22:28:04 protocol buffers would be a much better choice and they have a migration story for changing the format of the object Dec 19 22:28:34 which means we've written, code-reviewed, and re-read several thousand lines of code that could be much more easily understood if it were @AutoValue instead. Dec 19 22:28:54 what is autovalue ? Dec 19 22:29:02 ask Google Dec 19 22:29:08 http://www.autovalue.com/ Dec 19 22:29:10 protobuffers have a lot more overhead while this is just a simple re-use of a parcelable object Dec 19 22:29:10 sweet Dec 19 22:29:15 g00s: https://github.com/google/auto/tree/master/value Dec 19 22:29:26 but yea you're right they are much more robust Dec 19 22:29:50 trevor-e: what overhead? i would argue it's less overhead Dec 19 22:30:24 to maintain the structure and then have it create the classes Dec 19 22:30:26 Any help on this? - http://stackoverflow.com/questions/27573500/android-project-not-working-after-updating-project-to-android-l?noredirect=1#comment43573499_27573500 Dec 19 22:30:46 Flatbuffers are even a bit faster and more efficient (also not as well documented :P ) Dec 19 22:31:35 also they have a gross API Dec 19 22:31:46 trevor-e: if you're lollipop+ there's a PersistableBundle. but yeah, protocol buffers / something else, the documentation is pretty explicit otherwise about parcelables and bundles being unsafe for serialization Dec 19 22:31:49 oh. yes. Dec 19 22:32:17 on the other hand, they're faster for transferring data over JNI boundary which is also funny Dec 19 22:32:49 yea I know it's unsafe, that's why I'd only use it as a fast disk cache Dec 19 22:33:03 https://github.com/trevor-e/Parcist Dec 19 22:33:06 if you're interested Dec 19 22:33:13 I am getting errors about insufficient storage available on my emulator. What should I set the size of the internal storage to to avoid this? Dec 19 22:33:24 I just see lots of people blindly use GSON to save things to disk and came up with this as a simple solution Dec 19 22:34:03 its time to code :D Dec 19 22:34:15 i mean, you have to be on a BG thread anyway Dec 19 22:34:23 trevor-e the format can change between android updates :| Dec 19 22:34:32 (and it has, historically) Dec 19 22:34:44 I'm migrating my project from eclipse to android studio. This project has a library (created by me) which is included in the project. But when I want to build the project, I do get "cannot find symbol class" errors. The classes exists, everything works fine when opening/running in eclipse. What could be the cause? Dec 19 22:34:46 neo3 is your styles / themes correct? Dec 19 22:34:53 yeah, but using Parcelable as a cache isn't really a problem Dec 19 22:34:55 so after updating android the app would crash, unless you protect against that somehow Dec 19 22:35:03 we covered that already Dec 19 22:35:11 since you just throw away the object when you can't deserialize it Dec 19 22:36:09 (it's also significantly faster than most things except the protobufs, flatbuf implementation which require you to do the whole code gen, schema and bunch of other boilerplate) Dec 19 22:38:12 @lasserix Theme.AppCompat.Light I am using Dec 19 22:38:24 re parcelable as cache: unless you're careful, wouldn't it be possible for an upgrade to mean you read valid _but incorrect_ data? Dec 19 22:38:42 I tried invalidate caches, clean project etc.. but none with a positive result.. Dec 19 22:39:04 Groxx: in theory yes Dec 19 22:39:16 you could solve that by encoding the versionCode as the first value Dec 19 22:39:24 or in the file name Dec 19 22:40:11 I mean an OS upgrade, not an app upgrade. and if versionCode is the first value, isn't that assuming that that doesn't get reordered in a new OS version? Dec 19 22:40:35 that would be fine, if it did you'd notice it was different and fail Dec 19 22:41:40 i am attempting to add the android L ripple animation to list view items, but it seems to only work on about 3 out of 10 of the list view items. If the activity/fragment is closed and re-opened there are still only a handful of these items that work, but they are different. Is there something that I am missing? Dec 19 22:41:48 in most cases, sure. every? say they reordered some of your ints, so you stared with [version, data, data2] [1, 1, 2] and you loaded it as [data2, version data]. successful load, incorrect data. Dec 19 22:42:06 ok so append the OS version Dec 19 22:42:25 see above. append OS version and… make sure to never serialize the same value anywhere in the parcel? Dec 19 22:42:49 i'm not arguing this is a good idea. but it's easy to make resilient Dec 19 22:43:06 see above. put it in the file name. Dec 19 22:43:27 or hash it Dec 19 22:43:29 ah, right. filename would avoid that. Dec 19 22:48:43 Aything on this ? -http://stackoverflow.com/questions/27573500/android-project-not-working-after-updating-project-to-android-l Dec 19 22:48:51 http://stackoverflow.com/questions/27573500/android-project-not-working-after-updating-project-to-android-l Dec 19 22:49:40 neo3: dunno. are you running proguard at all by any chance? Dec 19 22:51:39 eh, what is the task assembleDebug? When I compile using ./gradlew -x assembleDebug it builds successful Dec 19 22:53:24 -x means you don't do that task i think? Dec 19 22:55:15 No I am not using progurard Dec 19 22:55:17 :( Dec 19 22:55:54 Hey all. I have three layouts.xml files.. they are in res/raw/values, layout-sw600p, and drawable-xlarge. I want to access a resource that is different depending on the xml selected by the OS (based upon the screen size). How would I do that? Dec 19 22:56:04 yeah, but what does the task do? And why do I need it when I want to run it in the emulator (do I need it??) Dec 19 22:56:36 hi guys, I am using RubyMotion for Android and I'm getting this error after install on the application: java.lang.NoClassDefFoundError: com/rubymotion/Hash. does anyone know how I might solve this Dec 19 22:56:49 the rubymotion channels way dead Dec 19 22:57:07 well NoClassDefFoundError means that a class that is referenced in your app is not found Dec 19 22:57:09 the error is happening on the device Dec 19 22:57:23 seems like a bug in the build system, no idea how to fix Dec 19 22:57:23 could be that you’re missing a .jar Dec 19 22:57:35 no xp with rubymotion :( Dec 19 22:57:41 thats ok Dec 19 22:57:48 i figured i might learn something about java Dec 19 22:57:48 but that’s what causes it Dec 19 22:58:09 your app is looking for a class that is in com/rubymotion/Hash. probably the Hash class if there is one Dec 19 22:58:59 yeah, just dont know where to look i guess Dec 19 22:59:01 It is referenced somewhere but didn’t make it to your build path for one reason or another. It’s present at compile time but not runtime Dec 19 22:59:02 http://stackoverflow.com/questions/34413/why-am-i-getting-a-noclassdeffounderror-in-java Dec 19 22:59:17 hmmm Dec 19 22:59:18 “Look for differences in your build time and runtime classpaths.” Dec 19 22:59:30 do you use Eclipse? Dec 19 22:59:31 no idea how to do that in RM Dec 19 22:59:34 im using sublime Dec 19 22:59:39 eeh yeah idk Dec 19 22:59:47 i have android studio too but i mainly do ruby Dec 19 22:59:58 ruboto was easier than this, really, but just slow Dec 19 23:00:03 I answered that stack post i guess “Also check that Properties>>Java Build Path>>Order and Export>> importedJar.jar is checked.” Dec 19 23:00:22 again, I have no xp with it Dec 19 23:00:26 or AS for that matter Dec 19 23:00:28 the thing is that the stuff it's lacking, is a core part of the system Dec 19 23:00:34 but maybe you can import your project into AS and fix it there Dec 19 23:00:42 then export and reimport where you want it.. hacky but.. Dec 19 23:00:49 can't really, Dec 19 23:00:51 seems like it Dec 19 23:01:06 there's like no docs and nobody around that knows it most of the time lol Dec 19 23:01:17 lasserix: It's not perfect but I actually found another way to animate the list view when the app is opened. http://android-er.blogspot.co.il/2009/10/listview-and-listactivity-layout.html Dec 19 23:01:54 Then I wouldn’t use it Dec 19 23:03:21 heh that emulator is so painfully slow Dec 19 23:03:33 pretty nifty technique tho Dec 19 23:03:57 I have three layouts.xml files.. they are in res/raw/values, layout-sw600p, and drawable-xlarge. I want to access a resource that is different depending on the xml selected by the OS (based upon the screen size). How would I do that? Dec 19 23:04:25 why aren’t all of the layout XML files in layout directories? Dec 19 23:04:37 this is for orientation change Dec 19 23:04:51 res/raw... Dec 19 23:04:56 then those 3 different subfolders Dec 19 23:05:00 there’s a layout-land directory for landscape Dec 19 23:05:30 This is how it is in the documnetation Dec 19 23:06:21 http://developer.android.com/training/multiscreen/screensizes.html Dec 19 23:06:34 if it’s based on screen size, couldn’t you put the different versions in res/- Dec 19 23:07:25 meh, it works for now. I just need to be able to access the one boolean resource from whichever xml is loaded Dec 19 23:07:43 it’s just a bool? Dec 19 23:07:46 yeah Dec 19 23:08:01 isTablet Dec 19 23:08:10 then res/values- not necessarily bool.xml, but some file you put in there Dec 19 23:08:34 yeah but it’s not just in res/values Dec 19 23:08:52 res/values-hdpi, res/values-xhdpi, etc Dec 19 23:09:11 use the size based qualifiers on the values folder Dec 19 23:09:31 although using something like isTablet is generally a bad practice Dec 19 23:09:31 as I understand it, the system looks at the display size and uses the xml inside of whichever folder matches the display size Dec 19 23:09:45 so I can’t specify exactly which path because I don’t knwo it Dec 19 23:09:49 at runtime Dec 19 23:10:08 you don’t specifiy a path. You use getValue Dec 19 23:10:13 oh ok nice Dec 19 23:10:22 you treat it like any other resource value Dec 19 23:10:39 it might not be getValue, but you get the idea. Dec 19 23:11:07 looks like the default app is broken in rubymotion android Dec 19 23:11:26 :/ Dec 19 23:13:16 is it possible to redirect the android emulator network to the host dev computer something like tethering. I have web server running on the emulator but would like to brose the web content from the emulator on the dev computer browser Dec 19 23:13:39 nice.. how do I change a typedvalue to bool? Dec 19 23:15:55 type Dec 19 23:15:57 type= Dec 19 23:18:13 ah lol, I should jsut use getBoolean(); Dec 19 23:18:24 I'm creating a CardView and I want it to expand/collapse when I tap on it. Does anyone have any ideas on how to go about animating that? Dec 19 23:19:34 In my cardview, I am populating a GridLayout with two columns and eight rows when expended, then changing it to eight columns and one row when collapsed. This...sort of works...only when it expands, but it doesn't quite work 100% Dec 19 23:19:48 "This" being the animating Dec 19 23:30:39 What is the best way to resize buttons on a tablet vs phone? Dec 19 23:30:44 gynamically I guess Dec 19 23:32:45 does google analytics v4 api support dimensions? Dec 19 23:32:52 tricknology: I've been (fairly idly) trying to figure out the "best" way to do stuff like that. no luck. Dec 19 23:33:14 right? maybe eright? Dec 19 23:33:15 tricknology: I'm guessing you're thinking of e.g. scaling them up a bit, so they're easier to hit on a bigger screen? Dec 19 23:33:18 weight* Dec 19 23:33:24 yes exactly Dec 19 23:33:46 there is now more realestate but the buttons are for ants Dec 19 23:35:12 mmm ants Dec 19 23:35:18 one idea I've had (and feel free to tell me it's insane, I haven't gone all the way with it yet) is to put literally everything into styles. so there would be