mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-05-07 05:53:06 +00:00
enable display image if vfs not enabled
This commit is contained in:
parent
deb245bcec
commit
0161430180
2 changed files with 3 additions and 3 deletions
|
|
@ -203,7 +203,7 @@ static const CGFloat CELL_IMAGE_X_MARGIN = 100;
|
|||
NSString *fileName = [NSString stringWithUTF8String:linphone_content_get_name(fileContent)];
|
||||
|
||||
if (!filePath) {
|
||||
char *cPath = linphone_content_get_plain_file_path(fileContent);
|
||||
char *cPath = [[LinphoneManager instance] lpConfigBoolForKey:@"vfs_enabled_preference"] ? linphone_content_get_plain_file_path(fileContent) : NULL;
|
||||
if (cPath) {
|
||||
filePath = [NSString stringWithUTF8String:cPath];
|
||||
ms_free(cPath);
|
||||
|
|
|
|||
|
|
@ -287,9 +287,9 @@
|
|||
dispatch_async(dispatch_get_main_queue(), ^ {
|
||||
LinphoneContent *fileContent = linphone_chat_message_get_file_transfer_information(_message);
|
||||
NSData *data = NULL;
|
||||
char *cPath = linphone_content_get_plain_file_path(fileContent);
|
||||
char *cPath = [[LinphoneManager instance] lpConfigBoolForKey:@"vfs_enabled_preference"] ? linphone_content_get_plain_file_path(fileContent) : NULL;
|
||||
if (cPath) {
|
||||
NSString *filePath = [NSString stringWithUTF8String:linphone_content_get_plain_file_path(fileContent)];
|
||||
NSString *filePath = [NSString stringWithUTF8String:cPath];
|
||||
data = [NSData dataWithContentsOfFile:filePath];
|
||||
ms_free(cPath);
|
||||
[[NSFileManager defaultManager] removeItemAtPath:filePath error:NULL];
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue