summaryrefslogtreecommitdiff
path: root/cocoa
diff options
context:
space:
mode:
authorVincent Sanders <vince@netsurf-browser.org>2011-08-31 12:18:25 +0000
committerVincent Sanders <vince@netsurf-browser.org>2011-08-31 12:18:25 +0000
commitc35b92acc105b763f9200e0b7c022c2930cc3e1d (patch)
tree1b333ba49a1e861b3fc61fe4ef70fb65bda62560 /cocoa
parent2348b134924e8b24fba02f068a16c6fb308af88a (diff)
downloadnetsurf-c35b92acc105b763f9200e0b7c022c2930cc3e1d.tar.gz
netsurf-c35b92acc105b763f9200e0b7c022c2930cc3e1d.tar.bz2
fix apple image content handler
svn path=/trunk/netsurf/; revision=12687
Diffstat (limited to 'cocoa')
-rw-r--r--cocoa/apple_image.m7
1 files changed, 4 insertions, 3 deletions
diff --git a/cocoa/apple_image.m b/cocoa/apple_image.m
index c6f3ae50c..4eef98530 100644
--- a/cocoa/apple_image.m
+++ b/cocoa/apple_image.m
@@ -146,8 +146,8 @@ static void animate_image_cb( void *ptr )
++ai->currentFrame;
if (ai->currentFrame >= ai->frames) ai->currentFrame = 0;
- [(NSBitmapImageRep *)ai->base.bitmap setProperty: NSImageCurrentFrame withValue: [NSNumber numberWithUnsignedInteger: ai->currentFrame]];
- bitmap_modified( ai->base.bitmap );
+ [(NSBitmapImageRep *)ai->bitmap setProperty: NSImageCurrentFrame withValue: [NSNumber numberWithUnsignedInteger: ai->currentFrame]];
+ bitmap_modified( ai->bitmap );
union content_msg_data data;
data.redraw.full_redraw = true;
@@ -224,6 +224,7 @@ void apple_image_destroy(struct content *c)
nserror apple_image_clone(const struct content *old, struct content **newc)
{
apple_image_content *ai;
+ apple_image_content *ai_old = (apple_image_content *)old;
nserror error;
ai = talloc_zero(0, apple_image_content);
@@ -240,7 +241,7 @@ nserror apple_image_clone(const struct content *old, struct content **newc)
old->status == CONTENT_STATUS_DONE) {
ai->base.width = old->width;
ai->base.height = old->height;
- ai->base.bitmap = (void *)[(id)old->bitmap retain];
+ ai->bitmap = (void *)[(id)ai_old->bitmap retain];
}
*newc = (struct content *) ai;