Made correction necessary for NSWindow.m to build w/ gcc < 3.0. This is necessary to support systems with earlier compilers (such as Darwin).

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@12562 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Gregory John Casamento 2002-02-19 02:33:52 +00:00
parent 2b8be48edf
commit 3572c9dc61
2 changed files with 18 additions and 17 deletions

View file

@ -1,3 +1,8 @@
2002-02-18 Gregory John Casamento <greg_casamento@yahoo.com>
* Source/NSWindow.m ([NSWindow -close]): Changes made earlier
would not compile w/ gcc < 3.0.
2002-02-18 Pierre-Yves Rivaille <pyrivail@ens-lyon.fr> 2002-02-18 Pierre-Yves Rivaille <pyrivail@ens-lyon.fr>
* Source/NSTableHeaderView.m ([NSTableHeaderView -mouseDown:]): * Source/NSTableHeaderView.m ([NSTableHeaderView -mouseDown:]):

View file

@ -2023,25 +2023,21 @@ resetCursorRectsForView(NSView *theView)
*/ */
- (void) close - (void) close
{ {
if (_f.has_closed == YES)
{
// already closed
return;
}
CREATE_AUTORELEASE_POOL(pool);
[nc postNotificationName: NSWindowWillCloseNotification object: self];
_f.has_opened = NO;
[[NSRunLoop currentRunLoop]
cancelPerformSelector: @selector(_handleWindowNeedsDisplay:)
target: self
argument: nil];
[NSApp removeWindowsItem: self];
[self orderOut: self];
RELEASE(pool);
if (_f.has_closed == NO) if (_f.has_closed == NO)
{ {
CREATE_AUTORELEASE_POOL(pool);
[nc postNotificationName: NSWindowWillCloseNotification object: self];
_f.has_opened = NO;
[[NSRunLoop currentRunLoop]
cancelPerformSelector: @selector(_handleWindowNeedsDisplay:)
target: self
argument: nil];
[NSApp removeWindowsItem: self];
[self orderOut: self];
RELEASE(pool);
_f.has_closed = YES; _f.has_closed = YES;
if (_f.is_released_when_closed) if (_f.is_released_when_closed)
{ {