Permalink
Browse files

Merge pull request #6689 from container1234/qt-minor-fixes

Qt: Minor changes
  • Loading branch information...
lioncash committed Apr 28, 2018
2 parents 6bb8804 + b46bf9b commit 6b8da197e8fc07034ebc4c7c58a0596354f6b8a6
@@ -390,9 +390,9 @@ bool CheatsManager::MatchesSearch(u32 addr) const
case DataType::Int:
return Compare(PowerPC::HostRead_U32(addr), text.toUInt(nullptr, base), op);
case DataType::Float:
return Compare(PowerPC::Read_F32(addr), text.toFloat(), op);
return Compare(PowerPC::HostRead_F32(addr), text.toFloat(), op);
case DataType::Double:
return Compare(PowerPC::Read_F64(addr), text.toDouble(), op);
return Compare(PowerPC::HostRead_F64(addr), text.toDouble(), op);
case DataType::String:
{
bool is_equal = std::equal(text.toUtf8().cbegin(), text.toUtf8().cend(),
@@ -516,10 +516,10 @@ void CheatsManager::Update()
16, QLatin1Char('0')));
break;
case DataType::Float:
value_item->setText(QString::number(PowerPC::Read_F32(m_results[i].address)));
value_item->setText(QString::number(PowerPC::HostRead_F32(m_results[i].address)));
break;
case DataType::Double:
value_item->setText(QString::number(PowerPC::Read_F64(m_results[i].address)));
value_item->setText(QString::number(PowerPC::HostRead_F64(m_results[i].address)));
break;
case DataType::String:
value_item->setText(tr("String Match"));
@@ -575,10 +575,10 @@ void CheatsManager::Update()
16, QLatin1Char('0')));
break;
case DataType::Float:
value_item->setText(QString::number(PowerPC::Read_F32(m_watch[i].address)));
value_item->setText(QString::number(PowerPC::HostRead_F32(m_watch[i].address)));
break;
case DataType::Double:
value_item->setText(QString::number(PowerPC::Read_F64(m_watch[i].address)));
value_item->setText(QString::number(PowerPC::HostRead_F64(m_watch[i].address)));
break;
case DataType::String:
value_item->setText(tr("String Match"));
@@ -143,11 +143,11 @@ void CodeViewWidget::Update()
item->setData(Qt::UserRole, addr);
if (color != 0xFFFFFF)
item->setBackground(QColor(color).darker(200));
item->setBackground(QColor(color).darker(110));
if (addr == pc && item != bp_item)
{
item->setBackground(Qt::darkGreen);
item->setBackground(QColor(Qt::green).darker(110));
}
}
@@ -170,7 +170,7 @@ void MemoryViewWidget::Update()
});
break;
case Type::Float32:
update_values([](u32 address) { return QString::number(PowerPC::Read_F32(address)); });
update_values([](u32 address) { return QString::number(PowerPC::HostRead_F32(address)); });
break;
}
}
@@ -72,6 +72,7 @@ void RegisterWidget::CreateWidgets()
m_table->setColumnCount(9);
m_table->verticalHeader()->setVisible(false);
m_table->verticalHeader()->setDefaultSectionSize(24);
m_table->setContextMenuPolicy(Qt::CustomContextMenu);
m_table->setSelectionMode(QAbstractItemView::SingleSelection);

0 comments on commit 6b8da19

Please sign in to comment.