Integer selectedRevision = revisionChooserDialog.showDialog(moduleNameToSync.toSourceText());
// If any revision was selected, sync.
if (selectedRevision != null) {
int selectedRevisionNum = selectedRevision.intValue();
ModuleRevision moduleRevision = new ModuleRevision(moduleNameToSync, selectedRevisionNum);
gemCutter.doSyncModulesUserAction(Collections.singletonList(moduleRevision), false);
}
}
};