From 8c689d79196d809f741b5580907d5326682c3aaa Mon Sep 17 00:00:00 2001 From: Syndamia Date: Fri, 6 May 2022 11:56:58 +0300 Subject: Autocommit at 06.05.2022 @ 11:56 --- src/ConsoleInterface/Toolbox.cpp | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) (limited to 'src/ConsoleInterface/Toolbox.cpp') diff --git a/src/ConsoleInterface/Toolbox.cpp b/src/ConsoleInterface/Toolbox.cpp index fc871ae..11ab374 100644 --- a/src/ConsoleInterface/Toolbox.cpp +++ b/src/ConsoleInterface/Toolbox.cpp @@ -74,20 +74,26 @@ void _printOrderedListBeginning() { std::cout << "[" << orderedListIndex++ << "] "; } -void _printInputBoxSubLabel(const char* label) { - std::cout << " (+) " << label; -} - void _printInputBoxLabel(const char* label) { std::cout << "(+) " << label; } -void inputLineBox(const char* label, char* output, unsigned maxWidth) { +void _printInputBoxSubLabel(const char* label) { + std::cout << " "; _printInputBoxLabel(label); +} + +void __inputLineBoxGetInput(char* output, unsigned maxWidth) { std::cin.ignore(); std::cin.getline(output, maxWidth); } -void inputLineSubBox(const char* label, char* output, unsigned maxWidth) { +void inputLineBox(const char* label, char* output, unsigned maxWidth) { + _printInputBoxLabel(label); + __inputLineBoxGetInput(output, maxWidth); +} +void inputLineSubBox(const char* label, char* output, unsigned maxWidth) { + _printInputBoxSubLabel(label); + __inputLineBoxGetInput(output, maxWidth); } -- cgit v1.3.1-23-gd82d