File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 6
6
// Copyright © 2017 Samaritan. All rights reserved.
7
7
//
8
8
9
- import UIKit
10
9
import WebKit
11
10
12
11
/// Bridge for WKWebView and JavaScript
@@ -197,7 +196,7 @@ public extension WKWebView {
197
196
}
198
197
199
198
/// Bridge for WKWebView and JavaScript. Initialize `lazy`
200
- public var bridge : Bridge {
199
+ var bridge : Bridge {
201
200
if let bridge = objc_getAssociatedObject ( self , & STPrivateStatic. bridgeKey) as? Bridge {
202
201
return bridge
203
202
}
@@ -207,7 +206,7 @@ public extension WKWebView {
207
206
}
208
207
209
208
/// Remove Bridge And Reset, All the handlers will be removed
210
- public func removeBridge( ) {
209
+ func removeBridge( ) {
211
210
if let bridge = objc_getAssociatedObject ( self , & STPrivateStatic. bridgeKey) as? Bridge {
212
211
let userContentController = bridge. configuration. userContentController
213
212
userContentController. removeScriptMessageHandler ( forName: Bridge . name)
@@ -218,7 +217,7 @@ public extension WKWebView {
218
217
219
218
fileprivate extension WKWebView {
220
219
221
- fileprivate func st_dispatchBridgeEvent( _ eventName: String ,
220
+ func st_dispatchBridgeEvent( _ eventName: String ,
222
221
parameters: [ String : Any ] ,
223
222
results: Bridge . Results ,
224
223
completionHandler: ( ( Any ? , Error ? ) -> Void ) ? = nil ) {
Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ public struct EthereumTransaction: CustomStringConvertible {
17
17
// The destination address of the message, left undefined for a contract-creation transaction.
18
18
public var to : EthereumAddress
19
19
// (optional) The value transferred for the transaction in wei, also the endowment if it’s a contract-creation transaction.
20
+ // TODO - split EthereumTransaction to two classes: with optional and required value property, depends on type of transaction
20
21
public var value : BigUInt ?
21
22
public var data : Data
22
23
public var v : BigUInt = BigUInt ( 1 )
You can’t perform that action at this time.
0 commit comments