Restore OnDiskGif deinit

This commit is contained in:
gamblor21 2023-03-22 22:30:38 -05:00
parent 00d78f7cfe
commit 52631bb1c5
1 changed files with 11 additions and 0 deletions

View File

@ -268,6 +268,17 @@ MP_DEFINE_CONST_FUN_OBJ_1(gifio_ondiskgif_get_max_delay_obj, gifio_ondiskgif_obj
MP_PROPERTY_GETTER(gifio_ondiskgif_max_delay_obj,
(mp_obj_t)&gifio_ondiskgif_get_max_delay_obj);
//| def deinit(self) -> None:
//| """Release resources allocated by OnDiskGif."""
//| ...
//|
STATIC mp_obj_t gifio_ondiskgif_obj_deinit(mp_obj_t self_in) {
gifio_ondiskgif_t *self = MP_OBJ_TO_PTR(self_in);
common_hal_gifio_ondiskgif_deinit(self);
return mp_const_none;
}
MP_DEFINE_CONST_FUN_OBJ_1(gifio_ondiskgif_deinit_obj, gifio_ondiskgif_obj_deinit);
STATIC const mp_rom_map_elem_t gifio_ondiskgif_locals_dict_table[] = {
{ MP_ROM_QSTR(MP_QSTR_deinit), MP_ROM_PTR(&gifio_ondiskgif_deinit_obj) },
{ MP_ROM_QSTR(MP_QSTR___enter__), MP_ROM_PTR(&default___enter___obj) },