diff options
Diffstat (limited to 'c/main.cpp')
-rw-r--r-- | c/main.cpp | 20 |
1 files changed, 9 insertions, 11 deletions
@@ -320,14 +320,9 @@ LRESULT CALLBACK WndProc(const HWND hWnd, const UINT uMsg, const WPARAM wParam, /*IDM_FILE_FETCH_DATA*/L"Fetch episode data from the web (may take a few seconds).", /*IDM_FILE_FETCH_SCREENWRITERS*/L"Fetch screenwriters from the web (may take a minute).", /*IDM_FILE_ABOUT*/L"Show information about Episode Browser.", - /*IDM_VIEW_WATCHED*/(g_bViewWatched? L"Click to hide watched episodes.": - L"Click to show watched episodes."), - /*IDM_VIEW_TV_ORIGINAL*/(g_bViewTVOriginal? - L"Click to hide TV original episodes.": - L"Click to show TV original episodes."), - /*IDM_VIEW_OTHERS*/(g_szLimitScreenwriter? - L"Click to hide episodes by other screenwriters.": - L"Click to show episodes by other screenwriters.") + /*IDM_VIEW_WATCHED*/L"Show/hide watched episodes.", + /*IDM_VIEW_TV_ORIGINAL*/L"Show/hide TV original episodes.", + /*IDM_VIEW_OTHERS*/L"Show/hide episodes by other screenwriters." }; static const wchar_t* aWszCtx[] = { /*IDM_WATCH_LOCALLY*/L"Open local copy of episode, if available.", @@ -351,9 +346,12 @@ LRESULT CALLBACK WndProc(const HWND hWnd, const UINT uMsg, const WPARAM wParam, const unsigned short wCommand = LOWORD(wParam); const unsigned short wGroup = ID_GROUP(wCommand); - if (!wGroup) break; - const wchar_t** aWsz = wGroup==IDG_MENU? aWszMenu: aWszCtx; - SendMessage(g_hWndStatus, SB_SETTEXT, MAKEWPARAM(0,0), (LPARAM)aWsz[ID_INDEX(wCommand)]); + const wchar_t* wsz = {0}; + if (wGroup) { + const wchar_t** aWsz = wGroup==IDG_MENU? aWszMenu: aWszCtx; + wsz = aWsz[ID_INDEX(wCommand)]; + } + SendMessage(g_hWndStatus, SB_SETTEXT, MAKEWPARAM(0,0), (LPARAM)wsz); break; } default: |