diff options
author | Damiano Galassi <[email protected]> | 2017-04-21 13:47:20 +0200 |
---|---|---|
committer | Damiano Galassi <[email protected]> | 2017-04-21 13:50:48 +0200 |
commit | bc092457f1409c7d014bbdd3fbd65db0340244bf (patch) | |
tree | 2cb9b1d445f9961440ba5c909deb88d0b6ab8d79 /macosx/HBJob.m | |
parent | 1cbd2f5a33ee8efadf6377da55bd6cb33a31608b (diff) |
MacGui: NSUUID is not available on 10.7, replace it with CFUUIDRef
Diffstat (limited to 'macosx/HBJob.m')
-rw-r--r-- | macosx/HBJob.m | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/macosx/HBJob.m b/macosx/HBJob.m index 5631c9006..15f77ede2 100644 --- a/macosx/HBJob.m +++ b/macosx/HBJob.m @@ -72,7 +72,10 @@ NSString *HBChaptersChangedNotification = @"HBChaptersChangedNotification"; _chapterTitles = [title.chapters copy]; - _uuid = [[NSUUID UUID] UUIDString]; + CFUUIDRef theUUID = CFUUIDCreate(NULL); + CFStringRef string = CFUUIDCreateString(NULL, theUUID); + CFRelease(theUUID); + _uuid = CFBridgingRelease(string); [self applyPreset:preset]; } @@ -271,7 +274,11 @@ NSString *HBChaptersChangedNotification = @"HBChaptersChangedNotification"; copy->_name = [_name copy]; copy->_presetName = [_presetName copy]; copy->_titleIdx = _titleIdx; - copy->_uuid = [[NSUUID UUID] UUIDString]; + + CFUUIDRef theUUID = CFUUIDCreate(NULL); + CFStringRef string = CFUUIDCreateString(NULL, theUUID); + CFRelease(theUUID); + copy->_uuid = CFBridgingRelease(string); copy->_fileURLBookmark = [_fileURLBookmark copy]; copy->_outputURLFolderBookmark = [_outputURLFolderBookmark copy]; |