From 8698ee4cce5bc0118f1f3d3da68e9976a0d8d02b Mon Sep 17 00:00:00 2001 From: sir_nacnud Date: Fri, 10 Jun 2016 12:57:41 +0200 Subject: [PATCH] Calculate correct preferredMaxLayoutWidth for message label This changes the calculation to use the same constants as supplied in the horizontal constraint. --- LNNotificationsUI/LNNotificationsUI/LNNotificationBannerView.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/LNNotificationsUI/LNNotificationsUI/LNNotificationBannerView.m b/LNNotificationsUI/LNNotificationsUI/LNNotificationBannerView.m index ffb4c86..7bdbeb4 100644 --- a/LNNotificationsUI/LNNotificationsUI/LNNotificationBannerView.m +++ b/LNNotificationsUI/LNNotificationsUI/LNNotificationBannerView.m @@ -273,7 +273,7 @@ - (void)layoutSubviews { [super layoutSubviews]; - _messageLabel.preferredMaxLayoutWidth = self.bounds.size.width - (15 + _appIcon.frame.size.width + 8 + 15); + _messageLabel.preferredMaxLayoutWidth = self.bounds.size.width - (15 + _appIcon.frame.size.width + 11 + 15); } - (void)configureForNotification:(LNNotification*)notification