Make IProjectPanelFactory a value based class

Change-Id: I40f9411f305ab7764b904306bbccd45887dc7432
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
This commit is contained in:
Daniel Teske
2014-07-11 15:20:06 +02:00
parent 96d9f05fad
commit a58325578c
16 changed files with 170 additions and 200 deletions

View File

@@ -38,31 +38,6 @@ using namespace TextEditor;
using namespace ProjectExplorer;
using namespace ProjectExplorer::Internal;
QString CodeStyleSettingsPanelFactory::displayName() const
{
return QCoreApplication::translate("CodeStyleSettingsPanelFactory", "Code Style");
}
int CodeStyleSettingsPanelFactory::priority() const
{
return 40;
}
bool CodeStyleSettingsPanelFactory::supports(Project *project)
{
Q_UNUSED(project);
return true;
}
PropertiesPanel *CodeStyleSettingsPanelFactory::createPanel(Project *project)
{
PropertiesPanel *panel = new PropertiesPanel;
panel->setWidget(new CodeStyleSettingsWidget(project));
panel->setIcon(QIcon(QLatin1String(":/projectexplorer/images/CodeStyleSettings.png")));
panel->setDisplayName(QCoreApplication::translate("CodeStyleSettingsPanel", "Code Style"));
return panel;
}
CodeStyleSettingsWidget::CodeStyleSettingsWidget(Project *project) : QWidget(), m_project(project)
{
m_ui.setupUi(this);