Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
liberty
tunnel
liberty-tunnel-client-library-apple
Commits
4f337036
Commit
4f337036
authored
Dec 05, 2018
by
Jose Blaya
Browse files
allow to open the PIAWelcome controller
parent
fbc03e2d
Changes
2
Hide whitespace changes
Inline
Side-by-side
PIALibrary/Resources/UI/iOS/Welcome.storyboard
View file @
4f337036
...
...
@@ -708,7 +708,7 @@ You will not be charged during this process.</string>
<!--Welcome View Controller-->
<scene
sceneID=
"ufC-wZ-h7g"
>
<objects>
<viewController
automaticallyAdjustsScrollViewInsets=
"NO"
id=
"vXZ-lx-hvc"
customClass=
"PIAWelcomeViewController"
customModule=
"PIALibrary"
customModuleProvider=
"target"
sceneMemberID=
"viewController"
>
<viewController
storyboardIdentifier=
"PIAWelcomeViewController"
automaticallyAdjustsScrollViewInsets=
"NO"
id=
"vXZ-lx-hvc"
customClass=
"PIAWelcomeViewController"
customModule=
"PIALibrary"
customModuleProvider=
"target"
sceneMemberID=
"viewController"
>
<view
key=
"view"
contentMode=
"scaleToFill"
id=
"kh9-bI-dsS"
>
<rect
key=
"frame"
x=
"0.0"
y=
"0.0"
width=
"375"
height=
"667"
/>
<autoresizingMask
key=
"autoresizingMask"
flexibleMaxX=
"YES"
flexibleMaxY=
"YES"
/>
...
...
@@ -1162,6 +1162,6 @@ You will not be charged during this process.</string>
</resources>
<inferredMetricsTieBreakers>
<segue
reference=
"L3M-2E-gAx"
/>
<segue
reference=
"
Vqa-Fa-HWk
"
/>
<segue
reference=
"
eeI-Xa-Rq6
"
/>
</inferredMetricsTieBreakers>
</document>
PIALibrary/Sources/UI/iOS/ViewControllers/GetStartedViewController.swift
View file @
4f337036
...
...
@@ -58,6 +58,19 @@ public class GetStartedViewController: AutolayoutViewController, ConfigurationAc
return
nav
}
public
static
func
withPurchase
(
preset
:
Preset
?
=
nil
,
delegate
:
PIAWelcomeViewControllerDelegate
?
=
nil
)
->
UIViewController
{
if
let
vc
=
StoryboardScene
.
Welcome
.
storyboard
.
instantiateViewController
(
withIdentifier
:
"PIAWelcomeViewController"
)
as?
PIAWelcomeViewController
{
if
let
customPreset
=
preset
{
vc
.
preset
=
customPreset
}
vc
.
delegate
=
delegate
let
navigationController
=
UINavigationController
(
rootViewController
:
vc
)
navigationController
.
setNavigationBarHidden
(
false
,
animated
:
false
)
return
navigationController
}
return
UIViewController
()
}
public
override
func
prepare
(
for
segue
:
UIStoryboardSegue
,
sender
:
Any
?)
{
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment