mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-08-25 16:33:22 +00:00
Monotone-Parent: 7717958c228c80920ba54d6300d040c7112bb646
Monotone-Revision: 1d682aef2107f2caaabd5b6b0afaf25a817fdaf9 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2010-11-23T14:50:25 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
2010-11-23 Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
|
||||
* OpenChange/MAPIStoreTypes.m (NSObjectFromSPropValue): added
|
||||
support for "PT_BINARY".
|
||||
|
||||
* OpenChange/NSData+MAPIStore.m (+dataWithBinary:): new
|
||||
constructor for generating an NSData instance from a struct
|
||||
Binary_r *.
|
||||
|
||||
@@ -32,6 +32,7 @@
|
||||
#import <Foundation/NSNull.h>
|
||||
#import <Foundation/NSString.h>
|
||||
|
||||
#import "NSData+MAPIStore.h"
|
||||
#import "NSCalendarDate+MAPIStore.h"
|
||||
|
||||
#import "MAPIStoreTypes.h"
|
||||
@@ -102,6 +103,13 @@ NSObjectFromSPropValue (const struct SPropValue *value)
|
||||
case PT_SYSTIME:
|
||||
result = [NSCalendarDate dateFromFileTime: &(value->value.ft)];
|
||||
break;
|
||||
case PT_BINARY:
|
||||
// lpProps->value.bin = *((const struct Binary_r *)data);
|
||||
|
||||
result
|
||||
= [NSData dataWithBinary:
|
||||
(const struct Binary_r *) &(value->value.bin)];
|
||||
break;
|
||||
default:
|
||||
// #define PT_UNSPECIFIED 0x0
|
||||
// #define PT_I2 0x2
|
||||
@@ -116,7 +124,7 @@ NSObjectFromSPropValue (const struct SPropValue *value)
|
||||
// #define PT_ACTIONS 0xFE
|
||||
// #define PT_BINARY 0x102
|
||||
result = [NSNull null];
|
||||
NSLog (@"object type not handled: %d", valueType);
|
||||
NSLog (@"object type not handled: %d (0x.4x)", valueType, valueType);
|
||||
}
|
||||
|
||||
return result;
|
||||
|
||||
Reference in New Issue
Block a user