我想在播放youTube视频时在WKWebView的导航栏上添加按钮。
当WKWebView成功加载YouTube视频时,会显示一个红色按钮供用户点击查看。
单击此红色按钮时,它将展开并覆盖整个屏幕。
在屏幕的顶栏或导航栏中,有一些按钮:a)X btn要关闭,b)展开垂直btn 3)声音btn。
The Problem:
I want to a button on this bar which contain the above 3 buttons.
I did the following but it didnot work.
I embed a WKWebView in the UiViewController and I add the following code in viewDidLoad:
let webViewConfiguration = WKWebViewConfiguration()
webViewConfiguration.allowsInlineMediaPlayback = true
let leftBtn = UIBarButtonItem(barButtonSystemItem: .add, target: self, action: #selector(addTapped))
navigationItem.leftBarButtonItem = leftBtn
请帮忙。
由于