#include <QtCore>
-#ifdef Q_OS_LINUX
+#if defined(Q_OS_LINUX) || defined(Q_OS_MACOS)
# include <termios.h>
# include <unistd.h>
#endif
QString Module::readPassword()
{
bool noEcho = false;
-#ifdef Q_OS_LINUX
+#if defined(Q_OS_LINUX) || defined(Q_OS_MACOS)
termios oldt;
tcgetattr(STDIN_FILENO, &oldt);
termios newt = oldt;
cout << endl;
}
-#ifdef Q_OS_LINUX
+#if defined(Q_OS_LINUX) || defined(Q_OS_MACOS)
tcsetattr(STDIN_FILENO, TCSANOW, &oldt);
#elif defined Q_OS_WIN32
SetConsoleMode(hStdin, mode);