mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-12-23 09:28:45 +00:00
Fixed: 0x0 is Auto mode
--HG-- branch : develop
This commit is contained in:
parent
b9231adb78
commit
13851e3df5
2 changed files with 22 additions and 1 deletions
|
@ -166,7 +166,18 @@ void CDisplaySettingsWidget::updateVideoModes()
|
||||||
|
|
||||||
while(itr != iend)
|
while(itr != iend)
|
||||||
{
|
{
|
||||||
videomodeComboBox->addItem(QString("%1x%2 %3 bit @%4").arg(itr->width).arg(itr->height).arg(itr->depth).arg(itr->frequency));
|
if (itr->frequency)
|
||||||
|
{
|
||||||
|
videomodeComboBox->addItem(QString("%1x%2 %3 bit @%4").arg(itr->width).arg(itr->height).arg(itr->depth).arg(itr->frequency));
|
||||||
|
}
|
||||||
|
else if (itr->width)
|
||||||
|
{
|
||||||
|
videomodeComboBox->addItem(QString("%1x%2 %3 bit").arg(itr->width).arg(itr->height).arg(itr->depth));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
videomodeComboBox->addItem(tr("Auto"));
|
||||||
|
}
|
||||||
|
|
||||||
++itr;
|
++itr;
|
||||||
}
|
}
|
||||||
|
|
|
@ -160,6 +160,16 @@ void CSystem::GetVideoModes( std::vector< CVideoMode > &dst, NL3D::IDriver *driv
|
||||||
std::vector< NL3D::GfxMode > modes;
|
std::vector< NL3D::GfxMode > modes;
|
||||||
driver->getModes( modes );
|
driver->getModes( modes );
|
||||||
|
|
||||||
|
{
|
||||||
|
// auto mode
|
||||||
|
CVideoMode mode;
|
||||||
|
mode.depth = 0;
|
||||||
|
mode.width = 0;
|
||||||
|
mode.height = 0;
|
||||||
|
mode.frequency = 0;
|
||||||
|
dst.push_back( mode );
|
||||||
|
}
|
||||||
|
|
||||||
for( std::vector< NL3D::GfxMode >::iterator itr = modes.begin(); itr != modes.end(); ++itr )
|
for( std::vector< NL3D::GfxMode >::iterator itr = modes.begin(); itr != modes.end(); ++itr )
|
||||||
{
|
{
|
||||||
if( ( itr->Width >= 800 ) && ( itr->Height >= 600 ) && ( itr->Depth >= 16 ) )
|
if( ( itr->Width >= 800 ) && ( itr->Height >= 600 ) && ( itr->Depth >= 16 ) )
|
||||||
|
|
Loading…
Reference in a new issue