in intellij/src/main/kotlin/motif/intellij/actions/MotifUsageAction.kt [63:71]
override fun update(e: AnActionEvent) {
val project = e.project ?: return
val graph = this.graph ?: return
val element: PsiElement? = e.getPsiElement()
e.presentation.isEnabled =
element is PsiClass &&
(!ScopeHierarchyUtils.isInitializedGraph(graph) ||
getUsageCount(project, graph, element) > 0)
}