Apply suggestions from code review

Co-authored-by: Ben <bene_thomas@web.de>
This commit is contained in:
SutandoTsukai181 2020-05-02 18:10:27 +03:00 committed by GitHub
parent acc46884ff
commit 6d5d5ceede
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 6 deletions

View file

@ -137,7 +137,7 @@ texture_filter_name =
# Limits the speed of the game to run no faster than this value as a percentage of target speed.
# Will not have an effect if unthrottled is enabled.
# 1 - 9999: Speed limit as a percentage of target game speed. 0 for unthrottled. 100 (default)
# 5 - 995: Speed limit as a percentage of target game speed. 0 for unthrottled. 100 (default)
frame_limit =
# Overrides the frame limiter to use frame_limit_alternate instead of frame_limit.
@ -145,7 +145,7 @@ frame_limit =
use_frame_limit_alternate =
# Alternate speed limit to be used instead of frame_limit if use_frame_limit_alternate is enabled
# 1 - 9999: Speed limit as a percentage of target game speed. 0 for unthrottled. 200 (default)
# 5 - 995: Speed limit as a percentage of target game speed. 0 for unthrottled. 200 (default)
frame_limit_alternate =
# The clear color for the renderer. What shows up on the sides of the bottom screen.

View file

@ -35,7 +35,7 @@ ConfigureGeneral::ConfigureGeneral(QWidget* parent)
ui->game_speed_display_label->setText(tr("unthrottled"));
} else {
ui->game_speed_display_label->setText(
QStringLiteral("%1%").arg(SliderToSettings(value)).rightJustified(11));
QStringLiteral("%1%").arg(SliderToSettings(value)).rightJustified(tr("unthrottled").size()));
}
});
@ -44,7 +44,7 @@ ConfigureGeneral::ConfigureGeneral(QWidget* parent)
ui->game_speed_alternate_display_label->setText(tr("unthrottled"));
} else {
ui->game_speed_alternate_display_label->setText(
QStringLiteral("%1%").arg(SliderToSettings(value)).rightJustified(11));
QStringLiteral("%1%").arg(SliderToSettings(value)).rightJustified(tr("unthrottled").size()));
}
});
}
@ -72,7 +72,7 @@ void ConfigureGeneral::SetConfiguration() {
} else {
ui->game_speed_display_label->setText(QStringLiteral("%1%")
.arg(SliderToSettings(ui->frame_limit->value()))
.rightJustified(11));
.rightJustified(tr("unthrottled").size()));
}
ui->toggle_alternate_speed->setChecked(Settings::values.use_frame_limit_alternate);
@ -89,7 +89,7 @@ void ConfigureGeneral::SetConfiguration() {
ui->game_speed_alternate_display_label->setText(
QStringLiteral("%1%")
.arg(SliderToSettings(ui->frame_limit_alternate->value()))
.rightJustified(11));
.rightJustified(tr("unthrottled").size()));
}
}