From 79ebab3d917c0a4b06e6dfd655b67bf5d8677c85 Mon Sep 17 00:00:00 2001 From: rmottola Date: Sun, 26 Jul 2015 21:04:57 +0000 Subject: [PATCH] add alphaValue property... although we don't use it anyway it helps to compile stuff git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@38840 72102866-910b-0410-8b05-ffd578937521 --- Headers/AppKit/NSView.h | 10 ++++++++++ Source/NSView.m | 14 ++++++++++++++ 2 files changed, 24 insertions(+) diff --git a/Headers/AppKit/NSView.h b/Headers/AppKit/NSView.h index b9dc998d7..67c97a268 100644 --- a/Headers/AppKit/NSView.h +++ b/Headers/AppKit/NSView.h @@ -119,6 +119,7 @@ PACKAGE_SCOPE NSInteger _gstate; void *_nextKeyView; void *_previousKeyView; + CGFloat _alphaValue; @public /* @@ -228,6 +229,15 @@ PACKAGE_SCOPE - (BOOL) isRotatedFromBase; - (BOOL) isRotatedOrScaledFromBase; +/* + * View Layers + */ + +#if OS_API_VERSION(MAC_OS_X_VERSION_10_5, GS_API_LATEST) +- (CGFloat) alphaValue; +- (void) setAlphaValue: (CGFloat)alpha; +#endif + /* * Converting Coordinates */ diff --git a/Source/NSView.m b/Source/NSView.m index e0f9fb2c7..6e5290819 100644 --- a/Source/NSView.m +++ b/Source/NSView.m @@ -630,6 +630,8 @@ GSSetDragTypes(NSView* obj, NSArray *types) //_nextKeyView = 0; //_previousKeyView = 0; + _alphaValue = 1.0; + return self; } @@ -1639,6 +1641,18 @@ static NSSize _computeScale(NSSize fs, NSSize bs) } } + +- (CGFloat) alphaValue +{ + return _alphaValue; +} + +- (void)setAlphaValue: (CGFloat)alpha +{ + _alphaValue = alpha; +} + + - (NSRect) centerScanRect: (NSRect)aRect { NSAffineTransform *matrix;