summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKatja Marttila <katja.marttila@qt.io>2022-01-26 08:35:50 +0200
committerKatja Marttila <katja.marttila@qt.io>2022-01-31 10:02:27 +0200
commitc23540ea462c5b91f0e41fc8c10e8b7d9a0610bf (patch)
treed6eab8705d470fc49af7ad8f356b50eb2b229909
parentcc975a8fea2ca4bc210518fce68d4fd7018d37bf (diff)
Doc: Update toNativeSeparators/fromNativeSeparators doc
Add information that the predefined variables are not resolved when calling this function. Task-number: QTIFW-2488 Change-Id: Ic6da8323c74c216f09dd54610ee9095d0a32c27c Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Arttu Tarkiainen <arttu.tarkiainen@qt.io>
-rw-r--r--doc/scripting-api/packagemanagercore.qdoc10
-rw-r--r--src/libs/installer/packagemanagercore.cpp10
2 files changed, 20 insertions, 0 deletions
diff --git a/doc/scripting-api/packagemanagercore.qdoc b/doc/scripting-api/packagemanagercore.qdoc
index aba0f6a10..d5b587a72 100644
--- a/doc/scripting-api/packagemanagercore.qdoc
+++ b/doc/scripting-api/packagemanagercore.qdoc
@@ -445,7 +445,12 @@
On Unix platforms the returned string is the same as the argument.
+ \note Predefined variables, such as @TargetDir@, are not resolved by
+ this function. To convert the separators to predefined variables, use
+ \c installer.value() to resolve the variables first.
+
\sa fromNativeSeparators()
+ \sa value()
*/
/*!
@@ -455,7 +460,12 @@
On Unix platforms the returned string is the same as the argument.
+ \note Predefined variables, such as @TargetDir@, are not resolved by
+ this function. To convert the separators to predefined variables, use
+ \c installer.value() to resolve the variables first.
+
\sa toNativeSeparators()
+ \sa value()
*/
/*!
diff --git a/src/libs/installer/packagemanagercore.cpp b/src/libs/installer/packagemanagercore.cpp
index 010a68d21..5e98ea1de 100644
--- a/src/libs/installer/packagemanagercore.cpp
+++ b/src/libs/installer/packagemanagercore.cpp
@@ -1015,8 +1015,13 @@ QString PackageManagerCore::readConsoleLine(const QString &title, qint64 maxlen)
On Unix platforms the returned string is the same as the argument.
+ \note Predefined variables, such as @TargetDir@, are not resolved by
+ this function. To convert the separators to predefined variables, use
+ \c installer.value() to resolve the variables first.
+
\sa {installer::toNativeSeparators}{installer.toNativeSeparators}
\sa fromNativeSeparators()
+ \sa {installer::value}{installer.value}
*/
QString PackageManagerCore::toNativeSeparators(const QString &path)
{
@@ -1028,8 +1033,13 @@ QString PackageManagerCore::toNativeSeparators(const QString &path)
On Unix platforms the returned string is the same as the argument.
+ \note Predefined variables, such as @TargetDir@, are not resolved by
+ this function. To convert the separators to predefined variables, use
+ \c installer.value() to resolve the variables first.
+
\sa {installer::fromNativeSeparators}{installer.fromNativeSeparators}
\sa toNativeSeparators()
+ \sa {installer::value}{installer.value}
*/
QString PackageManagerCore::fromNativeSeparators(const QString &path)
{