**** BEGIN LOGGING AT Thu Aug 07 02:59:59 2014 Aug 07 03:00:11 This is getting quite frustrating. I can't access ACTION_MEDIA_BUTTON or ACTION_SCREEN_ON through a service registered broadcast receiver. Aug 07 03:00:19 AND you won't need a google account, Aug 07 03:00:38 and you can use mqtt as well for some other devices. Aug 07 03:01:04 but I think it's unnecesary to discuss, every plattform has it's benefits Aug 07 03:01:39 most apps with notifications are using GCM, because its easier... Aug 07 03:01:56 for my smart home stuff, mqtt was easier, as i hosted it on my Pi Aug 07 03:10:44 I want to start my broadcast receiver (registered in my manifest) on BOOT_COMPLETED - is there a way to do this? Aug 07 03:12:23 g00s: you seen crashlytics new "answers" ? Aug 07 03:12:49 StingRay_ no i haven't Aug 07 03:13:26 StingRay_ link ? Aug 07 03:14:12 i see Aug 07 03:14:15 cant get a link, it just appears in my console Aug 07 03:14:17 :) Aug 07 03:14:20 RT stats Aug 07 03:14:38 98% crash free users , but that 2% was a hacker or something Aug 07 03:18:45 hey i am trying to use unmkbootimg and i get a warning to change some things in the mkbootimg file how can i edit it? Aug 07 03:18:56 could someone explain id appreciate it Aug 07 03:19:04 sounds like an #android-root question Aug 07 03:19:31 hm, seems like my AS updater is busted. I have it set to canary for updates, but it won't pick up 0.8.5 Aug 07 03:19:37 well i am unpacking a stock boot.img just want to change the default.prop for the time being Aug 07 03:19:56 and it tells me before repacking to modify mkbootimg.c first Aug 07 03:20:17 g00s: Ouch - mine did that and then became impossible to update. Had to do a complete reinstall. Aug 07 03:20:20 so i try to open mkbootimg.c in a text editor and that wont work Aug 07 03:20:30 I found a way to pick up volume changes btw Aug 07 03:22:14 StingRay_ i have to look at crashlytics again; i had some reservations because (1) owned by twitter and (2) not sure how they make money Aug 07 03:22:40 so its more about the privacy of my users Aug 07 03:22:42 twitter own it? wow ... there's you go Aug 07 03:22:47 well, it will become a premium service Aug 07 03:22:55 i can get contact name by using contactLookup.getString(contactLookup.getColumnIndex(ContactsContract.Data.DISPLAY_NAME)); Aug 07 03:22:59 they are in the free stage Aug 07 03:23:02 how do i get contact image blob or drawable ? Aug 07 03:25:51 ugh, so i guess i'll dl a whole new AS Aug 07 03:27:35 ah, i selected 'ignore this update' because i wasn't ready. i didn't know that was /forever/ like, fucking diamonds Aug 07 03:32:46 you should use IJ, you'd never have those problems Aug 07 03:34:16 oh i thought the updater was from IK Aug 07 03:36:09 g00s, acra Aug 07 03:36:17 free Aug 07 03:36:28 Open source, all the crap you want Aug 07 03:37:04 yeah acra is on my list to look at Aug 07 03:37:39 I run my reporter on appengine Aug 07 03:38:56 https://github.com/pfn/android_crash_reports Aug 07 03:39:15 for my level of traffic, it's stupid to use anything but appengine Aug 07 03:39:20 free is free Aug 07 03:44:41 pfn: do you ever go over that free allocation? Aug 07 03:45:15 bankai_au, for some of my apps, yeah, but those have about 100k users Aug 07 03:45:30 for Acra, not even close Aug 07 03:45:31 pfn qicr ? Aug 07 03:45:41 ChromeIPass and passifox Aug 07 03:45:50 ah Aug 07 03:47:53 if you have a few thousand crashes per day, you'll not hit the limit Aug 07 03:48:13 my appengine Acra app fork isn't suitable for thousands of crashes either Aug 07 03:48:23 ladies Aug 07 03:48:30 you'll go nuts digging through them Aug 07 03:53:00 hey ron_frown Aug 07 03:53:09 yo Aug 07 03:53:16 ron_frown capella this looked interesting http://www.oreilly.com/pub/e/3090 Aug 07 03:53:35 HOLY FUCK Aug 07 03:53:38 VAMPIRE! Aug 07 03:53:57 canadiancow since you're here http://techcrunch.com/2014/08/05/opensignal-series-a Aug 07 03:55:00 g00s: I didnt get what that was about Aug 07 03:55:08 sounds like he contradicts himself Aug 07 03:55:47 you'll have to watch it tomorrow i guess :) Aug 07 03:58:44 shit I dont have time for that Aug 07 03:59:04 I watched a somewhat inexperienced coworker merge a massive refactor I did 12 branches Aug 07 03:59:15 and more than half were a huge ass failure Aug 07 03:59:22 but cant just revert it, gotta get it all fixed up and working Aug 07 04:00:25 octopus merge ftl Aug 07 04:00:45 man Aug 07 04:00:56 I was sitting there and he's like oh thats an old branch Aug 07 04:01:01 ACCEPT SOURCE! Aug 07 04:01:05 uhhh ok Aug 07 04:01:29 then I gotta knockout a few glass apps so I can get my work off my ass about developing for glass Aug 07 04:01:54 if anyone from google is here, fuck you very much for glass Aug 07 04:02:17 such antiquated hardware that all the fantastic ideas you have for it Aug 07 04:02:24 just is not at all capable of much at all Aug 07 04:03:45 cripple the hardware, cripple the software, then lock it down Aug 07 04:03:50 yay! Aug 07 04:04:05 eh, glass is obviously being played down in favour of wear Aug 07 04:04:15 i think glass was an experiment Aug 07 04:04:52 I don't think that glass as is, or anything very similar, will get a wide consumer release Aug 07 04:04:56 I gotta say the potential for glass is fucking huge Aug 07 04:05:08 I come from industrial environment where this would be absolutely fucking perfect Aug 07 04:05:29 if the os wasnt crippled and the hardware was even REMOTELY capable of taking a decent picture/barcode/qr code scanning Aug 07 04:05:32 I mean it will Aug 07 04:05:41 but barcodes like 6x6" Aug 07 04:06:11 I like wearables watch Aug 07 04:06:31 but that specifically is a solution for a diff problem Aug 07 04:07:00 best thing I can imagine at this point is to reduce it to a remote display/camera for custom uses Aug 07 04:07:09 from what i recall VCs weren't willing to fund Glass based startups because google wasn't giving info on availability, pricing to consumers, timelines Aug 07 04:07:11 camera is basically out Aug 07 04:07:18 if you cant use it like a hud Aug 07 04:07:22 what you see is what you are taking a picture of Aug 07 04:07:25 its no good Aug 07 04:07:37 that little teeny tiny ass viewfinder is pointless Aug 07 04:07:54 I was super stoked on atheerlabs stuff Aug 07 04:08:04 looks like they had come up with a much much more viable solution Aug 07 04:08:15 and some of there tech demos (not the marketing crap) were pretty impressive Aug 07 04:08:34 but it almost sounds like they are done for Aug 07 04:09:05 google or atheer labs ? Aug 07 04:09:29 atheer Aug 07 04:09:38 https://www.atheerlabs.com/ Aug 07 04:09:42 ron_frown also Babak Parviz left google Aug 07 04:09:42 Is the main problem of glass the fact the battery can't hold out? Aug 07 04:09:53 no Aug 07 04:10:03 that was honestly the least of my concerns Aug 07 04:10:15 there is literally no viable input mechanism, other than the touchpad and voice Aug 07 04:10:20 the main problem of glass is people don't like other people walking around with cameras on their heads Aug 07 04:10:32 its not about technological limitations Aug 07 04:10:40 those would all be worked on in time Aug 07 04:10:46 so if you are trying to do stuff like get info on a machine thats running 10ft in front ofyou... you can sit there walking back/forward/back/forward until the 1foot barcode manages to get focus Aug 07 04:11:02 g00s: in my case... an industrial application Aug 07 04:11:04 it wouldnt matter Aug 07 04:11:17 yeah but google isn't in business for industrial applications Aug 07 04:11:17 I dont think for consumers glass makes a bunch of sense Aug 07 04:11:27 well thats why the shitcanned it Aug 07 04:11:34 takes bad pictures, its slow hardware Aug 07 04:11:41 I loaded up some ar shit I wrote Aug 07 04:11:49 took about 1minute to initialize and start running Aug 07 04:11:49 Ahh we need some advances in biofeedback Aug 07 04:11:55 and I am not shitting you Aug 07 04:11:58 1 minute of AR Aug 07 04:12:02 and that thing was burning the side of my face Aug 07 04:12:06 ahh Aug 07 04:12:11 i see what you mean Aug 07 04:12:52 also Adrian Wong left google too Aug 07 04:13:12 Are the sdk kits from atheerlabs available? Aug 07 04:13:13 I bitch a lot Aug 07 04:13:21 lasserix_: sdk download is Aug 07 04:13:32 Yeah but can i get the hardware, i mean? Aug 07 04:13:35 but I basically told them I'd be willing to drop a shitton of cash down on a few units Aug 07 04:13:44 and intersted in a partnership Aug 07 04:13:46 no response Aug 07 04:13:57 I think they are having problems financially Aug 07 04:14:06 their kickstart refunded a lot of the consumer sponsors Aug 07 04:14:07 doh] Aug 07 04:14:17 and they say they are focusing on enterprise... which is what we do Aug 07 04:17:19 basically vusix is the only real option right now Aug 07 04:17:22 and its not much of an option Aug 07 04:17:35 I have inquiries in with meta space glasses Aug 07 04:17:41 and a couple others Aug 07 04:19:21 interesting, iOS 8 has separate permissions for foreground and background location Aug 07 04:19:49 goof news for foursquare users haha Aug 07 04:21:38 when the fuck is google selling their tango tablet Aug 07 04:21:48 daddy want. Aug 07 04:21:51 daddy need. Aug 07 04:21:54 [OT] Is there any push framework like PubNub which offers channel history and a good Android SDK? Aug 07 04:22:43 http://1.bp.blogspot.com/-OnJtmIOFb3w/UBroj-ycpYI/AAAAAAAAB_I/F9oSLxwAAxk/s1600/mayweather-money.gif Aug 07 04:26:00 napster you can try mqtt Aug 07 04:26:17 ok g00s lemme check Aug 07 04:26:40 you would need a mosquitto server and eclipse paho client Aug 07 04:26:51 chennel history ... hmm Aug 07 04:30:24 Hi guys, is it possible for me to get all the notification in status bar currently made by my app? Aug 07 04:30:47 i think you have to maintain that state yourself Aug 07 04:32:39 ok Aug 07 04:32:45 history is important Aug 07 04:33:16 hal abelson just coauthored a book on App Inventor 2 Aug 07 04:33:24 i guess AI is still going ... Aug 07 04:57:31 ron_frown still there ? Aug 07 04:57:47 for a little bit longer Aug 07 04:57:48 yes Aug 07 04:58:15 was reading an article today about police / military getting very interested in electric motorcycles Aug 07 04:58:20 cool Aug 07 04:58:22 yeah Aug 07 04:58:25 its the cool thing right now Aug 07 04:58:27 for obvious reasons, like being quiet and sneaking up ;) Aug 07 04:58:38 to be green Aug 07 04:59:07 electric vehicles are still not GREAT for environment in all the manufacturing and byproducts of the metals in batteries Aug 07 04:59:11 but yeah Aug 07 04:59:25 less about green, but being able to sneak up Aug 07 04:59:37 most stock bikes are pretty silent Aug 07 04:59:38 batteries can be single, double Aug 07 04:59:53 but it does fit well Aug 07 05:00:09 build a charging station Aug 07 05:00:15 poweer it by the sun Aug 07 05:00:37 harley davidson Aug 07 05:00:44 the LAST brand I'd ever go for Aug 07 05:00:47 zero mmx looks pretty badass http://www.zeromotorcycles.com/fleet/military/ Aug 07 05:00:53 is making a very cool looking electric bike Aug 07 05:01:15 http://project.harley-davidson.com/ Aug 07 05:01:35 yeah Aug 07 05:02:05 theres a place here with a few zeros for sale Aug 07 05:02:14 the usmc designed it with Zero, so they had a long list of shit like maintenance requirements Aug 07 05:02:15 I'm a petrol head Aug 07 05:02:16 so Aug 07 05:02:31 naturally a drawing to engines etc Aug 07 05:02:42 ron_frown what will you do post industrial society :P Aug 07 05:02:48 mad max is coming man Aug 07 05:03:22 http://www.zeromotorcycles.com/press-releases/may-16-2013-zero-fleet-hong-kong.html Aug 07 05:03:55 Leeds have you seen any on the road ? Aug 07 05:04:11 not sure I'd have recognised one, to be honest Aug 07 05:04:57 I mean, I probably would if I walked past one, but not if it drove past me Aug 07 05:06:33 was at an event last night with the local Uber boss - they soft-launched here a couple of months ago, went to 'full launch' a week or two back - where he had to deny a rumour they were planning to import a small fleet of Teslas Aug 07 05:08:14 some big changes are coming to batteries in the next 1-2 years; should be exciting to see how they find their ways into cars, motorcycles, etc Aug 07 05:08:29 i'd be interested in an electric ultralight aircraft Aug 07 05:09:21 don't like that crappy gas engine right behind Aug 07 05:19:29 acer c720 is $179; just read an article today about putting ubuntu on it Aug 07 05:19:52 hello all Aug 07 05:20:50 which laptop i should choose for android development. i like to use android studio. please suggest. Aug 07 05:21:14 " WIN DEATH " can anyone point why this occurs for no reason in my activity? Aug 07 05:22:00 t2mkn over 4G memory, probably not celeron (i5 or i7) Aug 07 05:22:10 after that ... pretty much anything i guess Aug 07 05:22:36 i have 4G and its a struggle Aug 07 05:24:08 g00s: ya, that true. i currently use a core 2 duo with 2G memory. using eclipse adt. but when i get android studio its hanging always. Aug 07 05:24:16 so thinking of a new system Aug 07 05:24:48 and hopefully it has vt-x so you can use genymotion / virtualbox Aug 07 05:25:16 i use Ubuntu 12.04. dont like windows at all. so need a compatible system for this requirement. Aug 07 05:25:56 lots of systems out their in market, m confused which to select. which brand. Aug 07 05:26:26 thats why i like mac; few choices, shit just works Aug 07 05:27:23 i too like to use mac but its very costly. 13" may not be a choice, 15" will do. but.... Aug 07 05:27:30 PC oems are pita. lets say they put our model X with some spac. it gets reviewed ... and then silently, they change the spec Aug 07 05:27:32 so looking for an alternative Aug 07 05:27:51 t2mkn maybe mac mini ? Aug 07 05:27:57 yeah, costly for what it is Aug 07 05:28:27 hi I have a quit function(just has finish() and exit() ) I want to have the same menu item for all the pages Aug 07 05:28:29 how can I do that Aug 07 05:28:44 I added the menu item in one activity Aug 07 05:29:13 though the menu item is visible for other pages but its function is not Aug 07 05:29:30 exit() ? Aug 07 05:29:34 like System.exit ? Aug 07 05:29:57 g00s: i have a laptop right now. if I go for mac mini, then i have to take all other things like monitor, ups, keybord etc. :( almost equal price to macbook pro Aug 07 05:30:10 yeah Aug 07 05:30:25 niru: create a superclass and extend in all activities Aug 07 05:31:33 waaaaait Aug 07 05:31:44 Android app's don't exit. niru what do you mean Aug 07 05:31:51 g00s: also there is lot of voltage problem in my area, so considering a desktop may not be good. Aug 07 05:32:11 t2mkn ohshit :O Aug 07 05:32:43 t2mkn well all i know PC wise, is better lenovo thinkpads are nice Aug 07 05:32:52 dell and hp are shit Aug 07 05:33:02 maybe asus Aug 07 05:33:40 g00s: I am building a custom app which needs a quit icon in the menu bar Aug 07 05:34:04 oh my Aug 07 05:34:49 g00s: i too think so. i have IBM and Compaq at moment. But i think IBM (Lenovo) dont like linux very much Aug 07 05:35:13 yeah always that video driver / wifi issue Aug 07 05:35:23 i guess avoid broadcomm wifi Aug 07 05:35:56 g00s: ya, also sound issues too. my speakers of IBM died because of Ubuntu 12.04 Aug 07 05:35:58 :P Aug 07 05:36:55 hehe, linux sound apis ... FTL Aug 07 05:38:09 :D Aug 07 05:38:17 t2mkn: thanks:) Aug 07 05:39:20 niru: happy helping :) hope u dont have lots of already created activities to extend Aug 07 05:39:35 t2mkn: no only two Aug 07 05:39:48 niru: cool, enjoy :D Aug 07 05:40:11 g00s: MacBook Pro 13" or 15" which u suggest Aug 07 05:40:50 t2mkn oh mine is very old. i find working on 13" too hard. i guess it depends how often you will be moving around with it Aug 07 05:41:06 hell if they made 17" still i would go for that :D Aug 07 05:41:36 ya i guess so, so 15" may be good for me Aug 07 05:42:09 there is cursor that contain all rows with all columns of table of sqlite db. Need to find one row by client_id. What is better, to search through cursor all rows or run dbHelper.query("where client_id = 123")? Aug 07 05:42:14 how about "NVIDIA GeForce GT 750M with 2GB of GDDR5 memory and automatic graphics switching" with it. i can neglect this i guess for android development. not a big fan of gaming in computers. Aug 07 05:42:53 ondroed search by query Aug 07 05:43:06 and if select x where foo = x ; make sure foo is indexed Aug 07 05:48:30 i heard that it's better to work in background with sqlite. does it applies to all queries or not so important for small queries? Aug 07 05:49:58 i was disconnected Aug 07 05:50:23 g00s: u suggested anything about NVIDIA? Aug 07 05:51:07 can make it better http://pastie.org/9452079 ? It looks a bit ugly… anyone has a better way? Aug 07 06:00:31 ondroed: I think the reason is because you might be touching the file system when accessing the database. So I'd say that it applies to all queries Aug 07 06:01:36 ok, thanks Aug 07 06:01:37 I was going to say g00s is not here, but s/he is. Aug 07 06:01:48 yay! Aug 07 06:01:58 t2mkn: you there? Aug 07 06:02:00 detachYo he :) Aug 07 06:02:05 hey thepoosh Aug 07 06:02:10 g00s: :) Aug 07 06:02:10 sup dudermeister? Aug 07 06:02:12 I got an issue that quit Aug 07 06:02:20 hehe, fucking around with TabHost ehehehe Aug 07 06:02:23 niru: was it SIGSEGV? Aug 07 06:02:25 TabHost is old! Aug 07 06:02:32 kamol: maybe you can use https://developer.android.com/reference/android/text/TextUtils.html#isEmpty(java.lang.CharSequence) to chek if the different .getText() are empty or not Aug 07 06:02:32 we've been dealing with that all week Aug 07 06:02:40 yeah but its not deprecated. i'm not using the tabs in the actionbar Aug 07 06:03:32 although i am curious, if they backport Toolbat to AppCompat, what it will have Aug 07 06:03:37 *Toolbar Aug 07 06:05:58 ah i see Aug 07 06:06:04 niru: ya, but busy with my 2 years old son. :) sory. Aug 07 06:07:04 jush: looks good :) let me try Aug 07 06:07:31 but how about mulltiple `return` is not ugly? Aug 07 06:08:04 yes, it looks ugly but I can't think of a better way Aug 07 06:08:45 Why can't type argument be of primitive type? Aug 07 06:08:56 Why won't List work but List does Aug 07 06:09:30 jush: anyway thank you for TextUtils Aug 07 06:10:28 g00s: i need your opinion Aug 07 06:11:23 detachYo basic java, generic collections can't take primitives Aug 07 06:11:31 long is primitive, Long is object Aug 07 06:11:45 oh, this was on something else but thanks for that oo :P Aug 07 06:11:51 too* Aug 07 06:12:54 if I have an id indicating a message, that can/will be passed around activities and fragments, should I make it static so I can access it from other activites, or should I just pass it through activities Aug 07 06:13:55 yes Aug 07 06:14:16 but seriously i'm a fan of passing Aug 07 06:14:41 if you feel like you have to make something static re-examine your application design Aug 07 06:14:41 your response was positive for both options Aug 07 06:14:46 ok Aug 07 06:14:48 that answers Aug 07 06:14:49 haha Aug 07 06:14:51 thanks Aug 07 06:14:59 detachYo making it static will break shit Aug 07 06:15:14 if your process gets killed, who populated it when it comes back ? Aug 07 06:15:35 kamol: actually have you thought about using https://developer.android.com/reference/android/text/TextWatcher.html Aug 07 06:17:34 g00s: makes sense, hadn't thought about it from that perspective Aug 07 06:30:01 jush: http://stackoverflow.com/questions/5047378/when-should-i-do-certain-sqlite-operations-on-another-threadnot-the-main-thread Aug 07 06:32:46 i was reading this page http://developer.android.com/guide/topics/sensors/sensors_motion.html and wondered why it says Two of these sensors are always hardware-based (the accelerometer and gyroscope), and three of these sensors can be either hardware-based or software-based (the gravity, linear acceleration, and rotation vector sensors) Aug 07 06:33:04 is there a difference between String.valueOf(id) and id.toString() Aug 07 06:33:16 Any performance differences? Aug 07 07:11:35 has anyone successfully implemented ChipsLibrary into their project? Aug 07 07:16:47 detachYo: are you using any 3rd party library? Aug 07 07:23:33 How do you handle a navigation drawer with subareas, like titles etc.? Do you tell the listview adapter how to make titles or do you put the ListView as a child in a relativelayout? Aug 07 07:24:03 later Aug 07 07:24:21 but you could also just manually create the list if you want to trick it out Aug 07 07:52:40 Hey I am trying to change java compiler to 1.7 in android studio, is this supposed to work? Aug 07 07:55:06 If Java had true garbage collection, most programs would delete themselves upon execution! Aug 07 07:55:39 lasserix_: yes Aug 07 07:55:52 where do I change it? Aug 07 07:56:44 there are two places, settings -> compiler -> java / othersettings -> compiler -> java I set to 1.7 but still get an error on an arraylist such as ArrayList blah = new Arraylist<>() (the <> doesn't require to be typed afte rnew in 1.7) Aug 07 08:11:22 i see many apps do singletons in the Application class - why not initialize static members in onCreate instead? Aug 07 08:13:03 just two different approaches I guess, or there could be deeper reasons that would need code insight in order to understand Aug 07 08:13:28 like for example the class in question is a shared base class Aug 07 08:15:02 ravilov: i was thinking maybe i'm making onCreate become really busy Aug 07 08:15:26 and that people noticed is slows the start time of the app and that's why they are lazily building singletons Aug 07 08:15:44 both object creation and oncreate take place after the app is started but before anything shows up, so visually (to the user) there would be no difference Aug 07 08:15:50 either that... or the usual Java over-engineering - people do singletons without thinking too much. Aug 07 08:16:20 it's hard to tell without insight into actual code Aug 07 08:16:36 well the simplest example - google analytics tracker. Aug 07 08:16:56 inside your Application class, you can either pre-initialize a tracker on onCreate and save it in a static field Aug 07 08:17:07 or you can lazily initialize it in a *synchronized* getTracker() Aug 07 08:17:29 oh wait Aug 07 08:17:37 singletons are not the same as lazy init Aug 07 08:18:05 so I'm guessing your original question has more to do with lazy inits than singletons Aug 07 08:18:31 yes - i can find a simple example Aug 07 08:18:59 here: https://github.com/amilien/ExpensesTracker/blob/e3816383f71e7bfabd6535a193aee3d37e9fb053/ExpensesTracker/src/com/amilabs/android/expensestracker/MyApp.java Aug 07 08:19:08 this guy lazily initializes 3 kinds of trackers. Aug 07 08:19:23 man, I read 'atom x86' in avd and I thought 'these must be fast enough'. how wrong I was.... Aug 07 08:19:33 however what i'm arguing - you know beforehand what trackers you need, why not initialize them into a *static* hashmap in onCreate Aug 07 08:19:54 then give everyone access to this static hashmap via Application.MyTrackers Aug 07 08:20:27 jk Aug 07 08:22:55 ravilov: is that example clearer? Aug 07 08:23:04 pellis, yes, to a point Aug 07 08:23:16 I don't know how he used the trackers later Aug 07 08:23:41 if he indeed ends up using all of them, then I guess he could've initialized them immediately Aug 07 08:23:50 ravilov: i'm not coming from android background - but i'm coming from serverside and (long time ago) desktop backgrounds. from what my instincts tell me - avoid laziness and concurrency when you can. Aug 07 08:24:17 for me its a big win if i have all the data i need to initialize stuff - i do it on the spot. Aug 07 08:24:24 unless there's something im missing here which is android-specific Aug 07 08:24:39 your experience might be hampering you - with servers it is indeed more important they run fast than they start fast Aug 07 08:24:48 i acknowledge that because the original Google integration code included a singleton maybe everyone is just copy/pasting Aug 07 08:25:02 could be Aug 07 08:25:18 ravilov: yep that's why im firstly asking - if the stuff im doing onCreate is making the app start slower Aug 07 08:25:29 maybe there's a best practice here i'm missing Aug 07 08:25:43 like I said earlier Aug 07 08:25:58 both activity init and oncreate happen before anything is shown to the user Aug 07 08:26:38 what is the most commonly used IDE for android development on win64? Aug 07 08:26:41 so yeah if you do too much in oncreate it can easily appear your app seem laggy Aug 07 08:27:04 placidb, whatever is official from google Aug 07 08:28:00 ravilov: thanks. seems i need to give android studio a try. Aug 07 08:28:01 premature optimization is root of all evil Aug 07 08:28:28 i think the other thing is principle of composition Aug 07 08:28:52 though what's the difference between your two approaches? Aug 07 08:29:01 in either case you're initiallizing something from oncreate? Aug 07 08:30:13 i see many apps do singletons in the Application class - why not initialize static members in onCreate instead--> whose onCreate? Aug 07 08:31:37 lasserix_: Application class Aug 07 08:31:57 lasserix_: lazy evaluation *is* premature optimization Aug 07 08:32:42 er Aug 07 08:32:43 what? Aug 07 08:33:05 wow google analytics API v4 is so broken Aug 07 08:33:29 looks like 5 different teams made this API in bits and then somehow duct taped it together Aug 07 08:33:42 pellis, the code you have linked, I don't see any calls to gettracker in oncreate Aug 07 08:34:02 so in this case lazy init totally makes sense Aug 07 08:34:07 ravilov: right - but trackers are lazily initialized Aug 07 08:34:20 yes, so? Aug 07 08:34:28 ravilov: what im saying - in Application.onCreate - why not create all trackers. all 3 of them. Aug 07 08:34:38 I just explained you why... twice Aug 07 08:34:55 yep, i thought we are going back to the start :) Aug 07 08:35:03 lol Aug 07 08:35:05 no thanks Aug 07 08:35:24 but OK - im willing to live with the argument it holds up the application Aug 07 08:36:15 there's always the second argument - with lazy init. the first user action the user will perform will be laggy :) Aug 07 08:39:26 Not really.. The point is to not initialize everything at the same time.. Each component might not take long to init, but combined.. Aug 07 08:40:36 You generally want something to show to the user immediately, otherwise your app seems sluggish Aug 07 08:40:52 like a splash screen? ;p Aug 07 08:41:06 I should ban you Aug 07 08:41:30 hehe Aug 07 08:43:42 Urgh, I remember making an app with a mandatory 5s delay on the splash Aug 07 08:44:36 What about a tutorial? Aug 07 08:45:42 yo Aug 07 08:45:59 Sometimes my logcat doesn't show anything for the automatically created package tag (of my apps name) is there any way to fix this? Aug 07 08:46:07 anyone knows how i can install apk(contains a service my app needs) without prompting the user? Aug 07 08:47:25 that would be a major security flaw if you could Aug 07 08:47:50 ravilov: so whats my options? i wanna have a service that more than one app uses Aug 07 08:47:52 Nick-S: only if your package is signed with the same signature as the system image] Aug 07 08:47:52 (but yes you can, provided the device is rooted and your app has already been given permission) Aug 07 08:47:56 i don’t need to include it with every app... Aug 07 08:48:07 estel: what does it mean? Aug 07 08:48:10 Nick-S, be straightforward and tell the user you need it and they should install it Aug 07 08:48:18 ^^ Aug 07 08:48:31 Nick-S you developing a service for other apps to use or just apps in your "family"? Aug 07 08:48:56 other apps Aug 07 08:49:10 then you are using AIDL? Aug 07 08:49:15 yes Aug 07 08:49:41 i supply a library with the .aidl's Aug 07 08:49:43 well i suppose Aug 07 08:49:57 oh nevermind that's too evil Aug 07 08:50:05 the only legitimate way to do this Aug 07 08:50:05 nothing is too evil Aug 07 08:50:11 is do what ravilov said Aug 07 08:50:24 and the non-legitimate? Aug 07 08:50:33 i had to figure out the same thing, but for the same the android ecosystem i told my boss that you'd have to prompt the user Aug 07 08:52:01 *for the sake Aug 07 08:52:24 hi Aug 07 08:52:25 so prompting the user is the way…. Aug 07 08:52:37 Nick-S, I'm going to assume this is some purpose-built app for a very limited range of users Aug 07 08:52:45 otherwise this is definitely no way to build any kind of trust Aug 07 08:53:09 if you're really considering being so sneaky and doing stuff behind people's backs Aug 07 08:53:23 anyone heard of updatenode.com? Aug 07 08:53:28 Hey guys, i've a problem using a custom library, someone could help me? Aug 07 08:53:36 * ravilov hasn't Aug 07 08:54:22 eduine, the rule is - you ask straight away and then wait and hope, not you seek people and THEN ask Aug 07 08:54:27 the general rule* Aug 07 08:54:39 ok sorry Aug 07 08:54:55 just ask Aug 07 08:54:58 it's like blind marriage Aug 07 08:55:05 i see. Aug 07 08:55:11 ofcourse i want to be sneaky :) Aug 07 08:55:12 i'm trying to use Telephony.NetworkQueryService, but eclipse wont recognise any .java file, i can only see .aidl files, i don't understand why Aug 07 08:55:31 eduine: huh?! Aug 07 08:56:02 i made a jar, with all java & aidl files from Telephony package (android undocumented sources) Aug 07 08:56:07 are you sure your eclipse/adt installation is done right? Aug 07 08:56:21 oh hm Aug 07 08:56:22 yup Aug 07 08:56:33 eduine: install adt plugin for eclipse Aug 07 08:56:44 shmooz done! Aug 07 08:56:46 oh Nick-S the best way is to actually make an app people will want that uses your service, then put that on the store Aug 07 08:57:08 or talk to oem folks Aug 07 08:57:09 Nick-S, then I for one am not going to help you get there, as I definitely do not support such approach Aug 07 08:57:14 can i put the service app on the store too? Aug 07 08:57:18 sure Aug 07 08:57:23 why not? Aug 07 08:57:24 it's just a service right? Aug 07 08:57:34 and then make sure it installs from the using app? Aug 07 08:57:38 the key is putting a activity on top of it that has some function Aug 07 08:57:45 how do i make a requirement? like dependency Aug 07 08:57:49 Nick-S: you can't Aug 07 08:57:53 like it prints out hello world Aug 07 08:57:54 Nick-S i am not sure you understand how it works Aug 07 08:58:03 Estel: ? Aug 07 08:58:03 someone downloads your AIDL files and puts them into your project Aug 07 08:58:05 Nick-S, this is all manual work from there Aug 07 08:58:17 and declare the service Aug 07 08:58:37 ravilov: you mean i need to send the user to the store with some link/intent? Aug 07 08:58:37 you want a system service, but the only way to get that kind of thing is to talk to google / cynogen mod / samsung / htc Aug 07 08:58:43 Nick-S, basically, yes Aug 07 08:58:52 also preferrably with some info as to why this is needed Aug 07 08:59:14 but thats not true, my service works, just like system service, but without their permission, if i bundle it directly in the app Aug 07 08:59:20 Nick-S, I don't know what's the big deal with such approach, it's not like that would be the first app to need extra support libs/services Aug 07 08:59:31 NOT just like a system service Aug 07 08:59:59 a system service is a service that exists on the phone before anyone but the manufacturer / distributor touches it Aug 07 09:00:16 people using your remote service download your aidl files, and stick them in your app Aug 07 09:00:28 its not a system service, its just a remote background service Aug 07 09:00:38 it only starts existing after the user starts the application first time Aug 07 09:01:23 yeah and the people using it bundle it into their apps Aug 07 09:01:33 using aidl to interface Aug 07 09:01:52 is there anyway eclipse could ignore a specific package? (here it's com.android.phone) Aug 07 09:02:17 this is roughly what I'd do: try { startService/bindService } catch (Exception) { ok/cancel AlertDialog ; cancel -> finish(), ok -> market or other link } Aug 07 09:02:28 eduine, ignore in what way? Aug 07 09:02:52 Nick-S: ^^ that's the best way Aug 07 09:03:20 ravilov: i could actually look at the packagemanager to see if its installed instead of waiting for the exception Aug 07 09:03:39 then you need permissions Aug 07 09:03:40 yes you could do that if you feel like overengineering it :p Aug 07 09:03:59 ravilov my source folder is imported, but i can only see some of the files in eclipse Aug 07 09:04:12 eduine, ok? Aug 07 09:04:16 i know some internal and hidden classes are hidden by eclipse Aug 07 09:04:26 but i don't know how to change it Aug 07 09:04:27 they shouldn't be Aug 07 09:04:33 ravilov: other link can be the apk intent, right? that one with the prompt… Aug 07 09:04:40 ravilov yes they should Aug 07 09:05:24 eduine, ok, well... I'm still not sure I understand what you mean/need, so it's probably best to wait for someone else to pitch in Aug 07 09:05:25 some classes for firmware development, i think, are not accessible to developers, nor in the doc (@hidden tag is used) Aug 07 09:05:32 eduine maybe it is file permission problem ? Aug 07 09:06:12 shmooz i'll see, i'll tell you if i manage to do it Aug 07 09:06:28 run eclipse as administrator Aug 07 09:06:32 Nick-S, not sure what you mean by apk intent, but yes, whatever you believe is most appropriate, so long as you're straightforward with the user about what is going to happen Aug 07 09:06:37 or check the files permissions Aug 07 09:07:13 hmm Aug 07 09:07:15 (honesty is the best policy) Aug 07 09:07:22 shmooz file permissions are okay Aug 07 09:07:53 i also tried another approach. i had the service as a library, i repeated the Aug 07 09:07:55 oops Aug 07 09:08:33 i repeated the declerations and it still worked, the service started only once, even though it existed in more than one apk Aug 07 09:08:49 hm interesting Aug 07 09:08:56 maybe it's down to its package name? Aug 07 09:09:26 i changed a package name, no influence.. Aug 07 09:09:37 eduine, that was intended for Nick-S Aug 07 09:09:47 oh sorry ^^ Aug 07 09:10:15 Nick-S then you were doing something wrong Aug 07 09:10:29 a new instance of the service is started for each distinct application Aug 07 09:10:52 eduine: com.android.phone is the dialer app, no? Aug 07 09:11:10 eduine: have you located and viewed the java files outside of eclipse ? Aug 07 09:11:10 eduine: Anyway, com.android.phone is not part of the SDK sources... Aug 07 09:11:47 flan3002, that's kind of the point - he's made some of the non-SDK sources into a JAR Aug 07 09:11:59 no, i know, i downloaded the android sources, and the files i want to use are in com.android.phone Aug 07 09:12:31 but importing it, i can only see the aidl & logtags files in eclipse, none of the java files are showing Aug 07 09:13:03 where are you expecting them to be though? Aug 07 09:13:16 they won't be a part of your own project's source tree Aug 07 09:13:40 lasserix_: not if you have android:process declaration in the Aug 07 09:13:46 Unless you put them in, which'd be weird. ^^ Aug 07 09:13:49 i've a folder on my computer with all my java files, i used buildpath -> add external class folder Aug 07 09:14:03 eduine, yes, so like I said Aug 07 09:14:07 they won't be a part of your own project's source tree Aug 07 09:14:19 could you explain? Aug 07 09:14:29 you have your src/ Aug 07 09:14:36 you have your project's .java files in there Aug 07 09:14:42 anything extra will not be in src/ Aug 07 09:14:55 example - I'm looking at one of my projects now Aug 07 09:15:13 I have two separate entries - Android x.x and Android Dependencies Aug 07 09:15:21 both host a single .jar each Aug 07 09:15:24 oh yeah yeah i see Aug 07 09:15:30 but that's not the proble Aug 07 09:15:32 +m Aug 07 09:15:51 in my project tree, i've Referenced libraries Aug 07 09:16:07 in that one i've got my phonelib folder Aug 07 09:16:14 well, to be honest, I've never included any external libraries other than whatever android included automatically Aug 07 09:16:17 eduine: But... what are you going to do with them? They don't define any API, or do they? Aug 07 09:16:19 so I don't really know how it works Aug 07 09:16:24 but in this folder, i can only see my aidl files Aug 07 09:16:56 not sure what you're trying to do there, but it could also be that you're taking a wrong approach Aug 07 09:17:07 kinda seems like it since you're trying to use code that's not meant to be (re)used Aug 07 09:17:16 flan3002 i'm using them for my application, it's hmm, to see all the available service providers (not just the one you subscribed) Aug 07 09:17:46 ravilov yeah i think that's the point, it might be blocked in anyway Aug 07 09:17:51 is there no official API to get the list of providers? Aug 07 09:18:19 but even changing the package and class name, i can't see them anyway, that's why i'm thinking i have made a mistake Aug 07 09:18:33 ravilov nope, not to see all providers Aug 07 09:18:44 Did you say you'd built the JAR and that's what you're including? Aug 07 09:19:11 going from my own (limited) experience, trying to adapt android built-in code (or even just trying to make it work) can be extremely painful, sometimes even impossible Aug 07 09:19:18 Estel i tried that, no success, i tried to import directly the folder, no more success Aug 07 09:19:34 I tried to clone the contacts system (app+provider), it's... very complicated Aug 07 09:20:28 eduine, http://stackoverflow.com/questions/2001590/get-a-list-of-available-content-providers Aug 07 09:21:28 ravilov: http://stackoverflow.com/questions/10454388/android-how-do-i-get-gsm-signal-strength-for-all-available-network-operators Aug 07 09:21:45 that's not exactly what i want to do, see my link for more details Aug 07 09:21:58 ah, not content providers Aug 07 09:22:02 but cell network providers Aug 07 09:22:19 yeah I think you're digging into something you're not supposed to even touch Aug 07 09:22:30 yep i know Aug 07 09:22:58 in fact i can't even say if it's 'legal' or not, if i achieve to do this, can i put my application on the store? Aug 07 09:23:27 I don't see why not Aug 07 09:23:39 there's nothing illegal about this Aug 07 09:24:01 it's just not what a user app is ever supposed to touch Aug 07 09:24:21 cuz it's for a professional app Aug 07 09:24:36 it's the goal i have in my current job Aug 07 09:24:51 interresting, but turn me crazy ^^ Aug 07 09:24:58 you might end up having to roll your own ROM in order to achieve this Aug 07 09:25:09 heh Aug 07 09:25:32 i must find another solution, cuz it should be an application downloadable from the store Aug 07 09:25:32 hi, how select a date from a calendar box for choice a date? Aug 07 09:25:33 that's always a fun conversation "Well to do what you want we'll have to hire a team of engineers to fork android" Aug 07 09:25:43 eduine what are you trying to do? Aug 07 09:26:00 http://stackoverflow.com/questions/10454388/android-how-do-i-get-gsm-signal-strength-for-all-available-network-operators Aug 07 09:26:16 lasserix_ see my link, it's really well explained Aug 07 09:27:11 can you bind to INetworkQueryServiceCallback without system access permission? Aug 07 09:28:22 i don't know, i can't event use NetworkQueryService.Localbinder (cannot be resolved), that's why i'm trying several ways to import my external library Aug 07 09:28:51 it could be protected, but it probably just extends Binder or IBinder, is that not good enough Aug 07 09:28:56 ? Aug 07 09:29:19 Quinto you should use DatePicker Aug 07 09:29:35 that's what i mean Aug 07 09:29:36 eduine: i want take also day and month Aug 07 09:29:52 you may not be able to bind to that remote service without being a system level process Aug 07 09:30:03 (which you can't be) Aug 07 09:30:19 Quinto: TimeSquare Aug 07 09:30:19 Quinto datepickerdialog see -> http://pulse7.net/android/date-picker-dialog-time-picker-dialog-android/ Aug 07 09:30:43 lasserix_ are you sure? Aug 07 09:30:47 lasserix_, maybe a shared uid would work? just an idea Aug 07 09:30:52 Quinto: or https://github.com/square/android-times-square Aug 07 09:31:01 thanks Aug 07 09:31:06 if my phone is'nt rooted, i would not be able to bind this service, is that it? Aug 07 09:31:17 has nothing to do with rooting Aug 07 09:31:32 no you'd have to fork the android Aug 07 09:31:46 and add a system level application of your own that would have the system permission Aug 07 09:31:51 I keep on running into EOFExceptions with Retrofit, no idea how to reproduce it, very random.. any idea how to approach this? Aug 07 09:31:58 there is a set of permissions only available to android os apps Aug 07 09:32:20 you CANT get access to these permissions Aug 07 09:32:26 and hence CANT bind to these services Aug 07 09:32:32 alternatively, you could state it works on rooted devices only and then have an option to roll it into /system Aug 07 09:32:34 hmm i think i see Aug 07 09:32:35 (if that's true for this one) Aug 07 09:32:40 no not even rooted devices Aug 07 09:32:49 no? Aug 07 09:32:52 well drats Aug 07 09:33:01 no, because you still need the system signing key Aug 07 09:33:01 so if i want to use them, it's kinda like i'm going to have to make a custom rom? Aug 07 09:33:10 you could root the device, i guess, then find the system files and add your app by editing them Aug 07 09:33:21 that would give your app system level access Aug 07 09:33:25 Mavrik, lasserix_, I thought most system services are protected with signatureOrSystem Aug 07 09:33:33 yes. Aug 07 09:33:40 which is what that means :) Aug 07 09:33:40 so rolling it into /system should be enough Aug 07 09:33:45 no. Aug 07 09:33:56 it means: app has to be signed with same signature or with system signature Aug 07 09:34:05 (in case of system apps that can be the same thing) Aug 07 09:34:07 "same" signature Aug 07 09:34:07 ? Aug 07 09:34:15 yes, same private key. Aug 07 09:34:18 same as what Aug 07 09:34:19 ? Aug 07 09:34:23 darn question mark Aug 07 09:35:36 sam as the app containing the service. Aug 07 09:35:49 so there's no way to make an app with these rights as a simple developer? Aug 07 09:35:59 no, because that's the whole point. Aug 07 09:36:10 they're meant only for system apps Aug 07 09:36:38 ok, well thanks for all these informations, i understand more of the problem now :) Aug 07 09:37:06 and is there a possibility to develop such an app? Aug 07 09:37:13 (system app) Aug 07 09:38:31 Mavrik, thanks, I've learned something too Aug 07 09:38:36 eduine, well, yes. Aug 07 09:38:49 System app is just an app signed with (one of) the system signing key Aug 07 09:39:34 and i've to get one of these keys, but how could i do that? Aug 07 09:40:03 if you could do that, then so could anyone else, what's there to stop malicious apps then? Aug 07 09:40:18 eduine, well... you ask for a job at Samsung and sign their NDAs Aug 07 09:40:25 of course, that would only work for Samsung devices :) Aug 07 09:40:36 Haha of course :) Aug 07 09:40:56 eduine, but basically, those permissions are meant only for OEM's and preloaded apps Aug 07 09:41:09 and singing keys for official ROM's are held by manufacturers Aug 07 09:41:13 yeah i see Aug 07 09:41:24 so, i'm gonna live, lunch time, but thanks again for all these informations! :) Aug 07 09:41:30 seeya later ;) Aug 07 09:45:13 I can't get Location.distanceBetween to work on my phone, it works on the emulator but the result on the phone returns distances which are way too high Aug 07 09:45:53 maybe you're not zoomed in enough :p Aug 07 09:45:57 just kidding, I have no idea Aug 07 09:50:21 I can do it the shitty way and do actual math Aug 07 09:50:38 but that's like 20 lines of code vs 3 Aug 07 09:58:58 eduine: i'm using the DatePicker but when i click on SET i have error on this line editText4.setText(dayOfMonth + "-" + (monthOfYear + 1) + "-" + year); and logcat is this:http://pastebin.com/eBdiaAQf Aug 07 10:04:57 any how guys 10x for the input Aug 07 10:09:55 Quinto did you initialize your editText well? like: EditText editText4 = (EditText)findViewById(R.id.myeditText) Aug 07 10:10:10 eduine: oh yes my error sorry! Aug 07 10:10:11 :( Aug 07 10:26:55 http://pastebin.com/7y8yGKYj can anyone tell me why results[0] and results[1] never return the correct distance Aug 07 10:27:09 they do on my emulator, but not in real life Aug 07 10:27:40 Hi Aug 07 10:27:57 Is it possible to use a shape as the app icon? Aug 07 10:28:42 MalekAlrwily: As in 'xml-defined'? Aug 07 10:28:49 yes Aug 07 10:28:56 Why do you want that? Aug 07 10:29:22 I want to make a rounded corners Aug 07 10:29:31 javnut: the distance is only in results[0] Aug 07 10:29:32 and I hate work on photoshop Aug 07 10:29:44 jush: neither of the distances are proper Aug 07 10:29:50 And you're unable to produce rounded cornes in Gimp/whatever else? Aug 07 10:30:14 can use android asset studio to create icons Aug 07 10:30:15 ok Aug 07 10:30:22 javnut: I've used that function a lot and never found any problem. How do you check it's correct? Aug 07 10:30:25 initially I had results = float[1] and I only outputted results[0] but the result was wrong as well Aug 07 10:30:45 canvs2321: What is this? Aug 07 10:30:46 jush: by actually going close to the nextPlace Aug 07 10:31:19 http://romannurik.github.io/AndroidAssetStudio/ Aug 07 10:31:34 javnut: hmmm maybe you can find some distance canculator online to check with the lat/lng pairs you're giving Aug 07 10:31:41 if I telnet a location that's close to nextPlace then it'll give me the correct result Aug 07 10:32:22 jush: I kind of have, I copied the coordinates of my actual physical location (because that app outputs it) Aug 07 10:32:37 thanks Aug 07 10:32:41 and sent those values to the emulator, it gave the correct distance Aug 07 10:32:53 but while I was there, it gave something like 1.95189324e Aug 07 10:33:39 what about testing with some hardcoded lat/lng? I really doubt that some manufacturer has changed the implementation of that function Aug 07 10:34:59 hmmm, I'll try that Aug 07 10:35:59 there is any way to improve speed of bitmap compression? Aug 07 10:36:17 I am having an issue with my cwac camera http://stackoverflow.com/questions/25142160/cwac-camera-why-my-simplecamerahost-saveimage-is-so-slow-am-i-doing-something?noredirect=1#comment39138401_25142160 Aug 07 10:41:15 did you verify lat and long on a real device were real numbers and not NAN or something? Aug 07 10:43:53 using the sqlite query method, is there a way to create this query: "SELECT * FROM tableA WHERE tableA._id IN (SELECT tableA_id FROM joint_table WHERE tableB_id = ?) Aug 07 10:49:51 How do you handle a navigation drawer with subareas, like titles etc.? Do you tell the listview adapter how to make titles or do you put the ListView as a child in a relativelayout? Aug 07 11:00:43 hi i am trying to start the android emulator and getting this error: WARNING : no emulator specified, defaulting to AVD_for_Nexus_S_by_Google Aug 07 11:00:43 Waiting for emulator... Aug 07 11:00:47 the emulator never starts Aug 07 11:01:14 How long did you wait? Aug 07 11:01:20 like5 min Aug 07 11:01:37 The emulator can be slow. Very slow. Aug 07 11:01:47 like 1h? Aug 07 11:01:50 You should see if you can use HAXM or Genymotion. Aug 07 11:02:00 flan3002: using phonegap Aug 07 11:02:03 duno if that works Aug 07 11:02:08 Well, I've seen it take +20 minutes to boot... Aug 07 11:04:26 Though it starts in less than minute with HAXM and feels faster than a real device. Aug 07 11:05:15 jush: it works for a hardcoded distance Aug 07 11:06:19 what's the absolute basic knowledge you need to code android apps, if you already know some java? Aug 07 11:07:01 pepee: understand the four basic components of android Aug 07 11:07:44 hardcoded location* Aug 07 11:07:45 pepee: Activity, Service, Broadcast Reciever, Content Provider Aug 07 11:08:02 pepee: More Java. Aug 07 11:08:09 :) Aug 07 11:08:27 bhargavg, ah, I just started with the basic activity part Aug 07 11:08:42 pepee: If you read examples, you'll be up to speed for basic things pretty soon, as long as you understand the Java part of it. Aug 07 11:08:45 but I'm really sloooow... and I just want to code a keyboard Aug 07 11:09:07 pepee: Maybe you... should start with something different than a keyboard... Aug 07 11:09:28 the xml stuff is a bit confusing, IMO Aug 07 11:09:39 flan3002, why? Aug 07 11:09:42 You'll get used to it. ^^ Aug 07 11:10:12 pepee: Because a keyboard doesn't usually exhibit the same characteristics as other apps. It's very specialized. Aug 07 11:10:31 ah Aug 07 11:10:38 even worse, then :/ Aug 07 11:11:18 I'm following the training from android.com: https://developer.android.com/training/index.html Aug 07 11:11:35 I wouldn't have guessed... -.- Aug 07 11:12:05 :) Aug 07 11:13:16 pepee: Agreed with bhargavg. Read up about Activity, Service, Broadcast Reciever, Content Provider. Before deliving into the tutorials. You'll understand it better. Aug 07 11:14:18 The tutorials always seem to tell you how to use a Activity in the one way descired but not actually teach you what an Activity is. Aug 07 11:14:29 described * Aug 07 11:15:40 yeah, that's really odd Aug 07 11:16:02 I can guess the concepts, but it'd be just a guess... Aug 07 11:17:21 pepee, my personal all-time favorite learning method: find an open-sourced app that's reasonably simple. compile it yourself. run it. take it apart, see why it does what it does. modify it, add features. Aug 07 11:17:48 from then on it's up to you Aug 07 11:17:51 pepee: Assumptions are the mother of all fuck ups, research and be clear how it works and what it does. Otherwise when you "guess" if you guess wrong it's allot harder to correct the understanding. Aug 07 11:18:34 ravilov, well, I took one of the samples and compiled it Aug 07 11:18:45 ravilov: That's one thing I've never tried, I must try that sometime. Aug 07 11:19:00 pepee, yeah that's cool, but IMO there's nothing like a real-life app Aug 07 11:19:04 but without following the tutorials, I would have had no idea about the XMLs Aug 07 11:19:33 pepee, the android documentation is actually a very good source btw Aug 07 11:20:08 my learning method is write some shit, build something, then start making it better Aug 07 11:20:58 MadMan2021: That's pretty much what I always tell people: Validate all your f-ing assumptions, so we don't have to. ^^ Oh, and don't come with the (broken) solution to us, but with the problem... Aug 07 11:21:39 bhargavg, that approach carries a potential risk of learning things wrong; a real-life app could teach you best practices too Aug 07 11:22:00 yeah, I'd feel pretty ashamed if I released something awfully bad Aug 07 11:22:47 javnut: then I guess there's something strange in the locations you're giving to the method. Aug 07 11:22:59 jush: I'm testing again Aug 07 11:23:12 ravilov: i agree, but if i start reading dependency injected code when i start learning java, it will take a looooot more time. I like to make mistakes myself and try to make them better Aug 07 11:23:25 pepee: If you know it's bad, you won't release it. The problem arises when you don't know it's bad. Aug 07 11:24:40 true Aug 07 11:28:46 bhargavg, true, it all depends on your past knowledge and experience, for me this works best Aug 07 11:30:17 I tend to just that app looks good, I wanna make it... WHY WONT IT WORK. Yup that's my development Aug 07 11:30:31 I tend to just say * Aug 07 11:31:36 jush: the locations I give it are pretty unspectacular Aug 07 11:31:53 at least the toString() versions of them are unspectacular Aug 07 11:42:26 adb is a command not found error. on debian 64bit because adb is a 32bit . what domi need to do to enable 32bit support on debian? Aug 07 11:44:21 does anyone know ? how to enable 32bit support on 64bit debain? Aug 07 11:44:48 abator: You'll probably need some 32 bit libs. Aug 07 11:44:58 abator: Let me have a look Aug 07 11:45:37 abator: Never mind it says command not found right ? Aug 07 11:45:39 thank you, please guide. i was trying but could not do it. Aug 07 11:45:57 MadMan2021: yes exactly, Aug 07 11:46:15 "command not found" is not an error you would receive because of incorrect platform Aug 07 11:46:15 abator: YOu have downloaded the tools? so you've downloaded ADB ? Aug 07 11:46:38 yes, i have downloaded adb, emulator etc Aug 07 11:46:56 abator, you are using debian because you have sufficient unix and command line knowledge, correct? Aug 07 11:47:13 if not, are you sure you want to use debian? Aug 07 11:47:18 HAve you tried to "cd" into the directory where adb is and do "./adb" ? Aug 07 11:47:41 abator: Also read ravilov. Very important. Aug 07 11:48:07 ravilov: some knowledge. i think i need commands to run and sometime i get help,from google. somehow i fix small problems Aug 07 11:48:54 anyway, tyvm, guys! Aug 07 11:49:04 MadMan2021: yes, the file does exist on the correct path. and the command file adb shows that its 32bit file Aug 07 11:49:04 pepee: Have fun! Aug 07 11:50:29 MadMan2021, I will :) Aug 07 11:50:38 again, "command not found" has nothing to do with architecture Aug 07 11:50:42 android studio question... how am I suppose to add external jar files? Aug 07 11:50:51 ravilov: i am sure i want to use debian. but depends on if there is no serious conflict between debian and android Aug 07 11:50:55 abator: What I ment was change directory to the place where the adb excutable is, Then try to run in there. For example I would do this Aug 07 11:50:55 cd /home/madman2021/androidtools/ Aug 07 11:50:55 ./adb logcat Aug 07 11:51:29 MadMan2021: i did that already and the error is command not found Aug 07 11:51:40 abator: You should really put it somewhere in your path or alter your path for it... Aug 07 11:51:49 With the dot and slash yes ? Aug 07 11:51:58 doesn't SDK come in a 64-bit flavor too though? Aug 07 11:52:10 ravilov: Pretty sure it does Aug 07 11:52:12 root@Abator:/home/imran/android/android-studio/sdk/platform-tools# adb Aug 07 11:52:12 bash: adb: command not found Aug 07 11:52:21 ./adb Aug 07 11:52:34 make sure you have "./" in front of adb. Aug 07 11:52:43 ./adb does the same Aug 07 11:52:49 ls -al adb Aug 07 11:53:39 root@Abator:/home/imran/android/android-studio/sdk/platform-tools# ./adb Aug 07 11:53:39 bash: ./adb: No such file or directory Aug 07 11:53:52 are you a bot? or a troll? Aug 07 11:54:10 first of all, why would you ever do anything like that as root?! Aug 07 11:54:10 root@Abator:/home/imran/android/android-studio/sdk/platform-tools# ls -al adb Aug 07 11:54:10 -rwxrwx--- 1 imran imran 1355536 Jun 21 20:09 adb Aug 07 11:54:13 how did you get root? sudo su? Aug 07 11:54:39 also, why are you running it as root anyway? Aug 07 11:54:53 sudo chmod 755 adb Aug 07 11:55:00 hmm, sorry, i think using root that way is not secure. but to avoid warnings i do it Aug 07 11:55:07 oh, I know remember, the udev problem... Aug 07 11:55:23 you didn't reply to my other question Aug 07 11:55:28 that problem is surely not solved by doing everything as root Aug 07 11:55:52 sudo chmod 755 adb, executed and no message was displayed Aug 07 11:56:02 Now try ./adb Aug 07 11:56:41 wait, you are running stable/old debian? Aug 07 11:56:41 bash: ./adb: No such file or directory Aug 07 11:56:52 working with OkHttp, how can I process a download as a stream? Aug 07 11:57:02 yes stable debain wheezy Aug 07 11:57:33 Just as a matter of interest, do "pwd" and send us output -_- Aug 07 11:57:48 hunter1 Aug 07 11:58:11 root@Abator:/home/imran/android/android-studio/sdk/platform-tools# pwd Aug 07 11:58:11 /home/imran/android/android-studio/sdk/platform-tools Aug 07 11:58:21 oh. wrong pwd Aug 07 11:58:32 (ignore me) Aug 07 11:58:39 abator: looks like a 64bit issue to me Aug 07 11:59:00 Command not found doesn't have anything to do with arch ? Does it ? Aug 07 11:59:07 i dont think so Aug 07 11:59:08 abator: what kind of os are you running? Aug 07 11:59:09 yes, look like 32bit issue or 64bit issue Aug 07 11:59:13 i run 64 bit ubuntu, it runs fine for me Aug 07 11:59:24 it's a typical 64 bit issue Aug 07 11:59:30 debian wheezy 64bit Aug 07 11:59:31 yeah, it's that old 64bit bug Aug 07 11:59:38 abator: add x86 to your arch Aug 07 11:59:39 probably.. https://bugs.launchpad.net/ubuntu/+source/ia32-libs/+bug/852101 Aug 07 11:59:47 and install the missing libraries Aug 07 11:59:53 you should be fine then Aug 07 11:59:57 siyb: please tell me how to do it Aug 07 12:00:03 abator, ldd ./adb Aug 07 12:00:21 abator: there is a tutorial on how to do that in the debian wiki Aug 07 12:00:32 root@Abator:/home/imran/android/android-studio/sdk/platform-tools# ldd ./adb Aug 07 12:00:32 not a dynamic executable Aug 07 12:00:37 abator, pretty sure people here can't tell you anything more than google can Aug 07 12:00:42 https://wiki.debian.org/Multiarch/HOWTO Aug 07 12:00:42 hmm Aug 07 12:00:54 try using "file" instead of "ldd" Aug 07 12:01:28 root@Abator:/home/imran/android/android-studio/sdk/platform-tools# file adb Aug 07 12:01:28 adb: ELF 32-bit LSB shared object, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.15, not stripped Aug 07 12:01:31 maybe he *should* try downloading the 64-bit SDK Aug 07 12:01:39 ravilov: that does not work Aug 07 12:01:40 abator, try installing libc6-i386 Aug 07 12:01:50 ravilov: i have had the same issue as well Aug 07 12:02:03 siyb, downloading the 64-bit SDK does not work? Aug 07 12:02:04 weird Aug 07 12:02:12 The adb is still 32bit i think Aug 07 12:02:13 ravilov: they compiled the binaries in 32bit Aug 07 12:02:24 oh Aug 07 12:02:29 it was typical to have this ussue in ubuntu 12.04 as well Aug 07 12:02:32 wouldn't know, I'm using 32-bit mint Aug 07 12:02:45 That's such a annoying error. Aug 07 12:02:57 apt-get install libc6-i386 , install is in progress Aug 07 12:03:00 I was sure it wasnt arch based error haha, Hats off to you guys Aug 07 12:03:07 abator: nononononono! Aug 07 12:03:16 oh Aug 07 12:03:20 there are instructions on the d.android.com site about this... Aug 07 12:03:25 abator: you _have to_ use the multiarch system Aug 07 12:03:35 abator: i've posted the link above Aug 07 12:03:43 do what siyb says Aug 07 12:03:57 That's the link https://wiki.debian.org/Multiarch/HOWTO Aug 07 12:03:57 http://developer.android.com/sdk/installing/index.html?pkg=tools Aug 07 12:03:57 yes, siyb that must be multiarch issue Aug 07 12:04:03 https://wiki.debian.org/Multiarch/HOWTO#line-126 Aug 07 12:04:06 and click on "troubleshooting ubuntu" Aug 07 12:04:24 yes, i must read that link now Aug 07 12:04:39 they really need to fix that then, "command not found" really shouldn't be a message for "wrong arch" Aug 07 12:04:56 by "they" I mean debian/bash/ubuntu/kernel devs Aug 07 12:05:21 it's already fixed in ubuntu Aug 07 12:06:38 siyb: should i remove the previous install of libc-i386 ? Aug 07 12:07:27 i then run this command as given in the link dpkg --add-architecture i386 Aug 07 12:08:48 abator: yes Aug 07 12:09:00 just follow the instructions on the debian wiki Aug 07 12:09:04 it's pretty trivial Aug 07 12:11:00 the only issue you might have later are configuration problems when upgrading (ambiguity - packages names) in which case you need to call dpkg --configure on each package for each architecture manually Aug 07 12:12:41 Sounds like fun... Aug 07 12:12:49 siyb: adb is running perfect after following the instructions in the link you gave. that solved my problem in minutes. spent a day on it Aug 07 12:13:05 flan3002, messing with debian IS fun :P Aug 07 12:13:07 abator: yw Aug 07 12:13:23 that's how you learn... Aug 07 12:13:44 flan3002: i am constantly trolling a debian dev in our channel regarding this issue Aug 07 12:13:47 I knew there's a reason I prefer to stick to good ol' 32-bit platform Aug 07 12:13:52 * flan3002 prefers ArchLinux. ^^ Aug 07 12:13:57 pepee: i am really afraid to play with debian because it then takes a lot of time to get back on tracks Aug 07 12:13:57 it's not too bad Aug 07 12:14:10 siyb: Which channel ;) Aug 07 12:14:10 abator, but you learn a lot too Aug 07 12:14:20 MadMan2021: private irc network :) Aug 07 12:14:30 siyb: :( Aug 07 12:14:36 siyb: That's no fun :( Aug 07 12:14:57 i am currently fighting with google+ login, can't figure out why it won't work ... i hate google for overengineering every single aspect of android -.- Aug 07 12:14:58 abator, unless you're on a very tight schedule, learning about your system is generally more valuable than time spent Aug 07 12:15:04 abator: Once you break linux a couple of hunderd times, You can fix it near enough instantly. It's just experiance :) Aug 07 12:15:16 flan3002, all the distros had this problem at the time Aug 07 12:15:27 in fact, arch f'd up big time... Aug 07 12:15:28 Hello Aug 07 12:15:51 pepee: Sure, getting adb to be friend with AL was... interesting. ^^ Aug 07 12:15:54 Any idea how to notify my contentobserver when my contentprovider failed to synchronize ? Aug 07 12:15:56 no doubt i learn a lot that way, but really my focus is android , you said ravilov Aug 07 12:16:17 pepee: any big change messes things up, systemd is the biggest issue on debian atm (at least in my experience) Aug 07 12:16:40 tbh, that's why I prefer ubuntu Aug 07 12:16:53 abator, android is unix/linux too, any knowledge you gain with linux will surely come in handy with android as well Aug 07 12:17:01 ^^^ Aug 07 12:17:16 hello there... i'm supposed to install something called 'google play services' using the sdk manager, it's supposed to be under 'extras', it isn't. any ideas? Aug 07 12:18:20 siyb: it took me 3 days again to setup debain and still few things has to be installed. but i found debain the best flavor. it never crashed Aug 07 12:18:33 abator: What ever you do, Never force uninstall glibc Aug 07 12:19:00 any one could help me with a contentprovider ? Aug 07 12:19:12 oh right, abator, check if glibc is still there... Aug 07 12:19:17 abator: It never crashed? That shouldn't be your crteria of choice for rating distros... Aug 07 12:19:21 haha pepee: P Aug 07 12:19:33 ravilov: that is right. i will keep playing with linux. i got rid of win and it on vm only Aug 07 12:19:39 just to be sure Aug 07 12:19:42 :P Aug 07 12:19:52 ok, let me check please Aug 07 12:20:28 Nine_9, did you check those boxes at the bottom of the window? Aug 07 12:21:19 MadMan2021: how to check glibc? Aug 07 12:21:32 do you know the basics of using dpkg? Aug 07 12:21:48 if not, you really should google and read some general stuff asap Aug 07 12:21:51 ldd --version should work Aug 07 12:22:16 dpkg, Never herd of it ;) Aug 07 12:22:38 peppe: you mean the ones to show 'updates/new', 'installed', etc? Aug 07 12:22:46 Nine_9, yeah Aug 07 12:22:49 yep Aug 07 12:23:01 yes, i know basic of dpkg and mostly i use apt-get Aug 07 12:23:04 abator, dpkg -l | grep libc Aug 07 12:24:35 http://paste.debian.net/114134/ Aug 07 12:25:16 now apt-get is not working and i think because of 32bit is enabled. Aug 07 12:25:26 abator: what does it say Aug 07 12:25:33 i bet it's the configuration issue Aug 07 12:25:34 ;) Aug 07 12:25:35 command not found Aug 07 12:25:43 wat? Aug 07 12:26:35 root@Abator:/home/imran/android/android-studio/sdk/platform-tools# apt-file search libc Aug 07 12:26:35 bash: apt-file: command not found Aug 07 12:27:02 abator: apt-file has its own package Aug 07 12:27:06 you know that, right? Aug 07 12:27:07 apt-get is not working too Aug 07 12:27:11 apt-get install apt-file Aug 07 12:27:13 ok Aug 07 12:27:21 try apt-get moo Aug 07 12:27:26 oh , let me try that first Aug 07 12:27:40 but i am sure aft-file was working Aug 07 12:29:09 damn it i'm on #ubuntu Aug 07 12:29:59 apt-file update is in progress. Aug 07 12:30:55 can anyone here tell me what is the quick hotkey to open xml files Aug 07 12:31:01 like the ctrl-n for java files Aug 07 12:31:08 it's annoying me to death that i cannot open xml Aug 07 12:31:10 like that Aug 07 12:31:34 vim Aug 07 12:32:16 i confusing point for me, will i be enabling 32bit / 64bit depending on the app i will be installing or is it automatic thing by debain Aug 07 12:32:43 Hi all. I am trying to reference the field R.id.fetch as described in this documentation (http://support.flurry.com/index.php?title=Publisher/Code/Android) but eclipse tells me R.id.fetch cannot be resolved. What do I need to do to resolve this? Aug 07 12:33:00 hello cumpsty Aug 07 12:33:03 how are you doing? Aug 07 12:33:16 to open a reference to a resource you will also need an instance of the context you're working in. Aug 07 12:33:21 Ivru, I guess you should ask again... :) Aug 07 12:33:32 In which class are you trying to get that reference? Aug 07 12:34:08 jvrodrigues: I'm fine thanks. you? Aug 07 12:34:14 jvrodrigues: AndroidApplication Aug 07 12:34:16 Very good Aug 07 12:34:20 Any idea how to notify my contentobserver when my syncadapter failed to synchronize ? Aug 07 12:34:26 pepee, let's try... Aug 07 12:34:31 cumpsty, the class you're trying to do this in, what does it extend? Aug 07 12:34:35 and what is the constructor Aug 07 12:34:56 i'd better ask how to install AS on a redhat Aug 07 12:35:01 which extends Application Aug 07 12:35:30 ah Aug 07 12:35:32 why not try Aug 07 12:35:49 before that Aug 07 12:35:55 sorry extends Activity Aug 07 12:35:56 https://github.com/libgdx/libgdx/blob/master/backends/gdx-backend-android/src/com/badlogic/gdx/backends/android/AndroidApplication.java Aug 07 12:36:05 lemme check Aug 07 12:36:10 while i sip a bit of my coffee Aug 07 12:36:26 implements AndroidApplicationBase Aug 07 12:36:27 in which line Aug 07 12:36:30 okay :) Aug 07 12:36:32 do you need the resource? Aug 07 12:36:46 no I'm extending that Aug 07 12:37:16 in onCreate(Bundle bunlde) Aug 07 12:37:36 ah, the new immersive mode <3 Aug 07 12:39:11 the resource you want Aug 07 12:39:15 what type is it? Aug 07 12:41:24 Button Aug 07 12:41:39 hi, i found a strange bug or similar bug. 1) create container (the father) 2) after i get meausrement i create a child inside this container. In android 4.2+ it's work but in android 4.1 not Aug 07 12:41:40 Button fetchAd = (Button)findViewById(R.id.fetch); Aug 07 12:41:47 this is the code: http://pastebin.com/J0AR1Y7M Aug 07 12:42:38 i solved with a little pause of 200ms.. but it's strange Aug 07 12:43:15 cumpsty Aug 07 12:43:20 have you tried cleaning the project_ Aug 07 12:43:25 also Aug 07 12:43:27 check in the xml Aug 07 12:43:27 flan3002: that sounds good idea. but i used fedora and mint for sometime both were crashing. and i was not able to install ubuntu. and after all that when debain installed i found it stable. actually, i am still not a smart user of linux. i cannot find real difference in all those flavors of linux Aug 07 12:43:49 if you have id = @+id/fetch instead of id = @id/fetch Aug 07 12:44:19 i need to stop pressing enter after each couple of words... Aug 07 12:46:57 jvrodrigues: lol, I have that problem Aug 07 12:47:16 there you go Aug 07 12:48:11 jvrodrigues: Is there a good article explaining what should be in there? I never added anything to the manifest, but I wasn't told to in the API documentation I'm referring to. Aug 07 12:49:55 jvrodrigues: something like this? http://pastebin.com/a7etVMHd Aug 07 12:50:09 with id/fetch? Aug 07 12:50:20 siyb: apt-file search libc now work. now i think i can run my hello app from android studio. i am glad my problems are solved Aug 07 12:50:47 may i did not install apt-file Aug 07 12:51:06 may be*** Aug 07 12:51:36 nevermind. Think i found it. Aug 07 12:51:51 Thanks for your help :) Aug 07 12:52:12 C Aug 07 12:52:21 Hmm... Aug 07 12:54:10 Rust... Aug 07 12:54:14 cumpsty, it should be in the documentation. basically +id adds the id to the R class, while id just gets one thats already there. Aug 07 12:56:27 jvrodrigues: do I put the code under in the manifest? Aug 07 12:56:33 no no Aug 07 12:56:36 you leave it in your layout Aug 07 12:56:43 the xml layout Aug 07 12:57:02 it should be in the layout that has the contentview of the activity Aug 07 12:57:18 or else it will return null, because it won-t find the view Aug 07 12:59:02 http://developer.android.com/guide/topics/resources/more-resources.html#Id Aug 07 13:00:46 hmm okay, I need to do some tweaking then. Because I don't have XML layout by default in this framework. Aug 07 13:00:57 jvrodrigues, ravilov: Thanks for help :) Aug 07 13:01:54 cumpsty, you don-t need an xml though... You can just set Button fetch = new Button(this) Aug 07 13:02:05 then you can pretty much do whatever you want with it Aug 07 13:02:12 've realized something.. Aug 07 13:02:18 Hi! I'm about to develop my first android app. I'm not new to programming in general. I have latest android studio (not eclipse, ugh). Most guides/tutorials are for eclipse+adt. Is there anything you would recommend that gives a good overview of "how android works"? Simple tutorials that show various features or something. :) Aug 07 13:02:25 A programmer is actually a tool Aug 07 13:02:40 it converts Caffaine into an App Aug 07 13:02:40 except taking it out for dinner. Believe me i tried, waited for 2 hours in the restaurant and nothing. Aug 07 13:02:41 really Aug 07 13:02:41 MapMan, android developer webpage has great guide Aug 07 13:02:43 s Aug 07 13:02:52 OverCoder: lool Aug 07 13:03:00 xd Aug 07 13:03:01 jvrodrigues: Okay, will try that. Thanks Aug 07 13:03:22 MapMan, www.thenewboston.com -> been a professional android dev for almost a year now and started with that website Aug 07 13:03:53 actually its www.thenewboston.org, my bad Aug 07 13:04:05 lol i see Aug 07 13:04:06 TNB is discredited by so many people for learning Android Aug 07 13:04:10 lol Aug 07 13:04:12 Vogella is easily the best place for tutorials for me though Aug 07 13:04:18 meh Aug 07 13:04:23 most 3rd party tutorials are out of date Aug 07 13:04:27 ^ Aug 07 13:04:27 what's wrong with official android tutorials? Aug 07 13:04:28 Anthaas: +1 Aug 07 13:04:32 or just give terrible advice obsoleted by modern libraries :/ Aug 07 13:04:46 ravilov: nothing Aug 07 13:04:48 xd Aug 07 13:05:16 Also, JakeWharton is now your best friend - he has so many libraries which make your life easier. Look up Picasso, for instance. Aug 07 13:05:22 jvrodrigues: gonna check it out Aug 07 13:05:41 Mavrik: yes, I actually am on the site, but most tutorials are for ADT and thats a bit problematic ;) Aug 07 13:05:50 railov: actually, Android Offical Tutorials assume you are very familiar with java and programming, Other tutorials help you a bit more.. Aug 07 13:05:55 IMO Aug 07 13:06:06 MapMan: That shouldn't be problematic. Aug 07 13:06:18 Well, if you-re not very familliar with java programming maybe thats where you should start... Aug 07 13:06:19 well, i am facing a big problem my emulator is not working Aug 07 13:06:23 MapMan, I don't get it... ADT is just a plugin for Eclipse which has practically nothing to do with actual app code O.o Aug 07 13:06:30 what could be thpe orlbme? Aug 07 13:06:31 Mavrik: +1 Aug 07 13:06:33 i am using linux Aug 07 13:06:36 maybe it doesnt Aug 07 13:06:36 OverCoder, official tutorials have a specific purpose, and the purpose is NOT to teach you programming Aug 07 13:06:39 MapMan, yes, some buttons are slightly different Aug 07 13:06:41 i press on start and nothing happenss Aug 07 13:06:43 but that's about it... Aug 07 13:06:43 for 1h or more Aug 07 13:06:49 the point is im unfamiliar with concepts how android apps are structured and stuff Aug 07 13:07:05 the tutorials often assume a lot of stuff and sometimes rely on ADT functions Aug 07 13:07:11 hmm, yeah, sadly my slides that explain that aren't in english :/ Aug 07 13:07:16 thats why I asked if you have any good guides other than those Aug 07 13:07:23 im not saying they're useless to me ;) Aug 07 13:07:24 jvrodrigues: yes, i know that, it just learn you the Android API stuff, i know that, but that's actually the difference in other tuts Aug 07 13:07:24 MapMan, ADT functionality is built into AS Aug 07 13:07:28 so I don't really see a problem there Aug 07 13:07:41 MapMan, this might help you: http://developer.android.com/guide/components/fundamentals.html Aug 07 13:07:46 raillov: sorry meant you Aug 07 13:08:01 idk, basic android programming is really straight forward Aug 07 13:08:02 Starting emulator for AVD 'AVD_for_Nexus_S_by_Google' and nothing happens Aug 07 13:08:08 ok ill check it out Aug 07 13:08:08 OverCoder, you should try autocomplete, you have yet to spell my nick correctly Aug 07 13:08:25 MapMan, if you're unfamiliar with basic concept, maybe it's not yet time for you to dig into code...? Aug 07 13:08:31 auto complete? Aug 07 13:08:37 it doesn't do that Aug 07 13:08:38 wtf Aug 07 13:08:42 anyone!? Aug 07 13:08:56 whats the diff between apply plugin : "android" and "com.android.application" ? Aug 07 13:08:57 OverCoder, you must be new to irc too... Aug 07 13:08:58 I wanted to start out with a setup wizard for my app, a few slides that you swipe and input some data. A lot of apps have that. I started reading about activities and fragments Aug 07 13:09:24 new to this IRC, but not to IRC generally raillov Aug 07 13:09:26 MapMan, maybe you're aiming a bit too high for your first go Aug 07 13:09:28 railov ^ Aug 07 13:09:37 you're still doing it wrong, OverCoder Aug 07 13:09:48 ahahah just press tab dude Aug 07 13:09:53 seriously Aug 07 13:09:58 railov: pfft Aug 07 13:10:06 * ravilov gives up, hopeless case Aug 07 13:10:38 * OverCoder feelling sad Aug 07 13:10:42 xd Aug 07 13:10:56 railov actually has a better sound to it. Aug 07 13:11:07 just sayan' Aug 07 13:11:13 well alright Aug 07 13:11:21 thanks for help, ill be back with specific problems Aug 07 13:11:39 what is the point of choosing a nick name such as jvrodrigues Aug 07 13:12:02 #android-tab Aug 07 13:12:07 OverCoder, to get the girls man... to get the girls Aug 07 13:12:28 One of the many girls we have in this channel... ^^ Aug 07 13:12:29 hi, how can i check if a file exists on the android device with adb in a bash script ? Aug 07 13:12:30 lel Aug 07 13:12:44 cumpsty, no xml layout in which framework? Aug 07 13:13:10 donnib you can't actually Aug 07 13:13:13 i am trying to have a bash script on my mac that checks if a file exists on the android then copy it but i have problems checking if the file exists Aug 07 13:13:15 hmmm Aug 07 13:13:25 unless you run a terminal and run an app Aug 07 13:13:34 yea you can Aug 07 13:13:37 Why not, OverCoder? Aug 07 13:13:39 ok, what if a program is running ? Aug 07 13:13:49 if the file is in the android storage Aug 07 13:13:56 i know the bundle which one i create Aug 07 13:13:59 you can just point the script to the drive android is mounted in Aug 07 13:13:59 adb devices shows nothing Aug 07 13:14:01 and search there Aug 07 13:14:02 donnib, adb shell test -e /path/to/file Aug 07 13:14:03 should it show theemulators? Aug 07 13:14:05 why adb_ Aug 07 13:14:09 ? Aug 07 13:14:14 yes you can. try to pull it. you can check if it then exists... Aug 07 13:14:25 adb devices Aug 07 13:14:27 hi, what is the best way to create an image viewer which will show me images by swiping from left to right and right to left? Aug 07 13:14:50 EugenA: Use the gallery? Aug 07 13:14:54 I have imageview and I created animations Aug 07 13:15:17 Segmentation fault (core dumped) Aug 07 13:15:33 when i do emulator -verbose -avd TestPhone Aug 07 13:15:34 your core has issues Aug 07 13:15:40 what to do? Aug 07 13:15:41 EugenA: You can look up for examples, easy to find Aug 07 13:15:51 ravilov: hmm that returns nothing in both case where the file is and not Aug 07 13:16:17 donnib, it is not supposed to print out anything Aug 07 13:16:23 donnib, adb shell test -e /path/to/file ; echo $? Aug 07 13:16:27 EugenA: library that might work for you https://github.com/daimajia/AndroidImageSlider Aug 07 13:16:29 or better yet Aug 07 13:16:32 ravilov: so how do i know ? Aug 07 13:16:44 donnib, how often do you actually write shell scripts? Aug 07 13:16:48 EugenA, http://developer.android.com/reference/android/widget/HorizontalScrollView.html Aug 07 13:17:05 EugenA: see http://www.androidhive.info/2013/09/android-fullscreen-image-slider-with-swipe-and-pinch-zoom-gestures/ Aug 07 13:17:05 ravilov: very rare :) Aug 07 13:17:50 donnib you can make a java app easily just to check that out xd Aug 07 13:17:56 I'm learning android development, so I'd like to create simple image viewer. But I'm not sure I'm doing things right. It's working.. but it would be nice to see examples. Thanks for links Aug 07 13:19:04 currently I use animation to hide out imageView, than change source and than hide in it again Aug 07 13:19:49 donnib, yeah I can tell Aug 07 13:20:03 donnib, if (adb shell test -e /path/to/file); then echo "yes"; else echo "no"; fi Aug 07 13:20:23 any can help me with volley lib? Aug 07 13:21:38 how i can get header of response on volley lib? Aug 07 13:22:06 if i use an input stream to dl a file, where is that stream saved if I have no output stream? Is it discarded or stored until perhaps a certain size then truncated? Aug 07 13:22:29 Jesperhead: An InputStream is not saved. Aug 07 13:22:34 interesting Aug 07 13:22:50 I've created a custom style with custom draweables, the problem is that when i apply the theme the works fine but everything is white (but visible) Aug 07 13:22:53 Jesperhead: An InputStream can be uses to read data. What you do with it is up to you... Aug 07 13:23:01 it should be orange Aug 07 13:23:12 Im trying to make a speed test and i get very accurate results the first time but it seems to vary a short number of re-tests later Aug 07 13:23:33 ravilov: that seems to work, where do i put ! if i want to change the expression ? Aug 07 13:23:43 Jesperhead, InputStream is an abstract memory object Aug 07 13:24:22 ty I assumed it wasnt "cached" anywhere. Just trying to identify why my tests are varying Aug 07 13:24:39 Jesperhead: Lots of factors. Aug 07 13:24:46 donnib, you want to negate the condition? Aug 07 13:24:51 yup Aug 07 13:24:53 right? Wifi, self connection, server connection Aug 07 13:24:54 Jesperhead, it could very well be buffered but not cached Aug 07 13:25:00 Jesperhead: If you really don't care about the data, discarding it implicitly is okay. Aug 07 13:25:12 Jesperhead: But... Aug 07 13:25:16 themes.xml http://pastebin.com/LD7r5wbY styles.xml http://pastebin.com/n5P3A4Tf Aug 07 13:25:32 donnib, if ( ! adb shell ... ); then Aug 07 13:26:15 yeah the data doesnt matter. a garbage jpg Aug 07 13:28:14 Jesperhead: You might still want to validate it... Aug 07 13:28:27 ravilov: i wrote this http://pastebin.com/AduyUM5F Aug 07 13:28:38 ravilov: is there a way I can clear this buffer post test to as to maybe not interfere with the next test? Aug 07 13:28:53 but i keep getting No such file or directory on adb command which is weird Aug 07 13:29:04 so as to* Aug 07 13:29:12 donnib: this is Obj-C right? Aug 07 13:29:14 i have few actions before the while that uses the $ADB and they can find it Aug 07 13:29:16 flan3002: forgive my ignorance, what do you mean by validate it? Aug 07 13:29:20 no, bash on mac Aug 07 13:29:57 anyone knows if there is a command line tool while debugging for eclipse like the one in xCode? Aug 07 13:30:15 click the bug icon top Aug 07 13:30:20 how i can get header of response on volley lib? Aug 07 13:30:22 Jesperhead: You don't just care that some data is there, you care that valid data arrived. Probably a hashsum and you'll be good... Aug 07 13:30:46 ravilov: any ideas what i am doing wrong ? Aug 07 13:30:57 donnib, I don't see where I mentioned you should put a period in front Aug 07 13:31:13 I also don't see where I mentioned braces, I used parenthesis Aug 07 13:31:23 ravilov: well i didn’t have it in the begining but added later, i tried without first Aug 07 13:31:41 braces have an entirely different meaning Aug 07 13:31:42 ty flan Aug 07 13:32:00 Birk_: unsure but see this http://stackoverflow.com/questions/138511/what-are-java-command-line-options-to-set-to-allow-jvm-to-be-remotely-debugged Aug 07 13:32:21 why you need to debug from command-line anyway? Aug 07 13:32:22 ravilov: i replaced the bracelets and removed the period but still same problem Aug 07 13:33:17 donnib, I also used plenty of whitespace, that is no accident Aug 07 13:33:51 donnib, http://pastebin.com/EqbLx2pa Aug 07 13:33:53 OverCoder: Its not debugging from command line. I want to be able to debug on eclipse but run some commands over variables. Aug 07 13:34:14 OverCoder: something like open a shell view inside eclipse and run commands there Aug 07 13:34:59 Birk_, I don't think eclipse has support for that, your best bet is a separate terminal/command window Aug 07 13:35:03 Birk_: i don't *think* that's possible as i searched for that Aug 07 13:35:04 ravilov: ok so far so good (the spaces made a difference), was not aware of that, thx Aug 07 13:35:34 donnib, for future reference, when it comes to scripts/programs it is probably best to copy literally everything verbatim Aug 07 13:35:35 Birk_: what do you mean "run command over variables". Aug 07 13:35:48 ravilov: thx, will do Aug 07 13:35:56 rgr: like myapp Aug 07 13:36:18 myapp being what? a shell script or what? Aug 07 13:36:20 rgr: e.g. in windows you use "ping 192.168.1.1" Aug 07 13:36:29 ping is an app Aug 07 13:36:43 I think the problem is my bad english. I dont know how to express my self lol Aug 07 13:36:55 Can I ignore TransactionToLargeExceptions when they occur only during monkey tests? Aug 07 13:37:01 Birk_: not, you are good at it Aug 07 13:37:02 try using pictures instead? :p Aug 07 13:37:03 Using the word "app" is wrong. but anyways. Just open a shell. Aug 07 13:37:21 on xCode you can open a view and type "print x.toString()" for example Aug 07 13:37:28 rgr: so what should i use Aug 07 13:37:36 ok. so nothing like ping then. You want to execute java. Aug 07 13:37:39 Syzygy_, that is too general and kinda up to you Aug 07 13:37:45 I'm back, Apparantly my IRC client decided to explode Aug 07 13:38:02 You would use the watch window and add expressions I guess. Aug 07 13:38:02 rgr: lol i was wrong Aug 07 13:38:03 Birk_, that would be called the debug view, more specifically watch/eval window Aug 07 13:38:28 I know eclipse has watch, not sure about eval Aug 07 13:38:30 MadMan2021: wb Aug 07 13:38:33 Yes. Theres no compulsion to answer if you dont know. Guessing is worse than saying nothing in a tech forum. Aug 07 13:38:47 ravilov: but Im able to execute varX.toString() and get the result, for example Aug 07 13:38:51 why guess if it has or not? Google is 2 seconds away.... Sheesh. Aug 07 13:39:16 ravilov, I've never seen a TransactionTooLargeException "in the wild", as in, we never got a crashlog like that. But during a monkey test run it just happened. Reading up on it it can happen when several actions are executed at the same time and considering how fast monkey clicked I assume that was the case. So should I even bother fixing it? Aug 07 13:39:40 during monkey test run? Aug 07 13:39:42 xd Aug 07 13:39:57 OverCoder, you should utilize google more often Aug 07 13:40:12 like i dont.. Aug 07 13:40:12 xd Aug 07 13:40:26 you should also read the android docs more often then? Aug 07 13:40:29 ravilov: watch IS eval. You can add any expression. Jesus... Aug 07 13:41:08 ravilov: well i have not read them all but reading a bunch of pages each day Aug 07 13:41:16 OverCoder, it's a tool shipped with adb, basically it randomly clicks all over the place for you Aug 07 13:41:16 trying to read them all, it has really useful info Aug 07 13:41:22 so a page of cross purposes for something as basic as "can I evaluate an expression". Yes you can. Google up "watch in eclipse". http://help.eclipse.org/indigo/index.jsp?topic=%2Forg.eclipse.jdt.doc.user%2Freference%2Fviews%2Fexpressions%2Fref-addwatch.htm Aug 07 13:41:42 Syzygy_: Thanks for the explaination, but the name made me laugh lol Aug 07 13:42:03 Syzygy_, then I guess it's safe to ignore them, unless your real-life user is *that* fast or your real-life device is *that* slow and laggy Aug 07 13:42:46 OverCoder, simple google, 2 seconds: http://developer.android.com/tools/help/monkey.html Aug 07 13:42:47 I think it comes from the "a million monkeys with typewriters will eventually write all of shakespears works" thingy, except they'll crash your app instead. Aug 07 13:42:48 watch do what I want Aug 07 13:43:01 thanks Aug 07 13:43:09 rgr, ok dude, I wasn't sure, sheesh Aug 07 13:43:15 ravilov: i know that google is 2 seconds away, but i didn't know monkey is a tool Aug 07 13:43:16 lol Aug 07 13:43:32 that's exactly when you should google Aug 07 13:43:33 i mean it's weird to name a tool monkey Aug 07 13:43:38 I've seen weirder Aug 07 13:43:44 like what Aug 07 13:43:45 xd Aug 07 13:43:55 the explanation for the name i just gave sounds valid imho D: Aug 07 13:44:07 sorry about the beginner question, but always i create one default java class (java.lang.Object) to support my main activity i cant compile, am i doing something wrong? Aug 07 13:44:11 the palm version was called gremlins Aug 07 13:44:26 Syzygy_, it could very well be it Aug 07 13:44:33 teslla: post your code in pastebin,com Aug 07 13:44:34 pastbin.com Aug 07 13:44:42 owww damn Aug 07 13:44:49 pastebin.com Aug 07 13:44:49 teslla, that doesn't make much sense Aug 07 13:45:05 teslla: ^ Aug 07 13:45:24 http://www.folklore.org/StoryView.py?story=Monkey_Lives.txt Aug 07 13:45:30 I just wish it wouldn't constantly activate airplane mode Aug 07 13:45:47 Syzygy_, can't you customize/configure it somewhat? Aug 07 13:45:51 i need to reconnect sec Aug 07 13:45:57 or turn up the volume and start playing deathmetal while I'm at work Aug 07 13:46:15 or else your airplane mode button must take up half the screen lol Aug 07 13:46:29 Syzygy_, yeah, monkeys are unpredictable like that Aug 07 13:46:33 ravilov: what doesn't make sense? create a default java class on android project or the fact that the IDE doesn't compile the code by doing that? Aug 07 13:46:34 it keeps opening the quick setting menu Aug 07 13:47:11 teslla, the fact you're trying to do anything using a mere default Object Aug 07 13:47:14 k back Aug 07 13:47:32 I mean that doesn't seem like it'll get you far... Aug 07 13:48:01 3mpty is an "empty" slot or just a normal person? Aug 07 13:48:02 Leeds, nice read Aug 07 13:48:17 what would an "empty slot" be? Aug 07 13:48:30 something like admin or something Aug 07 13:48:42 ... Aug 07 13:48:52 online all time? Aug 07 13:48:55 weird Aug 07 13:49:00 yes you are Aug 07 13:49:06 ravilov: let's say i'm tring to migrate one app that i already have in regular java to android, i have a lot of java classes already written and a want to use them in the android project Aug 07 13:49:36 teslla, ok, based on what the classes do and how they're written, that shouldn't be too much problem Aug 07 13:49:45 s/based/depending/ Aug 07 13:51:23 Syzygy_: can i use monkey to draw a specific gesture? i mean cheat in a game for example? Aug 07 13:51:23 xd Aug 07 13:51:27 how do i make my context menu black when my theme is light Aug 07 13:51:50 iffa: you should make a style and apply it *i think* Aug 07 13:51:50 ravilov: just to test i created the file "test.java" in the src folder, with a test void method, just with a println, when a try to run, it always fails Aug 07 13:52:19 i dont know how to apply a style to it thouh Aug 07 13:52:23 well you can't do that in android Aug 07 13:52:26 iffa Aug 07 13:52:32 teslla: you can't run it directly if you do that anyway, you should run it in mainactivity Aug 07 13:52:35 jvrodrigues: ? Aug 07 13:52:37 use a dialog instead Aug 07 13:52:44 thats an idea Aug 07 13:52:46 thanks jvrodrigues Aug 07 13:52:50 System.out.println is not useful there Aug 07 13:52:58 that's why i'm here for Aug 07 13:53:15 teslla, if you're trying to create a classic static main() method like in plain java, that will do nothing Aug 07 13:53:19 that's not how android apps work Aug 07 13:53:35 teslla: you might want to use Toast instead Aug 07 13:53:45 er Aug 07 13:53:46 no Aug 07 13:53:55 I never said System.out.println() doesn't work Aug 07 13:53:57 why not, similar to println at least Aug 07 13:54:04 I only said creating a static main() makes no sense Aug 07 13:54:15 how can println work, at aleast teach me Aug 07 13:54:16 xd Aug 07 13:54:23 why wouldn't it work? Aug 07 13:54:25 teslla android java is very diferent from regular java, you will probably have to rewrite everything Aug 07 13:54:36 becuase there's no where it can print the result? does nothing afaik Aug 07 13:54:42 jvrodrigues, hey, it's not *that* different Aug 07 13:54:44 teslla, go read d.android.com Aug 07 13:54:51 but any interface towards the user will have to be refactored Aug 07 13:54:51 ravilov: no, i'm just calling the test method in the test class from my main activity, expecting that my dialog print something, as it prints when i call the println from the main activity directly. Aug 07 13:54:55 teslla, then come back and ask questions about Aug 07 13:55:09 it's not that you will have to rewrite everything - but you *will* have to fit it into the Android UI and lifecycle Aug 07 13:55:17 teslla, hm ok, I see... I think Aug 07 13:55:33 teslla, but to make it perfectly clear, you should post some code Aug 07 13:55:36 teslla: Java is a bit different when you come to android, but you will get familiar fast as you understand java, it won't be a trouble Aug 07 13:56:10 basically, it's Java Jim, but not as you know it Aug 07 13:56:16 OverCoder, just for the record, I use System.err.println() for debugging all the time, I really don't see why you think that wouldn't work Aug 07 13:56:22 http://www.youtube.com/watch?v=FCARADb9asE Aug 07 13:56:44 ravilov: :| Aug 07 13:56:55 whatever that emote means Aug 07 13:57:19 ravilov: how many pages are there in developers.android.com? Aug 07 13:57:30 a whole library Aug 07 13:57:30 damn it Aug 07 13:57:34 i need years to read it all Aug 07 13:57:49 well you better start then, right? lol Aug 07 13:57:51 and i the end i create a pussy android app Aug 07 13:57:54 xd Aug 07 13:58:05 ravilov: You should still use Log.e or similar, even though System.err will also appear in your log... Aug 07 13:58:09 how will that work ? Aug 07 13:58:38 gordon_: that's why i shut up Aug 07 13:58:39 flan3002, this is just for quick&dirty debugging, when I don't feel like adding import android.os.Log (or whatever package it's in) ;) Aug 07 13:58:53 Ugh... Aug 07 13:59:06 flan3002 cringes Aug 07 13:59:06 ravilov: silly Aug 07 13:59:13 thanks for the help guys, but nobody answered my question yet. if i cant call a method from a regular java class from my main activity, what can i do make it happen? create a service wold be solution? Aug 07 13:59:17 guys, pls, i need to know, what-s the equivalent of CTRL-N to navigate to xml files? Aug 07 13:59:30 teslla no, far away Aug 07 13:59:41 teslla, did you paste some code like I told you to? Aug 07 13:59:51 teslla: you need a service only when you want to do background Aug 07 13:59:54 teslla you can call a static method from your main activity Aug 07 14:00:02 ugh Aug 07 14:00:08 you can call whatever you want in any way you want Aug 07 14:00:11 so long as you do it right Aug 07 14:00:39 railov is right! Aug 07 14:00:47 ravilov: what does that even mean? Aug 07 14:00:50 ravilov: not *whatever* you want, at least you can't use swing afaik xd Aug 07 14:00:56 rgr, which part? Aug 07 14:01:05 jvrodrigues: ok, i think now we are geting closer to the answer, i will try that, thanks. Aug 07 14:01:25 does anybody know anything about configuring adbd, and getting it to listen on some other ip addresses? Aug 07 14:01:29 jvrodrigues said he can call a static method, I'm saying he's not limited to just static methods Aug 07 14:01:41 thats like saying "you can do it if you can do it". Why bother saying that?!? Aug 07 14:01:50 rgr, what's your problem? Aug 07 14:01:55 ah, yeah, you can call non-static methods if you have a reference to the instance of the object the method is in Aug 07 14:02:04 forget it. Aug 07 14:02:08 gladly Aug 07 14:02:21 but i thought this was basic java Aug 07 14:02:22 anyways Aug 07 14:02:33 how can i navigate to my xml files? Aug 07 14:02:38 it is totally basic java and better in #java. Aug 07 14:02:44 its slowly killing me Aug 07 14:02:54 which ide? Aug 07 14:02:56 what do you mean "navigate"? Aug 07 14:02:59 android-studio Aug 07 14:03:09 the equivalent of ctrl-n Aug 07 14:03:10 aren't they inside your project? Aug 07 14:03:20 the popup where you write the name of the class Aug 07 14:03:30 i want the popup where i write the name of my xml Aug 07 14:03:38 you want to create a new xml? Aug 07 14:03:40 instead of scrolling up and down hundreds of files Aug 07 14:03:45 jvrodrigues: ctrl-shift-n Aug 07 14:03:46 that's not navigating to your xml files... Aug 07 14:03:47 jvrodrigues: you mean with ctrl-n (New)? Aug 07 14:04:02 will search among all files Aug 07 14:04:10 whoa, you have hundreds of xml files?! Aug 07 14:04:11 thanks heinrisch, you're the man Aug 07 14:04:11 sounds like teslla doesn't know java Aug 07 14:04:11 yes it IS navigating to his xml files. Aug 07 14:04:18 :) Aug 07 14:04:19 xd Aug 07 14:04:28 so im a girl? Aug 07 14:04:31 pfft Aug 07 14:04:35 xd Aug 07 14:04:52 the key being the big menu item called "Navigate". ie how to move around your classes and resources etc. Aug 07 14:04:53 ravilov, yes i do. Aug 07 14:04:53 jvrodrigues, just remap keybindings Aug 07 14:05:00 intellij - so hard Aug 07 14:05:22 its not hard, its complex. Lots of functionalities, takes a while to get used to it Aug 07 14:05:35 IMO less than Eclipse Aug 07 14:05:47 DO NOT REMAP BINDINGS IN INTELLIJ Aug 07 14:05:50 ravilov: for how much time you work with android/java development? Aug 07 14:05:55 gordon_: hey, it gets fun! Aug 07 14:06:08 gordon_: especially when you combine Emacs keymap with IdeaVim! Aug 07 14:06:10 I like doing ^j for Java class and ^L for fiLe Aug 07 14:06:23 jvrodrigues, in eclipse I just click in the navigation pane and start typing, it automatically starts searching Aug 07 14:06:29 I <3 ideavim Aug 07 14:06:32 OverCoder, hm? Aug 07 14:06:42 it's the 1 reason why I'm using intellij at all Aug 07 14:06:47 ravilov, thats one click too many, the less i touch the mouse, the more productive i am, i hate taking my hand off the keyboard Aug 07 14:06:54 pfn: nah Aug 07 14:07:00 real coders dont "click" anywhere : they keep the fingers on the keyboard ;) Intellij is great for that : one of its basic design cores is keyboard navigation. Aug 07 14:07:05 ravilov: in what time you started developing android/java Aug 07 14:07:06 jvrodrigues, I agree, I just haven't bothered yet to figure out the shortcut Aug 07 14:07:09 ravilov, you can do the same in as Aug 07 14:07:13 sorry there was a typo Aug 07 14:07:20 rgr: Real coders use butterflies anyway... Aug 07 14:07:24 hit alt 1, then start typing Aug 07 14:07:32 flan3002: so emacs Aug 07 14:07:32 ctrl-shift-a search among all commands Aug 07 14:07:36 rgr: Which doesn't require clicking anyways... Aug 07 14:07:47 gordon_, nah what Aug 07 14:07:59 * OverCoder tired Aug 07 14:08:06 http://xkcd.com/378/ Aug 07 14:08:19 reference do this by flan3002 Aug 07 14:08:20 pfn: Yeah, there's a macro for that. Up to writing one in VimL? Aug 07 14:09:12 macro for what, butterflies? Aug 07 14:09:20 Yeah... Aug 07 14:09:33 nah, viml sucks Aug 07 14:09:40 You don't say... ^^ Aug 07 14:09:42 how i can get header of response on volley lib? Aug 07 14:09:53 Though I've never tried ELisp... Aug 07 14:10:02 only thing I like about emacs is elisp Aug 07 14:10:05 most of the time ~5 users chatting, where are the rest? Aug 07 14:10:17 i mean hundreds should really make a noisy IRC Aug 07 14:10:26 OverCoder: lurking Aug 07 14:10:30 Coding/Sleeping/Eating/Having fun? Aug 07 14:10:36 OverCoder, i'm assuming they're working, instead of slacking like us bunchg Aug 07 14:10:45 * p_l just finished a job interview Aug 07 14:10:54 :X Aug 07 14:11:46 p_l, interviewing someone not looking for a new job, right? Aug 07 14:11:53 emacs is great. elisp fun. erc (the emacs irc client) is super. Aug 07 14:12:01 pfn: looking for a job Aug 07 14:12:05 should i make Pro features an separate app or in-app purchase? Aug 07 14:12:20 p_l, already? I thought you landed one not long ago Aug 07 14:12:44 pfn: looking for something non-remote Aug 07 14:12:49 need to get out of country Aug 07 14:13:03 need? heh Aug 07 14:13:15 I <3 remote work Aug 07 14:13:17 TeamViewer? xd Aug 07 14:13:18 lol Aug 07 14:13:31 I haven't had a commute in over a year Aug 07 14:13:32 OverCoder: conference call + shared writepad Aug 07 14:14:02 p_l, you could just move... since its remote work Aug 07 14:14:19 pfn: and I want something non-remote Aug 07 14:14:31 I see Aug 07 14:14:31 p_l something similar to Windows Azure? Aug 07 14:14:32 it's just... remote working doesn't exactly work for me, I found Aug 07 14:14:37 OverCoder: no Aug 07 14:14:55 OverCoder: there's a bunch of multi-user writepads, including even Google Docs Aug 07 14:15:32 did I just see windows azure being mentioned in an android dev channel? Aug 07 14:15:33 take the whole thing with you? Aug 07 14:15:33 xd Aug 07 14:15:36 * ravilov checks temperature in hell Aug 07 14:15:45 lol Aug 07 14:15:46 ravilov: the lowest ring of hell is very cold anyway Aug 07 14:15:56 hell is frozen Aug 07 14:15:58 azure is actually meant to be pretty decent Aug 07 14:16:10 after MS's written few programs for linux Aug 07 14:16:16 and steam is on linux too Aug 07 14:16:24 MS did? Aug 07 14:16:30 ravilov: they stopped calling it "windows azure" a while ago... Aug 07 14:16:37 OverCoder: first is skype Aug 07 14:16:44 second is hyper-v driver for linux kernel Aug 07 14:16:47 OverCoder: actually, MS used to write software for Unix as well as selling a Unix variant... Aug 07 14:16:50 :| Aug 07 14:17:07 didnt know that even though i use Ubuntu Aug 07 14:17:20 p_l: xenix? Aug 07 14:17:21 xd Aug 07 14:17:29 that was a *long* time ago... Aug 07 14:17:29 do you know what ubuntu stands for in old african's dialect ? OverCoder ? Aug 07 14:17:31 Leeds: yep Aug 07 14:17:48 gordon_: no Aug 07 14:17:52 gordon_: "I couldn't install debian", right? Aug 07 14:17:55 "I cannot insall debian" Aug 07 14:18:03 *install Aug 07 14:18:05 p_l: yes Aug 07 14:18:08 it was a long time ago when I started working at SCO, more than 15 years ago... Aug 07 14:18:17 * p_l shuuuns Aug 07 14:18:26 shun the SCO! ;P Aug 07 14:19:15 thinking of starting a new app project, i'm really unsure what should i make xd Aug 07 14:20:01 Leeds, what's it called now? Aug 07 14:20:10 Hello, I'm looking at a decompiled APK, all the R.id. references are translated to numbers, how can I know which number correspondes to which resource? Aug 07 14:20:13 can i use sensors to see how much the phone is far from the ground? Aug 07 14:20:32 OverCoder: not really Aug 07 14:20:41 socket: open the R file and search there using Ctrl-F Aug 07 14:20:50 p_l: too bad.. Aug 07 14:21:12 OverCoder, you can use the accelerometer to know when to play the "ouch!" sound Aug 07 14:21:22 just before the device crashes into the ground Aug 07 14:21:39 lol Aug 07 14:21:43 i will make that Aug 07 14:21:45 lol Aug 07 14:21:52 once the phone falls he will say ouch xd Aug 07 14:21:53 OverCoder: there's no R file (as far as I can see) I don't have the original code anymore just the APK which I have decompiled Aug 07 14:22:08 OverCoder: Have fun testing... Aug 07 14:22:15 lol Aug 07 14:22:16 OverCoder: But I think it already exists... Aug 07 14:22:27 flan3002: show me i wanna install it Aug 07 14:22:28 xd Aug 07 14:22:36 feels funny xd Aug 07 14:22:42 I won't google it, takes too long. Aug 07 14:22:47 lol Aug 07 14:24:50 this might seem so basic, but, if for example i want a value to change everytime gyro values change, how can i do that? i mean if use a "for" loop it will freeze the whole app Aug 07 14:26:07 callbacks Aug 07 14:26:18 or you put all the code in a loop (as it's done in games) Aug 07 14:26:42 Or you use a background thread, if you feel like it... Aug 07 14:26:44 really? games do that? Aug 07 14:26:46 Syzygy_: Thanks a lot Aug 07 14:26:53 need to look at android game development Aug 07 14:26:53 i just didn't know what to google lol Aug 07 14:27:13 flan3002: it's silly to use a lot of threads to do multiple things such as this Aug 07 14:27:27 * flan3002 sighs. Aug 07 14:27:32 i mean i might end up with a lot of threads Aug 07 14:27:51 jvrodrigues, maybe not all, but most games use a game loop and do all their stuff on every frame. Aug 07 14:27:58 OverCoder: I don't know how the gyro API is done. Aug 07 14:28:07 Syzygy_, that makes sense i guess Aug 07 14:28:14 OverCoder: http://developer.android.com/reference/android/hardware/SensorListener.html Aug 07 14:28:15 But... there are very valid reasons to use threads... Aug 07 14:28:44 what's wrong with "a lot of threads"? Aug 07 14:28:53 even though i will use Gyro, i'm not really talking only about it, anyway thanks for the link i''m reading them.. Aug 07 14:29:00 I guess that depends on what 'a lot' is... Aug 07 14:29:01 everything should be fine so long as you're managing them like you should Aug 07 14:29:13 well yeah, also so long as you don't seriously overdo it Aug 07 14:29:14 ravilov: i've seen at a time that a lot makes some slowdown, but not really sure Aug 07 14:29:21 In case you're *not* doing a game, and actually only do care if the motion sensor's TYPE_ROTATION_VECTOR changes. Aug 07 14:29:44 OverCoder, you actually got my nick right! cograts Aug 07 14:29:47 congrats* Aug 07 14:30:03 tab magic Aug 07 14:30:08 ravilov: i really didn't notice the "v" all the time lol Aug 07 14:30:14 i think i need a glasses Aug 07 14:30:14 gordon_, yeah maybe he finally got it Aug 07 14:30:15 xd Aug 07 14:30:34 you could also tone down with all these emotes, are you like 12? Aug 07 14:30:42 i got it after you said autocomplete thing xd Aug 07 14:31:33 i still think railov sounds better. Though, to be honest, is very close to gaylov. So we might want to go back to ravilov Aug 07 14:31:49 hey guys Aug 07 14:32:03 Hello there Aug 07 14:32:04 I want to set the audio source to Jack 3.5 explicitly, is there anyway to do so? Aug 07 14:32:08 how can i kill a bug standing on my screen without turning the screen into four pieces Aug 07 14:32:12 xd Aug 07 14:33:04 OverCoder, http://imgur.com/a/J9URj Aug 07 14:33:25 that's my laptop :P Aug 07 14:33:35 lol how Aug 07 14:33:38 i dont know Aug 07 14:33:40 loooolz Aug 07 14:33:42 but it got me a lot of karma Aug 07 14:33:45 Sicp it would be possible through the audiomanager Aug 07 14:33:48 four pieces...?? Aug 07 14:33:59 I know that through AM I can set setSpeakerOn Aug 07 14:34:02 Sicp, isHeadSetOn() Aug 07 14:34:10 yes, and if it is? Aug 07 14:34:20 setAudioSourceToJack() <-- is what Im looking for Aug 07 14:34:40 as far as i know, it should do that automatically by default Aug 07 14:34:42 Scip so the ant it dead and will stay like this forever? Aug 07 14:34:51 damn it Aug 07 14:34:59 yea, I stopped seeing it now, its behind the edges Aug 07 14:35:12 it appears and reappears, magnetism Aug 07 14:35:31 damn ant lol Aug 07 14:36:34 ant makes me sad Aug 07 14:36:42 sad makes me sad Aug 07 14:37:14 sad me me ravilov Aug 07 14:37:15 xd Aug 07 14:37:19 jvrodrigues, the problem I'm facing is that when I plug the jack in while recording audio, the whole app freezes and I get an Audio Manager permission denial on setSpeakerOn() Aug 07 14:37:24 while I havent even called that anywhere Aug 07 14:37:32 then it goes back to recording fine, from the jack Aug 07 14:37:37 this big pause is whats killing me! Aug 07 14:38:27 What happens if my app called a sensor that is not present on the device? for e.g. some devices dosn't have gyro, what will happen? Aug 07 14:39:54 probably some exception Aug 07 14:40:07 Sicp, sounds like a permission issue for me. Aug 07 14:40:12 to me* Aug 07 14:40:18 for something that Im not even using Aug 07 14:40:31 but Ive added the permissions, all the possibly related ones, namely audio edit settings Aug 07 14:40:53 and there is no isHeadSetOn() Aug 07 14:41:00 ravilov: so i should make a test if the device have that sensor before i run the code? Aug 07 14:41:01 there's isWiredHeadSetOn() and it's deprecated Aug 07 14:41:05 isnt even responding Aug 07 14:42:21 OverCoder, you should just generally always try/catch Aug 07 14:42:44 ravilov: k, thx Aug 07 14:46:04 Please help... Aug 07 14:46:07 OverCoder, actually no. Aug 07 14:46:10 any app to read the docs without using the website Aug 07 14:46:15 OverCoder, you should set in the manifest Aug 07 14:46:35 that way only applications that have the sensor will be able to install your app Aug 07 14:46:48 but in any case always try/catch those things Aug 07 14:46:50 i encode image and i put into database... but have problem decoding it and return back to image... please help Aug 07 14:47:02 jvrodrigues: that seems to be the actual soloution, seems ravilov is mroe familiar with java without android Aug 07 14:47:29 jvrodrigues: Thanks alot btw Aug 07 14:47:35 no worries Aug 07 14:47:40 i encode image and i put into database... but have problem decoding it and return back to image... please help Aug 07 14:47:43 hackable, post code Aug 07 14:48:01 okay Aug 07 14:48:01 hackable: ^ Aug 07 14:48:03 public static Bitmap decodeBase64(String input) Aug 07 14:48:03 { Aug 07 14:48:03 byte[] decodedByte = Base64.decode(input, Base64.DEFAULT); Aug 07 14:48:03 return BitmapFactory.decodeByteArray(decodedByte, 0, decodedByte.length); Aug 07 14:48:03 } Aug 07 14:48:09 no! Aug 07 14:48:20 use www.pastebin.com Aug 07 14:48:32 that's the code i'm using to convert to image from base64 encode Aug 07 14:48:37 poste the encode method too Aug 07 14:49:00 i used sqlite database broswer Aug 07 14:50:06 i'm really really tired and i'm about to die, think i should sleep even thought it's morning Aug 07 14:50:15 gn Aug 07 14:50:39 http://pastebin.com/zkjsQe6W Aug 07 14:51:07 Yes... OverCoder, you need to sleep but before you do.. kindly help me resolve the error Aug 07 14:51:13 hackable, this seems correct, provided the image was correctly encoded and stored to begin with Aug 07 14:51:33 does anyone know of an app that will fire the "pinch" action in another app for devices that don't have touchscreens? Aug 07 14:51:34 this is what is display on logcat D/skia﹕ --- SkImageDecoder::Factory returned null Aug 07 14:51:44 I can't fine zoom in my browser with a keyboard or mouse Aug 07 14:51:52 hackable: if i really had the answer i would LOVE to help you Aug 07 14:52:10 Thanks ravilov, see the error displaying... D/skia﹕ --- SkImageDecoder::Factory returned null Aug 07 14:52:16 but im still a little more than a begnner Aug 07 14:52:27 its possible to set the compression type used when calling the video record intent? Aug 07 14:52:42 hackable, then I guess you need to inspect your byte array, make sure there is a valid encoded image in there Aug 07 14:53:00 or is *anything* in there at all, maybe the byte array is null too? Aug 07 14:53:15 or I need to transcode the video when receiving it? Aug 07 14:53:33 i'm checking now... trying to get the encoded String... Aug 07 14:53:58 c|oneman, not sure, I'd say no since doing multitouch is a problem in android emulator as well Aug 07 14:54:33 c|oneman, I'd say using some API is your best bet, hopefully there is some Aug 07 14:54:48 Hello guys and girls, Is it just me or does the link account button never work for linking your old admob account to the new ? Aug 07 14:55:18 i've check, the string is there... Aug 07 14:55:24 is there a way to stop a monkey test? Aug 07 14:55:27 Anybody having any experience with admob not wanting to show my ad campaign? I've got 0 displays so far Aug 07 14:55:27 is it valid though? Aug 07 14:55:34 Syzygy_, from the shell maybe? Aug 07 14:55:43 hackable, how do you encode? Aug 07 14:55:48 <-- not using ads of any sort Aug 07 14:55:52 yeah, but what would I enter? Aug 07 14:56:18 Yeah, but it's not in my app. It's I want to get people to see my app with ads Aug 07 14:56:30 encode it using SQLite Database broswer Aug 07 14:56:43 Yes.. i think its valid Aug 07 14:56:58 Let me copy it for you to see Aug 07 14:57:03 wut? Aug 07 14:57:29 Syzygy_, killall monkey? lol, not sure Aug 07 14:57:33 check the output of ps Aug 07 14:57:35 ah ok Aug 07 14:57:41 data:image/jpeg;base64,/9j/4QAYRXhpZgAASUkqAAgAAAAAAAAAAAAAAP/sABFEdWNreQABAAQAAABkAAD/4QNfaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wLwA8P3hwYWNrZXQgYmVnaW49Iu+7vyIgaWQ9Ilc1TTBNcENlaGlIenJlU3pOVGN6a2M5ZCI/PiA8eDp4bXBtZXRhIHhtbG5zOng9ImFkb2JlOm5zOm1ldGEvIiB4OnhtcHRrPSJBZG9iZSBYTVAgQ29yZSA1LjAtYzA2MCA2MS4xMzQ3NzcsIDIwMTAvMDIvMTItMTc6MzI6MDAgICAgICAgICI+IDxyZGY6UkRGIHhtbG5zOnJkZj0iaHR0cDovL3d3dy5 Aug 07 14:57:41 3My5vcmcvMTk5OS8wMi8yMi1yZGYtc3ludGF4LW5zIyI+IDxyZGY6RGVzY3JpcHRpb24gcmRmOmFib3V0PSIiIHhtbG5zOnhtcE1NPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvbW0vIiB4bWxuczpzdFJlZj0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL3NUeXBlL1Jlc291cmNlUmVmIyIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bXBNTTpPcmlnaW5hbERvY3VtZW50SUQ9IjAwQzJEM0M3ODY4MjZBQjkxQTcwQUM4NTdDNUQxRjFEIiB4bXBNTTpEb2N1bWVudElEPSJ4b Aug 07 14:57:41 XAuZGlkOjEzMkY1OEZBMEJEMjExRTM4RUI3RjZCRTAyNjEwNkYwIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOjEzMkY1OEY5MEJEMjExRTM4RUI3RjZCRTAyNjEwNkYwIiB4bXA6Q3JlYXRvclRvb2w9IkFkb2JlIFBob3Rvc2hvcCBDUzYgKFdpbmRvd3MpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6NkIxNTNCOEM0QTBBRTMxMTk3MjdBQkY2NzZEOTYwMTkiIHN0UmVmOmRvY3VtZW50SUQ9IjAwQzJEM0M3ODY4MjZBQjkxQTcwQUM4NTdDNUQxRjFEIi8+IDwvcmRmOkRlc2N Aug 07 14:57:41 yaXB0aW9uPiA8L3JkZjpSREY+IDwveDp4bXBtZXRhPiA8P3hwYWNrZXQgZW5kPSJyIj8+/+0ASFBob3Rvc2hvcCAzLjAAOEJJTQQEAAAAAAAPHAFaAAMbJUccAgAAAgACADhCSU0EJQAAAAAAEPzhH4nIt8l4LzRiNAdYd+v/7gAOQWRvYmUAZMAAAAAB/9sAhAABAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAgICAgICAgICAgIDAwMDAwMDAwMDAQEBAQEBAQIBAQICAgECAgMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwMDAwP/wAARCAFoAWgDAREAAhEBA Aug 07 14:57:41 xEB/8QBogAAAAYCAwEAAAAAAAAAAAAABwgGBQQJAwoCAQALAQAABgMBAQEAAAAAAAAAAAAGBQQDBwIIAQkACgsQAAIBAwQBAwMCAwMDAgYJdQECAwQRBRIGIQcTIgAIMRRBMiMVCVFCFmEkMxdScYEYYpElQ6Gx8CY0cgoZwdE1J+FTNoLxkqJEVHNFRjdHYyhVVlcassLS4vJkg3SThGWjs8PT4yk4ZvN1Kjk6SElKWFlaZ2hpanZ3eHl6hYaHiImKlJWWl5iZmqSlpqeoqaq0tba3uLm6xMXGx8jJytTV1tfY2drk5ebn6Onq9PX29/j5+hEAAgEDAgQEAwUEBAQGBgVtAQIDEQQhEgUxBgAiE0FRBzJhFHEIQoEjkRVSoWIWMwm Aug 07 14:57:41 xJMHRQ3LwF+GCNCWSUxhjRPGisiY1GVQ2RWQnCnODk0Z0wtLi8lVldVY3hIWjs8PT4/MpGpSktMTU5PSVpbXF1eX1KEdXZjh2hpamtsbW5vZnd4eXp7fH1+f3SFhoeIiYqLjI2Oj4OUlZaXmJmam5ydnp+So6SlpqeoqaqrrK2ur6/9oADAMBAAIRAxEAPwDf49+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r Aug 07 14:57:42 3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737 Aug 07 14:57:42 r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+69173 Aug 07 14:57:43 7r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+6917 Aug 07 14:57:43 37r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691 Aug 07 14:57:44 737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+691737r3Xvfuvde9+6 Aug 07 14:57:49 stahp Aug 07 14:57:53 lol Aug 07 14:57:58 hackable, this is not acceptable here, please use pastebin or similar service Aug 07 14:58:06 dafuq :p Aug 07 14:58:09 i'm sorry dear Aug 07 14:58:15 also, this is not valid base64 because it has a prefix Aug 07 14:58:28 hey everyone, is there a well-known pattern for getting rid of a foreground service's notification after a crash? Aug 07 14:58:29 you need to get rid of "data:image/jpeg;base64," Aug 07 14:58:52 base64 decoder is meant for raw base64 data, not for web-like urls Aug 07 14:58:54 Really??? is that the problem Aug 07 14:59:00 really? Aug 07 14:59:01 i see Aug 07 14:59:02 i.e. if my foreground service crashes, its notification stays around forever, and i dont want this Aug 07 14:59:30 explore the string using "," Aug 07 14:59:42 s1gmab3ta, thats a good question. But if the notification is still around, that means the app is still open Aug 07 14:59:57 hackable, that seems unsafe, I'm not sure but I think "," can appear within the data as well Aug 07 15:00:08 is that the right solution by exploding it Aug 07 15:00:19 explode the string using "," Aug 07 15:00:23 jvrodrigues, that's actually probably the case. in most cases it's not my foreground service crashing, but the activity i use to interact with it Aug 07 15:00:27 I just answered you... Aug 07 15:00:50 exploding is always the right solution Aug 07 15:00:58 hackable: what field type are you using to store your image in the database? Aug 07 15:01:01 God bless you for me... Please be aware of EBOLA Aug 07 15:01:16 s1gmab3ta, but if the activity crashes, you want the foreground process to also crash? Aug 07 15:01:25 I'm Using the String data type Aug 07 15:01:27 hackable, that seems unsafe, I'm not sure but I think "," can appear within the data as well Aug 07 15:01:28 why? Aug 07 15:01:50 jvrodrigues, not necessarily "crash", but yes I want it to go away Aug 07 15:02:05 so what's the alternative to remove data:image/jpeg;base64 Aug 07 15:02:31 can i use substring Aug 07 15:02:34 yes Aug 07 15:02:39 jvrodrigues, i think long-term it would probably be better for my activity to intelligently know that the service already exists and not try to start a new one, but this sounds harder than just killing the service Aug 07 15:02:45 I'd find the first comma then remove everything before it Aug 07 15:02:46 I wish I could explode this monkey script... Aug 07 15:02:46 yoou could store it as byte array or a blob. though storing in the db is wrong anyway in most cases. Aug 07 15:02:51 it keeps logging itself out. Aug 07 15:03:01 s1gmab3ta, thats quite easy, just turn the service into a singleton Aug 07 15:03:12 and stats playing death metal. Aug 07 15:03:14 * ravilov has successfully stored images in databases without any problems whatsoever Aug 07 15:03:17 Is there any option to continue running an android app when it is minimized? Aug 07 15:03:24 or at least, a static method that returns its instance if it has one. Aug 07 15:03:27 ivali, services Aug 07 15:03:29 good idea, thanks ravilov Aug 07 15:03:37 hm, you can do that with services? Aug 07 15:04:05 s1gmab3ta, i don't see why not. Aug 07 15:04:13 thats a terrible idea. There has to be built in filters to remove prefix data. Aug 07 15:04:35 also why are you storing it as a string? This is really inefficient. Aug 07 15:04:38 jvrodrigues, interesting, i never thought of that. i guess the "no instance exists" case would consist of the relevant intent.startservice call, then Aug 07 15:05:03 s1gmab3ta, that's where i'd start Aug 07 15:05:04 see the first answer here : http://stackoverflow.com/questions/9357668/how-to-store-image-in-sqlite-database Aug 07 15:05:24 blobs have size limitations Aug 07 15:06:12 but it would probably be a good design to shut the service off in case its activity also crashes.. hmmm... Aug 07 15:07:47 Does anyone have experience with expansion files for the play store? This is my first crack at it -- I've created an OBB file using JOBB, transferred it manually to my device at /mnt/shell/emulated/0/Android, and am trying to mount it with a StorageManager instance. The weird thing is, that Environment.getExternalStorageDirectory() returns "storage/emulated/0" which doesn't even exist on my device... Aug 07 15:08:14 So I can't get a path to mount the OBB file. Aug 07 15:08:36 Holo IRC seems good, any suggestions though? Aug 07 15:09:31 Google's docs explain the concept of expansion files, yet don't go too much into the implementation. I found this as well http://stackoverflow.com/questions/22368251/how-to-make-android-extension-file-using-android-studio/22431752#22431752 -- looked promising, but I can't see how it would hook itself into the starting of the app to see if it needs to download the expansion file or not... Aug 07 15:09:51 ravilov: yes they do. And? Obviously you look at those limitations. If its too big then chances are it shouldnt be in the db in the first place. Aug 07 15:10:20 highcup, my S4 returns its internal storage directory when i call getExternalStorageDirectory. Aug 07 15:10:27 im thinking its an hardware problem? Aug 07 15:10:38 all things have "limitations". And using the first knee jerk solution like storing a bitmap as a string in the database is another one. Aug 07 15:11:12 rgr, if you say so Aug 07 15:11:19 jvrodrigues that's why I hard code sometumes Aug 07 15:11:23 rgr, ikr, store it as a blob stop being silly Aug 07 15:11:29 clearly you know everything all of a sudden Aug 07 15:11:39 rgr i always store images as strings Aug 07 15:11:49 jvrodrigues, I'm testing ona nexus 7, the storage seems to be fine -- I have other apps installed that make use of expansion packages that function correctly.. so I think the storage is functioning properly. Aug 07 15:12:13 overcoder, but the paths differ based on the device manufacturer, no? Aug 07 15:12:49 It does, but not when you do some checks, right? Aug 07 15:13:25 It"s silly though Aug 07 15:14:08 Hmm Aug 07 15:17:14 Hi all, question: Bitmap overlay = Bitmap.createScaledBitmap(source, 1080, 1920, false); doesnt scale the bitmap to 1080 1920 pixels, there is still space on the left and right. Why is that? Aug 07 15:17:22 and yeah, screen is definately 1920 x 1080 :D Aug 07 15:17:49 using getDefaultDisplay() to get the display, and Display.getSize to convert it to a Point Aug 07 15:18:07 what size is your source bitmap though? Aug 07 15:18:20 20x20 Aug 07 15:18:30 px Aug 07 15:18:46 ... Aug 07 15:18:55 With SQLiteOpenHelper I have noticed that it calls onCreate even if the database exists Aug 07 15:19:02 I do say so. Storing it as a string is pointless and inefficient. And I dont know everything but I also dont think I know everything and offer solutions out of my backside when I clearly dont know something about it. Aug 07 15:19:03 Is this expected behavior? Aug 07 15:19:04 why would that matter though, if i scale it to 1080 1920? Aug 07 15:19:21 1 Aug 07 15:19:22 oops Aug 07 15:19:49 how to generate sha1 from image.Image? Aug 07 15:19:58 wouldnt going from 20x20 to 1080x1920 throw off the height/width ratio? Aug 07 15:20:11 or is that intended? Aug 07 15:20:18 ow yeah sure, but its just a black, half transparent bitmap Aug 07 15:20:20 ThomQ, what are you actually trying to achieve? Aug 07 15:20:24 ah Aug 07 15:20:41 Getting a half transparent bitmap Aug 07 15:20:47 50 % opacity Aug 07 15:20:50 to fill the screen Aug 07 15:20:57 hm, if it's really just a solid color, it might be more efficient to use canvas? Aug 07 15:21:05 (and paint) Aug 07 15:21:14 ravilov: sounds like a background image. its a popular web design technique to use small images and just scale them. because smaller Aug 07 15:21:42 bg or not doesnt matter either... ignore that i said that Aug 07 15:21:49 Yeah perhaps, but this is just a quick way of trying to get a result. I could draw a canvas, but I was just wondering why it wouldnt scale correctly Aug 07 15:22:10 Jesper, that is where i got the practice from though :D Aug 07 15:22:20 hi, I want to make an app that has a menu on the top, and when pressing on a button in the menu - it'll open the corresponding web page with Intent. I used framelayout for both the menu and the other part (container). How can I tell it to open the web page (with the intent) inside of the container framelayout? Aug 07 15:23:12 meital, perhaps you mean a Webview? Aug 07 15:23:33 either webview or launch new browser. Aug 07 15:23:41 ThomQ: so I read a little bit about webview, but I really want to do it with intent Aug 07 15:24:01 is there a way to make my searchView only move action items to overflow when it is expanded? right now if I set an action item to ifRoom, the searchView (which is set to always) will move the ifRoom items to overflow even when not expanded Aug 07 15:25:47 it looks like it doesn't do that for the other items defined with it (in the fragment menu), but only for the items in the activity menu Aug 07 15:30:48 rgr, I don't know what's gotten into you, but if you have a problem with me or my advice, grow some balls and take it with me directly instead of challenging everything I say and attacking me like a jerk Aug 07 15:35:31 My problem is this : I did challenge you and you come back and say "if you say so" like a petulant child. Three times in the last hour or so youve answered something either completely wrong or just misguided. From "that isnt navigation" to using nasty hacks to remove encoding prefixes. I point out blobs are almost certainly better than strings if you MUST store bitmaps in sqlite and you come back with "there is a limitation of 1 gig" as Aug 07 15:35:31 if somehow no one else would realise this well documented feature and this somehow makes using strings all fine. There is enough wrong info and bad advice out there without adding to it. Aug 07 15:35:54 anyway. end of. Aug 07 15:36:38 what a jerk Aug 07 15:37:46 lol Aug 07 15:39:33 Does anyone have experience on MMS forwarding Aug 07 15:39:34 ? Aug 07 15:40:14 probably not Aug 07 15:40:51 as i need to forward last recived MMS Aug 07 15:41:29 currently I am using https://github.com/klinker41 lib Aug 07 15:41:37 didnt think people still used mms Aug 07 15:42:02 yeah but you know clients Aug 07 15:42:12 That link is to a user profile, are you saying you are using them to do mms for you? Aug 07 15:42:12 what about snapchat forwarding ? Aug 07 15:42:23 I still use mms btw Aug 07 15:42:27 yes i am able to forward MMS using this lib Aug 07 15:42:33 but below 4.4 Aug 07 15:42:42 and above 4.0 Aug 07 15:42:45 oh Aug 07 15:42:57 but i need some good solutions Aug 07 15:42:59 what is your min/max sdk Aug 07 15:43:05 you just got me interested Aug 07 15:43:11 min2bhandari: That link is to a user profile, are you saying you are using them to do mms for you? Aug 07 15:43:16 currentl min 4.0 and mx 4.4 Aug 07 15:43:32 oh sorry Aug 07 15:43:40 well Aug 07 15:43:43 https://github.com/klinker41/android-smsmms Aug 07 15:43:46 theres a content provider for mms Aug 07 15:44:10 i guess thats how your app can access mms Aug 07 15:44:17 now, for forwarding Aug 07 15:44:32 i am using receiver for that Aug 07 15:44:49 to catch incoming MMS Aug 07 15:45:14 and this explains how to send it http://stackoverflow.com/questions/2972845/how-to-send-image-via-mms-in-android Aug 07 15:45:17 quite easy imho Aug 07 15:45:36 When something like dalvik.system.NativeStart.main is at the start of the crashlog, does that mean the app just started? Aug 07 15:48:31 Here is the full crashlog: http://pastebin.com/5pYSKFAz Aug 07 15:48:41 http://goo.gl/uzY2oJ Aug 07 15:48:59 i'm getting a warning, “not annotated parameter overrides @NotNull parameter”. but none of the super methods have this @NotNull. where does this @NotNull come from? Aug 07 15:49:33 it's ClickableSpan.updateDrawState Aug 07 15:49:58 yiati, not the same issue. I'm just wondering where the crash originates from Aug 07 15:51:27 i checked the URL its just for image Aug 07 15:52:37 to go in depth i have to analysis the comment provided by Damian Kołakowski Aug 07 15:52:43 http://stackoverflow.com/questions/2972845/how-to-send-image-via-mms-in-android Aug 07 15:59:37 I got the expansion package thing to load finally, except I'm loading HTML files that reference images/css, so looks like paths are broken *smh* Aug 07 15:59:54 Syzygy__, not necessarily, that's just the stack trace, it means whatwver method caused the crash can be traced all the way back to zygote Aug 07 16:01:02 zygote would be app start? Aug 07 16:01:17 guess I'll google it first. Aug 07 16:01:39 yes zygote is the dalvik VM instance Aug 07 16:02:44 that's weird because app start should automatically start a few activities and there shouldn't be a way to directly go through everything to the DB as far as I understand it. Aug 07 16:02:51 Is it possible to contact admob.com ? Aug 07 16:03:15 I've tried different browser, the link account just does not do anything. Aug 07 16:03:29 I've tried different browserS*, the link account just does not do anything. Aug 07 16:03:38 DB? Aug 07 16:03:55 jvrodrigues, in the case that my activity crashes, Android kills the process the app is running in, and apparently all the background threads with it. however, in android's task manager, I can still see my foreground service in the "running" tab (not as a cached process either) Aug 07 16:04:27 jvrodrigues, so it's kind of a rock and a hard place. the service is of no use to me and i might as well start a new one, but i don't seem to have any way of killing the old one, short of starting the new one Aug 07 16:04:31 which comes with its own problems Aug 07 16:04:38 ravilov, database Aug 07 16:05:42 Which API version should I use? I have 19, should I upgrade to 20? Aug 07 16:05:50 or 20 L? Aug 07 16:06:35 Syzygy__, well I'm sure all that happens, but there's gotta be something in the far back that actuall makes it happen, right? something to manage the activity and such Aug 07 16:06:58 your activities do not replace thr zygote, they run *inside* it Aug 07 16:07:58 and a part of thr zygote are certain java classes that then sometimes end up in stack traces Aug 07 16:08:20 yeah, I just find it weird that the stack trace would end up like that. Aug 07 16:08:52 well, it's not weird ;) Aug 07 16:09:01 s1gmab3ta, ah ofc, services keep on running until android decides to shut them off. I remember now, it will not run forever though Aug 07 16:10:27 s1gmab3ta, im not sure ifyou can still attach it back if you launch a new instance of your app Aug 07 16:12:28 pretty sure the service will be started anytime startService() is called for it and it hasn't been started already Aug 07 16:26:19 is there a way to let the main thread execute a method called by another another thread Aug 07 16:26:46 ulli909, read jcip Aug 07 16:26:57 jcip? Aug 07 16:27:02 there's too many answers to that question Aug 07 16:27:32 i think he only wants one answer tho Aug 07 16:27:57 there isn't just 1 answer Aug 07 16:28:18 oh come on Aug 07 16:30:59 pfn, thats sounds rather paradoxal. We're talking about programming that objectively produces either positive or negative results. The same things can't produce either. What you could be telling me is that either depends on the situation, or it's possible yet not advisable (which is a definite yes as an answer to his question) Aug 07 16:31:24 in short, i find it hard to believe that there are many answers to a yes or no question Aug 07 16:31:24 in this context Aug 07 16:35:05 ugh, somebody crashed a drone into Grand Prismatic Aug 07 16:35:22 ulli909, yes there is Aug 07 16:36:42 g00s: Excuse me for this, but if they were flying it outside line-of-sight, I hope they get reamed to the full extend of the law Aug 07 16:42:03 hows it going p_l Aug 07 16:42:46 g00s: had a kernel dev. phone screen today Aug 07 16:43:13 oh nice. that was one of those areas i thought about changing careers to a few years back Aug 07 16:43:25 seemed like quite a few linux kernel dev positions Aug 07 16:43:56 seems like every year i'm interested in something else though :( Aug 07 16:44:07 p_l did it go well ? Aug 07 16:44:43 I think so. Didn't do too well on the most important aspect (I think), which was reading and correcting errors in a broken driver Aug 07 16:46:20 if it goes well, I might end up with a job offer from Red Hat in Czech Republic :) Aug 07 16:46:55 like fixing incorrect code or implementing error correction? Aug 07 16:48:23 ravilov: fixing bugs Aug 07 16:48:52 (which is what the job would be about) Aug 07 16:49:14 jvrodrigues, the question implies more than just yes no Aug 07 16:49:18 jvrodrigues, if you can't read that subtext... Aug 07 16:50:23 ah Aug 07 16:50:53 lol Aug 07 16:51:19 jvrodrigues subscribes to literal interpretation Aug 07 16:51:27 pfn, i understand what you mean, but he asked a straightforward question, either you can or you can't. your answer was just douchebaggy =/ Aug 07 16:51:48 jvrodrigues, do I care, I'm not going to answer yes and leave him hanging Aug 07 16:51:52 is there an android theme attribute which points to holo light / dark foreground and background colors for widgets ? for example that aqua color for the foreground. lots of widgets use 9 patches Aug 07 16:51:57 and I'm not going to explain to him how concurrency works Aug 07 16:52:33 pfff finally found my problem (createScaledBitmap not filling screen).. ScaleType not set correctly for the ImageView. Dumb! :D Aug 07 16:53:26 congrats Aug 07 16:53:27 thus the correct answer is "go fucking reaazd jcip" Aug 07 16:55:41 * ravilov tries to assume people coming in here to ask questions have put effort into googling it first, at least until proven otherwise at which point there is no mercy, lol Aug 07 16:56:17 ravilov you haven't spent enough time here ;) Aug 07 16:56:21 ravilov: you're new here, aren't you? Aug 07 16:56:34 yes and yes Aug 07 16:56:38 g00s: cynic high-five! Aug 07 16:56:45 Leeds yeah \o Aug 07 16:56:53 I'm just trying to be nice Aug 07 16:56:58 it's not easy Aug 07 16:57:03 it won't last Aug 07 16:57:18 you'll get bitter and cynical like the rest of us - or you'll leave... there is no third option :) Aug 07 16:57:53 oh I've been bitter and cynical before, I'm trying to change Aug 07 16:58:38 I might be new here but I've already been through the cycle elsewhere Aug 07 17:02:40 * autrilla insists in getting a bot Aug 07 17:02:55 ravilov, unfortunately, you are very right Aug 07 17:03:00 Do you ever sleep ravilov? Aug 07 17:03:12 I'd love to be able not to sleep Aug 07 17:03:22 Days are so short Aug 07 17:03:34 he was just on "last night" which was 7 hours ago ;p Aug 07 17:03:51 autrilla: Who said we can't have a bot? Aug 07 17:03:57 flan3002, topic Aug 07 17:04:03 If we can, I'll make one :P Aug 07 17:04:09 Or host one Aug 07 17:04:16 autrilla: Well, the topic can be changed... :P Aug 07 17:04:29 sleep is overrated Aug 07 17:04:34 I understand that limitation is there to avoid 100 bots Aug 07 17:04:55 autrilla: Of course, but approved bots shouldn't be that much of a problem... Aug 07 17:05:06 coders are just annoying human beings.. Including me :D I learned to deal with that and them a long time ago ;) Aug 07 17:05:09 I just need a Google guy to come here and approve! Aug 07 17:05:24 ThomQ, non-dumb people are always annoying Aug 07 17:05:30 And dumb people are annoying too Aug 07 17:05:33 Google guy, Google guy... nope, haven't seen any of them around these parts recently Aug 07 17:05:36 autrilla: We don't get Google guys here... Aug 07 17:05:47 who's to say dumb people can't be annoying? Aug 07 17:05:54 Leeds: I asked Romain Guy once about some OpenGL stuff... ^^ Aug 07 17:06:03 Didn't work for Google at that point anymore though... Aug 07 17:06:29 * ravilov used to know a google guy Aug 07 17:06:34 flan3002: I thought he still worked for Google, just not in the Android team - in fact, I thought he'd moved to Andy Rubin's robot group Aug 07 17:06:40 How do you record your android screen to promote your app? Aug 07 17:06:41 not an android guy though Aug 07 17:06:44 Oh, okay... Aug 07 17:07:04 I know a Google Glass girl Aug 07 17:07:07 Kake_Fisk, adb screenrecord Aug 07 17:07:16 we make fun of her a lot ^.^ Aug 07 17:07:16 he might have left Google since leaving Android, but I haven't heard anything to suggest that Aug 07 17:07:16 autrilla: We don't need someone from Google... I'd say if SimonVT is okay with it, we're ready to roll... ^^ Aug 07 17:07:40 pfn: Thanks. But unfortunately my phone is 4.2 and emulator doesn't support screenrecord :/ Aug 07 17:07:53 Kake_Fisk, then get a phone that does support it Aug 07 17:07:59 Kake_Fisk, use an external camera to record, then Aug 07 17:08:32 can't ddms help? (or whatever it's called) Aug 07 17:08:38 is adb screenrecord not supported in 4.2? Aug 07 17:08:49 I don't think so, is it? Aug 07 17:08:59 it's new in 4.4 Aug 07 17:09:16 you might want to update then Aug 07 17:09:16 you have 2 options, get a phone with 4.4 or use an external camera Aug 07 17:09:28 Any particular likings for a bot? Aug 07 17:09:43 External camera? As in a screen recorder? Aug 07 17:09:51 as in a video camera Aug 07 17:09:57 :P Aug 07 17:10:10 screenrecord needs 4.4 Aug 07 17:10:15 That looks kinda unprofessional :p Aug 07 17:10:44 depends on your postprocessing :p Aug 07 17:10:44 just upgrade your phone then. If you have 1 test device, it's prob best to have the latest version on it anyways Aug 07 17:10:45 Kake_Fisk use one phone to take a video of the other phone :) Aug 07 17:11:43 make sure you cover the lens partially with your finger Aug 07 17:11:50 I can't just get a new phone. But I'll see if I can manage to upgrade soon Aug 07 17:11:58 I also need to afford a laptop :p Aug 07 17:12:03 I'm a student Aug 07 17:12:17 oh and make sure it's shaky and has lots of portrait to landscape switches Aug 07 17:12:31 most 4.2 phones are upgradable to 4.4, correct? I havent heard of any who weren't Aug 07 17:13:17 upgrading as in upgrading android, not getting a new phone :D Aug 07 17:13:38 id be in the poor house if I had to get a new one for every update Aug 07 17:13:55 Oh, I have Galaxy S2, but I have no idea how to upgrade Aug 07 17:14:21 the expensive genymotion has a screencasting feature Aug 07 17:14:38 hrm that won't help Aug 07 17:16:10 I think I need to root or something, if I want 4.4 Aug 07 17:16:49 wait, you're doing android development but you have no clue about upgrading firmware?? Aug 07 17:18:48 ravilov, I wouldn't know how to update a SGS2 Aug 07 17:18:51 yeah i should know that too, but don't. like i should have an older phone running 4.0 - 4.1 based on what i install Aug 07 17:18:56 But Google would sure help me Aug 07 17:19:43 SGS2 is easy to upgrade to non-standard firmware, as long as you didn't do the stupid thing and bought North American version :P Aug 07 17:19:46 autrilla, well I wouldn't know how to upgrade some random device either, but my own? definitely Aug 07 17:20:05 Nexus 4 ftw :) Aug 07 17:20:09 Just take a laptop into bestbuy, plug in your phone to one of their demo 4.4 adb screencast and voila Aug 07 17:20:25 riiight Aug 07 17:20:45 * ravilov doubts it would be that simple Aug 07 17:20:52 it is totally that simple Aug 07 17:21:11 if the manager gives you gruff just tell him you'll add him to your beta tester list Aug 07 17:22:02 ... I'm calling Poe Aug 07 17:22:05 both drawables and talk about a "level" - does this refer to a level in a stack (z-order) or does each drawable have its own idea of a level ? Aug 07 17:22:15 also that you're known as the techie guy in your (wider) family and you'll totally recommend everyone you know to come buy at bestbuy, right lasserix? Aug 07 17:23:00 yeah, exactly! Aug 07 17:23:04 ;p Aug 07 17:25:10 oh man, family tech support horror story: my mom's friend 'helped' her by installing a whole bunch of toolbars Aug 07 17:25:31 on windows 7. all she wanted was some kind of calendar. i spent the rest of the day uninstalling shit Aug 07 17:25:43 g00s: that's some perverse kind of vengeance Aug 07 17:25:53 p_l exactly :D Aug 07 17:26:44 brother in law has a huge ego and is the self declared "computer guy", I can handle the ego blow of never being hastled Aug 07 17:26:50 i'm thinking my mom could use one of these acer c720 chromebooks Aug 07 17:28:55 g00s: you just rediscovered their original purpose :P Aug 07 17:29:15 yeah hehe Aug 07 17:29:16 why not a mac? aren't those closed off precisely for people like this? Aug 07 17:29:29 g00s: hey hows things@? Aug 07 17:29:34 p_l i read yesterday a nice story about converting it to ubuntu Aug 07 17:29:43 g00s, ubuntu Aug 07 17:29:44 ravilov: it's not yet that closed Aug 07 17:29:44 hey Napalm ok over here, hows it overthere ? Aug 07 17:29:44 srsly Aug 07 17:29:57 p_l, but certainly going there? Aug 07 17:30:16 yea, not bad, just building some hardware.. making a fancy deploy button for the CI server Aug 07 17:30:19 ravilov: who knows, Jobs kicked it... Aug 07 17:30:26 Napalm oh yeah i saw that ! Aug 07 17:30:33 don't launch the nukes Aug 07 17:30:33 yea, its getting there Aug 07 17:31:36 just sorting out a bit of PWM code to drive the brightness of the LED and also done some software serial comms to work with FTDI cable so now it can be plugged in on USB and controlled Aug 07 17:31:44 its good to see the sysinternals stuff is still available for windows Aug 07 17:31:51 helps you get to the bottom of sneaky programs Aug 07 17:31:59 Napalm, arduino? Aug 07 17:32:01 Fun stuff Aug 07 17:32:21 g00s: there's always the option of attaching kernel debugger ;D Aug 07 17:33:07 na, just trying to use up some old microchip processors using a 12F675 which literally has nothing but the bare pins, no UART for serial or anything.. its "feature" is that it has an analog pin.. lol Aug 07 17:34:04 Napalm its illegal to have this much fun you know Aug 07 17:34:33 * Napalm muh ha ha ha Aug 07 17:34:37 :) Aug 07 17:34:56 oh, i got an awesome idea Aug 07 17:35:06 to have even more fun?? Aug 07 17:35:10 i'll use my OTG cable and write a Android driver for this.. just for kicks :D Aug 07 17:46:57 Napalm here's a project: make an electronic coaster; when you pick up the beer it kicks off the build. if it goes well, it turns colors red / green - the beer should light up nicely Aug 07 17:47:19 nice idea Aug 07 17:47:40 * g00s wonders if JakeWharton already working on that Aug 07 17:47:46 it's done Aug 07 17:47:55 that was quick XD Aug 07 17:48:22 the light-speed of JakeWharton is legendary Aug 07 17:48:27 :) Aug 07 17:54:33 is there any way to visualize these? i could probably copy the file into my AS project, i think it puts little swatches on each line https://github.com/android/platform_frameworks_base/blob/master/core/res/res/values/colors.xml Aug 07 17:55:17 you could always use an XSLT to convert it to HTML Aug 07 17:55:29 hm, yeah. xslt is kinda cool Aug 07 17:59:39 g00s, https://github.com/Monnoroch/ColorHighlighter ? Aug 07 18:00:03 interestingf Aug 07 18:00:09 Afzal cool, thanks ! Aug 07 18:00:26 anyone got any ideas for a college level project in android? Aug 07 18:00:31 yaaay google fit dev sdk was just released apperently Aug 07 18:01:03 KaylieG what is college level ? Aug 07 18:01:35 KaylieG: Yeah - define what you mean by college level, and what you mean by college (US/UK difference in meaning, for example) Aug 07 18:01:36 KaylieG, a timetable organizer app linked to the class times on your college website? Aug 07 18:01:39 i guess that was pretty vague, but basically something a senior in college would be expected to do Aug 07 18:01:56 the light-speed of JakeWharton is legendary <-- some would say that's nothing to brag about... Aug 07 18:02:03 KaylieG wouldn't your instructor define that O.o Aug 07 18:02:03 in this case community college i guess Aug 07 18:02:13 KaylieG, like this http://www.timetablegenerator.com/ but an app instead Aug 07 18:02:13 ravilov: lol Aug 07 18:02:43 KaylieG, hello and welcome, the only thing a college senior is expected to know how to do is drink beer and chat ladies. Some can't even do that. Aug 07 18:02:48 we've just been told to do a project that would take maybe about 2 months at least to develop Aug 07 18:02:49 KaylieG: How about developing a mobile application which acts as a survey platform - could interact with a back end which generates analytics etc. Think SurveyMonkey (They do not have a mobile application version - USP) Aug 07 18:04:18 Napalm, o/ Aug 07 18:04:35 some examples of what have been approved, a carpooling app using gps, an app that translates voice into musical notes, and a recycle bin for mobile Aug 07 18:04:38 KaylieG: A better question to ask would be what modules have you covered / topics do you understand? Aug 07 18:05:08 I've always liked the idea of an app which you can speak into, uses voice recognition, and outputs audio of that same sentence but translated to another language. Aug 07 18:05:17 honestly, android is more or less new to most of us, so we're expected to learn as we develop Aug 07 18:05:22 Ahhh ok Aug 07 18:05:30 i've made a couple of sample apps though, but very simple ones Aug 07 18:05:47 How about an application for keeping notes on your phone? Aug 07 18:05:48 like using the twitter and instagram apis, or communicating with a server app on my laptop with my phone Aug 07 18:05:56 Think like Google Keep, but you should be able to store photos etc too Aug 07 18:06:08 god damn it, google fit preview is only available for nexus 5 and 7 -.- Aug 07 18:06:14 Anthaas that's a good one. Its not even that hard, i don't think. There's a speech recognition api, and a tranlation api. lol, you could probably build the whole app with only a couple of classes Aug 07 18:06:17 and where the notes can have a geolocation attached to them Aug 07 18:06:39 jvrodrigues: Precisely - I just can't be bothered doing it haha Aug 07 18:06:47 I dont know enough of any other language to know if it is useful etc. Aug 07 18:06:48 speaking of social APIs, anybody got any recommendations for using hte facebook sdk. It's so freaking weird, UiHelper and redundant session calls and whatnot :/ Aug 07 18:06:50 Anthaas, that's actually fairly easy Aug 07 18:06:56 i feel like the professor grades projects not just on utility, but also on largeness and flashiness Aug 07 18:06:57 Syzygy_: Which? Aug 07 18:07:13 talk int your app, and let it repeat the sentence in another language Aug 07 18:07:16 KaylieG: Do the notes on, and add in some sexy UI and cool animations then? Aug 07 18:07:35 nah, that's too crappy Aug 07 18:07:35 Syzygy_: Ahhh - go for it then :-) it was a suggestion for KaylieG to do as her project - wasn't posted based on difficulty. Aug 07 18:07:37 granted, i haven't worked with translation engines yet, but voice recognition and speech output is really easy on android Aug 07 18:07:56 lol, finally a reason to buy an android watch http://www.androidpolice.com/2014/08/07/terminal-watch-face-android-wear-app-inner-geek-clamoring/ Aug 07 18:08:09 KaylieG, maybe an app for your town that maps all the public transports and tells you exactly the fastest way to get from one place to another? Aug 07 18:08:13 that's flashy, usefull, and complex Aug 07 18:08:22 i guess i'll definitely be trying on these projects even if it's not approved just as a hobby Aug 07 18:08:35 oh yeah that transportation one was another one that another group is doing and was approved Aug 07 18:09:06 How about you one-up them Aug 07 18:09:07 jeeeeeeeeeeeez Aug 07 18:09:10 basically what happened was that i was late to the signup sheet and a few of the suggested topics that were interesting to me were all taken by other groups Aug 07 18:09:28 KaylieG, well, they have it easy then. Speech in and output is less than 200 lines of code... pretty straight forward. Aug 07 18:09:32 Have all the features in your towns coords stored in the phone, and create an augmented reality app which shows them on screen as you look in their direction through the phone Aug 07 18:09:40 I did that within 2 months of learning Android Aug 07 18:09:59 haha nice! Aug 07 18:10:07 g00s, https://www.dropbox.com/s/twhtj7owcjnv6vy/Screenshot%202014-08-07%2014.10.00.png :p Aug 07 18:10:11 when you say look in their direction do you mean with the camera? Aug 07 18:10:16 and have you published it to the store? Aug 07 18:10:28 Yeah, so you hold your phone up and look through it - your phone will have a compass etc available Aug 07 18:10:28 Afzal \o/ thanks Aug 07 18:10:29 And no :P Aug 07 18:10:31 * autrilla summons SimonVT Aug 07 18:10:32 All the better for you Aug 07 18:10:33 KaylieG, what about an app that tracks your general location, builds your personality profile based on the shit you have installed and matches you with people of the opposite sex whose personalities match? Aug 07 18:10:51 i feel like i just gave away a million dollar idea Aug 07 18:10:52 I dont actually have the source code - I did it whilst I was on placement within the first month and a bit whilst I was told to learn the platform. Aug 07 18:10:58 Afzal: what sublime plugin is that?. Aug 07 18:11:02 g00s, it's called Gutter Color and you unfortunately have to remove the transparency part from the hex color Aug 07 18:11:17 jvrodrigues: But for god sake don't use their search history! :P Aug 07 18:11:18 i'll look into fixing that Aug 07 18:11:22 do a checker pattern Aug 07 18:11:29 Sublime is awesome Aug 07 18:11:39 jvrodrigues, I almost have no personality then :( Aug 07 18:11:49 Sublime 3 + Grey Tuesday Theme = <3 Aug 07 18:12:01 scite and the scintilla editor was my choice once upon a day, then sublime took over every editor Aug 07 18:12:03 Syzygy_, then you're perfect for a girl/man with no personalitty Aug 07 18:12:10 I guess. Aug 07 18:12:12 I mean Aug 07 18:12:29 not having apps installed is also a character distinction Aug 07 18:12:34 means you're not that much into it Aug 07 18:12:43 the app would find someone that would also not be that much into it Aug 07 18:12:51 and that only means Aug 07 18:13:00 the shit you have installed are real mirrors into your personality Aug 07 18:13:02 Afzal: it requires ImageMagick.... really.. that sucks big time Aug 07 18:13:12 I just have spotify, a lockscreen, chromecast, facebook and chrome and a ton of work related apps Aug 07 18:13:24 Not sure if I would want to be recommended someone of the opposite sex based on what phone apps they have installed? Aug 07 18:13:24 I used to have games Aug 07 18:13:29 because those really matter. imagine finding a girl/man/unspecified with the exact same shit? You would have so much in common i guess Aug 07 18:13:31 but I got a Vita Aug 07 18:13:44 KaylieG one idea is to use the GoodReads API to find dating matches between people who have liked the same books Aug 07 18:13:45 Napalm, ah, I must already have imagemagick Aug 07 18:13:51 Anyways, KaylieG i just gave you a million dollar idea, have fun with it Aug 07 18:14:10 KaylieG also using location of course :) Aug 07 18:14:20 yea, so do i, but everytime it parses a color it spawns a imagemagick process.. kinda overkill considering Aug 07 18:14:21 jvrodrigues, so basically tinder but only with similar likes? Sounds good Aug 07 18:14:36 Afzal: ^ Aug 07 18:14:48 Afzal, tinder without being based on looks, but on whatever you have installed in your app Aug 07 18:14:59 i like it, but this professor isn't the kind of person who'd approve that Aug 07 18:15:20 You never know until you try Aug 07 18:15:21 KaylieG, maybe he's just lonely, this app will change that Aug 07 18:15:45 another group tried a social networking type thing and he said he wants utility over time wasting Aug 07 18:15:52 he's definitely lonely Aug 07 18:15:54 Afzal: looks like you can add alpha support with the custom_colors field in https://github.com/ggordan/GutterColor/blob/master/GutterColor.sublime-settings Aug 07 18:16:29 What is the difference between the SENT pendingintent and DELIVERED pendingintent when sending an SMS? Aug 07 18:19:40 Napalm, nice. I still wish there was a chrome extension or a github userscript for this Aug 07 18:19:55 Maybe that's my next userscript... hmm.. after work it is Aug 07 18:20:52 ugh, the color swatch download from http://developer.android.com/design/style/color.html gas .aso and .ase files ... Aug 07 18:21:02 adobe shit, hmm Aug 07 18:21:19 any open source tools that can open these ? Aug 07 18:21:39 and? Aug 07 18:21:48 g00s, you mean GIMP can't? Aug 07 18:21:51 g00s: they have the gpl one.. GIMP palette Aug 07 18:21:55 its open Aug 07 18:22:18 oh thats what that was, i thought it was the license XD Aug 07 18:22:28 * g00s headdesk Aug 07 18:24:16 .gpl heh Aug 07 18:24:34 Anyone know the difference between the Sent PendingIntent and Delivered PendingIntent when sending an SMS? Aug 07 18:24:58 hey guys, can I disable on datepicker scroll year? Aug 07 18:25:24 Anthaas: ones probably the delivery report Aug 07 18:25:40 But when is it actually triggered? Aug 07 18:25:55 I get the sent intent, I never get the delivered intent, even when the SMS is opened and replied to? Aug 07 18:25:56 pass Aug 07 18:26:00 Anthaas i dont know anythin about SMS, but there is delivery conf Aug 07 18:26:20 on my phone, for example, i can disable SMS / MMS delivery conf Aug 07 18:26:43 Anyone know how to open the default sms application to a given thread id in >= 4.4 ? Aug 07 18:26:55 (or know if it is possible anymore) Aug 07 18:27:04 lasserix: wernt you asking about this the other day? Aug 07 18:27:25 Yeah, i believe you gave me a suggestion but it did not work. Aug 07 18:27:33 Then someone said maybe it's not possible anymore. Aug 07 18:27:35 lasserix: dont you just fire an ACTION_VIEW with the content uri in the data field Aug 07 18:27:45 Doesn't work for thread-id Aug 07 18:27:53 What is the name of the "stuff" that makes a background become similar in color to a given image? Aug 07 18:28:00 I get "No Activity Found" error Aug 07 18:28:18 I was hoping either someone could confirm it's impossible to do anymore, or have figured out a way. Aug 07 18:28:27 explodes wut? Aug 07 18:28:30 (it used to be possible) Aug 07 18:28:51 Its a new thing in L where the hero-banner colorizes to match a hero image Aug 07 18:28:51 oh is that the android color pallete api in L Aug 07 18:28:57 yea that sounds right Aug 07 18:29:53 so i'm reading this http://www.androidpolice.com/2014/08/07/google-releases-google-fit-preview-sdk-opens-google-fit-developers-community/ Aug 07 18:30:03 "Recording API allows apps to register for battery-efficient, cloud-synced background collection of fitness data." Aug 07 18:30:12 it would be cool if they talked about how they did this Aug 07 18:31:39 Here is a question Aug 07 18:31:52 Is it possible to get a service to turn itself off for, say, 30 seconds? Aug 07 18:32:01 and then turn back on Aug 07 18:32:06 alarmmanager ? Aug 07 18:32:13 AlarmManager. Aug 07 18:32:17 Sweet - cheers Aug 07 18:32:35 Anthaas don't forget the wakelock handoff :D Aug 07 18:32:40 * g00s runs Aug 07 18:32:54 What do you mean? The fact wakelock will keep the application on for those 30 seconds? Aug 07 18:33:07 Thats fine, I just dont want user interactivity with the service for 30 seconds Aug 07 18:33:18 g00s: How do I use the Palette api? I'm compiling with L and using support v4 20+, but Palette is not available Aug 07 18:33:56 Palette is not in v4, it has its own support library Aug 07 18:34:18 Oi Aug 07 18:34:28 Simon, someone said if you were ok with having a bot here there'd be no problem Aug 07 18:34:39 Thanks SimonVT and goos: FYI: compile 'com.android.support:palette-v7:+' Aug 07 18:34:39 Bots suck Aug 07 18:34:41 Are you ok? Basic functionality such as factoids Aug 07 18:34:54 SimonVT, aren't you tired of answering the same things? Aug 07 18:35:32 That's why I hardly ever answer ^_^ Aug 07 18:35:35 ~ide ~intent ~books Aug 07 18:35:48 SimonVT, there's three common questions Aug 07 18:36:07 I don't own the channel. The channel rules says no bots, so that's what I go by :) Aug 07 18:36:28 Hm, it's in plural Aug 07 18:36:58 So as long as there is just one... :P Aug 07 18:37:06 Try your luck :) Aug 07 18:37:39 You are on the channel access list, I don't want a ban :( Aug 07 18:38:09 if googlers don't hang out here any more, there should be a process where they relinquish control to the community Aug 07 18:38:31 for all practical purposes they abandoned this place Aug 07 18:39:38 i think Zed Shaw had an IRC reputation bot Aug 07 18:39:51 g00s, the JavaBot has a lot of stuff Aug 07 18:39:56 google should love it, governance by algorithm ! Aug 07 18:40:11 And is coded in Java, a language pretty much everyone here knows Aug 07 18:42:17 anyone have a suggestion for decoding a seemingly infinite video stream, like from a webcam or something similar? Aug 07 18:42:47 seems like the only methods to read in a stream is from a file Aug 07 18:43:24 * adroidbot coughs Aug 07 18:43:37 dat typo Aug 07 18:44:52 androidbot can i do networking on the main thread ? Aug 07 18:45:02 androidbot: ~ide ~intent ~books ~eclipse ~networkingforg00s ~finishmyapp Aug 07 18:45:12 :/ Aug 07 18:45:17 g00s: Yes if you change the strict policy :P Aug 07 18:45:21 Protip: I'm not a bot yet Aug 07 18:45:24 ~ban Aug 07 18:45:42 Google should put their own android robot bot Aug 07 18:45:50 Does it bother anyone? It won't do anything but answer factoids Aug 07 18:45:53 they have the mascot, they should make some primitive AI and stick it in this channel Aug 07 18:46:00 You have more time than I. Aug 07 18:46:21 they could probably just put their Play support online as well :) Aug 07 18:47:00 This is what I'll have http://javabot.sourceforge.net/index.php Aug 07 18:47:25 LOL Aug 07 18:47:26 nice Aug 07 18:47:36 ooo Aug 07 18:47:40 So it did bother someone Aug 07 18:47:52 SimonVTBot Aug 07 18:47:59 if i want to draw a shapedrawable, what do I use? can I use just View? and have the shapedrawable as bg ? Aug 07 18:48:07 You use xml Aug 07 18:48:23 create a my_shape_drawable.xml in res/drawable Aug 07 18:48:26 lasserix, xml doesn't draw anything Aug 07 18:48:32 yes I know Aug 07 18:48:33 then define it as you need too Aug 07 18:48:42 but then I draw it programmatically Aug 07 18:48:46 how? Aug 07 18:49:05 So, can I release an app with the Palette support library into the play store Today? Aug 07 18:49:07 set the what container? Aug 07 18:49:22 Or do I have to wait until L is actually released Aug 07 18:49:46 explodes was it in 20 or 21-rc ? Aug 07 18:50:07 the Palette supprt librarY? Aug 07 18:50:08 (support lib) Aug 07 18:50:09 I don't know Aug 07 18:50:20 There's no v20 of the new support libraries Aug 07 18:50:58 K Aug 07 18:52:34 question about gps. i've used getLastKnownLocation before because I wanted instant results, but how long does doing fresh gps locationing take normally? Aug 07 18:53:13 greetings humans. Aug 07 18:53:38 Humans? Are you sure? Aug 07 18:55:07 SimonVT, by the way, why did you kick the one with the nick "androidbot"? Aug 07 18:55:24 from the hours of 9-6PST i am a code monkey. barely human. Aug 07 18:56:04 Why does using a Viewpager cause ActionBar text to get dragged out? Aug 07 18:56:45 or not dragged out why did i write that Aug 07 18:56:48 Is there some way when you are in a shell to an android device to send it touch screen events ? Aug 07 18:56:57 Like this: Highscores => Highscor... Aug 07 18:57:37 autrilla: I thought that was obvious Aug 07 18:58:41 did google ever put up widget design guidelines? like if you wanted to make a custom control, the colors you should use Aug 07 18:59:36 In an xml layout file, if I'm using a custom view, what is the first part of the view declaration called. ie. ? Aug 07 18:59:58 The package? Aug 07 19:00:10 having to write some documentation, wanted to be sure thanks Aug 07 19:00:31 hi, I'm using googlemaps and trying to figure out how to display multiply strings in an customized infowindow, anyone? Aug 07 19:01:14 It's just the fully qualified name of the class Aug 07 19:01:22 by the way, if anyone has to make documentation for a library or SDK, checkout mkdocs Aug 07 19:01:28 yeah that's what i thought Aug 07 19:02:26 thanks Aug 07 19:02:49 I can set TextView and return an whole view, but I can't insert the text I want from an other class Aug 07 19:03:33 happy IPA day :) Aug 07 19:04:49 So, something is bothering me. I have a textview layout that's a listview item, i created a drawable to set the background accordingly if it's pressed, focused or normal. They all have round corners. What happens is: When pressed, the corners, from the semicircle to the point, get the background color of the normal state Aug 07 19:05:01 checkout the code here https://github.com/papaecho91/Parkapp/blob/master/Parkapp/src/com/parkpkg/parkapp/MainActivity.java Aug 07 19:05:25 i mean from the semicircle of the corner to the actual edge (the part that should be transparent) Aug 07 19:05:27 jvrodrigues: sounds like your selector states are incorrect Aug 07 19:06:02 that same drawable works flawlessly in buttons Aug 07 19:06:31 jvrodrigues: you dont set the background on each child.. instead you set the selector on the ListView.. or alternativly set the selector to @null for the ListView and use per-child ones Aug 07 19:07:22 no one have used infowindow in googlemaps? Aug 07 19:07:33 Napalm, that has to be it! the listview selector. Didn't think of that. Thansk mate Aug 07 19:07:40 np Aug 07 19:12:48 SimonVT, it was obviously not a bot. Just a person with a bot-like name Aug 07 19:13:13 he did say he was going to bot around Aug 07 19:14:23 Meh, I'll just have to get accostumed to the fact that laws are sometimes stupid Aug 07 19:16:37 whoa, L preview update!! Aug 07 19:18:17 oh rly? Aug 07 19:19:50 Napalm, yeah! https://developers.google.com/fit/preview#flash_your_nexus_5_or_nexus_7 Aug 07 19:22:06 Do you know what would be even better than that? Having L on the Nexus 4 Aug 07 19:22:43 autrilla, meh Aug 07 19:23:20 No meh. It's a perfectly good phone, and I'd rather not install a thrid party firmaware (they're usually buggier) or buy a nexus 5 Aug 07 19:23:31 'til it breaks Aug 07 19:35:35 autrilla, it's a developer preview. It makes sense to only release it for the current devices. Release version should come to N4 for sure Aug 07 19:36:18 Afzal, the support for the nexus 4 has ended Aug 07 19:36:33 autrilla, last time I checked, it still got the 4.4.4 update Aug 07 19:36:34 autrilla: and as Google has pointed out, they supported all Nexus devices longer than 18 months Aug 07 19:36:42 which is the last update that came out Aug 07 19:36:56 The EOL was a while ago, so no guarantee Aug 07 19:37:00 When it's not update, then you can say that Aug 07 19:37:04 updated* Aug 07 19:37:16 the "18 month" thing was an agreement (more like lightly-binding promise) with other vendors for a *minimal* support period Aug 07 19:37:36 anyway, L will be probably released together with a new device Aug 07 19:37:59 p_l not looking foward to buying a 6" Nexus :( Aug 07 19:38:25 Afzal: next Galaxy S, whatever it's name will be, is rumoured to also be 64bit Aug 07 19:38:43 Galaxy S? Aug 07 19:39:01 And I don't care much about 64-bitness Aug 07 19:40:13 OK I have an array of AlertDialog.Builder is there a way to find the index from the .setPositiveButton code? Aug 07 19:40:14 Why would you want 64 bits on a phone? Aug 07 19:40:15 Afzal: "whatever the next gen of the S-series is called" Aug 07 19:40:37 callmeDarwin, what index? Aug 07 19:40:49 autrilla: AArch64 includes some other improvements other than 64bit addresses and integers Aug 07 19:41:16 p_l, and I doubt 64 bit processors cost the same Aug 07 19:41:17 autrilla, if this image from a month ago has any credibility (especially since we have lpv81c now), then L will come to N4 Aug 07 19:41:18 http://i.imgur.com/NowM2qH.jpg Aug 07 19:41:29 people have reported nice improvements on iphone 5S Aug 07 19:41:30 Index of the AlertDialog.Builder[index] Aug 07 19:41:56 AlertDialog.Builder is an array? Aug 07 19:42:44 yes set them up with final AlertDialog.Builder builder[] = new AlertDialog.Builder[CardCount]; builder[CardCount] = new AlertDialog.Builder(CashoutScreen.this); Aug 07 19:44:05 ... Aug 07 19:44:15 Isn't the AlertDialog#Builder a factory class? Aug 07 19:44:36 hah! They fixed a little UI quirk on the new update Aug 07 19:44:45 Afzal: what quirk? Aug 07 19:44:47 The date shows when you pull the notification shade down :D Aug 07 19:44:58 before, it only showed when you expanded Quick Settings Aug 07 19:44:59 how about the battery charge? Aug 07 19:45:07 http://cdn.androidpolice.com/wp-content/uploads/2014/08/nexusae0_wm_Screenshot_2014-08-07-14-16-10.png Aug 07 19:45:07 each builder pops up in reverse sequence when I builder[CardCount].show(); but I'd like to know what CardCount is from in the setPositive Aug 07 19:45:09 what about it? Aug 07 19:45:17 i want that too show in the shade Aug 07 19:45:36 callmeDarwin, there is no situation in which you'll want an array of factories Aug 07 19:45:46 oh. yeah that's difficult to happen with google Aug 07 19:45:58 alexfu, what's that horrid blue thing? Aug 07 19:46:07 autrilla, what's a factory class? Aug 07 19:46:12 Afzal* Aug 07 19:46:14 OK, zwork needs help. zwork is settting a button width width 1 and height 1 and it is 1cm high and 0.7 cm wide. how can this be zwork wonders!? Aug 07 19:46:27 autrilla, hmm? Aug 07 19:46:34 Afzal, on the pic Aug 07 19:46:38 top right Aug 07 19:46:51 ?g java factory class Aug 07 19:46:55 Oh wait. Aug 07 19:47:19 autrilla, top right? the profile pic? what? Aug 07 19:47:32 Afzal, ah, that's maybe the profile pic Aug 07 19:47:37 It doesn't really blend :( Aug 07 19:47:43 yeah, that's Artem's profile pic Aug 07 19:47:47 callmeDarwin, http://lmgtfy.com/?q=java+factory+class Aug 07 19:50:49 ok well it's working as is now but I guess I'll have to rethink it. I need to queue up some AlertDialog.builders to pop off one after another. Aug 07 19:52:11 callmeDarwin, do you know you can use the same factory to make several dialogs? Aug 07 19:52:23 And AlertDialog.Builder is a factory Aug 07 19:54:03 thats what I thought I did I just stored them in an array. Aug 07 19:54:51 I also see no reason to even store the dialogs on an array Aug 07 19:54:59 In fact, I see no reason to use an array Aug 07 19:55:58 ahh just pop .show them in the loop without the array? Aug 07 19:56:26 callmeDarwin, yes Aug 07 19:57:40 ok how do I keep unique data with each builder? Aug 07 19:58:40 MY FACE WHEN the callback on Picasso .into doesn't provide a Bitmap Aug 07 19:58:50 explodes: it does Aug 07 19:58:55 explodes: its the way you do it Aug 07 19:59:13 it doesn't Aug 07 19:59:18 waaa? Aug 07 19:59:20 because the callback shoudn't be used to manipulate the Bitmap Aug 07 19:59:26 if you want the Bitmap, use Target Aug 07 19:59:29 each setpositive has some logic depending on unique data. Aug 07 19:59:36 yea, thats what I was talking about Jake Aug 07 19:59:38 the Target Aug 07 19:59:38 :P Aug 07 19:59:44 Napalm: How do you make that happen? Aug 07 20:00:02 want an example? Aug 07 20:00:17 I don't want to manipulate it, just use it for something else... Aug 07 20:00:20 Yes please Aug 07 20:00:25 like what? Aug 07 20:00:49 Specifically, when I get an image, I want to show it in a view, but the ViewGroup holding it should have a blurred version of the bitmap as a background. Aug 07 20:01:02 You know, for style points Aug 07 20:01:06 so call picasso twice Aug 07 20:01:15 and use a blur transform on the second one Aug 07 20:01:29 it's not dumb, it won't download twice Aug 07 20:01:59 that's pretty legit Aug 07 20:02:00 explodes: https://gist.github.com/slightfoot/0ecccdf80f57804884e0 Aug 07 20:02:31 "it's not dumb" -JakeWharton on Picasso, August 2014 Aug 07 20:02:35 :) Aug 07 20:03:26 JakeWharton: you should add that type of "into" to set a compound-drawable Aug 07 20:03:30 Thanks Napalm Aug 07 20:03:53 callmeDarwin, unique data? Aug 07 20:03:54 JakeWharton: https://gist.github.com/slightfoot/0ecccdf80f57804884e0#file-contributorsfragment-java-L136 Aug 07 20:03:58 Seems like you have to learn java Aug 07 20:04:01 We talked about it. Didn't like the API Aug 07 20:04:19 so i need to have the user fill out a form within a web view and then call back to the app when they're done. what's the best way of doing this? Aug 07 20:04:48 I love how people go through the hassle of making libs public Aug 07 20:04:58 whomp: http://developer.android.com/reference/android/webkit/JavascriptInterface.html Aug 07 20:05:26 whomp: you should read the docs > http://developer.android.com/guide/webapps/webview.html Aug 07 20:05:31 Hi. Aug 07 20:06:08 Napalm, thx i'll check it out Aug 07 20:06:36 when using GCM, the server can connect to google cloud via xmpp or http. But is connection device <> cloud also a xmpp connection, which is always on? Aug 07 20:06:39 autrilla, done in the setpositive as to handle different situations Aug 07 20:06:56 callmeDarwin, show me your code Aug 07 20:07:10 gist.github.com Aug 07 20:08:30 Maybe someone else can help, I'm going to sleep. See y'all Aug 07 20:15:46 autrilla, http://pastebin.com/XYGSnQZf Aug 07 20:16:54 autrilla, thanks for the direction I'll work it here Aug 07 20:17:05 well...looks like the UI quick isn't fixed :( Aug 07 20:28:20 crap. anyone know how to get the exact alpha channel value with gimp's color picker ? Aug 07 20:28:32 shift - select gives r,g,b but alpha as a percentage Aug 07 20:28:52 * g00s is investigating some 9 patches in the system res/ Aug 07 20:29:14 well.... as a percentage, that would be out of 100% so divide %value by 100 Aug 07 20:29:23 * g00s sighs :| Aug 07 20:30:05 i want it to be exactly the same, so if the drawable is adjacent to a system defined one, there is no transition Aug 07 20:30:06 Was that a facepalm, or did I not answer your question? Aug 07 20:31:00 so you're wanting the hex code? Aug 07 20:31:17 oh wait, as pixel its giving me a decimal # Aug 07 20:31:25 26 vs 10% Aug 07 20:31:32 thats good enough Aug 07 20:31:47 autrilla, what's the hassle of making libs public Aug 07 20:31:55 easier than running your own nexus Aug 07 20:31:56 good deal Aug 07 20:39:12 wowo, i didn't realize the drawable for primary progress indicator was a fancy gradient Aug 07 20:45:19 i just spent almost a day making the horizontal progress indicator taller (thicker bar). jees, that should be a basic call Aug 07 20:45:44 mucking around with layer lists, clips, guessing platform colors Aug 07 20:46:57 the default one is too damn thin anyhow, the google accessibility guy needs to kick the designer in the ass Aug 07 20:47:57 g00s, hmm? Just touch up the 9 patch for the progress drawable? Aug 07 20:48:12 I did that some weeks ago :p Aug 07 20:48:18 how the hell is anyone supposed to see #33b5e5 line 2dp high Aug 07 20:48:27 on a white background in daylight Aug 07 20:48:46 Screenshot - send to computer, open in fireworks, zoom in, pipette, get hex value Aug 07 20:48:49 ;-) Aug 07 20:48:54 Not that I have also had to do that :( Aug 07 20:49:08 Anthaas, you know there are apps to extract colour from the screenshot :p Aug 07 20:49:11 one thing i really like about Windows Phone - all the apps follow the system system defined theme, which you can change Aug 07 20:49:21 all you can change really is the highlight and background Aug 07 20:49:28 g00s, das no fun <_< Aug 07 20:49:29 haha, Afzal - you are too pro at this, I should up my game :P Aug 07 20:49:40 every app looks the same unless lots of work goes into not looking the same Aug 07 20:49:42 I do get that - there are certain portions of Android UI that are no flexible at all Aug 07 20:50:06 Like, for example, if you call TextView.setError(), you cannot change the layout of the view that is displayed Aug 07 20:50:06 Anthaas, haha. Screenshot > app > colour > send via pushbullet. Colour extraction level: CIA Aug 07 20:50:10 i.e. colour etc Aug 07 20:50:34 Anthaas yeah but a screenshot isn't going to have alpha Aug 07 20:50:43 lots of android drawables use alpha Aug 07 20:50:48 Its a fair shout :/ Aug 07 20:51:38 maybe android has this too , but also nice windows phone has high contrast mode, and sun mode Aug 07 20:51:42 We finally have global asset colours in Android L Aug 07 20:51:52 if I have a service, and I want that service to end, but restart 30 seconds later (and all this needs to be done within the service - there is no activity available) is this possible? Aug 07 20:51:59 Just set two colours in your theme and all assets are painted using those colours Aug 07 20:52:16 Afzal thats good Aug 07 20:52:19 i have to check that out Aug 07 20:52:31 So the progression of events, for example, would be, 1) Do stuff, 2) Set intent to start 30 seconds later, 3) Stop this instance of the service Aug 07 20:52:37 All called within the service Aug 07 20:52:45 g00s, you should watch Chris Banes' migrating to Android L video in that case Aug 07 20:53:01 Why not stop whatever the service is doing, wait 30 secs, launch the intent? Aug 07 20:53:05 i'm migrating to holo :( Aug 07 20:53:28 jvrodrigues: Just gave me an idea - clever man :D Aug 07 20:53:31 Anthaas, afaik, AlarmManager is outside your app so when you use that, it invokes whenever you want. I might be wrong about the first part though Aug 07 20:53:46 Afzal maybe you know : http://developer.android.com/design/style/color.html Aug 07 20:54:00 are the top swatches for the light theme, and bottom for the dark theme ? Aug 07 20:54:10 the first row Aug 07 20:54:11 Afzal: Yeah - for me when I tried it, the service ended and no alarm intent was launched Aug 07 20:54:15 Anthaas, i'm sure it has nothing to do with what i said, but you're welcome D Aug 07 20:54:34 ugh g00s, that is so two years ago. http://www.google.com/design/spec/style/color.html :p Aug 07 20:55:19 In fact that wont work Aug 07 20:55:23 and IMHO, the lighter swatches would look nice on the dark theme and vice versa Aug 07 20:55:37 Anthaas, I guess I'm wrong about alarm manager then Aug 07 20:55:43 Afzal right, but take aqua: is #33b5e5 light theme aqua, and #0099cc dark theme aqua ? Aug 07 20:55:51 ok Aug 07 20:55:51 My Service uses a broadcast reciever, I want that receiver to stop receiving anything for 30 seconds, and then after that time it can continue registering Aug 07 20:56:44 I thought I'd have to kill and restart the service 30 secs later, dont think itll work. I thought about unregistering the BR and reregistering later, but that would have to be done in onReceive() which would unregister the receiver which is running the onReceive the code would be in Aug 07 20:56:51 Out of ideas Aug 07 20:57:59 Anthaas, you could just keep a timer in your service and ignore until the timer runs out? Aug 07 20:58:32 ahh currentTimeStamp - cheers Aug 07 20:58:39 yeah Aug 07 20:58:44 ;) Aug 07 20:59:23 Anthaas, I do something similar here: https://github.com/AfzalivE/MI-Chat/blob/master/android-app/src/main/java/com/afzaln/mi_chat/activity/MessagesActivity.java#L405 Aug 07 21:00:24 and using AlarmManager means you can cancel stuff if it's not needed when AlarmManager is doing it's thing Aug 07 21:02:04 JakeWharton: What mechanism are you using to make sure Picasso doesn't double up on requests? Aug 07 21:02:12 a Map Aug 07 21:03:27 And how do requests get put into a holding pattern? Aug 07 21:04:09 there's a queue that the executor is using Aug 07 21:06:26 Ok cool. Aug 07 21:06:56 I don't know if it is because of RenderScript, or what the hell is going on, but onBitmapLoaded doesn't get called unless the debugger is attached. Aug 07 21:06:59 http://pastebin.com/i72LKSRU Aug 07 21:07:09 BlurTransform uses renderscript Aug 07 21:07:17 the Target is being garbage collected Aug 07 21:07:18 is it getting gc'ed? Aug 07 21:07:29 is using a ThreadpoolExecutor okay when you have data coming in continuously and each piece of data is analyzed independently? Is it still okay to just create a new thread every time? Aug 07 21:07:34 Whoa Aug 07 21:07:35 ok Aug 07 21:07:39 also, don't create a BlurTransform multiple times Aug 07 21:07:43 create it once and re-use it Aug 07 21:08:03 Since it uses context, is that ok? Aug 07 21:08:33 Why is target getting gc'd? Aug 07 21:08:35 Hands up if you feel thick as shit right now Aug 07 21:08:37 * Anthaas raises hand Aug 07 21:08:56 Anthaas, lol why? :p Aug 07 21:09:17 Saying that, I've never had exposure to these things I guess... Aug 07 21:09:49 oh, yeah never tried Renderscript stuff myself Aug 07 21:10:38 everything else in that pastebin looks familiar (never tried renderscript knowingly :p) Aug 07 21:10:58 "Renderscript" here is just using libraries that use renderscript. Aug 07 21:11:17 http://android-developers.blogspot.com/2013/08/renderscript-intrinsics.html Aug 07 21:11:55 oh okay, so BlurTransform and other transform stuff use Renderscript then? Aug 07 21:12:33 Transform is a class for Picasso, a 3rd party library used for loading images from URLs into views (and more) Aug 07 21:12:56 This custom transform utilizes the Renderscript libs to perform native image processing Aug 07 21:12:57 Picasso doesn't keep a strong reference to it Aug 07 21:13:03 JakeWharton: why is it gc'd? picasso doesn't hold a strong reference to the target obviously Aug 07 21:13:04 implement it on a View or set it as a tag Aug 07 21:13:07 Oh Aug 07 21:13:09 Lol Aug 07 21:13:26 Bluring bitmaps has always been painful on Android Aug 07 21:13:27 * Afzal wishes this was the next Nexus http://www.androidauthority.com/galaxy-alpha-clear-pictures-414082/ (sans the samsung part) Aug 07 21:13:28 real shame Aug 07 21:13:31 Ok, and last question, why keep an instance of BlurTransform, JakeWharton ? Aug 07 21:13:43 because it's wasteful to create every time Aug 07 21:13:50 unless this is only being called once Aug 07 21:13:59 * Napalm wishes they would build a Shader in for it. Aug 07 21:14:01 Yea, its a one-off Aug 07 21:14:10 ok, that's fine then Aug 07 21:14:21 Napalm: you wouldn't want a shader, shaders would blur the image every time Aug 07 21:14:37 And that would be expensive! Aug 07 21:14:52 So you make a blurred version, and just draw that. Aug 07 21:15:29 perhaps, but thats what GPU's are for Aug 07 21:15:41 they could then also optimize it in the framework Aug 07 21:15:50 like the new elevation shadows Aug 07 21:15:59 if I want to dynamically add a menu to the actionbar does that have to be done in onCreateOptionsMenu(Menu menu) ? Aug 07 21:16:05 is there a way to align the center of an imagespan with the center of the text? Aug 07 21:16:20 true. Aug 07 21:16:31 devslash: yes Aug 07 21:16:35 ok Aug 07 21:16:35 devslash: yea or onPrepareOptionsMenu Aug 07 21:16:44 devslash: context menu, or nav drawer? Aug 07 21:16:45 so i have an alertdialog prompt the user to enter a name Aug 07 21:16:46 call invalidateOptionsMenu to have onCreate called again Aug 07 21:16:52 I can see and modify my Android Device Name by going to Menu->Settings->Wireless and Networks->More Settings->Nearby Devices->Device Name. How in the world do I get that programatically? Aug 07 21:17:20 and then i want to add it to the actionbar. after they click on ok i call onCreateOptionsMenu(Menu menu) where menu is a reference to the menu actionbar Aug 07 21:17:30 jvrodrigues: http://developer.android.com/reference/android/text/style/ImageSpan.html < thats what the verticalAlignment is for Aug 07 21:17:32 but that call to onCreateOptionsMenu(Menu menu) causes my app to crash Aug 07 21:17:34 And what permission would that be? To traverse that path programatically, it would take several permissions, I think. Aug 07 21:18:00 :/ Managing a local db + wear storage. weird Aug 07 21:18:09 Napalm, the vertical alignment seems to be working against me, either aligns both baselines or the baseline of the imagespan with the center of the text Aug 07 21:19:22 devslash: sounds like you are doing something wrong. you probably want to put a item with your icon and showAsAction set to always. Then get the reference to this in your onCreateOptionsMenu and add a sub-menu with your other items Aug 07 21:19:58 any nice way (via API) to get username from uid on android? Aug 07 21:20:14 like 10056 -> app_56, 2000 -> system, 0 -> root etc Aug 07 21:20:18 jvrodrigues: go into developer options and turn on layout bounds.. you'll probably notice something else at work.. like your parent LinearLayout has the default baseAligned set to true Aug 07 21:20:28 Jonathan_Eyre, I don't see "Nearby devices" option on my phone Aug 07 21:21:35 Afzal: One guy said: Menu, settings, wireless & networks, bluetooth settings, device name Aug 07 21:21:51 Hi is there a way I can change the transparency of the actionbar dynamically? Aug 07 21:21:51 Seems like that's the Bluetooth name, though. Aug 07 21:22:09 is there any way to have dalvik cache regenerate without a reboot? Aug 07 21:22:14 i've made it an overlay but I also want to make it fade into invisible. Aug 07 21:22:20 JakeWharton: which event is called when I clik on the 3 dot menu ? Aug 07 21:22:22 Napalm, actually i'm setting the imagespan on the actionbar subtitle. I think i'm just going to scale the bitmap until it's actually the same size as the text Aug 07 21:22:23 i cant figure out how Aug 07 21:22:25 AKK9: yes, set a background drawable to it and change its alpha value Aug 07 21:22:43 devslash: none Aug 07 21:23:08 is it possible for mt to dynamically add a menu item to that menu Aug 07 21:23:16 what is "dynamically" Aug 07 21:23:22 you can add an item at any time Aug 07 21:23:30 call invalidateOptionsMenu and add it when onCreateOptionsMenu is called Aug 07 21:23:33 i mean prompt user for a string, add that to the menu ? Aug 07 21:23:44 oh ok Aug 07 21:23:47 yes Aug 07 21:23:51 devslash: ^ Aug 07 21:23:52 thanks got it Aug 07 21:24:03 JakeWharton, I wanted the transparency based on how far a listview has scrolled. Aug 07 21:24:31 Napalm, thanks Aug 07 21:24:38 AKK9: http://cyrilmottier.com/2013/05/24/pushing-the-actionbar-to-the-next-level/ Aug 07 21:24:40 thats what you want Aug 07 21:25:27 Napalm, wow that is exactly what im trying to make. i saw in the updated Google Play Store and though it looked quite nice. Aug 07 21:25:28 Thanks mate Aug 07 21:26:14 AKK9: your welcome, but if you really want to thank someone thank Cyril in his blog comments section Aug 07 21:26:29 thanks i got it working now Aug 07 21:26:57 One question though, how do I add the actionbar style without overriting an actionbar theme i already use? Aug 07 21:27:22 you dont have to use one Aug 07 21:28:09 So I can ignore the themes and styles he sets up? Aug 07 21:29:20 you would probably want to always have windowActionBarOverlay set to true and where you dont want it to overlay set padding or margin Aug 07 21:31:04 AKK9: hint use android:paddingTop="?android:attr/actionBarSize" Aug 07 21:32:11 AKK9: heres the guide https://developer.android.com/training/basics/actionbar/overlaying.html Aug 07 21:32:44 Yeha i seen that but I didn't like that I had to change my actionbar theme Aug 07 21:32:51 But I think ill do what you said with the padding Aug 07 21:32:52 you dont Aug 07 21:32:57 and I'll just have it overlayed always Aug 07 21:33:01 the windowActionBarOverlay is a attribute only Aug 07 21:33:10 exactly Aug 07 21:33:18 oh Aug 07 21:33:21 whatever Aug 07 21:33:37 Oh wait, so I can change that attribute when i create the activity? Aug 07 21:33:59 yes, but before you call setContentView Aug 07 21:34:13 AKK9: http://developer.android.com/reference/android/view/Window.html#FEATURE_ACTION_BAR_OVERLAY Aug 07 21:35:31 I understand, thanks Aug 07 21:39:15 Anyone here uses ViewPager? I set a text in the ActionBar but it is distorted because of the ViewPager, how can this be? Seems ridiculous. Aug 07 21:39:33 zwork seems rediculous indeed Aug 07 21:39:39 * g00s doesn't believe it Aug 07 21:40:22 well it happened when I added the viewpager...it only happens if i visit the fragment using the viewpager. then it shows up in other places as well Aug 07 21:40:50 zwork: yes, i posted the answer on SO.. one moment Aug 07 21:41:07 zwork: http://stackoverflow.com/questions/24089136/why-my-android-actionbar-doesnt-update-when-it-is-explictily-changed Aug 07 21:41:41 so apparently not, looks like I'll just have to hardcode them Aug 07 21:43:53 How do I make a drawable which is the correct size for the actionbar? Aug 07 21:45:21 AKK9 9 patch ? Aug 07 21:45:31 You dont need to. It can scale. Aug 07 21:46:27 heh. the joys of multi-threading and run locks. Amazing what a difference it can make when you fiddle with the runlock granularity. Aug 07 21:47:53 rgr run locks ? Aug 07 21:48:04 i've used spinlocks before, never heard of that Aug 07 21:48:06 synchronization guards. Aug 07 21:48:10 general term. Aug 07 21:48:57 googling "concurrency run lock" brings up virtually nothing Aug 07 21:49:07 actionbar images dont scale properly for some bloody reason - they have to be the correct size. look up the pixels for each dpi on d.android.com Aug 07 21:49:17 Napalm: checking it out now, thanks a ton Aug 07 21:49:26 Chainfire oh man :| Aug 07 21:49:42 stupidest shit ever. not sure if its still the case but it certainly used to be Aug 07 21:50:59 Chainfire: ive not experienced that on v4+ perhaps it was a honeycomb issue Aug 07 21:51:27 perhaps. all I know is that I'm sure I make them the right size, just in case Aug 07 21:51:34 rgr: its true, as in making them finer? Aug 07 21:52:04 depends. Aug 07 21:52:38 rgr: be careful though.. this happened to me before https://code.google.com/p/guava-libraries/issues/detail?id=1403 Aug 07 21:52:38 make them too fine and its bad. make them too large and they can cause stutter, of course depends on what you're doing and which thread really needs access as a priority. Aug 07 21:53:01 rgr: in this case, "synchronized" was optimized out by the compiler :| Aug 07 21:54:47 Can I remove the shadow on the listview? Aug 07 21:54:55 shadow? Aug 07 21:54:59 Not sure if the shadow is at the top of the listview, or under the actionbar. Aug 07 21:55:05 yea Aug 07 21:55:21 add android:windowContentOverlay="@null" to your theme Aug 07 21:55:45 in Eclipse Luna, is it safe to use JDK 1.8? Specifically, I would like to use the class LocalDateTime. Aug 07 21:55:47 some optimisation... Aug 07 21:56:23 lol Aug 07 21:56:30 with the Android tools to create an Android app, for version 4.4.4. Aug 07 21:56:55 Amazing, thanks Napalm Aug 07 21:57:18 zwork: your adapter is using the wrong fragment-manager Aug 07 21:57:54 ok, so why is it that my spannable image only works when i get a resource from an already loaded image. Aug 07 21:57:57 Hmm, getContentResolver().insert(Uri.parse("content://sms/sent"), values); is actually sending an SMS on my N5, I wonder if it even uses the permissions? Aug 07 21:58:11 Nivag android is java 6/7-ish Aug 07 21:58:26 As in imageView.getDrawable() and not a drawable gotten through getResources()? Aug 07 21:59:23 jvrodrigues: because its bounds are set.. you need to set the drawables bounds. code on its way. Aug 07 21:59:33 are not set Aug 07 22:00:16 jvrodrigues: drawable.setBounds(0, 0, drawable.getIntrinsicWidth(), drawable.getIntrinsicHeight()); Aug 07 22:00:21 Napalm, both use the support one...? Aug 07 22:00:44 When I make the actionbar transparent only the background goes transparent, all the buttons and stuff stay. Howo can I make the entire thing go transparent at the same time? Aug 07 22:01:05 Napalm: Will it not work with the support library? Aug 07 22:01:17 beautifull Napalm thanks! Aug 07 22:01:24 zwork: support fragments getFragmentManger() and getChildFragmentManager() return the support ones. Any fragment that loads other fragments contained within its own view hierarchy must use the getChildFragmentManager() Aug 07 22:02:08 When rendering direct to a surface having obtained using surfaceholder.lockCanvas is it generally the case in android, or maybe just a nexus 4, that you're limited to 60fps. Or is it just a coincidence that that's the rate my app is churning frame out? Aug 07 22:02:22 Anthaas: so the destination actually recieved it? hmm.. sounds like a bug in Hangouts.. if thats your default Aug 07 22:03:08 Napalm: Precisely. Aug 07 22:03:11 And it is. Aug 07 22:03:23 Im wondering if it actually bypasses the permission Aug 07 22:03:41 I would check, but Ill do it tomorrow haha Aug 07 22:03:48 if it does, raise a bug ticket Aug 07 22:04:09 and ping it back here so it can be picked up and raised as a priority Aug 07 22:04:09 Will do Aug 07 22:04:17 Ill look now Aug 07 22:04:23 you are talking about this call right? pageAdapter = new ChooseLevelAdapter( Aug 07 22:04:23 getActivity().getSupportFragmentManager(), Aug 07 22:04:24 fragments ); Aug 07 22:05:15 nm saw your post Aug 07 22:06:36 AKK9: android:alpha in your actionbar style. Aug 07 22:07:00 Napalm: Ok, it doesn't send, but doesn't throw any exception or error or anything of the sort. Aug 07 22:07:08 eg https://gist.github.com/anonymous/17c92ed3f10bffca393 Aug 07 22:07:40 rgr: 404 on that gist Aug 07 22:07:52 rgr, I want to change the alpha of the actionbar based how far a listview has been scrolled Aug 07 22:08:08 so far ive made a drawable and changed the alpha of it Aug 07 22:08:18 but i was hoping I could do this for the actionbar as a whole Aug 07 22:08:30 AKK9: sounds like want you really want to do is control the animation of the actionBar Aug 07 22:09:22 Napalm, animation? i just want it to disppear gradually as the user scrolls past the first item on the list view. Aug 07 22:09:42 AKK9: yes, Animation as in fade in and out Aug 07 22:09:46 Napalm: Would you say that is a bug, even though its not? Aug 07 22:09:59 i think its fine Aug 07 22:10:03 okay ill look into that and see how it goes Aug 07 22:10:07 hmm thats not the first time thats happebed. weird. Aug 07 22:10:10 Hmm, odd that it would send the sms using that though Aug 07 22:10:20 https://gist.github.com/anonymous/17c92ed3f10bffca3939 Aug 07 22:10:21 rgr: copy/pasta bug? Aug 07 22:10:25 ha. yup. Aug 07 22:10:27 g00s: That what I thought, as I think they may have added at least one new byte code to the JVM. However, has anyone tried JDK1.8 successfully to develop Android apps, or is the 1.8 JDK totally ruled out for now? Aug 07 22:10:27 yup.. Aug 07 22:10:59 rgr: that just gave me an idea Aug 07 22:12:00 rgr: oh my code.. that could be an awesome hack thats legit. set android:tag="something" on the style and then use View.findViewWithTag("somethingW); to get a handle to the actionBar Aug 07 22:12:06 Nivag use 1.7 source code compatibility Aug 07 22:12:19 you can still use java 8 javac Aug 07 22:12:28 a nice way to get the actionBar view on all platforms without looking for internal id's ? Aug 07 22:12:31 me thinks it could work Aug 07 22:12:48 I dont know enough about it. You mean you cant get a ref to the actionbar view as it is? Aug 07 22:12:56 nope Aug 07 22:13:13 since its your app thats a bit strange. Whats the reasoning or is it just legacy? Aug 07 22:13:14 its a flaw in the original ActionBar principles thats been corrected in L Aug 07 22:13:25 interesting to know. Aug 07 22:13:56 g00s: That is SO obvious! I should have realized that myself, having used Java for 15+ years! :-) Aug 07 22:14:26 rgr: imho, thats just my opinion Aug 07 22:19:32 rgr: it works! Aug 07 22:20:42 hey AKK9 Aug 07 22:22:21 g00s: The android tools slapped my wrist when I tried to set anything to above JDK1.6! :-( Aug 07 22:22:42 Nivag: wrong build tools version Aug 07 22:25:16 Napalm, why would I want the childfragment manager? Aug 07 22:25:41 zwork: read up above, i already answered that Aug 07 22:26:10 zwork: in the meantime, post your ChooseLevelAdapter code to the SO post. Aug 07 22:27:32 g00s: I thought I WAS using the latest! Both the Eclipse update & Android SDK Manager says I'm up-to-date. My Manifest to set to SdkVersion="19". What have I missed? Aug 07 22:28:13 check your project.properties file and also, make sure you update your Eclipse plugin Aug 07 22:28:17 g00s: I have a Nexus 7 with Android 4.4.4 Aug 07 22:28:31 Nivag: that was a message for you Aug 07 22:29:04 Napalm: thanks Aug 07 22:35:17 can you change the swipe color? meaning the color that shows up on the edge when you swipe in a viewpager or list/scroll view? Aug 07 22:35:33 yes with something i write Aug 07 22:35:35 wrote Aug 07 22:35:47 zwork: https://github.com/slightfoot/android-edge-effect-override Aug 07 22:36:18 if you want to apply it Activity wide (probably true) then use the attach Base content Aug 07 22:36:19 context Aug 07 22:36:25 Napalm: the only property in project.properties is target=android-19, eclipse considers me up-to-date - as far as I can tell! All Android tools show as 23.0.2, for example: Aug 07 22:36:27 \Android DDMS 23.0.2.1259578 com.android.ide.eclipse.ddms.feature.feature.group The Android Open Source Project Aug 07 22:38:08 Napalm, ty Aug 07 22:38:17 Napalm, I posted the adapter code as well Aug 07 22:38:44 zwork: like this http://pastebin.com/6jpnFbe5 Aug 07 22:38:53 as a method in your Activity Aug 07 22:39:24 strange bug where onSurfaceCreated call back is not being called when I recall my app. since its there once is recommended to start rendering threads etc this is a bit of a problem... Aug 07 22:40:42 Nivag: check your eclipse workspace settings for java environments. open preferences and type in jre. you'll see the options. make sure its only got 1.8 and your Java>Compiler>JDK Compliance level is set to 1.6/1.7 Aug 07 22:44:51 zwork: correction on that paste: http://pastebin.com/dASAwr2L Aug 07 22:47:40 can someone tell me what are glob uri selectors? Aug 07 22:47:42 https://developer.android.com/reference/com/google/android/gms/wearable/DataApi.html Aug 07 22:47:48 (deleteDataItems) Aug 07 22:48:27 i think that was suppose to read global Aug 07 22:48:48 oh wait Aug 07 22:48:57 a Uri that matches others Aug 07 22:49:21 Napalm, hmm. I have this uri: WEAR_URI_SCHEME + /motion837498273498 Aug 07 22:49:32 Afzal: http://developer.android.com/reference/android/content/IntentFilter.html Aug 07 22:49:35 I want to remove everything that matches WEAR_URI_SCHEME + /motion*** Aug 07 22:49:40 search that page for glob Aug 07 22:49:48 you'll see globbing pattern Aug 07 22:50:04 Napalm, thanks! I'll try that Aug 07 22:50:08 ". If the latter, you can use '*' anywhere in the pattern to match zero or more instances of the previous character, '.' as a wildcard to match any character, and '\' to escape the next character." Aug 07 22:50:11 Afzal: wait Aug 07 22:50:25 Afzal: are you simply trying to delete one data item? Aug 07 22:50:31 then use the Uri you have Aug 07 22:50:46 or all motion events say use WEAR_URI_SCHEME + "/motion*" Aug 07 22:50:52 Napalm, no, I'm trying to remove all data items, yeah like that Aug 07 22:51:08 oopsy Aug 07 22:51:08 because I stupidly didn't put a / at the end of that "motion" >_< Aug 07 22:51:19 that was suppose to read: WEAR_URI_SCHEME + "/motion.*" Aug 07 22:54:17 whats the best way programatically to completely wipe a setting holder from Settings.System. Aug 07 22:54:26 Napalm, thanks! didn't work though :/ Aug 07 22:55:09 are you implementing the remote end on your wear app? Aug 07 22:55:23 then you'll need to use the Uri correctly to match more Aug 07 22:55:48 can I stop the threads view auto expanding with each step in intellij? Cant see the option. Aug 07 22:56:05 do people usually set up some kind of corporate developer account when starting to publish apps? It's not clear to me how to do it... Aug 07 22:58:20 Napalm, I'm removing all the items from the wear storage network on a localdb upgrade. I should expect the dataItems to be removed from the wear app as well, right? Aug 07 22:58:51 nesoi: you create a new Google account for your company and use that with google services. Inside the Google Play store you can enable two-factor authentication and that is your master account. Aug 07 22:59:35 nesoi: now you can login to the publish console with that master account and add your own personal google account with permissions to publish apps, or limited too other things. Aug 07 22:59:39 Napalm: thanks… but in the signup it wants a name, not a corporate name Aug 07 23:00:00 is there a separate place to sign up for a corporate account? Aug 07 23:00:29 You sign up as a person who manages the account I believe. Aug 07 23:00:34 the name can later be changed. Aug 07 23:01:40 Napalm, seems that the uri might be wrong here Aug 07 23:03:04 Napalm: It doesn't look correct. it wants a date of birth, etc. Aug 07 23:06:13 nesoi: its how I have done it and it works fine.. I am the "owner" of said business so its my details. Aug 07 23:06:29 nesoi: once done.. if your that concerned then you can add a business listing connected to the account Aug 07 23:09:14 nesoi: https://www.google.co.uk/a/signup/u/0/#0 Aug 07 23:09:18 or .com Aug 07 23:09:27 https://www.google.com/a/signup/u/0/#0 Aug 07 23:09:41 see it provides a name for business Aug 07 23:10:32 can I be confident that, the compiler optimizes things such as, "while (running) { long curTime = ..; more code etc; }, the application won't create a new variable (curTime) each tick and mark for garbage, but instead reuse the same variable or something? Aug 07 23:11:19 I currently have curTime as a global variable because of this, but I'm 90% sure it's not necessary.. Aug 07 23:17:01 I'm coding part of the TeleService.apk. Is there any way to clear the dalvik-cache of a singular app, rather than having to rebuild the entire cache? Aug 07 23:18:09 NVM..... I found that it should be possible. I guess the question now is if I do delete the system@priv-app@TeleService.apk@classes.dex, will it rebuild upon restart. Aug 07 23:18:11 altcp: you can make it volatile Aug 07 23:19:29 is something like long curTime even handled by GC ? I would doubt it. Aug 07 23:19:37 ok, thanks Napalm. Aug 07 23:19:51 its a primitive type. Aug 07 23:21:04 currently I have "long curTime; while (running) { code; }" so I think that bypasses it :P Aug 07 23:21:21 (although I still wonder if it makes a difference) Aug 07 23:28:16 Napalm: I just looked up volatile, what will it change exactly? Aug 07 23:28:23 (in this case) Aug 07 23:28:39 it means curTime will not be cached/optimized Aug 07 23:30:13 I see.. but that's the opposite of what I want :P Aug 07 23:30:46 show the code in a paste. What are you using it for and are you updating it? Aug 07 23:31:12 its a primitive type so there will be no GC afaik....... let the compiler do the work. Aug 07 23:32:06 http://pastebin.com/0aUxBPFb Aug 07 23:32:18 what are you trying to do? Aug 07 23:32:27 ack. I found my bug. I had a return in a catch which was triggered by a Thread.sleep interruption and thus exiting my runnable's run(). Doh. Aug 07 23:32:33 not trying anything, just wondering if it hurts leaving the variable initialisation inside the loop Aug 07 23:32:46 yes it does a lot. Aug 07 23:32:58 alright thanks Aug 07 23:33:15 altcp: http://pastebin.com/ATsDNjrU Aug 07 23:33:20 it gets reinitliased on each and every run. thats probably not what you want. You probably want the "time" to be the same in all code called in that loop I would guess. But who knows. You havent said. Aug 07 23:33:25 yup that's how I have it now Aug 07 23:33:46 rgr: I thought the compiler would optimise it, you're saying this is not the case? Aug 07 23:33:49 altcp: it shouldnt make that much of a difference Aug 07 23:33:53 it does optimize it Aug 07 23:34:01 the variable is given scope in the locals Aug 07 23:34:02 okay, who do I believe? :p Aug 07 23:34:06 Why wuold it optimise it? it's a new value each loop. Aug 07 23:34:25 rgr: he means the allocation not the initialisation Aug 07 23:34:39 I know what he means. but it makes no difference to him. Aug 07 23:34:50 its a primitive. its reset each and every loop- Aug 07 23:35:02 yes but the stack memory is the same Aug 07 23:35:21 the compiler handles that Aug 07 23:35:27 that shouldnt matter to him or anyone else. The point is the compiler handles it. Aug 07 23:35:30 exactly Aug 07 23:35:34 thats what he was asking Aug 07 23:35:52 and again - he was on about gc. thats not involved here. Aug 07 23:36:04 I only do that to show scope. if ever. Aug 07 23:36:10 altcp: ^ Aug 07 23:36:24 rgr: was he? i didnt pay that much attention Aug 07 23:36:25 lol Aug 07 23:37:01 ok the GC's just a detail, was kinda ignorant of it, I just wondered if it makes a difference (in the end result) Aug 07 23:37:15 which appears to be no Aug 07 23:37:59 its far from a detail :) It was the major "Q" I had regarding your query about it being "optimised". GC is not invoked for that. Aug 07 23:38:24 personally I would have the long inside the loop for scope clarity. Aug 07 23:38:30 it's a detail in my question Aug 07 23:38:31 alright Aug 07 23:38:37 later. Aug 07 23:58:27 If I have a line ListView theSensors = (ListView) findViewById(R.id.sensorList); why is eclipse unhappy with the next line theSensors.setAdapter(sensorsAdapter); Aug 07 23:58:55 its probably because its suppose to be setListAdapter Aug 07 23:59:13 oh wait Aug 07 23:59:16 im thinking of something else Aug 07 23:59:32 its is because sensorsAdapter is not a ListAdapter Aug 07 23:59:36 Napalm: the period is highlihted and so is the argument Aug 07 23:59:50 press whatever brings up the javadoc in eclipse. Aug 07 23:59:50 jamesson: what does it tell you if you put your mouse over it? Aug 08 00:00:05 sorry, I gave the wrong preceding line ArrayAdapter sensorsAdapter; Aug 08 00:00:36 youre probably better off posting a gist/pastebin Aug 08 00:00:40 there you go. uninitialised variable. Aug 08 00:01:23 since the name is different from last line and ones before hard to tell... Aug 08 00:01:23 Napalm: so I have to initialize it inline? Can I do it before setContentView? Aug 08 00:01:42 jamesson: the adapter needs to be set before you call setAdapter Aug 08 00:01:55 set or created?.... Aug 08 00:02:00 /correction adapter needs to be created Aug 08 00:02:05 ;) Aug 08 00:02:07 ;) Aug 08 00:02:28 but we dont know because the code has changed with names etc, post a small gist. Aug 08 00:02:49 http://hastebin.com/pepavavaso.axapta Aug 08 00:03:39 you havent created sensorsAdaptor. Aug 08 00:04:09 so obviously you cant use it... ;) Aug 08 00:04:41 rgr: so I need to set the view before I can access the variable? Aug 08 00:04:46 no. Aug 08 00:05:04 you need to create your adaptor from what I can see. Aug 08 00:05:22 rgr: then what does line 2 do? Aug 08 00:05:30 (Im guessing from standard java point of view but I dont know adaptors per se) Aug 08 00:05:53 It declares a reference which is null. Did you step through with the debuger? Aug 08 00:06:13 rgr: I cannot build yet Aug 08 00:06:50 I suggest you do the oracle java tutorial if you havent already done so and, of course, this isnt just a silly oversight ;) Aug 08 00:06:57 rgr: Im assuming you mean the variable is uninitialized. How do I initialize it? Aug 08 00:07:24 you look up in the java tutorials how to create objects. Aug 08 00:12:44 how can i have a split screen view in android studio? Aug 08 00:12:54 Anyone have an idea why a CheckBoxPreference isChecked() would return true when the checkbox on screen is not checked? Aug 08 00:13:10 whomp: right click and chose split vertically Aug 08 00:13:19 on the tab I mean Aug 08 00:13:49 whomp: it has split screens Aug 08 00:14:17 great, ty Aug 08 00:17:30 Napalm: Sorry got distracted. Thanks for that. Now I an using JDK 8 as before, but I have been able to up the version used by Android tools from 1.6 to 1.7! Aug 08 00:27:24 Hi guys. Time for a n00b question :D.. So, my project has grown quite big, and the UIthread especially has grown quite complicated. I was wondering, besides from building custom timers and boolean checks, is there a better way for me to know when different methods are done? Aug 08 00:27:48 For instance, I need to do some work in onStart, but i can only do that werk if onCreateOptionsMenu has finished Aug 08 00:28:05 this is different under certain circumstances Aug 08 00:28:05 ThomQ: decouple it with message bus Aug 08 00:28:39 I have never used messages before. Should I google Broadcasters and recievers? Aug 08 00:28:40 https://square.github.io/otto/ <--- for example this Aug 08 00:28:55 ThomQ: no, those are for inter-application messaging Aug 08 00:29:08 Otto is an *internal* event bus Aug 08 00:29:31 you read up on the lifeycle. These run on the main thread. btw I seem to recall there is no guarentee when that (onCreateOptionsMenu) is called. I cant see any reason for buses or queues here. Aug 08 00:31:19 rgr; yeah at this point I'm fairly read up on activiy and fragment lifecycles. It's mainly when I have to wait for other listeners to run first before I do any actions, like OnConnect or onCreateOptionsMenu. Why is there no guarantee that onCreateOptionsMenu is ever called btw? Aug 08 00:31:33 and p_l: thanks, I'm reading up on it now Aug 08 00:31:44 Im not sure. I was told the other day. Aug 08 00:32:40 I haven't seen that problem yet fortunately. Aug 08 00:33:24 I hope it's not going to happen either :D Just published yesterday Aug 08 00:33:30 wow, what's the use of being able to provide glob uri selectors if the first part of the uri needs you to keep track of the node id >_< Aug 08 00:34:08 even all of google's wearable samples have to get all data items and then delete them one by one instead of just deleting them using a uri selector Aug 08 00:34:10 come on :/ Aug 08 00:40:51 p_l: I read Otto's page, it's not Entirely clear yet (must be the time of day here). So lets say in the situation of having to wait for OnConnect and onCreateOptionsMenu to finish before running a certain method. I end both requited methods with a seperate event call, and then get those events in a subscriber method Aug 08 00:42:06 so the method fires Twice at that point, correct, one for every events. So I'd need some sort of bool or null check to verify if the other one already exsists / is true upon receiving an event? Aug 08 00:43:05 I think I'm misunderstanding, because in what I just described, I could just send an int or string to the recieving method Aug 08 00:43:12 probably, but checking out if you have run a method vs. gonzo weird timers and checks... :D Aug 08 00:44:03 i can have [:-)] action key with android:inputType="textShortMessage" and [return ...] without it. long pressing [return ...] gets me to the smileys. can i have a [:-) ...] key that long-presses into enter key? Aug 08 00:44:22 yeah, and especially in Large examples with Tons and Tons of methods, I see how it can be helpful Aug 08 00:45:23 and, can i have [Send] button with multiline text (no carriage returns)? Aug 08 00:46:48 yeah, I think I'm stuck to having to deal with the Spagetti my UI thread is atm Aug 08 00:51:10 WHy dont you just make some runnable classes with interfaces so that when run completes it calls back to your activity and then you perform whatever you need to? Aug 08 01:01:45 Where in your project directory do you sit preferences.xml? Aug 08 01:01:54 in res/xml ? Aug 08 01:01:59 why use runnables for that? Just use a standard handler and post back to ui thread. Aug 08 01:02:55 handleris more complicated Aug 08 01:03:18 you can define your own callback with some interface, and just stick its observing method at the end run Aug 08 01:03:38 The easiest way to do threading with callbacks is actually using context local broadcast receivers Aug 08 01:03:39 plus the classes implementing runnable can do some specific function, makes for good abstract and encapsulation and composition Aug 08 01:03:53 easiest != best though Aug 08 01:04:00 Anthaas: no way, involving context? Aug 08 01:04:14 Yeah, so keeping it local to your activity, for example. Aug 08 01:04:15 why invoke complicated datastructures like context and handler? Aug 08 01:04:49 all you need is interface onTaskComplete { void taskIsComplete() } and some class DoWorkTask implements runnable Aug 08 01:04:54 I refer the honourable gentleman to my previous statement Aug 08 01:05:16 he was specifically doing a bunch of different things and said his code was sphagetti Aug 08 01:05:28 Ahh consistency is often more important. Aug 08 01:05:35 YOu want to put in an extra layer of threading and runnables and interfaces? Maybe I missed something in the requirement. All his stuff is on main ui thread. Aug 08 01:05:40 Ill assume preferences.xml goes in res/xml then? Aug 08 01:05:44 i dont know why you'd use broadcast recievers to communicate asynchronously within the same activity Aug 08 01:05:51 he doesnt. Aug 08 01:06:05 he should be doing work off the ui thread anyways Aug 08 01:06:07 Like I said, I never said it was the best way, its just the easiest way Aug 08 01:06:15 rgr he was talking to me Aug 08 01:06:26 oh. sorry thought he was to ThomQ. Aug 08 01:06:47 Nah, I mentioned that they are the easiest way - not the best way Aug 08 01:07:23 easiest for what? The easisest is merely to post back to a state handler. Aug 08 01:07:48 To understand Aug 08 01:07:53 I found it was anyway Aug 08 01:08:05 I dont use it Aug 08 01:08:16 I just did to understand broadcast receivers and how they worked Aug 08 01:08:19 It worked for me I guess haha Aug 08 01:12:08 I cant believe Ive never had to develop an app which had settings before. haha Aug 08 01:12:36 Hard to find an example that isnt out of date Aug 08 01:12:46 apparently addPreferencesFromResource is deprecated.. lol Aug 08 01:13:51 but it still works Aug 08 01:14:09 But is it really a good idea to keep using deprecated methods? Aug 08 01:15:12 Ahh - preference fragments Aug 08 01:15:42 Wait Aug 08 01:15:54 Whats the point in having a SettingsFragment if you are only ever going to display settings in a settings activity? Aug 08 01:16:15 I get that fragments are good for reusability, but I don't really ever see a settings page being reused? Aug 08 01:17:04 Ahh its for the whole tablet thing Aug 08 01:17:11 on (some) tablets the device settings activity in landscape mode has kind of "tabs" on the side Aug 08 01:17:37 Yeah - this is only being used on one device (one single device, not model), so I guess its not that important. Aug 08 01:17:44 yo yo yo Aug 08 01:26:55 Question; I'm building a tutorial overlay. Currently I'm using a screen filling half transparent dialog, since that's the only way I could find to get the overlay on top of my actionbar. However, this makes all my animated elements move in jerky fashion, due to the focus being on the Dialog. Aug 08 01:27:21 So I'm looking for a way to get a normal view overlaying the actionbar, but google wasn't helping much, other then saying "Dialog" Aug 08 01:27:23 any suggestions? Aug 08 01:35:58 How'd you come to the conclusion that it's due to the focus being on the Dialog? What does that even mean, plus what animations, ones playing underneath your dialog? how are you playing/animating them Aug 08 01:37:32 ThomQ: what exactly is the problem? Aug 08 01:43:01 Napalm: the problem is animations being choppy when the dialog overlay is added Aug 08 01:43:28 ThomQ: is this in the Emulator? Aug 08 01:46:40 this is going to be something glaringly obvious : I have a png thats 91 pixels high in my drawables. I load it using BitmapFactory.decodeResource. bmp.height is giving me double, ie 182, the height. Why could this be? Im not setting anything in the options parameter. Aug 08 01:48:20 Ive just realised the whole app could be a PreferenceScreen hahaha Aug 08 01:48:21 wow Aug 08 01:48:46 The actual functionality is within a service Aug 08 01:48:47 rgr: you didnt set the density right Aug 08 01:49:26 rgr: infact its right, its doubled the height in pixels to match the devices density Aug 08 01:49:30 im writing to a surface and only using pixels. I havent set density anywhere I must admit. Aug 08 01:49:44 still inferred :) try putting it in a -nodpi folder. Aug 08 01:50:33 Yeah, Ive been delaying this part of android learning by doing I must admit. The whole scaling thing wrecks my head a little. I need to go do some spadework. Thanks. Aug 08 01:50:58 rgr: be sure to dig at least 6 feet before burying something. Aug 08 01:51:01 rgr: you can specify a BitmapFactory.Options class with the densities set Aug 08 01:51:19 ok I'll look at that. Aug 08 01:51:47 rgr: set inScaled = false.. by the looks of the docs Aug 08 01:52:18 perhaps Aug 08 01:52:21 blah, its late Aug 08 01:52:40 too tired for this crap.. got my fancy hiding ActionBar class made Aug 08 01:52:44 who wants it? Aug 08 01:53:19 suddenly nobody Aug 08 01:53:22 :D Aug 08 01:53:38 Napalm, no it is on test devices Aug 08 01:54:03 it is indeed. working. thanks. Aug 08 01:54:04 For instance the zoom of the google maps camera, an animtion driven by a Timer and a handler Aug 08 01:55:36 https://gist.github.com/slightfoot/95a87f6f0ab08600b45d#file-actionbarhider-java Aug 08 01:56:20 ahh no, i need the actionbar Aug 08 01:56:32 its a tutorial, and parts of the action bar are also explained Aug 08 01:56:40 ThomQ: that wasnt for you.. but a link in general for the room Aug 08 01:57:01 Ahh sjit Aug 08 01:57:03 haha sorry man Aug 08 01:57:18 I bookmarked it though Aug 08 02:01:02 which I switch from my initial launch activity to a second activity, the app goes to my home screen then launches the 2nd activity. Why is that happening? Aug 08 02:07:05 Added example of use with a ListView https://gist.github.com/slightfoot/95a87f6f0ab08600b45d#file-observablelistview-java **** ENDING LOGGING AT Fri Aug 08 02:59:59 2014