Another small lib I want to share.
The only feature is called ListView2 which acts like an normal ListView (from Core) but supports a CharSequence for all labels.
So can use normal Strings as text or RichStrings for more color and formats.
specci48
I have had extreme problems with my program crashing with Fatal Signal 11 and Error 7 just at the end of the 'End Sub' when I have a subroutine such as this:
sub Globals
Dim lvMenus As ListView2
end sub
sub Activity_Create
lvMenus.Initialize("lvMenus")
end sub
Sub lvMenus_ItemClick(Position As Int, Value As Object)
lvMenus.Visible = False
CallSubDelayed2("", "Do_Menu_Item", Position)
End Sub
The crash is random; doesn't always occur. When iz change them from ListView2 to ListView the crash goes away (and, unfortunately, the RichString colors also go away... oh well).
The ListView is populated with lines of text which form a menu of choices which you click-on. Once the user has clicked on it, the function number is sent via Position to the lvMenus_ItemClick() rountine and then on to a 'Menu Choice' routine which handles the menu choice subs.
I would suspect that your ListView2 is closing something; but it doesn't close fast-enough, or something?
Any idea how to get around the problem? I could just throw away the idea of having colored menu items... but they look so nice. Works perfectly except when it crashes.
Every had anybody complain that they were getting Fatal Signal 11 errors from the library, sometimes? I can absolutely say without a doubt that it is the library which is doing it because whenever I change it to ListView instead of ListView2 the problem goes away (and when I use ListView2 it can crash about 1 out of 3 times).
Is there something I could delay doing somewhere? I could either set a flag to wait or do a timer that wastes some time... but the crash seems to occur after the End Sub occurs, not before; which I have no control over.