**** BEGIN LOGGING AT Mon Mar 17 02:59:58 2014 Mar 17 03:00:09 bankai_: codeguru: i just need to know how to install one, i already have the xml files Mar 17 03:00:22 where do i drop them in linux? Mar 17 03:00:32 I don't know about that, sorry Mar 17 03:00:40 ask #eclipse Mar 17 03:00:42 codeguru: no worries, thanks Mar 17 03:00:48 bankai_: will do Mar 17 03:16:44 why is onSavedInstanceState not called when the back button is pressed? am i right in thinking that it is because the workflow is considered discarded and related data therefore irrelevant? Mar 17 03:18:09 http://developer.android.com/reference/android/app/Activity.html#onSaveInstanceState(android.os.Bundle) read the description Mar 17 03:36:00 hey guys what best way to cast a string to boolean in android? Mar 17 03:36:25 in java Mar 17 03:36:39 and you don't cast Mar 17 03:36:42 jareddlc: You can't cast a String to a boolean Mar 17 03:37:03 so then parse it? Mar 17 03:37:10 if you are storing the string "true", you probably need to rethink your design Mar 17 03:37:11 codeguru: Boolean.parseBoolean("true"); Mar 17 03:37:37 ublic boolean onPreferenceChange(Preference preference, Object newValue) { does not return a boolean Mar 17 03:37:45 it returns the string "true"/"false" Mar 17 03:38:02 hmm? Mar 17 03:38:27 why? Mar 17 03:38:31 why what? Mar 17 03:38:43 why are you trying to return a String when you should return a boolean Mar 17 03:38:43 why what where? Mar 17 03:38:50 that function Mar 17 03:39:06 when i craete that function it autofills the overide Mar 17 03:39:14 onPreferenceChange() **must** return a boolean Mar 17 03:39:19 which autofilled the returnvalues, there arent bools Mar 17 03:39:28 can you give a pastebin? Mar 17 03:39:39 one sec codeguru Mar 17 03:39:43 k Mar 17 03:39:43 let me change it to type boolean Mar 17 03:40:38 https://gist.github.com/jareddlc/9593586 Mar 17 03:40:42 doesnt like boolean Mar 17 03:41:20 what is the error? Mar 17 03:42:02 codeguru: no error Mar 17 03:42:11 i just wanted to pass boolean Mar 17 03:42:28 umm...are we talking about the same thing? Mar 17 03:42:34 :D Mar 17 03:42:39 im talking about not having a boolean Mar 17 03:42:49 object newValue is not of type boolean Mar 17 03:42:51 are you referring to the return value or the `Object` passed in? Mar 17 03:42:54 and i want it so i can do some logic on it Mar 17 03:43:02 not return value, Mar 17 03:43:05 that will always be true Mar 17 03:43:07 yes, newValue must be an Object Mar 17 03:43:17 you could pass in a Boolean Mar 17 03:43:25 it complained when i did Mar 17 03:43:37 so...what was the error? Mar 17 03:43:55 do you know the difference between boolean and Boolean? Mar 17 03:44:07 nope Mar 17 03:44:15 prim type Mar 17 03:44:19 oppose to static class? Mar 17 03:44:33 Boolean is a class, yes Mar 17 03:44:42 :D Mar 17 03:44:44 not static, though, since it's a top-level class Mar 17 03:45:15 so id need to instanciate it? Mar 17 03:45:31 I'm not familiar enough with SharedPreferences to know the details of what you are doing. Mar 17 03:45:39 Where does the preference get set? Mar 17 03:45:48 no idea Mar 17 03:45:51 im just learning Mar 17 03:45:56 what is BtEnable? Mar 17 03:45:59 i decided to use preference Mar 17 03:46:03 is that your own method? Mar 17 03:46:14 for my UI since its simple, BtEnable is my own method Mar 17 03:46:31 what is its signature? Mar 17 03:46:32 guys, is it faster, when reading, to read from storage an uncompressed bitmap or a WEBP bitmap? Mar 17 03:46:56 well i want to know the value of the switch, so i can turn on or off bluetooth Mar 17 03:47:05 which is why i need to go a logical check Mar 17 03:47:23 i mean i suppose to can to a string comparison Mar 17 03:47:36 is it faster to read a PNG, WEBP, or JPEG? Mar 17 03:47:59 I suggest that you figure out the type of the `Object` being sent to your `onPreferenceChange()` method. You can probably make this easier by casting to the concrete child class. Mar 17 03:48:17 :| Mar 17 03:48:26 what child class? Mar 17 03:48:47 whatever the concrete type of newValue is Mar 17 03:50:08 ugh Mar 17 03:50:16 i';ll just do string equality Mar 17 03:50:19 this is dumb Mar 17 03:50:26 thx codeguru Mar 17 03:50:45 no problem Mar 17 03:51:39 its kind of odd Mar 17 03:51:44 that it doesnt return a bool Mar 17 03:51:45 err Mar 17 03:51:52 get called in with a bool Mar 17 03:52:36 jareddlc: the boolean is to say whether the method was handled or not Mar 17 03:52:39 newValue might be a Boolean...not sure Mar 17 03:53:06 jareddlc: where does the key name "pref_connectivity_bluetooth" come from? Mar 17 03:53:10 codeguru: i need to do logic of that value Mar 17 03:53:16 my preference Mar 17 03:53:25 preferences.xml Mar 17 03:53:29 do you have an XML layout? Mar 17 03:53:35 oic...can you pastebin that? Mar 17 03:54:19 updated gist https://gist.github.com/jareddlc/9593586 Mar 17 03:54:49 or is there a proper way to retrieve the value of the preference? Mar 17 03:55:11 http://developer.android.com/reference/android/preference/SwitchPreference.html Mar 17 03:55:22 > This preference will store a boolean into the SharedPreferences. Mar 17 03:56:11 From that information from the docs, I think you can do `boolean btEnabled = (Boolean)newValue;` Mar 17 03:56:33 i'll try Mar 17 03:56:37 im super new to android Mar 17 03:56:45 :D so i dont know what sharedprefs are Mar 17 03:56:57 The Object *is* a boolean...it's just wrapped up in a Boolean and upcast to an Object. Mar 17 03:57:48 I've never used sharedprefs myself. Mar 17 03:58:21 thx codeguru that works Mar 17 03:58:31 no problem Mar 17 03:58:35 now i can do some logic Mar 17 03:58:36 XD Mar 17 03:58:45 also there is the wierd bug Mar 17 03:58:54 with SwitchPreference Mar 17 03:59:11 it calls onChangeLisntener, aswell as the onClickListener, very anoying Mar 17 03:59:31 you probably don't need both then Mar 17 04:19:16 anyone have experience with ListPreference Mar 17 04:46:52 where can i get all the defaults icons for actions such as refresh, contact, etc? Mar 17 04:47:07 android.jar Mar 17 04:47:09 http://android-ui-utils.googlecode.com/hg/asset-studio/dist/index.html?utm_source=twitterfeed&utm_medium=twitter Mar 17 04:47:45 choose the type of ion you want and a colours etc Mar 17 04:48:06 ah, thanks!! Mar 17 04:50:25 hello guys Mar 17 04:50:43 I dont know why but I am getting a crash on this every time: http://pastebin.com/YK7M17Xy Mar 17 04:51:08 well... writing the file works fine but reading it reads null Mar 17 04:51:26 is there something I am doing wrong here? Mar 17 04:52:42 here is the whole thing with the reading bit: http://pastebin.com/4ZxjMWzs Mar 17 04:52:47 any ideas please? Mar 17 05:04:03 hey guys, what type of type is the following : CharSequence[] entries = { "One", "Two", "Three" }; CharSequence[] entryValues = { "1", "2", "3" }; Mar 17 05:04:24 i want to be able to build a CharSequence while iterating over another list Mar 17 05:05:22 they're both arrays of charsequence, but the types inside are strings Mar 17 05:05:30 strings are charsequences so it's all ok Mar 17 05:06:33 how can I insert into the charsequence Mar 17 05:06:57 Im looping over an object and i want to add it to the charSequence Mar 17 05:07:30 do you mean insert into the array or the string? Mar 17 05:07:45 well listPreference uses a CharSequence Mar 17 05:07:51 and i want to dynamically add entries to it Mar 17 05:08:06 can you share some code? Mar 17 05:08:10 so my reasoning was to iterate over object and insert into the charSequence Mar 17 05:08:22 one sec alex_PP Mar 17 05:10:41 https://gist.github.com/jareddlc/9594284 alex_PP Mar 17 05:11:14 didnt know what to include Mar 17 05:12:47 does this help https://gist.github.com/alex-richards/2bc96b40e2b65b228d33 Mar 17 05:12:53 jareddlc the entries should be in your resources, so that it can be internationalized Mar 17 05:13:04 so you would use Mar 17 05:13:39 g00s: yes, but this list is paired Bt devices Mar 17 05:13:51 so i cant insert them into a resource Mar 17 05:14:01 jareddlc, https://gist.github.com/alex-richards/2bc96b40e2b65b228d33 see update Mar 17 05:14:04 alex_PP: let me try Mar 17 05:14:31 well that list comes from BluetoothAdapter.getBondedDevices O.o Mar 17 05:14:38 yep Mar 17 05:14:47 i need to prompt the user to select a device Mar 17 05:14:54 without doing the whole discovery stuff Mar 17 05:15:20 so if he has paired with it, it should be in the paired list and i need the user to select the device they want to connect to Mar 17 05:15:29 how would i do that g00s ? Mar 17 05:16:10 https://gist.github.com/alex-richards/2bc96b40e2b65b228d33 Mar 17 05:16:13 one last update Mar 17 05:16:19 ArrayList.addall( … the set ) Mar 17 05:16:25 you don't need to localise bluetooth devices Mar 17 05:16:33 listAdapter, or your own adapter Mar 17 05:16:35 the name is set by the device's owner Mar 17 05:18:14 Is it possible to backup my boot partition with fastboot? Mar 17 05:18:26 ParkerR wrong channel Mar 17 05:18:26 Looking at the help it seems like it just flashes Mar 17 05:18:34 ParkerR, #android-root Mar 17 05:18:36 Where would be better? Mar 17 05:18:41 Ok thanks Mar 17 05:19:50 g00s: but adapters are for listview Mar 17 05:19:58 listpreference needs a charsequence? Mar 17 05:20:08 o yeah :) Mar 17 05:20:08 im unsure im basing that on stackoverflow Mar 17 05:20:10 :) Mar 17 05:20:24 jareddlc, did you read my last update? Mar 17 05:20:30 that should do what you want Mar 17 05:20:39 doing it now Mar 17 05:20:41 alex_PP: Mar 17 05:21:43 is this a typing mistak: CharSequence> entries = new CharSequence[size]; Mar 17 05:21:44 kinda lame android doesn't have an intent to show system-ui for picking a device Mar 17 05:21:59 g00s: agreed Mar 17 05:22:04 eugh, dies it not? Mar 17 05:22:06 *does Mar 17 05:22:14 well, its a hidden api Mar 17 05:22:35 hidden u say? Mar 17 05:22:45 yeah :) Mar 17 05:22:59 i dont use it Mar 17 05:24:07 its all buried in the Settings app Mar 17 05:24:09 alex_PP: cant convert Mar 17 05:24:32 the new update was incomplete didnt know what type u assigned: Type mismatch: cannot convert from CharSequence[] to List Mar 17 05:26:25 im just going to use u didnt set them to CharSequence[] Mar 17 05:39:26 sorry jareddlc , popped out Mar 17 05:40:00 np Mar 17 05:40:09 devices doesnt have method get Mar 17 05:40:14 so im doing imlpementation 3? Mar 17 05:40:18 using lists Mar 17 05:41:04 what's the type of pairedDevices? Mar 17 05:41:26 pairedDevices = mBluetoothAdapter.getBondedDevices(); Mar 17 05:43:36 ok, very last update Mar 17 05:43:36 https://gist.github.com/alex-richards/2bc96b40e2b65b228d33 Mar 17 05:45:24 alex_PP: Mar 17 05:45:38 i think i got it but now im getting FC when i call setEntries Mar 17 05:47:08 got it Mar 17 05:47:14 thx alex_PP now to fix these issues Mar 17 05:47:27 u can only grab, paired devices, if bt is enabled Mar 17 05:47:28 which is odd Mar 17 05:52:22 the entries are cached. if the service isn't running, the cache goes away :) Mar 17 06:14:45 hey guys Mar 17 06:14:51 whats best way to wait for 2 secs Mar 17 06:14:51 hi, how can i detect if tablet or minipc have an hardware keyboard? Mar 17 06:14:53 before returning? Mar 17 06:15:06 i want to make sure bluetooth finally initialized correctly Mar 17 06:19:55 jareddlc, i am not very sure but you can use a callback like resultreceiver. Mar 17 06:20:08 i'll look into it Mar 17 06:20:10 jareddlc, is it 2 secs exactly ? Mar 17 06:20:16 no i dont know how long Mar 17 06:20:22 but im getting odd behavior Mar 17 06:20:31 i;ll ask g00s later Mar 17 06:20:38 jareddlc, how do you know that the bluetooth has been initiated ? Mar 17 06:20:47 do you get any event ? Mar 17 06:20:51 nope Mar 17 06:20:55 i extend a metho Mar 17 06:20:57 to start it Mar 17 06:21:01 ok Mar 17 06:21:19 but then there is no callback or any event from the hardware . correct ? Mar 17 06:22:36 i dont think so Mar 17 06:22:41 hey sunny_slls thx for the help Mar 17 06:22:43 but im calling it a night Mar 17 06:22:49 going to commit and push Mar 17 06:22:51 and work tommorrow Mar 17 06:23:01 jareddlc, cool. good night buddy :) Mar 17 06:37:13 alex_PP have you done any bluetooth? Mar 17 06:40:19 holy crap, i gotta hand it to the chrome devs, they are pushing out an update on sun night.probably because Pwn2Own 2014 :) Mar 17 06:55:16 Hi eveyone ! Mar 17 06:58:55 hi, I've got a basic question. For a fragment... is it always true that onCreateView is always called everytime the fragment appears? reason why i'm asking is I'm tracking something inside onCreateView as well as a button click within that view in an anonymous inner class setOnClickListener. However, I'm getting some weird results because within the same period, I'm getting more clicks than view created. I'm already decoupling to unique v Mar 17 06:58:55 iew and i'm pretty sure the analytics are unique. Any ideas why this might happen? thanks Mar 17 07:01:56 how do you become the best programmer in the world, and how do you avoid not getting anywhere (such as by becoming an expert in qbasic and implementing a lot of stuff in it)? Mar 17 07:02:33 treehouse, keep practising :) Mar 17 07:02:39 Quick Question : I am using the native library [OpenCV] in my android project. I am running simple example and I am getting exception 03-17 06:50:45.728: A/libc(1453): Fatal signal 11 (SIGSEGV) at 0x00000170 (code=1), thread 1453 (mple.opencvdemo) Mar 17 07:03:00 This Fatal signal 11 always problem for me Mar 17 07:03:35 I could not find the reason for this. Any help ? Mar 17 07:03:36 I'd suggest running under native mode debugger Mar 17 07:04:14 segfault \o/ Mar 17 07:04:31 I don't have native code, only have so files, Is it possible to debug that Mar 17 07:04:53 Zharf : hmm how and I don't know much about this Mar 17 07:05:03 ... oh boy, I see you need education from scratch -_- Mar 17 07:05:11 TGMCians: .so files *are* native code Mar 17 07:05:32 hmm but these are native binary files Mar 17 07:05:52 I'm just so afraid that I'm wasting my time.. that the stuff that I'm learning will be useless and that I could have focused on the right things instead Mar 17 07:05:57 I don't think you can read the code of them Mar 17 07:06:54 treehouse: the stuff important in 10 years hasn't been invented yet so if you're thinking of it that was you're wasting your time on anything Mar 17 07:08:10 TGMCians: ... I think you need serious education in C and C debugging before you go further with OpenCV. Mar 17 07:08:13 Sorry Mar 17 07:08:38 what if I force myself to learn something (I think it's boring or not worth it.. but I have to do it)? College is one reason you'd have to do that. Mar 17 07:09:02 p_l hmm, I am trying that so first,. doing first time NDK stuff Mar 17 07:09:24 TGMCians: not NDK. Go out and grab an education on plain old C and assembly and such Mar 17 07:09:43 when you can handle a remote GDB session, come to this problem Mar 17 07:09:57 let me try that Mar 17 07:18:55 frankly I think you should ask the opencv android guys Mar 17 07:19:24 hmm thnx Mar 17 07:32:41 hi :) Mar 17 07:32:46 Does anyone can help me ? Mar 17 07:32:58 I want to customize my ActionBar Tab-Textcolor Mar 17 07:33:05 but i don't know how to do it :( Mar 17 07:33:12 it doesn't work :/ Mar 17 07:39:58 Hello, is anyone here? Mar 17 07:40:11 I have a question. Our server sends a signal to google, then it sends back a series of JSON parameters but missing one part which is called developer payload. How can I fix it? Mar 17 07:41:10 use a packet sniffer to see what is actually being sent.. use command line curl etc to test if you're sending correctly Mar 17 07:41:50 if its a google api's issue, ask in google, i'd think... if you narrow it down to specific android api, let us know Mar 17 07:42:31 Can I paste the response from google here? Hope you can help me out Mar 17 07:43:58 qwebirc28842: are u using the purchase HTTP API [http://developer.android.com/google/play/billing/gp-purchase-status-api.html] ? Mar 17 07:44:04 I have tracked what has been sent out Mar 17 07:44:47 We are using IAB V3 interface Mar 17 07:45:22 you need to provide the developer payload yourself Mar 17 07:46:29 V3 API is between ur app and the Google Play Service Client which can be returning cached responses or querying directly from the Google Servers. You never really know Mar 17 07:47:04 Google provides a HTTP purchase API that you can call from your production servers to check the status of the in app items. Mar 17 07:47:49 We can finish the whole set of payment when we test for the first time. However, we retest it after a few days without any change, but the developer payload in the parameters is missing Mar 17 07:48:38 hello guys, I have this issue Activity A -> signleInstance -> launching Acitivity B -> standart -> I want to start Activity C and clear A and B from the stack, so far I've tried those -> https://gist.github.com/tagrudev/9595419 but nothing seems to get rid of activity A Mar 17 07:48:40 any ideas ? Mar 17 07:50:54 oh man, bit hard by another android bug Mar 17 07:51:11 :/ Mar 17 07:51:13 i'm either constantly unlucky, or this platform has more bugs than an anthill Mar 17 07:51:14 good morning brethren Mar 17 07:51:20 hey lemonxah Mar 17 07:51:27 @MohitKanwal yeah maybe my statement is a little bit ambiguous. Our client side is using the IAB v3 and our server side is follow the guide of (https://developers.google.com/android-publisher/v1_1/inapppurchases#resource) Mar 17 07:51:36 lemonxah hey, maybe you know, have you ever used LocalServerSocket ? Mar 17 07:51:40 quick question is there a way to know if an intent was handled successfully? Mar 17 07:51:53 no i haven't yet g00s sorry Mar 17 07:52:54 lemonxah is the intent into your app ? Mar 17 07:53:13 probably not, thats easy :) Mar 17 07:53:13 both .. but the one i am looking at is if i share out of my app Mar 17 07:53:22 yeah .. no. Mar 17 07:53:35 i want to know whether or not the accepting app has canceled it or handled it Mar 17 07:53:40 it depends, if you startActivityForResult, maybe you get something bavk Mar 17 07:53:49 yeah, i had that same problem Mar 17 07:53:57 it alwyas returns canceled :/ Mar 17 07:54:00 i wanted to know if gmail actually sent it Mar 17 07:54:08 same here Mar 17 07:54:16 or, if the user actually sent, or backed out Mar 17 07:54:35 sorry i got a browser crash here Mar 17 07:55:12 that is exactly what i want g00s :/ Mar 17 07:55:22 found this Mar 17 07:55:22 http://android-developers.blogspot.com/2012/02/share-with-intents.html Mar 17 07:55:28 does anyone say something just now? About the developerpayload missing issue Mar 17 07:55:35 but its like the apps doesn't handle the result codes Mar 17 07:56:08 GCSDK_serverside: havent encountered such case before. Any ways you should cache the query results on your server side Mar 17 07:56:35 only query once i suppose Mar 17 07:57:31 yeah I already cached them Mar 17 07:57:40 and resend the query request Mar 17 07:58:07 but still missing the developerPayload Mar 17 07:59:30 would it help if I post the whole content of the query request and the response? Mar 17 08:01:17 dont think i believe the developer payload is missing coz of a genuine reason Mar 17 08:03:12 I've solved it :) Mar 17 08:03:50 g00s, what are you doing LocalServerSocket Mar 17 08:04:13 diagnostics Mar 17 08:04:39 I just mentioned that we can test the whole procedure successfully for the first time, but it is shown that the developerpayload is missing when we retest it Mar 17 08:04:42 ran into this https://code.google.com/p/android/issues/detail?id=29939 Mar 17 08:04:59 it pisses me off to no end when there isn't any closure Mar 17 08:05:31 regarding bson. How to create class which can handle these two version http://pastie.org/8937256 ? Mar 17 08:05:56 g00s: feel your pain. Will star it for you :) Mar 17 08:06:04 pduin :D thanks Mar 17 08:06:34 Have run into a couple of those unresolved issues before myself Mar 17 08:06:35 one more star but that's an old issue Mar 17 08:06:46 2012 hmm Mar 17 08:06:59 Doesn't mean it's not valid Mar 17 08:08:10 https://github.com/android/platform_frameworks_base/blob/master/core/java/android/net/LocalServerSocket.java#L83-L89 Mar 17 08:08:10 That first 'hope giving' comment... Mar 17 08:08:28 I think that should be the behavior Mar 17 08:08:53 at least the docs say so Mar 17 08:09:22 GCSDK_serverside: https://code.google.com/p/android/issues/detail?id=67048 Mar 17 08:09:48 sorry, it was regarding gson not bson. How to create class which can handle these two version http://pastie.org/8937256 ? Mar 17 08:10:32 tagrudev pduin the solution is gross; you need to have another thread mark the .accept() thread is interrupted, and then make a bogus connect request to un-jam accept(); after accept falls through, you check thread.isInterrupted() Mar 17 08:10:39 ugh i'm going to barf in m mouth Mar 17 08:12:14 kamol, check if the result is an array or an object ? Mar 17 08:13:11 tagrudev: how to reach that stage where I can check it is array or object? Mar 17 08:14:41 at least create null object, if it doesn't exist Mar 17 08:16:06 MohitKanwal: Thank you. I have checked the link. But there's nothing helpful. I have tried to contact with Robin who asked for the same problem. Mar 17 08:16:46 kamol, well you should check the library documentation usually you would create a new Gson().fromJSON("string") Mar 17 08:18:07 :tagrudev ListResult listResult = gson.fromJson(jsonObject.toString(), ListResult.class); this line. I checked the doc but cannot find anything to related to this Mar 17 08:19:20 what is ListResult ? Mar 17 08:28:17 Excuse me, I found a link about the same problem I came across. Is there anyone else ever came across the same problem as the link describes? http://stackoverflow.com/questions/8363643/other-requirements-for-developer-payload-in-android-in-app-billing Mar 17 08:33:32 :tagrudev http://pastie.org/8937298 Mar 17 08:34:04 Hi, there is a way to get active fragment objects ? I need to call a public function of them when user press a menu Mar 17 08:39:16 I was told if I have the okHttpClient and retrofi lib that it will cache autmatically is this true? or do I need to still add the cache to the restadapter? Mar 17 08:39:23 retrofit* Mar 17 08:45:26 did anyone tried this fix yet? http://stackoverflow.com/questions/20636330/start-sticky-does-not-work-on-android-kitkat-edit-and-jelly-bean Mar 17 08:48:26 shineworld: from the activity? yes Mar 17 08:48:37 misterli wow, i didn't know about that ! Mar 17 08:48:39 yes Mar 17 08:48:57 holy shit, thats been like basic behavior since …. forever ? Mar 17 08:49:07 I've and activity which show ONLY one fragment at time but I need to update some field when user change a global setting Mar 17 08:49:13 g00s_, what? :> Mar 17 08:49:21 START_STICKY ? Mar 17 08:49:23 it's since kitkat Mar 17 08:49:35 kitkat ignore START_STICKY in some cases (most) Mar 17 08:50:10 shineworld: just do a findFragmentById Mar 17 08:50:37 looking .... Mar 17 08:51:14 ah ok I need to call it for each fragment which could be running Mar 17 08:51:24 g00s_, so.. have you tried it yet? :) Mar 17 08:51:38 no, i don't use start_sticky Mar 17 08:51:45 thanks bankai_ I'm not used with fragments... Mar 17 08:51:47 ive tried using the fix but onDestroy dont get called even when the service is killed (due lowmemory) Mar 17 08:53:51 onDestroy() behavior is normal Mar 17 08:54:41 Yes? So how can i make sure that i trigger smth before the service is killed in a low-memory-case? Mar 17 08:54:51 for example writing to the sharedpreferences Mar 17 08:54:58 you can't Mar 17 08:55:27 good Mar 17 08:55:36 great design :) Mar 17 08:56:29 Hello. Anyone have a recomendation on best way to serialize a URI with minimal toString action? Mar 17 08:58:02 misterli for low memory, you could try to grab Application.onLowMemory / onTrimMemory() Mar 17 08:58:13 but your process could be killed, just because :) Mar 17 08:59:56 but Service has onLowMemory too, so i'm sure you saw that Mar 17 09:02:38 Hi guys. Does anyone know how I can have an application name which is different from the first activity launched? Mar 17 09:02:38 I tried programmatically with getSupportActionBar().setTitle(MY.R.STRING.RESOURCE);, but I got (rapidly) a non responding application message from android. Any idea how to circumvent that problem? Mar 17 09:20:20 how do you programmatically add more than one fragment to a view (ie LinearLayout)?? I've tried using the FragmentTransaction.add(container, fragment, tag) method and it works however only one fragment is visible (the initial one). Mar 17 09:20:21 getString(R.string.blah) Mar 17 09:21:01 woops, ignore that *giggles* Mar 17 09:22:19 teasp00n: add another container Mar 17 09:25:54 Hello, is there a way using the android sdk library to automatically create a vpn network on the user's phone? Mar 17 09:27:02 g00s_, i dont get it. How do they mean it to use the patch=? Mar 17 09:29:03 p_l : my problem solved \o/ Mar 17 09:29:24 http://pastebin.com/02i4QBXs here is what ive tried vbut it doesnt work. Onec its killed it keeps killed Mar 17 10:02:06 what should I be using for fragment placeholders in my layouts? currently im chopping and changing between FrameLayouts and fragments Mar 17 10:04:21 Hi all, does somebody know a good lib with a swipe listview? (swipe to remove item) Mar 17 10:15:02 Still no one for my question asked above? ^ Mar 17 10:17:22 genuses: why is theDrawable null on line 8, even tho url on line 9 does point to an image, verified by browser check? http://hastebin.com/viqoyaqahu.coffee Mar 17 10:17:36 I have String FFFF6666 how to represent it in hex 0xFFFF6666 ? Mar 17 10:17:49 *geniuses Mar 17 10:17:59 wget: what's your stack trace say Mar 17 10:18:51 bankai_: Hum. One moment, then I'm undoing the modifications I made, and recompile the app. Mar 17 10:21:56 bankai_: According to the logcat in verbose mode, I've no error and the app is running fine (and it actually is). But I've a non response dialog which appears rapidly and then fade out. Mar 17 10:22:24 I've no stack trace generated. Mar 17 10:29:06 hi, I have an activity that starts a service using startService(), I then background and kill the activity using the task switcher. I see from settings-apps-running that the service is still running, I start the activity again, and I notice the service's oncreate() is getting called Mar 17 10:30:04 if the service is already running, why would oncreate() be called again, if the activity calls startService() on it again? Mar 17 10:30:41 maybe it got destroyed Mar 17 10:31:12 I put in logging for its onDestroy(), and see that it is not being destroyed Mar 17 10:32:07 bankai_: Mmh. I saw this line in the log 03-17 11:22:42.957 7107-7107/be.wget.droidcontact.app I/Choreographer﹕ Skipped 77 frames! The application may be doing too much work on its main thread. Mar 17 10:32:08 Maybe I should do another thread? Mar 17 10:32:49 testing on a nexus4, a lot of free memory, and always reproducible for me Mar 17 10:39:32 Hello, is the Log.e etc output only visible on the development pc with its emulator or can I view it on an actual device when testing ? Mar 17 10:40:29 I use logcat from eclipse on a nexus 4, so yes it works on a real device Mar 17 10:42:14 So i must install logcat in my device ? Mar 17 10:43:07 no logcat is part of the eclipse setup Mar 17 10:43:19 you enable usb debugging on device Mar 17 10:43:49 Oh. Does the Android system of the phone not do logs ? Mar 17 10:43:57 like in /etc/log or something ? Mar 17 10:44:14 Unknown0BC: there are onboard logcat apps around, but they were restricted a few releases ago so they can't get the full log without root/system perms now, AFAIK Mar 17 10:44:47 is there any way to run code when a fragment transaction gets popped Mar 17 10:45:54 Leeds to restricted to tell me which method in which Activity "crashed" ? Mar 17 10:45:59 * Unknown0BC blinks Mar 17 10:46:11 And why... Mar 17 10:46:14 :) Mar 17 10:46:16 restricted to reading only the log from the log-reading app, I think Mar 17 10:48:17 I'm starting my service as per this: http://developer.android.com/guide/components/services.html#StartingAService, and it says oncreate should get called if the service is not already running, in my case it is always getting called Mar 17 10:50:59 magellanic, Are you sure the service is running ? I would check on a real device in the task manager which programs are actually running. Mar 17 10:51:39 yep, I use settings-apps-running to check that the service is running ,even after I kill the activity from the task manager Mar 17 10:51:54 mhmm.. why does accessing /dev/graphics/fb0 even with su before returning permission denied?= Mar 17 10:51:56 also nothing from the service's logging in onDestroy() is printed Mar 17 10:52:19 did you use the @Overrides? Mar 17 10:52:31 If you want to make sure services are only used onec use a handleintentservice Mar 17 10:52:58 yes, used @Override Mar 17 10:53:00 magellanic, is your service actually performing its task ? And yet onCreate is called when you navigate to it ? Mar 17 10:53:07 hmm, let me google a handleintentservice Mar 17 10:53:19 You may also check if the service is already running before starting it again. Are you using intents? Flags? Mar 17 10:53:31 not using intent flags no Mar 17 10:53:56 Unknown0BC: it starts a thread and should be idling for now while I'm testing Mar 17 10:54:33 how do i goto app X2 install page from inside an app X1? Mar 17 10:54:39 I'm checking out intent flags, thanks misterli Mar 17 10:54:41 just send to http://market.android.com/details?id=packageName? Mar 17 10:54:54 or? Mar 17 10:57:18 got it: http://developer.android.com/distribute/googleplay/promote/linking.html Mar 17 11:08:47 misterli: no intent flags look relevant? I am using intents yes, I'm using this to start the service: http://developer.android.com/guide/components/services.html#StartingAService Mar 17 11:09:09 I could pastebin some relevant chunks? Mar 17 11:11:06 http://pastie.org/8937542 Mar 17 11:12:41 while testing, I'm not binding to the service, just starting it with startService, I expect it to run in the back even if the activity is destroyed, when the activity is recreated, I want to bind to it and operate with it. Mar 17 11:13:26 issue I have is that oncreate() is called, not sure why, and my service "state" is lost from a previous creation of it Mar 17 11:16:34 brb, lunch ;) Mar 17 11:33:12 :/ Mar 17 11:33:24 anyone understand why this Drawable from Bitmap doesn't show up when added as View to Layout, if content is ok? http://hastebin.com/qiwuhiwoju.avrasm Mar 17 11:33:34 is there a way to know when something is popped from the backstack? Mar 17 11:38:33 Hey folks, I'm trying to load some data for my UI in an AsyncTask. When I load the Activity without executing the task it loads instantly. If I execute the AsyncTask it waits until the AsyncTask completes before showing the Activity. What am I missing here? Mar 17 11:58:05 So air.byss.mobi.instaweatherpro is pushing me messages. I haven't installed InstaWeather, so I'm assuming it goes via some other package. No packages with that name is installed. Any idea how to find it? Can't long press message since it's gone, and long pressing that notification in Notification History does nothing. Any idea? Mar 17 11:58:27 what's wrong with my layout xml? why isn't the button, text, showing up? https://www.dropbox.com/s/v65n3u7hakyzon8/Screenshot%202014-03-17%2013.52.54.png Mar 17 11:59:01 Actually, the icon in notification history matches another app which I did not expect bundled this kind of shite... Mar 17 12:05:20 kjeldahl i only have one app … mine :D Mar 17 12:05:30 oh and kindle :) Mar 17 12:06:04 its worked out pretty well so far Mar 17 12:06:29 well isn't this just great... in case of super crappy connection, httpurlconnection isn't throwing ioexceptions or anything, it just hangs in getResponseCode Mar 17 12:06:44 until android gets its shit together with its permission system, i'll pass Mar 17 12:06:50 on everything pretty much Mar 17 12:07:42 Zharf really, no timeout ? Mar 17 12:07:46 yep Mar 17 12:07:52 I let it sit there for 5 minutes Mar 17 12:07:58 android permission system is pretty much better than every other released and funcitonal alternative Mar 17 12:09:14 g00s_, I used wifi to connect to my other phone where I turned off networking to simulate bad network Mar 17 12:12:15 Zharf also the read timeout ? Mar 17 12:13:11 I'm doing POST actually Mar 17 12:13:46 try it :) Mar 17 12:13:48 after writing my whatever I tried reading response code where it hangs.. Mar 17 12:17:09 Kind of scary that it seems apps are allowed to push ad messages via GCM with misleading package names and invalid icons (it shows whatever icons was active last, not it's own). Looks like it has been designed to confuse. Mar 17 12:17:32 Now that same ad shows the Google Music icon. Mar 17 12:17:42 (in the Notification History list) Mar 17 12:18:08 i thought adds in notifications was against tos Mar 17 12:18:22 or is that wishful thinking Mar 17 12:18:52 ok setting the timeout manually helped... why isn't there a sane default -.- Mar 17 12:19:22 If it is not already, it should be. It also explains why kids tablets ALWAYS have a LOONG list of notifications. I thought it was only from installed apps, but probably isn't anyway. Mar 17 12:23:07 hello Mar 17 12:25:44 anybody here? Mar 17 12:27:19 hi all. i'm having problems adding some textviews to a linearlayout dynamically. the code runs but i don't see the widgets. see http://pastebin.com/HcLG0d0k for the java code, http://pastebin.com/Zw6t5bTY for the xml including list_container_id, and http://pastebin.com/VBFMpTjz for settings_row.xml. can someone tell me why my widgets don't appear? i suspect i'm doing things in the wrong order or messing up heights or widths... : Mar 17 12:29:34 .j eclipse Mar 17 12:30:03 helpppp Mar 17 12:30:45 g00s_: Looks like you're right: http://phandroid.com/2013/09/30/google-play-notification-ads-policy/ Mar 17 12:31:53 Ads for third parties in push notifications ARE NOT ok. Mar 17 12:33:44 sigh Mar 17 12:33:47 .c Mar 17 12:33:50 -_- Mar 17 12:34:06 I hate how they got rid of mass storage mode Mar 17 12:35:05 when in mtp mode adb doesn't work... and it doesn't even appear in my explorer... in ptp adb works and it shows the camera files but I can't access the other files -.- Mar 17 12:35:49 español? Mar 17 12:35:53 no Mar 17 12:35:56 The network which is currently abusing this policy seems to be App lovin', bundled with Rope Escape, according to "AirPush Detector", seemingly the only such app on my device. Time will tell. Mar 17 12:36:45 Airpush detector, ha. may as well be called herpes detector Mar 17 12:39:17 Well, even my updated Nexus 5 device was unable to tell me who pushed this message in Notification History, so I guess the only way to tell is to long press when you receive it. Mar 17 12:39:38 (which is hard to test/verify right now for obvious reasons) Mar 17 12:42:03 Hey, has anyone here done low-level audio manipulation? Mar 17 12:42:55 hi all. i'm having problems adding some textviews to a linearlayout dynamically. the code runs but i don't see the widgets. see http://pastebin.com/HcLG0d0k for the java code, http://pastebin.com/Zw6t5bTY for the xml including list_container_id, and http://pastebin.com/VBFMpTjz for settings_row.xml. can someone tell me why my widgets don't appear? i suspect i'm doing things in the wrong order or messing up heights or widths... : Mar 17 12:45:26 I'm using android.media.AudioTrack.write, and I feel like it is responsible for 'stuttering'. I call it tens-hundreds of times per second and there is a lot of noise, I am not outputting myself. Mar 17 12:46:00 I need a little help on a code, I think you could help me in 2 minutes, I'm very donkey not any of this. Mar 17 12:47:52 i need help with this code Mar 17 12:47:53 https://github.com/pocmo/Yaaic/blob/master/application/src/org/yaaic/activity/AddServerActivity.java Mar 17 12:48:04 on function "save" Mar 17 12:48:09 how to set textview width auto to text size requirement? Mar 17 12:51:02 mylord: Google autoscaletextview Mar 17 12:51:09 thx Mar 17 13:02:41 helppppppppppppppppp Mar 17 13:19:01 Hola Mar 17 13:21:42 So I was wondering, I want to have several connections to the SQLite3 database on the phone for two separate threads Mar 17 13:21:45 should I just kill mysefl? Mar 17 13:23:53 you shouldn't. Mar 17 13:24:11 for both of those things :P Mar 17 13:24:32 hi everybody. I am currently trying to integrate the Facebook SDK to my android app, but as soon as I import the sdk projects and add a project dependency to the SDK project into my app, I can't build it anymore... Mar 17 13:24:41 Dex Loader] Unable to execute dex: Multiple dex files define Landroid/support/v4/accessibilityservice/AccessibilityServiceInfoCompat$AccessibilityServiceInfoVersionImpl; Mar 17 13:25:02 anybody an idea what I can do about this? Mar 17 13:25:23 evident, Facebook SDK it pulling in another instance of v4 support library Mar 17 13:25:40 evident, you have to tell your build system to exclude the Facebook supplied one Mar 17 13:25:46 evident, there are multiple libraries of facebook you are using Mar 17 13:27:45 Anyone ever seen a SecurityException on setContentView? Noticed a few this weekend in my analytics logs. Never seen it before. Mar 17 13:28:24 Do I just have to remove the jar from the libs folder? Because I can't find any reference to the jar in the buildpath of the facebook-sdk Mar 17 13:28:46 evident, you didn't tell which build system you're using so we can't really tell you more. Mar 17 13:28:57 also you didnt' tell just how you're including Support v4 and Facebook SDK Mar 17 13:29:45 Well I just imported all the Facebook-SDK projects into eclipse and in my project under "Android" set the dependency to the facebook project Mar 17 13:30:27 ah Mar 17 13:30:36 well somehow you have support-v4 twice as a dependency Mar 17 13:30:46 probably it's in your libs folder and in facebook sdk libs folder. Mar 17 13:32:20 well it's not in my libs folder... might just be that it's somehwer inside the libgdx jars (I am using libgdx as game engine) Mar 17 13:34:24 bacon1989 you have have multiple threads using sqlite. but best t only have one writer Mar 17 13:40:38 hey guys ... please help me with this http://stackoverflow.com/questions/22402941/up-navigation-to-parent-goes-always-to-main-activity/22451207?noredirect=1#comment34153648_22451207 :) Mar 17 13:42:24 g00s_: I started to write into the SQLHelper a locking mechanism with one getWritableDatabase() method Mar 17 13:42:35 omg, this is hilarious https://www.youtube.com/watch?v=QxnY2SWZTvk Mar 17 13:42:41 Mavrik: any other ideas where this comes from? Mar 17 13:42:45 does this seem like an adequate way to do this? Mar 17 13:42:49 bacon1989: you can have 1 writeable db Mar 17 13:43:08 but you need to be sure the writing is on an executor Mar 17 13:43:09 bacon1989 don't mess with that stuff ;) Mar 17 13:43:11 or handler Mar 17 13:43:32 plus, locking is just another way of creating deadlocks Mar 17 13:43:46 deadlocks are NOT fun Mar 17 13:44:01 well, I was going to try / finally everything that uses the writeable, and unlock after use Mar 17 13:44:17 any ideas on these fatal segs on android 4.3 on nexus 7? InputDispatches, etc: https://gist.github.com/adaptivedev/9599333 Mar 17 13:44:20 why not use transactions? Mar 17 13:44:24 evident, what do you mean "other ideas"? Mar 17 13:44:28 I told you where that is coming from. Mar 17 13:44:36 Now it's up to you to find out what you're including. Mar 17 13:44:39 And where. Mar 17 13:44:55 g00s_: that was evil! Mar 17 13:44:58 ok thank you :) I'll have another look Mar 17 13:45:21 just look for jars, there's a list in eclipse of included libs if I remember correctly Mar 17 13:45:28 (been awhile since I used Eclipse) Mar 17 13:45:48 idk where to find this transaction stuff Mar 17 13:46:01 i'm working with what I have available Mar 17 13:46:03 try reading docs for SQLiteDatabase Mar 17 13:46:08 I have been Mar 17 13:46:32 is it the SQLiteTransactionListener Mar 17 13:46:37 bacon1989: http://developer.android.com/reference/android/database/sqlite/SQLiteDatabase.html#beginTransaction() Mar 17 13:47:17 thepoosh: but at this point, I need to have a connection to the db using getWriteableDatabase Mar 17 13:47:22 which still sticks me in the hole Mar 17 13:47:48 you can use in your writer handler that one instance of the writeable db Mar 17 13:47:56 and use transactions on that Mar 17 13:48:06 the transactions will manage connections Mar 17 13:48:11 thepoosh: is this to solve any issues involved with the blocking call to the database? Mar 17 13:48:15 and prevent threading issues Mar 17 13:48:18 sort of Mar 17 13:48:33 thepoosh: oh I see Mar 17 13:48:33 no, you can always lock your db with bad access Mar 17 13:48:37 who is locking who? Mar 17 13:48:42 so I place one writeable db in the helper Mar 17 13:48:45 Mavrik: it seems that my game engine libgdx is including the support library itself, so it's somewhere in the gdx-backend-android.jar which is included into my project. I now just removed the support-library jars form the facebook sdk and instead added a reference to the gdx-backend-android.jar nad that seemed to have done the job... :) So thx for your help :) Mar 17 13:48:46 and use it throughout Mar 17 13:48:50 with transactions? Mar 17 13:49:27 evident, np :) Mar 17 13:49:31 you need to manage all writes in one place Mar 17 13:49:45 bacon1989, remember that sqlite database is just a single file Mar 17 13:49:58 yaaic Mar 17 13:49:58 .c Mar 17 13:50:00 and opening it multiple times can give you one hell of a time :) Mar 17 13:50:19 mavrik beacon teaches databases Mar 17 13:50:23 yeah, I keep hearing that it's a pain to perform multiple connections on an sqlite db Mar 17 13:50:38 bacon1989: it's not a pain, it's just bad practice Mar 17 13:50:41 and kinda stupid Mar 17 13:50:45 well Mar 17 13:51:01 that is what transactions are for Mar 17 13:52:00 so I should place a getWriteableDatabase() in my sqlhelper, pull the db helper when I want to add something, and begintransaction --> endtransaction Mar 17 13:52:07 mikedg, good for him. Mar 17 13:52:33 am I getting this straight? Mar 17 13:52:40 every write to the DB should be from the same place to allow management Mar 17 13:52:40 bacon1989, I usually have a queue-like handler to do that just to avoid issues Mar 17 13:52:49 basically do all writes on a single thread Mar 17 13:52:58 executor or handler Mar 17 13:53:33 I actually use GreenDao so I don't manage that, but I do schedule at times the work Mar 17 13:56:10 the same sqliteopenhelper will keep giving you the same connection object, since its cached. so make it a singleton and you are golden Mar 17 13:56:29 the only way you can fuck things up is using multiple instances of sqliteopenhelper Mar 17 13:56:35 g00s_, just reading our stats we send out over 200K push notifications a day Mar 17 13:56:38 heh Mar 17 13:56:42 lemonxah \o/ Mar 17 13:57:06 first of all .. WHY use multiple instances of sqliteopenhelper Mar 17 13:57:14 that will severely brake things Mar 17 13:57:34 and even then, multiple connection objects from multiple instances of sqliteopenhelper wiill work, technically, just a wast of memory and also the locking is more coarse grained Mar 17 13:58:02 yeah, i can't think of a good reason Mar 17 13:58:04 multiple sqliteopenhelpers will also break your database when you upgrade Mar 17 13:58:16 or when you have different tables per helper Mar 17 13:58:26 lemonxah: 200K and that's it? Mar 17 13:58:53 well those are push notifications Mar 17 13:59:17 messages that go over our tcp connection just for the android users are in the millions Mar 17 13:59:31 and android is our smallest userbase Mar 17 13:59:39 lemonxah: http://pbrd.co/1ohDP3r Mar 17 13:59:45 well .. apart from iOS but no one here counts that since the iOS app is new Mar 17 13:59:51 lemonxah does mxit do WP ? Mar 17 14:00:02 yes Mar 17 14:00:11 forgot about that one :/ Mar 17 14:00:11 hm Mar 17 14:00:15 also, since for ever, iOS holds about 30% of the users Mar 17 14:00:27 lemonxah: where do you work? Mar 17 14:01:08 thepoosh, what app is that? Mar 17 14:01:12 andi work at mxit Mar 17 14:01:12 glide Mar 17 14:01:25 also on whatsapp Mar 17 14:01:31 i work at glide Mar 17 14:01:53 anyone got any ide ahow to make this ui ? in particular the transition when you click on something Mar 17 14:01:57 https://www.dropbox.com/sc/uute04efin9kys3/jgfzXjrV8u Mar 17 14:02:05 what do you guys use for CI? Mar 17 14:02:12 looks like the two big ones are jenkins and buildbot Mar 17 14:02:14 some of these new fangled UIs on ios are getting too hard to clone Mar 17 14:02:57 Gaz`: AndroidHorizontalListView Mar 17 14:03:59 yeh that would do the scrolliong but watch when i tap an item Mar 17 14:04:09 it has some elaborate animation Mar 17 14:04:21 ok, so you need to set custom animation Mar 17 14:04:25 cool thepoosh Mar 17 14:04:27 :) Mar 17 14:04:31 :D Mar 17 14:04:33 thanks Mar 17 14:04:35 hmm Mar 17 14:04:41 easier said than done :) Mar 17 14:04:45 if theyre rows in a list Mar 17 14:04:57 why? Mar 17 14:05:03 it's animating a view Mar 17 14:05:08 Gaz` there is a devbytes for expanding animation for a regular listview Mar 17 14:05:14 listview item Mar 17 14:05:24 i don't really like horizontal scrolling stuff Mar 17 14:05:25 onItemClicked returns the view Mar 17 14:05:38 lemonxah: are you a user? Mar 17 14:05:47 hmm Mar 17 14:05:56 i am not sry Mar 17 14:06:18 don't be Mar 17 14:06:30 I wouldn't be if I haven't worked here :) Mar 17 14:06:37 I'm more of an irc type of guy Mar 17 14:06:46 less of instant video messaging Mar 17 14:07:00 checking it thanks g00s_ Mar 17 14:09:03 thepoosh: how are you supposed ot see tatas if you dont video chat Mar 17 14:09:24 what?! Mar 17 14:09:57 mikedg: not following Mar 17 14:10:06 neither am i Mar 17 14:10:10 twitter is lame Mar 17 14:10:33 I can have several databases, correct? Mar 17 14:10:58 I mean, I don't see why I couldn't have more than one Mar 17 14:13:25 you mean readableDataBase Mar 17 14:13:38 *readableDatabase Mar 17 14:15:53 bacon as in completely different databases yes Mar 17 14:16:17 but do you want multi connections to the same database you can .. but sqliteopenhelper is per database only 1 of them per databse Mar 17 14:17:25 lemonxah: I see, I think I can work with that Mar 17 14:18:13 you can create multiple connections to the db if you want a readonly db then do something a little diff Mar 17 14:18:27 the sqliteopenhelper only gives you a read write connection Mar 17 14:19:04 maiatoday, hello Mar 17 14:24:41 wb maiatoday Mar 17 14:24:45 thx Mar 17 14:26:07 lemonxah: there is a getReadableDatabase method Mar 17 14:26:21 I can make several of these, no? Mar 17 14:26:56 no Mar 17 14:27:05 that actually returns a full writable db Mar 17 14:27:52 that's strange Mar 17 14:29:33 bacon1989, just do something like this Mar 17 14:29:33 readDb = SQLiteDatabase.openDatabase(path, null, SQLiteDatabase.OPEN_READONLY); Mar 17 14:29:36 in your provider Mar 17 14:29:43 how do I say in my on text change listener Mar 17 14:29:52 then use the readDb to do all the queries Mar 17 14:30:03 if the text is not correct then dont let it be inputted Mar 17 14:30:04 and use the Mar 17 14:30:06 mWriteOpenHelper = new UserDatabase(getContext()); Mar 17 14:30:07 writeDb = mWriteOpenHelper.getWritableDatabase(); Mar 17 14:30:13 to do all the writing Mar 17 14:30:32 I have a validator I just want to know how to stop the text in the beforetextChange or whatever needs to be done (using input filter) Mar 17 14:31:06 hi all. I just started a new Android project to test something out. And for some reason now I get a "fragment_main.xml" file. I didn't do anything different than with other tests. I removed the project and created it again several times. But fragment_main.xml seems to be here to stay. I'm using Eclispe on Linux, though I guess that doesn't make much of a difference. Any reason why I'm getting this all of a sudden? Mar 17 14:31:34 why dont you just delete the file? Mar 17 14:31:50 lemonxah actually, i dont think that works. if i recall, its the same connection Mar 17 14:32:06 also, opening a db open read only with WAL enabled corrupts the db Mar 17 14:32:13 i think HTC fucked that up Mar 17 14:32:32 g00s_, WAL is enabled Mar 17 14:32:44 if (!SQLiteDatabaseCompat.enableWriteAheadLogging(writeDb)) Mar 17 14:33:20 LoneSoldier728: it's the first time I got it. I don't know why as I am not working with fragments. So I would like to know the cause of this. Also, my regular activity_main.xml looks different because of it it seems Mar 17 14:33:33 and if the openDatabase doesn't work .. its ina try catch then the readDb deafults to the writeDb Mar 17 14:33:49 but so far its been working great and we have had an increase in access speed tot he db Mar 17 14:33:55 hi, i have a custom device and i cant get data from gps, but on emulator it is works fine. the gps path: /dev/ttyACM6 but i not reach this device from my code. anyone help me? Mar 17 14:34:09 app startup is now sub 100ms it used to be over 500ms Mar 17 14:34:10 are you using a blank activity? Mar 17 14:34:33 Yes I am, just starting a default blank project Mar 17 14:34:49 lemonxah yeah , i think HTC compiled sqlite a special way. Mar 17 14:34:55 on one of their phones Mar 17 14:35:08 make sure you have nothing else checked off, I am using Android Studio so I don't know what you could be doing wrong Mar 17 14:35:23 do you recall which one ? Mar 17 14:35:35 i would like to test it to make sure its working at least Mar 17 14:35:54 did anyone ever use an input filter... instead of removing the entire text inputted by the user I am trying to just remove the last character Mar 17 14:37:08 anyone can help me? Mar 17 14:37:32 I thought perhaps I made some kind of selection somewhere. So I recreated a new project a few times, checking what could have been the cause. But there's actually little to do 'wrong'. The result is always the same though. Very strange. It just started happening today Mar 17 14:37:35 nvm it works Mar 17 14:37:41 I made no updated or changes Mar 17 14:39:03 How can I get the size of a bitmap after performing an inSampleSize? Mar 17 14:39:40 hm, i'm trying to remember. it was on SO Mar 17 14:41:35 hm, old phone Mar 17 14:41:36 http://stackoverflow.com/questions/4718934/sqlite-issues-with-htc-desire-hd Mar 17 14:41:53 hello Mar 17 14:42:13 has anyone managed to get the MediaExtractor example to run? http://bigflake.com/mediacodec/ExtractMpegFramesTest.java.txt Mar 17 14:42:38 it's the "ExtractMpegFramesTest.java (requires 4.1, API 16) " example from http://bigflake.com/mediacodec/ Mar 17 14:43:19 I can't get the onFrameAvailable() to arrive before the timout in the example Mar 17 14:43:42 it always arrives after the timeout, regardless of how big or small I set the timeout Mar 17 14:45:58 Just curious: why does ActionBarSherlock require getSupportMenuInflater()? Mar 17 14:57:20 hey guys .. Mar 17 14:58:11 i was wondering ... when you create layout with some relative dimensions .. is there and event when the actual dimension is computed? Mar 17 14:59:10 i need to set height based on actual width .. i know the reation of heigh/width but i dont know how to set it ... like height = 1.5 * width Mar 17 14:59:54 g00s: I joined Metro, so they cancelled the project ;) Mar 17 15:01:54 Weird, I am seeing this same thing on my app with an updated phone http://forum.cyanogenmod.com/topic/67693-securityexception-on-nightly-build-with-goog-voice-goog-drive-facebook/ Mar 17 15:02:04 SecurityExceptions on some apps Mar 17 15:02:25 hi Mar 17 15:02:57 i am trying use apache commons codec but i have this NoSuchMethodError encodeBase64String, can anyone help me? Mar 17 15:05:10 http://stackoverflow.com/questions/22457831/imegaview-height-relative-to-width Mar 17 15:08:13 capella i see ! Mar 17 15:08:33 JakeWharton: Are you here? I have a quick ActionBar question. Mar 17 15:08:33 FF got pretty owned in the pwn2own Mar 17 15:09:03 :( Oh well ... I got four patchs in Mar 17 15:09:04 Oh yah, but minor bugs I hear we'll have fixes by Weekend Mar 17 15:09:24 chrome already fixed theirs Mar 17 15:09:44 * capella shakes fist !!! Mar 17 15:09:47 you mean, *next* weekend? Mar 17 15:09:55 Has anyone had any problems with ScriptIntrinsicBlur? I keep ending up with bitmaps with black marks on them Mar 17 15:09:56 thats too long man ! Mar 17 15:10:13 capella FF for android has been hanging on me, i might have to reinstall Mar 17 15:10:40 I wonder if we have a tracking bug for "Fix the pwn2own exploits" :p Mar 17 15:10:55 any? Mar 17 15:12:11 Ah, we had some issues but I thought they cleared them all ... are you using sync? and yah, re-install might do it Mar 17 15:12:12 I had one issue where I had to uninstall all four versions off FF before a clean re-install would work :o Mar 17 15:15:34 Seems fragments are being pushed now by Android Mar 17 15:16:18 The only way around it is to not create an activity during project creation and then make an activity_main.xml Mar 17 15:16:55 Okay, so I'm using Picasso, with a BlueTransform class using RenderScript support library. I'm trying to blur an image, here you can see the result http://i.imgur.com/yHWRKIm.png . Anyone have any idea what the black marks are from? It's more visible on other images, it's really quite perculiar Mar 17 15:17:00 Confusing though as I was just geeting used to the situation, now they're pushing fragments and as far as I can read even more experienced devs find them confusing Mar 17 15:17:03 being pushed "now" ? Hasn't it been a thing for some time? Mar 17 15:18:53 capella: I jsut started with Android about a week or 2 ago. And I didn't get the fragments up until today Mar 17 15:18:57 Searching around on the net Mar 17 15:19:24 I see some people asking about it as well, most of them rather recently it seems Mar 17 15:19:41 Anywya, so I guess I should get used to using them Mar 17 15:22:52 is anyone using CyanogenMod 10.2.1? Mar 17 15:26:12 Hi, I have been drawing an image programmatically to my app and I would like to know if anyone could help me figure out how to add it to an array of objects? What I have tried has failed and I'm not sure where else to turn Mar 17 15:26:37 Here is the method I am using to draw the image as an invidivual instance: http://pastie.org/8938078 Mar 17 15:26:49 and here is its class: http://pastie.org/8938080 Mar 17 15:30:08 Rellac: You want a List, or something different? Mar 17 15:31:27 I suppose something like this would be appropriate? Sorry I am just learning this new array method and I'm rather confused by it :P I want to be able to do, for example, Enemy[e].setX(something) Mar 17 15:31:56 Fixed my issue, if anyone ever has any image artifacts when using ScriptIntrinsicBlur, MAKE SURE that it's width and height is divisible by *4* Mar 17 15:32:22 Rellac: So you want an Enemy[]? Mar 17 15:32:57 As long as I can reference the idividual Enemy instances, so I can control, for example, a row of different images that will move at their own rates Mar 17 15:33:20 Rellac: Yep. That could be a List, if it's dynamically-sized, or an array, if it's fixed-size, with a List preferred. Mar 17 15:33:33 Hi, if I write to a file opened with openFileOutput(logfilename, 0). Where can I find this file on the device ? Mar 17 15:33:43 Yes a list seems most appropriate then, I will need some dynamic control Mar 17 15:33:59 can I browse somehow android emulator or install apps from appstore in the emulator? Mar 17 15:34:04 I see under the Android directory various programs and some of their files, but mine is not there ? Mar 17 15:34:24 by browsing I mean opening app directories etc.. Mar 17 15:34:47 Silmarilion: adb can connect to the emulator as if it were a phone. Mar 17 15:34:51 using ADT bundle Mar 17 15:34:57 aha Mar 17 15:35:54 Silmarilion: if you have a rooted device you can get access to the aok files in your system and transfer them to an emulator Mar 17 15:36:05 freeone: I had attempted a class like this: http://pastie.org/8938105, but I'm not sure how to reference it outside the class without making it static. Am I taking the correct direction here? Mar 17 15:36:27 Might sound like a dumb question. Mar 17 15:36:34 :\ Mar 17 15:37:23 I am developing inteligent history eraser app, so I need to find all the paths were common apps save history like firefox, opera, android browser etc.. I dont want to mess with the phone for now so I thought I could install the apps in emulator and test there. Mar 17 15:37:24 Rellac: Why does it extend Activity? Is it an Activity? Mar 17 15:38:02 Is there a way to tell the UniversalImageLoader if it failed to find a bitmap locally to ask me again for a potentially updated url, rather than retrying with the same url Mar 17 15:38:03 No I guess not, however I am unsure of how else to support getResources() without making it an activity Mar 17 15:38:36 Rellac: It needs access to a Context, which can be passed in. Think of what role it plays in the application lifecycle. (I don't have enough information to give you more clues, because it looks like you have half-a-factory.) Mar 17 15:40:30 So i'm just writing to external storage then. At least that way I can find the file ! Mar 17 15:40:31 haha Mar 17 15:40:54 something along the lines of "public void spawn(Context context) " and passing in the context from the main gameview then? Mar 17 15:41:10 Rellac: Possibly. Mar 17 15:41:31 hm, still an undefined method with thi Mar 17 15:41:32 s Mar 17 15:41:45 Rellac: How are you calling it? Mar 17 15:42:18 EnemyList.spawn(getContext());, but it still wants the spawn method to be static Mar 17 15:42:45 Rellac: That's because you're referencing it statically. You need to create an instance of the class to call instance methods. Mar 17 15:44:09 ah I see, simple matter of "private static EnemyList EnemyList;", yes? Mar 17 15:44:39 Rellac: No. "EnemyList list = new EnemyList(); list.spawn(getContext());" Mar 17 15:47:10 ok thanks a lot, you are the bees knees, I *think* I can do this form here Mar 17 15:47:21 Ok let me get this straight. Application data is stored in the data directory found in the Android directory right ? Mar 17 15:47:39 how to change fragment and also the class handling user inputs, associated with fragment (eg, from MainActivity to OtherActivity) Mar 17 15:48:45 OH google ! Mar 17 15:48:46 :) Mar 17 15:48:59 how long should I wait before emu starts? It has passed 5 min, still at boot Android _ (blinking dash). I have 4gb of ram, quad core cpu, and 9600GT gpu with 1gb ram DDR3. Mar 17 15:50:36 Silmarilion: Try a lesser-spec'd emulator. Mar 17 15:50:46 Is (google is) not really telling my why the file my application wrote to internal storage is not there nor the package name. ( in Android/data/ Mar 17 15:52:27 would there be any reason why sqlite would competely ignore the WHERE clause when performing a particular query? Mar 17 15:53:04 mode is 0 IE: MODE_WORLD_READABLE Mar 17 15:53:39 Its the first time I try write to internal storage so i'm not sure if this is normal. For it not to appear under Android/data/ Mar 17 15:53:54 in fact the is not appearing... Mar 17 15:54:08 :) Mar 17 15:54:43 oh wait wrong mode. Mar 17 15:54:54 duh Mar 17 15:56:08 Well thanks for listening, you have been a great help. Mar 17 15:56:15 :) Mar 17 16:00:16 I'm trying to get Retrofit working with ORMlite where the object to be persisted stores one-to-many foreign field IDs. Anyone ever tried this? Mar 17 16:07:17 Unknown0BC: rubber duck debugging Mar 17 16:07:45 * Unknown0BC rows Mar 17 16:07:53 panting Mar 17 16:10:07 or did you mean a birdy ? Mar 17 16:10:10 colintheshots: I don't see what that has to do with Retrofit Mar 17 16:11:22 http://en.m.wikipedia.org/wiki/Rubber_duck_debugging Mar 17 16:11:27 JakeWharton: ORMlite seems to want to use a ForeignCollection of the POJO to handle storing foreign objects. However, the returned JSON from Retrofit is field IDs. There seems to be no clear way to set up the relationship when using the two together. Mar 17 16:13:18 Obviously, it's no longer Json once it's inside Retrofit. I need some way to get from the field Ids to a ForeignCollectionField. Mar 17 16:13:20 Write a custom Converter. Retrofit doesn't do anything with (de)serialization. It sounds like you want to change the behavior of Gson Mar 17 16:14:53 colintheshots, I tried one times the ForeignCollection of ORMLite, and finnaly i create my owner foreign keys without ORMLte, (taken the add, delete and update action manually)) Mar 17 16:15:31 colintheshots, the update of foreignCollection has a lot of problem like the delete, for the insert is ok Mar 17 16:15:58 JakeWharton: Ah, so I could write a custom typeadapter to deserialize it to the actual foreign field then. Mar 17 16:16:13 Or that Mar 17 16:16:33 Sure Mar 17 16:16:43 JakeWharton: I'm moving from ABS to the native ActionBar. It seems that, in 4.0, settings homeAsUp in a theme doesn't enable the home button. I have to manually call setHomeButtonEnabled(true). Is this a bug in 4.0? Mar 17 16:16:44 feanorin: Yeah, I'm not too impressed by the foreignCollection functionality yet. I know it's not an easy problem to tackle, but a custom solution would probably be better. Mar 17 16:16:53 The documentation seems to suggest that the home button will be enabled when homeAsUp is set. Mar 17 16:17:11 Oh yes. I see myke. Mar 17 16:17:16 Thanks for listening :D Mar 17 16:17:27 I should get me one of those. Mar 17 16:17:31 cute. Mar 17 16:17:43 lol Mar 17 16:17:48 * DarkSlay3r talks to rubber duck in office Mar 17 16:17:57 * DarkSlay3r looks like idiot Mar 17 16:18:08 * DarkSlay3r buys real duck to talk to Mar 17 16:18:09 Has anyone gotten http://developer.android.com/reference/android/bluetooth/BluetoothHeadset.html#startVoiceRecognition(android.bluetooth.BluetoothDevice) to work with any bluetooth headset in existance? Mar 17 16:18:14 * DarkSlay3r gets promoted Mar 17 16:18:16 DarkSlay3r: where did you order your rubber duck? Mar 17 16:18:53 I hate comments. :/ Mar 17 16:18:56 They're so "look at me". Mar 17 16:19:18 cezium: found one in my house Mar 17 16:19:26 hell if i know where it came from Mar 17 16:19:40 Do you folks prefer // or /* */ in general? Mar 17 16:19:43 I have to get one for when I'm working at home and have no real colleges to talk to. :P Mar 17 16:20:03 My rubber duck is a red devil ducky. Mar 17 16:20:05 cats are a good substitute Mar 17 16:20:17 http://www.mcphee.com/devilduckie/duckies.html Mar 17 16:20:26 have two cats but don't want to waste their valuable time. Mar 17 16:20:40 colintheshots: I own a black one Mar 17 16:20:50 my nick on BF3 is RubberDucky Mar 17 16:20:56 although they try to "help" with the problem Mar 17 16:21:17 when i tell my cat about problems with XML Mar 17 16:21:36 it starts typing and eventually makes everything worse Mar 17 16:22:05 colintheshots: this is my avatar on our company git Mar 17 16:22:06 https://secure.gravatar.com/avatar/2efee729dc1e1a6615a1d8ce3a950be3?d=https%3A%2F%2Fd3oaxc4q5k2d6q.cloudfront.net%2Fm%2F8981a4b643b7%2Fimg%2Fdefault_avatar%2F96%2Fuser_blue.png&s=96 Mar 17 16:22:28 Careful, when the cat answers a question, it inevitably licks its behind and you end up with tail recursion. Mar 17 16:22:50 colintheshots: tail recursions are the good kind Mar 17 16:24:16 When i carefully explain a problem and it licks its ass it's like it's telling me its ass hole is more interesting than my problems... Mar 17 16:25:03 Hi everyone, I need to send a bluetooth message from my application to any other available device with the same application, is this possible? Mar 17 16:25:41 I've just uploaded my first app, how many downloads/installs should i expect in the first week? or what are some of your experiences? Mar 17 16:25:54 mrcloud: How would you tell whether they have the application or not? Mar 17 16:26:12 Tacticalmind: Depends on your marketing and reach Mar 17 16:26:21 Tacticalmind: what app? Mar 17 16:26:27 good marketing, thousands Mar 17 16:26:36 poor to no marketing Mar 17 16:26:39 5s Mar 17 16:26:42 just telling friends about it so far, it's a game called tycoon of all trades Mar 17 16:26:55 expect 5s Mar 17 16:27:01 freeone3000 Thats the question :P Mar 17 16:27:13 i uploaded it thursday i'm at 35 installs Mar 17 16:27:16 TacticalJoke: probably Mar 17 16:28:26 mrcloud: see docs Mar 17 16:28:31 bluetooth chat Mar 17 16:30:28 Tacticalmind: that's nice Mar 17 16:30:34 JakeWharton: ALOHA! Mar 17 16:30:42 why thank you Mar 17 16:31:40 Tacticalmind: Link to app Mar 17 16:32:34 https://play.google.com/store/apps/details?id=com.neidert.myfirstapp Mar 17 16:32:40 i'm still workin out some kinks Mar 17 16:32:52 is there a way to dynamically set the "up" button rather than having to specify statically in Android Manifest? I am trying to do an "up" button for a Settings page, which can be accessed for anywhere in the app. Mar 17 16:33:01 and i'm not a very good graphic designer so it's not that pretty lol Mar 17 16:33:29 Tacticalmind: little hint, DON'T CALL YOUR PACKAGE NAME MY_FIRST_APP Mar 17 16:33:31 !!! Mar 17 16:33:55 i know i know, i realized that mistake after it was uploaded i felt foolish Mar 17 16:34:06 hmmmm Mar 17 16:34:09 never mind Mar 17 16:34:11 Tacticalmind: you don't have many users Mar 17 16:34:16 fix it now Mar 17 16:34:20 i'm aware lol Mar 17 16:34:22 before you get popular Mar 17 16:34:41 you can't revise package name Mar 17 16:34:43 i'm trying, just difficult with so many exams right around the corner Mar 17 16:36:12 seriously... Mar 17 16:36:25 refactor package name, it's like 5secs Mar 17 16:36:31 Hi, so I am just wondering if anyone can help me out here. I am attempting to utilise getResources() to draw an image and I seem to be having trouble with it not being recognised. Here is the class in which I am using it: http://pastie.org/8938247 Mar 17 16:36:34 sign and reupload Mar 17 16:37:00 oh, I thought it couldn't be done anymore, it would change the google play link Mar 17 16:37:17 line 13 Mar 17 16:37:35 Yeah, you have to take down the old app Mar 17 16:37:36 "The method getResources() is undefined for the type EnemyList" Mar 17 16:37:43 and start fresh with the new one Mar 17 16:38:00 ah shoot, but wouldn't my current users lose their progress that way? Mar 17 16:38:02 easier to tell 35 people that they need to install than 10,000 Mar 17 16:38:33 Sacrifices must be made Mar 17 16:39:17 i'll do it after I enable cloud saving, so their progress can be saved Mar 17 16:39:19 How do I use variables declared inside buildTypes in my project ? Mar 17 16:39:56 I dunno... but wouldn't the save be tied to the current package name Mar 17 16:40:21 depends, if i could save to my own server i could connect both package names to the same server Mar 17 16:40:25 Charl1e: Regarding your ScriptIntrinsicBlur problem, which version of the OS is that on? Mar 17 16:40:34 I see Mar 17 16:40:41 the flow of my app is: FragmentA, FragmentB, FragmentC. But when the user pushed the back button on fragmentB, I want to close the app (not the fragment), what's the best way to do this? Mar 17 16:40:48 that's a project for another day Mar 17 16:41:11 Good luck Mar 17 16:41:16 thank you Mar 17 16:41:38 FrancescoV: Don't add fragment a to the back stack. Mar 17 16:42:10 finish() Mar 17 16:42:17 but we aren't supposed to do that Mar 17 16:44:43 freeone3000: I only add FragmentC to the backstack Mar 17 16:46:12 help Mar 17 16:46:38 i need help getting the download speed and latency Mar 17 16:47:12 Gumboot: 4.2, mainly only devices though, I found this and solved my problem by roman nurik https://plus.google.com/+RomanNurik/posts/TLkVQC3M6jW Mar 17 16:48:46 i am having errors updating eclipse, its not finding some packages in repository Mar 17 16:52:00 OK. Sounds like it might have been fixed recently anyway, then. Mar 17 16:52:20 does the "downloads" number under and app on google play represent the total number that have downloaded it? or just the number that still have it installed? Mar 17 16:52:27 Yeah, at least I fixed it even if it is a workaround, client wont be happy *facepalm* Mar 17 16:54:22 how do I get manifest variables from inside android studio? Mar 17 16:54:48 I mean from inside gradle Mar 17 16:59:05 no idea totic Mar 17 16:59:30 what is the diff b/w android platform an sdk ? Mar 17 16:59:38 an == and Mar 17 16:59:51 rsz: You build using an sdk for a platform. Mar 17 17:00:18 the platform is not part of the sdk? Mar 17 17:01:04 does this line make sense? Intent theIntent = new Intent(MainActivity.this, GameJoinLobby.class); Mar 17 17:01:16 / GameJoinLobby is a FragmentActivity in my same package Mar 17 17:01:23 rsz: No, the platform runs on the phone. It has a version, the API level. Your SDK version happens to have its numbers coincide with the API levels. So you could, say, use a version 19 SDK to compile for API level 12. Mar 17 17:01:34 it's failing.. i'll print out error Mar 17 17:04:38 I can use SQLiteDatabase.rawQuery to update rows in a table, right? It doesn't seem to be working as intended Mar 17 17:05:49 hi Mar 17 17:06:05 i have a problem with the in app subscriptions since yesterday. is someone there who could help? Mar 17 17:06:16 anyone know why this won't update my database values? http://pastebin.com/9diMV1Nb Mar 17 17:06:24 mylord: try ... = new Intent(this, GameJoinLobby.class); Mar 17 17:06:51 Char1le: was missing activity in the AndroidManifest.xml Mar 17 17:07:19 that works tho.. MainActivity.this Mar 17 17:07:19 :) Mar 17 17:07:23 okay Mar 17 17:07:41 verification through the android pusblisher is always returning (500) Backend Error Mar 17 17:07:47 Hey peeps, just wondering if any of you guys used coleifer's django-relationship for following/followers? Mar 17 17:12:42 thanks, freeone3000! Mar 17 17:13:25 freeone3000, you're doing god's work son Mar 17 17:14:41 in case anyone else runs into SQLite UPDATE problems, you need to use the provided update function, because rawQueries don't work. Mar 17 17:16:17 Char1le: how do I send an object to my new running Activity, either upon start/intent, or immediately after? Mar 17 17:17:38 bacon1989, raw queries work quite well. Mar 17 17:18:59 bacon1989: rawQuery is really for querying data, there's execSQL for just executing SQL statements Mar 17 17:20:52 But yeah, use the provided methods.. They escape values for you and everything Mar 17 17:33:47 does google play crash reporting only report a subset of crashes? Mar 17 17:33:51 can someone look at www.isforth.com/lc.9.png and rc.9.png and tell me whats wrong with them? Mar 17 17:34:13 It shows the crashes people submit Mar 17 17:34:40 which is <5% of all crashes Mar 17 17:34:45 yeah Mar 17 17:34:51 they work but when they are drawn i see a solid black background underneath the bubble at the same level as the decending part. Mar 17 17:34:51 Probably <1% Mar 17 17:35:26 i see the bubble. isee the decending chat bubble arrow. but the part of the png to the left and the right of the decending chat arrow is solid black Mar 17 17:35:28 not transparent Mar 17 17:36:49 if someone could look at my 9 patch png's as linked and tell me wth is wrong with them that would be awesome :) Mar 17 17:50:24 is there some plugin which could open directly in eclipse ddms sqlite database? Mar 17 17:52:25 what is the diff b/w Google API(x86 system image) and Intel x86 Atom system image? what is the need of 2 system images? Mar 17 17:52:56 Hi all, n00bie here. I'm trying to understand httpRequest and HttpResponse. Contex: I'm doing a Google Places tutorial, where a request is made, but a REQUEST_DENIED status keeps coming back. I'm not entirely clear on how HttpResponse works though, upon logging the response I get com.google.api.client.http.HttpResponse@42fee508 for example. What is going on there, and how would I get to Mar 17 17:52:56 read what is being returned in it's entirety? Mar 17 17:53:28 If I use the same URL in a browser I get back an XML Mar 17 17:53:42 <7JTAABRMY> have you set the correct permissions Mar 17 17:54:14 rsz: _Is_ there any Google APIs x86 image? The difference used to be that the Google APIs images were ARM only, and therefore a lot slower when running on x86 type architectures (emulators). Mar 17 17:54:22 hi there. I'm stuck trying to get a simple google(plus) login working within my android app. logcat shows the following output after triggering the login process: http://pastebin.com/6QBfKcB7 Mar 17 17:54:27 Yeah, i think so. But i'm not really looking to solve the Request Denied problem, i'm looking to understand and read the HttpResponse Mar 17 17:55:11 so that in the End i can fix the request denied problem, but it would be very handy to also get the error_message, rather then just the Status Mar 17 17:55:27 i've searched and tried a lot to resolve this problem, but could not yet find any solution (I'm stuck on that for 2 days/evenings now...) Mar 17 17:55:48 kjeldahl, there is a seperate Google APIs (ARM).. :-) Mar 17 17:58:37 my code (shortened) currently looks like this: http://pastebin.com/sZX9URGz Mar 17 17:58:41 kjeldahl, I d/l the vanill android sdk, and then fired up the command line 'android update sdk', there the API19 gives default selections for ARM EABI/Intel Atom/Google API(x86)/Google Api (ARM) system images. Mar 17 17:59:02 Hey, I want to build the following UI, first a login screen, after login a home screen, you push a specific button on the home screen you go to the next screen... do I need an activity for every screen? Is there better method? Mar 17 17:59:56 jellybee: those sound like activities to me Mar 17 17:59:58 I'm using eclipse with adt and added the SHA1 fingerprint from the debug.keystore of my eclipse using my google api console Mar 17 18:00:06 jellybee, Fragments Mar 17 18:00:22 I find fragment's much much easier to deal with vs lots of activities Mar 17 18:00:53 jonc-1: how do you trasition from fragment to fragment? Mar 17 18:01:05 FragmentManager Mar 17 18:01:08 jellybee: You can use fragment manager to handle all your transactions Mar 17 18:01:25 great, thanks Mar 17 18:01:30 I disagree, if you want to reuse the login-screen a fragment is of course a way to go, but login and home are different activities to me.. Mar 17 18:01:39 jellybee: take a look at this http://developer.android.com/guide/components/fragments.html Mar 17 18:02:09 is there a way to set the android manifest versionname from gradle? Mar 17 18:02:35 rsz: Ok, I see it now. That's fairly new, and good news I believe. Could also be a precursor to an Intel based Nexus tablet (like the rumours say). It also makes it a lot smoother to test Google APIs while developing (running the emulator), which the Intel ones do not support. Mar 17 18:02:37 jellybee: ^ Mar 17 18:03:03 if you have some kind of remember me option with multiple activies, you have to start the login activity and then check then spawn the logged in activity if cached. With fragments you can do that check and decide which fragment should be first loaded Mar 17 18:03:18 totic: http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Manifest-entries Mar 17 18:03:35 kjeldahl, so it would be better to work with the Google API rather than the Intel/ARM ones? Mar 17 18:04:28 kakazza: awesome, so I just don't set them anymore in my manifest and just set them in gradle? Mar 17 18:05:04 I would be glad about any idea what I could try *cough* ;) Mar 17 18:05:05 rsz: If you're doing anything related to Google APIs and/or Play Services, you want to run the "Google API" ones yes. You should test with ARM as well, but that is often easier and more realistic to do on-device. Mar 17 18:05:07 jonc-1: it appears easier but its the same effort, plus I would go the other way, load the default activity and if a login is needed spawn the login activity Mar 17 18:06:13 totic: yeah Mar 17 18:07:12 thats the way any weblogin-process works, replacing fragments feels hacky to me Mar 17 18:07:46 but I dont consider this as THE solution. intersting topic btw Mar 17 18:07:52 I find fragments a lot simpler to deal with, activities feel too heavy Mar 17 18:08:03 they are all java-classes Mar 17 18:08:14 fragments, if done properly feel much cleaner to me Mar 17 18:08:56 kjeldahl, do you have a handy doc that talks about the differences between the two and possibly when to use which? Mar 17 18:09:10 i dont know... an activity that shows only one fragment is like a box in a box... i dont see the need of the outer box then.. Mar 17 18:09:23 Build to extend Mar 17 18:09:31 why? the login screen is the login screen Mar 17 18:09:39 it should not display any other information as the user is not logged in Mar 17 18:10:08 rsz: Nope, I wasn't even aware Google had started pushing x86 images until you mentioned it now. ;-) Mar 17 18:10:11 you could still extend it with different fragments if you need, but in logged in vs. not logged in i'd prefer to keep things separated Mar 17 18:10:31 * kjeldahl is currently knees deep in iOS work. Mar 17 18:10:32 ohcibi, I personally would just rather decide which fragment is shown vs launching 2 activities to get logged in Mar 17 18:11:07 if logged in, show X fragment, if no logged in show login fragment, on login, replace login fragment Mar 17 18:11:19 not logged in* Mar 17 18:12:07 vs having to create 2 full activities to login, that's why I say it feels heavier, a Fragment is close to a mini activity, but a little lighter weight underneath Mar 17 18:12:10 i know what you mean.. I still would go for 2 activities as I dont see the overhead and this is what activities are for actually 8-)) Mar 17 18:12:41 kjeldahl, ok no problem :-), I got concerned because, the Google API are smaller by 1MB for the ARM and 25M+ for x86, wonder why they did not reuse the default system images and wrap their functionality on top of them. Mar 17 18:14:57 SimonVT: that was probably my problem, I thought I could use the SQL rawQuery to update values as well, and was sorely mistaken Mar 17 18:21:10 could someone please guide me? http://pastebin.com/5SA7VQr9 Mar 17 18:25:00 anyone else seeing 500 errors coming back from the purchase status API? Mar 17 18:34:24 I'm aiming to write a useful AI for my phone, noncommercial, just a personal project so 'whatever works' is fine. I'm torn between writing it within tasker's JS abilities for the easy abstraction of device and event functions, or python via SL4A Mar 17 18:34:42 anyone have any advice regarding either option, or indeed any other? Mar 17 18:35:17 the AI is voice controlled, and ideally preserves state, which is an issue with trying to write it in tasker Mar 17 18:35:43 best option in that case looks like saving and reloading all current data at the end and start of each invocation, respectively Mar 17 18:35:49 Hornet: do a real app Mar 17 18:36:14 means java, which I don't speak, and a learning curve that looks something like a space shuttle travectory Mar 17 18:37:01 I'd have to manually manage every detail of everything, which of course is ultimately the better option Mar 17 18:37:18 Hornet: java is not really hard Mar 17 18:37:19 but I want it to actually work in the near future, not have a 'hello world' a year down the line Mar 17 18:37:22 how can I get specific package path for example /data/data/com.android.browser? Looking at some SO answers I came to conclusion that I shouldn't hardcode them and use context instead. Mar 17 18:38:04 I know js, php and python, java's syntax seems somewhat similar to all in various aspects Mar 17 18:38:18 Hornet: NO! just no Mar 17 18:38:27 helpful Mar 17 18:38:47 Hornet, see this Mar 17 18:38:50 https://sites.google.com/site/jalcomputing/home/mac-osx-android-programming-tutorial Mar 17 18:38:52 sorry, that last sentance gave me cancer Mar 17 18:39:08 thepoosh: anglioblastoma I hope Mar 17 18:39:16 lol Mar 17 18:39:24 thepoosh: I'm not wrong though Mar 17 18:39:44 php and java syntax are quite similar Mar 17 18:39:45 all programming languages (almost) look similar Mar 17 18:39:49 :S Mar 17 18:39:49 both inspired from C Mar 17 18:39:52 I've studied java before for OOP information that applies to the others Mar 17 18:39:57 Hornet: js isn't too far off, php is probably closer to C and python hardly has any resemblance other than being for programming Mar 17 18:39:58 chpo: why are you killing me Mar 17 18:40:09 thepoosh: it s only the syntax Mar 17 18:40:12 hmmm Mar 17 18:40:17 php is more like perl Mar 17 18:40:28 python actually can if you set it up to use braces rather than whitespace Mar 17 18:40:32 for me they are so different Mar 17 18:40:39 but most people aren't even aware that's possible Mar 17 18:40:46 because it's not Mar 17 18:40:50 see Mar 17 18:40:53 in the normal way of coding Mar 17 18:41:13 you need to customise the interpreter Mar 17 18:41:14 nothing wrong with managing everything yourself Mar 17 18:41:24 i prefer to do it that way Mar 17 18:41:27 ides cope well with brace scope, whitespace they get royally confused Mar 17 18:41:28 hey, does anybody know the team behind google keep? Mar 17 18:41:39 i don't even use xml layouts Mar 17 18:41:40 ultra-: no doubt, but that's only the best option if you already know most of what you're doing Mar 17 18:41:57 no i've started that way from scratch Mar 17 18:41:59 I'm an experienced webdev but know nothing about android events or api management Mar 17 18:42:13 if you can learn python you can learn java, it's not hard Mar 17 18:42:37 it's not hard, but it's deep Mar 17 18:42:47 especially when you consider the android part of it Mar 17 18:42:59 it's another learning curve that ultimately I might be able to avoid Mar 17 18:43:10 within tasker is almost ideal, other than state preservation Mar 17 18:43:10 or one that could be useful to you again and again Mar 17 18:43:19 potentially Mar 17 18:43:26 google keep devs? Mar 17 18:43:48 depends how well they pay them Mar 17 18:43:50 HURR Mar 17 18:44:08 well that was effective Mar 17 18:44:22 hmm Mar 17 18:44:33 well, I'll look into java, but it wasn't really the answer I wanted Mar 17 18:44:42 will mean every aspect of everything is a new learning curve Mar 17 18:44:49 yeah Mar 17 18:44:58 rather than simply the issue of state preservation Mar 17 18:45:00 Hornet: sorry, but it s the good answer Mar 17 18:45:01 as you learn one thing, it helps with learning others Mar 17 18:45:06 java will introduce you C syntax Mar 17 18:45:07 etc Mar 17 18:45:14 I know that from php Mar 17 18:45:20 and if I ever start doing C, someone shoot me Mar 17 18:45:23 great, apply it to java :) Mar 17 18:45:29 i like using C Mar 17 18:45:34 and i'm no programming guru Mar 17 18:45:35 someone shoot him, quick Mar 17 18:45:37 not even close Mar 17 18:45:40 C is awesome. Mar 17 18:45:43 i use it for microcontrollers Mar 17 18:46:03 * Hornet reaches for the shooting irons Mar 17 18:46:13 anyway Mar 17 18:46:17 c is the thing that spawned the syntax for all *GOOD* programming languages. :P Mar 17 18:46:19 * Fenny hides Mar 17 18:46:31 sssshhh i love coding in python Mar 17 18:46:37 * Hornet throws haskell and fortran into Fenny's hole and slams the lid Mar 17 18:46:47 althoguh i don't recommend it as a first language because you can be sloppy, i'd recommend something explicit like C Mar 17 18:46:56 * ohcibi stones Fenny with some rubies Mar 17 18:47:01 * Fenny trolls soooo good. :D Mar 17 18:47:11 wasn't even a 1/10 Mar 17 18:47:20 telegraphed it tbh Mar 17 18:47:21 * Fenny now waits for someone to correct his grammar. Mar 17 18:47:44 OH, snap didn't even phone it in. Mar 17 18:48:07 anyway, you're worried about the semantics of a language like raising events Mar 17 18:48:15 that's simple stuff to learn though Mar 17 18:48:21 interfaces in java for that Mar 17 18:48:23 no, I'm concerned about the details of that Mar 17 18:48:31 which are deep and full of pitholes, some rarely documented Mar 17 18:48:38 nah Mar 17 18:48:56 I actually do love ruby. ruby makes my wiggly bits just a bit less wiggly. Mar 17 18:49:03 TMI Mar 17 18:49:11 Hornet: the only resemblance between java and python is poor memory management Mar 17 18:49:14 haven't tried ruby but it sounds like a good time Mar 17 18:49:15 I've written AIs before, in any case, that part isn't actually remotely hard for me Mar 17 18:49:28 it's the android part that's new Mar 17 18:49:34 Hmm... maybe I have been doing it wrong. Mar 17 18:49:35 meh Mar 17 18:49:37 thepoosh: both are OOP which helps a great deal Mar 17 18:49:39 and not sure two learning curves at the same time is a great idea Mar 17 18:49:43 no it doesn't Mar 17 18:49:49 https://developer.android.com/reference/android/net/http/AndroidHttpClient.html#getUngzippedContent%28org.apache.http.HttpEntity%29 I understand this correctly that I can use getUngzippedContent even for non-gzipped responses, right? Mar 17 18:50:10 both are almost purely OOP which causes cyclic refs Mar 17 18:50:12 constantly Mar 17 18:50:18 Hornet: i learned C and python simultaneously so i could build midi controllers that work with ableton live... you can do it Mar 17 18:51:06 ultra-: simultaneously?! Mar 17 18:51:06 I don't doubt that I can do it, I'm questioning whether it's the best use of my time Mar 17 18:51:20 define "use of my time" Mar 17 18:51:21 especially as I won't be learning the GUI aspects so can't even reuse it for other apps later Mar 17 18:51:33 yeah more or less i learned them for the same project Mar 17 18:51:44 thepoosh: I have a very packed life Mar 17 18:52:05 so something like this means I'm not doing something that's more useful Mar 17 18:52:11 less talking more doing chop chop Mar 17 18:52:13 :) Mar 17 18:52:17 rather than missing a few episodes of rerun #2093 of House Mar 17 18:52:35 i've cut out TV almost completely Mar 17 18:52:51 why?! Mar 17 18:52:59 what's wrong with the blacklist?! Mar 17 18:53:07 mostly i don't find it to be that entertaining and i didn't watch much in the first place Mar 17 18:53:19 I have a TV but it's only hooked up to the htpc Mar 17 18:53:25 ^ same Mar 17 18:53:29 now i might turn on the science channel while i'm eating and watch whatever's on that... technically, right now at least, i don't even have a show i watch regularly Mar 17 18:54:11 The only thing to watch on a regular basis is BBC documentaries Mar 17 18:54:13 but lately i've been reading books while i eat instead Mar 17 18:54:32 All the rest can be mv'd to the "crap" folder Mar 17 18:55:21 darkDr0id: are you condescending us? Mar 17 18:55:36 no, you do that to yourselves I think Mar 17 18:55:37 the BBC made better things than documentaries Mar 17 18:55:41 Haha, no Mar 17 18:55:45 like the flying circus Mar 17 18:55:50 Just a personal opinion Mar 17 18:56:04 right, back in a while Mar 17 18:56:09 From time to time I watch something else but it always fails to keep my attention Mar 17 18:56:17 ty for assorted insights and insults, as applicable Mar 17 18:56:24 So I'll be doing something while it's playing in the background and I give it a glance from time to time Mar 17 18:56:40 so you have ADHD Mar 17 18:56:53 lol that's another reason i don't watch tv Mar 17 18:56:57 I have ADD and I love watching movies and TV Mar 17 18:56:59 i'ts hard to sit through a tv show Mar 17 18:57:14 there isn't much interaction so i get jumpy' Mar 17 18:57:15 Probably, also, more and more doctors and researchers are saying ADHD isn't a thing Mar 17 18:57:35 i think it's the lightest end of the autism spectrum Mar 17 18:57:39 I know it is, I've seen many kids with it that are on the moon without their drugs Mar 17 18:57:49 and it's not parenting that causes that Mar 17 18:58:04 drugs are about the worst thing you can give them Mar 17 18:58:10 ultra-, it can be comorbid Mar 17 18:58:21 I haven't been diagnosed but I would not be surprised at all if I fall at least somewhere on the light side of autism Mar 17 18:58:22 AS etc often is extreme focus on certain things tohugh Mar 17 18:58:22 Is it possible to treat a connected android device as connected to the local network, through usb? Mar 17 18:59:04 i was diagnosed with ADHD in the early 90's and i can become extremely focused on a certain thing Mar 17 18:59:24 my son has high functioning autism, and i see plenty of my quirks in him Mar 17 18:59:40 I recognize that, but then again, I guess a lot of people do Mar 17 19:03:08 alpha masking, how do i? Mar 17 19:12:42 https://medium.com/p/db854689243 Mar 17 19:26:01 http://pastebin.com/5SA7VQr9 anyone have any tips? Mar 17 19:27:12 JesperHead: yes, ask question Mar 17 19:28:48 thepoosh: its almost all in the pastebin. Animating an intro for an app. PNG has an alpha of 0.0 and want to "slide" the alpha mask to the right of each word sequentially, causing a "typed out" effect Mar 17 19:30:39 I have the png loaded, and set the alpha to 0 onCreate, but not sure where to go from there Mar 17 19:31:08 Does anyone know if it's possible to connect my phone to the local network via usb? Mar 17 19:31:26 In order to test an app that requires devices on the same network. Mar 17 19:32:31 heqs: you don't have wifi? Mar 17 19:32:35 heqs: http://www.youtube.com/watch?v=tvu33kshlSY theres THAT, dunno about using a desktop as a bridge (which I assume is what you're asking) Mar 17 19:33:20 thepoosh, the only wifi network I have is a strange university-wide one Mar 17 19:33:31 no no no Mar 17 19:33:34 that's bad Mar 17 19:33:43 what computer do you have? Mar 17 19:33:59 heqs: http://www.codeproject.com/Articles/191930/Android-Usb-Port-Forwarding meh? Mar 17 19:34:03 there are ways to broadcast wifi from laptops Mar 17 19:34:09 but listen to JesperHead Mar 17 19:34:25 yeah i have a desktop with a wifi adapter and i tried a couple of ways of making ad hoc networks Mar 17 19:34:47 and yeah is that the adb port forwarding stuff? i think i'll try that next Mar 17 19:34:48 Cannot resolve method loadBitmapFromView(andriod.widget.TextView) <--why not? it does in another class of mine Mar 17 19:35:08 oh it looks better, thanks JesperHead Mar 17 19:35:38 I don't know how effective it will be, that was quick google-fu. I suspect anything like that will be at best a "clever hack" Mar 17 19:35:42 I440r: Maybe that other class has a method called loadBitmapFromView...? Mar 17 19:35:51 ooh lol duh Mar 17 19:36:35 JesperHead, yeah i'll give it a go anyway, really sucks since if I was at home I could just use a normal wifi network but at uni we have authenticated ethernet ports and stuff which probably won't work with my router Mar 17 19:36:47 i wrote the other class about a year ago lol Mar 17 19:39:31 heqs: setup a wifi hotpost on your devie Mar 17 19:39:34 It also doesn't help that I'm using an Ubuntu VM for development which means i even have to do port forwarding from my Windows host machine to the dev vm Mar 17 19:39:35 and connect your computer to it Mar 17 19:39:53 mikedg: hmm didn't think of doing it that way round Mar 17 19:40:04 i do it all the time for network related testing Mar 17 19:40:29 yo, on the android interface, at the top left there are small pictures, ie, services running, like i have a bbc news one and a play store one. What are these called? and does anyone know of any good tuts ? Mar 17 19:41:16 They're called notifications Mar 17 19:41:26 Hi. I have android_studio running. How do I start the SDK tools (adb and fastboot)? Mar 17 19:41:30 notification icons? Mar 17 19:42:11 are you sure? my notifications are on a screen in blocks, Mar 17 19:42:19 the icons are notifications and indicative of services running I believe (and of course, of whatever they are notifying you of) Mar 17 19:42:20 and they dont show running services? Mar 17 19:43:41 The notifications small icon is shown in the status bar Mar 17 19:43:46 Not sure if a ticker text is required Mar 17 19:43:49 Try it out Mar 17 19:44:40 we have any android animators in here? Mar 17 19:45:04 mikedg, I'm being really dumb here but now I'm connected to my phone's portable hotspot how can I access the computer from the phone and vice versa? (e.g. what are the corresponding ip addresses?) Mar 17 19:45:13 I assumed that SDK was included in the AS tarball. Does SDK need to be imported somehow? Mar 17 19:45:26 you can look up the phones ip using adb shell netcfg Mar 17 19:45:36 i think wlan0 would be th eip Mar 17 19:45:48 ah cool, thanks Mar 17 19:45:53 (if your phone has a terminal app, you can type netcfg there too) Mar 17 19:45:56 ipconfig in the terminal on windows should give you the ip of the computer Mar 17 19:46:01 i forget what to use it a mac Mar 17 19:46:08 ifconfig i think for osx Mar 17 19:46:15 ifconfig Mar 17 19:46:59 mikedg, JesperHead: awesome, thanks guys Mar 17 19:48:49 yup yup Mar 17 19:51:47 Friends, romans, countrymen. Mar 17 19:52:02 I am unsure of how to appropriately implement my context within this snippet: http://pastie.org/8938982 Mar 17 19:52:11 any help would be great Mar 17 19:53:18 getResources is "undefined for the type EnemyList" - I know I need to utilise the context for this but I am confused as to how Mar 17 19:53:40 getResources is a method on the Context class Mar 17 19:53:52 So just call getResoureces on a Context instance Mar 17 19:54:26 the problem is, I am still getting the same when I use "public static void spawn(Context context)" to start the method Mar 17 19:54:44 shouldn't this pass the method? Mar 17 19:55:20 Not sure what you mean Mar 17 19:55:21 since ViewPager was included in the v4 support library but not the mainline android library in Ice Cream Sandwich, what is now the blessed way of doing ViewPager-like stuff going forward? Mar 17 19:55:40 zerowaitstate: By using the support library Mar 17 19:55:59 if you check line 11 of my code, attempting to input context as I put will still give me the same issue Mar 17 19:57:00 But you're not calling getResources on context Mar 17 19:57:26 ah I see Mar 17 19:57:28 thanks Mar 17 19:59:12 um, once last question: how do I call this in a static function? "EnemyList.spawn(getContext());" doesn't like static functions Mar 17 19:59:57 "Cannot make a static reference to the non-static method getContext() from the type View" Mar 17 20:00:19 learn2java :p Mar 17 20:00:35 getContext() isn't a static method, so you have to call it on an instance of View Mar 17 20:00:52 And yeah, a java tutorial might be a good idea Mar 17 20:02:28 When doing theme stuff, should I say [ parent="android:Theme.Holo" ] or [ parent="@android/style:Theme.Holo" ]? They both seem to work, and I found both in the documentation. Mar 17 20:03:27 Just select one of them Mar 17 20:03:28 Oops, that should be "@android:style/:Theme.Holo". Mar 17 20:03:37 -: Mar 17 20:03:39 Anyway. lol Mar 17 20:03:42 I use @android:style Mar 17 20:03:57 Wait, no I don't Mar 17 20:04:10 I use the other one Mar 17 20:04:28 Wonder if I'm consistent with that Mar 17 20:04:32 I'm reading one Android page that switched between them. Mar 17 20:04:34 http://developer.android.com/guide/topics/ui/themes.html Mar 17 20:05:27 Wait, it seems to use "android:" for themes and "@android:style/" for styles. Mar 17 20:06:21 Themes are just styles used for the android:theme manifest attribute Mar 17 20:06:25 There's no difference Mar 17 20:07:00 Would I ever encounter issues using "android:"? Mar 17 20:07:08 I like that it's shorter. Mar 17 20:07:17 Nope Mar 17 20:07:59 K. Mar 17 20:25:41 I've written fields a,b,c to a parcel, in that order. Do I read them c,b,a or a,b,c? Mar 17 20:26:43 does anybody know what eclipse is doing from the time that i compile to the time that it starts uploading my apk to device, does it really take around a minute to create an apk? Mar 17 20:26:54 finish compiling* Mar 17 20:28:01 icetooth: that doesn't seem unreasonable Mar 17 20:28:14 icetooth: what kind of computer do you have? Mar 17 20:28:44 q6600 cpu, but eclipse only uses 1 core during that period Mar 17 20:29:07 It's probably dexing Mar 17 20:29:26 that's an old cpu Mar 17 20:29:30 has anybody here worked with the facebook sdk on android? I am getting an error "100 link URL is not properly formatted" ... does anybody know how the links have to look like? Mar 17 20:29:37 many things only use one core Mar 17 20:30:20 sonOfRa: Parcel is a stream rather than a stack - so, a,b,c Mar 17 20:30:35 thanks, kbs Mar 17 20:31:15 i compile most of my code into a .so using the NDK, maybe that is being processed further, i'm not familiar with what dexing is Mar 17 20:32:18 or at least i think thats what it compiles too Mar 17 20:32:50 i'm just wondering if i can speed things up at all, and if thats normal behavior Mar 17 20:33:23 .so is a binary format (ELF probably). Dexing is converting java bytecodes to dalvik bytecodes, and some more stuff. If you are using the NDK there should be no dexing involved. Mar 17 20:33:36 Speeding up depends very much on what you are doing. Mar 17 20:34:52 icetooth: buy a new i-core cpu and be amazed at how much faster things are Mar 17 20:35:16 i have no money or i would :\ Mar 17 20:46:57 a question about this TabListener, http://pastebin.com/UTxs9P3i , why use FragmentTransaction.replace() instead FragmentTransaction.add() in. onTabSelected() ? Mar 17 20:48:50 Does anyone know the "proper" way to fix this gradle error I am getting in Android Studio? Should I move the joda-time-android project into my PatientIO directory? https://www.dropbox.com/s/8fsu36ht7cpnq5i/Screenshot%202014-03-17%2015.47.51.png Mar 17 20:53:48 Did you add it to settings.gradle? Mar 17 20:55:00 SimonVT: I did not. How exactly do I add it there? include ':lib:joda-time-android' ? Mar 17 20:55:27 Yeah, http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Multi-project-setup Mar 17 20:56:02 SimonVT: Success! Many thanks. Mar 17 21:18:47 looking for guidance drawing an invisible logo for an intro animation, then "sliding off" the alpha channel from left to right: http://pastebin.com/5SA7VQr9 Mar 17 21:19:23 revision: sliding off the "transparency" channel, so that what was once the background is now the logo Mar 17 21:20:11 I have a shared domain model between my REST server and the client in Android, both written in Java. On the Android side I extend the Java Domain model with Parcelable so I can pass it around between Services and Activities. The Domain Model also has Jackson annotations. Is it possible to deserialize from Jackson directly to these subclasses (they have exactly the same fields, except for the CREATOR Mar 17 21:20:11 )? Mar 17 21:22:52 One example: https://gist.github.com/sonOfRa/1e0b1d4304e24420cdf5 is the domain model, https://gist.github.com/sonOfRa/33925e063d7ab05f5116 is the android version with parcelable added Mar 17 21:25:17 Is it possible to connect to an android emulator on a host windows machine from within a linux vmware VM? Mar 17 21:27:14 Argh as well as ensuring the emulator can talk to the VM on a local network Mar 17 21:52:05 Does anyone know if it's possible to set the height of an ActionBar Tab? Mar 17 21:53:48 JGarrido: http://stackoverflow.com/questions/21110322/how-to-set-height-of-actionbar-tabs-for-android Mar 17 21:54:22 hmm, looking at that as we speak Mar 17 21:54:38 did you see http://stackoverflow.com/questions/13827762/actionbar-with-navigation-tabs-changes-height-with-screen-orientation as well? Mar 17 21:56:31 Yeah thanks, digging into that now to see if the bug was eventually squashed Mar 17 21:58:38 perhaps you could elaborate as to what problem you're having? Mar 17 22:00:24 Well I'm actually having the exact problem reported by the OP of that first link. I was able to implement a custom layout in order to get an icon in the tabs, but the problem now is there isn't enough padding in the tabs, so the text is overlapped by the indicator (as in that screenshot) Mar 17 22:01:13 I had attempted to resolve it by setting heights and paddings within the layout, but nothing seemed to help, so apparently I've been going about it the wrong way (Android dev noob) Mar 17 22:02:51 I've got API min level set to 7, but it looks like I'll need to bump it up to 13 to make this happen, which is a bit of a bummer. Mar 17 22:06:37 eh Mar 17 22:07:08 Make it minSdk=15 Mar 17 22:07:10 well I was hoping to be able to support as far back as Gingerbread, but maybe now Mar 17 22:07:11 dont stress it, I personally think its time to start transitioning to 4.0 Mar 17 22:07:11 *not Mar 17 22:07:17 13 and 14 are not worth it. Mar 17 22:07:39 well kakazza, depending on what his app does, if he CAN support it, why wouldn't he? Mar 17 22:08:15 Because 14 introduces shitloads of new APIs and both 13 and 14 are ≤0.1% of the market. Mar 17 22:08:51 While ≥15 is around 80% Mar 17 22:09:10 correct, but if it's a simple app that doesn't use these new apis... might as well... Mar 17 22:09:48 Yeah, I'll need to take a look to see if I'll want to leverage those newer APIs, it's very possible Mar 17 22:10:15 JesperHead: Yeah, might aswell skip them and go for 15, exactly :p Mar 17 22:10:22 I'll just make notes as I go along, whenever I run into something (like this) that would require me to bump up the min Mar 17 22:10:37 10 I'd understand, 14 (or 15) I understand, but 13, no. Mar 17 22:10:46 herp a derp. It's quite simple. Code as normal for 13/14. If you run into problems using an api not supported, bump her ump. Mar 17 22:10:47 Let's pretend Honeycomb doesn't exist. Mar 17 22:10:57 up* Mar 17 22:11:11 what are min cpu/ram requirements for android sdk vdi device testing? Mar 17 22:11:14 yeah honeycomb was a joke, but again, if you're not using these apis, there is no reason not to Mar 17 22:11:15 Yeah, I think even the Xoom was eventually upgraded Mar 17 22:12:04 krast what are your computer specs Mar 17 22:14:42 JesperHead: Read what 3.2 (API level 13) has to offer as "new" and what 14/15 offer. It's a no brainer, considering API Level 13 will probably disappear completely the next time the chart is updated. Mar 17 22:15:06 Not worth the three extra users you can expect. Mar 17 22:15:36 Anyway, I'm off. Mar 17 22:16:28 it would have been nice if they supported exclusion ranges :) for a while, i would have said minSdk = 9, but exclude HC, and everything else above that is OK :) Mar 17 22:24:31 yuck Mar 17 22:24:34 that's nasty Mar 17 22:24:36 14+ Mar 17 22:24:38 seriously Mar 17 22:24:41 it's not rocket science Mar 17 22:24:41 there's no reason to exclude HC Mar 17 22:24:42 it's 14+ Mar 17 22:27:19 hmm, in an activity, how do I detect that my content view has layed out? Mar 17 22:27:57 i dont recall a elegant solution. usually post a runnable after setContentView to do what needs to be done afterwards Mar 17 22:28:46 yeah, that's lame Mar 17 22:30:09 not to mention, the event immediately after setContentView has not yet laid out Mar 17 22:31:04 I guess I can just make it run in onResume Mar 17 22:31:06 yuck Mar 17 22:50:03 does vdi does translating instructions set from arm to x86 or just virtualizing x86 Mar 17 22:52:42 im having problems with a 9 patch drawing a black where it should be transparent Mar 17 22:52:50 do entries have to be in any particular order? i keep seeing things in different places implying that Mar 17 22:53:11 its a chat bubble and everything below the bubble to the left and the right of the dangly bit is drawn in black and it should be transparent Mar 17 22:53:20 in the gimp its transparent Mar 17 22:53:54 can someone help me figure out why? Mar 17 22:54:04 hey guys. Got a funky problem Mar 17 22:54:10 my app seems to be getting false resume events Mar 17 22:54:26 I'll turn off the screen and hear that my video has stopped playing, which I do on pause Mar 17 22:54:31 on resume, I start playing back Mar 17 22:54:45 however, while the screen is off I will occasionally get an on resume and so I can hear the video playing Mar 17 22:55:00 wondered if this is somewhat common and if there is a particular best solution Mar 17 22:57:16 interesting. you logged the resume events to make sure the player wasnt starting some other way ? Mar 17 22:58:16 yes Mar 17 22:58:31 well Mar 17 22:58:40 in that the only resume-playback code happens in that Mar 17 22:59:03 there is an extra piece to this Mar 17 22:59:15 when I pull down the system menu, it sends pause and resume events Mar 17 22:59:20 which feels kind of strange Mar 17 22:59:31 would prefer for the playback to continue since the application wasn't really backgrounded Mar 17 23:00:41 so maybe I should be doing onStart and onStop instead Mar 17 23:01:02 but those may not be called when the app is backgrounded, right? Mar 17 23:01:17 why do you use enter so much :( Mar 17 23:02:03 Hehe. Sorry for the wall of text. Mar 17 23:03:22 ProgramMax yeah , try onStart / onStop Mar 17 23:12:22 can someone please explain to me why the transparent areas of my 9 patches are being drawn in black? Mar 17 23:13:21 I440r maybe try loading them in the 9-patch tool instead of gimp Mar 17 23:13:24 * g00s dunno Mar 17 23:13:30 i hate those things too :) Mar 17 23:14:05 theoretically, you can use any tool as long as you put the markers in the right places Mar 17 23:14:09 i have a 9 patch tool in intellij and in that they are drawn right Mar 17 23:14:38 ugh. /me shoots self in foot Mar 17 23:14:39 9-patch is one heck of a strange way to do things Mar 17 23:14:49 like, when do programmers ever open an image editor? Mar 17 23:14:53 rgb 565 doesnt have an alpha channel lol Mar 17 23:18:18 http://www.businessinsider.com/syndromes-drive-coders-crazy-2014-3 Mar 17 23:20:19 9 patch is very efficient Mar 17 23:32:48 hi Mar 17 23:32:55 is it possible to create this: http://share.thomas-peterson.de/Ungesichertes%20Vorschau-Dokument-2XGOfPm4nt.png Mar 17 23:33:04 with an swipe gesture ? Mar 17 23:33:17 left 1 day back right 1 day forward ? Mar 17 23:34:05 Napalm :) Mar 17 23:36:00 Napalm i think this is also part of the problem https://training.kalzumeus.com/newsletters/archive/do-not-end-the-week-with-nothing Mar 17 23:36:24 i guess it ties into point #1 though - credibility in the field requires proof , many times Mar 17 23:36:48 I did it. I set minSdkVersion to 14. Mar 17 23:36:58 so you're always working on stuff to show people just so they don't suspect an impostor :) Mar 17 23:37:10 AMA? Mar 17 23:37:12 TacticalJoke may as well do 15. 14 was an anomoly Mar 17 23:38:25 Hi g00s Mar 17 23:38:56 One of the last times I was on here, I remember you being here g00s :) Mar 17 23:39:04 hi markyosullivan Mar 17 23:39:10 Got a couple of questions guys, wondering if people can answer them Mar 17 23:39:17 i'm probably more crazy now though Mar 17 23:39:23 It's just questions regarding what's possible for Android apps Mar 17 23:40:00 1. Is it possible to connect to another Android device, then choose to disable app 'x' or lock the entire device? Mar 17 23:42:28 markyosullivan: yes Mar 17 23:42:54 g00s: nice article, skimmed the major points, will read it in full later, Mar 17 23:42:55 Napalm, could you link me to an app which already does this? Just interesting to find out how it works Mar 17 23:43:22 Napalm also what methods would be needed to do this? Mar 17 23:43:28 markyosullivan: http://developer.android.com/guide/topics/admin/device-admin.html Mar 17 23:44:03 markyosullivan: https://github.com/android/platform_development/blob/master/samples/ApiDemos/src/com/example/android/apis/app/DeviceAdminSample.java Mar 17 23:45:29 Brilliant thanks. Could you explain just what you have linked me to Napalm? Mar 17 23:45:35 Hey can anyone explain to me why when I inflate a single LinearLayout for my ListView adapter in getView() I'm not seeing the views background as red, even though I set it with android:background="@color/red" ? Mar 17 23:47:18 Mentos: did you specify a parent when inflating and what version of Android are you testing this on? Mar 17 23:47:33 Napalm: I just added a textview to it with some text and now it starts showing the red background Mar 17 23:47:41 but only behind the text Mar 17 23:48:05 take a screenshot Mar 17 23:48:28 is the layout set to match parent for width and height? Mar 17 23:48:38 or only wrap content? Mar 17 23:49:01 birbeck: fill_parent for both Mar 17 23:49:30 birbeck: i guess i need to give it a hard width/height if its going to be empty Mar 17 23:50:01 Mentos: incorrect Mar 17 23:50:17 set a android:minHeight Mar 17 23:50:30 and your TextView can have a android:minLines="1" Mar 17 23:51:05 Mentos: why dont you gist or pastebin your layout that you inflate Mar 17 23:53:49 Napalm: so i originally just wanted to create a LinearLayout with 3 sub linear layouts and color each a different color Mar 17 23:54:12 Napalm: but found nothing was drawing, so i tried just creating 1 in red Mar 17 23:55:03 Napalm: I'm guessing that if you just provide a LinearLayout with fill_parent for width/height and red for background its still going to be empty? Mar 17 23:55:27 yes because list items are forced wrap_content for height Mar 17 23:55:30 you need to set a minHeight Mar 17 23:55:59 Mentos: remember match_parent/fill_parent doesn't make sense in a ListView Mar 17 23:58:50 Napalm: k thanks Mar 18 00:04:36 Napalm: I'm trying to nest 2 sub LinearLayouts now, one black, one red yet not seeing anything http://pastebin.com/sMZY01TF Mar 18 00:05:01 is that again because i don't have min widths/heights Mar 18 00:05:34 no Mar 18 00:06:14 and i'm trying to have the views be left/right of each other Mar 18 00:07:54 Mentos: http://pastebin.com/7LHuRG2j Mar 18 00:08:30 so without a layout_weight they won't "compete" ? Mar 18 00:09:50 yea i added only the layout_weight to my code and it now shows half red/half black Mar 18 00:10:15 interesting, i thought they would have 'competed' on their default values Mar 18 00:10:38 but i guess they were both representing 0 parts of 0 Mar 18 00:10:44 instead of now, 1 part of 2 Mar 18 00:33:43 might anyone know why android:layout_gravity="center" isn't working to center my textView's text yet textView.setGravity() is working when i call it programmatically? Mar 18 00:34:42 <7JTAABRMY> android:layout_gravity is an instruction for the parent view, android:gravity is for the view itself Mar 18 00:35:01 <7JTAABRMY> so setGravity does the same as android:gravity Mar 18 00:36:08 7JTAABRMY: ah thanks Mar 18 00:36:23 are list adaptors run in their own thread away from the UI thread? Mar 18 00:36:38 (meaning, if I do network calls, will I get a networking in main thread exception?) Mar 18 00:44:41 Mentos: because its android:gravity="center" for TextView Mar 18 00:44:51 ah, someone already answered Mar 18 00:45:27 Hi all, can someone look at this code? I get many errors in the keys, at first glance I see that all is well. Mar 18 00:45:33 http://pastebin.com/Lm0vsHq1 Mar 18 00:46:01 Hi, What's up people? Mar 18 00:47:54 what is an array in javascript to an array in java Mar 18 00:48:01 is it equivalent to an arraylist? Mar 18 00:49:01 ... Mar 18 00:50:17 nvm just going to turn it into a json Mar 18 00:51:57 please check my link Mar 18 01:03:46 If I am using a custom object in a list like so ArrayList list... how can I go about passing in a JSONObject? gives me an error currently... because the types don't match but... how do I fix that Mar 18 01:20:19 anybody help me??? Mar 18 01:27:20 b0ts don't need help, silly Mar 18 01:27:38 shut up Mar 18 01:27:42 big nerd Mar 18 01:28:27 maybe '.r help' ? Mar 18 01:29:14 b0t isn't on the ban list yet? Mar 18 01:29:40 :) Mar 18 01:29:42 and it's interesting that anyone on IRC uses "nerd" as an insult Mar 18 01:29:59 ya lol Mar 18 01:33:43 oh wow, OneNote free on the mac :D Mar 18 01:35:08 dang, 10.9 and above :| grr, need to update sometime Mar 18 01:35:58 g00s: say something bad about apple and good about android I dare you! Mar 18 01:37:24 i'm mostly unbiased with apple; i never bought into their ecosystem. i have no apps, itunes stuff, or anything. i dont have an iPhone either, but an iPod touch Mar 18 01:37:25 hey guys if I am passing this in https://gist.github.com/anonymous/9611960 and this is the custom object receiver http://pastebin.com/jBa1aGMg you guys see anything wrong... because I keep getting expect object but got an array... Mar 18 01:37:33 LoneSoldier728: Type objectType = new TypeToken>() {}.getType(); gson.fromJson(blah,objectType); Mar 18 01:38:26 that was quick Mar 18 01:38:34 so what I need to wrap it with collection? Mar 18 01:38:36 i was answering your previous question Mar 18 01:39:00 oh well I kind of fixed that in the new one Mar 18 01:40:23 for some reason pastebin is down... is it down for you Mar 18 01:40:41 ill make a gist with the new way I am doing it... but I am unsure how to take in the array... because now that seems to be the problem Mar 18 01:41:13 are you using gson ? Mar 18 01:41:28 retrofit which uses it i believe Mar 18 01:42:25 any idea how to create beautiful layouts? :( Mar 18 01:42:35 eclipse doesn't seem to be the best thing for doing that.. Mar 18 01:42:44 so bankai_ https://gist.github.com/anonymous/9612016 Mar 18 01:43:00 there are more fields I just didnt want to include so many fields Mar 18 01:43:21 if you're using GSON you don't need to do all that Mar 18 01:43:30 but the keys match... I have a feeling it cannot take in arrays... Mar 18 01:43:51 yeah it uses it by default from what I see Mar 18 01:44:04 so how do I make sense of that data Mar 18 01:44:08 why are you playing with JSONArray and JSONObject then Mar 18 01:44:24 Well I thought I can only pass back objects Mar 18 01:44:26 Also, Im looking to hire an android developer who's good with UI, UX and has experience or can develop apps with XMPP and Location services. If anybody is interested, and think they fit the bill, feel free to PM me. Mar 18 01:44:28 and not arrays of objects Mar 18 01:44:39 ughlol: not in here ... Mar 18 01:44:50 bankai_: where can I find devs? Mar 18 01:44:58 i don't know/care, read teh topic Mar 18 01:44:58 not in irc chats... Mar 18 01:45:03 LoneSoldier728: use lists and objects Mar 18 01:45:14 org.json is an abomination Mar 18 01:46:38 kk, but the problem I am having... I guess maybe I do not understand it well enough... but if I am sending an array how do I make sense of it in the retrofit callback since the callback calls the ObjectResponse Mar 18 01:47:13 Do I just build a constructor with a list Object that takes the ObjectResponse as a parameter Mar 18 01:47:44 Gson doesn't use constructors. Mar 18 01:48:33 I didn't understand the rest Mar 18 01:49:20 well basically getting this error from retrofit BEGIN_OBJECT but was BEGIN_ARRAY at line 1 column 2 Mar 18 01:49:48 and I am passing in an object that contains an array like so https://gist.github.com/anonymous/9611960 Mar 18 01:50:13 What is "passing in"? Mar 18 01:50:18 And to whom? Mar 18 01:50:53 well from my server-side nodejs I am sending the results back and I can send it as an object or an array Mar 18 01:51:06 and trying to use it in the retrofit callback Mar 18 01:51:41 That error is from Gson. It's never making it to the callback. Mar 18 01:52:50 You're telling it to deserialize an object when the JSON has an array Mar 18 01:52:56 right so I am trying to figure out how to http://stackoverflow.com/questions/8371274/how-to-parse-json-array-in-android-with-gson is this essentially it Mar 18 01:53:28 List Mar 18 01:54:26 Gson will handle it. Mar 18 01:55:53 ok where do I need to specify the list... in the retrofit callback or before it somewhere else? (objectresponse) Mar 18 01:57:29 I don't know what your response looks like. If it's a list of objects then use a List. If it's an object with a list put a List inside that object's type. Mar 18 01:58:25 Maybe you should just play around with Gson by itself with its docs to figure out how it works. It maps the JSON to Java directly so your type structure has to be identical. Mar 18 01:59:19 right ok, yeah I think I need too, what was throwing me off too, is if something is passed as a jsonarray if it can just be used as a list Mar 18 01:59:43 Right. Mar 18 02:02:17 how was the earthquake btw Mar 18 02:02:41 Not large enough to feel, apparently. When was it? Mar 18 02:03:10 and more important, where was it? Mar 18 02:03:11 in the morning I think, saw it all over facebook, and a video of a news studio being shaken Mar 18 02:03:20 Cali, san fran I think Mar 18 02:04:50 nvm good night Mar 18 02:07:07 4.4 outside LA Mar 18 02:07:10 Tiny Mar 18 02:10:43 really you should see the video of the studio that felt it hard Mar 18 02:10:54 news studio* Mar 18 02:18:52 Do you folks use CharSequence in general APIs? Mar 18 02:19:36 String seems easier, but I wonder whether CharSequence should be used sometimes. Mar 18 02:21:01 TacticalJoke: For UI, yes Mar 18 02:21:20 TacticalJoke: only way to preserve spans Mar 18 02:21:38 Okay. What if you're making a class that's conceptually general-purpose? String in that case? Mar 18 02:21:56 I have a class that corrects the grammar of user input. It's being used in my UI only, but the concept isn't restricted to UIs. Mar 18 02:27:27 hey, i'm jason too Mar 18 02:27:46 Hmm. StringBuilder doesn't override Object.equals. Mar 18 02:28:58 So if an API returns a CharSequence then you might have to use returnValue.toString().equals, anyway. Mar 18 02:30:09 no you are Mango_Man :) Mar 18 02:30:28 It's Dr. Mango and Mr. Jason Mar 18 02:30:43 Mr. Jason Phd to you :P Mar 18 02:31:35 * imjason is done programming for today Mar 18 02:32:08 hmm, if you use a sqlite database, does that data get deleted when the app gets uninstalled? Mar 18 02:32:22 yes Mar 18 02:32:31 it gets stored in the apps data folder Mar 18 02:32:33 which gets blown away Mar 18 02:32:34 not necessarily Mar 18 02:32:48 lame...guess storing data on the network is the best choice Mar 18 02:33:02 JesusFreke: I am intrigued Mar 18 02:33:02 in the clouds ? Mar 18 02:33:06 Using String seems way easier. Mar 18 02:33:13 it depends on how it's uninstalled Mar 18 02:33:20 fair enough :) Mar 18 02:33:22 see the -k flag for adb uninstall Mar 18 02:34:14 somehow I dont think his users are using adb to uninstall his application :) Mar 18 02:34:19 but then I do not know :) Mar 18 02:34:33 JesperHead: best, can you help me? Mar 18 02:34:38 JesusFreke: Mar 18 02:34:41 sorry Mar 18 02:34:47 hehe Mar 18 02:34:52 was like "wutttt" Mar 18 02:35:23 b0t: I cannot Mar 18 02:35:32 lol Mar 18 02:35:37 hacker Mar 18 02:36:49 hello, someone who can look at this code, I just need to correct a single error, and could finally finish it. Mar 18 02:36:58 http://pastebin.com/vgiup7Ka Mar 18 02:37:04 what's the "single error" / Mar 18 02:37:16 is b0t a real person? Mar 18 02:37:25 Server server = 0x0; -------------------> FAILED Mar 18 02:37:33 i really do wonder sometimes :S he's a major spammer, so probably not Mar 18 02:37:41 check this Mar 18 02:37:44 lovely, a penis Mar 18 02:38:42 i need the value 0x0 Mar 18 02:39:38 the server is stored in the database and then I need to call it by its id Mar 18 02:40:04 take a step back, think hard, then ask a proper question Mar 18 02:40:46 ok, you've seen the code? Mar 18 02:41:22 was that your 'proper question' ? Mar 18 02:41:58 /clear Mar 18 02:46:00 b0t: are you trying to make your own irc app ? Mar 18 02:46:24 yeah right Mar 18 02:47:04 not sure if that's sarcasm Mar 18 02:50:45 ok Mar 18 02:54:58 o_O **** ENDING LOGGING AT Tue Mar 18 02:59:58 2014