MythTV  master
proglist_helpers.h
Go to the documentation of this file.
1 #ifndef _PROGLIST_HELPERS_H_
2 #define _PROGLIST_HELPERS_H_
3 
4 #include <utility>
5 
6 // Qt headers
7 #include <QDateTime>
8 
9 // MythTV headers
10 #include "mythscreentype.h"
11 #include "recordingtypes.h"
12 
13 class MythUIText;
14 class MythUIButtonList;
15 class ProgLister;
16 
18 {
19  Q_OBJECT
20 
21  public:
23  ProgLister *parent,
24  RecSearchType searchType,
25  QStringList list,
26  QString currentValue)
27  : MythScreenType(parentStack, "phrasepopup"),
28  m_parent(parent), m_searchType(searchType),
29  m_list(std::move(list)),
30  m_currentValue(std::move(currentValue)) {}
31 
32  bool Create() override; // MythScreenType
33 
34  signals:
35  void haveResult(QString item);
36 
37  private slots:
38  void okClicked(void);
39  void deleteClicked(void);
40  void recordClicked(void);
43  void editChanged(void);
44 
45  private:
46  ProgLister *m_parent {nullptr};
48  QStringList m_list;
49  QString m_currentValue;
50 
51  MythUIText *m_titleText {nullptr};
57 };
58 
60 {
61  Q_OBJECT
62 
63  public:
65  ProgLister *parent,
66  RecSearchType searchType,
67  QStringList list,
68  QString currentValue)
69  : MythScreenType(parentStack, "phrasepopup"),
70  m_parent(parent), m_searchType(searchType),
71  m_list(std::move(list)),
72  m_currentValue(std::move(currentValue)) {}
73 
74  bool Create() override; // MythScreenType
75 
76  signals:
77  void haveResult(QString item);
78 
79  private slots:
80  void editClicked(void);
81  void deleteClicked(void);
82  void recordClicked(void);
85 
86  private:
87  ProgLister *m_parent {nullptr};
89  QStringList m_list;
90  QString m_currentValue;
91 
92  MythUIText *m_titleText {nullptr};
98 };
99 
101 {
102  Q_OBJECT
103 
104  public:
105  EditPowerSearchPopup(MythScreenStack *parentStack, ProgLister *parent,
106  const QString &currentValue);
107 
108  bool Create() override; // MythScreenType
109 
110  private slots:
111  void okClicked(void);
112 
113  private:
114  void initLists(void);
115 
116  ProgLister *m_parent {nullptr};
117  QStringList m_categories;
118  QStringList m_genres;
119  QStringList m_channels;
120 
121  QString m_currentValue;
122 
129 
131 };
132 
133 #endif // _PROGLIST_HELPERS_H_
void phraseSelected(MythUIButtonListItem *item)
unsigned int slots[4]
Definition: element.c:38
void haveResult(QString item)
ProgLister * m_parent
QStringList m_list
MythUITextEdit * m_subtitleEdit
RecSearchType m_searchType
MythUIButton * m_recordButton
All purpose text widget, displays a text string.
Definition: mythuitext.h:28
MythUIButton * m_okButton
MythUITextEdit * m_descEdit
void phraseClicked(MythUIButtonListItem *item)
void phraseSelected(MythUIButtonListItem *item)
MythUIText * m_titleText
void haveResult(QString item)
MythUITextEdit * m_phraseEdit
RecSearchType m_searchType
bool Create() override
QString m_currentValue
void recordClicked(void)
MythUIButtonList * m_channelList
PhrasePopup(MythScreenStack *parentStack, ProgLister *parent, RecSearchType searchType, QStringList list, QString currentValue)
MythUIText * m_titleText
MythUIButtonList * m_genreList
bool Create() override
A text entry and edit widget.
QStringList m_list
MythUITextEdit * m_titleEdit
RecSearchType
MythUITextEdit * m_phraseEdit
MythUIButton * m_okButton
List widget, displays list items in a variety of themeable arrangements and can trigger signals when ...
MythUIButton * m_recordButton
MythUIButtonList * m_phraseList
A single button widget.
Definition: mythuibutton.h:21
void editChanged(void)
void deleteClicked(void)
EditPowerSearchPopup(MythScreenStack *parentStack, ProgLister *parent, const QString &currentValue)
ProgLister * m_parent
void phraseClicked(MythUIButtonListItem *item)
MythUIButtonList * m_categoryList
MythUIButton * m_deleteButton
Screen in which all other widgets are contained and rendered.
PowerSearchPopup(MythScreenStack *parentStack, ProgLister *parent, RecSearchType searchType, QStringList list, QString currentValue)
MythUIButton * m_editButton
MythUIButton * m_deleteButton
void okClicked(void)
MythUIButtonList * m_phraseList