Audacity 3.2.0
Public Types | Public Attributes | List of all members
FileNames Class Reference

Provides Static functions to yield filenames. More...

Public Types

enum class  Operation {
  _None , Temp , Presets , Open ,
  Save , Import , Export , MacrosOut
}
 
enum class  PathType { _None , User , LastUsed }
 
using FileTypes = std::vector< FileType >
 

Public Attributes

FILES_API const FileType AllFiles { XO("All files"), { wxT("") } }
 
FILES_API const FileType AudacityProjects { XO("AUP3 project files"), { wxT("aup3") }, true }
 
FILES_API const FileType DynamicLibraries
 
FILES_API const FileType TextFiles { XO("Text files"), { wxT("txt") }, true }
 
FILES_API const FileType XMLFiles { XO("XML files"), { wxT("xml"), wxT("XML") }, true }
 

Detailed Description

Provides Static functions to yield filenames.

This class helps us with setting a base path, and makes it easier for us to keep track of the different kinds of files we read and write from.

JKC: In time I plan to add all file names and file extensions used throughout Audacity into this one place.

Member Typedef Documentation

◆ FileTypes

using FileNames::FileTypes = std::vector< FileType >

Definition at line 75 of file FileNames.h.

Member Enumeration Documentation

◆ Operation

enum class FileNames::Operation
strong
Enumerator
_None 
Temp 
Presets 
Open 
Save 
Import 
Export 
MacrosOut 

Definition at line 161 of file FileNames.h.

161 {
162 // _ on None to defeat some macro that is expanding this.
163 _None,
164
165 // These do not have a specific pathtype
166 Temp,
167 Presets,
168
169 // These have default/lastused pathtypes
170 Open,
171 Save,
172 Import,
173 Export,
174 MacrosOut
175 };
Main class to control the export function.

◆ PathType

enum class FileNames::PathType
strong
Enumerator
_None 
User 
LastUsed 

Definition at line 177 of file FileNames.h.

177 {
178 // _ on None to defeat some macro that is expanding this.
179 _None,
180 User,
181 LastUsed
182 };

Member Data Documentation

◆ AllFiles

const FileNames::FileType FileNames::AllFiles { XO("All files"), { wxT("") } }

◆ AudacityProjects

const FileNames::FileType FileNames::AudacityProjects { XO("AUP3 project files"), { wxT("aup3") }, true }

◆ DynamicLibraries

const FileNames::FileType FileNames::DynamicLibraries
Initial value:
{
XO("Dynamically Linked Libraries"), { wxT("dll") }, true
}
wxT("CloseDown"))
XO("Cut/Copy/Paste")

Definition at line 71 of file FileNames.h.

Referenced by MP3Exporter::GetLibraryTypes(), and FindFFmpegDialog::OnBrowse().

◆ TextFiles

const FileNames::FileType FileNames::TextFiles { XO("Text files"), { wxT("txt") }, true }

◆ XMLFiles

const FileNames::FileType FileNames::XMLFiles { XO("XML files"), { wxT("xml"), wxT("XML") }, true }

The documentation for this class was generated from the following files: