MythTV  master
mythcdrom.h
Go to the documentation of this file.
1 #ifndef MYTHCDROM_H
2 #define MYTHCDROM_H
3 
4 #include "mythmedia.h"
5 
7 {
8  Q_OBJECT
9  protected:
10  MythCDROM(QObject* par, const QString& DevicePath, bool SuperMount,
11  bool AllowEject);
12  public:
13  ~MythCDROM() override = default;
14 
15  virtual bool mediaChanged(void) { return false; }
16  virtual bool checkOK(void) { return true; }
17  MythMediaStatus checkMedia(void) override // MythMediaDevice
18  {
19  return setStatus(MEDIASTAT_UNKNOWN, false);
20  }
21  void setDeviceSpeed(const char *devicePath, int speed) override; // MythMediaDevice
22 
23  static MythCDROM* get(QObject* par, const QString& devicePath,
24  bool SuperMount, bool AllowEject);
25 
26  enum ImageType : std::uint8_t
27  {
30  kDVD
31  };
32 
33  static ImageType inspectImage(const QString& path);
34 
35  protected:
36  void onDeviceMounted() override; // MythMediaDevice
37 };
38 
39 #endif
MythMediaDevice::setDeviceSpeed
virtual void setDeviceSpeed(const char *, int)
Definition: mythmedia.h:100
MythCDROM::checkOK
virtual bool checkOK(void)
Definition: mythcdrom.h:16
MBASE_PUBLIC
#define MBASE_PUBLIC
Definition: mythbaseexp.h:15
MythCDROM::kBluray
@ kBluray
Definition: mythcdrom.h:29
MythMediaStatus
MythMediaStatus
Definition: mythmedia.h:12
mythmedia.h
MythCDROM
Definition: mythcdrom.h:6
MythMediaDevice::onDeviceMounted
virtual void onDeviceMounted(void)
Override this to perform any post mount logic.
Definition: mythmedia.h:133
MythMediaDevice::setStatus
MythMediaStatus setStatus(MythMediaStatus newStat, bool CloseIt=false)
Definition: mythmedia.cpp:465
MythCDROM::kUnknown
@ kUnknown
Definition: mythcdrom.h:28
hardwareprofile.distros.all.get
def get()
Definition: all.py:22
MEDIASTAT_UNKNOWN
@ MEDIASTAT_UNKNOWN
Definition: mythmedia.h:14
MythMediaDevice
Definition: mythmedia.h:48
MythCDROM::checkMedia
MythMediaStatus checkMedia(void) override
Definition: mythcdrom.h:17
ImageType
ImageType
Definition: musicmetadata.h:28
MythCDROM::mediaChanged
virtual bool mediaChanged(void)
Definition: mythcdrom.h:15