**** BEGIN LOGGING AT Mon Feb 09 02:59:58 2015 Feb 09 03:21:59 yiati: thnx solve Feb 09 03:22:13 yiati: i have solve the problem Feb 09 03:43:09 john67: cool what was the problem? Feb 09 04:05:40 How to figure out which child view was clicked in a parent's onClick or onItemClick handler? Feb 09 04:05:58 Got a ListView with multiple clickable regions Feb 09 04:07:47 Seems like setTag can be used to associate a random object with a view. Is it arbitrary? Feb 09 04:08:13 I can easily use the tag to tell the views what to do in their onClick handlers Feb 09 04:08:47 without plumbing back through the listview to the fragment etc. Navigating trees in code is evil. Feb 09 04:15:13 hmm, a Swift compiler for Android and .net Feb 09 04:17:36 from apple? Feb 09 04:18:48 yiati https://news.ycombinator.com/item?id=9019498 Feb 09 04:19:09 <_genuser_> oh geez, LogCat stopped working. Feb 09 04:19:12 <_genuser_> ove eclipse bugs. Feb 09 04:19:18 <_genuser_> *love Feb 09 04:19:53 probably adb Feb 09 04:19:58 happens to me in AS all the time Feb 09 04:20:06 g00s: interesting, but yeah if it's third party and it comes from apple land then it's not going anywhere Feb 09 04:20:22 unless they decided to make their own clone or buy it Feb 09 04:23:35 <_genuser_> g00s: heh, at least re-starting eclipse is a lot faster than AS. Feb 09 04:23:58 <_genuser_> hey offloading work to IntentService is working!! need to beta test it further. Feb 09 04:24:29 :) Feb 09 04:26:11 <_genuser_> now if my ProgressDialog went away properly.... Feb 09 04:28:05 <_genuser_> seems like while teh IntentService runs the main activity kinda just freezes over. Feb 09 04:30:40 _genuser_ get rid of the progressdialog, thats like froto crap Feb 09 04:30:45 *froyo Feb 09 04:31:43 <_genuser_> so how does one show stuff in progress? Feb 09 04:32:11 _genuser_ what have you observed in newish apps ? Feb 09 04:32:59 <_genuser_> I'll be honest, I'm not that into using apps. I guess hangout is the one I use the most. and I use that once in 6months. and the UI is different everytime. Feb 09 04:33:36 <_genuser_> I can think of the think progress bar embedded at the top of the UI somewhere below actionbar, etc. Feb 09 04:33:43 <_genuser_> s/think/thin/ Feb 09 04:35:40 i see the swipe to refresh spinning disk thing too Feb 09 04:35:59 yeah, i dont use many apps either. play books puts an indeterminte spinner in the content area Feb 09 04:36:21 <_genuser_> so you're saying do something on screen without showing older style pgoress bar. Feb 09 04:36:31 <_genuser_> I can dig that idea of _NOT_ showing older UI patterns. Feb 09 04:38:03 yeah Feb 09 04:38:45 <_genuser_> well, thanks for mentioning that. :) if the app is slow, at least it should _look_ modern Feb 09 04:39:20 <_genuser_> argh stupid timesheet. I just remember to do mine. Feb 09 04:49:05 _genuser_: as an user in general, I prefer when apps are responsive :D Feb 09 04:49:43 <_genuser_> p_l: I'm working on that bit. It's just a lot of processing. I'm looking into caching, background processes, work-ahead, etc. Feb 09 04:50:46 just minimalizing blocking and having some indicator of what is happening (even better if it can subtly show what stage of work the application is on) does wonders Feb 09 04:51:53 <_genuser_> yeah, that's why I was showing a progressdialog. but I think I'll just have an onscreen overlay progress bar. somethign with a transparent background so the UI underneath is still visible. Feb 09 04:52:51 remember that transparency has a huge cost in drawing Feb 09 04:53:32 <_genuser_> well, people _are_ carrying around quadcore pentiums in their pocket, lol. Feb 09 04:56:03 man i hate when i gave to come back up and work on the ui shit, so depressing Feb 09 04:56:16 _genuser_: and use the extra power mostly on less efficient code because "well, it runs good enough when it's the only application on my high-end machine, so of course it does fine on performance, right?" Feb 09 04:57:13 <_genuser_> p_l: no, my last comment was a joke. I'm cutting out all the unneccesarry bits out. For example, I'm on my third implementation for this current feature. Feb 09 04:57:37 <_genuser_> I'm logging time it takes for each individual step in the process using task timers and trying to find the fastest route. Feb 09 04:57:59 oh nice, GTD 2015 edition coming out soon Feb 09 04:58:37 _genuser_: I've recently read some interesting bits regarding using asynchronous tasks coming from a real-time world, where they made even a logging function async Feb 09 04:59:09 isn't logging ususally async ? Feb 09 04:59:19 g00s: log functions tend to be sync Feb 09 04:59:22 afaik :) Feb 09 04:59:32 at least in slf4j-logvack and log4v Feb 09 04:59:35 *log4j Feb 09 04:59:39 <_genuser_> logging would have to sync to get teh log output in the correct order. Feb 09 04:59:44 actually, log4j uses lmax disruptor Feb 09 04:59:46 now imagine that everything that didn't need to was pushing a request to another queue Feb 09 05:00:08 <_genuser_> or at least it would have to be queue in a fifo pipe somewhere to correct order of log stmts is written Feb 09 05:01:38 <_genuser_> opensuse, that's a nice cloak. Feb 09 05:08:44 Can I bubble an event to a parent even though I have an onClickListener set in a child? Feb 09 05:13:31 alternatively, how can I figure out which child was pressed in a parent's onItemClick? Feb 09 05:19:55 g00s: now That's a disruptor http://www.artasylum.com/wp-content/uploads/2013/02/Disruptor1.jpg Feb 09 05:20:37 capella-s3 lol, i've never seen that before but i'm guessing its ... klingon Feb 09 05:21:17 who also had cloaks Feb 09 05:21:30 hehe :p Feb 09 05:22:47 capella is it star trek ? Feb 09 05:23:01 ofc! Feb 09 05:23:26 that looks like original star trek kinda look Feb 09 05:23:50 <_genuser_> TOS FTW!! Feb 09 05:24:19 Yah, just random google... i saw your lmax disruptor comment and that's all I could think about Feb 09 05:28:45 How can I respond to touch events while allowing them to bubble up to the parent (in a list) to let the click animation for the list item go off? Feb 09 05:44:02 hello Feb 09 05:44:12 I have an activity, in this activity I have Feb 09 05:44:15 public boolean dispatchTouchEvent(MotionEvent event) Feb 09 05:44:30 I was under the impression, returning false would mean the screen is essentially disabled from touch Feb 09 05:44:37 which is the case Feb 09 05:44:44 however, when I return true it is also disabled Feb 09 05:44:54 i don't know why that is happening Feb 09 06:16:32 ir7466, don't call super Feb 09 06:17:08 i'm not calling super Feb 09 06:17:44 it looks like this: Feb 09 06:17:47 public boolean dispatchTouchEvent(MotionEvent event) { boolean isAdministrator = _appData.User.isAdministrator(); return isAdministrator; } Feb 09 06:18:04 if the user is not an adminstrator, the screen should be disabled to touch Feb 09 06:18:05 ir7466, oh, brcaus you're not calling super Feb 09 06:18:14 oh, i SHOULD call it? Feb 09 06:18:44 you're not actually dispatching if you don't Feb 09 06:18:55 ah okay Feb 09 06:20:03 hmm, now it just works on both Feb 09 06:20:12 whether true or false is returned, the screen is totally enabled Feb 09 06:20:21 I added this as the first line: super.dispatchTouchEvent(event); Feb 09 06:20:25 don't call it when you don't want to dispatch Feb 09 06:20:33 duh Feb 09 06:20:50 don't call super? Feb 09 06:21:18 so it's calling super that dictates whether the event fires or not, not what is returned? Feb 09 06:21:35 I was following http://stackoverflow.com/a/28401496/2884981 Feb 09 06:21:45 How do you handle clicks on children within listviews? I'd like not to screw up the parent's click animations Feb 09 06:21:47 you're misunderstanding how the return value is used Feb 09 06:22:01 quit. reading stackoverflow and read the apidoc Feb 09 06:23:18 learning via stackoverflow sucks Feb 09 06:23:43 ActionBar.OnNavigationListener, obsoleted? What's the recommended way for doing actionbar spinners now? Feb 09 06:24:02 pfn: it works now, thank you Feb 09 06:34:08 I want my background row animation to fire when row's child views are clicked Feb 09 06:34:17 setting onClick listeners is breaking this Feb 09 06:36:02 <_genuser_> so is there a way to load a temporary view in a gridview while getItem() prepares a real view? Feb 09 06:41:51 Phlow, the recommendation is no spinners Feb 09 06:42:31 _genuser_, return a view that will load itself Feb 09 06:43:43 How can I keep a child onClick handler from preventing the parent's click animation? Feb 09 06:44:06 I want the parent to animate normally even though the child is handling the click Feb 09 06:57:12 does anyone know what the default android edittext drawable is? Feb 09 06:57:23 sorry, I meant to say autocompletetextview Feb 09 06:57:55 <_genuser_> pfn: sorry, I do'nt understand. Feb 09 07:02:53 child view focus prevents click animation in parent Feb 09 07:03:22 how do I keep my listviews click animations from getting screwed up by click handlers? Feb 09 07:03:49 disabling clickable prevents click hander from getting called. Not finding the right combination of focusability. Feb 09 07:04:02 https://github.com/chrisjenx/Calligraphy#configuration says "Define your default font using CalligraphyConfig, in your Application class." - should I have an Application class? Should I create it, and what should it extend? Feb 09 07:13:39 I'm following these instructions, and nothing is happening to my actionbar: https://developer.android.com/training/basics/actionbar/styling.html Feb 09 07:13:57 I set the background to just be a color, and I made the parent Theme.AppCompat... Feb 09 07:15:14 got my stuff working by setting background drawable Feb 09 07:16:18 so using a @color won't work? Feb 09 07:17:42 I just tried setting it to the google+ button and it still fails Feb 09 07:19:09 set style Feb 09 07:20:38 nvm ^ I just put it in every activity Feb 09 07:20:54 http://pastebin.com/PA38Zdcn This is the beginning of my styles.xml. My manifest has my application theme set to "AppTheme" Feb 09 07:34:10 hesperaux did you figure it out? your paste is gone Feb 09 07:34:36 drinfernoo, still can't figure it out - I am doing what the dev page says, but the actionbar does not change Feb 09 07:34:47 I'm extending ActionBarActivity and I'm using v21+ Feb 09 07:35:01 using ActionBar or Toolbar? Feb 09 07:35:23 what are you trying to do? Feb 09 07:35:28 I am not sure - I assume it's ActionBar because until about 2 minutes ago I didn't know what Toolbar was, and I'm extending ActionBarActivity Feb 09 07:35:37 I just want to change the background color of the actionbar for the moment Feb 09 07:36:10 wait a sec Feb 09 07:36:20 background="@color/yourColor"? Feb 09 07:36:21 http://pastebin.com/NEFr278S <--here is the start of my styles.xml. In my manifest I've declared AppTheme as the theme for the application. Feb 09 07:36:43 drinfernoo, correct. I've also tried @android:drawable/somerandomgoogle+icon Feb 09 07:37:20 no Feb 09 07:37:31 https://chris.banes.me/2014/10/17/appcompat-v21/ Feb 09 07:37:33 you Feb 09 07:37:40 you're doing it wrong Feb 09 07:37:59 gordon_, so far not helpful Feb 09 07:38:04 lol Feb 09 07:38:12 http://pastebin.com/ctSvdPSe Feb 09 07:38:24 all you need to do is set colorPrimary and colorSecondary Feb 09 07:38:27 and color will change Feb 09 07:38:48 only works with Toolbar, right? Feb 09 07:38:53 no Feb 09 07:38:57 oh Feb 09 07:39:02 interesting Feb 09 07:39:18 brb, trying Feb 09 07:39:20 well, it does only work if you don't want the actionbar to change colors at any point Feb 09 07:39:31 good luck Feb 09 07:39:33 I'm out Feb 09 07:39:41 when you need change style Feb 09 07:39:46 s/when/then Feb 09 07:40:37 hesperaux: if you have more questions highlight me Feb 09 07:40:45 gordon_, thanks, will do Feb 09 07:41:53 awe Feb 09 07:41:55 how goes Feb 09 07:42:10 nice. it worked. thanks gordon_ Feb 09 07:42:18 good Feb 09 07:42:21 hi good morning, can i use contact list image jpeg instead bitmap ? Feb 09 07:42:42 gordon_, do you know if this works the same on 4.2.1-5? Feb 09 07:42:55 it doesnt matter Feb 09 07:43:09 if you are using appcompatv7 - 21 it will work Feb 09 07:43:28 yay. Should I go back and use Toolbar, or keep using ActionBar? Feb 09 07:45:45 technically you are already using toolbar Feb 09 07:46:03 hey lemonxah Feb 09 07:46:06 I dont see any advantage of using toolbar in your layout for now Feb 09 07:46:14 maybe I'm wrong Feb 09 07:46:38 but still, if you will need to, you can always define new style for that one activity and put toolbar in layout Feb 09 07:46:58 I haven't done anything to spice up the actionbar yet. It's just the activity name with nav... Feb 09 07:48:56 I can set the action bar background color, but then if I also set the app background color the action bar becomes that color too? Feb 09 07:49:35 i am trying to subscribe to location updates but get an exception cuz the location provider is off but i also can't get the event onProviderEnabled... Feb 09 07:50:22 http://dpaste.com/35T3YAZ Feb 09 07:51:01 without the android:background line, the app is white and the actionbar is @color/action_bar. with the android:background line, both the app and the action bar are @color/background. I want action bar to be @color/action_bar and the app to be @color/background, obviously Feb 09 07:52:11 Is there a reason why a textPassword EditText has wider letter spacing than that of for instance textEmailAddress ? Feb 09 07:58:15 duncannz, I had a working action bar color, but when I set my theme's android:backround="@color/bleh" it made the activity and action bar backgrounds @color/bleh. Feb 09 07:58:59 hesperaux: that is the exact same problem I am having :/ Feb 09 07:59:00 any solution? Feb 09 07:59:15 I don't know - I just ran across it so I thought you would want to know Feb 09 07:59:36 I'm guessing that background overrides the background color of all views, including action bar Feb 09 08:01:45 can i use .jpeg instead bitmap on contact list ? Feb 09 08:02:46 duncannz: because it's not background property... Feb 09 08:03:25 gordon_: what property is it? Feb 09 08:03:58 http://pastebin.com/ctSvdPSe Feb 09 08:04:07 colorPrimary Feb 09 08:04:10 colorPrimaryDark Feb 09 08:04:32 gordon_, for me, colorPrimaryDark doesn't change the background color of activities Feb 09 08:04:54 for activity it's background I guess Feb 09 08:05:20 let me check Feb 09 08:05:27 ActionBarActivity for me technically. The issue I think is that he wants to set activity background, but it overrides the actionbar colorPrimary Feb 09 08:05:55 @color/base Feb 09 08:05:59 it's windowBackground Feb 09 08:06:07 ahah! that makes sense Feb 09 08:07:58 android:colorPrimary requires API level 21 Feb 09 08:08:06 oh yep android:windowBackground works, thanks :) Feb 09 08:08:31 duncannz, are you using appcompat? Feb 09 08:08:55 yes, hesperaux Feb 09 08:09:18 android:windowBackground is working and is not giving any compatibility warnings so I think that should be fine Feb 09 08:10:01 thank you again gordon_ :D Feb 09 08:10:17 now it's bed time for me Feb 09 08:27:57 Hi all, can any one help to find where(in which file) exactly in contacts app the blacklist is implemented ? Feb 09 08:31:36 What is the best way to get an app to display nicely on all devices? In Android Studio, the design fits but when I load it on my actual device, some things kind of "get squashed" for example I have a textView that overlaps a button etc Feb 09 08:32:07 need a screenshot Feb 09 08:32:42 Hi all, can any one help to find where(in which file) exactly in contacts app the blacklist is implemented ? Feb 09 08:33:16 If you use a relative layout, make sure not to specific widths of elements, but instead let them wrap around their content or fill the remaining space with layout weight and gravity. Feb 09 08:37:22 yeah I specified widths. can you specific percentages? Feb 09 08:37:32 like if i want an image to fill only 25% of the screen Feb 09 08:37:58 Utils, you design an app in a way that has stretchable content/empty areas Feb 09 08:38:10 doing stuff like "this HAS to be 25% of the screen" will cause you grief, pain and huge performance hits Feb 09 08:39:48 You usually want the UI to have for example a button, but fill the remaining space of that row with a text area. Or have an image, but fill the remaining space below that with text. Feb 09 08:40:25 In that case you specify wrap_content on the button, and a width of 0 with a weight of more than 0 on the text area. Feb 09 08:44:00 or match_parent with margins ;) Feb 09 08:46:00 http://i.imgur.com/0o8b1bT.png well at the moment I have this. Basically what happens is that the Register textView overlaps the button. It doesn't force itself under. The textViews and the button are wrap_content and I use margins and paddings. on the button. Should I be using a grid or something? Feb 09 08:46:57 It's all in a relativelayotu too. Feb 09 08:48:38 Utils: use the android:layout_below attribute Feb 09 08:49:35 On what? Feb 09 08:51:36 well what do you want below the login button in your screenshot? Feb 09 08:51:52 do you want the blue login button below the grey register button? Feb 09 08:53:23 The register button is red? :o Feb 09 08:54:41 If one had to go below the other, I would choose the login button to be below. Feb 09 08:55:09 Okay, so what is your Problem? The textview and the button overlaying each other? Feb 09 08:55:45 First, I'd set a leftOf="@id/whatever_I'd_your_button_has" on the textview. Feb 09 08:56:13 This means it stays left of the button, and becomes multiple lines if not enough space exists. Feb 09 08:56:56 Utils: do just add android:layout_below to your login button with the value of what is above it Feb 09 08:57:02 id value Feb 09 08:58:57 Ah! Is the layout_below/above used to determine how it's displayed on smaller views? Feb 09 08:59:21 Not really. Feb 09 09:00:02 It is used for where to align it. Feb 09 09:00:03 It tells the system "this layout will always be below this one", so you don't position with pixels. Feb 09 09:03:59 hi. i need some help for setting up jdk for android studio. android studio is unable to find a valid JVM after the recent update. Feb 09 09:06:21 I tried that Napalm but "Exception raised during rendering: Circular dependencies cannot exist in RelativeLayout" what exactly does this mean? Feb 09 09:06:38 it means what it says Feb 09 09:06:48 lol Feb 09 09:07:03 pastebin your xml layout so we can see it to help you Feb 09 09:07:43 http://pastebin.com/AXXwUbML here Feb 09 09:13:46 Napalm interesting that the ble callbacks occur on different binder threads Feb 09 09:14:23 there must be a pool of threads used for each call Feb 09 09:19:42 g00s: yes there is Feb 09 09:20:13 Utils: sorry you didnt mention my nick so I didnt get an alert Feb 09 09:22:01 Utils: have you ever used Styles? Feb 09 09:22:55 having problems with mavericks + jdk + android studio. Android studio cannot find valid jvm. java command not found. Feb 09 09:23:08 well I'm almost fully new to this. I have two styles although it's simply the style tags for themes that I use in the manifest, otherwise no I haven't used them. Feb 09 09:23:18 Napalm ^ Feb 09 09:24:15 jdk installation from oracle keeps failing! anyone can help? Feb 09 09:24:17 :/ Feb 09 09:24:38 Utils: just fixing up this layout for you Feb 09 09:24:55 Is it that bad, Napalm lmao. Feb 09 09:25:38 http://i.imgur.com/0o8b1bT.png Feb 09 09:25:45 thats the layout you want? Feb 09 09:25:49 whats the problem exactly here Feb 09 09:26:39 The main problem was that the register textView overlapped the button when on a smaller device. You suggested adding layout_below to the button in which I did and then I apparently ended up with a circular dependency issue Feb 09 09:27:12 ok, one moment Feb 09 09:31:34 i have deleted Current under /System/Library/Frameworks/JavaVM.framework/Versions/ in mavericks. Can i restore this? Feb 09 09:31:57 oops Feb 09 09:34:07 tty all you can try is reinstalling the apple and/or oracle jvms Feb 09 09:34:26 dont eff around with that unless you really know what you're doing :) Feb 09 09:35:01 you could screw things up you need to reinstall the OS, or at least the latest service bundle Feb 09 09:36:20 g00s: do you think this will help? http://support.apple.com/kb/DL1572 Feb 09 09:36:57 Post Date: May 29, 2014 Feb 09 09:37:13 hm, dunno i would think you want one for 10.10 Feb 09 09:37:21 i'm still using 10.7 ;) Feb 09 09:37:26 10.9 here Feb 09 09:37:45 ah ok, yeah apple does a crappy job of listing those things Feb 09 09:38:09 g00s: I'm using 10.10 Feb 09 09:38:13 it's mmmkay Feb 09 09:38:17 not good, not bad Feb 09 09:38:28 g00s: ok. installed. java now is a valid command. Feb 09 09:39:13 thepoosh yeah, i dont know if it will work well on my 2009 MBP Feb 09 09:39:19 4G memory Feb 09 09:39:31 g00s: he. 2008 MBP here :P Feb 09 09:39:43 10.9 is doing good. Feb 09 09:39:51 the newer ones come standard with 16G Feb 09 09:40:10 tty maybe i will go with 10.9 then Feb 09 09:40:38 thepoosh are you sprinting now ?! Feb 09 09:45:13 g00s: always! Feb 09 09:45:30 oh, I have a MBP 2012 Feb 09 09:45:33 i think Feb 09 09:45:36 even 2013 Feb 09 09:45:41 i have the retina display Feb 09 09:45:44 whatever that is Feb 09 09:45:55 nice Feb 09 09:46:11 anyone ever tried http://www.rushorm.com/ ? any feedbacks ? Feb 09 09:46:33 g00s: I told them I'll do with a Linux machine Feb 09 09:46:53 but the CPO changed to the MBP 2014 (and then to the 2015) Feb 09 09:46:56 so I got his Feb 09 09:47:16 lol, devs should get first dibs Feb 09 09:47:29 what the hell does the CPO need the latest MBP for ? Feb 09 09:48:31 well, i guess its Certificed Pre Owned :D Feb 09 09:48:59 Morning all Feb 09 09:49:02 what type of exception is a "CalledFromWrongThreadException" -exception? Feb 09 09:49:38 Troffel did you try googling it ? Feb 09 09:49:49 yap, might google fuu is shit apparently Feb 09 09:50:45 how about Sewer Overflow? Feb 09 09:50:57 WrongThreadException Feb 09 09:51:29 had to look at a bit of an obscure place, since all stackoverflows provide the "runonuithread" solution Feb 09 09:58:54 O.o Feb 09 09:59:03 what exactly are you doing you're getting that exception? Feb 09 10:00:03 blusky, yet another orm lib? ^^ Feb 09 10:04:00 I feel like im using way to many layouts since Material Design Feb 09 10:04:28 such a waste to have to wrap Relative Layouts in a CardView just to get the look Feb 09 10:05:25 Hmm? Feb 09 10:05:38 g00s, worked with retrofit a lot? Feb 09 10:05:48 lemonxah not at all Feb 09 10:05:51 oh ok Feb 09 10:05:52 You should only wrap stuff in a cardview anyway if the user can swipe it away and it actually makes sense. Feb 09 10:05:53 nvm thne Feb 09 10:06:02 then even Feb 09 10:06:09 Mavrik, great question. it's a simple function that sets visibility of a textview on adverts, implemented inside a viewpager adapter. It's called everytime a swipe occours, but from a 100k installed devices we get 300 reports of a wrongthreadexception. Feb 09 10:06:10 lemonxah how are your kotlin adventures going ? you have to keep us posted :D Feb 09 10:06:26 i will :) its still early days Feb 09 10:06:41 haven't had much time this weekend though Feb 09 10:07:02 lemonxah do you know what parts of the app will get kotlin love yet ? Feb 09 10:07:20 i'm assuming this is mixit right ? Feb 09 10:07:23 my app .. all of it :) but i am starting with my mqtt service Feb 09 10:07:32 oh yeah, that :D Feb 09 10:07:34 no its not mxit its a loadshedding app Feb 09 10:08:24 the power provider in south africa has grossly misused its funds and never done any maintanance Feb 09 10:08:34 so now the entire country has loadshedding Feb 09 10:09:01 once a day at a determined time (or out of the blue) they shut off all power to designated areas for 2 to 4 hours at a time Feb 09 10:09:02 lol Feb 09 10:10:58 i know right .. Feb 09 10:11:13 lemonxah government corruption ? Feb 09 10:11:33 yes our government is sooooo corrupted its not even funny Feb 09 10:12:32 our president did "security" upgrades to his home worth $25M wich included a personal cinema and a jacuzi and ... Feb 09 10:12:45 anyway Feb 09 10:12:49 always feel safer behaind a big screen Feb 09 10:13:14 does anyone know of a way using gson to decode 1 field that is in base64 or do i have to decode after getting it Feb 09 10:13:24 i am hoping gson will just do it :) Feb 09 10:20:27 hi all, is there any one who is aware of contacts app? Feb 09 10:21:46 ythej: ? Feb 09 10:22:05 yeah a friend of mine was telling me that he was going to ship his brother from SA to Ireland because it was just impossible to get work done down there Feb 09 10:22:18 thepoosh, hi :) Feb 09 10:22:21 hi Feb 09 10:22:51 http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android-apps/4.1.2_r1/com/android/contacts/ Feb 09 10:24:03 bah Feb 09 10:24:12 does anyone know out of his head... in NDK Feb 09 10:24:19 is the bitmap buffer size width*height or stride*height? Feb 09 10:25:26 thepoosh, help to find where(in which file) exactly in contacts app the blacklist is implemented ? Feb 09 10:25:33 no Feb 09 10:28:24 hi, I'm wondering, what is the best way to generate and store RSA keys on Android 4.0 and 4.3? Feb 09 10:28:59 http://stackoverflow.com/a/9965964/1056359 Feb 09 10:31:35 lemonxah, kotlin now eh? Feb 09 10:32:26 and scala Feb 09 10:32:30 comparing Feb 09 10:33:37 i like scala but i dont like the copmlex interface inheritance causeing the app to not run on 2.3 devices Feb 09 10:33:39 Dexopt fails with "LinearAlloc exceeded" for deep interface hierarchies Feb 09 10:34:17 on newer phones that isn't an issue but seing as we are still supporting 2.1 2.2 and 2.3 its causing issues Feb 09 10:34:26 thepoosh, I searched a lot in that repo a lot before too.But couldn't figure out. Can you please tell the exact file ? Feb 09 10:34:27 bummer Feb 09 10:34:29 for now i got around it by narrowing the proguard rules Feb 09 10:34:42 try 2.11.5? Feb 09 10:34:49 ythej: no, I haven't read the code, you need to read it yourself Feb 09 10:35:02 thepoosh: so from what i understand it's best to use spongycastle for key generation and general crypto operations, but how to store private keys in a secure manner? Feb 09 10:35:04 not yet was on 2.11.2 i was having that issue Feb 09 10:35:11 will try 2.11.5 in a bit Feb 09 10:35:26 that is the highest voted answer Feb 09 10:35:26 thepoosh, okay, thanks :) Feb 09 10:35:39 2.11.5 made some changes that may or may not improve it Feb 09 10:36:21 will check it out Feb 09 10:36:38 doing scala for work related stuff and learning kotlin just to know it Feb 09 10:37:08 there is allready one thing kotlin doesn't do as well as scala that is getting to me and that is the pattern matching Feb 09 10:37:31 i mean its there just not as pretty and you have to do extra things to bind to data values Feb 09 10:37:33 meh Feb 09 10:52:05 but i am only a noob Feb 09 11:05:03 anyone familiar with android bluetooth le scanning? Feb 09 11:05:34 i have the standard device advertising every second, but on one phonem it scans then stop receiving the advertising Feb 09 11:05:53 it is just that one phone - i tried also other apps with the same result Feb 09 11:06:11 i think it is actively scanning or trying to connect to device Feb 09 11:06:20 switching scanning on/off mitigates the problem Feb 09 11:06:29 but maybe there is some system-wide bluetooth le setting Feb 09 11:10:21 I've made an Android Library project in Eclipse (MyLib). I've also made an Android Application Project (MyApp). MyApp refers to MyLib. Both projects have resources, and both have an background color in values/color.xml, and both have a set of app_icons under drawable-*. Feb 09 11:10:24 ... Feb 09 11:10:54 do they have the same namespace? Feb 09 11:11:02 Both also have auto-generated R.javas where MyApp appears to overwrite MyLib's background color. But they have different namespaces =) Feb 09 11:11:14 However, how does this lookup work? Feb 09 11:13:16 It seems that java code in MyLib looks up resources from its own library. And MyApp prefers to load its own resources, but fallbacks to MyLibs. But how does this work? My mean, R.color.background is simply and int. This int is the same in MyLib and MyApp. How does Android know which file to load based on the same int? Feb 09 11:14:30 Everything appears to work as expected. I would just like to know why it works -- the inner working of Android's resource lookup. Feb 09 11:17:46 it will first lookup for its own resources Feb 09 11:18:55 then in librarie's Feb 09 11:19:26 also it will first look for values in phone's Locale, i.e. values-de, then fallback to values Feb 09 11:22:29 I've got a pretty good feeling how that works: http://developer.android.com/guide/topics/resources/providing-resources.html#BestMatch Feb 09 11:23:37 But I'm still puzzled how (e.g.) id 0x123456789 translates to either an image in MyLib or MyApp. Feb 09 11:30:19 It's all merged into a single res folder Feb 09 11:31:45 mylib.R.drawable.image and myapp.R.drawable.image has the same int value, which corresponds to an image in the final (and only) res folder Feb 09 11:32:42 You can also "override" a library resource by providing one with the same name Feb 09 11:56:02 btw. if someone other encounters this bluetooth le problem - some devices like nexus 4 and nexus 7 show one advertising per scan :f and override is to keep restarting startLeScan/stopLeScan :F Feb 09 12:11:09 SimonVT: but different images are looked up depending on the lookup is done by code in MyLib or MyApp. Feb 09 12:26:47 HI all can i get root from adb ? Feb 09 12:27:21 or be able to write to "/system/etc/permissions/platform.xml Feb 09 12:27:28 in any form Feb 09 12:27:41 Not on production builds. Feb 09 12:27:59 i can pull it to my linux and modify it but not push it back Feb 09 12:28:06 On debug builds you can use adb root, adb remount to get access. Feb 09 12:28:44 ok Feb 09 12:29:13 the NO write permission to externel Sdcard from 4.4x is a miss Feb 09 12:29:31 It exists for a good reason. Feb 09 12:30:00 And I'd have preferred if Google never introduced write permissions directly, but instead providers for media types. Feb 09 12:30:02 i know but on ASTR images at 35MB per image its not good on a 4GB system Feb 09 12:30:17 You can put them on the sdcard. Feb 09 12:30:32 In your apps folder on the sdcard. Feb 09 12:30:51 Android/data/com.example.app/ Feb 09 12:31:52 You have access to that folder, but warning, no other app has. Feb 09 12:32:39 im using dslrdashboard app Feb 09 12:34:47 Oh, hmm. Feb 09 12:35:18 Camera apps can just use the system provider to put photos into DCIM on the SD Feb 09 12:36:26 ok i see then i only can make 2 images in a row and push it to the external via ESfileexplorer Feb 09 12:38:49 justJanne: there are oneClick root apps out that gives root for only to next restart are they able to root Feb 09 12:51:26 Hello friends... Feb 09 12:53:11 Please my content provider is not refreshing after delete... Feb 09 12:59:24 every once and a while, when I come back to using Android studio, I won't get any updated log cat data. I usually just restart Android Studio, but is there a quicker way to do it? Feb 09 13:00:56 You can press the "restart logcat" button Feb 09 13:01:47 Hey, I'm trying to add Google Analytics to my app, the following line of code never returns a value for some reason, GoogleAnalytics analytics = GoogleAnalytics.getInstance(this); have you encountered that? Feb 09 13:03:02 Thanks justJanne Feb 09 13:03:04 The device have play services installed and isGooglePlayServicesAvailable () returns SUCCESS Feb 09 13:11:21 I want to add search button similar to youtube app at top in the navigation bar/action bar. Feb 09 13:12:05 Anyone have any idea how to do this? Feb 09 13:12:07 Look into the search mode of the new toolbar. Feb 09 13:13:43 justJanne: thx look in to that Feb 09 13:13:49 Zta: It'll be the same image if they are looking up the same resource name Feb 09 13:17:37 How do i refresh UI when i delete an item from the list.. using content provider! Feb 09 13:18:33 i've use getContentResolver().notifyChange(uri, null, null) Feb 09 13:19:28 .* Feb 09 13:19:37 i am reading characterstics values from BLE device but it thorugh error ?? Feb 09 13:19:38 .* Feb 09 13:19:38 mBluetoothGatt.readCharacteristic(lv_characterstics); Feb 09 13:19:39 .* Feb 09 13:19:52 any idea Feb 09 13:20:53 it complies but runtime through error Feb 09 13:23:27 any one worked on BLE example Feb 09 13:24:01 gaganchd2000: Ask your question and wait for an answer. If noone answers within 20-30 minutes, try again. Feb 09 13:24:33 gaganchd2000: maybe pastebin some logcat Feb 09 13:24:38 or code snippset Feb 09 13:26:43 BluetoothGattDescriptor descriptor = characteristic.getDescriptor( Feb 09 13:26:43 UUID.fromString(SampleGattAttributes.RFDUINO_CHARACTERISTIC)); Feb 09 13:26:44 descriptor.setValue(BluetoothGattDescriptor.ENABLE_NOTIFICATION_VALUE); Feb 09 13:26:44 mBluetoothGatt.writeDescriptor(descriptor); Feb 09 13:27:01 sorry Feb 09 13:27:27 mhm Feb 09 13:27:57 Anyone an idea how to write tests for a fragment that uses Otto ( event bus square )? Feb 09 13:29:24 http://pastebin.com/exNdLhis Feb 09 13:29:58 i got error on mBluetoothGatt.readCharacteristic(lv_characterstics); Feb 09 13:32:39 justJanne: is it this you mean ? http://www.coderzheaven.com/2012/10/20/actionbar-search-option-options-android/ it is not working =( i get null pointer from getActionView() Feb 09 13:33:00 Nope, that is far too old. Feb 09 13:33:12 There is a new tutorial, with all the new nice material stuff. Feb 09 13:33:21 Please, check this... http://pastebin.com/vWCp0F7m Feb 09 13:33:46 View not refresh after deleting Feb 09 13:36:36 gaganchd2000: and what's the error exactly Feb 09 13:39:20 hackable: You should show where you register a contentobserver, etc, as well.. Where you actually update the view Feb 09 13:40:55 public boolean deleteSafeContact(long mContactId){ Feb 09 13:40:55 Uri deleteUri = Constants.Entry.CONTENT_URI.buildUpon() Feb 09 13:40:55 .appendPath(Long.toString(mContactId)).build(); Feb 09 13:40:55 boolean check = false; Feb 09 13:40:55 int deleteRow = _context.getContentResolver().delete(deleteUri, null, null); //Long.toString(mContactId) Feb 09 13:40:55 if(deleteRow != 0){ Feb 09 13:40:56 check = true; Feb 09 13:40:56 _context.getContentResolver().notifyChange(deleteUri, null); Feb 09 13:40:57 } Feb 09 13:40:57 return check; Feb 09 13:41:04 .. Feb 09 13:41:13 SimonVT: please check Feb 09 13:41:25 Pastebin, always pastebin Feb 09 13:41:34 Alright, next time Feb 09 13:41:36 Where are you updating your View? Feb 09 13:42:02 I'm talking about deleting a view list Feb 09 13:42:09 http://pastebin.com/vWCp0F7m Feb 09 13:42:22 that's where i've my content provider Feb 09 13:42:48 Somewhere you query the ContentProvider.. And in the place, you have code that's supposed to update the View once a change happens Feb 09 13:42:55 Show that code Feb 09 13:43:17 is there a way to put margin and border around the scrollable area contained within a listview/recyclerview? Feb 09 13:43:45 Padding? Feb 09 13:44:34 SimonVT: i've this --> getContext().getContentResolver().notifyChange(Constants.Entry.CONTENT_URI, null); Feb 09 13:45:08 hackable: Where do you query your ContentProvider? Feb 09 13:45:21 SimonVT: nope, that moves the scrollbar in, and also the border on the view doesn't encompass the scrolling area, just the main view borders Feb 09 13:45:50 SimonVT: please scroll up Feb 09 13:46:07 ashiren it goes to exception handleing Feb 09 13:46:09 hoping for something like a scrollableArea set of properties that I'm just missing, but I kinda figure if I haven't found it yet it doesn't exist Feb 09 13:46:27 shekibobo: scrollbarStyle="outsideOverlay" should fix that Feb 09 13:47:00 hackable: You've only shown your ContentProvider.. I'm asking for the code where you query your ContentProvider, get a Cursor, and use that Cursor for something Feb 09 13:54:18 justJanne: i just be searching for wrong words =( i can find anything Feb 09 13:55:58 SimonVT: hold on.. i'll upload it now Feb 09 13:58:05 Attempt to invoke virtual method 'boolean android.bluetooth.BluetoothGatt.readCharacteristic(android.bluetooth.BluetoothGattCharacteristic)' on a null object reference Feb 09 13:58:31 SimonVT: here is ->> http://pastebin.com/WEhDcyd5 Feb 09 13:59:54 SimonVT: outsideOverlay solves part of it. Is there a way to apply a background that only surrounds the area inside the padding? Feb 09 14:00:15 SimonVT: hope you understand my code Feb 09 14:03:44 http://pastebin.com/QFj98jU9 Feb 09 14:03:48 this is logcat Feb 09 14:03:50 for error Feb 09 14:08:09 hackable: I'm asking for the code where you query your ContentProvider, get a Cursor, and use that Cursor for something Feb 09 14:46:37 Is there any way to add (layout xml) attributes to existing controls without subclassing them? Feb 09 14:52:05 Hi, does anyone know how to set up a type adapter for RetroFit to parse a string as JSON Feb 09 15:47:24 heya folks. i'm currently reading up on android activities and context but am finding myself puzzled by a problem i'm encountering. I'm trying to launch an activity with startActivityForResult() from a regular activity (whose parent is an Activity Group) and listen for it's result in onActivityResult(). However, it seems onActivityResult is never firing. any thoughts? Feb 09 15:50:07 also, i'm aware that ActivityGroup is depricated, but I don't feel comfortable changing out that class as it plays a central role in the application's architecture (this is an inherited application), i'm an android noob, and my deadline is the end of the week to resolve this and other issues. Feb 09 15:51:15 pablq, you are calling setResult ? Feb 09 15:51:57 where would that be called? in the activity that is being launched (whose result is expected?) Feb 09 15:52:05 or in the parent activity Feb 09 15:52:18 pablq, the former Feb 09 15:53:14 hmmm. the activities (intent) being launched is MediaStore.ACTION_IMAGE_CAPTURE Feb 09 15:53:40 or a pick image intent Feb 09 15:54:44 pablq, are they designed to be called ...WithResult? Feb 09 15:55:39 previously these were launched from the activities parent activity group (via getParent().startActivityForResult() )... and onActivityResult did work as expected in the parent activity, but i thought it'd be cleaner to do it right from the activity that really cares about the result instead of delegating to its parent. Feb 09 15:55:43 timemage: i think so Feb 09 15:57:04 http://developer.android.com/training/camera/photobasics.html yes they (or at least take picture) is meant to be called in this way Feb 09 15:57:35 pablq, i expect the result is routed to whatever issued the start. are you trying to decouple these or what? Feb 09 15:57:57 hmm, not sure what decouple means. Feb 09 15:58:43 which version of Android was the runtime annotations bug fixed? Feb 09 15:58:45 pablq, what i'm saying is, if you called getParent().startActivityForResult() i expect the result to be issued to getParent().onActivityResult() Feb 09 15:59:15 pablq, and not to the onActivityResult of the class where you made the call to startActivityForResult(). Feb 09 15:59:30 timemage: right. what i'm trying to do is just call startActivityForResult() instead of getParent().startActivityForResult() Feb 09 16:00:14 pablq, okay. the why aren't you using your own startActivityForReult innstead of the parents? Feb 09 16:01:07 it previously was getParent().startActivityForResult() but i am trying to refactor to avoid handling the response in the parent as the parent really doesn't need to know anything about it. it makes more sense to just to startActivityForResult... the reason it was getParent().startActivityForResult() is unknown to me. i'm refactoring inherited code. Feb 09 16:04:32 ok so did the s4 mini get an upgade from 4.2 to 4.3? one of the devs was asked to bring a phone in for me to do BLE dev with but it has android 4.2 so no ble. Feb 09 16:04:50 i see some talk about some carriers upgrading the phone to 4.3 but i dont know of this happened yet or not Feb 09 16:05:25 timemage: to be clear... previously myActivity launched an activity through it's parent parentActivity() using getParent().startActivityForResult(). in the parent, the response was handled with onActivityResult(). in an attempt to simplify and clarify code i have made it so that myActivity directly launches the activity by called startActivityForResult(). I have added the onActivityResult() method to myActivity, but it is not firi Feb 09 16:05:48 arg parentActivity should not have parens Feb 09 16:06:15 pablq, it doesn't really clarify for me. it may for someone else. Feb 09 16:06:22 k Feb 09 16:08:35 Hi, I have a specific need with gradle: I have an Exec task, and I'd like tu set a custom arg to commandLine according to the flavor executed Feb 09 16:08:55 I don't know how to get mergedFlavor at build time Feb 09 16:09:15 (in doFist{} of my task) Feb 09 16:10:19 having a parallax layout over an image is cool, but would it still make sense to have a parallax layout over a map? Feb 09 16:11:47 pablq, you may find it worth looking at the source to startActivityForResult in android/app/Activity.java Feb 09 16:12:55 thanks timemage. i'm currently searching stackoverflow and android docs. Feb 09 16:41:12 think google went out of stock on the nexus 5 to try get people to purchace the stupidly expensive nexus 6? Feb 09 16:44:34 When I have a customer class say UserModel that stores the details of my user, how would it be best to store it and then be able to read in future? Feb 09 16:50:46 dvass: sqlite? Feb 09 16:52:26 JoePosillico: Is that the fastest way of doing it? Feb 09 16:52:48 and is it secur? Feb 09 16:56:11 I440r: Probably went out of stock because nexus 5 isn't thier step forward for hardware so they have reduced production Feb 09 16:56:44 yiati, and their nexus 6 is over priced Feb 09 16:56:55 I400r: yes Feb 09 16:57:07 by about 100% :P Feb 09 16:58:40 dvass: What user data are you trying to store. Storing stuff on a back end works nicely because then you can resync the user if they switch devices Feb 09 16:59:08 dvass: Cached data is the only kind of stuff you really want to save per device, to help performance Feb 09 17:11:37 Yiati, I'm planning on storing the access token to retrieve their details in future sessions so they don't have to keep reauthenticating and alongside it some other info like name and email so it doesn't have to keep making that request Feb 09 17:13:24 yo JoePosillico what up buttercup? Feb 09 17:14:28 dvass, faster and secure don't necessarily go together... Feb 09 17:15:24 well some compromise is always necessary I suppose but a balance between the two is what im looking for Feb 09 17:15:37 Leaning more on security Feb 09 17:16:32 saving to sql, preferences or file in user space is pretty much equally secure. Unless you are on a rooted device, then all security goes out the window Feb 09 17:16:47 you can save on SD , that's not secure Feb 09 17:17:20 saving to cloud can be practical depending on your use case, but it's the least trivial Feb 09 17:28:01 Hi, for some reason on Android 5 all my buttons have text with all capital letters, is that normal? Feb 09 17:34:17 viran, yeah thats the new button style in 5 Feb 09 17:34:30 viran, there is probably a way to change it Feb 09 17:34:42 fixed it with false Feb 09 17:35:34 viran: http://www.google.com/design/spec/components/buttons.html#buttons-flat-raised-buttons Feb 09 17:35:40 part of material design spec Feb 09 17:55:14 :/ I haven't figured out why the buttons *raise* on tap. doesn't that seem backwards? Feb 09 17:56:03 magnets Feb 09 17:56:44 nah, static cling Feb 09 17:57:23 are you wearing socks on the carpet? Feb 09 17:57:27 Android Studio is such a pain when it comes to renaming/moving packages. "Are you sure you want to do this?" "Are you *really* sure?" "Okay, here's a preview. If you're sure, click the Refactor button." Feb 09 17:57:49 enter CAPTCHA Feb 09 17:58:02 Together with progress dialogs showing. Feb 09 17:58:11 TacticalJoke: Agreed, it’s always felt like a lot of friction compared to Eclipse Feb 09 17:58:12 MikeWallaceDev: Oh, that would be the icing on the cake. Feb 09 17:58:35 CAPTCHA == The cake is a lie. Feb 09 17:58:49 But the icing is real!! :D Feb 09 17:58:50 I also hate AS's progress dialogs in general. Some can't be disabled. It's like "Stop typing! I'm busy doing stuff. You can't type while I'm doing stuff!" Feb 09 17:59:09 what bothers me is the "directory name" "package name" thing... Feb 09 17:59:23 aren't they supposed to always be the same? Feb 09 18:08:13 Hi all, I am using fragments and using FragmentTransaction.addToBackStack, so far so good it seems to be working as expected. However i am also using navigation drawer. When using the backbutton how do i Manage the actionbar to Restore also? Feb 09 18:10:46 MikeWallaceDev: are they not the same? there are top level "main" / "test" folders, but my code folders are all com/etc/roflcopter/LolManagerFactoryBean.java Feb 09 18:11:48 groxx, that's what I'm asking, really... I don't understand that option. Like at all. Feb 09 18:12:03 I keep refactoring until it does what I want! Feb 09 18:12:13 It's terrible Feb 09 18:13:07 which option? Feb 09 18:13:41 I suspect the difference is because packages aren't hierarchical, while directories are Feb 09 18:13:44 when you try to refactor a package. It presents you with a dlg with two radio buttons. I don't understand them Feb 09 18:13:56 e.g. com.blah has no relationship to com.blah.blah Feb 09 18:14:05 JesusFreke, I thought packages == dir names Feb 09 18:14:12 or is that only convention? Feb 09 18:14:21 JesusFreke: yeah, though editors always present them that way too Feb 09 18:14:43 MikeWallaceDev: right, com.blah would be in com/blah, com.blah.blah would be in com/blah/blah Feb 09 18:14:49 MikeWallaceDev: convention, but you can change it with a fair amount of additional configuration Feb 09 18:14:54 exactly! Feb 09 18:14:55 if you rename the directory blah, it would rename both packages Feb 09 18:15:04 SEE!? Feb 09 18:15:05 if you renamed the package, it would only rename com.blah Feb 09 18:15:10 So why the radio button? Feb 09 18:15:12 because com.blah has no relationship to com.blah.blah Feb 09 18:15:22 oh, wait, let me reread that Feb 09 18:15:37 yeah, me too... Feb 09 18:15:56 You lost me there JesusFreke : if you renamed the package, it would only rename com.blah Feb 09 18:16:00 Has anyone seen this error "Failure [INSTALL_FAILED_DEXOPT]" and have any idea how to fix it? Most of the stuff on SO said to uninstall which didn't work for me. Feb 09 18:16:10 what would it do to the dirs? Feb 09 18:16:15 does it not rename the dir to match? I think I've done that, and it changed the folder... might be misremembering though Feb 09 18:16:37 I think that's what the choice is groxx Feb 09 18:16:58 but it makes no sense to me... Feb 09 18:17:09 pieces029: surprising. is this your app, or some random one? and what os version are you running? Feb 09 18:17:17 Hmm. Do I have to change .idea/.name to rename a project? Refactor > Rename doesn't seem to be sufficient. Feb 09 18:17:29 (In the Project view.) Feb 09 18:18:01 I wrote a blog post on that TacticalJoke , gimme a sec Feb 09 18:18:06 TacticalJoke: I toss all idea files, and reimport from gradle. waaay easier, and easy to handle with a team. Feb 09 18:18:46 can't believe it's not the officially-suggested .gitignore, tbh. it's great. Feb 09 18:18:55 TacticalJoke, this might help : http://androiddevcorner.blogspot.ca/2014/02/copying-template-project.html Feb 09 18:19:09 groxx: My app, trying to run tests. I'm on linux Feb 09 18:19:10 basically, I had to copy a project over and over and rename it Feb 09 18:19:29 pieces029: ah, sorry. phone os. Feb 09 18:19:52 Ah, okay. Yeah, I might just throw all the files away and import. Feb 09 18:19:55 oh lol, 4.4.4 Feb 09 18:21:23 pieces029: Hm. I would guess it could be invalid java compiled code, buy that seems unlikely for 4.4. Feb 09 18:21:39 pieces029: so I'm guessing it's a cache somewhere. have you uninstalled and then installed, or just reinstalled over the top? Feb 09 18:21:59 TacticalJoke: did you come up with a new name for you app ? Feb 09 18:22:37 groxx: Yeah I have. That's what AS is trying to do after it fails. Feb 09 18:22:56 pieces029: reboot the phone? :/ Feb 09 18:23:17 Yeah, shmooz. Feb 09 18:23:34 pieces029: not that that's a great option, but it does sometimes fix install problems. Feb 09 18:23:37 I can try, I think it's an issues with libraries colliding. I just delt with this the other day, and I don't remember what I did :( Feb 09 18:23:40 don't worry, not gonna ask what it is ;) Feb 09 18:23:48 I already PMed you. lol Feb 09 18:23:54 oh Feb 09 18:24:05 pieces029: ah. could be. do you get any logcat output? it might mention class names Feb 09 18:24:19 groxx: Did you create a new project and them import from Gradle? Feb 09 18:24:28 TacticalJoke: that's what I do, yeah Feb 09 18:24:54 delete all .idea and .iml and .etc, reimport "non-android studio project" Feb 09 18:25:13 copy it somewhere else so you don't destroy a working version though :) Feb 09 18:25:42 Okay, thanks. Feb 09 18:25:47 This is way unnecessarily complicated. ;o Feb 09 18:25:50 Much easier on Eclipse. Feb 09 18:26:11 I configure everything through gradle though, so it works reliably for me. it seems like it should work with most projects, but I won't claim belong that Feb 09 18:27:29 I dunno about eclipse being easier... project names != display names in eclipse, but if the project names collide it won't work and can screw up caches... Feb 09 18:28:08 I remember it being really easy to rename projects in Eclipse. (Though not having Gradle wasn't so nice.) Feb 09 18:28:13 I ended up adding some eclipse files to .git/info/exclude just to get it to stop reordering xml and renaming things randomly Feb 09 18:28:31 groxx: oh good call I'll check there. It fails with Unknown failure, which is you know, awesome haha Feb 09 18:29:07 pieces029: well there's your problem! helpful logcat is helpful. Feb 09 18:29:39 pieces029: nothing above it? no dex warning or dead code removal or anything? Feb 09 18:30:15 nope. I got logcat running now so I'll look there there and see if there is anything. Feb 09 18:32:02 pieces029: make sure there isn't a your-package filter on the output Feb 09 18:32:23 pieces029: otherwise, googling suggests clean and rebuild. try that? Feb 09 18:32:34 hey there Feb 09 18:32:53 pieces029: I assume you're using android studio? Feb 09 18:33:38 pieces029: Hm: http://stackoverflow.com/questions/26568621/failure-to-install-apk-install-failed-dexopt-android-studio Feb 09 18:34:29 pieces029: and you're not running out of the 65k limit on methods, are you? Feb 09 18:35:01 I am but I fixed that with progaurd Feb 09 18:35:04 guard* Feb 09 18:35:51 Also I've tried cleaning and building no luck. Feb 09 18:42:47 groxx: I did that but now all my build.gradles are showing warnings. Feb 09 18:43:37 TacticalJoke: error messages or it didn't happen :p Feb 09 18:44:49 pieces029: aaah. proguard adds a few wrinkles... I'll be happy to guess, but there's a lot there I don't yet understand. Feb 09 18:45:14 In app's build.gradle, for example, the whole 'dependencies' block is highlighted and the warning is 'dependencies' cannot be applied to '(groovy.lang.Closure)'. Feb 09 18:45:28 I have the file setup correctly afaik Feb 09 18:46:00 The thing about AS is that where it is worse than Eclipse it is just awful. Feb 09 18:46:01 pieces029: what has changed since the last working version? Feb 09 18:46:14 It's either great or terrible. Feb 09 18:46:29 TacticalJoke: yeah, and gradle has an awfully steep learning curve :( Feb 09 18:46:55 It's weird. I should be able to just import a Gradle project. Feb 09 18:47:01 TacticalJoke: you have an "apply plugin: " line above that dependencies block? Feb 09 18:47:05 I mean, it works, but there are like 52 warnings. Feb 09 18:47:09 Yeah. Feb 09 18:47:17 groxx: Lots of stuff :) I am using a smaller project to test things and move them into the larger project. So that's why I'm pretty confident my proguard file works. Feb 09 18:47:17 All the files are identical to before. Feb 09 18:48:10 groxx: Found it. totally a lib version issue, with a file not being loaded to the classpath... Feb 09 18:48:12 TacticalJoke: yeah, I'm just wondering if something was configured in intellij, but not gradle Feb 09 18:48:14 This makes me think I should check in my IML files. Feb 09 18:48:43 pieces029: cool, glad something works :) Feb 09 18:48:59 TacticalJoke: make sure you're not in offline mode Feb 09 18:49:10 TacticalJoke: bleh. hit send too soon Feb 09 18:49:35 Okay, not offline. Feb 09 18:49:42 But "Gradle home" is blank in project settings. Feb 09 18:49:56 TacticalJoke: ... mode? seems possible that the gradle cache isn't being used, so it needs to download stuff again Feb 09 18:50:01 groxx: lol, proguard and merging file and all that shit is a huge pain in the ass... Feb 09 18:50:14 pieces029: yeah, and annoyingly magical :( Feb 09 18:50:37 Okay, setting "Gradle home" fixed it. Feb 09 18:51:02 I hate complexity. Ugh. Feb 09 18:51:19 TacticalJoke: huh. don't think I've had to tweak that. will have to look at it again. Feb 09 18:51:31 Yeah, not sure why. Feb 09 18:51:42 yeah. and i hate not understanding how the build process works. Feb 09 18:51:51 making progress, but it's kinda slow :) Feb 09 18:52:24 A new project sets "Gradle home" correctly, so an imported one should. Feb 09 18:52:39 Yeah, not understanding stuff can cause a lot of anxiety. Feb 09 18:55:24 I might just stick with my old project. Lol. Not sure whether I trust this Gradle-project-importer thing. Feb 09 18:56:01 Actually, I'll do a directory diff on the old and the new. Feb 09 19:00:45 Okay, a lot of differences. I'll stick with the old one. Feb 09 19:01:00 I kinda feel like we should probably be checking in IML files (which I'm not doing). Feb 09 19:02:48 * gdrc switches from ffmpeg to javacv o_O Feb 09 19:04:12 im at a total loss as to what to do now. boss had someone bring in a phone for me to do my devel with and it was totally unsuitable to the task. i emailed him about it and i guess he told the original dev who has a ble ready phone to give it to me again. I had it for all of 30 seconds before it rang and he took it back... that was half an hour ago. wtf am i supposed to do here! Feb 09 19:04:14 dafq Feb 09 19:05:11 "i told you to develop a BLE app and all you have done is complain about the complete and utterl lack of development tools! what good are you!!!" <--- i can see it coming Feb 09 19:06:58 I440r quit Feb 09 19:07:41 g00s ive been out of work for a year and a half and this guy hired me. ok so it looks like he is setting me up to fail and is basicaly paying me a pitance but... quit and do what? Feb 09 19:08:08 actually its more accurate to say ive been out of work for 4 yeras other than one short term contract a year and a half ago Feb 09 19:08:17 you are telling me , he couldn't order a moto G 2? Feb 09 19:08:39 he has avoided the issue of spending money Feb 09 19:08:41 off contract thats at most $175 Feb 09 19:08:49 yeah, quit Feb 09 19:09:02 without it you aren't going to make progress, and then get fired Feb 09 19:09:05 im being paid $600 a week to do fuck all Feb 09 19:09:08 may as well be the one making the decision Feb 09 19:09:29 or just TRY to do what he asks as best i can till he fires me Feb 09 19:09:40 then i give him a piece of my mind and walk out Feb 09 19:09:54 politely because im not going to be a jerk about it Feb 09 19:10:02 I440r or say you'll take unpaid leave until he gets you what you need Feb 09 19:10:15 or just talk to these people? Feb 09 19:10:17 and not get pay Feb 09 19:10:36 I440r honesty though, you should have at least one phone for development. but for BLE , you'll need at least 10 Feb 09 19:10:37 go to the guy who took the phone back and say you can't do work without a ble phone, what should you do? Feb 09 19:10:49 so if he can't get you 1, you're being set up for failure Feb 09 19:10:49 im honestly trying to do what he asks with the tools available (i.e. NONE) Feb 09 19:11:04 g00s i know this he does not Feb 09 19:11:52 a few weeks ago i called him out on something and he later told me he was impressed by my willingness to tell him he is wrong to his face. not impressed enough :/ Feb 09 19:12:56 Is there an easy way to tell the layout engine to add appropriate spacing to my UI elements? I have a really simple layout but it looks like everythings mushed together, there's barely any space between the UI elements: http://pastebin.com/QWrjUSvW http://i.imgur.com/otjc3pz.png Feb 09 19:14:24 g00s do you have 10 devel phones to do your ble work on? Feb 09 19:14:30 if so, which 10? Feb 09 19:14:42 jerkface03: Padding or margins. Feb 09 19:14:56 I440r no, i specified a list in my contract for the other buyer to acquire. thats kinda the problem doing freelancing, because that list changes a lot Feb 09 19:15:00 i have the list, one sec Feb 09 19:15:29 this is an "official" list? Feb 09 19:15:41 TacticalJoke: but what should I use for padding/margins? Is there a specific system defined value that I should be using? Feb 09 19:15:47 oh. its YOUR official list :) Feb 09 19:16:07 Not as far as I know. Feb 09 19:16:10 oficially compiled by g00s! that makes it official as it can get :) Feb 09 19:16:35 Just use dp units for consistency regardless of screen pixel-density. Feb 09 19:17:00 I440r no its just what i threw together based on market penetration Feb 09 19:17:10 what does copy / paste no work in gdrive doc viewe? Feb 09 19:17:18 i swear to god ... Feb 09 19:17:19 lol Feb 09 19:17:22 because google sucks Feb 09 19:17:45 g00s is this list based on "making sure the application works reliably on 'almost' any phone" ? Feb 09 19:17:49 i only hope google's role in my life steadily declines moving forwards ;) Feb 09 19:17:56 lol Feb 09 19:18:03 if it doesn't, i know i've died and gone to hell Feb 09 19:18:04 dont count on it Feb 09 19:18:06 they are a virus Feb 09 19:19:23 I440r Samsung SGS4/SGS5 soon SGS6, Samsung Note 3/4, one of the Samsung Galaxy Tabs, LG Nexus 5, HTC One M8, Moto G 1 & 2, Moto X, Nexus 7, Nexus 9 Feb 09 19:19:59 i didn't have any Sony's in there. who knows if they are even going to continue with android Feb 09 19:21:16 heh Feb 09 19:21:27 rumor control has it they are going to go with their own OS Feb 09 19:22:00 did your customer bail on you whe you gave them that list? :) Feb 09 19:22:16 seems so. the competitors already had that list and more Feb 09 19:22:19 and is the list based on making the app reliable? Feb 09 19:22:23 yes Feb 09 19:22:39 i.e. if you had all those phones already then no problem Feb 09 19:22:46 yeah Feb 09 19:24:43 brb Feb 09 19:26:40 hmm Feb 09 19:26:48 dagger cannot inject my classes Feb 09 19:27:08 got some nullpointers Feb 09 19:27:16 guess it's time to sleep then Feb 09 19:30:57 Hey guys any idea how should i use Retrofit if i have few call and their response is once with status and data in it and once is only status and variables. Should i just make two Type Adapter Factories and then two Rest Clients? Feb 09 19:34:10 TacticalJoke: fwiw this is what JetBrains recommends for .gitignore: https://intellij-support.jetbrains.com/entries/23393067 Feb 09 19:35:18 personally I think that's a load of crap. there's a lot of dev-specific stuff left in the .idea files, so e.g. if you change flavors, it changes the files, so you have to beware uploading them. If you build, it adds a build folder, which you may or may not want in the uploaded version. etc etc etc the team/local separation is _awful_. Feb 09 19:37:47 <_genuser_> hello ppl. Feb 09 19:37:57 I always .gitignore .idea Feb 09 19:37:59 no reason not to Feb 09 19:38:18 <_genuser_> darn reconnects that cause identification with nickserv to go out. Feb 09 19:38:19 pfn: yeah, I + work am using the gradle files exclusively, and we're very happy with it. Feb 09 19:39:05 Anyone know in which Android version the runtime @annotation performance problem was fixed? Feb 09 19:39:23 Thanks, groxx. Feb 09 19:39:26 zero dev-specific crap, Studio versions can change with no problems, and we can add specific hooks for dev-specific stuff we want to allow (like extra flavors, private servers, etc) Feb 09 19:45:45 <_genuser_> anybody know a security/encryption channel/community on freenode? Feb 09 19:47:01 What's up people? Feb 09 19:47:51 <_genuser_> yo Feb 09 19:56:46 i dont think i would get a google nexus ANYTHING for my own personal use, no flash card slot. thats an instant disqualification for me Feb 09 19:57:08 <_genuser_> 8 seconds to generate getView() view. 10 pictures and bam! Feb 09 19:58:05 I440r: yeah, no sd slot is certainly annoying. they seem downright hostile to the idea, though they finally added framework support in what, 4.4? Feb 09 19:58:32 groxx google has their head up their ass sometimes Feb 09 19:58:40 and theres no tractor big enough to pull it out Feb 09 19:59:07 that pretty much guarnatees i wouldnt buy any of their products for personal use Feb 09 20:00:27 <_genuser_> you guys, any ideas on how to load a default view in gridview item while getView() actually computes a view? Feb 09 20:00:46 <_genuser_> like an image from resources that says, "loading...." or an icon like it. Feb 09 20:01:28 _genuser_: you mean, show a placeholder while something works in the background? Feb 09 20:01:49 lasserix: Are you here? Feb 09 20:02:19 <_genuser_> groxx: yep. Feb 09 20:03:04 <_genuser_> groxx: I remember seeing somethign that for a listview long time ago. but I can't locate that either. googling is not yielding better results. probably the choice of keywords. Feb 09 20:03:42 _genuser_: you could add a "Loading" view that you make visible and hide all the other parts of the view Feb 09 20:04:04 _genuser_: Picasso makes that pretty simple, since you can set a placeholder. there may be a library out there for more generic purposes, but ultimately just do the background work, reload data, return different view. Feb 09 20:04:11 use an async task or something to load the images, and then hide the loading view/ show the other parts when it's finished Feb 09 20:04:40 <_genuser_> groxx: and I'm already using picasso for the final image. So google picasso placeholder image then, eh? Feb 09 20:05:10 yep Feb 09 20:05:14 hello Feb 09 20:05:20 <_genuser_> oh, I see .placeholder(R.drawable.image-temp) Feb 09 20:05:25 <_genuser_> groxx: thanks. :) Feb 09 20:05:47 <_genuser_> bmcdermott-work: I appreciate the input. :) but hey if picasso wants to do the work.... :) Feb 09 20:06:03 yeah definitely use a library when you can :) Feb 09 20:06:14 <_genuser_> right, and if it doesn't work we can blame Jake. Feb 09 20:06:19 <_genuser_> LOL Feb 09 20:07:14 hey TacticalJoke what's up? Feb 09 20:08:01 <_genuser_> at 4seconds per image load, I wanted to show something while the image is loading. Feb 09 20:08:09 <_genuser_> next I'm going to work on caching so the image loading is much much faster. Feb 09 20:08:24 <_genuser_> some temp work had increased the time to 8 second. yikes! Feb 09 20:08:31 hey again androids. i'm having a problem scaling a bmp image. i am attempting to populate a horizontal scroll view with nested listviews with nested imageviews. my problem is that despite the imageviews have ScaleType.FIT_CENTER (and look the right size)... their imageviews or parent listview's size is reflecting the actual size of the bmp (making them wayy too wide). hopefully this is legible. Feb 09 20:09:49 <_genuser_> it's legible. comprehensible? that's another story. Feb 09 20:10:18 i'm hoping for one of two solutions... one is... i can manually scale the bmp but i'd need it to conform to the size of it's parent views (one of which has a height of "100dp"), or figure out a way to have the parent view's WRAP_CONTENT match the scaled down imageview. Feb 09 20:10:30 pablq: set adjustsViewBounds to false, I forget if that's true by default Feb 09 20:10:43 _genuser_: indeed. i apologize for my rambling. feeling halfway brain dead at the moment. Feb 09 20:11:08 <_genuser_> pablq: no worries. I myself moved to using picasso due to many features it offers... one of them being auto-fit. Feb 09 20:11:20 is your image view wrap_content? Feb 09 20:11:43 <_genuser_> you're loading image with android:src="" ? Feb 09 20:15:38 TacticalJoke: going to lunch ttyl Feb 09 20:15:50 Okay. I PMed. Feb 09 20:18:23 lasserix: TacticalJoke hello Feb 09 20:20:12 Hi. Feb 09 20:21:40 Encountering a weird situation. I have a RelativeLayout containing a GridView with a TextView below it. On Android 4.1 and up, both of them display properly show up, but on Android 4.0 it doesn't appear. Any ideas how to debug? Feb 09 20:22:00 The TextView doesn't appear Feb 09 20:22:57 cobar: any negative margins? Feb 09 20:23:51 it may be unrelated, but I feel like I've read about problems there, and we had a complex relativelayout with negative margins and stuff was drawing over other stuff _in the wrong order_. I don't trust it any more. Feb 09 20:25:01 wrong order? the z order should be quite deterministic, groxx Feb 09 20:25:08 cobar: start toggling stuff, see if you can get the textview to appear by itself on 4.0, etc Feb 09 20:25:20 pfn: agreed. but it was absolutely drawing things out of order. Feb 09 20:25:46 cobar, relative layout behavior changed around wrap content, I don't remember which version though Feb 09 20:25:47 <_genuser_> heh, my eclipse doesn't even render views anymore. have to guess and run it on the device, lol. Feb 09 20:25:51 add a view (anywhere! doing anything!) and the draw order of other views would change. Feb 09 20:26:01 ie, it works correctly on new versions of androir Feb 09 20:26:30 groxx: no negative margins but I am using the navigation drawer which sort of has the same effect Feb 09 20:27:14 yiati: ok I'll try that Feb 09 20:27:27 I'm going to test some of that and then post the xml for you guys to look at Feb 09 20:27:36 groxx: the imageview is created programmatically. currently doesn't have any bounds that way. the only params it has is ScaleType.FITCENTER Feb 09 20:28:26 Is there anyway I can change the onclick behaviour on a view to require a press-and-hold for at least 2 seconds or something before it registers as a click? Feb 09 20:28:29 pablq: it'll still have defaults. are you inflating from xml, or `new ImageView(context)` ? Feb 09 20:28:44 NEW Feb 09 20:28:46 a Feb 09 20:28:51 *new sorry Feb 09 20:29:11 jerkface03: add a long-press listener? if it has to be 2 seconds or less you may need to make your own touch listener, not sure Feb 09 20:29:21 the thing is... Feb 09 20:29:22 s/less/more Feb 09 20:29:31 jerkface03: What's the xml attribute for longpress? Feb 09 20:29:36 err Feb 09 20:29:40 groxx rather Feb 09 20:29:58 i want to use notification, but i dont get the idea, how can i implement it and how is the notification going to display when the telepĥone is switch on? Feb 09 20:30:06 the imageview is nested in a linearlayout... which is nested in another linearlayout -> horizontalscrollview Feb 09 20:30:24 jerkface03: hm. there might not be a way in xml. Feb 09 20:30:46 i believe it is either the imageview it's immediate parent linearlayout that's throwing off my layout Feb 09 20:32:27 ah, i think i might be onto something. Feb 09 20:33:25 i was missing the imageview's immediate parent linearlayout. there will be multiple of these layouts. they will be nested in another linearlayout->horizontalscrollview. Feb 09 20:34:17 how can I search in gradle source code on android studio? Feb 09 20:37:54 gdrc: hm. good question. dunno, but I'd be interested if you find out Feb 09 20:38:46 actually I'm using github search :P Feb 09 20:39:04 I’m making my first android app, I’ve got a surfaceview showing the live preview from the camera. I’d like to add a semi-transparent “cross-hair” in the middle of the surfaceview, how do I go about doing this? should I create a new view on top of it just for the cross-hair or somehow draw onto the same view? Feb 09 20:42:12 also please let me know if this is the wrong irc to ask for dev help :) Feb 09 20:43:26 no, this is the right place Feb 09 20:43:30 Gormandy: yeah, add a new view on top. if you put the surfaceview in a framelayout (or relativelayout or whatever), you can put the view after the surfaceview in xml, and it'll appear over. Feb 09 20:44:15 Gormandy: in some other scenarios it might make sense to draw to the same view, but the camera rather forcefully takes control over the surface. it's best to not fight with it. Feb 09 20:47:39 OH okay, thanks. Right now I have: http://pastebin.com/QiThC5S7, should this second view be inside the same framelayout where the camera-preview is, just after, or in the overall linear layout after the camera preview? because that would most likely not go on top right? Feb 09 20:48:36 Once location is added to a manifest the user doesn't have an ability to take away the get location permission from an app do they? Feb 09 20:50:30 Gormandy: you're making a "new Surface()" and adding it to the framelayout at runtime? yeah, I'd add the other view to the same framelayout - that way it'll (by default) be contained in the same box as the surface.. Feb 09 20:51:21 Gormandy: beware that you don't really control the bounds of the surface reliably. depending on the device / OS + the preview parameters, you could draw outside its bounds. if you're able to use a Texture, use that instead, it'll behave "normally". Feb 09 20:53:40 this is how I’m adding it to the framelayout: mPreview = new CameraPreview(this, mCamera); Feb 09 20:53:40 FrameLayout preview = (FrameLayout) findViewById(R.id.camera_preview); Feb 09 20:53:41 preview.addView(mPreview); Feb 09 20:53:56 onCreate Feb 09 20:54:30 yup. if you just "preview.addView(mOtherView)" after that, it'll appear over the surface Feb 09 20:54:45 Awesome, thanks a lot groxx Feb 09 21:00:34 groxx: here is the XML, I removed everything that wasn't essential http://pastebin.com/HBCJFkD3 Feb 09 21:01:18 the TextView not only doesn't appear, findViewById on it returns null Feb 09 21:02:58 <_genuser_> interesting bugs. if I put a TextView height=wrap_content , text = "one line\ntwo line\nthree line" it shows fine. Feb 09 21:03:07 <_genuser_> if I get a reference to it in code, it doesn't show the textview anymore. Feb 09 21:03:08 cobar, are you trying to findViewById on the same inflated layout as that file Feb 09 21:03:13 <_genuser_> mStatus=(TextView)findViewById(R.id.status); Feb 09 21:03:18 <_genuser_> anybody see that before? Feb 09 21:03:39 yiati: yes, findViewById is able to find all the other elements in that file, just not the TextView Feb 09 21:04:01 and I'm calling it in onCreateView after it's been inflated, so that's not the issue Feb 09 21:05:08 cobar, is this layout part of a bigger layout, there could be id collision Feb 09 21:06:54 yiati: There is a DrawerLayout for the activity that this fragment gets loaded into, but I grep'ed the source code and there are any duplicate ids for that view Feb 09 21:07:02 *aren't Feb 09 21:08:34 There must be something else going on inflation wise if you can't find it Feb 09 21:09:36 I think it's some kind of a layout bug because it works on 4.1 and up just fine. Maybe to do with putting the TextView above the GridView even though it displays below it Feb 09 21:09:58 Which is necessary to give the TextView priority so the GridView doesn't take up the whole screen Feb 09 21:10:22 yiati: is there any kind of log that would show layout errors? Feb 09 21:13:26 What does it mean to have priority over the gridview? What are you trying to achieve? Feb 09 21:13:36 cobar, not that I'm aware of since it's probably not technically an error, just a usage error Feb 09 21:14:05 usage error relative to what you want to achieve, but not an error relative to what you are allowed to do Feb 09 21:15:41 <_genuser_> ok, help me understand this. I get a reference to a TextView and it doesn't show on screen. if I don't it displays fine. Feb 09 21:15:48 <_genuser_> mAppStatus=(TextView)findViewById(R.id.app_status); Feb 09 21:16:22 maybe post more than one line of code.. Feb 09 21:17:10 <_genuser_> right, that's the only line that's causing the different. if I comment it out, it's fine. Feb 09 21:17:20 <_genuser_> you wanna see the layout? Or the oncreate that leads up to this? Feb 09 21:17:34 That's not how it works.. Feb 09 21:17:39 I want it all :o Feb 09 21:17:44 Maybe you just need to do a clean build Feb 09 21:18:00 SimonVT: if you have two elements in a RelativeLayout and the top one is set to a height of match_parent, it won't display the bottom element unless you put the element definition above the bottom element in the layout Feb 09 21:18:01 But calling findViewByid will not change anything Feb 09 21:18:39 <_genuser_> SimonVT: hmm, I'll do a clean build. It has solved odd behavior before. Feb 09 21:18:53 <_genuser_> and yes I think the same thing: calling findViewById shouldn't mess anything up at all. Feb 09 21:19:36 cobar: You want to use match_parent, but not have it match parent? Feb 09 21:19:43 does an android phone require an active sim card in order to update its firmware? Feb 09 21:20:29 I440r, i think you cant say that in general. This might depend on the manufacturer. but I'd say no Feb 09 21:20:41 SimonVT: I have a status bar at the bottom that needs a fixed amount of space, there's a grid above it that should take up the remaining space, so I have to use match parent on the grid Feb 09 21:20:58 That's what linearlayout and weight is for Feb 09 21:21:12 the phone in question is a galaxy s4 mini running android 4.2, my boss is using a s3 running 4,4 so he things the mini should at least be updatable that far Feb 09 21:21:40 Which library is the viewpager in? Feb 09 21:21:48 Will linear layout let me specify an exact height for the status bar, not just a percentage? Feb 09 21:21:54 Yes Feb 09 21:21:54 ok it seems he might be right, At&t phone Feb 09 21:22:14 but you would be able to SEE the update if it were avaialable even if you had no sim card no? Feb 09 21:22:15 lasserix, v4 support Feb 09 21:22:24 and i think its also in v14 for native frags Feb 09 21:22:47 It's in support-v4, support-v13 has -v4 as a dependency Feb 09 21:22:59 dunno. I usually use my phone with sim cards I440r Feb 09 21:23:04 thanks Feb 09 21:23:21 Is there any easy way to detect if my activity was started/created from outside my application? meaning that an activity in my application didn't start the current activity. Feb 09 21:23:25 daniele_athome, not my phone lol - does at&t publish direct download links for their updates? Feb 09 21:23:57 <_genuser_> SimonVT: yeah, the mermaids sing again, the puppies dance again, and the babies coo again!!! Feb 09 21:24:08 I440r lol, did that guy give you his phone minus sim ? Feb 09 21:24:25 g00s he wasnt going to give me his wifes phone AND her sim Feb 09 21:24:33 pure comedy Feb 09 21:24:34 <_genuser_> SimonVT: I just found out where I was "clearing" the textview and thought had commented that bit out. :) doh moment. Feb 09 21:24:51 jerkface03, add intent extras when you start it on your own. if they are missing, its from outside Feb 09 21:25:07 <_genuser_> I440r: you're upgrading/rooting someone's phone? Feb 09 21:25:19 boss came in asking me questions about the phone i asked him to get and before he gets it he needs to know that the phone i TRIED to use doesnt have an update first Feb 09 21:25:25 _genuser_, no Feb 09 21:25:34 danijoo: Pretty clever :D Feb 09 21:25:52 I440r you are working with idiots Feb 09 21:25:58 :D Feb 09 21:26:06 g00s no actually, just slow to spend money lol Feb 09 21:26:36 i need to see if there is a direct download link to an official at&t update for the s4 mini Feb 09 21:26:56 Anyone using gradle to add viewpagerindicator to their project? Do you know the correct dependency line? Feb 09 21:27:11 lasserix, yep Feb 09 21:28:00 danijoo: what's the dependency line? Feb 09 21:28:09 would a galaxy s4 update work on an s4 mini? Feb 09 21:28:16 are they basically the same phone but different size? Feb 09 21:28:27 compile 'com.viewpagerindicator:library:2.4.1@aar' and add maven { url "http://dl.bintray.com/populov/maven" } to repositories Feb 09 21:28:35 I440r there are probably 20 different s4 minis Feb 09 21:28:44 crap Feb 09 21:28:48 nightmare Feb 09 21:28:49 and different carriers can have different chipsets Feb 09 21:29:11 like some US samsung have qualcom, international have exynos Feb 09 21:29:47 this is a freeking international conspiracy to make my job impossible! lol Feb 09 21:29:50 of the same model. try blacklisting a galaxy note 3 from pay store, you'll have to choose between 50 of them Feb 09 21:30:49 I440r yeah, by Apple Feb 09 21:30:52 lol Feb 09 21:32:22 well if you cant laugh at this what an you laugh at... $*^$&*T! Feb 09 21:32:43 guy that owns the phone is earching for ANY sim card to see if that will enable an update lol Feb 09 21:32:52 he did not bring his wifes sim card Feb 09 21:33:23 <_genuser_> ok, now to implement broadcast senders for IntentService. Feb 09 21:33:31 let him try to update, that way he can brick his wife's phone Feb 09 21:33:40 <_genuser_> I440r: just curious, you're upgrading a friend's phone? Or is that what you do for a living? Feb 09 21:34:10 no, im developing BLE code with NO phone thats BLE capable. boss had one of the other devs bring his WIFES fone in for me to use as a dev phone Feb 09 21:34:32 but its running android 4.2 and were trying to find out if it can be updated to 4.3 (minimum requirement for ble) Feb 09 21:34:33 lol Feb 09 21:34:42 im not doing ANY updates on anyone elses phone Feb 09 21:34:45 <_genuser_> oh, wow, poor wife. she must've been like why do I have to lose my phone for a day. Feb 09 21:34:52 not for a day Feb 09 21:34:57 <_genuser_> longer? Feb 09 21:35:01 till done Feb 09 21:35:05 <_genuser_> that's a very understanding wife! Feb 09 21:35:07 lol Feb 09 21:35:23 this is an indian company, indian man tells indian wife "this is how it is" Feb 09 21:35:27 end of story :P Feb 09 21:35:28 <_genuser_> sounds like my boss tho. instead of buying one, just borrow employee's wife's phone. Feb 09 21:35:32 I440r BLE dev story #42th issue Feb 09 21:35:45 your a little behind there Feb 09 21:35:48 i have to admit, i'm a fan :) Feb 09 21:35:54 <_genuser_> hmm, you think Indian wives are more understanding? Feb 09 21:36:07 its "how stupid can we get" drama Feb 09 21:37:48 <_genuser_> intersting boss. so is s4 BLE enabled? I mean how much would it cost to buy a second hand off ebay? Feb 09 21:38:32 yes it has a 4.0 bt module Feb 09 21:38:35 just no drivers or api Feb 09 21:38:37 yet Feb 09 21:38:53 <_genuser_> heh, you reminded me. gotta ask my boss if he would upgrade my company phone. he shares a country of origin with yours. Feb 09 21:40:21 how do I add XML elements within the code? So I can display a table of data and only add the elements when there is new data to display? Feb 09 21:40:29 heya folks - got a hopefully simple question. I have a textview. In it I want to put up to 10 status updates (just text, one per line). I can append with myTextView.append("foo"); but does anyone know a simple way to pop the first line? or should I be using another widget Feb 09 21:40:53 <_genuser_> troy: how about setting .maxLines Feb 09 21:40:59 newbQ: searching "how to do ____ programatically" is a nice way to find examples online Feb 09 21:41:27 _genuser_: that seems to prevent me from appending once the limit is reached rather than removing the top lines... unless I'm doing something wrong, haha Feb 09 21:41:32 yiati: thanks. I couldnt figure out the right way to word it so my searches came up empty Feb 09 21:41:43 with android in the search too Feb 09 21:42:26 troy: I think I'd use a ListView for that. Feb 09 21:43:17 * troy looks Feb 09 21:43:42 <_genuser_> hmm, i see. I was always thinking it would auto chop off the top. Feb 09 21:45:41 I need something like a FIFOTextView :P Feb 09 21:47:43 troy: Make a Queue object, and construct a string from that, and keep your TextView up to date with it Feb 09 21:48:07 either that, or simply have 10 textviews, and cycle through them Feb 09 21:48:59 <_genuser_> troy: http://stackoverflow.com/questions/5078058/how-to-delete-the-old-lines-of-a-textview Feb 09 21:49:31 <_genuser_> it's getting .getLineCount(), then getting getEditableText() reference and delete first x lines. Feb 09 21:49:54 s73v3r: definitely that, doing all of this with one textview is overly complicated Feb 09 21:49:55 <_genuser_> basically it's a .log_to_textview_and_keep_last_x_lines( msg) ; Feb 09 21:51:35 Even using 10 TextViews seems like manually creating a ListView. ListView (and, I guess, RecyclerView) were made for this. Feb 09 21:52:55 _genuser_: thanks Feb 09 21:55:23 TacticalJoke, yep you can have a listview that generates 10 textviews Feb 09 21:55:39 This is the stuff adapters are made for Feb 09 21:56:01 g00s you should send me YOUR phone :) Feb 09 21:56:37 troy also see listview transcript mode Feb 09 21:59:28 I440r my phone is a lumia :) only android device i have is n7; only one i'd consider buying is n9 Feb 09 21:59:38 I'm playing around with the SMS API on android. Looking to write a small application that'll fire an SMS 5 minutes from the current time in the background, even if my application isn't running. Is AlarmManager what I should be using to schedule a background event? Feb 09 21:59:49 whats good about the N9? Feb 09 21:59:57 jerkface03, yes Feb 09 22:00:09 I440r kinde & play books on 9" ;) Feb 09 22:00:18 lol Feb 09 22:00:28 Totally off-topic, but do you guys know whether Amazon minds customers (not sellers) having multiple accounts in the same name? Feb 09 22:00:33 i hope an ipad pro comes out, at 12" it could be awesome for reading pdfs Feb 09 22:00:51 not a fan of reading books on any "Device". dont even like it on the desktop. i want something in my hand i can stuff a business card in (cuz what else are they good for :) Feb 09 22:01:10 mm, N9 just fits a full A4 page in portrait mode :) Feb 09 22:01:28 danijoo: AlarmManager will fire off an intent, which will inturn start up an activity in my application, correct? If that's the case that would bring my application to the foreground rather than telling it to send an SMS in the background. Feb 09 22:01:35 I440r i had too many books taking up too much space, its the tradeoff i had to make (using ebooks) Feb 09 22:02:50 problem is, im a linux user and the ONLY pdf readers worth a damn in linux are Gnome or Kde based which instantly makes them not worth a damn Feb 09 22:03:02 jerkface03, you can send intents to services :) Feb 09 22:03:08 i remember hacking on pxdf Feb 09 22:03:10 *xpdf Feb 09 22:03:32 xpdf wont reopen at last page Feb 09 22:03:40 wont open more than one file.. . . Feb 09 22:03:49 i.e. complete and utter TRASH Feb 09 22:09:10 what is layoutparams for viewpager? Feb 09 22:09:19 and what if i dont want to set attrs set for them? Feb 09 22:09:22 can I pas in null? Feb 09 22:09:27 or can I use ViewGroup instead? Feb 09 22:10:13 Every view (including viewpager) requires layout params Feb 09 22:10:16 Whiling returning an imageview for a viewpager (i know ahead of time the w/h) i can do... ViewPager.LayoutParams lps = new ViewPager.LayoutParams(getContext(), null);, or can i use ViewGoup.LayoutParams (in insnatiateItem) Feb 09 22:11:07 Sorry, i mean during instantiateItem() I am trying to add an imageView, i know the height and width of the imageView, so I'd presume i use layout params to set that while returning it, but which layout params can i Use? Feb 09 22:11:27 qpdfview is better than xpdf but the option to reopen docs is grayed out and its not enough that it reopens docs it has to reopen them on the right page or else it is utterly freeking useless to me. the only options are gnome or kde and both of those are permanantly blacklisted as being ubber bloatware upon ubber bloatware. if i wanted that kind of bloat i would be running ms windows Feb 09 22:14:48 lasserix: So are you trying to ask which classes LayoutParams you are supposed to use for ViewPager? Feb 09 22:15:08 You always set use the layout params of the containing viewgroup Feb 09 22:15:15 while returning from instatiateItem Feb 09 22:15:16 So yes ViewGroup.LayoutParams is always valid Feb 09 22:15:29 if you only care about width height Feb 09 22:15:30 yeah but ViewPager.LayoutParams only has one constructor that takes context, attrset Feb 09 22:15:35 ah ok Feb 09 22:15:36 cool Feb 09 22:17:13 ViewGroup.LayoutParams isn't always valid Feb 09 22:17:52 Mm not if you don't have a viewgroup for a parent yeah Feb 09 22:19:31 As in, the viewgroup might just throw away the LayoutParams and use some default parameters if the LayoutParams aren't of the right type Feb 09 22:20:23 There's nothing in the API that says it must read width/height if the LayoutParams are of the wrong type Feb 09 22:21:19 <_genuser_> SimonVT: so I saw your blog. hating on asynctasks.... Feb 09 22:21:41 I'm not hating on AsyncTasks Feb 09 22:21:54 I'm hating on haters hating on AsyncTask Feb 09 22:22:11 * _genuser_ tries to understand the wordplay.... Feb 09 22:23:37 <_genuser_> anyhoo, I your blog and it was informative. I had already been told of IntentService for my app. and in the end your blog helped me understand why aynctask won't work for my app Feb 09 22:25:12 I implement my IntentServices the exact same way Feb 09 22:26:08 <_genuser_> exact same way each time? Or exact same way you would an async task? Feb 09 22:26:25 Unless you need it to be a Service, there's really no difference.. Other than the API for AsyncTasks being simpler Feb 09 22:26:38 With an eventbus Feb 09 22:26:59 <_genuser_> I need the task to finish even if the activity goes out. Feb 09 22:27:30 Either you didn't read my blog post, or you didn't understand it :/ Feb 09 22:27:49 <_genuser_> someone else mentioned that part in here. Feb 09 22:28:55 The entire point of the post is to show you how you can use asynctask in a way that isn't tied to a specific activity instance, and works properly through configuration changes Feb 09 22:29:49 <_genuser_> interesting. I guess I saw IntentService started on it, saw your blog, roped you in as a fellow believer of my approach and went. Feb 09 22:29:52 <_genuser_> I'll re-read it. Feb 09 22:31:23 There's nothing wrong with using IntentService :) Feb 09 22:31:53 There's just the added hassle of having to create an Intent, make sure your parameters are parcelable, .., vs just passing them in a constructor Feb 09 22:32:04 <_genuser_> right, and I liked it's approach. and I demo'd like 8 backed up tasks and shut down the activity and they all completed. Feb 09 22:32:13 <_genuser_> I liked that it says once it starts it _will_ finish. Feb 09 22:32:21 So will AsyncTask Feb 09 22:32:25 <_genuser_> yeah true that about intent and tasks. Feb 09 22:32:38 well, without any managed object, an async task can be killed mid-execution Feb 09 22:32:45 if there are no activities and services active Feb 09 22:35:35 <_genuser_> yeah mine closed and I guess I would have to do other stuff. Feb 09 22:48:06 http://zeromq.org/ is bloody awesome Feb 09 22:48:19 Napalm have you used jermoq ? Feb 09 22:48:25 nope Feb 09 22:48:40 you mean jeromq Feb 09 22:48:42 *jeromq Feb 09 22:48:44 yeah Feb 09 22:48:52 oooo Feb 09 22:48:55 interesting Feb 09 22:49:02 they just need their TLS story , which is the big problem Feb 09 22:49:33 0mq itself has that in experimental, i don't think jermoq has it yet though Feb 09 22:49:58 you can stunnel it Feb 09 22:50:07 that gut went off to do nanomsg i think Feb 09 22:50:13 can't spell Feb 09 22:51:10 basically im trying to implement a push service Feb 09 22:51:18 thinking of using zeromq Feb 09 22:51:27 /jeromq Feb 09 22:51:40 oh. well if you must do that, fb uses mqtt Feb 09 22:51:53 modified mqtt Feb 09 22:52:27 i am just trying to think my way around 1M+ persistent tcp connections Feb 09 22:52:38 hello Feb 09 22:52:49 im thinking cloud load balancer in front of a swath of cloud vm's Feb 09 22:53:07 each cloud vm with essentially 64000 sockets Feb 09 22:53:14 g00s Feb 09 22:53:35 i want to make a notification, when the phone or tablette launches i want the notification to appear how can i do that? Feb 09 22:54:13 john67: http://developer.android.com/reference/android/content/Intent.html#ACTION_BOOT_COMPLETED Feb 09 22:54:37 Napalm: thnx Feb 09 22:54:38 Napalm yeah, i get the impression google has some special magic sauce / params with carriers to make gcm reliable. nm scaling, reliability with low power is hard to do yourself Feb 09 22:55:20 hello everyone i'm having trouble with android studio (im new). anyway my activity's java frame has every R in "R.(something).(something)" red Feb 09 22:55:26 its giving me errors and I cant fix that Feb 09 22:55:34 right off the bat, you are probably looking at a remote service so that the bigger part of the app could be killed off, while he smaller remote service can keep listening Feb 09 22:55:55 john67: you add the RECEIVE_BOOT_COMPLETED permission to your manifest and setup a broadcast receiver for BOOT_COMPLETED then that can start a service which starts an activity Feb 09 22:56:24 MitraFeio: I guess you have an error in one of your XML files. Feb 09 22:56:24 g00s: yea, android side is not a problem Feb 09 22:56:35 g00s: its the damn scalability of the server Feb 09 22:57:17 mosquitto can handle a lot of connections, and servers can be bridged Feb 09 22:57:23 TacticalJoke: How do I find out the XML errors :S? They dont appear on debug Feb 09 22:57:44 g00s: so thats a MQTT broker Feb 09 22:57:45 I just realised that a neat way of importing a Gradle project is simply to create a new project and just copy everything over. Feb 09 22:57:55 Napalm yeah Feb 09 22:58:23 MitraFeio: What error messages do you see if you go Build > Make Project? Feb 09 22:58:24 Napalm if you have any questions about it, you can ask ral on #mqtt Feb 09 22:59:52 doing I'll tell you in a bit. Feb 09 23:00:26 wtf that R isnt red anymore Feb 09 23:01:52 IntelliJ needs manual building sometimes. Feb 09 23:02:04 Napalm: thnx Feb 09 23:02:13 To see that something is or isn't problematic. Feb 09 23:02:58 TacticalJoke: Please explain to me what that just did and why did it stop my "bug" Feb 09 23:05:42 I just noticed nslu2-log is watching us: http://logs.nslu2-linux.org/livelogs/android-dev/ not even anonymizing the nicks....... Feb 09 23:05:44 I guess something was out of date making IntelliJ think that there was an error. Building the entire project led IntelliJ to see that all was well. Feb 09 23:06:33 so that was a bug >.< ? Feb 09 23:06:51 I don't think it was a bug anywhere. Feb 09 23:07:08 Have you recently come from Eclipse? Feb 09 23:07:12 well there was nothing wrong with it and it accused there was a bug so ye Feb 09 23:07:28 nah man im honestly just starting on android I dont even know java Feb 09 23:08:41 If you had run the project, I think the same would've happened: the errors would've disappeared. Feb 09 23:08:59 So it's not like some secret Illuminati handshake you have to do. Feb 09 23:09:55 learn java first Feb 09 23:10:17 yo I have Samsung Galaxy Ace GT-S5839, its connected but doesnt recognize my phone, whats wrong? not compatible or what? I already downloaded Google USB driver thing Feb 09 23:34:04 well, good night everyone, thanks for the help! Feb 09 23:39:23 What’s the best way to re-lay out a screen when the keyboard pops up? Feb 09 23:55:10 Using CirclePageIndicator and it is not showing, tho everything else is, anyone know why this would be? Feb 10 00:00:18 Will viewpagerindicator work an on any arbitrary viewpager? Feb 10 00:10:16 sure, why not Feb 10 00:20:08 s73v3r, set android:softInputMode Feb 10 00:26:32 stupid question what is the only state method guarenteed to be called? is it onResume() on onPause()? Feb 10 00:28:44 both of those will be called Feb 10 00:29:15 they are both garunteed? Feb 10 00:29:26 unless your app is killed, yes Feb 10 00:29:40 and if it is killed neither of them are called? Feb 10 00:30:17 if it's killed you'll get no notification, correct Feb 10 00:30:25 cool thanks Feb 10 00:33:39 Weird guess it is setOnPageListener that doesn't work Feb 10 00:53:33 for my game, i am thinking maybe it is best to have the game screen a seperate activity from the menu screen, and during the game you can press back to return to the menu screen -but before it does this it will save the state of the game to database storage. is intercepting the back button like this a good idea? or is it against recommended practices Feb 10 00:57:18 i feel like handcuffed. i can't do "chmod +x a.out" on my phone (lollipop wft!) Feb 10 01:02:42 i was going to test for a bug in bionic and this is ridiculous.... *%!#& Feb 10 01:04:50 lul / sanata root can't chmod ;( Feb 10 01:11:08 kuldeepdhaka: /data/local/tmp Feb 10 01:11:28 njcomsec: its fine, but you probably want to use a confirm dialog, go like if back pressed -> show is paused dialog (with return to main menu) Feb 10 01:11:29 the shell user should have access to that directory, and be able to +x Feb 10 01:11:48 the shell user is the user that "adb shell" runs as Feb 10 01:13:14 yeh a dialog is a good idea thanks Feb 10 01:13:40 JesusFreke, still says bad mode but after uploading exec flag is retained. now i can execute :) Feb 10 01:13:55 kuldeepdhaka: oh, you probably have to specify it numerically Feb 10 01:13:59 755 or whatever Feb 10 01:14:09 still says bad mode when "ch +x a.aout" but Feb 10 01:14:37 yeah, I don't think android's chmod accepts the "+x" syntax Feb 10 01:16:17 uploading to ".../tmp" exec flag Feb 10 01:18:08 JesusFreke, no success on other than "/data/local/tmp" directory Feb 10 01:19:40 JesusFreke, yes dont accept +x anywhere Feb 10 01:20:11 JesusFreke, thanks for the trick :) Feb 10 01:20:15 np :) Feb 10 01:24:50 I have a list of non-string objects I want to pass to a spinner. I don't want the spinner to use the toString() method on the objects to derive what the text for the items should be. Is there anything I can override that'll let me create custom text to display for each item? Feb 10 01:24:58 Is there any way to speed up the Android Arm Assembler? Feb 10 01:26:13 What's best way to go from %20 -> " " when dealing with html encoded strings? Feb 10 01:26:21 jerkface03: not quite what you asked, but could you override the object's toString() Feb 10 01:26:36 JesusFreke: That'd work I guess. Feb 10 01:37:59 So. It's 100% impossible to use JAXB in android eh? Feb 10 01:38:08 Google. you stupid fucking morons **** BEGIN LOGGING AT Tue Feb 10 01:42:16 2015 Feb 10 01:42:23 ^ the evil logger Feb 10 01:44:03 jerkface03: just use an interface ISpinnerTextGenerator or something Feb 10 02:19:33 android doesn't support every single java library, so what Feb 10 02:19:56 android isn't billed as java, it just uses java the language and part of the runtime Feb 10 02:22:42 actually, something like JAXB should be possible, you just need to properly import the libs Feb 10 02:23:25 though given that searching led me to project glassfish, I kinda doubt it was ever intended for non-enterprise java ;) Feb 10 02:24:29 so I’m trying to put this image inside the camera preview, it’s shrinking down the preview and inserting the image below it, not on top of it. Any suggestions? XML and screenshot in the link http://imgur.com/vyyzZLU Feb 10 02:38:40 hmmm making a game on android/learning as I go, do it with plain ol java or libgdx it? or something else perhaps. Feb 10 02:47:36 dang. irccloud's getting hit lately it seems. **** ENDING LOGGING AT Tue Feb 10 02:59:58 2015