mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-02-07 04:10:08 +00:00
Refactored some String operators to bring them into line with c++ best practices. Removed the JUCE_STRINGS_ARE_UNICODE flag - all strings are now unicode by default. Removed the String class's implicit cast to const char* and copyToBuffer() method, replacing them with toCString(), toUTF8(), copyToCString(), copyToUnicode(), etc., so that it'll force users to think about the encoding they want to use in a particular context. Added the ability to pass a String directly to a std::ostream. Extended the juce version number to include a build number.
This commit is contained in:
parent
038886510a
commit
6b79430341
75 changed files with 1371 additions and 1576 deletions
|
|
@ -86,7 +86,7 @@ JUCE_DECL_JACK_FUNCTION (int, jack_port_connected_to, (const jack_port_t* port,
|
|||
#if JACK_LOGGING_ENABLED
|
||||
static void jack_Log (const String& s)
|
||||
{
|
||||
puts (s);
|
||||
std::cerr << s << std::endl;
|
||||
}
|
||||
|
||||
static void dumpJackErrorMessage (const jack_status_t status) throw()
|
||||
|
|
@ -148,9 +148,9 @@ public:
|
|||
for (int i = 0; i < inputChannels.size(); i++)
|
||||
{
|
||||
String inputName;
|
||||
inputName << "in_" << (++totalNumberOfInputChannels);
|
||||
inputName << "in_" << ++totalNumberOfInputChannels;
|
||||
|
||||
inputPorts.add (JUCE_NAMESPACE::jack_port_register (client, (const char*) inputName,
|
||||
inputPorts.add (JUCE_NAMESPACE::jack_port_register (client, inputName.toUTF8(),
|
||||
JACK_DEFAULT_AUDIO_TYPE, JackPortIsInput, 0));
|
||||
}
|
||||
|
||||
|
|
@ -159,9 +159,9 @@ public:
|
|||
for (int i = 0; i < outputChannels.size (); i++)
|
||||
{
|
||||
String outputName;
|
||||
outputName << "out_" << (++totalNumberOfOutputChannels);
|
||||
outputName << "out_" << ++totalNumberOfOutputChannels;
|
||||
|
||||
outputPorts.add (JUCE_NAMESPACE::jack_port_register (client, (const char*) outputName,
|
||||
outputPorts.add (JUCE_NAMESPACE::jack_port_register (client, outputName.toUTF8(),
|
||||
JACK_DEFAULT_AUDIO_TYPE, JackPortIsOutput, 0));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue