mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-08-04 16:32:39 +00:00
Fixed segfault when trying to change opacity after table refresh
This commit is contained in:
parent
88f3e06bd6
commit
f340ae471d
@ -82,6 +82,8 @@ void GameGridFrame::PlayBackgroundMusic(QString path) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void GameGridFrame::PopulateGameGrid(QVector<GameInfo> m_games_search, bool fromSearch) {
|
void GameGridFrame::PopulateGameGrid(QVector<GameInfo> m_games_search, bool fromSearch) {
|
||||||
|
this->crtRow = -1;
|
||||||
|
this->crtColumn = -1;
|
||||||
QVector<GameInfo> m_games_;
|
QVector<GameInfo> m_games_;
|
||||||
this->clearContents();
|
this->clearContents();
|
||||||
if (fromSearch)
|
if (fromSearch)
|
||||||
|
@ -105,6 +105,7 @@ void GameListFrame::PlayBackgroundMusic(QTableWidgetItem* item) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void GameListFrame::PopulateGameList(bool isInitialPopulation) {
|
void GameListFrame::PopulateGameList(bool isInitialPopulation) {
|
||||||
|
this->m_current_item = nullptr;
|
||||||
// Do not show status column if it is not enabled
|
// Do not show status column if it is not enabled
|
||||||
this->setColumnHidden(2, !Config::getCompatibilityEnabled());
|
this->setColumnHidden(2, !Config::getCompatibilityEnabled());
|
||||||
this->setColumnHidden(6, !Config::GetLoadGameSizeEnabled());
|
this->setColumnHidden(6, !Config::GetLoadGameSizeEnabled());
|
||||||
|
@ -292,18 +292,22 @@ void MainWindow::CreateConnects() {
|
|||||||
connect(settingsDialog, &SettingsDialog::CompatibilityChanged, this,
|
connect(settingsDialog, &SettingsDialog::CompatibilityChanged, this,
|
||||||
&MainWindow::RefreshGameTable);
|
&MainWindow::RefreshGameTable);
|
||||||
|
|
||||||
// Connect background opacity changes to refresh both frames
|
connect(settingsDialog, &SettingsDialog::BackgroundOpacityChanged, this,
|
||||||
connect(
|
[this](int opacity) {
|
||||||
settingsDialog, &SettingsDialog::BackgroundOpacityChanged, this, [this](int opacity) {
|
Config::setBackgroundImageOpacity(opacity);
|
||||||
Config::setBackgroundImageOpacity(opacity);
|
if (m_game_list_frame) {
|
||||||
if (m_game_list_frame) {
|
QTableWidgetItem* current = m_game_list_frame->GetCurrentItem();
|
||||||
m_game_list_frame->SetListBackgroundImage(m_game_list_frame->GetCurrentItem());
|
if (current) {
|
||||||
}
|
m_game_list_frame->SetListBackgroundImage(current);
|
||||||
if (m_game_grid_frame) {
|
}
|
||||||
m_game_grid_frame->SetGridBackgroundImage(m_game_grid_frame->crtRow,
|
}
|
||||||
m_game_grid_frame->crtColumn);
|
if (m_game_grid_frame) {
|
||||||
}
|
if (m_game_grid_frame->IsValidCellSelected()) {
|
||||||
});
|
m_game_grid_frame->SetGridBackgroundImage(m_game_grid_frame->crtRow,
|
||||||
|
m_game_grid_frame->crtColumn);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
settingsDialog->exec();
|
settingsDialog->exec();
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user