fix crash ViewMenu