[Slate-FHittestGrid] Can someone explains about comment in source code?
I was analyzing the slate input system. and I've faced the comment which i couldn't understand why.
can someone explains why this was necessary? when slate system finds appropriate widget that has hitted by cursor(or pointer), first look it up exact cursor point at that time you guys not check widget's IsInteractable() method. and after that it is not checked you guys do check widgets inside cursor's radius, but this time checks IsInteractable() I wonder what reason makes this behavior difference. Isn't that check widget's IsInteractable() in every case would be simpler and more robust? there are any reason behind that I couldn't find out?
I try to understand why and I have spend times to look it up other code around but i couldn't find a reason. can someone internal who knows history of this explains to me??
now i understand what's happening. in case who stumbled the same question, i leave my understanding.
1st of all point hittest accepts all hittestable widgets not just interactable. so it gets hittestted widget and if there are any interactable widget in parent hierarchy of hitted widget, it accepted. this thing makes many of widget is working based on parent widget's event handling. and next hittest with radius there are many other candidate which is not directly hitted by, so they just prioritized interactable widget, because there will be many candidates. i don't know this will gives better cognitive institution, but this is how it made up i guess.
answered Feb 26 '19 at 07:17 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here