ReactOS 0.4.16-dev-178-g8ba6102
CDesktopFolder.cpp File Reference
#include <precomp.h>
#include "CFSFolder.h"
Include dependency graph for CDesktopFolder.cpp:

Go to the source code of this file.

Classes

class  CDesktopFolderEnum
 

Functions

 WINE_DEFAULT_DEBUG_CHANNEL (shell)
 
BOOL SHELL32_IsShellFolderNamespaceItemHidden (LPCWSTR SubKey, REFCLSID Clsid)
 
static BOOL IsSelf (UINT cidl, PCUITEMID_CHILD_ARRAY apidl)
 
static const CLSIDIsRegItem (PCUITEMID_CHILD pidl)
 
HRESULT WINAPI IEParseDisplayNameWithBCW (DWORD codepage, LPCWSTR lpszDisplayName, LPBC pbc, LPITEMIDLIST *ppidl)
 
int SHELL_ConfirmMsgBox (HWND hWnd, LPWSTR lpszText, LPWSTR lpszCaption, HICON hIcon, BOOL bYesToAll)
 
HRESULT WINAPI SHGetDesktopFolder (IShellFolder **psf)
 

Variables

static const REQUIREDREGITEM g_RequiredItems []
 
static const REGFOLDERINFO g_RegFolderInfo
 
static const DWORD dwDesktopAttributes
 
static const DWORD dwMyComputerAttributes
 
static DWORD dwMyNetPlacesAttributes
 

Function Documentation

◆ IEParseDisplayNameWithBCW()

HRESULT WINAPI IEParseDisplayNameWithBCW ( DWORD  codepage,
LPCWSTR  lpszDisplayName,
LPBC  pbc,
LPITEMIDLIST ppidl 
)

Definition at line 503 of file shdocvw_main.c.

504{
505 /* Guessing at parameter 3 based on IShellFolder's ParseDisplayName */
506 FIXME("stub: 0x%x %s %p %p\n",codepage,debugstr_w(lpszDisplayName),pbc,ppidl);
507 return E_FAIL;
508}
#define FIXME(fmt,...)
Definition: precomp.h:53
#define E_FAIL
Definition: ddrawi.h:102
#define debugstr_w
Definition: kernel32.h:32
int codepage
Definition: win_iconv.c:156

◆ IsRegItem()

static const CLSID * IsRegItem ( PCUITEMID_CHILD  pidl)
static

Definition at line 50 of file CDesktopFolder.cpp.

51{
52 if (pidl && pidl->mkid.cb == 2 + 2 + sizeof(CLSID) && pidl->mkid.abID[0] == PT_GUID)
53 return (const CLSID*)(&pidl->mkid.abID[2]);
54 return NULL;
55}
#define NULL
Definition: types.h:112
#define PT_GUID
Definition: pidl.h:87

Referenced by CDesktopFolderViewCB::ShouldShow(), and CDrivesFolder::ShouldShow().

◆ IsSelf()

static BOOL IsSelf ( UINT  cidl,
PCUITEMID_CHILD_ARRAY  apidl 
)
static

Definition at line 45 of file CDesktopFolder.cpp.

46{
47 return cidl == 0 || (cidl == 1 && apidl && _ILIsEmpty(apidl[0]));
48}
static BOOL _ILIsEmpty(LPCITEMIDLIST pidl)
Definition: pidl.h:267

Referenced by CDesktopFolder::GetUIObjectOf().

◆ SHELL32_IsShellFolderNamespaceItemHidden()

BOOL SHELL32_IsShellFolderNamespaceItemHidden ( LPCWSTR  SubKey,
REFCLSID  Clsid 
)

Definition at line 92 of file CDrivesFolder.cpp.

93{
94 // If this function returns true, the item should be hidden in DefView but not in the Explorer folder tree.
96 wsprintfW(path, L"%s\\%s", REGSTR_PATH_EXPLORER, SubKey);
98 DWORD data = 0, size = sizeof(data);
100}
#define CHARS_IN_GUID
LSTATUS WINAPI RegGetValueW(HKEY hKey, LPCWSTR pszSubKey, LPCWSTR pszValue, DWORD dwFlags, LPDWORD pdwType, PVOID pvData, LPDWORD pcbData)
Definition: reg.c:1931
#define MAX_PATH
Definition: compat.h:34
#define RRF_RT_DWORD
Definition: driver.c:581
unsigned long DWORD
Definition: ntddk_ex.h:95
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
GLsizeiptr size
Definition: glext.h:5919
#define L(x)
Definition: ntvdm.h:50
#define REGSTR_PATH_EXPLORER
Definition: regstr.h:33
static __inline int SHELL32_GUIDToStringW(REFGUID guid, LPWSTR str)
Definition: shfldr.h:143
Definition: name.c:39
#define HKEY_CURRENT_USER
Definition: winreg.h:11
int WINAPIV wsprintfW(_Out_ LPWSTR, _In_ _Printf_format_string_ LPCWSTR,...)
__wchar_t WCHAR
Definition: xmlstorage.h:180

