Website Summary Files Commits Branches @commit @diff @stats
path: root / src / Generic / ConsoleInterface / Menu.cpp
diff options
context:
space:
mode:
Commit572034064bc8579cda9cebb28e657c79e5c96e3d (patch)
Author
 Syndamia <kamen.d.mladenov@protonmail.com>
2022-05-07 11:02:43 +0300
Committer
 Syndamia <kamen.d.mladenov@protonmail.com>
2022-05-07 11:02:43 +0300
Filesc80c2343c0407e8f079e449189ebe1bd98978288 /src/Generic/ConsoleInterface/Menu.cpp
FMI-OOP-P1_TicketSystem-572034064bc8579cda9cebb28e657c79e5c96e3d.tar
FMI-OOP-P1_TicketSystem-572034064bc8579cda9cebb28e657c79e5c96e3d.tar.gz
FMI-OOP-P1_TicketSystem-572034064bc8579cda9cebb28e657c79e5c96e3d.zip
Parente79951e129ae4f0f6f51496c247edabce0c1d0c5 (diff)
Autocommit at 07.05.2022 @ 11:02
1 files changed, 4 insertions, 4 deletions
-rw-r--r--src/Generic/ConsoleInterface/Menu.cpp8
diff --git a/src/Generic/ConsoleInterface/Menu.cpp b/src/Generic/ConsoleInterface/Menu.cpp
index 0b27d48..d672540 100644
--- a/src/Generic/ConsoleInterface/Menu.cpp
+++ b/src/Generic/ConsoleInterface/Menu.cpp
@@ -27,7 +27,7 @@ enum MessageType {
Warning,
Error,
};
-String msg;
+const char* msg;
MessageType msgType;
void Menu::registerError(const char* message) const {
@@ -61,9 +61,9 @@ void Menu::navigate() const {
titleBox(title);
switch(msgType) {
- case Error: errorBox(msg.get_cstr()); msgType = NoPrint; break;
- case Warning: warningBox(msg.get_cstr()); msgType = NoPrint; break;
- case Success: successBox(msg.get_cstr()); msgType = NoPrint; break;
+ case Error: errorBox(msg); msgType = NoPrint; break;
+ case Warning: warningBox(msg); msgType = NoPrint; break;
+ case Success: successBox(msg); msgType = NoPrint; break;
case NoPrint: printLine(""); break;
}
printLine("");