**** BEGIN LOGGING AT Tue Aug 21 02:59:58 2012 Aug 21 03:00:07 I dunno if they're large enough for it to make a difference Aug 21 03:00:50 SimonVT: but what about I need to draw/annotate sth on the screen, I need to update the screen for every onTouch event. Should I stick to use imageview? Aug 21 03:00:50 Aug 21 03:03:06 I don't really know Aug 21 03:06:13 it's registered. n i was idle. but apparenlty i'm not banned. it just kept saying "cannot send messageto channel while banned" but i re-entered n all looks were Aug 21 03:06:24 err wrong window Aug 21 03:09:27 Is anyone here used to Robolectric? If I do shadowOf().getNextStartedActivityForResult() and then shadowOf().getNextStartedActivity(), I get the same intent. Is this the expected behaviour? Aug 21 03:09:56 is SoundPool picky about what formats it can load? Aug 21 03:11:25 really stupid question Aug 21 03:11:40 but there's no reason why i can't install eclipse and ADT in Ubuntu right? Aug 21 03:13:44 None Aug 21 03:13:47 just Do it. Aug 21 03:14:46 t0mless: k good Aug 21 03:14:58 now i just gotta make sure there's enough space in my VM Aug 21 03:15:01 god i need a new machine Aug 21 03:16:15 why are you making a VM as your dev machine? Aug 21 03:16:23 why not just dev on the host OS? Aug 21 03:16:30 t0mless: i am right now Aug 21 03:16:35 t0mless: windows is the host OS Aug 21 03:16:41 but i prefer ubuntu for dev Aug 21 03:16:51 * t0mless shrugs Aug 21 03:16:57 Whatev's Aug 21 03:17:07 HorizonXP i don't use ubuntu primarily but i have setup adt and eclipse several times. i mostly run arch linux and it's way bettter than windows if tht's your comparison, in terms of dev ability Aug 21 03:17:08 yeah it's a really stupid setup on my paret Aug 21 03:17:37 rootlicker: yeah, i don't imagine you're wrong Aug 21 03:17:44 t0mless, why it is giving me this: http://pastebin.com/LWWgtSyF , i just added line 80 here: http://pastebin.com/3tVd2mUT Aug 21 03:17:54 i would prefer vm over windows. forced to use windows for work machine but it doesn't have enough ram to handle vm on top of it Aug 21 03:18:11 so I'm trying to use a SoundPool to play some small, simple samples and they're apparently never ready Aug 21 03:18:33 it's stupid, it actually has 6 gigs in it, but their VPN cleint software is 32 bit winows only, so i have to have 3 bit windows, and it can't address all the ram Aug 21 03:18:58 rootlicker: that is stupid Aug 21 03:19:26 HorizonXP yeah it is. i've had battles about the shit ever sincei started there, been 1 year and about ready to leave Aug 21 03:19:54 rootlicker: lol because of not being able to support 64 bit? Aug 21 03:20:00 yeah, I'd leave too :P Aug 21 03:21:23 well just a lot of stuff. it's not a dev/tech principle company, but they have a HUGE it shop (maybe 30k IT employees, probably like 5k developers?) and Aug 21 03:21:50 they have so many constraining rules and polcies and so many bad practicies... it's just numbing Aug 21 03:22:24 rootlicker: where do you live? Aug 21 03:22:57 USA Aug 21 03:23:03 too broad? Aug 21 03:28:00 hey guys, how would i save custom data to the clipboard in api level < 11? for example, i have a spannable text view and its text is a SpannableStringBuilder... it contains text and drawables. i tried using android.text.ClipboardManager.setText, but that just copies the text, not the drawables... any ideas? Aug 21 03:29:45 dammit, who was I talking to? Aug 21 03:30:54 HorizonXP , to me, about locale Aug 21 03:31:31 notice it says "setText" thats a hint, yuyo Aug 21 03:32:18 rootlicker: it takes a CharSequence, and SpannableStringBuilder is a CharSequence... that said, do you know how to do what I want to do? Aug 21 03:32:36 rootlicker: right :) Aug 21 03:32:48 rootlicker: and? i missed your answer because my video driver crashed. Aug 21 03:33:47 t0mless, r u there? why it is giving me this: http://pastebin.com/LWWgtSyF , i just added line 80 here: http://pastebin.com/3tVd2mUT Aug 21 03:34:26 HorizonXP i said usa... in the south Aug 21 03:42:13 rootlicker: like south, like around Texas? Aug 21 03:42:27 anyway, the point i was gonna make is that you can probably find work pretty easily Aug 21 03:48:23 hargh Aug 21 03:49:51 I am trying to use ksoap and having an issue with the jar file. Is it suppose to be in libs because it won't go there Aug 21 03:51:45 Galaktik: what happens, does it pop out ? Aug 21 03:53:01 LogCat error when I run it with ksoap in root is could not find class 'org.ksoap.serialization.SoapObject Aug 21 03:54:07 g00s: Evertime I try to put it in libs it pops out into the root Aug 21 03:56:02 O.o Aug 21 03:56:38 I manually put it in instead of trying to get Eclipse to do it.... maybe that will work Aug 21 03:56:54 OK that seems to have worked Aug 21 04:09:36 ok note to self, when using SoundPool, load() returns a soundId that is different than the resource id of the sound, so later when you want to play(), you have to give it the soundId, not the resource id Aug 21 04:10:09 love running in circles :) Aug 21 04:12:33 hello, calling requestRender on GLSurfaceView should invoke onDrawFrame on the REnderer, correct? Aug 21 04:28:27 Actionbar is introduced on API 11 and dropdown on the actionbar requires min sdk version 14? Looks like a misunderstanding from my side or is it correct? Aug 21 04:33:02 hello Aug 21 04:33:15 has anybody experienced slow activity start times on ICS? Aug 21 04:33:25 specifically, I am starting an activity from a service Aug 21 04:33:51 the activity is empty, it has no themes applied etc. It still takes about 3+ seconds to display Aug 21 04:34:10 it worked fine on gingebread, just wondering if anybody has any hints Aug 21 04:35:53 rootlicker: it takes a CharSequence, and SpannableStringBuilder is a CharSequence... that said, do you know how to do what I want to do? Aug 21 04:35:56 hey guys, how would i save custom data to the clipboard in api level < 11? for example, i have a spannable text view and its text is a SpannableStringBuilder... it contains text and drawables. i tried using android.text.ClipboardManager.setText, but that just copies the text, not the drawables... any ideas? Aug 21 04:38:16 Can you use a TimePicker for lengths of time? e.g. "how late was your flight" instead of "what time did your flight arrive" Aug 21 04:45:34 thats a good question SoulPropagation Aug 21 04:47:34 thanks :P it looks like I might be able to set it in 24 hour mode and then convert it, so I'll let ya know Aug 21 04:48:46 yeah i haven't played with timepicker much tbh Aug 21 04:49:48 look at it's api reference and its source, maybe you can extend it into something you need Aug 21 04:52:24 or you might be able to setCurrentHour to 00 and setCurrentMinute to 0 and when they pick a time, get them seperately Aug 21 04:53:01 yeah that's what I'm thinking, just convert it from like "12:40 am" to "0 hours 40 minutes" Aug 21 04:53:30 getCurrentMinute and getCurrentHour Aug 21 04:53:52 would the time range for this application be less than 24 hours ? Aug 21 04:56:05 yeah. no more than an hour or two Aug 21 05:15:53 "Samsung attorney John Quinn told the court that in the first two quarters it was in the market, the Galaxy Nexus sold $250 million worth of the device, arguing that "this is a product that, at most, captured 0.5 percent of the market." Aug 21 05:16:14 thats not too bad Aug 21 05:16:21 hardly a formula to emulate apparently; thats why we don't see more vanilla devices Aug 21 05:17:01 of course they were minimizing the success of the device for the court Aug 21 05:21:56 I just read a section on threading in the docs ... and I'm a little confused on something (due to unfamiliarity with terminology); if two activities/services, or one of each, are running in a process -- is the default behavior to start only one thread and swap between them in some fashion? Aug 21 05:22:25 or does it create one thread for each Aug 21 05:22:36 phantal: by default there is one thread; events are dispatched on that thread Aug 21 05:22:41 by default services run in the same thread Aug 21 05:22:53 ah good, I didn't read it wrong Aug 21 05:23:10 to do multithreading, use async task or traditional java threading, if you dare!! Aug 21 05:23:24 or IntentService Aug 21 05:23:41 yeah or that Aug 21 05:23:52 What's the difference between IntenService and AsyncTask Aug 21 05:23:55 Intent Aug 21 05:24:19 IntentServices are cool and AsyncTasks will torture your puppy Aug 21 05:25:16 i can't recall the specifics of intentService Aug 21 05:27:11 so heres a good question. there's a UI feature i want (pull to refresh list), there's a couple of libraries for it. i could implement myself n getm ore experience (it's a learning project) or use a library and get the app in a first release state faster... fork in the road Aug 21 05:27:19 So, if I subclass 'Service' it will run in the same thread as whatever instructed it to start, but if I use IntentService it starts another thread automatically, so to speak Aug 21 05:27:45 lol i am such a pompous asshole, startingm y question with "so here's a good question" Aug 21 05:28:00 no, services generally run in their own process, don't they? Aug 21 05:28:03 rootlicker: what's wrong with having a refresh action in the Action Bar? Aug 21 05:28:30 eddie because it is an ongoing list pulling more, basically a way to do paging Aug 21 05:28:49 briswolf: that I don't know. Still pretty green to the android dev terminology & whatnot Aug 21 05:28:52 but not reallyp aging. it will fetch 20 items from an api at a time (will be adding caching tho) Aug 21 05:29:03 are we talking multi-application here? Aug 21 05:29:05 I have a question. For people who do Android professionally... Aug 21 05:29:08 or does this all run in one application Aug 21 05:29:09 briswolf no they do not Aug 21 05:29:34 if the service is in another application, then it runs in the process for that application Aug 21 05:29:47 ...if you are doing UI for a page, and they're very big on the spec. and animations etc., how long does one page usually take? Including JSON backend implementation and everything. Aug 21 05:30:04 ologn that's a loaded question Aug 21 05:30:08 you can specify that the service runs in its own process in its own application... why you would need to I haven't quite worked out Aug 21 05:30:30 rootlicker, yaa, I know... Aug 21 05:30:41 scope creep. you started out with ui, then enaimation, then backend implementation - could be a whole app in one screen Aug 21 05:31:17 phantal: what are you trying to accomplish, out of curiousity? Aug 21 05:31:27 briswolf: supposing I was just writing a tool to use on a computer; I'd have a thread for handling the gui, and a thread for doing the heavy lifting. I'm unsure whether a service, intentservice, or asynctask is most appropriate Aug 21 05:31:36 rootlicker, I did Unix administration since 1996. I just started doing programming contracts recently. Aug 21 05:31:40 probably intentservice Aug 21 05:32:08 phantal Aug 21 05:32:19 phantal it depends on what your heavy lifting is Aug 21 05:32:31 or java threads Aug 21 05:32:32 rootlicker: stuff that would clobber a gui thread Aug 21 05:32:46 async task is appopritate for some typeso f things not others Aug 21 05:33:37 "syncTask is designed to be a helper class around Thread and Handler and does not constitute a generic threading framework. AsyncTasks should ideally be used for short operations (a few seconds at the most.) If you need to keep threads running for long periods of time, it is highly recommended you use the various APIs provided by the java.util.concurrent " Aug 21 05:34:00 I quite like async tasks too Aug 21 05:34:15 they are handy when you are starting from the ui thread, say, responding to a button Aug 21 05:34:48 IntentService is a base class for Services that handle asynchronous requests (expressed as Intents) on demand. Clients send requests through startService(Intent) calls; the service is started as needed, handles each Intent in turn using a worker thread, and stops itself when it runs out of work. Aug 21 05:34:49 otherwise if you were going to be doing something periodic, I'd start a thread Aug 21 05:35:15 or, use some sort of timer, not that I am familiar with anything like that on android... Aug 21 05:35:57 there ya have it Aug 21 05:36:04 supposing I needed to periodically poll a remote server ... based on what rootlicker just quoted, AsyncTask and IntentService weren't necessarily designed for that purpose Aug 21 05:36:23 eg, I /could/ just have the service loop indefinitely and never complete its task, but that isn't how it was designed Aug 21 05:36:32 phantal: you would use those in conjunction with alarm manager Aug 21 05:36:36 you would need your own thread probably, or use a timer* to start an asynctask Aug 21 05:36:40 alarm manager + intentService Aug 21 05:36:45 yeah, i would just extend service into another class and use traditional java threads to fo your http request Aug 21 05:37:08 actually i wouldn't even do it as a service unless you need it to keep going when the app isn't being used Aug 21 05:37:27 nah, I'd rather have the app close when someone hits home/back, etc Aug 21 05:37:34 the thing about service is it's for background things, service has higher priority not to get killed by system than activity Aug 21 05:38:03 "foregrounded service" i.e. service that puts a notification in the status bar - has even hgiher priority Aug 21 05:38:04 service is also useful for inter-process communication Aug 21 05:38:13 like a shared library or resource Aug 21 05:38:17 yeah Aug 21 05:39:00 if you're just doing some work thato nyl needs to happen when the app is in view, then just use a thread method Aug 21 05:39:14 and in your onPause or onStop, stop that thread Aug 21 05:39:36 speaking of ... when communicating within the same process, do you just use the normal java way of doing it (synchronized blocks), or is it better to use an existing API (like bundles, etc) Aug 21 05:39:58 don't make life hard on yourself, just use sync blocks and functions :) Aug 21 05:40:06 communicating between activities? Aug 21 05:40:14 activities, services, etc Aug 21 05:40:16 threads Aug 21 05:40:36 i'm not sure i get your question i see multiple ways of interpretingi t Aug 21 05:40:57 I'll try to word it better, but I'm still kinda green with the terminology Aug 21 05:41:29 its probably my fault but do you mean different components calling methods on each other, or passing data around, or both? Aug 21 05:42:39 A simple example ... suppose the app has an activity or service that uses the camera to get images; if I want another thread to consume it, I could either go about it through the API (using built-in IPC techniques like bundles), or just use a synchronized block and access it through my own framework Aug 21 05:43:10 oh ok Aug 21 05:43:43 phantal: you would probably want some kind of queue Aug 21 05:43:48 i'd probably go the later if its only without your app Aug 21 05:44:01 the thread would put data into the queue, and the main thread would take data out Aug 21 05:44:12 i don't know if yuo need IPC if your just sharing between threads in one app, they are in one process still Aug 21 05:44:15 java has some concurrent queue classes Aug 21 05:44:17 http://docs.oracle.com/javase/tutorial/collections/implementations/queue.html Aug 21 05:44:43 I wouldn't use IPC, it is just more plumbing for no reason Aug 21 05:44:50 now, if the thread is one activity and the camera fetchig is in another, it's a questino of how to share the resource Aug 21 05:45:11 i'd probably go with a static singleton in that case i think Aug 21 05:45:32 well in that case a bound service might be appropriate?... Aug 21 05:45:43 haha I really do not know. Aug 21 05:45:43 yeah bound service would be good too Aug 21 05:45:57 Actionbar is introduced on API 11 and dropdown on the actionbar requires min sdk version 14? Looks like a misunderstanding from my side or is it correct? Aug 21 05:46:03 then you could get a handle on the service in the IBinder onServiceConnected() or whatever Aug 21 05:46:22 yeah. Although I find services to be horribly complex Aug 21 05:46:36 Hi all. I have URI pointing to some audio, like that: "content://media/internal/audio/media/122". How can I play it? I tried to use SoundPool for that, but when I try to load such sound mSoundPool.load("content://media/internal/audio/media/122", 1) i got an error: error loading content://...... Aug 21 05:46:37 napster: list navigation is api 11+ Aug 21 05:46:39 anyone playing around with onx? Aug 21 05:46:44 so how can I play it? Aug 21 05:46:47 the documentation takes a little to wade through but they aren't too bad once you get the hang o f em Aug 21 05:47:21 I have been working with a service for about 9 months now, it is ok yes, but there are some crazy gotchas Aug 21 05:47:25 like memory leaks etc Aug 21 05:47:33 especially remote process bound services Aug 21 05:47:43 JakeWharton: ok, just wanted to know if this is ultimately possible to get it down back to API-8 using support lib Aug 21 05:47:49 haven't done remote process but yeah memory leaks can be one thing Aug 21 05:47:55 napster: try http://actionbarsherlock.com Aug 21 05:48:03 anyone know why webview quality loosk bad when u zoom in, got this image which becomes too pixelated when zoomed, but looks fine on iphone Aug 21 05:48:13 I'm really struggling with the docs because of all the new terminology. What I need to find is something that breaks it down by stepping through (at a somewhat high level) designing a non-trivial application Aug 21 05:48:18 if you hold a handle to a service in an activity, you have to get rid of that handle in onStop n such Aug 21 05:48:26 JakeWharton: This is what I use now, I was trying for a native solution :) Aug 21 05:48:33 native? Aug 21 05:48:43 action bar didn't exist in the platform until Honeycomb Aug 21 05:48:48 probably means the android equivalent of JNI Aug 21 05:49:03 nah Aug 21 05:49:15 phantal: have you done much java work? Aug 21 05:49:36 JakeWharton: The question is, does the support library brings the android actionbar to API 8 or even API 10 Aug 21 05:49:37 phantal sounds like you don't need a service as you mentioned not caring about it running when the app is out of view Aug 21 05:49:46 eh, some. I have more experience with C/C++ and perl Aug 21 05:50:01 napster: no, the support library does not contain the action bar Aug 21 05:50:12 yeah. I worked with java for years and still struggled with android concepts like activities and services Aug 21 05:50:13 thats it. Thank you JakeWharton Aug 21 05:50:20 briswolf: I know enough to work competently in Java, but I'm not an expert by any means Aug 21 05:50:28 implement a thread in your activity, or if it needs to be more complex than implement a class that extends thread or one that implements runnable Aug 21 05:50:31 my advice is to just use one activitiy and pretend like that is all you have Aug 21 05:50:33 and work in there Aug 21 05:50:38 and then go more complex if you need to Aug 21 05:50:59 make yourself a thread and use syncronized blocks and such to work with it Aug 21 05:51:45 if your app is just like one screen or one set of screens, then this is all you should need really (you can make more threads if you like of course :) Aug 21 05:51:52 rootlicker: in short, the 'worker thread' (whether that's a service or whatever) will be doing some complex arithmetic (image DSP stuff), so obviously it can't be in the UI thread. Whether it's a service, asynctask, java thread, or some other thing ... I just don't want this to be difficult to maintain Aug 21 05:52:18 my vote is for java thread Aug 21 05:52:19 heres my suggestion then Aug 21 05:52:28 so I'm trying to get a handle on 'best practices' for this sort of thing Aug 21 05:52:41 implement a class that implements runnable (easy, just implment the run() method where its thread will start its work) Aug 21 05:52:53 also create acorresponding interface Aug 21 05:53:08 so class Worker implements runnable Aug 21 05:53:39 and interface IWorkerClient Aug 21 05:53:53 the interface specifies the name of the callbacks - success/fails, whatever Aug 21 05:53:58 so your activity implements the interface Aug 21 05:54:34 then, in that Worker class, have a member object - of type IWorkerClient - and a setter method. so then implement your dsp stuff there Aug 21 05:54:39 so no way to set webview render quality? Aug 21 05:54:51 so, I'd use that interface to notify the activity consuming the results, and I could use it to poll for more work Aug 21 05:55:00 then your activity does Worker worker = new Worker(); worker.setClient(this) //setClient(IWorkerClient client) Aug 21 05:55:36 rootlicker: makes sense Aug 21 05:55:52 then (new Thread(Worker)) .start(); Aug 21 05:56:12 yeah so in yuor worker class, you can callback reliable on the activity Aug 21 05:56:18 for communicating with a server, it sounds like I might be better off doing the same thing there Aug 21 05:56:35 phantal: Aug 21 05:56:37 IWorkerClient myClient; //set by activity in the corresponding setter Aug 21 05:56:50 then myClient.successCallback(result) //callback specified by interface Aug 21 05:56:59 don't forget that the worker will callback those methods on its worker thread Aug 21 05:57:10 yeah Aug 21 05:57:10 briswolf: ::nod::, so need to synchronize Aug 21 05:57:16 so you will have to use like handler.post(Runable); to post back to the main thread Aug 21 05:57:21 in the impelemntation of the callbacks, in the activity, use RunOnUiThread Aug 21 05:57:29 briswolf: what does posting accomplish Aug 21 05:57:31 oooh RunOnUiThread? Aug 21 05:57:35 yeah Aug 21 05:57:44 *goes to look it up* :P Aug 21 05:57:54 runOnUiThread, it's a method of the Activity class Aug 21 05:58:07 wow. Here I have been making my own handler and posting to it Aug 21 05:58:14 see what happens when you miss the basics :P Aug 21 05:58:30 runONUiThread(new Thread() { public void run() { //stuff to do in callback} }); Aug 21 05:59:00 yeah I got that much, I usualy make a new handler like handler = new Handler(getMainLooper()); Aug 21 05:59:07 ah Aug 21 05:59:10 i'm not a thread expert Aug 21 05:59:13 and then I can post to that from other threads. Just ignorance on my part Aug 21 05:59:13 So, instead of actually creating a new thread, I imagine there's a queue the UI thread uses to determine what to run Aug 21 05:59:39 yes, there is an event queue in the main thread Aug 21 05:59:50 which is why it is important not to block that main thread, so things stay responsive Aug 21 05:59:50 err Aug 21 05:59:55 maybe it's new Runnable*** Aug 21 06:00:01 oh, I see Aug 21 06:00:07 so you post a Bundle to it Aug 21 06:00:10 and that runable gets posted in a queue for the ui thread to pick up Aug 21 06:00:17 yes I see, new runnable Aug 21 06:00:41 yeah, woops Aug 21 06:00:44 most java systems (awt, swing, blackberry) have this kind of mechanism Aug 21 06:00:52 posting runnable objects to a queue Aug 21 06:00:57 I am a fan :) Aug 21 06:00:58 this is why it's better to bookmark docs and references than it is to memorize ;-) Aug 21 06:01:28 phantal no need for a bundle unless you need ab undle Aug 21 06:01:31 so... has anybody used DDMS to profile an application? Aug 21 06:01:55 what does posting accomplish if you aren't handing it something in a bundle? Aug 21 06:01:57 a little briswolf but not extensively Aug 21 06:02:10 you'rep osting the runnable Aug 21 06:02:13 I see in the traceview utility there is a timeline view, is that not a part of eclipse/ddms? Aug 21 06:02:16 the runnable gets picked up and exectued Aug 21 06:02:43 phantal: the runnable can make reference to objects later, provided they were marked final when passed to the runnable Aug 21 06:03:07 nod Aug 21 06:03:07 it is all the same memory space, you can access things between threads.... just gotta watch the syncronisation Aug 21 06:03:54 yeah, usually i just have the run() method call other methods, some stuff doesn't even need to be on the UI thread Aug 21 06:04:41 so perhaps you would do something like this: Aug 21 06:04:42 final WorkResultType workResult = getWorkResult(); // this reads out of a synced queue, or something Aug 21 06:04:42 runOnUiThread(new Runnable(){ public void run() { process(workResult); }}); Aug 21 06:04:56 of course, there are a million ways to do it Aug 21 06:04:59 as there always are Aug 21 06:05:04 nod Aug 21 06:05:07 it goes down to style and readability really Aug 21 06:05:26 android is a damn good framework if you like nutsn bolts. doesn't lock you out, just provides itso wn mechanisms Aug 21 06:05:39 actually, if you are using callbacks like rootlicker suggested, you can pass the work result straight in as a parameter Aug 21 06:05:46 How do the scoping rules work for that ... I assume you mean workResult is a local variable in a function Aug 21 06:05:57 yep Aug 21 06:06:05 yeah you can pass results directly back doingi t this way Aug 21 06:06:17 the object itself isn't garbage collected until after that runnable object is destroyed Aug 21 06:06:25 nod Aug 21 06:06:27 which happens after it has been run Aug 21 06:06:38 so you don't have to keep a reference to that object anywhere special Aug 21 06:07:08 nope just instantiate it in the scope of the method that spawns the thread Aug 21 06:07:13 So, the function that initiated the runOnUiThread could have long-since returned, but it lives on because it was used in that (what is that ... a lambda function?) Aug 21 06:07:36 nah it's not lambda Aug 21 06:07:45 anonymous class Aug 21 06:07:48 I've used it before, but wasn't sure on terminology Aug 21 06:07:53 it is kind of like the same concept though Aug 21 06:07:58 like blocks in iOS Aug 21 06:08:03 the function doesn't live on Aug 21 06:08:23 ya, not the function, just the final'd variable Aug 21 06:08:42 but the Runnable object, if it has a reference to an object instantiated in the scope of the worker clas in another thread- will cause that object ot persist until the runnable object itself is destoryed Aug 21 06:08:43 until runnable is finished Aug 21 06:09:00 in general, the java compiler is very good, it won't let you access something you cannot do (thread concurrency aside) Aug 21 06:09:05 so don't sweat it too much Aug 21 06:09:12 it will warn or error you if you do something wrong Aug 21 06:09:18 aside from concurrency ;P Aug 21 06:09:24 The final is necessary though because it's in a different thread; without it, it would be cleaned up I'm guessing? Aug 21 06:10:04 that is a good question. I think you are guaranteeing that the object reference will not change Aug 21 06:10:14 ergo the compiler can make a cache of it inside the runnable object Aug 21 06:10:18 I am just guessing Aug 21 06:10:22 morning Aug 21 06:10:59 ::nod:: Aug 21 06:11:01 and so, yes, without the final keyword, the reference wouldn't be stored and could be collected Aug 21 06:12:14 Cool, I think I have enough to go on here. Thanks for all the info and brainstorming, I appreciate it Aug 21 06:13:01 oh, one more: I'm guessing I don't need to declare anything in AndroidManifest.xml for threads; only if it's a component (service, activity, etc) Aug 21 06:13:16 correct! Aug 21 06:13:27 go forth and make as many threads as you like :) Aug 21 06:16:08 and so, yes, without the final keyword, the reference wouldn't be stored and could be collected <--- what? that's not true at all Aug 21 06:16:52 garbage collection only occurs when there are no references left to an object (ignoring weak references) Aug 21 06:16:59 I know that Aug 21 06:17:00 doesn't matter whether or not those references are final Aug 21 06:17:05 no of course not Aug 21 06:17:19 I meant that the compiler wouldn't be free to create that cached reference Aug 21 06:17:33 I am only surmising, why else would the final keyword be needed? Aug 21 06:17:44 I should research. Aug 21 06:20:23 briefly glancing over the conversation it looks like you're talking about accessing local variables from the surrounding method within anonymous classes Aug 21 06:21:04 yeah Aug 21 06:21:16 ryanm: I am sorry if what I said was wrong, I was just trying to explain it. Please don't make me feel bad for just trying to help. Aug 21 06:21:28 "The language designers could have allowed usage of non-final local variables inside inner classes. However, this could be confusing for the developer, since it would not be clear whether assignments to the reference are seen by the inner class or not." Aug 21 06:21:51 "closures are confusing. force them to make it final" Aug 21 06:22:16 rootlicker: well, the problem is less "closures are confusing" and more "Java doesn't have support for closures" Aug 21 06:22:22 I did say "I think you are guaranteeing that the object reference will not change ergo the compiler can make a cache of it inside the runnable object I am just guessing" Aug 21 06:22:35 so, short answer: final is required Aug 21 06:22:46 briswolf: that part is basically correct, yes Aug 21 06:22:55 not even optional if for whatever perverse reason you wanted to leave it off Aug 21 06:22:57 cool. I surrender! Aug 21 06:23:34 it can be a pain if you want to change it within the inner/anonymous class Aug 21 06:24:35 also another thing about defining an interface like i mentioned above is it allows you to reuse that Worker with any client even if it isn't an activity Aug 21 06:28:12 can I use DDMS in eclipse to crearte a tracefile for use in traceview? I can't really work it out... :/ Aug 21 06:33:43 o/ Aug 21 06:35:04 \o Aug 21 06:43:38 err this is a silly question but you cant modify an arraylist as you loop through it huh Aug 21 06:44:01 no you cannot Aug 21 06:44:25 like for (Object o : list) { if(o.equals(guyToRemove)) list.remove(o) } Aug 21 06:44:42 build a new list instead Aug 21 06:45:05 hmm Aug 21 06:45:09 list.remove(guyToRemove) Aug 21 06:45:13 yeah Aug 21 06:45:23 well , err, that was abad shrothand example Aug 21 06:45:26 new list for (object o : list { if(true) { newlist.add } } Aug 21 06:45:30 assumei t's not using equals() to compare Aug 21 06:46:06 it's a bummer, c# has some iterators which will let you remove objects and keep iterating Aug 21 06:46:13 so does Java Aug 21 06:46:21 really Aug 21 06:46:24 in fact, you can do it with an ArrayList Aug 21 06:46:27 school me again :) Aug 21 06:46:27 https://developer.android.com/reference/java/util/Iterator.html#remove() Aug 21 06:47:08 and https://developer.android.com/reference/java/util/ArrayList.html#iterator() Aug 21 06:47:17 huh. now I'm hoping C# actually does let you remove objects, I could have gotten them muddled in my stupid brain Aug 21 06:48:52 outside of an ant script to modify the manifest, is there any way to request permissions (like writing to SD card) for debug version of the application and not have that permission in the release version? Aug 21 06:50:42 gah Aug 21 06:50:45 Java @.@ Aug 21 07:06:05 Iterator i = trackRecords.iterator(); while (i.hasNext()) { if (i.next().getTrackId() == removeTrackId) i.remove(); } Aug 21 07:06:31 good call ryanm Aug 21 07:06:45 I do what I can :-) Aug 21 07:07:20 its more elegant not squeezed on one line ;) Aug 21 07:07:34 lol yeah Aug 21 07:10:52 someone quick, how do you link to another class in javadoc Aug 21 07:12:43 {@link #getInstance()} Aug 21 07:12:52 for a method in the same class.. that is Aug 21 07:13:18 I think it is just {@link ClassName} Aug 21 07:13:32 but if I was wrong yet again, well I wouldn't be surprised Aug 21 07:14:12 I can just imagine: "somebody, Quick! I must write documentation!" - said noone, ever ;P Aug 21 07:14:25 well, not true. But you know what I mean :) Aug 21 07:15:35 has anyone wrapped __android_log_print in a std::cout like interface with support for other c++ stream operators? Aug 21 07:16:20 briswolf: looks correct to me Aug 21 07:16:37 eclipse's autocomplete works nicely for @link, which is helpful Aug 21 07:16:38 *phew* Aug 21 07:18:29 lol Aug 21 07:18:58 yeah i got a call at 2 am from the pm all "oh snap we need to javadoc now!!" happens often sure Aug 21 07:21:44 lol nah, i am just gonig through docing todays code while i'm too tired to write bt awake enough to do this - helps me fele productive and it helps te next day Aug 21 07:21:52 hi gusy Aug 21 07:22:06 *guys Aug 21 07:22:16 gusy isn't here you just missed him Aug 21 07:22:17 Hi Aug 21 07:23:13 i have a scrollview which contains a gallery and a webview . while i click on the webview in the landscape mode it scrolls up thus hiding the gallery, while it works fine in the portrait mode Aug 21 07:23:25 moreover its happens only the first time in the landscape mode Aug 21 07:24:16 any idea how to resolve this? i don't want the webview to scrollup while i click on it Aug 21 07:24:22 in the landscape mode also Aug 21 07:27:52 yo Aug 21 07:34:02 What is the best way to implement ActionBar on API level 10? I have seen a couple of third party libs like Actionbar sherlock. Aug 21 07:35:48 napster: we use actionbar sherlock :) Aug 21 07:35:57 ok Aug 21 07:36:05 :) Aug 21 07:38:57 this isn't a guarantee of quality Aug 21 07:42:23 Ivru: ^^ Aug 21 08:11:36 any intresting news on the galaxy s advance ? Aug 21 08:12:40 i thought that dual-sim phone was interesting Aug 21 08:13:52 Galaxy S Duos ? Aug 21 08:47:11 hi Aug 21 08:47:21 hi Aug 21 08:47:22 I have a need of freelancer Aug 21 08:47:34 app development is required Aug 21 08:47:36 elektrinis: not in here, please. see the topic. Aug 21 08:48:06 work includes usb host with this driver: http://www.ftdichip.com/Android.htm Aug 21 08:48:28 elektrinis: do not advertise jobs in here. Aug 21 08:48:37 where should I do that? Aug 21 08:48:44 oh Aug 21 08:48:46 ok Aug 21 08:48:48 sorry :) Aug 21 08:54:49 hi Aug 21 08:55:18 did any1 here worked with microlog4android? Aug 21 09:26:29 Hi! Is the Galaxy Nexus engineering model still available for ordering? Aug 21 09:27:38 there is no engineering model - they haven't done that for a long time... Aug 21 09:27:46 AFAIK it's still available on the play store Aug 21 09:28:24 I live in Hong Kong. Google has blocked my region to browse that page. Aug 21 09:28:37 hahahaha Aug 21 09:28:41 awesome Aug 21 09:28:46 I'd get a Galaxy Nexus for dev purpose Aug 21 09:28:51 oh, well - yeah, apparently it's out of retail here Aug 21 09:28:57 But it kicks me out of the door Aug 21 09:29:09 they wouldn't ship it to us anyway Aug 21 09:29:17 Leeds: I know you're in HK as well Aug 21 09:29:19 I'm sure you can still find one in Mongkok Aug 21 09:29:23 so I'm trying to duplicate a spannable string builder, by doing strBuilder.append(strBuilder), unfortunately none of the span information is getting copied - what's the deal with that? Aug 21 09:29:42 alternatively, make a good offer to buy my gf's phone from her :D Aug 21 09:30:11 Leeds: I just don't want to buy those cracked device from Japan. Aug 21 09:30:21 yeah, that's what she's got... why not? Aug 21 09:31:23 Leeds: Those are rooted device which I don't know what was done to the kernel. Aug 21 09:31:31 so flash back to stock before using it Aug 21 09:31:53 factory images come straight from google Aug 21 09:33:10 Leeds: You mean flashing it with Google's image? Aug 21 09:33:19 yes Aug 21 09:33:43 Leeds: That's still cracked kernel which I don't know what was done to it. Aug 21 09:33:49 no, it isn't Aug 21 09:34:17 Did they crack the kernel and boot loader in order to unlock it from Japan carrier? Aug 21 09:34:35 no cracking involved, just unlocking Aug 21 09:34:51 you can reflash a factory image and relock and it will be pristine Aug 21 09:35:08 They unlock it in the malicious way, don't they? Aug 21 09:35:45 no Aug 21 09:36:00 you're not coming across as someone with clue, you know... Aug 21 09:37:26 does anybody know of a book that has a good section on drawing in android? Aug 21 09:37:33 such as drawing gradient buttons, other controls, etc Aug 21 09:38:56 ultra-: like this? http://developer.android.com/guide/topics/graphics/2d-graphics.html Aug 21 09:39:06 Leeds: The Japanese Galaxy Nexus was locked by the carrier. Those devices are bundled with service contracts, not all of them. I don't think they will pay to unlock the phone gracefully as they can just unlocking it with root. Or I have misunderstood something? Aug 21 09:39:45 ultra-: Well... The tutorials on android.com are pretty good. Aug 21 09:39:46 Carbon_Monoxide: see, I've (approximately) got one, so I know what I'm talking about... you're guessing, and you're paranoid Aug 21 09:39:57 well i was hoping to find a book with various examples… but i'll look at the developer page some more Aug 21 09:40:18 Leeds: I'm paranoid before I know about it. Aug 21 09:40:47 i should probably now what i want to draw first… i need a custom look that's not cheesy :) Aug 21 09:40:53 *know Aug 21 09:41:50 Spoiler alert: most of my answers to questions in here are links to developer.android.com Aug 21 09:42:04 ryanm++ Aug 21 09:42:56 it's the first place to look for pretty much everything - even if it's not the last Aug 21 09:43:42 ryanm: it is a helpful site… i've gotten by with that and some various tutorials, and i usually end up at the developer site to understand those… the only thing i've read in a book so far is an intro/overview to how things work Aug 21 09:45:12 There's one of those on that site too ;-) Aug 21 09:45:46 yeah i may have read it during my first android programming attempt a couple years ago Aug 21 09:46:32 the developer site has changed so much since i started 2 years ago Aug 21 09:46:45 ultra-: If you know good enough about how to use Drawable, you may try to look at the API doc for GradientDrawable. http://developer.android.com/reference/android/graphics/drawable/GradientDrawable.html Aug 21 09:46:52 i'll read it again… i do that in my work truck on downtime Aug 21 09:47:18 always chrome-to-phoning web pages before i leave for work and reading/coding every chance i get Aug 21 09:47:44 thanks, i should be able to do this Aug 21 09:48:04 i'm not sure about xml vs java… for some reason i like to code everything manually and i always find xml examples Aug 21 09:48:21 perhaps i should bite the bullet… i'm used to programming for microcontrollers and back-end stuff in python Aug 21 09:48:29 CallumTaylor: Yeah, it has. It's gotten a lot better. Aug 21 09:48:45 ryanm: i wish it was this good when i started... Aug 21 09:49:00 you can actually access the tutorials with 1 click Aug 21 09:53:42 Wot. getXPrecision() for my display gives me ... 8.12 :O Aug 21 09:57:35 Leeds: Where did your girl buy that phone? Aug 21 09:57:59 Leeds: Maybe I can shop around Aug 21 09:58:03 Carbon_Monoxide: citylink via groupon Aug 21 09:58:30 Leeds: Wow! She caught the train. That was cheap Aug 21 09:58:47 hmm? Aug 21 09:59:03 nice, i have a graphic drawn :) Aug 21 09:59:06 I also bought one at full price from broadway, but it was stolen in shenzhen Aug 21 09:59:49 Leeds: CityLink provides reasonable warranty to the phone. I saw the outdated group buy on GroupOn. The price was quite attractive. Aug 21 10:00:11 it was pretty much the lowered retail price, before it went cheap everywhere Aug 21 10:01:10 that is, it was cheap at the time, but it was available for that price everywhere a few weeks later Aug 21 10:05:45 can I post now Aug 21 10:05:52 yes Aug 21 10:05:54 no Aug 21 10:05:57 yaaah Aug 21 10:06:01 lols Aug 21 10:06:21 hi everyone Aug 21 10:07:51 Leeds: Samsung lowered the retail price and stopped selling it. Aug 21 10:08:07 right Aug 21 10:08:50 Leeds: Samsung just doesn't want its Galaxy S III beated by Galaxy Nexus Aug 21 10:09:10 yes, I've heard that theory Aug 21 10:10:09 Leeds: I thought about it as well. I think many people do have the same logic. Aug 21 10:11:08 But Google stops selling Nexus phones after 1 year Aug 21 10:11:43 Maybe that's Google's intention and Samsung follows this plan to introduce Galaxy S III Aug 21 10:12:18 But I just want a official phone to start my dev on new API Aug 21 10:12:36 what is an 'official phone'? Aug 21 10:13:10 Leeds: Android phone with stock Android Aug 21 10:13:24 most of your users won't have stock Android Aug 21 10:13:32 assuming you're planning mass-market dev Aug 21 10:14:27 https://developer.android.com/reference/android/nfc/NdefRecord.html#NdefRecord(short, byte[], byte[], byte[]) what's the purpose of "id" byte array? Aug 21 10:15:20 Leeds: At least I don't want to have wierd behaviors from custom Android. And I don't know about it's different as the stock one. Aug 21 10:15:52 Carbon_Monoxide: then get an SII or something and flash a community build on it Aug 21 10:16:03 I'd still recommend a nexus phone for dev Aug 21 10:16:08 or make me a good offer for the gf's phone, and I'll flash stock Android onto it :) Aug 21 10:16:17 Okay, I need to sleep now... Aug 21 10:16:24 Leeds: Good idea Aug 21 10:16:33 as much fun as watching builds while chatting is Aug 21 10:16:48 Leeds: Does S II have NFC component? Aug 21 10:16:50 or get a Nexus 7 if/when they ever actually ship here Aug 21 10:17:01 no, SII doesn't have NFC Aug 21 10:17:40 Leeds: yes it does Aug 21 10:17:45 http://www.samsung.com/global/microsite/galaxys2/html/feature.html Aug 21 10:19:02 is there some sort of color picker somewhere that i can generate hex such as 0xff74AC23? Aug 21 10:19:23 i managed to get a n7 locally the other day Aug 21 10:19:28 has anyone seen any substantial Renderscript apps? Aug 21 10:19:34 it's a good tablet Aug 21 10:19:48 What's substantial? Aug 21 10:19:49 ultra-: Google search "color picker" ---> http://www.colorpicker.com/ Aug 21 10:19:49 ryanm: you might be right - I thought mine didn't, but it might be that I just never used it :) Aug 21 10:20:10 more than a demo Aug 21 10:20:21 then just stick 0xff on the front of the 6-digit hex code Aug 21 10:20:27 ryanm: i did find one like that, but what's up with the length of the ... Aug 21 10:20:29 ok :) Aug 21 10:20:41 I guess not, then. Aug 21 10:20:48 the first two characters are the alpha value :-) Aug 21 10:20:50 deweylewie: I think renderscript has been toned down a bit in JB, because not many people were using it... Aug 21 10:20:56 then 2 red, 2 green, 2 blue Aug 21 10:21:02 Stripped back to just compute. Aug 21 10:21:06 gotcha Aug 21 10:22:15 ryanm: just fired up my SII, with Samsung ICS on it - no NFC settings... Aug 21 10:23:26 deweylewie: Why do you ask? Aug 21 10:24:16 And what sort of an answer would you get for the same question asked of any other honeycomb-and-up feature? Aug 21 10:25:50 just wondering since I remember it coming out with 3.0 and it looked pretty neat Aug 21 10:26:14 I kind of assumed non-demo apps would always restrict themselves to really old APIs. With something like renderscript if you have to conditionally turn it off you have to wonder what you're going to do instead, and why you don't just do that all the time. Aug 21 10:28:19 hi Aug 21 10:28:52 hi Aug 21 10:28:53 I'm having market filtering issues. I never seem to figure out how to NOT filter many devices! : http://pastebin.com/gEUik7KW Aug 21 10:30:45 I recently managed to un-filter the Nexus 7 by adding a couple of uses-feature...false. But now I'm not using any features associated to permissions I ask for any more, I support all screen sizes and so on... I don't know why I'm still filtering devices that should be supported! Aug 21 10:35:30 i've found several answers online for dithering, but none that work… .setDither(true) and overriding onAttachedToWindow in my main activity with window.setFormat(PixelFormat.RGBA_8888); doesn't seem to do much… anybody else have luck? Aug 21 10:35:48 i'm getting banding in my gradient… fills the entire background Aug 21 10:37:48 maybe the issue is with your screen in your device, maybe it doesn't support 8 bits per pixel Aug 21 10:38:49 yeah could be an old answer Aug 21 10:43:26 I have 2 jar files residing inside Linux/android/vendor/myjar/libs/frameworks . I need to access this jar from my application inside Linux/android/packages/apps Aug 21 10:43:34 How should I specify the LOCAL_STATIC_JAVA_LIBRARIES and LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES in the Android.mk of my application such that I can access these jar's from my application. Aug 21 10:48:17 http://pastebin.com/csRJ3Q5f why is my service not started with nfc tag? when I put the intent-filter to some activity, it starts. Aug 21 10:49:42 I want to have foreground service which will take "commands" from nfc tags. Aug 21 10:56:13 should my class extending scrollview be calling ondraw? Aug 21 11:32:16 i could use some advice over here =/ Aug 21 11:32:27 with that nick I bet you could Aug 21 11:33:36 could anyone guess why is it that my string resources are picked according to the selected language but drawables arent Aug 21 11:34:01 in 2.3.3 the drawables are picked according to the language but in 4.0.3 it seems to pick the default drawables Aug 21 11:35:00 wow the Google now app just beautiful. Does anyone know the font they used for this app? Aug 21 11:35:12 is there a reason that in the onResume() method of my fragment, an edittext in my layout has a getWidth() that returns 0?? Aug 21 11:35:45 donotunderstand Aug 21 11:36:05 view hasn't been attached yet? Aug 21 11:36:15 mephju: http://developer.android.com/design/style/typography.html ? Aug 21 11:36:32 there's a download link on the right Aug 21 11:36:58 doc_savage, r u sure? Aug 21 11:37:07 Hi, I have a colored rectangle on my screen. I then write some text and enclose some text in it. I'm trying to use Canvas.DrawText to try to center the text using the method detailed here --> http://stackoverflow.com/questions/4909367/how-to-align-text-vertically (since this exactly my problem too). However, the text doesn't seem vertically aligned to my eyes. What gives? Is there a simeple Aug 21 11:37:07 way to align the text vertically? Thank you. Aug 21 11:37:21 how do you use the font in apps? Aug 21 11:37:22 mephju: no, I've not used google now, but that is the font they're pushing for use on android and I presume what it used for google now Aug 21 11:37:22 the word ROBOTO on that page really looks like the font used in google now Aug 21 11:37:32 CallumTaylor: is that possible? I thought onResume() was called way after onattach Aug 21 11:37:33 do you have to load them in customary in code, or is there an option to change global fonts Aug 21 11:37:40 * enclose it in a rectangle. Sorry. Aug 21 11:37:46 stork: i guess so if its returning 0 Aug 21 11:38:06 mephju: roboto is afaik the font used everywhere in android since 4.0. Aug 21 11:38:15 bizarre Aug 21 11:38:41 well. on my device which is 41, the fonts of my own apps don't look like the font being used in Google Now Aug 21 11:39:05 whats the sdk target Aug 21 11:39:11 14 Aug 21 11:39:28 hm Aug 21 11:39:44 haha omg...It Aug 21 11:39:47 is 13 Aug 21 11:40:17 mephju: just loaded it up, I think that is the same font, just italic in google now Aug 21 11:40:33 (at least on the 'Get Google Now' screen anyway Aug 21 11:43:17 doc_savage, but how do they make the font THAT narrow Aug 21 11:44:12 that download has a "roboto thin" Aug 21 11:44:20 and a roboto light too Aug 21 11:44:30 I assume it's one of those Aug 21 11:45:08 see the specimen book (also on that page) Aug 21 11:45:15 and I guess it's not possible to set it through xml Aug 21 11:46:05 can anyone take a quick look at a Crash Debug Android report, and see if they recognize any reason why the "Window died" , http://pastebin.com/2YZGmQFW the game crashes when i load up a map, it logs into my server fine, it loads up the map, and as soon as its abotu to switch screens, it dies Aug 21 11:46:23 at the bottom, I/iNemoSensor( 2214): enable(): handle(0), en(0), what(0) D/AkmSensor( 2214): akm_disable_sensor: Accel is disabled. (orien = 0) I/AkmSensor( 2214): enable_accelerometer, mEnabled = 1, enable = 0 D/Zygote ( 1913): Process 2002 terminated by signal (11) Aug 21 11:46:34 happens only on Samsung Galaxy s2, and s3 Aug 21 11:46:43 works perfectly on all other models Aug 21 11:46:52 the only common feature i can find, is Mali-400 Aug 21 11:47:01 because the s2x works fine, but its adreno 220 Aug 21 11:47:10 so does the gnexus Aug 21 11:47:35 the game is online, http://m.realdefinition.net/ Aug 21 11:47:51 tripknotix: signal 11 is segementation fault isn't it? Aug 21 11:48:11 it happens after you do a Guest Login, it starts loading themap, once everything has loaded, it switches to teh scene Aug 21 11:48:16 what does that mean appel1 Aug 21 11:48:56 im sorry, i have to confess, ive only been developing using Unity , i havent dug into the details of android, 3 months and this issue has just come up in the last few weeks Aug 21 11:49:27 is there a reference for those signals appel1 Aug 21 11:49:45 an android reference page Aug 21 11:50:00 tripknotix: in unity there is an option to build on different devices? Aug 21 11:50:04 when you compile Aug 21 11:50:49 tripknotix: invalid memory access usually Aug 21 11:51:22 yes there, but the standard one seemed to workf or all devices Aug 21 11:51:26 yes there is^ Aug 21 11:52:10 acrtually there is only texture compression options Aug 21 11:52:16 but none of which are for mali-400 Aug 21 11:53:04 theres adreno, tegra, powervr, and etc1 or rgba16 (opengl es2.0) Aug 21 11:53:36 i guess i can try the last one Aug 21 11:53:42 but i usually dotn over wride Aug 21 11:53:44 soit works with all Aug 21 11:53:59 powervr is not the samsung devices? Aug 21 11:57:13 tripknotix: is there any stack trace in the log after a crash? Aug 21 11:57:26 there are many samsung devices, the ones im having troubnel with are mali-400 Aug 21 11:57:42 this guy did not have a trace directory so it did not save it, it looks like, but ill ask him Aug 21 11:58:09 these guys have the same issue as me, http://forum.unity3d.com/threads/147436-Android-game-crashes-on-scene-loads-(Inflate-error-signal-11-(SIGSEGV)) Aug 21 11:58:18 im goign to see if perhaps, they have a solution or can shed some light Aug 21 11:58:56 android needs better capabilities to switch between cell and wifi Aug 21 11:59:17 nothing like being 200MB into a download, switching wifi APs or switching cell<->wifi Aug 21 11:59:22 and having it fail Aug 21 11:59:52 there's nothing stopping the app from handling that gracefully =) Aug 21 12:00:22 they said that it didnt crash, it closed itself appel1 Aug 21 12:00:54 tripknotix: if it just dissapears then it is usually a native crash Aug 21 12:00:55 there is an option to enable logcat profiler, in unity but im not sure what that does Aug 21 12:01:03 tripknotix: as your log shows Aug 21 12:01:04 what does that mean appel1 Aug 21 12:01:06 hmm Aug 21 12:01:58 canadiancow: Android is absolutely loaded with examples like that... stuff where Google could spend $1000 on an engineer fixing something fancy in an afternoon vs us reimplementing it over and over again. Aug 21 12:02:26 I'm a bit surprised about the lack of 3rd party libraries handling that sort of stuff, though. Aug 21 12:02:47 Same with asynctask handling, dialogs, lifecycle management, etc. Aug 21 12:04:28 appel1: if there was a stack trace log, where would i find that, is it a unity thing? Aug 21 12:04:50 really they should hire a team (i.e. JakeWharton the one man army) to write compatability libs which might eventually get merged into the code Aug 21 12:05:09 tripknotix: not sure about unity, but when I've dabbled in ndk stuff it has shown up in logcat without me having to do anything :\ Aug 21 12:06:32 well im not sure what enable logcat profiler is, and if that will show up for him, if its something that has to be installed before hand =/ Aug 21 12:06:39 is logcat profiler a native android thign? Aug 21 12:07:14 damn i have to have the device to do that Aug 21 12:07:14 Anyone knows a vnc server that works on JB? Aug 21 12:07:15 nevermind Aug 21 12:07:39 appel1: do u see the last line, http://forum.unity3d.com/threads/147436-Android-game-crashes-on-scene-loads-(Inflate-error-signal-11-(SIGSEGV)) Aug 21 12:07:58 is there an equivelent for eglPreserveContextOnPause , on api 8 (android 2.2) Aug 21 12:08:18 my friends phones can only do 2.2 Aug 21 12:08:26 so i want to keep compatibility sinc eit works with them Aug 21 12:08:38 i mean is the onyl solution to create a higher api version, for samsung galaxy phones? Aug 21 12:09:56 stork: i think if they cared, they would have fixed it Aug 21 12:10:07 i'm going with: not a priority Aug 21 12:13:20 damn, it could be anythign Aug 21 12:13:20 no tripknotix Aug 21 12:13:21 lol Aug 21 12:13:22 wat Aug 21 12:13:55 if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.ICE_CREAM_SANDWICH) { glSurfaceView.setPreserveEGLContextOnPause(true); } Aug 21 12:14:00 use it where you can Aug 21 12:14:03 dont use it where you cannot Aug 21 12:14:07 err not ICS Aug 21 12:14:09 HONEYCOMB Aug 21 12:15:36 interesting Aug 21 12:15:51 based on the log, does it look like thats the issue canadiancow Aug 21 12:15:56 i dont know Aug 21 12:16:00 i didnt look at your log Aug 21 12:17:23 http://pastebin.com/2YZGmQFW Aug 21 12:17:27 at the bottom Aug 21 12:17:45 I have 2 jar files residing inside Linux/android/vendor/myjar/libs/frameworks . I need to access this jar from my application inside Linux/android/packages/apps Aug 21 12:17:50 How should I specify the LOCAL_STATIC_JAVA_LIBRARIES and LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES in the Android.mk of my application such that I can access these jar's from my application. Aug 21 12:17:53 (1) core.jar and (2) porting.jar is the name of the jar files Linux/android/vendor/myjar/libs/frameworks. If someone can help me define the LOCAL_STATIC_JAVA_LIBRARIES and LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES, it is appreciated. Aug 21 12:17:56 let me rephrase that Aug 21 12:18:05 im willing to offer help when i immediately know the answer Aug 21 12:18:09 but i am at work Aug 21 12:18:12 being paid for my expertise Aug 21 12:18:19 oh ok Aug 21 12:18:22 so there's a limit to what i will give away for free on irc while im being paid :P Aug 21 12:18:30 sure sure Aug 21 12:18:31 (by someone else) Aug 21 12:18:44 i mean youll get paid either way... Aug 21 12:18:47 =P <3 Aug 21 12:18:53 my gl knowledge is fairly minimal Aug 21 12:18:59 you've probably hit the limit already Aug 21 12:19:58 i just know the preserve context thing because AndEngine doesn't use it Aug 21 12:20:03 and ive been looking at implementing it there Aug 21 12:22:27 its ok, thanks anyway can Aug 21 12:36:13 Could you give me some hints how to implement custom AsyncTaskLoader that immediately deliver cached result from SQLite database but requests those cached data update and sequentially delivers updated results as they came? Aug 21 12:50:22 Anyone knows a vnc server that works on JB? Aug 21 13:07:34 hi guys ... hope someone can help me with my problem. i'm trying to override the method getItemId(int position) inside my customized android.support.v4.app.FragmentPagerAdapter, but somehow the method is not included, although even the official android documentation says it should be included. i've searched for hours now, but nobody else does seem to have the problem. what am i missing? I'm beginning to think im just blind or somet Aug 21 13:08:03 not included? Aug 21 13:08:07 k Aug 21 13:08:25 mrmaffen, you sure? Aug 21 13:08:28 I don't understand what I have to import for getting my R to work. Bitmap ball = BitmapFactory.decodeResource(getResources(), R.drawable.ball); Aug 21 13:08:43 there is no getItemId(int position) inside android.support.v4.app.FragmentPagerAdapter Aug 21 13:08:43 I dragged the accelerometerplay sample file into a new android project Aug 21 13:08:48 added their png and jpg files to the resolution resource directories to resolve those errors Aug 21 13:08:49 i've checked several times :S Aug 21 13:09:17 mrmaffen, make sure you have the latest support package Aug 21 13:09:21 because i can guraantee you it's there Aug 21 13:09:23 i just checked Aug 21 13:09:47 android-sdk-windows\extras\android\support\v4\src\java\android\support\v4\app\FragmentPagerAdapter.java Aug 21 13:10:20 i'm using actionbarsherlock with the android.support.v4.app package, so maybe that's the problem? although i think the support packages should be identical Aug 21 13:11:15 i'll check if my support package is up to date Aug 21 13:11:21 man this is driving me crazy Aug 21 13:14:28 * Jaggz- shakes iron fist at android Aug 21 13:16:11 Jaggz: are you using the ball drawable inside your projects drawable folder ? Aug 21 13:16:49 Jaggz: and did you check your layout files ... if there's an error in one of your xmls, R is not being generated Aug 21 13:17:20 first project really. Aug 21 13:17:36 just copied one of the sample files Aug 21 13:27:30 it was the support package that came with actionbarsherlock which didn't have the getItemId(int position) Aug 21 13:27:43 i just copied the newest support package directly out of the android sdk, and now it works Aug 21 13:27:56 what's wrong with this? seems onDraw is never called. http://pastebin.com/0VztdcTP Aug 21 13:28:08 my bad that i've trusted actionbarsherlock -.- Aug 21 13:28:09 grrr Aug 21 13:28:32 gee a release of ABS from 6 weeks ago didnt have the support package from 2 weeks ago? Aug 21 13:28:43 big surprise Aug 21 13:29:10 getItemId was added into the support package 2 weeks ago Oo ? Aug 21 13:29:42 the latest support library was released last week Aug 21 13:30:18 the latest ABS was released in may Aug 21 13:30:25 yeah i know Aug 21 13:30:42 but still the support library should include the getItemId method, right ? Aug 21 13:30:54 i mean the support packages before the current release Aug 21 13:30:55 i have no idea Aug 21 13:31:07 kk ... whatever Aug 21 13:31:09 it does work now Aug 21 13:31:32 thanks for helping me out Aug 21 13:36:06 hey guys.. i am using LayoutParams.FLAG_NOT_TOUCH_MODAL and LayoutParams.FLAG_WATCH_OUTSIDE_TOUCH to get the touch event in the former activity and based on that dismiss the current activity. The problem is that my former activity has a listview so on clicking on that it invokes the onclicklistener of the listview's adapter also Aug 21 13:37:23 And the listview's onclicklistener doesn't work on that instant but pauses and activates only after i click on anything else Aug 21 13:38:22 what's wrong with this? seems onDraw is never called. http://pastebin.com/0VztdcTP Aug 21 13:41:32 mrmaffen: have you found your solution? Aug 21 13:42:23 blackhex: yeah, thanks for asking :) i needed to copy the newest support package into my abs project's lib folder Aug 21 13:43:11 mrmaffen: ok, since had the same problem recently and the solution was to include another support package v4 vs. v13 iirc Aug 21 13:43:36 mrmaffen: I was fighting with ViewPager quite a long time recently Aug 21 13:43:37 your answer here: http://stackoverflow.com/questions/7723964/replace-fragment-inside-a-viewpager/11974777#11974777 helped me a lot ... thanks for posting that Aug 21 13:43:46 mrmaffen: np Aug 21 13:44:07 mrmaffen: the last comment is the most important Aug 21 13:44:23 yeah that's the answer i meant in particular Aug 21 13:45:12 last night i spent hours on this stuff ... but nothing is better than the feeling to really have gotten your head around something Aug 21 13:45:18 mrmaffen: but still i'm not sure if attaching and detaching a fragment without adding or removing it from transaction coudn't cause sime problems in future Aug 21 13:45:52 mrmaffen: hmm, that's true, now I'm fighting with AsyncTaskLoader with cache :-( Aug 21 13:45:52 yeah me neither :S Aug 21 13:46:10 http://stackoverflow.com/questions/12055299/custom-asynctaskloader-with-cache/12055714#12055714 Aug 21 13:46:39 :S Aug 21 13:46:52 yeah i've heard that working with the loader can be a bit tricky sometimes Aug 21 13:48:21 new bug verison if someone can take alook, https://www.dropbox.com/s/6tnmap0jn9lkeua/myfile.txt Aug 21 13:48:39 appel1: same result, different log Aug 21 13:49:00 I/ActivityManager( 2215): Process com.RealDefinition.ZombieOpsOnline (pid 7227) has died. Aug 21 13:49:06 mrmaffen: that's not my case, at least not for now, I rather fight with understanding how to bend AsyncTaskLoader to my needs than some missbehave of it Aug 21 13:52:16 is it possible to display the percentage inside of a progressbar? Aug 21 13:52:28 like [-------50% ] Aug 21 13:53:31 sonOfRa: http://weavora.com/blog/2012/02/23/android-progressbar-with-text/ Aug 21 13:53:39 thanks Aug 21 13:56:26 http://android.stackexchange.com/questions/25927/all-unity-3d-games-force-close Aug 21 14:07:05 so I have a catch-22 here: R.java ITSELF contains errors which would resolve if it rebuilt, but of course it won't rebuild while errors exist in the project, so... how do I proceed? :) Aug 21 14:09:13 filter: using eclipse? if so try Project -> Clean from meubar Aug 21 14:10:46 yep eclipse, but alas clean doesn't help, removing the offending lines manually causes it to restore the bogus copy, deleting it causes it to restore the bogus copy Aug 21 14:11:15 i once fixed such a bug by making the file readonly Aug 21 14:16:14 I have a TextView element that contains a long document. Is there a way to set the 'starting position' to halfway through the text? Aug 21 14:16:47 I don't see any attribute that looks helpful, perhaps I could scroll automatically? Aug 21 14:17:49 Setting up ABS for the first time. Should I have support library in my project as well as ABD lib project? Aug 21 14:18:33 yes Aug 21 14:18:41 and they must be the same version Aug 21 14:25:52 Hmm. Still getting NullPointerException on on api < 14. ABS 4.1.0 using SherlockActivity and set theme. Any advice on where to start debugging? Aug 21 14:27:44 at the line that had the NPE Aug 21 14:31:31 *sigh* another fun trap. Aug 21 14:32:16 you want a ListPreference. You put @array/foo_entries as the entries as the value. You press cmd+1 and let android autogenerate arrays.xml 1 for you Aug 21 14:32:29 then you try to use it and it crashes in nullpointerexception. The cause? Why, it has to be ! Aug 21 14:32:52 hah Aug 21 14:32:57 Fuck this god damn ADT shit and everything that is so idiotic about it Aug 21 14:33:33 like these automatic fixes that are wrong Aug 21 14:43:30 *sigh* ADT is alright but it's still not user-friendly enough. I guess I'm just incredibly frustrated about this sort of bug because it did not occur for me for some time that it proposed invalid automatic fix Aug 21 14:47:28 i can only recommend to set a shortcut to "project-> clean" ... already saved me hours of clicking :D Aug 21 14:47:42 still extremely annoying though :S Aug 21 14:49:16 unlike other people, I never have to clean project to clean some bug Aug 21 14:49:23 I guess I just don't do something other people are doing Aug 21 14:49:48 i only have to do it to convice the resource compiler to run Aug 21 14:49:58 * alankila is preparing for releasing his first app. Aug 21 14:50:01 which i find to less necessary than it used to be Aug 21 14:50:37 alankila: gz :) Aug 21 14:51:10 acquired developer account today, paid the $25 free, waiting for google to send some test payment to my bank account, etc. Aug 21 14:52:36 ok seriously, where does eclipse/adt store this backup copy of R.java? I need to nuke it very badly Aug 21 14:52:43 filter: gen/ Aug 21 14:52:52 oh wait, backup copy? maybe it's under bin/ Aug 21 14:52:57 that's where it stages the build Aug 21 14:53:02 do a clean Aug 21 14:53:05 that will kill everything Aug 21 14:53:12 I removed both, but it still manages to pull it out of somewhere Aug 21 14:53:20 it regenerates it... Aug 21 14:53:23 what are you trying to do Aug 21 14:53:39 hi droid developers Aug 21 14:53:42 *Android Aug 21 14:54:10 JakeWharton: android, android ok ;-) Aug 21 14:54:15 sorry, here's what happened: I found some really old strings from six months ago that I had named like ... so I changed the periods to underscores and saved the file, but apparently that was a terrible idea Aug 21 14:54:43 A.) they already get converted to underscores anyway when R.java is generated, B.) the underscored and period versions are considered different up until they get inserted into R.java, and then C.) the build process happily inserted the duplicate entries before cleaning out the old ones Aug 21 14:54:59 so now voila, R.java won't rebuild because it, and no other file (and I really, really, really mean no other file), contains errors Aug 21 14:56:15 hmm ... so there could be foo.bar and foo_bar and the build crashes because of this? Aug 21 14:56:39 due to making duplicate public static int foo_bar twice? Aug 21 14:56:45 or how do you mean it doesn't rebuild? Aug 21 14:57:46 oh crap I got a meeting that I must go to Aug 21 14:57:48 my R.java has several duplicate entries now, and it must not be rebuilding from my XML because there are no duplicates in my XML Aug 21 15:00:46 is there any way to remove the fading edge you get with textviews doing marquee scrolling? Aug 21 15:00:47 filter: if you don't have untracked file in your project directory, you can git clean (assuming you use git) Aug 21 15:02:22 I have many, but that's worth a shot--I'll copy the whole dir structure and try a git clean Aug 21 15:06:34 nah, no luck there either Aug 21 15:14:16 I have a TextView element that contains a long document. Is there a way to set the 'starting view' to a dynamic number of lines into the text? Aug 21 15:14:30 (rephrased to make it slightly less of a shit question)))) Aug 21 15:18:44 aadq: it's still a confusing question, but you can set android:lines on the textview, optionally with an ellipsize option. There's no nice toggle to make it show the entire text, though. Aug 21 15:20:17 HDroid: The document is 1000+ lines long. I currently have it in a TextView and can scroll through it without problem. I would like to start the 'view' at, say, 500 lines into the document. Am I making slightly more sense? :D Aug 21 15:20:38 Oh you want to scroll to some part in the textview? Aug 21 15:20:42 correct Aug 21 15:20:50 automatically Aug 21 15:21:55 Hm, scrollview has scrollTo (but it takes coordinates instead of lines), I'm not aware of similar functionality in textview. Aug 21 15:22:56 I could write my own function, but I don't know the method to scroll a TextView via code. Aug 21 15:24:59 ScrollingMethodMovement pageDown(), i suppose Aug 21 15:30:16 i have a scrollview that has custom buttons on it… with those, smoothscroll doesn't work, but it does with a standard button… any idea why? Aug 21 15:36:46 so I've got a GridView, and we set the selector like this: mGridView.setSelector(R.drawable.feed_item_selector); Aug 21 15:36:49 aadq: I can't vouch for the correctness, but in the past I've successfully used getLineHeight() * SOME_LINE_NUMBER as the y parameter to scrollTo() Aug 21 15:36:54 which highlights single items in ICS Aug 21 15:37:00 but highlights the WHOLE GRID VIEW in Froyo Aug 21 15:37:02 why? Aug 21 15:41:49 blackhex: i'm getting a illegalstateexception when calling the back() method in your pagerAdapter: "can't change tag of fragment". do you know what could be the cause of this? Aug 21 15:42:12 i've modified it to support unlimited amounts of fragments in the backtrace Aug 21 15:42:45 mrmaffen: I made this change too, but I don't have this exception Aug 21 15:43:03 mrmaffen: I can send you my code... Aug 21 15:43:10 why does setting android:listSelector="@color/foo" highlight the ENTIRE GRID VIEW on 2.2? Aug 21 15:43:11 that would be awesome ! :) Aug 21 15:43:19 mrmaffen: are you setting tags of the fragments? Aug 21 15:43:23 is this a major bug or do I have a weird GridView or something? Aug 21 15:43:26 no i'm not Aug 21 15:44:20 mrmaffen: what's your e-mail? Aug 21 15:44:24 works fine in ICS, but fails miserably in 2.2 Aug 21 15:46:18 filter: cheers Aug 21 15:47:15 what a weird bug Aug 21 15:47:16 http://stackoverflow.com/questions/2183447/listselector-applies-to-the-entire-list Aug 21 15:52:35 I have pretty much the exact code as on here ---> http://stackoverflow.com/questions/4909367/how-to-align-text-vertically and am trying to do the same thing. I have a rectangle A that's of a certain color. I create another rectangle B that is inside of A and has some text. I'm able to center the text horizontally - but not vertically. I've tried the snippet of code in the link above but Aug 21 15:52:35 it doesn't seem to be centering. Was wondering what I'm missing. Any help would be greatly appreciated. Thank you. Aug 21 16:05:53 Hey, very stupid question, but how do I explore what styling options I have in ActionBarSherlock? I am trying to find out how to reference the ActionBar divider in Widget.Sherlock.blahblah. Aug 21 16:09:47 hi Aug 21 16:09:56 is possible to record audio in background? Aug 21 16:10:04 form a thread, service or alarm? Aug 21 16:11:01 Farfennugen, you could check this out http://jgilfelt.github.com/android-actionbarstylegenerator Aug 21 16:11:44 So I have an app I'm making that will require people to login to a custom made web service. But we agreed that there's so many services out there and many apps asking people to login to google, facebook, twitter, etc that it's the best approach we can do as well. We know we need to do OAuth to authenticate with the services, but how do we use THAT authentication for OUR data? OpenID? Aug 21 16:13:57 Jouva: OpenID is a different protocol than OAuth; Aug 21 16:14:06 I'm very aware of that Aug 21 16:14:17 And I'm aware they are solutions for different problems Aug 21 16:14:31 Jouva: I recommend you get familiar with OAuth 2, as OAuth 1 and 1a will be shortly deprecated; see http://oauth.net/2/ Aug 21 16:14:49 BadDesign: That's still out of the scope of my question as to which one to use Aug 21 16:15:42 BadDesign: My question was asking: "Ok, I have the OAuth data. Now what?" I'm not using the service directly. I'm using it mostly to identify themselves Aug 21 16:15:57 So I think I'd be using OpenID for this? Aug 21 16:16:21 is there anyway to move the google logo in map view up a few pixels like in maps app? Aug 21 16:16:37 I'm trying to achieve the same bottom navigation as the maps app, but it overlays the google logo Aug 21 16:18:21 Jouva: if you only require authentication and not authorization you can use OpenID, because that allows the user to use the same ID he already has if he uses Google, Facebook, etc... on your app; Aug 21 16:18:34 Right Aug 21 16:18:40 authentication only tells you who the user is not what rights he has Aug 21 16:18:47 Right Aug 21 16:22:48 i'm trying to animate something using a scroller, and I want to call Handler.postDelayed every 16ms Aug 21 16:22:53 how can I do that? Aug 21 16:23:01 I figured throwing it into a while loop would do it Aug 21 16:23:13 but not so, i think it's blocking the UI thread :-/ Aug 21 16:23:28 make the handler a public variable Aug 21 16:23:34 then call itself inside the runnable Aug 21 16:23:46 ooh, good idea Aug 21 16:24:23 CallumTaylor: I couldn't just use the this keyword? Aug 21 16:24:34 wait Aug 21 16:24:37 no i can't, i see it Aug 21 16:24:42 I have pretty much the exact code as on here ---> http://stackoverflow.com/questions/4909367/how-to-align-text-vertically and am trying to do the same thing. I have a rectangle A that's of a certain color. I create another rectangle B that is inside of A and has some text. I'm able to center the text horizontally - but not vertically. I've tried the snippet of code in the link above but Aug 21 16:24:42 it doesn't seem to be centering. Was wondering what I'm missing. Any help would be greatly appreciated. Thank you. Aug 21 16:26:53 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 21 16:30:23 JakeWharton: I didn't knew you were the developer of Actionbar Sherlock when I asked a question about Actionbars today morning. Thanks anyway. :) Aug 21 16:30:36 yes, sir. at your service! Aug 21 16:31:37 JakeWharton: I'm reading the FAQ and docs to digg more. I will surely have doubts in the future. Hope I can find you here ;) Aug 21 16:32:31 there's also a mailing list and stack overflow. but keep in mind the API is exactly the same as the native action bar so any questions you have around how to do something with the action bar is probably not ABS specific and can be asked of the native action bar Aug 21 16:32:59 I see, Aug 21 16:33:07 a lot of people fall into the trap of asking fundamental questions about ABS that actually have nothing to with ABS Aug 21 16:33:42 ok, got it. The basic questions should be answered by the Android docs itself. Aug 21 16:38:25 hello Aug 21 16:38:46 the MediaRecorder can be used from a service? Aug 21 16:40:10 try it and let us know Aug 21 16:42:43 erg, class SomeClass { void someMethod(SomeOtherClass param) {}} seems to be problematic when used like SomneClass Aug 21 16:43:04 and calling some method Aug 21 16:43:57 i am trying to create different AsyncTasks and respective listener for differnet result types Aug 21 16:44:08 if i were to compile a c program in android which headers would i need ? Aug 21 16:44:21 #include ? Aug 21 16:44:53 well i got this cc-tools thing, and it compiles and runs fine there, but the native-activity thing is failing.... Aug 21 16:45:08 the hello world example i mean Aug 21 16:45:19 duh Aug 21 17:16:24 hey guys, i'm trying to implement Cyril Mottier's slide menu Aug 21 17:16:39 i'm having trouble interpreting what he's saying for scrolling content using Scroller Aug 21 17:16:42 http://android.cyrilmottier.com/?p=658 Aug 21 17:17:18 right now, my code is set up to call the Runnable evert 16ms, computeOffset, and do offsetLeftAndRight Aug 21 17:17:31 but when/where do I call anim.startScroll? Aug 21 17:17:56 currently, I call it outside of the Runnable, and just after I do the handler.postDelayed Aug 21 17:18:24 I set the startScroll's dx to 200, but that send my content flying off the screen Aug 21 17:20:06 To use KSoap you have to download the jar right? Aug 21 17:20:51 oh sweet, figured it out :) Aug 21 17:22:22 how? Aug 21 17:26:54 anyone use AIDE? Aug 21 17:30:09 nobody active Aug 21 17:34:01 im amazed at how many people build against the sdk that matches their minSdkVersion Aug 21 17:34:45 canadiancow: those are clueless people Aug 21 17:34:54 * HorizonXP is currently writing for API 16 Aug 21 17:35:03 but minSDK = 10 Aug 21 17:36:20 is it possible to root an HTC Merge, running android 2.2? Aug 21 17:36:41 its not rooting channel, try on android-root Aug 21 17:36:47 im trying to convince someone who writes an open source tool lib that i use to stop building against 1.6 :P Aug 21 17:37:09 because i cant use their lib project without modifying it due to lint errors when it sees the build target so low Aug 21 17:37:11 or something like that Aug 21 17:39:23 canadiancow: smack em Aug 21 17:39:32 or fork it Aug 21 17:39:36 it is forked Aug 21 17:39:38 whichever's easier Aug 21 17:39:43 ixc: thanks Aug 21 17:39:44 well i also want to educate Aug 21 17:39:51 this is something my company's going to use for a while Aug 21 17:39:55 and if i can help improve it at teh source... Aug 21 17:40:45 ah fair enough :) Aug 21 17:53:26 canadiancow: I'd figure they should do a @TargetAPI() rather than change what version to build against Aug 21 17:54:10 Oh you meant the TARGET isn't new but the min and target are both 1.6 Aug 21 17:54:20 the build target is 1.6 Aug 21 17:54:25 as an example of why that wont work, i have an app that suppors and uses nfc, and suppors 2.1 Aug 21 17:54:38 the nfc apis dont exist until 2.3, so you MUST build against at least 2.3 Aug 21 17:54:50 Yeah min should stay 1.6 but target should be 4.1 now Aug 21 17:55:16 And just @TargetAPI anything that has specifics for stuff above 1.6 Aug 21 17:55:22 That's what they need to do Aug 21 18:03:32 canadiancow: wait, you can't write an app that uses NFC with a min SDK less than 2.3 Aug 21 18:03:35 ? Aug 21 18:04:11 yes you can Aug 21 18:06:28 canadiancow: ok, that's what i thought. i misinterpreted what you wrote then Aug 21 18:06:29 HorizonXP: He's saying that when he tries to use a library in his app that has a build target before 2.3, that he gets lint errors cause his build target is past 2.3 Aug 21 18:06:47 no Aug 21 18:07:04 im saying if you build against 1.6, you cant reference things like Build.VERSION_CODES.ECLAIR Aug 21 18:07:13 or android.nfc.whatever Aug 21 18:07:35 Yes but it's the library that's doing it, right? Aug 21 18:07:40 Not your whole project Aug 21 18:08:19 well the library being minSdkVersion="4" and building against 4 was causing some lint error Aug 21 18:08:25 i think Aug 21 18:08:27 i dunno there was a reason i changed it Aug 21 18:08:36 ahhh i get it now Aug 21 18:08:42 makes sense :) Aug 21 18:08:44 Right Aug 21 18:09:07 my project had minSdkVersion="7" and building against 15 Aug 21 18:15:13 Ugh so I'm conflicted here. I want an app I'm making to not require people to register for an account since there's already plenty of accounts that people have out there for various services, but we need to uniquely identify somebody across devices. So we'll be letting people login via Gmail, Facebook, Twitter and Yahoo. However for things like Facebook and Twitter we might want to do Aug 21 18:15:13 OAuth since we might let people make posts. But OAuth isn't for identity Aug 21 18:16:35 So what should I do here? And is there a way to do identity with the AccountManager info? Aug 21 18:23:40 Has anyone used SSH on the android device to achieve interdevice communication? If so how do you go about handling the dynamic IP issue? Aug 21 18:24:49 am server. Aug 21 18:24:58 a server Aug 21 18:26:02 Jouva: facebook will give you a user id, which can be used for identification Aug 21 18:28:03 kapilratnani: yes that's facebook. What about twitter? What about the other services just to get the identity? Aug 21 18:29:07 Sweet. I loving having issues relating to app private content on a device which isn't rooted and which doesn't give shell permissions to /data/data Aug 21 18:29:56 Jouva: check the documentation... there should be something similar for twitter and other services as well Aug 21 18:30:16 lov: dev on non-root is evil :P Aug 21 18:30:57 lov, im pretty sure it's rooted iff you have access to /data/data Aug 21 18:31:36 canadiancow: /data/data itself is a=rX, iirc Aug 21 18:32:01 it's indvidual app dirs that are u=rwX o-rwx Aug 21 18:32:06 ... Aug 21 18:32:16 yeah, I don't have read permission into /data as a shell user Aug 21 18:32:16 ergh Aug 21 18:32:17 regardless Aug 21 18:32:20 http://code.google.com/p/android/issues/detail?id=949 Aug 21 18:32:22 I seem to be running into this Aug 21 18:32:26 Open since 1.0 r1! Aug 21 18:32:26 well in the context of this discussion, /data/data == /data/data/com.whatever Aug 21 18:32:27 swell. Aug 21 18:32:39 Happens for one and only one db file, too. Aug 21 18:32:41 * p_l mixed up owner and others in his example again Aug 21 18:32:45 What's the problem with that file? WHO KNOWS! :D Aug 21 18:32:46 Jouva: confirmed. twitter also provides a user_id Aug 21 18:35:22 would you put a hint in a password field? Just saying password or something? Or just leave it blank? Aug 21 18:39:06 Yes, a hint is a good idea. Aug 21 18:43:39 anyone have some pointers on how to securely log in to a remote server? thinking of packetsnooping Aug 21 18:44:50 SSL? Aug 21 18:46:07 xorgate: just use SSL christ Aug 21 18:46:12 what decade are you in Aug 21 18:47:00 i found it hard to figure out how to do that in android Aug 21 18:47:03 also, the 1990s Aug 21 18:47:14 i mean, rot13 might be an acceptable substitute Aug 21 18:47:47 maybe even rot26, that's twice as secure, right? Aug 21 18:49:08 that's unbreakable! Aug 21 18:49:09 no Aug 21 18:49:09 xorgate: are you using HTTP, or are you rolling your own protocol? Aug 21 18:49:14 i prefer double rot13 Aug 21 18:49:15 If you're using http, just use HttpsUrlConnection Aug 21 18:49:23 canadiancow: unacceptable. triple rot13 Aug 21 18:49:24 because then you actually have to run the algo twice Aug 21 18:49:27 it's like triple DES but without the cost Aug 21 18:49:34 lov right now, i use http with post to send login/pass to app engine Aug 21 18:49:48 is it that easy? Aug 21 18:50:15 It is seriously that easy. Aug 21 18:50:24 my app engine then checks the login/pass against what it has stored, and responds accordingly Aug 21 18:50:32 later on i will implement some real safety :0 Aug 21 18:50:37 https is not difficult, if your server side certificate isn't ghetto Aug 21 18:50:38 but ok, i will give that a whirl Aug 21 18:50:58 The simple solution is to just use HttpsUrlConnection. If you're concerned about MITM because you're totally paranoid, you can modify what certificates it will accept, etc. Aug 21 18:50:58 don't be comin round here with no self-signed certs! ;) Aug 21 18:51:02 will app engine take care of this for me? or do i have to make a certificate Aug 21 18:51:10 I have no idea how app engine works. Aug 21 18:51:20 You probably don't have to make a cert if your webserver actually has a public cert for ssl Aug 21 18:51:25 so uh actually Aug 21 18:51:29 well i dump .py files and i can access it :0 Aug 21 18:51:29 does your webserver support https? Aug 21 18:51:38 because if it doesn't that's step 0. Aug 21 18:51:40 go buy a cert. Aug 21 18:51:50 app engine is my webserver Aug 21 18:51:55 so 'google' Aug 21 18:52:28 oh whoops Aug 21 18:52:30 derp Aug 21 18:52:41 Was thinking you meant you were writing the android app in app inventor Aug 21 18:52:49 heavens no Aug 21 18:53:01 appengine PROBABLY has https Aug 21 18:53:13 yeah, I have no idea how app engine handles ssl, but I'm assuming that the answer is "transparently" and "you don't even need to care" Aug 21 18:53:22 And is PROBABLY a well known cert, especially for android Aug 21 18:53:26 right i'll give it a whirl Aug 21 18:54:07 I'd be REALLY shocked if something like appengine didn't have https access and that said https cert wasn't known on most/all devices Aug 21 18:54:20 first result for "appengine https" http://googleappengine.blogspot.com/2008/10/announcing-https-support-for-appspotcom.html Aug 21 18:57:00 I am using OpenGL for the first time, I am having trouble in importing android.graphics.OpenGLContext. Any quick Fixes? Aug 21 18:57:31 OpenGL: use a class that exists ._. Aug 21 18:57:41 maybe you just need to "import myself;" Aug 21 18:58:07 are you maybe thinking of http://developer.android.com/reference/javax/microedition/khronos/egl/EGLContext.html instead? Aug 21 19:03:47 Ok, so OpenGLContext was an old class which was given in a tutorial I was following. I have to use a new Java micro version, EGL as you suggested. I could import that. thanks lov Aug 21 19:04:30 or use an engine Aug 21 19:04:47 people who use opengl directly are, or will soon be, insane Aug 21 19:04:59 canadiancow: you mean a game engine? Aug 21 19:05:18 any kind of engine Aug 21 19:05:26 some kind of abstraction layer Aug 21 19:05:29 game engines are a good example Aug 21 19:07:28 canadiancow: ok I also need to integrate the code later with Android Open Accessory(have written a working code, currently working on improving display) Aug 21 19:07:39 would it be a problem if I opt for an engine? Aug 21 19:07:51 i doubt it Aug 21 19:08:01 im just saying i couldnt work with raw opengl very long without pulling my hair out :) Aug 21 19:08:22 hey canadiancow Aug 21 19:08:24 ok thanks for sharing your experience :) Aug 21 19:08:29 yea, i recently did that, i felt the same Aug 21 19:08:50 there is a lot of indirect relationships which are a pain Aug 21 19:11:05 i looked at opengl for a couple days, in which time i was able to gather that it would require far more than a couple days to learn :P Aug 21 19:11:54 Thanks Napalm and wongk : I need to get this working by the end of this week. Wish me luck :P Aug 21 19:12:33 if its just android, try AndEngine Aug 21 19:12:37 it's smexy Aug 21 19:13:25 oh did i tell everyone my dad got a galaxy nexus? Aug 21 19:13:28 i was so proud :) Aug 21 19:13:39 i don't even have a gnex Aug 21 19:13:40 canadiancow: I see its a 2D engine, I nneed to draw a 3D cube Aug 21 19:14:11 ah lame Aug 21 19:14:20 ive been told AndEngine could be made into a 3D engine in a day Aug 21 19:15:26 canadiancow: make it happen Aug 21 19:15:42 yea no Aug 21 19:15:56 there is at most one person capable of doing that Aug 21 19:15:57 and it's not met Aug 21 19:15:59 me* Aug 21 19:16:45 that's scary. Any knows of a 3D engine? Aug 21 19:17:23 a simple 3d Engine for Android? Aug 21 19:19:33 hey guys, question about kernels: I installed miui last night and forgot to install a kernel. can I still boot into recovery and flash one? Aug 21 19:19:48 yes Aug 21 19:20:01 recovery contains its own kernel Aug 21 19:20:38 OpenGL: I don't know about simple, but libgdx is pretty sweet Aug 21 19:20:53 Napalm: I won't need to wipe anything, right? Aug 21 19:21:00 You might want to use http://www.andengine.org/ instead, however. Aug 21 19:21:12 lov Aug 21 19:21:13 read up Aug 21 19:21:15 ~_~ Aug 21 19:21:16 Does it need to actually be in 3D, or is 2D/2.5D ok? Aug 21 19:21:27 the vast majority of "3D" games are really 2D/2.5D. Aug 21 19:21:55 pr0metheu5: probably, but you should ask in #android-root Aug 21 19:22:10 thanks lov Aug 21 19:22:52 lov: the 3d cube will move based on the accelerometer sensor reading in all 3 directions.. I think 2D should suffive, if its drawn in a neat fashion. Aug 21 19:23:26 You'll probably be fine with like libgdx or something Aug 21 19:23:48 Honestly, just search google for "Android 3D Engines" Aug 21 19:24:07 though if you're JUST drawing a cube based on an accelerometer, it's probably simplest to just make a simple GLSurfaceView implementation Aug 21 19:24:15 take a look at the API Samples Aug 21 19:24:29 there's some GL stuff in there, and some sensor stuff in there. Aug 21 19:25:49 lov: I have beeen looking at those stuff and did similar searches. Eventually ended up in a OpenGL tutorial for drawing a 3D cube Aug 21 19:26:17 OpenGL: I'd be extremely wary of any Android tutorials that are older than 2009, or even 2010. As you found, some are for pre-release SDKs and don't even compile. Aug 21 19:26:34 I have a declaration, private AbsoluteLayout ly; after the class declaration and I instantiate the variable in onCreate() as ly=(AbsoluteLayout) findViewById(R.id.widget49); Aug 21 19:26:36 however, when using the variable ly in onTouch() it gives nullpointer exception. is it that onCreate() is not called before onTouch() is called? Aug 21 19:26:39 I would be happy if I can make it more of a game, than just a simple 3D cube, but I will need the source code for it because of time constraints Aug 21 19:26:39 OpenGL: have you looked at http://developer.android.com/guide/topics/graphics/opengl.html yet Aug 21 19:26:42 ? Aug 21 19:27:17 mintt, dont use AbsoluteLayout Aug 21 19:27:19 it's deprecated Aug 21 19:27:24 it's been deprecated for 3 years Aug 21 19:27:46 lov: I opened the same page 5 mins before I logged in here Aug 21 19:27:58 should try those examples given there Aug 21 19:28:07 canadiancow: I might use FrameLayout, this is what droiddraw makes as default Aug 21 19:28:12 May be they are much simpler to follow Aug 21 19:28:45 dont use droiddraw Aug 21 19:28:46 canadiancow: my question was different though, i instantiate the variable on onCreate() and use it in onTouch(), however it gives nullpointer exception Aug 21 19:29:00 maybe findViewById returned null Aug 21 19:29:04 but still, dont use AL Aug 21 19:29:51 why would it return null ? it is put in main.xml Aug 21 19:30:00 did you setContentView? Aug 21 19:30:39 yes setContentView(R.layout.main); Aug 21 19:30:46 before calling findviewbyid? Aug 21 19:31:38 yes before calling Aug 21 19:31:59 i dont believe you Aug 21 19:32:03 you ahve said something that is not true Aug 21 19:32:08 paste all your code Aug 21 19:32:12 and xml Aug 21 19:32:20 are you sure onCreate() is called before onTouch() then i would try again making the variable public Aug 21 19:32:35 onCreate is called first, always. Aug 21 19:32:52 pastebin your code/layouts Aug 21 19:33:23 lov likes to repeat thing's i've said today Aug 21 19:33:25 :P Aug 21 19:33:38 this is the root element of the xml file Aug 21 19:33:42 I'll repeat your mom. Aug 21 19:33:43 android:id="@+id/widget49" Aug 21 19:33:43 android:layout_width="fill_parent" Aug 21 19:33:44 android:layout_height="fill_parent" Aug 21 19:33:44 android:background="#ffefefef" android:focusable="true" android:focusableInTouchMode="true" xmlns:android="http://schemas.android.com/apk/res/android"> Aug 21 19:33:46 stop. Aug 21 19:33:50 pastebin Aug 21 19:33:51 pasteBIN Aug 21 19:33:54 ... Aug 21 19:34:00 use a pastebin site like pastebin.com Aug 21 19:34:03 paste your code there Aug 21 19:34:04 press submit Aug 21 19:34:08 paste the URL you're given here Aug 21 19:34:14 seriously? Aug 21 19:34:26 canadiancow: your mom is pretty serious Aug 21 19:34:31 yo Aug 21 19:34:36 :3 Aug 21 19:34:37 your wife is pretty serious Aug 21 19:34:43 hot Aug 21 19:34:52 especially in all those pics you sent me Aug 21 19:35:01 those are pictures of my cat hth Aug 21 19:35:14 no, the ones of your wife Aug 21 19:35:28 anyhoo Aug 21 19:35:32 :D Aug 21 19:35:36 mintt: waitin on dem erls Aug 21 19:35:47 who married a cat? Aug 21 19:36:33 http://pastebin.com/gVLzWnRG Aug 21 19:36:56 lov: the layout is pretty plain, generated by DroidDraw Aug 21 19:37:35 mintt: ok, so pastebin your code. If your NPE is generated by a view that's not in that xml, please pastebin the WHOLE xml including that element. Aug 21 19:42:22 lov: let me check with logcat hold on Aug 21 19:43:36 is having a fragment-based viewpager inside a fragment going to cause problems? Aug 21 19:43:55 bah too warm to think Aug 21 19:44:14 yes Stew-a Aug 21 19:46:07 Woohooo I got a response from my database Aug 21 19:46:07 meh, it was such a nice way to display the information >.< Aug 21 19:46:12 E/AndroidRuntime( 1261): FATAL EXCEPTION: main Aug 21 19:46:13 E/AndroidRuntime( 1261): java.lang.NullPointerException Aug 21 19:46:43 Well the try don't fail at least. Now to find out how to get stuff out of this soapobject Aug 21 19:47:08 I have a class that extends another class, maybe the base class's onCreate() is called before the derived class's Aug 21 19:48:12 Hello. In browser app when you scroll the page up (or down with finger), the URL bar appears. When you then scroll down, the URL bar disappears. At first glance it seems the URL bar is separate from the webpage (ScrollView or whatever that is) but when you scroll up slowly and are at the top of the page, the URL bar looks like it's part of the ScrollView. I want to implement this effect (display a hidable widget on top of the scr Aug 21 19:48:12 een), is there a good way to do it? Aug 21 19:48:14 that would depend on your palcement of super.onCreate Aug 21 19:49:49 mintt: take a look at the topic. Aug 21 19:49:51 pastebin your stacktrace Aug 21 19:49:54 pastebin the relevant code Aug 21 19:49:58 pastebin your layouts, if relevant Aug 21 19:50:19 also, your base class's onCreate will be called when you call super.onCreate Aug 21 19:50:26 (you MUST call super.onCreate!) Aug 21 19:50:38 wongk and lov you are right Aug 21 19:50:48 this is a java issue rather than an android one Aug 21 19:53:06 rabbit have you tried anything yet? Aug 21 19:54:05 the problem is solved. thanks everyone Aug 21 19:55:18 ElefantPhace, I have not tried to implement it, but I guess i would use animations somehow, dynamically detach/attach the element I want to display depending if I want to show it above the 'ScrollView' or like a part of the ScrollView (when I scrolled slowly on top). I think this approach is too complex and there might be an easier solution. Aug 21 19:55:59 ... i tried to goole it, but didn't find anything :( Aug 21 19:56:16 try googling instead Aug 21 19:56:34 haha lov Aug 21 19:58:08 is it true that the kindle fire "trusts" the amazon android application store? Therefore you can download applications from it without checking the unknown sources. Does anyone know how they accomplished this? Aug 21 19:58:30 GeKKo__: seriously? Aug 21 19:58:35 GeKKo__: by making the firmware themselves. Aug 21 19:58:43 GeKKo__: you realize that Amazon Makes This Device, right? Aug 21 19:59:47 yes... you're sure thats a firmware thing and not modification to the android source? Aug 21 20:00:13 heh Aug 21 20:00:31 GeKKo__: put the store app on /system/app Aug 21 20:00:57 /system apps can get permissions downloaded apps can't Aug 21 20:01:21 yes, it's a change to the Android firmware used by the device Aug 21 20:01:41 GeKKo__: it's a preload. It is allowed to request certain permissions, including permissions to install applications directly without asking the user. Aug 21 20:01:51 they don't need to change the frameworks, but even if they did they could quite easily do so. Aug 21 20:22:11 is there a reason to separate wiring up the view references for a fragment into onActivityCreated instead of onCreateView? Aug 21 20:22:23 holy fuck Aug 21 20:22:26 my bank's app sucks Aug 21 20:22:29 they have an actionbar which is nice Aug 21 20:22:33 but there's a Home action item Aug 21 20:22:46 (which is a problem in itself...) Aug 21 20:22:49 but it just launches a new activity Aug 21 20:27:50 hi. Aug 21 20:27:58 canadiancow: at least they have an app that's not a wrapper around their webview Aug 21 20:28:10 I just installed android sdk but I can not find the NDK ... where does android put it? Aug 21 20:28:10 it is Aug 21 20:28:11 s/webview/mobile website Aug 21 20:28:14 :P Aug 21 20:28:18 for the most part Aug 21 20:28:21 convivial: you have to download the NDK separately Aug 21 20:28:21 the location finder is "real" Aug 21 20:28:22 I ask because I need its location for ecliopse Aug 21 20:28:29 but the login/transaction stuff is all in a webview Aug 21 20:28:34 and the whole thing is very ios-y Aug 21 20:28:37 convivial: http://developer.android.com/tools/sdk/ndk/index.html Aug 21 20:28:41 I downloaded them together from eclipose Aug 21 20:28:46 uh Aug 21 20:28:51 you don't need the NDK for eclipse... Aug 21 20:29:06 ok Aug 21 20:29:13 Does an arrayAdapter have a guaranteed order on the objects? Like the order the input is ordered in? Aug 21 20:29:14 how do I uninstall it Aug 21 20:29:18 ??? Aug 21 20:29:37 convivial: the SDK is for general development. The NDK is for developing native code. Eclipse has an ADT plugin which is for developing android apps in eclipse. Aug 21 20:29:46 Eclipse is just an IDE Aug 21 20:30:02 yes, i installaed ADT Aug 21 20:30:04 sonOfRa: probably the order that the array is in. Aug 21 20:30:14 convivial: you need to install and run the SDK. Aug 21 20:30:16 and now under android prefs it wants location of ndk Aug 21 20:30:18 probably is probably a problem :> Aug 21 20:30:54 convivial: I don't see that. Looking in preferences -> Android I only see an entry field for "SDK Location" Aug 21 20:30:54 it will not do anything related to android it keeps asking for ndk Aug 21 20:30:56 it would make sense to do it in that order, but I kind of want to know if I can rely on that Aug 21 20:30:57 SDK != NDK Aug 21 20:31:12 sonOfRa: look in the source I guess? Aug 21 20:31:17 expand the Android tree Aug 21 20:31:19 arrayAdapter is just a convenience class Aug 21 20:31:33 you will SEE NDK just below LogCat Aug 21 20:31:42 convivial: no, I don't see it. Aug 21 20:31:51 convivial: I see Logcat then Usage Stats Aug 21 20:32:01 do you have latest version of SDK? Aug 21 20:32:03 lov: http://mobilesyrup.com/2012/03/08/td-canada-trust-android-app-updated-brings-ability-to-initiate-stock-trades/ Aug 21 20:32:06 :) Aug 21 20:32:10 it is there Aug 21 20:32:21 convivial: I'm using 20.0.2v201207191942-... of the ADT. Aug 21 20:32:27 What version of the ADT are you using? Aug 21 20:32:38 I can try updating the ADT and seeing what happens, but a dependency on the NDK would be strange indeed. Aug 21 20:33:04 canadiancow: that's not even an actionbar, that's just straight out of iOS Aug 21 20:33:24 yeah, that's just lazy UX Aug 21 20:33:29 no no Aug 21 20:33:31 thats an old version Aug 21 20:33:36 that part's in the webview Aug 21 20:33:43 lov: latest adt is 20.0.3 fti Aug 21 20:33:47 *fyi Aug 21 20:33:48 yeah, I just checked Aug 21 20:33:51 I'll try updating, see what happens Aug 21 20:34:12 i think they just set targetSdkVersion >= 14 iwthout testing Aug 21 20:36:00 yea Aug 21 20:36:03 just got a toast when i logged in Aug 21 20:36:09 "press phone's menu button" blah blah Aug 21 20:36:54 convivial: Even using 20.0.3 I still don't see that NDK entry Aug 21 20:36:59 convivial: where did you install the ADT from? Aug 21 20:40:12 errr, when i rotate my screen, my fragment is getting a null Bundle in onActivityCreated Aug 21 20:40:38 hi lov, http://tinypic.com/r/mcdpol/6 Aug 21 20:40:44 that is what is installed Aug 21 20:40:58 it is image of eclipse installed 'wares Aug 21 20:41:03 safe for work! Aug 21 20:42:16 you see plainfully NDK is there Aug 21 20:42:32 convivial: oh, ok. Aug 21 20:42:37 It looks like there's an NDK plugin now Aug 21 20:42:44 you can just uninstall that; it's not necessary for app development Aug 21 20:42:47 it's only useful if you use the NDK. Aug 21 20:43:21 i want NDK so I install it Aug 21 20:43:24 i wonder which store this is; since its in the SouthWest where i am :/ http://gizmodo.com/5936324/exclusive-confessions-from-the-most-corrupt-apple-store-in-america Aug 21 20:43:33 is there a layout parameter that fills the layout just so far until it gets to another layout? Aug 21 20:44:08 not layout, other view actually Aug 21 20:46:39 convivial: ...... Aug 21 20:46:46 convivial: then install the damned NDK like I suggested and point to that location Aug 21 20:46:52 http://developer.android.com/tools/sdk/ndk/index.html Aug 21 20:47:06 it's a zip file, it goes wherever you extracted it to Aug 21 20:48:53 oh, hell, you have to give the fragment an ID for it to get the Bundle correctly Aug 21 20:49:49 Or a tag Aug 21 20:50:05 the fragment is specified in XML Aug 21 20:51:17 android:tag :p Aug 21 20:51:26 16:32:19 < LiENUS> yeah stop depositing dna in your phone Aug 21 20:51:27 16:33:13 -!- MartyD [~martyd@unaffiliated/martyd] has quit [Remote host closed the connection] Aug 21 20:51:29 yeah yeah :P Aug 21 20:51:30 16:33:48 -!- link_108 [~link108@cn-sfo1-natout.cnet.com] has joined #android Aug 21 20:51:33 16:34:24 -!- zfly9 [0c9d929b@gateway/web/freenode/ip.12.157.146.155] has joined #android Aug 21 20:51:37 whoops, sorry Aug 21 20:51:41 accidentally middle-clicked Aug 21 20:51:47 no worries :) Aug 21 20:56:12 how can i make a phone call from my app without launching the call interface? Aug 21 21:05:18 so is making a background phone call not possible? Aug 21 21:08:18 porten: http://developer.android.com/guide/appendix/g-app-intents.html Aug 21 21:08:20 see the dialer intent Aug 21 21:08:30 no, making a background phone call using the device's telephony is not possible Aug 21 21:08:33 this is intentional. Aug 21 21:10:23 lov: thanks Aug 21 21:10:43 [2012-08-21 06:19:49 - Bubbles] W/ResourceType( 9928): Bad XML block: header size 111 or total size 0 is larger than data size 0 Aug 21 21:11:44 too much to learn.. what's this error referring to? Aug 21 21:13:36 bueller? Aug 21 21:14:26 is on the first line? Aug 21 21:31:40 what's up peeps, I am thinking in starting android development anyone help from where to start and what tools is best? Aug 21 21:31:44 Ryanm, of which file? Aug 21 21:32:30 maybe the next line.. which points to activity_main.xml Aug 21 21:32:38 it starts with yeah add as the first line Aug 21 21:33:24 see if it starts working Aug 21 21:34:09 any help? Aug 21 21:34:22 Kasir: http://developer.android.com/tools/index.html Aug 21 21:35:12 @lov thanks man, what about the best language should i use java or what? Aug 21 21:36:33 no change... Aug 21 21:38:04 Kasir: Yes, you'll want to use Java. You can use the NDK to develop in solely in C if you're willing to target 2.3 and above, or if you have cross-platform code you need to use. Aug 21 21:38:54 http://vvcap.net/db/CfNwx9017oCBX6saUsjU.htp Aug 21 21:40:20 @lov thanks mate, does it matter if I use ubuntu, will I miss something ? Aug 21 21:40:41 Kasir: no. Aug 21 21:40:45 * p_l recently looked into codebase that had single source for Windows, Linux, WinCE, Android and some special embedded platform Aug 21 21:40:46 Ubuntu is fine. Aug 21 21:41:05 I think you need to use ubuntu 64 Aug 21 21:41:12 I don't remember Aug 21 21:42:01 @lov why 64 ?? Aug 21 21:42:14 i have 2 views, one larger than the other, and both using match_parent. this results in the smallerview not filling the entire thing. how do i get the second view to do this? Aug 21 21:42:32 Kasir: just read this Aug 21 21:42:33 http://developer.android.com/sdk/installing/index.html Aug 21 21:43:11 Kasir: you don't need 64bit, unless you want to build Android from scratch (because it will blow through heap) Aug 21 21:43:12 @lov, I'll do thanks a lot, see you around :D Aug 21 21:47:04 Hello, i search Icons for the Holo Light Theme. I am missing a "Home" Icon in the official pack: http://developer.android.com/design/downloads/index.html Aug 21 21:51:26 @p_l I only want to do some apps, also can you tell me about a good book for starting ? Aug 21 21:57:22 Kasir: start here: http://developer.android.com/training/index.html Aug 21 22:00:49 @lov, have a nice day :) Aug 21 22:04:20 hello Aug 21 22:04:27 hi Aug 21 22:05:38 could you tell me what is a shortcut for another room Aug 21 22:05:42 android-root? Aug 21 22:05:53 #android-root Aug 21 22:05:56 try /join #android-root Aug 21 22:07:40 thanks Aug 21 22:07:51 the room "is dead" and I will ask here Aug 21 22:07:57 No you wont Aug 21 22:07:58 bad idea Aug 21 22:08:16 I mean it is dev sector.. Aug 21 22:08:17 ? Aug 21 22:08:21 so? Aug 21 22:08:23 Read the topic Aug 21 22:08:28 dev != root Aug 21 22:08:58 I know...just i need idea for button trigger camera Aug 21 22:09:05 to setup different button nothing more Aug 21 22:09:21 htcdesire_: and you can't do that in an android app. therefore you are asking in the wrong channel. Aug 21 22:09:45 htcdesire_: we're asking you nicely Aug 21 22:09:58 made a custom button (extends view, not button)…how can i detect ACTION_DOWN, then moved out of the view before ACTION_UP Aug 21 22:10:33 ACTION_UP is never triggered after long click and my finger is moved Aug 21 22:10:35 ok, wrong room, cheers :) Aug 21 22:11:20 onFocusChanged doesn't seem to be the answer Aug 21 22:19:48 when can I call getLeft and getWidth on a View object? Aug 21 22:19:56 onMeasure? onLayout? Aug 21 22:23:56 i'm calling it from onMeasure to set the outer border of a custom view i've made Aug 21 22:24:31 i assume this is called whenever the control is brought to the screen, or resized… either way, the documentation says you have to implement onMeasure Aug 21 22:25:09 so i allow my width and height variables to be set externally, then use this: Aug 21 22:25:10 protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { Aug 21 22:25:11 setMeasuredDimension(width, height); Aug 21 22:26:16 does that help? if so, you'd be the first i've helped b/c i haven't been doing this for long :P Aug 21 22:27:02 yeah, i already have onMeasure implemented Aug 21 22:27:13 hold on Aug 21 22:41:34 HorizonXP: in your custom view, do you know how to detect if a finger has been dragged outside the view's area? Aug 21 22:48:18 HorizonXP: After layout Aug 21 22:55:04 cool, RGBW 13mp sensors http://www.gizmag.com/sony-exmor-rs-sensors/23785/ Aug 21 23:18:52 i have a grid of buttons… how do i detect a long press and drag to another button? Aug 21 23:19:19 do i do it from within the button's parent? or within the button itself? i want to know if a finger has been dragged in/out of the iew Aug 21 23:19:22 *view Aug 21 23:31:32 Hey, guys!\ Aug 21 23:32:54 hi Aug 21 23:33:30 Look at what I makez Aug 21 23:33:32 http://forum.xda-developers.com/showthread.php?t=1846294 Aug 21 23:33:32 Hehe Aug 21 23:42:06 Simran|xChat: sounds like you want #android-root Aug 21 23:42:17 mmmk Aug 21 23:42:19 Thanks Aug 21 23:47:53 What really happens when a call goes in? Is the audio passed straight to the speaker at the OS level or is the phone app taking care of it? Aug 21 23:50:14 Trying to record calls, MediaRecorder can't start on VOICE_CALL source, but it won't let me. Aug 21 23:50:16 on the SGS2 Aug 21 23:53:55 It's likely not possible to record calls with stock software Aug 21 23:54:19 rom, whatever Aug 21 23:55:58 That's what I'm trying to figure out Aug 21 23:56:02 and why. Aug 21 23:56:23 It makes no sense. I'd want to record calls... Aug 21 23:56:30 A lot of people do. Aug 21 23:56:43 Security I suppose Aug 21 23:57:27 I wonder if you can fake a bluetooth headset and just get the audio stream. Aug 21 23:57:50 you need root and a ROM that supports it to record calls, afaik Aug 22 00:00:54 wongk-home, yea sure, but what does "supports it" imply? What's missing/blocking us in the stock rom Aug 22 00:01:04 Of course, E/MediaRecorder(12201): start failed: -2147483648 Aug 22 00:01:28 But that seems to be due to a binary not allowing the MediaRecorder to open this stream Aug 22 00:01:49 though the audio stream makes it to the speaker, bluetooth headset and wired headset. Aug 22 00:03:45 is the nexus 7 a large / xhdpi screen device? Aug 22 00:04:07 large tvdpi Aug 22 00:04:20 ah thanks Aug 22 00:04:35 Just providing hdpi resources should be enough Aug 22 00:04:42 That's what android does Aug 22 00:41:53 can a view detect that a finger has been dragged onto it? Aug 22 00:42:26 or does that have to be done from the parent? Aug 22 00:42:27 so i'm incrementally pulling a list, up to ~100K items or more, from a webservice. i need to cache these things. sqlite seems like the best way to store, any problems with that? Aug 22 00:42:53 no Aug 22 00:43:00 to both questions Aug 22 00:43:17 ultra i think if you use the onDragStart etc, there is a callback when the drag goes over an item, which will indicate the item being dragged over, if that makes sense Aug 22 00:43:40 well there's no actual item that's dragging Aug 22 00:43:56 hmm. then why drag? Aug 22 00:44:09 there's a grid of buttons, if long-click and dragged, i want the other buttons to recognize when a finger is over them Aug 22 00:44:29 i got the long click part :) Aug 22 00:44:54 hmmm Aug 22 00:45:18 you would need to implement a drag event handler Aug 22 00:45:30 which is simpler than the documentatino makes it seem Aug 22 00:45:58 inside the button itself? Aug 22 00:46:15 and for each button/view you want to have that behavior, add that handler as their dragevent listener, if i'm nto mistaken Aug 22 00:46:23 i've barely played with dragging but i have some code, hold on Aug 22 00:46:35 ok Aug 22 00:47:18 would be perfect if it's 100% done inside the button Aug 22 00:51:05 guys. give me an amazing idea. right now. gratis. Aug 22 00:51:17 time travel Aug 22 00:51:34 one secu ltra Aug 22 00:51:40 ok Aug 22 00:51:45 i seemed to have left this code in an error state :-D Aug 22 00:52:01 :) Aug 22 00:52:05 ultra-: android phones don't normally have flux capacitors :( Aug 22 00:52:16 but it's an amazing idea Aug 22 00:52:52 i have a couple degrees in electronics, but we didn't cover flux capacitors Aug 22 00:55:10 Hi all.. I'm looking for some feedback. I'm developing a racing game. On our test Galaxy S2 it runs a smooth (capped) 60 fps. On our test galaxy s1 we run a max of 44, but get some serious drops down to 24/22, mainly when steering / camera turning. Aug 22 00:55:43 We were thinking this could be a scripting problem, since our polycount is a steady 40k on screen, wich according to stats it should handle.. Aug 22 00:56:27 Anyway, I was looking on feedback about the differences between the s1 and the s2..Anybody any expierence? Aug 22 00:59:36 sorry ThomQ thats beyond my expertise Aug 22 00:59:54 ultra i think the code is on another machine, but hold on Aug 22 01:00:57 ok, i'm still hanging around Aug 22 01:01:00 looking up other stuff Aug 22 01:01:04 half a rounded rectangle Aug 22 01:02:32 http://developer.android.com/guide/topics/ui/drag-drop.html Aug 22 01:02:42 theres some documentation but let me see if i can find that code in a minute Aug 22 01:03:36 During the drag operation, the system dispatches drag events to the drag event listeners of the View objects in the current layout. The listeners should react by calling getAction() to get the action type. At the start of a drag, this methods returns ACTION_DRAG_STARTED. Aug 22 01:03:58 yeah, so basically make a generic drag event listener (they have an example) and assign it to every button Aug 22 01:05:04 ok will do, thanks rootlicker Aug 22 01:05:18 i'll find that example code but let me know if anything isn't clear to you Aug 22 01:06:08 ACTION_DRAG_ENTERED: The listener receives this when the touch point (the point on the screen underneath the user's finger) has entered the bounding box of the listener's View. Aug 22 01:06:23 so thats the action you'll be paying attention to. Aug 22 01:08:32 this works a lot like MotionEvents, so no problem there… implementing it is another issue Aug 22 01:08:45 i'm not very good at this part as i'm new: public class GridButton extends View implements View.OnDragEventListener Aug 22 01:09:26 could be b/c i'm using api level 10 Aug 22 01:09:35 but View.OnDragEventListener isn't found Aug 22 01:10:25 it's OnDragListener Aug 22 01:11:18 yeah shit this is api 11+ Aug 22 01:11:40 crap Aug 22 01:11:46 i'm not sure theres an easy way or feasible one before that level, but it may be possible to do it using compatibility library Aug 22 01:12:02 compat. library is something i'm admittedly inexperienced with but i'm sure someone here could help you with that Aug 22 01:12:04 i wanted this 2.3.3 compatible Aug 22 01:12:23 i'll google it Aug 22 01:15:57 http://developer.android.com/reference/android/support/v4/view/MotionEventCompat.html Aug 22 01:16:07 that _might_ be something, not sure tho Aug 22 01:18:41 it looks similar to dragging, talking about motion going in bounds of a view, etc. might be the workaround ya need Aug 22 01:22:01 hover enter :) Aug 22 01:30:51 I'm trying to override the microphone/audio input during a phone call, is this possible? Aug 22 01:31:37 or at least superimpose data on it Aug 22 01:37:54 rockap you mean like send something over the phone channel? Aug 22 01:38:04 i get a call, my phone plays audio over the call? Aug 22 01:38:31 pretty sure you can't do that Aug 22 01:38:58 who was asking about scrollview earlier? Aug 22 01:40:24 I heard it scrolls Aug 22 01:41:14 something like that anyway... Aug 22 01:42:06 an activity can't manage the audio input? Aug 22 01:43:02 says who? Aug 22 01:43:34 during a phone call? Aug 22 01:44:41 hmm... I'm pretty sure I've seen call recorders on the store? but I'm not sure Aug 22 01:44:52 They require root Aug 22 01:51:06 i have MotionEventCompat imported, i don't know how to implement OnGenericMotionEvent Aug 22 02:05:04 need a reboot, then i'll tyr to help you ultra- Aug 22 02:05:54 SimonVT: and specific hw Aug 22 02:50:43 What are you guys working on right now? Aug 22 02:53:03 trying to use motion event compat Aug 22 02:53:15 don't know how to make it trigger Aug 22 02:53:33 Hey guys. I have a compilation issue with the NDK. It can't find binder/IMemory.h. It seems I need to have framework/base but how should I get it? I can't find the corresponding docs. Aug 22 02:56:15 who knows how to use MotionEventCompat? in onTouchEvent, i'm using switch (event.getAction() & MotionEventCompat.ACTION_MASK) { and then testing for MotionEventCompat.ACTION_HOVER_ENTER but no luck Aug 22 02:56:31 there's very little on google for MotionEventCompat Aug 22 02:58:10 Is there any way to stop a MyLocationOverlay from requesting any more location updates, but still have it draw the blue circle indicator from it's first location fix? Aug 22 02:58:16 Doesn't seem like it. **** ENDING LOGGING AT Wed Aug 22 03:00:00 2012