PYQT 6:当设备连接/与Internet连接/断开连接时,是否有任何具有信号的类?
我将下载功能添加到我正在创建的应用程序中。当下载过程中丢失了用户设备的Internet连接时,我希望下载一旦连接重新建立,我希望继续下载;当然,如果应用程序仍在运行。我该怎么做?看来曾经有一个qtnetwork.qnetworksession()。statechanged
信号可以用于执行此操作,但在QT6中进行了弃用,我似乎找不到它的替代方法。
I'm adding a download function to an application that I'm creating. When the user's device's internet connection is lost during a download, I want the download to continue on once the connection is re-established; provided that the application is still running, of course. How can I do this? It appears that there used to be a QtNetwork.QNetworkSession().stateChanged
signal that could be used to do this but it's deprecated in Qt6 and I can't seem to find an alternative to it.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论