Commit 16da43922493ea2693ac5cf75d190cd7a7da1b9a
1 parent
107a0c98
Add a qFatal when initializing GUI transforms when Globals->useGui is not set.
Showing
1 changed file
with
3 additions
and
2 deletions
openbr/plugins/gui.cpp
| @@ -592,8 +592,9 @@ public: | @@ -592,8 +592,9 @@ public: | ||
| 592 | template<typename WindowType> | 592 | template<typename WindowType> |
| 593 | void initActual() | 593 | void initActual() |
| 594 | { | 594 | { |
| 595 | - if (!Globals->useGui) | ||
| 596 | - return; | 595 | + if (!Globals->useGui) { |
| 596 | + qFatal("GUI transform %s created without enabling GUI support.\nRun \"br -gui ...\" to enable GUI support from the command line, or set\nGlobals->useGui to true.", this->metaObject()->className()); | ||
| 597 | + } | ||
| 597 | 598 | ||
| 598 | if (displayBuffer) | 599 | if (displayBuffer) |
| 599 | delete displayBuffer; | 600 | delete displayBuffer; |