| 16 | CInfoDocument::~CInfoDocument(void) {} |
| 17 | |
| 18 | BOOL CInfoDocument::net_Spawn(CSE_Abstract* DC) |
| 19 | { |
| 20 | BOOL res = inherited::net_Spawn(DC); |
| 21 | |
| 22 | CSE_Abstract* l_tpAbstract = static_cast<CSE_Abstract*>(DC); |
| 23 | CSE_ALifeItemDocument* l_tpALifeItemDocument = smart_cast<CSE_ALifeItemDocument*>(l_tpAbstract); |
| 24 | R_ASSERT(l_tpALifeItemDocument); |
| 25 | |
| 26 | m_Info.clear(); |
| 27 | shared_str m_wDoc = l_tpALifeItemDocument->m_wDoc; |
| 28 | if (m_wDoc.size()) |
| 29 | m_Info.push_back(m_wDoc.c_str()); |
| 30 | |
| 31 | CInifile& ini = l_tpAbstract->spawn_ini(); |
| 32 | if (ini.section_exist("known_info")) |
| 33 | { |
| 34 | const auto& sect = ini.r_section("known_info"); |
| 35 | for (const auto& I : sect.Data) |
| 36 | { |
| 37 | m_Info.push_back(I.first.c_str()); |
| 38 | } |
| 39 | } |
| 40 | |
| 41 | if (pSettings->line_exist(l_tpAbstract->name(), "known_info")) |
| 42 | { |
| 43 | LPCSTR S = pSettings->r_string(l_tpAbstract->name(), "known_info"); |
| 44 | if (S && S[0]) |
| 45 | { |
| 46 | string128 info; |
| 47 | int count = _GetItemCount(S); |
| 48 | for (int it = 0; it < count; ++it) |
| 49 | { |
| 50 | _GetItem(S, it, info); |
| 51 | m_Info.push_back(info); |
| 52 | } |
| 53 | } |
| 54 | } |
| 55 | |
| 56 | return (res); |
| 57 | } |
| 58 | |
| 59 | void CInfoDocument::Load(LPCSTR section) { inherited::Load(section); } |
| 60 |
nothing calls this directly
no test coverage detected