From 5e4f5cd2a01605bdbce062011d15318d089da6c9 Mon Sep 17 00:00:00 2001 From: Maxime Coste Date: Fri, 20 Nov 2015 08:50:53 +0000 Subject: Move enum option handling in enum.hh and refactor enum options --- src/client.hh | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'src/client.hh') diff --git a/src/client.hh b/src/client.hh index f16bd09b..7a0c8571 100644 --- a/src/client.hh +++ b/src/client.hh @@ -7,6 +7,7 @@ #include "safe_ptr.hh" #include "utils.hh" #include "option_manager.hh" +#include "enum.hh" namespace Kakoune { @@ -84,6 +85,24 @@ private: SafePtr m_last_buffer; }; +enum class Autoreload +{ + Yes, + No, + Ask +}; + +constexpr Array, 5> enum_desc(Autoreload) +{ + return { { + { Autoreload::Yes, "yes" }, + { Autoreload::No, "no" }, + { Autoreload::Ask, "ask" }, + { Autoreload::Yes, "true" }, + { Autoreload::No, "false" } + } }; +} + } #endif // client_hh_INCLUDED -- cgit v1.2.3