Added support for file type selection.