tag1->prev = tag;
if(tag) tag->next = tag1;
tag = tag1;
- swf_DeleteTag(tag2);
+ swf_DeleteTag(0, tag2);
} else {
/* use the jpeg version- it's smaller */
tag2->prev = tag;
if(tag) tag->next = tag2;
tag = tag2;
- swf_DeleteTag(tag1);
+ swf_DeleteTag(0, tag1);
}
return tag;
}
}
if (swf->firstTag == tables_tag)
swf->firstTag = tables_tag->next;
- swf_DeleteTag(tables_tag);
+ swf_DeleteTag(swf, tables_tag);
}
typedef struct scale_lookup {
{
SWFSHAPEDRAWER*sdraw = (SWFSHAPEDRAWER*)draw->internal;
if(sdraw->tagfree) {
- swf_DeleteTag(sdraw->tag);
+ swf_DeleteTag(0, sdraw->tag);
sdraw->tag = 0;
}
swf_ShapeFree(sdraw->shape);
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#include <assert.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include "../rfxswf.h"
/* one bit flag: */
#define clip_type 0
/* delete line buffers */
for(y=0;y<i->height2;y++) {
- swf_DeleteTag(i->lines[y].points);
+ swf_DeleteTag(0, i->lines[y].points);
i->lines[y].points = 0;
}
/* I never saw recursive sprites, but they are (theoretically)
possible, so better add base here again */
enumerateUsedIDs(tag2, tag->pos + base, callback, callback_data);
- swf_DeleteTag(tag2);
+ swf_DeleteTag(0, tag2);
swf_GetBlock(tag, NULL, len);
}
}
/* we found two identical tags- remap one
of them */
remap[id] = swf_GetDefineID(tag2);
- swf_DeleteTag(tag);
- if(tag == swf->firstTag)
- swf->firstTag = next;
+ swf_DeleteTag(swf, tag);
}
} else if(swf_isPseudoDefiningTag(tag)) {
int id = swf_GetDefineID(tag);
/* if this tag was remapped, we don't
need the helper tag anymore. Discard
it. */
- swf_DeleteTag(tag);
- if(tag == swf->firstTag)
- swf->firstTag = next;
+ swf_DeleteTag(swf, tag);
}
}
tag->internals.data = 0;
}
if(tag->internals.tag) {
- swf_DeleteTag(tag->internals.tag);
+ swf_DeleteTag(0, tag->internals.tag);
tag->internals.tag = 0;
}
Py_DECREF(tag->internals.tagmap);
/* a setattr will almost certainly change the tag data,
so delete the tag */
if(self->internals.tag) {
- swf_DeleteTag(self->internals.tag);
+ swf_DeleteTag(0, self->internals.tag);
self->internals.tag = 0;
}
if(self->internals.setattr) {
while(t) {len++;last=t;t=t->next;}
if(last && last->id==ST_END) {
- swf_DeleteTag(last); last = 0;
+ swf_DeleteTag(0, last); last = 0;
len--;
if(len==0) tag = 0;
}
SWFPLACEOBJECT* swfpo = malloc(sizeof(SWFPLACEOBJECT));
swf_GetPlaceObject(self->tag, swfpo);
i->po = swfpo;
- swf_DeleteTag(self->tag);self->tag = 0;
+ swf_DeleteTag(0, self->tag);self->tag = 0;
if(i->po->id) {
i->character = tagmap_id2obj(self->tagmap, i->po->id);
{
sprite_internal_t*si = (sprite_internal_t*)self->data;
if(self->tag) {
- swf_DeleteTag(self->tag);
+ swf_DeleteTag(0, self->tag);
self->tag = 0;
}
if(!strcmp(a, "tags")) {
i->isindexed = 0;
i->islossless = 1;
- swf_DeleteTag(self->tag);self->tag = 0;
+ swf_DeleteTag(0, self->tag);self->tag = 0;
return 1;
}
static int imagetag_getWidth(PyObject* self)
SHAPE2* shape2 = malloc(sizeof(SHAPE2));
swf_ParseDefineShape(self->tag, shape2);
i->shape2 = shape2;
- swf_DeleteTag(self->tag);self->tag = 0;
+ swf_DeleteTag(0, self->tag);self->tag = 0;
return 1;
}
static void shape_dealloc(tag_internals_t*self)