diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2012-01-29 17:19:44 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2012-01-29 17:19:44 (GMT) |
commit | ce3157c263b1c3c3346596eb5ad31d53c95ac135 (patch) | |
tree | 53040e8f6024cafa32bb61391bc131bd032e521d /generic/tkImgPhInstance.c | |
parent | 1f0ffdd4d06989c359d53164ea7fb406af33d329 (diff) | |
parent | 570f0139dce2dee0c35422b973a4664d08adbb88 (diff) | |
download | tk-ce3157c263b1c3c3346596eb5ad31d53c95ac135.zip tk-ce3157c263b1c3c3346596eb5ad31d53c95ac135.tar.gz tk-ce3157c263b1c3c3346596eb5ad31d53c95ac135.tar.bz2 |
Bug-3480634: PNG Images missing in menus on Mac
Diffstat (limited to 'generic/tkImgPhInstance.c')
-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, |