Skip to content

Commit

Permalink
Update documentation view if current class is the active class (OpenM…
Browse files Browse the repository at this point in the history
  • Loading branch information
adeas31 committed Jun 13, 2024
1 parent 44cf517 commit 0051418
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions OMEdit/OMEditLIB/Modeling/ModelWidgetContainer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6855,8 +6855,9 @@ void ModelWidget::reDrawModelWidget()
}
// update the icon
mpLibraryTreeItem->handleIconUpdated();
// if documentation view is visible then update it
if (MainWindow::instance()->getDocumentationDockWidget()->isVisible()) {
// if documentation view is visible and this model is the current active model then update it
ModelWidget *pModelWidget = mpModelWidgetContainer->getCurrentModelWidget();
if (pModelWidget && pModelWidget == this && MainWindow::instance()->getDocumentationDockWidget()->isVisible()) {
MainWindow::instance()->getDocumentationWidget()->showDocumentation(getLibraryTreeItem());
}
// clear the undo stack
Expand Down

0 comments on commit 0051418

Please sign in to comment.