mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-03-12 13:13:43 +00:00
Qt: add reset button to game window title and center the label
This commit is contained in:
parent
c1bdaccd8c
commit
b5ed73ebe0
@ -1355,6 +1355,13 @@ settings_dialog::settings_dialog(std::shared_ptr<gui_settings> guiSettings, std:
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
connect(ui->reset_button_game_window_title_format, &QAbstractButton::clicked, [this, game]()
|
||||||
|
{
|
||||||
|
const std::string default_game_title_format = xemu_settings->GetSettingDefault(emu_settings::WindowTitleFormat);
|
||||||
|
xemu_settings->SetSetting(emu_settings::WindowTitleFormat, default_game_title_format);
|
||||||
|
ui->label_game_window_title_format->setText(qstr(default_game_title_format));
|
||||||
|
});
|
||||||
|
|
||||||
// Load and apply the configured game window title format
|
// Load and apply the configured game window title format
|
||||||
ui->label_game_window_title_format->setText(qstr(xemu_settings->GetSetting(emu_settings::WindowTitleFormat)));
|
ui->label_game_window_title_format->setText(qstr(xemu_settings->GetSetting(emu_settings::WindowTitleFormat)));
|
||||||
|
|
||||||
|
@ -2271,17 +2271,34 @@
|
|||||||
<property name="text">
|
<property name="text">
|
||||||
<string>FPS: 60 | Renderer | Version | Game [ID]</string>
|
<string>FPS: 60 | Renderer | Version | Game [ID]</string>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignCenter</set>
|
||||||
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="edit_button_game_window_title_format">
|
<layout class="QHBoxLayout" name="layout_buttons_game_window_title">
|
||||||
<property name="toolTip">
|
<item>
|
||||||
<string>Reset the title to default</string>
|
<widget class="QPushButton" name="reset_button_game_window_title_format">
|
||||||
</property>
|
<property name="toolTip">
|
||||||
<property name="text">
|
<string>Reset the game window title to default</string>
|
||||||
<string>Edit</string>
|
</property>
|
||||||
</property>
|
<property name="text">
|
||||||
</widget>
|
<string>Reset</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="edit_button_game_window_title_format">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>Edit the game window title</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Edit</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user