TextInputMessageBox::~TextInputMessageBox() { ToggleMenuShortcutKeys(true); MessageMenu* menu = (MessageMenu*)GetMenuByType(kMenuType_Message); if (menu) menu->HandleClick(menu->kButtonID_Close, 0); //closes the menu delete[] m_fmtString; }
static bool Cmd_SetButtonPressed_Execute(COMMAND_ARGS) { UInt32 button = 0; if (ExtractArgs(PASS_EXTRACT_ARGS, &button)) { MessageMenu* menu = (MessageMenu*)GetMenuByType(kMenuType_Message); if (menu) menu->HandleClick(menu->kButtonID_Button1 + button, 0); } return true; }