MythTV  master
mythcontext.h
Go to the documentation of this file.
1 #ifndef MYTHCONTEXT_H_
2 #define MYTHCONTEXT_H_
3 
4 #include <QObject>
5 #include <QString>
6 
7 #include "mythcorecontext.h"
8 #include "mythevent.h"
9 #include "mythexp.h"
10 #include "mythlogging.h"
11 
12 class MythContextPrivate;
13 
14 class MythContextSlotHandler : public QObject
15 {
16  Q_OBJECT
17 
18  public:
20 
21  private slots:
22  void VersionMismatchPopupClosed(void);
23 
24  public slots:
25  void OnCloseDialog(void);
26 
27  private:
28  ~MythContextSlotHandler() override = default;
29 
30  MythContextPrivate *d {nullptr}; // NOLINT(readability-identifier-naming)
31 };
32 
43 {
44  public:
45  explicit MythContext(QString binversion, bool needsBackend = false);
46  virtual ~MythContext();
47 
48  bool Init(bool gui = true,
49  bool promptForBackend = false,
50  bool disableAutoDiscovery = false,
51  bool ignoreDB = false);
52 
53  DatabaseParams GetDatabaseParams(void);
54  bool SaveDatabaseParams(const DatabaseParams &params);
55  bool saveSettingsCache(void);
56 
57  void SetDisableEventPopup(bool check);
58 
59  private:
60  MythContextPrivate *d {nullptr}; // NOLINT(readability-identifier-naming)
62 };
63 
66 
67 #endif
68 
69 /* vim: set expandtab tabstop=4 shiftwidth=4: */
mythevent.h
MPUBLIC
#define MPUBLIC
Definition: mythexp.h:10
MythContextSlotHandler::VersionMismatchPopupClosed
void VersionMismatchPopupClosed(void)
Definition: mythcontext.cpp:1535
gContext
MPUBLIC MythContext * gContext
This global variable contains the MythContext instance for the application.
Definition: mythcontext.cpp:61
DatabaseParams
Structure containing the basic Database parameters.
Definition: mythdbparams.h:10
mythexp.h
d
static const uint16_t * d
Definition: iso6937tables.cpp:1025
MythContext
Startup context for MythTV.
Definition: mythcontext.h:43
slots
unsigned int slots[4]
Definition: element.cpp:38
MythContext::m_appBinaryVersion
QString m_appBinaryVersion
Definition: mythcontext.h:61
mythlogging.h
MythContextSlotHandler::d
MythContextPrivate * d
Definition: mythcontext.h:30
mythcorecontext.h
MythContextSlotHandler::~MythContextSlotHandler
~MythContextSlotHandler() override=default
MythContextSlotHandler::OnCloseDialog
void OnCloseDialog(void)
Definition: mythcontext.cpp:708
MythContextSlotHandler
Definition: mythcontext.h:15
MythContextSlotHandler::MythContextSlotHandler
MythContextSlotHandler(MythContextPrivate *x)
Definition: mythcontext.h:19
MythContextPrivate
Definition: mythcontext.cpp:66