mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
macOS: Fallback for creating unique ID for MIDI ports if the bundleRef isn't created
This commit is contained in:
parent
11aee7cb6a
commit
de251d36ed
1 changed files with 3 additions and 2 deletions
|
|
@ -197,9 +197,10 @@ namespace CoreMidiHelpers
|
|||
}
|
||||
#endif
|
||||
|
||||
if (uniqueID.isNotEmpty())
|
||||
uniqueID += "." + deviceName + (isInput ? ".input" : ".output");
|
||||
if (uniqueID.isEmpty())
|
||||
uniqueID = String (Random::getSystemRandom().nextInt (1024));
|
||||
|
||||
uniqueID += "." + deviceName + (isInput ? ".input" : ".output");
|
||||
return uniqueID.hashCode();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue