Respond to CR.

pull/1/head
Matthew Chen 7 years ago
parent 53b1ae6a36
commit 196d82c17a

@ -41,8 +41,6 @@ NS_ASSUME_NONNULL_BEGIN
{ {
OWSAssert(!self.titleLabel); OWSAssert(!self.titleLabel);
self.preservesSuperviewLayoutMargins = NO;
self.contentView.preservesSuperviewLayoutMargins = NO;
self.layoutMargins = UIEdgeInsetsZero; self.layoutMargins = UIEdgeInsetsZero;
self.contentView.layoutMargins = UIEdgeInsetsZero; self.contentView.layoutMargins = UIEdgeInsetsZero;

@ -49,8 +49,6 @@ NS_ASSUME_NONNULL_BEGIN
// Ensure only called once. // Ensure only called once.
OWSAssert(!self.messageBubbleView); OWSAssert(!self.messageBubbleView);
self.preservesSuperviewLayoutMargins = NO;
self.contentView.preservesSuperviewLayoutMargins = NO;
self.layoutMargins = UIEdgeInsetsZero; self.layoutMargins = UIEdgeInsetsZero;
self.contentView.layoutMargins = UIEdgeInsetsZero; self.contentView.layoutMargins = UIEdgeInsetsZero;

@ -46,8 +46,6 @@ NS_ASSUME_NONNULL_BEGIN
{ {
OWSAssert(!self.imageView); OWSAssert(!self.imageView);
self.preservesSuperviewLayoutMargins = NO;
self.contentView.preservesSuperviewLayoutMargins = NO;
self.layoutMargins = UIEdgeInsetsZero; self.layoutMargins = UIEdgeInsetsZero;
self.contentView.layoutMargins = UIEdgeInsetsZero; self.contentView.layoutMargins = UIEdgeInsetsZero;

@ -40,8 +40,6 @@ NS_ASSUME_NONNULL_BEGIN
{ {
OWSAssert(!self.titleLabel); OWSAssert(!self.titleLabel);
self.preservesSuperviewLayoutMargins = NO;
self.contentView.preservesSuperviewLayoutMargins = NO;
self.layoutMargins = UIEdgeInsetsZero; self.layoutMargins = UIEdgeInsetsZero;
self.contentView.layoutMargins = UIEdgeInsetsZero; self.contentView.layoutMargins = UIEdgeInsetsZero;

@ -87,20 +87,12 @@ class MessageDetailViewController: OWSViewController, MediaGalleryDataSourceDele
object: OWSPrimaryStorage.shared().dbNotificationObject) object: OWSPrimaryStorage.shared().dbNotificationObject)
} }
override public func viewWillLayoutSubviews() { override public func viewWillTransition(to size: CGSize, with coordinator: UIViewControllerTransitionCoordinator) {
Logger.debug("\(self.logTag) in \(#function)") Logger.debug("\(self.logTag) in \(#function)")
super.viewWillLayoutSubviews() super.viewWillTransition(to: size, with: coordinator)
self.conversationLayoutInfo.viewWidth = self.view.width() self.conversationLayoutInfo.viewWidth = size.width
}
override public func viewDidLayoutSubviews() {
Logger.debug("\(self.logTag) in \(#function)")
super.viewDidLayoutSubviews()
self.conversationLayoutInfo.viewWidth = self.view.width()
} }
override func viewWillAppear(_ animated: Bool) { override func viewWillAppear(_ animated: Bool) {

Loading…
Cancel
Save