Skip to content

Commit

Permalink
feat: add iOS AudioPlayer from Nota fork
Browse files Browse the repository at this point in the history
  • Loading branch information
ddfreiling committed Aug 21, 2023
1 parent aaa259f commit 178ba14
Show file tree
Hide file tree
Showing 35 changed files with 4,004 additions and 0 deletions.
Empty file added ios/Assets/.gitkeep
Empty file.
19 changes: 19 additions & 0 deletions ios/Classes/FlutterAudioPlayerPlugin.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import Flutter
import UIKit

public class FlutterAudioPlayerPlugin: NSObject, FlutterPlugin {
public static func register(with registrar: FlutterPluginRegistrar) {
let channel = FlutterMethodChannel(name: "flutter_audio_player", binaryMessenger: registrar.messenger())
let instance = FlutterAudioPlayerPlugin()
registrar.addMethodCallDelegate(instance, channel: channel)
}

public func handle(_ call: FlutterMethodCall, result: @escaping FlutterResult) {
switch call.method {
case "getPlatformVersion":
result("iOS " + UIDevice.current.systemVersion)
default:
result(FlutterMethodNotImplemented)
}
}
}
Loading

0 comments on commit 178ba14

Please sign in to comment.