**** BEGIN LOGGING AT Tue Mar 25 02:59:58 2014 Mar 25 03:00:42 i have an architecture question for best practices. if I have variables which are constant such as a web service end point where should I put that stuff? Mar 25 03:01:04 gradle build config :) Mar 25 03:09:20 thanks Mar 25 03:11:00 i am using intellij Mar 25 03:18:40 Mr_Grim: I would actually put them in a dedicated constants file. I like BuildConfig for things that should be obtained at compile time. Keeping those constants in a dedicated file let's you document them and helps keep your build.gradle cleaner Mar 25 03:19:35 yeah ill go with buildconfig for now Mar 25 03:19:41 gradle is going to take some reading Mar 25 03:20:55 hi Mar 25 03:21:07 can someone help me about this: http://stackoverflow.com/questions/22620881/librtmp-so-for-libffmpeg-so-not-found Mar 25 03:21:48 molavy: which OS are you compiling on ? Mar 25 03:23:05 android 2.3.6 Mar 25 03:23:17 oh, linux fedora Mar 25 03:23:37 Fedora release 19 Mar 25 03:23:38 the built in VideoView will let you stream rtsp mms and http but not rtmp Mar 25 03:23:58 ok linux is a good choice if you're compiling ffmpeg Mar 25 03:24:37 guys Mar 25 03:24:47 why is sin 90 .89 in java? Mar 25 03:24:51 and vitamio should make it easier, but don't you have to tell your users to install Vitamio first ? Mar 25 03:24:53 should it not be 1? Mar 25 03:25:04 samuel: radians vs degrees Mar 25 03:25:24 i'm using xamarin, when i create another activity i cannot access the ui elements in that activity via my activity.cs Mar 25 03:25:38 JesusFreke: sin uses radians? Mar 25 03:25:38 i've followed this exactly, yet it still isn't working http://docs.xamarin.com/guides/android/getting_started/hello,_multi-screen_applications/ Mar 25 03:25:38 "the angle whose sin has to be computed, in radians" Mar 25 03:25:41 (http://developer.android.com/reference/java/lang/Math.html#sin(double)) Mar 25 03:25:42 no at all in new version of Vitamio Mar 25 03:25:49 tstivers: ask in the xamarin channel Mar 25 03:25:59 JesusFreke: aaah! thanks! that explains it! Mar 25 03:26:09 what's the xamarin channel? Mar 25 03:26:40 Huh, that app I made for someone as a freelance thing recently is now on the Play store. For $5. Kind of ridiculous. Mar 25 03:27:02 have they sold any? Mar 25 03:27:35 i've asked in the monodevelop and monodroid channels on another server Mar 25 03:27:47 It says 1-5 installs and has 1 rating, so I'm guessing no. Mar 25 03:27:48 those channels are completely dead, not a single post in probably an hour Mar 25 03:27:51 Was last updated 3 days ago too. Mar 25 03:28:06 tstivers: good to use a platform with good community support, huh? Mar 25 03:28:23 Nilium: were they not supposed to do that ? Mar 25 03:28:30 shmooz: Do what? Mar 25 03:28:55 I made the app, I'm not in charge of how it's published or marketed. Mar 25 03:28:55 Was just my job to implement the thing. Mar 25 03:28:59 put it out there for $5 Mar 25 03:29:20 i don't particularly care for xamarin's lack of community support, and i also find it quite outrageous how miguel screwed the community over, but it beats using the unintuitive ide that is eclipse Mar 25 03:29:25 I'd assume that's what they thought they could sell it for. Mar 25 03:29:44 regardless it's an issue directly related to android, odds are the solution that works for eclipse probably works in my case as well, i'm guessing there's something i'm not doing Mar 25 03:30:33 The app's literally a list of things that leads to static HTML pages, so I guess whether it's worth $5 depends on whether you want to pay for a bunch of stuff written by a guy. Mar 25 03:30:50 JesusFreke: thanks so much! I never thought of that!!! Mar 25 03:31:00 Nilium: did you get paid a reasonable amount, on time? then you win :) Mar 25 03:31:06 Yep. Mar 25 03:31:36 At least I consider $400 for 1-2 days worth of work reasonable. Mar 25 03:31:49 The app's 300-ish lines long (666 exactly if you just use wc -l -- this was intentional), so not a whole lot of effort to do. Mar 25 03:32:03 yup, that's decent Mar 25 03:32:06 so why, when i create a new activity, and a new layout, am i not able to access the ui elements within that layout from the activity's class? Mar 25 03:32:19 tstivers: you are, in Java. Mar 25 03:32:37 not that decent if you compare it to the price of WhatsApp ;) Mar 25 03:33:07 but it shouldn't be about money anyway, so Mar 25 03:33:15 Why would I compare it to WhatsApp? Mar 25 03:33:17 i should be able to in xamarin as well unless there's some limitation i'm not aware of, the hello multiscreen applications does it the same way it would be with eclipse/java Mar 25 03:33:26 i have a feeling there's linking somewhere that i'm not doing Mar 25 03:33:35 why shouldn't it be about money? Mar 25 03:33:40 it would apply to both java and xamarin i would think Mar 25 03:33:56 money is important - it allows for the purchase of beer and gadgets Mar 25 03:34:34 And coffee. Mar 25 03:34:43 since you seem so anti-xamarin, is there a xamarin related chat room on this server? Mar 25 03:34:48 not to mention the whole roof over your head thing. Mar 25 03:34:50 channel* Mar 25 03:34:55 Which I stopped drinking recently just to see if it would do anything. Mar 25 03:35:03 semantics* Mar 25 03:35:05 And it did. Instead of going to sleep at 3am, I now go to sleep at 5am. It's like it backfired. Mar 25 03:35:13 Leeds: well money shouldn't be the main reason for becoming a programmer Mar 25 03:35:14 tstivers: the problem is, the normal response would be to ask you to post code... but since most of us don't do C#/mono/xamarin/etc... Mar 25 03:35:15 Nilium: headaches? Mar 25 03:35:22 shmooz: why on earth not? Mar 25 03:35:29 I think Dark Souls 2 may actually be a form of caffeine. Mar 25 03:35:32 my favourite is tim o'reilly's quote - money is like gasoline; you don't want to run out, but you aren't doing a tour of gas stations. Mar 25 03:35:41 I had headaches for a little while but they subsided. Mar 25 03:35:47 tstivers not that we're anti-xamarin but, its a different environment. "all bets are off" Mar 25 03:35:54 ok well assume it's not code related Mar 25 03:35:57 we use java Mar 25 03:35:58 i'm anti-xamarin Mar 25 03:36:03 In retrospect, I shouldn't have gone cold turkey on it. Mar 25 03:36:04 assume that it's a step i missed when it comes to creating another activity Mar 25 03:36:07 Leeds: because it doesn't make good programmers, they just want to rush and get their money Mar 25 03:36:14 Yeah, I get pretty bad headaches if I don't get my daily dose Mar 25 03:36:19 I am loading a url in a webview (the site is not my site). Is there a way for me to use jquery on the client side similar to how you can with a Greasemonkey script Mar 25 03:36:22 they don't enjoy the puzzle solving journey Mar 25 03:36:31 shmooz: nonsense... if being better at your job means you make more money, that's a good thing Mar 25 03:36:37 As for money, if you do a good job and money's your motivation, cool, continue doing a good job and getting money. Mar 25 03:36:37 I don't have a problem with money being a factor for people. Mar 25 03:36:39 tstivers, learn the java environment for android first, then switch to xamarin Mar 25 03:36:47 i already know the java environment Mar 25 03:36:55 programming isn't a calling, it's not like joining the priesthood to help the world Mar 25 03:36:56 and i've made apps in java/eclipse Mar 25 03:37:04 have any of you done ios development ? Mar 25 03:37:11 Hell, if the quality of your output scales with money as an input, money makes you useful. Mar 25 03:37:13 Leeds: crap, I've been doing it wrong! Mar 25 03:37:22 devslash: i do a bit Mar 25 03:37:22 Now hold on Mar 25 03:37:23 devslash: not i, 15% of the market just isn't worth the extra work imo Mar 25 03:37:25 I found it to be much more difficult and has a much steeper learning curbe Mar 25 03:37:28 JesusFreke: you may be a special case... in many ways Mar 25 03:37:28 tstivers, then contact xamarin for help Mar 25 03:37:32 curve Mar 25 03:37:44 It is like a priesthood, it's just the ritual involves neckbeards and anime Mar 25 03:37:45 compare to android Mar 25 03:37:58 Some people answer the branch of neckbeards, others take the tentacle of anime Mar 25 03:38:01 dont laugh but I am currently using aide on my phone to develop Mar 25 03:38:06 its as good as eclipse Mar 25 03:38:08 * JesusFreke is the canonical corner case.. for everything. Mar 25 03:38:14 AIUI, the xamarin stuff ain't cheap - so you should actually be able to contact them for help, unlike those aloof Googlers and their free tools Mar 25 03:38:17 And then a select few drop out and become web devs. Mar 25 03:38:31 * Nilium needs to come up with more ways to make fun of web devs. Mar 25 03:38:41 "Be alert - the world needs more lerts!" "Be aloof - we have enough lerts now!" Mar 25 03:39:14 so why do you hate xamarin so much? Mar 25 03:39:19 * Leeds wanders back over to #django for a while Mar 25 03:39:23 does anyone here use AIDE ? Mar 25 03:39:34 What is AIDE? Mar 25 03:39:54 an android development ide Mar 25 03:39:56 on android Mar 25 03:40:02 so you can developer for android on android. Mar 25 03:40:03 Sounds stupid. Will disregard. Mar 25 03:40:08 its not Mar 25 03:40:15 its nearly as good as eclipse Mar 25 03:40:20 that's not saying much Mar 25 03:40:30 It is. Mar 25 03:40:38 ah, that's actually kinda interesting - self-hosted development Mar 25 03:40:39 well adt now Mar 25 03:40:52 I've developed 2 applications with it in the past week Mar 25 03:40:56 I think terminal-ide is more interesting Mar 25 03:41:05 "It's almost as good as Eclipse!" *gasps all around because of how offense that statement is* Mar 25 03:41:08 kbs. if you think self hosted development is cool, you should check out the PC! :P Mar 25 03:41:19 send the whippersnappers back to using ed, goshdarnit Mar 25 03:41:24 notepad is almost as good as eclipse Mar 25 03:41:24 it's THE editor Mar 25 03:41:51 what's java's version of tpl? Mar 25 03:41:53 vim >* blah Mar 25 03:42:11 TECO scripts forever Mar 25 03:42:30 whats going to happen if bram dies, i think he's the only one who knows how vim works inside Mar 25 03:42:42 well, if you like teco, may as well just go join the cult of emacs Mar 25 03:42:44 I'll just stick with my schizophrenic switching between vim and Sublime and using a terminal for everything else. Mar 25 03:42:48 g00s: progress, as the world moves away from vim? :) Mar 25 03:42:55 JesusFreke \o/ Mar 25 03:43:02 kbs: TECO is pretty different from Emacs Mar 25 03:43:27 Well, if that odd neovim project is an indication, someone will jump in and take over because they figured out how to read the code Mar 25 03:43:39 i think that dude has no idea what he's getting into Mar 25 03:43:51 there is a new version of vim called NeoVIM Mar 25 03:43:57 neovim resulted from a conflict where someone didn't get their patch in vim Mar 25 03:44:04 So the guy actually probably does know what he's gotten himself into Mar 25 03:44:05 a lot of refactoring for not much benefit Mar 25 03:44:17 for vim users Mar 25 03:44:30 I still think neovim is the wrong move, but it is evidence that there're people who can work with vim's source. Mar 25 03:44:35 p_l: I always thought EMACS was pretty much how anyone actually used teco; but not having used either, what do I know ;-) Mar 25 03:44:56 (er, meaning the macros on teco of course) Mar 25 03:45:03 kbs: TECO is actually closer to VIM's origins Mar 25 03:45:06 i think his crowdfunding goal was $10k, which to me seems like a gross mis-underestimation of the effort Mar 25 03:45:33 It probably is, but who knows. Mar 25 03:45:39 kbs: consider that vi and sed have common ancestor in ed Mar 25 03:45:42 I think people are going to find themselves disappointed with the result and it will be abandoned. Mar 25 03:46:01 p_l: yes, somewhat familiar with the history ;-) Mar 25 03:46:06 Much like how Atom's an enormous piece of crap Mar 25 03:46:14 kbs: Emacs was written *in* TECO, not an evolution of TECO Mar 25 03:46:28 i haven't heard about atom since it initially launched :) maybe its dead already Mar 25 03:46:40 All that excitement and buildup for when people found bits of Atom around GitHub and then it turns out it's a slow, dumb, not very interesting project Mar 25 03:46:41 p_l: *nod* see above "meaning the macros on teco" etc Mar 25 03:47:14 It's not dead, but I think everyone quickly realized it's not the godking of editors and lost interest quickly Mar 25 03:47:21 p_l: my understanding of TECO's actual usage was that pretty much everyone just used it via EMACS Mar 25 03:47:36 what if the guy gets done with neovim and delivers emacs ? Mar 25 03:47:42 :D Mar 25 03:47:54 That's how my dad used teco, since emacs supposedly just made it better to work with, but that was years ago Mar 25 03:48:07 kbs: emacs was pretty late in TECO history, and iirc quickly turned into separate application Mar 25 03:48:19 TECO's origin is stream editing paper tape ;)( Mar 25 03:48:22 He didn't really like Stallman much, though. Mar 25 03:48:57 not surprising (about rms :) Mar 25 03:49:03 Does anyone know of any good tutorials for using TDD with Android Studio for a beginner to TDD? Mar 25 03:49:26 kbs: Shouldn't be. Not a lot of people like him as a person. Mar 25 03:49:57 I like his ideas and his dedication to principles, but he's kind of insufferable. Mar 25 03:51:56 yea. I also thought him as a techno- chicken little, but he's proved in the end to be right; the twerp Mar 25 03:55:10 if rms wasn't insufferable he wouldn't be any good at what he is Mar 25 03:56:09 there's some argument whether he's actually good at it *tongue in cheek* :) Mar 25 03:56:50 some impedance mismatch between internal brilliance and getting people to realize it. Mar 25 03:57:09 ideological pariahs don't make a lot of friends Mar 25 04:01:42 I am loading a url in a webview (the site is not my site). Is there a way for me to use jquery on the client side similar to how you can with a Greasemonkey script Mar 25 04:05:18 devslash: you mean like angular.js? Mar 25 04:05:38 dunno never used it Mar 25 04:06:08 i want to include jquery so I can use my existing jquery based script that I wrote as a Greasemonkey script with my webview Mar 25 04:06:45 in my GM script, I included the compressed jquery 2.1.0 Mar 25 04:09:16 kbs: regarding teco, you know the joke about using Vi as random number generator? Well, TECO had the game of "type your name in freshly started teco", during which it was very prudent to take whole-system backups :D Mar 25 04:09:27 (backup before playing, that is) Mar 25 04:09:46 :-) haha Mar 25 04:10:05 it sounds like you were a teco user? Mar 25 04:10:06 especially for names starting with "d" Mar 25 04:10:40 kbs: Not really. But I did have ITS and TOPS-20 running once, and used EMACS on TOPS-20 Mar 25 04:10:49 very cool Mar 25 04:11:06 sup guys Mar 25 04:11:13 the answer to my question btw was to rebuild the app, for some reason it didn't update when i tried this before, however it's working now Mar 25 04:11:34 kbs: and you just presented me with evidence on how my age is mistaken on the net... Mar 25 04:11:45 p_l: glad to help :-) Mar 25 04:12:58 p_l: now you have to tell us your age. Mar 25 04:13:22 shmooz: nope, not saying. But I am not old enough to be at MIT in 70s :P Mar 25 04:13:47 awww Mar 25 04:17:18 do you ever need to import the R class? Mar 25 04:18:06 anyone have exp with services? Mar 25 04:18:06 depends on your current package Mar 25 04:18:37 the R class is just a class in the package you defined in your manifest Mar 25 04:18:47 if you use anu other packages, you'll need to import it Mar 25 04:18:51 *any Mar 25 04:19:37 mhmm i see Mar 25 04:19:46 its just that its not working how i expected Mar 25 04:20:20 maybe i shouldnt try writing a game to start with Mar 25 04:24:54 what's the best way to store an enum in a ContentValues object? Mar 25 04:25:23 ContentValues being the object representing a row of a sqlite db Mar 25 04:25:39 there's no convenient cv.putEnum Mar 25 04:25:54 you'll have to have something like .getCode() to represent the enum as an sqlite type Mar 25 04:26:09 if you use the ordinal value, and then change something later, you'll f thing sup :) Mar 25 04:27:11 i'd use a string Mar 25 04:27:22 then it wont break if you add a new one in the middle Mar 25 04:27:29 and enum.valueOf takes a string Mar 25 04:28:04 i like that approach Mar 25 04:28:04 valueOf throws exceptions, you'll have to be ready for that i guess Mar 25 04:29:50 also, if you rename your enum, it will mess up the schema too :) Mar 25 04:30:09 argh Mar 25 04:30:22 i'm tempted to just use static final ints... Mar 25 04:30:45 :) Mar 25 04:30:59 they have all the same problems Mar 25 04:31:07 ic c++, we had a saying … do as the ints do :) Mar 25 04:31:21 sup g00s Mar 25 04:31:27 hi jareddlc Mar 25 04:31:40 jareddlc: your name reminds me that the bioshock dlc hits today! :D Mar 25 04:31:57 In C++ I have a saying: Java sucks. Mar 25 04:32:22 hahaha Mar 25 04:32:25 Mango_Man: Mar 25 04:32:32 I want to get the Bioshock DLC but the I'd have to reinstall it. Mar 25 04:32:58 And that takes time... no instant gratification to be found. Mar 25 04:33:09 Nilium: yeah, and if you're not a windows user you have to spend a day on windows Mar 25 04:33:31 It's on OS X. Mar 25 04:33:37 Via Steamplay, anyway? Mar 25 04:34:04 That should be a ., not a ?. Damn iPad keyboard. Mar 25 04:36:36 g00s: im trying to do this service stuff Mar 25 04:36:42 i think im doing it all wrong :D Mar 25 04:37:15 the documentation for Services is very good Mar 25 04:37:26 buttt Mar 25 04:37:30 i am not using activity Mar 25 04:37:36 im doing preferenceFragment Mar 25 04:39:11 that reminds me, i need to add auto-reconnect to my bluetooth service Mar 25 04:39:21 actually a preference Mar 25 04:39:53 the BT stack on kitkat is flaky as hell!!! Mar 25 04:39:56 yeah so iunno what im doing Mar 25 04:40:03 i am on 4.4 Mar 25 04:40:40 luckily i haven't seen the BT service crash , then you just have to reboot the device Mar 25 04:40:54 g00s: can i offer u some programming trade Mar 25 04:41:01 so u can write my service :D Mar 25 04:41:05 no :) Mar 25 04:41:19 * g00s is busy writing his own app :D Mar 25 04:41:42 * jareddlc goes spends beaucoup bucks elsewhere Mar 25 04:41:42 i can answer questions about BT, the channel can help with general android questions Mar 25 04:42:03 i feel like im doing things as they shouldnt be done Mar 25 04:42:05 xD Mar 25 04:42:10 probably :D Mar 25 04:42:26 so Mar 25 04:42:35 i havent quiet read services Mar 25 04:42:39 but i dl a project Mar 25 04:42:42 my understanding Mar 25 04:42:53 the service should run the threads of what i want to run in background? Mar 25 04:43:00 yes Mar 25 04:43:06 alright Mar 25 04:43:08 read the service stuff, a couple of times Mar 25 04:43:14 has to sink in ;) Mar 25 04:44:17 jareddlc: threads do that too Mar 25 04:44:49 canvs2321: ? Mar 25 04:44:50 jareddlc: in whatever activity u r running Mar 25 04:44:54 threads runs thread Mar 25 04:45:03 i have a preferenceFragments Mar 25 04:45:04 service could extend passed dead activities Mar 25 04:45:09 which should call start service Mar 25 04:45:27 services still run on ui thread? you have to spawn threads inside to seperate from ui? Mar 25 04:46:13 dunno Mar 25 04:46:21 im "learning" Mar 25 04:46:22 or shoulda said can't services block ui Mar 25 04:46:24 being lazy Mar 25 04:46:31 bzzz Mar 25 04:46:40 jareddlc if you want help, you can't be lazy Mar 25 04:46:50 being lazy not reading docs Mar 25 04:46:53 implementing from tut Mar 25 04:47:10 also Mar 25 04:47:23 my preferenceFragments calls into the mainacitivy to start service Mar 25 04:47:26 i hope that works :D Mar 25 04:47:50 jareddlc maybe pick up a book like big ner ranch Mar 25 04:47:55 *nerd Mar 25 04:48:09 you are pretty lost when it comes to the basics of the android components Mar 25 04:48:16 yup Mar 25 04:49:07 im learning g00s Mar 25 04:49:35 i find that i learn better readng code Mar 25 04:49:38 than reading docs Mar 25 04:49:45 when i need something i then dig into the docs Mar 25 04:52:11 jareddlc: main thing is find something you wanna create. Then find what you need. if just following a tutorial on random stuff, how's that gonna get you where you wanna be? there r tutorials on every aspect of coding. Gonna read em all? find an end game project and grow from that Mar 25 04:53:58 well I am just trying to make this Mar 25 04:54:05 as a proof of concept of a device i want to build Mar 25 04:54:14 i am uncertain if i want to continue with android dev Mar 25 04:56:11 i learned alot with doing UI stuff Mar 25 04:56:14 which kinda suck Mar 25 04:56:19 well Mar 25 04:56:27 its just different from all other UI languages ive used Mar 25 04:56:39 C++, python Mar 25 04:57:40 i wonder if there is an enhancement request on the issue tracker to add java 8 lambdas :D Mar 25 04:58:17 although, i'm not really sure if doing it right means changes to the vm Mar 25 05:06:15 anyone used android memory tools from intellij / android studio / Mar 25 05:06:45 got memory leak somewhere but cannnot find it Mar 25 05:08:28 my problem is - when I export hprof file and open it in MAT all I can see is byte[] objects not class names Mar 25 05:09:05 is there anyway to prevent compiler to do that ? Mar 25 05:09:20 or I'm just completly wrong here and they are really byte[] ? Mar 25 05:14:22 Nilium what do you think of the Gbattery Mar 25 05:15:21 yeah I must be wrong Mar 25 05:20:26 gordon_: they're really byte[] Mar 25 05:20:48 is it possible Mar 25 05:20:56 to extend function as a parent class Mar 25 05:20:57 I forget exactly how it works, but you should be able to see where they are allocated Mar 25 05:21:12 and have child class call a method that requires parents "this" Mar 25 05:21:36 jareddlc: super.methodName() Mar 25 05:22:43 JesusFreke: ( Mar 25 05:22:44 no go Mar 25 05:22:50 im in different scope Mar 25 05:23:06 or Mar 25 05:23:12 my class has a class defined in it Mar 25 05:23:25 jareddlc: ah, you mean inner class Mar 25 05:23:32 in that case ParentClass.this Mar 25 05:23:36 but the inner class must be non-static Mar 25 05:23:43 private void? Mar 25 05:23:52 non-static. Mar 25 05:24:04 oh class not method Mar 25 05:24:04 public static class SettingsFragment extends PreferenceFragment Mar 25 05:24:06 :(( Mar 25 05:24:44 i want to start a service from my preferenceFragment Mar 25 05:24:49 but i dont know how Mar 25 05:24:58 or given my class if it is possible Mar 25 05:25:29 A quick search reveals: http://stackoverflow.com/questions/8215308/using-context-in-fragment Mar 25 05:25:35 jareddlc: seems you just want a context Mar 25 05:27:54 do i pass it from top class Mar 25 05:27:55 ? Mar 25 05:28:16 jareddlc, that's not learning by reading code, that's learning by copying and praying that it works Mar 25 05:28:30 see: cargo cult coding Mar 25 05:28:41 copypasta is best pasta Mar 25 05:28:51 al dente ! Mar 25 05:28:58 well pfn, the examples i have dont use preferenceFragment Mar 25 05:29:01 they use acitivties Mar 25 05:29:12 i cant find any tuts Mar 25 05:29:15 using fragments Mar 25 05:29:16 * JesusFreke points to the SO link he gave Mar 25 05:29:16 gordon_, and no, they're not byte[] Mar 25 05:29:57 and because i lack basic knoledge of android :) Mar 25 05:30:07 jareddlc, so what if it's a fragment, if you can't read and use documentation, then you will never code effectively Mar 25 05:30:20 you lack basic knowledge, period Mar 25 05:30:57 http://www.lolhome.com/img_big/shat-myself.jpg Mar 25 05:31:13 yes i dont know android Mar 25 05:31:14 :D Mar 25 05:31:30 No, you don't know how to program period Mar 25 05:31:44 i dont think thats a correct statement Mar 25 05:31:51 accept that, and then you can move on Mar 25 05:32:13 you are having basic programming problems, has nothing to do with android in particular Mar 25 05:32:36 my problems are more related to andoird and some java Mar 25 05:32:47 but they aren't Mar 25 05:32:49 becuase its not a language a program everyday Mar 25 05:32:56 but i wont argue with you no point Mar 25 05:34:56 you are given numerous pointers, but you ignore, can't help you if you don't know basics Mar 25 05:35:24 jareddlc the nature of what you are trying to do, will require java, android, concurrency (can't block main thread for BT), services, and quirks of bluetooth. thats not really a beginner project .. but if you want to tackle it, you'll have to have a good understanding of those areas Mar 25 05:35:31 quick question: which android is the "android-18" platform? jelly bean? Mar 25 05:35:35 otherwise, you're just going to be hitting your head on every branch Mar 25 05:35:44 18 is 4.3 Mar 25 05:35:48 well pfn i dont want to continue discussing with u Mar 25 05:35:54 pfn: thanks Mar 25 05:36:03 things ive ask Mar 25 05:36:05 shingshang: handy table at http://developer.android.com/guide/topics/manifest/uses-sdk-element.html Mar 25 05:36:06 i try Mar 25 05:36:12 jareddlc, good, please go away and pick up some basics Mar 25 05:36:15 no point of asking and not trying, that would be a jerk Mar 25 05:36:15 You guys win Mar 25 05:36:20 Fuck xamarin Mar 25 05:36:27 but i do lack knowledge Mar 25 05:36:31 its microsoft now, right ? Mar 25 05:36:38 and i want to create an prototype app asap Mar 25 05:36:49 JesusFreke: thank you Jesus Mar 25 05:36:55 Buggy piece of shit for a lot of money is what it is, at least eclipse doesn't break itself every 5 minutes Mar 25 05:37:18 I though xamarin is supposed to be pretty good... Mar 25 05:37:28 g00s: not officially, yet... Mar 25 05:37:35 why the motivation for using it anyway Mar 25 05:37:59 No, its crap, most of it doesn't work worth a damn, finding answers to any issue is a pain in the ass, its expensive Mar 25 05:38:19 Because I like c# far more than java Mar 25 05:38:29 pfn: cross-platform, and if you already know/like c#... Mar 25 05:38:41 I think there are quite a few games out there using it Mar 25 05:38:44 i think it will make a lot of sense for enterprise apps Mar 25 05:38:46 g00s: The what Mar 25 05:38:53 What's a Gbattery? Mar 25 05:39:00 * JesusFreke misses c# :( Mar 25 05:39:02 c# is ok, I guess Mar 25 05:39:02 Idgaf about cross platform personally, no intention of developing for iOS, especially not for an extra $300 Mar 25 05:39:12 it's moderately better than java Mar 25 05:39:20 Nilium http://techcrunch.com/2014/03/24/gbatteries-batterybox/ Mar 25 05:39:21 also thats kind of a jerk move of yours Mar 25 05:39:25 sending someone away from IRC Mar 25 05:39:28 :) Mar 25 05:39:28 I would like C# that compiled to JVM bytecode. Mar 25 05:39:34 f# much more interesting Mar 25 05:39:50 The language has significantly more useful features than Java. Mar 25 05:39:52 as i do have the will to learn Mar 25 05:39:53 Sole reason for using xamarin is c#, and honestly with all the problems mono/xamarin present plus the cost, I'll just become more familiar with java Mar 25 05:40:07 not like im not taking advice from others Mar 25 05:40:23 I haven't touched F#, though I've heard it's good. Mar 25 05:40:32 Nilium, sure, but you're already a scala user... no advantage of c# there Mar 25 05:40:46 can you use F# on windows phone ? Mar 25 05:40:56 No, there isn't, but it would be a nice way to kill off Java on Android. Mar 25 05:41:02 Does java have an equivalent to c# task parallel library? Mar 25 05:41:03 if it helps MS improve this situation, it would be a good move: http://goo.gl/NRa3cK Mar 25 05:41:10 As is, I use Scala to fix the Java-really-really-sucks problem. Mar 25 05:41:18 tstivers not .. really. i use rxjava Mar 25 05:42:06 I can't go back to using c#, it's unpleasant Mar 25 05:42:18 That's funny. I like seeing Microsoft shoot itself in the foot. Mar 25 05:42:42 Java does suck Mar 25 05:42:55 pfn yeah, coming from scala, i *imagine* scala is more powerful. but coming from java, c# seems much nicer Mar 25 05:43:00 dunno what task parallel is, but futures > * Mar 25 05:43:00 My main gripe is a complete lack of innovation at all Mar 25 05:43:22 I need to play with rxjava, well, rxscala Mar 25 05:43:23 That's where I love c#, there are a ton of innovations constantly coming out Mar 25 05:43:42 scala-react was interesting but there's no clear license for it and as far as I know it was just a research project. Mar 25 05:43:54 TPL is the async/await features in c# Mar 25 05:44:05 futures > rx Mar 25 05:44:06 tstivers well, doesn't matter how fast oracle innovates on java; not like you can just update your android's VM to use the innovations Mar 25 05:44:14 I'd also welcome the ability to use Go for some parts of Android development. Mar 25 05:44:15 It makes asynchronous programming amazingly easy Mar 25 05:45:03 G00s if java did innovate, I feel like android would bring the innovations into the platform Mar 25 05:45:18 tstivers let me know when we get java 8 :) Mar 25 05:45:20 pfn: I think futures and reactive stuff aren't really trying to solve the same problem. Mar 25 05:45:21 there's java 8 now Mar 25 05:45:34 Imagine if java added a sync/await, do you think Google would not bring that into android? Mar 25 05:46:13 What does java 8 add that's truly worth having? Mar 25 05:46:29 I don't see the problem that rx solves still Mar 25 05:46:30 And what benefit would it bring to android development Mar 25 05:46:32 To me, reactive stuff is more like event-based coding whereas futures is just saying "I'll have this one thing eventually" Mar 25 05:46:45 I'm not familiar with java so idk what java 8 really adds Mar 25 05:47:00 i.e., you watch a stream of events with reactive coding and react to the events. Mar 25 05:47:03 It's a different solution to a different problem. Mar 25 05:47:19 Well I'm familiar, but not that familiar I should say Mar 25 05:47:30 Nilium: That is event based IO right? Mar 25 05:48:02 tstivers http://www.oracle.com/technetwork/java/javase/8-whats-new-2157071.html Mar 25 05:48:14 emotionull: Probably sort of kind of. Mar 25 05:48:42 Nilium: Its tof for java I guess...NodeJS is great at that Mar 25 05:49:10 node.js can go die in a fire. Mar 25 05:49:13 event based IO .. like nonblocking networking? plenty of stuff for that like vert.x, spring reactor Mar 25 05:49:33 node.js is the callback spaghetti that claims to be new ;) Mar 25 05:49:35 So pretty much lambda expressions is what I get from that, something I tend to avoid in c# because it makes code difficult to read Mar 25 05:49:45 nonblocking networking came in NIO.2, which is not in android Mar 25 05:49:49 I can't really believe people seriously use node.js for anything. Mar 25 05:50:00 but it's new! and cool! Mar 25 05:50:11 and rockstar RoR developers love it! Mar 25 05:50:21 Nilium: node.js itself is nothing to NPM :P Mar 25 05:50:23 it's new to people who have only ever written webapps :p Mar 25 05:50:40 Is that a web developer joke? Mar 25 05:50:45 Nilium: LinkedIn uses it...GitHub is shifting to it Mar 25 05:50:53 p_l: Well, npm is a trainwreck waiting to happen and I'm just waiting for the gleeful moment when it all comes crashing down Mar 25 05:50:53 Leeds: I really hate the term "rockstar" Mar 25 05:50:56 anyone who has written anything with a main loop just rolls their eyes Mar 25 05:51:37 node.js users: threads are bad, let's create gigantic expensive forks of existing processes and see how that work sout. Mar 25 05:51:56 *works out Mar 25 05:51:56 (five minutes later: the swap drive is making grinding noises) Mar 25 05:51:58 is that really whta it does? Mar 25 05:52:01 w00 g00s looks like i got basic service running Mar 25 05:52:01 forks? Mar 25 05:52:13 looks :| not sure Mar 25 05:52:15 emotionull: Both companies aren't really "one language" kinds, and even then they probably end up more resources than they would have needed with tighter code Mar 25 05:52:24 I feel bad for web devs tbh... Web development is a clusterfuck of mashed together tools and languages that really shouldn't be mashed together, and the very nature of it makes innovation damn near impossible Mar 25 05:52:30 ^^ Mar 25 05:52:31 I seem to recall its approach to parallelism being forking. Mar 25 05:52:38 forking isn't that bad Mar 25 05:52:42 esp with copy on write Mar 25 05:53:05 and i'd rather have ppl learn how to write good cooperative multitasking style code than throwing in preemptive threads where they don't make sense Mar 25 05:53:07 wabz: no, but since it's single threaded, every time they call to code that isn't JS or runs for long time they have to fork Mar 25 05:53:08 just wanted to appologize to everyone who had to hear my complain. Im usuallly dont. But i got upset when pfn smack talked Mar 25 05:53:09 Forking's still more expensive than spinning up a thread and it means resource sharing is more difficult as a result. Mar 25 05:53:34 also, http://shitryandahlsays.tumblr.com/ Mar 25 05:53:45 pl_: maybe...Node is not good for CPU intensive tasks but u can hv C plugins /modules for that Mar 25 05:54:11 Ruby has C plugins and modules for that stuff because it has poor threading support Mar 25 05:54:23 JesusFreke yeah, adb over tcp/wifi is much more stable then USB for me. i would think a wire would be better :| Mar 25 05:54:30 emotionull: which lock the whole process Mar 25 05:54:45 Nope...it doesnt Mar 25 05:54:45 It turns out this is a bad thing because now it's impossible to give Ruby decent threading support without C libraries potentially crapping themselves due to assumptions about thread safety Mar 25 05:54:57 g00s: check the cable for possible breakage Mar 25 05:55:14 I was thinking same thing about cable Mar 25 05:55:19 p_l seems ok .. i mean, adb over usb disconnects like every 15 minutes Mar 25 05:55:26 g00s: that's not right Mar 25 05:55:27 emotionull: Does node not create a GIL for C extensions? Mar 25 05:55:29 I experience no instability with adb over usb Mar 25 05:55:30 p_l: ah, right Mar 25 05:56:02 i routinely have adb connected for hours at a time without problems, on usb Mar 25 05:56:04 Though tbh adb over WiFi is simply more convenient so Mar 25 05:56:11 g00s: the original cable that came with my N4 got broken making it quite common for the connection to drop Mar 25 05:56:25 Actually, no, it probably doesn't since it's single-threaded. Mar 25 05:56:45 my ~/Library/Logs/CrashReported is FILLED with adb crashes, i dunno. adb is just a piece of shit Mar 25 05:56:56 works pretty well here Mar 25 05:57:04 g00s: ahh, adb on OSX, no idea what kind of insanity happens there :P Mar 25 05:57:06 No u Mar 25 05:57:11 p_l XD Mar 25 05:57:49 g00s: hey, not my fault that OSX is last surviving example of an OS using "the microkernel that killed microkernels" :P Mar 25 06:00:22 how can I record a screen with andorid studio in emulator (kitkat) Mar 25 06:00:37 * p_l will have to one day dig up the bug that someone hit caused by OSX not being restarted often :> Mar 25 06:00:39 g00s: hah, yeah. you would think so Mar 25 06:00:46 slani: adb screenrecord from the command line Mar 25 06:02:50 How is android studio anyway? Significantly better than the standard eclipse/ADT? Mar 25 06:03:15 yes Mar 25 06:03:36 it's first-party, actively-developed android support in IntelliJ IDEA Mar 25 06:03:47 What's better? Mar 25 06:04:13 your internet bandwidth is not fast enough for the stream of bytes that would be required to accurately answer that question Mar 25 06:04:18 JakeWharton: I tried this. I get this error Mar 25 06:04:19 ERROR: unable to create encoder input surface (err=-38) Mar 25 06:04:41 for snarkier answers, it's better because no Eclipse. It also got some stuff over IntelliJ's android plugin for now Mar 25 06:04:44 Yeah, its this crappy 3g connection :( Mar 25 06:04:55 p_l: it *is* IntelliJ's android plugin Mar 25 06:05:20 JakeWharton: Well, a bit "forward" in developement, iirc :) Mar 25 06:05:27 which is also why it's alpha :P Mar 25 06:05:35 gnight guys Mar 25 06:05:36 yes. two heads, one snake Mar 25 06:06:07 JetBrains merges Google's repo, Google merges JetBrains' repo Mar 25 06:06:07 How big a download is android studio if I already have all the SDK requirements installed? Mar 25 06:06:20 200 meg or something Mar 25 06:06:30 Not too bad Mar 25 06:11:54 ?? Mar 25 06:13:05 ok. Screen record doesn't work on emulator Mar 25 06:13:07 http://code.google.com/p/android/issues/detail?id=61682 Mar 25 06:32:06 * g00s sighs Mar 25 06:32:10 git reset --hard :( Mar 25 06:49:52 git reset --easy Mar 25 06:52:38 alias nuke-the-repo="git push --force" Mar 25 07:01:57 it sounds like you're straying into the realm of mutually assured destruction Mar 25 07:02:15 you nuke the repo, and every one else using the repo nukes you Mar 25 07:07:06 having a problem building. "BUILD FAILED /home/james/android-sdk-linux/tools/ant/build.xml:542: Application package '' must have a minimum of 2 segments." Mar 25 07:07:25 It seems to think my project name is blank for some reason. Mar 25 07:20:16 hm, the new gradle examples use mavenInstaller() rather than mavenDeployer() inside uploadArchives Mar 25 07:20:49 i guess this just puts it in ~/m2 ? Mar 25 07:26:04 g00s: where have you been the past few days?! Mar 25 07:26:27 I had to talk to bankai_ about his dogs for you! Mar 25 07:26:31 thepoosh hmm, working hard. try not to get too distracted Mar 25 07:26:36 oh Mar 25 07:26:42 I'll keep quite Mar 25 07:26:53 bankai_ thepoosh oh, i'm sure you guys would like to know, i cleaned Jake's ears for wax today :D Mar 25 07:27:06 defaq?! Mar 25 07:27:09 hehe Mar 25 07:27:15 dogs are capable of getting ear wax?! Mar 25 07:27:20 hey man, labs, water, and gooey stuff Mar 25 07:27:27 yakk Mar 25 07:27:49 my wife really wants to adopt a dog Mar 25 07:27:56 happens with a lot of dogs that go in water, but have floppy ears that cover the canal. so they don't dry Mar 25 07:28:19 thepoosh yeah, get a rescue. Mar 25 07:28:31 I'll for sure not buy one Mar 25 07:28:45 but we're renting now and our lease doesn't allow animals Mar 25 07:28:57 mixes tend to be healthier; you'll save a life ;) Mar 25 07:29:05 they usually appreciate it :) Mar 25 07:30:07 but know how to eval a dog; it has to fit your temperament / lifestyle, what you want to do, and you should be clear on any behavior disorders Mar 25 07:31:19 like if it has a tendency to want to kill any other dog, i'd either pick something else, commit to evaluation by animal behaviorist, have a farm where its OK Mar 25 07:31:24 Cats are better. Mar 25 07:32:11 we had a beautiful cat here one time, my friend used to show it. such a great personality. used to play fetch. some cats are awesome Mar 25 07:32:50 Nilium do you let your cats and birds play together :P Mar 25 07:33:10 oh, and it seems the more you dislike cats, the more they like you Mar 25 07:33:13 so this cat loved me Mar 25 07:33:17 since i was allergic to cats Mar 25 07:42:13 hm, uploadArchives { mavenInstaller() } is doing something weird; publishing the artifact twice, once with the hyphenated name, the other without Mar 25 07:42:42 so if i have me:foo-bar:0.0.0 , there is 0.0.0/bar and foo-bar Mar 25 07:43:21 are hyphens magical in maven coordinates ? Mar 25 07:47:25 Hm, been a while since I updated Gambit. I'm apparently a full minor version behind now. Mar 25 07:48:00 oh, a schemer? :) Mar 25 07:50:49 looks like Google and a bunch of other companies, but not FB, had illegal no-poaching agreements Mar 25 07:50:57 to keep wages down Mar 25 07:51:03 Sort of. I use it for odd things. Mar 25 07:51:10 I have a small thing written in Scheme for doing bits of my taxes, for example. Mar 25 07:51:16 O.o Mar 25 07:51:19 g00s: "saint" jobs was apparently originator of the scheme Mar 25 07:51:30 Nilium tax schemes :) Mar 25 07:51:37 Mainly just formatting and adding up income from app sales. Mar 25 07:52:02 Has any1 tried the Android Wizard Pager by Romain Nurik? https://github.com/romannurik/Android-WizardPager Mar 25 07:52:12 lacks documentation :/ Mar 25 07:52:44 It doesn't do anything special like try to fill out a tax form, it's just for the sake of having human-readable text files that I can run to get fancy output Mar 25 07:52:46 any hint / help on how to get started with it Mar 25 07:52:54 mhm.. snce a background service do not guarantee that onDestroy is called - how would you (thread safe, performance) make sure that a thread which was created and started in onStart(command) is destroyed successfully= Mar 25 07:52:56 Also because numerical accuracy is important. Mar 25 07:53:52 Keep the thread for the lifetime of the process and simply reuse it as needed. Mar 25 07:54:11 so creating a singleton thread would be the proper case (proberbly in a extends Application) Mar 25 07:54:24 there Mar 25 07:54:35 Singleton thread is incorrect. Mar 25 07:54:54 there's just one problem. when the service restart (return sticky, whatever) then i need to validate if the thread is already running and working. Mar 25 07:54:58 Just start a thread with a looper. Mar 25 07:55:07 Then run stuff on it. Mar 25 07:55:17 yeah and this is the problem Mar 25 07:55:32 You could in theory have multiple threads and treat them as a pool, balancing tasks between them. Mar 25 07:56:36 Just to clarify, do you know what the Looper class is? Mar 25 07:56:58 class a extends Service { Thread pubThread = null; onStart(..) { if (pubThread == null) { pubThread = new Thread(.... while (true/keepalive/whatever) { }; ) } else { // thread is already running } } now since onDestroy is not guaranteed the thread will remain NOT null and run forever Mar 25 07:57:01 yes, sure Mar 25 07:57:41 Considering how small, horizontally, my IRC window is, that's an unreadable mess of horror. Mar 25 07:57:50 haha Mar 25 07:57:56 WAit, i'll pastebin an example Mar 25 07:58:45 I'm not seeing the problem with the looper thread. Mar 25 08:00:02 http://pastebin.com/fZnRzR6S Mar 25 08:00:20 Well. Looper is designed for having multiple threads, right? Mar 25 08:00:44 I dont need them. I do only need one thread since it's a persistent connection and there's no sense creating multiple threads for just one socket connection Mar 25 08:00:58 What are you trying to get at by asking that? Mar 25 08:01:30 Loopers are attached to threads. Threads are not attached to loopers. Mar 25 08:01:31 Only one loop per thread. Mar 25 08:01:33 I try to get a proper solution to avoid the a) kitkat bug and b) to make sure to validate if the service was killed (and the thread was still running) Mar 25 08:02:14 Is using a looper the proper solution? I thought about using a blockingqueue which should mainly do the same, right? Mar 25 08:03:13 I'm not sure why you're comparing the two. Mar 25 08:07:07 misterli what again were you trying to do, from the top? i hope not try to keep that service around becuase START_STICKY was busted Mar 25 08:07:38 yes, trying this :) Mar 25 08:07:38 Hi there. Mar 25 08:08:06 Using an Alarmtimer with a 30min delay to verify if the service is still running. If not starting. But when i try to start it i need to verify if the thread is "really" still running Mar 25 08:08:16 isAlive() returns true even when the thread is not running anymore Mar 25 08:08:41 I have a restful web service. And I need app that will communicate with restful web serivce. For communication I could use volley or similar. But I want application to work offline and show data even thoug there is no network connectivity. How can I do this? Mar 25 08:13:09 What docs do you recommend? Mar 25 08:14:34 frojnd well, sounds simple enough … but here are lots of moving parts; rest / caching / databases / using the radio efficiently, etc. personally, i think its quite a bit of work Mar 25 08:15:04 yeah it is Mar 25 08:15:15 I just need a architecture how to put those parts together in theory Mar 25 08:15:28 its a bit out dated, but there is a presentation Mar 25 08:16:02 http://www.youtube.com/watch?v=xHXn3Kg2IQE Mar 25 08:16:35 but there are libraries that do some of this , maybe look at retrofit and whatnot Mar 25 08:17:22 btw he gives 3 architecture styles there, its been a while, but one was kind of wacky. i think it was the last one Mar 25 08:17:37 its the one where the content provider itself, is the interface to the web service Mar 25 08:18:05 so you query the provider, and it returns i think a null cursor Mar 25 08:18:14 but sends a http get out Mar 25 08:18:24 when it comes back, it does a uri notification Mar 25 08:18:31 and then you requery with the loaded data Mar 25 08:19:08 kinda have to break the contract for provider tho, seems weird. Mar 25 08:19:34 * g00s wonders if anyone ever decided to run with that architecture Mar 25 08:22:39 seems hard Mar 25 08:23:00 this is android :) Mar 25 08:23:11 everything is 2-3x more difficult than it needs to be :) Mar 25 08:24:33 :) Mar 25 08:24:35 sounds fair Mar 25 08:24:36 you're so dramatic .... Mar 25 08:24:51 for example, look at Google Keep. that thing is like 1-2 steps above Reto's Hello World Note app; but its probably like 40k lines of code Mar 25 08:25:05 cause it has some animations and shininess Mar 25 08:26:02 i'm wondering did google abandon Keep already, there have been no updates Mar 25 08:26:06 hehe Mar 25 08:26:24 ios imageView.animationImages = @[ img1, img2, img3 ]; Mar 25 08:26:28 :( Mar 25 08:27:16 .gif like animation is done so Mar 25 08:27:17 doh! the one thing I thought they'd hang on to , with a name like 'Keep' Mar 25 08:27:27 ios has some really nice features, but other things make me think "wtf, why aren't you doing this by default???" Mar 25 08:28:03 g00s: what about sync adapter? http://developer.android.com/training/sync-adapters/creating-sync-adapter.html <- isn't this exactly what I need? synchronization between local database on android and restful web service? Mar 25 08:28:19 frojnd sure, another piece to toss into the salad Mar 25 08:28:33 through in yourself some AccountManager for more fun Mar 25 08:28:36 *throw Mar 25 08:28:37 g00s: this way my app can work offline and if user taps a button that needs to send request to a web service, that request will be sent after phone gets network connection? Mar 25 08:29:09 frojnd you'll probably also look at google GCM Mar 25 08:29:46 bah Mar 25 08:29:53 don't wanna use anything from google cloud Mar 25 08:29:54 i have a confession, i haven't done a REST app on android Mar 25 08:30:00 beside, REST is for sleeping Mar 25 08:30:04 mqtt is for mobile :D Mar 25 08:30:18 mqtt win Mar 25 08:30:23 g00s: server side rest. Android will just communicate with rest Mar 25 08:30:40 i use RESTful service for registration Mar 25 08:30:46 and all other coms with mqtt Mar 25 08:31:02 nice Mar 25 08:32:56 hm Mar 25 08:33:16 lemonxah: you used to use restful android client in the past? Mar 25 08:33:30 Any of you guys set up intellij to use groovy to run the build.gradle directly in intellij? Mar 25 08:33:44 frojnd, i use post and get at the moment Mar 25 08:34:09 to a website with json data Mar 25 08:34:13 lemonxah: for the authentication, if I understand you right? Mar 25 08:34:14 but only for registration Mar 25 08:34:27 yeah kind of like that yes Mar 25 08:34:34 and all my other comms runs over mqtt Mar 25 08:34:44 rgr just use AS :) Mar 25 08:35:13 unless you are using a paid version or something, and have plugins you need Mar 25 08:35:17 lemonxah: can you explain how does this work (just for registration) what apis or classes did you use to make it work? Mar 25 08:35:26 rgr intelliJ supports build.gradle Mar 25 08:35:39 yes I know. Mar 25 08:35:54 frojnd, i just use httpclient Mar 25 08:36:09 But Im referring to using a groovy edit configurations as opposed to the built in build.grade "defaults". Mar 25 08:36:20 frojnd, http://www.androidsnippets.com/executing-a-http-post-request-with-httpclient Mar 25 08:36:55 g00s: I see no reason to use AS. All the gradle support is in ij. Im just experimenting with other approaches. Mar 25 08:37:56 lemonxah: ok thanx. Mar 25 08:37:56 rgr can intellij use gradle 1.11 and gradle-plugin 0.9 ? Mar 25 08:38:05 frojnd, that is what you are looking for? Mar 25 08:38:14 lemonxah: not particularly Mar 25 08:38:39 frojnd, then i dont understand what you are trying to do Mar 25 08:38:54 do you mean server side? Mar 25 08:39:00 I use (have defaulted) gradle 1.11 but use the gradlew wrapper for my android samples and throttle the per project version to 1.10. Mar 25 08:39:01 i host my own server Mar 25 08:39:15 lemonxah: I'm looking at a way to work with a restful web service if there are interruptions from client side. Like user is trying to send a post to a restful server but he is without network connection. Mar 25 08:39:17 and i wrote it in scala using scalate Mar 25 08:39:49 frojnd, those things i handle client side with events Mar 25 08:39:58 lemonxah: or he is withut internet connection at all when he starts app but he can see "last synced" stuff on the phone Mar 25 08:40:00 you get events with a Broadcastreceiver Mar 25 08:40:12 to know if there is internet or not Mar 25 08:40:18 but I read something late last night that suggests 1.11 might now work. Was late. Mar 25 08:40:24 (13.1.1) Mar 25 08:42:29 lemonxah: yeah, but would I need some sort of database on android to show data from the previous requests from rest web service? Mar 25 08:43:14 lemonxah: for a solution when user starts app completely without internet connecetion or data connection Mar 25 08:43:21 yes Mar 25 08:43:26 contentprovider Mar 25 08:43:31 and content resolver Mar 25 08:43:42 those two are for database? Mar 25 08:44:02 its like a mvc / mvvm aproach for android Mar 25 08:44:16 not exactly the same but its the closest you will get with the android framework Mar 25 08:44:29 One thing that does seems overly comlex or messy is the concept of creating a library jar for use in another android project. Got there in the but seems rather long winded and you need to specifically build artifacts. Mar 25 08:46:27 rgr its 3 lines of code Mar 25 08:46:38 lemonxah: So now I know I must use HttpClient, for a communication between client (android) and server (rest). I know that I have to create database on android in order to show data if there is no connectio (I must implement events -> BroadcastReceiver to tell if there is network connection) Mar 25 08:47:15 ok Mar 25 08:47:30 uploadArchives { repositories { mavenLocal() } } basically Mar 25 08:48:10 that is if you have your own maven repo Mar 25 08:48:17 or access to upload to one Mar 25 08:48:26 g00s: what is? Mar 25 08:48:35 it just stuffed it in ~/.m2/repository Mar 25 08:48:37 lemonxah: I don't know how to create database on a client side? At the beginning when I know how rest web service is built? Or can this be done automatically somehow? Mar 25 08:49:14 Not sure what you mean. Its nothing to do with maven. I was referring to creating my own android utility library. Are we at cross purposes? Mar 25 08:50:38 rgr we're talking about the same thing Mar 25 08:50:40 create anroid project, add module, project structure, modules, artifacts, add artifact (the library) then be sure to filter out app-support stuff etc. Mar 25 08:50:41 heh Mar 25 08:50:50 O.o Mar 25 08:51:30 rgr did you look at gradle-samples mavenLocal ex? Mar 25 08:51:46 i dont use the ide to make anything, i just use the gradle DSL Mar 25 08:52:37 i mean, use any of those fancy dialogs Mar 25 08:52:44 mkdir -p x/c/v/b/n Mar 25 08:52:46 you have a ref to this? I dont mind moving fully to command line gradle but bit at a time. Mar 25 08:52:50 touch build.gradle :) Mar 25 08:53:17 i launch from the ide, but i do all my project structure / build system stuff though the DSL Mar 25 08:53:53 If you do it like that it kind of begs the Q as to why you use AS whose sole role in life is to limit to Android Dev and to smooth over the gradle experience. Mar 25 08:54:46 lemonxah: probably I'd have to define database when app is being installed at the very beginning right? Mar 25 08:54:48 gradle is powerful. if the dialogs get you where you need, thats good Mar 25 08:54:58 but to really leverage it, you need to know a little about the DSL Mar 25 08:55:04 and the android gradle plugin DSL Mar 25 08:55:49 lemonxah: also any ideas of what can I use when there is an event about network lost so that user is noted that he is working in offline mode and when network comes back request is being sent? Mar 25 08:57:06 frojnd, the SqliteOpenDatabaseHelper handles creating the the database when its first accessed Mar 25 08:58:13 frojnd, a google search on "android network connection state" will give you the information you need most likely Mar 25 08:58:25 lemonxah: thank you very much! Mar 25 09:01:08 lemonxah: https://developer.android.com/reference/android/database/sqlite/SQLiteOpenHelper.html is it possible these are the same? SqliteOpenDatabaseHelper and SQLiteOpenHelper Mar 25 09:01:21 Hello. We have some trouble with local broadcast receiver. It works fine on my galaxy S4 phone but on tablet and galaxy s3 mini(but not on another same type of phone) program crashesh. Relevant code(all I think) is on http://pastebin.com/MFx2N3gy - Program crash right after tmp.sendBroadCast(intent); call so I presume problem is with the receiving part. Anybody could help us? Mar 25 09:01:58 sure, but like I said its all in intellij too. istn gradle the DSL? You cant say gradle plugin dsl can you? (So many new terms) Mar 25 09:02:11 yes frojnd Mar 25 09:02:33 sry i was just writing i know what it is but my brain filled in the Database part sorry Mar 25 09:02:51 action.compareTo("update_workplaces")==0 O.o Mar 25 09:03:33 tneva82 if you are using localbroadcastmanager, you aren't *really* using broadcast receivers Mar 25 09:03:45 anyhow, a stacktrace should tell you exactly what the problem is Mar 25 09:03:50 since its all local to your process Mar 25 09:09:59 anyone seen this? suddenly all my sdks stopped working in eclipse - Ignoring platform 'android-19': ro.build.version.sdk is missing from 'build.prop' Mar 25 09:12:41 guess a reboot might work :( Mar 25 09:19:34 g00s: so from your point of view if I have a lib that I built elsewhere and I stick it in a repo directory somewhere then this line in my build.gradle *should* bring it in? "compile fileTree(dir: '~/development/java/libs', include: ['*.jar'])" Mar 25 09:20:15 rgr built elsewhere … on your computer or some other machine? Mar 25 09:20:32 also, did you use gradle to build it ? Mar 25 09:20:37 (the lib) Mar 25 09:23:07 Well, lets assume yes and yes.. would that be the right line? Currently Im only getting it to work if I drop the jar into the project lib dir. gradle does the building on this machine yes. Mar 25 09:24:28 no, you would build your lib; and have gradle install it into mavenLocal(), which is ~/.m2/repository Mar 25 09:24:49 then, to use it in your project, you would add mavenLocal() to the repositories { } block Mar 25 09:24:58 and in dependencies, add compile (my lib) Mar 25 09:25:13 its right there in the gradle plugin example Mar 25 09:25:32 android-gradle plugin example Mar 25 09:25:33 and yet me just dumping it into projectdir/lib works fine. Mar 25 09:25:42 yeah but thats dumb Mar 25 09:26:04 so you're going to have to exclude it from your version control Mar 25 09:26:20 but works and should be all thats required : this is nothign to do with maven. nothing. the library contains NO maven components and even it did its another project. Mar 25 09:26:44 gradle uses the maven repository layout for its stuff Mar 25 09:26:45 its "just a lib" that gradle should make available to the project build. Mar 25 09:26:50 thats only why maven is mentioned Mar 25 09:27:01 yup Mar 25 09:27:12 I dont keep mentioing maven ;) You're confusing me. Maven doesnt come into it. Mar 25 09:27:16 Or? Mar 25 09:27:20 i dont think i even have maven installed Mar 25 09:27:24 Huh? Mar 25 09:27:51 Now im really confused. Why keep on about maven? You have me worried Im missing something really obvious. Mar 25 09:28:01 rgr read the docs Mar 25 09:28:02 "D Mar 25 09:28:14 look at the damn examples Mar 25 09:28:39 the stuff at the bottom of this page http://tools.android.com/tech-docs/new-build-system Mar 25 09:28:49 get the samples, look at mavenLocal Mar 25 09:30:59 ok. forget it but thanks anyway. We seem to be at cross purposes. Once again :this is nothing whatsoever to with maven. Its simply to do with a local gradle dependency as covered there with no reference to maven whatsoever. See "Dependencies, Android Libraries and Multi-project setup" Mar 25 09:31:07 when you run gradle for the first time ever, what happens ? with an empty .gradle dir ... Mar 25 09:31:30 it downloads the whole internet, into .gradle … into a maven directory structure cache Mar 25 09:31:39 yes I know. I use the wrapper remember. Mar 25 09:31:52 so maven has nothing to do with it Mar 25 09:32:01 its the dir structure layout , coordinate system, gradle uses Mar 25 09:32:04 Is there any way to download a .txt from my application and then shove it into my res/raw directory? Mar 25 09:32:17 EGHDK no Mar 25 09:32:28 you can put it in your private data dir Mar 25 09:32:32 your APK is read only Mar 25 09:32:39 g00s: I really appreciate your help but its not me bringing up maven all the time. You do. I know its nothign to do with maven. I have said this about ten times above. OK, lets leave it. Cheers anyway. Mar 25 09:33:18 rgr you had a library you wanted to use by your own projects.a local library. thats accomplished, using a local repository Mar 25 09:33:23 A LOCAL MAVEN REPOSITORY Mar 25 09:33:28 g00s knows what he's talking about and is trying to help you while others have already given up, stop being so dense, rgr. Mar 25 09:34:13 :) Mar 25 09:36:38 dense? Cheers for that.... very nice. g00s thanks. I'll re-read. But like I said its a local repo not in maven and works fine. I only wanted to point to a different tree. I dunno. Mar 25 09:37:18 You're welcome Mar 25 09:38:00 rgr so lets say you have 3 projects that use your library. are you going to copy that into each project's libs/ dir? thats what we're trying to avoid Mar 25 09:38:16 ok, gotta code Mar 25 09:38:18 :) Mar 25 09:40:50 No, which is why Im using the compile dependency to an external lib as explained in the gradle build tool documentation. I'll run through it again. I do appreciate you help. kakazza however can take a ride ;) dense indeed.... Mar 25 09:42:51 kakazza :D Mar 25 09:44:00 What's the easiest way to add tabs to my app? Mar 25 09:45:20 https://developer.android.com/training/implementing-navigation/lateral.html Mar 25 10:04:03 I use Jackson for my json. Mar 25 10:04:44 I create an ObjectNode and convert to string to send during POST request Mar 25 10:06:12 I just found out calling objectNode.asText() doesn’t serialize it to the appropriate string Mar 25 10:06:23 anything I could be doing wrong? Thanks Mar 25 10:06:43 morning Mar 25 10:07:10 having the weirdest issues in a webview-ified webapp. actually, even just browsing to it on a htc desire hd is fricking magical. Mar 25 10:07:36 can't scroll, and if I remove my meta viewport tag, both the browser and the webview just crashses Mar 25 10:07:55 and CAN zoom, even though it's disabled in the meta tag Mar 25 10:08:05 googling is getting me nowhere. ideas? Mar 25 10:11:22 logcat says nothing about the crash. wtf. Mar 25 10:11:40 [WebView.WebView] >> Enable Shutdown = true Mar 25 10:29:14 That's working. a local flatdir containing the library jar was wrong in my repository setting. Fixed. Working. Mar 25 10:41:38 hello Mar 25 10:42:03 I need some help with Endpoints + Android. Mar 25 10:43:01 I coded an Endpoints Python backend for my Android App. Mar 25 10:43:29 I generated the jar file to add into my Android project as a library. Mar 25 10:43:45 I'm using Android Studio. Mar 25 10:44:29 I'm able to add the jar, but no class from it or it's model is recognized by AS. Mar 25 10:45:20 SOF has a question regarding this matter, but so far unanswered. Mar 25 10:45:51 http://stackoverflow.com/questions/22597097/using-client-library-from-cloud-endpoints-jar-import-not-working Mar 25 10:46:27 Some one knows how to fix that? Mar 25 10:55:04 hey, anyone have any issues with keytool? I enter my password fine in eclipse and it builds, also if i type in manually from command line, it works, however if I enter it into gradle config, it says my password is wrong Mar 25 10:55:10 could be an encoding issue? Mar 25 11:04:14 hey guys, I have a quick question about services. I want to make a service that will play some music in background even when the starting activity is destroyed. I want to communicate with service through IBinder interface. SO question is: if I start the service with startService() and then immediately run bindService() to make interface-connetcion for updating UI - will the service remain running after activity is destroyed? Mar 25 11:07:34 Hi I have following problem: My Activity A is extending Activity B which overrides the onResume method to execute an Asynctask. The onCreate method in Activity A also executes an AsyncTask. They seem to block each other because when Activity A isn't extending Activity B it works. How can I let the AsyncTask in Activity B wait for the first AsyncTask or how can I get them not blocking each other? Mar 25 11:10:01 byt89: maybe use post/preExecute to start/stop the other asynctask Mar 25 11:10:28 Hello Mar 25 11:12:27 hi Mar 25 11:12:34 i have a problem with linux deploy Mar 25 11:12:41 line 1535 dd: Permission denied Mar 25 11:14:15 I have ViewPager with multiple pages (fragments), now when I want to add another fragment inside every page. But they all are placed in first one. I attached new fragment on every page, but they all show in first one. What am I doing wrong ? Mar 25 11:20:09 Hi all, can i start a service on boot without using an activity? Mar 25 11:20:40 i had implemented it but the service doesnt start Mar 25 11:24:52 barbs: fix your connection! Mar 25 11:50:23 brandy_m: has anyone ever suggested to you that this is the right channel to ask about whatever linux deploy is? Mar 25 11:50:40 bambuka: yes, of course you can Mar 25 11:51:53 Leeds, tell me the right channel Mar 25 11:52:47 not this one Mar 25 11:54:11 brandy_m: are you trying to install an IDE to program android ? Mar 25 11:54:34 no Mar 25 11:54:55 anything to do with android ? Mar 25 11:56:30 Leeds, I created a class "Autostart extends BroadcastReceiver" that create a intent for startService(intent) Mar 25 11:56:47 I've created 10 fragments for all the screens of my app, I'm trying to figure out how to manage them on screen. I'm thinking about a ViewPager but I dont want all my fragments available using scrolling, for example I have a login screen, I want it to be displayed first and only after the user logs in the next 3 fragments are avaiable. any suggested method I should go with? Mar 25 11:56:53 but the service never start at boot Mar 25 11:57:04 bambuka: does the broadcastreceiver get run? Mar 25 11:57:10 not Mar 25 11:57:17 obviously you've done the necessary in your manifast Mar 25 11:57:20 er, manifest Mar 25 11:57:36 manifast is a speedy nail cutting service... Mar 25 11:57:43 and uses permision with receive_boot_completed Mar 25 11:58:56 so the question is nothing to do with services or activities - it's about getting your broadcastreceiver to run Mar 25 11:59:16 ok. thx Leeds Mar 25 11:59:31 can i pastebin you de manifest? Mar 25 11:59:41 its too short Mar 25 11:59:49 sure Mar 25 12:01:17 Leeds, http://pastebin.com/pVhX5zpA Mar 25 12:01:21 thx so much Mar 25 12:02:11 that looks okay to me Mar 25 12:03:06 Hi, Mar 25 12:03:22 ok, I'll keep on trying Mar 25 12:04:13 I see that some lines of code in onCreate() of and Activity is called when the screen orientation changed... Mar 25 12:04:18 That was unexpected. Mar 25 12:04:26 but not all the code. Mar 25 12:04:53 an* Activity Mar 25 12:04:59 leeds. in theory, boot->manifest->broadcastReceiver class->service class Mar 25 12:05:11 that the ? Mar 25 12:05:15 and my problem its on manifest Mar 25 12:05:19 bambuka: take a look at http://pastebin.com/tdRm1ri8 Mar 25 12:05:20 ? Mar 25 12:05:25 my manifest seems to be the same as yours Mar 25 12:06:08 what I do is have my broadcastreceiver run my Service 1 minute later - because the BroadcastReceiver can run before the network is connected, so it just waits a bit Mar 25 12:06:34 i dont check for the class of action -> if (action.equals(Intent.ACTION_BOOT_COMPLETED)) Mar 25 12:06:57 you probably don't have to Mar 25 12:07:10 I don't say I am an expert, but my code works :) Mar 25 12:07:24 Hi Mar 25 12:07:28 hi hi Mar 25 12:07:53 :) Mar 25 12:09:06 is it a "rain alarm" service? Mar 25 12:09:08 hi all, anyone knows about FileObserver (file monitoring) ? I need some help ... Mar 25 12:09:08 :) Mar 25 12:09:19 something like that, yes Mar 25 12:09:29 rain, typhoons, hot/cold, etc. Mar 25 12:09:50 have you the source on github/bitbucket? Mar 25 12:10:00 nope Mar 25 12:10:11 ok :) Mar 25 12:11:07 i want to monitoring /sdcard/ file changes and timely destroying the files, but i have no idea to do that... Mar 25 12:12:31 You start your service from an activity or just at boot time without activity intermediate? Mar 25 12:13:01 hum i have a FragmentActivity that launch somes activities and i have activate the up on actionBar. Back and up don't do the same thing is it normal? Back do back and nothing more, up recall onCreate method and if i have onSaveInstanceState in the onCreate the bundle in params is null. Someone has an idea about what i'm doing wrong? Mar 25 12:16:02 bambuka: both Mar 25 12:16:12 How to disable auto-clear LogCat in eclipse? Mar 25 12:17:00 what does a fragment's .getTag() return? Mar 25 12:17:04 the boot broadcastreceiver always runs, and as you can see it checks if the user has chosen to run the service at boot time or not... otherwise, the user can manually start the service from a regular activity Mar 25 12:17:13 does it return the tag you set when adding it to the fragment manager? Mar 25 12:17:22 and the service schedules itself to run again in 15/30/60/etc/etc/ minutes when it's finished Mar 25 12:17:32 and its null if the fragment did not come from the fragment manager? Mar 25 12:18:47 ok Mar 25 12:19:45 How to disable auto-clear LogCat in eclipse? Mar 25 12:23:00 has anyone used .getTag() on a fragment? Mar 25 12:23:41 lemonxah: is there any reason why it work work differently from getTag on anything else? Mar 25 12:24:01 Leeds, there is no setTag() Mar 25 12:24:10 so i want to know how and when the tag is set Mar 25 12:24:24 the documentation is extremely vague regarding it Mar 25 12:24:38 Get the tag name of the fragment, if specified. Mar 25 12:24:44 so how do you specify it? Mar 25 12:26:10 Leeds, ? Mar 25 12:26:24 looks from a quick browse on stackoverflow that you can either specify a tag in a FragmentTransaction, or in XML... I don't use Fragments Mar 25 12:26:42 yes but my question was that exactly though Mar 25 12:27:04 if you get fragment but not from the fragment manager thent he getTag will be null? Mar 25 12:27:17 either that, or it'll return the magic string "pony" Mar 25 12:32:44 So i'm using an android device which only has an external HDMI output. Is there any way to allow it to change it's orientation? Mar 25 12:32:55 I have a rooted device, so i'm up for anything Mar 25 12:33:45 The code i'm using works fine if it's a mobile device, but since it's a streaming device with HDMI, it's almost like they think the idea of orienting the screen is completely out of the question Mar 25 12:40:34 Hey anyone recommend a library for picking multiple images from a phones gallery? The best I could find was this https://github.com/luminousman/MultipleImagePick Mar 25 12:41:48 nobody has an idea on my problem? Mar 25 12:43:37 Mentos: you can use Cursor.moveToNext() with MediaStore.Images.... Mar 25 12:44:09 without needing an external library Mar 25 12:45:13 or Cursor.moveToPosition(position) Mar 25 12:45:47 Leeds it does return pony :/ Mar 25 12:49:49 shmooz: which activity are you talking about? Mar 25 12:50:29 you can do that in your activity in onCreate or use asynctask if it studders Mar 25 12:51:39 for getting the images in an array or whatever and then write more code elsewhere in your mainactivity for picking them Mar 25 12:52:04 but uh, which activity would i be presenting to the user to select multiple photos from their device Mar 25 12:52:36 from my stack overflow research it shows thats not possible with stock Activities? Mar 25 12:54:32 you probably don't need to present an activity, you can just open up a view Mar 25 12:55:05 or layout or whatever Mar 25 12:55:24 or you can put all in a new activity if you like Mar 25 13:13:54 Is there a way to inject dependencies to a Service? Mar 25 13:39:27 Question: BitmapDescriptorFactory has a bunch of constants that are type floats, but have values like HUE_BLUE, HUE_RED etc, and are used like: BitmapDescriptorFactory.HUE_AZURE. How would make that a var of it's own, so I can set it, before using it in a function? I've tried a string and a float, but neither work Mar 25 13:46:18 i have an actionbaractivity (support lib) and i call setTitle("Blah"); when i then call getTitle() i get "Blah". Only when running the app the title is the name of my app (which is not "Blah"). What could be responsible for this? It works properly on 4.x but on 2.3 it fails like specified Mar 25 13:46:26 ThomQ: define "neither work" Mar 25 13:48:25 thomq the 'var' already is HUE_AZURE Mar 25 13:48:38 it's 210 Mar 25 13:50:02 i tried it like this: Float HueVar = 210, BitmapDescriptorFactory.HueVar and like this: String hueVar = UE_AZURE, BitmapDescriptorFactory.HueVar Mar 25 13:50:45 i have an if statement in which it should define HueVar, and use that after the loop Mar 25 13:52:09 ?? Mar 25 13:52:25 float blah = BitmapDescriptorFactory.HUE_AZURE; Mar 25 13:53:01 then blah is 210 Mar 25 13:53:37 210.0 Mar 25 13:53:47 but i cant use it to set the hue later with BitmapDescriptorFactory.IconHue though Mar 25 13:53:58 BitmapDescriptorFactory.blah in that case :P Mar 25 13:54:17 bitmapdescriptorfactory is not your class Mar 25 13:54:35 there is no .blah Mar 25 13:54:39 ThomQ: I think for sure a small pastebin would help. It seems your mixing up classes. Mar 25 13:54:41 Hello! Can I get the BSSID of the wifi related to a NetworkInfo object? Mar 25 13:55:16 Code snippet: http://pastebin.com/emqZXcjA Mar 25 13:55:49 whats IconHue? make it complete. Mar 25 13:56:19 which IDE are you using, if any? Mar 25 13:56:37 IconHue is a public static float. It's a class member Mar 25 13:56:53 IntelliJ IDEA Mar 25 13:57:34 starting with a capital I? And then you use it as a field name? Mar 25 13:57:54 i never said i wasn't a n00b Mar 25 13:57:59 possibly my java isnt hot enough... but that looks dodgy from here. Mar 25 13:58:13 istn intellij telling you the problem? Mar 25 13:59:08 yes, it can't find the variable iconHue Mar 25 13:59:52 thats because of line 16 Mar 25 14:00:03 uhuh Mar 25 14:00:09 basicly, all i'm trying to do is to define the value of the constant, before i use it. Mar 25 14:00:11 BitmapDescriptorFactory has no IconHue Mar 25 14:00:20 as a first step make the member iconHue. And thats before any other issues. check the parameters to call in line 16. Use smart completion to help you. Mar 25 14:00:28 constants generally don't allow reassignment Mar 25 14:00:35 the ".IconHue" bit is wrong for a start. Mar 25 14:00:58 you want the constant value into a float an pass the float. you're not doing that. Mar 25 14:01:35 and thats assuming that call in line 16 accepts a hue value which you have assined to (newly renamed) this.iconHue. Mar 25 14:01:46 well, the main problem would be that iconHue isn't a class member of BitmapDescriptorFactory, right? Mar 25 14:01:56 No. Mar 25 14:02:22 its not a member of your class. and neither is IconHue which is what you assigned a value to in your code snippet. Mar 25 14:03:04 and it probably doesnt want to be static either if this is your own instance. Mar 25 14:04:00 ow yes, it has to be static, it's being used in a static context Mar 25 14:04:19 make it easier. define a local Float before mainloop. "Float saveHue;" . The set that in line 7. (not that this is good structure but at least we can get it compiling for you) . Then pass that to whatever in line 16. Mar 25 14:05:01 icon(BitmapDescriptorFactory.defaultMarker(BitmapDescriptorFactory.IconHue)) <--- I have no idea if that default Mar 25 14:05:06 arker takes a float Mar 25 14:05:23 defaultMarker(). Thats where intellij can help. Mar 25 14:06:39 like so? http://pastebin.com/sNzsXiiL Mar 25 14:06:50 hey guys, I was wondering where properties are stored for commands called from adb shell setprop? Mar 25 14:06:51 it still can't resolve the iconHue var in line 18 Mar 25 14:06:55 intellij Q : when using the java or android plugin DSL can one dynamically query settings like in a console? Mar 25 14:07:00 Bitmap thumbnail = (Bitmap) data.getExtras().get("data"); make nullpointerexception on camera intent Mar 25 14:07:03 why? Mar 25 14:07:22 ThomQ: well of course it cant Mar 25 14:07:31 how can i show grid lines for gridview? Mar 25 14:07:48 read what you have passed. read what intellij is telling you. You have not passed savedHue. Mar 25 14:07:48 so say I call 'adb shell setprop persist.demo.hdmirotationlock false', where is this value being stored? Mar 25 14:08:33 you have passed some magical new invention called BitmapDescriptorFactory.iconHue whatever that is ;) Mar 25 14:08:55 :P Mar 25 14:09:12 I guess im confused to what you mean with "The set that in line 7. (not that this is good structure but at least we can get it compiling for you) . Then pass that to whatever in line 16." Mar 25 14:09:16 try ##java too... but be careful. Its like a nest of vipers... Mar 25 14:09:29 yeah they ignored that question :P Mar 25 14:10:34 because its so very basic. Sorry. You declare a vairable : "Float savedHue;" You assign a value "savedHue=VALUE; ". You than pass that to whatever needs it later. Mar 25 14:11:04 you are passing BitmapDescriptorFactory.iconHue NOT your savedHue. Mar 25 14:11:27 use the errors from the IDE : tis what they are there for. Good luck : it can be daunting. but stick with it. Mar 25 14:11:53 iconHue and savedHue are both floats though, and neither are classmembers of BitmapDescriptorFactory.. Mar 25 14:12:21 err, correct. Mar 25 14:13:03 so the outcome is the same, the var can't be resolved Mar 25 14:13:08 so why are you using iconHue as if it was? iconHue didnt even exist a while ago. We changed the name to savedHue to stop you getting confused with a class IconHue and the variable iconHue. Mar 25 14:13:22 savedHue didnt exist I should say. Mar 25 14:13:53 no, that was just my bad capitalization :P it was always a float Mar 25 14:14:25 what is the default font on a TextView if I don't specify one? Mar 25 14:15:16 what? Q: What do you mean your bad capitalization? Mar 25 14:15:53 i called it IconHue in that example, why i should used iconHue Mar 25 14:16:40 because you clearly are confused over class and instance/vars. I suggested your changed the var to a name where you didnt get mixed up. look : http://dpaste.com/1755704/ Mar 25 14:16:53 look where savedHue is used. Mar 25 14:17:22 read the errors intellij tells you. I have no idea if that call in line 18 even takes a float. good luck. Mar 25 14:17:51 AHhhhhh Mar 25 14:17:53 thanks man Mar 25 14:18:18 ps its standard for java vars to start with lower case. I suggest you read a beginners book on classes, instances, variables and calling functions. Mar 25 14:18:19 Insstead of .icon(BitmapDescriptorFactory.defaultMarker(savedHue), i was using .icon(BitmapDescriptorFactory.defaultMarker(BitmapDescriptorFactory.savedHue)) Mar 25 14:18:27 as I said ten times. Mar 25 14:18:41 hue Mar 25 14:19:15 lol dude, i know that. Every now and then in quick code i do still make mistakes though, my bad. Mar 25 14:19:23 But I think it works now, let me compile Mar 25 14:19:41 hy all Mar 25 14:19:51 it was more than that. you tried to use a class as a var. you then tried to use that as an member on an instance. none of which existed. Mar 25 14:20:15 oh god. is this a hipster channel? Mar 25 14:20:21 I tried to use gradlew build in cmd, but android studio still can't sync project with gradle. What is the problem? Mar 25 14:20:22 yeah it works Mar 25 14:20:28 L0j1k: ... wat? Mar 25 14:20:39 what I dont understand is why you're not using intellij to tell you the errors. This was gross syntax errors all the way though. Mar 25 14:21:04 about 40% of the channels on freenode revolve around insulting one another Mar 25 14:21:35 gregtom6: back to intellij again I take it? Mar 25 14:22:48 Nah, all it said was it couldn't resolve it. I didn't realize BitmapDescriptorFactory.HUE_AZURE was a float, i thought HUE_AZURE itself was the float Mar 25 14:23:07 L0j1k: what the fsck are you wibbling about? Mar 25 14:23:14 ^ Mar 25 14:23:44 hipster channel? Mar 25 14:23:46 and you have a var called IconHue and you tried BitmapDescriptorFactory.IconHue which made zero sense ;) Anyway you got there.... Mar 25 14:24:03 yeah exactly, i get it now Mar 25 14:24:05 thanks :) Mar 25 14:24:36 np... read the IntelliJ errors in the editor. I cant see how you would have even thought that would compile. Good luck! Mar 25 14:26:27 btw that code in the pasebin is still wrong. There is a change savedHue will be null. Mar 25 14:26:35 s/change/chance Mar 25 14:28:00 rgr: yes, because I want to know a bit better this studio too Mar 25 14:28:06 and now I have more time to discover Mar 25 14:31:52 how did you create the wrapper? Pastebin the error output. Saying "it cant sync" tells very little. It depends what its trying to sync amongst other things and that depends on the dependencies in your build.grade. Mar 25 14:32:16 (Ive just been through all this) Mar 25 14:35:04 ugh Mar 25 14:36:29 hey guys, i want to save my whole app state, which includes imagebuttons with images. Since i cannot save images with sharedpreferences i wonder what else is probably the best. I´d love to save just my whole bundle to a file but from what i`ve read this is not reliable. what do you say? Mar 25 14:37:56 so i'm unable to force my device not to turn on the hdmirotationlock, using setprop persist.demo.hdmirotationlock false Mar 25 14:38:00 any ideas why this wouldn't work? Mar 25 14:39:02 bacon1989: just so you know, if you'd read the channel topic, it says very clearly at the start "Android application development" Mar 25 14:39:52 Leeds: manipulating the android system programmatically isn't considered development? Mar 25 14:40:42 yeah, definitely not cool enough to be in this hipster channel... peace Mar 25 14:45:10 sound on topic to me too I must admit... Mar 25 14:50:34 adkins you could save the images as base64 encoded strings Mar 25 14:51:45 the_fog: this saves the image itself in a string? Mar 25 14:53:08 adkins yeah, you encode to a string and save in shared prefs. re-encode when needed Mar 25 14:54:50 the_fog: nice, is there a limitation of saving with sharedpreferences? i think i`ve read somewhere that it is only for small amount storage like user-logins and stuff Mar 25 14:56:01 hum i have a FragmentActivity that launch somes activities and i have activate the up on actionBar. Back and up don't do the same thing is it normal? Back do back and nothing more, up recall onCreate method and if i have onSaveInstanceState in the onCreate the bundle in params is null. Someone has an idea about what i'm doing wrong? Mar 25 15:02:28 i'm not passing in the onRestoreInstanceState if i add it in place of restore state from onCreate Mar 25 15:10:41 adkins: I stored my images in sqlite3 as blobs. That way I can hold more metadata in other columns to describe where it came from if need be Mar 25 15:11:14 where can I set gradle folder? I have forgotten where can I find that window Mar 25 15:11:48 bacon1989: thank you too. will think about it......so would you say sharedpreferences is limited? Mar 25 15:13:07 What should if I only want to display the last for digits after a decimal point in a float ? Like if I want to display 0.8987654 as 0.8987 ( no rounding ) Mar 25 15:13:21 Anyone know of a library that will take two dates and return a human readable duration "3 days", "2 weeks" , "5 hours" etc ? Mar 25 15:13:23 can I dev android apps in clojure or scala for example? Mar 25 15:13:50 adkins: hmm, idk. I just found it easier to put it in a database Mar 25 15:14:04 bacon1989: aight Mar 25 15:14:19 also, it's more unique, since I can also include other information on the images stored Mar 25 15:14:33 adkins the lowest size limit will be the amount of free heap space the app has Mar 25 15:15:13 storing it in shared prefs would probably be easier if you don't need to worry about more of the knitty gritty details Mar 25 15:15:57 or rounding the float to 4 decimal points would also work. Mar 25 15:17:14 in xml, why hasn't the style attribute an android: prefix? Mar 25 15:23:24 why onCreate is call after a up on actionBar and not on back button? and why saveInstance Bundel is null in case of new call to onCreate? Mar 25 15:24:28 OnCreate should be called on up button only if the parent activity is destroyed. i'm right? Mar 25 15:28:27 the_fog: thank you. I`ll think about both variants Mar 25 15:28:40 finally I could imported a project into android studio...it has taken fow a while Mar 25 15:28:48 *had taken Mar 25 15:33:46 gregtom6 how exactly? Mar 25 15:34:28 gregtom6 I gave up after 3 hours. the studio kept converting mine to gradle and moving all my files Mar 25 15:34:40 i had to go back to eclipse Mar 25 15:35:16 So I am trying to get the new LocationClient working, if I use a requestLocationUpdates to my LocationListener it works fine, but If I try to use the PendingIntent version I am for some reason not getting any intent to to my service Mar 25 15:35:30 the_fog: if project sync not working, I need to download packages with sdk manager, sometimes build-tools 19.0.3 missing, sometimes a support library if a project refers to that Mar 25 15:36:19 how can i find out what the latest version of the gradle is? inspection says a newer version is available than '0.7.+' but not which it then is Mar 25 15:36:25 sometimes it's good to use cmd and go to the project's folder and gradlew build, because sometimes I get new and other error messages in here what android studio doesn't showed before Mar 25 15:37:14 osxorgate: I had guessed that there is another version of gradle plug-in and the gradle itself Mar 25 15:40:36 the_fog: sometimes you need to change the gradle.build file's version numbers to be good for your android studio/and the sdk files Mar 25 15:41:05 there's an "inner" build.gradle file in one of the project's folder too Mar 25 15:44:10 I can't scroll on my webapp on htc desire. works on other test phones. all scrolling is within other divs, the actual body is never larger than the viewport. ideas? Mar 25 15:44:35 htc desire hd even Mar 25 15:45:05 gregtom6 it's a non gradle project, but the studio trys to convert it to grale Mar 25 15:45:17 *gradle Mar 25 15:45:22 the_fog: I know Mar 25 15:45:39 the_fog: you can export that from eclipse to be a gradle project Mar 25 15:45:50 the_fog: somewhere in the export you can find that option Mar 25 15:45:58 build that to be a gradle project Mar 25 15:46:43 okay sorry, i wasn't aware. i'll give it a go. thanks Mar 25 16:05:31 can you show me a good example for nfc reading, writing? Mar 25 16:14:31 My class has a List property. It returns this with 'getList()'. I'm a little confused about something. Mar 25 16:14:44 I want getList to return a copy, not the exact instance. Mar 25 16:14:52 I can't, of course, say "new List()". Mar 25 16:15:09 What is the best thing to do here? Make my class take an ArrayList instead of a List? Mar 25 16:15:38 And then say "return new ArrayList(originalList);"? Mar 25 16:15:40 TacticalJoke, first of all Mar 25 16:15:42 new List(listToBeCopied) Mar 25 16:15:54 TacticalJoke, you have to think if you need a copy of the objects themselves Mar 25 16:16:02 TacticalJoke, because copying the list won't copy the objects Mar 25 16:16:14 TacticalJoke, otherwise yes, you'll have to do ArrayList or somethin :) Mar 25 16:16:23 canvs2321: That doesn't work. Mar 25 16:16:48 Mavrik: Right. Mar 25 16:16:55 Mavrik: I think I simply want a copy of the list. Mar 25 16:16:58 The list just contains strings. Mar 25 16:17:13 TacticalJoke, yeah, only copy of list will do Mar 25 16:17:17 K. Mar 25 16:17:21 just do new ArrayList(yourOldList) Mar 25 16:17:23 and it'll make a copy Mar 25 16:17:53 K. Thanks. Mar 25 16:18:05 It feels wrong to require the caller to make the copy. lol Mar 25 16:18:39 Like "ArrayList list = new ArrayList<>(objectInQuestion.getList());". Mar 25 16:18:50 It seems that the objectInQuestion class should be making the copy. Mar 25 16:18:53 yes Mar 25 16:18:54 Hello! Is there a way to get notifications of changes in SupplicantState of a WifiInfo? Mar 25 16:18:56 Then make it do that Mar 25 16:18:57 K. :) Mar 25 16:18:59 why don't you return a copy then? Mar 25 16:19:02 TacticalJoke, well that depends, but if you return a reference Mar 25 16:19:02 what's wrong with that... Mar 25 16:19:11 TacticalJoke, that means that external classes can tamper with your internal list :) Mar 25 16:19:14 pfn: Oh, nothing. Just thinking out loud. :D Mar 25 16:19:14 maybe not what you want :) Mar 25 16:19:15 or if you want your copy to be readonly, return Collections.unmodifiableList Mar 25 16:19:20 Mavrik: Yeah. Mar 25 16:19:57 it's a pity immutability isn't enforced at compile time... Mar 25 16:20:52 The only drawback I'm seeing is that my class has to use ArrayList<>, not List<>, now. Mar 25 16:20:55 But it's not a huge deal. Mar 25 16:21:01 huh? Mar 25 16:21:04 it can still use List<> Mar 25 16:21:20 Hmm. Does that make sense? Mar 25 16:21:44 Because then it'd be taking a List<> in some cases while returning an ArrayList<> in 'getList()'. Mar 25 16:21:44 TacticalJoke, yes Mar 25 16:21:53 TacticalJoke, List is just an interface Mar 25 16:21:59 ArrayList and other derive from it Mar 25 16:22:10 (or abstract class or whatever), there is no "List" implementation per se Mar 25 16:22:15 What if someone gives it an AbstractList and then I return an ArrayList? Mar 25 16:22:19 Wouldn't that be a problem? Mar 25 16:22:20 any "List" you'll see wil be an ArrayList, or LinkedList or something :) Mar 25 16:22:25 Yeah. Mar 25 16:22:58 learn inheritance more Mar 25 16:22:59 It seems weird to allow other Lists as input and then return an ArrayList. Mar 25 16:23:11 it takes list as input and returns List Mar 25 16:23:14 what are you talking about Mar 25 16:23:17 arraylist is a List Mar 25 16:23:21 learn inheritance more Mar 25 16:24:16 it's not like List is any concrete type Mar 25 16:33:19 I know that List is not a concrete type. Mar 25 16:34:07 I guess that, if the contract is "This takes Lists and returns Lists", users can't complain if they get an ArrayList rather than whatever list they gave it. Mar 25 16:34:55 pfn: I know inheritance very well, BTW. Mar 25 16:35:12 I'm new to Java, not OOP. Mar 25 16:35:48 pfn: "learn not jumping to conclusions more" Mar 25 16:41:24 StrategicGag Mar 25 16:44:01 TacticalJoke, why require sending an arraylist back though? Mar 25 16:45:23 I can find a million examples on how to hide the status bar, but can find a single one about how to show the status bar after I have hidden it Mar 25 16:46:55 TacticalJoke, yes, you're new to OOP Mar 25 16:47:10 if you read docs, you see arraylist extends list, done deal Mar 25 16:47:19 being new doesn't mean can't read docs Mar 25 16:47:27 My application is taking up a ton of ram. I don't know where to start debugging. Anyone have any suggestions or tutorials? Mar 25 16:47:46 if you know list is not a concrete type and arraylist is a list... then clearly you're just stupid ;-) Mar 25 16:48:31 eghdk_: You can use a memory profiler, and take a look at a memory dump Mar 25 16:49:04 eghdk_: https://developer.android.com/tools/debugging/debugging-memory.html Mar 25 16:49:40 eghdk_: http://android-developers.blogspot.com/2011/03/memory-analysis-for-android.html Mar 25 16:50:09 eghdk_: I prefer VisualVM to the standard Eclipse HMAT (Heap Memory Analysis Tool) Mar 25 16:50:44 eghdk_: Also look for Context leaks http://android-developers.blogspot.com/2009/01/avoiding-memory-leaks.html Mar 25 16:56:36 does bitmap filtering works when scaling down? Mar 25 16:56:56 *work ^ Mar 25 16:57:15 i see no difference when it's enabled or not Mar 25 16:59:29 Anyone have experience with their StaticLayout (or DynamicLayout) not centering properly when using spannable text? Mar 25 17:00:43 For some damn reason its showing up off centered Mar 25 17:02:50 http://pastie.org/8967854%20http://i.imgur.com/xvjpu15.png Mar 25 17:02:52 wow Mar 25 17:03:01 http://i.imgur.com/xvjpu15.png Mar 25 17:03:06 http://pastie.org/8967854 Mar 25 17:03:09 There ya go Mar 25 17:03:24 XXX should be centered within the red line Mar 25 17:03:31 s/within/about Mar 25 17:04:01 bitkiller: you could always debug and check out the bitmap size to see if it changed Mar 25 17:04:46 yiati, yes it changed, but quality is as if there were no filtering Mar 25 17:05:20 i did read somewhere that filtering algorithm is bi-cubic interpolation Mar 25 17:05:28 If it changed then it changed, and that answers your question. Mar 25 17:05:43 yiati, no. i'm talking about quality Mar 25 17:06:01 bitkiller: So am I Mar 25 17:06:15 bitkiller: If the size changed then the quality most definitely changed Mar 25 17:06:29 bitkiller: Human eyes are pretty easy to fool Mar 25 17:06:58 using a desktop software and scaling down the same image using bicubic algorithm, the result is better Mar 25 17:07:43 using no interpolation in the desktop, the result is the same as in Android Mar 25 17:08:02 ...in Android with filtering enabled or not Mar 25 17:09:49 I don't understand what you are stating/asking? Mar 25 17:10:16 Hello guys. I have a progressDialog. I want to have a custom rotating icon for the loading. I can set a drawable to this progressDialog, but i cant make it rotate. Or i cant find how to affect a rotateAnimation to the progressDialog. I also found how to create his own animation with multiple pictures and states, but i have only one picture and want it to rotate on itself Mar 25 17:12:05 pfn: You misunderstood my point. Mar 25 17:12:06 wtf is this !! Mar 25 17:12:12 Learn to read. Mar 25 17:12:36 I know that ArrayList, a class, extends List, an interface. Mar 25 17:12:37 Duh. Mar 25 17:12:45 That was clear from my messages. Mar 25 17:12:50 Is English not your first language? Mar 25 17:13:03 s/extends/implements/ Mar 25 17:13:05 TacticalJoke: dude don't be a tit Mar 25 17:13:16 explodes: Just giving back what I'm getting. Mar 25 17:13:30 I'm polite until someone is rude like that. Mar 25 17:13:36 fuck off m8 Mar 25 17:13:41 is it worth swapping out sqlitedatabasehelper with an ORM layer? Mar 25 17:13:48 Okay, ignored. Mar 25 17:13:57 chill guys and focus on my ez request :) Mar 25 17:15:27 macTAR: something like this: new RotateAnimation(0.0f, -90.0f, Animation.RELATIVE_TO_SELF, 0.5f, Mar 25 17:15:27 Animation.RELATIVE_TO_SELF, 0.5f); Mar 25 17:17:20 thx for answer explodes. yeah i got no prob with doing the animation, but i cant find how to affect it to my ProgressDialog. Seems progress dialog only handle drawable :( Mar 25 17:18:43 man, can't wait until i get to play with opengl es Mar 25 17:18:59 thats what im talking about : http://i.stack.imgur.com/fwUlD.png. Like this but with a custom picture instead of the normal circle Mar 25 17:22:43 macTAR: Oh. I think you need to set a custom view for the whole piece, the custom view should handle the animation of its icon Mar 25 17:23:42 ok thx ill try it in this way Mar 25 17:29:10 TacticalJoke, yeah, you're just plain stupid, ok Mar 25 17:32:16 I'm trying to install mat in eclipse but it doesn't accept by address: http://download.eclipse.org/mat/1.1/update-site/ Mar 25 17:32:47 just install MAT standalone Mar 25 17:33:51 Has anyone run proguard on an app that uses the Jackson parsing library? Mar 25 17:36:57 Hey might anyone know why when I include compile 'com.github.flavienlaurent.datetimepicker:library:VERSION' in my build.gradle in Android Studio its complaining that 'Could not find com.github.flavienlaurent.datetimepicker:library:VERSION' Mar 25 17:38:03 So it seems facebook has now added in the app permissions dialogue that friend's list is always accessable, and your app cannot get rid of these permissions Mar 25 17:38:48 my acceptance rate has dropped pretty significantly since they explicitly stated this in the permissions dialogue (it was always available just considered part of basic info) Mar 25 17:39:02 Trying to publish using maven-publish . "Could not find property 'java' on SoftwareComponentInternal set.". Someone maybe familiar with this? Mar 25 17:39:38 jonc-1: dont even look at that the FB app itself is granted... you'll cry. Mar 25 17:39:45 P21 Mar 25 17:40:11 rgr, I don't care really, but it hurts my app and website when people think I need the friend's list Mar 25 17:40:13 I definitely do not Mar 25 17:40:18 just a user's interests is all Mar 25 17:42:18 yeah I know. Its almost the lowest level of access now I think. I wrote some JS yonks ago for FB login and noticed that the base permissions started to get a little more greedy. Mar 25 17:42:36 still, you cant live without it as they say.. Mar 25 17:43:36 http://myflixfinder.com my site, the app will be launched here shortly, just need to add a bit of error handling Mar 25 17:43:59 and legitimately all I need is interests, and that is just to feed to a learning algorithm to make matches for users Mar 25 17:44:25 the database they are stored in is not accessible from the public network interface Mar 25 17:46:31 I've been thinking of doing an email login system and just showing popular videos with a rating system to learn what a user likes Mar 25 17:46:39 but that would require a bit more work Mar 25 17:52:41 pfn: Or you simply jump to conclusions before figuring out what's going on. Mar 25 18:01:44 no conclusions jumped to there Mar 25 18:01:52 you didn't know how inheritance worked, e.g. arraylist vs. list Mar 25 18:02:19 pfn: Wrong. Mar 25 18:02:26 I was asking about the concept. Mar 25 18:02:50 Is the *concept* of yielding an ArrayList a good one when the user might've given another kind of List to the object earlier. Mar 25 18:02:56 There is actually a debate about this on StackOverflow. Mar 25 18:03:00 People disagree, it seems. Mar 25 18:03:07 pfn: So learn to read. Mar 25 18:03:11 people are wrong Mar 25 18:03:13 what's your point Mar 25 18:03:19 Don't call people stupid when you just don't know what is being discussed. Mar 25 18:03:23 You just embarrass yourself. Mar 25 18:03:24 Thanks. Mar 25 18:03:31 sure, but you're generally stupid, so it's ok Mar 25 18:03:44 pfn: I bet I'd beat you in an IQ test. Mar 25 18:04:00 sure you would Mar 25 18:04:08 keep trying to make yourself feel better Mar 25 18:04:48 pfn: The key differences are these: (1) I can read. (2) I don't call people idiots unless I'm *certain* of what's going on, and even then I'm civilized enough not to, in most cases. Mar 25 18:05:11 you can't read Mar 25 18:05:16 #1 you already contradicted yourself Mar 25 18:05:20 docs count as reading, and you can't Mar 25 18:05:30 pfn: Wow. Mar 25 18:05:33 anyway, carry on Mar 25 18:05:34 You still don't understand what happened? Mar 25 18:05:40 Okay, you're just too dumb to interact with. Later. Mar 25 18:16:14 If I am developing an android application using Qt/QML, is there a way to make that application be a background application? Mar 25 18:30:00 I'm using a library that requires me to set the application name to something. Now I have another library that also requires the same thing. How would I solve that? Mar 25 18:33:37 Images, not the right place to ask Mar 25 18:33:48 JustSighDudes, set the application name.... Mar 25 18:36:57 mornings good people Mar 25 18:38:32 * platzhirsch slaps codetroll Mar 25 18:38:40 It's 7.38pm Mar 25 18:38:51 lol depends on where you are... Mar 25 18:38:59 Certainly not Hawaii Mar 25 18:39:00 and it is always morning in the channels Mar 25 18:39:19 and you are right it is 7:39pm here as well Mar 25 18:39:42 haha Mar 25 18:39:49 ;) Mar 25 18:40:06 Hi Mar 25 18:40:25 hi Mar 25 18:40:41 In Intellij, when I create a class (say HelloWorld) with a main() function, and run it by right clicking and selecting 'run HelloWorld.main()', it runs fine and terminates, but if I try to run it again it throws a ClassNotFoundException. Anyone else facing this 'run only once and then only throw an exception' behaviour? Mar 25 18:41:13 this is #android Mar 25 18:41:16 try ##java Mar 25 18:41:23 step through it. Mar 25 18:41:34 lots of people use intellij here and you get some good help here too. Mar 25 18:41:57 he really should ask in ##java Mar 25 18:42:07 and possibly try to understand the toolchain before using big IDEs Mar 25 18:42:19 sine this is android-dev and not android-java this about DEV and intellij is a dev tool. lighten up. Mar 25 18:42:41 the question is not about android dev though Mar 25 18:43:00 Theres always intelilj help here. And thank god too since the intellij channel is dead and ##java is a viper pit. Mar 25 18:43:07 ##c++ has this bot with this quote Mar 25 18:43:07 " I want to buy a Volvo but all the Volvo shops closed down, so I came into this Ford dealership instead. Why won't you sell me a Volvo? Mar 25 18:43:11 " Mar 25 18:43:34 Zharf: you spent more time compaining about off topic than actually contributing anything. Help the guy for you can. Does it hurt? Sheesh. Mar 25 18:43:59 Yeah this channel is so busy all the time how can we possibly expect to accomodate some-what off topic questions!?!? Mar 25 18:44:15 yes, it does, because I don't care about newbies trying to use tools they don't understand... they should use the tools those powertools are based on first so that they would even have a slightest chance of understanding the problem they have Mar 25 18:45:48 I've been programming for 6 years, I'm just trying out intelliJ Mar 25 18:45:52 Paradoxically you care but not care about the noobs and their noob problems ;p Mar 25 18:46:52 fexilal: did you try googlign? http://stackoverflow.com/questions/21588758/classnotfoundexception-on-simple-hello-world-in-intellij Mar 25 18:47:41 fexilal I have only been using Android Studio for a few weeks now. Am mainly an eclipse/rational developer so this is all new to me. But try and debug through it and see where it happens. I haven't encountered it my self.. Mar 25 18:49:49 lasserix: I saw that post, but the weird thing is it runs fine just once. Thereafter it compiles fine, but never runs Mar 25 18:51:17 guess I'll have to keep experimenting, thanks though Mar 25 18:52:19 ;) I guess it feels like my first endeavor into android development.. everything I thought would be easy is not, and difficult tasks are suddenly easy.. :) Mar 25 19:02:19 OK - this is a fairly broad question to ask - I have this planned for my initial activity : http://pastebin.com/JdZn0m4g Before I go off on the wrong trail... I would like to hear some advice on how to attack this best.. If anyone is willing to give it a shot of course. Mar 25 19:04:49 I have a ViewPager as a child of a GridView item. How do I retain the ability to use onItemClick with my GridView? It seems as though the ViewPager steals focus and as such, the GridView's onItemClick never fires. Mar 25 19:05:32 Ideally I want swipes to go to the ViewPager child and taps to go to the GridView onItemClick Mar 25 19:07:07 pfn: So I can have two "android:name" s? Mar 25 19:11:28 why would you have 2? Mar 25 19:11:40 biscarch really? huh i thought that would work. as long as the two containers don't use the same axis for scrolling Mar 25 19:12:19 rgr, yes, it hurts Mar 25 19:12:27 rgr, it invites further off topic crap that no one cares about Mar 25 19:12:41 g00s yea, the scrolling works fine in both directions. (ie: grid scrolls vertically, pager scrolls horizontally). Mar 25 19:13:15 g00s it would seem that the viewpager steals the tap along with the horizontal scroll though Mar 25 19:13:30 so the onItemClick for the grid never fires. Mar 25 19:13:37 a gridview of viewpagers? saywhat Mar 25 19:13:47 i have a listview in a viewpager and it works fine Mar 25 19:14:36 pfn yes. Was trying to achieve a gallery effect. Swipe for more photos, tap to get to the profile fragment Mar 25 19:14:52 so why would it be a grid of viewpagers, that makes no sense Mar 25 19:14:56 a list of viewpagers, ok Mar 25 19:15:10 so I can set columns=2 in landscape Mar 25 19:16:31 is that something I can do in a listview? Mar 25 19:17:41 not quite, no Mar 25 19:19:49 biscarch sorry, i must have misread what you were doing Mar 25 19:20:01 g00s nbd Mar 25 19:20:44 biscarch: can you set on click on the viewpager, pass in the host grid cell to its child pager, then pass the click event up? Mar 25 19:22:14 i am guessing pager handles scroll via ontouch consuming the vent barring itemclick from firing Mar 25 19:22:27 lasserix I'll try that, thanks Mar 25 19:29:56 pfn: intellij and its support tools are most certainly not off topic in #android-dev. The proof being how much help I have received from people here. Gradle and android deployment is off topic? No. Same way as intellij isnt. Cut noobs some slack. ##java is the place to be constantly bitching and laying down the law and banning people. Mar 25 19:37:02 ugh, fixed on of those 'didn't shut down the foreground service, still had wakelock' bugs :| Mar 25 19:46:35 How do you access colors.xml programatically? Mar 25 19:46:42 R.color.myColor? Mar 25 19:47:52 getResources().getColor(R.color.idname); Mar 25 19:47:57 rgr, off topic in #android-dev Mar 25 19:48:10 gradle-android and android deployment are not off topic, because they're android development Mar 25 19:48:12 intellij is not Mar 25 19:48:19 intellij has a support forum for general support issues Mar 25 19:48:21 go there Mar 25 19:48:57 g00s: Thanks. So getResources is a method of Activity? Mar 25 19:49:09 context i think Mar 25 19:49:49 Alright. Will look into it. Mar 25 20:00:29 android 4.3 : in onDraw(Canvas c)... when i do c.drawLine(x1,y1,x2,y2,p); when x1==x2 and y1==y2, the line is _not_ drawn? Mar 25 20:02:30 makes sense that you don't see it if the x never changes and the y never changes Mar 25 20:02:50 the start and the end is the same? Mar 25 20:03:22 i set the stroke width to 20 pixels... :-/ Mar 25 20:03:30 you have a distance of 0 Mar 25 20:03:34 and caps to ROUND Mar 25 20:04:35 it drew a disc before... dunno really what i changed... i thought it was 140,140,140+x,140+y before, when x and y where declare float... Mar 25 20:11:58 bonjour Mar 25 20:14:55 how do i disable multitouch on android? Mar 25 20:15:00 im having a hell of a time here Mar 25 20:15:48 disable it for the whole device Mar 25 20:15:50 ? Mar 25 20:15:59 android wear emulator is cool :) Mar 25 20:16:21 now i dont have to check my phone when a notification comes in Mar 25 20:17:33 i have to see what that api is capable of Mar 25 20:18:12 you just create notifications Mar 25 20:18:29 sounds boring Mar 25 20:18:50 lol Mar 25 20:21:06 nick9998: well for the whole app Mar 25 20:21:15 its alloweing the user to click two buttons at the same time Mar 25 20:21:20 which i dont want to allow Mar 25 20:21:27 my whole app only should use one touch at a time anyway Mar 25 20:23:59 i dont understand why turning off multitouch would be such a difficult issue... it like turning off auto orientation, you should be able to do it easily with a flag in the app manifest Mar 25 20:24:21 (althouhg for orientation you ahve to do one for each activity, which should be an option but there should be a single liner to do the whole entire app) Mar 25 20:24:22 ah Mar 25 20:25:02 why is that even a problem? Mar 25 20:25:53 well like i said, i dont want the user to press two buttons at the same time ( each button engages a chain of reactions and adds fragments to the screen, but once you chose one, you cannot go back or chose 2 at the same time) Mar 25 20:26:16 or if you ment the orientation complaint, well its just a matter of ease. Mar 25 20:26:24 Ahh, well, see it that way. You found a bug in your program then Mar 25 20:27:17 even if you turn off multitouch, what happens if the user presses those two buttons quickly after each other? Mar 25 20:27:53 as soon as one button is pressed, a hud appears until the actions are completed, after which the button is not present to be pressed. Mar 25 20:28:18 you are using a side effect Mar 25 20:29:13 im not sure what you mean Mar 25 20:29:20 but pressing a button makes a call on the server Mar 25 20:29:45 based on the response from the server we show the user a new list of options Mar 25 20:29:46 and I assume the call is asynchronous Mar 25 20:30:36 and during that call to the server, the user could press any other butten before the new list of options appears Mar 25 20:33:43 there are two ways, the UI should run in a single UI thread, so no new events happen simultaneously. The code that processes events can queue those button presses up or just throw away excessive events while a request to server is active Mar 25 20:34:13 so if multitouch on or off, the problem should be gone Mar 25 20:38:50 mlehmk: yes the call is async... Mar 25 20:39:05 it's as easy as setting a flag in your viewmodel Mar 25 20:40:07 JeremieDeNoob this code sounds brittle :( Mar 25 20:40:29 g00s: which code? mine or using a flag as a solution? Mar 25 20:40:33 god damn it, the leaf blower dudes are coming, i have that crap Mar 25 20:40:38 *hate Mar 25 20:41:07 mlehmk: and yes, this would work, but seems rather hacky instead of just disabling multitouch... Mar 25 20:41:28 JeremieDeNoob: I see disabling multitouch as hacky to cover a flaw in your event processing Mar 25 20:42:19 yeah, definitely Mar 25 20:42:20 the whole entire app always require only one button to be pressed at a time Mar 25 20:42:28 for instance Mar 25 20:42:32 if I have a music player Mar 25 20:42:45 JeremieDeNoob: Then make your event processing around to only allow a single state to be at a time Mar 25 20:42:45 why would i want to allow the user to press play and forward at the same time Mar 25 20:43:17 actually, pressing play and forward at the same time would allow to listen to the song while playing it faster Mar 25 20:43:39 used in a multitude of tape decks in the past Mar 25 20:44:31 Along with holding the pause and play buttons at the same time to slow the song down Mar 25 20:44:51 ok fine, what about forward and reverse at the same time Mar 25 20:44:59 and many tape decks needed a press of record and play simultaniously to record Mar 25 20:45:24 and you could even press record play and pause together to prepare the deck for recording Mar 25 20:45:24 if you have a listview, you only want one of the items to be selected, but if the user presses 2 at the same time it selects both Mar 25 20:45:55 yeah, multiselect Mar 25 20:46:03 if you dont want multiselect Mar 25 20:46:16 you raise a flag in the view? Mar 25 20:46:23 though if you turn multiselect off, then internally it would select one item, then the other so fast, you don't see it happening Mar 25 20:46:56 alternatively, the listview would only register the first touch of a multitouch event each time Mar 25 20:47:09 ok so if the selecting of this item was causing a call to a server. and you only wanted one call to get called and wait for the answer before calling a second one... raise a flag? thats the best solution? Mar 25 20:47:38 JeremieDeNoob: No, in this case you would have to queue the requests to the server or send them in parallel Mar 25 20:47:39 JeremieDeNoob uh, have the one button disable the other button Mar 25 20:47:52 when the response comes back, enable the button Mar 25 20:48:21 given that they were pressed at the same time, im pretty sure youd have the same behavior im dealing with now Mar 25 20:48:22 JeremieDeNoob what if your user mashes the same button 100 times ? Mar 25 20:48:26 maybe have a method in your viewmodel that disables all buttons and enabled all buttons, which is then a shell around your server call code Mar 25 20:48:35 i have a thing that pops up and blocks new user input until the call ends Mar 25 20:48:47 but its when the user selects 2 things simultaneously thats the problem... Mar 25 20:49:00 no, its not a problem Mar 25 20:49:05 the UI is not multithreaded Mar 25 20:49:05 yeah, but the thing popping up doesn't stop the other button press events from being processed Mar 25 20:49:15 the event loop processes things in an order Mar 25 20:49:46 yeah, but all the button presses are queued before the pop up opens, the event loop still processes those even when the pop up is open Mar 25 20:50:35 so in each activity which has to prevent this behavior (ie: all the activities in the app ) I have to manually program in a flag that stops new events from firing once one fires off... instead of simply putting a flag in the manifest that says "DONT ALLOW MULTITOUCH" Mar 25 20:50:37 ) Mar 25 20:50:42 so, you want to guard your server call to queue requests or just throw requests away when one is in progress Mar 25 20:50:50 i dont see how you guys cant see that this is not optimal Mar 25 20:51:00 you should be easily able to disable multitouch on any activity you want Mar 25 20:51:15 without programming a bunch of things into it... Mar 25 20:51:19 you can also make the enabled states observe your guard to disable buttons while a request is processing Mar 25 20:51:33 Still, you would only mask a bug in your logic, not solve the problem Mar 25 20:53:16 and writing a guard around your server call makes it easy to prevent multiple processings in parallel Mar 25 20:53:30 that way is DRY Mar 25 20:54:31 so two things Mar 25 20:54:40 i dont see it as a bug in the logic at all... if this is truly the only solution its just another point that apple can handle better than android... coding efficiently and making things work well and being stable with little code makes more sence that writing a bunch of code to guard things... for the same reason we dont have to write memory heap checkers before initing each var which would check if initing a new var would ov Mar 25 20:54:41 erload the app... Mar 25 20:54:45 Out of curiosity, what is the effect of the user pressing two things at once? Mar 25 20:54:49 it would make no sence to do something like this Mar 25 20:54:51 first, a well designed webservice will be idempotent Mar 25 20:55:27 second, the way the event loop works on android, if your button gets an onTouch EVENT , dispatched from the main looper, you can disable the other button and that will happen atomically Mar 25 20:55:28 each item is a selection, which opens up a new list of selections, when pressing two selections, it opens up both resulting lists of selections at the same time. Mar 25 20:56:14 Just a curious question, does MVVM map onto android userinterface? Mar 25 20:56:28 its not like the user can sneak in a touch, and the 2nd button disable gets queued after that Mar 25 20:57:02 JeremieDeNoob but, i'm sure you will find monkey runner of great interest :D Mar 25 20:57:04 and a second one, are there observables that can be bound to properties like the enabled state of a button? Mar 25 20:57:30 i think there is a library for mvvm on android, i haven't used it, don't know how well it works Mar 25 20:57:56 maybe i'm weird, i just do things the way that fits most naturally given the platform i'm using Mar 25 20:57:57 well, I'm just wondering if stuff like KnockoutJS can work with android's UI Mar 25 20:58:04 when in rome, do as the romans :) Mar 25 20:58:19 So they overpopulate the next level of lists? Or do they expand beyond each other? The most common effect I see in those scenarios is that selecting one will cancel out the others, so pressing two at once would result in the one returning last to display its content, with the possibility of some "flicker" of the data from the one that returns first. Mar 25 20:58:27 Thorbear: yes Mar 25 20:58:32 overpopulate Mar 25 20:58:46 well, I found out, that when I learn features of languages that I suddenly can use the same features in other languages that are known to lack those Mar 25 20:59:29 for example the Variant datatype known from visual basic. I managed to do that in a scripting language called LSL Mar 25 21:00:04 and I also managed to do things like callbacks and closures in that very simple language that doesn't even do those things Mar 25 21:00:48 and since I learned prototypes from Javascript I was just about to make prototype feature available in C# Mar 25 21:03:27 it's awesome what you can do when you have lists and functions like head, tail and concatenate Mar 25 21:07:59 im kind of having a problem with drawing here Mar 25 21:08:09 whenever i draw stuff on my canvas, the previously drawn stuff doesnt disappear Mar 25 21:08:13 its like its drawing on top of it or something Mar 25 21:09:57 JeremieDeNoob if you are interested, here is some from View.setEnabled() : if (!enabled) { cancelPendingInputEvents(); } Mar 25 21:10:14 reading through the code is always an enlightening experience :) Mar 25 21:11:41 nvm i got it Mar 25 21:11:58 for anyone else having this issue, you need to do canvas.drawColor(0, Mode.CLEAR) Mar 25 21:12:12 as described on http://stackoverflow.com/questions/6956838/how-to-erase-previous-drawing-on-canvas Mar 25 21:13:25 cancelPendingInputEvents(); also only masks the actual problem Mar 25 21:13:43 and I think Apple just makes it easier to mask problems than to prevent them Mar 25 21:16:12 JeremieDeNoob: Your problem has a simple solution then, clear the current level before populating the loaded data, and then the user can press as many items as he wants and make the app spend a load of time loading for no reason. Mar 25 21:18:37 Should APIs use CharSequences or Strings? Mar 25 21:19:13 I feel like it should be "Strings", because CharSequence doesn't define equality comparison, but then Android uses CharSequence a lot. Mar 25 21:20:05 String, unless you have a specific reason to need CharSequence. i.e. because you need to handle Android CharSequence objects that may contain spans. Mar 25 21:22:15 thank god for people like this: http://udinic.wordpress.com/2013/07/24/write-your-own-android-sync-adapter/ Mar 25 21:22:37 a string is a charsequence Mar 25 21:24:33 JesusFreke: Good point> Mar 25 21:24:34 .* Mar 25 21:24:39 I guess that's why Android uses CharSequences? Mar 25 21:25:07 Yeah, it's because of the Spannable Mar 25 21:25:19 g00s: The problem is that CharSequence doesn't refine 'equals'. Something like this has undefined behaviour: charSequence1.equals(charSequence2); Mar 25 21:25:29 JesusFreke: K. Thanks. Mar 25 21:25:57 TacticalJoke sure, but thats because its an interface. equals impl is up to concrete classes Mar 25 21:26:07 but yeah Mar 25 21:36:11 ok so im about to do my MOB pathing and am wondering if i should make mobs chase you through secret walk through walls Mar 25 21:36:28 because if a mob spawns on the other side of the wall it could clue the player in to there being a walkthrough there Mar 25 21:37:56 good thought Mar 25 21:38:15 it's also perfectly fine to have two classes of "walls" one for mobs and the other for players Mar 25 21:47:38 walls should just implement types of barriers Mar 25 21:49:04 hi all. Anyobdy working with IntelliJ Idea here? Mar 25 21:49:18 got a question about the debugging Mar 25 21:49:28 ask and you might be answered, no other way Mar 25 21:51:48 well. I got a for (int ii = 0; i < place.types.length; i++) loop, that fires 20 times. Inside I have some code and a if statement. If i place the linebreaker anywhere in the for loop, it will pause everytime, but if I set it anywaher in the if statement, it pauses 4 times, after which it nothing, even though it still is looping Mar 25 21:54:28 Hi, I've set up a soundpool with a couple short sound clips I want to play, but to actually play the sound I'll need to call "playsound(context, songID)". What is meant by context? Mar 25 21:57:10 actualy my walk thru wall is achieved by placing the wall in layer 2. visually looks the same but layer 1 is not blocked. in order to make the mob not walk thru the wall it would have to specifically look at layer 2 Mar 25 21:57:24 as im about to do the pathing... NOW is the time to think of these things heh Mar 25 21:58:11 i just fixed a non bug bug in my arm forths /mod where its result was not floored. found a way to floor the result yay Mar 25 21:58:32 yes. i have this arm forth running as a NDK library on my android phone and is where ill be computing the pet pathing :P Mar 25 21:59:30 Hi all. Trying to use wifi direct but after discoverPeers i never get the WIFI_P2P_PEERS_CHANGED_ACTION in my broadcast reciever...any thoughts? Mar 25 22:01:42 john carmack now works for facebook Mar 25 22:01:43 ! Mar 25 22:01:53 I440r:crazy Mar 25 22:02:06 FB just bought the company he is CTO of Mar 25 22:02:10 or so im told Mar 25 22:02:16 Occulus rift? Mar 25 22:02:22 i suggeted a game called doombook Mar 25 22:02:27 someone suggested facequake Mar 25 22:08:48 nm, i needed an actual peer to get the broadcast back Mar 25 22:10:25 can anyone tell me the name of https://www.youtube.com/watch?v=H6d0VcxJYL0 this song? Mar 25 22:10:30 its been bugging me for months lol Mar 25 22:11:06 any analytics users here? Mar 25 22:14:08 I440r mercy mercy mercy? Mar 25 22:14:40 cannonball adderley I think. Mar 25 22:17:11 my sqliteopenhelper impl is complaining in the onCreate method about a table not existing. my onCreate consists of 2 execSQL calls. one to create the tables and database and the next to populate one of the tables with data Mar 25 22:20:12 is this approach legit or should i attempt the inserts from elsewhere in the class and allow onCreate to finish to ensure the database has been successfully created? Mar 25 22:22:46 biscarch, erm let me search on that Mar 25 22:23:11 no not the same song Mar 25 22:25:59 i suck at programming Mar 25 22:26:10 there is only one way to fix that Mar 25 22:26:18 Hi all Mar 25 22:26:30 how could i extract boot.img from nexus 5 ? Mar 25 22:26:37 nick9998, that doesnt matter. you can still get a job doing it and make lots of money. 99% of the code i have to deal with is by people couldnt code their way out of a soggy wet paper bag Mar 25 22:26:37 dont leave me hanging bro Mar 25 22:26:54 I440r: yeah ,good point Mar 25 22:30:36 nick9998 if you'd like to learn more about programming, i recommend learning how to think algorithmically; lots of good books like http://www.amazon.com/Algorithms-Unlocked-Thomas-H-Cormen/dp/0262518805 Mar 25 22:30:37 ech0s7: do you really need to? Mar 25 22:30:54 yes JesusFreke Mar 25 22:30:58 ech0s7: you can get all the stock images from https://developers.google.com/android/nexus/images Mar 25 22:31:41 http://www.amazon.com/Power-Algorithms-Inspiration-Examples-Everyday/dp/3642396518 Mar 25 22:31:54 http://www.amazon.com/Algorithms-Unplugged-Berthold-V%C3%B6cking/dp/3642153275 Mar 25 22:32:05 http://www.amazon.com/Algorithmic-Adventures-Knowledge-Juraj-Hromkovic/dp/3540859853 Mar 25 22:32:13 and then of course there is htdp, sicp, etc Mar 25 22:32:38 there are a few books that use processing as their pedagogical tool Mar 25 22:34:23 thanks for the links Mar 25 22:34:44 pfn: Thanks - I wasn't sure. Not getting much traction in the qt channels either so far Mar 25 22:45:00 Hi, I've set up a soundpool with a couple short sound clips I want to play, but to actually play the sound I'll need to call "playsound(context, songID)". What is meant by context? Mar 25 22:46:14 RetroDude: an activity is a context. Mar 25 22:46:20 among other things. Mar 25 22:46:33 http://developer.android.com/reference/android/content/Context.html Mar 25 22:46:51 maybe i just have low self esteem Mar 25 22:47:11 Anyone know how to make my phone use data for internet while connected to wifi.? My WiFi doesn't have internet but I want to use adb over wifi Mar 25 22:49:45 Thanks JesusFreke, so what value would I supply for context to play a sound clip with ID Sound1? The program is only one activity Mar 25 22:50:22 RetroDude: you would supply the current activity instance. Mar 25 22:50:28 Question: The google map api allows me to display markers. Upon pressing those markers, it shows an info window (if specified). How would I get a listener onto that info window, so that I know when that is pressed? Mar 25 22:51:29 would that be like an int, like 1? Mar 25 22:53:30 is an int an instance of android.content.Context? Mar 25 22:59:26 guys, Mar 25 22:59:54 besides drawBitmap, and moving the coordinates along, is there another way to move a bitmap in android? Mar 25 23:00:11 or is that the accepted/only way? Mar 25 23:00:18 I am using a Surfaceview Mar 25 23:02:04 If I were to use the following code for creating sound effects, how would I call it? http://android.okhelp.cz/play-sound-android-example/ Mar 25 23:03:11 SoundManager.playsound(song #); doesn't work Mar 25 23:15:18 Yo all Mar 25 23:15:42 Having real trouble with TabHost and tabWidgets, the tabWidget on TabHost is always null even after calling .setup(); Mar 25 23:25:41 You really should be using Actionbar tabs. Mar 25 23:26:05 There's an official training with code by Google on the Android website. Mar 25 23:39:55 JakeWharton is this 'publishing' http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Library-Publication in any way related to this publishing http://www.gradle.org/docs/current/userguide/publishing_maven.html … it doesn't seem to, just confused Mar 25 23:40:29 no Mar 25 23:40:57 android one refers to what flavor/build type you expose as the default artifact Mar 25 23:41:36 ok, thanks Mar 26 00:53:05 If I were to use the following code for creating sound effects, how would I call it? http://android.okhelp.cz/play-sound-android-example/ Mar 26 00:53:23 SoundManager.playsound(song #); doesn't work Mar 26 01:00:44 is there any difference between like a RectF and a Rectangle2D.Float? Mar 26 01:21:40 guys, besides drawBitmap, and moving the coordinates along, is there another way to move a bitmap in android? Is drawBitmap the most CPU friendly way to animate things when using a SurfaceView? Mar 26 01:22:07 My Nexus 5 runs things without problems but I am worried about other devices Mar 26 01:23:15 samuel: you could set up a couple of virtual devices which'll represent those other devices you're worried about Mar 26 01:23:39 ThomQ: thanks, I had not thought about that! Mar 26 01:23:48 for example; i do testing on Virtual Devices which represent the Galaxy S1 through S4 Mar 26 01:24:02 ThomQ: is drawBitmap the best way to animate things? Mar 26 01:24:06 but, it's always good to have the actual devices them selves Mar 26 01:24:20 Or get a high-end gingerbread device Mar 26 01:24:22 I have no idea Sam, I haven't animated anything yet Mar 26 01:25:04 I do use threads, so all the other calculations are done in threads which dont affect the draw thread Mar 26 01:25:10 SpeedEvil: I'm talking about some older devices as well. I got a range of devices collected over the years. You'd be surprised how many people have old androids laying around Mar 26 01:25:42 yeah I have an old Galaxy Nexus somewhere Mar 26 01:25:58 I should dig it out to test it in a *real* device Mar 26 01:26:19 Gingerbread is getting less common than it was. It wasn't that long ago it was at 50% Mar 26 01:26:41 I think the galaxy nexus has the same hardware as a Galaxy S2 Mar 26 01:26:46 *I think* Mar 26 01:28:11 around and about. For comparisons i always just use Wikipedia (the right bar): http://en.wikipedia.org/wiki/Galaxy_Nexus, http://en.wikipedia.org/wiki/Samsung_Galaxy_S_II Mar 26 01:28:38 Hell- I even have a froyo device I use :) Mar 26 01:28:52 There are different S2's out there, some with the same CPU. The GPU is a bit better on the S2, but not much, same amount of memory Mar 26 01:29:09 Is anyone aware of a site that scrapes http://developer.android.com/about/dashboards/index.html?utm_source=ausdroid.net and generates graphs over time Mar 26 01:29:26 Sep 2013 they pulled the graphs over time Mar 26 01:30:03 wow yeah, they are almost identical! Mar 26 01:30:14 SpeedEvil: yes but unfortunately don't remember urls Mar 26 01:30:29 search for mobile os adoption Mar 26 01:30:41 i've seen at least 2 sites with historical graphs Mar 26 01:30:45 hmm Mar 26 01:31:40 hehe. I got a S1, Nexus 10, old and new Nexus 7, sony ericsson xperia arc s, and a couple of Iphone's i haven't touched in a year Mar 26 01:32:11 ow and my personal s4 of course Mar 26 01:32:46 you getting the S5? Mar 26 01:33:29 Next year. I just bought the S4 for a really decent price, so that's good enough for me Mar 26 01:33:58 fair enough Mar 26 01:34:05 I would like the S5 Mar 26 01:34:14 but they are so slow to bring phones to mexico Mar 26 01:34:37 I tend to buy the Nexus phones from eBay Mar 26 01:34:48 I started out developing in Unity, and you want to streamline your builds to run decently at last years line-up, or even 2 years ago. If you build just for the current gen you'll miss out on a lot of users Mar 26 01:35:13 Yeah i bought my nexus devices also from the bay. They don't / didn't sell them here in the Netherlands Mar 26 01:35:26 blame samsung :D Mar 26 01:36:00 I am aiming for minimum SDK of 11 Mar 26 01:36:23 because of deprecations it is as low as I can go Mar 26 01:36:32 thats why I am worried about old devices Mar 26 01:38:06 yeah, thats s1 territory, arc s as well I think Mar 26 01:38:08 Hey, could anyone help me hack gamepad input into a live wallpaper? Mar 26 01:58:29 bankai_ new rx, just some bugfixes Mar 26 02:01:13 more rx fun? i'm still catching up from the last update Mar 26 02:10:34 How can I create a JSON file based on a MySQL table that updates every while? I think I can either create a json file with php inside, which I'm not sure would work, or maybe I can make a php file to write to the json file? Mar 26 02:11:12 question; I want a info window to appear on top of the current view, maybe with the current view's lighting a bit darker. What do I have to google, what am i looking for? Mar 26 02:11:39 ThomQ: probably a dialog Mar 26 02:12:34 ThomQ: a quick google for 'android dialog/ dialog builder' will probably have you well on your way Mar 26 02:12:37 ThomQ maybe PopupWindow Mar 26 02:12:50 if you want to anchor it to a specific view Mar 26 02:13:13 warning: PopupWindow is api 1 and archaic :) Mar 26 02:13:43 ive googled both Mar 26 02:14:43 ThomQ: youve googled both as a result of our suggestions or youve googled them both prior to asking here and we haven't answered your question?? Mar 26 02:14:49 it seems that Dialog would be more to what I want, but any more ideas? Mar 26 02:15:01 no as a result :D Mar 26 02:15:23 ThomQ: not without getting silly with translucent views :P Mar 26 02:16:05 haha Ouch Mar 26 02:16:58 What if i'd wanted to slide a panel containing some text, a picture and a link from the top of the screen, Over the main view? Mar 26 02:17:06 The same widht, no translucency Mar 26 02:17:38 Could I even Slide the mainview down with it, making place for the panel that comes from the top, as it were? Mar 26 02:18:27 I know what functionality I want, I just didnt put any thoughs into design yet. Just seeing what's out there 'standard', if you know what i mean Mar 26 02:19:27 ThomQ: yeah you could use animations with a fragments to do that Mar 26 02:20:17 ThomQ: so your new view would then take up the whole screen (having 'pushed' the old view out the bottom?)? Mar 26 02:20:37 yeah, or maybe halfway or something Mar 26 02:20:58 I'm googling fragment layout options :) Mar 26 02:22:28 http://blog.lastpass.com/2014/03/logging-into-android-apps-just-got.html?m=1 Mar 26 02:22:47 Interesting, I wonder how they accomplish that Mar 26 02:22:48 yeah ill probably go that way, fragments. To use a dialog seems a bit to Easy as it were Mar 26 02:23:00 a proxy ime? Mar 26 02:24:21 is it possible to prevent listview to scroll to the top on adding more data to it ? Mar 26 02:24:37 ThomQ: yeah all good, dialogs fit a pretty basic use case. if you want to have full control over what its doing then i think fragments could be the way to go. :) Mar 26 02:25:16 gordon_, it doesn't... Mar 26 02:26:48 Howdy, still new to andriod dev- setup on my 2nd machine fine however on this one (my desktop win7, latest jdk) the andrio sdk manager refuses to run, i've read it may be my PATH env for java... anyone had similar issues/ know how to check if this is the issue? Mar 26 02:29:33 Eppiox: win7? Type in Path in the search bar, select Edit ENviroment variables, and then in the bottom window, the System Variable window, scroll down to path and see if your JDK's folder is among those Mar 26 02:30:40 i would think, opening cmd.exe and saying 'java -version' would tell Mar 26 02:30:58 if that doesn't work, yeah gotta edit env variables Mar 26 02:31:34 hmm version works, 1.8.0 but 'where java' shows a windows dir.. which is not where I installed it to Mar 26 02:31:45 hm, maybe all you need is JAVA_HOME. not sure if you need to have path = … stuff … + JAVA_HOME Mar 26 02:32:00 Another question, more specific to fragments: UI work should always be done in the UI thread, correct? So let's say i want a fragment to become visible / overlay on top of the main view. I got a onclicl listener firing off when to do so. I should there instantiate a new class, the Fragment Class as it were, where i do all the work for that fragment then, complete with it's Own layout file? Mar 26 02:32:41 g00s: you could, but then he wouldn't be in the same place to quickly add the path :) something tells me that he did not do that Mar 26 02:33:11 pfn: it does for me Mar 26 02:33:17 maybe there's something wrong with that Mar 26 02:33:21 yeah, i dunno wth with windows ;) Mar 26 02:33:52 Was kinda hoping I would not need to edit any path variables >_> last time I had to edit them was for using Heroku, I think I pulled most of my hair out for that one xD.. alas using windows seems difficult for this stuff Mar 26 02:34:26 gordon_, your adapter is busted, don't replace the adapter with setAdapter Mar 26 02:34:41 pfn: thanks, will look for that Mar 26 02:34:55 can clear() make the same effect ? Mar 26 02:36:17 ThomQ: fragments have a lifecycle similar to that of an activity. you will write the code to modify your views in the onCreateView method in your fragment class (which needs to extend fragment) Mar 26 02:36:23 Awesome- adding the path fixed it, thanks :D Only needed the JAVA_HOME one Mar 26 02:38:03 pfn: yes, adapter is quite weird Mar 26 02:38:11 ThomQ: that code will be called when the fragment is added via the fragment manager. so for example your listener will use a reference to the current context (likely your activity) and get a reference to a fragment manager. you can then use this to add your fragment/ replace the current fragment Mar 26 02:38:53 gordon_, if you clear, there's no data, so of course it'll scroll to the top Mar 26 02:39:18 Yeah, just reading through the lifecycle now. So I give it it's own class, and create it through the fragment manager in the UI thread, correct? Mar 26 02:40:21 ThomQ: http://pastebin.com/bYXGuRpD Mar 26 02:41:17 ThomQ: using sometihng similar to that snippet will ensure the ui code runs on the correct thread Mar 26 02:44:12 ahh k, setting the fragmentmanager options like that you mean right? Not the options specificly Mar 26 02:50:36 ThomQ: im confused, so im going to say yes :P Mar 26 02:53:34 Hi, I am writing an Android program, but I face a database design problem. I have four database tables: Groups, GroupUsers, Users, Photos. I want to implement a page which list all groups with its first fix group user avartar and last fix photos. What I can think of is to join all table but it will be huge when the number of groups and photos increase. Can anyone suggest a better way for me? Thanks Mar 26 02:56:38 what will be huge ? Mar 26 02:56:39 query ? Mar 26 02:57:00 gordon_: the result after join Mar 26 02:57:12 it wont change anyway Mar 26 02:57:20 if you want to list all of that Mar 26 02:57:39 gordon_: I am thinking should I seperate the query Mar 26 02:58:12 like first query all group, and query first group user for each group **** ENDING LOGGING AT Wed Mar 26 02:59:59 2014