diff options
author | das <das> | 2006-06-14 21:18:47 (GMT) |
---|---|---|
committer | das <das> | 2006-06-14 21:18:47 (GMT) |
commit | 1fd8c27bae2a921521024e8fa33336f4a45a9295 (patch) | |
tree | f2eb65f8b9e8b4145a71a6566999c452a83786aa /macosx/tkMacOSXSubwindows.c | |
parent | d7b0d0af547943f11f02255a54433c9d702adc0b (diff) | |
download | tk-1fd8c27bae2a921521024e8fa33336f4a45a9295.zip tk-1fd8c27bae2a921521024e8fa33336f4a45a9295.tar.gz tk-1fd8c27bae2a921521024e8fa33336f4a45a9295.tar.bz2 |
* macosx/tkMacOSXSubwindows.c (TkMacOSXInvalidateWindow): ensure invalid
clip regions are recreated via TkMacOSXUpdateClipRgn() before they are
used; correct call order of TkMacOSXInvalidateWindow() and
TkMacOSXInvalClipRgns() throughout. [Bug 1501922]
* macosx/tkMacOSXDraw.c (TkPutImage): implement drawing of very wide
images in slices of less than 4096 pixels to workaround CopyBits
limitation. [Bug 950121]
Diffstat (limited to 'macosx/tkMacOSXSubwindows.c')
-rw-r--r-- | macosx/tkMacOSXSubwindows.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/macosx/tkMacOSXSubwindows.c b/macosx/tkMacOSXSubwindows.c index 1ac6579..92295fb 100644 --- a/macosx/tkMacOSXSubwindows.c +++ b/macosx/tkMacOSXSubwindows.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkMacOSXSubwindows.c,v 1.13 2006/05/12 18:17:48 das Exp $ + * RCS: @(#) $Id: tkMacOSXSubwindows.c,v 1.14 2006/06/14 21:18:47 das Exp $ */ #include "tkMacOSXInt.h" @@ -231,8 +231,8 @@ XMapWindow( * Generate damage for that area of the window */ SetGWorld(destPort, NULL); - TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW); TkMacOSXInvalClipRgns((Tk_Window) macWin->winPtr->parentPtr); + TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW); } } @@ -368,8 +368,8 @@ XResizeWindow( if (havePort) { SetPort(destPort); - TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr); TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW); + TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr); } deltaX = macParent->xOff + macWin->winPtr->changes.x - macWin->xOff; @@ -402,8 +402,8 @@ XResizeWindow( if (havePort) { SetPort(destPort); - TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr); TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW); + TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr); } deltaX = - macWin->xOff; deltaY = - macWin->yOff; @@ -497,14 +497,12 @@ XMoveResizeWindow( * region. It is currently assumed that Tk will need * to completely redraw anway. */ - if (havePort) { SetPort( destPort); SizeWindow(GetWindowFromPort(destPort), (short) width, (short) height, false); MoveWindowStructure(GetWindowFromPort(destPort), x, y); - /* TODO: is the following right? */ TkMacOSXInvalidateWindow(macWin, TK_WINDOW_ONLY); TkMacOSXInvalClipRgns((Tk_Window) macWin->winPtr); } @@ -541,8 +539,8 @@ XMoveResizeWindow( if (havePort) { SetPort( destPort); - TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr); TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW); + TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr); } deltaX = - macWin->xOff; @@ -615,7 +613,6 @@ XMoveWindow( SetPort(destPort); MoveWindowStructure( GetWindowFromPort(destPort), x, y); - /* TODO: is the following right? */ TkMacOSXInvalidateWindow(macWin, TK_WINDOW_ONLY); TkMacOSXInvalClipRgns((Tk_Window) macWin->winPtr); } @@ -651,8 +648,8 @@ XMoveWindow( if (havePort) { SetPort(destPort); - TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr); TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW); + TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr); } deltaX = - macWin->xOff; @@ -1046,8 +1043,11 @@ TkMacOSXInvalidateWindow( grafPtr = TkMacOSXGetDrawablePort((Drawable)macWin); windowRef = GetWindowFromPort(grafPtr); + if (macWin->flags & TK_CLIP_INVALID) { + TkMacOSXUpdateClipRgn(macWin->winPtr); + } if (flag == TK_WINDOW_ONLY) { - InvalWindowRgn(windowRef,macWin->clipRgn); + InvalWindowRgn(windowRef, macWin->clipRgn); } else { if (!EmptyRgn(macWin->aboveClipRgn)) { InvalWindowRgn(windowRef, macWin->aboveClipRgn); |