本文整理汇总了C++中ProjectItem::GetType方法的典型用法代码示例。如果您正苦于以下问题:C++ ProjectItem::GetType方法的具体用法?C++ ProjectItem::GetType怎么用?C++ ProjectItem::GetType使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ProjectItem
的用法示例。
在下文中一共展示了ProjectItem::GetType方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: Refresh
void ScoreErrorsDlg::Refresh()
{
itmSel.ResetContent();
ProjectItem *pi = prjTree->FirstChild(theProject->nlInfo);
while (pi)
{
if (pi->GetType() == PRJNODE_NOTEFILE)
{
int ndx = itmSel.AddString(pi->GetName());
itmSel.SetItemDataPtr(ndx, (void*)pi);
}
pi = prjTree->NextSibling(pi);
}
itmSel.SetCurSel(0);
ShowErrors();
}
示例2: Save
int InstrList::Save(XmlSynthElem *node)
{
XmlSynthElem *child = node->AddChild("instrlib");
ProjectItem *pi = prjTree->FirstChild(this);
while (pi)
{
if (pi->GetType() == PRJNODE_INSTR)
{
XmlSynthElem *instr = child->AddChild("instr");
InstrItem *ii = (InstrItem *) pi;
ii->Save(instr);
delete instr;
}
pi = prjTree->NextSibling(pi);
}
delete child;
return 0;
}
示例3: OnInitDialog
void WavetableSelectDlg::OnInitDialog(wxInitDialogEvent& evt)
{
CenterOnParent();
wxWindow *frm = FindWindow("IDC_WT_GRAPH");
if (!frm)
return;
wxPoint pos = frm->GetPosition();
wxSize siz = frm->GetSize();
frm->Destroy();
plotter = new WavetableDraw(this, 99, pos, siz);
plotter->index = initSelect;
lst = (wxListBox*)FindWindow("IDC_WT_LIST");
lst->Append("Sin", (void*)0);
lst->Append("Sawtooth (sum)", (void*)1);
lst->Append("Square (sum)", (void*)2);
lst->Append("Triangle (sum)", (void*)3);
lst->Append("Pulse (sum)", (void*)4);
lst->Append("Sawtooth (direct)", (void*)5);
lst->Append("Square (direct)", (void*)6);
lst->Append("Triangle (direct)", (void*)7);
lst->Append("Sawtooth (positive)", (void*)8);
lst->Append("Triangle (positive)", (void*)9);
int selected = initSelect;
ProjectItem *pi = prjTree->FirstChild(theProject->synthInfo);
while (pi)
{
if (pi->GetType() == PRJNODE_WVTABLE)
{
WavetableItem *wi = (WavetableItem*)pi;
int index = lst->Append(wi->GetName(), (void*)(long)wi->GetID());
if (wi->GetID() == initSelect)
selected = index;
}
pi = prjTree->NextSibling(pi);
}
if ((unsigned int)selected < lst->GetCount())
lst->SetSelection(selected);
}
示例4: NextInum
int InstrList::NextInum()
{
int inum = 1;
InstrConfig *ic = 0;
ProjectItem *pi = prjTree->FirstChild(theProject->instrInfo);
while (pi)
{
if (pi->GetType() == PRJNODE_INSTR)
{
InstrItem *ii = (InstrItem *) pi;
ic = ii->GetConfig();
if (ic && ic->inum < 16384 && ic->inum >= inum)
inum = ic->inum+1;
}
pi = prjTree->NextSibling(pi);
}
// check against library values...
while ((ic = theProject->mgr.FindInstr(inum)) != 0)
inum++;
return inum;
}