我知道这个话题已经讨论过了,但是我花了半天时间来弄清楚我做错了什么。我一直有这个错误,我想我已经做了数千次语法检查。谁能帮我?
#ifndef ADDEDITDIALOG_H
#define ADDEDITDIALOG_H
#include <QDialog>
#include <QStandardItemModel>
#include "characteristics.h"
#include "equipment.h"
#include "generaldata.h"
#include "registration.h"
#include "revisiondialog.h"
#include "vehicle.h"
#include "vehiclehelper.h"
#include "verification.h"
#include "verificationdialog.h"
namespace Ui {
class AddEditDialog;
}
class AddEditDialog : public QDialog
{
Q_OBJECT
public:
explicit AddEditDialog(QWidget *parent = 0);
~AddEditDialog();
bool getIsNew() const;
bool getIsEdited() const;
bool getAddRevision() const;
Vehicle getVehicleToAdd() const;
void setVehicleToAdd();
void loadVehicleToEdit(Vehicle car);
void createTableView(const QList<Verification> list);
QList<Verification> getRevisionsList() const;
private slots:
void on_add_revision_clicked();
void on_save_clicked();
void on_cancel_clicked();
void on_generate_reg_number_clicked();
private:
Ui::AddEditDialog *ui;
RevisionDialog *newDialog; //this line is giving the error
Vehicle toAdd;
bool isNew;
bool isEdited;
bool addRevision;
QList<Verification> newVerificationList;
QStandardItemModel *newModel;
};
#endif // ADDEDITDIALOG_H
修订对话框.h
#ifndef REVISIONDIALOG_H
#define REVISIONDIALOG_H
#include <QDialog>
#include "addeditdialog.h"
#include "verification.h"
namespace Ui {
class RevisionDialog;
}
class RevisionDialog : public QDialog
{
Q_OBJECT
public:
explicit RevisionDialog(QWidget *parent = 0);
~RevisionDialog();
void setRevision();
void setRevisionsList();
Verification getRevision() const;
bool getOk() const;
private slots:
void on_ok_revision_clicked();
void on_cancel_revision_clicked();
private:
Ui::RevisionDialog *ui;
QList<Verification> revisionsList;
Verification revision;
bool okClicked;
};
#endif // REVISIONDIALOG_H