void MediaWindow::_AddNodeItems(NodeList& list, MediaListItem::media_type type) { int32 count = list.CountItems(); for (int32 i = 0; i < count; i++) { dormant_node_info* info = list.ItemAt(i); if (_FindNodeListItem(info) == NULL) fListView->AddItem(new NodeListItem(info, type)); } }
void TreeTableNode::DetachRow() { fRow = NULL; if (fChildren != NULL) { for (int32 i = 0; TreeTableNode* child = fChildren->ItemAt(i); i++) child->DetachRow(); } }
void SettingsView::_PopulateMenu(BMenu* menu, NodeList& nodes, const BMessage& message) { for (int32 i = 0; i < nodes.CountItems(); i++) { dormant_node_info* info = nodes.ItemAt(i); menu->AddItem(new NodeMenuItem(info, new BMessage(message))); } if (Window() != NULL) menu->SetTargetForItems(BMessenger(this)); }
TreeTableNode* TreeTableNode::ChildAt(int32 index) { return fChildren != NULL ? fChildren->ItemAt(index) : NULL; }