00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef SCONNECT_H
00023 #define SCONNECT_H
00024
00025 #include <QObject>
00026 #include <QDebug>
00027
00028 inline void sconnect(const QObject *from, const char* fromSignal,
00029 const QObject *to, const char* toSignal, Qt::ConnectionType type = Qt::AutoConnection)
00030 {
00031 if (!QObject::connect(from, fromSignal, to, toSignal, type))
00032 qFatal(" *****************\n"
00033 "Connect returned false, aborting, enable core dumping (ulimit -c unlimited), \n"
00034 "enable debug (qmake CONFIG+=debug), recompile, rerun and then use the\n"
00035 "core file with gdb's backtrace to see the location.\n"
00036 " *****************\n");
00037 }
00038
00039 #endif