Fix tests segfault
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
This commit is contained in:
parent
f60d6e4d48
commit
2030041fcc
6 changed files with 32 additions and 26 deletions
|
@ -81,6 +81,12 @@ class Index;
|
|||
#endif
|
||||
#define APPLICATION (static_cast<Application*>(QCoreApplication::instance()))
|
||||
|
||||
// Used for checking if is a test
|
||||
#if defined(APPLICATION_DYN)
|
||||
#undef APPLICATION_DYN
|
||||
#endif
|
||||
#define APPLICATION_DYN (dynamic_cast<Application*>(QCoreApplication::instance()))
|
||||
|
||||
class Application : public QApplication {
|
||||
// friends for the purpose of limiting access to deprecated stuff
|
||||
Q_OBJECT
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue