qrcodewindow.h 822 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. #ifndef QRCodeWindow_H
  2. #define QRCodeWindow_H
  3. #include <QWidget>
  4. #include <QLabel>
  5. #include <QPushButton>
  6. #include <string>
  7. #include "qrencode.h"
  8. #include "IUserLinkPlayer.h"
  9. #include "EasyConnectLink.h"
  10. using namespace std;
  11. class QRCodeWindow : public QWidget
  12. {
  13. Q_OBJECT
  14. public:
  15. explicit QRCodeWindow(QWidget *parent = nullptr);
  16. void getPlayer(IUserLinkPlayer *player);
  17. protected:
  18. void resizeEvent(QResizeEvent *event);
  19. QPixmap createQRCode(string str);
  20. signals:
  21. void UIChange(bool visible);
  22. public slots:
  23. void onUIChanged(bool visible);
  24. void onClicked();
  25. void onQrcodeInfo(char *qrcode);
  26. private:
  27. QPushButton* m_IosQRCode;
  28. QPushButton* m_AndroidQRCode;
  29. QPushButton* m_Close;
  30. QLabel* m_Label;
  31. IUserLinkPlayer *mPlayer;
  32. };
  33. #endif // QRCodeWindow_H