MCPcopy Create free account
hub / github.com/SOUI2/soui / CreateListBox

Method CreateListBox

SOUI/src/control/SComboView.cpp:21–39  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19 }
20
21 BOOL SComboView::CreateListBox(pugi::xml_node xmlNode)
22 {
23 SASSERT(xmlNode);
24 //创建列表控件
25 pugi::xml_node listStyle = xmlNode.child(L"listStyle");
26 SStringW strListClass = listStyle.attribute(L"wndclass").as_string(SListView::GetClassName());
27 m_pListBox=sobj_cast<SListView>(SApplication::getSingleton().CreateWindowByName(strListClass));
28 SASSERT(m_pListBox);
29
30 m_pListBox->SetContainer(GetContainer());
31
32 m_pListBox->InitFromXml(listStyle);
33 m_pListBox->SetAttribute(L"pos", L"0,0,-0,-0", TRUE);
34 m_pListBox->SetAttribute(L"hotTrack",L"1",TRUE);
35 m_pListBox->SetOwner(this); //chain notify message to combobox
36 m_pListBox->SetID(IDC_DROPDOWN_LIST);
37
38 return TRUE;
39 }
40
41 int SComboView::GetListBoxHeight()
42 {

Callers

nothing calls this directly

Calls 10

GetClassNameFunction · 0.85
CreateWindowByNameMethod · 0.80
SetContainerMethod · 0.80
SetOwnerMethod · 0.80
childMethod · 0.45
as_stringMethod · 0.45
attributeMethod · 0.45
InitFromXmlMethod · 0.45
SetAttributeMethod · 0.45
SetIDMethod · 0.45

Tested by

no test coverage detected