From d59d73db24aa8c2c5d8138a20e8668e3d534e7d4 Mon Sep 17 00:00:00 2001 From: rowanbeentje Date: Mon, 6 May 2013 19:34:12 +0000 Subject: - Fix truncation of table content BINARY values which are being edited in-place, addressing Issue #1702 - Ensure that truncation of data values includes an ellipsis to make it clear when performance-based truncation is occurring --- Source/SPTableContentDataSource.m | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'Source/SPTableContentDataSource.m') diff --git a/Source/SPTableContentDataSource.m b/Source/SPTableContentDataSource.m index 0f84950d..c49169a0 100644 --- a/Source/SPTableContentDataSource.m +++ b/Source/SPTableContentDataSource.m @@ -108,8 +108,12 @@ if ([value isNSNull]) return [prefs objectForKey:SPNullValue]; - if ([value isKindOfClass:[NSData class]]) - return [value shortStringRepresentationUsingEncoding:[mySQLConnection stringEncoding]]; + if ([value isKindOfClass:[NSData class]]) { + if ([tableContentView shouldUseFieldEditorForRow:rowIndex column:columnIndex]) { + return [value shortStringRepresentationUsingEncoding:[mySQLConnection stringEncoding]]; + } + return [value stringRepresentationUsingEncoding:[mySQLConnection stringEncoding]]; + } if ([value isSPNotLoaded]) return NSLocalizedString(@"(not loaded)", @"value shown for hidden blob and text fields"); -- cgit v1.2.3