function _setProjectRoot(rootEntry) {
        var d = new $.Deferred();
        model.setProjectRoot(rootEntry).then(function () {
            d.resolve();
            model.reopenNodes(PreferencesManager.getViewState("project.treeState", _getProjectViewStateContext()));
        });
        return d.promise();
    }
@private

Sets the project root to the given directory, resetting the ProjectModel and file tree in the process.

@param {Directory} rootEntry directory object for the project root
@return {$.Promise} resolved when the project is done setting up