mirror of
https://github.com/oxen-io/session-ios.git
synced 2023-12-13 21:30:14 +01:00
Centralize translucency configuration
// FREEBIE
This commit is contained in:
parent
12c98f4340
commit
33eb4c38cd
|
@ -80,7 +80,6 @@
|
|||
|
||||
OWSAssert([self.navigationController isKindOfClass:[OWSNavigationController class]]);
|
||||
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
self.navigationItem.leftBarButtonItem =
|
||||
[[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemStop
|
||||
target:self
|
||||
|
|
|
@ -47,12 +47,6 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
[self updateTableContents];
|
||||
}
|
||||
|
||||
- (void)viewDidLoad
|
||||
{
|
||||
[super viewDidLoad];
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
}
|
||||
|
||||
#pragma mark - Table view data source
|
||||
|
||||
- (void)updateTableContents
|
||||
|
|
|
@ -31,7 +31,6 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
@"CENSORSHIP_CIRCUMVENTION_COUNTRY_VIEW_TITLE", @"Title for the 'censorship circumvention country' view.");
|
||||
|
||||
self.view.backgroundColor = [UIColor whiteColor];
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
|
||||
[self createViews];
|
||||
}
|
||||
|
|
|
@ -500,11 +500,8 @@ typedef enum : NSUInteger {
|
|||
{
|
||||
[super viewDidLoad];
|
||||
|
||||
// self.topLayoutGuide
|
||||
[self createContents];
|
||||
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
|
||||
[self registerCellClasses];
|
||||
|
||||
[self createConversationScrollButtons];
|
||||
|
@ -527,8 +524,6 @@ typedef enum : NSUInteger {
|
|||
{
|
||||
[super loadView];
|
||||
|
||||
// extendedLayoutIncludesOpaqueBars
|
||||
// self.extendedLayoutIncludesOpaqueBars = YES;
|
||||
self.view.backgroundColor = [UIColor ows_toolbarBackgroundColor];
|
||||
}
|
||||
|
||||
|
|
|
@ -252,7 +252,6 @@ NSString *const kArchivedConversationsReuseIdentifier = @"kArchivedConversations
|
|||
- (void)viewDidLoad
|
||||
{
|
||||
[super viewDidLoad];
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
|
||||
self.editingDbConnection = OWSPrimaryStorage.sharedManager.newDatabaseConnection;
|
||||
|
||||
|
|
|
@ -269,8 +269,6 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
// a message.
|
||||
[self.contactsViewHelper.contactsManager requestSystemContactsOnce];
|
||||
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
|
||||
[self showContactAppropriateViews];
|
||||
}
|
||||
|
||||
|
|
|
@ -420,13 +420,6 @@ const NSUInteger kNewGroupViewControllerAvatarWidth = 68;
|
|||
|
||||
#pragma mark - Methods
|
||||
|
||||
- (void)viewDidLoad
|
||||
{
|
||||
[super viewDidLoad];
|
||||
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
}
|
||||
|
||||
- (void)viewDidAppear:(BOOL)animated
|
||||
{
|
||||
[super viewDidAppear:animated];
|
||||
|
|
|
@ -75,7 +75,6 @@ NSString *const kProfileView_LastPresentedDate = @"kProfileView_LastPresentedDat
|
|||
{
|
||||
[super loadView];
|
||||
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
self.title = NSLocalizedString(@"PROFILE_VIEW_TITLE", @"Title for the profile view.");
|
||||
|
||||
_avatarViewHelper = [AvatarViewHelper new];
|
||||
|
@ -94,7 +93,7 @@ NSString *const kProfileView_LastPresentedDate = @"kProfileView_LastPresentedDat
|
|||
UIView *contentView = [UIView containerView];
|
||||
contentView.backgroundColor = [UIColor whiteColor];
|
||||
[self.view addSubview:contentView];
|
||||
[contentView autoPinEdgeToSuperviewEdge:ALEdgeTop];
|
||||
[contentView autoPinToTopLayoutGuideOfViewController:self withInset:0];
|
||||
[contentView autoPinWidthToSuperview];
|
||||
|
||||
const CGFloat fontSizePoints = ScaleFromIPhone5To7Plus(16.f, 20.f);
|
||||
|
|
|
@ -97,11 +97,6 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
|
||||
OWSAssert([self.navigationController isKindOfClass:[OWSNavigationController class]]);
|
||||
|
||||
// HACK otherwise CNContactViewController Navbar is shown as black.
|
||||
// RADAR rdar://28433898 http://www.openradar.me/28433898
|
||||
// CNContactViewController incompatible with opaque navigation bar
|
||||
[self.navigationController.navigationBar setTranslucent:YES];
|
||||
|
||||
self.title = _thread.groupModel.groupName;
|
||||
|
||||
[self updateTableContents];
|
||||
|
|
|
@ -113,7 +113,7 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
[self.view addSubview:firstSection];
|
||||
[firstSection autoSetDimension:ALDimensionHeight toSize:100.f];
|
||||
[firstSection autoPinWidthToSuperview];
|
||||
[firstSection autoPinEdgeToSuperviewEdge:ALEdgeTop];
|
||||
[firstSection autoPinToTopLayoutGuideOfViewController:self withInset:0];
|
||||
|
||||
_tableViewController = [OWSTableViewController new];
|
||||
_tableViewController.delegate = self;
|
||||
|
@ -125,13 +125,6 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
[self updateTableContents];
|
||||
}
|
||||
|
||||
- (void)viewDidLoad
|
||||
{
|
||||
[super viewDidLoad];
|
||||
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
}
|
||||
|
||||
- (void)setHasUnsavedChanges:(BOOL)hasUnsavedChanges
|
||||
{
|
||||
_hasUnsavedChanges = hasUnsavedChanges;
|
||||
|
|
|
@ -16,6 +16,8 @@ class SignalNavigationBar: UINavigationBar {
|
|||
override init(frame: CGRect) {
|
||||
super.init(frame: frame)
|
||||
|
||||
self.isTranslucent = false
|
||||
|
||||
// TODO better place to observe?
|
||||
NotificationCenter.default.addObserver(forName: .OWSWindowManagerCallDidChange, object: nil, queue: nil) { _ in
|
||||
Logger.debug("\(self.logTag) in \(#function) OWSWindowManagerCallDidChange")
|
||||
|
|
|
@ -463,13 +463,6 @@ NSString *const kOWSTableCellIdentifier = @"kOWSTableCellIdentifier";
|
|||
[self.tableView registerClass:[UITableViewCell class] forCellReuseIdentifier:kOWSTableCellIdentifier];
|
||||
}
|
||||
|
||||
- (void)viewDidLoad
|
||||
{
|
||||
[super viewDidLoad];
|
||||
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
}
|
||||
|
||||
- (void)viewWillAppear:(BOOL)animated
|
||||
{
|
||||
[super viewWillAppear:animated];
|
||||
|
|
|
@ -26,7 +26,6 @@
|
|||
[super loadView];
|
||||
|
||||
self.view.backgroundColor = [UIColor whiteColor];
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
self.title = NSLocalizedString(@"COUNTRYCODE_SELECT_TITLE", @"");
|
||||
|
||||
self.countryCodes = [PhoneNumberUtil countryCodesForSearchTerm:nil];
|
||||
|
|
|
@ -55,7 +55,6 @@ NSString *const kSelectRecipientViewControllerCellIdentifier = @"kSelectRecipien
|
|||
[super loadView];
|
||||
|
||||
self.view.backgroundColor = [UIColor whiteColor];
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
|
||||
_contactsViewHelper = [[ContactsViewHelper alloc] initWithDelegate:self];
|
||||
|
||||
|
|
|
@ -81,12 +81,6 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
[self updateTableContents];
|
||||
}
|
||||
|
||||
- (void)viewDidLoad
|
||||
{
|
||||
[super viewDidLoad];
|
||||
[self.navigationController.navigationBar setTranslucent:NO];
|
||||
}
|
||||
|
||||
- (void)createViews
|
||||
{
|
||||
OWSAssert(self.selectThreadViewDelegate);
|
||||
|
|
Loading…
Reference in a new issue