From d9f5a46a6aa64598cba6f74b376f3bd11ea3cfc5 Mon Sep 17 00:00:00 2001 From: adelikat Date: Mon, 13 Apr 2009 14:51:07 +0000 Subject: [PATCH] Win32 - Gray out recent ROM menu item if there are no recent ROMs --- desmume/src/windows/main.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/desmume/src/windows/main.cpp b/desmume/src/windows/main.cpp index 407ac97c3..ac470c314 100644 --- a/desmume/src/windows/main.cpp +++ b/desmume/src/windows/main.cpp @@ -2285,6 +2285,9 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM EnableMenuItem(mainMenu, IDM_STATE_LOAD_F1+x, MF_BYCOMMAND | (romloaded) ? MF_ENABLED : MF_GRAYED); } + //Gray the recent ROM menu item if there are no recent ROMs + EnableMenuItem(mainMenu, ID_FILE_RECENTROM, MF_BYCOMMAND | (RecentRoms.size()) ? MF_ENABLED : MF_GRAYED); + //Updated Checked menu items //Pause @@ -2317,8 +2320,7 @@ LRESULT CALLBACK WindowProcedure (HWND hwnd, UINT message, WPARAM wParam, LPARAM MainWindow->checkMenu(ID_VIEW_DISPLAYMICROPHONE, MF_BYCOMMAND | ((ShowMicrophone)?MF_CHECKED:MF_UNCHECKED)); MainWindow->checkMenu(ID_VIEW_HUDEDITOR, MF_BYCOMMAND | ((HudEditorMode) ?MF_CHECKED:MF_UNCHECKED)); MainWindow->checkMenu(IDC_FRAMELIMIT, MF_BYCOMMAND | ((FrameLimit) ?MF_CHECKED:MF_UNCHECKED)); - - //TODO Recent ROMs gray if no recent roms + //Language selection //Frame Skip