Edit: latest version of CustomListView is available here: https://www.b4x.com/android/forum/t...-cross-platform-customlistview.84501/#content
Last edited:
Assuming that the classes are well written and used correctly then you will not have any negative impact on performance.whether in a 'big' project containing many of such classes, would tend to use more resources than specialized routines.
Assuming that the classes are well written and used correctly then you will not have any negative impact on performance.
If you look at the code of SearchView and TableView you will see that they are highly optimized. This specific class is simpler as it is intended for limited sized lists (1000 - 2000 items).
Adding a panel just for holding a view, is it not a waste of resources?Note that in the example the two CustomListViews are added to two panels that are handled with the visual designer. You can use such a "holding" panels as the base for any custom view.
Dim r As Reflector
r.Target = r.GetContext
r.Target = r.RunMethod("getResources")
r.Target = r.RunMethod("getSystem")
Dim ID_PressedDrawable As Int
ID_PressedDrawable = r.RunMethod4("getIdentifier", Array As Object("list_selector_background_pressed", "drawable", "android"), Array As String("java.lang.String", "java.lang.String", "java.lang.String"))
r.Target = r.GetContext
r.Target = r.RunMethod("getResources")
PressedDrawable = r.RunMethod2("getDrawable", ID_PressedDrawable, "java.lang.int")
Is it possible to create a list with some products where user is suppose to pick as many as he wants and then, on the same line(item) to put a number(textboxview, up/down customview or something) near any item he choose?
For ex. one must pick some products and quantities on a single step!
I created two examples. The first is made with CustomListView, the second is made with another class
When I try to scroll down, application crush, saying "Sub pnlsvtouch signature does not match expected signature".
I am missing something?
My mistake. I forgot to mention that you need the latest Reflection library.
So if I wanna put two buttons near qty box, like - and +, do you think it could be done? I should add it in the panel in "CreateItem", right?
It's as simple as that.
Thanks, I already create that. Now I was just wandering, how to put the 3 views(plus/minus,qty) on the second line(on expanded panel), because to be honest... the list items tend to have more characters in description/name on real world app...
And one other thing(with is related with the one above).... I think you should implement a list on global process(or class) because one may "lose" item checked after screen rotation ie.
You don't need the expanded panel to create a second line. You just have to increase the item panel height and put the views below the existing ones.