MythTV  master
mythdisplaydrm.cpp
Go to the documentation of this file.
1 // MythTV
2 #include "mythdrmdevice.h"
3 #include "mythdisplaydrm.h"
4 
5 #define LOC QString("DispDRM: ")
6 
8 {
10  if (!m_device->IsValid())
11  {
12  delete m_device;
13  m_device = nullptr;
14  }
15  Initialise();
16 }
17 
19 {
20  delete m_device;
21 }
22 
23 // FIXME - I doubt this slot is being called correctly
24 void MythDisplayDRM::ScreenChanged(QScreen *qScreen)
25 {
27 
28  if (m_device && m_device->GetScreen() != m_screen)
29  {
30  delete m_device;
31  m_device = nullptr;
32  }
33 
34  if (!m_device)
35  {
37  if (!m_device->IsValid())
38  {
39  delete m_device;
40  m_device = nullptr;
41  }
42  }
43 }
44 
46 {
47  if (m_device)
48  {
52  m_edid = m_device->GetEDID();
53  m_modeComplete = true;
54  return;
55  }
57 }
MythDisplay::m_physicalSize
QSize m_physicalSize
Definition: mythdisplay.h:89
MythDisplayDRM::ScreenChanged
void ScreenChanged(QScreen *qScreen) override
Definition: mythdisplaydrm.cpp:24
MythDisplay::Initialise
void Initialise(void)
Definition: mythdisplay.cpp:504
MythDRMDevice::IsValid
bool IsValid(void) const
Definition: mythdrmdevice.cpp:80
MythDisplay::m_resolution
QSize m_resolution
Definition: mythdisplay.h:88
MythDisplay::ScreenChanged
virtual void ScreenChanged(QScreen *qScreen)
The actual screen in use has changed. We must use it.
Definition: mythdisplay.cpp:392
MythDisplayDRM::~MythDisplayDRM
~MythDisplayDRM() override
Definition: mythdisplaydrm.cpp:18
MythDisplay::UpdateCurrentMode
virtual void UpdateCurrentMode(void)
Retrieve screen details.
Definition: mythdisplay.cpp:442
MythDisplay::m_modeComplete
bool m_modeComplete
Definition: mythdisplay.h:85
mythdisplaydrm.h
MythDRMDevice::GetResolution
QSize GetResolution(void) const
Definition: mythdrmdevice.cpp:95
MythDisplay::m_edid
MythEDID m_edid
Definition: mythdisplay.h:90
MythDRMDevice
Definition: mythdrmdevice.h:19
MythDisplayDRM::m_device
MythDRMDevice * m_device
Definition: mythdisplaydrm.h:26
MythDisplay::m_refreshRate
double m_refreshRate
Definition: mythdisplay.h:86
MythDRMDevice::GetEDID
MythEDID GetEDID(void)
Definition: mythdrmdevice.cpp:115
MythDisplayDRM::UpdateCurrentMode
void UpdateCurrentMode(void) override
Retrieve screen details.
Definition: mythdisplaydrm.cpp:45
MythDRMDevice::GetScreen
QScreen * GetScreen(void) const
Definition: mythdrmdevice.cpp:90
MythDisplay::m_screen
QScreen * m_screen
Definition: mythdisplay.h:93
MythDisplayDRM::MythDisplayDRM
MythDisplayDRM()
Definition: mythdisplaydrm.cpp:7
mythdrmdevice.h
MythDRMDevice::GetRefreshRate
double GetRefreshRate(void) const
Definition: mythdrmdevice.cpp:105
MythDRMDevice::GetPhysicalSize
QSize GetPhysicalSize(void) const
Definition: mythdrmdevice.cpp:100