mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-30 02:20:37 +00:00
* Source/NSImage.m (-guiDrawInRect:...): Handle dstRect with a zero size
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@33303 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
903996fd17
commit
d0b58a4fd4
2 changed files with 12 additions and 1 deletions
|
@ -1086,7 +1086,14 @@ Fallback for backends other than Cairo. */
|
|||
s = [self size];
|
||||
|
||||
if (NSEqualRects(srcRect, NSZeroRect))
|
||||
srcRect = NSMakeRect(0, 0, s.width, s.height);
|
||||
{
|
||||
srcRect.size = s;
|
||||
/* For -drawAtPoint:fromRect:operation:fraction: used with a zero rect */
|
||||
if (NSEqualSizes(dstRect.size, NSZeroSize))
|
||||
{
|
||||
dstRect.size = s;
|
||||
}
|
||||
}
|
||||
|
||||
if (!dstRect.size.width || !dstRect.size.height
|
||||
|| !srcRect.size.width || !srcRect.size.height)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue