You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

67 lines
1.7 KiB

​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. #ifndef __ONVIF_SOURCE_CHOOSER_WIDGET_HEADER__
  2. #define __ONVIF_SOURCE_CHOOSER_WIDGET_HEADER__
  3. #ifdef __linux__
  4. #include <QDialog>
  5. #else
  6. #include "../gui.h"
  7. #endif
  8. //#include "../../data/protocol/onvifDeviceNode.h"
  9. #include "../../data/protocol/onvifMediaObserver.h"
  10. #include "../controls/VideoThumbWidget.h"
  11. #include "../../data/media/video/videoAVLIBSource.h"
  12. class guiAddSourceDialog;
  13. class OnvifClientDevice;
  14. class OnvifSourceFinderDialog : public QDialog {
  15. private:
  16. onvifMediaObserver *m_pOnvifObserver;
  17. OnvifClientDevice *m_pDeviceNode;
  18. guiAddSourceDialog *m_pParentDialog;
  19. char m_pSelectedProfileToken[256];
  20. char m_pSelectedVideoMRL[MAX_PATH_LEN];
  21. char m_pSelectedPictureMRL[MAX_PATH_LEN];
  22. /* GUI */
  23. QHBoxLayout *m_pHL;
  24. QVBoxLayout *m_pVL1;
  25. QVBoxLayout *m_pVL2;
  26. QTreeWidget *m_pTreeWidget;
  27. QTableWidget *m_pTableWidget;
  28. QProgressBar *m_pProgressBar;
  29. QListWidget *m_pProfileslist;
  30. QLineEdit *m_pTxtLogin;
  31. QLineEdit *m_pTxtPassword;
  32. QPushButton *m_pButtonCmdConnect;
  33. QPushButton *m_pButtonCmdSearch;
  34. QSpacerItem *m_pVSpacer;
  35. QPushButton *m_pButtonCmdUseProfile;
  36. QTimer *m_pTimer;
  37. char m_pDevURL[MAX_PATH_LEN];
  38. int m_nSelectedProfile;
  39. public:
  40. explicit OnvifSourceFinderDialog( guiAddSourceDialog *parent = NULL );
  41. ~OnvifSourceFinderDialog();
  42. public slots:
  43. void connectToSelectedSource();
  44. void startDevicesDiscovery();
  45. void startAskDevice();
  46. void updateProgress();
  47. void treeItemClicked(QTreeWidgetItem *item,int column);
  48. void listItemClicked(QListWidgetItem *item);
  49. void listItemDblClicked(QListWidgetItem *item);
  50. void startPrevewNetStream(void);
  51. void useSelectedProfile(void);
  52. };
  53. #endif