本文整理汇总了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++;
}
}
示例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;
}
示例3: ClearModelTree
void ClearModelTree()
{
Button_Enable(GetControl(IDC_START),false);
Button_Enable(GetControl(IDC_CLEARMODELS),false);
g_targets.clear();
TreeView_DeleteAllItems(GetControl(IDC_MODELS));
}
示例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;
}
示例5: CloseBCP
void CloseBCP()
{
if(!file) return;
free(fent); free(fetime);
fclose(file); file = 0; nfiles = 0;
TreeView_DeleteAllItems(htree);
}
示例6: rowOptFillRowTree
int rowOptFillRowTree(HWND hwnd)
{
TreeView_DeleteAllItems(hwnd);
rowOptGenerateTreeView(rowOptTmplRoot, NULL, hwnd);
TreeView_Expand(hwnd, TreeView_GetRoot(hwnd), TVM_EXPAND);
return 0;
}
示例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();
}
示例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;
}
示例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;
}
示例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);
}
示例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;
}
示例12: TreeView_GetRoot
void plResTreeView::ClearTreeView( HWND hWnd )
{
HTREEITEM root = TreeView_GetRoot( hWnd );
if( root != nil )
IDeleteRecurse( hWnd, root );
TreeView_DeleteAllItems( hWnd );
}
示例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();
}
示例14: getNextSibling
void TreeView::removeAllItems()
{
for (HTREEITEM tvProj = getRoot();
tvProj != NULL;
tvProj = getNextSibling(tvProj))
{
cleanSubEntries(tvProj);
}
TreeView_DeleteAllItems(_hSelf);
}
示例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);
}