From 273ba9f64d3b055c499afe76a841d8f51b37ce7b Mon Sep 17 00:00:00 2001 From: Paul Licameli Date: Mon, 20 May 2019 13:28:21 -0400 Subject: [PATCH] Fix Windows build... ... unfortunately inclusion of ErrorDialog.h in FileNames.h ties nine files into a low-level s.c.c. --- src/FileNames.cpp | 3 +++ src/FileNames.h | 3 +++ src/Internat.cpp | 1 - src/Internat.h | 3 --- src/commands/CommandBuilder.cpp | 2 +- src/prefs/GUIPrefs.cpp | 1 + 6 files changed, 8 insertions(+), 5 deletions(-) diff --git a/src/FileNames.cpp b/src/FileNames.cpp index 5ab0b45f1..7bc57e768 100644 --- a/src/FileNames.cpp +++ b/src/FileNames.cpp @@ -36,6 +36,7 @@ used throughout Audacity into this one place. #include "Internat.h" #include "PlatformCompatibility.h" #include "wxFileNameWrapper.h" +#include "widgets/ErrorDialog.h" #include "../lib-src/FileDialog/FileDialog.h" #if defined(__WXMAC__) || defined(__WXGTK__) @@ -583,6 +584,8 @@ void FileNames::FindFilesInPathList(const wxString & pattern, } #if defined(__WXMSW__) +wxCharBuffer FileNames::mFilename; + // // On Windows, wxString::mb_str() can return a NULL pointer if the // conversion to multi-byte fails. So, based on direction intent, diff --git a/src/FileNames.h b/src/FileNames.h index 90fa472b0..fdb28f935 100644 --- a/src/FileNames.h +++ b/src/FileNames.h @@ -149,6 +149,9 @@ public: * on Windows */ #if defined(__WXMSW__) static char *VerifyFilename(const wxString &s, bool input = true); + + // stuff for file name sanitisation + static wxCharBuffer mFilename; #endif private: diff --git a/src/Internat.cpp b/src/Internat.cpp index 93c3e7791..7eba60e96 100644 --- a/src/Internat.cpp +++ b/src/Internat.cpp @@ -40,7 +40,6 @@ and on Mac OS X for the filesystem. wxChar Internat::mDecimalSeparator = wxT('.'); // default wxArrayString Internat::exclude; -wxCharBuffer Internat::mFilename; // DA: Use tweaked translation mechanism to replace 'Audacity' by 'DarkAudacity'. #ifdef EXPERIMENTAL_DA diff --git a/src/Internat.h b/src/Internat.h index d70e70c16..c9f2756ef 100644 --- a/src/Internat.h +++ b/src/Internat.h @@ -142,10 +142,7 @@ public: private: static wxChar mDecimalSeparator; - // stuff for file name sanitisation static wxArrayString exclude; - - static wxCharBuffer mFilename; }; #define _NoAcc(X) Internat::StripAccelerators(_(X)) diff --git a/src/commands/CommandBuilder.cpp b/src/commands/CommandBuilder.cpp index 44f9d9d2a..6d549123c 100644 --- a/src/commands/CommandBuilder.cpp +++ b/src/commands/CommandBuilder.cpp @@ -29,7 +29,7 @@ system by constructing BatchCommandEval objects. #include "ScriptCommandRelay.h" #include "CommandContext.h" #include "CommandTargets.h" -#include "Shuttle.h" +#include "../Shuttle.h" CommandBuilder::CommandBuilder(const wxString &cmdString) : mValid(false) diff --git a/src/prefs/GUIPrefs.cpp b/src/prefs/GUIPrefs.cpp index 756d51dfb..797ac6e5c 100644 --- a/src/prefs/GUIPrefs.cpp +++ b/src/prefs/GUIPrefs.cpp @@ -287,6 +287,7 @@ wxString GUIPrefs::InitLang( wxString langCode ) return SetLang(langCode); } +#define IPC_APPL wxT("audacity") static std::unique_ptr sLocale; wxString GUIPrefs::SetLang( const wxString & lang )