[FORMATTING] Remove trailing whitespace. Addendum to 34593d93.

Excluded: 3rd-party code (incl. wine) and most of the win32ss.
This commit is contained in:
Hermès Bélusca-Maïto 2021-09-13 03:33:14 +02:00
parent bbabe2489e
commit 9393fc320e
No known key found for this signature in database
GPG key ID: 3B2539C65E7B93D0
701 changed files with 14685 additions and 14693 deletions

View file

@ -29,7 +29,7 @@ typedef struct _BATCH_CONTEXT
char *mem; /* batchfile content in memory */
DWORD memsize; /* size of batchfile */
DWORD mempos; /* current position to read from */
BOOL memfree; /* true if it need to be freed when exitbatch is called */
BOOL memfree; /* true if it need to be freed when exitbatch is called */
TCHAR BatchFilePath[MAX_PATH];
LPTSTR params;
LPTSTR raw_params; /* Holds the raw params given by the input */

View file

@ -74,7 +74,7 @@ CheckTerminalDeviceType(IN LPCTSTR pszName)
}
else
if ( _wcsnicmp(DeviceName, DosLPTDevice, 3) == 0 ||
_wcsnicmp(DeviceName, DosCOMDevice, 3) == 0 ||
_wcsnicmp(DeviceName, DosCOMDevice, 3) == 0 ||
_wcsnicmp(DeviceName, DosPRNDevice, 3) == 0 ||
_wcsnicmp(DeviceName, DosAUXDevice, 3) == 0 ||
_wcsnicmp(DeviceName, DosNULDevice, 3) == 0 )

View file

@ -1,32 +1,32 @@
General Overview of How Things Work
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
First it comes into _main in cmd.c(1811). The command line params are taking in and if it is unicode it uses CommandLineToArgvW.
This can cause a problem on older machines and that is why we have our own custom _CommandLineToArgvW to help this along.
We pull in the launch directory as the initial dir and set that in _tchdir. We make a handle to the default console out using CreateFile.
First it comes into _main in cmd.c(1811). The command line params are taking in and if it is unicode it uses CommandLineToArgvW.
This can cause a problem on older machines and that is why we have our own custom _CommandLineToArgvW to help this along.
We pull in the launch directory as the initial dir and set that in _tchdir. We make a handle to the default console out using CreateFile.
Then we call Initialize(). Here we need to load ntdll.dll if it isn't loaded (windows 9x machines).
We also setup some global vars like default io handles and nErrorLevel and set %prompt% to $P$G.
Then we call Initialize(). Here we need to load ntdll.dll if it isn't loaded (windows 9x machines).
We also setup some global vars like default io handles and nErrorLevel and set %prompt% to $P$G.
This is where all command lines switches given to cmd on startup are done.
From here main calls ProcessInput(). This is where cmd loops for getting input and doing the commands.
First it checks to see if there is a batch file(note: there is a global struct "bc" which is NULL when not processing a batch file)
and if there is it will pull a new line from that file. If not, then it will wait for input.
Currently there is some stuff for set /a in there, which might stay there or see if we can find a better spot.
From here main calls ProcessInput(). This is where cmd loops for getting input and doing the commands.
First it checks to see if there is a batch file(note: there is a global struct "bc" which is NULL when not processing a batch file)
and if there is it will pull a new line from that file. If not, then it will wait for input.
Currently there is some stuff for set /a in there, which might stay there or see if we can find a better spot.
Once there is input taken in from the command line it is sent into ParseCommandLine().
In here we fist check for aliases and convert if need be.
Then we look for redirections using GetRedirection() which will remove any redirection symbols.
and pass back info about where to redirect.
from this info it will do some switching around with the handles for where things go and send them as need be.
personally i dont like this code and i tried to change it before but failed.
Once there is input taken in from the command line it is sent into ParseCommandLine().
In here we fist check for aliases and convert if need be.
Then we look for redirections using GetRedirection() which will remove any redirection symbols.
and pass back info about where to redirect.
from this info it will do some switching around with the handles for where things go and send them as need be.
personally i dont like this code and i tried to change it before but failed.
it is confusing to me and i dont understand why a lot of it is there but apparently it is needed.
It sends the new string without any redirection info into DoCommand(). In this function we just look to see what should be done.
There is one of 2 things that could happen.
1) we fnd the matching command and send it off to that commands little section.
It sends the new string without any redirection info into DoCommand(). In this function we just look to see what should be done.
There is one of 2 things that could happen.
1) we fnd the matching command and send it off to that commands little section.
2) we dont find it so we send it to Execute() and see if it is a file that we can do something.
Execute will try to launch the file using createprocess and falls back on shellexecute.
Execute will try to launch the file using createprocess and falls back on shellexecute.
It calls a function called SearchForExecutable() to find the full path name and looks in all the correct locations like PATH,
current folder, windows folder. If it cant find it, just fails and prints out a message.

View file

@ -1,6 +1,6 @@
Made by Vicmarcal 23/11/08
THIS FILE HELPS TO EXPLAIN HOW REN IS NOW IMPLEMENTED.
THIS FILE HELPS TO EXPLAIN HOW REN IS NOW IMPLEMENTED.
****************************************************************
(Please change or add latest modifications)
****************************************************************
@ -14,7 +14,7 @@ ren c:\ie\hello.txt c:\ie\hi.txt
rename command will change the name of hello.txt->hi.txt. We have to be sure that both paths(c:\ie\ ) be the same.Since rename cant move files within Directories (MSDN).
WAY #2:Semi Path Way:
ren c:\ie\hello.txt hi.txt
ren c:\ie\hello.txt hi.txt
This is a special feature,since this does the same as Way #1 but without telling the Destiny path.So this feature must be implemented also.
@ -35,7 +35,7 @@ So it changes the name of hello.txt in the current directory.
Explaining code:
srcPattern: here is stored Source Argument (C:\ie\hello.txt)
srcPattern: here is stored Source Argument (C:\ie\hello.txt)
srcPath: here is stored Source Path(C:\ie)
srcFILE: here is stored FILE name(hello.txt)
@ -43,7 +43,7 @@ dstPattern: here is stored Destiny Argument (C:\ie\hi.txt)
dstPath: here is stored Destiny Path(C:\i)
dstFILE: here is stored FILE re-name(hi.txt)
1)We begin retrieving arguments from command line and fulfilling dstPattern and srcPattern
1)We begin retrieving arguments from command line and fulfilling dstPattern and srcPattern
2)If srcPattern contains "\" then:

View file

@ -25,7 +25,7 @@ INT_PTR CALLBACK CustomizeNotifyIconsProc(HWND hwnd, UINT Message, WPARAM wParam
switch(Message)
{
case WM_INITDIALOG:
return TRUE;
case WM_COMMAND:
switch(LOWORD(wParam))

View file

@ -68,7 +68,7 @@ extern BOOL bExplorerIsShell;
* explorer.c
*/
static inline
static inline
LONG
SetWindowStyle(IN HWND hWnd,
IN LONG dwStyleMask,
@ -312,14 +312,14 @@ CreateStartMenu(IN ITrayWindow *Tray,
/*
* startmnucust.cpp
*/
VOID
VOID
ShowCustomizeClassic(HINSTANCE, HWND);
/*
* startmnusite.cpp
*/
HRESULT
HRESULT
CStartMenuSite_CreateInstance(IN OUT ITrayWindow *Tray, const IID & riid, PVOID * ppv);
/*

View file

@ -134,7 +134,7 @@
/* Customize Notifications Dialog */
#define IDC_TASKBARPROP_NOTIREST 1402
#define IDC_NOTIFICATION_LIST 1005
#define IDC_NOTIFICATION_LIST 1005
#define IDC_NOTIFICATION_BEHAVIOUR 1006
/* Customize classic start menu dialog */

View file

@ -43,7 +43,7 @@ BOOL TaskbarSettings::Load()
cbSize = sizeof(dwValue);
dwRet = SHGetValueW(hkExplorer, L"Advanced", L"TaskbarSizeMove", NULL, &dwValue, &cbSize);
bLock = (dwRet == ERROR_SUCCESS) ? (dwValue == 0) : TRUE;
dwRet = SHGetValueW(hkExplorer, L"Advanced", L"ShowSeconds", NULL, &dwValue, &cbSize);
bShowSeconds = (dwRet == ERROR_SUCCESS) ? (dwValue != 0) : FALSE;

View file

@ -212,7 +212,7 @@ public:
return S_OK;
}
virtual HRESULT STDMETHODCALLTYPE
virtual HRESULT STDMETHODCALLTYPE
GetCommandString(UINT_PTR idCmd,
UINT uType,
UINT *pwReserved,

View file

@ -369,7 +369,7 @@ bool CIconWatcher::AddIconToWatcher(_In_ CONST NOTIFYICONDATA *iconData)
bool CIconWatcher::RemoveIconFromWatcher(_In_ CONST NOTIFYICONDATA *iconData)
{
EnterCriticalSection(&m_ListLock);
IconWatcherData *Icon;
Icon = GetListEntry(iconData, NULL, true);
@ -717,7 +717,7 @@ BOOL CNotifyToolbar::AddButton(_In_ CONST NOTIFYICONDATA *iconData)
InternalIconData * notifyItem;
WCHAR text[] = L"";
TRACE("Adding icon %d from hWnd %08x flags%s%s state%s%s",
TRACE("Adding icon %d from hWnd %08x flags%s%s state%s%s",
iconData->uID, iconData->hWnd,
(iconData->uFlags & NIF_ICON) ? " ICON" : "",
(iconData->uFlags & NIF_STATE) ? " STATE" : "",
@ -1243,7 +1243,7 @@ void CNotifyToolbar::Initialize(HWND hWndParent, CBalloonQueue * queue)
SetWindowTheme(m_hWnd, L"TrayNotify", NULL);
m_ImageList = ImageList_Create(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), ILC_COLOR32 | ILC_MASK, 0, 1000);
m_ImageList = ImageList_Create(GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), ILC_COLOR32 | ILC_MASK, 0, 1000);
SetImageList(m_ImageList);
TBMETRICS tbm = {sizeof(tbm)};
@ -1292,7 +1292,7 @@ LRESULT CSysPagerWnd::OnCreate(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bH
HWND hWndTop = GetAncestor(m_hWnd, GA_ROOT);
m_Balloons.Create(hWndTop, TTS_NOPREFIX | TTS_BALLOON | TTS_CLOSE);
TOOLINFOW ti = { 0 };
ti.cbSize = TTTOOLINFOW_V1_SIZE;
ti.uFlags = TTF_TRACK | TTF_IDISHWND;
@ -1380,7 +1380,7 @@ BOOL CSysPagerWnd::NotifyIcon(DWORD dwMessage, _In_ CONST NOTIFYICONDATA *iconDa
void CSysPagerWnd::GetSize(IN BOOL IsHorizontal, IN PSIZE size)
{
/* Get the ideal height or width */
#if 0
#if 0
/* Unfortunately this doens't work correctly in ros */
Toolbar.GetIdealSize(!IsHorizontal, size);

View file

@ -86,7 +86,7 @@ public:
virtual HRESULT STDMETHODCALLTYPE ResizeBorderDW(
LPCRECT prcBorder,
IUnknown *punkToolbarSite,
BOOL fReserved)
BOOL fReserved)
{
/* No need to implement this method */
return E_NOTIMPL;
@ -174,7 +174,7 @@ public:
}
/*****************************************************************************/
virtual HRESULT STDMETHODCALLTYPE SetClient(
IN IUnknown *punkClient)
{

View file

@ -195,7 +195,7 @@ LRESULT CTrayClockWnd::OnThemeChanged()
}
else
{
/* We don't need to set a font here, our parent will use
/* We don't need to set a font here, our parent will use
* WM_SETFONT to set the right one when themes are not enabled. */
textColor = RGB(0, 0, 0);
}

View file

@ -46,7 +46,7 @@ static void SetBitmap(HWND hwnd, HBITMAP* hbmp, UINT uImageId)
class CTaskBarSettingsPage : public CPropertyPageImpl<CTaskBarSettingsPage>
{
private:
private:
HBITMAP m_hbmpTaskbar;
HBITMAP m_hbmpTray;
HWND m_hwndTaskbar;
@ -85,7 +85,7 @@ private:
uImageId = IDB_TASKBARPROP_NOLOCK_NOGROUP_QL;
else if (!bLock && bGroup && bShowQL)
uImageId = IDB_TASKBARPROP_NOLOCK_GROUP_QL;
else
else
ASSERT(FALSE);
SetBitmap(hwndTaskbarBitmap, &m_hbmpTaskbar, uImageId);
@ -107,7 +107,7 @@ private:
uImageId = IDB_SYSTRAYPROP_SHOW_CLOCK;
else if (!bHideInactive && !bShowClock)
uImageId = IDB_SYSTRAYPROP_SHOW_NOCLOCK;
else
else
ASSERT(FALSE);
SetBitmap(hwndTrayBitmap, &m_hbmpTray, uImageId);
@ -129,7 +129,7 @@ public:
m_hwndTaskbar(hwnd)
{
}
~CTaskBarSettingsPage()
{
if (m_hbmpTaskbar)
@ -188,7 +188,7 @@ public:
class CStartMenuSettingsPage : public CPropertyPageImpl<CStartMenuSettingsPage>
{
private:
private:
HBITMAP m_hbmpStartBitmap;
void UpdateDialog()
@ -253,7 +253,7 @@ public:
// fix me: start menu style (classic/modern) should be read somewhere from the registry.
CheckDlgButton(IDC_TASKBARPROP_STARTMENUCLASSIC, BST_CHECKED); // HACK: This has to be read from registry!!!!!!!
UpdateDialog();
return TRUE;
}
@ -295,9 +295,9 @@ DisplayTrayProperties(IN HWND hwndOwner, IN HWND hwndTaskbar)
CTaskBarSettingsPage tbSettingsPage(hwndTaskbar);
CStartMenuSettingsPage smSettingsPage;
CStringW caption;
caption.LoadStringW(IDS_TASKBAR_STARTMENU_PROP_CAPTION);
hpsp[0] = tbSettingsPage.Create();
hpsp[1] = smSettingsPage.Create();

View file

@ -47,7 +47,7 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
if (SUCCEEDED(hr))
{
CATID catid = CATID_DeskBand;
hr = pcr->RegisterClassImplCategories(CLSID_QuickLaunchBand, 1, &catid);
hr = pcr->RegisterClassImplCategories(CLSID_QuickLaunchBand, 1, &catid);
}
return hr;
}
@ -59,7 +59,7 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
if (SUCCEEDED(hr))
{
CATID catid = CATID_DeskBand;
hr = pcr->UnRegisterClassImplCategories(CLSID_QuickLaunchBand, 1, &catid);
hr = pcr->UnRegisterClassImplCategories(CLSID_QuickLaunchBand, 1, &catid);
}
return hr;
}
@ -82,16 +82,16 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
LPITEMIDLIST PidlBrowse(HWND hwnd, int nCSIDL)
{
CComHeapPtr<ITEMIDLIST> pidlRoot;
WCHAR path[MAX_PATH];
if (nCSIDL)
{
SHGetSpecialFolderLocation(hwnd, nCSIDL, &pidlRoot);
}
}
BROWSEINFO bi = { hwnd, pidlRoot, path, L"Choose a folder", 0, NULL, 0, 0 };
LPITEMIDLIST pidlSelected = SHBrowseForFolder(&bi);
LPITEMIDLIST pidlSelected = SHBrowseForFolder(&bi);
return pidlSelected;
}
@ -132,24 +132,24 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
if (pidl == NULL)
return E_FAIL;
pISFB->InitializeSFB(pISF, pidl);
return hr;
}
// IObjectWithSite
STDMETHODIMP CQuickLaunchBand::SetSite(IUnknown *pUnkSite)
{
{
// Internal CISFBand Calls
CComPtr<IObjectWithSite> pIOWS;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IObjectWithSite, &pIOWS));
if (FAILED(hr))
return hr;
return hr;
return pIOWS->SetSite(pUnkSite);
}
STDMETHODIMP CQuickLaunchBand::GetSite(IN REFIID riid, OUT VOID **ppvSite)
{
{
CComPtr<IObjectWithSite> pIOWS;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IObjectWithSite, &pIOWS));
if (FAILED(hr))
@ -165,7 +165,7 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
// Internal CISFBand Calls
CComPtr<IDeskBand> pIDB;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IDeskBand, &pIDB));
if (FAILED(hr))
if (FAILED(hr))
return hr;
return pIDB->GetWindow(phwnd);
@ -183,53 +183,53 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
}
STDMETHODIMP CQuickLaunchBand::ShowDW(IN BOOL bShow)
{
{
// Internal CISFBand Calls
CComPtr<IDeskBand> pIDB;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IDeskBand, &pIDB));
if (FAILED(hr))
return hr;
return pIDB->ShowDW(bShow);
return pIDB->ShowDW(bShow);
}
STDMETHODIMP CQuickLaunchBand::CloseDW(IN DWORD dwReserved)
{
{
// Internal CISFBand Calls
CComPtr<IDeskBand> pIDB;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IDeskBand, &pIDB));
if (FAILED(hr))
if (FAILED(hr))
return hr;
return pIDB->CloseDW(dwReserved);
}
STDMETHODIMP CQuickLaunchBand::ResizeBorderDW(LPCRECT prcBorder, IUnknown *punkToolbarSite, BOOL fReserved)
{
STDMETHODIMP CQuickLaunchBand::ResizeBorderDW(LPCRECT prcBorder, IUnknown *punkToolbarSite, BOOL fReserved)
{
// Internal CISFBand Calls
CComPtr<IDeskBand> pIDB;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IDeskBand, &pIDB));
if (FAILED(hr))
if (FAILED(hr))
return hr;
return pIDB->ResizeBorderDW(prcBorder, punkToolbarSite, fReserved);
}
STDMETHODIMP CQuickLaunchBand::GetBandInfo(IN DWORD dwBandID, IN DWORD dwViewMode, IN OUT DESKBANDINFO *pdbi)
{
{
// Internal CISFBand Calls
CComPtr<IDeskBand> pIDB;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IDeskBand, &pIDB));
if (FAILED(hr))
if (FAILED(hr))
return hr;
return pIDB->GetBandInfo(dwBandID, dwViewMode, pdbi);
}
}
/*****************************************************************************/
// IPersistStream
STDMETHODIMP CQuickLaunchBand::GetClassID(OUT CLSID *pClassID)
{
{
// Internal CISFBand Calls
CComPtr<IPersistStream> pIPS;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IPersistStream, &pIPS));
@ -240,7 +240,7 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
}
STDMETHODIMP CQuickLaunchBand::IsDirty()
{
{
// Internal CISFBand Calls
CComPtr<IPersistStream> pIPS;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IPersistStream, &pIPS));
@ -261,7 +261,7 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
}
STDMETHODIMP CQuickLaunchBand::Save(IN IStream *pStm, IN BOOL fClearDirty)
{
{
// Internal CISFBand Calls
CComPtr<IPersistStream> pIPS;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IPersistStream, &pIPS));
@ -280,7 +280,7 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
return pIPS->GetSizeMax(pcbSize);
}
/*****************************************************************************/
// IWinEventHandler
@ -290,50 +290,50 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
}
STDMETHODIMP CQuickLaunchBand::OnWinEvent(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT *theResult)
{
{
// Internal CISFBand Calls
CComPtr<IWinEventHandler> pWEH;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IWinEventHandler, &pWEH));
if (FAILED(hr))
if (FAILED(hr))
return hr;
return pWEH->OnWinEvent(hWnd, uMsg, wParam, lParam, theResult);
}
STDMETHODIMP CQuickLaunchBand::IsWindowOwner(HWND hWnd)
{
{
// Internal CISFBand Calls
CComPtr<IWinEventHandler> pWEH;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IWinEventHandler, &pWEH));
if (FAILED(hr))
if (FAILED(hr))
return hr;
return pWEH->IsWindowOwner(hWnd);
}
/*****************************************************************************/
// *** IOleCommandTarget methods ***
STDMETHODIMP CQuickLaunchBand::QueryStatus(const GUID *pguidCmdGroup, ULONG cCmds, OLECMD prgCmds [], OLECMDTEXT *pCmdText)
{
{
// Internal CISFBand Calls
CComPtr<IOleCommandTarget> pOCT;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IOleCommandTarget, &pOCT));
if (FAILED(hr))
if (FAILED(hr))
return hr;
return pOCT->QueryStatus(pguidCmdGroup, cCmds, prgCmds, pCmdText);
}
STDMETHODIMP CQuickLaunchBand::Exec(const GUID *pguidCmdGroup, DWORD nCmdID, DWORD nCmdexecopt, VARIANT *pvaIn, VARIANT *pvaOut)
{
{
// Internal CISFBand Calls
CComPtr<IOleCommandTarget> pOCT;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IOleCommandTarget, &pOCT));
if (FAILED(hr))
if (FAILED(hr))
return hr;
return pOCT->Exec(pguidCmdGroup, nCmdID, nCmdexecopt, pvaIn, pvaOut);
}
}
/*****************************************************************************/
// *** IContextMenu ***
@ -342,7 +342,7 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
// Internal CISFBand Calls
CComPtr<IContextMenu> pICM;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IContextMenu, &pICM));
if (FAILED(hr))
if (FAILED(hr))
return hr;
return pICM->GetCommandString(idCmd, uFlags, pwReserved, pszName, cchMax);
@ -353,7 +353,7 @@ const GUID CLSID_QuickLaunchBand = { 0x260cb95d, 0x4544, 0x44f6, { 0xa0, 0x79, 0
// Internal CISFBand Calls
CComPtr<IContextMenu> pICM;
HRESULT hr = m_punkISFB->QueryInterface(IID_PPV_ARG(IContextMenu, &pICM));
if (FAILED(hr))
if (FAILED(hr))
return hr;
return pICM->InvokeCommand(pici);

View file

@ -18,14 +18,14 @@ class CQuickLaunchBand :
public CComCoClass<CQuickLaunchBand, &CLSID_QuickLaunchBand>,
public CComObjectRootEx<CComMultiThreadModelNoCS>,
public IObjectWithSite,
public IDeskBand,
public IDeskBand,
public IPersistStream,
public IWinEventHandler,
public IOleCommandTarget,
public IContextMenu
{
HWND m_hWndBro;
CComPtr<IUnknown> m_punkISFB;
CComPtr<IUnknown> m_punkISFB;
public:
@ -46,36 +46,36 @@ class CQuickLaunchBand :
virtual STDMETHODIMP SetSite(
IN IUnknown *pUnkSite
);
// IDeskBand
virtual STDMETHODIMP GetWindow(
OUT HWND *phwnd
);
);
virtual STDMETHODIMP ContextSensitiveHelp(
IN BOOL fEnterMode
);
);
virtual STDMETHODIMP ShowDW(
IN BOOL bShow
);
);
virtual STDMETHODIMP CloseDW(
IN DWORD dwReserved
);
);
virtual STDMETHODIMP ResizeBorderDW(
LPCRECT prcBorder,
IUnknown *punkToolbarSite,
BOOL fReserved
);
);
virtual STDMETHODIMP GetBandInfo(
IN DWORD dwBandID,
IN DWORD dwViewMode,
IN OUT DESKBANDINFO *pdbi
);
);
// IPersistStream
@ -98,17 +98,17 @@ class CQuickLaunchBand :
IN BOOL fClearDirty
);
// IWinEventHandler
// IWinEventHandler
virtual STDMETHODIMP ContainsWindow(
IN HWND hWnd
);
virtual STDMETHODIMP OnWinEvent(
HWND hWnd,
UINT uMsg,
WPARAM wParam,
LPARAM lParam,
HWND hWnd,
UINT uMsg,
WPARAM wParam,
LPARAM lParam,
LRESULT *theResult
);
@ -169,5 +169,5 @@ class CQuickLaunchBand :
COM_INTERFACE_ENTRY_IID(IID_IWinEventHandler, IWinEventHandler)
COM_INTERFACE_ENTRY_IID(IID_IOleCommandTarget, IOleCommandTarget)
COM_INTERFACE_ENTRY_IID(IID_IContextMenu, IContextMenu)
END_COM_MAP()
END_COM_MAP()
};

View file

@ -232,7 +232,7 @@ public:
if (IsEqualCLSID(m_Clsid, CLSID_StartMenu))
return RSHELL_CStartMenu_CreateInstance(riid, ppvObject);
if (IsEqualCLSID(m_Clsid, CLSID_MenuDeskBar))
return RSHELL_CMenuDeskBar_CreateInstance(riid, ppvObject);