if _mouse_down / _mouse_up is executed but select_mode is NULL, then
this will crash.
Depends on D8828
I just encountered this when i wrote the tests. I could return earlier. However i like to either sanity check that earlier on, or only return at the end. This ensures that the function either "early" returns, or returns at the end of the function. This makes the function less branchy, and very easy to understand when reading the code :).
This does not appear in any particular widget. This happens in the testcase where i am just instanciating efl_ui_item. I know this is meant to be inherited from. However, I wanted to test the base implementation, so i decided that this little fix here would be beneficial for us, since we can test & verify the implementation of efl_ui_item.
I'm not in favor of this kind of change since it makes the code misleading by implying that this is a scenario which can regularly occur. The test should either have its own item implementation with a constructor to handle this or efl.ui.item should have a base constructor to handle this. I'd prefer the former.