mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-03-12 04:14:35 +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
|
||||
ui->label_game_window_title_format->setText(qstr(xemu_settings->GetSetting(emu_settings::WindowTitleFormat)));
|
||||
|
||||
|
@ -2271,17 +2271,34 @@
|
||||
<property name="text">
|
||||
<string>FPS: 60 | Renderer | Version | Game [ID]</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="edit_button_game_window_title_format">
|
||||
<property name="toolTip">
|
||||
<string>Reset the title to default</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Edit</string>
|
||||
</property>
|
||||
</widget>
|
||||
<layout class="QHBoxLayout" name="layout_buttons_game_window_title">
|
||||
<item>
|
||||
<widget class="QPushButton" name="reset_button_game_window_title_format">
|
||||
<property name="toolTip">
|
||||
<string>Reset the game window title to default</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<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>
|
||||
</layout>
|
||||
</widget>
|
||||
|
Loading…
x
Reference in New Issue
Block a user