diff options
author | Shawn Rutledge <[email protected]> | 2025-04-23 19:53:28 +0200 |
---|---|---|
committer | Shawn Rutledge <[email protected]> | 2025-04-25 15:08:14 +0200 |
commit | 81b21b475d20083a95f0d173c7f4086745bec219 (patch) | |
tree | 1702fc8822ab625f0f2a267deda6ee6b9a7578c4 | |
parent | 2f2b2669a53d9b6faed680759f6b68ef8c6e66ce (diff) |
Fix warning text in QQuickTextDocument::setSource()
The warning suggested calling TextEdit.clear() before loading a
different url if the text is modified, but that actually doesn't work.
But as the `source` property docs say, it's possible to set
`modified = false`.
Pick-to: 6.9 6.8
Change-Id: Ia078269c76be141adb06303163a661927f125bcd
Reviewed-by: Oliver Eftevaag <[email protected]>
-rw-r--r-- | src/quick/items/qquicktextdocument.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/quick/items/qquicktextdocument.cpp b/src/quick/items/qquicktextdocument.cpp index aefacc6ed9..d11bae5919 100644 --- a/src/quick/items/qquicktextdocument.cpp +++ b/src/quick/items/qquicktextdocument.cpp @@ -240,7 +240,7 @@ void QQuickTextDocument::setSource(const QUrl &url) if (isModified()) { qmlWarning(this) << "Existing document modified: you should save()," - "or call TextEdit.clear() before setting a different source"; + " or set modified=false before setting a different source"; return; } |