MCPcopy Create free account
hub / github.com/OpenXcom/OpenXcom / btnReportClick

Method btnReportClick

src/Geoscape/ResearchCompleteState.cpp:106–127  ·  view source on GitHub ↗

* open the Ufopaedia to the entry about the Research. * @param action Pointer to an action. */

Source from the content-addressed store, hash-verified

104 * @param action Pointer to an action.
105 */
106void ResearchCompleteState::btnReportClick(Action *)
107{
108 _game->popState();
109 std::string name;
110 std::string bonusName;
111 if (_bonus)
112 {
113 if (_bonus->getLookup() == "")
114 bonusName = _bonus->getName();
115 else
116 bonusName = _bonus->getLookup();
117 Ufopaedia::openArticle(_game, bonusName);
118 }
119 if (_research)
120 {
121 if (_research->getLookup() == "")
122 name = _research->getName();
123 else
124 name = _research->getLookup();
125 Ufopaedia::openArticle(_game, name);
126 }
127}
128
129}

Callers

nothing calls this directly

Calls 3

getLookupMethod · 0.80
popStateMethod · 0.45
getNameMethod · 0.45

Tested by

no test coverage detected