mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2026-02-28 10:44:19 +00:00
Fix issue with modal image viewer with low live_preview_refresh_period (#16981)
This commit is contained in:
@@ -54,6 +54,7 @@ function updateOnBackgroundChange() {
|
||||
updateModalImage();
|
||||
}
|
||||
}
|
||||
const updateModalImageIfVisible = updateOnBackgroundChange;
|
||||
|
||||
function modalImageSwitch(offset) {
|
||||
var galleryButtons = all_gallery_buttons();
|
||||
@@ -164,6 +165,7 @@ function modalLivePreviewToggle(event) {
|
||||
const modalToggleLivePreview = gradioApp().getElementById("modal_toggle_live_preview");
|
||||
opts.js_live_preview_in_modal_lightbox = !opts.js_live_preview_in_modal_lightbox;
|
||||
modalToggleLivePreview.innerHTML = opts.js_live_preview_in_modal_lightbox ? "🗇" : "🗆";
|
||||
updateModalImageIfVisible();
|
||||
event.stopPropagation();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user