fix selected HRfix upscaler localstorage
This commit is contained in:
parent
0f4aeeb0d5
commit
b8c02d630d
2 changed files with 5 additions and 8 deletions
|
@ -340,7 +340,7 @@
|
|||
|
||||
<!-- Content -->
|
||||
<script src="js/prompt.js?v=7a1c68c" type="text/javascript"></script>
|
||||
<script src="js/index.js?v=bc49f7d" type="text/javascript"></script>
|
||||
<script src="js/index.js?v=e28f84d" type="text/javascript"></script>
|
||||
|
||||
<script
|
||||
src="js/ui/floating/history.js?v=fc92d14"
|
||||
|
|
11
js/index.js
11
js/index.js
|
@ -797,7 +797,10 @@ async function getUpscalers() {
|
|||
});
|
||||
|
||||
upscalerAutoComplete.value = upscalers[0];
|
||||
hrFixUpscalerAutoComplete.value = upscalersPlusNone[0];
|
||||
hrFixUpscalerAutoComplete.value =
|
||||
localStorage.getItem("openoutpaint/hr_upscaler") === null
|
||||
? "None"
|
||||
: localStorage.getItem("openoutpaint/hr_upscaler");
|
||||
} catch (e) {
|
||||
console.warn("[index] Failed to fetch upscalers:");
|
||||
console.warn(e);
|
||||
|
@ -1109,11 +1112,6 @@ function loadSettings() {
|
|||
? 2.0
|
||||
: localStorage.getItem("openoutpaint/hr_scale");
|
||||
|
||||
let _hrfix_upscaler =
|
||||
localStorage.getItem("openoutpaint/hr_upscaler") === null
|
||||
? "None"
|
||||
: localStorage.getItem("openoutpaint/hr_upscaler");
|
||||
|
||||
let _hrfix_denoising =
|
||||
localStorage.getItem("openoutpaint/denoising_strength") === null
|
||||
? 0.7
|
||||
|
@ -1126,7 +1124,6 @@ function loadSettings() {
|
|||
document.getElementById("cbxSyncCursorSize").checked =
|
||||
Boolean(_sync_cursor_size);
|
||||
document.getElementById("hrFixScale").value = Number(_hrfix_scale);
|
||||
document.getElementById("hrFixUpscaler").value = Number(_hrfix_upscaler);
|
||||
document.getElementById("hrDenoising").value = Number(_hrfix_denoising);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue