Add support to load only the first frame of the animation (used in file selector's preview).

This commit is contained in:
David Capello 2011-01-23 19:35:22 -03:00
parent 36e605bdf2
commit 749ff05ef7

View File

@ -306,6 +306,13 @@ bool GifFormat::onLoad(FileOp* fop)
default:
break;
}
// Just one frame?
if (frame_num > 0 && fop->oneframe)
break;
if (fop_is_stop(fop))
break;
} while (record_type != TERMINATE_RECORD_TYPE);
}
catch (...) {