Referenced by CDesktopFolderViewCB::ShouldShow(), and CDrivesFolder::ShouldShow().

◆ SHELL_ConfirmMsgBox()

int SHELL_ConfirmMsgBox ( HWND  hWnd,
LPWSTR  lpszText,
LPWSTR  lpszCaption,
HICON  hIcon,
BOOL  bYesToAll 
)

Definition at line 204 of file shlfileop.cpp.

205{
206 struct confirm_msg_info info;
207
208 info.lpszText = lpszText;
209 info.lpszCaption = lpszCaption;
210 info.hIcon = hIcon;
211 info.bYesToAll = bYesToAll;
213}
#define shell32_hInstance
HWND hWnd
Definition: settings.c:17
HICON hIcon
Definition: msconfig.c:44
static INT_PTR CALLBACK ConfirmMsgBoxProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
Definition: shlfileop.cpp:186
#define IDD_YESTOALL_MSGBOX
Definition: shresdef.h:427
LPWSTR lpszCaption
Definition: shlfileop.cpp:90
LONG_PTR LPARAM
Definition: windef.h:208
#define MAKEINTRESOURCEW(i)
Definition: winuser.h:582
INT_PTR WINAPI DialogBoxParamW(_In_opt_ HINSTANCE, _In_ LPCWSTR, _In_opt_ HWND, _In_opt_ DLGPROC, _In_ LPARAM)

Referenced by SHELL_ConfirmDialogW().

◆ SHGetDesktopFolder()

HRESULT WINAPI SHGetDesktopFolder ( IShellFolder **  psf)

Definition at line 1079 of file CDesktopFolder.cpp.

1080{
1081 HRESULT hres = S_OK;
1082 TRACE("\n");
1083
1084 if(!psf) return E_INVALIDARG;
1085 *psf = NULL;
1086 hres = CDesktopFolder::_CreatorClass::CreateInstance(NULL, IID_PPV_ARG(IShellFolder, psf));
1087
1088 TRACE("-- %p->(%p)\n",psf, *psf);
1089 return hres;
1090}
#define E_INVALIDARG
Definition: ddrawi.h:101
#define S_OK
Definition: intsafe.h:52
HRESULT hres
Definition: protocol.c:465
#define TRACE(s)
Definition: solgame.cpp:4
#define IID_PPV_ARG(Itype, ppType)

