If bitrate was higher than max, replace the max
This commit is contained in:
@@ -90,7 +90,6 @@ Kirigami.ScrollablePage {
|
|||||||
Kirigami.FormData.label: i18n("Bitrate:")
|
Kirigami.FormData.label: i18n("Bitrate:")
|
||||||
from: 1
|
from: 1
|
||||||
to: 200
|
to: 200
|
||||||
value: config.bitrate
|
|
||||||
|
|
||||||
textFromValue: (value, locale) => i18nc("bitrate", "%1 Mbit/s", value)
|
textFromValue: (value, locale) => i18nc("bitrate", "%1 Mbit/s", value)
|
||||||
valueFromText: function (text, locale) {
|
valueFromText: function (text, locale) {
|
||||||
@@ -366,6 +365,9 @@ Kirigami.ScrollablePage {
|
|||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
openvr_libs.init()
|
openvr_libs.init()
|
||||||
config.load(WivrnServer);
|
config.load(WivrnServer);
|
||||||
|
// If bitrate was manually set higher, keep the limit
|
||||||
|
bitrate.to = Math.max(bitrate.to, config.bitrate)
|
||||||
|
bitrate.value = config.bitrate
|
||||||
settings.allowUpdates = true;
|
settings.allowUpdates = true;
|
||||||
settings.load();
|
settings.load();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user