1*c7e6a9d0SMark Jansen /* 2*c7e6a9d0SMark Jansen * PROJECT: ReactOS Zip Shell Extension 3*c7e6a9d0SMark Jansen * LICENSE: GPL-2.0+ (https://spdx.org/licenses/GPL-2.0+) 4*c7e6a9d0SMark Jansen * PURPOSE: IShellFolderViewCB implementation 5*c7e6a9d0SMark Jansen * COPYRIGHT: Copyright 2017 David Quintana (gigaherz@gmail.com) 6*c7e6a9d0SMark Jansen * Copyright 2017 Mark Jansen (mark.jansen@reactos.org) 7*c7e6a9d0SMark Jansen */ 8*c7e6a9d0SMark Jansen 9*c7e6a9d0SMark Jansen #include "precomp.h" 10*c7e6a9d0SMark Jansen 11*c7e6a9d0SMark Jansen class CFolderViewCB : 12*c7e6a9d0SMark Jansen public CComObjectRootEx<CComMultiThreadModelNoCS>, 13*c7e6a9d0SMark Jansen public IShellFolderViewCB 14*c7e6a9d0SMark Jansen { 15*c7e6a9d0SMark Jansen public: 16*c7e6a9d0SMark Jansen ~CFolderViewCB()17*c7e6a9d0SMark Jansen virtual ~CFolderViewCB() 18*c7e6a9d0SMark Jansen { 19*c7e6a9d0SMark Jansen } 20*c7e6a9d0SMark Jansen 21*c7e6a9d0SMark Jansen // *** IShellFolderViewCB methods *** MessageSFVCB(UINT uMsg,WPARAM wParam,LPARAM lParam)22*c7e6a9d0SMark Jansen STDMETHODIMP MessageSFVCB(UINT uMsg, WPARAM wParam, LPARAM lParam) 23*c7e6a9d0SMark Jansen { 24*c7e6a9d0SMark Jansen /* TODO: Handle SFVM_GET_WEBVIEW_CONTENT to add tasks */ 25*c7e6a9d0SMark Jansen switch (uMsg) 26*c7e6a9d0SMark Jansen { 27*c7e6a9d0SMark Jansen case SFVM_DEFVIEWMODE: 28*c7e6a9d0SMark Jansen { 29*c7e6a9d0SMark Jansen FOLDERVIEWMODE* pViewMode = (FOLDERVIEWMODE*)lParam; 30*c7e6a9d0SMark Jansen *pViewMode = FVM_DETAILS; 31*c7e6a9d0SMark Jansen return S_OK; 32*c7e6a9d0SMark Jansen } 33*c7e6a9d0SMark Jansen case SFVM_COLUMNCLICK: 34*c7e6a9d0SMark Jansen return S_FALSE; 35*c7e6a9d0SMark Jansen case SFVM_BACKGROUNDENUM: 36*c7e6a9d0SMark Jansen return S_OK; 37*c7e6a9d0SMark Jansen } 38*c7e6a9d0SMark Jansen 39*c7e6a9d0SMark Jansen return E_NOTIMPL; 40*c7e6a9d0SMark Jansen } 41*c7e6a9d0SMark Jansen 42*c7e6a9d0SMark Jansen public: 43*c7e6a9d0SMark Jansen DECLARE_NOT_AGGREGATABLE(CFolderViewCB) 44*c7e6a9d0SMark Jansen DECLARE_PROTECT_FINAL_CONSTRUCT() 45*c7e6a9d0SMark Jansen 46*c7e6a9d0SMark Jansen BEGIN_COM_MAP(CFolderViewCB) 47*c7e6a9d0SMark Jansen COM_INTERFACE_ENTRY_IID(IID_IShellFolderViewCB, IShellFolderViewCB) 48*c7e6a9d0SMark Jansen END_COM_MAP() 49*c7e6a9d0SMark Jansen }; 50*c7e6a9d0SMark Jansen _CFolderViewCB_CreateInstance(REFIID riid,LPVOID * ppvOut)51*c7e6a9d0SMark JansenHRESULT _CFolderViewCB_CreateInstance(REFIID riid, LPVOID * ppvOut) 52*c7e6a9d0SMark Jansen { 53*c7e6a9d0SMark Jansen return ShellObjectCreator<CFolderViewCB>(riid, ppvOut); 54*c7e6a9d0SMark Jansen } 55