![]() ![]() I have more on this issue in this blog post. Or, have your viewmodel hold onto the previous Configuration and compare it with the current one in onCreate() of your activity. So, some of those "change the system theme" apps might trigger this same unblockable configuration change.Īs Nguyễn Hoài Nam notes, you can detect this from onConfigurationChanged() of a custom Application. There are other edge cases for this - this whole "unblockable configuration change" thing came about when Sony got Google to add support for runtime resource overlays (RROs) back in 2017. (diff.toLong() and 0x80000000) != 0L will evaluate to true if a wallpaper change or something similar triggered the configuration change. Here, vm.originalConfiguration points to the older Configuration, and we get the current Configuration from the Resources object. ![]() Somebody in the comments suggested a formula for converting an XYPosition to an index value, I came up with the following method which works: Relying on the code snippets isn't enough.įormula for converting XY position to an index I would recommend you clone PyxlMoose and reproduce the errors, then work from there. I've tried myself to fix these issues but haven't had much success, so I'm offering 50 reputation for anyone who can assist. I understand that this question is extremely difficult to answer and will require a lot of thinking. This is so anyone who wants to help me fix this can have a look at my code and reproduce the bugs. I've actually pushed the fill tool to GitHub as a KIOL (Known Issue or Limitation), so the user can use the fill tool if they want, but they need to be aware of the limitations/issues. So I have two one major problem, if anyone can try and find a solution for it, it would be great because I have tried to myself without much luck. Implementation-wise it is quite messy unfortunately because of the whole list index to XYPosition conversions, but at least it works - the only problem is the performance. Any help would be appreciated to fix this issue.Īpologies if I didn't do a good enough job of explaining the exact issue, but I have tried my best. Converting the code to use a map increased the speed by around 20%, although the algorithm is still slow.Īfter spending a couple of days trying to make the algorithm work faster, I'm out of ideas and I'm unsure why the expandToNeighbors function is taking a long time. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |