diff --git a/RemesherPlugin.cc b/RemesherPlugin.cc index 1ff02499b349e6978f24dd8137164e79c7c1de7b..4b6a22a109d07b4a6f84535c6ef0eca68a6d7528 100644 --- a/RemesherPlugin.cc +++ b/RemesherPlugin.cc @@ -61,17 +61,20 @@ RemesherPlugin::RemesherPlugin() : progress_(0) { - progress_ = new ProgressEmitter(); + if ( OpenFlipper::Options::gui() ) { + progress_ = new ProgressEmitter(); - connect(progress_, SIGNAL(signalJobState(QString,int)), this, SIGNAL(setJobState(QString,int)), Qt::QueuedConnection); - connect(progress_, SIGNAL(changeDescription(QString,QString)), this, SIGNAL(setJobDescription(QString,QString)), Qt::QueuedConnection); + connect(progress_, SIGNAL(signalJobState(QString,int)), this, SIGNAL(setJobState(QString,int)), Qt::QueuedConnection); + connect(progress_, SIGNAL(changeDescription(QString,QString)), this, SIGNAL(setJobDescription(QString,QString)), Qt::QueuedConnection); + } } // ---------------------------------------------------------------------------------------- RemesherPlugin::~RemesherPlugin() { - - delete progress_; + if ( OpenFlipper::Options::gui() ) { + delete progress_; + } } // ---------------------------------------------------------------------------------------- diff --git a/RemesherPlugin.hh b/RemesherPlugin.hh index 9a4075b4496b074d0812ce77e7d1542057f71596..1a0d7d2b8558469fac37543a0e0957f89ec8a51b 100644 --- a/RemesherPlugin.hh +++ b/RemesherPlugin.hh @@ -204,6 +204,8 @@ public slots: public slots: QString version() { return QString("1.0"); }; + + void noguiSupported( ) {} ; }; #endif //ADVANCEDREMESHERPLUGIN_HH