summaryrefslogtreecommitdiff
path: root/common/rawaccel-userspace.hpp
diff options
context:
space:
mode:
authorJacob Palecki <[email protected]>2020-07-28 17:21:39 -0700
committerJacob Palecki <[email protected]>2020-07-28 17:21:39 -0700
commitcdd82efdfdd7c2e9b4c2ed9777792f9921eedb9e (patch)
tree64620804479337358e5c5d2dfd1e54407a032de2 /common/rawaccel-userspace.hpp
parentRename acceleration constants, arguments (diff)
downloadrawaccel-cdd82efdfdd7c2e9b4c2ed9777792f9921eedb9e.tar.xz
rawaccel-cdd82efdfdd7c2e9b4c2ed9777792f9921eedb9e.zip
Get rid of enum and use types\tags directly
Diffstat (limited to 'common/rawaccel-userspace.hpp')
-rw-r--r--common/rawaccel-userspace.hpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/common/rawaccel-userspace.hpp b/common/rawaccel-userspace.hpp
index 5996364..82a9e98 100644
--- a/common/rawaccel-userspace.hpp
+++ b/common/rawaccel-userspace.hpp
@@ -68,34 +68,34 @@ mouse_modifier parse(int argc, char** argv) {
// modes
auto noaccel_mode = "no-accel mode" % (
- clipp::command("off", "noaccel").set(accel_args.accel_mode, mode::noaccel)
+ clipp::command("off", "noaccel").set(accel_args.accel_mode, accel_implementation_t::id<accel_noaccel>)
);
auto lin_mode = "linear accel mode:" % (
- clipp::command("linear").set(accel_args.accel_mode, mode::linear),
+ clipp::command("linear").set(accel_args.accel_mode, accel_implementation_t::id<accel_linear>),
accel_var
);
auto classic_mode = "classic accel mode:" % (
- clipp::command("classic").set(accel_args.accel_mode, mode::classic),
+ clipp::command("classic").set(accel_args.accel_mode, accel_implementation_t::id<accel_classic>),
accel_var,
(clipp::required("exponent") & clipp::number("num", accel_args.lim_exp)) % "exponent"
);
auto nat_mode = "natural accel mode:" % (
- clipp::command("natural").set(accel_args.accel_mode, mode::natural),
+ clipp::command("natural").set(accel_args.accel_mode, accel_implementation_t::id<accel_natural>),
accel_var,
limit_var
);
auto log_mode = "logarithmic accel mode:" % (
- clipp::command("logarithmic").set(accel_args.accel_mode, mode::logarithmic),
+ clipp::command("logarithmic").set(accel_args.accel_mode, accel_implementation_t::id<accel_logarithmic>),
accel_var
);
auto sig_mode = "sigmoid accel mode:" % (
- clipp::command("sigmoid").set(accel_args.accel_mode, mode::sigmoid),
+ clipp::command("sigmoid").set(accel_args.accel_mode, accel_implementation_t::id<accel_sigmoid>),
accel_var,
limit_var,
(clipp::required("midpoint") & clipp::number("speed", accel_args.midpoint)) % "midpoint"
);
auto pow_mode = "power accel mode:" % (
- clipp::command("power").set(accel_args.accel_mode, mode::power) >> [&] { accel_args.accel = 1; },
+ clipp::command("power").set(accel_args.accel_mode, accel_implementation_t::id<accel_power>) >> [&] { accel_args.accel = 1; },
(clipp::required("exponent") & clipp::number("num", accel_args.lim_exp)) % "exponent",
(clipp::option("scale") & clipp::number("num", accel_args.accel)) % "scale factor"
);