fix incorrect positioning of function call graph

This commit is contained in:
shocoman 2022-08-29 13:22:42 +07:00 committed by Ryan Kurtz
parent 30319a9b0d
commit 30cba57716

View file

@ -172,6 +172,13 @@ public class FcgProvider
if (!graphData.hasResults()) {
return;
}
// The graph component won't contain valid perspective information if it's not 'initialized'
// (i.e. rendered or displayed to the user). It may happen if the graph has been kept minimized
// in the separate tab. Related method: `GraphComponent::viewerInitialized`
if (view.getGraphComponent().isUninitialized()) {
return;
}
GraphPerspectiveInfo<FcgVertex, FcgEdge> info = view.generateGraphPerspective();
graphData.setGraphPerspective(info);