From 7b33c541a452bf36a8bf97f888d765c8733e2877 Mon Sep 17 00:00:00 2001 From: Ryan Zhao Date: Tue, 26 Apr 2022 14:32:07 +1000 Subject: [PATCH] minor fix for conversation screen title position --- Session/Conversations/ConversationVC.swift | 2 +- Session/Shared/BaseVC.swift | 5 +---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/Session/Conversations/ConversationVC.swift b/Session/Conversations/ConversationVC.swift index 1e6e06348..5475f9588 100644 --- a/Session/Conversations/ConversationVC.swift +++ b/Session/Conversations/ConversationVC.swift @@ -496,7 +496,7 @@ final class ConversationVC : BaseVC, ConversationViewModelDelegate, OWSConversat else { // Note: Adding an empty button because without it the title alignment is busted (Note: The size was // taken from the layout inspector for the back button in Xcode - navigationItem.rightBarButtonItem = UIBarButtonItem(customView: UIView(frame: CGRect(x: 0, y: 0, width: 37, height: 44))) + navigationItem.rightBarButtonItem = UIBarButtonItem(customView: UIView(frame: CGRect(x: 0, y: 0, width: Values.verySmallProfilePictureSize, height: 44))) } } else { diff --git a/Session/Shared/BaseVC.swift b/Session/Shared/BaseVC.swift index 8d32b7b43..08106e3ff 100644 --- a/Session/Shared/BaseVC.swift +++ b/Session/Shared/BaseVC.swift @@ -62,10 +62,7 @@ class BaseVC : UIViewController { navigationBar.barTintColor = Colors.navigationBarBackground } - // Back button (to appear on pushed screen) - let backButton = UIBarButtonItem(title: "", style: .plain, target: nil, action: nil) - backButton.tintColor = Colors.text - navigationItem.backBarButtonItem = backButton + navigationItem.backButtonTitle = "" } internal func setNavBarTitle(_ title: String, customFontSize: CGFloat? = nil) {