mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-22 17:41:54 +00:00
* Source/NSImage.m (-nativeDrawInRect:...): Compute the rep size
after the nil test. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@33513 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
727e1993f0
commit
f13ac2cd84
2 changed files with 6 additions and 3 deletions
|
@ -934,7 +934,6 @@ behavior precisely matches Cocoa. */
|
|||
{
|
||||
NSGraphicsContext *ctxt = GSCurrentContext();
|
||||
NSSize imgSize = [self size];
|
||||
NSSize repSize;
|
||||
float widthScaleFactor;
|
||||
float heightScaleFactor;
|
||||
NSImageRep *rep;
|
||||
|
@ -954,8 +953,6 @@ behavior precisely matches Cocoa. */
|
|||
rep = [self bestRepresentationForRect: dstRect
|
||||
context: nil
|
||||
hints: nil];
|
||||
repSize = [rep size];
|
||||
|
||||
if (rep == nil)
|
||||
return;
|
||||
|
||||
|
@ -1018,6 +1015,7 @@ behavior precisely matches Cocoa. */
|
|||
int gState;
|
||||
/* The context of the cache window */
|
||||
NSGraphicsContext *cacheCtxt;
|
||||
NSSize repSize = [rep size];
|
||||
/* The size of the cache window that will hold the scaled image */
|
||||
NSSize cacheSize = [[ctxt GSCurrentCTM] transformSize: repSize];
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue