23#include <shdeprecated.h>
34 public IBandSiteStreamCallback
83 *ppvObj =
static_cast<IBandSiteStreamCallback*
>(
this);
91 TRACE(
"ITaskBandSite: IWinEventHandler queried!\n");
141 hRet = pStm->Seek(liPosZero, STREAM_SEEK_CUR, &liCurrent);
161 TRACE(
"IBandSiteStreamCallback::OnLoad intercepted the task band CLSID!\n");
184 TRACE(
"IBandSiteStreamCallback::OnLoad(0x%p, 0x%p, 0x%p) returns 0x%x\n", pStm,
riid, pvObj, hRet);
198 TRACE(
"IBandSiteStreamCallback::OnSave(0x%p, 0x%p) returns E_NOTIMPL\n",
pUnk, pStm);
268 ERR(
"ITrayBandSite->IWinEventHandler::ProcessMessage: WM_NOTIFY for 0x%p, From: 0x%p, Code: NM_FIRST-%u returned 0x%x\n",
hWnd, nmh->
hwndFrom,
NM_FIRST - nmh->
code, hRet);
272 ERR(
"ITrayBandSite->IWinEventHandler::ProcessMessage(0x%p,0x%x,0x%p,0x%p,0x%p->0x%p) returned: 0x%x\n",
hWnd, uMsg,
wParam,
lParam, plResult, *plResult, hRet);
324 if (bPrevLocked != bLock)
329 bsi.
dwStyle = (
Locked ? BSIS_LOCKED | BSIS_NOGRIPPER : BSIS_AUTOGRIPPER);
374 return m_BandSite->EnumBands(uBand, pdwBandID);
400 if (pdwState !=
NULL)
401 *pdwState |= BSSF_UNDELETEABLE;
412 else if (ppstb !=
NULL)
423 return m_BandSite->SetBandState(dwBandID, dwMask, dwState);
464 if (
SUCCEEDED(pBand->GetClassID(&BandCLSID)))
555 hRet = pPStm->Load(pStm);
556 TRACE(
"->Load() returned 0x%x\n", hRet);
588 L"Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Streams",
613 TRACE(
"Loaded user bands settings: 0x%x\n", hRet);
629 TRACE(
"Loaded default user bands settings: 0x%x\n", hRet);
670 hRet = pDbc->SetDeskBarSite(tray);
674 hRet = pDbc->GetWindow(&
m_Rebar);
684 if (!
m_Tray->IsHorizontal())
685 dwMode = DBIF_VIEWMODE_VERTICAL;
687 hRet = pDbc->SetModeDBC(dwMode);
725 hr =
tb->_Init(tray, pTaskBand);
#define InterlockedIncrement
#define InterlockedDecrement
HRESULT WINAPI _CBandSite_CreateInstance(LPUNKNOWN pUnkOuter, REFIID riid, void **ppv)
HRESULT WINAPI _CBandSiteMenu_CreateInstance(REFIID riid, void **ppv)
HRESULT IsSameObject(IN IUnknown *punk1, IN IUnknown *punk2)
const GUID CLSID_ITaskBand
#define STDMETHODCALLTYPE
#define RegCloseKey(hKey)
virtual HRESULT STDMETHODCALLTYPE RemoveBand(IN DWORD dwBandID)
CComPtr< IWinEventHandler > m_WindowEventHandler
virtual ULONG STDMETHODCALLTYPE Release()
virtual HRESULT FinishInit()
virtual HRESULT LoadFromStream(IN OUT IStream *pStm)
virtual HRESULT STDMETHODCALLTYPE SetBandSiteInfo(IN const BANDSITEINFO *pbsinfo)
virtual ULONG STDMETHODCALLTYPE AddRef()
virtual IStream * GetDefaultBandsStream(IN DWORD grfMode)
virtual HRESULT STDMETHODCALLTYPE OnSave(IN OUT IUnknown *pUnk, IN OUT IStream *pStm)
virtual HRESULT STDMETHODCALLTYPE OnLoad(IN OUT IStream *pStm, IN REFIID riid, OUT PVOID *pvObj)
virtual HRESULT STDMETHODCALLTYPE EnumBands(IN UINT uBand, OUT DWORD *pdwBandID)
virtual HRESULT STDMETHODCALLTYPE QueryBand(IN DWORD dwBandID, OUT IDeskBand **ppstb, OUT DWORD *pdwState, OUT LPWSTR pszName, IN int cchName)
CComPtr< ITrayWindow > m_Tray
virtual HRESULT STDMETHODCALLTYPE SetBandState(IN DWORD dwBandID, IN DWORD dwMask, IN DWORD dwState)
virtual HRESULT STDMETHODCALLTYPE QueryInterface(IN REFIID riid, OUT LPVOID *ppvObj)
virtual HRESULT STDMETHODCALLTYPE GetBandObject(IN DWORD dwBandID, IN REFIID riid, OUT VOID **ppv)
virtual HRESULT STDMETHODCALLTYPE AddContextMenus(IN HMENU hmenu, IN UINT indexMenu, IN UINT idCmdFirst, IN UINT idCmdLast, IN UINT uFlags, OUT IContextMenu **ppcm)
virtual HRESULT STDMETHODCALLTYPE GetBandSiteInfo(IN OUT BANDSITEINFO *pbsinfo)
virtual VOID BroadcastOleCommandExec(REFGUID pguidCmdGroup, DWORD nCmdID, DWORD nCmdExecOpt, VARIANTARG *pvaIn, VARIANTARG *pvaOut)
virtual HRESULT STDMETHODCALLTYPE AddBand(IN IUnknown *punk)
virtual HRESULT STDMETHODCALLTYPE Lock(IN BOOL bLock)
CComPtr< IBandSite > m_BandSite
HRESULT _Init(IN ITrayWindow *tray, IN IDeskBand *pTaskBand)
CComPtr< IContextMenu > m_ContextMenu
virtual IStream * GetUserBandsStream(IN DWORD grfMode)
CComPtr< IUnknown > m_Inner
virtual HRESULT Show(IN BOOL bShow)
virtual HRESULT STDMETHODCALLTYPE IsTaskBand(IN IUnknown *punk)
virtual HRESULT STDMETHODCALLTYPE ProcessMessage(IN HWND hWnd, IN UINT uMsg, IN WPARAM wParam, IN LPARAM lParam, OUT LRESULT *plResult)
virtual BOOL HasTaskBand()
CComPtr< IDeskBand > m_TaskBand
LONG WINAPI RegCreateKeyW(HKEY hKey, LPCWSTR lpSubKey, PHKEY phkResult)
#define FAILED_UNEXPECTEDLY(hr)
HRESULT WINAPI OleLoadFromStream(IStream *pStm, REFIID iidInterface, void **ppvObj)
HRESULT WINAPI IUnknown_Exec(IUnknown *lpUnknown, REFGUID pguidCmdGroup, DWORD nCmdID, DWORD nCmdexecopt, VARIANT *pvaIn, VARIANT *pvaOut)
HRESULT WINAPI IUnknown_SetOwner(IUnknown *iface, IUnknown *pUnk)
static void *static void *static LPDIRECTPLAY IUnknown * pUnk
HRESULT Exec([in, unique] const GUID *pguidCmdGroup, [in] DWORD nCmdID, [in] DWORD nCmdexecopt, [in, unique] VARIANT *pvaIn, [in, out, unique] VARIANT *pvaOut)
#define SetWindowStyle(hwnd, val)
static const CLSID *static CLSID *static const GUID VARIANT VARIANT *static IServiceProvider DWORD *static HMENU
BSTR WINAPI SysAllocString(LPCOLESTR str)
void WINAPI DECLSPEC_HOTPATCH SysFreeString(BSTR str)
struct tagNMMOUSE * LPNMMOUSE
#define IsEqualGUID(rguid1, rguid2)
#define IsEqualIID(riid1, riid2)
IStream *WINAPI SHOpenRegStreamW(HKEY hkey, LPCWSTR pszSubkey, LPCWSTR pszValue, DWORD dwMode)
DWORD WINAPI SHRestricted(RESTRICTIONS rest)
HRESULT CTrayBandSite_CreateInstance(IN ITrayWindow *tray, IN IDeskBand *pTaskBand, OUT ITrayBandSite **pBandSite)
_In_ PSID _Out_writes_to_opt_ cchName LPSTR _Inout_ LPDWORD cchName
#define HKEY_LOCAL_MACHINE
#define IID_PPV_ARG(Itype, ppType)