Пример #1
0
        ShellItemImpl GetParent()
        {
            IntPtr pidl = Shell32.ILClone(_pidl);

            if (ILShell32.ILRemoveLastID(pidl))
            {
                return(new ShellItemImpl(pidl, true));
            }
            else
            {
                return(this);
            }
        }
Пример #2
0
        public HResult GetParent(out IShellItem ppsi)
        {
            IntPtr pidl = Shell32.ILClone(_pidl);

            if (ILShell32.ILRemoveLastID(pidl))
            {
                ppsi = new ShellItemImpl(pidl, true);
                return(HResult.S_OK);
            }
            else
            {
                ppsi = null;
                return(HResult.MK_E_NOOBJECT);
            }
        }