inspection tool window: sync right panel on update action finish fixed

This commit is contained in:
Dmitry Batkovich
2016-04-30 11:09:22 +03:00
parent dfff070981
commit 9bb9115931
2 changed files with 4 additions and 3 deletions
@@ -40,8 +40,9 @@ public class InspectionTreeState {
public void restoreExpansionAndSelection(InspectionTree tree, InspectionTreeNode reloadedNode) {
restoreExpansionStatus((InspectionTreeNode)tree.getModel().getRoot(), tree);
if (mySelectionPath != null) {
if (reloadedNode == null || needRestore(reloadedNode))
mySelectionPath.restore(tree);
if (reloadedNode == null || needRestore(reloadedNode)) {
mySelectionPath.restore(tree);
}
} else {
TreeUtil.selectFirstNode(tree);
}
@@ -198,7 +198,7 @@ public class QuickFixPreviewPanelFactory {
@Override
public void treeLoaded() {
ApplicationManager.getApplication().invokeLater(() -> {
if (myView.isValid()) {
if (!myView.isDisposed()) {
myView.syncRightPanel();
}
});