bold items in some context menus, fix #3516233
This commit is contained in:
parent
4353064ead
commit
edf03984f2
|
@ -361,7 +361,7 @@ BOOL CALLBACK CheatConsoleCallB(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM l
|
|||
if (selcheat >= 0) {
|
||||
// Open IDC_LIST_CHEATS Context Menu
|
||||
hCheatcontextsub = GetSubMenu(hCheatcontext,0);
|
||||
|
||||
SetMenuDefaultItem(hCheatcontextsub, CHEAT_CONTEXT_TOGGLECHEAT, false);
|
||||
if (lParam != -1)
|
||||
TrackPopupMenu(hCheatcontextsub,TPM_RIGHTBUTTON,LOWORD(lParam),HIWORD(lParam),0,hwndDlg,0); //Create menu
|
||||
else { // Handle the context menu keyboard key
|
||||
|
|
|
@ -1197,7 +1197,7 @@ BOOL CALLBACK DebuggerCallB(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPara
|
|||
if (SendDlgItemMessage(hwndDlg,IDC_DEBUGGER_BP_LIST,LB_GETCURSEL,0,0) >= 0) {
|
||||
// Open IDC_LIST_CHEATS Context Menu
|
||||
hDebugcontextsub = GetSubMenu(hDebugcontext,0);
|
||||
|
||||
SetMenuDefaultItem(hDebugcontextsub, DEBUGGER_CONTEXT_TOGGLEBREAK, false);
|
||||
if (lParam != -1)
|
||||
TrackPopupMenu(hDebugcontextsub,TPM_RIGHTBUTTON,LOWORD(lParam),HIWORD(lParam),0,hwndDlg,0); //Create menu
|
||||
else { // Handle the context menu keyboard key
|
||||
|
|
|
@ -384,7 +384,7 @@ TASEDITORCONTEXTMENUS MENU
|
|||
BEGIN
|
||||
POPUP "Selected"
|
||||
BEGIN
|
||||
MENUITEM "Set Markers", ID_SELECTED_SETMARKERS
|
||||
MENUITEM "Set Markers\tDbl-Clk", ID_SELECTED_SETMARKERS
|
||||
MENUITEM "Remove Markers", ID_SELECTED_REMOVEMARKERS
|
||||
MENUITEM SEPARATOR
|
||||
MENUITEM "Deselect", ID_SELECTED_DESELECT
|
||||
|
|
|
@ -1282,6 +1282,7 @@ void PIANO_ROLL::RightClick(LVHITTESTINFO& info)
|
|||
{
|
||||
SelectionFrames* current_selection = selection.MakeStrobe();
|
||||
HMENU sub = GetSubMenu(hrmenu, 0);
|
||||
SetMenuDefaultItem(sub, ID_SELECTED_SETMARKERS, false);
|
||||
// inspect current selection and disable inappropriate menu items
|
||||
SelectionFrames::iterator current_selection_begin(current_selection->begin());
|
||||
SelectionFrames::iterator current_selection_end(current_selection->end());
|
||||
|
@ -1293,15 +1294,14 @@ void PIANO_ROLL::RightClick(LVHITTESTINFO& info)
|
|||
else
|
||||
unset_found = true;
|
||||
}
|
||||
if (set_found)
|
||||
EnableMenuItem(sub, ID_SELECTED_REMOVEMARKER, MF_BYCOMMAND | MF_ENABLED);
|
||||
else
|
||||
EnableMenuItem(sub, ID_SELECTED_REMOVEMARKER, MF_BYCOMMAND | MF_DISABLED | MF_GRAYED);
|
||||
if (unset_found)
|
||||
EnableMenuItem(sub, ID_SELECTED_SETMARKER, MF_BYCOMMAND | MF_ENABLED);
|
||||
EnableMenuItem(sub, ID_SELECTED_SETMARKERS, MF_BYCOMMAND | MF_ENABLED);
|
||||
else
|
||||
EnableMenuItem(sub, ID_SELECTED_SETMARKER, MF_BYCOMMAND | MF_DISABLED | MF_GRAYED);
|
||||
|
||||
EnableMenuItem(sub, ID_SELECTED_SETMARKERS, MF_BYCOMMAND | MF_DISABLED | MF_GRAYED);
|
||||
if (set_found)
|
||||
EnableMenuItem(sub, ID_SELECTED_REMOVEMARKERS, MF_BYCOMMAND | MF_ENABLED);
|
||||
else
|
||||
EnableMenuItem(sub, ID_SELECTED_REMOVEMARKERS, MF_BYCOMMAND | MF_DISABLED | MF_GRAYED);
|
||||
POINT pt = info.pt;
|
||||
ClientToScreen(hwndList, &pt);
|
||||
TrackPopupMenu(sub, 0, pt.x, pt.y, 0, taseditor_window.hwndTasEditor, 0);
|
||||
|
|
Loading…
Reference in New Issue