Obsolete Members for QQmlFile
QQmlFile 类的以下成员已被废弃。提供这些成员是为了确保旧的源代码能够继续运行。我们强烈建议在新代码中不要使用它们。
公共类型
(deprecated in 6.11) enum | Status { Null, Ready, Error, Loading } |
公共函数
(deprecated in 6.11) void | clear() |
(deprecated in 6.11) void | clear(QObject *object) |
(deprecated in 6.11) bool | connectDownloadProgress(QObject *object, const char *method) |
(deprecated in 6.11) bool | connectDownloadProgress(QObject *object, int method) |
(deprecated in 6.11) bool | connectFinished(QObject *object, int method) |
(deprecated in 6.11) const char * | data() const |
(deprecated in 6.11) QByteArray | dataByteArray() const |
(deprecated in 6.11) QString | error() const |
(deprecated in 6.11) void | load(QQmlEngine *engine, const QString &url) |
(deprecated in 6.11) void | load(QQmlEngine *engine, const QUrl &url) |
(deprecated in 6.11) qint64 | size() const |
成员类型文档
[deprecated in 6.11] enum QQmlFile::Status
该枚举自 6.11 版本起已弃用。我们强烈建议不要在新代码中使用它。
| 常量 | 值 |
|---|---|
QQmlFile::Null | 0 |
QQmlFile::Ready | 1 |
QQmlFile::Error | 2 |
QQmlFile::Loading | 3 |
成员函数文档
[deprecated in 6.11] void QQmlFile::clear()
自 6.11 版本起,此函数已被废弃。我们强烈建议不要在新代码中使用它。
[deprecated in 6.11] void QQmlFile::clear(QObject *object)
自 6.11 起,此函数已被废弃。我们强烈建议不要在新代码中使用它。
重定向到另一个 clear() 重载方法,并忽略 `object`。
[deprecated in 6.11] bool QQmlFile::connectDownloadProgress(QObject *object, const char *method)
自 6.11 版本起,此函数已被废弃。我们强烈建议不要在新代码中使用它。
将object 的 `method ` 连接到内部信号 `downloadProgress `。
[deprecated in 6.11] bool QQmlFile::connectDownloadProgress(QObject *object, int method)
自 6.11 版本起,此函数已弃用。我们强烈建议不要在新代码中使用它。
将object 的 `method ` 连接到内部信号 `downloadProgress `。
[deprecated in 6.11] bool QQmlFile::connectFinished(QObject *object, int method)
自 6.11 版本起,此函数已被废弃。我们强烈建议在新代码中不要使用它。
将object 的 `method ` 连接到内部信号 `finished `。
[deprecated in 6.11] const char *QQmlFile::data() const
自 6.11 版本起,此函数已被废弃。我们强烈建议不要在新代码中使用它。
[deprecated in 6.11] QByteArray QQmlFile::dataByteArray() const
自 6.11 版本起,此函数已被废弃。我们强烈建议不要在新代码中使用它。
[deprecated in 6.11] QString QQmlFile::error() const
自 6.11 版本起,此函数已被废弃。我们强烈建议不要在新代码中使用它。
[deprecated in 6.11] void QQmlFile::load(QQmlEngine *engine, const QString &url)
自 6.11 版本起,此函数已被废弃。我们强烈建议不要在新代码中使用它。
使用engine 加载url 上的内容。
[deprecated in 6.11] void QQmlFile::load(QQmlEngine *engine, const QUrl &url)
自 6.11 起,此函数已被废弃。我们强烈建议不要在新代码中使用它。
使用engine 加载url 上的内容。
[deprecated in 6.11] qint64 QQmlFile::size() const
自 6.11 版本起,该函数已被废弃。我们强烈建议不要在新代码中使用它。
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.