2012-10-02 09:12:39 +02:00
|
|
|
/****************************************************************************
|
2009-11-26 18:03:16 +01:00
|
|
|
**
|
2014-01-07 13:27:11 +01:00
|
|
|
** Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies).
|
2012-10-02 09:12:39 +02:00
|
|
|
** Contact: http://www.qt-project.org/legal
|
2009-11-26 18:03:16 +01:00
|
|
|
**
|
2012-10-02 09:12:39 +02:00
|
|
|
** This file is part of Qt Creator.
|
2009-11-26 18:03:16 +01:00
|
|
|
**
|
2012-10-02 09:12:39 +02:00
|
|
|
** Commercial License Usage
|
|
|
|
|
** Licensees holding valid commercial Qt licenses may use this file in
|
|
|
|
|
** accordance with the commercial license agreement provided with the
|
|
|
|
|
** Software or, alternatively, in accordance with the terms contained in
|
|
|
|
|
** a written agreement between you and Digia. For licensing terms and
|
|
|
|
|
** conditions see http://qt.digia.com/licensing. For further information
|
|
|
|
|
** use the contact form at http://qt.digia.com/contact-us.
|
2009-11-26 18:03:16 +01:00
|
|
|
**
|
|
|
|
|
** GNU Lesser General Public License Usage
|
2012-10-02 09:12:39 +02:00
|
|
|
** Alternatively, this file may be used under the terms of the GNU Lesser
|
|
|
|
|
** General Public License version 2.1 as published by the Free Software
|
|
|
|
|
** Foundation and appearing in the file LICENSE.LGPL included in the
|
|
|
|
|
** packaging of this file. Please review the following information to
|
|
|
|
|
** ensure the GNU Lesser General Public License version 2.1 requirements
|
|
|
|
|
** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
|
|
|
|
|
**
|
|
|
|
|
** In addition, as a special exception, Digia gives you certain additional
|
|
|
|
|
** rights. These rights are described in the Digia Qt LGPL Exception
|
2010-12-17 16:01:08 +01:00
|
|
|
** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
|
|
|
|
|
**
|
2012-10-02 09:12:39 +02:00
|
|
|
****************************************************************************/
|
2009-11-26 18:03:16 +01:00
|
|
|
|
|
|
|
|
#ifndef BASEPROJECTWIZARDDIALOG_H
|
|
|
|
|
#define BASEPROJECTWIZARDDIALOG_H
|
|
|
|
|
|
|
|
|
|
#include "projectexplorer_export.h"
|
2014-05-27 13:18:05 +02:00
|
|
|
|
|
|
|
|
#include <coreplugin/basefilewizard.h>
|
2014-05-26 16:58:50 +02:00
|
|
|
#include <coreplugin/basefilewizardfactory.h>
|
2009-11-26 18:03:16 +01:00
|
|
|
|
2014-02-11 21:55:42 +02:00
|
|
|
namespace Utils { class ProjectIntroPage; }
|
2009-11-26 18:03:16 +01:00
|
|
|
|
|
|
|
|
namespace ProjectExplorer {
|
|
|
|
|
|
|
|
|
|
struct BaseProjectWizardDialogPrivate;
|
|
|
|
|
|
2011-04-14 12:58:14 +02:00
|
|
|
// Documentation inside.
|
2014-05-27 13:18:05 +02:00
|
|
|
class PROJECTEXPLORER_EXPORT BaseProjectWizardDialog : public Core::BaseFileWizard
|
2009-11-26 18:03:16 +01:00
|
|
|
{
|
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
|
|
protected:
|
2014-05-27 13:18:05 +02:00
|
|
|
explicit BaseProjectWizardDialog(Utils::ProjectIntroPage *introPage, int introId,
|
2012-02-03 18:00:08 +01:00
|
|
|
QWidget *parent, const Core::WizardDialogParameters ¶meters);
|
2009-11-26 18:03:16 +01:00
|
|
|
|
|
|
|
|
public:
|
2012-02-03 18:00:08 +01:00
|
|
|
explicit BaseProjectWizardDialog(QWidget *parent, const Core::WizardDialogParameters ¶meters);
|
2010-03-12 11:20:32 +01:00
|
|
|
|
2009-11-26 18:03:16 +01:00
|
|
|
virtual ~BaseProjectWizardDialog();
|
|
|
|
|
|
2010-01-07 18:17:24 +01:00
|
|
|
QString projectName() const;
|
2009-11-26 18:03:16 +01:00
|
|
|
QString path() const;
|
|
|
|
|
|
|
|
|
|
// Generate a new project name (untitled<n>) in path.
|
2010-01-07 18:17:24 +01:00
|
|
|
static QString uniqueProjectName(const QString &path);
|
2012-02-14 15:21:21 +01:00
|
|
|
void addExtensionPages(const QList<QWizardPage *> &wizardPageList);
|
2009-11-26 18:03:16 +01:00
|
|
|
|
|
|
|
|
public slots:
|
|
|
|
|
void setIntroDescription(const QString &d);
|
|
|
|
|
void setPath(const QString &path);
|
2010-01-07 18:17:24 +01:00
|
|
|
void setProjectName(const QString &name);
|
2012-04-13 16:37:48 +02:00
|
|
|
void setProjectList(const QStringList &projectList);
|
|
|
|
|
void setProjectDirectories(const QStringList &directories);
|
|
|
|
|
void setForceSubProject(bool force);
|
2009-11-26 18:03:16 +01:00
|
|
|
|
2010-03-22 15:33:33 +01:00
|
|
|
signals:
|
2010-10-27 12:51:33 +02:00
|
|
|
void projectParametersChanged(const QString &projectName, const QString &path);
|
2010-03-22 15:33:33 +01:00
|
|
|
|
2009-11-26 18:03:16 +01:00
|
|
|
protected:
|
|
|
|
|
Utils::ProjectIntroPage *introPage() const;
|
2012-02-08 17:25:35 +01:00
|
|
|
QString selectedPlatform() const;
|
|
|
|
|
void setSelectedPlatform(const QString &platform);
|
|
|
|
|
|
|
|
|
|
Core::FeatureSet requiredFeatures() const;
|
|
|
|
|
void setRequiredFeatures(const Core::FeatureSet &featureSet);
|
2009-11-26 18:03:16 +01:00
|
|
|
|
|
|
|
|
private slots:
|
|
|
|
|
void slotAccepted();
|
2010-10-27 12:51:33 +02:00
|
|
|
void nextClicked();
|
2009-11-26 18:03:16 +01:00
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
void init();
|
|
|
|
|
|
|
|
|
|
BaseProjectWizardDialogPrivate *d;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
} // namespace ProjectExplorer
|
|
|
|
|
|
|
|
|
|
#endif // BASEPROJECTWIZARDDIALOG_H
|