mirror of
https://github.com/reactos/reactos.git
synced 2024-07-12 23:55:07 +00:00
browse drives in start menu
svn path=/trunk/; revision=5808
This commit is contained in:
parent
53ee161d92
commit
aa77f6df20
|
@ -19,6 +19,7 @@
|
|||
#define IDS_ADMIN 15
|
||||
#define IDS_NETWORK 16
|
||||
#define IDS_CONNECTIONS 17
|
||||
#define IDS_DRIVES 18
|
||||
#define IDI_REACTOS 100
|
||||
#define IDI_EXPLORER 101
|
||||
#define IDI_STARTMENU 102
|
||||
|
|
|
@ -262,6 +262,7 @@ STRINGTABLE DISCARDABLE
|
|||
BEGIN
|
||||
IDS_NETWORK "Network"
|
||||
IDS_CONNECTIONS "Connections"
|
||||
IDS_DRIVES "File System"
|
||||
END
|
||||
|
||||
#endif // German (Germany) resources
|
||||
|
|
|
@ -51,6 +51,7 @@
|
|||
#define IDC_EXPLORE 0x100C
|
||||
#define IDC_NETWORK 0x100D
|
||||
#define IDC_CONNECTIONS 0x100E
|
||||
#define IDC_DRIVES 0x100F
|
||||
|
||||
#define IDC_FIRST_MENU 0x3000
|
||||
|
||||
|
|
|
@ -128,7 +128,8 @@ void StartMenu::AddShellEntries(const ShellDirectory& dir, int max, bool subfold
|
|||
|
||||
for(const Entry*entry=dir._down; entry; entry=entry->_next) {
|
||||
// hide files like "desktop.ini"
|
||||
if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_HIDDEN)
|
||||
if (entry->_shell_attribs & SFGAO_HIDDEN)
|
||||
//not appropriate for drive roots: if (entry->_data.dwFileAttributes & FILE_ATTRIBUTE_HIDDEN)
|
||||
continue;
|
||||
|
||||
// hide subfolders if requested
|
||||
|
@ -565,6 +566,7 @@ LRESULT StartMenuRoot::Init(LPCREATESTRUCT pcs)
|
|||
AddButton(ResString(IDS_RECENT), 0, true, IDC_RECENT);
|
||||
AddButton(ResString(IDS_SETTINGS), 0, true, IDC_SETTINGS);
|
||||
AddButton(ResString(IDS_ADMIN), 0, true, IDC_ADMIN);
|
||||
AddButton(ResString(IDS_DRIVES), 0, true, IDC_DRIVES);
|
||||
AddButton(ResString(IDS_NETWORK), 0, true, IDC_NETWORK);
|
||||
AddButton(ResString(IDS_CONNECTIONS),0,true, IDC_CONNECTIONS);
|
||||
AddButton(ResString(IDS_SEARCH), 0, false, IDC_SEARCH);
|
||||
|
@ -626,6 +628,11 @@ int StartMenuRoot::Command(int id, int code)
|
|||
CreateSubmenu(id, CSIDL_CONNECTIONS);
|
||||
break;
|
||||
|
||||
case IDC_DRIVES:
|
||||
//TODO: exclude removeable drives
|
||||
CreateSubmenu(id, CSIDL_DRIVES);
|
||||
break;
|
||||
|
||||
case IDC_LOGOFF:
|
||||
DestroyWindow(GetParent(_hwnd)); //TODO: show dialog and ask for acknowledge
|
||||
break;
|
||||
|
|
|
@ -56,6 +56,12 @@
|
|||
#ifndef TB_GETBUTTONINFO //missing in mingw headers
|
||||
#define TB_GETBUTTONINFO (WM_USER+65)
|
||||
#endif
|
||||
#ifndef SFGAO_HIDDEN //SFGAO_GHOSTED wrong defined, SFGAO_HIDDEN missing in mingw headers
|
||||
#define SFGAO_HIDDEN 0x00080000L
|
||||
#undef SFGAO_GHOSTED
|
||||
#define SFGAO_GHOSTED 0x00008000L
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
|
Loading…
Reference in a new issue