EXProjectView.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. #ifndef EXPROJECTVIEW_H
  2. #define EXPROJECTVIEW_H
  3. #include <QWidget>
  4. class ProjectInfo;
  5. class EXIndexView;
  6. class EXDataView;
  7. class QPushButton;
  8. class TreeWidget;
  9. class QVBoxLayout;
  10. class QHBoxLayout;
  11. class QLabel;
  12. class QTreeWidgetItem;
  13. class QStackedWidget;
  14. class EXProjectView : public QWidget
  15. {
  16. Q_OBJECT
  17. public:
  18. explicit EXProjectView(ProjectInfo *proj, QWidget *parent = nullptr);
  19. void showEvent(QShowEvent *event) override;
  20. void hideEvent(QHideEvent *event) override;
  21. ProjectInfo *proj() const;
  22. void showEvalWidget(int eval, int task);
  23. private:
  24. void initWidgets();
  25. void initLayout();
  26. void connectSigalsAndSlots();
  27. private slots:
  28. void itemClicked(QTreeWidgetItem *item, int column);
  29. void slotCompleteStateChanged(bool complete);
  30. private:
  31. ProjectInfo *m_proj = nullptr;
  32. QVBoxLayout *m_layout = nullptr;
  33. QHBoxLayout *m_headerLayout = nullptr;
  34. QHBoxLayout *m_contentLayout = nullptr;
  35. QLabel *m_title = nullptr;
  36. TreeWidget *m_tree = nullptr;
  37. QWidget *m_seperator = nullptr;
  38. QStackedWidget *m_stack = nullptr;
  39. EXIndexView *m_indexSystem = nullptr;
  40. EXDataView *m_dataCollection = nullptr;
  41. QPushButton *m_export = nullptr;
  42. QPushButton *m_user = nullptr;
  43. };
  44. #endif // EXPROJECTVIEW_H