1
0
mirror of https://github.com/flutter/samples.git synced 2025-11-10 14:58:34 +00:00

Add-to-app samples using plugin (#152)

This commit is contained in:
Andrew Brogdon
2019-10-16 15:53:29 -07:00
committed by GitHub
parent 64cfc2bdc7
commit bfdc21841c
61 changed files with 2124 additions and 89 deletions

View File

@@ -13,6 +13,8 @@ class ViewController: UIViewController {
var count = 0
override func viewDidLoad() {
super.viewDidLoad()
if let flutterEngine = (UIApplication.shared.delegate as? AppDelegate)?.flutterEngine {
methodChannel = FlutterMethodChannel(name: "dev.flutter.example/counter",
binaryMessenger: flutterEngine.binaryMessenger)