**** BEGIN LOGGING AT Thu Aug 23 03:00:00 2012 Aug 23 03:01:09 SimonVT: is a child View's size and position determined by onLayout or onMeasure? Aug 23 03:02:13 It's the size you pass in View.layout(..) Aug 23 03:02:24 Whether it messes up if you don't measure it at the same size, I don't know Aug 23 03:02:52 SimonVT: yeah, that's what i'm kinda seeing Aug 23 03:03:06 the child View is a RelativeLayout set to match_parent Aug 23 03:03:27 seems it doesn't draw properly when i reduce the width and change the position Aug 23 03:03:36 unless i gotta do something like invalidate? Aug 23 03:03:45 i doubt that though, layout should do it.. Aug 23 03:05:18 Try it, see what happens Aug 23 03:06:52 SimonVT: invalidate doesn't change behaviour Aug 23 03:07:00 the View is being moved the left as required Aug 23 03:07:14 but if I reduce the width, it doesn't seem to draw the View completely Aug 23 03:07:29 if I leave the width as is, because I've moved it ot the left, the view is cutoff Aug 23 03:07:57 basically, i need to move it to the *right* actually, and account for the change in width by the same amount Aug 23 03:09:04 So try and measure it at the new size Aug 23 03:09:21 do I have to override View.onMeasure? Aug 23 03:09:29 or can I do that from ViewGroup.onMeasure? Aug 23 03:09:47 You pass a measurespec to View.measure Aug 23 03:09:55 It can have a width and height Aug 23 03:15:32 Anybody know what percentage of major Android devices don't support Google Maps (like Kindle Fire and Nook Color)? Aug 23 03:16:44 Anyone without play store probably Aug 23 03:19:51 hey all. Aug 23 03:20:37 Wth, I'm not being able to start adb on the netbook (linux), I always get cannot "bind 'tcp:5037'" with my user or root... and nobody is taking the port... Aug 23 03:20:41 has anyone ever had that? Aug 23 03:25:28 FIrewall? Aug 23 03:26:11 A firewall would.... well, wait Aug 23 03:26:27 shouldnt matter though since you arent leaving the comp Aug 23 03:26:29 Nope, good idea, but it's all in accept Aug 23 03:26:39 Then is it 64 bit? Aug 23 03:26:44 ubuntu Aug 23 03:26:46 Nope, it's 32 bit Aug 23 03:26:50 hmmmmmmm Aug 23 03:26:51 well the machine is.... Aug 23 03:27:08 And, adb is 32 bit too. Aug 23 03:27:17 it's exceedingly odd Aug 23 03:27:49 yea That is weird Aug 23 03:28:27 hmmm let me see.... Aug 23 03:28:33 http://ubuntuforums.org/showthread.php?t=1652877 Aug 23 03:28:35 oh Aug 23 03:28:38 wtf... Aug 23 03:29:04 interface lo was down Aug 23 03:29:08 lol Aug 23 03:29:09 :/ Aug 23 03:29:10 wow Aug 23 03:29:11 oh well Aug 23 03:29:15 first time I see that Aug 23 03:29:20 righttttttttttttt Aug 23 03:29:24 I never have haa Aug 23 03:29:41 thanks for helping me figure it out Aug 23 03:29:46 no prob Aug 23 03:30:06 Now I need to solve my phone trouble, but that's more of a root than a dev, and I'll try myself Aug 23 03:30:09 thanks Aug 23 03:30:17 I will come back though, when I dev my first ppa Aug 23 03:31:49 rooting it pretty easy nowadays Aug 23 03:32:15 hello, I create a custom view, if I just add to a relative layout, it shows properly. But I put several of my custom views into linear layout, none of them show. Did I miss something that I have to implement for the view? Aug 23 03:32:33 I implement onDraw and onMeasure only Aug 23 03:34:27 http://stackoverflow.com/questions/4439456/how-to-create-a-simple-custom-view Aug 23 03:34:31 idkau: It's rooted, and pretty much has lost all it's virginity since the second day I had it. Aug 23 03:34:54 nice lol. I am too lazy to root mine. I guess I havent had a need to yet. Aug 23 03:34:54 idkau: I was pretty much fighting a problem with app2sd Aug 23 03:35:06 ohhhh Aug 23 03:35:27 idkau: er…are u answering my question? Aug 23 03:35:38 see you all latter. Aug 23 03:35:39 It seems to have the answer. Aug 23 03:35:43 later Aug 23 03:36:03 The views werent showing in a linearlayout Aug 23 03:38:04 idkau: er…but I don't know how they solve it Aug 23 03:40:05 to update an application do I have to upload another apk and deactivate the old one? Aug 23 03:40:11 Looks like you have to create constructors Aug 23 03:40:17 yes mad Aug 23 03:40:25 deactivate first Aug 23 03:40:47 after you upload it though LOL Aug 23 03:41:04 if you try to activate more than one it will yell at you. Aug 23 03:53:18 hey, serious question, who here has string literalls littered through out their code, and who has all their would-be string literals as const vars? Aug 23 03:55:46 like this? Toast.makeText(this, "Saving Client...", Toast.LENGTH_SHORT).show(); Aug 23 03:59:34 Nvm I was thinking PHP Aug 23 04:11:03 hey guys im having a problem with a handler object. It waits to till after my thread runs to run the handler. can someone please look and tell me whats up with this? Aug 23 04:11:05 http://pastebin.com/pysBW1q9 Aug 23 04:11:50 idkau, ya Aug 23 04:11:56 or just anything Aug 23 04:12:05 Ya I do Aug 23 04:12:22 I put most in vars though. Aug 23 04:12:32 you'll almost NEVER see "something" in the body of my methods. They either get pulled from string files, or are static final strings in the class def Aug 23 04:12:49 i thought that was standard, but im seeing a lot of code where thats not the case Aug 23 04:12:51 its probably proper lol Aug 23 04:13:24 Im still considered a newb though. Aug 23 04:13:44 I have been using Java for about 20 weeks now and Android API for 2 weeks. Aug 23 04:15:06 can some ppl help? I think my custom view onMeasure is working, but I don't know why it doesn't draw anything Aug 23 04:18:48 hello Aug 23 04:22:09 hey peoples, i'm trying to determine when a user has scrolled to the bottom of a webview. Webview provides getContentHeight(), but this seems to be consistently 75-77% smaller than the actual scrollable view Aug 23 04:27:31 how do i make html5 video play in browser not in video player Aug 23 04:30:15 allballs: not sure if you care, but i've kind of blown the lid off this NSURLConnection thing. turns out tons of apps suffer from this, and you can actually find reproducible little use cases all over iOS apps. Aug 23 04:30:31 especially funny when you look at the very same apps and user flows between iOS and Android. iOS is clearly much slower due to this stupidity. Aug 23 04:30:49 err that was to alankila Aug 23 04:31:15 why do they say don't use the NDK unless you have to ? Aug 23 04:32:54 there are a lot of reasons. the most significant in my book is the tendency some individuals have to micro-optimize code they don't even know to be causing bottlenecks, all while ignoring the drawback of portability. Aug 23 04:33:13 shmooz: because it makes your code less portable, and potentially less robust Aug 23 04:35:12 you know when ANSI C came out it was supposed to be portable across systems Aug 23 04:35:59 Posix 1 compatible Aug 23 04:36:20 seems like java reinvented the wheel Aug 23 04:37:22 shmooz: the portability is in binary distribution, which was not a problem C attempted to combat. Aug 23 04:37:23 um, portable 'binary' Aug 23 04:39:29 I guess a JIT C compiler would have taken too long to compile Aug 23 04:39:56 shmooz: are you suggesting that developers distribute their app source code to users? Aug 23 04:40:17 can anyone recommend on hardware? Aug 23 04:40:27 port-er: nexus, always the nexus. Aug 23 04:40:40 jasta a laptop Aug 23 04:40:52 port-er: you're asking us which laptop to buy? Aug 23 04:41:00 that would have been a nice side effect Aug 23 04:41:09 forcing everything to be open source Aug 23 04:41:10 jasta for a graphic designer Aug 23 04:41:26 shmooz: ...please stop trolling. Aug 23 04:41:29 port-er: go away Aug 23 04:41:51 port-er: or, you're way off topic. Aug 23 04:41:57 he's gone... Aug 23 04:42:04 usually that doesn't work so well Aug 23 04:42:08 let's try it again Aug 23 04:42:10 shmooz: go away Aug 23 04:42:29 thats not nice Aug 23 04:42:39 I was just thinking Aug 23 04:42:45 rats. Aug 23 04:48:12 hmm, http://telehash.org/ Aug 23 04:49:13 in an actionmodeCallback onActionItemSelected, how can I reference the overall activity's class that is implementing LoaderManager.LoaderCallbacks ? Aug 23 04:49:41 I have a fragment which contains an actionmodecallback, and I want to restart a loader the fragment has, from inside the callback. Aug 23 04:51:35 oh, maybe i solved it. Aug 23 04:56:21 anyone here know about handler objects? Aug 23 04:56:32 or threading? Aug 23 05:00:13 kingargon: most of us, yes. Aug 23 05:06:46 kingargon: were you doing a survey on levels of handler/threading knowledge amongst the #android-dev community? Aug 23 05:08:38 no i just need to know why my handler is running after my thread executes :) Aug 23 05:08:42 Well, I'm not great at threading needles, but I know the general theory. Aug 23 05:08:59 well handler.post Aug 23 05:09:02 kingargon: can you give a code sample that demonstrates it? Aug 23 05:09:25 http://pastebin.com/pysBW1q9 Aug 23 05:09:58 so what exactly is happening? Aug 23 05:10:34 the handler inside the record thread does not run untill long after the recording and playback threads die Aug 23 05:11:00 like something is blocking it. Aug 23 05:11:08 you mean textViewHandler? Aug 23 05:11:17 yup Aug 23 05:11:42 it looks to me like textViewHandler is on the UI thread Aug 23 05:12:07 let me make sure I'm not crazy first Aug 23 05:12:31 right, the docs said to use the handler.post method to communicate between threads Aug 23 05:13:16 right, but on the UI thread, you're spawning a second thread that only sends something back to the UI thread... Aug 23 05:14:04 s/only sends/sends/ Aug 23 05:14:47 so i need to create the button object within the thread? Aug 23 05:14:51 so startBtn.setText("Recording!"); isn't gonna get executed until the UI thread is done whatever it's doing Aug 23 05:15:03 onClick is already on the UI thread Aug 23 05:15:08 just put startBtn.setText("Recording!"); in there Aug 23 05:21:41 okay. so that didnt seem to have much an effect. Aug 23 05:21:54 what does the code look like now? Aug 23 05:22:45 i dropped startBtn.setText("Recording"); into the onClick method Aug 23 05:23:52 http://pastebin.com/xHfgfutZ Aug 23 05:24:06 what happens now? Aug 23 05:24:16 OH Aug 23 05:24:22 you're doing recThread.run Aug 23 05:24:31 you need to do recThread.start() Aug 23 05:25:22 never call the run method directly on a Thread, it won't spawn a new thread if you do Aug 23 05:26:33 what about join()? Aug 23 05:27:29 I'm surprised it's not an error to call join() on a Thread that hasn't been started yet, but looking at the source it's not. Aug 23 05:27:56 your use of join is correct, but pointless. Aug 23 05:28:18 in fact, your use of threads is totally pointless Aug 23 05:28:43 since you wait for the thread to complete before you do anything anyway Aug 23 05:29:47 still nothin Aug 23 05:29:48 http://pastebin.com/SziPBSEr Aug 23 05:30:40 kingargon: what's happening, and what do you want to happens? Aug 23 05:30:43 *happen Aug 23 05:31:35 (I don't do audio work, so I have no idea if your audio code is correct) Aug 23 05:32:05 wait i commented out the join(s) and it switches but now its not recording Aug 23 05:32:23 it does record and playback Aug 23 05:32:29 well it did lol Aug 23 05:33:19 okay i pressed the button again and it plays back than crashes out Aug 23 05:34:07 you're not synchronizing it at all and you're trying to record and play simultaneously Aug 23 05:34:11 that's not gonna work Aug 23 05:35:44 should i use asynch? Aug 23 05:36:07 I think what you ACTUALLY want to do is have most of the code run in a background thread and post updates to the UI Aug 23 05:37:18 keep in mind that the UI will block until onClick returns Aug 23 05:37:49 what do u mean background thread? Aug 23 05:42:31 kingargon: you want to let onClick return so that your UI doesn't freeze Aug 23 05:44:14 have a look at http://www.vogella.com/articles/AndroidPerformance/article.html Aug 23 05:44:24 it explains a bit about threading on Android Aug 23 05:50:18 cool thanks! Aug 23 06:15:14 hello Aug 23 06:15:33 i want to send the time as universal like if india has current time 10:00 pm then it should be send.But if i increase the time manually from settings and then try to get the time then it will give me increamented time.I want the default india's time.so how can i get that time? Aug 23 06:30:20 So I googled for a while out of sheer interest, and feel the answer is probably obvious, but if all communication with telephony happens through RIL, how do BT headsets get past this, does the audio stream go to the chipset directly? Aug 23 06:30:27 *baseband. Aug 23 06:32:01 any suggestion for a JSON parser lib :? Aug 23 06:32:12 tagrudev: use the one in Android already. Aug 23 06:32:28 org.json Aug 23 06:32:41 http://developer.android.com/reference/org/json/package-summary.html Aug 23 06:33:01 pft. real developers write their own json library. Aug 23 06:33:03 directly in smali. Aug 23 06:33:08 ;) Aug 23 06:33:08 yeah I use it now anything else ? Aug 23 06:33:22 why would use something else ? Aug 23 06:35:23 api -> returns json object and json arrays depends on the set of records Aug 23 06:35:32 array* Aug 23 06:36:16 with org.json I need to know exactly what type of response I will get to parse it Aug 23 06:37:51 JesusFreke: I have an OCaml framework similar to smali being released in the next few days. Aug 23 06:37:57 :-) Aug 23 06:39:16 hah :) Aug 23 06:39:34 never looked at it (caml) Aug 23 06:40:03 so any suggestions ? Aug 23 06:41:17 It's been a while since I've looked at any json. Maybe you could encapsulate it in a wrapper object (textually), so that you always have an object at the top level, instead of possibly an array? Aug 23 06:42:00 tagrudev: I'm sorry, I'm not really understanding your question, your problem is that you don't know the structure of the json that org.json gives you back? Aug 23 06:42:07 And how will other libraries help? Aug 23 06:42:46 nope, kmicinski the api response is either a single json object or an array of json objects Aug 23 06:42:57 im using the org.json library but its quite slow. Sufficient for what im using it for, though. Aug 23 06:44:23 tagrudev: so I'm not sure why this is an issue Aug 23 06:44:28 handle the two cases? Aug 23 06:45:42 if youre working with org.json and you need to know what kind of response youre getting, you can check if the first char in the response is [ or or { Aug 23 06:46:00 so that youll know if its an array or an object Aug 23 06:46:08 theres probably a better workaround though Aug 23 06:46:28 kmicinski, i am asking how to handle it sorry i didnt make it clear Aug 23 06:46:47 eSatsu, that is a solution but I dont like it Aug 23 06:46:59 i dont like it either but it is indeed a solution Aug 23 06:47:28 [ means its an array, { means its an object, anything else probably means its an error from the server Aug 23 06:48:34 you are right but in case of a nested json it really becomes a pain in the a** Aug 23 06:49:16 hm, and org.json doesnt give you the type? Aug 23 06:49:22 even by reflection? Aug 23 06:51:02 kmicinski, can you be more specific ? Aug 23 06:52:52 I'm sorry, so, you can't tell the difference between the two because they both give you back an object and you can't tell the differenc Aug 23 06:53:04 it seems like you're basically trying to decide which thing you have Aug 23 06:54:12 this is the scenario, i make an http request it gets me a response I want to read from that response Aug 23 06:54:26 since it is json I want to somehow parse it in my android application Aug 23 06:55:20 you can't just read it in using the org.json classes? Aug 23 06:55:24 (I remember doing this..) Aug 23 06:55:59 can you remember on how you did this and show it to the rest of the class Aug 23 06:57:16 looks like you just make a JSONTokener, and call nextValue() Aug 23 06:57:25 and then check if it's a JSONObject or JSONARray Aug 23 06:58:24 looks pretty straight-forward to me Aug 23 06:59:24 ty Aug 23 06:59:38 that is what i was looking for Aug 23 07:04:59 So..I am running an Ubuntu image on my phone which has gcc,make and whatnot so I thought I could compile anything for android Aug 23 07:05:36 But the simple C apps I compilenl do not run on phone Aug 23 07:06:12 Ive compiled with bionic libc Aug 23 07:06:47 diki: assuming you're doing platform mods? Aug 23 07:06:49 But when I try to run on phone like ./app I get File or directory not found... Aug 23 07:07:04 that sounds like a dynamic linking thing.. Aug 23 07:07:06 But binary is there.. Aug 23 07:07:08 so you have an ubuntu chroot? Aug 23 07:07:15 JesusFreke: yes Aug 23 07:07:33 are you trying to run the binaries in the chroot? Or in the normal android environment? Aug 23 07:07:45 Normal android env Aug 23 07:08:00 how are you compiling them against bionic? Aug 23 07:08:29 Since there is an android port of gcc, I had used libc from there Aug 23 07:08:51 As well as crtbegin_dynamic.so and crtend object files Aug 23 07:09:10 Anyone else seen a huge spike in downloads today? All my apps got 5x more downloads for the last two days. Bug? Aug 23 07:09:31 sounds like you're on the right track at least. Aug 23 07:09:38 Needless to say I get a binary but its like android cannot find it Aug 23 07:10:03 diki: it's almost certainly a dynamic library that it's linked with that it can't find Aug 23 07:10:07 And itbis definitely arm elf with bionic libc Aug 23 07:10:28 Unfortunately ldd does not work on it Aug 23 07:10:47 in my experience, there are 3 main ways to compile a binary that works in android Aug 23 07:11:18 1. build a static executable with any cross-toolchain you want (produces large binaries, of course) Aug 23 07:11:39 2. use the ndk (somewhat limited support for libraries, etc.) Aug 23 07:12:10 3. create a project in the android source tree, e.g. external/, and build an Android.mk for what you're wanting to compile Aug 23 07:12:54 Believe it or not, Im doing all of this so I can build autotools for android Aug 23 07:13:15 So I can get make and configure etc Aug 23 07:16:07 when i hear autotools, i run Aug 23 07:18:19 Hi, I take a picture using the code that's very similar to --> http://stackoverflow.com/questions/4184951/get-path-of-image-from-action-image-capture-intent but the actual picture on the device is of size 0 (and so can't be opened). Was wondering if there's some piece I'm missing. Tried taking pics with the 'regular' camera app and it works fine. Thoughts? Thank you! Aug 23 07:45:21 I have a string question. Before enabling hardwareacceleration, my draw on my custom view works fine. But if I enable it, the text on my custom view won't show up. Why is that? Aug 23 07:52:11 hello. i want to play mp3/ogg/... backwards, i red the once way is to convert it to WAV. it's true? if yes, is there a way to convert the files to WAV? Aug 23 07:52:18 how do i get utf-8 out of EditText? or how do i re-encode the string as utf-8? Aug 23 07:52:46 eSatsu: is it really critical that it's specifically UTF-8, or do you just need Unicode? Aug 23 07:53:35 not sure, by default its getting mangled on the server Aug 23 07:53:45 i can try with either, whichever is simpler Aug 23 07:53:53 all Strings in Java are Unicode Aug 23 07:54:29 probably utf-8 then Aug 23 07:54:44 the server is handling it as json Aug 23 07:57:04 the problem is almost certainly not in the extraction from EditText Aug 23 07:57:21 i confirmed, the server needs utf-8 Aug 23 07:57:36 so how do i convert it? Aug 23 07:57:43 how are you uploading it to the server? Aug 23 07:57:57 httpPut, multipartentity Aug 23 07:58:12 defaulthttpclient Aug 23 07:59:02 if you NEED UTF-8 (i.e., an array of bytes representing a UTF-8 string) you want myString.getBytes("UTF-8"); Aug 23 07:59:30 so basically Aug 23 08:00:22 new String(oldstring.getBytes("UTF-8"), "UTF-8") this should convert the string into a new string in utf-8? Aug 23 08:00:40 not working for some reason Aug 23 08:00:41 ...no. Aug 23 08:00:48 that doesn't do anything. Aug 23 08:00:51 oh haha i misunderstood something then Aug 23 08:01:06 Strings are unicode and they abstract away the encoding. Aug 23 08:01:24 Try printing your string to a log before sending it to the server Aug 23 08:01:30 to see if it looks correct. Aug 23 08:01:42 on the log it does Aug 23 08:02:52 oh wait now i think i got it Aug 23 08:04:53 ty Aug 23 08:19:16 interesting http://news.ycombinator.com/item?id=4416864 Aug 23 08:19:25 i guess this could be applied to the play store rating system also Aug 23 08:29:25 g00s, http://play.google.com/store/apps/details?id=com.panaceasupplies.android.filemanager&reviewId=01554462957505452201 Aug 23 08:29:27 https://play.google.com/store/apps/details?id=com.panaceasupplies.android.filemanager&reviewId=10330158902171449845 Aug 23 08:30:57 I get two negative one star reviews from a Michal and a "Mi", both suggesting mkc file manager Aug 23 08:31:21 And the author of mkc just happens to be named Michal Kosta Aug 23 08:31:32 yeah, i suggested a while ago we needed to be able to see all reviews someone has writte Aug 23 08:32:01 that sucks. what an ass Aug 23 08:32:39 Yaa, it doesn't hurt my overall thing too much. But he is an ass. Aug 23 08:32:58 i downvoted his :) Aug 23 08:34:28 the reviews, that is Aug 23 08:34:36 thanks Aug 23 08:35:40 Hi guys Aug 23 08:35:51 dude, i love almonds ! Aug 23 08:35:57 :-D Aug 23 08:36:04 me too Aug 23 08:36:12 orly :P Aug 23 08:36:42 XD Aug 23 08:37:03 let's talk about serious things Aug 23 08:37:14 I need to shutdown android programmatically Aug 23 08:37:30 at the moment I'm only able to reboot it using the powermanager class Aug 23 08:37:49 is there a way to shut it down? Aug 23 08:37:53 from java? Aug 23 08:39:20 mrAlmond, I'm not sure it's possible on a non-rooted phone Aug 23 08:39:30 my phone is rooted Aug 23 08:39:48 and I can generate new roms and flash them Aug 23 08:40:02 I've also recompiled the whole android source tree Aug 23 08:41:51 sudo shutdown now? Aug 23 08:42:35 if your android phone has sudo, I dunno wtf ROM you have Aug 23 08:43:09 don't they all have sudo o.O Aug 23 08:43:31 ...no... Aug 23 08:43:43 not even rooted ones? Aug 23 08:44:04 I'll check a CM7 device, one sec. Aug 23 08:44:54 # sudo Aug 23 08:44:55 sudo: not found Aug 23 08:45:25 nor does it have shutdown Aug 23 08:45:33 well i'll be Aug 23 08:45:48 sudo is not available Aug 23 08:45:53 ryanm: try su Aug 23 08:45:59 I'm thinking about using suid bit Aug 23 08:46:05 for shutdown binary Aug 23 08:46:13 diki: kinda pointless, it's a root shell Aug 23 08:46:30 su does exist though Aug 23 08:46:47 yes it exists but I've always had problems when executing it from java code Aug 23 08:46:48 in any case, the root discussion should probably go in #android-root Aug 23 08:47:08 hello world, i have written an accessibility application. it functions most of the time but sometimes it cant get the events. ive checked the logcats, the only difference in when it works and doesnt is that mem allocs are being called more frequently then when it is working Aug 23 08:49:15 the starting and unbinding functions call when its toggled on and off, and i have put test lines in that visually respond when any event is detected... Aug 23 08:50:41 please help me to debug this: Unable to resolve superclass of Lcom/dummy/fooforandroid/ScriptApplication Aug 23 08:51:18 source: http://android-scripting.googlecode.com/hg/android/script_for_android_template.zip Aug 23 08:54:53 problem being? Aug 23 08:55:03 oh, duh, brb Aug 23 08:56:14 ack... Aug 23 08:56:27 android-4, ide have to spend another hour downloading another api level... Aug 23 08:59:07 darkun: are you talking with me ? Aug 23 09:05:05 yeah mherweg i was, gimmie a second, brb in rl Aug 23 09:06:51 ok, thanks Aug 23 09:07:23 mherweg, im changing build targets right now to get it up Aug 23 09:08:20 compiled, installed and crashed... Aug 23 09:08:38 thanks for confirmation :-) Aug 23 09:08:56 any idea ? Aug 23 09:09:03 not sure, whats the app supposed to do? Aug 23 09:09:44 start the python script that you see int the raw folder Aug 23 09:09:50 Hi there. I develop an android opencv application and I just get a really low framerate (there's an opencv sample doing basically the same that's much faster). Are there any ways for coda analyzing/benchmarking so I can find out what's taking so long right now? Like valgrind for example. Aug 23 09:11:04 Would anyone explain the difference between crtbegin_dynamic.o and crtbegin_so.o? Aug 23 09:13:22 dakun: on which android version did you try to run it ? Aug 23 09:14:11 built to api 8(lowest i have at the moment) running on 4.1 Aug 23 09:15:10 I buld & run on Api 8 - same result Aug 23 09:15:30 the script is ok. it runs in SL4A Aug 23 09:15:45 must be something else Aug 23 09:15:46 yeah i see that, its crashing before the script Aug 23 09:18:15 dakun: I noticed that files are missing compared th a older version of "PythonAPK" in bin/classes Aug 23 09:18:55 that could be a reason, im getting class now found errors Aug 23 09:25:09 have you verified that a simple app can run with this? Aug 23 09:25:18 mherweg, Aug 23 09:26:23 "with this ?" I successfully build "Touchpaint" with my Eclipse setup Aug 23 09:28:48 Man, the Filter functionality for adapters is so annoying... very prone to race conditions. Aug 23 09:29:17 dakun: I'll try http://code.google.com/p/android-python27/wiki/TutorialHowToUpdateWithLatestSL4A instead Aug 23 09:29:47 mherweg, i honestly dont know at that level... yeah thats probably a good idea. ive kinda given up on trying to use py for what i need(crashing and such) Aug 23 09:29:53 PythonAPK is a different project whith the same goal Aug 23 09:29:56 i write my stuff native in java anyways Aug 23 09:30:18 or cross compile :) Aug 23 09:30:40 cross-compile from which language ? Aug 23 09:31:49 ok, than later you maybe can help me to add a button to the Touchpaint app. First I'll try it myself Aug 23 09:32:22 Touchpaint = android example app in java Aug 23 09:34:00 hehe, shouldnt be hard Aug 23 09:34:08 the examples are good for that Aug 23 09:35:46 has anyone used a very good lazy image loader? Aug 23 09:35:59 in android Aug 23 09:38:27 is there a way for the manifest to identify api version? like in android <4, i want a launcher icon for my app, but in 4=< i dont... Aug 23 09:51:18 sudarshan: you can implement that with a Lru Cache Aug 23 09:51:25 https://developer.android.com/reference/android/util/LruCache.html Aug 23 10:05:09 DashCC: Hi there! Long time no see! How have you been? Aug 23 10:06:26 This is the question I have ---> Hi, I take a picture using the code that's very similar to --> http://stackoverflow.com/questions/4184951/get-path-of-image-from-action-image-capture-intent but the actual picture on the device is of size 0 (and so can't be opened). Was wondering if there's some piece I'm missing. Tried taking pics with the 'regular' camera app and it works fine. Thoughts? Aug 23 10:06:26 Thank you! Aug 23 10:07:06 aLearner: I was very busy with different projects but am happy and good, you? :-) Aug 23 10:07:30 http://stackoverflow.com/questions/2058945/using-videoview-for-streaming-or-progressive-download-video , there is no method to play rstp stream on emulator? Aug 23 10:08:19 DashCC: Cool. PM? Aug 23 10:08:33 sure Aug 23 10:11:33 DashCC: PMed ya! Aug 23 10:21:41 where in the android docs do i find the guarantee that the bundle passed to onCreate is null only when the activity is newly created and not recreated after a configuration change? Aug 23 10:30:53 or asked differently: Aug 23 10:31:11 let's say i start an AsyncTask in onCreate(), how to make sure i don't restart it after a config change? Aug 23 10:32:06 a flag Aug 23 10:32:16 use intent extra maybe Aug 23 10:32:32 if no extra, dont start async Aug 23 10:33:27 hmm Aug 23 10:33:29 Does anyone program on an Android tablet? Aug 23 10:33:48 jrajav: yeah, you mean program FOR it or program ON it? Aug 23 10:33:48 E.g. with an online "ide" like cloud9, ideone, or compilr Aug 23 10:33:53 ON it Aug 23 10:34:07 Or even with something offline like AIDE Aug 23 10:34:21 AIDE is the best one atm Aug 23 10:34:23 no better Aug 23 10:34:28 online or offline Aug 23 10:34:34 Seems to be Java only though :/ Aug 23 10:34:44 what lang you want to use Aug 23 10:34:58 ? Aug 23 10:35:20 you can NDK in AIDE I think Aug 23 10:35:21 Javascript, Java, Objective C, Haskell, Clojure…. Aug 23 10:35:22 :P Aug 23 10:35:26 Wow, really? Aug 23 10:35:28 :/ Aug 23 10:35:44 not most desktop ide's do all those in one Aug 23 10:36:09 Yes, well, I'm not really looking for an ide Aug 23 10:36:36 Blou_Aap: ok, after a configuration change an activity is allowed to be completely destroyed and recreated, right? Aug 23 10:36:42 there is DeuterIDE on Android, it does compiling and what not offline Aug 23 10:36:51 apparently supports 40 languages Aug 23 10:36:53 I guess the only real way to accomplish what I want is to have some Linux box or VM always on that I can ssh into Aug 23 10:36:59 Blou_Aap: so the correct way would be to store the info about the started task in the savedInstanceState (a bundle)? Aug 23 10:37:03 And just run vim or something Aug 23 10:37:14 but looks to be like $5 Aug 23 10:37:32 Blou_Aap: you mentioned intent extras.. i was not aware that the activity itself could put more stuff into the intent extras bundle Aug 23 10:37:44 Blou_Aap: That would be worth it :O Aug 23 10:38:15 tapas, i done something like that before lol. but what is the async task going to do at onCreate()? Aug 23 10:38:20 jeez what is it with phones being so expensive now Aug 23 10:38:33 Bear10, blame apple Aug 23 10:38:45 ans M$ Aug 23 10:38:49 Blou_Aap: it's just started in onCreate.. it might run for quite a while.. Aug 23 10:38:53 i honestly dont even know what phone to get anymore, i wanted something cheap with a bigger screen Aug 23 10:39:03 Blou_Aap: and i want to allow the user to change the device orientation during that time.. Aug 23 10:39:20 Blou_Aap: if i just unconditionally start the asynctask in onCreate several instances of it will get started. Aug 23 10:39:20 tapas, ye, but what does it do. Does it download stuff online from a server, etc ? Aug 23 10:39:29 tapas: Start it in a service instead Aug 23 10:39:45 jrajav, lol that was what i was getting to. Aug 23 10:39:49 Blou_Aap: yes, and migrate data from an external sqlite file into the internal one, get thumbnails, etc.. Aug 23 10:39:55 any suggestions on a phone for maybe 200$? Aug 23 10:40:05 a service is normally for even longer running tasks.. Aug 23 10:40:21 tapas, use a service instead for that, then you dont have to worry about the activity recalling the task Aug 23 10:40:33 tapas: A service can be for whatever you want it to be for Aug 23 10:40:37 by acident from config change Aug 23 10:41:02 ye a service can even just have a single tak and then be destroyed Aug 23 10:41:07 task* Aug 23 10:41:21 and wont be bound to the activity Aug 23 10:41:23 tapas: I use one as a data layer for an app that stores in a local db and syncs with a server. Both operations block for potentially longer than or across the lifetime of the app, and I also don't want it starting those ops several times Aug 23 10:41:29 unles you bind yourself Aug 23 10:41:31 tapas: So I just send them to the service Aug 23 10:41:43 And you can even bind it if you want the result Aug 23 10:41:47 It's pretty flexible Aug 23 10:42:03 jrajav: yeah, but in my case due to client request the tasks execution lifetime is directly bound to the lifetime of the activity Aug 23 10:42:08 it's the point of service really Aug 23 10:42:11 once it finishes, the activity is finished, too Aug 23 10:42:31 putting stuff into a service would introduce more coupling points and more potential errors lateron.. Aug 23 10:42:43 anyways, i think using the savedInstanceState is the wat ty to go Aug 23 10:43:02 that's not the service's fault lol. that would be your fault :P Aug 23 10:43:46 of course, errors are always the developer's fault (unless they're a bug in the libraries used or the toolchain) Aug 23 10:43:53 i never made that assertion :D Aug 23 10:44:00 Well, there's something to be said for reducing complexity, sure Aug 23 10:44:09 But in this case the path to lower complexity is probably using a service Aug 23 10:44:46 I'm pretty sure it would be possible to start the service for a somewhat long-running task and have the service message whatever instance of the main app is up, if any, when it finishes Aug 23 10:44:56 well, right now since the activity has no other instance state it's a matter of if (null == savedInstanceState) { new Task().execute(); } Aug 23 10:44:59 :D Aug 23 10:45:03 Though whether you'd do that with startservice or binding I couldn't say Aug 23 10:45:13 this amount of complexity is hard to beat :D Aug 23 10:45:13 does anyone know if eople are happy with Motorola Razr Maxx? Aug 23 10:45:34 tapas, but is also the wrong aproach Aug 23 10:45:51 tapas: That doesn't look like it would even work. Your activity is destroyed every time you wiggle the device Aug 23 10:45:52 opening your self up for some serious bugs Aug 23 10:46:02 tapas: So the asynctask, being a part of the activity, is destroyed too Aug 23 10:46:08 jrajav: nope.. Aug 23 10:46:17 the asynctask is not destroyed.. Aug 23 10:46:30 you can always just use a thread and handler Aug 23 10:46:46 thread wont get destroyed until it finishes it's functions Aug 23 10:48:57 hmmm Aug 23 10:50:50 hmm, but actually you guys have me thinking.. Aug 23 10:51:24 the asynctask also communicates progress change back to the activity.. and if the activity is destroyed and rebuilt again all references held to te activity will be "invalid" Aug 23 11:03:11 Hello. My phone runs off the battery much quicker than a month ago, and I want to check if it's due to battery poor health, or the motherboard itself. Can you suggest me any way to do that? Aug 23 11:12:46 Hi everyone, Is it possible for an app to control or activate special keyboard tap sounds? Aug 23 12:09:09 anyone know how to get the language code that app has actually selected? I know hot to get language from locale, but it's not what I want Aug 23 12:09:45 user might have phone set to Finnish. but app does not know finnish so english is selected. so I want to know what language the app selected Aug 23 12:13:13 hi Aug 23 12:17:04 tapas, why are you destroying your activity to begin with ? Aug 23 12:17:48 Blou_Aap: android destrys activities at any time Aug 23 12:18:10 if you don't code with that in mind, you going to have bugs Aug 23 12:18:18 -_- Aug 23 12:18:40 bit out of context wongk Aug 23 12:19:05 was talking to tapas a bout his async chat we had quite a while ago Aug 23 12:19:10 it's in context with tapas's statement Aug 23 12:19:56 I know how activities work, I want to know why his is destroyed quicker than his task can finish Aug 23 12:20:13 because android can destroy tasks *at any time* Aug 23 12:20:34 s/tasks/activities Aug 23 12:21:31 doing things asynchronously on android is especially cumbersome for that reason Aug 23 12:22:35 even more difficult is the fact that the actvity may become paused and no destroyed Aug 23 12:22:58 in which case doing any updates to the ui, or displaying messages, will cause an exception Aug 23 12:31:43 Hello guys, I already added a function to my app to start the camera intent to take a picture and on return grap de filename to load the pciture (for sending to a server). But is it also possible to specify the path yourself and than the camera uses it to save the photo accordingly? Aug 23 12:33:05 i don't know the answer, but for sanity's sake, were you wanting to store the picture on external or internal storage? Aug 23 12:33:16 I've done that with Samsung devices, because the camera intent doesn't return the filename. Aug 23 12:33:16 yeah Number5 u can do that Aug 23 12:33:21 On extarnal sd Aug 23 12:33:26 give me a minute Aug 23 12:33:30 may b i can help Aug 23 12:33:43 hitesh88, can you give me a link, I couldn't find a simple example. Aug 23 12:33:51 ok, just making sure Aug 23 12:33:58 well I created camera from scratch Aug 23 12:34:00 wongk tnx Aug 23 12:34:02 if u wanna try it Aug 23 12:34:07 i can give u a link Aug 23 12:34:12 wanna try Aug 23 12:34:13 ? Aug 23 12:34:21 hitesh88, you mean used the camera api? Aug 23 12:34:38 * hitesh88 created camera from scratch Aug 23 12:34:52 wanna see the code ? Aug 23 12:34:59 i can give apk Aug 23 12:35:02 if want to try Aug 23 12:35:08 If that is what I'm looking for, why not. Aug 23 12:35:36 hitesh88, thnx, but I rather seek a simple solution Aug 23 12:35:45 well thats pretty simple Aug 23 12:36:11 that would require all his users to have your camera installed Aug 23 12:36:35 intent.putExtra(MediaStore.EXTRA_OUTPUT, uri); works for non-Samsung devices too? Aug 23 12:36:44 yeah Aug 23 12:36:47 it will work Aug 23 12:37:02 Ok. thnx Aug 23 12:37:03 u can get full size image using the EXTRA OUTPUT Aug 23 12:37:32 hitesh88, ok thank you and other for your help. Aug 23 12:39:19 np Aug 23 12:44:28 'ello Aug 23 12:45:51 This might be the wrong place to ask, but would anyone be able to tell me if the filesystem structure is any different between the iOS and Android? In terms of trying to load a file from e.g. file:///mnt/sdcard/myfile.txt Aug 23 12:46:07 That works on Android, would it yell at me on the iOS? Aug 23 12:46:16 I am fairly certain it would, but yeah, double checking. Aug 23 12:54:10 hi Aug 23 12:54:52 Tee_Pee: that does not work "on android"... that works on 1 android device Aug 23 12:55:16 do not use hardcoded file paths Aug 23 13:02:58 Tee_Pee: I don't know how iOS works, sorry. You might want to ask in an ios dev channel. The file:// uri works in android, but I'd really recommend that you not hardcode paths; there's no guarantee that the SD card will always be at that location. Aug 23 13:04:23 Aye, I understand... doing it dynamically now. Aug 23 13:04:36 Phonegap is rather stubborn when it comes to the file system though. Aug 23 13:04:48 phonegap is a dirty word here Aug 23 13:04:51 Yeah, that's the disadvantage of working with compatability layers like phonegap. Aug 23 13:05:00 It does everything poorly instead of some things well Aug 23 13:05:24 phonegap should be a dirty word everywhere Aug 23 13:05:28 phonegap is a dirty word here <----Thought as much. However, choice I have none. Aug 23 13:05:46 This thing needs to fly on both Android and iOS. Aug 23 13:06:37 There's a good chance it'll flap uncontrollably before crashing hard on both platforms instead :P Aug 23 13:06:52 just so long as the business side understands that in exchange for getting 2 products for half the time, they get two mediocre products at best Aug 23 13:07:05 Yup, they do. Aug 23 13:07:12 That's why my job currently reads Aug 23 13:07:20 I've made one app with phonegap and getting the app-like look'n'feel was really hard Aug 23 13:07:28 "Create a light version of the app for both platforms to get them out quickly, then start from scratch and focus on each platform natively" Aug 23 13:07:36 Job title: mediocre developer Aug 23 13:07:55 If it was my decision, I'd go native right away. Aug 23 13:07:56 well, at least they plan to correct this issue going forward Aug 23 13:08:00 However, I do not make the decisions. Aug 23 13:08:12 They understand that phonegap is murder in terms of performance. Aug 23 13:08:56 we made it to iphone and android, and after the project we noticed that we might have done two native applications in the same time Aug 23 13:09:31 it took us like two weeks to tweak the performance and feeling to be "almost" like a native app Aug 23 13:11:23 Well, truth be told, using Sencha Touch, I am pleased with the look and feel for now. However, I am running this on an SGS2, so for all I know it'll roll over and die on a 1 year older device. Aug 23 13:12:38 hello Aug 23 13:12:45 Yeh, we managed to get our app work with zte blade Aug 23 13:12:56 Sencha Touch will slow to a crawl on anything that you can wrap your hand around Aug 23 13:13:02 but if somebody in this firm asks my opinion, never again :D Aug 23 13:13:04 my company likes making phonegap apps and then blaming android for the poor performance of them :( Aug 23 13:13:20 HTML5/JS phone apps aren't really ready for the world yet Aug 23 13:13:46 is HTML5 even published yet? :P Aug 23 13:13:48 does anybody know how can we get the timezone's current time like GSM 's current time in android? Aug 23 13:13:51 Yeah, technology is really promising but with current frameworks it is just not worth it Aug 23 13:14:15 jagruti_: use the Date class. Aug 23 13:14:47 lov: if i use the date and get the time then it will always give me the current time Aug 23 13:14:59 jagruti_: sorry, use Calendar instead Aug 23 13:15:07 jagruti_: right, but the Date will have the timezone offset as well. Aug 23 13:15:35 anyway, Calendar will let you interact directly with TimeZone instances Aug 23 13:15:55 lov: ya but that will give me also current time Aug 23 13:18:15 09:15:40 < lov> anyway, Calendar will let you interact directly with TimeZone instances Aug 23 13:18:30 You can A) look at that TimeZone instance to see what the offset is Aug 23 13:18:40 or B) get an instance of a Calendar with the TimeZone set to UTC0 Aug 23 13:18:59 jagruti_: I encourage you to read the docs for the Calendar class, and maybe search google for 2 minutes. Aug 23 13:20:10 lov: if we will manually change the time in mobile and then we get the time then it will give me the after changed time but i really need the default the time which should be actually there like current time of GSM Aug 23 13:20:28 i have already spend the two days for this issue please help me Aug 23 13:22:22 lov:actually my requirement is that if i send the message from sender to receiver then receiver does not get any idea about when the sender has send the message ,so i have send the Date().gettime() with the messages and then converted the that time to reciever's timezone Aug 23 13:22:33 uh Aug 23 13:22:49 does the receiver actually know the sender's timezone? Aug 23 13:22:58 lov:no Aug 23 13:23:05 Then how in the fuck do you plan on converting this? Aug 23 13:23:30 I don't even understand what you're doing here Aug 23 13:23:32 first off, gsm is a cellular technology, i think you mean UTC Aug 23 13:23:40 wongk: I think he means GMT :( Aug 23 13:23:44 previously known as gmt Aug 23 13:23:49 has anyone implemented peer-to-peer SIP? Aug 23 13:24:14 porten: that sounds like a horrible idea. Get to it! Aug 23 13:24:19 lov: lol Aug 23 13:24:45 lov: on receiver side i also get the date().gettime() and then set the reciever's timezone and settime to sender's time Aug 23 13:24:51 lov: I'm trying to make a call where I can modify the audio and the typical phone call service doesn't allow this Aug 23 13:25:03 so I'm wondering if I can just use SIP Aug 23 13:25:05 so it will give me the current time of receiver's correctly Aug 23 13:25:08 lov: why is it sucha bad idea? Aug 23 13:25:10 all dates coming from a server should be in UTC and converted on the client side Aug 23 13:25:18 ^^ Aug 23 13:25:20 exactly this. Aug 23 13:25:24 however i can't make any sense of what you're actually saying Aug 23 13:25:30 ^^ also this Aug 23 13:25:36 I literally don't understand half of what you're saying Aug 23 13:25:43 I'm not trying to be flippant, I cannot actually parse your statements Aug 23 13:25:58 lov: wait i will show you my code Aug 23 13:26:03 please don't ._. Aug 23 13:26:08 lol Aug 23 13:26:08 y? Aug 23 13:26:15 I don't have time to trawl through it Aug 23 13:26:20 This is something you need to architect Aug 23 13:26:33 but really i need the help Aug 23 13:26:43 What is your communication architecture? Do you have an intermediate server, or are both sides communicating directly? Aug 23 13:26:57 intermediate server, Aug 23 13:26:59 openfire Aug 23 13:27:03 In either case, you should be sending the message with a timestamp of UTC +0, period. Aug 23 13:27:45 You either include the timestamp in the message, or you allow all parties to make assumptions of what the timestamp is by making it always UTC +0 Aug 23 13:27:56 UTC will send the current time of device or as per timezone's current time? Aug 23 13:27:56 You can create a Calendar instance using a TimeZone with UTC 0. Aug 23 13:28:01 .... Aug 23 13:28:04 lol Aug 23 13:28:07 fuck it, I'm done. Aug 23 13:28:11 learn what UTC is please. Aug 23 13:29:48 timezones and DST are just the man trying to make our jobs as difficult as possible ;) Aug 23 13:30:13 DST is a nightmare Aug 23 13:31:52 SimpleDateFormat sdf = new SimpleDateFormat();sdf.setTimeZone("UTC");Calendar cal = Calendar.getInstance();System.out.println(sdf.format(cal.getTime())); then it will give me the current time of my device Aug 23 13:34:35 When working with the licensing package, I discovered that google doesn't like it if I send a lot of licensing requests as I was debugging a crash. I get a 429 error which is translated as a networking error. Aug 23 13:34:56 Does anybody know how long this condition lasts, or if I have to do something special to fix the problem myself? Aug 23 13:35:03 I need to call two activities in succession, and process the result from both after the second has completed. How do I propagate the result from the first call? Aug 23 13:35:43 lov,wongk... please give me some idea how can i get the time which is not the current time of device but actually time of timezone Aug 23 13:35:59 Information from the internet indicated a clearing timespan of "2 days" to "3 weeks". Aug 23 13:36:54 Lachezar: startActivityForResult Aug 23 13:37:25 jagruti_: Use Calendar and set the TimeZone... Aug 23 13:38:24 wongk: I know how to get the result, but the second intent is not connected to the first. The activity state (fields) is not suitable, since it pertains longer than needed. Aug 23 13:38:35 Lachezar: i have already tried that but it will also give the device's current time Aug 23 13:39:04 Lachezar: where are you starting these activies from? why can't you just hold on to the result from the first? Aug 23 13:39:07 jagruti_: Calendar.setTime(), Calendar.setTimeInMillis()... Aug 23 13:39:32 wongk: Since calling an Activity is an Asynchronous process, that won't work. Aug 23 13:39:54 Lachezar: but which time i will set to calender Aug 23 13:40:25 Lachezar: why not Aug 23 13:40:39 Activity CombineActivity calls SelectActivity twice (that is implemented). However I need to store (where?) the result from the first call, and process it when the second call returns. Aug 23 13:40:46 jagruti_: http://developer.android.com/reference/java/util/Calendar.html#getInstance(java.util.TimeZone) Aug 23 13:40:56 jagruti_: http://developer.android.com/reference/java/util/Calendar.html#setTimeInMillis(long) Aug 23 13:41:02 Lachezar: a member? Aug 23 13:41:09 Fucking hell. Deleting the last version of APK from developer console = nuke the whole app. Thanks, google. Aug 23 13:41:29 jagruti_: http://developer.android.com/reference/java/util/SimpleTimeZone.html Aug 23 13:41:47 wongk: That needs I have to make the field respawn using onSave...(...) onRestore...(...), :( Aug 23 13:42:09 wongk: And then... This field will continue to live if the process is canceled, which is undesirable. Aug 23 13:42:18 jagruti_: http://developer.android.com/reference/java/util/TimeZone.html#getTimeZone(java.lang.String) Aug 23 13:42:27 wongk: And it will stay after the process has ended... Aug 23 13:42:45 jagruti_: http://stackoverflow.com/questions/2818086/android-get-current-utc-time Aug 23 13:42:45 Lachezar: intent chaining is probably the only other option Aug 23 13:42:46 wongk: Ignore... I will create a medium Activity with no UI. Aug 23 13:42:56 jagruti_: http://stackoverflow.com/questions/308683/how-can-i-get-the-current-date-and-time-in-utc-or-gmt-in-java/6697884#6697884\ Aug 23 13:42:58 wongk: What is Intent Chaining? Aug 23 13:43:01 jagruti_: if this doesn't help then fuck you. Aug 23 13:43:19 Lachezar: stick the result of the first activity into the intent for the 2nd Aug 23 13:43:29 return it in the result Aug 23 13:43:51 wongk: I was thinking of that, but I need the Intent to be engineered to handle that. The SelectIntent is not mine. Aug 23 13:44:00 oh Aug 23 13:44:34 well that data is going to have to "live" somewhere, so you'll have to adapt the lifecycle to consider that Aug 23 13:44:44 wongk: I believe an activity that is SelectTwoActivity that will have the state will help. Aug 23 13:45:14 wongk: An UI-less Activity. Aug 23 13:45:37 maybe, i don't know Aug 23 13:45:42 Lachezar: my requirement is that if my current time is 10:00 as per my timezone gsm+5:30 and if i change time manually to 11:00 and after that if get the time then it should be give me 10:00,not 11:00 Aug 23 13:46:21 jagruti_: OK, I know English is NOT my native language, but I did not understand what you need. Aug 23 13:46:44 gsm+5.30? :( Aug 23 13:46:52 neither do the native english speakers, don't feel bad :P Aug 23 13:46:54 no yar Aug 23 13:47:15 GMT+03:50 India? Aug 23 13:47:20 no Aug 23 13:48:23 i want the current time of gmt which is universally correct, but if i will get from my devices then it will give me time which is i have set in the date and time Aug 23 13:49:34 NO IT WON'T Aug 23 13:49:38 READ THE LINKS I GAVE YOU Aug 23 13:49:45 YOU CAN GET UTC TIME VIA CALENDAR BY REQUESTING UTC TIME Aug 23 13:49:49 STOP BEING DENSE Aug 23 13:50:03 09:40:51 < lov> jagruti_: http://developer.android.com/reference/java/util/Calendar.html#getInstance(java.util.TimeZone) Aug 23 13:50:22 fuck it Aug 23 13:50:31 you're going to make lov's head explode, and then we're all going to have to clean that up Aug 23 13:50:49 jagruti_: you're literally the worst. Aug 23 13:50:55 this isn't Android programm Aug 23 13:50:58 *programming Aug 23 13:51:01 this is Java programming Aug 23 13:51:03 go to #java Aug 23 13:51:10 this is why /ignore was invented Aug 23 13:51:10 let them beat their heads against the wall Aug 23 13:51:34 you are absolutely right Aug 23 13:51:39 and ignored he is. Aug 23 13:52:43 lov: sorry for confused you all but i dont know very well english Aug 23 13:53:29 you're also making it more difficult than it needs to be, and acting helpless about it Aug 23 13:53:35 lov: and also i can't get correct result thats y i am asking more and more ,otherwise i dont want to disturb Aug 23 13:54:35 wongk: sorry but even though i have tried all this things ,i have not get correct result ,so i am asking again and again Aug 23 13:55:51 How do you put text OVER a ProgressBar? Aug 23 13:56:04 z-order wise? Aug 23 13:56:06 Can you have a TextView and a ProgressBar occupy the same space? Aug 23 13:56:19 probably Aug 23 13:56:20 i don't think there's a layout for that :P Aug 23 13:56:30 wongk: I think that you can do it with FrameLayout hijinks or something Aug 23 13:56:36 maybe Aug 23 13:56:40 The FEATURE_PROGRESS does this automatically. Aug 23 13:56:58 It has the App Title over the progress bar. Aug 23 13:57:14 I'm trying to do the same thing with a custom title bar. Aug 23 13:57:30 i have try to get the time of UTC that will give correct time of current time but if i will change the mobile time and then i will try to get the time then it will give me the time which was i have changed.but really i need the time which is not changed or default time of UTC Aug 23 13:58:15 ... this has been since API level 1? Aug 23 13:58:24 well, that's news to me. Aug 23 13:58:59 Jonathan_Eyre: you could always take a look at what FEATURE_PROGRESS does in the source Aug 23 13:59:19 I will say that it's probably going to be an utter PITA to style this yourself, since the progressbar changes themes on different devices/api levels Aug 23 13:59:20 i'd guess it draws things itself Aug 23 14:00:40 yeah, I'd really say look in the source and see how this even happens. Aug 23 14:00:53 if there's a hidden API with ProgressBar you could try using that Aug 23 14:03:39 http://weavora.com/blog/2012/02/23/android-progressbar-with-text/ Aug 23 14:03:41 WOW Aug 23 14:04:04 All that just to have a progress bar with "Loading 34%" on it. Aug 23 14:07:39 welcome to custom drawing Aug 23 14:07:41 Hi Aug 23 14:07:50 you can see why it's avoided at al lcosts :P Aug 23 14:08:14 I have an ImageButton defined in an xml. It has a drawable set as background and as src. How can I reposition the src drawable ? Aug 23 14:12:35 Jonathan_Eyre: I would probably have made a custom ViewGroup for that. Aug 23 14:13:28 And the viewgroup would contain a progressbar and a textview, e.g. in a relativelayout. Aug 23 14:23:00 Jonathan_Eyre: RelativeLayout allows you to put a text view on top of the progress bar. Aug 23 14:23:52 wongk: a No-UI Activity that handles the conversation state worked. Aug 23 14:24:03 excellent Aug 23 14:37:58 do i need to like declare resources 'public' when turning an application into a library? Aug 23 14:38:45 trying to turn my core app into a library so i can release 2 different versions with different feature sets, not sure how to go about it.. Aug 23 14:38:59 if by resources you mean things in /res no, since they are already. Aug 23 14:39:23 if by resources you mean classes then any classes that anyone using the library needs to know about need to be public Aug 23 14:39:46 so i should be able to just like copy the contents of the manifest from the library into the applications manifest? Aug 23 14:39:58 to get access to the libraries and such Aug 23 14:40:05 uhh, activites* Aug 23 14:44:41 stork: basically Aug 23 14:44:49 you don't need to mark anything as exported. Aug 23 14:45:22 Note that you should NOT copy any custom permissions that you declare (not to be confused with permissions that you request) as they'll be created automatically during compile of the library in its R file Aug 23 14:45:59 G'day all, might seem like a silly question but how do I turn off accessibility in eclipse for android apps. I have a [Accessibility] Missing contentDescription attribute on image error in ImageButton Aug 23 14:48:05 Mechdave: that's the linter, not accessability in particular Aug 23 14:48:12 go to window -> preferences -> android, go to the section for the linter Aug 23 14:48:20 you might want to set it so that the linter is not run when you build Aug 23 14:48:54 lov, what is the linter?, sorry but I am very new to android programming Aug 23 14:49:25 Mechdave: it's an extra step that checks for common mistakes, rather than compile errors Aug 23 14:49:33 eclipse is telling me it can't find in my lib project from my application project? Aug 23 14:49:49 for example, creating a toast but not showing it, not adding acessability content to your resources, creating a string but not translating it if you have translations Aug 23 14:49:52 do i need like a namespace prefix or something? Aug 23 14:50:07 stork: I don't know? :( Aug 23 14:51:03 lov, Aha sort of like the -Wall options in C language!! Aug 23 14:51:09 holy fuck nvm i'm a fucking idiot :/ was looking at the wrong manifest file Aug 23 14:51:27 kick me or something Aug 23 14:51:32 Thanks lov Aug 23 14:55:45 thx Aug 23 14:58:56 Do you know any library for SOAP communication ? Aug 23 14:59:22 1. SOAP on mobile is less than good, 2. ksoap is about as good as it gets, afaik Aug 23 15:00:19 lol soap Aug 23 15:00:28 TIL android library projects can't have assets Aug 23 15:00:58 pro_metedor: kSOAP2 and WSClient++, which is non-free. Good luck... Aug 23 15:01:11 has anyone tried to run JAX-WS on Android? Aug 23 15:01:16 will it even run? Aug 23 15:05:46 can you get eclipse to sign a debug ubild with a release key? Aug 23 15:06:43 nm Aug 23 15:06:53 mv debug.key debug.key.bak; mv release.key debug.key Aug 23 15:06:57 what was the answer Aug 23 15:06:58 :P Aug 23 15:07:00 wait no Aug 23 15:07:05 i can specify a custom keystore Aug 23 15:07:06 but not hte password Aug 23 15:07:21 the password is hardcoded Aug 23 15:07:26 it's documented Aug 23 15:07:26 ah Aug 23 15:07:30 [11:05:46] can you get eclipse to sign a debug ubild with a release key? Aug 23 15:07:34 so then i'll ask again Aug 23 15:07:50 i need to test in app billing Aug 23 15:07:55 and it's proving to be a massive pain in the ass Aug 23 15:08:05 ant out of the question? Aug 23 15:08:19 canadiancow yep Aug 23 15:08:25 thats bc in app billing Aug 23 15:08:29 is a massive pain in the ass Aug 23 15:08:34 until u get it working Aug 23 15:08:36 then its ok lol Aug 23 15:09:18 Can anyone recommend software to edit images for buttons etc in ubuntu? Aug 23 15:09:23 Mechdave: gimp :P Aug 23 15:09:35 canadiancow: right click project, android, export ? Aug 23 15:09:36 gimp :S Aug 23 15:09:37 +1 Aug 23 15:09:44 that's not a debug build Aug 23 15:09:46 gimp works but I wouldn't really recommend it ;) Aug 23 15:09:50 i also use gimp on windows Aug 23 15:09:50 then set the debug flag in the manifest Aug 23 15:09:54 presto it's a debug build Aug 23 15:09:57 no Aug 23 15:10:01 i prefer it over photoshop Aug 23 15:10:02 because BuildConfig.DEBUG = false Aug 23 15:10:07 ... Aug 23 15:10:18 lov, That is what I thought :) Some web sites have been talking about inkscape... I'm not sure about inkscape :) Aug 23 15:10:29 isn't that mac only? Aug 23 15:10:36 Mechdave: it's the first thing that came to mind, inkscape may be better. Aug 23 15:10:42 canadiancow: I don't know offhand. Ask stackoverflow. Aug 23 15:10:54 htf do people test iab Aug 23 15:11:01 I shall find out eh :) Aug 23 15:11:04 painstakingly slowly Aug 23 15:11:09 im going to have an expense report of like $0.99 * 1000 Aug 23 15:11:42 i see, run up the CC bill and leave :P Aug 23 15:12:09 canadiancow is a classy developer Aug 23 15:12:15 he's going to leave the fridge door open too Aug 23 15:12:20 hah Aug 23 15:12:21 toilet seat up Aug 23 15:12:28 he's a rude dude. Aug 23 15:12:31 canadiancow: Dont you have your own log class that wraps androids Log class? Aug 23 15:12:46 If that's what it's for Aug 23 15:13:01 Or, make ZyngaConfig.DEBUG Aug 23 15:13:18 im an americancow Aug 23 15:13:18 mikedg gfy Aug 23 15:13:33 ill sell you this nick for 6 pence Aug 23 15:13:47 canadian pence or american pence? Aug 23 15:14:05 depends, whose pence is bigger Aug 23 15:14:08 I have a class A extends Activity, and overrides setTitle, and then class B extends A, but it seems that class A's setTitle is never called Aug 23 15:14:11 zing! Aug 23 15:14:21 =D Aug 23 15:14:22 zyng* Aug 23 15:14:37 wongk likes the big pence Aug 23 15:14:45 that's how i roll Aug 23 15:17:04 08-23 11:16:43.138: E/Volley(17213): [1634] BasicNetwork.performRequest: Unexpected response code 500 for https://android.clients.google.com/fdfe/purchase Aug 23 15:19:37 error 500 means not enough glue Aug 23 15:24:32 jcromartie: that would mean the system does not call that method Aug 23 15:25:12 osxorgate: It was just a silly mistake. I thought the action bar's title was taken from the Activity Aug 23 15:25:13 but it's not Aug 23 15:25:25 so some places were just setting the action bar title Aug 23 15:25:34 while others set the full activity title Aug 23 15:36:56 Is there any way to lock the entire app to portrait orientation only, instead of supplying android:screenOrientation="portrait" attribute to each Activity tag? Aug 23 15:37:52 napster: that doesn't make much sense Aug 23 15:38:03 apps consist of more than just activities Aug 23 15:38:04 evancharlton: why? :) Aug 23 15:38:10 what is a portrait service? Aug 23 15:38:21 (yes, services can draw to the UI) Aug 23 15:38:53 ha :) ok got it. How to keep all activities portrait? Aug 23 15:39:46 Give them each the screenOrientation tag. Aug 23 15:39:54 Or better yet, just have appropriate landscape layouts. Aug 23 15:39:58 ==lov Aug 23 15:40:07 apps that force orientations suck Aug 23 15:40:07 :) ok Aug 23 15:40:29 I have a round ImageButton with a transparent square edge around it, how would you recommend hiding the edge? I have tried to set the background colour but to no avail, the button is still square Aug 23 15:40:34 I really liked the everyme app though Aug 23 15:43:36 Sorted it out :) Aug 23 15:43:56 hrmph, is it impossible to charge this Asus Transformer while connected to USB for debgging? Aug 23 15:44:20 oh, guess not. lame. Aug 23 15:45:17 shouldagotanexus7.jpg Aug 23 15:45:19 Is there a slick way to restart an app? Aug 23 15:45:40 It looks like some recommend just starting a new intent and running finish. Aug 23 15:45:54 Activity#recreate(), but it's only API 11+ Aug 23 15:45:54 something with addFlags( Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_SINGLE_TOP); Aug 23 15:46:47 I'm strictly minSdkVersion="15" Aug 23 15:47:59 then use Activity#recreate() Aug 23 15:48:16 also, that's not restarting an *app* Aug 23 15:52:51 does anyone has experience with https://github.com/BoD/android-switch-backport#readme Aug 23 15:53:00 its basically a back-port of switch Aug 23 15:54:37 at first I thought you were saying it was a backport of the switch() {} construct and I was like "uhhhh...." Aug 23 15:54:50 evancharlton: :) Aug 23 15:55:03 I was wondering if holoeverywhere already has it too Aug 23 15:55:54 IIRC, you can get the switch L&F with nothing more than styles on a checkbox Aug 23 15:56:43 anyone know what woudl cause this to be called after the purchase finished? void onRequestPurchaseResponse(RequestPurchase request, ResponseCode responseCode); Aug 23 15:56:55 wait is that an internal class Aug 23 15:56:55 fuck Aug 23 15:57:22 no wait that's from google Aug 23 15:58:17 evancharlton: checkbox? Aug 23 15:58:46 evancharlton: But you can't drag the switch if it's a checkbox! Aug 23 15:58:54 canadiancow: pull yourself together man Aug 23 16:01:03 lol Aug 23 16:06:01 what would cause: Aug 23 16:06:08 08-23 12:01:51.865: D/Finsky(23574): [1] MarketBillingService.sendResponseCode: Sending response RESULT_OK for request 5155322440647497333 to com.package.name. Aug 23 16:06:27 this purchase may hve happened at some point, but if so, it was a long time ago Aug 23 16:11:16 lov, Thanks for your help, it has been appreciated :) Aug 23 16:11:52 Mechdave: np Aug 23 16:19:08 this is kind of a long question, but any ideas? http://stackoverflow.com/questions/11996409/how-can-i-fix-jumpy-android-rendering-performance-due-to-gpu-throttling-i-dont Aug 23 16:19:37 in a nutshell, I have an opengl wallpaper that gets really jumpy framerates on older phones... I don't care if I get a lower framerate, I just need it to be more consistent Aug 23 16:19:47 Can you paint half a pixel one color and another pixel a different one? or is that not possible Aug 23 16:20:01 for anyone using eclipse juno + ADT - does it seem to have stabalized at this point? Aug 23 16:25:15 bear pixels are fundamental units.. you can make the pixel an average of the 2 Aug 23 16:25:47 bear10, even Aug 23 16:26:10 xorgate, not sure what you mean Aug 23 16:26:11 Makes you wonder what he did to the othe r9 Aug 23 16:26:23 oh average of the 2 Aug 23 16:26:39 xorgate, im mainly wondering because im learning how to game program, and im confused as to how you target different resolutions Aug 23 16:27:12 targeting different resolutions is generally done not on the pixel-pushing level Aug 23 16:28:13 xorgate, where it it usually done? Aug 23 16:28:55 Bear10 imagine you have a 'view' level. say you have a 3d world, then you need to define a camera Aug 23 16:28:56 resources Aug 23 16:29:16 xorgate, even easier it's 2d :P Aug 23 16:29:52 im assuming you want to figure out how to draw a certain tile at a certain place Aug 23 16:30:09 it's all pretty complex Aug 23 16:30:20 xorgate, well right now the "draw a tile at a certain place" im doing it by multiplying tile# * width for the x Aug 23 16:30:37 well column # * width for x, androw # * height for y Aug 23 16:30:38 i'm sure this talk can help a bit http://www.youtube.com/watch?v=7-62tRHLcHk Aug 23 16:30:52 the problem im running into is the scaling for different screen resolutions, they show different number of tiles (which is understandable Aug 23 16:30:56 ok but you need to remember that on a small phone you will see fewer tiles Aug 23 16:31:16 so maybe you want to zoom them out a bit Aug 23 16:31:25 ah yeah zooming could help would that be possible? Aug 23 16:31:37 if you use opengl it's free Aug 23 16:32:14 * Bear10 uses the surfaceview Aug 23 16:35:37 xorgate, watching the video Aug 23 16:35:43 hopefully it helps hehe, its 1 hour xd Aug 23 16:35:52 that guy also made another vid Aug 23 16:37:37 I have a api jar which has a service class that basically takes 4 parameters and computes a value. For such a use case the design should be just an activity or do I need to have service ? Aug 23 16:38:36 the api reads xml file and loads in data structure so when queries it and computes things based on param passed. Aug 23 16:39:20 I was thinking that whats advantage of creating the api as android service and if I do so how do I pass the params to service ? as Intent ? Aug 23 16:39:45 mms_: using a service or not is mostly determined by whether there is a single user interface that will be interacting with the class or not. Aug 23 16:40:11 TheTrash: as such single interface meaning single app Aug 23 16:40:36 If you have more than one screen and the operations are long-running and more than one screen needs to be aware of the status of the operation, a service might be worth it. Aug 23 16:40:39 well may be other apps if they wish to use it better I convert it to service then Aug 23 16:40:59 If you want to make it available to other apps, then yes, a service would work. Aug 23 16:41:18 well I think that if I make it service in sense of j2ee service then any web tier like activity or other service can leverate it Aug 23 16:41:49 Android services have a somewhat more limited scope. Aug 23 16:41:54 But it could still be useful. Aug 23 16:42:18 well in web programming we submit form and it available to framework to our action class...here how do we pass the data from activity to service ? Aug 23 16:42:22 You can't really have it active as a web service or SOAP thingy, though, that'd drain the battery probably. Aug 23 16:42:25 Intents Aug 23 16:42:54 Intents is like HttpRequest that I can call getParameter(name) Aug 23 16:43:16 I read some where Intent is for limited data passing Aug 23 16:43:18 No not quite Aug 23 16:43:34 Yes that's sort of true, though you can pass complex types with some work. Aug 23 16:43:48 well then say I have four parameters to pass and three get requests to make to populates 3 lists then how to do it ? Aug 23 16:43:51 Read up on it to see if it's what you want. Aug 23 16:44:40 JakeWharton: are you aware of the problem that the method getItemId(int) inside FragmentPagerAdapter.java isn't included in the android support package v4 that ships with the current release of abs ? Aug 23 16:44:46 Just know that you're going to introduce quite a lot of programming overhead, so if it's basically your app parsing some file, it's much, much easier to just do it in an Activity. Aug 23 16:45:05 My app is kind of displayed here if you can visualize it http://imagebin.org/225101 Aug 23 16:45:38 mrmaffen: i am Aug 23 16:45:48 I have in xml file the categories, from and to list data Aug 23 16:45:54 kk good Aug 23 16:45:55 it's also not a problem Aug 23 16:46:03 at least not with ABS Aug 23 16:46:11 the lists are cascaded and then when I enter value I see results Aug 23 16:46:12 i've just copied the newest support package into abs libs folder Aug 23 16:46:13 works now Aug 23 16:46:22 sounds good to me Aug 23 16:46:43 manual dependency management in 2012, so elegant Aug 23 16:46:50 TheTrash: took a look ? Aug 23 16:46:51 kk ... by the way ... i wanna thank you for your awesome work ! abs is the shit :) Aug 23 16:47:13 haha thanks. do you have any released apps that use it? Aug 23 16:47:33 not yet released ... i'm currently working on it Aug 23 16:47:48 TheTrash: sounds to me that if I make it service it will be useful to other apps also if they like Aug 23 16:48:12 mms_: looking at that... at least for your own app, there's no need to do it in a service (but I would thread it if calculations are potentially heavy). If you want to offer that functionality to other apps you could consider it, but I'd probably still use a local instance of the class in the app itself and leave the service exclusively for other apps. Aug 23 16:48:13 but since new to android I am trying to understand how to break it up and how to get the communication done Aug 23 16:48:39 mrmaffen: cool. well good luck. let me know when you release so I can check it out! Aug 23 16:49:03 can you point me to a page where I can easily learn how to pass submitted form params to service ? Aug 23 16:49:06 JakeWharton: thanks man ... i'll definitely let you know Aug 23 16:49:34 http://developer.android.com/reference/android/app/Service.html Aug 23 16:49:41 meaning in andriod I will have button click and then collect all data from widgets and then pass on to service Aug 23 16:49:48 Somewhere that links to intent. Aug 23 16:50:05 Well, that's a bit broad, start with the tutorials, I guess. Aug 23 16:50:25 Just keep in mind service = layer of complexity, especially if you're new. Aug 23 16:51:14 anyone here use Robolectric? I'm having an issue with progressBar.setIndeterminate(). I'm trying to set it to true, but it remains false. It only happens when in a test with Robolectric. Running the app in a device/emulator is fine Aug 23 16:51:54 TheTrash: I got it...Message seems to be android api class like HttpReqeust ? Aug 23 16:53:13 Sort of, though it doesn't have much to do with http or any network connectivity. Aug 23 16:54:23 It has more in common with message queueing system jobs. Aug 23 16:54:52 But it's not much more than an id (on which you switch so you get to the right piece of code) and a payload. Aug 23 16:55:01 I want to know if I can fill the message with my params in the button click handler and service can get it how ? Aug 23 16:55:36 I am looking to that bit of piece on how to publish and how to fetch it Aug 23 16:56:56 the service will register callbacks with system which the client will invoke with intent ? Aug 23 16:57:21 but exactly how is payload sent ? Aug 23 16:57:28 and receieved... Aug 23 16:57:34 any simple example ? Aug 23 16:57:42 Look, just read that code, it's a pretty simple example. Aug 23 16:59:17 ok sounds like I need to use local service ? Aug 23 16:59:57 It's pointless to use a local service in your case. Aug 23 17:00:46 ok...I do not see client for service here Aug 23 17:01:05 Since you don't seem to have any operations transcending multiple screens, and a local service doesn't accept connections from outside the app. Aug 23 17:01:20 ok I get it ...I need remote... Aug 23 17:01:28 where is client side of this example ? Aug 23 17:02:11 i cant get my g1 to sign in to google Aug 23 17:02:25 it has an active sim and is connected to wifi Aug 23 17:02:26 The last piece of code before Summary. Aug 23 17:02:27 try signing in to iTunes Aug 23 17:02:48 if i even had an apple account Aug 23 17:02:51 I see messenger ...may be that Aug 23 17:03:54 problem is the example does not show imports so I cannot figure out if they are api class or user developed class Aug 23 17:04:13 Yeah that's somewhat annoying.. most of that is imported, though. Aug 23 17:04:38 All user classes are inline anyhow... see class IncomingHandler extends Handler { for instance Aug 23 17:05:22 strange things I see like the connection class is weired Aug 23 17:05:29 mConnection Aug 23 17:05:57 It's all inline class body. Aug 23 17:06:05 Into mConnection as a member variable. Aug 23 17:06:29 All java, be it somewhat obscure and not very scalable. Aug 23 17:06:44 But it makes sense on Android sometimes. Aug 23 17:07:36 I see the class but where is it used ? Aug 23 17:08:13 doBindService and doUnbindService Aug 23 17:09:52 no one calls the methods ? Aug 23 17:10:35 I would expect client to say socket.connect and get stream and write to it Aug 23 17:10:48 Yes. It doesn't remotely work like that :) Aug 23 17:11:04 that whats the strategy here ? Aug 23 17:11:51 we say hey android I am client registering my bind method ....and here is remote service name...once you connected ....call my bind method ? Aug 23 17:12:17 Well, you'd call doBindService and doUnbindService from your Activity somewhere. Aug 23 17:12:29 ok then it makes sense... Aug 23 17:12:35 same as socket.connect Aug 23 17:12:49 so we need to explicitly initiate connection Aug 23 17:13:22 but its still via callback Aug 23 17:13:46 bind is registering the mConnection as callback Aug 23 17:14:19 ok do we have the sample activity for this example ? Aug 23 17:14:29 then it will be complete Aug 23 17:14:45 mms_: yes, but furthermore it assigns the service's Messenger to mService. Aug 23 17:16:23 http://developer.android.com/guide/components/services.html see that as well Aug 23 17:16:31 I don't think there's a complete example for those docs. Aug 23 17:16:42 http://developer.android.com/tools/samples/index.html that might have an example of a service, though. Aug 23 17:18:57 Messenger is api class ? Aug 23 17:19:25 I think I need to read better client server tutorial Aug 23 17:19:51 any suggestion on it ? Aug 23 17:20:30 Not really, I mainly used the tutorials there and played with them until I figured it out. Messenger is builtin, yes. Aug 23 17:21:24 on that page you pointed how can I quickly search the api to locate the class ? Aug 23 17:21:53 hi, I am using android 4.0 and I want to be able the change the background of the tabs of an actionbar Aug 23 17:21:56 http://i.imgur.com/YksnY.png Aug 23 17:22:02 mms_: see the magnifying glass in the upper right hand corner? Aug 23 17:22:06 That is the tabs shown in the picture above Aug 23 17:22:10 ok let me try Aug 23 17:22:12 how can I do this? Aug 23 17:22:35 mms_: it's linked a few times when it's mentioned in the tutorial. Aug 23 17:22:43 So yes, control-F until you find a linked one. Aug 23 17:22:57 ok Aug 23 17:23:08 I think that magnifier search also is good Aug 23 17:23:13 quicky gets me to it Aug 23 17:24:39 so messenger has both read and write methods ? Aug 23 17:24:44 I see send Aug 23 17:24:53 I do not see receive Aug 23 17:24:54 is there a way to echo variables in Android.mk Aug 23 17:25:02 see read/write Aug 23 17:25:29 read is to receive Aug 23 17:25:43 why dont Aug 23 17:25:46 you type on Aug 23 17:25:50 a single sentence Aug 23 17:25:52 so that Aug 23 17:25:54 it's not a Aug 23 17:25:56 pain to read what your Aug 23 17:25:57 writing Aug 23 17:26:18 nice one lov Aug 23 17:26:43 or anyone to get a dump of the variables? Aug 23 17:27:40 kind of confusing things...it says send message to this messengers handler ? Aug 23 17:27:58 where is the nkd room? Aug 23 17:28:00 oh well I will need to read this site bit more to connect things...thanks guys... Aug 23 17:34:52 Hi, I need someone experienced with ASyncTask, and has Skype. Is anyone here available? Aug 23 17:35:07 I get stuck often, and I hate keep having to come on here and ask every time Aug 23 17:35:11 just ask here Aug 23 17:35:16 no one is going to chat with you over skype about it Aug 23 17:35:26 unless you feel like paying contractor rates for help Aug 23 17:35:32 in which case I can skype with you for $200/hr Aug 23 17:35:40 o_o Aug 23 17:36:47 I'm spawning a thread in a service that reads audio data and my main activity becomes unresponsive, is this a bad thing to do? Aug 23 17:37:00 Well, my problem is the following Aug 23 17:37:00 http://i.imgur.com/NNWu0.png Aug 23 17:37:14 I am confused on how to achieve that Aug 23 17:37:18 porten: you should be spawning a new thread. I don't know why your main thread is getting blocked, though. Aug 23 17:37:32 I need to get the user's location and pass it to the ASyncTask Aug 23 17:37:50 use LocationManager to get the user's location. Aug 23 17:37:51 hmmmmm... Aug 23 17:38:05 Make sure that your code will handle async callbacks, since it might take a few seconds to get a position. Aug 23 17:38:25 porten: attach the debugger. When your activity is getting blocked, pause the main thread w/ the debugger, look at the call stack. Aug 23 17:38:30 its Async Task btw, not A Sync Task Aug 23 17:38:36 porten: what method are you using to start the thread? Aug 23 17:39:36 lov: Callbacks? Which are those again -_- Aug 23 17:39:55 ._. Aug 23 17:40:08 they're what you're not getting on your job interviews! :D Aug 23 17:40:15 :D Aug 23 17:40:19 *ba dum tss* Aug 23 17:40:20 Not bad :) Aug 23 17:40:50 But seriously... ._. Aug 23 17:41:08 http://www.javaworld.com/javatips/jw-javatip10.html Aug 23 17:41:28 seriously though you're going to be implementing your own LocationListeners, on which you'll get callbacks. Aug 23 17:41:38 Ah Aug 23 17:41:38 you'll also need to handle the case of not ever getting callbacks, of the user turning off the gps, etc. Aug 23 17:41:49 wongk: I'm using run() Aug 23 17:41:53 point is that you'll have to deal with asynchronous project flows Aug 23 17:41:55 porten: bzzzt Aug 23 17:41:57 porten: you're doing it wrong Aug 23 17:41:58 porten: you want start() :( Aug 23 17:42:05 run is the method that's run on the thread Aug 23 17:42:08 start() actually starts the new thread. Aug 23 17:42:22 porten: make sure you understand why it's wrong before proceeding Aug 23 17:42:35 you're just creating a new thread object and then calling its run method instead of actually having that new thread start and go off on its own Aug 23 17:43:41 Ok, i'm looking at the doc now Aug 23 17:44:43 porten: http://docs.oracle.com/javase/tutorial/essential/concurrency/index.html Aug 23 17:44:46 You should read that. Aug 23 17:45:51 What can I use, instead of "ProgressDialog.show(mapScreen.this" on an external class? Aug 23 17:45:55 The mapScreen.this bit?> Aug 23 17:46:04 huh? Aug 23 17:46:52 I want to show a ProgressDialog from an ASyncTask in an external class Aug 23 17:47:04 Aaaand that rhymes ._. Aug 23 17:47:39 do that in onPreExecute() Aug 23 17:47:45 I am doing Aug 23 17:47:53 But what should the first argument be? Aug 23 17:48:00 Your activity Aug 23 17:48:16 How do I address it? Can you give me an example? Aug 23 17:48:23 lov: thanks I'm not sure why I overlooked that, sorry Aug 23 17:48:28 calling run vs start Aug 23 17:48:42 hope I can get the plus.google.com/americancow vanity url Aug 23 17:49:04 holy shit Aug 23 17:49:12 stop it Aug 23 17:49:14 lov: this is kind of wierd, the thread actuall worked but the main thread became unresponsive Aug 23 17:49:25 and start has VMThread.create(this, stackSize); Aug 23 17:49:26 you get so flustered that it becomes hard to stop Aug 23 17:49:38 it's like when someone doesn't like you format your comments Aug 23 17:49:41 ? Aug 23 17:49:46 so you make stupider formatting decisions Aug 23 17:51:09 How do I do it? Aug 23 17:53:42 mooo Aug 23 17:56:15 hmm, I see that JPEGs written from the camera have proper exposure time in the Exif data but I wonder how to get at this from Java at the time the photo is taken Aug 23 17:56:45 I have a class called mapScreen, which is also an activity. I also have a class called placeManager. mapScreen.this doesn't work from placeManager in an ASync Task inside onPreExecute(). It says that there is no enclosing type of mapScreen in the scope when I use it inside ProgressDialog. Aug 23 17:57:04 What do I use instead of mapScreen.this? Aug 23 17:57:21 you learn how to write java. Aug 23 17:57:25 that's what you do. Aug 23 17:57:32 you understand what scope is Aug 23 17:58:02 Ok :P Aug 23 17:58:09 Can you tell me what you put in there though? Aug 23 17:59:30 I'm not going to tell you how to copy/paste your way through this. Aug 23 17:59:49 I could pass the context to the execute method Aug 23 18:00:16 Would that work? Aug 23 18:00:16 just run everything on the UI thread Aug 23 18:00:22 what could possibly go wrong? Aug 23 18:00:24 evancharlton: xD Aug 23 18:00:29 use handlers man Aug 23 18:00:31 evancharlton: This is a HTTPGet Aug 23 18:00:32 handlers fix everything Aug 23 18:00:39 ManHandlers are hot Aug 23 18:01:03 Can I see some example code? Aug 23 18:01:05 tcial: oh I can solve that, make sure you target api level 6 so it lets you do HTTPGet on the UI thread Aug 23 18:01:23 americancow: Is that safe? Aug 23 18:01:39 The idea of ASyncTask is safety / security? Aug 23 18:02:07 its safer than filling up a toilet bowl with pirahnas and taking a poo Aug 23 18:02:29 You need to put it in your jeffrey's tube first Aug 23 18:02:43 Seriously -_- Aug 23 18:03:49 i am not in the mood for serious answers today Aug 23 18:04:01 i apologize for the inconvenience Aug 23 18:04:17 he may apologize, but he doesn't mean iut Aug 23 18:05:06 drat, 1 letter too many Aug 23 18:05:30 lol Aug 23 18:05:48 i seem to have a little mikedg in my canadiancow Aug 23 18:06:03 :( Aug 23 18:06:17 That's not even funny, mericanmikecowdg ;/ Aug 23 18:08:12 So nobody is willing to help me on skype? Aug 23 18:08:28 lov is, for $200/hr Aug 23 18:08:31 is that a euphamism Aug 23 18:09:46 tcial: seriously, this is a beginner java issue, this isn't an android issue. Aug 23 18:09:49 you should go to #java Aug 23 18:10:00 mention that you want to reference one class from another class Aug 23 18:10:08 And then everyone will laugh Aug 23 18:10:14 i want to start toying with GCM Aug 23 18:10:18 well we're already laughing at you Aug 23 18:10:22 tcial: everyone is laughing hear too Aug 23 18:10:37 mikedg: Nice spelling :) Aug 23 18:10:39 i think a few of us even high fived Aug 23 18:11:35 o/ Aug 23 18:11:56 Can't someone just help me please Aug 23 18:12:15 i here people laughing Aug 23 18:12:17 its hilarious Aug 23 18:12:22 :/ Aug 23 18:12:46 I can't use the "new mapScreen", as that would re-create it Aug 23 18:12:52 tcial: we're trying to gently tell you that your issue is not an android issue, it's a java issue, and you need to learn java before you can use android. Aug 23 18:13:11 If you aren't clear why "mapScreen.this won't work", you need to understand what OO is. Aug 23 18:13:18 this is a prerequisite Aug 23 18:13:25 it is an absolute firm requirement Aug 23 18:13:29 lov: Can you explain the problem, please Aug 23 18:13:39 the problem is that you don't understand what classes and instances are firmly Aug 23 18:13:42 lov: I would use mapScreen ms = new mapScreen(); Aug 23 18:13:47 please don't. Aug 23 18:13:53 never actually create new activities yourself. Aug 23 18:13:54 lov: Exactly, I didn't think it would work Aug 23 18:13:56 it doesn't do what you want it to do. Aug 23 18:14:08 the point is that you don't understand what "mapScreen.this" actually MEANS Aug 23 18:14:23 I know :( Aug 23 18:14:25 until you actually understand scope and object instanciation, you're just going to keep fumbling. Aug 23 18:14:29 :/ Aug 23 18:14:34 we'll solve this by telling you what to type Aug 23 18:14:34 How long do those take to learn? Aug 23 18:14:40 and then you'll just stumble on something else Aug 23 18:14:44 days? years? I don't know. Aug 23 18:14:49 :( Aug 23 18:14:53 seriously though you need to learn java. Aug 23 18:15:04 I know intermediate java Aug 23 18:15:08 I just don't get that Aug 23 18:15:21 you don't know intermediate java if you don't understand why this doesn't work. Aug 23 18:15:35 -_- where can I learn this Aug 23 18:15:46 http://docs.oracle.com/javase/tutorial/java/javaOO/index.html Aug 23 18:15:46 when i call TelephonyManager.getNetworkType and it returns NETWORK_TYPE_CDMA is that cdmaone? or cmda2000? or? Aug 23 18:16:03 in general http://docs.oracle.com/javase/tutorial/java/index.html and http://docs.oracle.com/javase/tutorial/essential/index.html Aug 23 18:16:07 these are STARTING POINTS. Aug 23 18:16:41 I have read the starting points -_- Aug 23 18:17:31 I understand OOP, I just don't get the .this part Aug 23 18:17:36 It's referencing the class mapScreen Aug 23 18:18:52 [14:05:48] i seem to have a little mikedg in my canadiancow Aug 23 18:18:56 Can you just not tell me why mapScreen.this isn't working Aug 23 18:18:56 why are you so interested in getting in me Aug 23 18:19:12 im never accepting a drink from you again Aug 23 18:19:13 ever Aug 23 18:19:17 unless it's free Aug 23 18:19:19 because mapScreen.this is useful for having an inner class reference an outer class Aug 23 18:19:20 lol! Aug 23 18:19:29 the inner class has a synthetic reference to the outer class Aug 23 18:19:40 mapScreen.this is roughly the same as writing this.this$0 Aug 23 18:19:56 Your other class, whatever it is, is (I'm assuming) not actually an inner class Aug 23 18:20:02 thus it doesn't already have a reference to that class Aug 23 18:20:21 you need to pass a reference to your activity. However, I advise extreme caution in doing this because you can leak activities without realizing it. Aug 23 18:20:38 Thankyou for explaining it :) Aug 23 18:22:18 Would you say 'new placeManager(mapScreen.this);' is ok? Aug 23 18:22:22 When I create it to call it Aug 23 18:22:37 It seems to work :) Aug 23 18:22:50 by the way Aug 23 18:22:58 your class names should start with an uppercase letter Aug 23 18:23:11 You should probably read this: http://geosoft.no/development/javastyle.html Aug 23 18:23:27 Oh Aug 23 18:23:37 >_< I've been using that naming convention Aug 23 18:23:42 I've forgotten what it's called though :D Aug 23 18:23:45 alternately, http://www.oracle.com/technetwork/java/javase/documentation/codeconvtoc-136057.html Aug 23 18:23:49 it's called camelCasing Aug 23 18:24:00 and you should continue to use it, but your classes should have their first character capitalized Aug 23 18:24:03 yup, that one Aug 23 18:24:06 And OK :) Aug 23 18:24:57 lov that document says to do private Object field_; Aug 23 18:24:59 Renamed them :0 Aug 23 18:25:01 dislike :( Aug 23 18:27:10 tcial: consider also http://source.android.com/source/code-style.html Aug 23 18:32:27 Can I show a Toast inside a doInBackground Aug 23 18:32:55 tcial, No. Aug 23 18:33:03 lut4rp, thanks :) Aug 23 18:33:22 :) Aug 23 18:34:18 Is it OK to do an conditional return statement before catching exceptions? Aug 23 18:34:28 Oh waitr Aug 23 18:34:29 DERP Aug 23 18:34:31 Nevermind :P Aug 23 18:38:58 I wonder people are reluctant to use holo theme on older devices, although decent backport are available Aug 23 18:39:31 are they worried there user's will complain "where is my ugly progress bar!, I want it back!!" Aug 23 18:45:36 what are some good options for high fps video capture of phone interaction? e.g. for demo videos? Aug 23 18:45:42 obviously would turn on "Show touches" Aug 23 18:45:46 just use an HDMI capture card? Aug 23 18:45:52 assume galaxy nexus is phone in use Aug 23 18:47:15 Rockmaninoff: yes, HDMI capture card Aug 23 18:47:23 ok Aug 23 18:47:33 I'm developing a landscape-only game, and I'm running into an issue where if I lock the screen, rotate to landscape mode, then unlock the screen-- the GL surface rotates back to landscape, but gets cut off and stretched weird.. Aug 23 18:47:39 would that also capture the device audio? e.g. if i were running a radio app? Aug 23 18:47:44 or music playing app Aug 23 18:47:45 etc Aug 23 18:48:04 I've managed to mitigate this issue by setting up a call to refresh the GL surface from a timer, triggered by onwindowstatechange Aug 23 18:48:14 the problem is, every device takes a different amount of time to do this rotation Aug 23 18:48:29 how do i add parameters to a url when loading with a webview, like i need response_type=token Aug 23 18:48:39 and I'd rather not refresh the GL surface upwards of 1000ms for the worst of devices (htc one x), on all devices Aug 23 18:48:44 just urlblabla&reponsetype=token? Aug 23 18:48:56 rather not delay the refresh of gl surface for 1000ms* Aug 23 18:49:19 Does anyone know of a callback that is triggered on screen rotate after an onwindowstatechange? I'm not seeing anything in adb logs Aug 23 18:53:30 hi, i'm using actionbarsherlock in my app, i've just upgraded to the latest version of this library and now i cannot export any application to upload to the market Aug 23 18:53:55 does anyone have a problem like this? Aug 23 18:54:13 are your support library versions in sync? Aug 23 18:54:38 i downloaded it from jack's site Aug 23 18:54:55 the older version worked fine Aug 23 18:55:02 jake Aug 23 18:55:09 sorry Aug 23 18:55:10 but you didn't answer my question Aug 23 18:55:20 i don't know what you mean Aug 23 18:55:27 sync? Aug 23 18:55:38 is the support library in your app's libs folder the same version as the one used by ABS Aug 23 18:55:49 Wouldnt he get a console error saying the libraries are not the same? Aug 23 18:55:59 i assume so Aug 23 18:56:05 i load it as a library in the properties of my app Aug 23 18:56:13 i don't use a libs folder Aug 23 18:56:23 should i? Aug 23 18:56:27 can you build successfully w/o exporting? Aug 23 18:56:35 yes Aug 23 18:56:41 and run the app in the emulator Aug 23 18:56:48 then i don't know what the issue is Aug 23 18:56:55 what's the error it gives you Aug 23 18:56:55 my app is eating about 50MB of ram, that sounds a lot for a app with couple of listviews Aug 23 18:57:27 hprof looks really weird Aug 23 18:57:27 https://groups.google.com/forum/?fromgroups#!topic/actionbarsherlock/k9k2QwWrIGY Aug 23 18:57:37 Conversion to Dalvik format failed with error 1 Aug 23 18:58:03 anyone? I'm having difficulty in tracking down a callback that is triggered on a forced rotation change when switching between portrait and landscape after unlocking the screen Aug 23 18:58:17 onstatechange does not appear to get triggered Aug 23 19:17:15 onConfigurationChanged? Aug 23 19:19:57 has anyoen had any problems with in-app billing lately? Aug 23 19:20:24 zynga knows that you're leaving and they revoked your CC Aug 23 19:20:57 lol Aug 23 19:25:43 Hi there people Aug 23 19:35:47 JesusFreke: i have finally been able to compile an executable from chroot ubuntu Aug 23 19:35:59 It runs on phone but sort of... Aug 23 19:36:14 Therebis no output.. Aug 23 19:36:19 There is* Aug 23 20:05:35 Overflow menu(one which appears when you click overflow action) is not properly aligned and item text is truncated, only first two letter from item is shown. does any1 know when it can happen? Aug 23 20:06:35 how can I disable/delay the screen lock? KeyguardManager is depreciated/doesn't work consistently, FLAG_DISMISS_KEYGUARD is not an option because this will run in the background and I don't want to use a WakeLock for battery reasons. Aug 23 20:07:41 Bink: What exactly are you doing? Aug 23 20:08:38 I simply want to disable/delay the screen lock when the phone connects to my Wi-Fi at home. Aug 23 20:09:33 ah, as in change the system behavior, not change how the system behaves when your app is in the foreground Aug 23 20:09:38 sacdroid: on the bottom action bar? Aug 23 20:09:43 I'll bet the APIs limit stuff like that pretty hard Aug 23 20:10:29 jrr: if that was for me, yes. in theory, I don't even need a UI. Aug 23 20:10:53 Bink: there's an app in the play store that disables the lock screen, so it must be possible Aug 23 20:11:06 wongk: doesnt matter which overflow button you click, overflow menu dropdown is not properly 60% of it goes out of screen on right side. Aug 23 20:11:19 is not properly aligned* Aug 23 20:11:30 sacdroid: oh, that's a different issue, then Aug 23 20:11:37 does tasker do it? Aug 23 20:11:48 wongk: I've looked, and many of these have issues with ICS and JB (KeyguardManager being depreciated). Aug 23 20:12:03 Bink: ah Aug 23 20:12:21 Bink: you may have to study the framework to see if you can find an exploit Aug 23 20:12:28 jrr: I've heard it can, but don't think it can under 4.0 and higher. Aug 23 20:12:39 wongk: I've looked/is why I'm here. Aug 23 20:12:59 well if that didn't get you anywhere, there's not much we can offer :P Aug 23 20:13:34 I was hoping someone knew more than I (as almost always someone does). Aug 23 20:14:58 hey guys, im reading the android documentation and this stuff on worker threads doesnt work right Aug 23 20:15:09 http://developer.android.com/guide/components/processes-and-threads.html Aug 23 20:15:30 Bink: yeah, unfortunately you're pretty far off the beaten path with this one Aug 23 20:15:48 kingargon: in what way Aug 23 20:15:53 though i've not heard of deprecated APIs no working in newer releases Aug 23 20:16:14 that just means you shouldn't use them Aug 23 20:16:18 the onClick example Aug 23 20:16:41 it never runs Aug 23 20:16:41 Which one of them Aug 23 20:16:57 sry, the one with the .post handler Aug 23 20:17:11 its towards the bottom of the page Aug 23 20:17:16 Looks fine Aug 23 20:17:31 thats what i thought, but its not working right in my code Aug 23 20:17:42 Is the onClick method ever being called in your code? Aug 23 20:17:54 i was talking to someone here yesterday and they tried to help but we couldnt solve the problem Aug 23 20:18:08 yeah Aug 23 20:18:15 hold on ill post the code Aug 23 20:18:19 hi all Aug 23 20:18:33 wongk: KeyguardManager works, but the results are inconsistent under ICS/JB. and it's not like I can file a bug report on a depreciated API. Aug 23 20:18:43 nope Aug 23 20:18:55 http://developer.android.com/guide/components/processes-and-threads.html Aug 23 20:19:03 whoops Aug 23 20:19:04 http://pastebin.com/SziPBSEr Aug 23 20:19:34 my function runs after the handler Aug 23 20:19:44 but before the thread ends Aug 23 20:20:03 and than i call the thread. but the handler does not execute till way after both threads Aug 23 20:20:27 someone mentioned to me that onClick is a blocking operation Aug 23 20:20:42 You probably shouldn't join the thread Aug 23 20:20:49 That defeats the purpose Aug 23 20:20:57 than my code breaks if i dont Aug 23 20:21:06 Then you need to rethink your code Aug 23 20:21:44 join makes sure that the code executes before it returns right? Aug 23 20:22:14 makes sure the thread executes and blocks everything else right? Aug 23 20:22:20 join blocks till the thread finishes Aug 23 20:22:46 i didn't even know there was a java SPI for that :P Aug 23 20:22:50 API Aug 23 20:23:12 So you're blocking the ui thread while your thread, whose whole purpose was to not block the ui thread, finishes its work Aug 23 20:23:24 there's no point in using a thread here Aug 23 20:23:33 As I said, you should probably rethink what you're doing Aug 23 20:23:37 you're just starting one thread and blocking the original one Aug 23 20:23:48 still only 1 thread Aug 23 20:24:23 oH! Aug 23 20:24:54 mImageView.post posts the runnable to the ui threads message queue Aug 23 20:25:12 It isn't run immediately Aug 23 20:26:21 oh, how do i get it to update asap? Aug 23 20:26:33 It does update asap Aug 23 20:26:39 Once other work in front of it on the ui thread is done Aug 23 20:26:49 That includes your onclick method Aug 23 20:27:25 damn, is there any way to get it to change as soon as the button is clicked? Aug 23 20:27:37 Yes, by not blocking the ui thread Aug 23 20:27:48 ^^ Aug 23 20:27:54 but how are you suppose to detect the click? Aug 23 20:28:03 Your first thread does nothing Aug 23 20:28:05 Why is it even there Aug 23 20:28:06 if i cant use onClick Aug 23 20:28:30 i was told that the AudioRecord object should run on a seperate thread Aug 23 20:28:35 Look, don't join your threads.. you're blocking the ui thread Aug 23 20:28:50 im sry, im new to Java Aug 23 20:29:01 Blocking the ui thread means no clicks, no drawing, no further execution of anything that happens on the ui thread Aug 23 20:29:03 also, as I told you last night, if you want the setText to happen immediately, just put it in onClick Aug 23 20:29:06 It's more a multithreading thing than a java thing. Aug 23 20:29:45 The setText happens immediately.. Actually drawing the view is also a message posted to the ui thread.. That wont happen until after onClick finishes Aug 23 20:30:39 SimonVT: Actually, the way he has it coded, it won't, since it looks like it's posting the message to the UI thread Aug 23 20:30:56 at least, I assume Activities are created on the UI thread Aug 23 20:30:59 I was reponding to "if you want the setText to happen immediately, just put it in onClick" Aug 23 20:31:14 oh, sorry Aug 23 20:31:22 yeah, that's definitely true Aug 23 20:37:18 okay, follow up question, do i even need this thread object still? Aug 23 20:37:45 do you want to not block your gui? Aug 23 20:37:57 and have your users get ANRs? Aug 23 20:38:09 oh Aug 23 20:38:12 nope Aug 23 20:38:23 are you guys still talking about this? Aug 23 20:38:41 sry, this concept is kinda weird to me Aug 23 20:39:00 learn about multithreading first Aug 23 20:39:13 like some of my books say i should extend the class to thread or implement a Runnable Aug 23 20:39:45 and my other books just create the object without extending or implementing Aug 23 20:39:49 don't worry about the details until you get the concepts Aug 23 20:40:02 kingargon: are you just programming by guess-and-check? Aug 23 20:40:09 yes Aug 23 20:40:30 i guess so Aug 23 20:40:32 evancharlton: as if there's any other way. come on, you've seen stackoverflow. Aug 23 20:40:56 evancharlton invented stackoverflow Aug 23 20:41:04 You mean ctrl-c ctrl-v isn't programming? Aug 23 20:41:10 i spend a lot of time there on php stuff lol Aug 23 20:41:12 this google play infrastructure doesn't impress me with its reliability, or integration. Aug 23 20:41:21 is there a simple way to block orientation change on ALL of my activities? I know i can put the configchange in my xml and then define onConfigChange Aug 23 20:41:23 i activated my g1 again :) Aug 23 20:41:35 but that is a major pain in the ass, considering i have quite a lot of activities Aug 23 20:41:57 thanks btw SimonVt, ryanm, and wongk Aug 23 20:42:04 Sometimes get 500 ISE, can dismiss same messages multiple times, they appear each time anew, every integrated site looks quite different, and when I try to buy the newly published application I made for myself -- as a test, and to prove it works -- I get some 500 ISE during the order processing. Aug 23 20:42:15 really. This stuff looks rather amateurish to the outside. Aug 23 20:42:21 sonOfRa: it's a pain because it's supposed to be for edge cases Aug 23 20:42:27 not applied to every activity Aug 23 20:42:43 edge case: release tomorrow, no time to implement landscape layouts Aug 23 20:42:54 I understand the scale is large but I also see a new version of the developer console is in the works. I can only hope it's better written. Aug 23 20:42:59 an edge case is an edge case Aug 23 20:43:09 Being lazy is pretty standard Aug 23 20:43:12 you're not using it how it's designed to be used Aug 23 20:43:41 alankila: did you get my follow-up on that NSURLConnection research? Aug 23 20:43:43 sonOfRa: be a programmer and ctrl-c ctrl-v like SimonVT Aug 23 20:43:50 jasta: hmm... I think not. Was it here? Aug 23 20:43:56 yeah, thats whats happening right now Aug 23 20:44:07 alankila: i dont think so. no matter, i'm wrapping it all up into a blog post now Aug 23 20:44:07 I want to use PreferenceFragment, but I also need to support API <11 devices. I've been thinking of implementing it this way: http://pastebin.com/0dT9T96X Is there a better approach? I also attach listeners for preferences, any idea about how I could avoid dublicating code for that? Aug 23 20:44:38 alankila: the conclusion is big tho. the problem is systemic, present in tons of apps, and reproducibly inferior to Android's user experience in a huge number of cases. Aug 23 20:45:13 jasta: well, I hope apple is thankful for you arguing your case and they making the competition better :-p Aug 23 20:45:44 alankila: you can download just about any arbitrary app from the app store that has a login screen and see the problemi n practice. Aug 23 20:46:04 jasta, alankila: What's this about NSURLConnection? Aug 23 20:46:07 what problem, curiosity hs gotten ahold of me Aug 23 20:46:43 lov: iOS' NSURLConnection closes all idle connections after 12s, even https. iOS apps because of this create fucking HUGE numbers of connections and pay the round-trip penalty for https in particular over and over and over again Aug 23 20:47:17 oh nice Aug 23 20:47:19 you can actually observe the difference in performance this causes manually (that is, just eyeballing it) Aug 23 20:47:38 but also wireshark proves it with real numbers. Aug 23 20:48:06 hi Aug 23 20:48:07 the simplest repro case: find an app with a login page (i used amazon app store a lot), type bogus credentials, try to login. error pops up in about 1000ms. Aug 23 20:48:14 is the only way to get a SignalStregth object to register a listener and wait for it to change? no way to poll the current value? Aug 23 20:48:15 hit login again, pops up in ~100ms. Aug 23 20:48:21 wait 12s, do it again, side-by-side with an android phone Aug 23 20:48:32 the android phone will pop up the error in 100ms, the iphone 1000ms. Aug 23 20:48:49 (the symptom here being a representation of _EVERY_ use operation over https that is spaced by more than 12s) Aug 23 20:49:07 the browser is even crazier. omg, just sitting idly on facebook and browsing around a bit after causes sooooooo fucking many http connections Aug 23 20:49:38 mostly because it tries to optimize with a pool of http/https connections to various CDN hosts. but they all timeout so quickly they never get re-used. Aug 23 20:49:39 does anyone know if static fields in an Activity class remain when the Activity instance is destroyed onDestroy() ? Aug 23 20:49:50 note that it is hard to notice the latency for http, though. https is a different matter because of the number of roundtrips & the fact servers agree to very long keepalive on it Aug 23 20:50:05 http, yes, you can't observe with the naked eye. Aug 23 20:50:06 for instance, 4 minutes is quite common for https, whereas apache 2 defaults to closing http keepalive in some 15 seconds Aug 23 20:50:08 https, though, you can. Aug 23 20:50:31 alankila: understood, and we discussed this. my strongest argument is against the behaviour for https. Aug 23 20:50:36 although apache's way of doing things probably results from its inferior architecture Aug 23 20:50:37 xroberx: static fields maintain their values for the lifetime of the process Aug 23 20:50:47 * alankila hates apache and thinks it's poorly suited for modern web Aug 23 20:50:56 alankila: keep in mind protocols like SPDY _require_ SSL. Aug 23 20:51:19 wongk: so... ? Aug 23 20:51:31 xroberx: do you not understand my answer Aug 23 20:51:37 wongk: nope Aug 23 20:51:47 which part is confusing you Aug 23 20:51:54 do you know what a process lifetime is? Aug 23 20:51:59 apache's problem is that it hasn't grown up from its "we want to push files as fast as possible with a worker-per-client model" Aug 23 20:52:08 wongk: no Aug 23 20:52:16 do you know what a process is? Aug 23 20:52:53 wongk: well, actually I know what a process and its lifetime are, but I don't connect the idea with Android activities Aug 23 20:53:06 alankila: my mind is still tightly spun around this unbelievable conclusion that iphone apps are so stupidly inefficient with respect to HTTPS connections because of this... Aug 23 20:53:14 i can't believe no one noticed this at apple... Aug 23 20:53:15 android activities are irrelevant Aug 23 20:53:30 this is a simple programming concept Aug 23 20:53:36 it's not even specific to java Aug 23 20:54:28 well, apple engineers aren't perfect, if google's aren't either Aug 23 20:54:39 alankila: still, christ... Aug 23 20:54:48 alankila: i did notice something cute though Aug 23 20:54:52 xroberx: A process may have many activities. Aug 23 20:55:05 apple's push infrastructure uses a long-lived SSL connection to *.push.apple.com Aug 23 20:55:18 so obviously they're not using their own policies :) Aug 23 20:55:38 hmm, I guess I just can't enable FOCUS_MODE_CONTINUOUS_PICTURE - setParameters throws an exception Aug 23 20:55:48 is there no such thing as a push email client on iOS? Aug 23 20:55:52 well, perhaps it's part of a nefarious plan on making non-apple-services look and feel poor Aug 23 20:56:00 xroberx: create public static class CounterClass { public static volatile int counter = 0; } and then in each of your activities, get and increment the counter. Aug 23 20:56:08 xroberx: the result may surprise you. Aug 23 20:56:23 actually get rid of volatile, it's not needed if you just do this in onCreate everywhere. Aug 23 20:56:24 or a simple oversight. After all, iOS gained some infamy from preventing in-app embedded browsers from JITting javascript which makes that model of creating iOS applications inferior Aug 23 20:56:29 I suppose I could just make a background thread that calls autofocus every second or something Aug 23 20:56:39 it's easy to say that it's part of the platform wars Aug 23 20:56:42 alankila: that doens't sound like apple's style. sounds much more like Google (p.s. google does this across the board for all of their services) Aug 23 20:56:45 whether it is, is far harder to determine Aug 23 20:57:20 i mean non-apple-services looking and feeling poor. not taht thing about JIT. Aug 23 20:57:22 lov: I would expect the counter to be increased in each Activity... Aug 23 20:57:39 yep! Aug 23 20:57:52 alankila: my comment about google, btw, relates to the fact that google typically uses different web services, with better optimized endpoints and protobufs for their apps. they do not use the public APIs. Aug 23 20:57:55 xroberx: also, onDestroy doesn't affect data members in any way Aug 23 20:57:59 now if you put that counter in one of your activities, and have all your activities reference that counter, the same thing will happen. Aug 23 20:57:59 pretty much never do they use their own public APIs. Aug 23 20:58:10 xroberx: that's specific to android Aug 23 20:58:17 jasta: everybody is trying to work out how to get an advantage for the home team in this I guess Aug 23 20:58:28 Does anyone know of a callback that occurs as a window is force-rotated when unlocking the screen? IE unlock in portrait -> force rotate -> app in force-landscape Aug 23 20:58:38 google's case though is a bit different -- they are still 99 % advertising company. Aug 23 20:58:40 wongk: class members or instance members ? Aug 23 20:59:01 both Aug 23 20:59:04 so all they care about is collecting all your data, and getting the right eyeballs seeing the right advertisements. Aug 23 20:59:08 boo, FOCUS_MODE_CONTINUOUS_VIDEO makes setParameters throw an exception too Aug 23 20:59:11 the force rotate seems to be different for each device I use so I need a reliable callback that is triggered when the rotation finishes Aug 23 20:59:12 if by class members you mean static memebers Aug 23 20:59:16 is continuous focusing a hardware feature or something? Aug 23 20:59:24 and if that means they need to make an entire mobile operating system or do their best to make sure web is competitive as platform, so be it Aug 23 21:00:04 although the modern app store model certainly is very lucrative Aug 23 21:00:29 meanwhile, Windows 8... Aug 23 21:00:37 *cricket* Aug 23 21:00:55 if it works out, you collect 30 % tax just from the privilege of having people do stuff with each other in your juridsiction. No company can resist such a deal. Aug 23 21:00:59 what about windows 8 Aug 23 21:01:27 lov: what I need to know is: If I declare a static member on Activity A (my entry point Activity) and then switch to Activity B (calling finish() in Activity A), will the static member of Activity A remain ? Aug 23 21:01:41 It's static.. Aug 23 21:01:47 It's not tied to the instance of the activity Aug 23 21:02:34 a modern business plan is a lot like state government. It needs to do no actual work itself, and taps into the money flow that passes through it. Aug 23 21:03:16 and I got to say, the guys who made kickstarter must have made money like bandits. 3 % of everything that goes through it. I wonder how many millions it pulls in every month. Aug 23 21:03:52 SimonVT: yes, but what about the garbage collector ? Can I be completely sure it won't free the static member of the Activity when it is destroyed ? Aug 23 21:03:55 I imagine the 30 % app-store regime can't last. Someone is bound to outcompete it with 3 % or even 0.3 % cut and still be profitable. Same goes for kickstarter. Aug 23 21:04:13 dude, it's static Aug 23 21:04:19 learn what static means :P Aug 23 21:04:45 alankila, for $1 transactions, i doubt theres even much profit for a credit card transaction Aug 23 21:04:48 with a 30% deal Aug 23 21:05:03 like paypal charges something like 2.9% + $0.30 Aug 23 21:05:21 google takes no profit from play store transactions Aug 23 21:05:22 and ive used other merchant accounts that were similar Aug 23 21:05:30 it all goes to processing Aug 23 21:05:35 no Aug 23 21:05:42 if you buy a $10 app, it doesnt cost $3 to process Aug 23 21:05:46 wongk: maybe for the smaller ones yes Aug 23 21:05:56 it's a "published fact" Aug 23 21:06:06 see the developers blog Aug 23 21:06:55 wongk: well how could they have negotiated a deal where full 30 % goes to processing no matter what the transaction size? Aug 23 21:07:08 dude, they're google Aug 23 21:07:16 you mean, incompetent? Aug 23 21:07:28 yea no Aug 23 21:07:32 normal transaction fees are greater then normal app prices Aug 23 21:07:40 'Extended depth of field (EDOF). Focusing is done digitally and continuously.' . . . sort of wish I knew what that meant Aug 23 21:07:40 i'll believe that for a $1 transaction, the fee is 30% Aug 23 21:07:40 wongk: ah, you mean subsidizing Aug 23 21:07:43 but not for higher than that Aug 23 21:07:44 focusing... digitally? Aug 23 21:07:56 how do you think the play store gift cards work? Aug 23 21:08:01 the stores that sell them make a profit Aug 23 21:08:07 anyway, quittin time for me Aug 23 21:08:16 oh wait they avoid the credit card fee Aug 23 21:08:16 hah Aug 23 21:08:49 I guess this is a moot point because FOCUS_MODE_EDOF also makes setParameters throw an exception. Aug 23 21:08:54 Hrmph. Aug 23 21:10:18 might be that bitcoin eventually sets a new low in money processing cost though... the cost is paid by all participants who have other reasons to participate. Aug 23 21:11:01 last time I looked its fee structure was market-priced after a fashion with some trivial amount like 0.1 % to set aside for whoever processes it, and some transactions might go through with just round 0 % Aug 23 21:11:33 all that needs though is services, competent exchanges, and serious bitcoin economy size that isn't all about drug trading Aug 23 21:12:38 alankila: hey, it's not all about drug trading. Aug 23 21:12:43 alankila: you can buy hit men too. Aug 23 21:12:50 and probably blow jobs. Aug 23 21:12:54 lovely. Aug 23 21:37:20 in widgets can you catch longpress vs shortpress? Aug 23 21:37:30 I don't believe so Aug 23 21:37:38 longpress is going to end up moving the widget Aug 23 21:37:49 ooh, glad i asked Aug 23 21:49:06 Is there a way to remove the "Slide to unlock" feature on Honeycomb? Aug 23 21:49:37 not from Settings, but to actually uninstall it? Aug 23 21:51:18 s Aug 23 21:52:08 It's part of systemui, isn't it Aug 23 21:52:14 uh Aug 23 21:52:18 I'm gonna just say "no" Aug 23 21:52:24 ^_^ Aug 23 21:57:06 bummer, too bad Android UI in Action isn't fue out until … this time 2013 :/ Aug 23 21:59:49 hello. I just installed eclipse indigo on my ubuntu 12.04 and installed the sdk, but there is no R.java in my project and when I try to run it, it shows: "Failed to get the adb version: Cannot run program "/home/user/android-sdk-linux/platform-tools/adb": java.io.IOException: error=2, No such file or directory from '/home/user/android-sdk-linux/platform-tools/adb' - exists=true" Aug 23 22:00:04 I've set chmod 777 to the adb Aug 23 22:00:06 but nothing Aug 23 22:00:09 any idea? Aug 23 22:02:08 Did you install that 32bit lib? Aug 23 22:04:50 SimonVT, oh yeah! I guest its this, Aug 23 22:04:51 can I get an android.net.Uri instance to a .jar resource? Aug 23 22:04:55 which is the command? Aug 23 22:05:21 ia32-libs Aug 23 22:05:25 got it. lemme test Aug 23 22:11:40 e Aug 23 22:11:49 ouch Aug 23 22:14:45 looks like the merchant can't buy his own application. Well, now that I know that, I was able to confirm that my application can be bought from market normally. Aug 23 22:15:26 *sigh* it could give some useful info back instead of just "unknown error". It's like there's some really spartan APIs in use when they can't tell that sort of things Aug 23 22:15:44 Does anyone know of a quick pet project for creating a android app? Like a "Hello world" for android apps? Aug 23 22:16:15 I can only hope that google spares engineering resources on this matter. I've noticed to my pleasure that ADT now warns about common programming mistakes like creating a Toast without show() following it Aug 23 22:16:21 kyconquers: i think "hello World" has 5 stars in the market. it will be tough to beat. Aug 23 22:17:12 and it warns about stuff like when I made Handler that was inner class about how it will leak the memory. Not sure if it actually does, of course -- there seems to be no cleanup protocol for a Handler Aug 23 22:17:34 but the inner class would have probably kept the activity around Aug 23 22:17:49 g00s, is that a tutorial on how to make it? Aug 23 22:20:26 g00s, nvm I just checked it out. Aug 23 22:20:31 interesting http://www.theverge.com/2012/8/23/3262782/facebook-for-ios-native-app " embedding HTML 5 inside an app isn't what people expect." so much for the hybrid app Aug 23 22:20:48 also proguard is a bit odd. When your app has a native method, it's fairly obvious that just blindly renaming that will result in runtime linking failure. But why does it need me to configure that "no, please do not rename native methods"? makes no sense. Aug 23 22:21:19 proguard is like a sausage grinder Aug 23 22:23:28 wat Aug 23 22:23:30 proguard is the awesome Aug 23 22:23:40 g00s did you see the article about facebook and android Aug 23 22:23:45 and forcing employees to use android Aug 23 22:23:49 so the ycan see how shitty their app is Aug 23 22:23:52 hehe, yeah ! Aug 23 22:24:02 stright from zuckerberg Aug 23 22:24:06 *straight Aug 23 22:24:34 not that i have ever seen the FB app myself, XD Aug 23 22:24:41 i use it because my friends do Aug 23 22:24:46 and my colleagues, because of where i work :P Aug 23 22:25:00 oh yeah, you guys work with FB :P Aug 23 22:25:01 i think we're only second to FB for percentage of employees with a FB account Aug 23 22:26:19 do android devices really have 3d magnetic field sensors? because the Sensor javadoc implies it... Aug 23 22:26:22 even though i'm not on FB officially, i probably have a shadow profile like lots of other people Aug 23 22:26:27 TheJH_: typically yes Aug 23 22:26:46 TheJH_: it is required to establish an absolute orientation in space, though it only works properly outdoors and away from all metal Aug 23 22:26:48 TheJH_, just because a sensor is supported doenst mean devices will have it Aug 23 22:27:05 canadiancow, hmm, right Aug 23 22:27:32 TheJH_: but without magnetic field, you do not know where magnetic North is. Combined with your coarse location, a correction can be calculated that establishes the estimated direction towards true North Aug 23 22:27:51 this might be interesting in a mapping application for instance. Aug 23 22:28:00 I always wondered how the compass works - so it's really just three magnetic field sensors? Aug 23 22:28:11 that being said, most systems take direction from the GPS, which works far better as long as you are moving Aug 23 22:28:24 TheJH_: quite correct, one for each primary axis Aug 23 22:28:44 it measures the magnetic flux direction. Typically it is uncalibrated value and means nothing Aug 23 22:28:58 but combined with long-term collection of magnetic readings, you can calibrate it Aug 23 22:29:29 if the magnetic vectors represent the Earth field, and you use your phone, turning around, the magnetic vectors will fall on a surface of an ellipsoid Aug 23 22:29:31 * TheJH_ wrote an app that lets you manage a minecraft server remotely and now wants to add a "kick sword" feature where you first enter player name and angle pairs and then strike the phone in people's directions to kick them :D Aug 23 22:29:49 so you collect those and then do ellipsoid fit -- this is done by android's software somewhere for you -- and then you get something like the direction to magnetic North Aug 23 22:30:03 but it's very unreliable because of the complicated calibrations required Aug 23 22:30:12 and because EArth's field is so weak Aug 23 22:30:25 ok, thanks for the explainations Aug 23 22:31:15 I know too much about the topic :-p Aug 23 22:35:07 I personally would love to have some other means to determine direction. Perhaps phone's camera should use the time of day and camera to figure out where Sun is and establish orientation from the Sun vector. Aug 23 22:36:07 there should be multiple methods where the best could be chosen depending on the circumstances. No one method will be perfect, however. Sun would be great because it's so excessively bright that it can be determined from that Aug 23 22:36:17 but the bugger is below horizon half of the ay Aug 23 22:37:02 maybe polarization of sky could be used also. Anyway, just my musings when I battled with how difficult it is to work out the true orientation of device in universe coordinate system. Aug 23 22:37:32 (for my purposes, would be centered on sun, not rotating.) Aug 23 22:40:52 anyway, whatever birds do, humans should do also. They have this shit down. Aug 23 22:42:19 alankila: i thought birds see magnetic fields :) Aug 23 22:42:42 not see, but sense, allegedly. They also see light polarization. They remember geography, and they obviously can see the sun Aug 23 22:43:10 http://blogs.discovermagazine.com/notrocketscience/2010/07/08/robins-can-literally-see-magnetic-fields-but-only-if-their-vision-is-sharp/ Aug 23 22:43:55 oh well Aug 23 22:43:57 i hope i never have to wear those goggles Aug 23 22:43:59 some "documentary" I watched the other day did say they can sense magnetic fields, also cows do something similar, apparently cows near power lines always face the power lines, away from power lines they tend to point north Aug 23 22:44:06 those birds are even more sophisticated than I thought Aug 23 22:44:26 (not actually looked into the cow thing more than the rumour I heard) Aug 23 22:46:08 well, maybe they just like how powerlines look and orientate perpendicular to that. And remember where sun rises and sets and lay down halfway in between those points. Aug 23 22:46:12 :-p Aug 23 22:46:45 magnetic sense could be tested, just glue a strong magnet to their heads and observe. Or something. Aug 23 22:47:23 lol this is possible, but yeah I think it's something to do with magentic something in their noses, but the reason I heard this was apparently it was discovered since Google Maps released satellite imagery lol Aug 23 22:47:27 it should be easy to crowd out the minimal 40 uT Earth field so completely that it can't plausibly be sensed Aug 23 22:47:46 doc_savage: they saw cows pointing towards magnetic north on the images? Aug 23 22:47:57 hi Aug 23 22:48:21 new to android, and i'm confused by this line and what/how it's expecting me to pass in parameters: public class TcpServiceHandler extends AsyncTask Aug 23 22:48:26 alankila: apparently yeah lol all cows seemed to be pointing north on satellite images is what triggered the research (this is what I heard - take it as a pinch of salt) Aug 23 22:48:51 http://news.cnet.com/google-earth-shows-cows-point-north/ Aug 23 22:48:53 lol Aug 23 22:49:38 um, ignore that question… sorry Aug 23 22:49:43 The resolution of the images was not sufficient to tell which ends of the cows were pointing north, however. Aug 23 22:49:47 i got more to learn than that Aug 23 22:49:50 so...maybe they're pointing south? Aug 23 22:50:42 i think they probably point towards the closes source of bacon Aug 23 22:51:00 if cows could vote, they'd vote for more bacon than beef Aug 23 22:51:08 but which was it he bacon pointing? Aug 23 22:51:14 wow, that came out badly Aug 23 22:51:23 which way is the* Aug 23 22:51:28 well done apple... 94 % full battery, 41 minutes before charged. Really. I bet it's not even 10 minutes Aug 23 22:51:33 I guess 10.8.1 nuked the stats Aug 23 22:51:35 the bacon points towards chickens Aug 23 22:52:49 the bacon strikes the elephant, bruising the forehead, crippling the left eyelid and brusing the outer brain. Aug 23 22:53:14 would it make sense that a tcp client example i'm looking at runs as an activity? Aug 23 23:01:38 http://radar.oreilly.com/2012/03/paleo-media-diet.html Aug 23 23:01:55 thought provoking. i noticed this in myself. Aug 23 23:05:15 many ways to skin a cat, aka live a life Aug 23 23:06:38 "Being in the present moment" is not exactly groundbreaking research, though Aug 23 23:07:47 and another one of those eating nazis who somehow neglects to mention that people live longer now than ever before. In terms of lifespan, it doesn't seem to matter a whole lot what you stuff inside as long as it's varied enough and energetic enough Aug 23 23:09:05 in terms of psychological well-being, that is harder to appreciate. I'd say if you show symptoms there might be something wrong in diet also, I guess, although I've never seen research to the matter Aug 23 23:26:45 catch (NullPointerException e) { // Swallow as the Android code has a bug on Samsung Galaxy Tab 10.1 running Android 3.1 } Aug 23 23:26:46 sigh Aug 23 23:27:43 canadiancow: which api ? Aug 23 23:27:52 hah Aug 23 23:28:03 Also, fu ColorDrawable Aug 23 23:28:04 this looks like a modification we made to BillingService Aug 23 23:28:07 from the in-app billing lib Aug 23 23:28:09 Broken shit Aug 23 23:28:15 response = mService.sendBillingRequest(request); Aug 23 23:35:03 does anybody see a problem with this simple tcp client? http://pastebin.com/WncUh7PP Aug 23 23:35:20 i get a NetworkOnMainThread exception Aug 23 23:36:57 Soo.. dont run it on the main thread Aug 23 23:37:58 how do i change it so it doesn't? Aug 23 23:38:11 Use a thread Aug 23 23:38:39 Is it possible to change the tab text color of Sherlock ActionBar via a Java method? Aug 23 23:39:00 If it's possible with the android actionbar api, then it is Aug 23 23:40:51 ok, i thought implementing runnable did that Aug 23 23:41:01 A Runnable is not a Thread Aug 23 23:41:05 A Thread can run a Runnable Aug 23 23:41:45 ok i see Aug 23 23:41:56 ultra-: http://docs.oracle.com/javase/tutorial/essential/concurrency/runthread.html Aug 23 23:42:02 Yeah, I've been looking through the API, but it looks like it requires setting a custom view Aug 23 23:42:04 you should probably read that whole lesson from the start Aug 23 23:42:14 But I don't see a way to get the current view to modify Aug 23 23:42:34 thanks doc_savage, i will Aug 23 23:42:36 Well, there you go.. you can't do it from java Aug 23 23:43:10 ultra-: np (by start, I mean the 'Concurrency' heading in the left navigation) Aug 23 23:44:25 how can I make a button that calls methods both when I press it and when I release it? Aug 23 23:45:05 Ok. That's unfortunate, but thanks. Aug 23 23:47:04 I have an activity that has a couple of custom widgets/views that are defined in the layout. I also have a service running which fires notifications. These notifications have a pending intent to start said service. However, whenever I click the notification to launch the activity, it fails when it attempts to findViewByID() on my custom views/widgets. Aug 23 23:47:17 ah, setOnTouchListener? Aug 23 23:47:51 Almost as if it doesn't have the original applications context and it's starting my activity as a NEW application instance and not just (re)starting the original instance/context. Aug 23 23:48:18 Sorry, the notifications have a pending intent to start said **activity. Aug 23 23:49:09 Anyone have any idea why this might be? The activity otherwise seems to run fine if I just comment out access to these custom widgets. Aug 23 23:56:20 is there a simple no-op rotation matrix for SensorManager.getOrientation? I don't know how rotation matrixes work Aug 23 23:56:45 but I do know that I just want the raw device-internal orientation Aug 23 23:56:59 Matrix.IDENTITY or something, TheJH_ Aug 23 23:57:56 evancharlton, thanks Aug 24 00:31:47 "Apple on Thursday provided developers with a beta release of OS X 10.8.2, offering a sneak peek into how one of the most talked-about inclusions, system-wide Facebook integration…" meh, fuck this shit. keep FB and crap out of my OS Aug 24 00:44:55 Is it possible to override btn_src.xml in the SDK with a file of the same name in your drawable folder? Aug 24 00:50:58 no Aug 24 00:51:05 That only works for lib projects Aug 24 01:39:11 My Xoom's oS got updated to Jelly bean. I want to revert it back since one the apps that I was developing doesnt function properly on the new OS.. is it possible to revert the OS without rooting? Aug 24 01:40:42 is wongk online? Aug 24 01:41:10 jellyvl: maybe you should fix the app :| Aug 24 01:41:39 hmm, this is my first app, I am not really sure how to do it! Aug 24 01:42:21 it is based on Google APIs Aug 24 01:42:31 android 2.3.3.. Aug 24 01:42:46 its for an android open accessory kit.. Aug 24 01:43:39 heh, the android open accessory standard … never hear about it Aug 24 01:43:47 See it as an opportunity to learn how to debug Aug 24 01:44:46 Has the API's for android 4.1.1 released on the SDK Aug 24 01:47:05 Yes, api16 Aug 24 01:47:34 Arrgh!! I have an error in setContentView(R.layout.main); it says R cannot be resolved to a variable. I have tried importing the R class and cleaning and rebuilding etc but not working. Has anyone got any ideas where I go from here? stackoverflow is giving me zip too :( Aug 24 01:47:59 ok. But I do not see it in my SDK manager.. why sis that? Aug 24 01:48:01 *is Aug 24 01:48:29 though http://developer.android.com/about/versions/android-4.1.html says, it has been released and can be downloaded from SDK Aug 24 01:48:49 try packages > reload Aug 24 01:49:23 Mechdave: do you have any errors in the layout files? also remove the R import Aug 24 01:49:40 its generated automatically Aug 24 01:49:42 eSatsu, the R import is gone Aug 24 01:50:03 Did you restart eclipse? Aug 24 01:50:08 if youre having errors in the layout files in the project, the R wont be generated automatically Aug 24 01:50:15 so fix those if you have any Aug 24 01:50:31 I restaerted adb and eclipse Aug 24 01:50:44 have tried package > reload too Aug 24 01:50:58 Is your sdk tools out of date? Aug 24 01:51:55 eSatsu, nope no errors in layout xml files Aug 24 01:53:30 eSatsu, in eclipse the setContentView(R.layout.main); the main is not highlighted any more! I have made a mistake somewhere but I don't know where~ Aug 24 01:54:53 SimonVT: I guess that was the problem, sdk tools was out of date. Updating it right now Aug 24 01:55:08 Hmmm, might have to recreate project yet Aug 24 01:56:32 is there a way to replicate uinavigationcontroller using an activity and fragments? Aug 24 01:56:51 basically have a stack of fragments programatically pushed into view/> Aug 24 01:57:54 ugh Aug 24 01:58:11 I hate it when an App is just an obvious webview pointed to a mobile version of the company's website Aug 24 01:58:12 SimonVT: I restarted eclipse after updating sdk tools, now eclipse is not able to locate SDK manager itself Aug 24 02:01:05 I updated the folder in Window> Preferences, but still it says, location has not been set in preferences! Aug 24 02:01:23 What are the steps to be followed after updating tools? Aug 24 02:08:14 Hey guys! Came here to ask this cuz you guys is smart. two builds. Cortex A8 with NEON, or Cortex A9 without neon Aug 24 02:11:04 I assume it's not that hard to split a screen with the top half being canvas and the bottom half being text input or similar, right? Aug 24 02:48:02 Hi,is there any way to hide the mouse in ICS? Aug 24 02:48:41 uhm, use the official firmware Aug 24 02:48:54 or at least firmware not made by a winzip commando Aug 24 02:49:31 official firmware? Aug 24 02:51:14 hide the mouse in ics? Aug 24 02:53:30 any way? Aug 24 02:53:55 is there any way to get an older version of your own app Aug 24 02:53:59 i can see the apks in the dev console Aug 24 02:54:03 but i dont see a download link Aug 24 02:55:41 yeah, hide the mouse cursor in ICS Aug 24 02:56:29 what mouse cursor Aug 24 02:57:02 in the old days, the cursor in draw by mouseSurface, but now it's not Aug 24 02:57:27 any cursor.. Aug 24 02:58:54 I have a touch pad, which can all be used as touch device with no cursor, Aug 24 02:59:29 but now there is a mouse arrow in the screen.. Aug 24 02:59:41 so i wanna hide it. **** ENDING LOGGING AT Fri Aug 24 03:00:04 2012