Or I guess there's an option c) here too: let the project tree's selection state dominate when currentDocument is null, and have the others (like Rename) ask for its selection.  There's already a ProjectManager.getSelectedItem() that might actually work for this as-is...