mirror of
https://github.com/dashpay/dash.git
synced 2024-12-26 04:22:55 +01:00
LSSharedFileListItemResolve() was deprecated in Mac OS X 10.10, use LSSharedFileListItemCopyResolvedURL() instead
This commit is contained in:
parent
2eda47bc37
commit
6bbca99baa
@ -696,7 +696,18 @@ LSSharedFileListItemRef findStartupItemInList(LSSharedFileListRef list, CFURLRef
|
||||
LSSharedFileListItemRef item = (LSSharedFileListItemRef)CFArrayGetValueAtIndex(listSnapshot, i);
|
||||
UInt32 resolutionFlags = kLSSharedFileListNoUserInteraction | kLSSharedFileListDoNotMountVolumes;
|
||||
CFURLRef currentItemURL = NULL;
|
||||
LSSharedFileListItemResolve(item, resolutionFlags, ¤tItemURL, NULL);
|
||||
|
||||
#if defined(MAC_OS_X_VERSION_MAX_ALLOWED) && MAC_OS_X_VERSION_MAX_ALLOWED >= 10100
|
||||
if(&LSSharedFileListItemCopyResolvedURL)
|
||||
currentItemURL = LSSharedFileListItemCopyResolvedURL(item, resolutionFlags, NULL);
|
||||
#if defined(MAC_OS_X_VERSION_MIN_REQUIRED) && MAC_OS_X_VERSION_MIN_REQUIRED < 10100
|
||||
else
|
||||
LSSharedFileListItemResolve(item, resolutionFlags, ¤tItemURL, NULL);
|
||||
#endif
|
||||
#else
|
||||
LSSharedFileListItemResolve(item, resolutionFlags, ¤tItemURL, NULL);
|
||||
#endif
|
||||
|
||||
if(currentItemURL && CFEqual(currentItemURL, findUrl)) {
|
||||
// found
|
||||
CFRelease(currentItemURL);
|
||||
|
Loading…
Reference in New Issue
Block a user