如何使用QWEBENGINEVIEW在QT6应用程序中使用Flash Display使用Flash Display

发布于 2025-02-04 05:18:59 字数 1086 浏览 5 评论 0原文

使用Pyside6构建一个应用程序闪存网站

我想在Pyside6中

如果将其安装在以下位置之一,则可以自动加载Pepper Flash Player插件,具体取决于平台: 视窗 C:\ Windows \ syswow64 \ macromed \ flash \ pepflashplayer*.dll c:\ windows \ system32 \ macromed \ flash \ flash \ pepflashplayer*.dll

和我安装了ppapi flash 32,并在syswow64 \ macromed \ macromed \ macromed \ macromed \ macromed \ flash \ and system32 \ macromed \ macromed \ flass \ folders

时,pepflashplayer*.dll文件,这只是一个空白页

link to Image

这是我的代码

from PySide6 import QtCore, QtWidgets, QtGui, QtWebEngineWidgets, QtWebEngineCore
import sys

app = QtWidgets.QApplication()

w = QtWidgets.QMainWindow()

central_widget = QtWidgets.QWidget()
w.setCentralWidget(central_widget)

view = QtWebEngineWidgets.QWebEngineView()
view.settings().PluginsEnabled = True
view.load(QtCore.QUrl("https://www.ultrasounds.com/US.html"))

lay = QtWidgets.QGridLayout(central_widget)
lay.addWidget(view)

w.show()
sys.exit(app.exec())

感谢您的帮助。

I want to build an app display flash website with pyside6

in the documentation of pyside6 it is mentioned:

Qt WebEngine supports loading Pepper Plugin API (PPAPI) plugins if WebEngineSettings::pluginsEnabled or QWebEngineSettings::PluginsEnabled is set.

The Pepper Flash player plugin can be loaded automatically if it is installed in one of the following locations, depending on the platform:
Windows
C:\Windows\SysWOW64\Macromed\Flash\pepflashplayer*.dll
C:\Windows\System32\Macromed\Flash\pepflashplayer*.dll

And I installed PPAPI flash 32 and had pepflashplayer*.dll files in SysWOW64\Macromed\Flash\ and System32\Macromed\Flash\ folders

But when i run my app, it's just a blank page

link to image

This is my code

from PySide6 import QtCore, QtWidgets, QtGui, QtWebEngineWidgets, QtWebEngineCore
import sys

app = QtWidgets.QApplication()

w = QtWidgets.QMainWindow()

central_widget = QtWidgets.QWidget()
w.setCentralWidget(central_widget)

view = QtWebEngineWidgets.QWebEngineView()
view.settings().PluginsEnabled = True
view.load(QtCore.QUrl("https://www.ultrasounds.com/US.html"))

lay = QtWidgets.QGridLayout(central_widget)
lay.addWidget(view)

w.show()
sys.exit(app.exec())

Thank for help.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文