awQuestionNavigate.h 856 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. #ifndef AWQUESTIONNAVIGATE_H
  2. #define AWQUESTIONNAVIGATE_H
  3. #include <QWidget>
  4. #include "CHttpBll.h"
  5. #include "awqn_item.h"
  6. namespace Ui {
  7. class awQuestionNavigate;
  8. }
  9. enum class ITEM_SHOW_TYPE
  10. {
  11. ist_showAll = 1,
  12. ist_showMarked,
  13. ist_showAnswered,
  14. ist_showUnanswered
  15. };
  16. class awQuestionNavigate : public QWidget
  17. {
  18. Q_OBJECT
  19. signals:
  20. void showSubQuestion(QString sQuestionId, int nOrder, bool bHasContent);
  21. public:
  22. explicit awQuestionNavigate(CPaperGroupStruct &pgs, QWidget *parent = nullptr);
  23. ~awQuestionNavigate();
  24. int setUI(const int nWidth);
  25. void refreshStatus();
  26. int setShowType(ITEM_SHOW_TYPE type);
  27. private:
  28. int showItems(std::vector<awqn_item*> vItemList);
  29. Ui::awQuestionNavigate *ui;
  30. CPaperGroupStruct &m_pgs;
  31. std::vector<awqn_item*> m_vItemList;
  32. };
  33. #endif // AWQUESTIONNAVIGATE_H