plug-ins: fix the fix for #6116 grayscale gif animation.

I must have not been awake yet when I pushed the
fix for #6116 because it has two problems:
- Updating cur_progress caused by not editing the
  for loop after a copy/paste, found thanks to
  Stanislav Grinkov.
- Not using the correct drawable to determine the
  drawable_type which I noticed while fixing the
  above issue.

These issues are not present in the backported
version for 2.10.
This commit is contained in:
Jacob Boerema 2021-05-31 11:59:58 -04:00
parent 8f89d31e5c
commit 1731c875a1
1 changed files with 2 additions and 4 deletions

View File

@ -822,11 +822,9 @@ save_image (GFile *file,
if (drawable_type == GIMP_GRAY_IMAGE ||
drawable_type == GIMP_INDEXED_IMAGE)
{
for (list = layers, i = nlayers - 1;
list && i >= 0;
list = g_list_next (list), i--, cur_progress = (nlayers - i) * rows)
for (list = layers; list; list = g_list_next (list))
{
GimpImageType dr_type = gimp_drawable_type (drawable);
GimpImageType dr_type = gimp_drawable_type (list->data);
if (dr_type == GIMP_GRAYA_IMAGE ||
dr_type == GIMP_INDEXEDA_IMAGE)