2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-08 18:24:55 +00:00

string_view refactor

This commit is contained in:
Jack Andersen
2017-11-12 20:19:18 -10:00
parent 742ab2514f
commit f7ec7bdc0c
345 changed files with 907 additions and 921 deletions

View File

@@ -111,7 +111,7 @@ public:
struct SpaceSelectBind : specter::IButtonBinding
{
Space& m_space;
const char* name(const specter::Control* control) const {return SpaceMenuNode::s_text.c_str();}
std::string_view name(const specter::Control* control) const {return SpaceMenuNode::s_text;}
MenuStyle menuStyle(const specter::Button* button) const {return MenuStyle::Primary;}
std::unique_ptr<specter::View> buildMenu(const specter::Button* button);
@@ -384,7 +384,7 @@ class TestSpace : public Space
specter::IButtonBinding* m_binding;
public:
TestSpace(ViewManager& vm, Space* parent, const std::string& content, const std::string& button,
TestSpace(ViewManager& vm, Space* parent, std::string_view content, std::string_view button,
specter::IButtonBinding* binding)
: Space(vm, Class::TestSpace, parent), m_contentStr(content), m_buttonStr(button), m_binding(binding)
{}