fix "cancel button"-index problem