Referenced by _BindToObject(), CViewStatePropertyBag::_CreateBag(), CFSDropTarget::_DoDrop(), _GetDocumentsPidl(), CBandSiteMenu::_GetMenuIdFromISFBand(), _ILParsePathW(), CMruNode::_InitLate(), CDesktopFolder::_ParseDisplayNameByParent(), _ParsePathToPidl(), CShellMenuCallback::AddStartMenuItems(), BindToDesktop(), CShellItem::BindToHandler(), BrFolder_GetChildrenEnum(), BrFolder_InitTreeView(), BrFolder_NewFolder(), BrFolder_OnSetExpandedString(), CGuidItemExtractIcon_CreateInstance(), COMDLG32_GetDisplayNameOf(), COMDLG32_UpdateCurrentDir(), CShellItem::Compare(), CSendToMenu::CSendToMenu(), CMyDocsDropHandler::Drop(), CDeskLinkDropHandler::Drop(), CAddressEditBox::Execute(), FileDialog_constructor(), FILEDLG95_LOOKIN_Init(), FILEDLG95_ValidatePathAction(), CAddressEditBox::FillOneLevel(), CQuickLaunchBand::FinalConstruct(), FM_InitMenuPopup(), CShellItem::get_parent_shellfolder(), CFolderItem::get_Path(), CShellItem::get_shellfolder(), CShellItem::GetAttributes(), GetFullName(), GetName(), GetPidlFromName(), CFolder::GetShellFolder(), GetShellFolderFromPidl(), CFindFolder::GetUIObjectOf(), HCR_GetFolderAttributes(), ILGetDisplayNameExW(), Initialize(), CDesktopBrowser::Initialize(), CFolderItems::Initialize(), CISFBand::InitializeSFB(), CSearchBar::Invoke(), CCPLItemMenu::InvokeCommand(), CShellBrowser::Navigate(), on_default_action(), CShellBrowser::OnOrganizeFavorites(), CAddressEditBox::ParseNow(), ParseSharedPacket(), CStartMenuBtnCtxMenu::QueryContextMenu(), CNtObjectFolder::ResolveSymLink(), CACListISF::SetLocation(), SHBindToFolder(), SHBindToFolderIDListParent(), SHBindToObjectEx(), SHBindToParent(), SHELL_CompareAbsoluteIDs(), SHELL_GetPathFromIDListForExecuteW(), ShellFolder::ShellFolder(), CDesktopFolder::ShellUrlParseDisplayName(), SHEmptyRecycleBinW(), SHILCreateFromPathW(), SHOpenFolderAndSelectItems(), SHParseDisplayName(), START_TEST(), test_basics(), test_BindToObject(), test_CallForAttributes(), test_click_make_new_folder_button(), test_CreateViewWindow(), test_CShellMenu(), test_CShellMenu_params(), test_DataObject(), test_desktop_displaynameof(), test_desktop_folder(), test_desktop_IPersist(), test_EnumObjects_and_CompareIDs(), test_ExpectFolders_imp(), test_FolderShortcut(), test_GetAttributesOf(), test_GetDisplayName(), test_GetItemObject(), test_GetSetCurrentViewMode(), test_GetUIObject(), test_IFolderView(), test_InputObject(), test_IOleCommandTarget(), test_IOleWindow(), test_IShellFolderView(), test_ITEMIDLIST_format(), test_LocalizedNames(), test_navigation(), test_parse_for_control_panel(), test_parse_for_entire_network(), test_ParseDisplayName(), test_ParseDisplayNamePBC(), test_selection(), test_SHCreateDefaultContextMenu(), test_SHCreateShellFolderView(), test_SHCreateShellFolderViewEx(), test_SHCreateShellItem(), test_SHCreateShellItemArray(), test_ShellFolderViewDual(), test_ShellItemArrayEnumItems(), test_ShellItemArrayGetAttributes(), test_ShellItemCompare(), test_ShellItemGetAttributes(), test_SHGetIDListFromObject(), test_SHGetItemFromDataObject(), test_SHGetItemFromObject(), test_SHGetNameFromIDList(), test_SHGetPathFromIDList(), test_SHIShellFolder_EnumObjects(), test_SHLimitInputEdit(), test_ShortcutFolder(), and test_SHParseDisplayName().

◆ WINE_DEFAULT_DEBUG_CHANNEL()

WINE_DEFAULT_DEBUG_CHANNEL ( shell  )

Variable Documentation

◆ dwDesktopAttributes

const DWORD dwDesktopAttributes
static
Initial value:
=
SFGAO_HASSUBFOLDER | SFGAO_FILESYSTEM | SFGAO_FOLDER | SFGAO_FILESYSANCESTOR |
SFGAO_STORAGEANCESTOR | SFGAO_HASPROPSHEET | SFGAO_STORAGE

Definition at line 216 of file CDesktopFolder.cpp.

Referenced by CDesktopFolder::GetAttributesOf().

◆ dwMyComputerAttributes

const DWORD dwMyComputerAttributes
static
Initial value:
=
SFGAO_CANRENAME | SFGAO_CANDELETE | SFGAO_HASPROPSHEET | SFGAO_DROPTARGET |
SFGAO_FILESYSANCESTOR | SFGAO_FOLDER | SFGAO_HASSUBFOLDER | SFGAO_CANLINK

Definition at line 219 of file CDesktopFolder.cpp.

Referenced by CDesktopFolder::GetAttributesOf().

◆ dwMyNetPlacesAttributes

DWORD dwMyNetPlacesAttributes
static
Initial value:
=
SFGAO_CANRENAME | SFGAO_CANDELETE | SFGAO_HASPROPSHEET | SFGAO_DROPTARGET |
SFGAO_FILESYSANCESTOR | SFGAO_FOLDER | SFGAO_HASSUBFOLDER | SFGAO_CANLINK

Definition at line 222 of file CDesktopFolder.cpp.

Referenced by CDesktopFolder::GetAttributesOf().

◆ g_RegFolderInfo

const REGFOLDERINFO g_RegFolderInfo
static
Initial value:
=
{
PT_DESKTOP_REGITEM,
CLSID_ShellDesktop,
L"",
L"Desktop",
}
static const REQUIREDREGITEM g_RequiredItems[]
#define _countof(array)
Definition: sndvol32.h:70

Definition at line 36 of file CDesktopFolder.cpp.

◆ g_RequiredItems

const REQUIREDREGITEM g_RequiredItems[]
static
Initial value:
=
{
{ CLSID_MyComputer, "sysdm.cpl", 0x50 },
{ CLSID_NetworkPlaces, "ncpa.cpl", 0x58 },
{ CLSID_Internet, "inetcpl.cpl", 0x68 },
}

Definition at line 30 of file CDesktopFolder.cpp.