本文整理汇总了C++中fsPluginMgr类的典型用法代码示例。如果您正苦于以下问题:C++ fsPluginMgr类的具体用法?C++ fsPluginMgr怎么用?C++ fsPluginMgr使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了fsPluginMgr类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: if
void CPluginFrame2::OnNewLng()
{
m_wndTabs.DeleteAllItems ();
int i = 0;
for (i = 0; i < _PluginMgr.GetPluginCount (); i++)
{
fsPluginInfo *plug = &_PluginMgr.Plugin (i);
if (i < 3 || m_bMoreTabs)
m_wndTabs.InsertItem (i, plug->strName);
else if (i == 3)
m_wndTabs.InsertItem (i, ">>");
if (i == m_iActivePlugin)
{
m_pMainFrame->AddPluginMenu (plug->hMenuMain, plug->pMenuMainImages, plug->cMenuMainImages);
m_pMainFrame->AddPluginMenuView (plug->hMenuView, plug->pMenuViewImages, plug->cMenuViewImages, plug->pMenuViewItems, plug->cMenuViewItems);
}
}
if (m_bMoreTabs)
m_wndTabs.InsertItem (i, "<<");
m_wndTabs.SetCurSel (m_iActivePlugin);
}
开发者ID:zhenyouluo,项目名称:Free-Download-Manager-vs2010,代码行数:25,代码来源:PluginFrame2.cpp
示例2: Initialize
BOOL CPlugToolBar::Initialize()
{
m_pMainFrame = (CMainFrame*) AfxGetApp ()->m_pMainWnd;
if (FALSE == _PluginMgr.LoadPlugins (m_pPlugFrame))
return FALSE;
int cMenuImages;
for (int i = 0; i < _PluginMgr.GetPluginCount (); i++)
{
fsPluginInfo &plug = _PluginMgr.Plugin (i);
AddString (plug.strName);
::ShowWindow (plug.hWnd, SW_HIDE);
if (plug.pbmpMenuImages)
{
cMenuImages = m_pMainFrame->m_imgsTool.GetImageCount ();
m_pMainFrame->m_imgsTool.Add (plug.pbmpMenuImages, RGB (255, 0, 255));
m_pMainFrame->m_dimgsTool.Add (plug.pbmpMenuDImages, RGB (255, 0, 255));
delete plug.pbmpMenuImages;
delete plug.pbmpMenuDImages;
plug.pbmpMenuImages = plug.pbmpMenuDImages = NULL;
for (int j = 0; j < plug.cMenuMainImages; j++)
{
plug.pMenuMainImages [j].iCheckImage += cMenuImages;
plug.pMenuMainImages [j].iImage += cMenuImages;
}
for (int j = 0; j < plug.cMenuViewImages; j++)
{
plug.pMenuViewImages [j].iCheckImage += cMenuImages;
plug.pMenuViewImages [j].iImage += cMenuImages;
}
}
}
int iPlug = _App.ActivePlugin ();
if (iPlug >= _PluginMgr.GetPluginCount () || iPlug < 0)
iPlug = 0;
SetActivePlugin (iPlug);
return TRUE;
}
开发者ID:pedia,项目名称:raidget,代码行数:50,代码来源:plugtoolbar.cpp
示例3: OnNewLng
void CPlugToolBar::OnNewLng()
{
ResetContent ();
for (int i = 0; i < _PluginMgr.GetPluginCount (); i++)
{
fsPluginInfo *plug = &_PluginMgr.Plugin (i);
AddString (plug->strName);
if (i == m_iActivePlugin)
{
m_pPlugFrame->SetFrameName (plug->strLongName);
m_pMainFrame->AddPluginMenu (plug->hMenuMain, plug->pMenuMainImages, plug->cMenuMainImages);
m_pMainFrame->AddPluginMenuView (plug->hMenuView, plug->pMenuViewImages, plug->cMenuViewImages, plug->pMenuViewItems, plug->cMenuViewItems);
}
}
}
开发者ID:pedia,项目名称:raidget,代码行数:16,代码来源:plugtoolbar.cpp
示例4: OnUpdatePluginCommand
void CChildView::OnUpdatePluginCommand(CCmdUI *pCmdUI)
{
#if 0
// TODO: remote tab
int state = _PluginMgr.OnUpdateToolBar (pCmdUI->m_nID);
pCmdUI->Enable ((state & WGP_CMDITEMSTATE_DISABLED) == 0);
pCmdUI->SetCheck (state & WGP_CMDITEMSTATE_CHECKED ? 1 : 0);
#endif
}
开发者ID:pedia,项目名称:raidget,代码行数:10,代码来源:childview.cpp
示例5:
void CPluginFrame2::OnSetFocus(CWnd* pOldWnd)
{
CWnd::OnSetFocus(pOldWnd);
if (m_iActivePlugin != -1)
{
fsPluginInfo &plug = _PluginMgr.Plugin (m_iActivePlugin);
::SetFocus (plug.hWnd);
}
}
开发者ID:zhenyouluo,项目名称:Free-Download-Manager-vs2010,代码行数:10,代码来源:PluginFrame2.cpp
示例6: SetActivePlugin
void CPlugToolBar::SetActivePlugin(int iPlugin)
{
if (m_iActivePlugin == iPlugin)
return;
if (m_iActivePlugin != -1)
{
::ShowWindow (_PluginMgr.Plugin (m_iActivePlugin).hWnd, SW_HIDE);
m_pMainFrame->RemovePluginMenu ();
m_pMainFrame->RemovePluginMenuView ();
_TBMgr.HideGroup (m_iActivePlugin + 1);
}
int iOld = m_iActivePlugin;
m_iActivePlugin = iPlugin;
CRect rc;
GetItemRect (iOld, &rc);
InvalidateRect (&rc, FALSE);
GetItemRect (iPlugin, &rc);
InvalidateRect (&rc, FALSE);
fsPluginInfo &plug = _PluginMgr.Plugin (iPlugin);
m_pMainFrame->AddPluginMenu (plug.hMenuMain, plug.pMenuMainImages, plug.cMenuMainImages);
m_pMainFrame->AddPluginMenuView (plug.hMenuView, plug.pMenuViewImages, plug.cMenuViewImages, plug.pMenuViewItems, plug.cMenuViewItems);
m_pPlugFrame->SetPluginWindow (plug.hWnd);
m_pPlugFrame->SetFrameName (plug.strLongName);
::ShowWindow (plug.hWnd, SW_SHOW);
::SetFocus (plug.hWnd);
_TBMgr.ShowGroup (m_iActivePlugin + 1, 6);
_PluginMgr.OnSetActivePlugin (iPlugin);
}
开发者ID:pedia,项目名称:raidget,代码行数:37,代码来源:plugtoolbar.cpp
示例7: DrawItem
void CPlugToolBar::DrawItem(LPDRAWITEMSTRUCT lpDraw)
{
CDC *pDC = CDC::FromHandle (lpDraw->hDC);
CString strItem;
Erase (pDC, lpDraw->rcItem);
GetText (lpDraw->itemID, strItem);
CPoint pt (lpDraw->rcItem.left + (lpDraw->rcItem.right - lpDraw->rcItem.left) / 2 - 32/2, lpDraw->rcItem.top + 5);
if (m_iPressed == (int)lpDraw->itemID)
DrawPressed (pDC, pt);
else if (m_iMayBeSelected == (int)lpDraw->itemID)
DrawMayBeSelected (pDC, pt);
lpDraw->rcItem.top += 32+6+3;
SetBkMode (lpDraw->hDC, TRANSPARENT);
if (lpDraw->itemID == (UINT) m_iActivePlugin)
pDC->SetTextColor (RGB (255, 255, 255));
else
SetTextColor (lpDraw->hDC, RGB (235, 235, 235));
HGDIOBJ oldFont = SelectObject (lpDraw->hDC, m_font.m_hObject);
DrawText (lpDraw->hDC, strItem, strItem.GetLength (), &lpDraw->rcItem, DT_TOP | DT_CENTER);
SelectObject (lpDraw->hDC, oldFont);
if (m_iPressed == (int)lpDraw->itemID)
{
pt.x++;
pt.y++;
}
_PluginMgr.GetImages ()->Draw (pDC, lpDraw->itemID, pt, ILD_TRANSPARENT);
}
开发者ID:pedia,项目名称:raidget,代码行数:42,代码来源:plugtoolbar.cpp
示例8: SendPluginCommand
void CPlugToolBar::SendPluginCommand(UINT uCmd)
{
::SendMessage (_PluginMgr.Plugin (m_iActivePlugin).hWnd, WM_COMMAND, uCmd, 0);
}
开发者ID:pedia,项目名称:raidget,代码行数:4,代码来源:plugtoolbar.cpp
注:本文中的fsPluginMgr类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论