From 54bedfb27c92f8aba1f5721343cb3ee7cbfd5053 Mon Sep 17 00:00:00 2001 From: koom Date: Mon, 12 Jul 2010 23:40:32 +0200 Subject: added xmessage for linux case of error Reviewed-by: Bertram. --- src/log.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src') diff --git a/src/log.cpp b/src/log.cpp index ba1610fd..d5a30bb4 100644 --- a/src/log.cpp +++ b/src/log.cpp @@ -123,6 +123,10 @@ void Logger::error(const std::string &error_text) StandardAlert(kAlertStopAlert, "\pError", (ConstStr255Param) msg, NULL, NULL); +#elif defined __linux__ + std::cerr << "Error: " << error_text << std::endl; + std::string msg="xmessage \"" + error_text + "\""; + system(msg.c_str()); #else std::cerr << "Error: " << error_text << std::endl; #endif -- cgit v1.2.3-70-g09d2 From d1d730b3e64cd7d0e064b8f3138604df2ad121c4 Mon Sep 17 00:00:00 2001 From: kook Date: Mon, 19 Jul 2010 21:00:04 +0200 Subject: Finished to add the xmessage support thanks to Kook. Reviewed-by: Bertram --- src/log.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/log.cpp b/src/log.cpp index d5a30bb4..435b2da0 100644 --- a/src/log.cpp +++ b/src/log.cpp @@ -30,6 +30,8 @@ #include #elif __APPLE__ #include +#elif __linux__ || __linux +#include #endif #include @@ -123,7 +125,7 @@ void Logger::error(const std::string &error_text) StandardAlert(kAlertStopAlert, "\pError", (ConstStr255Param) msg, NULL, NULL); -#elif defined __linux__ +#elif defined __linux__ || __linux std::cerr << "Error: " << error_text << std::endl; std::string msg="xmessage \"" + error_text + "\""; system(msg.c_str()); -- cgit v1.2.3-70-g09d2