Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
xx messenger iOS
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mobile
iOS
xx messenger iOS
Commits
665b4ff3
Commit
665b4ff3
authored
2 years ago
by
Bruno Muniz
Browse files
Options
Downloads
Patches
Plain Diff
Fix dismissing webscreen
parent
b6db0f19
No related branches found
Branches containing commit
No related tags found
1 merge request
!103
Fix dismissing webscreen
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Package.swift
+3
-0
3 additions, 0 deletions
Package.swift
Sources/WebsiteFeature/WebsiteController.swift
+21
-1
21 additions, 1 deletion
Sources/WebsiteFeature/WebsiteController.swift
with
24 additions
and
1 deletion
Package.swift
+
3
−
0
View file @
665b4ff3
...
@@ -203,6 +203,9 @@ let package = Package(
...
@@ -203,6 +203,9 @@ let package = Package(
),
),
.
target
(
.
target
(
name
:
"WebsiteFeature"
,
name
:
"WebsiteFeature"
,
dependencies
:
[
.
target
(
name
:
"AppResources"
),
],
swiftSettings
:
swiftSettings
swiftSettings
:
swiftSettings
),
),
.
target
(
.
target
(
...
...
This diff is collapsed.
Click to expand it.
Sources/WebsiteFeature/WebsiteController.swift
+
21
−
1
View file @
665b4ff3
import
UIKit
import
UIKit
import
WebKit
import
WebKit
import
AppResources
public
final
class
WebsiteController
:
UIViewController
{
public
final
class
WebsiteController
:
UIViewController
{
private
lazy
var
webView
=
WKWebView
()
private
lazy
var
webView
=
WKWebView
()
...
@@ -12,7 +13,26 @@ public final class WebsiteController: UIViewController {
...
@@ -12,7 +13,26 @@ public final class WebsiteController: UIViewController {
}
}
public
override
func
loadView
()
{
public
override
func
loadView
()
{
view
=
webView
let
screenView
=
UIView
()
let
navigationBar
=
UINavigationBar
()
navigationBar
.
isTranslucent
=
false
navigationBar
.
backgroundColor
=
Asset
.
neutralLine
.
color
screenView
.
addSubview
(
navigationBar
)
screenView
.
addSubview
(
webView
)
navigationBar
.
translatesAutoresizingMaskIntoConstraints
=
false
navigationBar
.
leftAnchor
.
constraint
(
equalTo
:
screenView
.
leftAnchor
)
.
isActive
=
true
navigationBar
.
rightAnchor
.
constraint
(
equalTo
:
screenView
.
rightAnchor
)
.
isActive
=
true
navigationBar
.
topAnchor
.
constraint
(
equalTo
:
screenView
.
safeAreaLayoutGuide
.
topAnchor
)
.
isActive
=
true
webView
.
translatesAutoresizingMaskIntoConstraints
=
false
webView
.
leftAnchor
.
constraint
(
equalTo
:
screenView
.
leftAnchor
)
.
isActive
=
true
webView
.
rightAnchor
.
constraint
(
equalTo
:
screenView
.
rightAnchor
)
.
isActive
=
true
webView
.
topAnchor
.
constraint
(
equalTo
:
navigationBar
.
bottomAnchor
)
.
isActive
=
true
webView
.
bottomAnchor
.
constraint
(
equalTo
:
screenView
.
bottomAnchor
)
.
isActive
=
true
view
=
screenView
}
}
required
init
?(
coder
:
NSCoder
)
{
nil
}
required
init
?(
coder
:
NSCoder
)
{
nil
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment