else if (class == MENUPICK) { while (code != MENUNULL) { menuitem = ItemAddress(menu,code); switch (ITEMNUM(code)) { case USESYSEX_ITEMNUM : tool->flags ^= USE_SYSEX; break; case FREESYSEX_ITEMNUM : tool->flags ^= FREE_SYSEX; break; case SNAPSHOT_ITEMNUM : dosnapshot(tool); break; } code = menuitem->NextSelect; } }