summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKarsten Heimrich <karsten.heimrich@theqtcompany.com>2015-05-27 14:22:44 +0200
committerKarsten Heimrich <karsten.heimrich@theqtcompany.com>2015-05-27 14:27:11 +0000
commita050b55190c4f83255be09416e79debd0772a4fd (patch)
tree5e76fef2fa24ab9ca17d99cc952ee9fd76db05e2
parentf54359d6351d695908ff6ecdbf60a27570bc518d (diff)
Fix missing details output in example.
Commit 17e29fc8d3 introduced a behavior change, the installer.components is no longer a array property, it is now a function returning an array. Update docs. Change-Id: I4fcdee6cff4572012236e1ac0768013a1e5689ac Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com> Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
-rw-r--r--doc/scripting-api/packagemanagercore.qdoc6
-rw-r--r--examples/dynamicpage/packages/org.qtproject.ifw.example.dynamicpage/meta/installscript.js7
2 files changed, 9 insertions, 4 deletions
diff --git a/doc/scripting-api/packagemanagercore.qdoc b/doc/scripting-api/packagemanagercore.qdoc
index 817f43b8a..c65ddce58 100644
--- a/doc/scripting-api/packagemanagercore.qdoc
+++ b/doc/scripting-api/packagemanagercore.qdoc
@@ -33,7 +33,11 @@
*/
/*!
- \qmlproperty array installer::components
+ \qmlmethod array installer::components()
+
+ Returns an array of all available components.
+
+ \sa component
*/
/*!
diff --git a/examples/dynamicpage/packages/org.qtproject.ifw.example.dynamicpage/meta/installscript.js b/examples/dynamicpage/packages/org.qtproject.ifw.example.dynamicpage/meta/installscript.js
index 66fc7de18..8b7da2dd0 100644
--- a/examples/dynamicpage/packages/org.qtproject.ifw.example.dynamicpage/meta/installscript.js
+++ b/examples/dynamicpage/packages/org.qtproject.ifw.example.dynamicpage/meta/installscript.js
@@ -162,9 +162,10 @@ Component.prototype.readyToInstallWidgetEntered = function () {
var widget = gui.pageWidgetByObjectName("DynamicReadyToInstallWidget");
if (widget != null) {
var html = "<b>Components to install:</b><ul>";
- for (i = 0; i < installer.components.length; ++i) {
- if (installer.components[i].installationRequested())
- html = html + "<li>" + installer.components[i].displayName + "</li>"
+ var components = installer.components();
+ for (i = 0; i < components.length; ++i) {
+ if (components[i].installationRequested())
+ html = html + "<li>" + components[i].displayName + "</li>"
}
html = html + "</ul>";
widget.showDetailsBrowser.html = html;