mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
MacOS: Fixed a bug parsing local file URLs containing URL escape characters
This commit is contained in:
parent
bedff61983
commit
81e206f963
1 changed files with 6 additions and 2 deletions
|
|
@ -207,8 +207,12 @@ private:
|
|||
auto addURLResult = [&chooserResults] (NSURL* urlToAdd)
|
||||
{
|
||||
auto scheme = nsStringToJuce ([urlToAdd scheme]);
|
||||
auto path = nsStringToJuce ([urlToAdd path]);
|
||||
chooserResults.add (URL (scheme + "://" + path));
|
||||
auto pathComponents = StringArray::fromTokens (nsStringToJuce ([urlToAdd path]), "/", {});
|
||||
|
||||
for (auto& component : pathComponents)
|
||||
component = URL::addEscapeChars (component, false);
|
||||
|
||||
chooserResults.add (URL (scheme + "://" + pathComponents.joinIntoString ("/")));
|
||||
};
|
||||
|
||||
if (isSave)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue