SECToolBarManager::AddToolBarResource
Adds a toolbar bitmap resource to the composite image to be referenced by all custom toolbar button objects.
Defined in: tbarmgr.cpp
Syntax
AddToolBarResource(LPCTSTR lpszStdBmpName, LPCTSTR lpszLargeBmpName)
AddToolBarResource(UINT nIDStdBmp,UINT nIDLargeBmp)
Return Value
True if toolbar bitmap was successfully added..
Parameters
lpszStdBmpName
Resource string for bitmap of the standard size buttons.
lpszLargeBmpName
Resource string for bitmap of the large size buttons. If you are not supplying "large button mode", you can use the same resource string as specified by lpszStdBmpName.
nIDStdBmp
Like lpszStdBmpName, but a resource id.
nIDLargeBmp
Like lpszLargeBmpName, but a resource id.
Comments
Used in conjunction with LoadToolBarResource(), this function can be used to concatenate multiple toolbar bitmap resources into 1 large composite resource. See comments in SECToolBarManager::LoadToolBarResource for more information on this process.
Example
CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct) {
SECToolBarManager* pToolBarMgr=(SECToolBarManager *)m_pControlBarManager;
pMgr->AddToolBarResource(MAKEINTRESOURCE(IDR_MAINFRAME1),MAKEINTRESOURCE(IDR_MAINFRAMELARGE1));
pMgr->AddToolBarResource(MAKEINTRESOURCE(IDR_MAINFRAME2),MAKEINTRESOURCE(IDR_MAINFRAMELARGE2));
VERIFY(pMgr->LoadToolBarResource());
...
See Also