예제 #1
0
void CWndMoveOrPasteTo::Init()
{
	CTreeViewUI *pTreeView = static_cast<CTreeViewUI*>(m_PaintManager.FindControl(_T("tree_file")));
	CTreeNodeUI *pRoot = static_cast<CTreeNodeUI*>(pTreeView->GetItemAt(0));

	CFileHandle *pFileRoot = CFileHandleManager::GetSingleInstance()->GetFileHandleTree();
	pRoot->SetAttribute(_T("checkboxattr"), _T("width=\"20\" height=\"20\" enabled=\"false\" bkimage=\"file='dir_icon_small' dest='4,2,20,18'\""));
	pRoot->SetTag((UINT_PTR)pFileRoot);

	EnumFileHandleTreeAddToTree(pRoot);

	pTreeView->ExpandItem(0,false);
}
예제 #2
0
CTreeNodeUI * CWndMoveOrPasteTo::CreateTreeNode( CFileHandle *pFileHandle )
{
	CTreeNodeUI *pRetNode = new CTreeNodeUI;
	pRetNode->SetItemText(pFileHandle->GetFileName().c_str());
	pRetNode->SetAttribute(_T("endellipsis"), _T("true"));
	pRetNode->GetTreeNodeHoriznotal()->SetToolTip(pFileHandle->GetFileName().c_str());
	pRetNode->GetItemButton()->SetFont(6);
	pRetNode->SetFixedHeight(20);

	pRetNode->SetTag((UINT_PTR)pFileHandle);	

	pRetNode->SetAttribute(_T("itemattr"), _T("textpadding=\"2,0,0,0\" textcolor=\"#FF000000\""));
	pRetNode->SetAttribute(_T("checkboxattr"), _T("width=\"20\" height=\"20\" enabled=\"false\" bkimage=\"file='dir_icon_small' dest='4,2,20,18'\""));
	pRetNode->SetAttribute(_T("folderattr"), _T("padding=\"0,5,0,5\" width=\"7\" height=\"1\""));

	pRetNode->GetFolderButton()->SetVisible(false);

	return pRetNode;
}