sculpt: expose unique name as 'Component' constant

This commit is contained in:
Norman Feske 2023-03-23 15:08:50 +01:00 committed by Christian Helmuth
parent 3a99deef5a
commit a351b0c164
2 changed files with 5 additions and 4 deletions

View File

@ -32,6 +32,7 @@ struct Sculpt::Component : Noncopyable
Allocator &_alloc;
/* defined at construction time */
Name const name;
Path const path;
Info const info;
@ -120,10 +121,10 @@ struct Sculpt::Component : Noncopyable
virtual void trigger_pkg_download() = 0;
};
Component(Allocator &alloc, Path const &path, Info const &info,
Affinity::Space const space)
Component(Allocator &alloc, Name const &name, Path const &path,
Info const &info, Affinity::Space const space)
:
_alloc(alloc), path(path), info(info), affinity_space(space)
_alloc(alloc), name(name), path(path), info(info), affinity_space(space)
{ }
~Component()

View File

@ -162,7 +162,7 @@ class Sculpt::Runtime_state : public Runtime_info
:
name(name), launcher(), launched(false)
{
construction.construct(alloc, pkg_path, info, space);
construction.construct(alloc, name, pkg_path, info, space);
}
void gen_deploy_start_node(Xml_generator &xml, Runtime_state const &state) const