diff --git a/reactos/dll/win32/devmgr/devmgmt/MainWindow.cpp b/reactos/dll/win32/devmgr/devmgmt/MainWindow.cpp index bb76e1e0cfa..01fb4ac9de6 100644 --- a/reactos/dll/win32/devmgr/devmgmt/MainWindow.cpp +++ b/reactos/dll/win32/devmgr/devmgmt/MainWindow.cpp @@ -29,23 +29,40 @@ static const MENU_HINT MainMenuHintTable[] = { IDC_EXIT, IDS_HINT_EXIT }, // Action Menu - { IDC_UPDATE_DRV, NULL }, - { IDC_DISABLE_DRV, NULL }, - { IDC_UNINSTALL_DRV, NULL }, - { IDC_SCAN_HARDWARE, IDS_HINT_REFRESH }, - { IDC_ADD_HARDWARE, NULL }, - { IDC_PROPERTIES, IDS_HINT_PROP}, + { IDC_PROPERTIES, IDS_HINT_PROPERTIES }, + { IDC_SCAN_HARDWARE, IDS_HINT_SCAN }, + { IDC_ENABLE_DRV, IDS_HINT_ENABLE }, + { IDC_DISABLE_DRV, IDS_HINT_DISABLE }, + { IDC_UPDATE_DRV, IDS_HINT_UPDATE }, + { IDC_UNINSTALL_DRV, IDS_HINT_UNINSTALL }, + { IDC_ADD_HARDWARE, IDS_HINT_ADD }, + // View Menu { IDC_DEVBYTYPE, IDS_HINT_DEV_BY_TYPE}, { IDC_DEVBYCONN, IDS_HINT_DEV_BY_CONN}, { IDC_RESBYTYPE, IDS_HINT_RES_BY_TYPE}, { IDC_RESBYCONN, IDS_HINT_RES_BY_TYPE}, + { IDC_SHOWHIDDEN, IDS_HINT_SHOW_HIDDEN }, { IDC_ABOUT, IDS_HINT_ABOUT } }; + + + +#define IDS_HINT_BLANK 20000 +#define IDS_HINT_PROPERTIES 20001 +#define IDS_HINT_SCAN 20002 +#define IDS_HINT_ENABLE 20003 +#define IDS_HINT_DISABLE 20004 +#define IDS_HINT_UPDATE 20005 +#define IDS_HINT_UNINSTALL 20006 +#define IDS_HINT_ADD 20007 +#define IDS_HINT_ABOUT 20008 +#define IDS_HINT_EXIT 20009 + // system menu hints static const MENU_HINT SystemMenuHintTable[] = { @@ -190,6 +207,17 @@ CMainWindow::MainWndMenuHint(WORD CmdId, return Found; } +void +CMainWindow::UpdateStatusBar( + _In_ bool InMenuLoop + ) +{ + SendMessageW(m_hStatusBar, + SB_SIMPLE, + (WPARAM)InMenuLoop, + 0); +} + bool CMainWindow::RefreshView(ViewType Type) { @@ -708,6 +736,18 @@ CMainWindow::MainWndProc(HWND hwnd, break; } + case WM_ENTERMENULOOP: + { + pThis->UpdateStatusBar(true); + break; + } + + case WM_EXITMENULOOP: + { + pThis->UpdateStatusBar(false); + break; + } + case WM_CLOSE: { // Destroy the main window diff --git a/reactos/dll/win32/devmgr/devmgmt/MainWindow.h b/reactos/dll/win32/devmgr/devmgmt/MainWindow.h index 7c6bbbe7c95..b7bbc78f72a 100644 --- a/reactos/dll/win32/devmgr/devmgmt/MainWindow.h +++ b/reactos/dll/win32/devmgr/devmgmt/MainWindow.h @@ -53,6 +53,10 @@ private: UINT uID ); + void UpdateStatusBar( + _In_ bool InMenuLoop + ); + bool MainWndMenuHint( WORD CmdId, const MENU_HINT *HintArray, diff --git a/reactos/dll/win32/devmgr/devmgmt/Resource.h b/reactos/dll/win32/devmgr/devmgmt/Resource.h index 3184e152acf..19151307b44 100644 --- a/reactos/dll/win32/devmgr/devmgmt/Resource.h +++ b/reactos/dll/win32/devmgr/devmgmt/Resource.h @@ -42,16 +42,21 @@ /* menu hints */ #define IDS_HINT_BLANK 20000 -#define IDS_HINT_REFRESH 20002 -#define IDS_HINT_PROP 20003 -#define IDS_HINT_HELP 20004 -#define IDS_HINT_ABOUT 20005 -#define IDS_HINT_EXIT 20006 +#define IDS_HINT_PROPERTIES 20001 +#define IDS_HINT_SCAN 20002 +#define IDS_HINT_ENABLE 20003 +#define IDS_HINT_DISABLE 20004 +#define IDS_HINT_UPDATE 20005 +#define IDS_HINT_UNINSTALL 20006 +#define IDS_HINT_ADD 20007 +#define IDS_HINT_ABOUT 20008 +#define IDS_HINT_EXIT 20009 #define IDS_HINT_DEV_BY_TYPE 20020 #define IDS_HINT_DEV_BY_CONN 20021 #define IDS_HINT_RES_BY_TYPE 20022 #define IDS_HINT_RES_BY_CONN 20023 +#define IDS_HINT_SHOW_HIDDEN 20024 /* system menu hints */ #define IDS_HINT_SYS_RESTORE 21001 @@ -60,4 +65,3 @@ #define IDS_HINT_SYS_MINIMIZE 21004 #define IDS_HINT_SYS_MAXIMIZE 21005 #define IDS_HINT_SYS_CLOSE 21006 - diff --git a/reactos/dll/win32/devmgr/devmgmt/lang/en-US.rc b/reactos/dll/win32/devmgr/devmgmt/lang/en-US.rc index f7c030f322f..79b535b3858 100644 --- a/reactos/dll/win32/devmgr/devmgmt/lang/en-US.rc +++ b/reactos/dll/win32/devmgr/devmgmt/lang/en-US.rc @@ -61,16 +61,21 @@ STRINGTABLE DISCARDABLE BEGIN IDS_APPNAME "ReactOS Device Manager" IDS_HINT_BLANK " " - IDS_HINT_EXIT " Exits the program." - IDS_HINT_REFRESH " Scan for changed or new Plug and Play devices." - IDS_HINT_PROP " Open property dialog for the current selection." - IDS_HINT_HELP " Display help window." + IDS_HINT_PROPERTIES " Open property dialog for the current selection." + IDS_HINT_SCAN " Scan for changed or new plug and play devices." + IDS_HINT_ENABLE " Enables the selected device." + IDS_HINT_DISABLE " Disables the selected device." + IDS_HINT_UPDATE " Launches the Update Driver Software wizard for the selected device." + IDS_HINT_UNINSTALL " Uninstalls the driver for the selected device." + IDS_HINT_ADD " Adds a legacy (non-Plug and Play) device to the computer." IDS_HINT_ABOUT " About ReactOS Device Manager." + IDS_HINT_EXIT " Exits the program." - IDS_HINT_DEV_BY_TYPE "Displays devices by hardware type" - IDS_HINT_DEV_BY_CONN "Displays devices by connection" - IDS_HINT_RES_BY_TYPE "Displays resources by type" - IDS_HINT_RES_BY_CONN "Displays resources by connection type" + IDS_HINT_DEV_BY_TYPE " Displays devices by hardware type." + IDS_HINT_DEV_BY_CONN " Displays devices by connection." + IDS_HINT_RES_BY_TYPE " Displays resources by type." + IDS_HINT_RES_BY_CONN " Displays resources by connection type." + IDS_HINT_SHOW_HIDDEN " Displays legacy devices and devices that are no longer installed." IDS_HINT_SYS_RESTORE " Restores this window to normal size." IDS_HINT_SYS_MOVE " Moves this window."