void (UsageViewImpl usageView) { ProgressManager.getInstance().run(new Task.Modal(getProject(), "Waiting", false) { @Override public void run(@NotNull ProgressIndicator indicator) { usageView.waitForUpdateRequestsCompletion(); usageView.drainQueuedUsageNodes(); } }); }