aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbobo1on1 <bobo1on1@svn>2010-10-10 18:43:46 +0000
committerbobo1on1 <bobo1on1@svn>2010-10-10 18:43:46 +0000
commit57274e44f4b4804429dc48eb77b23396d1c79cb3 (patch)
tree7c6ab3364f055f73f32f6d81307dc4df398349eb
parentfe373a42f5e30e59a52476c91124bd687064b44b (diff)
Revert "fixed: #10125 - fix xbmc crash with 1 or more displays disabled. (thanks dandel)"
This reverts commit 154bad3d333d0b12532de4dc57eab1bb3b254191. (cherry picked from commit 15f2224dd4f9bff484684e10afc05231951160b4) git-svn-id: https://xbmc.svn.sourceforge.net/svnroot/xbmc/branches/Dharma@34630 568bbfeb-2a22-0410-94d2-cc84cf5bfa90
-rw-r--r--xbmc/linux/XRandR.cpp13
-rw-r--r--xbmc/linux/XRandR.h2
2 files changed, 0 insertions, 15 deletions
diff --git a/xbmc/linux/XRandR.cpp b/xbmc/linux/XRandR.cpp
index 5bd8cae2f3..8337b36c83 100644
--- a/xbmc/linux/XRandR.cpp
+++ b/xbmc/linux/XRandR.cpp
@@ -87,7 +87,6 @@ bool CXRandR::Query(bool force)
xoutput.name.TrimLeft(" \n\r\t");
xoutput.name.TrimRight(" \n\r\t");
xoutput.isConnected = (strcasecmp(output->Attribute("connected"), "true") == 0);
-
xoutput.w = (output->Attribute("w") != NULL ? atoi(output->Attribute("w")) : 0);
xoutput.h = (output->Attribute("h") != NULL ? atoi(output->Attribute("h")) : 0);
xoutput.x = (output->Attribute("x") != NULL ? atoi(output->Attribute("x")) : 0);
@@ -108,10 +107,6 @@ bool CXRandR::Query(bool force)
xmode.h = atoi(mode->Attribute("h"));
xmode.isPreferred = (strcasecmp(mode->Attribute("preferred"), "true") == 0);
xmode.isCurrent = (strcasecmp(mode->Attribute("current"), "true") == 0);
-
- if(xmode.isCurrent)
- xoutput.isEnabled = true;
-
xoutput.modes.push_back(xmode);
if (xmode.isCurrent)
{
@@ -155,8 +150,6 @@ void CXRandR::RestoreState()
bool CXRandR::SetMode(XOutput output, XMode mode)
{
- if(!output.isEnabled)
- return false;
if ((output.name == m_currentOutput && mode.id == m_currentMode) || (output.name == "" && mode.id == ""))
return true;
@@ -235,7 +228,6 @@ bool CXRandR::SetMode(XOutput output, XMode mode)
if (!isModeFound)
{
CLog::Log(LOGERROR, "CXRandR::SetMode: asked to change resolution for non existing mode: %s mode: %s", output.name.c_str(), mode.id.c_str());
- CLog::Log(LOGERROR, "CXRandR::SetMode: requested resolution was %ux%u at %3.0f hz",mode.w,mode.h,mode.hz);
return false;
}
@@ -262,8 +254,6 @@ XOutput CXRandR::GetCurrentOutput()
Query();
for (unsigned int j = 0; j < m_outputs.size(); j++)
{
- if(!m_outputs[j].isEnabled)
- continue;
if(m_outputs[j].isConnected)
return m_outputs[j];
}
@@ -277,9 +267,6 @@ XMode CXRandR::GetCurrentMode(CStdString outputName)
for (unsigned int j = 0; j < m_outputs.size(); j++)
{
- if(!m_outputs[j].isEnabled)
- continue;
-
if (m_outputs[j].name == outputName || outputName == "")
{
for (unsigned int i = 0; i < m_outputs[j].modes.size(); i++)
diff --git a/xbmc/linux/XRandR.h b/xbmc/linux/XRandR.h
index b7f33a54ab..8cfa95ecdd 100644
--- a/xbmc/linux/XRandR.h
+++ b/xbmc/linux/XRandR.h
@@ -76,12 +76,10 @@ public:
{
name="";
isConnected=false;
- isEnabled=false;
w=h=x=y=wmm=hmm=0;
}
CStdString name;
bool isConnected;
- bool isEnabled;
int w;
int h;
int x;