Audacity 3.2.0
Public Member Functions | Public Attributes | List of all members
ExportCL::ExtendPath Struct Reference

Public Member Functions

 ExtendPath ()
 
 ~ExtendPath ()
 

Public Attributes

wxString opath
 

Detailed Description

Definition at line 304 of file ExportCL.cpp.

Constructor & Destructor Documentation

◆ ExtendPath()

ExportCL::ExtendPath::ExtendPath ( )
inline

Definition at line 309 of file ExportCL.cpp.

310 {
311 // Give Windows a chance at finding lame command in the default location.
312 wxString paths[] = {wxT("HKEY_LOCAL_MACHINE\\Software\\Lame for Audacity"),
313 wxT("HKEY_LOCAL_MACHINE\\Software\\FFmpeg for Audacity")};
314 wxString npath;
315 wxRegKey reg;
316
317 wxGetEnv(wxT("PATH"), &opath);
318 npath = opath;
319
320 for (int i = 0; i < WXSIZEOF(paths); i++) {
321 reg.SetName(paths[i]);
322
323 if (reg.Exists()) {
324 wxString ipath;
325 reg.QueryValue(wxT("InstallPath"), ipath);
326 if (!ipath.empty()) {
327 npath += wxPATH_SEP + ipath;
328 }
329 }
330 }
331
332 wxSetEnv(wxT("PATH"),npath);
333 };
wxT("CloseDown"))
BuiltinCommandsModule::Registration< CompareAudioCommand > reg

References opath, anonymous_namespace{CompareAudioCommand.cpp}::reg, and wxT().

Here is the call graph for this function:

◆ ~ExtendPath()

ExportCL::ExtendPath::~ExtendPath ( )
inline

Definition at line 335 of file ExportCL.cpp.

336 {
337 if (!opath.empty())
338 {
339 wxSetEnv(wxT("PATH"),opath);
340 }
341 }

References opath, and wxT().

Here is the call graph for this function:

Member Data Documentation

◆ opath

wxString ExportCL::ExtendPath::opath

Definition at line 307 of file ExportCL.cpp.

Referenced by ExtendPath(), and ~ExtendPath().


The documentation for this struct was generated from the following file: