diff options
author | Stijn Buys <ingar@osirion.org> | 2011-08-07 12:14:12 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2011-08-07 12:14:12 +0000 |
commit | 33fabb093ff391dda41b04f6a6634c940e134e9c (patch) | |
tree | 773a549585cc09695687dd70378063859e6597e8 /src/core | |
parent | 219d005ad0643a0b94b3f02de563c9ebd91a2761 (diff) |
Add zone label to the entity info label.
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/parser.cc | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/core/parser.cc b/src/core/parser.cc index 984d403..01d4dba 100644 --- a/src/core/parser.cc +++ b/src/core/parser.cc @@ -50,10 +50,18 @@ bool Parser::got_entity_key(filesystem::IniFile &inifile, core::Entity *entity) Info *info = Info::find(entity->info()); if (!info) { - info = new Info(Entity::infotype(), entity->label().c_str()); + std::string labelstr; + if (entity->zone()) { + labelstr.append(entity->zone()->label()); + labelstr += ':'; + } + labelstr.append(entity->label()); + info = new Info(Entity::infotype(), labelstr.c_str()); entity->set_info(info); } + info->add_text(strval); + return true; } else if (inifile.got_key_label("label", strval)) { |