aboutsummaryrefslogtreecommitdiff
path: root/javascript/images_history.js
diff options
context:
space:
mode:
Diffstat (limited to 'javascript/images_history.js')
-rw-r--r--javascript/images_history.js18
1 files changed, 9 insertions, 9 deletions
diff --git a/javascript/images_history.js b/javascript/images_history.js
index f7d052c3..ac5834c7 100644
--- a/javascript/images_history.js
+++ b/javascript/images_history.js
@@ -88,15 +88,15 @@ function images_history_set_image_info(button){
}
-function images_history_get_current_img(tabname, image_path, files){
+function images_history_get_current_img(tabname, img_index, files){
return [
- gradioApp().getElementById(tabname + '_images_history_set_index').getAttribute("img_index"),
- image_path,
+ tabname,
+ gradioApp().getElementById(tabname + '_images_history_set_index').getAttribute("img_index"),
files
];
}
-function images_history_delete(del_num, tabname, img_path, img_file_name, page_index, filenames, image_index){
+function images_history_delete(del_num, tabname, img_file_name, page_index, filenames, image_index){
image_index = parseInt(image_index);
var tab = gradioApp().getElementById(tabname + '_images_history');
var set_btn = tab.querySelector(".images_history_set_index");
@@ -129,15 +129,15 @@ function images_history_delete(del_num, tabname, img_path, img_file_name, page_i
setTimeout(function(btn){btn.click()}, 30, btn);
}
images_history_disabled_del();
- return [del_num, tabname, img_path, img_file_name, page_index, filenames, image_index];
+ return [del_num, tabname, img_file_name, page_index, filenames, image_index];
}
-function images_history_turnpage(img_path, page_index, image_index, tabname){
+function images_history_turnpage(img_path, page_index, image_index, tabname, date_from, date_to){
var buttons = gradioApp().getElementById(tabname + '_images_history').querySelectorAll(".gallery-item");
buttons.forEach(function(elem) {
elem.style.display = 'block';
})
- return [img_path, page_index, image_index, tabname];
+ return [img_path, page_index, image_index, tabname, date_from, date_to];
}
function images_history_enable_del_buttons(){
@@ -170,8 +170,8 @@ function images_history_init(){
}
tabs_box.classList.add(images_history_tab_list[0]);
- // same as above, at page load
- //load_txt2img_button.click();
+ // same as above, at page load-- load very fast now
+ load_txt2img_button.click();
} else {
setTimeout(images_history_init, 500);
}