diff --git a/include/ftxui/component/component.hpp b/include/ftxui/component/component.hpp index 8bddb2c..ff7085a 100644 --- a/include/ftxui/component/component.hpp +++ b/include/ftxui/component/component.hpp @@ -31,7 +31,7 @@ Component Input(StringRef content, ConstStringRef placeholder); Component Menu(const std::vector* entries, int* selected_); Component Radiobox(const std::vector* entries, int* selected_); Component Toggle(const std::vector* entries, int* selected); -template // T = {int, float} +template // T = {int, float, long} Component Slider(StringRef label, T* value, T min, T max, T increment); Component Renderer(Component child, std::function); Component Renderer(std::function); diff --git a/src/ftxui/component/slider.cpp b/src/ftxui/component/slider.cpp index 0ec1091..ff50c16 100644 --- a/src/ftxui/component/slider.cpp +++ b/src/ftxui/component/slider.cpp @@ -134,6 +134,12 @@ template Component Slider(StringRef label, float max, float increment); +template Component Slider(StringRef label, + long* value, + long min, + long max, + long increment); + } // namespace ftxui // Copyright 2020 Arthur Sonzogni. All rights reserved.