1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-29 02:40:05 +00:00

String tokenisation clean-up.

This commit is contained in:
Julian Storer 2011-03-14 10:00:26 +00:00
parent ed0ed361f0
commit eabc372ea9
6 changed files with 174 additions and 240 deletions

View file

@ -172,9 +172,7 @@ void PlatformUtilities::registerFileAssociation (const String& fileExtension,
targetExecutable.getFullPathName() + "," + String (-iconResourceNumber));
setRegistryValue (key + "\\", fullDescription);
setRegistryValue (key + "\\shell\\open\\command\\",
targetExecutable.getFullPathName() + " %1");
setRegistryValue (key + "\\shell\\open\\command\\", targetExecutable.getFullPathName() + " %1");
}
@ -194,12 +192,10 @@ bool juce_IsRunningInWine()
//==============================================================================
const String JUCE_CALLTYPE PlatformUtilities::getCurrentCommandLineParams()
{
String s (::GetCommandLineW());
StringArray tokens;
tokens.addTokens (s, true); // tokenise so that we can remove the initial filename argument
return tokens.joinIntoString (" ", 1);
const String commandLine (GetCommandLineW());
return String (CharacterFunctions::findEndOfToken (commandLine.getCharPointer(),
String (" ").getCharPointer(),
String ("\"").getCharPointer())).trimStart();
}
//==============================================================================