ProjectExplorer: Introduce priorities for RunControlFactories

This can be used by downstream plugins to overrule existing
RunControlFactories.

Change-Id: I23c8e3983827dfa1b5f780664d2e539e908944aa
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
hjk
2017-06-26 12:57:33 +02:00
parent a72b38b8c9
commit e974f0733e
3 changed files with 26 additions and 1 deletions

View File

@@ -501,6 +501,19 @@ IRunConfigurationAspect *IRunControlFactory::createRunConfigurationAspect(RunCon
than it needs to be.
*/
const char PRIORITY_KEY[] = "RunControlFactoryPriority";
int ProjectExplorer::IRunControlFactory::priority() const
{
return property(PRIORITY_KEY).toInt(); // 0 by default.
}
void IRunControlFactory::setPriority(int priority)
{
setProperty(PRIORITY_KEY, priority);
}
namespace Internal {
class RunControlPrivate