Commit 9f7725da authored by hjk's avatar hjk

Debugger: Code cosmetics

Namespace, override, re-shuffle.

Change-Id: I6327b032707294b680a5411a652970a5f9b38c75
Reviewed-by: default avatarChristian Stenger <christian.stenger@theqtcompany.com>
parent 3737986a
......@@ -281,34 +281,28 @@ void DebuggerRunControl::abortDebugger()
namespace Internal {
class DebuggerRunControlFactory
: public ProjectExplorer::IRunControlFactory
class DebuggerRunControlFactory : public IRunControlFactory
{
public:
explicit DebuggerRunControlFactory(QObject *parent);
explicit DebuggerRunControlFactory(QObject *parent)
: IRunControlFactory(parent)
{}
ProjectExplorer::RunControl *create(
ProjectExplorer::RunConfiguration *runConfig,
ProjectExplorer::RunMode mode,
QString *errorMessage);
RunControl *create(RunConfiguration *runConfig,
RunMode mode, QString *errorMessage) override;
bool canRun(ProjectExplorer::RunConfiguration *runConfig,
ProjectExplorer::RunMode mode) const;
bool canRun(RunConfiguration *runConfig, RunMode mode) const override
{
return (mode == DebugRunMode || mode == DebugRunModeWithBreakOnMain)
&& qobject_cast<LocalApplicationRunConfiguration *>(runConfig);
}
ProjectExplorer::IRunConfigurationAspect *createRunConfigurationAspect(
ProjectExplorer::RunConfiguration *rc);
IRunConfigurationAspect *createRunConfigurationAspect(RunConfiguration *rc) override
{
return new DebuggerRunConfigurationAspect(rc);
}
};
DebuggerRunControlFactory::DebuggerRunControlFactory(QObject *parent)
: IRunControlFactory(parent)
{}
bool DebuggerRunControlFactory::canRun(RunConfiguration *runConfig, RunMode mode) const
{
return (mode == DebugRunMode || mode == DebugRunModeWithBreakOnMain)
&& qobject_cast<LocalApplicationRunConfiguration *>(runConfig);
}
bool fillParametersFromLocalRunConfiguration
(DebuggerRunParameters *sp, const RunConfiguration *runConfig, QString *errorMessage)
{
......@@ -401,11 +395,6 @@ RunControl *DebuggerRunControlFactory::create
return createDebuggerRunControl(sp, errorMessage);
}
IRunConfigurationAspect *DebuggerRunControlFactory::createRunConfigurationAspect(RunConfiguration *rc)
{
return new DebuggerRunConfigurationAspect(rc);
}
QObject *createDebuggerRunControlFactory(QObject *parent)
{
return new DebuggerRunControlFactory(parent);
......
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