[XForms] Question #2: Relying on menu subitem IDs after fl_delete_menu_item().

Jason Cipriani jason.cipriani at gmail.com
Thu Jul 3 16:53:23 EDT 2008


To subscribers of the xforms list

Let's say I have a menu with these items, created in fdesign:

1. Red
2. Green
3. Blue

So the IDs (returned by fl_get_menu) are 1, 2, and 3.

If I use fl_delete_menu_item() to remove the second item (id = 2),
then I've observed that the IDs of the other menu items do NOT change,
leaving the menu like this:

1. Red
3. Blue

This is convenient and is what I want to happen, I was pleasantly
surprised when I noticed it. However, I was always under the (possibly
incorrect) impression that menu item IDs *always* corresponded to the
index of the item (so Blue would have been changed to 2 rather than
remaining as 3).

Is this ("Blue" keeping it's ID of 3) a bug that coincidently worked
out well for me? Or is this intentional behavior that I can rely on in
the future?

Thanks,
Jason
_______________________________________________
To unsubscribe, send any message to
xforms-leave at bob.usuhs.mil or see: 
http://cweblog.usuhs.mil/mailman/listinfo/xforms
List Archive: http://bob.usuhs.mil/pipermail/xforms and
http://bob.usuhs.mil/mailserv/list-archives/
Development: http://savannah.nongnu.org/files/?group=xforms



More information about the Xforms mailing list