+ fixes #0002134: FreeCAD crashes when the window is restored and a plot is shown

This commit is contained in:
wmayer 2015-05-31 17:29:30 +02:00
parent a12f700aa2
commit 2e14552a50

View File

@ -1463,7 +1463,7 @@ void MainWindow::changeEvent(QEvent *e)
QMdiSubWindow* mdi = d->mdiArea->currentSubWindow();
if (mdi) {
MDIView* view = dynamic_cast<MDIView*>(mdi->widget());
if (getMainWindow()->activeWindow() != view) {
if (view && getMainWindow()->activeWindow() != view) {
d->activeView = view;
Application::Instance->viewActivated(view);
}