configure_input: fix modifier scale saving
This commit is contained in:
parent
e33677b021
commit
75f9c2cc13
|
@ -266,6 +266,8 @@ ConfigureInput::ConfigureInput(QWidget* parent)
|
||||||
tr("Modifier Scale: %1%").arg(slider_value));
|
tr("Modifier Scale: %1%").arg(slider_value));
|
||||||
analogs_param[analog_id].Set("modifier_scale", slider_value / 100.0f);
|
analogs_param[analog_id].Set("modifier_scale", slider_value / 100.0f);
|
||||||
}
|
}
|
||||||
|
ApplyConfiguration();
|
||||||
|
Settings::SaveProfile(ui->profile->currentIndex());
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -373,6 +375,9 @@ void ConfigureInput::RestoreDefaults() {
|
||||||
Config::default_analogs[analog_id][sub_button_id])};
|
Config::default_analogs[analog_id][sub_button_id])};
|
||||||
SetAnalogButton(params, analogs_param[analog_id], analog_sub_buttons[sub_button_id]);
|
SetAnalogButton(params, analogs_param[analog_id], analog_sub_buttons[sub_button_id]);
|
||||||
}
|
}
|
||||||
|
if (analogs_param[analog_id].Get("modifier_scale", 0.5f) != 0.5f) {
|
||||||
|
analogs_param[analog_id].Set("modifier_scale", 0.5f);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
UpdateButtonLabels();
|
UpdateButtonLabels();
|
||||||
|
|
||||||
|
|
Reference in New Issue