Move 0-item clipboard collapser to update_clipboard_tray.
This commit is contained in:
parent
2adadf9871
commit
4b79308119
1 changed files with 5 additions and 4 deletions
|
@ -170,10 +170,6 @@ function on_tray_delete_button(event)
|
|||
var clipboard_line = event.target.parentElement;
|
||||
var photo_id = clipboard_line.dataset.id;
|
||||
photo_clipboard.delete(photo_id);
|
||||
if (photo_clipboard.size == 0)
|
||||
{
|
||||
clipboard_tray_collapse();
|
||||
}
|
||||
save_photo_clipboard();
|
||||
}
|
||||
|
||||
|
@ -188,6 +184,11 @@ function update_clipboard_tray()
|
|||
return;
|
||||
}
|
||||
|
||||
if (photo_clipboard.size == 0)
|
||||
{
|
||||
clipboard_tray_collapse();
|
||||
}
|
||||
|
||||
var tray_lines = document.getElementById("clipboard_tray_lines");
|
||||
if (!clipboard_tray.classList.contains("hidden"))
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue