Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
Flutter Inappwebview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李增强
Flutter Inappwebview
Commits
c316c479
Commit
c316c479
authored
Sep 23, 2019
by
wyy
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
migrating to swift 5.0
parent
f6353b8f
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
26 additions
and
20 deletions
+26
-20
example/ios/Runner.xcodeproj/project.pbxproj
example/ios/Runner.xcodeproj/project.pbxproj
+4
-3
example/ios/Runner/AppDelegate.swift
example/ios/Runner/AppDelegate.swift
+1
-1
ios/Classes/InAppBrowserWebViewController.swift
ios/Classes/InAppBrowserWebViewController.swift
+7
-7
ios/Classes/InAppWebView.swift
ios/Classes/InAppWebView.swift
+1
-1
ios/Classes/SafariViewController.swift
ios/Classes/SafariViewController.swift
+1
-1
ios/Classes/SwiftFlutterPlugin.swift
ios/Classes/SwiftFlutterPlugin.swift
+12
-7
No files found.
example/ios/Runner.xcodeproj/project.pbxproj
View file @
c316c479
...
@@ -179,7 +179,7 @@
...
@@ -179,7 +179,7 @@
97C146ED1CF9000F007C117D
=
{
97C146ED1CF9000F007C117D
=
{
CreatedOnToolsVersion
=
7.3.1
;
CreatedOnToolsVersion
=
7.3.1
;
DevelopmentTeam
=
PFP8UV45Y6
;
DevelopmentTeam
=
PFP8UV45Y6
;
LastSwiftMigration
=
091
0
;
LastSwiftMigration
=
110
0
;
};
};
};
};
};
};
...
@@ -188,6 +188,7 @@
...
@@ -188,6 +188,7 @@
developmentRegion
=
English
;
developmentRegion
=
English
;
hasScannedForEncodings
=
0
;
hasScannedForEncodings
=
0
;
knownRegions
=
(
knownRegions
=
(
English
,
en
,
en
,
Base
,
Base
,
);
);
...
@@ -447,7 +448,7 @@
...
@@ -447,7 +448,7 @@
SWIFT_OBJC_BRIDGING_HEADER
=
"Runner/Runner-Bridging-Header.h"
;
SWIFT_OBJC_BRIDGING_HEADER
=
"Runner/Runner-Bridging-Header.h"
;
SWIFT_OPTIMIZATION_LEVEL
=
"-Onone"
;
SWIFT_OPTIMIZATION_LEVEL
=
"-Onone"
;
SWIFT_SWIFT3_OBJC_INFERENCE
=
Default
;
SWIFT_SWIFT3_OBJC_INFERENCE
=
Default
;
SWIFT_VERSION
=
4
.0
;
SWIFT_VERSION
=
5
.0
;
VERSIONING_SYSTEM
=
"apple-generic"
;
VERSIONING_SYSTEM
=
"apple-generic"
;
};
};
name
=
Debug
;
name
=
Debug
;
...
@@ -475,7 +476,7 @@
...
@@ -475,7 +476,7 @@
PRODUCT_NAME
=
"$(TARGET_NAME)"
;
PRODUCT_NAME
=
"$(TARGET_NAME)"
;
SWIFT_OBJC_BRIDGING_HEADER
=
"Runner/Runner-Bridging-Header.h"
;
SWIFT_OBJC_BRIDGING_HEADER
=
"Runner/Runner-Bridging-Header.h"
;
SWIFT_SWIFT3_OBJC_INFERENCE
=
Default
;
SWIFT_SWIFT3_OBJC_INFERENCE
=
Default
;
SWIFT_VERSION
=
4
.0
;
SWIFT_VERSION
=
5
.0
;
VERSIONING_SYSTEM
=
"apple-generic"
;
VERSIONING_SYSTEM
=
"apple-generic"
;
};
};
name
=
Release
;
name
=
Release
;
...
...
example/ios/Runner/AppDelegate.swift
View file @
c316c479
...
@@ -5,7 +5,7 @@ import Flutter
...
@@ -5,7 +5,7 @@ import Flutter
@objc
class
AppDelegate
:
FlutterAppDelegate
{
@objc
class
AppDelegate
:
FlutterAppDelegate
{
override
func
application
(
override
func
application
(
_
application
:
UIApplication
,
_
application
:
UIApplication
,
didFinishLaunchingWithOptions
launchOptions
:
[
UIApplicationLaunchOptionsKey
:
Any
]?
didFinishLaunchingWithOptions
launchOptions
:
[
UIApplication
.
LaunchOptionsKey
:
Any
]?
)
->
Bool
{
)
->
Bool
{
GeneratedPluginRegistrant
.
register
(
with
:
self
)
GeneratedPluginRegistrant
.
register
(
with
:
self
)
return
super
.
application
(
application
,
didFinishLaunchingWithOptions
:
launchOptions
)
return
super
.
application
(
application
,
didFinishLaunchingWithOptions
:
launchOptions
)
...
...
ios/Classes/InAppBrowserWebViewController.swift
View file @
c316c479
...
@@ -172,8 +172,8 @@ class InAppBrowserWebViewController: UIViewController, UIScrollViewDelegate, WKU
...
@@ -172,8 +172,8 @@ class InAppBrowserWebViewController: UIViewController, UIScrollViewDelegate, WKU
}
}
func
prepareConstraints
()
{
func
prepareConstraints
()
{
containerWebView_BottomFullScreenConstraint
=
NSLayoutConstraint
(
item
:
self
.
containerWebView
,
attribute
:
NSLayout
Attribute
.
bottom
,
relatedBy
:
NSLayoutRelation
.
equal
,
toItem
:
self
.
view
,
attribute
:
NSLayout
Attribute
.
bottom
,
multiplier
:
1
,
constant
:
0
)
containerWebView_BottomFullScreenConstraint
=
NSLayoutConstraint
(
item
:
self
.
containerWebView
,
attribute
:
NSLayout
Constraint
.
Attribute
.
bottom
,
relatedBy
:
NSLayoutConstraint
.
Relation
.
equal
,
toItem
:
self
.
view
,
attribute
:
NSLayoutConstraint
.
Attribute
.
bottom
,
multiplier
:
1
,
constant
:
0
)
containerWebView_TopFullScreenConstraint
=
NSLayoutConstraint
(
item
:
self
.
containerWebView
,
attribute
:
NSLayout
Attribute
.
top
,
relatedBy
:
NSLayoutRelation
.
equal
,
toItem
:
self
.
view
,
attribute
:
NSLayout
Attribute
.
top
,
multiplier
:
1
,
constant
:
0
)
containerWebView_TopFullScreenConstraint
=
NSLayoutConstraint
(
item
:
self
.
containerWebView
,
attribute
:
NSLayout
Constraint
.
Attribute
.
top
,
relatedBy
:
NSLayoutConstraint
.
Relation
.
equal
,
toItem
:
self
.
view
,
attribute
:
NSLayoutConstraint
.
Attribute
.
top
,
multiplier
:
1
,
constant
:
0
)
webView
.
translatesAutoresizingMaskIntoConstraints
=
false
webView
.
translatesAutoresizingMaskIntoConstraints
=
false
let
height
=
NSLayoutConstraint
(
item
:
webView
,
attribute
:
.
height
,
relatedBy
:
.
equal
,
toItem
:
containerWebView
,
attribute
:
.
height
,
multiplier
:
1
,
constant
:
0
)
let
height
=
NSLayoutConstraint
(
item
:
webView
,
attribute
:
.
height
,
relatedBy
:
.
equal
,
toItem
:
containerWebView
,
attribute
:
.
height
,
multiplier
:
1
,
constant
:
0
)
...
@@ -183,8 +183,8 @@ class InAppBrowserWebViewController: UIViewController, UIScrollViewDelegate, WKU
...
@@ -183,8 +183,8 @@ class InAppBrowserWebViewController: UIViewController, UIScrollViewDelegate, WKU
let
bottomContraint
=
NSLayoutConstraint
(
item
:
webView
,
attribute
:
.
bottomMargin
,
relatedBy
:
.
equal
,
toItem
:
containerWebView
,
attribute
:
.
bottomMargin
,
multiplier
:
1
,
constant
:
0
)
let
bottomContraint
=
NSLayoutConstraint
(
item
:
webView
,
attribute
:
.
bottomMargin
,
relatedBy
:
.
equal
,
toItem
:
containerWebView
,
attribute
:
.
bottomMargin
,
multiplier
:
1
,
constant
:
0
)
containerWebView
.
addConstraints
([
height
,
width
,
leftConstraint
,
rightConstraint
,
bottomContraint
])
containerWebView
.
addConstraints
([
height
,
width
,
leftConstraint
,
rightConstraint
,
bottomContraint
])
webView_BottomFullScreenConstraint
=
NSLayoutConstraint
(
item
:
self
.
webView
,
attribute
:
NSLayout
Attribute
.
bottom
,
relatedBy
:
NSLayoutRelation
.
equal
,
toItem
:
self
.
containerWebView
,
attribute
:
NSLayout
Attribute
.
bottom
,
multiplier
:
1
,
constant
:
0
)
webView_BottomFullScreenConstraint
=
NSLayoutConstraint
(
item
:
self
.
webView
,
attribute
:
NSLayout
Constraint
.
Attribute
.
bottom
,
relatedBy
:
NSLayoutConstraint
.
Relation
.
equal
,
toItem
:
self
.
containerWebView
,
attribute
:
NSLayoutConstraint
.
Attribute
.
bottom
,
multiplier
:
1
,
constant
:
0
)
webView_TopFullScreenConstraint
=
NSLayoutConstraint
(
item
:
self
.
webView
,
attribute
:
NSLayout
Attribute
.
top
,
relatedBy
:
NSLayoutRelation
.
equal
,
toItem
:
self
.
containerWebView
,
attribute
:
NSLayout
Attribute
.
top
,
multiplier
:
1
,
constant
:
0
)
webView_TopFullScreenConstraint
=
NSLayoutConstraint
(
item
:
self
.
webView
,
attribute
:
NSLayout
Constraint
.
Attribute
.
top
,
relatedBy
:
NSLayoutConstraint
.
Relation
.
equal
,
toItem
:
self
.
containerWebView
,
attribute
:
NSLayoutConstraint
.
Attribute
.
top
,
multiplier
:
1
,
constant
:
0
)
}
}
func
prepareWebView
()
{
func
prepareWebView
()
{
...
@@ -254,7 +254,7 @@ class InAppBrowserWebViewController: UIViewController, UIScrollViewDelegate, WKU
...
@@ -254,7 +254,7 @@ class InAppBrowserWebViewController: UIViewController, UIScrollViewDelegate, WKU
}
}
func
setWebViewFrame
(
_
frame
:
CGRect
)
{
func
setWebViewFrame
(
_
frame
:
CGRect
)
{
print
(
"Setting the WebView's frame to
\(
NS
StringFromCGRect
(
frame
)
)
"
)
print
(
"Setting the WebView's frame to
\(
NS
Coder
.
string
(
for
:
frame
)
)
"
)
webView
.
frame
=
frame
webView
.
frame
=
frame
}
}
...
@@ -276,7 +276,7 @@ class InAppBrowserWebViewController: UIViewController, UIScrollViewDelegate, WKU
...
@@ -276,7 +276,7 @@ class InAppBrowserWebViewController: UIViewController, UIScrollViewDelegate, WKU
DispatchQueue
.
main
.
async
(
execute
:
{()
->
Void
in
DispatchQueue
.
main
.
async
(
execute
:
{()
->
Void
in
if
(
weakSelf
?
.
responds
(
to
:
#selector(
getter: self.presentingViewController
)
))
!
{
if
(
weakSelf
?
.
responds
(
to
:
#selector(
getter: self.presentingViewController
)
))
!
{
weakSelf
?
.
presentingViewController
?
.
dismiss
(
animated
:
true
,
completion
:
{()
->
Void
in
weakSelf
?
.
presentingViewController
?
.
dismiss
(
animated
:
true
,
completion
:
{()
->
Void
in
self
.
tmpWindow
?
.
windowLevel
=
0.0
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
.
Level
(
rawValue
:
0.0
)
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
if
(
self
.
navigationDelegate
!=
nil
)
{
if
(
self
.
navigationDelegate
!=
nil
)
{
self
.
navigationDelegate
?
.
browserExit
(
uuid
:
self
.
uuid
)
self
.
navigationDelegate
?
.
browserExit
(
uuid
:
self
.
uuid
)
...
@@ -285,7 +285,7 @@ class InAppBrowserWebViewController: UIViewController, UIScrollViewDelegate, WKU
...
@@ -285,7 +285,7 @@ class InAppBrowserWebViewController: UIViewController, UIScrollViewDelegate, WKU
}
}
else
{
else
{
weakSelf
?
.
parent
?
.
dismiss
(
animated
:
true
,
completion
:
{()
->
Void
in
weakSelf
?
.
parent
?
.
dismiss
(
animated
:
true
,
completion
:
{()
->
Void
in
self
.
tmpWindow
?
.
windowLevel
=
0.0
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
.
Level
(
rawValue
:
0.0
)
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
if
(
self
.
navigationDelegate
!=
nil
)
{
if
(
self
.
navigationDelegate
!=
nil
)
{
self
.
navigationDelegate
?
.
browserExit
(
uuid
:
self
.
uuid
)
self
.
navigationDelegate
?
.
browserExit
(
uuid
:
self
.
uuid
)
...
...
ios/Classes/InAppWebView.swift
View file @
c316c479
...
@@ -240,7 +240,7 @@ public class InAppWebView: WKWebView, UIScrollViewDelegate, WKUIDelegate, WKNavi
...
@@ -240,7 +240,7 @@ public class InAppWebView: WKWebView, UIScrollViewDelegate, WKUIDelegate, WKNavi
takeSnapshot
(
with
:
nil
,
completionHandler
:
{(
image
,
error
)
->
Void
in
takeSnapshot
(
with
:
nil
,
completionHandler
:
{(
image
,
error
)
->
Void
in
var
imageData
:
Data
?
=
nil
var
imageData
:
Data
?
=
nil
if
let
screenshot
=
image
{
if
let
screenshot
=
image
{
imageData
=
UIImagePNGRepresentation
(
screenshot
)
!
imageData
=
screenshot
.
pngData
(
)
!
}
}
completionHandler
(
imageData
)
completionHandler
(
imageData
)
})
})
...
...
ios/Classes/SafariViewController.swift
View file @
c316c479
...
@@ -43,7 +43,7 @@ class SafariViewController: SFSafariViewController, SFSafariViewControllerDelega
...
@@ -43,7 +43,7 @@ class SafariViewController: SFSafariViewController, SFSafariViewControllerDelega
dismiss
(
animated
:
true
)
dismiss
(
animated
:
true
)
DispatchQueue
.
main
.
asyncAfter
(
deadline
:
.
now
()
+
.
milliseconds
(
400
),
execute
:
{()
->
Void
in
DispatchQueue
.
main
.
asyncAfter
(
deadline
:
.
now
()
+
.
milliseconds
(
400
),
execute
:
{()
->
Void
in
self
.
tmpWindow
?
.
windowLevel
=
0.0
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
.
Level
(
rawValue
:
0.0
)
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
if
(
self
.
statusDelegate
!=
nil
)
{
if
(
self
.
statusDelegate
!=
nil
)
{
...
...
ios/Classes/SwiftFlutterPlugin.swift
View file @
c316c479
...
@@ -350,7 +350,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
...
@@ -350,7 +350,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
let
tmpController
=
UIViewController
()
let
tmpController
=
UIViewController
()
let
baseWindowLevel
=
UIApplication
.
shared
.
keyWindow
?
.
windowLevel
let
baseWindowLevel
=
UIApplication
.
shared
.
keyWindow
?
.
windowLevel
self
.
tmpWindow
?
.
rootViewController
=
tmpController
self
.
tmpWindow
?
.
rootViewController
=
tmpController
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
Level
(
baseWindowLevel
!
+
1
)
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
.
Level
(
baseWindowLevel
!.
rawValue
+
1
)
self
.
tmpWindow
?
.
makeKeyAndVisible
()
self
.
tmpWindow
?
.
makeKeyAndVisible
()
let
browserOptions
:
InAppBrowserOptions
let
browserOptions
:
InAppBrowserOptions
...
@@ -435,7 +435,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
...
@@ -435,7 +435,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
// UIApplication.shared.statusBarStyle = UIStatusBarStyle(rawValue: self.previousStatusBarStyle)!
// UIApplication.shared.statusBarStyle = UIStatusBarStyle(rawValue: self.previousStatusBarStyle)!
// }
// }
webViewController
.
presentingViewController
?
.
dismiss
(
animated
:
false
,
completion
:
{()
->
Void
in
webViewController
.
presentingViewController
?
.
dismiss
(
animated
:
false
,
completion
:
{()
->
Void
in
self
.
tmpWindow
?
.
windowLevel
=
0.0
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
.
Level
(
rawValue
:
0.0
)
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
})
})
}
}
...
@@ -466,7 +466,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
...
@@ -466,7 +466,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
let
tmpController
=
UIViewController
()
let
tmpController
=
UIViewController
()
let
baseWindowLevel
=
UIApplication
.
shared
.
keyWindow
?
.
windowLevel
let
baseWindowLevel
=
UIApplication
.
shared
.
keyWindow
?
.
windowLevel
self
.
tmpWindow
?
.
rootViewController
=
tmpController
self
.
tmpWindow
?
.
rootViewController
=
tmpController
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
Level
(
baseWindowLevel
!
+
1
)
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
.
Level
(
baseWindowLevel
!.
rawValue
+
1
)
self
.
tmpWindow
?
.
makeKeyAndVisible
()
self
.
tmpWindow
?
.
makeKeyAndVisible
()
let
browserOptions
:
InAppBrowserOptions
let
browserOptions
:
InAppBrowserOptions
...
@@ -499,7 +499,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
...
@@ -499,7 +499,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
webViewController
.
webView
.
loadData
(
data
:
data
,
mimeType
:
mimeType
,
encoding
:
encoding
,
baseUrl
:
baseUrl
)
webViewController
.
webView
.
loadData
(
data
:
data
,
mimeType
:
mimeType
,
encoding
:
encoding
,
baseUrl
:
baseUrl
)
})
})
webViewController
.
presentingViewController
?
.
dismiss
(
animated
:
false
,
completion
:
{()
->
Void
in
webViewController
.
presentingViewController
?
.
dismiss
(
animated
:
false
,
completion
:
{()
->
Void
in
self
.
tmpWindow
?
.
windowLevel
=
0.0
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
.
Level
(
rawValue
:
0.0
)
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
})
})
}
}
...
@@ -518,7 +518,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
...
@@ -518,7 +518,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
}
}
else
{
else
{
if
#available(iOS 10.0, *)
{
if
#available(iOS 10.0, *)
{
UIApplication
.
shared
.
open
(
url
,
options
:
[:]
,
completionHandler
:
nil
)
UIApplication
.
shared
.
open
(
url
,
options
:
convertToUIApplicationOpenExternalURLOptionsKeyDictionary
([:])
,
completionHandler
:
nil
)
}
else
{
}
else
{
UIApplication
.
shared
.
openURL
(
url
)
UIApplication
.
shared
.
openURL
(
url
)
}
}
...
@@ -536,7 +536,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
...
@@ -536,7 +536,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
DispatchQueue
.
main
.
async
(
execute
:
{()
->
Void
in
DispatchQueue
.
main
.
async
(
execute
:
{()
->
Void
in
if
webViewController
!=
nil
{
if
webViewController
!=
nil
{
let
baseWindowLevel
=
UIApplication
.
shared
.
keyWindow
?
.
windowLevel
let
baseWindowLevel
=
UIApplication
.
shared
.
keyWindow
?
.
windowLevel
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
Level
(
baseWindowLevel
!
+
1
)
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
.
Level
(
baseWindowLevel
!.
rawValue
+
1
)
self
.
tmpWindow
?
.
makeKeyAndVisible
()
self
.
tmpWindow
?
.
makeKeyAndVisible
()
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
self
.
tmpWindow
?
.
rootViewController
?
.
present
(
webViewController
!
,
animated
:
true
,
completion
:
nil
)
self
.
tmpWindow
?
.
rootViewController
?
.
present
(
webViewController
!
,
animated
:
true
,
completion
:
nil
)
...
@@ -558,7 +558,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
...
@@ -558,7 +558,7 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
DispatchQueue
.
main
.
async
(
execute
:
{()
->
Void
in
DispatchQueue
.
main
.
async
(
execute
:
{()
->
Void
in
if
webViewController
!=
nil
{
if
webViewController
!=
nil
{
webViewController
?
.
presentingViewController
?
.
dismiss
(
animated
:
true
,
completion
:
{()
->
Void
in
webViewController
?
.
presentingViewController
?
.
dismiss
(
animated
:
true
,
completion
:
{()
->
Void
in
self
.
tmpWindow
?
.
windowLevel
=
0.0
self
.
tmpWindow
?
.
windowLevel
=
UIWindow
.
Level
(
rawValue
:
0.0
)
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
UIApplication
.
shared
.
delegate
?
.
window
??
.
makeKeyAndVisible
()
if
self
.
previousStatusBarStyle
!=
-
1
{
if
self
.
previousStatusBarStyle
!=
-
1
{
UIApplication
.
shared
.
statusBarStyle
=
UIStatusBarStyle
(
rawValue
:
self
.
previousStatusBarStyle
)
!
UIApplication
.
shared
.
statusBarStyle
=
UIStatusBarStyle
(
rawValue
:
self
.
previousStatusBarStyle
)
!
...
@@ -749,3 +749,8 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
...
@@ -749,3 +749,8 @@ public class SwiftFlutterPlugin: NSObject, FlutterPlugin {
}
}
}
}
// Helper function inserted by Swift 4.2 migrator.
fileprivate
func
convertToUIApplicationOpenExternalURLOptionsKeyDictionary
(
_
input
:
[
String
:
Any
])
->
[
UIApplication
.
OpenExternalURLOptionsKey
:
Any
]
{
return
Dictionary
(
uniqueKeysWithValues
:
input
.
map
{
key
,
value
in
(
UIApplication
.
OpenExternalURLOptionsKey
(
rawValue
:
key
),
value
)})
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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