File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
src/Interface/Application Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -543,6 +543,7 @@ void ModuleWidget::postLoadAction()
543543
544544void ModuleWidget::showReplaceWithWidget ()
545545{
546+ #ifndef __APPLE__
546547 replaceWithDialog_ = new QDialog;
547548 replaceWithDialog_->setWindowTitle (" Replace a module" );
548549 auto layout = new QHBoxLayout;
@@ -557,6 +558,9 @@ void ModuleWidget::showReplaceWithWidget()
557558 layout->addWidget (cancel);
558559 replaceWithDialog_->setLayout (layout);
559560 replaceWithDialog_->exec ();
561+ #else
562+ QMessageBox::information (nullptr , " Replace with disabled" , " The replace with command is disabled on OSX until the Qt 5 upgrade is complete." );
563+ #endif
560564}
561565
562566bool ModuleWidget::guiVisible () const
@@ -583,7 +587,8 @@ void ModuleWidget::fillReplaceWithMenu(QMenu* menu)
583587
584588void ModuleWidget::replaceModuleWith ()
585589{
586- delete replaceWithDialog_;
590+ replaceWithDialog_->deleteLater ();
591+ replaceWithDialog_ = nullptr ;
587592 auto action = qobject_cast<QAction*>(sender ());
588593 auto moduleToReplace = action->text ();
589594 Q_EMIT replaceModuleWith (theModule_, moduleToReplace.toStdString ());
You can’t perform that action at this time.
0 commit comments