当前位置: 首页>>代码示例>>C++>>正文


C++ TreeView_DeleteAllItems函数代码示例

本文整理汇总了C++中TreeView_DeleteAllItems函数的典型用法代码示例。如果您正苦于以下问题:C++ TreeView_DeleteAllItems函数的具体用法?C++ TreeView_DeleteAllItems怎么用?C++ TreeView_DeleteAllItems使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了TreeView_DeleteAllItems函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: TreeView_DeleteAllItems

void CConfig::FillTree(HWND hTree,bool bCList)
{
	TreeView_DeleteAllItems(hTree);

	TVINSERTSTRUCT tvis;
	tvis.hParent=NULL;
	tvis.hInsertAfter=TVI_LAST;
	tvis.item.mask=TVIF_PARAM|TVIF_TEXT|TVIF_IMAGE|TVIF_SELECTEDIMAGE;	
	
	vector<CProtoFilter*>::iterator iter = m_ProtoList.begin();
	while(iter != m_ProtoList.end())
	{
		tvis.item.lParam=(LPARAM)(*iter);
		tvis.item.pszText= (LPTSTR)(*iter)->strName.c_str();
		if(!bCList)
		{
			tvis.item.iImage= (*iter)->bNotificationFilter;
			(*iter)->bTempNotificationFilter = (*iter)->bNotificationFilter;
		}
		else
		{
			tvis.item.iImage= (*iter)->bContactlistFilter;
			(*iter)->bTempContactlistFilter = (*iter)->bContactlistFilter;
		}
		tvis.item.iSelectedImage= tvis.item.iImage;
		
		TreeView_InsertItem(hTree,&tvis);
		iter++;
	}
}
开发者ID:Tharit,项目名称:g15-im-applets,代码行数:30,代码来源:CConfig.cpp

示例2: BuildMenuObjectsTree

static int BuildMenuObjectsTree(HWND hwndDlg)
{
	TVINSERTSTRUCT tvis;
	HWND hTree = GetDlgItem(hwndDlg,IDC_MENUOBJECTS);
	int i;

	tvis.hParent = NULL;
	tvis.hInsertAfter = TVI_LAST;
	tvis.item.mask = TVIF_PARAM | TVIF_TEXT | TVIF_IMAGE | TVIF_SELECTEDIMAGE;
	TreeView_DeleteAllItems( hTree );
	if ( g_menus.getCount() == 0 )
		return FALSE;

	for ( i=0; i < g_menus.getCount(); i++ ) {
		if ( g_menus[i]->id == (int)hStatusMenuObject  || !g_menus[i]->m_bUseUserDefinedItems )
			continue;

		tvis.item.lParam  = ( LPARAM )g_menus[i]->id;
		tvis.item.pszText = LangPackPcharToTchar( g_menus[i]->Name );
		tvis.item.iImage  = tvis.item.iSelectedImage = TRUE;
		TreeView_InsertItem( hTree, &tvis );
		mir_free( tvis.item.pszText );
	}
	return 1;
}
开发者ID:TonyAlloa,项目名称:miranda-dev,代码行数:25,代码来源:genmenuopt.cpp

示例3: ClearModelTree

void ClearModelTree()
{
	Button_Enable(GetControl(IDC_START),false);
	Button_Enable(GetControl(IDC_CLEARMODELS),false);
	g_targets.clear();
	TreeView_DeleteAllItems(GetControl(IDC_MODELS));
}
开发者ID:yanqinghuang,项目名称:BehaviorDetection,代码行数:7,代码来源:tracking_ui.cpp

示例4: FillTree

int FillTree(HWND hwnd)
{
	ProtocolData *PD;

	TVINSERTSTRUCT tvis;
	tvis.hParent = NULL;
	tvis.hInsertAfter = TVI_LAST;
	tvis.item.mask = TVIF_PARAM | TVIF_TEXT | TVIF_IMAGE | TVIF_SELECTEDIMAGE;

	TreeView_DeleteAllItems(hwnd);

	int n;
	PROTOACCOUNT** pa;
	Proto_EnumAccounts(&n, &pa);

	for (int i = 0; i < n; i++) {
		if (Proto_IsAccountEnabled(pa[i])) {
			PD = (ProtocolData*)mir_alloc(sizeof(ProtocolData));
			PD->RealName = pa[i]->szModuleName;
			PD->enabled = IsProtoIM(pa[i]);
			PD->show = PD->enabled ? (plSets->ProtoDisabled(PD->RealName) ? 1 : 0) : 100;

			tvis.item.lParam = (LPARAM)PD;
			tvis.item.pszText = pa[i]->tszAccountName;
			tvis.item.iImage = tvis.item.iSelectedImage = PD->show;
			TreeView_InsertItem(hwnd, &tvis);
		}
	}

	return 0;
}
开发者ID:Seldom,项目名称:miranda-ng,代码行数:31,代码来源:opt_proto.cpp

示例5: CloseBCP

void CloseBCP()
{
	if(!file) return;
	free(fent); free(fetime);
	fclose(file); file = 0; nfiles = 0;
	TreeView_DeleteAllItems(htree);
}
开发者ID:AdrienTD,项目名称:wktools,代码行数:7,代码来源:bcpview.c

示例6: rowOptFillRowTree

int rowOptFillRowTree(HWND hwnd)
{
	TreeView_DeleteAllItems(hwnd);
	rowOptGenerateTreeView(rowOptTmplRoot, NULL, hwnd);
	TreeView_Expand(hwnd, TreeView_GetRoot(hwnd), TVM_EXPAND);
	return 0;
}
开发者ID:Seldom,项目名称:miranda-ng,代码行数:7,代码来源:modern_rowtemplateopt.cpp

