[BROWSEUI] Add checkmark for Explorer bar menu items (#7229)

Improve UI/UX.
JIRA issue: CORE-19689
- In the CShellBrowser::OnInitMenuPopup method,
  check/uncheck menu items depending on
  fCurrentVertBar.
This commit is contained in:
Katayama Hirofumi MZ 2024-08-10 22:15:23 +09:00 committed by GitHub
parent 73bed31363
commit 81ec056963
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1823,6 +1823,19 @@ void CShellBrowser::UpdateViewMenu(HMENU theMenu)
SetMenuItemInfo(theMenu, IDM_VIEW_TOOLBARS, FALSE, &menuItemInfo);
}
SHCheckMenuItem(theMenu, IDM_VIEW_STATUSBAR, m_settings.fStatusBarVisible ? TRUE : FALSE);
// Check the menu items for Explorer bar
BOOL bSearchBand = (IsEqualCLSID(CLSID_SH_SearchBand, fCurrentVertBar) ||
IsEqualCLSID(CLSID_SearchBand, fCurrentVertBar) ||
IsEqualCLSID(CLSID_IE_SearchBand, fCurrentVertBar) ||
IsEqualCLSID(CLSID_FileSearchBand, fCurrentVertBar));
BOOL bHistory = IsEqualCLSID(CLSID_SH_HistBand, fCurrentVertBar);
BOOL bFavorites = IsEqualCLSID(CLSID_SH_FavBand, fCurrentVertBar);
BOOL bFolders = IsEqualCLSID(CLSID_ExplorerBand, fCurrentVertBar);
SHCheckMenuItem(theMenu, IDM_EXPLORERBAR_SEARCH, bSearchBand);
SHCheckMenuItem(theMenu, IDM_EXPLORERBAR_HISTORY, bHistory);
SHCheckMenuItem(theMenu, IDM_EXPLORERBAR_FAVORITES, bFavorites);
SHCheckMenuItem(theMenu, IDM_EXPLORERBAR_FOLDERS, bFolders);
}
HRESULT CShellBrowser::BuildExplorerBandMenu()