summaryrefslogtreecommitdiffstats
path: root/game/client/config/gamepad_axis.hh
diff options
context:
space:
mode:
authoruntodesu <kirill@untode.su>2025-09-11 13:48:31 +0500
committeruntodesu <kirill@untode.su>2025-09-11 13:48:31 +0500
commitaaed751bf4430bf4b9b30cef532b8753b9f639ce (patch)
tree16bc751c272ba27ad53ec48dbdd3a6d9e6a8d4c2 /game/client/config/gamepad_axis.hh
parent96bd73ae020ecca1f94698744c77498a89ad19f7 (diff)
downloadvoxelius-aaed751bf4430bf4b9b30cef532b8753b9f639ce.tar.bz2
voxelius-aaed751bf4430bf4b9b30cef532b8753b9f639ce.zip
Replace most of C strings with string_view
Diffstat (limited to 'game/client/config/gamepad_axis.hh')
-rw-r--r--game/client/config/gamepad_axis.hh8
1 files changed, 4 insertions, 4 deletions
diff --git a/game/client/config/gamepad_axis.hh b/game/client/config/gamepad_axis.hh
index 0308ce6..86a2990 100644
--- a/game/client/config/gamepad_axis.hh
+++ b/game/client/config/gamepad_axis.hh
@@ -14,8 +14,8 @@ public:
explicit GamepadAxis(int axis, bool inverted);
virtual ~GamepadAxis(void) = default;
- virtual const char* get(void) const override;
- virtual void set(const char* value) override;
+ virtual std::string_view get(void) const override;
+ virtual void set(std::string_view value) override;
int get_axis(void) const;
void set_axis(int axis);
@@ -29,13 +29,13 @@ public:
// this configuration value actually contain the
// inversion flag. Since we're updating that flag
// in the UI by means of a separate checkbox, we only need the name here
- const char* get_name(void) const;
+ std::string_view get_name(void) const;
private:
bool m_inverted;
int m_gamepad_axis;
std::string m_full_string;
- const char* m_name;
+ std::string_view m_name;
};
} // namespace config