Can you show us some sample code that demonstrates the problem?
It may be that you have to manage tags in some fashion so that deleted tags can be reused. One way to do that would be to keep a high water mark variable and a stack of available tags. If the stack is empty use the tag number from the high water mark variable and bump the variable. When you delete a tag, push it onto the stack.
True laziness is hard work
| [reply] |
Hi,
I assume you are talking about the item-id returned by the createITEM - method. It would not be very useful having these wrap, because if they did, how would you ensure their uniqueness. Concerning your problem: If you can find a point in your program where all items are deleted, you could recreate the canvas there and get a new id-counter.
Cheers, Christoph | [reply] |