Android Tutorial [XUI] CustomListView with floating titles

clv_floatingtitle.gif


Title items are added to the list.
A Panel is set above the list. The panel shows the current title when the top visible item is not a title item.

It works by checking for the top item type. If it is a title item then the panel is hidden, otherwise the panel is shown with the current title.

The title layout should be anchored to the bottom. This allows the same layout to be loaded to the panel and to the cell items.
The panel is slightly taller to compensate for the two dividers.
It is recommended to remove the call to AutoScaleAll. Otherwise the switch between the cell title and the panel title will not be accurate (as the variants sizes are different).

It should be simple to implement the same solution in B4J and B4i.
 

Attachments

  • CLV_FloatingTitle.zip
    9.4 KB · Views: 1,164
Last edited:

love2you

New Member
I have a question.
To refresh the list, some sentences in Activity_Create were moved to sub AAAAA.
And I created Button and tried calling AAAAA from Button1_Click.
It worked well until I pressed the button, but when I pressed the button, only the default value(Title) appears on the floating table.
Do you know how to solve this problem?
I am beginner and I am poor at English. I am very sorry about this.
 

Attachments

  • CLV_FloatingTitle_Question.zip
    12 KB · Views: 416
Top