**** BEGIN LOGGING AT Sat Feb 25 03:00:01 2017 Feb 25 03:00:37 Leeds i'm still figuring out how google benefits from Things Feb 25 03:00:58 do they get royalties or collect license fees ? Feb 25 03:04:16 I don't know in particular, but with a lot of (small-t) things there are different ways to benefit - directly by profiting, indirectly by association (e.g. being able to sell tools, certification etc.) or very indirectly by blocking competitors from owning a market Feb 25 03:07:26 competitor to google is alternate path for data they can't access, i don't see how embedded systems fit in that picture Feb 25 03:11:31 hey g00s yesterday you recommended glide Feb 25 03:11:42 (pasting from earlier) i have code to draw some bitmaps to a canvas -- can I just take this answer (to adapt it to glide): http://stackoverflow.com/a/31940058/2684182 and modify Generators.imageWithText do draw those bitmaps to that canvas? or is that not gonna work? Feb 25 03:11:59 thomasross i'm rusty on bitmap topic Feb 25 03:12:30 hm okay Feb 25 03:12:34 i'll give it a shot Feb 25 03:54:52 what's the best way to put all of the stuff in that answer into seperate files? Feb 25 03:55:02 i'm just not sure how to organize it Feb 25 05:04:42 Friday night, and it's wine o'clock! **** BEGIN LOGGING AT Sat Feb 25 05:11:22 2017 Feb 25 05:24:39 hi Feb 25 05:25:18 Hello :') Feb 25 05:27:29 i want to take data from user like name,email and have to store that on any database server ,i saw one project ,in that they have used JSON,async task,gcm to do this whole stuff, how these things are related? i have no idea about web services,please tell me! Feb 25 05:33:08 Yo guys (and possibly girl) Feb 25 05:33:53 3rd row from the top of Android studio, is that a longass pathname, and where is the top directory located? Feb 25 05:34:34 also, where is the .exe of android studio located, do I always have to run that script to start it? Feb 25 05:49:03 Guessing on windows, but what os? Feb 25 05:51:20 looking at this article on CircleCI / Travis / Jenkins http://djangostars.com/blog/continuous-integration-circleci-vs-travisci-vs-jenkins/ Feb 25 05:52:23 it looks like Travis is the only one that supports android ? Feb 25 05:52:50 no that can't be right Feb 25 07:21:45 Did anybody use the Kotlin Koans? Feb 25 07:22:25 The UI is not very reactive in both Firefox and Chrome. You press "Check" and nothing happens Feb 25 07:24:49 Nothing happens in most cases, at least. Sometime clicking and re-clicking here and there I manage to make it work Feb 25 07:29:12 hey all Feb 25 07:38:17 damn online Kotlin Koans! They are dumb, anyway... Feb 25 07:42:59 how would I do an action on the result of two separate asynchronous callbacks? Feb 25 07:43:15 is having two boolean flags the only way? Feb 25 07:43:42 an rx guy would advise to use combine latest Feb 25 07:43:45 or something like that Feb 25 07:44:08 hm, sounds interesting, ill look into that Feb 25 07:44:31 but im not really an rx guy, yet Feb 25 07:46:41 man, rxjava looks super complicated lol Feb 25 07:47:47 without using rx, I suppose the only way is to use two boolean flags then Feb 25 07:48:13 or populate a list Feb 25 07:48:21 a counter Feb 25 07:48:31 but yeah, same concept Feb 25 07:49:37 boomber: just encapsulate the whole thing in another class. It won't look so ugly. Feb 25 07:49:58 boomber: you can make it generic too Feb 25 07:50:14 Melatonina: you mean just create another class that kicks off two asynctasks? Feb 25 07:50:39 hm, that could work Feb 25 07:50:42 boomber: yes, that manages the whole thing Feb 25 07:50:56 if you don't like refactoring, don't like generics and don't like RxJava then consider another activity Feb 25 07:50:59 and I suppose it would just hit a callback to the activity once both asynctasks have finished, passing in both pieces of data? Feb 25 07:51:11 exactly Feb 25 07:51:28 that sounds a lot better actually, I think I'll try that :) Feb 25 07:51:33 :) Feb 25 07:58:16 hey raoul11 and Melatonina :) Feb 25 07:58:28 o/ Feb 25 07:58:43 hi :) Feb 25 08:01:03 eagles0513875|2: how are you? Feb 25 08:01:21 excited got the rough cut of my kiosk app ready Feb 25 08:01:26 and working on my phone. Feb 25 08:01:32 :) Feb 25 08:01:35 good Feb 25 08:01:43 need to do alot of custom work though for wht I am wanting to achieve. Feb 25 08:01:51 ill be working on that a bit later on today if not today tomorrow Feb 25 08:02:00 working on my website trying to get my business going :) Feb 25 08:14:46 eagles0513875|2: business ftw! Feb 25 08:15:12 Melatonina: i have a great idea for such a tiny island that i live on Feb 25 08:15:21 this is on top of my current full time job Feb 25 08:15:33 where do you live? Feb 25 08:15:37 if I may ask Feb 25 09:05:36 Hey all.. Feb 25 09:05:44 hey Feb 25 09:06:10 I was just looking at rebuilding my system and I was considering a mac.. and visual studios. Feb 25 09:06:56 Given the wonderful experience of working with AS.. is VS starting to gain ground. Feb 25 09:07:38 Is anyone using VS for droid dev? Feb 25 09:07:45 (I mean anyone here) Feb 25 09:10:35 hey Feb 25 09:11:27 i'm using ubuntu with android sdk Feb 25 09:11:36 dont know about mac though Feb 25 09:16:17 Yeah.. visual studios doesn't run on linux.. Feb 25 09:16:53 I'm not a fan of "restart you computer" when I run into a gradle freeze. Feb 25 09:17:04 :) Feb 25 09:20:19 have you managed to use gradle to build .apk in android-sdk?? Feb 25 09:20:52 i downloaded sdk and dependancies and made new project Feb 25 09:21:21 the "hello world" gets loaded by defaault but i dont know how to build it. Feb 25 09:21:39 when i run ./gradlew build Feb 25 09:21:50 it gives me ERROR Feb 25 09:24:44 Perhaps you should investigate into the error Feb 25 09:33:23 well from what i understand its a gradle problem.. it says failed to build gradle.. Feb 25 10:00:47 Melatonina, u use rxjava1 or 2? Feb 25 10:02:54 raoul11: 1 Feb 25 10:04:17 seems like 2 is completely overwritten Feb 25 10:06:13 overwritten? Do you mean written from scratch? "Completely overhauled"? Feb 25 10:06:28 They had to make it match with Java 8 Streams Feb 25 10:06:37 for obvious reasons Feb 25 10:06:54 it would have been ridiculous if they didn't do it Feb 25 10:09:59 Melatonina which version are u using? Feb 25 10:10:05 1.2.1? Feb 25 10:13:05 compile 'io.reactivex:rxjava:1.1.6' Feb 25 10:13:26 OMG I'm so outdated Feb 25 10:17:03 Not very reactive of you Feb 25 10:17:03 ;p Feb 25 10:21:07 I trusted Android Studio. It usually suggests updates Feb 25 10:23:52 hi Feb 25 10:24:08 I've implemented an appwidgetprovider/broadcast receiver for a widget, so I've populated onUpdate method and I've added onReceive method Feb 25 10:24:36 unfortunately, though I've placed some log call in logcat, visual changes in my widget are not displayed Feb 25 10:24:55 in particular, onUpdate log message ia not displayed anymore in logcat Feb 25 10:25:29 I pastebin java code: http://pastebin.com/RDNC1Gyq Feb 25 10:25:56 any ideas? Feb 25 10:36:50 raoul11: now I'm using 1.2.1 Feb 25 10:54:35 when changing something about an activity in manifest in a flavor, do I have to specify the whole manifest or only the node I am changing? Feb 25 10:56:32 OK so, Only the part I am changing , cool Feb 25 11:14:12 Is it stupid to create a media selector instead of an Intent to provide a consistent UI when you can select and query for media from other sources as well? Feb 25 11:14:54 "create a media selector instead of USING an Intent" Feb 25 15:08:11 hey am having and issue with generated classes in build folder Feb 25 15:08:58 because the project packages are not recognized Feb 25 15:49:03 Does anybody have experience with using the linear accelerometer in Android, or otherwise using high-pass filters on the accelerometer data? Feb 25 15:52:57 hello - is this a good place to ask questions about flashing my samsung galaxy android phone. there are a lot of info on the web but it is a bit hard to distinguish good vs bad - especially for risky thing like this one Feb 25 15:54:01 vpathak: this is for developing android apps - ask in #android Feb 25 15:54:14 ok thanks Feb 25 15:54:26 or rather, #android-root I believe vpathak Feb 25 16:11:51 hey am having and issue with generated classes in build folder,because the project packages are not recognized Feb 25 16:39:53 hi all. I'm having some issues with my ui. I'm trying to use a viewPager within a Scrollview and scrolling doesn't work at all. I have created a custom ScrollView class that overrides the scroll behaviour (saw some discussions on SO on it) but I still can't scroll when the ui draws itself Feb 25 16:41:07 the problem is especially more pronounced on API 16 target on 233 dp devices where the view pager doesn't even show Feb 25 16:41:29 would anyone ever played with such a ui structure, or have any suggestions? Feb 25 16:41:57 on the old devices, scrolling works however the view pager isn't visible Feb 25 16:47:35 horizontal scroll? vertical scrollview horizontal viewpager? Feb 25 16:53:57 hey am having and issue with generated classes in build folder,because the project packages are not recognized Feb 25 16:54:01 raoul11, I have a vertical scroll view and a horizontal viewpager Feb 25 16:54:22 did u set a height for the viewpager? Feb 25 16:54:41 i got a recyclerview with each row as a viewpager Feb 25 16:54:58 I have set the hieght to wrap Feb 25 16:55:02 wrap_content Feb 25 16:55:06 try fixing a height Feb 25 16:55:19 i'm using a ListFragment Feb 25 16:55:25 in my view pager Feb 25 16:55:41 raoul11, I have tried that, but to no avail Feb 25 16:55:57 each pager item is a fragment? Feb 25 16:56:42 raoul11, that's correct Feb 25 16:58:17 donno, from some SO posts iv seen, its usually not setting a fixed height on the viewpager Feb 25 16:58:40 http://i67.tinypic.com/2agkmyo.png Feb 25 16:58:42 but again, i am using a RV Feb 25 16:59:01 RV within SV? Feb 25 16:59:13 or RV within viewpager Feb 25 16:59:24 in fragments Feb 25 16:59:26 viewpager as a row inside an RV Feb 25 16:59:37 with just plain views, like an inline image gallery Feb 25 16:59:41 oh ok, wow that must be something Feb 25 16:59:48 why do u need a scrollview btw? Feb 25 16:59:54 looking at the picture Feb 25 17:00:02 its the way that I have designed the ui Feb 25 17:00:14 well I need to scroll to see the viewpager Feb 25 17:00:36 you can see just the header at the bottom Feb 25 17:00:44 but the scrolling doesn't occur Feb 25 17:01:16 was reading on SO, that a custom scroll view is needed as some events might not be caught or misinterpreted, however the solutions didn't work for me Feb 25 17:01:44 which part of the ui is suppose to be the viewpager? Feb 25 17:04:42 where you see synopsis Feb 25 17:04:47 just below is the viewpager Feb 25 17:04:56 but I reckon I might be going about the wrong way here Feb 25 17:05:10 I'm fighting the framework thus why it isn't working Feb 25 17:06:07 thats part of the fun no? Feb 25 17:06:45 did u try .requestDisallowInterceptTouchEvent on the parent? Feb 25 17:07:08 during the viewpager onTouch listener? Feb 25 17:07:43 I tried on the scroll view not on the viewpager Feb 25 17:08:13 any examples? Feb 25 17:09:09 also when I scroll I press above the viewpager Feb 25 17:09:18 http://stackoverflow.com/questions/8381697/viewpager-inside-a-scrollview-does-not-scroll-correclty Feb 25 17:09:24 so I don't see how the viewpager might be capturing the events at that point Feb 25 17:09:53 try the first answer Feb 25 17:10:30 basically disable the parent (SV) scroll when theres a touch event in the viewpager Feb 25 17:13:09 raoul11, I had already that one, but the problem is that it never scrolls in the first place for me to get to the viewpager Feb 25 17:13:27 oh Feb 25 17:13:40 if I could the view to scroll and say not have the viewpager scroll horizontally then I would be in a better place I think Feb 25 17:13:54 the problem is it doesn't even want to scroll, the view remains static Feb 25 17:14:31 as if having a viewpager inside a scroll view breaks everything Feb 25 17:14:41 you sure its the vp thats causing the sv to break? Feb 25 17:14:50 like, without the vp does it scroll ok? Feb 25 17:15:32 yes it used to work fine without it, that's how it was before I added the VP Feb 25 17:15:57 whats the main child on the sv? Feb 25 17:15:58 on an old target API, the scroll works but then the VP doesn't show Feb 25 17:17:41 LL Feb 25 17:18:42 \: Feb 25 17:20:09 http://pastebin.com/bUhzwqr7 Feb 25 17:20:14 this is how my view looks Feb 25 17:26:10 removed the vp and it scrolls perfectly fine Feb 25 17:26:14 sigh .. Feb 25 17:31:10 Gooood morning Feb 25 17:35:57 raoul11, anyhow, thanks for your help Feb 25 17:53:58 What would be a good way to measure accelerometer accuracy Feb 25 18:00:04 freefall? :) Feb 25 18:01:53 might be a little hard to achieve :p Feb 25 18:23:31 easy for very short periods of time Feb 25 18:23:45 ;-) Feb 25 18:26:23 is there any android expert that can help me to resolve an error Feb 25 18:27:08 classes in build folder are not resolving project packages Feb 25 18:27:08 + Feb 25 18:28:15 Pastebin ur error Feb 25 18:30:16 whatitis, error: cannot find class symbol Model; error: package Model does not exist Feb 25 18:33:42 Are you using android studio? Feb 25 18:34:17 edi__: still the same error as yesterday? Feb 25 18:37:56 yep Feb 25 18:38:09 am stuck Feb 25 18:38:40 Is model in your package? Feb 25 18:39:44 no Model is a package Feb 25 18:40:28 but it says that package Model does not exist Feb 25 18:40:35 Faizan: there are two sources of errors: inaccuracy (accelerometer reporting a wrong information) and sampling rate (between two samples you are forced to consider the acceleration constant, and so speed while performing the second integration). As for the first source, you should perform some controlled experiment. The second can be estimated in a more theoretical way. Make an hypothesis about the kind of motion equation of the object you are Feb 25 18:40:35 trying to follow, then compute how the errors would accumulate with two integration if you sampled that movement with an accelerometer having perfect accuracy, with the available sampling frequency Feb 25 18:41:13 Faizan: what kind of degree are you getting, if I may ask? Feb 25 18:41:23 I am trying to implement LoganSquare Feb 25 18:41:32 Melatonina: Computer Science major Feb 25 18:41:56 as I said it generate clsses in build folder Feb 25 18:42:45 but even it seems correct the import statement of package model it cannot find it Feb 25 18:42:45 As for inaccuracy measurement, that's one of my experiments. Recording the sensor data of a still device, in an isolated room with no vibrations, and plotting the readings over time Feb 25 18:42:53 Any fluctuations are therefore, purely noise Feb 25 18:44:31 that's a good experiment. If you get enough noise, integrating that noise as in that video should be a good enough proof. Feb 25 18:44:57 any help please Feb 25 18:45:02 Yeah exactly, just waiting for access to the room :) Feb 25 18:45:10 Thanks for the tips. Feb 25 18:45:35 Finally convinced my supervisor that using an android IMU wasn't a good approach, so just want a solid evaluation for my thesis Feb 25 18:59:24 Does anyone see any returned URLs here usable in Android? The returned formats just cause a VideoView to throw the "Can't Play Video" error Feb 25 18:59:30 url: https://dev.twitch.tv/docs/v5/guides/clips-discovery/ Feb 25 19:00:22 If I go to a web browser and use the clip url, and then copy the video address, that kinda works, but the dimensions are out of whack. Feb 25 19:00:42 But I don't see anything usable returned from the api. Feb 25 19:07:58 pleasehelp me because am running out of time Feb 25 19:10:25 please tell us when you'll actually run out of time Feb 25 19:10:50 did you clean your project? Feb 25 19:11:10 did you attempt to recreate the project from scratch? Feb 25 19:25:02 ny help for my problem Feb 25 19:25:41 a;;p Feb 25 19:27:09 hi guys Feb 25 19:27:13 anyone here Feb 25 19:27:53 Hello! Welcome to "#android-dev", please use !ticket if you have a question. Feb 25 19:34:45 edi__: Feb 25 19:34:49 did you clean your project? Feb 25 19:34:52 did you attempt to recreate the project from scratch? Feb 25 19:36:27 well, good luck edi__ Feb 25 19:36:58 Melatonina, it is a bit b ig Feb 25 19:38:28 big, i have clean but classes in apt folder cannot find packages in project Feb 25 19:39:15 apt is a folder in build/generated Feb 25 19:41:44 I had that problem too Feb 25 19:41:46 once Feb 25 19:41:51 I don't recall the fix Feb 25 19:42:01 but it was something stupid Feb 25 19:42:05 once you know it Feb 25 19:45:07 I'm new to Android development, and am using ButterKnife with RxJava. Is it better to use ButterKnife's @OnClick or the RxView.clicks() binding to hook up a button to a click handler? Feb 25 19:45:37 @OnClick seems easier in that it requires less boilerplate, but maybe I'm missing something. Feb 25 19:47:28 Melatonina, can you please try to recall it Feb 25 19:47:42 i am really stuck there Feb 25 19:51:48 occultbloodtaco: If you need rxjava when handling the click, you probably want the RxView thing. Otherwise, whatever is easiest Feb 25 19:52:41 Cool - ty! Feb 25 20:09:38 i want to thank all people that tried to help me. I am going to do a deep research about my problem and if I cannot solve it i will see Gsson Feb 25 20:20:45 Melatonina, wtf, the error was that the first letter of package was upper case Feb 25 20:32:50 Hey, does google mind if I also allow download of my APK from my website? Feb 25 20:35:34 no Feb 25 21:09:15 can you suggest a Firebase opensource alternative to have db/api exposed? Feb 25 21:23:21 hello! I’m trying to use http://stackoverflow.com/questions/11256563/how-to-set-both-lines-of-a-listview-using-simple-list-item-2 Feb 25 21:23:44 I’m using the getView override trick Feb 25 21:24:37 In the setText i don’t get the persons thing Feb 25 21:24:58 where does this variable come from? Feb 25 21:25:53 I actually want to use list (last argument from the new ArrayAdapter, but i can’t use it: needs to be declared final Feb 25 21:27:48 http://pastebin.com/nyg4Dat4 Feb 25 21:30:02 what's the blocking issue with final? Feb 25 21:33:24 tried this: final ArrayList games = gameList; Feb 25 21:33:58 well I just don’t understand how to make that argument gameList final Feb 25 21:34:37 stick it in the method declaration if that's the issue Feb 25 21:35:39 won’t work, same error Feb 25 21:35:42 on gamelist Feb 25 21:35:57 is accessed from within inner class, needs to be declared final Feb 25 21:36:04 public void updateGameList(final List gameList) { ... } should be just fine. Feb 25 21:37:24 hmmmmm looks obvious, never knew i could that with arguments from functions as well Feb 25 21:48:33 ok it works :) Feb 25 21:49:57 Java 8 does away for having to manually declare it for things that are "effectively final" anyway, though I don't know if that's one of the Java 8 features they've got in that Jack thing. Feb 25 21:56:08 ok next issue… Attempt to invoke virtual method 'void android.widget.TextView.setText(java.lang.CharSequence)' on a null object reference Feb 25 21:56:41 I’ve tried to replace the simple_list_item_2.xml with my own custom_simple_list_item_2.xml Feb 25 21:57:12 id text1 and text2 are in my new layout file Feb 25 21:57:21 like the original Feb 25 21:59:19 http://pastebin.com/EcC1CkVm Feb 25 21:59:59 Hey all! I'm working on an app for myself and I'm having an issue with the text "jumping" around in a textview. I've basically made a stopwatch with a textview displaying the time(updates every 50-100ms) and when I try to use a different font, every time a digit changes all the text shifts a little. Feb 25 22:00:06 It does not do this using the default font(roboto if I'm not mistaken) Feb 25 22:02:03 to ask the dumb question :) does it show the same number of digits in general? Feb 25 22:02:42 kbs, Yea! Feb 25 22:02:57 00:00:00.00 Feb 25 22:03:08 in general (naturally) any non-fixed font will exhibit this problem, if you directly write the complete string Feb 25 22:03:36 I would have thought the default roboto is not a fixed-font (for digits) but at any rate, the quick fix might be to provide a fixed-widh font? Feb 25 22:04:15 Yea I checked out a few monospace fonts and they seemed to not have the issue(duh!) but the choices where limited and I feel like there SHOULD be a way to use any font I want Feb 25 22:04:42 I'm 95% sure roboto is non fixed-width Feb 25 22:05:06 https://fonts.google.com/specimen/Quantico Feb 25 22:05:13 Is the font I was hoping to use. Feb 25 22:05:38 so the basic issue is just that the fonts are designed to squeeze closer (e.g. 31 33) . In principle, you could write each character at a specific position if you don't mind taking the effort to find the max width for the characters you need, and spacing them that much apart Feb 25 22:06:14 Roboto Mono existss Feb 25 22:06:34 you want a mono space font Feb 25 22:06:44 Ha, that's the same route I took in my head(loop over all letters, find the widest char, loop through all chars, set width to max width) Feb 25 22:06:57 But I really have no idea how to achieve that! Feb 25 22:07:35 pfn, Ideally yea. But I was having trouble finding one that fits what I want(in terms of style) Feb 25 22:08:22 take a look at Paint.measureText Feb 25 22:09:09 but yes - if your font happens to be not fixed-width, you'll need to fiddle in code. An alternate (if you're comfortable editing fonts) is to copy the digits you need, and edit the font metrics in the font file directly Feb 25 22:09:49 (i.e., convert to a fixed width font :) Feb 25 22:09:52 kbs, Hmm. That font editing could work. Feb 25 22:21:07 hey guys, I have a recyclerview right now that allows items to be checked/unchecked... how can I keep track of if an list item is checked/unchecked without modifying my data model? Feb 25 22:24:36 one way would be to add hashmap position-isChecked to adapter Feb 25 22:25:19 yeah, that's what I was thinking, but some items can be "checked" already when the adapter is created Feb 25 22:25:31 I suppose I would have to create that boolean list myself in the constructor? Feb 25 22:27:14 yes Feb 25 22:27:31 boomber Why can't you change your data model? The checked state is state of the item, not state of the adapter. Feb 25 22:27:55 thing is I only want to save that state when they click a "save" button Feb 25 22:28:25 Like, they can check/uncheck an item and only after hitting save do I want to mark an item as checked and save to teh db Feb 25 22:29:30 hm, I suppose I could just not save the result to the DB unless they hit save though Feb 25 22:29:39 I think I'll try that out and just modify the data model Feb 25 22:30:04 either change model or add relation object<>boolean Feb 25 22:30:32 yeah the model can already tell if it should be checked or not, I just didn't want to modify it in case the user didn't hit save Feb 25 22:30:50 but if they dont hit save then I would just never save it to the DB I suppose Feb 25 23:15:19 Hey is anyone in here a Mockito guru? Feb 25 23:16:46 trying to.. Mockito.doReturn(KeyEvent.ACTION_DOWN).when(keyEvent).getAction(); Feb 25 23:16:54 keyEvent is a mocked KeyEvent Feb 25 23:22:13 That looks reasonable enough, but any reason to not just use the standard when(keyEvent.getAction()).thenReturn(KeyEvent.ACTION_DOWN) form instead? Feb 25 23:43:17 fizzie Feb 25 23:43:25 yeah that's the ide.. I got it to work but I had to do.. Feb 25 23:43:26 Mockito.doReturn(keyEvent.ACTION_DOWN).when(keyEvent).getAction(); Feb 25 23:43:39 notice that I'm using the mocked keyEvent instead of KeyEvent Feb 25 23:44:02 weird but I guess Mockito doesn't like to return anything that's not of the Mocked class Feb 25 23:47:50 nvm that didn't work :( Feb 25 23:48:37 Good, because it would not have made any sense, because KeyEvent.ACTION_DOWN is just a number. Feb 25 23:49:27 hmm maybe just returning the int value would suffice Feb 25 23:50:29 Both doReturn(X).when(mock).method() and when(mock.method()).thenReturn(X) should be fine, though the latter is officially recommended except for some special cases where the former is required. Feb 25 23:52:14 when() requires an argument which has to be 'a method call on a mock'. Feb 25 23:52:17 :/ Feb 25 23:53:08 http://pastebin.com/J27jGqA8 Feb 25 23:53:20 lines 15 and 16 Feb 25 23:55:44 Well, the argument *is* 'a method call on a mock'. Feb 25 23:56:23 but that's not my class :/ Feb 25 23:57:20 android.view.KeyEvent Feb 25 23:57:46 That shouldn't matter. Feb 25 23:57:52 If it's an IDE warning or something, maybe it's expecting the style where you do @Mock annotations and inject the mocks, since that way it's presumably easier to tell mocks from non-mocks. Feb 25 23:58:08 it's a compile-time exception Feb 25 23:58:20 I'll give that a go Feb 25 23:58:37 sorry it's a runtime exception Feb 26 00:07:52 ugh i'm silly. I can initialize KeyEvent.. For some reason I thought it was abstract.. Feb 26 00:09:54 Heh, I didn't even consider that. By any means use a real object instead of a mock if you can. Feb 26 00:21:46 key events are just the start 😀 Then we can explore mouse, touch, and pointerEvents 🐁☝️🖋️ Feb 26 00:34:43 If I have an adapterview for a spinner, do I need to register the spinner for menu click changes? Feb 26 00:35:35 http://pastebin.com/JTu30LLq - I have this code but it never seems to go into the onItemSelected callback Feb 26 00:41:01 your code is a bit incomplete Faizan Feb 26 00:41:09 Faizan, where are you setting the callback Feb 26 00:41:16 doesnt show in the code Feb 26 00:41:34 but I'd guess that you are either not implementing the interface somewhere, becasue I don't see the @Override annotation on your listener Feb 26 00:41:50 and then I don't see you setting adapter.setOnItemSelectedListener(foo) Feb 26 01:27:54 Is it possible in mockito to call a method of in a subclass by mocking the parent class? Feb 26 01:28:10 i want to verify that a method in the parent class is called by a method in its subclass Feb 26 01:28:13 ..if that makes sense Feb 26 01:44:59 guys, how serious is a situation in which you want to modify how an application behaves for your usability? to get things straight, I want simply to reverse engineer swiftkey to permanently remove (or hide) the emoji icon - and this is solely for the purpose of me using it. is this condemned when talking about apks and the intention of it not being for cracking? Feb 26 01:45:02 Tricknology: If the method you want to verify the call of isn't hidden/overridden in the subclass, you might instead spy an instance of the subclass. (If it is, then I don't know of a Mockito way to do it.) Feb 26 01:46:18 murder, depends on the TOS or any agreements Feb 26 01:47:19 yeah I'm trying everything I can... kinda learning as I go. a bit frustrating but I believe I tried the spy.. it just says that nothing has been called in the parent class.. i got the "in fact..." message Feb 26 01:47:51 so I make a mock of parent. create a new memberclass by parent.new Subclass() Feb 26 01:48:25 then spy(subclass).doStuff() but nothing has toughed the player.method() Feb 26 01:50:08 I've heard Microsoft acquired SwiftKey, and as we all know for the past 25 years with their posture around DOS, Windows, etc - without considering strict TOS (as probably everything outside GNU/GPL/etc is 'private property') - how does the overall software development community think about it? Feb 26 01:50:39 in such a situation that I go to a job interview and mention this situation as something I've done Feb 26 01:53:41 I wouldn't mention that specifically Feb 26 01:54:01 you're better off meddling open source if that's what you want to do - use it in a job interview Feb 26 01:54:37 but then again, the right interviewer might be looking for instances where you've gone above and beyond to solve a problem.. but that method isn't legal so questions about ethics would arise Feb 26 02:01:18 Aren't ethics orthogonal to legality? Feb 26 02:18:43 Hi all - anyone here ? Feb 26 02:18:50 Yes Feb 26 02:21:53 i got bit and byte questions still struggling from yesterdya - Feb 26 02:23:32 I converted 0b to binary using > int intValue = Integer.parseInt(inputValue, 16 ); then padding it with 0s using String.format("%8s", Integer.toBinaryString( intValue & 0xFF)).replace(' ', '0'); I ended up with 00001011 Feb 26 02:24:22 no I want to get the values of bits 4-6 how do i do that ? Feb 26 02:29:45 ty Tricknology Feb 26 02:30:56 str.substring(4,6) Feb 26 02:31:31 methings bitchift would be more efficient here Feb 26 02:31:37 bit shift Feb 26 02:40:49 Tricknology: If I use substring(4,6) on 00010011 I get 0 : according to my docs (based on the settigns I have) I should be getting the value of 3 Feb 26 02:41:12 are you counting your bits from 1 or 0 on the left? Feb 26 02:41:44 Tricknology: How can I tell ? Feb 26 02:42:16 011 is 3 Feb 26 02:42:46 "00010011".substring(5) Feb 26 02:43:31 how are you counting bits 4-6.. which bits are those in 00010011 ? Feb 26 02:44:05 That;s what I'm not sure about Tricknology Feb 26 02:44:33 my docs says > To get the temp range use Bits 4-6 : 0 = 30-41 : 1 = 30-43 : 2 = 30-47 (temperature set range) Feb 26 02:44:33 0 is bit 8 (on the left) Feb 26 02:44:55 bits 4-6 of what? Feb 26 02:44:58 do you have some hex? Feb 26 02:46:02 on this one 13 Feb 26 02:46:05 You're getting this out of a sensor I'm gathering.. what is the output? Int? Feb 26 02:46:11 string? Feb 26 02:46:14 string Feb 26 02:46:26 Yes Tricknology from a sensir Feb 26 02:47:13 ok, the byte all the way on the right is bit 0 Feb 26 02:47:53 ok so if I substring > 00010011 I'm going backwards ? Feb 26 02:48:14 whats the right way to get the value I need ? Feb 26 02:49:33 sinsgting(1,3) i think Feb 26 02:49:37 substring* Feb 26 02:50:00 or substring(1,4) Feb 26 02:50:13 depending on if you want to include byte 4 or not Feb 26 02:50:23 that's not 3 though Feb 26 02:50:35 bits are not bytes Feb 26 02:50:39 but 011 is Feb 26 02:51:09 yeah he has 13h which is 00010011b Feb 26 02:51:25 but it's weird he things Bit 4-6 = 3d Feb 26 02:51:57 Tricknology: from my current setting its 13 (not 13d) Feb 26 02:51:58 bit 0 starts right counts up to the left Feb 26 02:52:17 depends on endianness I guess? Feb 26 02:52:28 still, that's not 3 Feb 26 02:52:34 endianness ? Feb 26 02:52:48 heh Feb 26 02:52:52 big endian vs little endian, basically where you count the 0th bit - left or right Feb 26 02:53:19 thanks IBM and Intel Feb 26 02:53:27 ibm offers differing endianess machines Feb 26 02:53:46 good for them Feb 26 02:54:05 I just remmember having such a headache due to endianness Feb 26 02:54:05 even amongst their differing platform hardware architecturs Feb 26 02:54:37 yah, you gotta love studying the core design Feb 26 02:54:43 oh bugger ;;; Feb 26 02:54:58 yay for macros Feb 26 02:55:02 but fels Feb 26 02:55:05 I befriended sn EE so he could explain it Feb 26 02:55:15 in your case, it doesnt make sense for 4-6 to be 3(decimal) in either case Feb 26 02:55:25 what if I reverse the string : from > 00010011 to 11001000 then do substring (4,6) Feb 26 02:55:52 the only thing in binary thats going to get you 3 is 011 Feb 26 02:56:28 buy not bitwise shift 4 times? Feb 26 02:56:48 nvm Feb 26 02:57:54 substring is a char operation, not a bitwise Feb 26 02:58:10 char == byte Feb 26 02:58:24 == 8 bits Feb 26 02:58:51 sorry... :) what are you trying to do? Feb 26 02:59:30 or are you representing boolean 1 and 0 ad string chars? Feb 26 02:59:37 *as Feb 26 02:59:46 he is yes Feb 26 02:59:53 String.format Feb 26 02:59:53 oh dear Feb 26 02:59:55 lol **** ENDING LOGGING AT Sun Feb 26 03:00:01 2017