// close tabs
if (getSelectedObject() instanceof Project) {
for (YaTab tab : YaFrame.get().getAllOpenTabs()) {
if (tab instanceof ProjectTab) {
ProjectTab p = (ProjectTab) tab;
if (p.getProject().equals(getSelectedObject())) {
YaFrame.close(p.getId());
}
}
}
// remove cache