**** BEGIN LOGGING AT Sun Nov 30 02:59:58 2014 Nov 30 03:02:57 that's a pretty low percentage Nov 30 03:03:14 have you considered not looking at your email? :) Nov 30 03:06:20 That's the percentage on a good day. Nov 30 03:14:07 lets say in AS, I am typing : ... = new Intent(); - with my cursor between the parens, and i would like to see the method signatures available. what is the keypress for that ? Nov 30 03:15:02 ah command-P :D Nov 30 03:17:00 ok so this is weird. my app runs on a 2.3.3 avd but not on a 2.3.3 device. it does not run on a 4.x avd but does run on the 4.x device Nov 30 03:17:03 ! Nov 30 03:17:44 g00s, ctrlp Nov 30 03:18:04 yeah, whatever stupid POS Mac with the cmd bullshit Nov 30 03:21:16 pfn: Is this correct? http://pastebin.com/DBMCyeRK Nov 30 03:22:17 I440r: The emulator/device thinks it's International Opposite Day? Nov 30 03:25:16 I might just return null from getItem. Nov 30 03:25:42 Sane users of that adapter won't care about its items. Nov 30 03:26:58 TacticalJoke, ? Nov 30 03:27:28 I440r: What is your app doing that might cause this weirdness? Nov 30 03:27:41 on the emu the app works fine for the most part. on the physical device i get a null pointer exception Nov 30 03:27:47 thats on the 2.3.3 versions Nov 30 03:27:52 What's the stack trace? Nov 30 03:28:22 erm the 2.3.3 stack trace doesnt really tell me WHERE its null pointer is Nov 30 03:28:27 it just says thats what causes it Nov 30 03:28:47 paste it Nov 30 03:29:11 hang on Nov 30 03:29:47 ok dafq, it just ran on the physical... Nov 30 03:29:50 lol Nov 30 03:30:07 TacticalJoke, view type count should be wrapped +1 Nov 30 03:30:30 pfn: Good point. Nov 30 03:30:31 yup. can now even launch it from the app icon.. weird stuff. must be some intermittant snafu in my code Nov 30 03:30:48 looks reasonable otherwise Nov 30 03:30:50 K. Thanks. Nov 30 03:31:00 I'm guessing this is the best way to do this. Nov 30 03:31:00 im creating a gazilliion unit tests for the code and already fixed some major bugs for doing it Nov 30 03:31:13 so ill probably come across what was causing this in the end Nov 30 03:31:14 ty Nov 30 03:49:59 I440r you may want to uninstall your app, and try it again Nov 30 03:50:08 perhaps something on the first run Nov 30 03:51:09 g00s actually i did that Nov 30 03:51:26 i cleared the data then uninstalled Nov 30 03:51:48 im sure ill figure it out, it was just weird is all lol Nov 30 03:52:05 bbl, got to go do dishes Nov 30 03:52:08 blargh Nov 30 03:57:15 is the onDestroy of a fragment a good place to do any last saves with sharedpreferences? Nov 30 04:00:36 hello Nov 30 04:00:41 anybody there ? Nov 30 04:02:59 anybody there use Retrofit ? Nov 30 04:03:26 I do Nov 30 04:03:58 cbot_: The documentation doesn't seem to say whether Fragment.onDestroy is guaranteed to be called. Nov 30 04:04:04 Since Activity.onDestroy isn't guaranteed, I wouldn't trust it. Nov 30 04:04:12 Yeah which is why I do it onPause Nov 30 04:04:15 seems best there Nov 30 04:04:33 Yeah, Activity.onPause is the usual place. Nov 30 04:04:52 Activity or Fragment? Nov 30 04:04:53 Oh, unless you mean Fragment.onPause. Nov 30 04:04:56 or does it not matter Nov 30 04:05:01 hello JakeWharton Nov 30 04:05:09 I meant fragment Nov 30 04:05:20 I'm trying send an image with Retrofit Nov 30 04:05:58 The documentation doesn't state whether Fragment.onPause is guaranteed. I'd guess so. Hard to say. :/ Nov 30 04:06:09 are you the same person who just made the StackOverflow post then? Nov 30 04:06:45 About Activity.onPause, the documentation says "This callback is mostly used for saving any persistent state the activity is editing". Nov 30 04:08:48 JakeWharton: here: http://pastebin.com/CEntqaVf Nov 30 04:09:03 i guess that's a yes then Nov 30 04:09:20 I think Fragment's onPause is fine too Nov 30 04:09:22 onPause() fragment is no longer interacting with the user either because its activity is being paused or a fragment operation is modifying it in the activity. Nov 30 04:09:41 cbot_: I'll look at the Android code. Nov 30 04:10:06 ferpa: your response JSON is malformed Nov 30 04:10:31 yep Nov 30 04:10:40 do you response here: http://stackoverflow.com/questions/27209319/sending-an-image-file-post-with-retrofit?noredirect=1#comment42900526_27209319 Nov 30 04:10:42 ? Nov 30 04:11:20 what does your response JSON look like? Nov 30 04:15:49 JakeWharton: http://pastebin.com/MvjhBUeR Nov 30 04:16:28 well there's your problem. you are returning HTML and Retrofit expects JSON Nov 30 04:17:50 wow Nov 30 04:17:55 1 minute Nov 30 04:18:00 I am trying change it Nov 30 04:20:56 JakeWharton: I don't know nothing about PHP Nov 30 04:21:08 i have drank enough to forget all i knew about it Nov 30 04:21:21 so I found this way to get image file using post Nov 30 04:21:23 http://pastebin.com/ZtagWqDs Nov 30 04:21:38 cbot_: The code is a nightmare. Nov 30 04:21:44 lol Nov 30 04:21:50 cbot_: But this line suggests that it always calls onPause: https://android.googlesource.com/platform/frameworks/base/+/master/core/java/android/app/Activity.java#6040 Nov 30 04:21:55 I can't say for sure, though. Nov 30 04:22:14 Oops, I mean line 6042. Nov 30 04:22:38 Trying to follow FragmentManagerImpl.dispatchPause is so hard, though. Nov 30 04:22:46 Gotta keep about 17 things in your head. Nov 30 04:23:18 Here it is, if you're adventurous: https://android.googlesource.com/platform/frameworks/support/+/refs/heads/master/v4/java/android/support/v4/app/FragmentManager.java#1930 Nov 30 04:23:37 cbot_ why not just commit the preference once you have the value :| Nov 30 04:27:04 good question Nov 30 04:27:46 back Nov 30 04:27:53 TacticalJoke: sorry for the delay matey Nov 30 04:28:02 TacticalJoke: so, how can i help? Nov 30 04:28:34 This is what I came up with: http://pastebin.com/DBMCyeRK Though I guess it's fine since somebody already said it was. :) Nov 30 04:28:47 As far as I can tell, that's the best solution to this problem. Nov 30 04:29:33 Dynamically addable footers without the tyranny of HeaderViewListAdapter and ListView. Nov 30 04:30:02 I'm guessing this code is what you meant, right, Napalm? Nov 30 04:30:26 The whole DataSetObserver thingamajig. Nov 30 04:30:30 TacticalJoke: that'll work, but only if the wrapped Adapter has only 1 view type Nov 30 04:30:38 all those observers gets confusing :| Nov 30 04:30:39 Oh, yeah, pfn pointed that out. Nov 30 04:30:39 Why is it so hard to start a new project without errors Nov 30 04:31:01 So I changed "return 2;" to "return wrappedAdapter.getViewTypeCount() + 1;". Nov 30 04:31:14 Magic numbers FTL. Nov 30 04:31:30 TacticalJoke: how is that magic number? Nov 30 04:31:37 I mean that 2 was a magic number. Nov 30 04:31:39 Then again, 1 is, too. Nov 30 04:31:43 TacticalJoke: oh and you'll need to return the correct type also Nov 30 04:31:56 The correct type of what? Nov 30 04:32:00 Oh. Nov 30 04:32:01 getItemViewType Nov 30 04:32:14 you might also want to do the same for the id's Nov 30 04:32:32 You mean "return wrappedAdapter.getItemViewType();"? Nov 30 04:32:41 yes +1 Nov 30 04:32:41 (position)* Nov 30 04:32:51 and turn 0 for your footer Nov 30 04:33:54 TacticalJoke: http://pastebin.com/DBMCyeRK line 37 should check the position Nov 30 04:34:48 return isFooterPosition(position) ? footer : wrappedAdapter.getView(position, recycledView, parent); Nov 30 04:35:14 I might just return null from getItem. :D Nov 30 04:35:21 Only crazies would use that getView. Nov 30 04:35:40 TacticalJoke: huh? Nov 30 04:36:08 Napalm: So are you saying that I should be using "wrappedAdapter.getItemViewType" in place of "NORMAL_ITEM_TYPE"? Nov 30 04:36:13 (position)* Nov 30 04:36:16 What should I set the target sdk and the compile with? Nov 30 04:36:26 21 Nov 30 04:36:32 Napalm: I mean that I don't expect anybody to call FooterAdapter.getItem. Nov 30 04:36:39 which is half of 42 :) Nov 30 04:36:50 omg Nov 30 04:36:52 nice one g00s Nov 30 04:36:55 Will I be able to test it on my 4.4kitkat phone? Nov 30 04:37:22 g00s, ? Nov 30 04:37:25 yes Nov 30 04:37:29 K thanks Nov 30 04:38:18 Napalm: So are you saying that I should be using "wrappedAdapter.getItemViewType(position)" wherever I'm currently saying "NORMAL_ITEM_TYPE"? Nov 30 04:38:28 That makes sense but feels so awkward. Nov 30 04:38:31 Like some weird coupling. Nov 30 04:38:37 TacticalJoke: not exactly Nov 30 04:38:40 sec Nov 30 04:38:42 K. Nov 30 04:38:48 Does anyone know why a singleton would be destroyed after my app is left in the background for a while (after interacting with a bunch of other apps and then returning to mine)? I mean maybe my whole process is getting destroyed due to low memory? But I never see onDestroyed() being called so I'm skeptical. Nov 30 04:39:05 I get a nocompile devices found error Nov 30 04:39:16 I have debugging on on my oneplus Nov 30 04:39:22 what else do I need to do Nov 30 04:39:51 SilentByte: I'm not sure that Application.onDestroy or whateverActivity.onDestroy will be called when the OS kills your process to reclaim memory. Nov 30 04:40:09 And I've seen Android killing processes for way less than what you mention. Nov 30 04:40:33 When the OS kills it, is the savedInstanceState bundle retained? Nov 30 04:40:46 I tested this, and it did seem to retain the bundle. Nov 30 04:41:11 Ok, that makes sense then, because I'm seeing my savedInstanceState data being retained. Nov 30 04:41:12 You can try killing your process using "am kill" (or whatever it is). Nov 30 04:41:38 Gotcha. Thanks! Nov 30 04:42:49 SilentByte: I think that swiping an app out of Recent Tasks will kill it, too. Nov 30 04:42:53 At least from what I've experienced. Nov 30 04:43:23 Right, but that wipes everything. Nov 30 04:43:35 Bundle and all. Nov 30 04:43:38 Oh, of course. Yeah. I wouldn't expect the bundle to have anything. Nov 30 04:44:06 My mind conflated two topics there. :D Nov 30 04:44:25 Is there a way of detecting if the process has been killed upon returning to it? I guess I can just test some of my data for null... Nov 30 04:45:03 Hmm. Not sure. Would overriding Application.onCreate tell you? Nov 30 04:45:22 Or a static initializer, maybe. Nov 30 04:45:36 Block, rather. Nov 30 04:47:03 hi Nov 30 04:47:29 what is a good jdk version for programming in android Nov 30 04:47:48 7 Nov 30 04:47:56 not 8? Nov 30 04:48:22 Haven't thought about overriding Application... Right now I'm just using a singleton for some global data. Maybe that's not the best way. Nov 30 04:48:24 android is somewhere in the middle of 6 and 7. none of the fun new 8 stuff works Nov 30 04:48:38 Do I need mtp enabled on my device? Nov 30 04:48:46 Try a static block. "static { Log.i("SilentByte", "Process created."); }" Nov 30 04:48:50 Place that somewhere. Nov 30 04:48:54 if i dont use the new stuff in 8 will compiling from 8 work on android Nov 30 04:53:13 Napalm: This seems complex. Seems like I have to return "wrappedAdapter.getItemViewType(position) + FOOTER_ITEM_TYPE_OFFSET". Everything has to be an offset. Nov 30 04:53:27 Napalm: Can't assume absolute values, it seems. Nov 30 04:53:47 Because the wrapped adapter might define, for example, 0..2. Nov 30 04:53:54 Then my indices have to be 3+. Nov 30 04:54:03 linuxuz3r: as long as you set your source and target to not 8 it should be fine Nov 30 04:54:14 Wait, that's wrong. Nov 30 04:54:39 It should be "wrappedAdapter.getViewTypeCount() + FOOTER_ITEM_TYPE_OFFSET". Nov 30 04:55:08 Their count has to be my zero. Nov 30 04:56:13 Or I could forego the "offset" naming and consider that an implementation detail. Just "inner.getViewTypeCount() + FOOTER_ITEM_TYPE". Nov 30 04:56:27 forgo* Nov 30 04:56:54 TacticalJoke: http://pastebin.com/51ZscAx8 Nov 30 04:57:44 Napalm RecycleView that shit ! Nov 30 04:57:50 i know Nov 30 04:57:56 TacticalJoke is not ready for that Nov 30 04:58:04 me neither, didn't stop me :) Nov 30 04:58:12 lol Nov 30 04:59:02 Napalm: What happens if I want to add headers to this class. lol Nov 30 04:59:50 I guess I could just do the same kinda thing. Give *them* the offset. Nov 30 04:59:53 All right, I guess it works. Nov 30 05:00:15 It'd just be "mWrappedAdapter.getItemViewType(position) + NUM_FOOTER_VIEWS + NUM_HEADER_VIEWS" Nov 30 05:00:16 . Nov 30 05:01:08 So much complexity for something so (seemingly) simple. lol Nov 30 05:01:33 TacticalJoke: its simpler with RecyclerView Nov 30 05:01:52 but you cant just use a ListAdapter with it Nov 30 05:02:00 so probably wont help you Nov 30 05:02:09 Okay. Nov 30 05:02:12 I will move to that eventually. Nov 30 05:02:29 For now, though, I think I totally get your example. Nov 30 05:02:47 Want a header? Nov 30 05:02:54 Okay, just to make sure. lol Nov 30 05:02:56 If you don't mind. :D Nov 30 05:03:11 I love how thorough your examples are. Nov 30 05:03:30 I should ask for an entire app. Nov 30 05:03:57 (Kidding.) Nov 30 05:07:14 why does my AVD have an app installed where the icon is in chinese? Nov 30 05:07:34 its a blue circle with a chinese symbol and a yellow blob. thats all i can tell you about it other than it is running in my avd Nov 30 05:08:12 The emulator is made in China. Nov 30 05:08:20 bs Nov 30 05:08:57 Joking aside, I dunno. Never seen that. Nov 30 05:09:11 its in my avd 4.0.3 Nov 30 05:12:24 TacticalJoke: http://pastebin.com/x7NnGmF4 Nov 30 05:15:31 Awesome! Thanks. Nov 30 05:15:36 Confirms what I thought. :) Nov 30 05:15:40 what image editor do you guys like to use to edit .png files ? Nov 30 05:15:41 Do you use eight-space tabs, BTW? Nov 30 05:15:50 no Nov 30 05:15:54 tab Nov 30 05:16:04 its just pastebin Nov 30 05:16:06 Oh, okay. Nov 30 05:17:58 One thing I'm wondering about... In getItemViewType, at the bottom, we're saying "return mWrappedAdapter.getItemViewType(position) + NUM_HEADER_VIEWS + NUM_FOOTER_VIEWS;". Shouldn't that be "return [...] + 2;" (or a constant representing the number of item types we have)? Nov 30 05:18:28 TacticalJoke: same thing? Nov 30 05:18:51 I'm thinking that I could change NUM_HEADER_VIEWS to 2 in future, in which case this would return 3 (but I think we'd still want 2). Nov 30 05:19:09 well then edit the code then Nov 30 05:19:10 lol Nov 30 05:19:20 Okay. Just making sure I'm not going crazy. lol Nov 30 05:19:26 going? Nov 30 05:19:30 lol Nov 30 05:19:30 Har har. Nov 30 05:19:44 :) Nov 30 05:20:12 Okay, thanks, Napalm. This was surprisingly tricky. Nov 30 05:20:21 I feel like this is some serious insider knowledge. Nov 30 05:20:48 can someone who's done expansion files tell me if this doc is out of date: http://developer.android.com/google/play/expansion-files.html -- the doc here suggests you have to manually expand the obb files yourself, but the behaviour i'm seeing has the files automatically extracted to context.getExternalFilesDir(context.getPackageName) Nov 30 05:21:13 TacticalJoke: nope, just ListView and Adapter's have been used since day 1 Nov 30 05:21:45 brb Nov 30 05:24:52 is there any way to call a function in a fragment whenever notifydatasetchanged is called from within a listview inside the saids fragment ? Nov 30 05:25:15 yes Nov 30 05:25:29 Napalm: how ? Nov 30 05:25:41 is it posible to implement gesture detector for a single view? Nov 30 05:25:45 create a DataSetObserver in your Fragment and register it against the adapter in your listview Nov 30 05:26:03 Napalm: super thanks :) Nov 30 05:26:03 you will get a callback to onChanged where you can call a method in your Fragment Nov 30 05:26:21 slani: yes, just do that Nov 30 05:27:04 Napalm: I can't cačll return super.onTouch(v, event); in onTouch method Nov 30 05:27:22 return* Nov 30 05:27:49 slani: create a GestureDetector and a View.OnTouchListener that calls it. Then assign that listener to the View. using View.setOnTouchListener(..); Nov 30 05:28:03 cya all Nov 30 05:28:05 im off Nov 30 05:28:33 Napalm|afk: thanks Nov 30 05:31:09 JakeWharton: now works Nov 30 05:31:37 JakeWharton: thanks Nov 30 06:31:31 why OnTouchListener on buttons when we set button1.setClickable(false)? Nov 30 06:31:44 *dosen't work Nov 30 06:49:12 i just used the fragment worker as M in MVC to good effect from http://www.reddit.com/r/androiddev/comments/2nq18l/examples_to_structure_your_app_using/ Nov 30 06:49:26 or worker fragment Nov 30 06:49:36 not too shabby Nov 30 07:11:39 Hi, I have some problems with dependency injection using dagger when it comes to a generated (aar) android library and using it from some other application. Nov 30 07:12:00 aaronfc: keep going Nov 30 07:13:12 I created a library recently "MyLibrary", and used dagger there. Now I did `./gradlew build` and it generated an *.aar, which I installed in my local maven repository for testing it on a sample application. Nov 30 07:14:14 Then I created my application (uses dagger also) and when I try to compile it, some binding errors raise. And that bindings are from the library. Nov 30 07:15:11 I do not know if I explained myself well enough. I get "SomethingFromTheLibraryManager" could not be bound required by "SomeOtherClassFromTheLibrary" for MySampleAppModule Nov 30 07:17:51 It is like dagger is inspecting also the @Inject annotations from my library, and he can not resolve it because is missing some bindings Nov 30 07:18:56 (The library consists of a main class "MyLibrary" that receives a context as a unique contructor parameter, and I did a provider for that MyLibrary in my MySampleAppModule Nov 30 07:21:18 any idea? Nov 30 07:49:06 ha, fun http://adelnizamutdinov.github.io/blog/2014/11/23/advanced-rxjava-on-android-popupmenus-and-dialogs/ Nov 30 07:49:10 fuck , we need lambdas Nov 30 07:49:47 g00s: there is an existing lib for lambda in android if I remembe Nov 30 07:49:50 remember Nov 30 07:50:10 thepoosh yeah, its a bit of hackery - not really sure about it Nov 30 07:50:22 yeah Nov 30 07:50:24 same here Nov 30 07:50:29 I miss C# at times Nov 30 07:59:20 thepoosh it was funny at i/o this year, during fireside, when Burke commented on Apple having to do something like Swift because Obj was "old", while we're stuck with this frankenstein java 6-7 shit haha - so ironic Nov 30 07:59:40 yeah Nov 30 08:00:08 https://scontent-a-lhr.xx.fbcdn.net/hphotos-xfp1/v/t1.0-9/10268646_10152442067691960_2781639889576172144_n.jpg?oh=2def18d5fa561d764351201c5f896f8f&oe=54D5A12C Nov 30 08:00:36 hah Nov 30 08:25:40 hey folks, looking for recommendations: for preferences should I just use the default preferences screen that android provides, or go with a transparent popup dialog to stay in theme with my app? Nov 30 08:26:09 you can chime in as a user or as a dev. Nov 30 08:28:20 B0BBY: I see no reason not to use the Android preference screen with a custom style Nov 30 08:29:09 thepoosh: oooh, I have never seen it before so I didn't think that was doable. you mean I can make it transparent, etc. theme it myself? Nov 30 08:29:51 yes Nov 30 08:30:08 thanks, googling for more info now. :) Nov 30 08:30:15 http://developer.android.com/reference/android/preference/PreferenceFragment.html Nov 30 08:30:22 I knew asking here would be a good idea. :) Nov 30 08:31:10 thanks for the link. I was reading about PreferenceScreen. I'll read about PreferenceFragment also. Nov 30 08:32:04 B0BBY you could put the pref fragment in an activity, which is styled to float on large screens and be dedicated on smaller ones Nov 30 08:32:38 i wouldn't put a pref screen in a popup dialog / floating window for small devices, like 4" etc Nov 30 08:33:06 g00s: thanks. I am only targetting phones but should be an important thing to check how the app looks on tablets. Nov 30 08:33:30 if only screens, i wouldn't do any of that in a floating thing Nov 30 08:33:35 lol Nov 30 08:33:39 if only phones Nov 30 08:34:02 I was thinking of the camera app on android phones, how the pref screen is a little popup transparent dialog. I liked that idea. Nov 30 08:34:04 otoh, 6" phablet maybe Nov 30 08:34:13 hm, i should try Nov 30 08:34:33 heh, the Note II/III/IV are reaching the 6" mark... Nov 30 08:34:48 on my n7, the camera app shows dedicated pref screen Nov 30 08:35:19 on my note II, and s4 it shows a little popup for the camera prefs, picture sizes, etc. Nov 30 08:40:36 pretty much every android phone has it's own set of apps with their own UI. can only imagine how many branches there are for each google app. Nov 30 08:44:46 B0BBY: not many, they use conditioning in the XML Nov 30 08:45:08 you can actually see this in many places. the resources folder is arranged to write once and run anywhere Nov 30 08:45:10 sort of Nov 30 08:46:06 I guess the UI changes, layout, etc. that I can understand. different icons, different functionality, different that sometimes looks like a whole new app. Nov 30 08:46:24 I"m thinking apps like camera, etc. and not stuff like Play Apps. Nov 30 08:46:34 Hi, all. It has been a long time since I developed for Android. I have a web site that I want to make a launchable app. From what I remember, all this takes is essentially a webview pointed to my site's URL. Am I correct that I can tell it to hide all navigation and address bar elements, making the site entirely fullscreen? Nov 30 08:50:58 cuppy thats not developing for android :) Nov 30 08:51:09 and doing that is also pretty pointless Nov 30 08:51:17 just bookmark it in your browser :) Nov 30 08:51:58 g00s, the idea is to make the site fullscreen without being hacky. Nov 30 08:52:01 also, http://developer.android.com/reference/android/webkit/WebView.html Nov 30 08:52:32 yeah. webview sucks Nov 30 08:52:45 I'm confused ... that's not an aspect of Android development? Nov 30 08:53:40 you can use it for hybrid apps Nov 30 08:56:52 g00s, the thing is, this isn't really just a web site. It's a web application. It's GPS-heavy, and actually has a functions other than just providing information. It works well. I just want to make it a launchable app. Furthermore, it seems webview is about to use Chrome's libs instead of stock, which is even more appealing. Nov 30 08:57:00 g00s: can html5 or js get your location Nov 30 08:57:11 if so how often can you poll them Nov 30 08:57:58 do you guys know Nov 30 08:59:37 linuxuz3r, yes. Nov 30 08:59:43 hmm later Nov 30 09:00:38 ... he sure was easy to satisfy. Nov 30 10:26:55 if I provide an image in my drawable and drawable-xhdpi, what will an xxhdpi device use? the default one or the xhdpi? Nov 30 10:31:19 test and see Nov 30 10:45:43 *thinking out loud* is it sane to have a fragment with setRetainInstance(true) and then you add this fragment to the fragmentmanager but its only purpose is to store data across configuration changes? Nov 30 10:48:03 XniX23: its a common way but there are alternatives. Nov 30 11:02:25 danijoo, what are the downsides of this approach? Nov 30 11:07:30 that you have to write a fragment ;) Nov 30 11:24:17 How do I iterate over the views in a recyclerview? Nov 30 12:18:58 JakeWharton: in the area ? Nov 30 12:35:47 hey guys Nov 30 12:35:51 any NFC gurus around? Nov 30 12:54:04 hey Nov 30 13:10:38 I have an animation on a Fragment (not Support Fragment) all my Fragments replaced with the ChildFragmentManager, the first fragment works good, fade out and after popBackStack() its fadeing in, but the new Fragment just fade in, on popBackStack() the new Fragment just disappears immediate without animations... somebody have an idea?? Nov 30 13:11:07 setCustomAnimations(android.R.animator.fade_in, android.R.animator.fade_out, android.R.animator.fade_in, android.R.animator.fade_out) Nov 30 13:11:49 should ic_stat_notify be white on black or white on transparent? Nov 30 13:19:17 Hi, how do I show system brightnes control? Nov 30 15:02:50 in the GCM documentation, it's recommended to use backoff multiplier when failing to get a REG_ID, any idea on how long to initially wait? Nov 30 15:02:59 what should I start from? Nov 30 15:49:34 Hi, I am having some problems with Dagger and Gradle. I have created a library project that uses dagger for DI, lets call it "MyLib". I added dagger dependency in build.gradle in compile and dagger-compile in provided. I build it using ./gradlew build and then I take the *.aar created in the app/build/outputs/aar.... Nov 30 15:49:57 When using that aar in a new created sample project (only an empty activity) Nov 30 15:50:16 I get "java.lang.NoClassDefFoundError: dagger.ObjectGraph" when trying to instantiate the "MyLib" class Nov 30 15:50:38 (MyLib is the main class of my library, the one that setup the injection using dagger) Nov 30 15:50:40 Any idea? Nov 30 15:54:39 Library build.gradle file: http://pastebin.com/Ze2ePEe6 Test app's build.gradle: http://pastebin.com/kEfU09hL Nov 30 16:00:08 Please? Can you see anything weird in ani of the build.gradle files ? Nov 30 16:00:08 That feeling when you make a huge code change and everything works perfectly. Nov 30 16:00:20 Always a scary feeling. Nov 30 16:02:23 I thought you meant that "Fuck yeah" feeling Nov 30 16:03:00 Yeah. It starts off as "Fuck yeah" and changes to "Wait, why is this working?". :D Nov 30 16:04:59 haha Nov 30 16:05:21 sounds familiar then Nov 30 16:21:18 Hmm. I haven't turned my phone off in forever. Gotta admit that Android uptime is pretty awesome. Nov 30 16:24:15 well, i'm really forced to restart it everynow and then :P Nov 30 16:24:21 it sucks Nov 30 16:24:21 it's Xperia U Nov 30 16:24:45 I have an Xperia U. :D Nov 30 16:24:49 And an Xperia M. Nov 30 16:24:50 pretty slow, i'm still on it's stock ICS, but just waiting for some chance so android lollipop rom get's released, gonna flash it Nov 30 16:24:55 ah nice Nov 30 16:24:55 Yeah, the U is slow. Nov 30 16:24:58 I have Xperia U Nov 30 16:25:02 my friends has M Nov 30 16:25:03 :D Nov 30 16:25:05 I use the U for making sure my app isn't too laggy. lol Nov 30 16:25:15 Though it has a very nice screen. Nov 30 16:25:28 yea i couldn't believe actually Nov 30 16:25:38 i was impressed when i saw the M/Galaxy Core 2 Nov 30 16:25:47 the U's screen smacks both of them Nov 30 16:25:52 Has your bottom cap broken yet? Nov 30 16:25:56 I used to play around with it so much that it broke. Nov 30 16:26:02 no it didn't broke Nov 30 16:26:12 i mostly use the white one Nov 30 16:26:15 Removable parts and I don't go well together. I fiddle way too much. Nov 30 16:26:16 the phone is black Nov 30 16:26:24 wtf did they do to the orientation lock button in 5. why do you need to turn it on in accessibility settings Nov 30 16:26:26 Mine came with a black one and a pink one. Wish I'd had a white one. Nov 30 16:26:59 is your U body is white? Nov 30 16:27:03 Nah, it's black. Nov 30 16:27:11 like mnine Nov 30 16:27:12 mine* Nov 30 16:27:19 really weird Nov 30 16:27:19 I got it from Amazon. Really good deal at the time. Nov 30 16:27:51 i got it from a local store, i've been using it for ~1.75 year Nov 30 16:27:53 :P Nov 30 16:30:02 I like Sony phones Nov 30 16:30:04 . Nov 30 16:30:04 What terms do i have to search for in order to find information about doing the following: "upon getting a notificatin and opening the notification drawer, user can 'extend' a notification by swiping with 2 fingers down on the notificatoin" (what exactly is that 'extending the notification like that' called?) Nov 30 16:30:09 THeir Android customisations are quite nice. Nov 30 16:30:12 Their* Nov 30 16:31:05 i quite like the weather widget Nov 30 16:37:46 TacticalJoke, none is better Nov 30 16:37:49 except Nexus Nov 30 16:37:59 Galaxy phones never been good IMO Nov 30 16:38:17 I prefer Sony devices to Nexuses (Nexi?), personally. Nov 30 16:38:22 Generally speaking. Nov 30 16:38:46 Mainly for the screens. Nov 30 16:38:49 well at the moment Nov 30 16:38:57 Nexus 6 > * Nov 30 16:39:04 it's back cover is wow <3 Nov 30 16:39:29 Sony screen has really really really nice colors Nov 30 16:40:01 currently i own the Xperia U and haven't seen any other Xperia Device except the M :P Nov 30 16:40:07 * OverCoder thinks what would the Z3 look like Nov 30 16:41:59 The Z phones have great screens, too. Nov 30 16:42:10 Even the U's screen is nice for the price. :) Nov 30 16:42:22 I think it has a higher-res screen than the M. Nov 30 16:45:51 Hmm. I switched from ViewHolder to a custom View, and my list just feels less snappy. Nov 30 16:46:10 But I've verified that inflation (and findViewById()ing) are happening exactly the same number of times. Nov 30 16:46:32 Maybe I'm just imagining. Hard to tell. Nov 30 16:46:42 Though the code for the custom View is so much nicer. :) Nov 30 16:46:48 It just makes sense. Nov 30 17:07:20 Hmm, the "ViewHolder considered harmful" guy made another post, describing something he considers even better than the first suggestion: http://blog.xebia.com/2013/07/30/a-better-custom-viewgroup/ Nov 30 17:07:23 What do you folks think about this? Nov 30 17:07:41 I actually find it slightly *less* convenient to have my custom View do layout inflation itself. Nov 30 17:08:16 Though I do see some benefits to this approach. Nov 30 17:16:01 hello, I can't run samepl game project provided by google. I get this error include ':MyModule', ':BaseGameUtils'? Any idea how to solve this? Nov 30 17:38:02 anyone can provide me any resources on how can i create a VPN that programmaticallyconnect to a PPTP vpn? Nov 30 18:05:19 what point is there in manually pairing an androidphone to a device? you cant do anything anyway right? you need an app that to do anything meaningful right? Nov 30 18:18:16 hm, mixing hot and cold observables is tricky Nov 30 19:12:10 hehe, this guy hates Spannables too https://github.com/quiqueqs/BabushkaText Nov 30 19:17:04 hi there Nov 30 19:17:27 I begin to use Android Studio and it keeps donloading Gradle whenever I create a new project ! Nov 30 19:17:53 on plugins list, it says Gradle is enable Nov 30 19:17:57 enabled* Nov 30 19:18:29 zoraj try enabling offline mode - i haven't tried it Nov 30 19:18:51 g00s, thx, let me try that, Nov 30 19:20:49 g00s, a bit lost, where can I set it to offline ^^ Nov 30 19:21:58 go i see it in preferenes -> gradle -> offline work Nov 30 19:22:02 lame it didn't show up in search Nov 30 19:22:30 this may not help. i guess try it Nov 30 19:26:39 g00s, it now says "Error Cause: error in opening zip file" Nov 30 19:26:43 and after some search Nov 30 19:26:52 it's on gradle-wrapper.properties Nov 30 19:27:08 the line distributionUrl=http\://services.gradle.org/distributions/gradle-1.12-all.zip Nov 30 19:27:16 that should be distributionUrl=https://services.gradle.org/distributions/gradle-1.12-all.zip Nov 30 19:27:34 and it starts downloading Gradle again !! Nov 30 19:27:39 how are you sure it's downloading Nov 30 19:29:47 pfn, it says on the bottom Nov 30 19:30:02 it says what Nov 30 19:30:29 Gradle: Download https://service.gradle...... Nov 30 19:31:02 it says specifically that it's downloading? and that it takes the corresponding amount of time per file? Nov 30 19:31:59 hen I clic on it, it shows me a popup with progress bar loading Nov 30 19:32:19 pfn it takes a long time to dl that file, pretty obvious whether its hitting a cache or not Nov 30 19:32:49 does Gradle not come with Android Studio ? do I need to download it separately ? Nov 30 19:33:28 i still haven't figured out what comes bundled with AS, what it tries to get, and what it tries to use Nov 30 19:33:37 seems every release is different, nm whether its working right Nov 30 19:33:46 * pfn shrugs Nov 30 19:34:03 set up new projects outside of android studio then import them Nov 30 19:34:08 always best way to go Nov 30 19:34:16 thats what i do too Nov 30 19:34:23 and why, when I open up the SDK manager it only gives me Android 4.4W the only installed, whereas I have ADT with full load of SDK platform already installed on the same machine Nov 30 19:34:43 android create project -g -v 1.0.0-rc1 etc Nov 30 19:34:45 zoraj oh - hah, now you have 2 sdk installed Nov 30 19:35:03 g00s, kind of, Nov 30 19:35:14 I have ADT and Android Studio on the same PC Nov 30 19:35:34 and would like to start the migration to AS, Nov 30 19:35:42 i liked it the old way, where you just pointed to some directory. now it goes and downloads sdk bits no matter what Nov 30 19:36:31 ^^ I am keen to the easiest path Nov 30 19:36:55 thx guys, Nov 30 19:37:18 i guess they tried to improve the onboarding experience Nov 30 19:37:25 *tried* Nov 30 19:37:54 android studio sounds like it's too idiotfied for me Nov 30 19:38:44 so little reason to use android studio specifically unless you never do anything else in java Nov 30 19:39:13 and sometimes other languages (in the case of eclipse and intellij) Nov 30 19:39:19 Okay, I'm a convert. No more ViewHolders for me. Custom views FTW. Nov 30 19:39:23 I thought AS is now able to create a full ready-to-release app, I'm really curious about the debugging capability Nov 30 19:39:24 pfn newflash, google is idiotfing android too Nov 30 19:39:46 lolliflop? Nov 30 19:40:40 g00s, that's patently untrue given how much trouble you have with the api Nov 30 19:40:51 i mean the UI Nov 30 19:41:31 firefox did it Nov 30 19:41:35 gnome did it Nov 30 19:41:40 seems like a common pathology Nov 30 19:42:06 what specifically about the UI now... Nov 30 19:43:02 well for starters, they idiotfied app installation by simplifing the permission information to the point of uselessness Nov 30 19:43:37 and that whole bs of coalescing multiple permissions into one, so its impossible to tell now in some cases Nov 30 19:44:21 that's play, not android Nov 30 19:45:30 * g00s goes back to coding Nov 30 19:45:34 The permissions thing is stupid. Nov 30 19:46:08 "We need a way to make it harder for users to see which permissions an app uses." Nov 30 19:46:40 The only benefit was their adding the "View Permission" link to the web page. Previously, you have to be signed in and you had to click "Install" to see that info. Nov 30 19:46:45 i think the Uber app is a good case study in how fucked up things are Nov 30 19:47:08 I also think it was a bad idea to hide the "Internet access" one. Nov 30 19:47:29 I use that to figure out whether (certain) apps have ads. (Though this has a limited use case, of course.) Nov 30 19:47:37 is* Nov 30 20:04:35 TacticalJoke, yes, view holders are dumb in the face of encapsulation Nov 30 20:05:10 Maybe on 1.x when you really had to care about every single piece of memory allocation Nov 30 20:05:27 but even then, you'd still have a similar allocation for a view holder Nov 30 20:09:59 pfn: I thought the purpose of viewholder was less memory and more preventing continual lookups of instantiated views in the row Nov 30 20:12:18 It's weird; I'm finding that using a custom View is a little more expensive. Nov 30 20:12:29 Though only relating to initial inflation/findViewById()ing. Nov 30 20:12:32 Is that expected? Nov 30 20:15:18 I'm seeing something like 12360 picoseconds to inflate a custom view and around 5000 picoseconds to inflate a LinearLayout (and then use the ViewHolder thing). Nov 30 20:15:27 Consistently. Nov 30 20:15:49 + or - 2 picoseconds :) Nov 30 20:15:54 :D Nov 30 20:16:01 I know these are small units, but it's curiuos. Nov 30 20:16:02 curious* Nov 30 20:16:47 Wait, I got the unit wrong. Not picoseconds, but whatever nanoseconds / 1000 are . Nov 30 20:17:17 Microseconds, I guess. Nov 30 20:17:33 i think your time scale is too fine grained; try inflating 1000 of them Nov 30 20:17:47 microseconds are nano * 1000 Nov 30 20:21:01 Okay. Nov 30 20:21:31 Okay, I'm getting the same numbers if I do this 1,000 times. Nov 30 20:22:04 Also, damn, that's a slow getView. :D Nov 30 20:23:26 TacticalJoke, which API are you using that gives you picosecond granularity? Nov 30 20:23:30 getview 1000 times isnt reasonable Nov 30 20:25:08 afaik the whole point of viewholder in a recylclerview isn't due to the expansion of the view, but the findviewbyid calls in every row binding Nov 30 20:25:55 Mavrik: Sorry, my mistake. I meant microseconds. Nov 30 20:26:06 I was using System.nanoTime() and dividing by 1000L. Nov 30 20:26:20 TacticalJoke, yeah, note that nanoTime doesn't have microsecond precision Nov 30 20:26:29 dragorn: Right. Just found it odd that inflating my custom view seemed to be slower. Nov 30 20:26:32 usually is like 5-50ms or so Nov 30 20:26:55 so make sure your runs have more than 50ms difference or you're really measuring the nanoTime API jitter ;) Nov 30 20:27:39 Ah. Nov 30 20:27:44 do the jitter bug . chk chk Nov 30 20:27:46 I'm guessing that using System.currentTimeMillis isn't great, either. Nov 30 20:28:20 they all come from the same source. Nov 30 20:28:34 I see. Nov 30 20:28:56 You'll have to use CPU high-precision timers (if your CPU has them) for precision measurment Nov 30 20:29:13 but for benchmarks it really makes no sense, since you can just do several 10000 iterations and get a more precise measurment that way Nov 30 20:30:01 TacticalJoke also check out caliper if you are doing some microbenchmarks https://code.google.com/p/caliper/ Nov 30 20:30:53 Hmm, looks interesting. Nov 30 20:31:37 wouldn't worry about it unless things are janky :) Nov 30 20:32:19 Yeah. What happened was that I switched to custom Views (from ViewHolders) and all of a sudden everything was slow. But the same happened when I (temporarily) reverted those changes. So it seemed to be my phone. Nov 30 20:32:28 But then every now and again it'd happen -- but only with the custom-View code. Weird. Nov 30 20:32:45 I verified that they're both inflating and finding views the same number of times (six, in this case). Nov 30 20:33:06 But the 1000-iteration test found no significant difference, so I can't see anything here. Nov 30 20:36:47 I might avoid the wrapped-adapter thing. It's horrible, subtle complexity. Nov 30 20:36:56 Looks simple but really isn't. Nov 30 20:37:08 Hi, I am getting NoClassDefFoundError: dagger.ObjectGraph when using a library which uses dagger. (I am not using dagger in the app) Nov 30 20:39:29 aaronfc say 'gradle dependencies' and make sure dagger is being added to your project Nov 30 20:39:55 if not , you may have to add it yourself to the project Nov 30 20:45:08 TacticalJoke, you should not mesure yourself, check Traceview or the method profiling in ddms Nov 30 20:45:44 g00s: I am supposed to include dagger in my project just because a library I use uses dagger ? Nov 30 20:46:27 aaronfc if the library was smart, they just depended on jsr-330 Nov 30 20:46:35 i think Nov 30 20:46:56 so yeah, you may need to bring it in excplicitly . also check the libraries manifest Nov 30 20:47:02 faster to drawcolor transparent or set the canvas to null and create a new one? Nov 30 20:47:10 TacticalJoke, injecting call of System.currentmillis and measuring its delta will corrupt your measurement Nov 30 20:47:12 g00s: I am asking because the library is mine, what I am really doing is the library, but I do not want to force any user of my library to add "dagger" if they don't want to use it Nov 30 20:47:20 and you should not use anything in nanosec/1000 to have microsec Nov 30 20:47:25 adq: Okay, I'll look. Nov 30 20:47:31 retrieve nanosecond precision is expensive Nov 30 20:47:36 and not necessarily accurate Nov 30 20:47:41 retrieving* Nov 30 20:47:48 aaronfc you may need to ask JakeWharton how to set it up Nov 30 20:49:07 aaronfc also, if its your won library - last i checked uploadArchives didn't work with maveinInstaller. stuff might be busted there too Nov 30 20:49:12 *own Nov 30 20:49:44 it doesn't include the deps in the manifest Nov 30 20:49:49 I am doing gradle build, and installing by myself the *.aar into my local maven repository Nov 30 20:49:52 (for testing) Nov 30 20:50:07 g00s: maybe there's something wrong with that ? Nov 30 20:50:25 maybe. go into you maven repo and make sure the deps are in the manifest Nov 30 20:51:58 g00s: thanks, that seems definitively my main problem. pom is mostly empty. Nov 30 20:53:17 aaronfc this used to work, but it broke. i brought it up but xav's team doesn't seem to care Nov 30 20:55:11 do you know any workaround ? or I should maybe install a local nexus ? Nov 30 20:58:10 aaronfc well, gradle-samples used to have a sample called localRepo that showed how to do it Nov 30 20:58:29 but those retards lost it or something, it not in the latest version Nov 30 20:58:50 and they took gradle-samples-0.13 down Nov 30 20:59:38 ok, thank you g00s for all your guiding! Nov 30 21:00:29 aaronfc use mavenDeployer() instead of mavenInstaller() that should fix the pom Nov 30 21:02:20 so it will look something like uploadArchives { Nov 30 21:02:21 repositories { Nov 30 21:02:21 mavenDeployer { Nov 30 21:02:21 repository(url: uri("../testrepo")) Nov 30 21:02:21 } } } Nov 30 21:08:10 Hi guys, I need some help about an app that I'm thinking to develop. Basically I need to write a 2 digit integer number in a NFC tag but I need it to be encrypted in order that only my app will be capable of reading and modify that number. I never worked with NFC tags so I don't know if it's possible and how much space the NFC tag needs to have. If someone could help me with that I would Nov 30 21:08:10 be very grateful Nov 30 21:08:51 anyone use the JYMCU for bluetooth? why does it blink red? because it is underpowered? red i would assume indicate something is wrong...I can pair with it though. but i power it with 3.3V and it should have 3.6-6V. Nov 30 21:28:32 Hi. How I can add build path to compile project with support library using ANT ? Nov 30 21:34:41 I am reading Ant docs but still I can't do this simple stuff :/ Nov 30 21:46:49 Hello, I am trying to attach a LongClickListener to a webview, and then change url when someone presses for long, however, i get a null pointer exception..., could someone give me a hand? Nov 30 21:47:30 you get an NPE when ? Nov 30 21:47:39 when i try to loadurl Nov 30 21:47:42 on the webview Nov 30 21:47:44 Anyone know why the getBitmapFromMemCache method would return blank bitmaps? (The bitmap going in was definitely drawn on) Nov 30 21:48:20 Here is my source, for the implementation: http://pastie.org/9752721 Nov 30 21:49:03 I have a toast, where i extract the url (to check if its the right object), and that works fine, but loadUrl() or even .reload(); simply give me the NPE Nov 30 21:49:44 11-30 22:45:15.904: E/AndroidRuntime(30510): at com.android.org.chromium.content.browser.LongPressDetector.dispatchLongPress(LongPressDetector.java:158) <- for reference Nov 30 21:50:36 sooo, what am I doing wrong? :( Nov 30 21:53:59 wtf. I press Tab and eclipse inserts 4 spaces, a tab, and 4 more spaces to indent a line 3 levels Nov 30 21:56:42 any idea bankai_au ? Nov 30 21:56:58 Thorn, did your file have a tab beforehand? Nov 30 21:57:05 thorn, you entered python mode :D Nov 30 21:57:16 or is there an alternative to using LruCache to keep bitmaps in memory without causing adverse effects to the app's performance? Nov 30 21:57:22 god I hope to never see that in a python file Nov 30 21:57:24 Insayne: does this happen every time or sporadically ? Nov 30 21:57:31 bankai_au, every single time Nov 30 21:57:35 i will try it on another device now Nov 30 21:58:04 Mavrik: yes, a lot. I seem to have switched to "spaces only" everywhere and it still does that Nov 30 21:58:48 It's probably just keeping tabs you still have in file, I suggest you purge that asap Nov 30 22:12:41 it works in the emulator :( Nov 30 22:20:13 JakeWharton was almost at 50, I knew the holidays would get me http://i.imgur.com/sa64na9.png Nov 30 22:20:24 so close Nov 30 22:21:27 write an Android app which launches Chrome to their website every 12 hours Nov 30 22:27:03 error: diamond operator is not supported in -source 1.5 Nov 30 22:27:07 Can anyone help me solve this ? Nov 30 22:27:12 It's Java or my code error ? Nov 30 22:27:29 Google has done a "Best Apps of 2014" thing: . Did anyone make it on there? :) Nov 30 22:27:42 Narzew: The diamond operator needs Java 7 support. Nov 30 22:28:32 How to check it's enabled or how to compile with Ant using Java 7 ? Nov 30 22:28:39 it's installed* Nov 30 22:29:09 TacticalJoke: Java 8 will be good ? Nov 30 22:29:36 I think JDK 8 will be good. I know nothing about Ant, though; sorry. Nov 30 22:29:41 I use JDK 7. Nov 30 22:34:22 When you're using a Dialog Fragment is there a way to stop the positive dialog button from cancelling the dialog? Nov 30 22:35:02 TacticalJoke: Ok, I have now Java 5 and Java 8 installed on my machine, but still the same error. Nov 30 22:35:05 I have a couple of EditTexts and I want to make sure that there's a value in one of them Nov 30 22:35:53 Narzew: I can only guess that it's not targetting Java 7. Nov 30 22:35:56 targeting* Nov 30 22:37:05 Ankhwatcher: One approach is to disable/enable the positive button as text is changed. Nov 30 22:37:12 I'm not sure whether it's the best idea or not, though. Nov 30 22:38:08 Google Keep used to let the user click OK and then show an "Empty note discarded" toast if the input was empty. That never seemed great, though. Nov 30 22:38:27 Partly because toasts aren't the best idea ever. Nov 30 22:40:06 so they switched to cruoton like things - and didn't put them in the support library Nov 30 22:40:38 not like its hard, but it would be soo easy ... Nov 30 22:40:42 yeah, I'd like to use setError Nov 30 22:41:55 Ankhwatcher: Your question is googleable, but it looks like there's no totally straightforward solution. Nov 30 22:41:58 The solutions look kinda 'hacky'. Nov 30 22:42:26 e.g., https://www.google.com/search?q=dialogfragment+positive+button+doesn%27t+close Nov 30 22:42:55 http://stackoverflow.com/questions/11327407/the-alert-dialog-must-not-dismiss-until-user-input-text-in-editext-is-valid Nov 30 22:43:59 sounds simple, doesn't work Nov 30 22:44:41 Hmm, can you call setCancelable(false) somewhere? Nov 30 22:45:19 I can, but it doesn;t make any difference the positive button still cancels it Nov 30 22:45:52 Oh. Nov 30 22:46:30 trying to fight the urge to implement this on an activity instead Nov 30 22:46:36 bloody dialog fragments Nov 30 22:46:41 always a pain in the ass Nov 30 22:48:39 This thread suggests that there's no simple solution: https://groups.google.com/forum/#!topic/android-developers/-1bIchuFASQ Nov 30 22:49:19 Though that's not about DialogFragments, to be fair. Nov 30 22:49:31 Wait, never mind. It's about a specific AlertDialog subclass. Nov 30 22:59:09 woohoo http://www.teamten.com/lawrence/writings/java-for-everything.html Nov 30 23:02:17 The argument against verbosity is about readability, not typing, IMO. Nov 30 23:06:08 I don't even get the "it takes too long to type in a language like Java" argument. I type so little using intellisense. Nov 30 23:06:20 Ctrl+Space all the things. Nov 30 23:16:11 google chose python, c++, java as their 3 languages Nov 30 23:16:24 looong time ago, i'm sure they use more now Nov 30 23:17:22 Weird how the game Dots has a fancy UI all the way through and then shows a boring Holo dialog when you try to exit. Nov 30 23:17:45 exit dialogs are almost as bad as splashscreens Nov 30 23:18:12 Are you *sure* about that, bankai_au? Nov 30 23:18:16 yes Nov 30 23:18:18 :D Nov 30 23:18:39 was that attempted humour? too early, sorry :/ Nov 30 23:18:44 Yes. lol Nov 30 23:21:45 What makes me laugh is Reddit clients that have exit dialogs. Nov 30 23:22:08 Better keep the user safe! Nov 30 23:23:09 gotta make sure people really really want to stop wasting time :) Nov 30 23:23:22 "Would you like to stop wasting time? Yes | No" Nov 30 23:23:44 * g00s likes reddit :) Nov 30 23:23:46 I used to use a Yahoo! Chat client that had a "Momma Mode". It'd nag you every N minutes about wasting your life. Nov 30 23:25:58 Wow, the permission list for New Words with Friends. Nov 30 23:26:10 It's basically the Android-permissions documentation. Nov 30 23:26:32 my app is starting to look like that :( Nov 30 23:26:41 bankai_au oh no ! Nov 30 23:26:49 I so wish we could choose to grant permissions. Nov 30 23:27:04 expansion files adds about 5 or 6 perms Nov 30 23:32:48 Gotta love how Scrabble, in immersive mode, puts the ad exactly where the navigation bar usually is. Nov 30 23:33:48 you are now immersed Nov 30 23:33:50 in ads Nov 30 23:33:53 \o/ Nov 30 23:34:14 lol Nov 30 23:34:33 Wow, it has 30-second-video ads. Nov 30 23:34:40 That you can't cancel. Yeah, I'm gonna give that a miss. Nov 30 23:37:16 I wish people would insta-uninstall such apps. Nov 30 23:37:20 Every single user. Nov 30 23:40:36 TacticalJoke: Angry Birs have same 30-second unskippable video ads. Nov 30 23:41:14 you can always skip an add, always Nov 30 23:41:34 you might have to uninstall the app, or take your battery out, but ... :) Nov 30 23:43:12 We have all this amazing new technology and we're using it to... force people to watch advertisements. Nov 30 23:43:34 its the attention economy Nov 30 23:44:26 i'd like the whole internet to find a new way to monetize Nov 30 23:45:04 if you connect your devices to a USB hub, can you launch an app on both at the same time? Nov 30 23:45:46 I think some adverts are done well. Nov 30 23:45:50 Reddit ads are an example. Nov 30 23:46:01 It's there; you can look at it; you can click on it. Nov 30 23:46:21 But it's not awful. Nov 30 23:52:22 if you connect your devices to a USB hub, can you launch an app on both at the same time? Dec 01 00:00:11 i wonder if would be a good thing to store sensor data as public vars in the main class and check them from fragments in custom periods Dec 01 00:00:21 aka not real time Dec 01 00:28:02 Can someone explain to me why my longclick/webview.loadurl() crashes? http://pastie.org/9752721 Dec 01 00:29:54 i am quite lost :( Dec 01 00:30:18 dragorn, its purpose is to reduce time taken by find view Dec 01 00:31:42 I have developed an App that may need to be deployed to a couple of hundred dedicated tablets, but it is not for general use. What is the simplest way to deploy it? Dec 01 00:32:44 thats more of a sysadmin question Dec 01 00:33:44 Nivag, make the APK available? Dec 01 00:35:51 I guess so Dec 01 00:36:14 unless, you are in a corporate environment? Dec 01 00:36:35 using Eclipse to install is fine for the prototype and 5 or so tablets, but hundreds.... Dec 01 00:36:47 TacticalJoke, and inflating your custom view would be no slower than using a view holder, unless you're doing it wrong Dec 01 00:37:15 nivag, are you in a corporate environment? Dec 01 00:37:46 university, but being deployed externally, won't know full details until (if?) IO get the contract for the production version Dec 01 00:37:56 well Dec 01 00:38:04 maybe they run something like SCCM Dec 01 00:38:16 and you deploy through the internal network Dec 01 00:39:28 at this stage, I don't know, just trying to get a feel for what is available Dec 01 00:39:41 pay 25$, release on play store Dec 01 00:39:52 then you will still have to install it on a per device Dec 01 00:40:13 usb -> adb cli to push it Dec 01 00:40:29 but then you will have to enable debug mode too Dec 01 00:40:55 else, e-mail, but it will require you to login on each Dec 01 00:41:11 the tablets may not be accessible by the university network, but we will have a server for uploading data possibly tis server could be used for downloads of the App? Dec 01 00:41:32 dont see why not Dec 01 00:41:46 i rarely seen a write only, but no read Dec 01 00:42:10 are there a URLs I can look at? Dec 01 00:42:26 how do you mean ? Dec 01 00:43:05 to know more about how to setup a sever, or whatever, to download the App Dec 01 00:43:13 server Dec 01 00:43:25 you dont make sense Dec 01 00:43:33 you wish to setup your own server, that feeds the APK ? Dec 01 00:44:02 possibly, if that is a viable option Dec 01 00:44:06 it is Dec 01 00:44:19 well, you know how to install windows or linux ? Dec 01 00:47:53 I've been installing Linux on machines about 20 years... Dec 01 00:49:26 If possible, I need to set things up that relatively non-technical people can download & instal the App, from instructions Dec 01 00:50:47 my main dev environment is Fedora Linux (currently 19) - not sure what the server would be running Dec 01 00:52:04 Nivag: Step one. Throw APK on HTTP server. Step 2. Give people the URL. Step 3: ??? Step 4: Profit. Dec 01 00:52:27 tell me more about step 4!!!! :-) Dec 01 00:54:00 so in essence, it is relatively straightforward, so I can leave the precise details to nearer the time... Dec 01 00:58:11 step 3, give people instructions how to enable untrusted sources for installs, enter link url, install Dec 01 00:59:09 http://www.ubergizmo.com/how-to/how-to-install-apk-files-sideloading-on-android/ Dec 01 01:01:39 thanks! Dec 01 01:01:59 yw Dec 01 01:03:36 how does any developer not know about side loading... Dec 01 01:10:21 pfn: When you have been developing software for over 40 years like me, you will find you ignorance grows faster than anything else! At least, that is my experience... :-) Dec 01 01:11:18 i dont typically do UI work, running into something im sure is silly simple. trying to use https://s3.amazonaws.com/uploads.hipchat.com/1148/6210/OG56kFrC3dPp1g3/background.png as an activity background with the code getWindow().setBackgroundDrawableResource(R.drawable.background); all i get is a blackimage as the background Dec 01 01:11:23 is this a image format issue or? Dec 01 01:11:39 at 40 years it's about time to throw in the towel Dec 01 01:12:54 There are exceptions ... but the 40 year in-grades I've met are all COBOL coders who have a hard time adjusting to Object Oriented Dec 01 01:13:54 pfn: you may plan to get senile early, if you want - but don't assume other people want to give up learning new things as they get older Dec 01 01:14:41 I wrote my first Java prog in 1997 Dec 01 01:14:58 too late to the party Dec 01 01:15:34 What's wrong with having been a programmer for 40 years? Dec 01 01:16:17 nothing if one keeps current :D Dec 01 01:16:36 I've been doing it for 15 and I feel like I wish I had much more experience. Dec 01 01:16:41 pretty much Dec 01 01:16:45 laeanrt enough from a Smalltalk article in a magazine in 1986, to help a help a colleague debug a smalltalk example in 1988 Dec 01 01:17:05 I hated Smalltalk. Dec 01 01:17:17 The syntax made my eyes bleed. Dec 01 01:17:51 Though almost everyone loves Smalltalk. Did you like it, Nivag? Dec 01 01:17:56 Almost everyone who uses it, anyway. Dec 01 01:18:06 hello, why I get this error in andorid studio http://shrani.si/f/1v/MQ/3xfrAX2Q/screenshot-from-2014-12-.png please help! Dec 01 01:18:31 Stay close to the hardware ... keep your ASM's up to date ... 6502, pdp-8, bal30, x86 Dec 01 01:18:58 slani: Have you tried "@android:style/"? Dec 01 01:19:00 After that Java's a breeze :D Dec 01 01:19:14 slani, set project sdk to 21 Dec 01 01:19:28 Ah. I guess both ways work. Dec 01 01:19:48 when I first went to university, they taught FORTRAN, since then NZ universities went through Pascall & Modula II, came back when they used C in 1990 - which was fine by me, as I had taught myself C when I was a COBOL programmer Dec 01 01:20:16 must have programmed in at least 20 different languages Dec 01 01:20:25 Don't go near RPG II, that stuf'll kill you XD Dec 01 01:20:42 grenades OP Dec 01 01:20:43 jcase: Can't you just declare the image as the background in the activity's layout file? Dec 01 01:20:45 jcase: try ticking some toggles in the gimp export menu. It's probably something to do with the way you saved the png. Dec 01 01:20:54 FORTRAN 99 was so horrible. Dec 01 01:21:03 God, programmers had it bad in the past. Dec 01 01:21:05 never actually programed in Smalltalk, but it was the first OO language I had come across Dec 01 01:21:28 My schools EE's used APL ... scrambled my brains Dec 01 01:22:01 Imagine having to use something like FORTRAN with CVS. Dec 01 01:22:03 What fun. Dec 01 01:22:19 FORTRAN 99, you should be so lucky, try FORTRAN II! Dec 01 01:22:25 :) Dec 01 01:22:36 C++ was an upgrade to these people. Dec 01 01:22:42 That's saying a lot. Dec 01 01:23:01 pfn: there's too much ':' being used in scala ... please fix it, reminds me too much of obj-c Dec 01 01:23:23 Does pfn have the power to fix Scala? :) Dec 01 01:23:52 Only done a few simply exercises in C++, but almost got a contract in C++, but went to Java instead - about 1998 Dec 01 01:24:58 I went through the whole C/C++ thing as a teen. It was painful. Surprises me when people recommend C++ to newbies today. Dec 01 01:25:01 bankai_au, only for ascribing types Dec 01 01:25:03 That's some form of sadism. Dec 01 01:25:12 now use git, even for my own exploratory projects Dec 01 01:25:28 no reason not to Dec 01 01:25:33 it's free Dec 01 01:25:38 Mercurial is better. Dec 01 01:25:41 0 effort Dec 01 01:25:42 But Git is good enough, I guess. Dec 01 01:25:44 python is probably best for newbies Dec 01 01:25:46 TacticalJoke, marduk191 sorry had to step away, kids... Dec 01 01:25:50 yeah, Python is good. Dec 01 01:25:52 Yeah* Dec 01 01:26:03 TacticalJoke, i could, but final plan is to wrap it on in a custom packer Dec 01 01:26:09 which would make that problematic for me Dec 01 01:26:18 I think I'd recommend Python to a newbie programmer. Dec 01 01:26:20 Or C# or something. Dec 01 01:26:22 Maybe Java. Dec 01 01:26:27 for being better, there is no compelling argument for jg Dec 01 01:26:31 hg Dec 01 01:27:02 Mercurial has a better CLI, better Windows support, better functionality (e.g., phases), etc. Dec 01 01:27:06 A better extension system. Dec 01 01:27:13 never C# (too limiting, not well supported in Linux), possibly Java Dec 01 01:27:28 mono us extremely well supported on Linux Dec 01 01:27:29 C# and .NET are going open source, aren't they? Dec 01 01:27:39 ?me barfs Dec 01 01:27:44 * Nivag barfs Dec 01 01:27:49 C# is a really nice language. Dec 01 01:27:52 barf all you want Dec 01 01:27:53 It's Java done right, basically. Dec 01 01:28:05 mono is pretty great Dec 01 01:28:05 Though it's getting bloated now. Dec 01 01:28:37 yes, & easier to develop in than Java, but does not scale well for large projects & JIT is not so well developed Dec 01 01:28:39 Nivag: I've read that MS is even targeting Android now. Dec 01 01:28:48 We might be able to use C#/.NET for Android development in the future. Dec 01 01:29:10 What's wrong with the JITter? Dec 01 01:29:13 that's pretty false Dec 01 01:29:18 Also, I think it scales very well. Dec 01 01:29:27 clr is quite advanced Dec 01 01:29:31 what is the "android:id" setting in the activity.xml file? Dec 01 01:29:56 hmm... I develop in Linux, much easier than using Microsoft, I have 35 virtual desktops, & don't have anti-virus slowing me down Dec 01 01:29:56 Mine is blank but I don't know what to set it too Dec 01 01:29:56 What is the best way to learn android SDK when i have kind of proficiency in OOP? Dec 01 01:30:33 Mallot1: Not everything needs an ID. Dec 01 01:30:58 TacticalJoke: So I can delete it Dec 01 01:31:05 I have a good friend who has worked in the Visual Basic & .Net environment for may years Dec 01 01:31:11 You need an ID to refer to it ("R.id.whatever") or, in some cases, for it to be persisted by the framework across Activity restarts. Dec 01 01:31:34 Nivag: .NET is really solid. Microsoft knows what they're doing. Dec 01 01:32:24 Also, VB.NET is such a lame language. Dec 01 01:32:33 Why anyone would ever use that in place of C# is a complete myster. Dec 01 01:32:35 mystery* Dec 01 01:32:43 he uses C# for last few years Dec 01 01:33:01 What is his complaint? Dec 01 01:33:45 vb is terrible Dec 01 01:33:56 vb3pro ftw Dec 01 01:34:01 On Error Resume Next Dec 01 01:34:09 How's that if I crash, only one activity is"taken down"? Dec 01 01:34:17 Not whoole app? Dec 01 01:34:32 marduk191, not the image hmm Dec 01 01:34:36 EndIf Dec 01 01:34:39 EndIf Dec 01 01:34:42 EndIf Dec 01 01:34:46 Dim foo As Integer Dec 01 01:34:59 more we compared features, and for small projects in a Microsoft environment it is very good - for really large stuff you'd be wanting a Linux server, and for really large things Java is better Dec 01 01:34:59 The capitalisation is so horrible, as well. Dec 01 01:35:19 if my if is too long I actually will add a comment after the closing brace } // end if Dec 01 01:35:31 Pascal was a nice language, but the "begin".."end" thing was similarly horrible. Dec 01 01:35:41 jcase: I dunno man, I'm not the best person to ask about ux work lol Dec 01 01:35:44 shmooz: You should refactor instead. :p Dec 01 01:35:47 tried ALGOL 68? Dec 01 01:36:04 marduk191, thanks, yeah me either Dec 01 01:36:09 I'm good at sphagetti coding Dec 01 01:36:40 If BlocksNeedComments Then \ CodeShouldBeRefactored = True Dec 01 01:37:09 Python has the nicest syntax, IMO. Dec 01 01:37:14 Nivag, only real advantage of Linux is ease of automation and administration Dec 01 01:37:17 puke Dec 01 01:37:20 I miss working in C, but that is nostalgia talking Dec 01 01:37:32 Though I hate how prevalent snake_casing is in the Python world. Dec 01 01:37:39 pfn, cost and easy of setup for large scales Dec 01 01:38:00 I don't like how python depends on whitespacing Dec 01 01:38:02 I have some nostalgia relating to C, but I love having a garbage collector. Dec 01 01:38:03 price is a factor as well Dec 01 01:38:06 emacs vs vi ? Dec 01 01:38:08 Life is a gazillion times easier. Dec 01 01:38:19 pico vs nano Dec 01 01:38:59 never seen any Microsoft O/S with virtual desktops, security is lousy,n and more devices run Linux than all other O/S's combined Dec 01 01:39:03 How about "tabs versus spaces"? :D Dec 01 01:39:21 tabs are spaces Dec 01 01:39:22 Nivag: C# and .NET aren't Windows-specific. Dec 01 01:39:49 Oh, you're talking about OSes in general. I see. Dec 01 01:40:25 shmooz: The problem with tabs, IMO, is that you're at the mercy of the viewer/editor. Dec 01 01:40:27 for practical purposes they are tied to Microsoft Dec 01 01:40:55 I think Google Chrome shows source code on GitHub.com that uses tabs with eight-space-wide indents. Dec 01 01:41:15 TacticalJoke: every editor should allow you to configure how many spaces a tab is Dec 01 01:41:15 then you have weirdos using 3 spaces for 1 level of indent Dec 01 01:41:16 Sees the scrollback ... I did ALGOL ! Dec 01 01:41:18 Nivag: I don't think that's accurate at all. Dec 01 01:41:37 (Just to play with ... was fun) Dec 01 01:41:38 g00s: True. Neither world is perfect. Dec 01 01:41:54 I'm not a fan of the two-space thing, but so many of the top programmers are using that these days. Dec 01 01:41:57 oh i use spaces. i think eclipse has hybrid mix of spaces and tabs eh Dec 01 01:41:59 Four spaces FTW. :D Dec 01 01:42:16 When did the world start using two spaces, BTW? Dec 01 01:42:23 I didn't see that much outside of Java. Dec 01 01:42:41 when you nest a lot big tabs cause your code to go off screen Dec 01 01:42:54 It's so easy to avoid that, though. Dec 01 01:43:01 Extracting methods/classes/whatever. Dec 01 01:43:13 I think the only time it's difficult is when we're writing performance-critical code. Dec 01 01:44:33 I guess one Java exception might be deeply nested classes. But that doesn't seem like a good idea, in general. Dec 01 01:44:42 Well I am both developer and SysAdmin on my Linux boxen and my home network Dec 01 01:46:26 gotta go, and do some actually work... Dec 01 01:50:37 g00s: misc interesting http://www.phoronix.com/scan.php?page=news_item&px=MTg1MDc Dec 01 01:50:41 I am reading Square Engineering Blog http://corner.squareup.com/2014/10/advocating-against-android-fragments.html. However, I cannot figure out how to replace view even after first view was created. Dec 01 01:51:21 What does that mean? Dec 01 01:55:54 capella yeah, saw that ... we're still on 3.4.0 :P Dec 01 01:57:50 Hello guys, How do I fix these android application errors? I'm using Eclipse Luna: http://hastebin.com/jajupexiko.xml Dec 01 02:00:16 Mallot1: I can't see an error there. Have you tried Project > Clean? Dec 01 02:01:48 JakeWharton: sorry, to replace one view from other, I just have to remove first one and inflate the second one? Dec 01 02:01:53 yes Dec 01 02:01:57 ok, thank you! Dec 01 02:01:58 :) Dec 01 02:02:48 "Project -> Clean" ? I've heard there's this thing called intelliJ :) Dec 01 02:03:02 TacticalJoke: Here's what I have now: http://hastebin.com/zusigoyuzi.xml Dec 01 02:03:13 capella: No if your using the Android NDK Dec 01 02:03:17 *not Dec 01 02:03:27 :D Dec 01 02:03:54 Ah, for ndk code I just use Sublime ... Dec 01 02:04:17 but that's for mozilla contributions, and they have a custom build process Dec 01 02:04:49 Mallot1: I guess you can't use app_name there. Dec 01 02:05:01 Gotta use "com.company.app.MainActivity" or something. Dec 01 02:05:08 capella: I meant Eclipse has the NDK library setup Dec 01 02:05:43 (Where "MainActivity" is your launcher-Activity name.) Dec 01 02:06:15 TacticalJoke: Congratulations, you solved the error! Dec 01 02:06:18 :D Dec 01 02:06:28 thanks! Dec 01 02:07:28 Do I win a three-night stay in a luxury resort in Beijing? Dec 01 02:07:42 beijing? take a mask! Dec 01 02:08:02 heh Dec 01 02:09:45 I wish those $100 fake chinese iPhone 6's had stock android Dec 01 02:10:25 I guess someone will install stock and CM on it eventually Dec 01 02:14:24 /j #startups Dec 01 02:16:18 anyone here a rom developer? Dec 01 02:16:35 TacticalJoke: Maybe in the future :D Dec 01 02:28:54 g00s: why is it scala needs to be proguarded? is it coz of the size of the scala lib ? Dec 01 02:30:06 bankai_au i don't follow scala much, but unless things have changed ... yea Dec 01 02:30:26 gotcha Dec 01 02:32:57 i'm not sure how scala is going to work with jack / jill, i guess scalac -> java bytecode -> jill -> jayce ? Dec 01 02:33:17 it will work the same exact way it does now Dec 01 02:33:58 also, who cares! lols cala Dec 01 02:35:22 I found a replacement for Candy Crush Saga: Candy Blast Mania. Dec 01 02:35:39 Though it looks like a children's game, it's actually good. :D Dec 01 02:41:55 lasserix: That "ViewHolder considered harmful" guy proposed a slight modification: http://blog.xebia.com/2013/07/30/a-better-custom-viewgroup/ Dec 01 02:41:57 Did you see that? Dec 01 02:42:01 I actually dislike the modification. Dec 01 02:42:33 It seems ugly to say "LayoutInflater.from(context).inflate(R.layout.contact_view, this, true);" (and ignore the return value). Dec 01 02:43:04 yeah i saw Dec 01 02:43:04 Yo all. Dec 01 02:43:06 seems fine Dec 01 02:43:15 Do you use the modification or the original? Dec 01 02:43:17 Just curious. Dec 01 02:43:19 modified Dec 01 02:43:25 Okay. Dec 01 02:43:35 finally built my own presenter pattern Dec 01 02:43:38 * g00s used original Dec 01 02:43:39 Should gradle "assembleRelease" even if AndroidStudio is set as debug in building tab? Dec 01 02:43:43 TacticalJoke oh noes, a tie ! Dec 01 02:43:50 what will he do now Dec 01 02:43:51 BuildVariants, I mean. Dec 01 02:44:23 Did you dislike the new idea, g00s? Dec 01 02:44:27 Sambarboz i see that too Dec 01 02:44:29 I find it too weird, personally. Dec 01 02:44:41 I like the idea of my adapter doing the layout-inflate-ing. Dec 01 02:44:59 g00s: Do you know how to solve? It take 2~3 minutos to a simple build :( Dec 01 02:45:11 if i gradle assembleDebug from the command line, the other sub-projects are compiled in release. but from AS, everything is *debug* or eveyrthing is *release* Dec 01 02:45:31 2-3 minutes doesn't sound fun. Dec 01 02:45:41 Sambarboz no idea - i thought i was losing my mind the first time i saw it, like wuuut dddfff Dec 01 02:45:42 Also, It's "skipping upload" cuz it has'n detected apk changes Dec 01 02:45:53 https://code.google.com/p/android/issues/detail?id=76539 Dec 01 02:46:11 Arg. Dec 01 02:47:28 Every time I see an Android issue, I look at the top left and expect to see "WrongForum" or something. Dec 01 02:47:34 Geniunely surprised when I see "Released". Dec 01 02:49:26 TacticalJoke: It says: "Released" But I'm using 0.8.14. Dec 01 02:49:38 Thats the price we pay for using a 0.x.x version haha. Dec 01 02:58:22 Sambarboz i see that on rc2. not sure if its the right behavior, if it was always like that ... i thought not **** ENDING LOGGING AT Mon Dec 01 02:59:58 2014