Commit 7c9c5bda authored by hjk's avatar hjk
Browse files

Debugger: Add variables for compiler and debugger display name



Change-Id: Iee98442317fb1d057ddd7ce7b993124c584660b0
Reviewed-by: default avatarEike Ziller <eike.ziller@theqtcompany.com>
parent 7a69585b
......@@ -308,6 +308,12 @@ void DebuggerKitInformation::addToMacroExpander(Kit *kit, MacroExpander *expande
const DebuggerItem *item = debugger(kit);
return item ? item->engineTypeName() : tr("unknown");
});
// FIXME: Use better strings.
expander->registerVariable("Debugger:Name", tr("Debugger"),
[this, kit]() -> QString {
const DebuggerItem *item = debugger(kit);
return item ? item->displayName() : tr("unknown");
});
}
KitInformation::ItemList DebuggerKitInformation::toUserOutput(const Kit *k) const
......
......@@ -208,6 +208,17 @@ void ToolChainKitInformation::addToEnvironment(const Kit *k, Utils::Environment
tc->addToEnvironment(env);
}
void ToolChainKitInformation::addToMacroExpander(Kit *kit, Utils::MacroExpander *expander) const
{
// FIXME: Use better strings
expander->registerVariable("Compiler:Name", tr("Compiler"),
[this, kit]() -> QString {
const ToolChain *tc = toolChain(kit);
return tc ? tc->displayName() : tr("None");
});
}
IOutputParser *ToolChainKitInformation::createOutputParser(const Kit *k) const
{
ToolChain *tc = toolChain(k);
......
......@@ -93,6 +93,7 @@ public:
ItemList toUserOutput(const Kit *k) const;
void addToEnvironment(const Kit *k, Utils::Environment &env) const;
void addToMacroExpander(Kit *kit, Utils::MacroExpander *expander) const;
IOutputParser *createOutputParser(const Kit *k) const;
static Core::Id id();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment