MCPcopy Create free account
hub / github.com/GrapheneCt/NetStream / First

Method First

NetStream/source/menus/menu_first.cpp:20–46  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18static bool s_afterBoot = true;
19
20menu::First::First() : GenericMenu("page_first", MenuOpenParam(true), MenuCloseParam()), m_showHvdb(false)
21{
22 Plugin::TemplateOpenParam tmpParam;
23
24 if (LocalFile::Exists("app0:config.ini"))
25 {
26 m_showHvdb = true;
27 }
28
29 auto topText = static_cast<ui::Text *>(m_root->FindChild(text_top));
30 wstring title = g_appPlugin->GetString(msg_title_menu_first);
31 topText->SetString(title);
32
33 m_rootList = static_cast<ui::ListView *>(m_root->FindChild(list_view_generic));
34 m_rootList->SetItemFactory(new ListViewFactory(this));
35 m_rootList->InsertSegment(0, 1);
36 m_rootList->SetCellSizeDefault(0, { 960.0f, 80.0f });
37 m_rootList->SetSegmentLayoutType(0, ui::ListView::LAYOUT_TYPE_LIST);
38 if (m_showHvdb)
39 {
40 m_rootList->InsertCell(0, 0, 5);
41 }
42 else
43 {
44 m_rootList->InsertCell(0, 0, 4);
45 }
46}
47
48menu::First::~First()
49{

Callers

nothing calls this directly

Calls 2

MenuOpenParamClass · 0.85
MenuCloseParamClass · 0.85

Tested by

no test coverage detected