**** BEGIN LOGGING AT Sun Jun 24 02:59:58 2012 Jun 24 03:24:43 i want to enble the split actionbar. however i'm only using 3 icons. know how I can have one icon be at the top right? Jun 24 03:24:59 Empty view? Jun 24 03:26:53 T-Dub: you talkin to me? Jun 24 03:26:57 Yes. Jun 24 03:27:10 I'm taking a shot in the dark simply because I have no idea. Jun 24 03:28:21 Pertaining to the SurfaceView, when exactly is surfaceDestroyed called? If I try to lockCanvas() or unlockCanvasAndPost() after this onSurfaceDestroyed() is called, what sort of behavior can I expect? Jun 24 03:30:08 And does the SurfaceView itself get destroyed, or only the Surface? I ask this because I am storing some data in a class extending SurfaceView Jun 24 03:30:39 romainguy: do you know if the classes on the 3rd day will be recorded? for some reason they are all missing (on that day) the camera icon Jun 24 03:30:49 that is, the android track Jun 24 03:30:52 themirror: looking at the docs, I believe the surface holder is destroyed Jun 24 03:31:09 themirror: if you are ever in doubt of what some behavior will be with something, always air on the defensive side Jun 24 03:32:36 "err" Jun 24 03:32:44 drpenguin: okay, the docs just say surface, but doesn't capitalize it as Surface. Jun 24 03:32:49 This is called immediately before a surface is being destroyed. After returning from this call, you should no longer try to access this surface. If you have a rendering thread that directly accesses the surface, you must ensure that thread is no longer touching the Surface before returning from this function. Parameters holder The SurfaceHolder whose surface is being destroyed. Jun 24 03:33:07 never mind, capitalized right there lol Jun 24 03:56:46 themirror: after onSurfaceDestroyed(), the SurfaceView may or may not have been destroyed Jun 24 03:57:02 the Surface's lifecycle is distinct from the lifecycle of the View Jun 24 03:57:23 don't do anything with the surface (or Surface if you prefer) after onSurfaceDestroyed Jun 24 03:57:26 bad things will happen Jun 24 04:04:21 romainguy_: Okay, now I am a bit confused. You said the SurfaceView is destroyed after the call returns. Is this correct? I only have one Activity, so it probably doesn't matter, but I'd like to know for future reference. Jun 24 04:04:50 no Jun 24 04:04:50 I am currently merely addressing this with a boolean surfaceValid Jun 24 04:04:58 the SurfaceView *may* have been destroyed Jun 24 04:05:03 or may be destroyed later Jun 24 04:05:12 but you can also get this call without the SurfaceView itself being destroyed Jun 24 04:06:53 Hm, okay. So it may or may not be destroying, but if it does, it's not merely destroying the Surface or the SurfaceHolder, but the SurfaceView itself? Jun 24 04:07:11 As I understood, they are separate Jun 24 04:07:25 if the SurfaceView is destroyed, so is the underlying Surface Jun 24 04:07:37 if the Surface is destroyed, its related SurfaceView may or may not be destroyed Jun 24 04:08:04 Okay, got it. Thanks for clearing that up. Jun 24 04:17:49 ello? Jun 24 04:18:44 I'm trying to move between two UIs in my app (two activites) and be able to use the back button to go back to the first UI. How can I do this? Jun 24 04:19:40 whats a good strategy to architect with dependancy injection? eg who builds up the app? Jun 24 04:20:13 on the one hand, you can treat things like singletons and have a static method that creates/retreives it on the class Jun 24 04:22:27 derekv: some people use guice Jun 24 04:23:09 g00s, well, I just got done working on a spring project, and I have a bad taste for automatic dependancy injection Jun 24 04:23:29 if you mean autowiring, i don't think guice does that Jun 24 04:23:36 but the idea of not hard-coding dependencies is still worth playing with i thin Jun 24 04:23:41 g00s, looking now... thanks Jun 24 04:24:56 -> http://code.google.com/p/roboguice/ Jun 24 04:25:29 awww look at that mascot Jun 24 04:25:35 i think you can use guice by itself if you don't want to drink all of the cool aid Jun 24 04:25:45 cutest library mascot ever Jun 24 04:26:49 like, the thing is also that the spring autowiring was abused horribly in this application I got to work on Jun 24 04:27:10 I don't even want to get into it... makes my stomach churn now thinking back Jun 24 04:27:39 we had like 12000 lines of xml configuration Jun 24 04:27:55 app took like 2 minutes to start on an i7 Jun 24 04:32:18 how about builders whats the best one to use... i'm over ant Jun 24 04:36:28 i use eclipse :| and ant for releases Jun 24 04:37:27 Eclipse doesn't do it for me either Jun 24 04:37:39 or intellij Jun 24 04:37:45 I'll have to spend time one day figuring out an alternative setup Jun 24 05:02:10 oh ... wow... ok weird, if you call new NestedClass from a static method Jun 24 05:02:21 new wants to belong to an instance Jun 24 05:02:38 unless the class is static Jun 24 05:02:46 yea Jun 24 05:02:59 I figued that out... not groking it yet... Jun 24 05:03:12 I kindof thought of nested classes as static Jun 24 05:03:19 what does it mean if they are not static Jun 24 05:03:27 Right... Jun 24 05:03:38 that they can access data from their outer class Jun 24 05:03:40 it can refer to the parent's fields Jun 24 05:03:41 yea Jun 24 05:03:50 ok I'm thinking it through lol Jun 24 05:03:54 lights are coming on Jun 24 05:04:00 =] Jun 24 05:04:38 it makes sense Jun 24 05:26:20 Finally, WHEN is surfaceDestroyed() called? Jun 24 05:27:36 when the creatures of the sea take revenge on us surface dwellers Jun 24 05:28:33 themirror: when required :) Jun 24 05:28:51 usually when your activity is destroyed or the SurfaceView removed from the window Jun 24 05:29:09 does the latter occur when the home button is pressed? Jun 24 05:29:16 no Jun 24 05:29:24 but the surface can be destroyed when you switch between app Jun 24 05:29:49 does it coincide more with onPause or onStop? Jun 24 05:32:50 So what you're saying is that when a user changes app (let's say she gets an incoming call), there's the possibility that my entire SurfaceView will be destroyed? Jun 24 05:33:02 no Jun 24 05:33:04 just the surface Jun 24 05:33:31 but the holder can change, so i can't count on that remaining after such an occurrence Jun 24 05:40:16 I just finished implementing an IntentService, what is the best method to update the UI fromit? Jun 24 05:40:34 *from it? Jun 24 05:44:55 Hi There, what is the difference between dp and dip? Jun 24 05:45:02 none Jun 24 05:46:05 Anyone familier with services? Jun 24 05:46:13 romainguy: ty Jun 24 05:46:24 romainguy_: ^^ Jun 24 05:47:25 is broadcastreciever a bad idea? Jun 24 05:47:35 yes Jun 24 06:17:29 romainguy_: You there? Jun 24 06:53:38 Anyone here familiar with disabling text selection in web apps, the Android browser seems to ignore -webkit-user-select: none, and the unprefixed variant. If there's a more apporiate place to ask this, please let me know. Jun 24 07:17:48 there is only 1 feature i care about and hope JB has : the ability for google to update the core more easily Jun 24 07:19:10 while "adb -d shell"`d into my phone, can I push files to my computer? (i know about adb pull) Jun 24 07:28:31 JB has been done for like 3 months Jun 24 07:28:44 if not more Jun 24 07:28:58 and we're already more agile than competitors since the core apps are decoupled Jun 24 07:29:14 bitchers gon bitch Jun 24 07:30:19 whoa, competitors.. Jun 24 07:30:27 what competitors? :p Jun 24 07:31:01 I just can't wait to see my feature on a stock build :p Jun 24 07:31:28 close other tabs ftw…sadly, couldn't find time to add it to the tablet interface Jun 24 07:32:24 I'm experimenting with a layered drawable XML. How to position a layer to the right of another layer? Jun 24 07:33:18 napster: idk what you're talking about, but, fetch width of layer, set x posistion of desired layer based on that Jun 24 07:33:21 JakeWharton: Hi, do you know how to style AlertDialog buttons? Jun 24 07:33:32 but u prob had that much Jun 24 07:33:48 Dr_Heckle: Jun 24 07:33:49 ok Jun 24 07:34:30 0.o i helped :` Jun 24 07:34:49 ;) Sort of Jun 24 07:35:01 :D Jun 24 07:35:34 has Larry Page ever served lunch to Google employees? (just asking) Jun 24 07:36:00 huh, wtf is /tombstones Jun 24 07:36:17 oooh root denied permission Jun 24 07:36:39 what's the dir '/tombstones' ppl? Jun 24 07:36:52 it's just dead files or something Jun 24 07:36:53 JakeWharton: were you replying to me? Jun 24 07:37:04 Afzal: boring :( Jun 24 07:37:07 Dr_Heckle: you can delete it. Jun 24 07:37:15 royale1223: bet i cant Jun 24 07:37:29 and i'm not going to try on my stock phone (w/ root) Jun 24 07:37:46 no nandroid to fix errors Jun 24 07:37:56 though i could prob try it to a virtual device Jun 24 07:37:58 Dr_Heckle: They take up lots of space in /data sometimes. Jun 24 07:38:16 DELETE IT!!!!!!!! Jun 24 07:38:20 :D Jun 24 07:38:21 no Jun 24 07:38:22 XD Jun 24 07:38:29 don't resist bro, Jun 24 07:38:31 delete it Jun 24 07:38:38 it's gonna be okay Jun 24 07:38:54 Dr_Heckle: Actually I'm trying to set a custom background to a Spinner. I have created one layer of a nice gradient and a 1dp border. Now I need to set a small down "arrow" on the right side of the spinner. Jun 24 07:39:11 napster, be sure to profile the UI Jun 24 07:39:45 Afzal: Means? Jun 24 07:39:59 http://developer.android.com/tools/help/hierarchy-viewer.html Jun 24 07:40:06 @napster ^^ Jun 24 07:40:20 ok Jun 24 07:41:46 http://i.imgur.com/5pZTZ.gif Jun 24 07:43:00 that looks like an oatmeal character Jun 24 07:43:02 Dr_Heckle: http://forum.xda-developers.com/showthread.php?t=1587707 Jun 24 07:43:12 now i'm hungry :( Jun 24 07:43:22 DigitalKiwi: its not complete without bacon though :) Jun 24 07:43:32 royale1223: what's this? Jun 24 07:43:38 i'm just poking around ;) Jun 24 07:44:15 Dr_Heckle: just some info on /data/tombstone. Jun 24 07:44:55 k, i'll poke it in a sec Jun 24 07:45:06 BTW, what's the disadvantage of using broadcastreciever for a local service? Jun 24 07:45:38 royale1223: performance mostly Jun 24 07:45:46 but if its low frequency, it won't matter Jun 24 07:46:05 if its a one-off, it definitely won't matter Jun 24 07:46:22 there are some security implications, but … :) Jun 24 07:46:25 6-7 broadcasts per task, is that a big deal? Jun 24 07:46:43 whats "per task" ? Jun 24 07:47:14 AsyncTask Jun 24 07:47:26 hmm Jun 24 07:47:30 Or say an operation. Jun 24 07:47:41 maybe use the LocalBroadcastReceiver thing in the compat library if it meets your needs Jun 24 07:47:58 or whatever its called. it will be obvious Jun 24 07:48:01 better performance? Jun 24 07:48:10 yes, it does not cross process boundaries Jun 24 07:48:18 when using a broadcast, it goes to a system service Jun 24 07:48:32 this other version is dumb but useful enough Jun 24 07:48:37 g00s: great. Any other alternatives? Jun 24 07:48:47 you can use an event bus, like guava eventbus Jun 24 07:48:58 but you will have to make some changes to the stock one Jun 24 07:49:06 (most likely) Jun 24 07:49:42 I just need to update ui from the service. Jun 24 07:49:47 and you really don't even need an event bus. just regular java listeners are fine Jun 24 07:50:21 hmm Jun 24 07:50:33 the challenge becomes when the ui is detached and the service completes Jun 24 07:50:41 should you then put up a notification ? Jun 24 07:50:46 if the ui is attached, probably not Jun 24 07:50:48 yes. Jun 24 07:58:34 royale1223: thx for that link about tombstone Jun 24 08:01:56 Quarx: Dr_Heckle you're very welcome. Jun 24 08:02:11 g00s: got this. http://stackoverflow.com/questions/11080141/how-can-android-service-update-the-ui-of-the-activity-that-started-it Jun 24 08:07:29 lulz, poking the AVD, either android is not booting cause my computer sucks, or i messed up ^_^ Jun 24 08:09:37 Does anyone else feel like android coding is so slow? >.< Jun 24 08:10:56 nope Jun 24 08:11:01 o.O Jun 24 08:11:07 <[deXter]> Slow, hw? Jun 24 08:11:11 <[deXter]> *how? Jun 24 08:11:34 Like.. When I get an error it takes forever to figure out what it's talking about. Jun 24 08:11:56 it takes only like 10 seconds to make a change to your code and run your new project on real hardware. theres are plenty of platforms that are much slower than that Jun 24 08:12:38 I run it on my phone. You think it's better to run on my computer? Jun 24 08:13:04 it takes longer to run in the emulator than on my phone here Jun 24 08:13:59 Well the boot takes a while but it runs pretty fast. I use my phone cause it's easier to organize than a window Jun 24 08:14:50 i like using real HW to test because it is the real HW that i carry around all day. im not taking the emulator with me everywhere Jun 24 08:15:10 True true. Do you like this new android dev website? Jun 24 08:15:15 maybe your apk is to fat :) Jun 24 08:15:21 anyone try out roman nurik's thing? Jun 24 08:15:26 i feel like i just spelled his name wrong Jun 24 08:15:30 Hi guys, I'm facing a problem with debuggable=true/false in manifest file. If I leave it set to true the app runs very well but If I change it to false the app restarts each time activity is paused. Does the debuggable attribute has anything related to that? Jun 24 08:15:34 nope Jun 24 08:15:51 whats roman's thing ? Jun 24 08:16:19 going to add NineOldAndroids… fairly certain it will work for all API levels Jun 24 08:16:56 git blame needs a BAC field Jun 24 08:17:16 blood-alcohol-content? Jun 24 08:17:50 that'd be the one Jun 24 08:18:59 i guess it was cool to always through out references to being drunk when i was like 20 … Jun 24 08:19:15 JakeWharton: you spelled it right Jun 24 08:19:27 JakeWharton: but if you add his stuff, you should add support for multiple pointers first Jun 24 08:19:31 saw your multi-finger comment too Jun 24 08:19:32 yeah Jun 24 08:19:48 the trick is to track the "active pointer" Jun 24 08:19:57 and when you get an UP, switch to the next pointer Jun 24 08:20:02 yeah i think view pager has that code which i copied for our stupid slide to unlock control Jun 24 08:20:06 yep Jun 24 08:20:08 it's very easy to do Jun 24 08:20:37 gaaah Jun 24 08:20:39 effin slides Jun 24 08:22:45 saw a cool heroku app today that made slides out of gists: http://gistdeck.herokuapp.com/ Jun 24 08:23:42 still quite partial to impress.js but it's far too impractical for anything that you need to iterate on rapidly Jun 24 08:23:52 this is pure genious, I need to write such script for every app crash: http://andialbrecht.wordpress.com/2009/05/09/when-merging-fails/ Jun 24 08:24:30 wow, that is beautiful Jun 24 08:25:53 Mavrik: look up lolcommits Jun 24 08:26:20 you get fun things like this: https://twitter.com/JakeWharton/status/215275035030597634 Jun 24 08:27:01 Hi Jun 24 08:27:21 I anderstood that I can't add views from Thread? Jun 24 08:27:29 embed: nope, only the UI thread Jun 24 08:28:40 JakeWharton: so, I can I go back to the UI thread from another thread? Jun 24 08:28:52 there are various ways to do that, yes Jun 24 08:29:10 you can use a Handler created on the UI thread (or with Looper.getMainLooper()) and post to that Jun 24 08:29:34 if you have a reference to an existing view you can post a Runnable to the main thread from it Jun 24 08:29:39 o.k, I'll check it.. Jun 24 08:30:13 what do you mean post a Runnable? Jun 24 08:30:47 View.post(Runnable) Jun 24 08:31:45 thanks, I'll check it :) Jun 24 08:42:06 i also can't swipe two things away at once Jun 24 08:48:10 I'm trying to get my head around how the ViewPager works and having difficulty finding a complete example. I found this in the API docs http://developer.android.com/reference/android/support/v4/view/ViewPager.html Jun 24 08:49:10 I don't understand why all the examples exclude the required view XML Jun 24 08:51:12 is everyone sleeping? Jun 24 08:52:26 no, but it's still not exactly the best time to ask questions Jun 24 08:56:33 I see Jun 24 08:57:59 I'm curious why the API samples seem incomplete or am I perhaps missing a link to the xml describing the UI Jun 24 08:58:23 lulz, my phone (Sprint HTC EVO 4G LTE) is was suposed to have the bloatware kept to a min Jun 24 08:58:58 130 .apks that can be removed (though this does include usefull things like Weather.apk, YouTube.apk, etc) Jun 24 08:59:45 it's sprint AND HTC, what did you expect, really Jun 24 09:00:18 I'm fairly happy with the Sprint Galaxy Nexus. Not happy with Sprint's pahntom LTE network Jun 24 09:00:27 *phantom Jun 24 09:00:51 i would only get a nexus device updated by google Jun 24 09:02:38 Sprint told me that if I puchsased the LTE Nexus from google.com they would not allow it on their network. All customers are required to complete 1-year contact period before being eligible for month to month. I had two sales reps tell me this bs. I still don't believe it's true Jun 24 09:03:31 so they would allow it, they just wouldn't allow me to go month-to-month with them.... No way I'm signing a contract with a carrier when I have my own device Jun 24 09:03:59 hmm. is that common ? Jun 24 09:04:06 would other carriers do that also ? Jun 24 09:04:11 ramzey76: are you currently sprint? Jun 24 09:04:19 In the US the system is crazy Jun 24 09:04:29 yeah, i'm in the us :P Jun 24 09:04:49 Dr_Heckle: yes, I am with Sprint (unfortunately) Jun 24 09:05:02 then talk to customer retention Jun 24 09:05:09 and don't be bitchy or threatning Jun 24 09:05:10 be sad Jun 24 09:05:14 be unhappy Jun 24 09:05:30 depressed, melancholic Jun 24 09:05:37 :( Jun 24 09:05:59 be dejected, act like you feel like sprint is rejecting the "type" of customer you are Jun 24 09:06:07 yep g00s Jun 24 09:06:11 but i wonder if tmo , at&t, or vz would give the same hassle Jun 24 09:06:13 that's how u deal w/ CSR Jun 24 09:06:27 dunno Jun 24 09:06:33 but honestly if u have a choice Jun 24 09:06:34 I'm not in this forum to complain about my carrier. In general I'm quite happy with the Sprint versin of the Galaxy Nexus, I figure I can always root and deploy some fantastic roms if the carrier becomes a real problem Jun 24 09:06:52 and aren't after unlimited data Jun 24 09:06:57 gtfo sprint Jun 24 09:07:05 gtfo cdma actually Jun 24 09:07:09 I'm ok with the stock ICS on Sprint's Galaxy Nexus for now Jun 24 09:07:49 Sprint's CDMA 3G is interesting to say the least. I average about 400mb/s around Houston Jun 24 09:08:13 i've got a stock galaxy nexus without any carrier contract. i use prepaid Jun 24 09:08:40 hello! Jun 24 09:08:44 but i'm not in the states Jun 24 09:08:46 Correction: 400kb/s Jun 24 09:09:31 The one time I was able to connect to Sprint's 4G LTE with my Nexus I was getting 12mb/s which was amazing Jun 24 09:10:03 :) Jun 24 09:10:19 Hi guys, I'm facing a problem with my app. In debug mode, if I launch it from eclipse it runs as expected. If I sign the app for the release with my keystore the app stops to work well: it get killed everytime the main activity is paused. Each time it restarts from the beginning instead of resume the paused activity. This thing doens't happen if I don't sign the app. Am i missing some key tag/attribute in m Jun 24 09:10:19 anifest file? Jun 24 09:10:33 Pre-paid in the US is frowned upon although it's not a bad option. Virgin mobile is the best and they are on Sprint's 3G CDMA network. Virgin pre-paid customers are getting the same quality signal as I am under contract Jun 24 09:11:25 salentinux, try skipping proguard for now Jun 24 09:11:29 Pre-paid phone selection is pretty horrible Jun 24 09:11:43 Zharf: I don't use it, yet Jun 24 09:11:58 morning guys Jun 24 09:11:58 salentinux, are you sure? Jun 24 09:12:03 Zharf: no proguard.cfg in dir Jun 24 09:12:15 motninh thepoosh Jun 24 09:12:21 *morning Jun 24 09:12:49 salentinux, you're using eclipse... Jun 24 09:12:49 quick question: what is better? using a single AsyncTask to do all things or for every function use a separate AsycTask? Jun 24 09:13:14 does someone know how to make themes work in an preferenceActivity and keep headers?It seems this problem has been here for a long time but the way around doesn't allow you to keep headers Jun 24 09:13:37 salentinux, also there's a default proguard config that might be used Jun 24 09:14:27 Zharf: yes, but I started "new project" wizard with an old version of sdk when proguard was not included. Jun 24 09:14:58 Zharf: I'm trying to recreate it... Jun 24 09:15:24 ok then, just a suggestio n based on my experiences with proguard :) Jun 24 09:15:38 JakeWharton: you're becoming a specialist in backporting :) Jun 24 09:16:32 romainguy_: do you know that the link in the topic is broken? Jun 24 09:16:34 haha, yeah a bit. need to expand my horizons and develop new things or something Jun 24 09:17:05 I'm looking for a good sample (source) of using the ViewPager, I want to create scrollable tabs interface like the CNN app, Play store app, etc.. Jun 24 09:17:30 does someone could help me with prefenceActivity and themes? Jun 24 09:19:37 thepoosh: which? all work for me Jun 24 09:19:52 ramzey76: there are ViewPager demos that come with the support library Jun 24 09:20:38 SDK/extras/android/support/samples/Support4Demos/ Jun 24 09:20:52 JakeWharton: the top link is coming to the web client like this: http://developer.android.com/%3E/index.html Jun 24 09:21:00 romainguy_: ^ Jun 24 09:21:11 probably specific to your IRC client Jun 24 09:21:18 sounds like it's picking up the ">" as part of the URL Jun 24 09:21:41 my memorization of the hex codes of ASCII characters isn't what it used to be… but i'm guessing 0x3E is ">" Jun 24 09:22:45 thnaks Jun 24 09:26:51 hi Jun 24 09:32:47 JakeWharton: this is the default webclient from the freenode website Jun 24 09:34:16 Hello! Jun 24 09:34:44 hi Jun 24 09:34:54 JakeWharton: http://stackoverflow.com/questions/11176364/what-is-better-many-asynctasks-or-one-to-handle-all-asyncrequest Jun 24 09:34:57 what do you think? Jun 24 09:35:08 I'm trying to get the Actionbar Sherlock sample working, but it doesn't find the theme. Why is that? I included com_actionbarsherlock as a project and the support package 4 as an external library. Jun 24 09:35:25 RedNifre: are you compiling with Android 4.0 or newer? Jun 24 09:36:04 thepoosh: AsyncTask's default executor has changed recently and it isn't very agile in how it communicates back to an activity Jun 24 09:36:25 I'm not compiling at all, the themes.xml has errors. Jun 24 09:36:42 It can't find the parent="Theme.Sherlock.Light.DarkActionBar" Jun 24 09:36:48 JakeWharton: what do you mean? how else will I implement server requests? Jun 24 09:37:16 IntentService, Loaders, HandlerThread/Runnables, Executor/Runnables Jun 24 09:37:29 hmmmmm Jun 24 09:37:34 AsyncTask is designed for one-off actions Jun 24 09:37:40 RedNifre: that's because you're not compiling with Android 4.0 or greater Jun 24 09:37:52 if you need to communicate regularly with a server you're better off using your own threads (and pools) Jun 24 09:38:05 it can't find the parent of Theme.Sherlock.Light.DarkActionBar which is Theme.Holo.Light.DarkActionBar which was introduced in API 14 (Android 4.0) Jun 24 09:38:34 I guess I'm doing something wrong when setting up the sample. How to get the ActionBar Sherlock Sample project set up correctly? Jun 24 09:38:45 romainguy_: I have all sorts of different actions to do with the server, I thought doing this with an AsyncTask is the propper way Jun 24 09:38:47 :S Jun 24 09:39:08 thepoosh: AsyncTask is a proper way to not block the UI thread Jun 24 09:39:09 RedNifre: Right click it > project properties > android. Choose "Android 4.0" or "Android 4.0.3" Jun 24 09:39:20 I have. Jun 24 09:39:25 on both your app and the library? Jun 24 09:39:32 s/your app/the sample/ Jun 24 09:39:59 Oh, I think I found it... Jun 24 09:40:23 Ah, yes. It doesn't work to add the project in the build path, I have to add it in the project properties. Jun 24 09:40:27 Thanks for your help! Jun 24 09:40:42 romainguy_: I know. for instance, I send a facebook request and stuff. after that, I get the user's image and display it. that is for AsyncTask. same is for getting a list of users from server and displaying them and so on and so forth Jun 24 09:41:39 I've found one of my paid applications in a couple of Russian sites, do you think is it worth to use the licensing service ? Jun 24 09:43:12 also, I've done a search in the google checkout list of customers, but none of them is from Russia ... Jun 24 09:43:53 what makes me worry about how they get the application on the first place Jun 24 09:44:01 s/get/got/ Jun 24 09:46:47 Hm, the Actionbar Sherlock sample now has no errors, but I can't compile it. I get this error when I try to run it: Jun 24 09:46:48 UNEXPECTED TOP-LEVEL EXCEPTION: Jun 24 09:46:48 java.lang.IllegalArgumentException: already added: Landroid/support/v4/accessibilityservice/AccessibilityServiceInfoCompat$AccessibilityServiceInfoStubImpl; Jun 24 09:46:48 [2012-06-24 11:45:23 - Actionbarsherlocsample] Dx at com.android.dx.dex.file.ClassDefsSection.add(ClassDefsSection.java:123) Jun 24 09:46:49 [2012-06-24 11:45:23 - Actionbarsherlocsample] Dx at com.android.dx.dex.file.DexFile.add(DexFile.java:163) Jun 24 09:47:08 What's that? Jun 24 09:48:23 you're including two support libraries in the classpath somehow Jun 24 09:50:07 Hm, I'll delete it and start again from scratch. Jun 24 09:51:24 crw-rw-r-- system radio 10, 82 2012-06-24 05:24 alarm Jun 24 09:51:31 what's the c stand for? Jun 24 09:52:17 Thank you JakeWharton, everything works now. :) Jun 24 09:53:17 Dr_Heckle: http://en.wikipedia.org/wiki/Filesystem_permissions#Symbolic_notation Jun 24 09:53:56 thank you JakeWharton Jun 24 09:56:54 dang Jun 24 09:57:00 not seeing a disk in /dev Jun 24 09:58:15 whoop! mebe this is it Jun 24 09:58:23 /dev/block/* Jun 24 10:00:56 Has something broken between Eclipse and the JDK? I just installed both and Eclipse won't pick up the JDK even though the path is specified. Jun 24 10:02:51 huh, so what happens if i "cat /dev/dlock/mmcblk0 >> /sdcard/!Garbage/Bootloader.sdblock0" Jun 24 10:03:17 um s/dlock/block Jun 24 10:03:34 expect anything horrible to happen? Jun 24 10:03:53 history expansion Jun 24 10:04:29 huf: should i google that?, is it bad? Jun 24 10:04:35 idk that i'll get garbage Jun 24 10:04:44 well, "garbage" Jun 24 10:05:03 it's a shell thing. unquoted ! tries to do history expansion and probably not what you wanted :) Jun 24 10:05:05 Dr_Heckle: c stands for "character", you can also see b for "block" Jun 24 10:05:20 xroberx: yep, these are blocks Jun 24 10:05:24 mainly why i'm asking Jun 24 10:05:44 not sure if cat will grab all the data or just the 1 block the system'll queue Jun 24 10:05:57 Dr_Heckle: what do you want to do ? Jun 24 10:06:05 also worried about the data being pulled gettin parsed causing problems Jun 24 10:06:08 i want to poke shit Jun 24 10:06:13 * Dr_Heckle pokeies Jun 24 10:07:10 xroberx: thx for the warning about the !, i'll rename the dir Jun 24 10:07:19 guess i'll use '_' Jun 24 10:07:20 just quote it Jun 24 10:07:34 quote it anyway if you're gonna call out to shell like that Jun 24 10:07:36 too much of a pita to keep having to do, and remember Jun 24 10:07:47 k Jun 24 10:08:07 but does anyone anticipate this causing any problems for my device? Jun 24 10:09:02 how do I start traceview on windows to show me which function takes how much time in my android app which is connected to my laptop? Jun 24 10:09:16 is it possible to let the user choose what localisation he prefeers? a german user might not want his app translated into german but rather use the default Jun 24 10:10:09 jakob|: yeah, switch the language in the preferences :) Jun 24 10:10:23 mmk, giving this a go Jun 24 10:10:55 I guess I'll simplify my question: How to start traceview? Jun 24 10:11:17 Waynes: do it from DDMS Jun 24 10:11:27 there's a button at the top to start/stop profiling Jun 24 10:11:32 it will automatically launch traceview Jun 24 10:11:39 xroberx: yeah, but for individual apps Jun 24 10:12:01 running... Jun 24 10:12:17 cat using 16.7% cpu... Jun 24 10:12:42 should have forced cup to perfromance first :D Jun 24 10:12:53 18.3% still running Jun 24 10:12:54 huh Jun 24 10:13:08 jakob|: I've never done that myself, but I guess there should be some API call to do it which requires you to set http://developer.android.com/reference/android/Manifest.permission.html#CHANGE_CONFIGURATION Jun 24 10:13:19 almost think i should kill it.... Jun 24 10:15:16 it works! thanks :) Jun 24 10:17:15 well, seems like myFloatBuffer.put() consumes 88% of my cpu time, never would have figured that out without this Jun 24 10:18:15 yay! had to kill cat via the phone, but i got it to end ^_^ Jun 24 10:18:55 you killed a cat? :( Jun 24 10:19:45 :D Jun 24 10:19:51 i did a stupid w/ that Jun 24 10:20:01 i was pulling from mmcblk0 Jun 24 10:20:04 no partition Jun 24 10:22:26 lulz, i'm coping the result to my computer, file size is 271,232KB and counting Jun 24 10:22:33 and taking forever ?? Jun 24 10:22:49 double that... weird, moves in spurts Jun 24 10:23:00 must be due to my i/o manager Jun 24 10:26:43 this is so strange Jun 24 10:26:50 i'm waiting for hell to break loose Jun 24 10:29:22 yeah, over 1.5 GB now Jun 24 10:29:44 killing adb, that drive is too full for this :D Jun 24 10:31:12 now to start over, and pull a partition, not the entirety of the flash memory :` Jun 24 10:33:05 acording to Ghost Commander on my phone, file was 4GB Jun 24 10:36:12 hi people, I'm creating a simple game with music and sound effects. Should I use MediaPlayer for music and SoundPool for sound effects or should I use only one of the two? Jun 24 10:39:33 i've spent the whole day trying to figure out why the new developer site's font does not render crisply in my browser. i've tried all the browsers. and i modified the css too. very strange. its the only site that seems to do this; even developer.google.com looks nice Jun 24 10:41:40 sucess w/ mmcblk0p1 instantainously Jun 24 10:42:36 two of these are read write, guessing one is /sdcard Jun 24 10:42:41 wonder what the other is... Jun 24 10:44:12 * Dr_Heckle chows down on over-cooked ramen (darn distracting phone :) Jun 24 10:48:35 where did all of the old blogs and articles go ? Jun 24 10:48:44 (from the old site) Jun 24 10:49:00 anyone know how to take a binary file and convert it into human readable machine language? Jun 24 10:49:03 http://developer.android.com/training/index.html Jun 24 10:49:14 and http://developer.android.com/guide/components/index.html Jun 24 10:49:17 guess i should ask google :) Jun 24 10:49:47 romainguy_: i saw those … i mean, for example - like your entry on minimizing view hierarchy depth Jun 24 10:50:00 it's in there Jun 24 10:50:01 the blog is still at android-developers.blogspot.com as it always was Jun 24 10:50:15 Dr_Heckle: you know this channel is for app development, right? Jun 24 10:50:51 true, sry Jun 24 10:51:01 thought this was interesting enough to be worth sharing Jun 24 10:51:38 you pulling the filesystem from your device and trying to decompile stuff? nope... Jun 24 10:52:02 i think i always got to the blog from the main d.android.com site Jun 24 10:52:05 Dr_Heckle: Ida Pro does that very well, but it's expensive Jun 24 10:52:53 uh, how do you search through android-developers.blogspot.com ? Jun 24 10:53:02 seems like the tags are gone Jun 24 10:53:17 no search box Jun 24 10:53:29 site:android-developers.blogspot.com Jun 24 10:54:07 dunno... Jun 24 10:55:17 uh Jun 24 10:56:19 there was a ton of stuff under d.android.com resources/ . training was one, but there was also technical resources: samples code, articles, etc Jun 24 10:57:23 looks good in links/lynx Jun 24 10:57:27 also curl Jun 24 10:57:46 i was going to try lynx :) Jun 24 10:59:33 the android training even has less than the old training section Jun 24 10:59:40 so maybe the site is not finished yet Jun 24 11:00:09 (just comparing what i have on my hard drive to what is online) Jun 24 11:00:34 hard drive != cloud Jun 24 11:00:37 therefore it's inferior Jun 24 11:01:05 JakeWharton: the docs installed with the sdk manager :P Jun 24 11:01:21 bits are 0.000001 less meaningful when stored on magnetic, spinning disks rather than when in condensed water molecules floating above our heads Jun 24 11:02:13 http://developer.android.com/resources/articles/can-i-use-this-intent.html Jun 24 11:02:21 yeah, stuff is just gone Jun 24 11:02:35 well that answer to that is always no Jun 24 11:02:39 you cannot use the intent Jun 24 11:04:18 4:04 Jun 24 11:04:18 i wonder if i should bother filing a bug Jun 24 11:04:18 ti Jun 24 11:04:21 time not found Jun 24 11:04:30 file a bug that shitty content from Android 1.1 is missing Jun 24 11:04:32 i'm guessing no Jun 24 11:04:46 can i use this intent is still applicable Jun 24 11:05:00 i already answered the question Jun 24 11:05:08 ok :P Jun 24 11:05:39 public Intent() { throw new YouCannotUseThisIntentException(); } Jun 24 11:12:02 I needed to access to system folder of my Android Tablet. So I rooted it. Where and how can I find the system directory? Jun 24 11:12:32 Mohsen_Hassani: read the channel topic, please Jun 24 11:13:18 Leeds, sorry ... Jun 24 11:14:09 Mohsen_Hassani: /system Jun 24 11:15:11 romainguy_: are you up late doing a i/o presentation :P ? Jun 24 11:15:20 maybe :) Jun 24 11:15:47 running it from an android tablet ? Jun 24 11:15:49 is the getString() method in fragments costly? Jun 24 11:16:07 g00s: keynote doesn't run on Android tablets, I think... Jun 24 11:16:15 i think reto did that last year Jun 24 11:16:22 not sure what he used Jun 24 11:16:23 nah Jun 24 11:16:24 I wanted to Jun 24 11:16:38 but I didn't have time to make it happen Jun 24 11:16:52 I actually would like to write my slides as an android app Jun 24 11:17:09 I thought reto did that? Jun 24 11:17:23 i seem to remember his tablet rebooting Jun 24 11:17:23 not quite Jun 24 11:17:29 his slides are PNGs Jun 24 11:17:38 so he presents from an android device Jun 24 11:17:49 but it's not quite what I have in mind Jun 24 12:08:47 Hey again. Jun 24 12:09:03 I'm new to preferenceActivities, they seem nice, but I don't know their limitations yet. Jun 24 12:09:49 Say I want to allow the user to select a time span (weekly/monthly) and in the other settings, I want him to choose a start point (monday through sunday if he selected weekly, 1 to 31 if he selected monthly). Is this possible? Jun 24 12:10:55 Basically, you have one preference where you can choose one out of many and depending on your choice, the other preference gives you different sets to choose from. Jun 24 12:11:11 Is that possible with preferenceActivity or do I have to do something custom? Jun 24 12:12:40 Or should I use PreferenceFragment instead? Jun 24 13:08:42 am i right saying that the api does not contain a scrollview that's capable of scrolling both horizontally (based on the fact that there is both a ScrollView and a HorizontalScrollView) Jun 24 13:15:31 hello! Do you know if there's a graphical editor for shapes? I need to create a left-only stroked linear layout Jun 24 13:23:19 can I set a layer-list's item's width? Jun 24 13:29:36 how to send and receive the requests from android emulator to my localhost Jun 24 13:35:25 How can I get the AVD device I'm using to switch to landscape mode? Jun 24 13:39:34 Viridian: it should be a parameter in the AVD manager Jun 24 13:41:48 Hmmm...yeah, it should :) Jun 24 13:42:03 onCreateView of a Fragment, TextView title = (TextView)getView().findViewById(R.id.info_rom_name); returns NULL... the id is correct, why doesn't it find it? Jun 24 13:42:40 btw Viridian, did you know you can now have a *decent* AVD with accelerated graphics? Jun 24 13:42:56 Speak more! Jun 24 13:42:59 :) Jun 24 13:43:08 Does it start up faster? Jun 24 13:43:16 elegos: maybe you can't use getView(), weren't you supposed to return the constructed view tree in the onCreateView Jun 24 13:43:40 alankila: are you suggesting me to set the text on another event? Jun 24 13:43:45 elegos: no Jun 24 13:44:04 You're supposed to be doing something like this: View view = inflater.inflate(...); now you do view.findViewById() Jun 24 13:44:27 alankila: thanks, will try Jun 24 13:44:35 "will try". Think man. Jun 24 13:44:40 how else is it supposed to work Jun 24 13:45:38 Viridian: it's all faster. Pre-requisites: SDK Platform API 15 rev. 3 or higher (Android 4.0.3) and the extra package Intel Hardware Accelerated Execution Manager Jun 24 13:45:57 you have to install the Intel thing once downloaded (in SDK folder/extras/intel) Jun 24 13:46:12 Aw. I'm deliberately targeting an older version for compatibility purposes. Jun 24 13:46:22 :) Jun 24 13:46:53 btw then you create a new AVD with target 4.0.3, CPU/ABI x85 (intel/atom) and voila! Jun 24 13:47:32 I'd have more interest in HAXM if it didn't simultaneously break attempts to use virtualbox Jun 24 13:48:14 although I hear it works on windows. OS X was not impressed by two kernel modules both trying to use the virtualization capabilities for some reason Jun 24 13:48:47 I'm sorry for you alankila, I'm sure it will be fixed in a future release :) Jun 24 13:49:21 by the way, is there any dl-like view for android? (DL is an HTML tag) Jun 24 13:49:58 the purpose is to list an array of subject-descriptions Jun 24 13:50:30 Android UI doesn't really work like that. Jun 24 13:50:36 nah I run android in virtualbox, experimentally Jun 24 13:50:54 although I haven't really tried to see if I can talk to it via adb and all that Jun 24 13:50:56 LostC1tY: I'm trying to use textviews, but it sucks Jun 24 13:51:12 alankila: you can connect ADB via tcp Jun 24 13:51:23 maybe but before that I need to have the TCP working Jun 24 13:51:35 just adb connect and then open eclipse Jun 24 13:51:41 there's ethernet card and it works but because it's neither bluetooth and wireless, android thinks it isn't connected Jun 24 13:51:45 yet on command line it works just fine Jun 24 13:51:46 bah Jun 24 13:51:55 ifconfig on TTY 1 :) Jun 24 13:52:10 well let's just say that the situation leaves something to be desired Jun 24 13:52:14 and leave it at that Jun 24 13:53:07 I have physical devices to play with anyway, so it's not like getting the emulator right is particularly important. I'd have preferred HAXM but thanks to that problem, no go. Jun 24 13:53:10 Oh, it looks like switching to landscape mode is something I do in the XML of the project, not in the AVD settings. Jun 24 13:53:57 I have a DialogFragment implementing Observer, and an AsyncTask with an Observable as a member, ive added the DialogFragment as an Observer to this Observable, and call Observables notifyObservers(Object) from within AsyncTask onProgressUpdate. I know for sure that onProgressUpdate is being called, and that a reference to the DialogFragment exists, but my Observer update(Observable, Object) isnt being called Jun 24 13:55:12 robb_www: you might just hand the dialogfragment to the asynctask Jun 24 13:55:17 then call a method directly Jun 24 13:55:32 how'd you prettify the list on the right? (note: one title, one descriptor as of now): http://img265.imageshack.us/img265/8268/sucks.png Jun 24 13:55:38 it's pretty ugly as-is Jun 24 13:55:42 alankila, i think i will try that now, because this is ridiculous Jun 24 13:59:06 alankila, yep, that worked fine :/ Jun 24 13:59:39 not surprising. Jun 24 13:59:55 wonder what id done so incredibly wrong with the Observable though Jun 24 14:00:12 if it were abstract I wouldnt have been able to instantiate it directly Jun 24 14:07:43 OK, different approach, is there a way to get the GPS coordinates from someone who sends you a text msg? Jun 24 14:12:10 I'm using opengl es 2.0 and "shortBuffer.put(shortArray, 0, shortCount);" consumes 22% of the cpus performance. What to do? Jun 24 14:24:48 Ok kinda new too developing but I just wanted to make sure I got this right. For my app, lets say it's a game; I would design my splash screen in main.xml. Then afterward make another xml in layout for instructions, and another for highscore. Like that right? Make a xml in layouts for every screen? Jun 24 14:31:14 Austrie: technically yes. You get bonus points if you can skip the loading screen though, or merge it with the instructions/game scree Jun 24 14:31:24 you get even more bonus poinst if you can merge the instructions with the actual game. Think braid. Jun 24 14:32:01 it starts so beautifully and fast it takes a few seconds to realize that you're already in the game. Jun 24 14:32:44 splashscreens are just shit Jun 24 14:32:46 is the short version Jun 24 14:32:51 how can I set the first element of a listview as "pressed" by default? Jun 24 14:32:55 What should I use as action item logos in ActionBarSherlock? Is it save to use android.R.drawable.ic_menu_something? Or are there other special icons somewhere else? Jun 24 14:32:57 nobody wants to look at how cool you think you are :) Jun 24 14:33:12 because in the main.xml it only shows on image even though you can set the logic in java; it's still one image. So I was thinking I would have to use different xml files to get the different UI Jun 24 14:33:13 elegos why would you want that? Jun 24 14:33:25 default value Jun 24 14:33:29 i.e. in a settings menu Jun 24 14:33:39 so that the fragment on the right is never void Jun 24 14:34:03 splashscreens are boss Jun 24 14:34:36 splashscreens are vanity Jun 24 14:34:36 Austrie: yeah, that could be a solution Jun 24 14:34:37 hi there, im currently doing some profiling. whats the difference between cpu time and real time in ddms? Jun 24 14:37:34 real time is just what it sounds like. cpu time also. Other questions? :-p Jun 24 14:37:50 well, real time is the time elapsed on clock on wall. cpu time is the cycles that cpu spent running your program Jun 24 14:38:42 since your program could consist of, say, 1-second sleeps, cpu time can be very low Jun 24 14:39:05 what does FragmentTransaction's replace require as 2nd argument? In the docs is a generic "Fragment"... do I need to call the name of a fragment class? Or something like "new myFragment()"? Jun 24 14:39:59 pass null if you don't care about tagging the fragment by some name Jun 24 14:40:36 I assume you mean the 3rd argument though? Jun 24 14:40:45 no, 2nd Jun 24 14:40:59 well you obviously need to provide the fragment to replace the earlier element with Jun 24 14:41:18 i.e. I set a default fragment class for the initial state, but when I select another element, I have to change the fragment's content Jun 24 14:41:35 alankila: damn intuitive ;) thank u! Jun 24 14:41:55 my concern is: if I set a new MyFragment() all the times, doesn't it create multiple instances of a fragment which may already be initialized? Jun 24 14:42:14 elegos: sure, it is liable to do something like that. Jun 24 14:42:23 you are constructing new instances after all Jun 24 14:42:44 alankila: should I treat fragments like singletons? Jun 24 14:42:48 * alankila thinks he is in tautological mode Jun 24 14:43:10 Should, or should not. There is no try. Wait, wrong movie. I mean, it depends. Jun 24 14:43:13 i.e. MySingleton.getInstance() Jun 24 14:43:34 uhm Jun 24 14:43:37 it's perfectly OK from android point of view to keep on constructing fragments Jun 24 14:43:43 OK, different approach, is there a way to get the GPS coordinates from someone who sends you a text msg? Jun 24 14:44:05 NTinNJ: no, if it's a SMS Jun 24 14:44:22 well if the SMS holds the gps coordinates in it Jun 24 14:44:28 then you'd parse them from the text Jun 24 14:44:50 alankila: what about memory usage if I continue creating new instances of the fragments? Jun 24 14:45:00 What would have to be done to the message for it to contain that information? Jun 24 14:45:09 elegos: eh, they probably get garbage collected in due course unless they go into the backstack Jun 24 14:45:33 but you have to add them to backstack I suspect Jun 24 14:45:37 NTinNJ: to write the coords in clear text inside the message. SMS doesn't have that information (for privacy) Jun 24 14:46:15 alankila: so, if I don't have to initialize all the times 'cause I don't need it, it's a good practice to singleton-ize them, right? Something against this politic? Jun 24 14:46:29 elegos: sounds like extra work for no good reason to me. Jun 24 14:46:36 objects are cheap. Jun 24 14:46:49 ok, but what about CPU cycles for initializing? Jun 24 14:47:07 Probably comparable to other work that must be done anyway. Jun 24 14:47:08 I'd pass for a PC program, but what about low-performance CPUs? Jun 24 14:47:08 who cares Jun 24 14:47:15 lol ok :) Jun 24 14:47:32 android is not exactly cpu starved in the sense we might look at mobile phones Jun 24 14:48:03 quite a number of our devices have CPU clocks above 1 GHz, and multiple cores. Even the shitty phones have CPUs with third to half of that performance level. Jun 24 14:48:11 It feels like laptop maybe 10 years ago Jun 24 14:48:22 or 7, or something like that. Something like that. Jun 24 14:48:38 elegos have you ever heard of or used "Mr. Tracker"? Jun 24 14:49:11 hell, android uses java, instead of forcing everybody to deal with C. And dalvik is not as fast as JVM, which is not as fast as C. We still get by. Jun 24 14:49:14 NTinNK: no, never heard of it Jun 24 14:50:13 alankila: that's the point: the less you use the garbage collector, the better your program (and system) will work without having to deal with CPU spikes Jun 24 14:50:34 Supposedly, it sends an SMS message to the target phone, the user of the target phone then sends you an SMS and the app retrieves the GPS. Jun 24 14:50:46 and I don't give a fuck. This is a self-solving problem, just wait until the devices get better instead of optimizing construction of a few objects directly in response to user interaction Jun 24 14:51:08 NTinNJ: nothing simplier: just intercept those SMS and send back a plain text with GPS coordinates Jun 24 14:51:30 by all means think about what you are doing when you do something complicated and long, but when user's hand is on the screen, from performance point of view it's going to suck anyway. There's so much code that's going to be running that there's nothing you can do about that, so you can just add your own shit in the queue Jun 24 14:52:10 CPU doesn't even use much of the battery compared to what cell, screen and wi-fi does Jun 24 14:52:42 elegos: The thing is, it needs to be done covertly. Just by the reply from the SMS sent by the host. Jun 24 14:53:12 NTinNJ: take a look to the android's SMS class Jun 24 14:54:00 thanks I'll give it a shot, just google android sms class for the reference, yes? Jun 24 14:54:03 btw it's stupid to send an SMS to the phone: the first thing a thief does it to substitute the SIM card Jun 24 14:54:48 better would be to send a PUSH message to the service running on the phone, which generates a unique code the first time it's run Jun 24 14:55:20 then, sending an SMS without the permission of the user is like stealing a candy to a child Jun 24 14:55:52 Well, there will never be any access to the target phone from the host, that is where the problem lies. Jun 24 14:55:57 btw, how can I set a layout to a generic fragment?^ Jun 24 14:56:07 elegos: onCreateView. Jun 24 14:56:10 thanks Jun 24 14:56:18 you don't use generic fragments though. You specialize them, obviously. Jun 24 14:56:53 alankila: what about when you want a linear layout with things detailed in an XML? Jun 24 14:57:08 onCreateView can inflate an XML layout. Jun 24 14:57:54 I am super new to app development, very experienced in other languages, but I like books as opposed to online. Anyone tell me a good android reference guide with example code of what each command does or something like that? Jun 24 14:57:57 does the fragment need to extend something different than Fragment? Jun 24 14:58:24 no, Fragments are Fragments. Jun 24 14:58:27 I'm again in tautological mood. Jun 24 14:58:54 thus I call inflater.inflate(R.layout.my_layout, null)? Jun 24 14:59:02 or this.getView()? Jun 24 14:59:34 ah, container Jun 24 14:59:35 kk Jun 24 15:00:15 ... Jun 24 15:00:23 you need to read the Fragment javadoc Jun 24 15:01:07 but the short of it is, onCreateView, View view = inflater.inflate(R.id.foo, null), don't pass the viewgroup/container/what-have-you here, just null, then use view.findViewById() to configure it, then return view Jun 24 15:01:42 forget all about getView(), and please do not use 'this.' to spare some typing. Jun 24 15:02:05 sorry, R.layout.foo obviously above Jun 24 15:02:57 Hello, can someone have an idea why my EditText become big when we select it ? Jun 24 15:04:55 alankila: intents and broadcast recievers, i understand their purpose/use but the code for them seems complicated and hard to remember Jun 24 15:05:47 Austrie: is there a question somewhere there? Jun 24 15:06:06 nah Jun 24 15:06:08 just a statement Jun 24 15:06:11 :/ Jun 24 15:06:18 okay. Noted. Jun 24 15:06:19 is there a way to get the build number of an app within itself? Jun 24 15:06:59 and by build number I mean the nth time it's being compiled Jun 24 15:07:22 elegos: afaik nobody maintains such a thing Jun 24 15:07:38 Youtube v2.13? Jun 24 15:07:41 AFAIK Visual Studio has a variable like that Jun 24 15:07:41 at least I've not seen it. There could be a manifest attribute to track automated version number but I haven't seen such a thing. Jun 24 15:07:55 elegos: i guess you can adapt the build.xml to do that.. Jun 24 15:08:11 tapas: interesting... any hint about it? Jun 24 15:08:26 elegos: not sure though how to do that though.. i am not that familiar with ant Jun 24 15:08:35 elegos: it would be trivial in C/C++ with gnu make Jun 24 15:09:22 elegos: http://ant.apache.org/manual/Tasks/buildnumber.html Jun 24 15:09:33 thanks Jun 24 15:09:55 I rather build with eclipse personally. Jun 24 15:10:40 so shortBuffer.put() eats my cpu (no matter if I put the elements one by one or all at once), how can I get more performance? (opengl es) Jun 24 15:10:42 http://stackoverflow.com/questions/6758685/auto-increment-version-code-in-android-app Jun 24 15:10:54 google is pretty neat ;D Jun 24 15:11:21 I must be doing something stupid, please point it out :-) I'm trying to instantiate a webview, and I've asked for android.permission.INTERNET in the manifest file. From inside the emulator, I'm unable to load a page, I get the "web-page not available message". However, the browser in the emulator loads successfully. https://gist.github.com/6fb61ea5bf7e0ce6b627 Jun 24 15:11:51 kbs: how do you set the URL? Jun 24 15:12:11 tapas: loadURL("http://www.google.com") Jun 24 15:12:13 Waynes: hm, sounds like a tough problem to me. Out of interest, what does the short data represent? Jun 24 15:12:56 alankila: vertices and texture coordinates Jun 24 15:13:18 I see. Sounds like you're most probably doing the work correctly. Jun 24 15:13:34 because iirc you were supposed to pass these using these *Buffers Jun 24 15:14:31 Waynes: ShortBuffer.wrap() any use to you? (I don't remember if the GLES stuff placed special requirements for the input buffers.) Jun 24 15:14:54 Just thinking that maybe you can spare the "put" part of the problem Jun 24 15:15:05 unfortunately the buffer has to be in native byte order Jun 24 15:15:15 and it has to be allocated directly Jun 24 15:15:17 ah, so that necessiates a copy in high likelihood Jun 24 15:15:30 how do you acquire the short[] stuff? Jun 24 15:15:38 if from file, it might be you can load directly to native buffer Jun 24 15:15:56 using the filechannel i/o Jun 24 15:15:56 it's calculated from a lot of little spaceships which fly around Jun 24 15:16:06 I see. So constructed. Jun 24 15:16:11 kbs: weird. that should work.. Jun 24 15:16:18 kbs: did you try on a real device? Jun 24 15:16:33 tapas: not yet, no. I wonder if I just have my uses-permission in the wrong spot. Jun 24 15:16:47 kbs: where do you have that tag in the manifest? Jun 24 15:16:52 alankila: how many apps do you think i can make without broadcast receivers and intents in the code? Jun 24 15:16:54 Waynes: perhaps you can abstract your vertex arrays as "objects with rotation and scale" and so on instead of just passing every vertex separately Jun 24 15:17:02 tapas: https://gist.github.com/6fb61ea5bf7e0ce6b627 Jun 24 15:17:17 kbs: yep, wrong spot Jun 24 15:17:22 tapas: yeah :-) thank you! Jun 24 15:17:24 move it out of the application tag Jun 24 15:17:25 Austrie: eh. Infinite. You don't *have* to use them, and I'm sure some fart soundboard applications require none, so you can make an infinite number of them. Jun 24 15:18:04 the code for them is long and hard to remember Jun 24 15:18:14 alankila: the movement is quite random so I guess I can't Jun 24 15:18:24 Austrie: how is it that you have to remember it? Don't you use an editor that remembers it for you? Jun 24 15:18:43 Waynes: okay. Well, it sounds to me like my idea battery regarding the topic has been exhausted, unfortunately. Jun 24 15:18:55 thanks anyway :) Jun 24 15:19:37 alankila: What do you mean by editor? Do you mean the IDE? Jun 24 15:19:50 An IDE, perhaps, is the better term. Jun 24 15:20:24 I use Eclipse Indinigo, but might downgrade to Helios though... Jun 24 15:20:28 but the guys who use BroadcastReceivers type something like 'new BR' then press ctrl-tab, select BroadcastReceiver from list (might be the first choice), hit enter, and get an implementation of it where you are ready to fill in the method Jun 24 15:20:34 this sort of thing sounds familiar to you? Jun 24 15:20:42 sorry, ctrl-space by the way Jun 24 15:21:00 yeah Jun 24 15:21:07 ctrl+space yeah Jun 24 15:21:09 so ... a lot of remembering, really? Jun 24 15:21:17 lol Jun 24 15:21:46 When I say remembering, I meant remember which each part of the line of code mean Jun 24 15:22:00 well it does take a little more work to get the 'onReceive' method filled in, new BR just expanded to BroadcastReceiver, still had to type () { and then here use ctrl-space } Jun 24 15:22:51 okay, let's talk about 'new BroadcastReceiver() { @Override public void onReceive(Context context, Intent intent) {} }' Jun 24 15:23:10 this would normally be around 5 lines, one has @Override, two has just }, and the remaining on separate lines Jun 24 15:24:02 if you have trouble with something like this, then maybe programming is not the profession for you. Or IDK. Jun 24 15:24:51 could be you're just very inexperienced about java Jun 24 15:24:52 alankila: Do you understand what this line mean? I think I understand it but just look "private void onReceive(Context context, Intent intent) { if (intent.getaCTION()==NULL) { CONTECT.STARTsERVICE(NEW iNTENT(CONTEXT, ToggleService.class)); Jun 24 15:25:04 yes, it's clear. Jun 24 15:25:29 im not the best at java, but I understand most of it Jun 24 15:25:32 if there is no action in the intent, it tries to start the ToggleService. But ... that's pretty weird intent, without action. Jun 24 15:25:37 I'm not sure if that can ever occur Jun 24 15:25:58 he wants a intent that don't have a action Jun 24 15:26:01 because presumably your broadcastreceiver is with an IntentFilter and the IntentFilter names some action for which that receiver triggers. Jun 24 15:26:18 so sounds to me like it's just confused code Jun 24 15:26:56 can anyone here say if it's possible to receive an intent with action set to null on a broadcastreceiver? and what should intent could mean. Jun 24 15:27:10 should=such Jun 24 15:27:39 he wants a intent that doesn't have a action Jun 24 15:27:47 Austrie: so you keep repeating. Jun 24 15:27:51 hello, I'm trying to use holoeverywhere and sherlockactionbar for an app, so I made the setup for sab and I launched and it works, then I imported holoverywherelib fixed the path error to sab but I get this error: "No .class files were found in project "library", so none of the classfile based checks could be run. Does the project need to be built first?"a Jun 24 15:28:23 And I can't find a fix Jun 24 15:28:49 its a widget, that toggles silent mode and ringermode Jun 24 15:29:37 and it uses a service for it? I wonder why doesn't it do the work directly. Jun 24 15:29:49 this applications sounds ever more curious Jun 24 15:30:02 haha Jun 24 15:32:46 the widget sends the information...err...i mean intent(used it right?) to the main app Jun 24 15:33:26 Austrie: what do you mean by "main app", is there a UI involved besides the widget itself? Jun 24 15:33:27 well, I imagine it uses intents for its communication. Jun 24 15:33:43 although to me it sounds like a rube goldberg machine by this point Jun 24 15:34:46 it original app that does the same thing, but the dev wanted to add a widget with the app so the user can use the app on the home screen for convience Jun 24 15:35:35 anyway, are you aware of the fact that this application sounds utterly pointless? not only is the choice of silent/noisy phone on lockscreen, it's also on the notification overlay (at least on my phone) Jun 24 15:36:01 it is pointless Jun 24 15:36:03 on old androids it looked to be lockscreen material, on ICS I imagine it moved to notification area Jun 24 15:36:11 it's just a example Jun 24 15:36:18 I see. Jun 24 15:36:25 to learn about a widgets Jun 24 15:36:52 hi Jun 24 15:37:20 A chinese user just sent me an email saying my app could not be downloaded in china Jun 24 15:37:26 it also brought intents into the code for the first time but the book wrighter didn't explain it good Jun 24 15:37:33 lol Jun 24 15:37:39 make it nation wide Jun 24 15:37:41 paid app Estragon? Jun 24 15:37:48 nop, free one Jun 24 15:37:50 include the chinease language Jun 24 15:38:01 but including in-app purchases Jun 24 15:38:12 "This item cannot be installed in your device's country." Jun 24 15:38:54 your app is probably only selected for the english laguage, country region Jun 24 15:39:12 add Chinese support too the app Jun 24 15:39:25 are you sure it matters ? Jun 24 15:39:43 Well... Jun 24 15:39:53 because spanish users can download it but my app is not spanish translated Jun 24 15:44:26 got bored of coding.. decided to do some visuals and a bit of music :) http://www.youtube.com/watch?v=H429FCXIG2g&feature=youtu.be Jun 24 15:55:27 gaz` o.o Jun 24 15:58:07 :-D Jun 24 15:58:17 gaz` did you code that? Jun 24 15:58:23 NO Jun 24 15:58:24 no Jun 24 15:58:26 after effects Jun 24 15:58:28 ;) Jun 24 15:58:36 ive coded something very similar but no where near as cool Jun 24 15:58:38 gaz` the music sucked Jun 24 15:58:43 haha yeh thats mine Jun 24 15:58:47 im a n00b Jun 24 15:58:56 :) Jun 24 15:59:07 Guys, I know these questions are stupid for you, but like I said, I am SUPER NOOB when it comes to the android, and my phone did not come with a manual or anything except the phone. I have an app that came as a .rar file. Does the droid extract on its own, or do I need an extracting app as well? Jun 24 15:59:12 atleast youtube cant take it down for (c) Jun 24 15:59:14 ;) Jun 24 15:59:36 NTinNJ unrar it, there will be apks, theyre what u install Jun 24 15:59:46 NTinNJ sounds more like pirated app ;) Jun 24 15:59:55 gaz`: Thought of that, there are no .apk files Jun 24 15:59:57 NTinNJ this is android developers channel not android channel Jun 24 16:00:02 NTinNJ impossible Jun 24 16:00:07 it's not an android app then Jun 24 16:00:10 or did you get the source code? Jun 24 16:00:14 parsing xml from sdcard is killing me.Followed several tutorials and still stucked with it Jun 24 16:00:18 what's the contents of the rar Jun 24 16:00:27 wHiTeHaT44 isn't there a lib for that? Jun 24 16:00:42 wHiTeHaT44 can you reliably read a file on the sd card? Jun 24 16:01:14 Dany0: It has some .xml, some .exe, some .cl The app is for more than just droids. Jun 24 16:01:18 there are several lib for it.Easyest for me would use DOM parser i assume Jun 24 16:01:24 NTinNJ an exe? Jun 24 16:01:27 are you retarded? Jun 24 16:01:31 putting an exe onto an android? Jun 24 16:01:42 wHiTeHaT44 yup Jun 24 16:01:50 Danyo: Like I said, it is for more thn just droid phones. Jun 24 16:01:55 NTinNJ where did oyu get the file Jun 24 16:02:54 Dany0: The program is called Mr. Tracker, allegedly, works on droids, bb, windows, etc. phones, so I believe they put all phones in the .rar Jun 24 16:03:57 NTinNJ are you trying to spy on your kids? Jun 24 16:04:18 or have a cheating wife? Jun 24 16:05:28 Dany0: That is one of the applications that is possible, but more for like someone calls me and says "I was bar hopping last night, not sure what bar I left my phone in. Jun 24 16:06:01 NTinNJ listen you fucking moron, RTFM and I don't like people like you http://www.mrxsystem.com/faq.html Jun 24 16:06:15 * Dany0 is mad because he's the overlord of invading people's privacyt Jun 24 16:06:20 *privacy Jun 24 16:06:49 /s/privacyt/privacy Jun 24 16:07:54 Dany0: Slow your roll, This app has legit purposes, pain medication has legit uses, can it be abused? Of course, but it also has legit purposes. Jun 24 16:08:03 ouch!! enabling beCarefull modus ON Jun 24 16:08:13 lol he mad Jun 24 16:09:50 Everything can be abused, but when handled properly and with respect it can also be helpful. What if your kid gets abducted, but he has a cell phone and you can locate him? Do you not think that is a legit purpose? Jun 24 16:10:24 hi, guys I've got a question about layout separation. I have two pretty much different results with different logo, splash screens etc. One is implemented for 480x800 resolution and the other for 1024x800. My task says that I have to separate those designs based on device screen resolution. Im building against 2.3 and as far as I know there's no native way to do it. In my case I can just getWidth() and get appropriate layout for the app - do u thin Jun 24 16:10:27 @Dany0 do i realy need an xml parser to simply get the folowing : Jun 24 16:10:34 String[] myArray = getResources().getStringArray(R.array.testArray); Jun 24 16:10:36 //String[] myArray={"http://www.upc.nl/","http://www.google.com","http://www.flyerwall.nl"}; Jun 24 16:10:51 sure just do one of those streamwriters Jun 24 16:11:07 write one on each line and then reassemble it afterwards Jun 24 16:11:39 My question was just should I extract the rar or can android handle it? Jun 24 16:11:56 dont think android can handle rars Jun 24 16:11:58 whats in the rar Jun 24 16:12:40 It has some .xml, some .exe, some .cl The app is for more than just droids. Jun 24 16:12:44 NTinNJ you fucking idiot Jun 24 16:12:45 http://www.mrxsystem.com/faq.html Jun 24 16:12:47 ^^^ Jun 24 16:12:48 please Jun 24 16:12:52 you're outraging me Jun 24 16:13:16 NTinNJ prob would need to compile etc Jun 24 16:13:38 guys what is needed to make an app default launcher? Can I write for example hello world app and make it default launcher or there are some requrements? Jun 24 16:13:41 Danyo: Problem is I did not download it from my phone, I downloaded it from my pc. Jun 24 16:13:57 wow you really are stupid aren't you Jun 24 16:14:01 http://www.mrxsystem.com/faq.html Jun 24 16:14:06 ^^^^^^ HOW TO INSTALL Jun 24 16:14:35 Yes . Mr Tracker can be installed many times but only on the one phone. Each download has a unique imie phone allocation. Torrent downloads will not work.. Jun 24 16:14:40 and it's Dany0 not Danyo, also use tab to autocomplete Jun 24 16:14:45 Danyo: Yeah, I read all of that, what they fail to tell you is, they send you an email that says "to download click here" silly me for checking my email using my pc. Jun 24 16:15:23 if it came with a .rar ... you have to extract the .rar on your desktop pc Jun 24 16:15:25 NTinNJ you don't install it on the phone you bum you install it on the PC first then the app will take care of uploading the necessary to the phone Jun 24 16:15:37 NTinNJ the exe is the installer Jun 24 16:16:04 then i assume you click the .exe (plugin your phone... but if it is agood program... it will ask you to) Jun 24 16:16:37 Dany0: No, it doesn't, it says "Install Google Earth Pro" which I did, there is a glitch somewhere. As far as a PC goes, I know them inside and out, the droid is a totally different story. Jun 24 16:16:52 ok I'm out Jun 24 16:17:33 1 last question does an app HAVE to be installed into the phone, or can it run off the SD card? Jun 24 16:18:02 can run off sd Jun 24 16:18:06 if designed properly Jun 24 16:18:27 gaz` he's asking if you can launch an apk like an exe Jun 24 16:18:29 NTinNJ so no Jun 24 16:18:31 I am getting a NullPointerException in the Java Builder after having imported an Android .project Jun 24 16:18:33 :/ Jun 24 16:18:43 hi, guys I've got a question about layout separation. I have two pretty much different designs for the same application with different logo, splash screens,etc. These designs are supposed to be used for < 1024x800 resolution devices and for >=1024x800 respectively. Jun 24 16:18:43 I'm building against 2.3 and as far as I know there's no native way to separate layouts/resources based on device resolution. Jun 24 16:18:43 In my case I can just getWidth() and get appropriate layout for the app - do u think it's a right way to implement my task ? Jun 24 16:18:49 guys what is needed to make an app default launcher? Can I write for example hello world app and make it default launcher or there are some requrements? Jun 24 16:19:31 F1rstAid: I imagine it declares in manifest the capability to be launcher Jun 24 16:19:38 how it acts as a launcher is likely up to its discretion Jun 24 16:20:09 Dany0: Like I said, it does not come with any .apk, but there is an xml file, also there are other .rar files. I guess what I should do is extract all the .rar files, copy them all into a folder on the sd card, and try to run the .xml from there. Does that make sense? Jun 24 16:20:26 figure it out on your own Jun 24 16:20:35 xml is a text file you moron it's not an app Jun 24 16:20:47 >.> Jun 24 16:21:29 Dany0: I said from the BEGINNING I am an android noob, wanna talk about dbase programming? I'll make you cry. lol Jun 24 16:21:54 NTinNJ OH MY GOD MOMMY TAUGHT YOU M$ ACCESS HOW CUTE, sure jump right at me Jun 24 16:22:09 Access is for rookies. Jun 24 16:23:02 SELECT NTinNJ FROM NOOBS WHILE MASTURBATING FURIOUSLY Jun 24 16:23:34 Oh I guess that was painful is some strange way. Jun 24 16:23:41 lol Jun 24 16:25:56 NTinNJ common... there must be a how to install or whatever inside the files and also somehow explained on theire website.But tell me.. did you buyed this program or downloaded via torrent/newsreader ? Jun 24 16:28:47 is there a way to display the cpu usage of a function in ddms? the values for incl cpu time and excl cpu time are relative to the actual cpu usage. Jun 24 16:29:04 wHiTeHaT44: I bought it. Jun 24 16:29:33 isnt it wise then you contact the seller? Jun 24 16:29:41 so the sum of all incl cpu usage is always 100% Jun 24 16:29:47 i readed if not be able to install you get refund Jun 24 16:30:05 wHiTeHaT44: I have, apparently, they take their sweetass time replying. Jun 24 16:30:36 I paid with my Amex, I can get my money back anytime, but I would rather it work. Jun 24 16:30:41 Dany0: incidentally, can you chill a bit? Jun 24 16:30:47 Leeds sure Jun 24 16:31:53 hello all, is there any api which is used to program external display? I want to have differnt outputs for my app Jun 24 16:31:59 i have a custom drawable for a progress bar. i would like to set the colors that the drawable uses based on the percentage value of the progress bar. is that possible to do? Jun 24 16:32:02 eg. at 0% it's red, at 100% it's green. linear shift between (gradient) Jun 24 16:32:22 brb, cigarette break to think about this.. Jun 24 16:37:59 Has anyone played with DialogFragments? Will they keep track of open instances so you can't open a dialog multiple times? Jun 24 16:38:19 Hello, anyone use holoeverywhere ? Jun 24 16:40:51 anyone knows how to tell lint not to scan libraries Jun 24 16:40:57 ? Jun 24 16:42:55 why is this replacing a sub-element of the target-fragment, instead of the target-fragment itself? http://pastebin.com/am3Wxvyw Jun 24 16:43:36 its "replacing" an ImageView with id "splash_logo" =\ Jun 24 16:43:38 elegos because... oh wait that's not why Jun 24 16:44:35 Dany0: ok, how can I fix that odd behavior? Jun 24 16:44:59 sorry no idea, I thought you were doing it in the wrong place but seems fine now Jun 24 16:45:08 can't help you no, sorry Jun 24 16:49:54 I get a "No .class files where found in library" error, the project I imported add them but eclipse doesn't see them ... Jun 24 16:53:55 back now Jun 24 16:54:08 and for the record, .XML is NOT a text file. Jun 24 16:55:49 NTinNJ: yes, it's a plain-text file Jun 24 16:56:05 maybe you're referring to a binary XML file, such as the MS one, or the android compiled ones Jun 24 16:56:51 elegos never heard of the MS one? Jun 24 16:57:02 Dany0: read up your head :) Jun 24 16:57:41 any possible answer on why my fragment is not being replaced correctly? Jun 24 17:02:52 elegos: maybe..? whats going on Jun 24 17:03:06 logcat you mean? Jun 24 17:03:19 well yeah, but what is the problem in general, I just joined Jun 24 17:03:45 well, logcat is null :P about the problem Jun 24 17:03:59 http://pastebin.com/am3Wxvyw is the code Jun 24 17:04:18 the problem is that the new fragment is being nested inside another one, instead of substituting it Jun 24 17:04:30 and it will replace an ImageView with id "splash_logo" Jun 24 17:04:43 you want me to debug an issue for you and you dont show me all the code being touched? Jun 24 17:04:48 thats cute Jun 24 17:05:09 I showed you the relevant part Jun 24 17:05:14 if you want more, please ask Jun 24 17:05:23 Nah, ill pass ;) Jun 24 17:05:23 elegos: afaik binary XML is a misnomer - those binary forms are more of "dump of preparsed XML" Jun 24 17:05:30 elegos: It is my understanding that .XML is Extensive Markup Language file. Yes, it can be created in a text editor, but it contains code instruction. Jun 24 17:07:01 .xml is a file extension Jun 24 17:07:26 XML means eXtendible Markup Language, and the XML file is being formatted as the standard says Jun 24 17:07:40 agreed Jun 24 17:07:42 now, being XML files just "containers", they may be written in different ways Jun 24 17:08:00 but the classic XML file is a tag-based, plain-text file Jun 24 17:08:17 it is compressed for speed purposes Jun 24 17:08:35 http://www.fileinfo.com/extension/xml Jun 24 17:09:13 just a second, I'll find you out the paper Jun 24 17:09:58 elegos: XML *is* defined as text format Jun 24 17:10:35 man, android development makes me miss Ruby Jun 24 17:10:46 p_l I was discussing about the difference between the standard and the file formats Jun 24 17:11:09 Tagami: I have never done a lick of ruby, is it similar to android? Jun 24 17:11:17 no Jun 24 17:11:19 very different Jun 24 17:11:23 btw I can't find the ISO doc right now Jun 24 17:11:24 p_l by that theory, then HTML is also just a text file, as is uncompiled C, C++, VBS, etc. Jun 24 17:11:30 but like, i'm spending hours getting a string parse just so Jun 24 17:11:35 and in ruby it'd be two lines and five minutes Jun 24 17:11:41 NTinNJ: you're making a big mistake :) Jun 24 17:11:58 Tagami: "hours"? Why? String Parsing in Java shouldnt take you that long to do Jun 24 17:12:26 NTinNJ: ISO and IEEE standards are there for a purpose, and XML is being registered at ISO Jun 24 17:12:41 drpenguin: it's complicated and i'm having to remember all that Java i've forgotten XP Jun 24 17:12:42 and it has been registered as a plain-text format Jun 24 17:13:07 (i'm pulling in CSV files of sensor data and it's a pain) Jun 24 17:13:26 [Google Maps] is it possible to bind a onTouchEvent to an overlay? Jun 24 17:13:32 a pain-text-format... Jun 24 17:13:32 Tagami: why not just use some regex magix and be done with it? Jun 24 17:13:47 drpenguin: well that's maybe a better solution Jun 24 17:13:49 elegos: Not at all, I can write any of those languages using a text editor. Does windows treat them as .txt? No, windows is told the file association and what program is used to run/open it. If for example VB is installed on the PC, windows will open a .vbs by launching VB, if the ext is .doc windows will launch MS Word, etc. Jun 24 17:14:07 although the CSV is pretty light on things to regex for and i don't control the generation Jun 24 17:14:13 NTinNJ: you could write an XML using assembler Jun 24 17:14:18 NTinNJ: windows is different though.. it relies on extension to know what the file is Jun 24 17:14:40 every file has its file type (MIME?) inside its own header Jun 24 17:14:43 i'm sure that if i really knew what i was doing i'd be done by now Jun 24 17:14:45 drpenguin: My point exactly. Jun 24 17:14:49 buuuut... Jun 24 17:15:00 Tagami: maybe I could help ya out? Im not bad with string parsing Jun 24 17:15:27 possibly so Jun 24 17:15:28 NTinNJ: I don't understand your point O.ò you stated XML is not a plain-text file format Jun 24 17:15:38 i'm using a string tokenizer atm Jun 24 17:15:52 NTinNJ: text format still. It's not related to *OS-dependant* anything Jun 24 17:16:00 basically like, getting dates and sensor values in a CSV Jun 24 17:16:05 elegos: In windows, it is not a plain text file unless you tell windows to treat it as such. Jun 24 17:16:22 i'm sticking each line into an arraylist Jun 24 17:16:30 Tagami: ok.. how are the dates and sensor values formatted? Jun 24 17:16:35 NTinNK: wrong, it's still plain text file, but windows doesn't know how to open it Jun 24 17:16:35 it's just like Jun 24 17:16:45 it's slightly different Jun 24 17:16:49 NTinNJ: actually... it is. The exact details of why and how are outside of scope of this channel though, and would require talking about Operating Systems you probably never seen Jun 24 17:16:50 I am STRICTLY talking about how Windows looks at it, nothing more. Jun 24 17:16:52 "2012-06-24 11:38:45,83.4,,52,0,100" Jun 24 17:16:54 for example Jun 24 17:17:00 (note the double comma there, that's for a missing temp value) Jun 24 17:17:19 NTinNJ: for windows all files are the same, it only has a registry full of associations extension -> program Jun 24 17:17:37 Tagami: maybe it would be easier for you to taht, instead of having empty values for something missing, have some default value Jun 24 17:17:53 drpenguin: yeah that'd be great :) Jun 24 17:17:59 NTinNJ: as it happens, windows has two types of "normal files" - binary and text. And the type isn't stored in the file, but is set by application when opening it (and even then it's mostly a case of catering to some languages) Jun 24 17:18:01 but as i said, i don't control the CSV Jun 24 17:18:03 elegos: again, agreed, but all I do now is windows, with unix and linux its different. Jun 24 17:18:06 i'm pulling it from somewhere else Jun 24 17:18:24 "text" means "convert certain elements in flight" Jun 24 17:18:27 (and then the ultimate gameplan is sticking it in a widget) Jun 24 17:18:36 but the files, in the end, are a stream of 8bit bytes Jun 24 17:19:22 still have that problem about fragments <.< cool story is that if I try to replace another fragment, it works. If I change the ID of the target fragment and update the code, BANG! still have the same issue Jun 24 17:19:40 Well, in Windows, unless you right-click and choose "Open With..." windows will always open the file with the program the extension is associated with, that is all I am saying. Jun 24 17:19:58 Thats not any different from linux or unix though Jun 24 17:20:29 (ultimately everything is bytes :P) Jun 24 17:20:33 drpenguin: Are we talking about in a GUI environment, or terminal? Jun 24 17:20:55 Uhh, Gui? But again, that also applies to windows.. Jun 24 17:21:48 In GUI, yes, the same as windows, in terminal, its all a text editor. Jun 24 17:22:17 ... are you saying terminal is a text editor? whats with that last part Jun 24 17:22:58 i know in ruby i would just do Jun 24 17:22:59 [date, time, temp, humidity, link].each do |value| { value = input.nextToken() if input.hasMoreTokens() } Jun 24 17:23:03 etc Jun 24 17:23:20 drpenguin: Just meaning that what you create is all pretty much text (yes of course there are the exceptions, like in debug or something) but it treats text as text until it is ran. Jun 24 17:23:27 Tagami: I wonder.. maybe you ould do some Adapter magic with the arraylist? Jun 24 17:23:39 drpenguin: that might be a better way to do it Jun 24 17:23:40 about my fragment problem: it seems it will APPEND the layout, 'cause I've tried deleting the imageview and now it will... append the new layout where the previous one ends Jun 24 17:23:45 what kind of thing would you advise doing? Jun 24 17:23:53 i am not familiar with the various adapter magic things you can do :) Jun 24 17:24:17 But HHmm.. nah.. I dont think an adapte rwould help you parse the stuf fpersay, unless you are displaying it? Then that would work out I think Jun 24 17:24:41 yeah, i think i want to store it Jun 24 17:24:45 NTinNJ: what are you even talking about. The OS doesnt treat something as anything unless you tell it what it is Jun 24 17:25:08 That is an abstraction. The OS need not know what the thing is, you just tell it "listen dude, you get this, run it with that, boom" Jun 24 17:25:19 i'm just going to hack away at the stringtokenizer idea until it works, it just won't be elegant :) Jun 24 17:27:14 String.split()? Jun 24 17:27:17 drpenguin: Lets say from a Command Prompt, you type Edit autoexec.bat in the root directory. you type whatever instructions, save the file, exit. Shut the computer down, when it starts it will launch autoexec.bat, even though it is just a text file. Jun 24 17:27:42 NTinNJ: Because the OS has been told what to do with bat files! It doesnt matter that its text dude Jun 24 17:27:58 Seriously, you need to learn basic OS Theory, you are talking about things you clearly do not understand Jun 24 17:29:09 AGAIN, agreed! But you know that is how it is going to occur. And I've been doing this for over 38 years, I go back to the apple //e days, I know how it works. Jun 24 17:29:34 heeeeeeeeey Jun 24 17:29:39 this stringtokenizer thing actually kind of works Jun 24 17:29:49 Then you owuldnt of said what you said. Because I can make any file I want a .bat file and it will attempt to run it. Doesnt mean its going to work dude Jun 24 17:30:06 This is off topic anyway Jun 24 17:30:30 Of course not, I was just using it as an example, same thing would apply to config.sys Jun 24 17:30:49 true, cocktail time for me anyway, bbl Jun 24 17:30:58 be well. Jun 24 17:34:33 NTinNJ-AWAY: btw, "clicking" on something is equivalent of running "start.exe " - the "open with" is a database of settings for the "start" program, like in MacOS "open" or freedesktop's "xdg-open" Jun 24 17:35:23 (and Plan9's "plumber" system) Jun 24 17:36:58 god damn it Jun 24 17:37:07 I upgrade my ram, and now weird shit starts happening :( Jun 24 17:37:34 Is there any online "gotcha" resource where common errors which are commonly causing force close on various platforms are listed? Jun 24 17:37:54 wow, upgrading ram on android devices must be a tough job Jun 24 17:38:38 luyang: stackoverflow.com ;) Jun 24 17:39:07 heh Ge0rG Jun 24 17:39:17 Ge0rG: that's a huge list to go thru :-o Jun 24 17:39:42 It would be nice to have a check list before publishing an app though Jun 24 17:42:38 luyang: whats wrong with just following the stack trace of an fc? Jun 24 17:44:03 drpenguin: users have to get FC and tell me… and rate app as 1star Jun 24 17:44:34 luyang: ok.. so how would this magical "list" prevent that? Jun 24 17:44:48 may stop common FC's from happening, but then agian, if you QA your app right, then people shouldnt see them Jun 24 17:45:10 drpenguin: it might make it less probable Jun 24 17:45:45 Right, but like I just said, if you QA your app properly, then you really dont need that list now do ya? Jun 24 17:45:45 I mean… You can get UnknownHostException in the emulator but it might work fine on a device. You might do things in the wrong thread… etc… Jun 24 17:46:26 And I also wanna have a checklist on when to use Activity context and when to use Application context and how to avoid memory leaks… or heck… a guide on how to "stop worrying and start coding away" Jun 24 17:47:00 Then what you are asking for isnt really a list, it sounds like you dont have a deep enough understanding of Android development and you need to brush up on it Jun 24 17:48:07 You already have what you need infront of you, there are tools in Eclipse from the sdk you either have or can download. You have d.android.com, plus multiple other online resources Jun 24 17:48:16 I dunno I have read a lot but I guess I haven't coded away enough Jun 24 17:48:36 Dr_Heckle: Jun 24 17:48:55 oops drpenguin: thanks for the tips… I guess I just gotta get down to biz and code Jun 24 17:56:20 Hi, I'm making a short list of items, and wanted to have a radiobutton in each item, but I'm generating the list dynamically, and each list item is a complex layout itself, is there a way to group all the radiobuttons into a radiogroup? Jun 24 18:01:04 Does android run .vbs without anything special, or do you need a special app or set an association to it or something? Jun 24 18:01:26 NTinNJ: just double click on it... Jun 24 18:02:40 GeorgeJ: It asks me what to open it with and I don't want to screw it up Jun 24 18:03:02 GeorgeJ: you can always undo the association..? Jun 24 18:04:49 .vbs is VBScript, right? Android by itself doesn't have an interpreter for that, afaik Jun 24 18:04:49 This is running off the SD card because I do not know how to install it into the phone itself. Like I said, the phone came with no manual Jun 24 18:05:20 p_l: Correct, VB Script. Jun 24 18:08:04 NTinNJ: yeah. Adroid by itself doesn't contain support for that. You can in theory run it if you get some application that a) implements VBScript b) registers an intent filter that will accept files with .vbs extension in appropriate way Jun 24 18:10:34 Is there a simple way that I can just copy a folder from the SD card and PASTE it to the phone itself? Jun 24 18:10:40 I dont finde the tutorial for google maps and onTap on the dev android homepage. And the search linking to death urls Jun 24 18:11:38 Is there a way to associate a radiobutton to a radiogroup if it doesn't detect it nested into the layout heirachy? Jun 24 18:13:29 NTinNJ: not exactly. /data isn't really for user storage, but you can get to it (and to /system) if you root the phone Jun 24 18:14:10 *sigh* You can tell these phones were not written by a Vulcan, on account of there is no logic to them. lol Jun 24 18:14:46 What are you talking about Jun 24 18:15:08 Searching a googlemaps onTap tutorial. The site from the offical android dev site dont work Jun 24 18:15:17 ,oO( s/talking/trolling/ ) Jun 24 18:15:39 Ge0rG: add a g next to the closing slash Jun 24 18:16:23 can i set a default value on a edit number field but have the hint show up till a user actually inputs something? Jun 24 18:17:08 JaredCE: If you set the field to someting, afaik, the hint wont appear because theres a value Jun 24 18:17:31 ahh Jun 24 18:17:58 whats the best practice for where a user hasn't inputted something and clicked a button that requires something being input? Jun 24 18:18:16 JaredCE: well I think that would depend on the context Jun 24 18:18:38 Because you can either impose a default value, or tell the user "dude! You need to put something there" and show it as an alert dialog to toast Jun 24 18:18:59 alert dialog to toast is what i want i think Jun 24 18:19:10 s/to/or/ Jun 24 18:19:24 lol alert dialog then Jun 24 18:19:30 i'll look into that Jun 24 18:20:30 a toast message is less abrupt though Jun 24 18:20:33 This is so frustrating, I'm sure if you have hours and hours to spend trying to figure out how the phone works, I'd bet it is wonderful. Jun 24 18:20:44 It depends how likely the user will be to notice the error message Jun 24 18:20:52 dsample: yeah thats true Jun 24 18:20:58 (a toast message disappears automatically) Jun 24 18:21:33 Its all a matter of context ya know, its a valid option, just may not be the best Jun 24 18:21:41 NTinNJ: what phone have you got? You realise you're on a developer channel not a user help channel? Jun 24 18:21:59 I think he would be better suited on #android-troll... Jun 24 18:22:13 God forbid an engineer study something for a couple hours... Jun 24 18:22:23 lol Jun 24 18:22:28 dsample: HTC EVO, yes, I know and I am trying to develop something, I just do not know if it the initial coder or if it is the phone that is the issue. Jun 24 18:23:12 NTinNJ: then try it in an AVD Jun 24 18:23:24 NTinNJ: but the first I saw was that you were trying to run VBS on it, which obviously won't run Jun 24 18:23:33 fjornir: I am not trying to do brain surgery, believe me. This should just be so obvious. Jun 24 18:23:43 Android is all Java, not .Net Jun 24 18:24:00 dsample: I just asked if it was possible, thats all, I did not get a manual with it. Jun 24 18:24:04 Ehh, its not *all* java Jun 24 18:24:07 Unless you're using Monotouch. Jun 24 18:24:08 Like Rdio. Jun 24 18:24:13 Their whole app is written in C#. Jun 24 18:24:41 Chronax: hmmm, interesting, will have to look at that Jun 24 18:25:31 Can I create a fragment without any content in it? i.e. without specifying the name attribut Jun 24 18:25:31 e Jun 24 18:25:57 AND TO ALL: I keep getting different answers, one person will say "Yeah, that will work!" someone else will say "No that cant work" then someone else will say "Well it COULD work if you have X" Jun 24 18:25:58 Chronax: I'm trying to learn Android development for the second/third time now, and this time it's sinking in, but I seem to hit walls for things that should be pretty simple. Jun 24 18:27:49 NTinNJ: you would need to find a VBS interpreter to wrap around the VBS code itself. The likely places to look for that kind of thing is Mono, since that's the name for the general .Net framework implementation on Linux Jun 24 18:28:20 Ntinnj: Have you tried reading the documentation for the SDK? It is pretty clear what the default programming language for the platform is. Jun 24 18:28:30 is there anything illegal with this layout, applied to a fragment? It seems this is the cause of my troubles not being correctly substituted: http://pastebin.com/iALvhzpd Jun 24 18:28:34 dsample: Now I am told this is all java based stuff, but I can't say for certain. Jun 24 18:28:58 It isnt *all* java... Jun 24 18:29:08 And if you read the docs, you'd know that Jun 24 18:29:14 fjornir: There is no .apk file for this app. Jun 24 18:29:18 NTinNJ: sorry, shit happens when asking on IRC first. d.android.com has really good guides, even if SDK examples sometime fail, but they describe the architecture well Jun 24 18:30:11 drpenguin: Yeah, I know, I get that, but it seems no matter what part of the app I try to open the droid asks me what to open it with. Jun 24 18:30:24 NTinnj: That's unfortunate. If you're just starting out hitting the documentation for the SDK is probably a better jumping off point than grabbing some random application that's not bundled for use on your phone. Jun 24 18:30:53 NTinNJ: The problem is that VBS is generally interpreted (if run standalone), like JavaScript (which is not the same as Java). You can't run JavaScript on Android without an interpreter either, it's just convenient that all browsers support JavaScript, so JavaScript-powered apps just wrap themselves with a browser component to run properly Jun 24 18:31:13 fjornir: They said it was find for the droid, course that was before they got my money, after that, no response from them. Jun 24 18:31:27 NTinNJ: who said that? Jun 24 18:31:33 And what did they say Jun 24 18:31:35 mrxsystem.com Jun 24 18:31:59 the app is called Mr. Tracker. Jun 24 18:32:18 Runs on all smartphones pretty much. Jun 24 18:32:38 Does anyone know what version of Java you need to run Android? Jun 24 18:33:01 NTinNJ: Well, I don't know what to tell you about what 'they' said. However if you are interested in developing for the android platform (which is the topic of this channel - this is not the mrxsystem.com support channel) then the SDK documentation is a good starting point. Savy? Jun 24 18:33:25 fjornir: nice, loved the tail portion Jun 24 18:33:55 fjornir: Yes, I understand, but all my questions will apply to all my future ideas that I have, I am just using this 1 app as a starting point. Jun 24 18:34:24 So wait.. you are using an app, you arent developing anything, and you are complaining? Jun 24 18:34:48 Ntinnj: Again, grabbing some random app that is not bundled up for your phone is not the appropriate starting point for android development. For development you should start with the SDK documentation. Do you understand? Jun 24 18:35:04 drpenguin: No, I am using the app as a starting point for what I want to develop, in other words, improve on a concept. Jun 24 18:35:58 NTinNJ: OK, first off, thats just wrong. Secondly.. how are you doing this? Is the source available? Did you just decompile it? Jun 24 18:36:09 drpenguin: Think of it like this, you created the rotary dial phone, I want to take that technology and make a touch-tone phone. Jun 24 18:36:31 class: http://pastebin.com/UfT6n8kQ / R.layout.splash_screen: http://pastebin.com/iALvhzpd => may the inflater.inflate method corrupt somehow the fragment so that it won't replace correctly? Jun 24 18:36:51 NTinNJ: Right.. but presumably you would have some experience in the background to be able to do that, and to me, it sounds like you dont for this instance Jun 24 18:37:10 Ntinnj: Excellent. There's a ton of room for improvement in the mobile application space. Reading the documentation for the SDK of the platform you are targeting is the way to get started on engineering those improvements. Does that make any sense to you at all? Jun 24 18:37:53 drpenguin: It is not wrong, it is the kind of concept of buiding a better mousetrap and people will beat on your doors. Something thought of this before, geeky guy who saw a mac and came up with the idea of "Windows" Jun 24 18:38:38 fjornir: Yes, it absolutely does, I have read the SDK stuff, unfortunately I am beginning to believe the app I bought is just a scam. Jun 24 18:38:43 NTinNJ: And hows that working out for you? Its not, but you blame the system for it not working Jun 24 18:39:02 building* Jun 24 18:39:42 don't worry if the app you bought is a scam Jun 24 18:39:48 since you improve on the _concept_ Jun 24 18:40:01 Hey guys, was wondering if anybody could help me out with this animation bug I'm having.. Hope its alright if I just link the stackoverflow thread as its got the code in there as well: http://stackoverflow.com/questions/11171304/android-animation-bug-after-making-spinner-look-like-a-button Jun 24 18:40:11 drpenguin: No I do not blame the system, I just feel it is not as logical as it should be. Who knows, maybe this leads me to build a better mousetrap on the phone concept as well. Jun 24 18:40:14 I think we're going a little bit off topic - if you want to discuss about *scam* please go to speak @ #android Jun 24 18:40:29 elegos: we arent, try to follow the conversation Jun 24 18:41:01 NTinNJ: and how should it be? Who are you to say "no, this is wrong, it should be this way" Jun 24 18:41:49 hello there, I need a little hand in here Jun 24 18:42:11 I'm having trouble debugging my NDK app, I can't seem to get any useful information out of ndk-gdb Jun 24 18:42:30 johnnyonflame: what seems to be goin on? Jun 24 18:42:51 the application force closes Jun 24 18:43:03 drpenguin: I have always believed in the KISS theory sortof. Keep It Simple Stupid, but also give the user power to make it more complex. Intuitive programming is what I believe in. When you type in Google say "Preg" google will suggest "Pregnancy" or something. Intuitive! (OK, maybe not the best example, but you get it.) lol Jun 24 18:43:15 johnnyonflame: riiiight.. so what are you getting out of ndk-gdb that you arent understanding? Jun 24 18:43:50 NTinNJ: and what isnt intuitive about android, a platform I am not convinced you really are keen on there pal? Jun 24 18:44:06 ntinnj: Great. Engineer something super KISS. The documentation for the SDK would be a great place to get going if you want to do that on android. Jun 24 18:44:15 drpenguin, first, I'm getting a "0xafd0c57c in epoll_wait () from /home/johnny/android-sdl/project/obj/local/armeabi/libc.so" Jun 24 18:44:50 johnnyonflame: Well, knowing gdb, I *think* that may be the line number where you are inside that function in that lib Jun 24 18:45:14 johnnyonflame: Let me stop ya for a second, have you compiled your bins with debugging symbols? Jun 24 18:45:30 drpenguin: To be honest, no I am not, and that may be unfair of me considering I am so new to it, however, that being said, it does seem very restrictive and controlling on the Google side of it with regard to the market place. I get the impression (AND I MAY BE INCORRECT) that if you are not in bed with Google, there is a problem. Jun 24 18:45:40 I'm not sure about that- NDK is not making much sense for me Jun 24 18:45:52 if I got to compile a few apps and run them, it was pure luck Jun 24 18:46:00 can I create a subfolder inside the res/layout one? Jun 24 18:46:25 johnnyonflame: heh, im not too keen on NDK either, I just know C, let me take a peek around this stuff.. from what I understand, there is some .mk file (Ithink Android.mk?) that you use to compile your code.. am I right? Jun 24 18:46:39 no Jun 24 18:46:47 It's compiling with Scons Jun 24 18:47:18 that's where the fun begins, I'm not using the usual procedure for compiling Jun 24 18:47:39 hmm.. well scons should have a way to compile debug symbols into the bin if it isnt already.. do you know how to use gdb? Jun 24 18:48:06 had some fun with it in the past Jun 24 18:48:14 -ggdb 'n pray Jun 24 18:48:52 What's the best practice for displaying a complex heirachy radiogroup? Jun 24 18:49:20 it -SHOULD- have build it with debugging info Jun 24 18:49:31 and the answer to my question is... Jun 24 18:49:32 johnnyonflame: hmm.. well looking online, however this is with Android.mk and gcc, it seems to strip debug symbols even when compiled with em.. im not sure what scons is doing.. how do you tell scons to compile your stuff? Jun 24 18:49:55 huge command-lines Jun 24 18:50:04 so you are doing it manually? Jun 24 18:50:05 I mean, huge env variables* Jun 24 18:50:44 are you familiar with Pelya's SDL Port? Jun 24 18:51:12 I am not familia with Pelya Jun 24 18:51:43 elegos: having just tried it for you, it appears not Jun 24 18:52:04 it seems to build two packages, one that SHOULD Have debugging symbols, and the rel one Jun 24 18:52:05 :( any way to divide elements from others? Jun 24 18:52:11 At least the Eclipse auto-complete doesn't recognise the subdirectory Jun 24 18:52:13 I am, met Pelya in Brazil, she was amazing! (J/K sorry couldn't resist.) lol Jun 24 18:52:39 elegos: divide in which way? with a horizontal divider? Jun 24 18:52:58 NTinNJ, I don't think I follow you on that Jun 24 18:53:02 johnnyonflame: what are the package sizes if you compaer em? Jun 24 18:53:14 elegos: or do you mean in the file structure? Jun 24 18:53:22 johnnyonflame: just a joke Jun 24 18:53:33 5.3mb and 7mb Jun 24 18:53:35 dsample: no, I mean divide layouts from single elements (for example items for a listview) Jun 24 18:53:41 most of the size -should- be the app data Jun 24 18:53:45 The 7 meg guy should be the one with debug syms Jun 24 18:53:45 dsample: yes, file structure Jun 24 18:54:51 oh wait Jun 24 18:54:56 it seems to have created a log file Jun 24 18:54:56 I need my application to make sure a user is in a specific location radius, At the moment I'm targetting android 3.0 and above but will probably make it android 2.3.3+. Which google APIs should I use? Or does it not make a difference? Jun 24 18:55:00 elegos: I don't know if it's 'best practice' but I name all of my layout files with heirachy names with underscores Jun 24 18:55:20 dsample: yes, it seems to be the unique way Jun 24 18:55:55 elegos: so I would have _listview.xml and _listitem.xml Jun 24 18:56:03 yep Jun 24 18:57:47 I GOT IT Jun 24 18:57:49 YEAAAAAAAAAAAAAAAAHHHHHHHHHH Jun 24 18:57:53 :) Jun 24 18:58:00 >:) Jun 24 18:58:06 ._.; Jun 24 18:58:14 mine seems a happy bug ahahaha Jun 24 18:58:28 I found a random logfile floating around, and it said: "WHERE THE HELL ARE THE DATA FILES" Jun 24 18:58:43 seems like that SDL Port does crazy stuff with the folders, so I did a few changes and bam Jun 24 18:59:09 ndk-gdb seems to not like console output of any sort Jun 24 19:05:49 i'm stucked with this xml parsing... i freak out.I tried so many examples and tutorials that i totaly mis it. Jun 24 19:07:37 i created a pastebin, i'm sure one of you could point me out Jun 24 19:07:44 whats up wHiTeHaT44, ive gone through that joy a few weeks back Jun 24 19:07:58 and which xml parser are you using? Jun 24 19:08:06 i use dom parser Jun 24 19:08:15 cool, thats one i used.. whats the pastebin? Jun 24 19:08:20 the xml is verry small Jun 24 19:08:37 http://pastebin.com/FAMRKSaD Jun 24 19:08:43 and whats the issue? Jun 24 19:08:57 i want the xml result as array Jun 24 19:09:19 the array is called in line 71 Jun 24 19:09:28 why an array? Jun 24 19:09:39 for now i only managed to get array from resources folder... Jun 24 19:09:40 be better to use an arraylist Jun 24 19:09:48 lemme send you some of my code hang on.. Jun 24 19:10:03 no wait... the content is readed internal Jun 24 19:10:19 i not show the xml content Jun 24 19:10:29 i use the content in another function Jun 24 19:11:20 ok.. id start by using a string arraylist Jun 24 19:11:44 if its strings youre parsing Jun 24 19:12:09 then you can pass that arraylist into a listview or however else youre using the information Jun 24 19:12:15 wHiTeHaT44: You should write a stupid Java console application that parses your XML. Then, just plug the same logic into your Android app. Jun 24 19:12:28 Just read the document off the SD Card using the snippet Is sent you yesterday. Jun 24 19:13:02 i parsed it Jun 24 19:13:05 aye what Chronax said, and rather than have it as an activity, use asynctask to start up the xml parser (providing the url is pre-determined) Jun 24 19:13:07 i used dom parser Jun 24 19:13:07 Did any of you notice the app crashing because a WebView is displaying a specific string? http://code.google.com/p/android/issues/detail?id=33612 (I only noticed on two HTC devices) "F//system/bin/app_process( 3983): stack corruption detected: aborted" Jun 24 19:13:36 wHiTeHaT44: So write something that turns your XML into an array. Jun 24 19:13:50 Then recycle that logic in something like an AsyncTask in your Android implementation. Jun 24 19:14:01 yeah that is the Q Jun 24 19:14:58 put it into an arraylist.. Jun 24 19:15:06 not sure why you want it in a string array Jun 24 19:15:39 development 101: I have an onclick button event, which calls a function AddStuff.. within that is: EditText etQuantity = (EditText)findViewById(R.id.etQuantity); and Log.d("add",etQuantity.getText().toString()); but nothing is being logged Jun 24 19:15:41 it loads websites one by one in a webview Jun 24 19:16:03 you can still use an arraylist for that though.. Jun 24 19:16:05 i know the button is being pressed because i have a Log.d before that line that says "button pressed" which shows in the log Jun 24 19:16:48 well, it is, i dont now how or where to go anymore Jun 24 19:17:16 use a for loop and then arraylistName.get(i) Jun 24 19:17:28 i certainly mis basics/expertise Jun 24 19:18:14 anything i might be missing? Jun 24 19:19:37 JaredCE, i know nothing get slogged when the string value is null.. so maybe that? Jun 24 19:19:55 does getText() not return a string anyway? Jun 24 19:21:08 ahh you're right nothing get's logged when it's empty Jun 24 19:22:26 finally :) http://datumedge.blogspot.co.uk/2012/06/java-8-lambdas.html Jun 24 19:27:24 I setup a sim to be a kindle fire -- dpi is 169 -- but when I fetch xdpi and ydpi, they're both 160.. is this normal Jun 24 19:30:15 yes, the DPIs are bucketed Jun 24 19:31:06 well according to the docs, the dpi property of DisplayMetrics should be bucketed Jun 24 19:31:16 " Jun 24 19:31:16 Since: API Level 4 Jun 24 19:31:16 The screen density expressed as dots-per-inch. May be either DENSITY_LOW, DENSITY_MEDIUM, or DENSITY_HIGH. Jun 24 19:31:20 whooops my b Jun 24 19:31:35 but not xdpi and ydpi "The exact physical pixels per inch of the screen in the X dimension." Jun 24 19:32:27 I was told never to rely on those as actual values since they're not enforced Jun 24 19:32:35 hm Jun 24 19:32:41 do you know of any way to get the physical size of the screen in inches? Jun 24 19:32:57 i did a quick google and saw some people who said to use xdpi and ydpi Jun 24 19:37:02 not exactly, no. I bet you can still use pixels/dpi for a fairly accurate assessment of 98% of devices Jun 24 19:37:14 Things like the O.G. Galaxy Tab and Dell Streak might give you wild values though Jun 24 19:38:53 hi JakeWharton Jun 24 19:39:08 hello cow Jun 24 19:39:34 how goes Jun 24 19:44:54 good, about to go grab food and put out a NOA release Jun 24 19:44:59 need to do laundry Jun 24 19:45:11 glad you're still alive Jun 24 19:47:24 Is there a better way to manage a group of radio buttons without a radiogroup? All I can think of is to use a For loop to go through all of the possible radio buttons and uncheck them when another one is checked, and it feels wrong and slow Jun 24 19:48:39 it's not that slow Jun 24 19:48:47 unless you have oodles of buttons Jun 24 19:49:43 for (int i = getChildCount() - 1; i >= 0; i--) { getChildAt(i).setChecked(i == selectedIndex); } Jun 24 19:49:52 JakeWharton: How would I even find the other buttons? I don't create unique IDs for them (I use ids.xml) Jun 24 19:50:21 JakeWharton: It's not that simple for me, my radiobuttons are each inside a relativelayout Jun 24 19:50:38 so find them and store them in a View[] Jun 24 19:50:49 the loop over that when one changes Jun 24 19:51:29 Can I store them without issues? Wasn't sure if it would break anything if I stored it and used it later (like I tried with Menu) Jun 24 19:52:19 JakeWharton why would i not be alive? Jun 24 19:52:26 im not sure if SimonVT is alive, but i am Jun 24 19:53:10 sure you can store them. you should be able to hold on to a Menu (and MenuItems) as well Jun 24 19:53:25 granted, calls to invalidateOptionsMenu will recreate the items Jun 24 19:55:06 JakeWharton: well, I tried to hold onto the Menu from onCreateOptionsMenu so I could change it later, but I got errors whenever I touched it. But then I found onPrepareOptionsMenu and I could do what I wanted in there (checkbox on menuitem) Jun 24 19:56:29 JakeWharton: which is why I thought the way I was doing the radiobuttons was some kind of crappy way, I would have preferred to use a RadioGroup and have it managed for me, but I can't seem to do that if the subitems of the RadioGroup aren't RadioButtons, but are instead MyRowView objects with a RadioButton inside Jun 24 19:56:49 what is the right way to stop a thread in android? .stop is deprecated Jun 24 19:57:16 JakeWharton: I thought there would be a way of linking a RadioButton to a group rather than the other way round Jun 24 20:09:06 do you guys know of a disclaimer that makes it very clear the user is responsible for their use of the software Jun 24 20:10:28 i suppose i could write one up... Jun 24 20:10:37 famous last words? Jun 24 20:15:37 parco: take the parts of a decent eula you need http://www.developer-resource.com/sample-eula.htm Jun 24 20:15:49 g00s, thanks just found that Jun 24 20:16:04 ...and then run the result past a lawyer. Jun 24 20:16:13 there is even a class that will show it the first time the app starts http://blog.donnfelker.com/2011/02/17/android-a-simple-eula-for-your-android-apps/ Jun 24 20:16:38 i thought there was a blog on this in the android website, can't find it now Jun 24 20:16:43 can't find shit actually Jun 24 20:17:59 not really sure how i feel about the new website Jun 24 20:18:02 change is good i guess Jun 24 20:18:17 i'm glad apple didn't make their website look like an iphone Jun 24 20:18:56 thats a damn nice site Jun 24 20:19:13 geniuses of design those guys Jun 24 20:21:26 whoa whoa my $3/day only gets me 200MB of "4G speed" per MONTH??? Jun 24 20:22:04 canadiancow: Moo, eh? Jun 24 20:23:06 canadiancow: i hope you are avoiding Tifton 85 grass for munching Jun 24 20:25:03 basically Jun 24 20:25:03 you guys Jun 24 20:25:07 note to self: never download a CM9 nightly on a 200MB limit Jun 24 20:25:36 anyway im out Jun 24 20:27:15 take care Jun 24 20:30:50 I just got an emulator crash Crashed Thread: 5 Exception Type: EXC_BAD_ACCESS (SIGSEGV) Exception Codes: 0x000000000000000d, 0x000000000000000c Jun 24 20:37:50 whats the best way to put the value from numberDecimal into a BigDecimal? Jun 24 20:38:43 new BigDecimal(numberDecimal); ? Jun 24 20:40:28 i mean getting the value from an editText thats formatted to be numberDecimal Jun 24 20:42:28 doesn't something like new BigDecimal(editText.getText().toString()) work? Jun 24 20:42:33 looks like String>Float>BigDecimal Jun 24 20:42:54 How do I debug a crash that happens on remote device? Jun 24 20:43:09 As in one I can't hook a debugger up to or dump a log from? Jun 24 20:43:15 adb logcat Jun 24 20:43:20 if it is on your phone Jun 24 20:43:28 connected via usb Jun 24 20:43:51 spuz: Is your app in the Google Play store? Jun 24 20:43:59 dsample, no Jun 24 20:44:08 perhaps you can just report the crash to your google play store and view the report in the console Jun 24 20:44:12 spuz: ok, so you can't use the crashes reported there Jun 24 20:44:30 spuz: consider downloading something like "aLogCat" Jun 24 20:44:35 it might output the error Jun 24 20:44:42 and install it on the phone Jun 24 20:44:57 https://play.google.com/store/apps/details?id=org.jtb.alogcat Jun 24 20:46:07 anyone here know intellij IDEA good? Jun 24 20:46:22 luyang, thanks Jun 24 20:46:30 for some reason every time i build and install my games apk and launch it on my physical device it tells me its waiting for the debugger to connect Jun 24 20:46:31 spuz: good luck… Jun 24 20:46:33 it never used to do taht Jun 24 20:46:37 what did i fsck up? Jun 24 20:47:02 it does that if you launch the program from debugging in an IDE Jun 24 20:47:09 nope Jun 24 20:47:17 what Jun 24 20:47:21 luyang, hang on it looks like alogcat just displays your logs Jun 24 20:47:24 i did a build, then i typed adb install -r /blahblbha.apk Jun 24 20:47:27 that's not to useful for me Jun 24 20:47:36 then i launched the apk and got "waiting for debugger to connect" Jun 24 20:47:36 I thought that's what you wanted… sorry Jun 24 20:48:08 My app is running on my brother's phone Jun 24 20:48:14 how can i make my apk NOT wait for the debugger to connect after i manually install it and run it on my phone? Jun 24 20:48:16 so ideally I need him to send me the log Jun 24 20:48:21 not sure how alogcat does that Jun 24 20:48:37 I think there is some built in feature to send a log but not 100% sure Jun 24 20:49:05 spuz: "Share logs via any application that handles plain text or HTML sharing, including Gmail, Email, Pastedroid, Bluetooth, and others." Jun 24 20:49:27 hmm Jun 24 20:50:01 anyone? Jun 24 20:50:15 i cannot run my apk unless im connected to the debugger. what did i change? Jun 24 20:52:53 anyone? this is driving me crazy! Jun 24 20:55:29 I440r: why did you have to install the app via adb install? not just open the apk from a file manager on the device? Jun 24 20:55:46 I'm trying to figure out why a fragment is not being replaced, but instead the new one will be appended to the end of the layout of the 1st. This is the original fragment class: http://pastebin.com/WLbEQHhG (it has a grid layout with a linear layout with 3 textviews and an imageview). And this is the code which is supposed to replace the fragment: http://pastebin.com/1mjhMFQx Jun 24 20:55:55 because i just buit it ? Jun 24 20:56:00 so its not ON the device Jun 24 20:56:04 adb install -r <-- reinstall Jun 24 20:56:56 every time i try launch my freeking app it says its waiting for the fucking debugger to connect :( Jun 24 20:57:05 what the fsck did i fsck up here? Jun 24 20:57:06 I440r: do you have   Jun 24 20:57:38 or wait "First, Set debug="false" in manifest.xml, and uninstall application from your device and reinstall it. It will work" Jun 24 20:57:41 i did not change anything in that file. ive not touched that file. Jun 24 20:58:01 http://stackoverflow.com/questions/5937369/application-on-device-waiting-for-debugger Jun 24 20:58:13 ive been switching back and forth between debugging on the device and running without the debugger for WEEKS Jun 24 20:58:18 with the SAME fucking build Jun 24 20:59:09 I440r: check Settings > Developer Options Jun 24 20:59:20 there you can specify the name of the package that will wait for the debugger to be attached Jun 24 20:59:26 make sure it's set to none Jun 24 21:00:01 example of my problem: https://dl.dropbox.com/u/1512702/tmp/1st_fragment.png https://dl.dropbox.com/u/1512702/tmp/2st_fragment.png Jun 24 21:00:10 note that the 2nd fragment is being appended to the 1st one Jun 24 21:00:11 romainguy, i dont have a settings menu. i have a file->settings but that doesnt have a developer options Jun 24 21:00:19 the next ones will still stay in the corner Jun 24 21:00:28 (i.e. not infinite nest) Jun 24 21:00:32 I440r: on the device Jun 24 21:00:36 oh Jun 24 21:00:40 and/or emulator Jun 24 21:01:33 dont seem to have a settings->developer options on the phone iether Jun 24 21:01:56 what version of the OS ? Jun 24 21:02:04 it might be in settings > apps > developer Jun 24 21:02:12 2.3.4 Jun 24 21:02:50 that has 3 itmes. usb debugging, stay awake and allow mock locations Jun 24 21:02:58 only the first is checked. that stays checked Jun 24 21:03:08 ah then install the devtools apk from the SDK Jun 24 21:03:11 thats not the problem, thats been checked for ever. ive never had that unchecked Jun 24 21:03:16 any idea on my problem? :\ I tried even creating the layout programmatically, without any success Jun 24 21:03:30 theres a devtools apk?! Jun 24 21:03:44 romainguy_: does the devtools apk work on all phones ? Jun 24 21:03:47 ok ive never had that installed. what did i change to make my apk ALWAYS wait on debugger? Jun 24 21:03:53 g00s: it should yes Jun 24 21:03:55 i never even tried it. i saw it on the emu i think ... Jun 24 21:04:09 yeah you can see it in the emu Jun 24 21:04:59 romainguy, ive been switching back and forth between debugging my apk on my phone and running it sans the debugger with NO connection to the pc at all Jun 24 21:05:04 something changed somewhere... where? Jun 24 21:05:11 the way the apk is being built? Jun 24 21:05:23 i.e. "build this apk for debug only" ? Jun 24 21:05:53 ok, simplier question: how can I remove a fragment? There's the transaction.remove(Fragment theFragment), but I should cycle through all the attached fragments, how can I see a list of them? Jun 24 21:07:37 I440r: have you tried to completely uninstall the app first and then install it again? Jun 24 21:08:33 yes Jun 24 21:10:43 what do you think guys http://j.mp/Ltbvfa http://j.mp/LtbBn8 Jun 24 21:10:59 Is there an issue with onKeyDown and multitouch? Jun 24 21:12:16 if i check if the menu button has been pressed down, and i have another finger on the screen, nothign happens Jun 24 21:13:48 is there any chance to get help about a stupid fragment? I read and read again the Fragments docs, still I don't have a solution. As you may have already read in this chat, I can't successfully replace a fragment with another: it will append the new one to the original one. These are the sources: https://dl.dropbox.com/u/1512702/tmp/ROM%20Updater%202.0.rar Jun 24 21:14:10 ActionsListFragment.java will handle the change (onListItemClick) Jun 24 21:15:38 (layout-large) Jun 24 22:02:48 i've created this http://pastebin.com/KGSghvxR where addItem is an onclick event from a button, but i can't but feel this is a little bloated. can i write this better. dealTwo inherits from deal Jun 24 22:03:42 you could get rid of bErrors if you did an if-else if-else Jun 24 22:04:25 and the return thing is useless Jun 24 22:05:49 ok cool Jun 24 22:06:45 also.. your classes should begin with a capital letter Jun 24 22:07:09 oh really? Jun 24 22:07:25 and consider putting the code in Eclipse and auto-format it using Control-Shift-F Jun 24 22:07:42 the indentation is bananas Jun 24 22:08:07 etc Jun 24 22:08:19 it is in eclipse Jun 24 22:08:30 i think it was me messing around in pastebin Jun 24 22:08:35 have you tried Control-Shift-F Jun 24 22:09:36 and also you cannot return in a void method Jun 24 22:09:41 your code simply doesn't compile Jun 24 22:09:51 I mean you cannot return an object Jun 24 22:10:05 yeah i forgot to add in the return before i stuck it in pastebin Jun 24 22:10:24 seems rather sloppy to me Jun 24 22:10:54 mainly i was wondering if i was doing too much in addItem and need seperating some more Jun 24 22:10:54 gotta go (good night) Jun 24 22:13:24 JaredCE: let me offer some advice, whether there is "too many" statements in a function is questionable.. I have heard soooo many computer programming rules over the years Jun 24 22:14:36 things like, if your program is more than a page, then you should split it up, your function should only be x long, blah blah blah.. how I feel is that a function is as long as it needs to be, as long as its doing what it its meant to do. if you have a function doing multiple things, not what its signature alludes to it doing, then you might wanna split it up, but it all to your coding style Jun 24 22:19:31 Hello, How I set view y position with canvas below zero? I have overrode the onDraw method. But if I example set canvas.translate(0, -10); it is at 0,0 position Jun 24 22:20:15 ArGGu^^: from what I remember, 0,0 is the top left most pixel of your screen, going down and to the right increases the coordinate, so -10 isnt valid Jun 24 22:20:33 negative coordinates are perfectly valid Jun 24 22:20:53 then ignore what I said Jun 24 22:21:00 if you translate to -10 and draw something 20 pixels high, you'll see the bottom 10 pixels of what you drew Jun 24 22:21:08 but the origin 0,0 is indeed the top left Jun 24 22:21:19 partially right, good enough! Jun 24 22:21:49 romainguy_ I have tried that but it won't work Jun 24 22:22:08 what are you trying to do? Jun 24 22:22:12 thanks for correcting me romainguy_, I hate going by misinformation Jun 24 22:25:16 romainguy_ Ignore what I just said, I realised that I'm either too tired or idiot Jun 24 22:48:29 romainguy: i think the sensor in my camera has an issue. i have a 3x3 area always pegged red Jun 24 22:48:53 i guess in a p&s thats probably the end ? Jun 24 22:51:57 g00s: Depends on if you can consistently place that 3x3 area somewhere artistic in the shots you take. Jun 24 22:52:37 hmm, yeah i guess like lens flair. its so hard to see on the lcd during the day Jun 24 22:57:24 I read and read again the Fragments docs, still I don't have a solution. As you may have already read in this chat, I can't successfully replace a fragment with another: it will append the new one to the original one. These are the sources: https://dl.dropbox.com/u/1512702/tmp/ROM%20Updater%202.0.rar ... ActionsListFragment.java will handle the change (onListItemClick) Jun 24 22:59:53 example: https://dl.dropbox.com/u/1512702/tmp/1st_fragment.png https://dl.dropbox.com/u/1512702/tmp/2st_fragment.png Jun 24 23:01:48 elegos: protip: make sure the links you provide work, and don't put your sources in a rar in dropbox :X Jun 24 23:02:58 I always download random RAR archives from dropbox with things like ROM in the name. Jun 24 23:03:21 g00s: 2nd: https://dl.dropbox.com/u/1512702/tmp/2nd_fragment.png Jun 24 23:03:55 and this is a ZIP: https://dl.dropbox.com/u/1512702/tmp/ROM%20Updater%202.0.zip Jun 24 23:03:59 fjornir: heh, yeah Jun 24 23:04:07 oh, a zip is much better Jun 24 23:04:09 * g00s facepalm Jun 24 23:04:23 and no fjornir, it's not for game ROMs Jun 24 23:04:38 For google play. Can you have a app unlisted on their marketplace. But you can download it if you know the exact name? Jun 24 23:04:53 sirellyn: i like that idea Jun 24 23:04:55 g00s: lens *flair*? :))) Jun 24 23:05:15 I'm trying to setup an in app purchase. But not have like 4 versions of the app on the google marketplace. Jun 24 23:05:49 sirellyn: the whole point of in-app purchases is to keep things internal, and off the market Jun 24 23:06:49 g00s: btw it's just a graphic interface, no libraries are in of course Jun 24 23:06:54 romainguy_: "Lens Flair" sounds like the perfect name for an app that makes every photo look like J.J.Abrams took the shot. Jun 24 23:06:55 I'm not _that_ stupid Jun 24 23:07:01 Ok, well I'm thinking of using Prime31's in App Billing plugin Jun 24 23:07:25 and it looks great, but I need to make sure what it downloads isn't listed in the google play store. Jun 24 23:07:37 otherwise you "buy" chapter 3 before you buy chapter 2 for example. Jun 24 23:07:45 which would really screw everything up. Jun 24 23:07:50 oh, flare :/ Jun 24 23:08:20 sirellyn: not sure about Prime31, i used this https://github.com/robotmedia/AndroidBillingLibrary Jun 24 23:09:01 taking a look. And thanks parco Jun 24 23:09:16 hey np Jun 24 23:09:28 I should have stated I'm using unity Jun 24 23:10:39 How can I copy /data/data/com.android.providers.telephony/databases/mmssms.db to the /sdcard ? :S Jun 24 23:11:03 I can't figured out how I can do it.. The only files that I can export are the databases from my packages Jun 24 23:14:30 parco, as a straight out questions, you can't "hide" an app from the google market list can you? Jun 24 23:14:42 sirellyn: not that i know of Jun 24 23:14:47 ok. Thank you Jun 24 23:16:28 drpenguin, i have only just seen your advice. thank you Jun 24 23:17:12 JaredCE: np Jun 24 23:28:20 is the settings section of android a list view? Jun 24 23:28:48 Pre 3.x Looks like it, post 3.x its probably List Fragments with other fragments Jun 24 23:29:50 hmm. i Have a linear layout thats basically just a form, when my users click a button i want a listview-esque thing to appear under the form that contains their inputted data Jun 24 23:30:16 does that make sense and would i be right in thinking i should use listview Jun 24 23:39:42 or would i want a scrool view? Jun 24 23:50:39 Hello! Jun 24 23:50:41 alta? Jun 24 23:50:44 From esper? Jun 24 23:51:06 what? Jun 24 23:51:15 Just thought I recognized someone Jun 24 23:51:18 Guess not. Jun 24 23:52:00 I get this error http://pastebin.com/fQ8ZgATY when I try to launch my app on the emulator Jun 24 23:52:42 SandboxActivity, line 29 Jun 24 23:55:27 Alright. Jun 24 23:56:40 so? Jun 24 23:57:39 Sicp, 29 is setText for a TextView Jun 24 23:57:56 can you paste the code to see? maybe I can find Jun 24 23:58:26 Ok, keep in mind I'm just playing around and anything doesn't represent any kind of product or usable application Jun 24 23:58:47 yea, I'll keep that in mind.. Jun 24 23:59:55 Here's what I'm messing with http://pastebin.com/M4R0D0Rw Jun 25 00:00:18 Trying to use IRC protocol, I'm probably doing it completely wrong in onCreate Jun 25 00:01:36 from that code, move lines 41 and 42 to the top of onCreate Jun 25 00:02:02 Done. Jun 25 00:02:14 don't define the textview in onCreate Jun 25 00:02:58 Done. Jun 25 00:03:21 try Jun 25 00:03:26 Also put your internet communication stuff in a thread, this is going to get Android to force close your app. Jun 25 00:03:41 yea, no connection on the UI thread Jun 25 00:03:44 Ok Jun 25 00:03:54 Yeah you can probably tell I'm new to this. Jun 25 00:04:11 http://developer.android.com/reference/android/os/AsyncTask.html Jun 25 00:04:31 JakeWharton: hey, if your there, I could use some help.. I just resetup a dev environment for Android, I go to include ABS but my project wont build, says it cant find the com_actionbarsherlock.jar...All I did was make a new project, set it to 4.0.3 build target, included v4 support jar, and added your project to it as a library Jun 25 00:04:41 You can probably bend that to something that uses onProgressUpdate to update the UI (i.e. call publishProgress for every line received). Jun 25 00:04:48 also don't declare any of the views inside onCreate, just initialize them there Jun 25 00:04:55 drpenguin: make sure "Is Library" is checked on the ABS project Jun 25 00:04:56 ah Jun 25 00:05:08 JakeWharton: it is by default Jun 25 00:05:53 dunno then. there's a bunch of StackOverflow posts with the same problem Jun 25 00:05:55 you're trying to write IRC client, langkid1 ? Jun 25 00:05:58 I don't use Eclipse so i've never seen it Jun 25 00:06:05 Also, not sure if you're doing this for fun, but there's quite a few IRC libraries for Java that make things much easier. Jun 25 00:06:16 Sicp, an IRC client that is the base for something else Jun 25 00:06:31 JakeWharton: its weird, I was literally just using ABS the other day on Fedora 16 with eclipse, now I am latest Arch Linux and its poopin out Jun 25 00:07:09 something else thats weird.. if I clean your project, i get a bunch of errors Jun 25 00:07:22 using JDK 1.6 compliance? Jun 25 00:07:37 project properties > java compiler Jun 25 00:07:49 see if this helps, langkid1 - https://github.com/Odaym/Rachat - it's a very minimal IRC client written in Racket, but the standards from the RFC of IRC protocol are all there Jun 25 00:07:54 does any of you speaks arabic here? Jun 25 00:08:05 the regexp's that define which messages are private, which ones deal with connectivity, etc.. Jun 25 00:08:16 Thanks! Jun 25 00:08:38 JakeWharton: hmm.. I was using jdk7, arch by default grabs the latest, but I remove dit and added openjdk-6, changed the compliance level, still nothing, let me reopen eclipse Jun 25 00:08:44 Pleasure talking with you! Jun 25 00:10:25 you can see how it works, http://dl.dropbox.com/u/19390574/Ra-chat%20-%20Windows.zip - this one is for Windows Jun 25 00:11:24 JakeWharton: nope, doesnt work, man this is a pita (this in general, not ABS, love your thing) Jun 25 00:11:45 I speak arabic, romainguy_ Jun 25 00:12:28 may I send you a private message please? Jun 25 00:12:31 sure Jun 25 00:12:35 thanks Jun 25 00:12:52 JakeWharton: oh wait, there we go, banging on it enough made it give up and want to work, thanks Jun 25 00:12:58 haha Jun 25 00:13:01 beat Eclipse into submission Jun 25 00:13:22 Eclipse is to Scheme, as cleans are to parenthesese Jun 25 00:14:12 Something like http://martyr.sourceforge.net/ handles IRC on a much higher level, so you don't need to worry about the protocol a lot. Jun 25 00:14:44 hey that's nice Jun 25 00:20:51 http://jerklib.sourceforge.net/ looks nice as well. Jun 25 00:20:56 Man who comes up with those names Jun 25 00:21:36 Thanks just gotta read those licenses Jun 25 00:22:44 Hey folks Jun 25 00:22:51 can somebody take a look at this : http://stackoverflow.com/questions/11173927/android-activity-dims-looses-focus-and-freezes-no-error-messages-and-works-af Jun 25 00:22:57 suggestions would be awesome Jun 25 00:24:12 I've had that Jun 25 00:24:17 every first-time Jun 25 00:24:39 really>! Jun 25 00:24:46 did you get to the bottom of it? Jun 25 00:24:57 it's a race condition that happens in my case Jun 25 00:25:09 and I still suffer from it, but I haven't gotten around to fixing it yet Jun 25 00:25:14 http://developer.android.com/tools/help/adb.html#logcat don't guess, see. Jun 25 00:25:27 what is the race condition Jun 25 00:25:29 (or use the thingy for that in Eclipse) Jun 25 00:25:50 the SSH connection and a function that depends on it needing to be called on launch Jun 25 00:26:11 the function comes up empty-handed because of the connection not having been established yet Jun 25 00:26:28 causes the loader to just keep loading Jun 25 00:26:45 and no error messages, no nufin Jun 25 00:26:52 well i dont see wot my race condition is Jun 25 00:26:56 can you take a look at the pastebin i left Jun 25 00:27:00 it doesnt look like a race condition Jun 25 00:27:39 look for ctate or SimonVT concerning this :P Jun 25 00:27:56 I could take a look Jun 25 00:30:33 thank you penguin Jun 25 00:30:38 did yuou get the link on my post? Jun 25 00:31:24 no Jun 25 00:31:30 you say that the activity starts and in onResume() does some work in the background? Jun 25 00:31:54 I may not know anything, but I do know that background work means AsyncTask, and you don't have that there Jun 25 00:32:17 You cn do it with asynctask - or you ccan do it my way Jun 25 00:32:34 http://stackoverflow.com/questions/11173927/android-activity-dims-looses-focus-and-freezes-no-error-messages-and-works-af Jun 25 00:32:38 for drpenguin Jun 25 00:32:41 but consider that the activity is being started for the first time, why would onResume be called? Jun 25 00:33:20 onresume is ALWAYS called Jun 25 00:33:24 after oncreate Jun 25 00:33:27 give me a minute.. i am trying to download vmware workstation again but its being a pita Jun 25 00:33:32 np Jun 25 00:33:34 Try using showDialog/dismissDialog Jun 25 00:33:40 i am using that! Jun 25 00:33:48 Manually managing dialogs is always bad Jun 25 00:33:53 No, the activity methods Jun 25 00:34:24 renegadeandy: yeah.. I dont know what it is.. I already own it, but its not letting me get a download link Jun 25 00:34:35 aha! it's always called after onStart() not onCreate()! :P Jun 25 00:34:49 but yea, my bad. Jun 25 00:34:58 dismissDialog (int) - how do i get the int of the dialog :S? Jun 25 00:35:09 you just give it a number Jun 25 00:35:27 renegadeandy: *face palm* DERP! shoujlda scrolled down more.. Jun 25 00:35:58 lol Jun 25 00:36:08 lol a number... Jun 25 00:36:10 any old numbr huh? Jun 25 00:36:46 private static final int SCANTYPE_NPING = 8; and call it where needed Jun 25 00:36:52 as an example Jun 25 00:37:14 dismissDialog and showDialog are both deprecated - so wont bother with that Jun 25 00:38:02 What you're doing is deprecated as well Jun 25 00:38:07 no its not Jun 25 00:38:08 The preferred approach is dialogfragment Jun 25 00:38:12 oh Jun 25 00:38:14 yes it probably is Jun 25 00:38:14 hm Jun 25 00:38:35 I love dialog fragment Jun 25 00:38:47 y Jun 25 00:38:59 Because its quite useful Jun 25 00:40:22 SimonVT: nice to know you lived Jun 25 00:40:35 Hey, I wrote on g+ earlier Jun 25 00:41:18 what happoned? Jun 25 00:41:19 :o Jun 25 00:41:40 fun nights were had Jun 25 00:41:59 those can kill you Jun 25 00:42:22 I seems like my emulator starts always an older verion from my app and not the version wich ist new Jun 25 00:43:13 free drinks happened Jun 25 00:43:49 "I am never going to drink again" in the morning, haha Jun 25 00:46:55 naw, just tired Jun 25 00:48:17 Alright, so I'm trimming out excess code to get to the very base, and an error's coming up on this line "TextView ircBox = (TextView) findViewById(R.id.ircBox);" http://pastebin.com/eybcLHG9 Jun 25 00:48:58 is there a red line under R.id.ircBox? Jun 25 00:49:22 No Jun 25 00:49:33 No errors showing in the code Jun 25 00:49:39 it seems like it cannot find the id you're referring to (ircBox) Jun 25 00:50:45 Strange, it's in R and main.xml Jun 25 00:51:36 renegadeandy: sorry about that.. had to reboot machine, had to upadte my kernel to pull latest headers, the headers for my current 1 werent in the repo.. so.. your prolem.. from what I read its a "first time" problem but doesnt happen again? Jun 25 00:51:39 Any ideas how to execute. /configure on Android? Ive got root and terminal emulator Jun 25 00:51:52 try to do Project > Clean, langkid1 ? Jun 25 00:51:53 But i get permission denied Jun 25 00:51:58 ok Jun 25 00:52:05 drpenguin exactly Jun 25 00:52:50 Sicp, it appears to be throwing the same error. Jun 25 00:52:55 yesssss Jun 25 00:52:56 renegadeandy: any other behavior different after first run? Jun 25 00:53:02 drpenguin: i finally figured out how to parse that thing Jun 25 00:53:11 no - the operations are the same Jun 25 00:53:14 .split("[,]") Jun 25 00:53:18 is the relevant thing Jun 25 00:53:29 the brackets make it not ignore the empty field Jun 25 00:53:33 (apparently) Jun 25 00:53:40 i have a linearlayout which lays out its children with equal weights. I have directly add multiple instances of a child to it in xml, the children are laid out fine. If I remove the child view into a separate file so I can add them via code, the weights get messed up Jun 25 00:53:46 Tagami: coool Jun 25 00:53:50 gah Jun 25 00:53:53 If I* Jun 25 00:53:54 renegadeandy: well im not talking about operations persay Jun 25 00:53:55 now onto the next thing! Jun 25 00:54:03 but overall behavior, besides it wokring, like anything running faster or slower? Jun 25 00:54:04 any ideas? Jun 25 00:54:15 did you move the declaration outside of onCreate() and left the initialization inside only, langkid1 ? Jun 25 00:54:18 When I run my project over Eclipse with the SDK Emulator, since today it doesnt install the APK with my new edits. It install the version from yesterday. I tried to uninstal the APP in the emulator, but it always install the old version... i am confused Jun 25 00:54:18 it will be faster after first run Jun 25 00:54:45 Sicp, Oh, that's supposed to be separate Jun 25 00:54:49 renegadeandy: ok thats a start.. find out who is running faster, that may heko Jun 25 00:54:50 try Jun 25 00:54:50 help* Jun 25 00:55:09 so is there still nobody here who can tell me why my application will not run on my phone without trying to connect to the debugger? Jun 25 00:55:30 Sicp, done, trying Jun 25 00:55:44 Sicp, it works, thanks! Jun 25 00:55:51 l440r, well I wasnt here when you explained your problem.. what happens when you try to deploy? Jun 25 00:55:52 good Jun 25 00:55:53 I REALLY appreciate your patience with me. Jun 25 00:56:10 launch it on my phone and it displays "waiting for debugger" Jun 25 00:56:31 are you pressing the bug icon instead of the Play icon, I440r ? :P Jun 25 00:56:37 l440r and the debugger never connects? Jun 25 00:56:53 it will do this even if i totally unplug the usb calbe Jun 25 00:56:59 :O!! Jun 25 00:57:00 it will NEVER just run. Jun 25 00:57:06 it's a woman. Jun 25 00:57:07 not any more Jun 25 00:57:38 l440r well.. you are telling it to run in debug.. not run normally Jun 25 00:57:39 so.. Jun 25 00:57:40 im using intellij idea and for the past month or two ive been switching between debugging with the emulator, debugging with the hardware and running full tilt boogie on the hardware Jun 25 00:57:48 it wont RUN on the hardware now, it will only debug Jun 25 00:58:07 what did i change in my IDEA setup to make the apk always expect to be connected to a debugger? Jun 25 00:58:24 how shoud i know? its your system not mine Jun 25 01:06:57 i440r: I assume you've already done a binary search through your version control tool to find out where/when it broke? Jun 25 01:12:13 is there some easy way to do math on time values in Android? Jun 25 01:12:32 (say finding the difference between two time values) Jun 25 01:12:48 anyone know why the weights are correctly applied to views if they are defined directly under a linearlayout in xml, but not if I inflate an individual view and add it as a child via code? Jun 25 01:15:45 a web search on this issue shows im not the only person experiencing it. a reboot is suggested in one place. tried that, it worked Jun 25 01:20:08 http://pastebin.com/tkqr1D7x Jun 25 01:21:43 alcapwn: sanity check - does R.id.ll_container have your style on it? Jun 25 01:22:25 fjornir: yep Jun 25 01:22:33 ello? Jun 25 01:22:47 fjornir: all i did was remove the button view into its own xml as it can be added an arbitary number of times Jun 25 01:23:07 how do you go back to the previous activity in your app? Jun 25 01:23:44 when i do context.startActivity(i); it starts at onCreate, I just want it to go back to onResume Jun 25 01:23:58 if I use the back button it just goes back to onResume Jun 25 01:24:06 but If I do it in code it goes back to onCreate Jun 25 01:24:36 how can I go back to my previous activity? Does it always have to start at onCreate? Jun 25 01:27:34 eggie5: i think you want Activity#finish() Jun 25 01:27:55 eggie5: you should review the android activity life cycle, but if you are in activity A, and you start activity B (pending you use special intent flags) your activity stack will look like A -> B. If you leave activity B, A will come back to the foreground, assuming it wasnt destroyed onCreate is not invoked Jun 25 01:28:01 startActivity starts it fresh, so you will have to go through onCreate Jun 25 01:35:07 Has anyone had issues with multi touch and onKeyDown? Jun 25 01:35:28 if i'm touching my screen and test for menudown no event is triggered despite me pressing the button Jun 25 01:36:25 drpenguin: well I want to go A -> B but then pass some data back to A (using a bundle). But the problem is when I go startIntent from B it calls onCreate on A and I loose my state. Jun 25 01:37:07 Why are you calling startActivity? Jun 25 01:37:29 A isnt gone, its just in the background sleeping on the Activity Stack Jun 25 01:37:48 drpenguin: i'm goign context.startActivity Jun 25 01:38:23 drpenguin: how else should I start the intent? Jun 25 01:38:41 drpenguin: but also pass soem data back to A Jun 25 01:38:52 eggie5: by doing this the proper way, you call Activity B using startActivityForResult Jun 25 01:39:26 drpenguin: oh i saw that in the docs Jun 25 01:39:35 drpenguin: then you have to implement some interface on A Jun 25 01:39:48 eggie5: all you implement is onActivityResult Jun 25 01:39:56 thats not an interface, its an abstract method Jun 25 01:40:18 drpenguin: ok i'll try that instead Jun 25 01:40:30 or whatever it is, you just implement that Jun 25 01:40:44 its not abstract, I take that back, but you override that and do what you need to do in there Jun 25 01:44:19 EuroTrash, would it be better to put the IRC stuff in a Thread of a AsyncTask? Jun 25 01:44:23 or a* Jun 25 01:44:48 AsyncTask is for short background tasks Jun 25 01:45:08 Yeah. Jun 25 01:45:27 and it doesn't offer much in the area of recovering or retrying Jun 25 01:48:20 drpenguin: when using startActivityForResult I'm confused what activity B is supposed to do to return... Jun 25 01:49:10 eggie5: It doesnt return anything Jun 25 01:53:27 How do I fuse all my standalone projects into one program / app? Jun 25 01:59:31 hunting around for an uncrustify config for java Jun 25 02:01:01 eggie5, activity b sets a result. Jun 25 02:01:29 eggie5, then activity a, the one who called startActivityForResult, reads that result and does whatever code you want. Jun 25 02:01:29 T-Dub: how does B get a ref to A? Jun 25 02:01:36 It doesn't. Jun 25 02:01:46 Or at least I've never used it for that, so I don't know Jun 25 02:01:51 setResult(number) Jun 25 02:01:56 T-Dub: ha, then how do I set a result in A? Jun 25 02:02:07 so you can do like setResult(5); finish(); Jun 25 02:02:20 T-Dub: I call B.setResult()?? Jun 25 02:02:36 and then activity A in the onActivityResult method do if(result == 5){code} Jun 25 02:02:51 If you want to send data from a to b you can pass it thought the bundle Jun 25 02:03:08 but startActivityForResult is usually used to send data from B to A, after A has already been started Jun 25 02:03:33 T-Dub: yeah that's what I want Jun 25 02:03:42 Which one do you want? Jun 25 02:05:28 I have an application that runs a native NDK ported binary Jun 25 02:05:53 how do I get the outputs that should be on the terminal? Jun 25 02:05:58 (printf and stuff) Jun 25 02:06:29 johnnyonflame: is it printing anything to the console in Eclipse? I doubt it does tho.. Jun 25 02:06:52 drpenguin, I'm not using eclipse for it due to a few issues Jun 25 02:07:03 the script I'm using compiles everything and installs right away Jun 25 02:07:21 oohh. then I dooooooooobut it.. you would need to get that stuff to print to logs Jun 25 02:07:51 that or gdb should be able to view the output Jun 25 02:07:51 it would be in logcast Jun 25 02:07:53 logcat Jun 25 02:08:20 well Jun 25 02:08:27 nothing is printed on the NDK Jun 25 02:08:29 i mean Jun 25 02:08:30 gdb Jun 25 02:08:34 neither on LOGCAT Jun 25 02:08:44 Has anyone had issues with multi touch and onKeyDown? If i'm touching my screen and test for menudown no event is triggered despite me pressing the button Jun 25 02:08:51 yeah, but with gdb you could do stepping and see what is being passed to the printf Jun 25 02:09:05 you can print register contents, variables, etc Jun 25 02:10:20 I see Jun 25 02:10:31 Is there any function that allows me to print? Jun 25 02:10:35 to logcat I mean Jun 25 02:10:52 System.out.println Jun 25 02:11:02 @ndk Jun 25 02:11:28 udk? Jun 25 02:11:33 johnnyonflame: that I am not sure.. I would think you would need to edit the binary to do so.. unless you can wrap the output of it to logcat from your app Jun 25 02:12:12 anyone know what the android icon development best practices are? Jun 25 02:12:18 (or have a link to that sort of thing) Jun 25 02:12:31 im pretty sure google has a recommended page tagami Jun 25 02:12:37 http://developer.android.com/guide/practices/ui_guidelines/icon_design.html Jun 25 02:12:38 i figured they would Jun 25 02:12:44 drpenguin, I have full access to the source code Jun 25 02:12:51 thanks! Jun 25 02:13:52 johnnyonflame: oh well that works.. now you just need to change those calls to the appropriate logcat printing calls or whatever needs to be done Jun 25 02:14:40 some quick googling, maybe thisl work: https://groups.google.com/forum/?fromgroups#!topic/android-ndk/EQzEQv9k1XM Jun 25 02:15:34 so after I call setResult() do I need to close my activity or something? it just says open... Jun 25 02:15:59 eggie5: setResult() wont end the current activity, it needs to be ended via a finish() call or the user hitting the back button Jun 25 02:23:28 so, no way to actually have access to stdout? Jun 25 02:23:57 Not that I am aware of Jun 25 02:24:23 there is a way ... saw some hack for it a while back Jun 25 02:24:23 Thats not really what you want to do anyway, I'd assume best practice is you use logcat Jun 25 02:25:36 using dup and dup2 Jun 25 02:30:31 I've redone my code, and now it uses an AsyncTask to try to get to IRC, it doesn't use an library, here's the code http://pastebin.com/M4R0D0Rw and the error it's throwing is here http://pastebin.com/mARCftEW Jun 25 02:32:08 did you look at the line of code the stacktrace is pointing at? Jun 25 02:33:21 I imagine in.readLine() is returning null Jun 25 02:35:43 bankai_, yes Jun 25 02:35:55 you defined an AsyncTask inside of an OnClickHandler?!?!? Jun 25 02:36:11 haha I didn't even notice that Jun 25 02:36:20 s/handler/listener/ Jun 25 02:36:20 JakeWharton, it returned errors in the other ways Jun 25 02:36:34 btw you probably want a Service for this, not an AsyncTask Jun 25 02:36:36 or, I THOUGHT that was the way to fix the errors Jun 25 02:36:48 wabz, ok, but just in case, if the Service fails, what else is there? Jun 25 02:36:55 JakeWharton: well Java lets you do that :) Jun 25 02:37:10 it's a weird scoped inner class Jun 25 02:37:21 it's used all over the place in java.util for iterators Jun 25 02:37:32 * langkid1 tries putting the task outside of onclick Jun 25 02:37:53 it's not going to fix your NPE Jun 25 02:38:04 you need to return in your catch clause Jun 25 02:38:21 since it's obviously being invoked but you ignore its failure Jun 25 02:39:28 JakeWharton, so in java, if a string is null, and you try to compare it, NPE happens? Jun 25 02:39:38 calling a method on null is always npe Jun 25 02:39:44 not if you do "".equals(string) :) Jun 25 02:39:49 comparing a string is calling a method Jun 25 02:39:53 I was under the impression your "in" variable was null Jun 25 02:39:56 depends on the direction of comparison Jun 25 02:40:24 There's a difference between "the null string" and "a String object reference which is null" Jun 25 02:40:48 Has anyone had issues with multi touch and onKeyDown? If i'm touching my screen and test for menudown no event is triggered despite me pressing the button. I'm really stuck on this one =/ Jun 25 02:41:17 Muramasa: because your view doesn't have focus in touch mode Jun 25 02:41:34 :) ... Jun 25 02:41:40 what does that mean? Jun 25 02:42:00 http://android-developers.blogspot.com/2008/12/touch-mode.html Jun 25 02:42:07 I don't think 'in' is null JakeWharton, he's only catching IOException and it npe's on the if (!(line.equals -- I think line is null Jun 25 02:42:19 gotcha Jun 25 02:42:21 JakeWharton, ok I'll add an "ok" bool that goes false if there's any errors when connecting and sending NICK/USER Jun 25 02:42:29 i couldn't look at the code long enough to glean the true cause Jun 25 02:42:36 what is the solution romain? Jun 25 02:42:53 Muramasa: read the article Jun 25 02:44:07 so this is intended behavior then? Jun 25 02:44:10 JakeWharton, in is defined null before it is set to a BufferedReader for a Socket Jun 25 02:44:19 Muramasa: yes Jun 25 02:44:44 actually that kind of makes sense.. Jun 25 02:44:54 langkid1: the problem is with your readLine() usage Jun 25 02:44:57 if my user accidently hits back instead he'll basically lose all progress Jun 25 02:45:11 wabz, truthfully I don't even know if it's connecting correctly Jun 25 02:45:58 * langkid1 throws in a isConnected Jun 25 02:47:15 yes it's connected Jun 25 02:50:28 wabz, what would be the better way to do readLine? Jun 25 02:51:59 I am not paricularly familiar with sockets in java, but if you really expect to receive something there you might want to wait until it's not null (is there some kind of select?) Jun 25 02:52:19 possibly put the reading in a separate thread entirely Jun 25 02:52:25 as part of a larger Service Jun 25 02:52:43 I don't know, I'm definitely not the best person to ask :p Jun 25 02:53:01 :o Jun 25 02:55:06 you might want to use a tool like wireshark to see exactly what's going on too Jun 25 02:55:51 managed to output it to logcat Jun 25 02:55:57 a pretty simple #define does the job **** ENDING LOGGING AT Mon Jun 25 02:59:58 2012