我正在尝试使用 QML 和 WebEngineView 组件为 Ubuntu 14.04 的桌面制作一个简单的网络浏览器。该应用程序将在带有触摸板的设备上运行,因此最好使 WebEngineView 中显示的内容可滑动。
我试图这样做,但它不起作用:
...
WebEngineView {
id: webView
url: "http://google.com"
width: parent.width
height: winternet.height-navigationBar.height-iStatusBar.height-iBackButton.height
anchors.top: navigationBar.bottom
MouseArea {
anchors.fill: parent
drag.target: parent.data
}
onLinkHovered: {
webView.url = hoveredUrl
}
}
...
Run Code Online (Sandbox Code Playgroud)
如果您对此有任何想法或经验,请提供帮助!