diff options
author | Arttu Tarkiainen <arttu.tarkiainen@qt.io> | 2021-11-23 17:23:26 +0200 |
---|---|---|
committer | Arttu Tarkiainen <arttu.tarkiainen@qt.io> | 2022-01-06 11:26:29 +0200 |
commit | 403e610e6b867dc840c4e78a344cac52bbe751c2 (patch) | |
tree | 746f263da474c1603ce14820d164cd37c97e95bc /src/libs/installer/packagemanagercore_p.cpp | |
parent | 8985801a4e61fad34914ed04480d0240ece53c15 (diff) |
Add support for moving child components with <TreeName>
Add new optional "moveChildren" attribute to <TreeName> element.
Children of components declaring "moveChildren=true" attribute are
calculated a value for an automatic tree name element.
Multiple components in a single tree branch can declare a
tree name, the order which the relocation happens is from leaf
components to root components.
Components may be moved under another tree name target.
Components may be moved to an existing identifier part that
does not have a component, for example in the following
repository structure:
rootA.childA
rootB
rootB.childB
the "rootB" component can legally declare a "rootA" tree name.
The tree names of components become static after installed. If
a repository declares a new tree name for a component that is
installed, it is only applied after updating in maintenance tool.
Child components, which have an automatic tree name, are moved if
the parent component is updated with a new tree name, however.
Task-number: QTIFW-2380
Change-Id: I9c44a114d3c1248b7e2dd4f0b5cda0739af102f3
Reviewed-by: Katja Marttila <katja.marttila@qt.io>
Diffstat (limited to 'src/libs/installer/packagemanagercore_p.cpp')
-rw-r--r-- | src/libs/installer/packagemanagercore_p.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libs/installer/packagemanagercore_p.cpp b/src/libs/installer/packagemanagercore_p.cpp index 058418f8e..948093ad7 100644 --- a/src/libs/installer/packagemanagercore_p.cpp +++ b/src/libs/installer/packagemanagercore_p.cpp @@ -2244,7 +2244,8 @@ void PackageManagerCorePrivate::installComponent(Component *component, double pr m_localPackageHub->addPackage(component->name(), component->value(scVersion), component->value(scDisplayName), - component->value(scTreeName), + QPair<QString, bool>(component->value(scTreeName), + component->treeNameMoveChildren()), component->value(scDescription), component->dependencies(), component->autoDependencies(), |