diff options
author | nijtmans@users.sourceforge.net <jan.nijtmans> | 2012-01-29 17:19:44 (GMT) |
---|---|---|
committer | nijtmans@users.sourceforge.net <jan.nijtmans> | 2012-01-29 17:19:44 (GMT) |
commit | 242c0a3cb9a69d25df98d82632a0c9b3468b5588 (patch) | |
tree | 53040e8f6024cafa32bb61391bc131bd032e521d /generic | |
parent | 6238d447a4e8bec1bd90d1019eda6fcb80e588a0 (diff) | |
parent | eae6f41412ae59102d5f28957560924b94fbe869 (diff) | |
download | tk-242c0a3cb9a69d25df98d82632a0c9b3468b5588.zip tk-242c0a3cb9a69d25df98d82632a0c9b3468b5588.tar.gz tk-242c0a3cb9a69d25df98d82632a0c9b3468b5588.tar.bz2 |
Bug-3480634: PNG Images missing in menus on Mac
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tkImgPhInstance.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/generic/tkImgPhInstance.c b/generic/tkImgPhInstance.c index 04f65e2..5429ee3 100644 --- a/generic/tkImgPhInstance.c +++ b/generic/tkImgPhInstance.c @@ -635,7 +635,8 @@ TkImgPhotoDisplay( (unsigned int)width, (unsigned int)height, AllPlanes, ZPixmap); if (bgImg == NULL) { Tk_DeleteErrorHandler(handler); - return; + /* We failed to get the image so draw without blending alpha. It's the best we can do */ + goto fallBack; } BlendComplexAlpha(bgImg, instancePtr, imageX, imageY, width, height); @@ -657,6 +658,7 @@ TkImgPhotoDisplay( * origin appropriately, and use it when drawing the image. */ + fallBack: TkSetRegion(display, instancePtr->gc, instancePtr->masterPtr->validRegion); XSetClipOrigin(display, instancePtr->gc, drawableX - imageX, |