void TreeListCtrlTestCase::Create(long style) { m_treelist = new wxTreeListCtrl(wxTheApp->GetTopWindow(), wxID_ANY, wxDefaultPosition, wxSize(400, 200), style); m_treelist->AppendColumn("Component"); m_treelist->AppendColumn("# Files"); m_treelist->AppendColumn("Size"); // Fill the control with the same data as used in the treelist sample: m_code = AddItem("Code"); AddItem("wxMSW", m_code, "313", "3.94 MiB"); AddItem("wxGTK", m_code, "180", "1.66 MiB"); m_code_osx = AddItem("wxOSX", m_code, "265", "2.36 MiB"); AddItem("Core", m_code_osx, "31", "347 KiB"); AddItem("Carbon", m_code_osx, "91", "1.34 MiB"); m_code_osx_cocoa = AddItem("Cocoa", m_code_osx, "46", "512 KiB"); wxTreeListItem Documentation = AddItem("Documentation"); AddItem("HTML", Documentation, "many"); AddItem("CHM", Documentation, "1"); wxTreeListItem Samples = AddItem("Samples"); AddItem("minimal", Samples, "1", "7 KiB"); AddItem("widgets", Samples, "28", "419 KiB"); m_treelist->Refresh(); m_treelist->Update(); }