示例7: GetDlgItem

//// IFillAgeTree /////////////////////////////////////////////////////////////
//  Refreshes/inits the tree view of all ages we have to work with. If
//  specified, will also get the latest version of the .age files from assetMan.
void plAgeDescInterface::IFillAgeTree( void )
{
    HWND ageTree = GetDlgItem( fhDlg, IDC_AGE_LIST );

    // Clear the tree first and add our two root headers
    TreeView_DeleteAllItems(ageTree);

#ifdef MAXASS_AVAILABLE
    if( fAssetManIface != nil )
        fAssetManBranch = SAddTreeItem(ageTree, nil, "AssetMan Ages", -1);
    else
        fAssetManBranch = nil;
#endif

    fLocalBranch = SAddTreeItem(ageTree, nil, "Local Ages", -1);

    IGetAgeFiles(fAgeFiles);

    // Add the ages to the tree
    for (int i = 0; i < fAgeFiles.size(); i++)
    {
        SAddTreeItem(ageTree,
                    (fAgeFiles[i]->fType == plAgeFile::kAssetFile) ? fAssetManBranch : fLocalBranch,
                    fAgeFiles[i]->fAgeName.c_str(),
                    i);
    }

    // Select the first age to view
    IUpdateCurAge();
}
开发者ID:Hoikas,项目名称:Plasma,代码行数:33,代码来源:plAgeDescInterface.cpp

示例8: DeleteAllItems

void DeleteAllItems(int page)
{
    int i;
    TreeView_DeleteAllItems(hwndTree[page]);
    for (i = 0; i < watchinfo_count[page]; i++)
        FreeVarInfo(watchinfo_list[page][i].info);
    watchinfo_count[page] = 0;
}
开发者ID:doniexun,项目名称:OrangeC,代码行数:8,代码来源:dbgwatch.c

示例9: DeleteAllItems

static void DeleteAllItems(WATCHDATA *ptr)
{
    int i;
    TreeView_DeleteAllItems(ptr->hwndWatchTree);
    for (i = 0; i < ptr->watchinfo_count; i++)
        FreeVarInfo(ptr->watchinfo_list[i].info);
    ptr->watchinfo_count = 0;
}
开发者ID:bencz,项目名称:OrangeC,代码行数:8,代码来源:dbgwatch.c

示例10: SendMessage

void TreeCtrl::Clear() {
    HWND hwnd = this->hwnd;
    SendMessage(hwnd, WM_SETREDRAW, FALSE, 0);
    TreeView_DeleteAllItems(hwnd);
    SendMessage(hwnd, WM_SETREDRAW, TRUE, 0);
    UINT flags = RDW_ERASE | RDW_FRAME | RDW_INVALIDATE | RDW_ALLCHILDREN;
    RedrawWindow(hwnd, nullptr, nullptr, flags);
}
开发者ID:jingyu9575,项目名称:sumatrapdf,代码行数:8,代码来源:TreeCtrl.cpp

示例11: TreeView_DeleteAllItems

bool CWindowTreeDlg::RefreshTree()
{
    TreeView_DeleteAllItems(GetDlgItem(*this, IDC_WINDOWTREE));
    m_lastTreeItem = TVI_ROOT;
    EnumWindows(WindowEnumerator, (LPARAM)this);
    SelectTreeItem(m_SelectedWindow);
    return true;
}
开发者ID:dbremner,项目名称:sendmessage,代码行数:8,代码来源:WindowTreeDlg.cpp

示例12: TreeView_GetRoot

void    plResTreeView::ClearTreeView( HWND hWnd )
{
    HTREEITEM   root = TreeView_GetRoot( hWnd );
    if( root != nil )
        IDeleteRecurse( hWnd, root );

    TreeView_DeleteAllItems( hWnd );
}
开发者ID:RPLawrence,项目名称:Plasma,代码行数:8,代码来源:plResTreeView.cpp

示例13: SendMessage

void ModelTreeDialog::clearTreeView(void)
{
	m_clearing = true;
	SendMessage(m_hTreeView, WM_SETREDRAW, FALSE, 0);
	TreeView_DeleteAllItems(m_hTreeView);
	SendMessage(m_hTreeView, WM_SETREDRAW, TRUE, 0);
	TreeView_SelectItem(m_hTreeView, NULL);
	m_clearing = false;
	updateStatusText();
}
开发者ID:HazenBabcock,项目名称:LDView,代码行数:10,代码来源:ModelTreeDialog.cpp

示例14: getNextSibling

void TreeView::removeAllItems()
{
	for (HTREEITEM tvProj = getRoot();
        tvProj != NULL;
        tvProj = getNextSibling(tvProj))
	{
		cleanSubEntries(tvProj);
	}
	TreeView_DeleteAllItems(_hSelf);
}
开发者ID:Loreia,项目名称:UDL2,代码行数:10,代码来源:TreeView.cpp

示例15: TreeView_DeleteAllItems

void
mxTreeView::remove (mxTreeViewItem *item)
{
    if (!d_this)
        return;

    if (!item)
        TreeView_DeleteAllItems (d_this->d_hwnd);
    else
        TreeView_DeleteItem (d_this->d_hwnd, (HTREEITEM) item);
}
开发者ID:xsopher,项目名称:VinHax,代码行数:11,代码来源:mxtreeview.cpp


注:本文中的TreeView_DeleteAllItems函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。