**** BEGIN LOGGING AT Mon Jan 26 02:59:59 2015 Jan 26 03:18:10 tez, interesting idea, maybe remote views can solve your problem Jan 26 03:18:20 otherwise, no Jan 26 03:29:45 JesusFreke i wish i /could/ rarely touch UI code (but somebody has too :( ) Jan 26 03:32:07 g00s: you know what you need, right? Jan 26 03:32:17 A UIWriterPersonFactory, obviously! Jan 26 03:33:01 i'd rather just romainguy.clone() Jan 26 03:33:29 I don't think romainguy writes UI though. He writes what you build a UI with :D Jan 26 03:34:22 i have no idea what he's doing anymore Jan 26 03:34:24 heh Jan 26 03:34:35 yeah, I don't know what he's doing now Jan 26 03:35:18 Can anyone point me to some decent resources/documentation about configuring Gradle builds? Especially about running an external command in the preBuild task Jan 26 03:35:24 if JakeWharton had a rabbit http://digg.com/video/i-built-my-rabbit-a-cart-and-now-he-delivers-me-beer Jan 26 03:35:51 Does google maps not work on the debug keystore? Jan 26 03:36:46 MikeClassic oh yeah, its not on d.android.com yet huh Jan 26 03:36:57 would have thought 1.0.0 meant official docs :) Jan 26 03:37:13 oh well, beside whats on tools.android.com you could try this new video https://thenewcircle.com/s/post/1695/dive_into_the_gradle_based_android_build_system_hans_dockter_xavier_ducrohet_video Jan 26 03:37:18 they do have some documentation Jan 26 03:37:23 ok i'll check that out Jan 26 03:38:03 thanks :) Jan 26 03:45:20 look at the normal Gradle docs Jan 26 03:45:33 not anything about Android Jan 26 03:47:08 I'm starting to love Gradle. So simple and powerful. Jan 26 03:49:15 i love it too when i dont have to think about it :) Jan 26 05:00:16 I'm trying to use styles.xml to create a custom button style that only changes the button's background (as a test). I have tried , but the button loses all system default styling (font, height, border, etc) when I use it. What am I doing wrong? Jan 26 05:01:19 duncannz: sounds correct.. your parenting to the default button widget and not the Holo or Material theme ones Jan 26 05:01:40 duncannz: parent="@android:style/Widget.Holo.Button" Jan 26 05:02:45 duncannz: that'll restore font and a few other properties.. the padding and border are supplied by the properties of the 9-patch background so if you want a padding add it to your style and if you want a border add it to your background Jan 26 05:02:53 @android:style/Widget.Holo.Button requires API level 11 (current min is 10) Jan 26 05:03:31 duncannz: yes, parent it to a base style and add a base style in your values-v11 res directory Jan 26 05:03:40 duncannz: either that or use Widget.Button Jan 26 05:03:56 dnc: Why are you using minSdkVersion=10? Jan 26 05:04:02 so is there no way to simply change the background of a button from a style? Jan 26 05:04:07 TacticalJoke: to support more devices? Jan 26 05:04:37 duncannz: there is not much use supporting less than v4 (APIv15) now Jan 26 05:04:50 ICS Jan 26 05:04:53 Yeah, you're just wasting your time trying to support them. Jan 26 05:05:10 Napalm: 10% of devices run gingerbread Jan 26 05:05:12 I'm a little masochistic - I'm aiming to support v9 with my side project :| Jan 26 05:05:26 duncannz: thats what your doing.. you are just changing the background.. but the background is a 9-patch so it supplies the other properties Jan 26 05:05:35 duncannz: read what i said above Jan 26 05:05:37 lol, no matter what targetSdk you use, its headache :) Jan 26 05:05:38 duncannz: And that number will drop and drop. Jan 26 05:05:58 g00s: true, but hopefully to a lesser degree Jan 26 05:06:10 TacticalJoke: some devices being sold today are running it Jan 26 05:06:16 You can have a big headache (15/16+) or an enormous headache (<15). Jan 26 05:06:18 whats up Napalm Jan 26 05:06:19 :D Jan 26 05:06:39 for btle i'm using minSdk=19 :D Jan 26 05:06:51 duncannz: It's not recommended to go below 15/16 for a new project. Jan 26 05:06:53 But it's your life. Jan 26 05:07:02 * g00s thinks of that bon jovi song Jan 26 05:07:09 just trying to make a backport of the Sensor.TYPE_SIGNIFICANT_MOTION functionality Jan 26 05:07:09 It's now or never! Jan 26 05:07:11 depends on what you're doing :) quite a lot has 3rd-party backports, and a lot of the gingerbread-ers prefer _something_ rather than nothing, so you can degrade some of the fancy stuff and everyone's happy Jan 26 05:07:29 i need to support Gingerbread for this.. and man-o-man is it a pain in the fucking ass Jan 26 05:07:45 if you use api 16 then 1 in 4 users can't download your app.. not worth it to me but each to their own Jan 26 05:08:23 alright thanks for your help Napalm Jan 26 05:08:38 duncannz: nobody said 16 Jan 26 05:09:01 Napalm: duncannz: It's not recommended to go below 15/16 for a new project. Jan 26 05:09:10 anyway I'm not arguing this. cya Jan 26 05:09:13 https://developer.android.com/about/dashboards/index.html Jan 26 05:09:22 8% is GB and below Jan 26 05:09:38 fwiw that's only google-play devices. Jan 26 05:09:56 By the time duncannz's app is released, that number will be 7%. :D Jan 26 05:10:51 yea, true... but you do know how many now side-load gapps/play-store plus.. the new Android-One devices.. KitKat and Lollipop.. basically its just not worth it Jan 26 05:11:08 groxx: i am not saying minSdkVersion APIv15 Jan 26 05:11:33 groxx: i am saying develop to it.. and then lower it and remove advanced functionality Jan 26 05:11:47 groxx: and im only saying that because of AppCompat Jan 26 05:11:59 if your not using AppCompat.. no point Jan 26 05:12:49 plus, on most devices your app will be broken on <=GB because the platform was altered by so many vendors.. CTA was pretty shit back then Jan 26 05:15:30 Ugh. I have a cold. Jan 26 05:15:32 Aching all over. Jan 26 05:15:36 i guess there was another update to the CDD http://www.androidpolice.com/2015/01/25/google-android-compatibility-definitions/ Jan 26 05:15:48 man-flu attack! everyone get down! Jan 26 05:15:57 :) Jan 26 05:16:07 I'll try not to sneeze near the screen. Jan 26 05:16:29 anyone know if I can get viruses through IRC? I heard I can.. LOLZ Jan 26 05:16:30 :| Jan 26 05:16:57 Something must be ridiculously hard about selecting an email address from an address book. Someone did it 3 times and still couldn't select an email address. Jan 26 05:18:13 Does your app spy on their every movement, Agamemnus? Jan 26 05:19:32 hardly Jan 26 05:20:08 it only knows what you had for breakfast lunch and dinner Jan 26 05:20:12 Napalm: yeah, that can make sense. plus a lot of the gingerbread devices are lower power, so fewer fancy touches can be a good thing Jan 26 05:20:13 it doesn't count the snacks Jan 26 05:21:41 TacticalJoke: I'm fighting something off too. probably spread it to you :p Jan 26 05:22:08 good news though! it meant I actually got something done this weekend. Jan 26 05:23:10 groxx Jan 26 05:23:17 you sound like the Professor Jan 26 05:23:20 Agamemnus: I'm just messing. :) Jan 26 05:23:24 groxx TacticalJoke get youselves some zing gluconate and high quality whey protein Jan 26 05:23:38 "GOOD NEWS EVERYBODY, the world is ending! Extended vacation this year!" Jan 26 05:23:51 groxx: Part of the reason I did this stream-parsing thing is that I just can't think. This is me basically wasting time (but with useful consequences). Jan 26 05:24:08 tacticaljoke: but I have a serious face Jan 26 05:25:28 Agamemnus: futurama may have infected my brain at some point, yeah :) Jan 26 05:26:13 The necessity to use streaming can be the sign of a problem: maybe you're getting too much data from the server, consider receiving less that you can display right away and download a bigger payload in the background Jan 26 05:26:15 g00s: is bazinga glutemate the same thing? Jan 26 05:26:28 lol Jan 26 05:26:45 sure groxx , sure Jan 26 05:27:44 g00s: k, I'll try that. TacticalJoke I'll let ya know if it cures me. Jan 26 05:27:46 sounds like something hipsters hate Jan 26 05:27:47 deuteros__: Yeah, this is reddit comments. The API isn't good enough to do that, unfortunately. Jan 26 05:27:48 take 30mg of bazinga and call back in the morning Jan 26 05:27:56 (plus one strip of bacon) Jan 26 05:28:01 Their "load more comments" thing is so lame. Jan 26 05:28:06 TacticalJoke: Sad to hear but understandable, then streaming is a decent solution Jan 26 05:28:51 The memory difference is surprising. Something like 2MB of RAM for a 200-comment listing with DOM parsing. Around 0.3MB with stream-parsing. Jan 26 05:29:06 Yeah not surprised at all Jan 26 05:29:21 I'm surprised by your lack of surprise. :) Jan 26 05:30:05 I have first hand experience on all these scenarios: 1) one big load 2) one big load + streaming 3) one small load and one big load in background Jan 26 05:30:29 streaming code is always more messy but so much faster and better memory wise Jan 26 05:30:44 Yeah, I'm extracting methods as we speak. Jan 26 05:30:50 Turning horribleness into semi-awesomeness. Jan 26 05:32:30 semi-awesomeness is the most we can hope for on android Jan 26 05:32:58 g00s: even with Rx? Jan 26 05:33:23 Can't make up my mind about Rx, so many people seem to fall for it and it's just not clicking for me Jan 26 05:33:43 Who here is convinced Rx is great and could show a convincing example? Jan 26 05:34:05 Hey everyone please join #android-os Jan 26 05:34:10 An open channel Jan 26 05:34:33 OERIAS: Why? Jan 26 05:35:18 deuteros__, because it is an open channel for custom roms and phones in general Jan 26 05:35:36 OERIAS what if most devs don't care about that, thats why we're in -dev lol Jan 26 05:35:48 Maybe 'dev' stands for 'device'. Jan 26 05:36:15 i think it stands for devil Jan 26 05:36:41 I also thought it stood for devil Jan 26 05:37:10 In seriousness it is Development Jan 26 05:37:37 I actually wonder Jan 26 05:37:39 1) Jan 26 05:38:02 Has anyone bought an international phone and connected it to AT&T's network? Jan 26 05:38:05 Just announcing that is outt there Jan 26 05:38:12 Agamemnus, I have Jan 26 05:38:14 2) Would anyone like to buy an unlocked AT&T Note 4? Jan 26 05:38:21 OERIAS: everything worked? Jan 26 05:38:35 One of my Samsung Galaxy S II international Jan 26 05:38:41 yes it worked Jan 26 05:38:50 I got it in Spain Jan 26 05:38:53 at&t is making things difficult Jan 26 05:38:56 very neat Jan 26 05:39:03 what steps did you use? Jan 26 05:39:07 just at&t's steps Jan 26 05:39:08 well At&t needs to be broken up Jan 26 05:39:10 or something else Jan 26 05:39:19 I just put in a sim and there you go Jan 26 05:39:19 at&t is actually SBC Jan 26 05:39:32 I did have to put in the right apns Jan 26 05:39:42 i see Jan 26 05:39:42 yes it is Jan 26 05:39:54 maybe this is a discussion for #android-os :) Jan 26 05:39:54 But it still needs to be broken up :S Jan 26 05:40:08 freeeeeedom Jan 26 05:40:09 OERIAS you have your first victim ! Jan 26 05:40:15 At&t needs to be broken up like the nor so united states Jan 26 05:40:22 Agamemnus, you are welcome to join Jan 26 05:40:36 we do talk about Android unlike #android Jan 26 05:40:55 #android at times gets fights and the lack of mods is an example of this Jan 26 05:41:25 actually i am not the first victim Jan 26 05:41:42 maybe the 15th or so Jan 26 05:44:33 Yes but it is a free channel Jan 26 05:45:28 What does that even mean, a free channel? Jan 26 05:45:44 no in-channel-payments Jan 26 05:45:50 but maybe advertisements Jan 26 05:46:20 I didn't know there were irc channels you can join without having to pay Jan 26 05:47:21 everyone in android-dev pays Jan 26 05:47:26 in time and sanity :D Jan 26 05:47:32 deuteros__, free in opinion and thought Jan 26 05:47:37 unlike #android Jan 26 05:47:47 or #android-offtopic Jan 26 05:47:58 eugene over there is racist. Jan 26 05:50:27 * deuteros__ shrugs Jan 26 06:04:42 I think this is more of a dev question - Question: What stops me replacing the android manifest of an apk to the same as some verizon bloatware and overwriting it? Jan 26 06:05:02 crypto something something? Jan 26 06:13:00 hello, could you help me please? can i use android_npapi ndk library in my application project? ( not pdk develop) Jan 26 06:14:15 NPAPI is being phased out Jan 26 06:14:48 The Google Gods regard it with slanted eye Jan 26 06:17:04 Does anyone here work for Google? Jan 26 06:17:12 Speak now or forever hold your peace Jan 26 06:17:20 i hope use just in my application (my application use webview) Jan 26 06:17:36 Levite: yes there are a few Jan 26 06:18:00 I figured. Tell me, how do you sleep at night? Jan 26 06:18:19 Pretty good, you? Jan 26 06:18:26 I close my eyes. Works well. Jan 26 06:18:47 My dog tends to want to go out at 4am though, always wakes me up Jan 26 06:18:51 On top of a pile of money, with many beautiful ladies Jan 26 06:20:40 Google is like the New York Yankees Jan 26 06:21:06 You can love them and hate them at once Jan 26 06:22:41 Can I have different configs based off of gradle buildTypes alone? Or do i really need to use flavors to toggle over? Jan 26 06:23:56 they're basically the same thing Jan 26 06:24:09 build types can be a bit interesting because you control things like the debuggable flag Jan 26 06:25:04 all i want to do is toggle some consts over between my dev/integration/prod envs Jan 26 06:25:21 I'm looking for RxJava examples involving sending each element from an obvservable of to an API request and observing the results Jan 26 06:25:39 i found a vid where a guy uses flavors for that, but to me it seems more useful for feature sets more-so than environments Jan 26 06:25:43 Flatmap is said to combine into a new observable. I can just chain in this method, right? Jan 26 06:25:54 vintz_: i don't use flavors at all Jan 26 06:25:56 knapper_tech: yes Jan 26 06:26:10 vintz_: we just have the normal two build types and then add a 'dogfood' type for internal releases Jan 26 06:26:17 JakeWharton, will map not create a new observable? Jan 26 06:26:33 every operator creates a new observable, technically Jan 26 06:26:58 flatMap is just map except that you return an observable which gets folded into the original Jan 26 06:27:21 so map can be chained as well? Jan 26 06:27:43 yes Jan 26 06:27:46 might need to look at the API types. Jan 26 06:27:57 how do you save a config to a certain buildType vs another buildType though? so that request urls point against diff servers for example? Jan 26 06:29:03 vintz_: our release buildType just hard codes it as a string. the debug buildType uses an override (via dependency injection) to allow us to change the endpoint dynamically Jan 26 06:29:06 JakeWharton, how might I support cancellable results? Jan 26 06:29:14 knapper_tech: observables can be unsubscribed from Jan 26 06:33:36 cool thanks. that helps a lot! :) Jan 26 06:34:21 JakeWharton, a stream of API calls where some will be cancelled. Jan 26 06:34:35 yes, unsubscribe goes upwards Jan 26 06:40:42 i know what google haven't support about npapi more. but i hope use android npapi ndk library. can i use android npapi library in my webview application? Jan 26 06:44:37 it's a dead end. find an alternative Jan 26 06:47:47 Levite, like ppnpi? Jan 26 06:48:15 ppnpi -> ppapi Jan 26 06:49:09 plugins are verbotoen Jan 26 06:49:18 find a native solution Jan 26 06:49:52 for the greater good Jan 26 06:49:57 (chorus) for the greater good Jan 26 06:55:42 thank you for advise Jan 26 07:24:14 I've got an AS project imported from Eclipse that seems to keep losing the Android library. There is no option in project structure under the "app" module Jan 26 07:25:05 nm, reset jdk to 7 and gradle sync looks hot Jan 26 07:25:30 ie sexy. never have i seen large toolchains that "just worked" to such a degree. Jan 26 07:28:24 Ah, AS is using its own Android libs for working projects but a system one for the broken one Jan 26 07:36:47 I am getting a runtime exception when creating a custom notification using RemoteViews Jan 26 07:36:48 bad array lengths Jan 26 07:36:51 any thoughts? Jan 26 07:37:18 rgr: defaq? Jan 26 07:37:29 your client is off the hook Jan 26 07:55:18 Awful quiet ... ... ... aha, g00s is out :p Jan 26 07:55:33 :D Jan 26 07:55:36 capella: !!! Jan 26 07:55:49 it's only rgr's client Jan 26 07:55:53 that is messing me up Jan 26 08:18:48 how convenient would be to create a workspace with eclipse, develop with ionic html/css framework and compile it with ecilse after finishing it? or should i use cordova? Jan 26 08:24:30 someone kick rgr|android Jan 26 08:24:42 ban* Jan 26 08:26:09 If I wanted to output color patterns to the screen of an Android phone; which technique would give me the highest framerate? NDK/C++ + OpenGL? What max framerate could I expect if I only wanted to output a "white screen", "black screen", "white screen", "black screen" pattern repeatedly? Jan 26 08:30:45 This may be outside the realm of android dev but it applies equally to Android and PHP soo.. any idea why `new SimpleDateFormat("hh:MM a").format(timestamp)` in Android gives 12:09 am, but `date("h:i a", $timestamp)` in php gives 12:46 pm? I have verified that the timestamp in each is exactly the same (apart from the php one being divided by 1000 because it uses second not millisecond timestamps) Jan 26 08:32:17 Smells like a timezone difference issue across Android and your webserver Jan 26 08:32:41 ok I made the timezones the same, now the PHP shows 12:46 am Jan 26 08:32:50 and Android shows 12:09 am Jan 26 08:39:52 thank you! Jan 26 08:40:12 NP :) Jan 26 08:41:38 +1 Jan 26 08:43:44 ACcording to www.epochconverter.com, PHP is right and android is wrong. maybe that's just because epochconverter.com is running PHP ;) Jan 26 08:45:07 anyone know where "Formatter Control" is in AS https://www.jetbrains.com/idea/help/code-style.html#d1783554e298 Jan 26 08:45:27 i'm trying to use //@formatter:on / off but i think i need to set something in the GUI Jan 26 08:47:38 aha, its in Code Style -> general, not Java Jan 26 08:55:48 adq, I've changed the manifest, but I can't get the permission from package manager yet Jan 26 09:21:35 JakeWharton, know any good open source apps in the 5k lines range using Rx? Jan 26 10:02:35 If I wanted to output color patterns to the screen of an Android phone; which technique would give me the highest framerate? NDK/C++ + OpenGL? What max framerate could I expect if I only wanted to output a "white screen", "black screen", "white screen", "black screen" pattern repeatedly? Jan 26 10:03:03 DisplayMessageActivity.class <——— this is instance of class? Jan 26 10:03:40 like new construtor(); Jan 26 10:03:44 right? Jan 26 10:04:00 It's not an instance, it is the file containing the bytecode for the class Jan 26 10:04:30 what is bytecode? Jan 26 10:04:36 skfax: Jan 26 10:05:01 It is the compiled form of your code, what the Java virtual machine executes Jan 26 10:05:21 oh great Jan 26 10:05:24 where are you from? Jan 26 10:05:36 skfax, my guess would be almost certainly NDK opengl Jan 26 10:06:07 and I'd guess your framerate would depend on 2d fill rate of the device Jan 26 10:06:55 does anyone of you knows a good open source, self hosted, mobile analytics solution ? Jan 26 10:07:29 Hi all. I know this is the android irc, but anybody here also on the iphonedev channel as well? I can't seem to access it anymore. It's been a few months since I've last logged in. Not sure why I can't log in anymore. I get a message about being banned when I try. However, that happens when I use a new account as well. Jan 26 10:08:16 Phlow: Thanks. I've seen games doing 60 fps on Android devices. I was just curious what one might achieve for very simple images. I'll probably have to write a small demo so I can measure it on my device Jan 26 10:08:20 i have one slow machine running on winxp and cool android device, i want to create and build helloworld app on xp machine and debug/run on android device, tell how, what tools i will need to install on my machine to do this with minimum requirements? android studio or eclipse? Jan 26 10:10:22 valder, your method of access is banned, they have a ban on *!*@gateway/web/* Jan 26 10:10:28 use a real irc client Jan 26 10:12:28 Is it a good idea to store a whole bunch of database sets to a singleton pattern in android if the memory load is not that high? For example: ive a list with 100 product groups which stores 1000 products each (name, id, an identifier to a ressource). And i dont want to query the database everytime because it would be a few hundret querys a minute Jan 26 10:13:13 DisplayMessageActivity.class <——The Class of the app component to which the system should deliver the Intent : why they say it Class? skfax Jan 26 10:14:02 Phlow: thanks for that. now ti seems my real client isn't connecting. I've installed a new router/network setup in my house. Perhaps that's why the client's aren't connecting. Is there information you can direct me to where I can find a way to fix this? I can't connect to this room either using a real client. I've installed Collolquy and LimeChat Jan 26 10:15:09 misterli, 100k entries x size of entry, does that sound like a lot of data to you? Jan 26 10:15:45 AirStar: When referencing "DisplayMessageActivity.class" in Java code, you are referencing the Class class instance of the given class. http://docs.oracle.com/javase/7/docs/api/java/lang/Class.html This is not an instance of the actual class. Jan 26 10:16:08 thanks skfax Jan 26 10:16:45 :) Jan 26 10:16:52 valder, typical irc port is 6667, make sure it's open/forwarded and any firewall on your system has it open Jan 26 10:19:13 Phlow, yes, it does Jan 26 10:20:34 how many chars in the typical name, and typical resource id? Jan 26 10:20:57 100k entries and each of them contains an object which holds about data which have about 800 bytes. (without a pointer to the resource id) Jan 26 10:21:15 Which means the singleton object may store up to 800 kb to 1 mb Jan 26 10:21:37 about 80 megs Jan 26 10:22:44 whops, okay. far too much to store it into an object Jan 26 10:23:12 think so? Jan 26 10:23:16 Of course, yes Jan 26 10:23:25 memory footprint of my facebook app says... 172MB Jan 26 10:23:55 Sure. But searching in an object which have 80mb of data may take ages. searching in a database which is 80mb in size should be rather fast Jan 26 10:24:34 sure, if you're getting the benefit of an index, which you won't have in an object graph Jan 26 10:25:13 B-tree will do much better for quick lookups Jan 26 10:25:20 Okay. Thank you Jan 26 10:27:10 A Java class file is a file (with the .class filename extension) containing Java bytecode that can be executed on the Java Virtual Machine (JVM). A Java class file is produced by a Java compiler from Java programming language source files (.java files) containing Java classes. <—— skfax. this is .class? Jan 26 10:27:17 skfax: Jan 26 10:28:11 that's the .class file Jan 26 10:28:29 DisplayMessageActivity.class <—— this is same? Jan 26 10:28:32 Phlow: Jan 26 10:28:43 AirStar: If you are talking about "X.class" within code, you are using the reflection mechanism in Java to reference the class object. If you are talking about "X.class" in the filesystem, you are talking about the compiled bytecode for a Java class Jan 26 10:29:25 http://stackoverflow.com/questions/2160788/what-is-a-class-literal-in-java Jan 26 10:29:33 AirStar ^ Jan 26 10:29:42 oh thanks skfax and Phlow Jan 26 10:29:44 :) Jan 26 10:34:00 MyClass.class == new MyClass() ? skfax Jan 26 10:35:46 yes? Jan 26 10:35:50 Phlow: Jan 26 10:36:41 no Jan 26 10:37:33 :( Jan 26 10:37:36 then? Jan 26 10:37:52 Phlow: Jan 26 10:38:13 AirStar, do you know any other languages perhaps? Jan 26 10:38:21 yes Jan 26 10:38:25 such as? Jan 26 10:38:40 c, c++, java, python, php, javascript, objective-c Jan 26 10:38:44 ........ Jan 26 10:38:49 i know many language Jan 26 10:39:06 ok, do you know what rtti is in c++? Jan 26 10:39:19 rtti Jan 26 10:39:20 ? Jan 26 10:39:25 runtime type information Jan 26 10:39:27 i heard it first now Jan 26 10:39:35 no Jan 26 10:39:36 :( Jan 26 10:39:52 what is it? Jan 26 10:41:24 Hello. Jan 26 10:43:30 In js, you can pass a callback function with .emit like this: http://stackoverflow.com/questions/20337832/is-socket-io-emit-callback-appropriate Jan 26 10:43:33 How do you do the same thing in java for android? Jan 26 10:44:35 I want to pass a callback function as parameter. Jan 26 10:45:42 AirStar, think of it as a way to identify the type at runtime Jan 26 10:47:02 runtime: MyClass.class compile time: new MyClass() <——right? Phlow Jan 26 10:48:35 AirStar, erm, no. new MyClass creates a new instance of that type Jan 26 10:48:43 Hi, how can i add an icon to a menu item? Jan 26 10:48:58 i don’t know .class meaning. Jan 26 10:49:02 how can i do? Jan 26 10:50:20 AirStar, start reading about "reflection" and maybe it'll start to make sense Jan 26 10:50:45 what is reflection? Jan 26 10:50:48 Phlow: Jan 26 10:51:57 I came few days ago here, and i was said it was impossible to add an icon to a menu item however i found an app where the menu items have icons, any help would be appreciated Jan 26 10:52:38 hi, has anyone played with googles heirachical state machine? Jan 26 10:52:39 or any other state machines? Jan 26 10:53:41 http://tutorials.jenkov.com/java-reflection/classes.html <—— is it right? Phlow Jan 26 10:54:46 AirStar, that looks promising, start with an overview of what reflection is and why you might want it Jan 26 10:55:05 ok thanks Phlow Jan 26 10:55:08 i will read it Jan 26 11:06:54 Class myObjectClass = MyObject.class; == MyObject myobject = new MyObject(); Jan 26 11:06:59 yes Phlow ? Jan 26 11:07:56 right? Phlow Jan 26 11:08:41 i want it for android app. Jan 26 11:08:44 Phlow: Jan 26 11:09:08 hello room, when generating a release apk, it also generate a unaligned apk.. what does this unaligned means? Thanks Jan 26 11:10:11 johnc--, the apk is actually a zip file. in a zip, the files are randomly located inside the file. aligning puts them in an order Jan 26 11:10:25 its like defragmenting a HDD Jan 26 11:10:34 gives faster access once the apk is installed Jan 26 11:10:54 AirStar, I'm not sure how you're associating those things. They're not equivalent, except to say that you're creating a reference by assignment. Jan 26 11:11:41 yes i want that answer : you're creating a reference by assignment. Jan 26 11:11:47 ok i see Jan 26 11:11:48 thanks Jan 26 11:12:20 thanks danijoo, so unaligned will means differently or randomly arranged files inside an apk's? why do they even make it :P Jan 26 11:12:39 Bazinga http://imgs.xkcd.com/comics/location_sharing.png Jan 26 11:12:43 johnc--, because by default if you zip a file, there is no alignment Jan 26 11:12:58 you have to just create it. and after that, the tool "zipalign" does the alignment Jan 26 11:13:19 oh, so i don't need the unaliged one? Jan 26 11:13:47 you can use the unaligned one for developing. (alignment needs time and for a quick debug build you dont need it) Jan 26 11:14:03 but the play store only accepts aligned apks. so you have to do it for a release Jan 26 11:14:18 ok thanks. Jan 26 11:28:03 reflection mechanism is Class myObjectClass = MyObject.class; ? Phlow Jan 26 11:29:02 good morning Jan 26 11:29:24 I'm looking for a solution to do login in facebook using my application Jan 26 11:29:41 I have an Dialog with EditText email/password Jan 26 11:29:58 i have a class with a variable called “active”, and a setActive() method… when i’m subclassing it, is there any way to change that variable’s value when overriding without running the associated code in the parent class? Jan 26 11:30:08 does it have to be set as public? Jan 26 11:30:23 when user no has a Facebook session opened I want login from my application Jan 26 11:30:34 sending email and password to facebook and open a session Jan 26 11:30:52 theres any to do that using JSON or somethink like this ? Jan 26 11:33:20 AirStar, that's one of the mechanisms of reflection, yes Jan 26 11:33:40 then what is relection in java? Jan 26 11:33:44 i don’t know reflection. Jan 26 11:34:13 AirStar, I think you may need to keep reading, I think you're missing some concepts that'll help you connect the dots Jan 26 11:34:34 give me docs of reflection. Jan 26 11:34:50 then i will read it first before making android app. Jan 26 11:36:28 ultra- - What's wrong with protected access and just not calling super? Jan 26 11:37:56 it’s a custom button, which normally shows a graphic in one way when active = true, and it sets the graphic from setActive()… i’m subclassing that button because i want most of the functionality, but i’m changing how setActive() behaves Jan 26 11:38:19 oh, wait Jan 26 11:38:21 you said NOT calling super Jan 26 11:38:54 mostly, i’d still like getActive() to return the correct value, but i might have to look up protected access (still kind of new to figuring out these scopes and modifiers in java) Jan 26 11:39:32 ah, so protected means i can access it from a subclass, i’ll try that Jan 26 11:40:42 that did it, thanks flan3002 Jan 26 11:54:01 why i cant make my logcat logs full screen by double clicking ? Jan 26 11:56:05 can i use json instaead of .xml when developing android app? Jan 26 11:57:47 sci-fi - Because you forgot to calibrate your cat. Jan 26 11:58:53 Alina-malina - You can use it, but by default layouts can only be inflated from (binary) XML, so probably not what you want. Jan 26 11:59:25 flan3002:how Jan 26 11:59:40 sci-fi - I don't have a cat, sorry. Jan 26 12:00:07 then adopt one Jan 26 12:00:10 :) Jan 26 12:00:11 sci-fi - Come on, you gave no context whatsoever and there are hundres of possible reasons. There's no way we can help you like that. Jan 26 12:00:11 hmmmm ok thanks heh Jan 26 12:00:52 Alina-malina - So... not easily for layouts, if at all, but certainly for data storage. Jan 26 12:01:11 flan3002: mate i was using eclipse and i could maximize and minimze logcat by double clicking, now i use android studio Jan 26 12:01:30 well yes, thanks for pointing me, because i was going to use .json for layout instead of xml:) Jan 26 12:01:41 hi Jan 26 12:02:08 i have android:color="#FF0000" in my textView, but the color of text is not changed , it is black. Any can help me? Jan 26 12:02:09 sci-fi - Yeah, and now it doesn't work like you're used to? Think there's a button somewhere on the top of the logcat frame, but... maybe not. Jan 26 12:05:11 t0th_-_ - s/color/textColor/? Jan 26 12:18:27 flan3002: offcourse Jan 26 12:18:29 thanks Jan 26 12:18:47 how i ca bold a specific character from string in textview? Jan 26 12:21:37 hello! has anyone done android facebook integration? I got problem like this: http://stackoverflow.com/questions/28137099/facebook-android-photo-upload-application-link Jan 26 12:22:44 t0th_-_ - Use Spans, or Html.fromHtml. Jan 26 12:23:13 thanks Jan 26 12:24:48 hello Jan 26 12:33:30 hi Jan 26 12:33:35 nobody :( Jan 26 12:34:03 :o Jan 26 12:34:35 if someone has done facebook integration before please let me know. any hint will do :) Jan 26 12:34:53 gordon_, if somebody would know, they would answer :0 Jan 26 12:35:23 so nobody has ever done this? eh... Jan 26 12:35:47 just a bad time to ask. Jan 26 12:36:02 ok, will try later Jan 26 12:36:10 thank you for the answer :) Jan 26 12:36:25 most people are online in the evening. its rather quiet before that :) Jan 26 12:36:49 you should have let him think noone has ever done it Jan 26 12:36:58 :o Jan 26 12:37:12 shmooz: smart as always ? ;) Jan 26 12:38:12 put one more s and jackpot :D Jan 26 12:43:32 Hej could someone look at what i do wrong when starting a service that should make a notification pop up : http://pastebin.com/v3ACWxbA Jan 26 12:44:11 hyrixo, read the topic Jan 26 12:45:46 1) dont use the deprecated Notification api, use Notification.Builder to build notifications Jan 26 12:46:08 2) set the notification in onCreate using setForground(notificationId, notification) Jan 26 12:46:46 3) dont return super.onStartCommand(..), return START_STICKY or something like that Jan 26 12:47:08 there was support notifitcation builder afaik Jan 26 12:47:20 and tell us what the problem is, not just "its not working". Jan 26 12:47:29 http://developer.android.com/reference/android/support/v4/app/NotificationCompat.Builder.html Jan 26 12:47:48 gordon_, yep. This or the normal one, but he shoudnt use new Notification(....) to build them Jan 26 12:47:59 Well my notification doesn't pop up for starters and he gives me in the warning that it's not safe cause i'm passing Extra Jan 26 12:48:14 yes I know. just give him good tip ;) Jan 26 12:48:21 hyrixo, do 1-3 and retry :) Jan 26 12:48:30 aha no it's the implicit starting that's unsafe Jan 26 12:50:48 Why shouldn't i use the new Notification way btw ? Jan 26 12:51:01 hyrixo, because the old is *deprecated* Jan 26 12:51:59 and there is a reason for it, which can be bugs that are not fixed, missing features or whatever Jan 26 12:55:01 If one includes code from http://developer.android.com/google/play/expansion-files.html in an app, and also "Google Play Licensing Library package" and "Google Play APK Expansion Library package", how does that work with licensing/copyright? Can I still release my project under whatever license I want to or how does it work? Do I write in the LICENSE that "all code is released under FOO license except the code from http://developer.android.com Jan 26 12:55:01 /google/play/expansion-files.html that is released under BAR license"? Jan 26 13:03:00 danijoo, is the NotificationCompat.Builder also a good choice ? Jan 26 13:03:10 yes Jan 26 13:05:50 meh still no pop up :/ Jan 26 13:06:09 show your current code Jan 26 13:06:41 http://pastebin.com/73FHY9CH Jan 26 13:07:13 not notify Jan 26 13:07:23 use startForground Jan 26 13:07:45 see http://developer.android.com/reference/android/app/Service.html#startForeground(int, android.app.Notification) Jan 26 13:08:21 if you just post it, the notification is not attached to the service Jan 26 13:09:40 Must still be doing something wrong, mplicit intents with startService are not safe: Intent { act=com.example.dries.littlechef.MyService (has extras) } android.content.ContextWrapper.startService:506 com.example.dries.littlechef.Kitchen.onAddNewClicked:138 java.lang.reflect.Method.invokeNative:-2, doesn't mean it stops right ? Jan 26 13:10:38 hyrixo, make the intent explicit. Jan 26 13:11:21 Intent serviceIntent = new Intent(context, MyService.class); Jan 26 13:14:52 didn't do it unfortunatelty Jan 26 13:14:52 anyone tried buck with some bigger project? I mean 65k limit Jan 26 13:14:55 beside facebook Jan 26 13:15:10 gordon_, need to split dex then Jan 26 13:15:25 hyrixo, did you do the rest of the stuff i wrote? Jan 26 13:16:16 danijoo: I tried multidex plugin but it doesnt seem to work Jan 26 13:16:30 never did it, sry Jan 26 13:16:47 danijoo, i put it in oncreate(), used a new NotificationCompat.Builder(this), i use startForeground(foodID,myNotification) and i do the explicit intent Jan 26 13:17:19 did you change the return value of onStartCommand ? Jan 26 13:17:36 Yes to START_STICKY Jan 26 13:18:08 have you checked if all those methods run correctly by attaching a debugger? Jan 26 13:18:25 Can look at it Jan 26 13:19:39 I'm having a mediaplayer in a service and I'm getting this Error (1,-2147483648) someone an idea? Jan 26 13:23:42 danijoo, my oncreate function gets called so and never again so i have the feeling he starts it but i can't cancel it so ye :/ Jan 26 13:24:40 what do you mean with "you cant cancel it"? Jan 26 13:25:06 Well i can't dismiss it since it doesnt pop up Jan 26 13:25:19 show your code again please. from the whole service Jan 26 13:27:03 kk sec Jan 26 13:27:57 danijoo, http://pastebin.com/8rZJDEYx Jan 26 13:29:12 hi everyone i am new to android what class can i use for a background work which will run while app is running Jan 26 13:29:14 pff.. how do i know what the latest versions for gradle and play services are? Jan 26 13:29:26 egedo: try IntentService Jan 26 13:29:31 hyrixo, you are throwing an exception in onBind...... Jan 26 13:29:53 can i get an image(jpg or anything) from contact list and send it with restful API ? Jan 26 13:29:53 Oh that was automatic generated Jan 26 13:29:54 return null; instead Jan 26 13:30:08 osxorgate: thx checking it right now Jan 26 13:31:02 danijoo, didn't do it Jan 26 13:31:39 If one includes code from http://developer.android.com/google/play/expansion-files.html in an app, and also "Google Play Licensing Library package" and "Google Play APK Expansion Library package", how does that work with licensing/copyright? Can I still release my project under whatever license I want to or how does it work? Do I write in the LICENSE that "all code is released under FOO license except the code from http://developer.android.com Jan 26 13:31:39 /google/play/expansion-files.html that is released under BAR license"? Jan 26 13:32:17 hyrixo, does the servie run and dont show a notification or does it not run at all? Jan 26 13:33:26 Well i get in the oncreate() function and i don't get in it anymore so i presume it's running Jan 26 13:34:21 danijoo, http://pastebin.com/f4iiEnK8 maybe this is wrong Jan 26 13:35:16 hyrixo, if you dont get in onCreate again after running it, it should be running Jan 26 13:37:39 osxorgate: intent service seems like a background function run, broadcast result and stop, what i want achieve is updating last known location with location listener while app is running Jan 26 13:38:28 egedo, then you register for location updates, and process them when the arrive Jan 26 13:38:38 egedo, use a normal service or an asynctask Jan 26 13:39:16 i get this error: Error:Android Gradle Build Target: org.gradle.tooling.GradleConnectionException: Could not execute build using Gradle installation '/Users/koolaid/.gradle/wrapper/dists/gradle-2.2.1-all/6dibv5rcnnqlfbq9klf8imrndn/gradle-2.2.1'. Now i wiped the /wrapper dir. How to fix? Jan 26 13:39:23 osxorgate, danijoo thx a lot Jan 26 13:39:34 but intent service seems fine too Jan 26 13:40:32 danijoo: i ll try with intent service if it stops listining i ll try service or asynctask Jan 26 13:40:50 danijoo: listening* Jan 26 13:41:00 egedo, it will stop. an intent is a one time job Jan 26 13:41:43 danijoo: ok then service it is thx again Jan 26 14:03:38 anybody could help me ? Jan 26 14:03:39 http://stackoverflow.com/questions/28150548/getting-user-date-from-facebook-session-android/28150643?noredirect=1#comment44673615_28150643 Jan 26 14:14:58 Hello how can I set an timeout for GPS Acquisition? Jan 26 14:15:43 soomsoom: why do you need a timeout? Jan 26 14:16:22 anyone know if downloads in china affect a ranking in non-chinese countries? Jan 26 14:16:25 alexfu: because not always Im inside, so I want to get coordinate from network when gps can't lock on sattelite Jan 26 14:16:39 **outside Jan 26 14:16:51 soomsoom, just start a timer and ignore the gps result if the timer is over Jan 26 14:17:15 soomsoom: fused location provider handles this for you Jan 26 14:17:20 fused? Jan 26 14:17:21 hey guys, gotto question. I can select speech-call in my car-navigation-system, which is connected via bluetooth with my phone and starts an activity "voice dialer" on my phone. I`d like to start this voice dialer programmatically just like my navi does, Jan 26 14:17:22 but i dont know how, since it is not a installed application. is this even possible ? Jan 26 14:18:02 soomsoom: it will determine the best way to obtain your location (i.e wifi/cell networks or gps) Jan 26 14:18:49 alexfu: so what is the difference between Fuse Location Proivder to getBestProivder()? Jan 26 14:21:28 hi guys. any recommendations for FSM implementations Jan 26 14:21:29 ? Jan 26 14:21:35 trying not to reinvent the wheel Jan 26 14:22:02 soomsoom: LocationManager.getBestProvider just returns the name of the best qualified provider to handle your needs. I would use LocationRequest to do the actual work. https://developer.android.com/training/location/receive-location-updates.html#location-request Jan 26 14:23:25 soomsoom: LocationRequest will use the FusedLocationProviderApi to get your location Jan 26 14:26:31 soomsoom: if you only need to grab location once, use http://developer.android.com/reference/android/location/LocationManager.html#requestSingleUpdate(android.location.Criteria, android.location.LocationListener, android.os.Looper) Jan 26 14:30:51 alexfu: thanks :D Jan 26 14:35:51 Hello Jan 26 14:36:16 Noob question... how can I open the R.java file in Android Studio? Jan 26 14:40:20 oscarb92: it should be under build/generated/source/r Jan 26 14:41:05 why would you need R.java Jan 26 14:41:14 oscarb92: easier way is probably to just do a search for R.java using double shift key stroke Jan 26 14:42:51 so, im thinking of using this state machine as a starting point: https://android.googlesource.com/platform/frameworks/base/+/9a7debe5857ffc7c71cfc4082b1b6d72a5cf81cd/core/java/com/android/internal/util/StateMachine.java Jan 26 14:44:10 and i’d like to use the msg.obj to pass items to new states Jan 26 14:48:58 i decide that i will postpone new android app project till reading http://docs.oracle.com/javase/tutorial/. Jan 26 14:57:08 Can someone please help me understand how Im allowed to reuse code found in http://developer.android.com/google/play/expansion-files.html ? That is, what and how is attribution needed, how can I license my whole project which includes the code snippets etc Jan 26 15:03:42 <_genuser_> hey guys, how do you guys track bugs? any bug tracking software that you use? will do my own research. just looking for some names that are being used so they'd be more relevant. Jan 26 15:05:49 _genuser_, I use Mantis Jan 26 15:10:59 Hi, how can i get a reference of the parent object in an anonymous class? Jan 26 15:11:47 soulisson, Class.this Jan 26 15:11:49 soulisson: SomeClass.this Jan 26 15:12:41 Ok, thanks :) Jan 26 15:15:44 I have an absolute bare-bones NativeActivity that's just trying to get to a single Java class through the JNI but the jni->FindClass is failing no matter what i do. Calling FindClass on something like "android/os/Environment" however works just fine. Any ideas? Jan 26 15:16:19 Intent intent = new Intent("android.intent.action.VOICE_COMMAND"); intent.addCategory("android.intent.category.DEFAULT"); lets me select between google search and voice dialer. Jan 26 15:16:20 Has anyone an idea how to make it possible to always launch voice dialer directly? Jan 26 15:19:02 adkins: you mean the default phone app? Jan 26 15:19:11 to make phone calls Jan 26 15:19:25 alexfu: voice dialer Jan 26 15:19:40 adkins: you're going to have to be more specific Jan 26 15:20:25 <_genuser_> FlipBill: thanks. googling now. Jan 26 15:20:32 <_genuser_> mantis Jan 26 15:21:32 Only one I've ever used, so i can't comment about relative value. Jan 26 15:22:01 if "setNavigationMode(NAVIGATION_MODE_LIST)" is deprecated, what is the recommended UI pattern to achieve the same result (i.e. a spinner for filtering in the ActionBar)? Jan 26 15:22:04 <_genuser_> FlipBill: no, that's good. We're using excel sheets, and multiple devs are sending it back with their commetns and the PM is having to consolidate them. Jan 26 15:22:06 alexfu: well i cant say more than that. If you launch that intent, an picker gets opened and you can choose the voice dialer. its not the default phone app, its the voice dialer activity Jan 26 15:22:16 <_genuser_> FlipBill: and it's a huge mess. and teh customer isn't even reading the comments. Jan 26 15:22:41 adkins: voice dialer meaning.. the phone app where you make phone calls? Jan 26 15:22:42 Would like tighter integration with VCS, but I'm too lazy to use it well. Jan 26 15:22:51 alexfu: it looks like this http://androidspin.com/wp-content/uploads/2013/02/Google-Now-Voice-Dialer.png Jan 26 15:23:03 _genuser_, you'll find Mantis a vast improvement over that Jan 26 15:23:24 A little baroque, but logical Jan 26 15:24:33 <_genuser_> FlipBill: heh, the problem is testers are regular workers and they're not even IT workers. they're just saying stuff like, "this didn't let me do this". no logs, no description, no steps to replicate. just bam. Jan 26 15:24:44 <_genuser_> FlipBill: educating them on use of a issue tracking tool will be a task too. :) Jan 26 15:25:55 _genuser_, it might be the structure needed to impose appropriate discipline Jan 26 15:26:03 or it might just piss 'em off Jan 26 15:26:16 <_genuser_> FlipBill: IkR? that's why I suggested an issue tracker this morning. Jan 26 15:26:50 <_genuser_> FlipBill: however, problem is: we have to find a webserver, deploy it on the server, then poke a hole thru the firewall to let only the customer access it. Jan 26 15:26:50 I suspect most people would appreciate the convenience of the structure it provides. Jan 26 15:26:59 <_genuser_> and all that will require IT support, etc and lot of time wasted. Jan 26 15:27:28 <_genuser_> I know all the devs and PM will appreciate the structure. because now the PM has to comb thru all the excel spreadsheets and generate a cleaned up version and send to customer PM everyday. Jan 26 15:27:46 <_genuser_> and the customer PM doesn't read it at all because who has the time to read thru 200+ rows and read the newly added comments in each. Jan 26 15:27:55 I work alone. So I can conjure a VM and throw something together anywhere in less than an hour. Jan 26 15:27:58 adkins: only way to really get a specific app to launch via an Intent is if you know the exact package name of the app you want to launch or just select the one you want from the dialog and set it as default. Jan 26 15:28:27 <_genuser_> FlipBill: yeah, for my own bugs, I'll just track them in a notepad file. because I'll typically fix them as soon as I see them. Jan 26 15:28:34 _genuser_, Mantis supports subscriptions and assignments and email notifications. Jan 26 15:28:35 adkins: the latter is a much better approach. users may have multiple apps that can accept voice commands Jan 26 15:28:44 <_genuser_> FlipBill: because I won't even release it with any bugs that I nkow of. Jan 26 15:29:00 which I suppose is de rigeur for this type of tool. Jan 26 15:29:07 <_genuser_> FlipBill: yeah, I like bug assignment, because you can immediately toss it back to the tester and say (logs needed)> Jan 26 15:29:26 <_genuser_> which makes it easy for their manager to log in and check up on and say hey vendor is waiting on you. Jan 26 15:38:14 please, anybody could help me with this how to ? Jan 26 15:38:15 http://www.rahuljiresal.com/2014/03/facebook-login-for-android-without-loginbutton/ Jan 26 15:38:18 ?? Jan 26 16:35:45 can someone help me understand the answer to this question http://stackoverflow.com/questions/5444355/android-listview-with-checkbox-problem Jan 26 16:46:29 samsamsam, what part of the explanation is not clear? Jan 26 16:53:14 trying to follow the android documentation for bluetooth and their example shows "startActivityForResult(enableBtIntent, REQUEST_ENABLE_BT); <-- REQUEST_ENABLE_BT does not exist... what am i missing? Jan 26 16:53:52 You haven't defined a REQUEST_ENABLE_BT variable Jan 26 16:54:01 neither does their example code Jan 26 16:54:42 how am i supposed to know what value its supposed to have? or do i just make it any value i want SomeStupidRandomNumber() Jan 26 16:55:02 Is it a complete and runnable example, or just a code snippet? Jan 26 16:55:23 Read up on how startActivityForResult works, and what the second parameter is Jan 26 16:55:26 maybe I will have more luck now. anyone has done facebook integration before? I got this problem: http://stackoverflow.com/questions/28137099/facebook-android-photo-upload-application-link Jan 26 16:55:56 thats the problem with google example code. they either give you a full blown multi tasking multi player networked space invaders game with sprites, music and sound effects and an online high score just to show how to do sprites or... they give you 95% of the example and expect you to "just know" Jan 26 16:56:21 Can someone please help me understand how Im allowed to reuse code found in http://developer.android.com/google/play/expansion-files.html ? That is, what and how is attribution needed, how can I license my whole project which includes the code snippets etc Jan 26 16:56:29 You should have encountered startActivityForResult when going through the training docs Jan 26 16:56:52 googles docs are shit read above comment Jan 26 16:57:42 i know what the second parameter is, its the request code. what i was asking was where is this code defined Jan 26 16:57:52 or... do i just make it up Jan 26 16:59:41 I have a verbose question about beginning dev and IDEs here: http://pastebin.com/dw21VH2J Jan 26 17:00:27 Java and Android Studio Jan 26 17:01:05 hey folks. i'm currently having performance problems with a custom arrayadapter in my application. in it, i am accessing thumbnail images that may need to be downloaded. in the adapter Jan 26 17:01:10 Hi Jan 26 17:01:22 someone could help me to fix a bootloop using adb? Jan 26 17:01:23 thanks Jan 26 17:01:49 pablq: are you using Picasso or something else designed to do thumbnails in listviews? Jan 26 17:02:07 newbQ, Without editorializing about its merits relative to alternatives, I would say Android Studio is what you should use. By default. Jan 26 17:02:16 rats Jan 26 17:02:19 Period. Jan 26 17:02:29 we were supposed to change Volley to Picasso Jan 26 17:02:34 didn't happen Jan 26 17:02:37 's "getView()" method i'm checking for the existence of the thumbs and if they do not exist i download them using a custom asynctask. in the asynctask's "onPostExecute()" i call notifyDataSetChanged... but for my longer listviews the performance is terrible. Jan 26 17:02:54 s73v3r: nope. just vanilla android. Jan 26 17:02:57 I am not android developper, Simply my phone stop of work with a bootloop Jan 26 17:03:08 s73v3r, FlipBill: stick with AS? alright. thanks for the advice Jan 26 17:03:22 the easiest way to fix it would be to use Picasso to handle downloading of the images Jan 26 17:03:25 where I should implement method for refreshing textview in fragment inside viewpager ? I have done onPageSelected() but fragment doesn't refresh propertly Jan 26 17:03:37 The_Photographer, #android-root Jan 26 17:03:48 pfn: thanks sir Jan 26 17:03:49 but either way, you should not be using notifyDataSetChanged Jan 26 17:04:15 newbQ, Maybe not the answer you wanted, but that's my opinion if you are new to this stuff. Jan 26 17:04:22 Your adapter is having to redo all of the cells on screen, regardless of if they’re in the middle of downloading, or have already downloaded Jan 26 17:04:47 FlipBill: I'm new to android, not so new to programming in general Jan 26 17:04:52 s73v3r: yeah i'm realizing notifyDataSetChanged is problematic... i imagine i'm getting duplicate download tasks when that's called. Jan 26 17:05:01 right Jan 26 17:05:16 so how can i just update the particular cell with the thumbnail? Jan 26 17:05:41 newbQ, I hear ya. Nice to be able to use the tools we know. But Android is complex, and there is Jan 26 17:05:56 a lot of stuff to lean on in AS. And it's google's Thing Jan 26 17:06:15 you need to give the async task a reference to the imageview in the cell, and set it’s image in onPostExecute. Jan 26 17:06:25 You don't want to fight too many battles at once. Jan 26 17:06:35 However, you also need to keep track of what URL has just been downloaded, and what URL the cell is currently expecting Jan 26 17:07:16 cause if you fling down the list, cells that may not have finished their downloading will be recycled. and if you don’t check before you set the imageview’s image, you could be putting the wrong image in the wrong cell Jan 26 17:09:23 If I want to match two images within my app, is there some code i can use to do that or is it something I'd have to code myself? Jan 26 17:09:40 some way to fix my bootloop using adb? Jan 26 17:10:16 s73v3r: thanks. yeah i was afraid that would be the case. i was hoping to keep my asynctask as generic as possible Jan 26 17:10:19 how'd you bootloop with your android app? Jan 26 17:11:30 anyone know what happened with the gradle-retrolambda plugin? 2.4.1 seems to not be available anymore... Jan 26 17:11:36 Quick question, if I pass a ListView to a registerForContextMenu() will the onCreateContextMenu be called on long click of a list item? Jan 26 17:12:30 s73v3r: thanks. Jan 26 17:13:10 Any image downloading async task is going to need a reference to the view Jan 26 17:13:33 FlipBill: how important is the minimum screen resolution for AS? Jan 26 17:15:05 have more screen :p Jan 26 17:15:21 i'm stuck with my laptop at the moment Jan 26 17:18:04 I've got 1280x768, i think. and AS says it's min is 1280x800. that wont be a big issue, will it? Jan 26 17:19:02 not really, no Jan 26 17:19:06 but 1280x800, how shitty Jan 26 17:20:33 my laptop is 4 years old and still working well. sort of. I just need to throttle the cpu 50% so it doesnt overheat the battery and cut power randomly. Jan 26 17:27:01 Can someone please help me understand how Im allowed to reuse code found in http://developer.android.com/google/play/expansion-files.html ? That is, what and how is attribution needed, how can I license my whole project which includes the code snippets etc Jan 26 17:28:04 google doesn't care Jan 26 17:29:42 LVL... what a joke in terms of security Jan 26 17:29:59 it annoys more the user than protect anything :((( Jan 26 17:30:06 has never been fixed in yearsss Jan 26 17:30:10 Jan 26 17:30:21 I believe they’re all Apache licensed snippets, so you’re free to use them without attribution Jan 26 17:31:52 And if it’s the sample snippets that tell you how to do something, like your link, you’re kinda expected to use them more or less verbatim. So no attribution or any special licensing needed Jan 26 17:32:58 s73v3r: Are you sure about this? I got OCD and shit but I sure don't want to get in trouble with getting some letters from lawyers and shit later Jan 26 17:33:25 I've been thinking about this so much geting confused that I've considered just dropping/abandoning my project Jan 26 17:33:27 O_O Jan 26 17:33:31 jesperj: Dude. Jan 26 17:33:37 You're that guy from two weeks ago, right? Jan 26 17:33:40 lol Jan 26 17:33:42 I am Jan 26 17:33:44 <_< Jan 26 17:33:51 Seriously? Quit being a baby Jan 26 17:33:58 Are you asking about Android code or SO code this time? Jan 26 17:34:05 s/Android code/Android sample code/ Jan 26 17:34:11 http://developer.android.com/google/play/expansion-files.html code Jan 26 17:34:31 s73v3r: meh. That's not helpful. Jan 26 17:34:34 the entire purpose of the code is to show you how to use it. It would be incredibly difficult to do anything with Android if all the examples showing you how to use them were unable to be used Jan 26 17:35:00 jesper listen, you dont just suddenly end up in court one day, so forgetting that you are free to use this code as you wish for a second... relax Jan 26 17:35:17 jesperj: You're seriously considering dropping a project over an obsession relating to sample code? Jan 26 17:35:20 it’s not helpful because you’re too scared to realize you’re just making excuses for why you’re not doing anything Jan 26 17:35:29 TacticalJoke: I'm fucking nuts. Jan 26 17:35:32 jesperj: Yes. Jan 26 17:35:34 right now i'm jacking some AOSP code for ItemDecoration Jan 26 17:35:38 yes, you’re nuts Jan 26 17:35:40 You should just stop worrying about this. You're being ridiculous. Jan 26 17:35:57 you need to get sued so you understand how it works Jan 26 17:36:01 then you will chill Jan 26 17:36:20 jesperj: If you were at any risk at all (which is *ludicrous*) then basically every Android programmer would be too. Jan 26 17:36:38 Your brain is hooking onto something that's stupid. Jan 26 17:36:41 If you’re really that scared, go hire an IP lawyer to answer the question for you Jan 26 17:36:57 or hire one when you (don't) get a letter Jan 26 17:37:03 why pay a pawyer now Jan 26 17:37:05 *lawyer Jan 26 17:38:15 Right. But what for example about licensing... I license my project code under MIT in LICENSE.txt... don't I need to mention that the tutorial code snippets are under apache 2.0? Jan 26 17:38:19 Not trying to be mean. Just giving you a reality check because you've been worrying about this for at least nine days. Jan 26 17:38:44 jesperj, normally you have to include the NOTICE if one is provided in the stuff you borrow Jan 26 17:38:51 If you think this last question is just stupid too then I'll seriously consider taking a break for a month or two and see if I'll be saner then. Jan 26 17:38:51 usually in "about" is a good place Jan 26 17:39:13 if you just include the gradle dependency, you dont provide that extension code at all Jan 26 17:39:23 you just give a link to it. so no licensing problem :0 Jan 26 17:39:34 TacticalJoke: bienvenida Jan 26 17:39:38 sabton: if he’s this scared and paranoid, he’d want a lawyer now to tell him that there’s nothing to be scared of Jan 26 17:39:51 jesperj, you're pretty safe with apache 2, and it's good to include attribution even when it's not required, so just include it to be "better safe than sorry" Jan 26 17:40:08 also, why should google care. every project that uses their libraries help on the way to world domination :p Jan 26 17:41:22 jesperj: It boils down to this: do you want to work on this project? If so, you'll have to find a way around this insanity. If not, give in to it. Jan 26 17:41:29 yeah. and something's only illegal if you get caught Jan 26 17:42:02 Levite: that’s terrible advice Jan 26 17:42:34 ok strike that Jan 26 17:42:53 TacticalJoke: It's true, I have. I'm really not doing it for fun or because I have a choice though. I can choose to try to combat my OCD and paranoia and try to figure it out and release my project, or just stop working on it. Since I'm sane enough to not want the crazy part of me win, I've been trying to choose to work on it and release it. Jan 26 17:43:26 is this, like an app where you periodically press a button three times? Jan 26 17:43:38 I really don't ask the questions I ask to be annoying, trolling, or because I think it's fun. It's genuine concerns I have. Jan 26 17:43:41 Thanks for the input. Jan 26 17:43:47 I know. Jan 26 17:44:33 It's just a shame if the OCD wins. Nothing is achieved there. It's irrational. Jan 26 17:45:39 sup TacticalJoke Jan 26 17:45:59 Hey, drose379. Jan 26 17:46:07 hows it going Jan 26 17:46:22 Pretty well but I have a horrible virus. You? Jan 26 17:46:58 Health virus or computer? Jan 26 17:47:25 Health. Jan 26 17:48:38 ah, sorry to hear that Jan 26 17:49:19 so im overriding onCreateContextMenu Jan 26 17:49:29 Where is that method coming from? Which class? Jan 26 17:49:43 for a "good" domain service hostgator is surprisingly annoying Jan 26 17:57:20 What I don't understand though is how it's ok to reuse code that was released under apache 2.0, and then license the whole project under for example MIT. How can it be ok to put the sample code I've borrowed under whatever license _I_ choose? Jan 26 17:57:29 drose379: When you call Activity.registerForContextMenu(View view), the activity register itself as a listener to the View's on-create-context-menu event. This means that the View calls your onCreateContextMenu override when it needs to build its context menu. Jan 26 17:57:43 ask a lawyer Jan 26 17:58:21 Got it TacticalJoke,thanks Jan 26 17:59:36 TacticalJoke and when I call super() in onContextItemSelected that will be using the construct from what? Jan 26 18:02:23 drose379: That calls Activity.onContextItemSelected: https://android.googlesource.com/platform/frameworks/base/+/refs/heads/master/core/java/android/app/Activity.java#3229 Jan 26 18:02:31 Not sure whether you need to call super(). Jan 26 18:03:12 I guess in the switch statement in the default: I need super.onContextItemSelected Jan 26 18:03:16 hi guys. would anyone care to take me through pros/cons of robospice/volley spring/google-http-java-client/retrofit . there’s a lot going on here! Jan 26 18:03:24 retrofit++ Jan 26 18:03:40 i say that as a totally unbiased bystander with no vested interest Jan 26 18:03:55 :P Jan 26 18:04:20 on iOS, i’ve been using AFNetworking Jan 26 18:04:37 drose379: Yeah, you could. Or you could just say "return false;" for, I think, the same effect. Jan 26 18:04:40 I only have experience with Retrofit and Volley. Either one of them would be fine, but they both have different aims Jan 26 18:04:49 I guess calling through to the superclass method looks nice and consistent. Jan 26 18:04:53 Volley is more heavyweight than Retrofit, but it also does more. Jan 26 18:05:02 JakeWharton: does retrofit need something like Robospice under it? Jan 26 18:05:02 Thanks TacticalJoke Jan 26 18:05:17 samskiter: no. Robospice actually sits on top of Retrofit Jan 26 18:05:39 Only thing I don't understand about that code is why it conditionally says "mParent.onContextItemSelected(item);". Not sure what a parent activity would have to do with context-menu handling. Jan 26 18:06:44 JakeWharton: how does auth fit into these libraries? Jan 26 18:06:59 retrofit has a callback for every request that you can add headers to Jan 26 18:07:18 ok and how can i deal with retries with a refresh token Jan 26 18:07:41 that's better handled with a smart HTTP client like OkHttp which would sit underneath Retrofit Jan 26 18:10:08 JakeWharton: so im a little confused that robospice sits on top of retrofit Jan 26 18:10:21 (and i’m not sure what it get’s me) Jan 26 18:10:28 me neither. i've never used it. Jan 26 18:13:21 Is there a way to check which item created the context menu in a listview Jan 26 18:15:18 a list view has no "context menu" Jan 26 18:15:31 JakeWharton: a lot to take in… Jan 26 18:15:43 i like the idea of robospice running things on a service. Jan 26 18:15:45 I have a listview of items, and each of those items can create a context menu Jan 26 18:16:45 tag it with the item position Jan 26 18:17:01 what do you mean Jan 26 18:17:10 setTag() Jan 26 18:17:11 Im using registerForContextMenu(Listview) Jan 26 18:17:31 Where would I set tag Jan 26 18:18:40 drose379: AdapterView.AdapterContextMenuInfo info = (AdapterView.AdapterContextMenuInfo) item.getMenuInfo(); doSomethingWith(info.position); Jan 26 18:19:18 wait what Jan 26 18:19:25 I have ContextMenu.ContextMenuInfo Jan 26 18:20:01 You have to cast it to the implementing class to get the 'info' property. Jan 26 18:20:08 position* Jan 26 18:20:22 so AdapterView.ContextmenuInfo Jan 26 18:20:22 It's kinda ugly. Jan 26 18:21:28 Ill try to figure it out :) Jan 26 18:22:55 JakeWharton: last question - can JSON validation be done in retrofit? (it seems like the right place in the heirachy) Jan 26 18:23:02 drose379: Did you see my paste above? Jan 26 18:23:06 Yes Jan 26 18:23:12 samskiter: validation how? Retrofit delegates to Gson for all serialization/deserialization Jan 26 18:23:26 which will throw exceptions on malformed or invalid JSON Jan 26 18:23:27 JakeWharton: json scheme Jan 26 18:23:37 schema* Jan 26 18:23:48 so validating JSON against a schema Jan 26 18:24:26 Is there a library to enforce such a thing? Jan 26 18:24:30 yes Jan 26 18:24:32 Gson will enforce structure and types for free Jan 26 18:24:34 json-schema Jan 26 18:24:41 https://github.com/fge/json-schema-validator here is a json implementation Jan 26 18:24:49 java* Jan 26 18:25:01 Retrofit is completely agnostic to the mechanism you use to convert the HTTP body to Java objects and it'll fully pluggable. Jan 26 18:25:10 So while it doesn't support that natively, it shouldn't be hard to make it work. Jan 26 18:25:56 eh.. I really have no idea. will spam you again - sorry. Anyone know the answer for this: http://stackoverflow.com/questions/28137099/facebook-android-photo-upload-application-link guess that topic was buried under other ones Jan 26 18:26:04 JakeWharton: thanks. i’ll try and fit it in if i use retrofit. i find json validation a useful thing to have to prevent paranoid coding :) Jan 26 18:26:08 huh, facebook lite is a webview app Jan 26 18:26:19 TacticalJoke so I need the list Jan 26 18:26:24 in order to use the position Jan 26 18:26:31 Yes. Jan 26 18:26:45 g00s: got link to apk ? Jan 26 18:26:51 You should probably have the list in any case. Jan 26 18:27:04 Should it be a private property so the whole class can use it? Jan 26 18:27:15 gordon_ i dont use fb, but read it here http://www.androidpolice.com/2015/01/26/apk-download-facebook-launches-facebook-lite-android-app-for-low-power-devices-and-developing-markets/ Jan 26 18:27:57 ah ok. thought you have the apk (guys wanted to check it - we have some users over there too) Jan 26 18:28:59 I guess you could also use the adapter (with 'getItem'), but IMO that's not always a good idea. Jan 26 18:29:06 Depends, I guess. Jan 26 18:29:29 An example of that being a bad idea (IMO, anyway) is when the adapter is dealing with multiple view types. Jan 26 18:29:38 Here, lemme show you what I wrote Jan 26 18:30:04 im a recent convert to AS, can someone direct me in creating a library project? The only tutorials i can find on it seem to be outdated and not relevant for as 1.X Jan 26 18:30:18 http://pastie.org/9862896 TacticalJoke Jan 26 18:30:38 Yeah, that's the kinda thing. Jan 26 18:31:21 jcase, just create a module and put "apply plugin: 'com.android.library' Jan 26 18:31:22 " in its respective build.gradle Jan 26 18:31:27 Hi. Is there a chart of video memory available to phones Jan 26 18:32:04 jcase, when it's not a library but let's say an application, there is "apply plugin: 'com.android.application'" instead Jan 26 18:32:08 plugin for library ? Jan 26 18:32:11 that's interesting Jan 26 18:32:15 hmm Jan 26 18:32:19 yes this seems odd Jan 26 18:32:24 ok thanks Jan 26 18:32:34 and this will build? Jan 26 18:32:45 and i can distribute it as a standalone dex to drop in as a library? Jan 26 18:33:00 this will build, no clue for the standalone dex to drop as in Jan 26 18:33:09 ah Jan 26 18:33:13 hmm Jan 26 18:33:39 too old to learn AS, to busy to retool, sigh Jan 26 18:33:40 thanks Jan 26 18:33:54 it generates a .aar in output Jan 26 18:35:01 aar is a zip it loks like Jan 26 18:35:12 with jar, and some other bits in it Jan 26 18:35:17 yes! Jan 26 18:35:29 hmm not going to work Jan 26 18:35:43 ill jsut convert to a dex Jan 26 18:35:43 isnt jar a zip too? Jan 26 18:35:52 danijoo, yes Jan 26 18:35:56 http://tools.android.com/tech-docs/new-build-system/aar-format Jan 26 18:36:10 and so is a apk, and a zip is a zip as well Jan 26 18:36:20 maybe with jack and jill there is a way to get the dex (https://www.saikoa.com/blog/the_upcoming_jack_and_jill_compilers_in_android) but I never tried jack & jill yet, and I know nobody who tried too :) Jan 26 18:36:25 a zip is one, too ??? Jan 26 18:36:30 :p Jan 26 18:37:23 anyone who works from their home, how do you deal with the google play address requirement now? a UPS box? Jan 26 18:37:39 i put my home address in there Jan 26 18:37:44 and nobody cares about it. Jan 26 18:37:57 fakey, use a registered agent Jan 26 18:38:05 and list their address Jan 26 18:39:11 danijoo i thought about that but i'm afeared.. Jan 26 18:39:25 just move somewhere where you cant be visited :p Jan 26 18:39:28 jcase also thought about that too but haven't looked into it yet. can they be relatively cheap? Jan 26 18:40:10 hah yeah let me just move to some bunker so i can publish a paid app... Jan 26 18:40:12 depends what relatively is, we have to have one since our LLC is out of state Jan 26 18:40:51 relatively as in for someone who is doing this mostly as a hobby without much money to spend. or compared to a UPS box Jan 26 18:40:51 fakey, what is your main concern with publishing "your" address? Jan 26 18:41:10 adq, i know my concern is that we have gotten threats, and loonies Jan 26 18:41:21 it depends on your market, if you publish anythign security related Jan 26 18:41:21 yeah but you're a special case, jcase :) Jan 26 18:41:23 you get nut cases Jan 26 18:41:33 exactly Jan 26 18:41:35 adq, there was a blog entry once about somebody who actually got chased by a user because of some weird shit Jan 26 18:42:14 adq, ive gotten countless loonies, 2 death threats, and a couple stalkers Jan 26 18:42:20 I don't like the idea of people having my home address. Not only could they visit, but they could pretend to be me (having my full name and address). Jan 26 18:42:25 just use a post office box maybe, it's probably the cheapest Jan 26 18:42:35 jcase, lol crazyness :/ Jan 26 18:42:39 indeed Jan 26 18:42:46 jcase: Stalkers who turned up at your home? Jan 26 18:42:47 adq, if you put a postbox, you can as well just put nothing in it Jan 26 18:42:57 TacticalJoke, no, but calling phone numbers etc Jan 26 18:42:59 they want to stop you from releasing sploits ;) Jan 26 18:43:04 because post boxes arent permitted. Jan 26 18:43:08 or worst, stole them Jan 26 18:43:40 s/stole/steal/ Jan 26 18:43:42 danijoo, $45yr I have a phuysical non pobox address in town Jan 26 18:43:55 im sure they can be gotten cheaper too Jan 26 18:43:58 Did you guys see this on reddit? http://www.reddit.com/r/Android/comments/2tpjep/the_new_step_by_step_guide_detailing_how_to_get/co16039 Jan 26 18:43:59 go to mom and pop mail stores Jan 26 18:44:04 I swear that /r/Android is a mini-cult. Jan 26 18:44:05 danijoo, oops i did not know Jan 26 18:44:07 out "Office" isntead of PMB Jan 26 18:44:23 I don't get it; the guy tells them to say happy birthday to a stranger and they all do? What's going on there? Jan 26 18:44:42 TacticalJoke getMenuInfo isnt working Jan 26 18:44:44 anyone here ever used PhoneGrap? Jan 26 18:44:47 just regular internet TacticalJoke, i will nto even open the link Jan 26 18:44:47 PhoneGap* Jan 26 18:45:17 http://i.imgur.com/XcI8ITe.jpg Jan 26 18:45:18 Also, that post sounds like it's written by someone who doesn't know much about programming. Jan 26 18:46:05 danijoo: The line about PO Boxes not being permitted has been disproven time and again Jan 26 18:46:32 s73v3r, what do you mean with disproven? Jan 26 18:46:52 hi there Jan 26 18:46:53 https://code.google.com/p/android-developer-preview/issues/detail?id=1340 related to address Jan 26 18:47:06 as in, people have registered with UPS boxes and USPS boxes, and have had no issues Jan 26 18:47:06 jcase what did you use for a physical address for $45 a year? Jan 26 18:47:19 is it possible to attach a menu to a toolbar situated in an upper level to current fragment? Jan 26 18:47:22 mom and pop mailing store Jan 26 18:47:26 TacticalJoke so getMenuInfo gets the "extra info" related to this menu item Jan 26 18:47:30 I mean take for example a tab layout Jan 26 18:47:49 s73v3r, yes but If you are unlucky, they can shut your account down because of that Jan 26 18:48:00 i dont say they do, I just say its clearly against their TOS Jan 26 18:48:00 show one example of that happening Jan 26 18:48:02 I think so. What's not working? Jan 26 18:48:21 A UPS box is considered a physical address. Jan 26 18:48:28 Getting a null pointed exception Jan 26 18:48:42 yes they wrote down that boxes are not ok. Jan 26 18:48:45 pointed Jan 26 18:48:48 pointer Jan 26 18:49:03 i think the real issue is EU laws instead of google Jan 26 18:49:10 Is 'list' null? Jan 26 18:49:24 fakey, I think eu laws allow boxes. Jan 26 18:49:42 TacticalJoke I think info.position is null Jan 26 18:49:50 p.o. boxes? Jan 26 18:49:56 Because im using the same list in an above method and it works fine Jan 26 18:50:01 yeah. Jan 26 18:50:04 you’re gonna have to point out where they’ve specifically said these things are not allowed Jan 26 18:50:17 'position' is an int. It can't be null. Jan 26 18:50:23 s73v3r, no. i dont have to :p Jan 26 18:50:24 TacticalJoke should i test that by just passing 3 into there Jan 26 18:50:29 Try using Log.i. Jan 26 18:50:33 Or the debugger. Jan 26 18:50:34 then stop spreading lies Jan 26 18:50:37 because im not in the mood to read that stuff again. but i remember it. :) Jan 26 18:50:46 if you want to see it, read the tos Jan 26 18:51:27 I’m not the one making the assertion Jan 26 18:52:34 TacticalJoke if I just pass a number into list.get() instead of list.get(info.position) it works Jan 26 18:52:34 s73v3r, there you go: https://support.google.com/business/answer/3038177?hl=en Jan 26 18:52:44 it's very ambiguous (law typical?), cause somehow a po box has a real physical address to receive the mail and store it lol Jan 26 18:52:46 TacticalJoke so its info.position giving a problem Jan 26 18:53:07 That’s for Google+ Jan 26 18:53:28 "Use a precise, accurate address to describe your business location. PO Boxes or mailboxes located at remote locations are not acceptable." but it is stated. Jan 26 18:53:47 drose379: What does your "registerForContextMenu()" statement look like? Jan 26 18:54:01 For a completely different product Jan 26 18:54:41 s73v3r, read the article: http://www.androidauthority.com/po-boxes-google-play-529092/ Jan 26 18:54:46 TacticalJoke in a method above, I do registerForContextMenu(listview) Jan 26 18:54:51 but that is on a different listview Jan 26 18:54:58 not on the one I am using in this method Jan 26 18:55:04 They __look__ the smae Jan 26 18:55:05 same Jan 26 18:55:17 but different variable, that may be the problem Jan 26 18:55:20 It’s an opinion article that doesn’t answer any questions Jan 26 18:55:54 close your eyes if you like :) I'm tired of discussing and will get something to eat. cheers! Jan 26 18:56:01 drose379: I'm not sure, but I think you can call registerForContextMenu on both ListViews. Jan 26 18:56:06 adq, hi Jan 26 18:56:26 I’m not closing my eyes. I’ve looked at everything you’ve shown, and nothing actually states what you say it states Jan 26 18:56:31 Oh wait, there is only one listview Jan 26 18:57:03 registerForContextMenu(listview) Jan 26 18:57:58 Maybe post the whole Activity? Jan 26 18:58:06 Though I always feel weird about asking people to open-source their apps. :D Jan 26 18:58:13 Why? Jan 26 18:58:26 Why which? Jan 26 18:58:39 In general I don’t have a problem with it, but some clients have huge issues with it Jan 26 18:58:42 Why worried about open source Jan 26 18:58:48 TacticalJoke Jan 26 18:59:26 I guess some people might want help but they might not want to post all their code (or their whole Activity). Jan 26 18:59:33 Ill just paste the 3 methods im working with Jan 26 19:00:09 Check out onContextItemSelected Jan 26 19:00:10 http://pastie.org/9862953 Jan 26 19:04:25 See anything TacticalJoke? Jan 26 19:06:15 Hmm, not yet. Jan 26 19:06:20 the problem with most articles about the google play address and po boxes and all that, is that they were all written in september and I'm trying to find more recent details based on actual happenings since it's been put in place. Jan 26 19:06:24 Though your posting a runnable to the message queue looks totally wrong. Jan 26 19:06:46 Why are you calling View.post? Jan 26 19:07:23 Oh jeez there was a reason but now I forgot Jan 26 19:08:17 ohhh ok Jan 26 19:08:27 That method is called inside a onRespone method Jan 26 19:08:32 and onResponse runs on a background thread Jan 26 19:08:45 Therefore I would not be able to touch the views unless I used a runnable Jan 26 19:08:58 TacticalJoke Jan 26 19:10:43 why my mac doesnt recognize my HTC ONE anymore? adb cant find it even after i added the vendor to adb_usb.ini manually Jan 26 19:11:41 does it show up at all, or does anything happen? Check the USB cable if it doesn’t Jan 26 19:12:25 drose379: I think I'd try calling registerForContextMenu in onCreate. Jan 26 19:12:33 quick question- Can i contact to my webservice and update datas while application is not running ? (i made some research and i guess you can do it with alarms) Jan 26 19:12:34 I have no idea where to even find the EU law that states you need a physical address displayed publicly... Jan 26 19:13:14 Also, according to what you said you're doing stuff like calling Activity.findViewById in a background thread, which seems like a bad idea. Jan 26 19:13:25 I'd put that code in Runnable.run. Jan 26 19:13:53 In fact, Runnable.run could simply buildList (after modification). Jan 26 19:13:59 simply call* Jan 26 19:14:00 Does anyone know a proper cross platform development tool for Android / iOS? Or rather a feature comparison. Jan 26 19:14:29 Ok TacticalJoke Jan 26 19:14:31 thanks for looking Jan 26 19:14:46 Im gonna try to registerForContextMenu in onCreate Jan 26 19:14:58 Generally it's best to set up your UI in callbacks such as onCreate. Jan 26 19:15:07 Actually, I'd rather have a comparison of APIs supported by these applications. Jan 26 19:15:22 ^ yeah, I'd avoid findViewById as well. probably fine in practice, but it's possible it could change while it's finding. Jan 26 19:15:23 Then, when something like Callback.onSuccess runs it simply modifies state (state which has already been initially set up). Jan 26 19:16:00 Tobbi: the documentation mentions which versions methods were added in, and there are also API-level diffs for full lists Jan 26 19:16:02 groxx: Yeah, and all the multithreading nightmares relating to touching state from multiple threads are avoided. :) Jan 26 19:17:49 groxx: I am talking about third party cross platform apps for Android and iOS. Jan 26 19:17:54 anyone ? can i contact to my webservice and update datas while application is not running ? (i made some research and i guess you can do it with alarms) Jan 26 19:18:06 eeh, app development. Jan 26 19:18:20 Tobbi: Xamarin, Phonegap / Cordova, there are a few others Jan 26 19:18:20 sci-fi, use a Service Jan 26 19:19:07 groxx: Yup, I am looking for a feature comparison between those. Or rather: A comparison which one of those covers which kind of APIs. Jan 26 19:19:17 But it's okay if something like that doesn't exist. Jan 26 19:19:18 Most of us don’t use those Jan 26 19:19:20 okey thanks i just want to know if is possible or not.Because i heard ios doesnt support that Jan 26 19:19:29 I know. I wouldn't use those either. Jan 26 19:19:56 Tobbi: ah. not sure :) I'll let you know if I find anything, but I can't look too hard. Jan 26 19:20:29 sci-fi: iOS lets you set an alarm and update data. However, both iOS and Android highly recommend that you use push instead Jan 26 19:20:47 groxx: No problem. :-) Just for clarification: This is part of my bachelor thesis, and it's quite hard to get some decent information on that on the web. I already tried contacting the support of some of the apps, but most of them haven't replied yet. Jan 26 19:21:29 ha, good luck then :) don't suppose you've tried contacting the makers of cross-platform stuff? Jan 26 19:21:38 s73v3r: ty mate Jan 26 19:22:26 groxx: No, I haven't tried that yet. Not sure if it's very scientific, though Jan 26 19:23:11 Tobbi: probably not, no. but they might let you know the downsides of X that X won't want tell you about. Jan 26 19:23:17 Yeah, probably. Jan 26 19:23:23 I will have a look around. Jan 26 19:23:35 Tobbi: I haven't used any unfortunately, not much info I can provide Jan 26 19:24:03 Tobbi, what's your thesis subject? cause focusing on cordova, xamarin & co does not sound scientific at all too :) Jan 26 19:24:04 groxx: So, I am supposed to write a prototype of a new cross platform tool for a very small example. It's really quite interesting. Jan 26 19:24:12 ah Jan 26 19:24:42 adq: So, the intro is giving an overview over the different tools. Jan 26 19:26:07 good evening Jan 26 19:26:41 adq, any idea how the tell lint to STFU in AS? Jan 26 19:27:06 TacticalJoke: danijoo hi Jan 26 19:27:10 jcase, yes in the settings of AS, inspections Jan 26 19:27:30 jcase: if you click the lightbulb, it gives you the option to //noinspection [whatever], or disable it entirely Jan 26 19:27:32 you can use the search box in the settings too for quickly find occurence Jan 26 19:27:54 ah thanks! Jan 26 19:27:58 Hi. Jan 26 19:28:40 there are some weird stuff lint detects (eg easter egg) Jan 26 19:29:22 yeah :) easter egg specifically, it's mentioned in one of the "android developer backstage" podcasts. don't remember which one. Jan 26 19:29:33 adq, also detects some things you are not suppose to do, but technically work Jan 26 19:30:34 oo yeah Jan 26 19:32:05 groxx, can you reenable it? Jan 26 19:32:57 there is also this little head guy on bottom right for quickly enable/disable inspections (save cpu) Jan 26 19:33:14 ah nice Jan 26 19:33:42 jcase: yeah, though that requires preferences -> inspections -> find the one that's relevant :) Jan 26 19:33:51 yep got it thanks Jan 26 19:33:57 jcase + adq: there's also a "power save mode" that does something similar Jan 26 19:34:15 ahh indeed, also! 4 ways almost Jan 26 19:34:23 adq, any ideas? Jan 26 19:34:27 cristian_c, about?? Jan 26 19:34:34 yeah im on a moster of a bulid box, so not worried about saving that cpu lol Jan 26 19:34:38 worried about stuff compiling Jan 26 19:34:39 in AS Jan 26 19:34:59 idk about you, but I'm full of ideas Jan 26 19:35:04 droidbuilder-army ;) Jan 26 19:35:29 anyone here using PagerSlidingTabStrip? Jan 26 19:35:57 specifically https://github.com/jpardogo/PagerSlidingTabStrip Jan 26 19:36:17 adq, I've changed the manifest, but I can't get the permission from package manager yet Jan 26 19:37:58 explain a bit more, cause I have no idea what's your current issue Jan 26 19:38:30 drinfernoo: I'm still using astuetz's version, is that one better? Jan 26 19:38:51 shekibobo, jpardogo updated it with MD, but I can't get it to build Jan 26 19:39:01 cristian_c, if you're attempting to use a permission with a protection level of signature or signatureOrSystem, you cannot. Jan 26 19:39:15 adq, I've added two further permissions to the manifest Jan 26 19:39:32 including it from a local maven repo, and it builds fine, but "import com.astuetz.*;" gives me an error Jan 26 19:39:54 "unknown type or package" Jan 26 19:39:54 adq, READ_EXTERNAL_STORAGE and WRITE_EXTERNAL_STORAGE Jan 26 19:40:40 the error you mention has nothing to do with permission Jan 26 19:41:18 I think I don't have to worry about creating that MutableString class anymore; Jackson provides access to the underlying char[] it uses for string values. Jan 26 19:41:25 adq, ok, but what should I do to add the permission? Jan 26 19:41:32 cristian_c, example: Jan 26 19:41:39 So you can either let it create a String from this (involving a copy) or you can create your own StringBuilder from it (involving, again, just one copy). Jan 26 19:41:45 cristian_c, maybe you did not write the android.permission. Jan 26 19:42:05 cristian_c, http://developer.android.com/guide/topics/data/data-storage.html the doc, it should be straight-forward for these things Jan 26 19:44:10 adq, ok, I'm reading quickly that page , at the moment. I see uses-permission is needed instead to add a new permission element Jan 26 19:44:17 but maybe I'm wrong... Jan 26 19:44:24 TacticalJoke, how's your project going? Jan 26 19:45:03 cristian_c, idk if you're wrong, read the doc, it will be then done for ever and you will know what to do and what you're doing ;) Jan 26 19:45:08 It's going well. :) I'm itching to switch to Material Design so that I can (finally) start doing serious UI work. Jan 26 19:45:12 So far, I've just done the back-end. Jan 26 19:45:14 good luck, i'm going afk a bit Jan 26 19:45:31 Basically, I just waited to switch to Toolbar and so on before even bothering. Now I'm ready to do that (almost). Jan 26 19:45:37 TacticalJoke, ETA for your reddit client!? :p Jan 26 19:46:01 Maybe months. Not sure. :) Jan 26 19:46:05 :)) Jan 26 19:46:08 damn lol Jan 26 19:46:12 It's kinda annoying how long everything takes. Jan 26 19:46:24 I was checking out Reddit News, but nothing has switched me from reddit sync yet Jan 26 19:46:31 adq, I was talking about this: cristian_c, maybe you did not write the android.permission. Jan 26 19:46:42 RedReader is not bad, though it's kinda ugly lately. Jan 26 19:47:09 He recently did stuff such as removing progress bars (displaying "Connecting...", etc.) instead. A total UI downgrade, IMO. Jan 26 19:47:30 shekibobo, are you using it with the standard Holo or MD? Jan 26 19:48:00 I'm using the unforked version, so it's with holo Jan 26 19:48:07 TacticalJoke, I'm really loving some of the stuff in Reddit News, but it feels kind of clunky still Jan 26 19:48:22 gesture-based and lots of wasted space imo Jan 26 19:48:37 shekibobo, any idea why mine wouldn't want to import? Jan 26 19:48:39 Yeah, I like the general look. Jan 26 19:48:47 But, yeah, wasting space. Jan 26 19:49:03 drinfernoo: not really, it looks like the package name is still the same as the original Jan 26 19:49:05 Some of the animations don't help the UX. Jan 26 19:49:35 shekibobo, it is, but it seems like other people are using it fine lol Jan 26 19:49:59 TacticalJoke, I really like the "bubbles" on the comment pages that let you skim OP/gilded/etc Jan 26 19:51:42 Do you use those often? Just curious. Jan 26 19:53:37 what's the differens between startActivity vs startActivityForResult? Jan 26 19:54:37 iflista: the latter will return a result code, along with any data that you set, back to the activity that you called it from. Jan 26 19:55:08 startActivity calls startActivityForResult with -1. Jan 26 19:55:25 so startActivity can't return data? Jan 26 19:55:57 iflista: no. it will not trigger onActivityResult Jan 26 19:56:14 hmm, thanks alexfu Jan 26 19:56:49 TacticalJoke, I probably would if News was my daily Jan 26 20:02:08 but that's me idk about everyone else Jan 26 20:03:07 Yeah, I have mixed feelings about that feature. Smart but I find it fiddly. Jan 26 20:03:22 It seems hard to be inventive with touchscreens. Jan 26 20:05:26 if I don't "extend" from anything is a class just an Object? Jan 26 20:06:41 Yeah, if you don't say "extends Whatever" then you're just extending Object. Jan 26 20:07:09 https://a.pomf.se/aomzjd.mp4 wooo Jan 26 20:07:24 (yes, sfw etc) Jan 26 20:07:24 likewise, every class is an Object, regardless of whatever else it extends Jan 26 20:07:29 ty Jan 26 20:08:07 Moter8, what's it? lol Jan 26 20:08:38 the video is rather self-explanatory Jan 26 20:08:43 im following some videos Jan 26 20:09:13 ^ it's a materialy-drawer video, is indeed sfw :) Jan 26 20:10:09 I watched it, just curious if I was looking for something specific Jan 26 20:10:18 Moter8, whose videos? Jan 26 20:10:28 slidenerd's material app playlist Jan 26 20:10:51 they are rather difficult to follow though Jan 26 20:11:13 he changes the files off-screen sometimes and then you wonder why "context" does nothing for you Jan 26 20:11:25 but else it's great, he doesnt go in-depth into java Jan 26 20:12:12 I kinda like SlideNerd. People on YouTube usually don't have a clue, but he seems to know what he's doing. Jan 26 20:12:49 I thought that was which ones Jan 26 20:12:50 Also trying to understand what he's saying is an additional challenge. Jan 26 20:12:58 yeah lol Jan 26 20:13:08 yeah haha Jan 26 20:13:12 if he only had a good mi Jan 26 20:13:14 mic Jan 26 20:13:19 I was trying to figure out his "drawer learned" pattern and I couldn't get it lol Jan 26 20:17:26 greetings android devs. i'm having a problem with decoded bitmaps not displaying properly on some devices. on higher res devices the images are tiny! they are displayed as thumbnails .the images aren't mega important so i'd really like not to have to have multiple versions of the same image but i would like them to scale. how can i make the images take up a certain percentage of an imageview? Jan 26 20:18:55 I think you can just make a huge one and have android scale it down Jan 26 20:19:10 but ideally you'd create multiple sizes Jan 26 20:19:52 pablq: are these bitmaps in a /res folder, or are you e.g. downloading them and displaying them? Jan 26 20:19:53 Levite: having a huge image isn't really feasible in this case. the thumbnail images are downloaded on the fly and wouldnt be worth the big download. Jan 26 20:20:05 groxx: downloading then display Jan 26 20:20:36 before the images are downloaded i have another option that lives in /res, and that one fits the imageview just fine. Jan 26 20:20:48 pablq: imageview has a "scaleType" attribute, you _probably_ want something like "fitCenter". I forget what the default is. Jan 26 20:20:55 set a scaletype on the imageview Jan 26 20:21:05 looks like it's centerCrop Jan 26 20:21:20 makes sense, I suppose Jan 26 20:22:17 JakeWharton: https://raw.githubusercontent.com/stephanenicolas/robospice/master/gfx/RoboSpice-InfoGraphics.png Now i see what robospice is good for :P Jan 26 20:24:23 thanks, trying to set a scaleType ---> CENTER_INSIDE is what i want. Jan 26 20:25:46 Uhhh Is it just me or is Glide a copy/paste of Picasso? Jan 26 20:26:51 Correction; It's the same API, not a copy/paste of the source code. There doesn't appear to be *much* of a difference Jan 26 20:27:04 Anyone know which one came first? Jan 26 20:28:41 groxx: Levite: it was fit_center. thanks. i was trying way more complex stuff before. Jan 26 20:31:05 Is there a place I can pay for someones time, to help with some dev? Jan 26 20:31:37 I'm really struggling with something. Jan 26 20:31:40 :o Jan 26 20:32:11 I can't really 'employ' anyone Jan 26 20:32:25 But just want some advice Jan 26 20:33:00 What do you guys do when you actually have no idea how to fix something? Jan 26 20:33:21 What kinda problem is it? Jan 26 20:33:38 Some animation thing Jan 26 20:34:19 Want a view to update on every frame while an animation is running. Jan 26 20:34:25 And then stop when the animation finishes Jan 26 20:34:42 It works if I just make a loop with my update method in it. Jan 26 20:35:06 But I obvsiouly don't want it to run ALL the time constantly. Jan 26 20:35:50 there is an event when the animation starts and stops but when I put my code in there it doesn't work, even though it definitely gets called and the code runs Jan 26 20:37:05 Its hard to explain Jan 26 20:39:50 AKK9: keep explaining Jan 26 20:40:13 Okay Ill try Jan 26 20:41:28 So I have an activity. There is an expanding toolbar, and a recyclerview. The toolbar expands when you're at the top of the list (Like the spotify list effect). Jan 26 20:42:00 When an item is removed from the recyclerview the ItemAnimator runs its animation to make the list item animate out of the recyclerview. This is where I have a problem. Jan 26 20:42:16 help Jan 26 20:42:28 When an item is removed the list becomes smaller and comes down from the top. Jan 26 20:42:36 I have "public Activity testActivity = new Activity () { void doPollfishInit () { ... " Jan 26 20:43:03 but then when I try doing "testActivity.doPollfishInit ()", I get "cannot find symbol". Jan 26 20:43:04 If you remove enough items the list shrinks to the point where the toolbar should be expanding. But the toolbar doesn't expand until I scroll the list. Jan 26 20:43:23 This made sense, because I run the toolbarUpdate method in the scroll listener. Jan 26 20:44:02 oh, never mind, i guess i can't just add classes like that Jan 26 20:44:06 SO, I added some code which used onPostAnimation on all views in the recyclerview, and passed my updateHeader method. Jan 26 20:44:27 can't you check for the length of the list and manually fire off a method to trigger the animation when it reaches a certain level? Jan 26 20:44:38 oh i see Jan 26 20:44:57 and you've confirmed that onPostAnimation is firing? Jan 26 20:45:26 pablq, yeah it' firing. And it works if I have it running constantly 24/7 in a loop. BUT this kills CPU. Jan 26 20:45:52 yeah Jan 26 20:45:54 So in my itemAnimator I used the startRemove and finishRemove events to start the loop and end the loop Jan 26 20:46:10 But it doesn't seem to work, I have no idea why. Jan 26 20:46:29 When I add breakpoints in my code it confirms that the method is beaing run. Jan 26 20:46:37 But just not seeing anythign update. Jan 26 20:47:05 what does the recyclerview do? Jan 26 20:47:07 I added Log entires and based on them the loop is executing perfectly. Jan 26 20:47:19 With Crashlytics, I have multiple projects belonging to one organization. Can I add a new user to JUST one of those projects? Jan 26 20:47:21 It's just a list of items Jan 26 20:47:27 Added and removed by the user. Jan 26 20:47:34 Just text. Jan 26 20:49:25 k Jan 26 20:51:11 it sounds to me like the activity should be watching it's views and manually tell the animation to trigger when the count of total views is right. Jan 26 20:51:23 Is there any way to do new Activity and then the "implements" keyword? Jan 26 20:51:32 or do I need to extend Activity? Jan 26 20:51:52 Agamemnus time to learn java :D Jan 26 20:52:08 on the bright side, horstman is writing 'core java for the impatient' Jan 26 20:52:18 AKK9: tbh i'm not sure what could be the issue. i have hardly any experience with animations and certainly not with android. thought it couldn't hurt to talk it over though. Jan 26 20:52:43 pablq, alright appreciate it though Jan 26 20:52:45 http://www.informit.com/store/core-java-for-the-impatient-9780133791556 Jan 26 20:52:57 or just head over to the oracle java tutorial Jan 26 20:53:23 Never Jan 26 20:53:29 what does the item animator do btw? Jan 26 20:54:02 In my app, I need to put a lot of "timer UI" (not designed yet). It's a view, with a date on it, with a hour / min / sec counter (so it needs to be updated every second), what's the best approach to do it ? Jan 26 20:54:36 blusky maybe http://developer.android.com/reference/android/widget/Chronometer.html Jan 26 20:54:43 its pretty weird, but usable Jan 26 20:55:23 nice, will see that, it can help indeed :) Jan 26 20:57:36 g00s: sadly that's a java 8 book :( Jan 26 20:57:53 oh yeah, well maybe the previous edition is better :D Jan 26 20:58:13 is there a previous version? Jan 26 20:58:47 I'd kinda like to find something to point people towards that's a relatively concise intro to java, but I don't know of any :( Jan 26 20:59:18 oracle's docs are pretty accurate, but hard to navigate / not organized for _learning_ so much as serving as a reference Jan 26 20:59:39 core java was an old standby for a long time, but being 2 volumes ~1000 pages each it was too much Jan 26 20:59:45 s/accurate/concise and kinda simple/ Jan 26 20:59:56 lol Jan 26 21:00:00 yeah, that would be way too much :) Jan 26 21:01:09 I just wish there were parallels of 'Javascript: the good parts' for every language. super-dense but readable. Jan 26 21:01:34 i do feel for people learning java now for android, since time & money would be wasted getting a newer java book that had thorough coverage of the new things Jan 26 21:01:47 I don't really agree with Crockford's analysis Jan 26 21:01:56 I have a different good parts Jan 26 21:02:29 the attitude of java devs and the fact that it needs an IDE doesn't help :DDDDD Jan 26 21:02:43 and javascript just doesn't Jan 26 21:02:45 java is dying Jan 26 21:04:31 (I wish) Jan 26 21:05:45 shekibobo I figured it out Jan 26 21:06:29 I had "compule 'com.astuetz.materialtabstrip:library:1.0.8' lmao Jan 26 21:07:35 I think it’d be far better if Google would just keep up with Java Jan 26 21:09:01 anything really game-changing in java 8? Jan 26 21:09:10 Lambdas are nice. Jan 26 21:09:11 i dont know how they could, even if android 5 was 100% java 8 compliant we'd have a tough time using those features in our apps for a lloooong time Jan 26 21:09:28 unless there weren't any vm changes for the feature Jan 26 21:12:48 Maybe. They updated from Java 5 to 6, and support a little bit of 7. Although that may be because there weren’t any VM changes Jan 26 21:14:03 TacticalJoke how come the getMenuItems only works when registerForContext menu is placed in oncreate? Jan 26 21:15:08 hello Jan 26 21:15:29 ohayo Jan 26 21:18:26 drinfernoo: glad you got it. Any idea if that has fixes for issues reported in the original? Jan 26 21:18:47 not sure but I would think so Jan 26 21:19:38 drose379: Not sure. Were you calling registerForContextMenu in the main thread or the background thread before (I've forgotten)? Jan 26 21:20:13 I was calling it from a runnable being posted from a View Jan 26 21:20:22 biggest thing is MD, but astuetz quit working in it so jpardogo forked it Jan 26 21:21:22 I remember that you were calling Activity.findViewById in a background thread to find the ListView. It's possible that that was failing. (Though this doesn't seem hugely likely.) Jan 26 21:21:57 And I guess if that happend you'd've had a NullPointerException upon calling Activity.registerForContextMenu. Jan 26 21:21:58 hmm Jan 26 21:22:16 had happened* Jan 26 21:22:19 Right, and thats what happend (NullPointer) Jan 26 21:22:58 Was that when you called registerForContextMenu or when you said "info.position"? Jan 26 21:23:26 info.position Jan 26 21:23:57 In any case, it makes more sense to do stuff such as calling Activity.registerForContextMenu in an Activity.onCreate override. Jan 26 21:24:06 Really, you should be doing UI-related initialization in onCreate. Jan 26 21:24:31 Ok, I will do that from now on\ Jan 26 21:25:22 Not everything of that type has to happen in onCreate, but probably most should be happening there. Jan 26 21:25:55 Ok, got it Jan 26 21:30:45 You guys ever heard of the NEC Mobile Pro 900? Jan 26 21:31:53 Does anyone make use of View.onPostAnimation in their app? Jan 26 21:32:06 In my app, I want to download an image from the internet by entering the image URL. What direction do i have to look for more info to do this? (in particular, downloading the image) Jan 26 21:32:07 Could do with some advice. Jan 26 21:32:09 I'm trying to use it. Jan 26 21:32:21 *postOnAnimation Jan 26 21:34:24 Strat: Picasso is the usual recommendation for that. Jan 26 21:35:15 What is the image going to be used for? Just curious. Jan 26 21:36:24 TacticalJoke, it's stored on the phone for later review. Nothing fancy (it's basically an exercise for myself) Jan 26 21:36:51 TacticalJoke, i know there are probably countless such solutions, but it's just a practice exercise for myself Jan 26 21:37:29 I see. Well, you could do it "manually" using an HTTP client. Jan 26 21:37:53 Or go to town and write the HTTP implementation yourself. It's a question of where you're drawing the line. :) Jan 26 21:37:58 I wouldn't recommend that, though. Jan 26 21:40:08 g00s, just use retrolambda, be happy Jan 26 21:40:19 no Stream and new apis, but whatever Jan 26 21:40:22 that's all livable Jan 26 21:46:41 method references are nice too Jan 26 21:46:50 miss function pointers from c++ ;( Jan 26 21:48:17 then use a language with function pointers Jan 26 21:50:04 anyone know how to make a view look like a list item? Jan 26 21:50:14 eg. on 5.0, I want it to have the ripple effect on touch Jan 26 21:50:50 and become blue on 4,0 etc Jan 26 22:04:16 TacticalJoke the same line is not throwing an exception again Jan 26 22:04:18 Randomly Jan 26 22:05:02 You mean 'now'? Jan 26 22:05:36 Yes, but I figured it out, a weird error in the code I wrote Jan 26 22:05:57 Ill show you if you want, but if you dont care then NBD Jan 26 22:07:11 I don't mind; show away. Jan 26 22:07:39 Well I already changed the code so ill just try to explain Jan 26 22:07:52 So i have a property that the contextMenu methods were using Jan 26 22:08:01 and that is set to the Subject List Jan 26 22:08:24 But that property was only being set if an item in the listview was clicked (just where I placed the line, by accident) Jan 26 22:08:47 So If I was using the contextMenu before setting the list (clicking on any item) then it would be NullPointer Jan 26 22:10:14 Is this property/field the list itself or something related to the list? Jan 26 22:11:29 When I make an array in the arrays.xml and fill the items with a reference to a drawable like "@drawable/myDrawable", will that return an int? Jan 26 22:11:33 or an actual Drawable Jan 26 22:13:58 Its the list Jan 26 22:14:30 see for yourself, id say itll return int Jan 26 22:14:58 drose379: Hmm, I thought you couldn't show a context menu until the ListView had items? Jan 26 22:15:03 Maybe I misremember. Jan 26 22:16:09 "Application/json" is a valid media type right? Jan 26 22:20:40 shekibobo, you still here? Jan 26 22:20:59 since you're using PagerSlidingTabStrip, I wondered if I could pick you brain lol Jan 26 22:30:38 I'm extending FragmentStatePagerAdapter for my ViewPager, and whenever a fragment gets added to the backstack (detail of GridView in the page), and I return, my page has to be remade. if the whole fragment is remade, then it seems to work fine Jan 26 22:31:55 is very hard to use intellij compare to eclipse, Jan 26 22:32:03 even auto-import isnt done Jan 26 22:36:17 what IDE should I be considering at for a video poker game? libGDX seems like overkill but it's looking like android studio might not be enough Jan 26 22:38:01 IDE is text editor Jan 26 22:38:04 you mean framework? Jan 26 22:38:57 ack, right Jan 26 22:39:15 well libgdx might look heavy unless you want some fancy animation Jan 26 22:44:00 no animation, would android studio be friendly for rendering stationary, pixelated sprites? Also, would the power-of-2 texture rule be relevant? Jan 26 22:44:12 john67, you just don't know intellij Jan 26 22:44:15 Help Jan 26 22:44:33 D: Jan 26 22:44:55 "com.facebook.AppEventsLogger.activateApp(context, facebook_app_id);" Jan 26 22:45:01 john67: IDEA definitely does auto-import Jan 26 22:45:03 I need to add this to my main activity Jan 26 22:45:06 and a library of some sort Jan 26 22:45:13 and other things maybe Jan 26 22:45:22 problem is I don't know where the library file is or what Jan 26 22:45:26 I downloaded the SDK Jan 26 22:45:32 NO ECLIPSE HERE Jan 26 22:45:42 bolts-android-1.1.2.jar .. only library? Jan 26 22:45:46 Anyone know? Jan 26 22:46:38 JesusFreke: its a making stuff like hell specially to newbies Jan 26 22:46:43 like me Jan 26 22:47:40 hey all, have some random UI elements that shouldn't have a descriptor so I was wondering if I have to give them a special descriptor that says they should be ignored by screen readers Jan 26 22:48:13 I haven't used it in the context of being a newbie, as I already knew java reasonable well before I started using it. But I've always found it extremely easy to use Jan 26 22:48:32 while i constantly had problems with eclipse Jan 26 22:54:36 john67: Settings > Editor > Auto Import > Optimize imports on the fly. Jan 26 22:54:48 TacticalJoke: have done it Jan 26 22:54:51 You can also tune the settings. Jan 26 22:55:05 Alt+Enter for manual import in some cases. Jan 26 22:55:13 yeah have done so Jan 26 23:03:38 how many people use Android Studio? because I love it Jan 26 23:03:53 TacticalJoke: thanks any way Jan 26 23:08:33 Does anyone know if there an easy to have an ImageButton just invert its colors or apply a tint when pressed, without having to get into the XML selector garbage? Jan 26 23:11:55 i have about 500 content , to insert into the database when the app is created for the first time how can i do that with out slowing the app? Jan 26 23:12:04 should i use a thread? Jan 26 23:12:14 could you bundle a pre-built database in the apk? Jan 26 23:13:04 hello everyone! Jan 26 23:13:23 like for local sql? Jan 26 23:13:24 john67, use an AsyncTask or something to do it in the background Jan 26 23:13:30 n^izzo: Yeah, it's nice. It'll be even nicer when the Gradle plugin supports JVM unit testing. :) Jan 26 23:13:46 john67 from 0, inserting 500 things is minimal time. i'll guess around 500ms Jan 26 23:14:06 1 transaction Jan 26 23:14:18 g00s: a transaction? Jan 26 23:14:39 TacticalJoke, pft who needs unit tests... #YDD (YOLO driven development) is the way to go Jan 26 23:14:46 lol Jan 26 23:14:51 \o/ Jan 26 23:15:10 i just realize \o/ ~ lol Jan 26 23:15:11 g00s: what type of transaction? Jan 26 23:15:11 I guess unit testing is more like "You only die once". Jan 26 23:15:33 john67 how many kinds are there ).0 Jan 26 23:15:54 google sqlite android transaction example Jan 26 23:16:12 or yeah do what JesusFreke said Jan 26 23:17:30 Damn, Jackson-core is fast. It even (as far as I can tell) has special support for giving it an InputStream (as opposed to a Reader) for maximal performance. Jan 26 23:17:31 TacticalJoke, you only live once so why waste your time testing when you could be learning that new JS libary :P Jan 26 23:17:55 I guess tests put that nagging voice in my head to sleep. Jan 26 23:18:26 TacticalJoke, head voices lie... dont listen to them Jan 26 23:18:30 Not the one that says "Kill. Kill." The one about my app crashing. Jan 26 23:18:56 g00s: JesusFreke said what? Jan 26 23:19:10 - JesusFreke: could you bundle a pre-built database in the apk? Jan 26 23:19:16 "JesusFreke: could you bundle a pre-built database in the apk?" Jan 26 23:19:54 Head voices are liars, what do head voices know? Jan 26 23:19:55 JesusFreke: interesting Jan 26 23:20:28 JesusFreke: never done that, let me check on the net Jan 26 23:21:11 I love that I can middle-click an identifier to go to its definition in Android Studio. Jan 26 23:21:14 Much handier than Ctrl+Click. Jan 26 23:28:50 I have the strangest bug... Whenever I add android:pivotX="50%p" Jan 26 23:28:51 android:pivotY="50%p" to my animation the animation doesn't show http://hastebin.com/ivohevifiy Jan 26 23:29:29 ^relevant code Jan 26 23:29:48 http://stackoverflow.com/questions/28160686/i-dont-know-how-to-add-the-facebook-sdk-to-my-android-cordova-project Jan 26 23:30:48 Agamemnus, how do you build without Eclipse or some other IDE? Jan 26 23:31:00 Cordova. Jan 26 23:31:24 cordova run --release Jan 26 23:32:08 you should probabbly add that to your question Jan 26 23:32:27 "I use cordova to build..." Jan 26 23:32:50 Agamemnus, this is no good: https://github.com/Wizcorp/phonegap-facebook-plugin ? Jan 26 23:37:33 I don't want to use a plugin. Jan 26 23:37:46 plus it's phonegap not completely compatible with Cordova Jan 26 23:38:53 ok I'm back Jan 26 23:39:13 ----> I don't want to use a plugin, plus it's phonegap not completely compatible with Cordova Jan 26 23:40:29 I'm having an issue where my DialogFragment isn't having it's onCreateDialog function called. Any thoughts about what might be causing this? Jan 26 23:40:57 I'm displaying it via dialogFragment.show(fragmentManager, "dialog"); Jan 26 23:41:32 Agamemnus, "This is the official plugin for Facebook in Apache Cordova/PhoneGap" Jan 26 23:43:34 doesn't matter, assume i am not using cordova Jan 26 23:43:48 and using command line only Jan 26 23:44:15 got to go, good night Jan 26 23:44:16 to all Jan 26 23:44:20 jessie: Is anything called (e.g., onCreate)? Does it show on screen? Jan 26 23:44:21 and thanks for all Jan 26 23:45:13 TacticalJoke: Yes. onCreateView is called. I just tried removing the onCreateDialog and the styling was different, so it's being called I think, but it isn't applying all my styles. Jan 26 23:45:27 Yeah, log statement is in there, debugging via a break point didn't work. Jan 26 23:45:43 So it is being called, but my translucent status and navigation aren't working. Jan 26 23:46:10 You're saying that onCreateView is being called but onCreateDialog isn't? Jan 26 23:46:50 No, both onCreateView and onCreateDialog are being called correctly. I thought onCreateDialog wasn't because my breakpoint wasn't being hit, but I put a log statement in and it is logging. Jan 26 23:47:16 can anyone help me on how to update my menu from its parent FragmentActivity? this is the menu fragment: http://paste.ofcode.org/W8VgE7gfpEM5BcA9a4saqS Jan 26 23:47:40 So for some reason the windowTranslucentStatus and windowTranslucentNavigation aren't being applied to the dialog's window, TacticalJoke Jan 26 23:52:19 TacticalJoke: I'm putting together an example app, one moment. Jan 26 23:54:03 my google foo is used I cant find why this wouldn't work :( when I add the pivot the animation wont run. Code --> http://hastebin.com/tetahanero.xml Jan 26 23:55:15 hmm got dc Jan 26 23:57:00 can anyone help me on how to update my menu from its parent FragmentActivity? this is the menu fragment: http://paste.ofcode.org/W8VgE7gfpEM5BcA9a4saqS Jan 26 23:59:17 is there any way to catch a tap on a disabled Preference? I want to show a toast if it's disabled for a certain reason. Jan 26 23:59:41 got it Jan 27 00:00:15 turns out I should be using android:pivotX="50%" not android:pivotX="50%p" Jan 27 00:08:31 TacticalJoke: Hmm... there must be some other interaction causing issues. When I try to reproduce in a simpler case it seems to work fine. Jan 27 00:08:51 Hi. I'm trying to use this code but getting the error I mentioned in its comment. Would anyone care to point me in the right direction to fixing the exception? http://stackoverflow.com/a/28160728/775283 Jan 27 00:11:32 TacticalJoke: Even better is on a 4.4.2 emulator it works fine and on my Nexus 5 with Lollipop it doesn't. :-/ Jan 27 00:11:33 looks like things will be exciting on the east coast tonight :) Jan 27 00:14:24 g00s: you gotta try this out https://play.google.com/store/apps/details?id=com.alexjlockwood.twentyfortyeight Jan 27 00:15:39 Napalm pretty slick ? Jan 27 00:15:54 yea.. really nice app and good game Jan 27 00:15:57 game(s) Jan 27 00:15:59 clean interface Jan 27 00:16:17 too much Jan 27 00:16:18 i'm glad most of my users don't care about slickness, its beyond me anyhow :) Jan 27 00:16:42 are you making money on the IAPs? Jan 27 00:16:50 I find that the better I make my game, the less money I make. Jan 27 00:17:15 (Napalm, is that your game?) Jan 27 00:17:17 Agamemnus: its not mine Jan 27 00:17:27 oh Jan 27 00:17:39 i'd like to switch to IAP + free fro paid, but there's no way to avoid pissing off all the past users Jan 27 00:18:12 s/fro/from Jan 27 00:18:16 Well Jan 27 00:18:29 You can piss off only a small fraction Jan 27 00:18:43 g00s: cant you add them as pro users after-the-fact Jan 27 00:18:48 g00s: i believe you can Jan 27 00:18:49 What might be causing this? Jan 27 00:18:51 Unhandled exception: java.lang.ClassNotFoundException Jan 27 00:18:59 Code: http://stackoverflow.com/a/28160728/775283 Jan 27 00:18:59 g00s: so your current users get it for free Jan 27 00:18:59 what the exception says Jan 27 00:19:00 exactly Jan 27 00:19:07 make an update that will add them in to your database as having paid Jan 27 00:19:10 (line 3 of that code) Jan 27 00:19:16 Napalm afaik there is no way to maintain any linkage between past purchase (of whole app) and IAP Jan 27 00:19:23 of course there is Jan 27 00:19:31 but only if they update Jan 27 00:19:42 just add them in via your server as having paid Jan 27 00:19:51 but you'll need a server system for this Jan 27 00:19:52 Keavon, read Jan 27 00:19:52 my server ? Jan 27 00:20:03 g00s, do it yourself Jan 27 00:20:05 or just run a local script Jan 27 00:20:07 in other words, the proper way to do IAPs Jan 27 00:20:14 g00s: you could transform the paid app as an unlocker for the free app (same effect than IAP) Jan 27 00:20:18 pfn: I obviously read the exception but I don't understand why it's happening. Jan 27 00:20:32 Keavon, why don't you read it again until you understand, you don't tell us what it is, so we can't understand it Jan 27 00:20:45 save the granted access separately from the in-app purchases Jan 27 00:20:49 in a database Jan 27 00:21:06 Keavon, and if the class doesn't exist, how do you expect to use it Jan 27 00:21:14 The specific part of the code is this, but I don't understand how this code works which is probably why I am having trouble understanding what the error means Jan 27 00:21:15 Class.forName(mConnectivityManager.getClass().getName()); Jan 27 00:21:29 on your server Jan 27 00:21:29 Napalm how would the local script thing work ? Jan 27 00:21:37 Agamemnus i'm not standing up a server for this Jan 27 00:21:41 pfn: I understand it means the class doesn't exist, but what class is it referring to? "Class"? Jan 27 00:21:48 Keavon, the error is in the message Jan 27 00:21:49 the only downside is, you need to get users to accept an authentication screen Jan 27 00:21:58 then idk Jan 27 00:22:01 Keavon: seems pretty redundan.. since you can do mConnectivityManager.getClass() gives you the same result Jan 27 00:22:18 and you do a Class.forName Jan 27 00:22:20 cargo cult ftw Jan 27 00:22:52 keep praying to your code gods, those planes might just come Jan 27 00:23:21 Napalm: That fixed it. I'm not sure if it broke the original intent of the person writing the code, though. Jan 27 00:23:28 g00s: just create your project.. https://console.developers.google.com/project link it to your app.. then use the API keys to call the api from a local script Jan 27 00:23:50 Now I have an error on line 4, but I actually don't understand what this means at all. Jan 27 00:23:51 Unhandled exception: java.lang.NoSuchFieldException Jan 27 00:23:52 Keavon: ps. that code wont work on L Jan 27 00:24:31 i hate you pfn Jan 27 00:24:33 Napalm: Good to know, I'll keep that in mind when evaluating the bounty, especially since I plan to upgrade to L when CyanogenMod releases it Jan 27 00:24:33 https://upload.wikimedia.org/wikipedia/commons/7/77/Martian_face_viking_cropped.jpg Jan 27 00:24:51 Keavon: doesnt work on KK either Jan 27 00:25:11 Napalm: Oh, I'm running KitKat. Should I not bother implementing it? Jan 27 00:25:29 Napalm have you seen any examples of that? i didn't understand Jan 27 00:25:49 but i haven't done IAP either, yet Jan 27 00:26:39 i have 1 purchase on iap from a non-friend Jan 27 00:26:44 had one on the 3rd day Jan 27 00:26:46 none since Jan 27 00:26:57 Keavon: one moment Jan 27 00:27:08 Napalm: Okay, thanks. Jan 27 00:27:15 i think i probably need to rethink my strategy. Jan 27 00:27:20 I have 100 images now Jan 27 00:27:25 50 free, 50 not Jan 27 00:27:31 maybe i should make it more like 10 free Jan 27 00:27:32 90 not Jan 27 00:28:28 Agamemnus, what Jan 27 00:28:36 i have a jigsaw puzzle Jan 27 00:28:40 remember Jan 27 00:28:43 50 free images Jan 27 00:28:47 50 images you get with gems Jan 27 00:29:04 which you can buy with cash, or you get daily, or you do polls for Jan 27 00:29:28 but it is too much, too many images Jan 27 00:29:35 people don't use the iap Jan 27 00:29:45 but most of them don't see the "my packs" button Jan 27 00:29:46 99% Jan 27 00:29:52 probably need a tutorial Jan 27 00:30:32 g00s, just setup a second service to get users migrated over Jan 27 00:30:45 g00s, then unlock features for them, then delete said service Jan 27 00:31:18 Keavon: i lied, it will work in KK https://android.googlesource.com/platform/frameworks/base/+/kitkat-mr2.2-release/core/java/android/net/IConnectivityManager.aidl#79 https://android.googlesource.com/platform/frameworks/base/+/kitkat-mr2.2-release/services/java/com/android/server/ConnectivityService.java#1886 Jan 27 00:31:28 Keavon: check those two sources Jan 27 00:31:41 Napalm: Excellent. I will read through those. Jan 27 00:31:43 g00s, of course, since you haven't started this yet, you aren't gonna get this underway any time soon at all Jan 27 00:31:44 Thanks. Jan 27 00:32:06 Keavon: its in JB MR2 also. Jan 27 00:32:28 Is it also in 4.4.4? Jan 27 00:32:42 yes thats KK Jan 27 00:33:34 Hello! I've got a question regarding reading from a USB device, I've scoured the internet and have writing working but I can't for the life of me figure out reading data I'm sending back... I'd love any pointers you guys have Jan 27 00:34:43 karoly: you mean using the usb apis directly or something? Jan 27 00:34:52 Napalm: Would you mind helping me fix the issues with the code I linked to? I removed the redundant parts around line 3 but now line 4 is saying: Unhandled exception: java.lang.NoSuchFieldException Jan 27 00:37:00 Keavon: https://www.google.com/#q=unhandled+exception+java Jan 27 00:37:06 this is pretty basic java stuff :) Jan 27 00:37:13 Keavon, you need to learn some basic java first Jan 27 00:37:17 JesusFreke: I'm currently using android.hardware.usb.* in an attempt to communicate with an Arduino Leonardo I have attached via USB cable to my Nexus tablet. Is there something more direct than that? Jan 27 00:37:28 Keavon: its just been removed in Lollipop by the looks of it Jan 27 00:38:11 Napalm: he's not getting a NoSuchFieldException.. he's just not catching/handling/"throws"ing it Jan 27 00:38:33 just a syntax error, not an actual runtime exception Jan 27 00:38:37 Keavon: looks like the field exists https://android.googlesource.com/platform/frameworks/base/+/kitkat-mr2.2-release/core/java/android/net/ConnectivityManager.java#396 Jan 27 00:38:47 Keavon: are you doing this on a L device? Jan 27 00:38:50 Napalm: Okay, that's okay I guess, although the changelog for this app mentioned it added Android L support, so it must be possible some other way which I'll investigate further: https://play.google.com/store/apps/details?id=com.atejapps.networksignalrefresher Jan 27 00:39:05 I'm currently using 4.4.4 but I plan to upgrade to L when it comes out on CyanogenMod Jan 27 00:39:16 Napalm: it's a compile-time error. it has nothing to do with the device Jan 27 00:39:33 JesusFreke: no its not Jan 27 00:39:42 "Unhandled exception: java.lang.NoSuchFieldException" Jan 27 00:39:48 that is an error from the compiler Jan 27 00:39:54 no its not Jan 27 00:40:01 It's underlined in the IDE Jan 27 00:40:08 ^ yes it is. :) Jan 27 00:40:08 what Jan 27 00:40:17 All of the following is underlined: mClass.getDeclaredField("mService"); Jan 27 00:40:24 lol Jan 27 00:40:26 with that exception when you hover over it Jan 27 00:40:41 Maybe because I'm using the Lolipop SDK? Jan 27 00:40:45 nope Jan 27 00:43:48 Maybe it's because line 4 uses the object set in line 3 which I removed the redundancies from in an imperfect way? Jan 27 00:45:50 Keavon: it's because you're not catching the exception, or declaring it in the "throws" for the method Jan 27 00:46:31 e.g. http://docs.oracle.com/javase/tutorial/essential/exceptions/catchOrDeclare.html Jan 27 00:47:02 That fixed it, thanks. Jan 27 00:47:53 Keavon: http://stackoverflow.com/questions/28131335/reset-android-mobile-network-signal/28161446#28161446 Jan 27 00:48:38 Napalm: Excellent. Did you post that? Jan 27 00:48:41 yes Jan 27 00:48:53 Does that work pre-Lollipop? Jan 27 00:49:10 yes Jan 27 00:49:25 I verified Froyo to KitKat Jan 27 00:49:51 Keavon: now gimme the bounty :D Jan 27 00:49:55 :P Jan 27 00:50:05 I will once I check that it works Jan 27 00:50:19 Or if someone finds an alternative that works with Lollipop too Jan 27 00:50:32 Cannot resolve symbol 'TAG' Jan 27 00:50:37 I'll just delete those Log.e lines? Jan 27 00:50:46 if you like.. or add a TAG string Jan 27 00:50:53 You can. Or in your activity you can create a TAG variable. Jan 27 00:51:01 bounty? Jan 27 00:51:08 there was money involved? Jan 27 00:51:17 pfn: Stack over flow reputation. Jan 27 00:51:24 oh, fuck that shit Jan 27 00:51:55 lol Jan 27 00:52:14 lol Jan 27 00:52:33 Napalm: false disables the connection? Jan 27 00:52:37 yes Jan 27 00:52:40 * g00s sprinkes internet awards around Jan 27 00:53:03 I am calling it with this line: Jan 27 00:53:04 setMobileConnectionEnabled(getApplicationContext(), false); Jan 27 00:53:26 or your activity yea Jan 27 00:54:07 Napalm: http://pastebin.com/ZhiSQcxK Jan 27 00:54:22 The toast notification worked but the data wasn't disabled. Jan 27 00:55:00 Why do you want to disable it anyway? Jan 27 00:55:39 "UI for switching selected test artifact." got merged. :D https://android-review.googlesource.com/#/c/123270/ Jan 27 00:56:01 Napalm: I'd like to toggle off then on because I to refresh the connection. Jan 27 00:57:00 Napalm found this http://stackoverflow.com/questions/15136955/changing-paid-android-app-to-free-with-in-app-billing-grandfathering-existing Jan 27 00:57:39 doesn't seem like much of a solution bah Jan 27 00:59:19 so it doesn't seem like there is an easy way of doing this without standing up your own service, which i'm not about to do Jan 27 00:59:26 because I want* to refresh the connection Jan 27 00:59:34 and just fopr migration, additionally Jan 27 01:00:07 g00s: why cant you just call the REST apis from your local machine to give those people the purchases.. or you could even get the app to do it.. if its the pro version.. or so on and so forth Jan 27 01:00:33 if the IAP is not free i don't think thats even possible Jan 27 01:00:44 just like there are no coupon codes in Play Jan 27 01:05:10 Napalm: Okay, I put a debug toast in the IllegalArgumentException which is being called. I think that's because CyanogenMod changed the setMobileConnectionEnabled arguments: https://github.com/CyanogenMod/android_frameworks_base/blob/cm-11.0/core/java/android/net/IConnectivityManager.aidl#L79 Jan 27 01:05:35 Keavon: so add it to the code Jan 27 01:05:47 Napalm: Doing that now. Jan 27 01:05:53 Although I'm not sure what the callingPackage is Jan 27 01:06:00 context.getPackageName() Jan 27 01:06:13 want me to modify my answer? Jan 27 01:06:20 Let me test it first Jan 27 01:06:47 Actually, yes please. Jan 27 01:09:17 Keavon: done Jan 27 01:09:30 Thanks, Napalm. I'll give that a try Jan 27 01:10:44 YES! Jan 27 01:10:59 now gimme my bountaaaa Jan 27 01:11:00 :D Jan 27 01:11:02 haha Jan 27 01:11:41 One sec, the question said **toggle**, so you need to add the self-calling line :) Jan 27 01:12:47 no Jan 27 01:12:52 you need to call the function twice Jan 27 01:12:57 once to disable and once to enalbe Jan 27 01:12:58 enable Jan 27 01:12:59 :P Jan 27 01:13:11 Oh, that would by why it crashed. Jan 27 01:13:20 I'm developing an obsession with Rach 2. Jan 27 01:13:21 I sent it into an infinite loop when I tried self-calling from within the function Jan 27 01:13:27 idiot Jan 27 01:13:29 :P Jan 27 01:13:30 :D Jan 27 01:13:33 Indeed :) Jan 27 01:14:44 Looks like I need to add a small delay between calling the enable. Jan 27 01:14:50 TacticalJoke: I figured out what's causing it. Jan 27 01:15:10 What was it? Jan 27 01:15:31 A bit hard to explain, but the way the background color works between dialogs and dialog fragments in lollipop is not consistent. Jan 27 01:15:38 What's the most elegant way to add a 500ms delay in this context? Jan 27 01:15:39 I see. Jan 27 01:15:49 Keavon: Thread.sleep(500); Jan 27 01:15:53 ok Jan 27 01:16:05 surround with a try/catch for the exception it throws Jan 27 01:16:13 I also saw some 10-line ways but that looks better Jan 27 01:17:15 worse* Jan 27 01:17:19 TacticalJoke: http://pastie.org/9863925 Jan 27 01:17:24 better* Jan 27 01:17:47 When I create the dialog.xml as a Dialog the dialog_background is set as the navigation and status bar color. Jan 27 01:18:25 When I create it using the onCreateDialog in the DialogFragment, I get transparent navigation and status bar for that window, causing the previous window's status and navigation bars' colors to be used. Jan 27 01:19:28 Napalm: I can't award the bounty for 21 more hours. Jan 27 01:19:48 But take your upvote and accepted answer for now Jan 27 01:19:49 jessie: thats expected.. beacause your not implementing the theme Jan 27 01:19:54 TacticalJoke: https://www.dropbox.com/s/6w849bvuyzmlizw/testdialogfragment.zip?dl=0 Here's a ZIP containing an exmaple app. Jan 27 01:20:10 Napalm: what do you mean by that? Jan 27 01:20:20 Keavon: coolo, im just looking at Lollipop.. see if there is a new method for this Jan 27 01:20:35 To be honest, I've almost given up with dialogs in Android. They're so quirky and limited. Jan 27 01:20:56 Napalm: You may find luck in decompiling the source code for the app I linked to in the original post. I haven't tried it myself, but the Google Play page has the changelog and the newest update mentions adding support for Lolipop Jan 27 01:22:52 hello people who are online Jan 27 01:23:05 TacticalJoke: I'm about ready to be at that point. The best/worst part is that this works fine on 19 and 20 but API version 21 has this behavior... Jan 27 01:23:12 hesperaux: No, the more useful statement is hello people who are *offline*! Jan 27 01:23:41 yeah? Jan 27 01:23:53 hey everyone (especially those who are offline :D ) Jan 27 01:24:02 * hesperaux sends bell characters to everyone Jan 27 01:24:09 After all, they need some hellos to encourage them to magically levitate towards their computers so they can respond to your friendly hellos! Jan 27 01:24:31 heh Jan 27 01:25:04 Does anyone use the Gimp to make the icons/graphics? I made an Android specific plugin that will generate all the correct size, folders, names... Jan 27 01:25:06 oh man, if IRC & clients had bell characters lol Jan 27 01:25:12 WTF? Phone app is empty https://android.googlesource.com/platform/packages/apps/Phone/+/master Jan 27 01:25:21 Does anyone want to try it out and give me some feedback? Jan 27 01:25:23 https://bitbucket.org/risesoftware/scripts/src/866cd9677f8f184d0c9a663330a09324db1042ae/rs_save_android_icons.py?at=master Jan 27 01:26:10 It's still alpha code.... I just want some feedback to finish it up, and see if the UI makes sense Jan 27 01:27:02 jessie: Activities are so much easier to customize. I also feel that dialogs don't offer a good UX in general. Jan 27 01:28:15 screenshot of the plug-in : http://uppix.com/f-screenshot_05854c6e9a20018424b.png Jan 27 01:29:03 TacticalJoke: At this point I'll probably just say screw it and let the bars at the top and the bottom be different colors. I might report a bug to the Android team, though. Jan 27 01:31:06 Napalm: I'm not sure if it will help you finding the lollipop solution, but here's the decompiled source for the app I mentioned that claims Lollipop support http://puu.sh/f4VNl/02e8f4cb32.txt Jan 27 01:31:44 Pretty crappy quality because it's decompiled and I can't really read it because I'm not experienced enough in Java or Android, but it may give a hint you need Jan 27 01:33:06 I want a soft edge for a oval any idea how I would do that? Jan 27 01:34:52 Keavon: Napalm: setMobileDataEnabledGingerplus in that app is the same as what you're wanting to use. Jan 27 01:35:19 Keavon: looks like that source doesnt support Lollipop Jan 27 01:35:24 jessie: was about it say that :D Jan 27 01:36:46 Keavon: it also looks like Lollipop doesnt have the option in Settings to disable Mobile data.. so I guess they removed the feature Jan 27 01:37:37 Napalm: It's in my status bar settings area, so it obviously exists. Jan 27 01:37:40 No takers for my plug-in? :( Now I have to sit here and cry. I hope you are all happy. Jan 27 01:37:52 Well... at least, the ability to turn mobile off completely. Jan 27 01:38:04 where? Jan 27 01:38:41 Interesting. Jan 27 01:38:44 Huh. maybe not. Jan 27 01:38:59 I assumed it toggled it, but instead it just opens up the data usage screen. Jan 27 01:39:18 I don't have Lollipop yet, but does anyone with Lollipop want to test if this app works at resetting your signal? http://stackoverflow.com/questions/28131335/reset-android-mobile-network-signal/28161446 Jan 27 01:39:20 Ah, but in the data usage section of the settings arrea there is a toggle for "cellular data" Jan 27 01:39:31 Wrong link: https://play.google.com/store/apps/details?id=com.atejapps.networksignalrefresher Jan 27 01:39:32 you have Airplane Mode but that requires an internal permission CONNECTIVITY_INTERNAL Jan 27 01:40:05 jessie: ah, didnt see it there.. will check how it does it Jan 27 01:40:24 Weird how the LogCat thing in Android Studio has a print button. Who prints LogCat output? Jan 27 01:40:25 Napalm: It works fine on my Lollipop Nexus 5. Jan 27 01:40:50 TacticalJoke, it's handy for when you want to fax it. Jan 27 01:40:55 lol Jan 27 01:40:58 Fax it back to 1995 :D Jan 27 01:41:05 found it Jan 27 01:41:05 jessie: Would you mind downloading this app and testing if it does work at resetting your signal? https://play.google.com/store/apps/details?id=com.atejapps.networksignalrefresher Jan 27 01:41:24 Keavon: I did. It works. Jan 27 01:41:25 Napalm: The Lollipop part? Jan 27 01:41:30 yus Jan 27 01:41:43 jessie: Okay, great, that means it's possible. And the fact that Napalm just found is is even better :P Jan 27 01:47:45 Napalm: When you get the code working, I'll give it a try and then, if jessie wants to, I can send him the APK and he can test it Jan 27 01:52:54 * groxx is back, after hella irccloud outage Jan 27 01:54:17 Doh! Jan 27 02:06:41 is there a way to get the width or height depending on which is bigger in XML Jan 27 02:07:05 get the height Jan 27 02:17:49 max(width, height) ? Jan 27 02:19:14 Napalm: If you get a chance, I'd love it if you could add the solution you found to the answer. I'll award you the bounty when it lets me, but if someone does add a solution including Lollipop and you don't add it, for the sake of completion, I will have to give it to them. Jan 27 02:23:20 hah, no pressure or anything Jan 27 02:23:23 free help Jan 27 02:23:32 lol Jan 27 02:23:36 :P Jan 27 02:23:50 as if anyone would want to answer that question though... Jan 27 02:24:07 Well, since he already found the solution and I doubt other people will find it, I don't foresee awarding it to anyone but him :) Jan 27 02:24:21 Keavon: looks like its been restricted to System apps only now Jan 27 02:24:24 new permission Jan 27 02:25:44 Keavon: updated post Jan 27 02:30:24 hey jessie.. you about? Jan 27 02:40:28 Hello. Is it possible to get the specific image/icon (by coordinates) from an image? Like a game icons, I want to crop the head of the charater or something else. Thanks Jan 27 02:41:21 yea MikeWallaceDev Jan 27 02:41:33 sorry for the late response Jan 27 02:41:38 +1 Jan 27 02:42:52 I want to scale an oval (as a circle) but I don't know how to reference the max width or height in xml Jan 27 02:43:25 Could a dev of a popular, free app please tell me their number of active installs vs total downloads? just want to get an idea of what numbers I should expect Jan 27 02:43:57 n^izzo, I don't understand what you want to do... Jan 27 02:44:26 duncannz how can you translate someone elses success into probability of your own ? Jan 27 02:44:51 g00s: I just want to get a general idea, probably worded that badly Jan 27 02:45:16 it really depends on your app Jan 27 02:45:54 anyway, apps range from 10 to 50% installed base Jan 27 02:46:04 paid apps more, free apps less Jan 27 02:46:20 alright thanks, so 50% isn't too bad then Jan 27 02:46:26 I want to reference the max width or height so I can make a circle that is a percentage of the screen width/height e.g. android:toXScale="150%p" Jan 27 02:46:42 you won't get 50%unless users have a reason to keep your app Jan 27 02:46:47 but that would give me the width, I want to get the height Jan 27 02:46:48 like if they paid for it Jan 27 02:47:07 toYScale? :D Jan 27 02:47:08 well I have 50% on a free app, albeit a very neiche one with a small install base Jan 27 02:47:13 niche* Jan 27 02:47:19 anyway thanks Jan 27 02:47:27 1 of 2 doesn't count as 50% Jan 27 02:47:46 it's 25/44 Jan 27 02:47:55 still a small sample but not quite that small :p Jan 27 02:48:15 yeah,thats just noise Jan 27 02:49:08 http://en.wikipedia.org/wiki/Sample_size_determination#Required_sample_sizes_for_hypothesis_tests Jan 27 02:49:08 ok Jan 27 02:49:20 What is your app about, duncannz? Jan 27 02:50:26 TacticalJoke: it is related to speech and language therapy Jan 27 02:50:47 MikeWallaceDev, to make a circle I need the value set for toXScale to reference the y max height Jan 27 02:51:06 because I will make an oval otherwise Jan 27 02:51:40 err... if it's a circle, then the width == height... :) **** ENDING LOGGING AT Tue Jan 27 02:59:58 2015