summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2019-09-05 11:02:47 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2019-09-05 11:02:47 +0900
commit80dc1e5317f9bf799df2493381484b1b65e77b5f (patch)
treedc06372707e8c80d66b214ae30bee58a2c14ec8c
parentaae0287741331748bf0c89cbe4db025bb8cf3af2 (diff)
downloadtqt3-80dc1e5317f9bf799df2493381484b1b65e77b5f.tar.gz
tqt3-80dc1e5317f9bf799df2493381484b1b65e77b5f.zip
Added tqDebug/tqWarning/tqFatal functions that takes a TQCString
argument. This fixes FTBFS of examples caused by previous ambiguous call and solves bug 3021. Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
-rw-r--r--src/tools/ntqglobal.h6
-rw-r--r--src/tools/qglobal.cpp15
2 files changed, 20 insertions, 1 deletions
diff --git a/src/tools/ntqglobal.h b/src/tools/ntqglobal.h
index ea6528ff4..413287dfe 100644
--- a/src/tools/ntqglobal.h
+++ b/src/tools/ntqglobal.h
@@ -741,6 +741,7 @@ typedef TQ_UINT64 TQ_ULLONG; // unsigned long long
// Data stream functions is provided by many classes (defined in ntqdatastream.h)
//
+class TQCString;
class TQDataStream;
class TQString;
@@ -958,6 +959,7 @@ Q_EXPORT int qWinVersion();
Q_EXPORT void tqDebug( const TQString& ); // print debug message
+Q_EXPORT void tqDebug( const TQCString& ); // print debug message
Q_EXPORT void tqDebug( const char *, ... ) // print debug message
#if defined(Q_CC_GNU) && !defined(__INSURE__)
__attribute__ ((format (printf, 1, 2)))
@@ -965,13 +967,15 @@ Q_EXPORT void tqDebug( const char *, ... ) // print debug message
;
Q_EXPORT void tqWarning( const TQString& ); // print warning message
+Q_EXPORT void tqWarning( const TQCString& ); // print warning message
Q_EXPORT void tqWarning( const char *, ... ) // print warning message
#if defined(Q_CC_GNU) && !defined(__INSURE__)
__attribute__ ((format (printf, 1, 2)))
#endif
;
-Q_EXPORT void tqFatal( const TQString& ); // print fatal message and exit
+Q_EXPORT void tqFatal( const TQString& ); // print fatal message and exit
+Q_EXPORT void tqFatal( const TQCString& ); // print fatal message and exit
Q_EXPORT void tqFatal( const char *, ... ) // print fatal message and exit
#if defined(Q_CC_GNU)
__attribute__ ((format (printf, 1, 2)))
diff --git a/src/tools/qglobal.cpp b/src/tools/qglobal.cpp
index e0a198ca3..e1ce5d5b9 100644
--- a/src/tools/qglobal.cpp
+++ b/src/tools/qglobal.cpp
@@ -528,6 +528,11 @@ void tqDebug( const char *msg, ... )
handle_buffer(buf, TQtDebugMsg);
}
+void tqDebug( const TQCString &s )
+{
+ tqDebug(s.data());
+}
+
void tqWarning( const TQString &msg )
{
char buf[QT_BUFFER_LENGTH];
@@ -558,6 +563,11 @@ void tqWarning( const char *msg, ... )
handle_buffer(buf, TQtWarningMsg);
}
+void tqWarning( const TQCString &s )
+{
+ tqWarning(s.data());
+}
+
void tqFatal( const TQString &msg )
{
char buf[QT_BUFFER_LENGTH];
@@ -588,6 +598,11 @@ void tqFatal( const char *msg, ... )
handle_buffer(buf, TQtFatalMsg);
}
+void tqFatal( const TQCString &s )
+{
+ tqWarning(s.data());
+}
+
/*!
\relates TQApplication