Object (@NotNull @NonNls String dataId) { if (PlatformCoreDataKeys.BGT_DATA_PROVIDER.is(dataId)) { TreePath path = getTree().getSelectionPath(); return path == null ? null : (DataProvider)slowId -> getSlowData(slowId, path); } else if (PlatformDataKeys.DELETE_ELEMENT_PROVIDER.is(dataId)) { return new DeleteProvider() { @Override public @NotNull ActionUpdateThread getActionUpdateThread() { return ActionUpdateThread.EDT; } @Override public void deleteElement(@NotNull DataContext dataContext) { deleteRow(); } @Override public boolean canDeleteElement(@NotNull DataContext dataContext) { return myTreeTable.getTree().getSelectionPaths() != null; } }; } return null; }