feat: add playback gain methods to all platforms
This commit is contained in:
parent
7608d79d64
commit
5a547958d5
7 changed files with 75 additions and 0 deletions
|
|
@ -244,6 +244,23 @@ public class LiblinphoneFlutterPlugin: NSObject, FlutterPlugin {
|
|||
case "getMicGain":
|
||||
result(linphoneBridge.getMicGain())
|
||||
|
||||
case "setPlaybackGain":
|
||||
guard let args = call.arguments as? [String: Any],
|
||||
let level = args["level"] as? String else {
|
||||
result(FlutterError(
|
||||
code: "INVALID_ARGUMENTS",
|
||||
message: "Missing required arguments",
|
||||
details: nil
|
||||
))
|
||||
return
|
||||
}
|
||||
|
||||
linphoneBridge.setPlaybackGain(level: level)
|
||||
result(success)
|
||||
|
||||
case "getPlaybackGain":
|
||||
result(linphoneBridge.getPlaybackGain())
|
||||
|
||||
default:
|
||||
result(FlutterMethodNotImplemented)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue