[NUI] Fix scrollableBase focus issue. (#4340)
authorSangHyeon Jade Lee <sh10233.lee@samsung.com>
Fri, 17 Jun 2022 10:21:25 +0000 (19:21 +0900)
committerdongsug-song <35130733+dongsug-song@users.noreply.github.com>
Tue, 21 Jun 2022 10:27:08 +0000 (19:27 +0900)
commitbb2bb6429f03a56bf69034ccdb472a4dfd9aecac
treefd38835cc20662c23c4f357597609f19cc7f84cc
parentd957c84363eb7198e70fb46462419c381b794f86
[NUI] Fix scrollableBase focus issue. (#4340)

* [NUI] Fix scrollableBase focus issue.

fix several issue on focus of scrollableBase.

1. fix wrong focus fallback when next focused children is invisble.
- if current focused object is children of scrollableBase,
  keep focus to current focused object.
- if current focused object is out of scrollableBase,
  to keep focus within the scrollableBase, set focus on scrollableBase.

2. fix wrong next focus returns on next find failed case.
   if next focus find is failed, we can move scroll when key can move
   foward and backward only not other directions.
   In other direction inputs, escape the scrollableBase.

3. fix wrong escape condition of EOS(end of scroll).
   we escape scrollableBase in EOS, but we need to reached EOS firstly,
   and escape scrollableBase on next key input to move out.

4. add conditional debugging log.

5. fix focus samples.
   add text label for notify prev/current focused object.
   fix title of items.
   make padding longer on items.

* [NUI] fix samples.

* [NUI] return null as nextFocusedView will always null.

* [NUI] Update scrollableBase focus logic for missing cases.

* [NUI] Update scrollableBase focus to find next focus properly.

* [NUI] remove unreachable code.
src/Tizen.NUI.Components/Controls/ScrollableBase.cs
test/Tizen.NUI.Samples/Tizen.NUI.Samples/Samples/ScrollableFocus/ScrollableFocusAllChildrenSample.cs
test/Tizen.NUI.Samples/Tizen.NUI.Samples/Samples/ScrollableFocus/ScrollableFocusNoneChildrenSample.cs
test/Tizen.NUI.Samples/Tizen.NUI.Samples/Samples/ScrollableFocus/ScrollableFocusSparseChildrenSample.cs