git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@4352 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 1999-06-03 12:36:10 +00:00
parent 1384ea663c
commit f019a501be
3 changed files with 50 additions and 40 deletions

View file

@ -1,7 +1,9 @@
Thu Jun 4 12:15:00 1999 Richard Frith-Macdonald <richard@brainstorm.co.uk>
Thu Jun 4 13:55:00 1999 Richard Frith-Macdonald <richard@brainstorm.co.uk>
* Source/NSCharacterSet.m: prepare for GC
* Source/NSString.m: prepare for GC
* Source/NSTimer.m: tidied and added timeInterval method
* Source/include/NSTimer.h: tidied and added timeInterval method
Tue Jun 2 10:50:00 1999 Richard Frith-Macdonald <richard@brainstorm.co.uk>

View file

@ -1,5 +1,5 @@
/* Declarations for NSTimer for GNUStep
Copyright (C) 1995, 1996 Free Software Foundation, Inc.
Copyright (C) 1995, 1996, 1999 Free Software Foundation, Inc.
Written by: Andrew Kachites McCallum <mccallum@gnu.ai.mit.edu>
Date: 1995
@ -48,31 +48,34 @@
/* Creating timer objects. */
+ scheduledTimerWithTimeInterval: (NSTimeInterval)ti
invocation: invocation
repeats: (BOOL)f;
+ scheduledTimerWithTimeInterval: (NSTimeInterval)ti
target: object
selector: (SEL)selector
userInfo: info
repeats: (BOOL)f;
+ (NSTimer*) scheduledTimerWithTimeInterval: (NSTimeInterval)ti
invocation: invocation
repeats: (BOOL)f;
+ (NSTimer*) scheduledTimerWithTimeInterval: (NSTimeInterval)ti
target: object
selector: (SEL)selector
userInfo: info
repeats: (BOOL)f;
+ timerWithTimeInterval: (NSTimeInterval)ti
invocation: invocation
repeats: (BOOL)f;
+ timerWithTimeInterval: (NSTimeInterval)ti
target: object
selector: (SEL)selector
userInfo: info
repeats: (BOOL)f;
+ (NSTimer*) timerWithTimeInterval: (NSTimeInterval)ti
invocation: invocation
repeats: (BOOL)f;
+ (NSTimer*) timerWithTimeInterval: (NSTimeInterval)ti
target: object
selector: (SEL)selector
userInfo: info
repeats: (BOOL)f;
- (void) fire;
- (void) invalidate;
- (BOOL) isValid; /* This method not in OpenStep */
#ifndef STRICT_OPENSTEP
- (BOOL) isValid;
- (NSTimeInterval) timeInterval;
#endif
- fireDate;
- userInfo;
- (NSDate*) fireDate;
- (id) userInfo;
@end

View file

@ -1,5 +1,5 @@
/* Implementation of NSTimer for GNUstep
Copyright (C) 1995, 1996 Free Software Foundation, Inc.
Copyright (C) 1995, 1996, 1999 Free Software Foundation, Inc.
Written by: Andrew Kachites McCallum <mccallum@gnu.ai.mit.edu>
Created: March 1996
@ -49,9 +49,9 @@
return self;
}
+ timerWithTimeInterval: (NSTimeInterval)ti
invocation: invocation
repeats: (BOOL)f
+ (NSTimer*) timerWithTimeInterval: (NSTimeInterval)ti
invocation: invocation
repeats: (BOOL)f
{
return AUTORELEASE([[self alloc] initWithTimeInterval: ti
targetOrInvocation: invocation
@ -60,11 +60,11 @@
repeats: f]);
}
+ timerWithTimeInterval: (NSTimeInterval)ti
target: object
selector: (SEL)selector
userInfo: info
repeats: (BOOL)f
+ (NSTimer*) timerWithTimeInterval: (NSTimeInterval)ti
target: object
selector: (SEL)selector
userInfo: info
repeats: (BOOL)f
{
return AUTORELEASE([[self alloc] initWithTimeInterval: ti
targetOrInvocation: object
@ -73,9 +73,9 @@
repeats: f]);
}
+ scheduledTimerWithTimeInterval: (NSTimeInterval)ti
invocation: invocation
repeats: (BOOL)f
+ (NSTimer*) scheduledTimerWithTimeInterval: (NSTimeInterval)ti
invocation: invocation
repeats: (BOOL)f
{
id t = [self timerWithTimeInterval: ti
invocation: invocation
@ -84,11 +84,11 @@
return t;
}
+ scheduledTimerWithTimeInterval: (NSTimeInterval)ti
target: object
selector: (SEL)selector
userInfo: info
repeats: (BOOL)f
+ (NSTimer*) scheduledTimerWithTimeInterval: (NSTimeInterval)ti
target: object
selector: (SEL)selector
userInfo: info
repeats: (BOOL)f
{
id t = [self timerWithTimeInterval: ti
target: object
@ -146,12 +146,17 @@
return !_invalidated;
}
- fireDate
- (NSDate*) fireDate
{
return _date;
}
- userInfo
- (NSTimeInterval) timeInterval
{
return _interval;
}
- (id) userInfo
{
return _info;
}