Skip to content
Snippets Groups Projects
Commit 6b78309a authored by Dariusz Rybicki's avatar Dariusz Rybicki
Browse files

Update scroll view setup in ProfileCodeController

parent 45244f96
Branches
No related tags found
1 merge request!91Fix transition bug when the keyboard is presented
This commit is part of merge request !91. Comments created here will be created in the context of that merge request.
...@@ -60,14 +60,20 @@ public final class ProfileCodeController: UIViewController { ...@@ -60,14 +60,20 @@ public final class ProfileCodeController: UIViewController {
} }
private func setupScrollView() { private func setupScrollView() {
scrollViewController.contentView = screenView
scrollViewController.scrollView.backgroundColor = Asset.neutralWhite.color
addChild(scrollViewController) addChild(scrollViewController)
view.addSubview(scrollViewController.view) view.addSubview(scrollViewController.view)
scrollViewController.view.snp.makeConstraints { scrollViewController.view.translatesAutoresizingMaskIntoConstraints = false
$0.edges.equalToSuperview() NSLayoutConstraint.activate([
} scrollViewController.view.topAnchor.constraint(equalTo: view.topAnchor),
scrollViewController.view.bottomAnchor.constraint(equalTo: view.bottomAnchor),
scrollViewController.view.leftAnchor.constraint(equalTo: view.leftAnchor),
scrollViewController.view.rightAnchor.constraint(equalTo: view.rightAnchor),
])
view.setNeedsLayout()
view.layoutIfNeeded()
scrollViewController.didMove(toParent: self) scrollViewController.didMove(toParent: self)
scrollViewController.contentView = screenView
scrollViewController.scrollView.backgroundColor = Asset.neutralWhite.color
} }
private func setupBindings() { private func setupBindings() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment