OS X: Use the proper localization code for the metadata importer.
git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@90898 e17a0e51-4ae3-4d35-97c3-1a29b211df97
This commit is contained in:
parent
3c2929ba90
commit
85871b22b9
|
@ -3439,7 +3439,10 @@
|
|||
GCC_OPTIMIZATION_LEVEL = 0;
|
||||
GCC_PRECOMPILE_PREFIX_HEADER = YES;
|
||||
GCC_PREFIX_HEADER = "Psx-Memcard/Psx-Memcard-Prefix.pch";
|
||||
GCC_PREPROCESSOR_DEFINITIONS = "$(inherited)";
|
||||
GCC_PREPROCESSOR_DEFINITIONS = (
|
||||
"$(inherited)",
|
||||
"PCSXRPLUG=MDPsx",
|
||||
);
|
||||
INFOPLIST_FILE = "Psx-Memcard/Psx-Memcard-Info.plist";
|
||||
INSTALL_PATH = "@executable_path/../Contents/Library/Spotlight";
|
||||
LIBRARY_STYLE = BUNDLE;
|
||||
|
@ -3464,7 +3467,10 @@
|
|||
GCC_ENABLE_OBJC_EXCEPTIONS = YES;
|
||||
GCC_PRECOMPILE_PREFIX_HEADER = YES;
|
||||
GCC_PREFIX_HEADER = "Psx-Memcard/Psx-Memcard-Prefix.pch";
|
||||
GCC_PREPROCESSOR_DEFINITIONS = "$(inherited)";
|
||||
GCC_PREPROCESSOR_DEFINITIONS = (
|
||||
"$(inherited)",
|
||||
"PCSXRPLUG=MDPsx",
|
||||
);
|
||||
INFOPLIST_FILE = "Psx-Memcard/Psx-Memcard-Info.plist";
|
||||
INSTALL_PATH = "@executable_path/../Contents/Library/Spotlight";
|
||||
LIBRARY_STYLE = BUNDLE;
|
||||
|
@ -3489,7 +3495,10 @@
|
|||
GCC_ENABLE_OBJC_EXCEPTIONS = YES;
|
||||
GCC_PRECOMPILE_PREFIX_HEADER = YES;
|
||||
GCC_PREFIX_HEADER = "Psx-Memcard/Psx-Memcard-Prefix.pch";
|
||||
GCC_PREPROCESSOR_DEFINITIONS = "$(inherited)";
|
||||
GCC_PREPROCESSOR_DEFINITIONS = (
|
||||
"$(inherited)",
|
||||
"PCSXRPLUG=MDPsx",
|
||||
);
|
||||
INFOPLIST_FILE = "Psx-Memcard/Psx-Memcard-Info.plist";
|
||||
INSTALL_PATH = "@executable_path/../Contents/Library/Spotlight";
|
||||
LIBRARY_STYLE = BUNDLE;
|
||||
|
|
|
@ -11,8 +11,6 @@
|
|||
|
||||
#include <CoreFoundation/CoreFoundation.h>
|
||||
|
||||
#define __private_extern __attribute__((visibility("hidden")))
|
||||
|
||||
__private_extern Boolean GetMetadataForFile(void *thisInterface, CFMutableDictionaryRef attributes, CFStringRef contentTypeUTI, CFStringRef pathToFile);
|
||||
|
||||
#endif
|
||||
|
|
|
@ -219,7 +219,7 @@ Boolean GetMetadataForFile(void *thisInterface, CFMutableDictionaryRef attribute
|
|||
|
||||
|
||||
attr[kPCSXRSaveNames] = @{@"en": [enNames copy],
|
||||
@"jp": [jpNames copy]};
|
||||
@"ja": [jpNames copy]};
|
||||
attr[kPCSXRMemCount] = @(memCount);
|
||||
attr[kPCSXRFreeBlocks] = @(freeBlocks);
|
||||
attr[kPCSXRMemNames] = [memNames copy];
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
// The contents of this file are implicitly included at the beginning of every source file.
|
||||
//
|
||||
|
||||
#define __private_extern __attribute__((visibility("hidden")))
|
||||
#include <CoreFoundation/CoreFoundation.h>
|
||||
|
||||
#ifdef __OBJC__
|
||||
|
|
|
@ -52,11 +52,11 @@ static ULONG MetadataImporterPluginRelease(void *thisInstance);
|
|||
//
|
||||
|
||||
static MDImporterInterfaceStruct testInterfaceFtbl = {
|
||||
NULL,
|
||||
MetadataImporterQueryInterface,
|
||||
MetadataImporterPluginAddRef,
|
||||
MetadataImporterPluginRelease,
|
||||
GetMetadataForFile
|
||||
NULL,
|
||||
MetadataImporterQueryInterface,
|
||||
MetadataImporterPluginAddRef,
|
||||
MetadataImporterPluginRelease,
|
||||
GetMetadataForFile
|
||||
};
|
||||
|
||||
|
||||
|
@ -93,13 +93,13 @@ MDImporterType *AllocMetadataImporterPluginType(CFUUIDRef inFactoryID)
|
|||
//
|
||||
void DeallocMetadataImporterPluginType(MDImporterType *thisInstance)
|
||||
{
|
||||
CFUUIDRef theFactoryID = thisInstance->factoryID;
|
||||
CFUUIDRef theFactoryID = thisInstance->factoryID;
|
||||
|
||||
free(thisInstance);
|
||||
if (theFactoryID){
|
||||
CFPlugInRemoveInstanceForFactory(theFactoryID);
|
||||
CFRelease(theFactoryID);
|
||||
}
|
||||
free(thisInstance);
|
||||
if (theFactoryID){
|
||||
CFPlugInRemoveInstanceForFactory(theFactoryID);
|
||||
CFRelease(theFactoryID);
|
||||
}
|
||||
}
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
|
@ -111,7 +111,7 @@ HRESULT MetadataImporterQueryInterface(void *thisInstance, REFIID iid, LPVOID *p
|
|||
{
|
||||
CFUUIDRef interfaceID = CFUUIDCreateFromUUIDBytes(kCFAllocatorDefault, iid);
|
||||
|
||||
if (CFEqual(interfaceID,kMDImporterInterfaceID)){
|
||||
if (CFEqual(interfaceID, kMDImporterInterfaceID)) {
|
||||
/* If the Right interface was requested, bump the ref count,
|
||||
* set the ppv parameter equal to the instance, and
|
||||
* return good status.
|
||||
|
@ -120,7 +120,7 @@ HRESULT MetadataImporterQueryInterface(void *thisInstance, REFIID iid, LPVOID *p
|
|||
*ppv = thisInstance;
|
||||
CFRelease(interfaceID);
|
||||
return S_OK;
|
||||
} else if (CFEqual(interfaceID,IUnknownUUID)){
|
||||
} else if (CFEqual(interfaceID, IUnknownUUID)) {
|
||||
/* If the IUnknown interface was requested, same as above. */
|
||||
((MDImporterType*)thisInstance )->conduitInterface->AddRef(thisInstance);
|
||||
*ppv = thisInstance;
|
||||
|
|
Loading…
Reference in New Issue