mirror of
https://github.com/oxen-io/session-ios.git
synced 2023-12-13 21:30:14 +01:00
Respond to CR.
This commit is contained in:
parent
cac85508cc
commit
822aa64b14
|
@ -10,8 +10,6 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
|
||||
+ (NSString *)cellReuseIdentifier;
|
||||
|
||||
+ (UIFont *)defaultTextMessageFont;
|
||||
|
||||
@end
|
||||
|
||||
NS_ASSUME_NONNULL_END
|
||||
|
|
|
@ -147,16 +147,11 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
return NSStringFromClass([self class]);
|
||||
}
|
||||
|
||||
+ (UIFont *)defaultTextMessageFont
|
||||
{
|
||||
return [UIFont ows_dynamicTypeBodyFont];
|
||||
}
|
||||
|
||||
- (UIFont *)textMessageFont
|
||||
{
|
||||
OWSAssert(DisplayableText.kMaxJumbomojiCount == 5);
|
||||
|
||||
CGFloat basePointSize = self.class.defaultTextMessageFont.pointSize;
|
||||
CGFloat basePointSize = [UIFont ows_dynamicTypeBodyFont].pointSize;
|
||||
switch (self.displayableBodyText.jumbomojiCount) {
|
||||
case 0:
|
||||
break;
|
||||
|
|
|
@ -20,9 +20,11 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
// Measurement
|
||||
- (CGSize)sizeForMaxWidth:(CGFloat)maxWidth;
|
||||
|
||||
// Factory method for "message bubble" views.
|
||||
+ (OWSQuotedMessageView *)quotedMessageViewForConversation:(TSQuotedMessage *)quotedMessage
|
||||
displayableQuotedText:(nullable DisplayableText *)displayableQuotedText;
|
||||
|
||||
// Factory method for "message compose" views.
|
||||
+ (OWSQuotedMessageView *)quotedMessageViewForPreview:(TSQuotedMessage *)quotedMessage;
|
||||
|
||||
@end
|
||||
|
|
|
@ -6,7 +6,6 @@
|
|||
#import "ConversationViewItem.h"
|
||||
#import "Environment.h"
|
||||
#import "OWSBubbleStrokeView.h"
|
||||
#import "OWSMessageCell.h"
|
||||
#import "Signal-Swift.h"
|
||||
#import <SignalMessaging/OWSContactsManager.h>
|
||||
#import <SignalMessaging/SignalMessaging-Swift.h>
|
||||
|
@ -68,7 +67,7 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
|
||||
_quotedMessage = quotedMessage;
|
||||
_displayableQuotedText = displayableQuotedText;
|
||||
_textMessageFont = OWSMessageCell.defaultTextMessageFont;
|
||||
_textMessageFont = [UIFont ows_dynamicTypeBodyFont];
|
||||
|
||||
return self;
|
||||
}
|
||||
|
@ -76,13 +75,13 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
- (BOOL)hasQuotedAttachment
|
||||
{
|
||||
return (self.quotedMessage.contentType.length > 0
|
||||
&& ![NSObject isNullableObject:self.quotedMessage.contentType equalTo:OWSMimeTypeOversizeTextMessage]);
|
||||
&& ![OWSMimeTypeOversizeTextMessage isEqualToString:self.quotedMessage.contentType]);
|
||||
}
|
||||
|
||||
- (BOOL)hasQuotedAttachmentThumbnail
|
||||
{
|
||||
return (self.quotedMessage.contentType.length > 0
|
||||
&& ![NSObject isNullableObject:self.quotedMessage.contentType equalTo:OWSMimeTypeOversizeTextMessage] &&
|
||||
&& ![OWSMimeTypeOversizeTextMessage isEqualToString:self.quotedMessage.contentType] &&
|
||||
[TSAttachmentStream hasThumbnailForMimeType:self.quotedMessage.contentType]);
|
||||
}
|
||||
|
||||
|
|
|
@ -18,6 +18,8 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
|
||||
+ (UIFont *)ows_boldFontWithSize:(CGFloat)size;
|
||||
|
||||
+ (UIFont *)ows_dynamicTypeBodyFont:(CGFloat)size;
|
||||
|
||||
#pragma mark - Icon Fonts
|
||||
|
||||
+ (UIFont *)ows_fontAwesomeFont:(CGFloat)size;
|
||||
|
|
|
@ -33,6 +33,11 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
return [UIFont boldSystemFontOfSize:size];
|
||||
}
|
||||
|
||||
+ (UIFont *)ows_dynamicTypeBodyFont:(CGFloat)size
|
||||
{
|
||||
return [UIFont ows_dynamicTypeBodyFont];
|
||||
}
|
||||
|
||||
#pragma mark - Icon Fonts
|
||||
|
||||
+ (UIFont *)ows_fontAwesomeFont:(CGFloat)size
|
||||
|
|
Loading…
Reference in a new issue