Commit 264b833f authored by Tobias Hunger's avatar Tobias Hunger

VcsBase: Rename CheckoutWizardDialog to BaseCheckoutWizard

Change-Id: I4e2729e7e0f0a15d4943099cd7f02824f3dc43d2
Reviewed-by: Orgad Shaneh's avatarOrgad Shaneh <orgads@gmail.com>
parent b4965ba0
......@@ -68,7 +68,7 @@ public:
BaseCheckoutWizardPrivate() : dialog(0) {}
void clear();
CheckoutWizardDialog *dialog;
BaseCheckoutWizard *dialog;
QList<QWizardPage *> parameterPages;
QString checkoutPath;
QString progressTitle;
......@@ -106,7 +106,7 @@ void BaseCheckoutWizardFactory::runWizard(const QString &path, QWidget *parent,
Q_UNUSED(extraValues);
// Create dialog and launch
d->parameterPages = createParameterPages(path);
CheckoutWizardDialog dialog(d->parameterPages, parent);
BaseCheckoutWizard dialog(d->parameterPages, parent);
if (!d->progressTitle.isEmpty())
dialog.setTitle(d->progressTitle);
if (!d->startedStatus.isEmpty())
......
......@@ -44,7 +44,7 @@
namespace VcsBase {
CheckoutWizardDialog::CheckoutWizardDialog(const QList<QWizardPage *> &parameterPages,
BaseCheckoutWizard::BaseCheckoutWizard(const QList<QWizardPage *> &parameterPages,
QWidget *parent) :
Utils::Wizard(parent),
m_progressPage(new Internal::CheckoutProgressWizardPage),
......@@ -58,37 +58,37 @@ CheckoutWizardDialog::CheckoutWizardDialog(const QList<QWizardPage *> &parameter
connect(m_progressPage, SIGNAL(terminated(bool)), this, SLOT(slotTerminated(bool)));
}
void CheckoutWizardDialog::setTitle(const QString &title)
void BaseCheckoutWizard::setTitle(const QString &title)
{
m_progressPage->setTitle(title);
}
void CheckoutWizardDialog::setStartedStatus(const QString &title)
void BaseCheckoutWizard::setStartedStatus(const QString &title)
{
m_progressPage->setStartedStatus(title);
}
void CheckoutWizardDialog::slotPageChanged(int id)
void BaseCheckoutWizard::slotPageChanged(int id)
{
if (id == m_progressPageId)
emit progressPageShown();
}
void CheckoutWizardDialog::slotTerminated(bool success)
void BaseCheckoutWizard::slotTerminated(bool success)
{
// Allow to correct parameters
if (!success)
button(QWizard::BackButton)->setEnabled(true);
}
void CheckoutWizardDialog::start(Command *command)
void BaseCheckoutWizard::start(Command *command)
{
// No "back" available while running.
button(QWizard::BackButton)->setEnabled(false);
m_progressPage->start(command);
}
void CheckoutWizardDialog::reject()
void BaseCheckoutWizard::reject()
{
// First click kills, 2nd closes
if (currentId() == m_progressPageId && m_progressPage->isRunning())
......
......@@ -27,8 +27,8 @@
**
****************************************************************************/
#ifndef CHECKOUTWIZARDDIALOG_H
#define CHECKOUTWIZARDDIALOG_H
#ifndef BASECHECKOUTWIZARD_H
#define BASECHECKOUTWIZARD_H
#include "vcsbase_global.h"
......@@ -40,12 +40,12 @@ class Command;
namespace Internal { class CheckoutProgressWizardPage; }
class VCSBASE_EXPORT CheckoutWizardDialog : public Utils::Wizard
class VCSBASE_EXPORT BaseCheckoutWizard : public Utils::Wizard
{
Q_OBJECT
public:
explicit CheckoutWizardDialog(const QList<QWizardPage *> &parameterPages,
explicit BaseCheckoutWizard(const QList<QWizardPage *> &parameterPages,
QWidget *parent = 0);
void setTitle(const QString &title);
......@@ -67,4 +67,4 @@ private:
} // namespace VcsBase
#endif // CHECKOUTWIZARDDIALOG_H
#endif // BASECHECKOUTWIZARD_H
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