Index: src/OFCondition.h ================================================================== --- src/OFCondition.h +++ src/OFCondition.h @@ -70,11 +70,11 @@ * to check the condition again after @ref waitForTimeInterval: returned! * * @param timeInterval The time interval until the timeout is reached * @return Whether the condition has been signaled */ -- (bool)waitForTimeInterval: (of_time_interval_t)timeInterval; +- (bool)waitForTimeInterval: (OFTimeInterval)timeInterval; #ifdef OF_AMIGAOS /** * @brief Blocks the current thread until another thread calls @ref signal, * @ref broadcast, the timeout is reached or an Exec Signal is received. @@ -84,11 +84,11 @@ * @param timeInterval The time interval until the timeout is reached * @param signalMask A pointer to a signal mask of Exec Signals to receive. * This is modified and set to the mask of signals received. * @return Whether the condition has been signaled or a signal received */ -- (bool)waitForTimeInterval: (of_time_interval_t)timeInterval +- (bool)waitForTimeInterval: (OFTimeInterval)timeInterval orExecSignal: (ULONG *)signalMask; #endif /** * @brief Blocks the current thread until another thread calls @ref signal, Index: src/OFCondition.m ================================================================== --- src/OFCondition.m +++ src/OFCondition.m @@ -84,11 +84,11 @@ exceptionWithCondition: self errNo: error]; } #endif -- (bool)waitForTimeInterval: (of_time_interval_t)timeInterval +- (bool)waitForTimeInterval: (OFTimeInterval)timeInterval { int error = of_condition_timed_wait(&_condition, &_mutex, timeInterval); if (error == ETIMEDOUT) return false; @@ -100,11 +100,11 @@ return true; } #ifdef OF_AMIGAOS -- (bool)waitForTimeInterval: (of_time_interval_t)timeInterval +- (bool)waitForTimeInterval: (OFTimeInterval)timeInterval orExecSignal: (ULONG *)signalMask { int error = of_condition_timed_wait_or_signal(&_condition, &_mutex, timeInterval, signalMask); Index: src/OFDNSResolver.h ================================================================== --- src/OFDNSResolver.h +++ src/OFDNSResolver.h @@ -163,11 +163,11 @@ /** * @brief The timeout, in seconds, after which the next name server should be * tried. */ -@property (nonatomic) of_time_interval_t timeout; +@property (nonatomic) OFTimeInterval timeout; /** * @brief The number of attempts before giving up to resolve a host. * * Trying all name servers once is considered a single attempt. @@ -187,11 +187,11 @@ /** * @brief The interval in seconds in which the config should be reloaded. * * Setting this to 0 disables config reloading. */ -@property (nonatomic) of_time_interval_t configReloadInterval; +@property (nonatomic) OFTimeInterval configReloadInterval; /** * @brief Creates a new, autoreleased OFDNSResolver. */ + (instancetype)resolver; Index: src/OFDNSResolver.m ================================================================== --- src/OFDNSResolver.m +++ src/OFDNSResolver.m @@ -645,16 +645,16 @@ OFArray *old = _settings->_searchDomains; _settings->_searchDomains = [searchDomains copy]; [old release]; } -- (of_time_interval_t)timeout +- (OFTimeInterval)timeout { return _settings->_timeout; } -- (void)setTimeout: (of_time_interval_t)timeout +- (void)setTimeout: (OFTimeInterval)timeout { _settings->_timeout = timeout; } - (unsigned int)maxAttempts @@ -687,16 +687,16 @@ - (void)setUsesTCP: (bool)usesTCP { _settings->_usesTCP = usesTCP; } -- (of_time_interval_t)configReloadInterval +- (OFTimeInterval)configReloadInterval { return _settings->_configReloadInterval; } -- (void)setConfigReloadInterval: (of_time_interval_t)configReloadInterval +- (void)setConfigReloadInterval: (OFTimeInterval)configReloadInterval { _settings->_configReloadInterval = configReloadInterval; } - (void)of_sendQueryForContext: (OFDNSResolverContext *)context Index: src/OFDNSResolverSettings.h ================================================================== --- src/OFDNSResolverSettings.h +++ src/OFDNSResolverSettings.h @@ -27,17 +27,17 @@ OFDictionary OF_GENERIC(OFString *, OFArray OF_GENERIC(OFString *) *) *_staticHosts; OFArray OF_GENERIC(OFString *) *_nameServers; OFString *_Nullable _localDomain; OFArray OF_GENERIC(OFString *) *_searchDomains; - of_time_interval_t _timeout; + OFTimeInterval _timeout; unsigned int _maxAttempts, _minNumberOfDotsInAbsoluteName; bool _usesTCP; - of_time_interval_t _configReloadInterval; + OFTimeInterval _configReloadInterval; @protected OFDate *_lastConfigReload; } - (void)reload; @end OF_ASSUME_NONNULL_END Index: src/OFDate.h ================================================================== --- src/OFDate.h +++ src/OFDate.h @@ -31,11 +31,11 @@ OF_SUBCLASSING_RESTRICTED #endif @interface OFDate: OFObject { - of_time_interval_t _seconds; + OFTimeInterval _seconds; } #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nonatomic) OFDate *distantFuture; @property (class, readonly, nonatomic) OFDate *distantPast; @@ -122,16 +122,16 @@ @property (readonly, nonatomic) unsigned short localDayOfYear; /** * @brief The seconds since 1970-01-01T00:00:00Z. */ -@property (readonly, nonatomic) of_time_interval_t timeIntervalSince1970; +@property (readonly, nonatomic) OFTimeInterval timeIntervalSince1970; /** * @brief The seconds the date is in the future. */ -@property (readonly, nonatomic) of_time_interval_t timeIntervalSinceNow; +@property (readonly, nonatomic) OFTimeInterval timeIntervalSinceNow; /** * @brief Creates a new OFDate with the current date and time. * * @return A new, autoreleased OFDate with the current date and time @@ -143,19 +143,19 @@ * 1970-01-01T00:00:00Z. * * @param seconds The seconds since 1970-01-01T00:00:00Z * @return A new, autoreleased OFDate with the specified date and time */ -+ (instancetype)dateWithTimeIntervalSince1970: (of_time_interval_t)seconds; ++ (instancetype)dateWithTimeIntervalSince1970: (OFTimeInterval)seconds; /** * @brief Creates a new OFDate with the specified date and time since now. * * @param seconds The seconds since now * @return A new, autoreleased OFDate with the specified date and time */ -+ (instancetype)dateWithTimeIntervalSinceNow: (of_time_interval_t)seconds; ++ (instancetype)dateWithTimeIntervalSinceNow: (OFTimeInterval)seconds; /** * @brief Creates a new OFDate with the specified string in the specified * format. * @@ -215,21 +215,21 @@ * time since 1970-01-01T00:00:00Z. * * @param seconds The seconds since 1970-01-01T00:00:00Z * @return An initialized OFDate with the specified date and time */ -- (instancetype)initWithTimeIntervalSince1970: (of_time_interval_t)seconds +- (instancetype)initWithTimeIntervalSince1970: (OFTimeInterval)seconds OF_DESIGNATED_INITIALIZER; /** * @brief Initializes an already allocated OFDate with the specified date and * time since now. * * @param seconds The seconds since now * @return An initialized OFDate with the specified date and time */ -- (instancetype)initWithTimeIntervalSinceNow: (of_time_interval_t)seconds; +- (instancetype)initWithTimeIntervalSinceNow: (OFTimeInterval)seconds; /** * @brief Initializes an already allocated OFDate with the specified string in * the specified format. * @@ -319,17 +319,17 @@ * @brief Returns the seconds the receiver is after the date. * * @param otherDate Date date to generate the difference with receiver * @return The seconds the receiver is after the date. */ -- (of_time_interval_t)timeIntervalSinceDate: (OFDate *)otherDate; +- (OFTimeInterval)timeIntervalSinceDate: (OFDate *)otherDate; /** * @brief Creates a new date with the specified time interval added. * * @param seconds The seconds after the date * @return A new, autoreleased OFDate */ -- (OFDate *)dateByAddingTimeInterval: (of_time_interval_t)seconds; +- (OFDate *)dateByAddingTimeInterval: (OFTimeInterval)seconds; @end OF_ASSUME_NONNULL_END Index: src/OFDate.m ================================================================== --- src/OFDate.m +++ src/OFDate.m @@ -89,20 +89,20 @@ { distantPast = [[OFDateSingleton alloc] initWithTimeIntervalSince1970: -62167219200.0]; } -static of_time_interval_t +static OFTimeInterval now(void) { struct timeval tv; - of_time_interval_t seconds; + OFTimeInterval seconds; OF_ENSURE(gettimeofday(&tv, NULL) == 0); seconds = tv.tv_sec; - seconds += (of_time_interval_t)tv.tv_usec / 1000000; + seconds += (OFTimeInterval)tv.tv_usec / 1000000; return seconds; } #if (!defined(HAVE_GMTIME_R) || !defined(HAVE_LOCALTIME_R)) && \ @@ -120,11 +120,11 @@ static __time64_t (*func__mktime64)(struct tm *); #endif #ifdef HAVE_GMTIME_R # define GMTIME_RET(field) \ - of_time_interval_t timeInterval = self.timeIntervalSince1970; \ + OFTimeInterval timeInterval = self.timeIntervalSince1970; \ time_t seconds = (time_t)timeInterval; \ struct tm tm; \ \ if (seconds != trunc(timeInterval)) \ @throw [OFOutOfRangeException exception]; \ @@ -132,11 +132,11 @@ if (gmtime_r(&seconds, &tm) == NULL) \ @throw [OFOutOfRangeException exception]; \ \ return tm.field; # define LOCALTIME_RET(field) \ - of_time_interval_t timeInterval = self.timeIntervalSince1970; \ + OFTimeInterval timeInterval = self.timeIntervalSince1970; \ time_t seconds = (time_t)timeInterval; \ struct tm tm; \ \ if (seconds != trunc(timeInterval)) \ @throw [OFOutOfRangeException exception]; \ @@ -146,11 +146,11 @@ \ return tm.field; #else # ifdef OF_HAVE_THREADS # define GMTIME_RET(field) \ - of_time_interval_t timeInterval = self.timeIntervalSince1970; \ + OFTimeInterval timeInterval = self.timeIntervalSince1970; \ time_t seconds = (time_t)timeInterval; \ struct tm *tm; \ \ if (seconds != trunc(timeInterval)) \ @throw [OFOutOfRangeException exception]; \ @@ -164,11 +164,11 @@ return tm->field; \ } @finally { \ [mutex unlock]; \ } # define LOCALTIME_RET(field) \ - of_time_interval_t timeInterval = self.timeIntervalSince1970; \ + OFTimeInterval timeInterval = self.timeIntervalSince1970; \ time_t seconds = (time_t)timeInterval; \ struct tm *tm; \ \ if (seconds != trunc(timeInterval)) \ @throw [OFOutOfRangeException exception]; \ @@ -183,11 +183,11 @@ } @finally { \ [mutex unlock]; \ } # else # define GMTIME_RET(field) \ - of_time_interval_t timeInterval = self.timeIntervalSince1970; \ + OFTimeInterval timeInterval = self.timeIntervalSince1970; \ time_t seconds = (time_t)timeInterval; \ struct tm *tm; \ \ if (seconds != trunc(timeInterval)) \ @throw [OFOutOfRangeException exception]; \ @@ -195,11 +195,11 @@ if ((tm = gmtime(&seconds)) == NULL) \ @throw [OFOutOfRangeException exception]; \ \ return tm->field; # define LOCALTIME_RET(field) \ - of_time_interval_t timeInterval = self.timeIntervalSince1970; \ + OFTimeInterval timeInterval = self.timeIntervalSince1970; \ time_t seconds = (time_t)timeInterval; \ struct tm *tm; \ \ if (seconds != trunc(timeInterval)) \ @throw [OFOutOfRangeException exception]; \ @@ -286,11 +286,11 @@ /* We intentionally don't call into super, so silence the warning. */ # pragma clang diagnostic push # pragma clang diagnostic ignored "-Wunknown-pragmas" # pragma clang diagnostic ignored "-Wobjc-designated-initializers" #endif -- (instancetype)initWithTimeIntervalSince1970: (of_time_interval_t)seconds +- (instancetype)initWithTimeIntervalSince1970: (OFTimeInterval)seconds { #if defined(OF_OBJFW_RUNTIME) && UINTPTR_MAX == UINT64_MAX uint64_t value; #endif @@ -321,11 +321,11 @@ #endif @end #if defined(OF_OBJFW_RUNTIME) && UINTPTR_MAX == UINT64_MAX @implementation OFTaggedPointerDate -- (of_time_interval_t)timeIntervalSince1970 +- (OFTimeInterval)timeIntervalSince1970 { uint64_t value = (uint64_t)object_getTaggedPointerValue(self); value |= UINT64_C(4) << 60; @@ -380,17 +380,17 @@ + (instancetype)date { return [[[self alloc] init] autorelease]; } -+ (instancetype)dateWithTimeIntervalSince1970: (of_time_interval_t)seconds ++ (instancetype)dateWithTimeIntervalSince1970: (OFTimeInterval)seconds { return [[[self alloc] initWithTimeIntervalSince1970: seconds] autorelease]; } -+ (instancetype)dateWithTimeIntervalSinceNow: (of_time_interval_t)seconds ++ (instancetype)dateWithTimeIntervalSinceNow: (OFTimeInterval)seconds { return [[[self alloc] initWithTimeIntervalSinceNow: seconds] autorelease]; } @@ -425,20 +425,20 @@ - (instancetype)init { return [self initWithTimeIntervalSince1970: now()]; } -- (instancetype)initWithTimeIntervalSince1970: (of_time_interval_t)seconds +- (instancetype)initWithTimeIntervalSince1970: (OFTimeInterval)seconds { self = [super init]; _seconds = seconds; return self; } -- (instancetype)initWithTimeIntervalSinceNow: (of_time_interval_t)seconds +- (instancetype)initWithTimeIntervalSinceNow: (OFTimeInterval)seconds { return [self initWithTimeIntervalSince1970: now() + seconds]; } - (instancetype)initWithDateString: (OFString *)string @@ -468,11 +468,11 @@ * of_strptime() can never set this to SHRT_MAX, no matter what is * passed to it, so this is a safe way to figure out if the date * contains a time zone. */ short tz = SHRT_MAX; - of_time_interval_t seconds; + OFTimeInterval seconds; if (of_strptime(UTF8String, format.UTF8String, &tm, &tz) != UTF8String + string.UTF8StringLength) @throw [OFInvalidFormatException exception]; @@ -496,11 +496,11 @@ return [self initWithTimeIntervalSince1970: seconds]; } - (instancetype)initWithSerialization: (OFXMLElement *)element { - of_time_interval_t seconds; + OFTimeInterval seconds; @try { void *pool = objc_autoreleasePoolPush(); unsigned long long value; @@ -603,11 +603,11 @@ } - (OFData *)messagePackRepresentation { void *pool = objc_autoreleasePoolPush(); - of_time_interval_t timeInterval = self.timeIntervalSince1970; + OFTimeInterval timeInterval = self.timeIntervalSince1970; int64_t seconds = (int64_t)timeInterval; uint32_t nanoseconds = (uint32_t)((timeInterval - trunc(timeInterval)) * 1000000000); OFData *ret; @@ -656,11 +656,11 @@ return [ret autorelease]; } - (unsigned long)microsecond { - of_time_interval_t timeInterval = self.timeIntervalSince1970; + OFTimeInterval timeInterval = self.timeIntervalSince1970; return (unsigned long)((timeInterval - trunc(timeInterval)) * 1000000); } - (unsigned char)second @@ -739,11 +739,11 @@ } - (OFString *)dateStringWithFormat: (OFConstantString *)format { OFString *ret; - of_time_interval_t timeInterval = self.timeIntervalSince1970; + OFTimeInterval timeInterval = self.timeIntervalSince1970; time_t seconds = (time_t)timeInterval; struct tm tm; size_t pageSize; #ifndef OF_WINDOWS char *buffer; @@ -799,11 +799,11 @@ } - (OFString *)localDateStringWithFormat: (OFConstantString *)format { OFString *ret; - of_time_interval_t timeInterval = self.timeIntervalSince1970; + OFTimeInterval timeInterval = self.timeIntervalSince1970; time_t seconds = (time_t)timeInterval; struct tm tm; size_t pageSize; #ifndef OF_WINDOWS char *buffer; @@ -878,34 +878,34 @@ return otherDate; return self; } -- (of_time_interval_t)timeIntervalSince1970 +- (OFTimeInterval)timeIntervalSince1970 { return _seconds; } -- (of_time_interval_t)timeIntervalSinceDate: (OFDate *)otherDate +- (OFTimeInterval)timeIntervalSinceDate: (OFDate *)otherDate { return self.timeIntervalSince1970 - otherDate.timeIntervalSince1970; } -- (of_time_interval_t)timeIntervalSinceNow +- (OFTimeInterval)timeIntervalSinceNow { struct timeval t; - of_time_interval_t seconds; + OFTimeInterval seconds; OF_ENSURE(gettimeofday(&t, NULL) == 0); seconds = t.tv_sec; - seconds += (of_time_interval_t)t.tv_usec / 1000000; + seconds += (OFTimeInterval)t.tv_usec / 1000000; return self.timeIntervalSince1970 - seconds; } -- (OFDate *)dateByAddingTimeInterval: (of_time_interval_t)seconds +- (OFDate *)dateByAddingTimeInterval: (OFTimeInterval)seconds { return [OFDate dateWithTimeIntervalSince1970: self.timeIntervalSince1970 + seconds]; } @end Index: src/OFEpollKernelEventObserver.m ================================================================== --- src/OFEpollKernelEventObserver.m +++ src/OFEpollKernelEventObserver.m @@ -185,11 +185,11 @@ events: EPOLLOUT]; [super removeObjectForWriting: object]; } -- (void)observeForTimeInterval: (of_time_interval_t)timeInterval +- (void)observeForTimeInterval: (OFTimeInterval)timeInterval { OFNull *nullObject = [OFNull null]; struct epoll_event eventList[EVENTLIST_SIZE]; int events; Index: src/OFFileURLHandler.m ================================================================== --- src/OFFileURLHandler.m +++ src/OFFileURLHandler.m @@ -87,14 +87,14 @@ #if defined(OF_WINDOWS) || defined(OF_AMIGAOS) typedef struct { of_offset_t st_size; unsigned int st_mode; - of_time_interval_t st_atime, st_mtime, st_ctime; + OFTimeInterval st_atime, st_mtime, st_ctime; # ifdef OF_WINDOWS # define HAVE_STRUCT_STAT_ST_BIRTHTIME - of_time_interval_t st_birthtime; + OFTimeInterval st_birthtime; DWORD fileAttributes; # endif } of_stat_t; #elif defined(HAVE_STAT64) typedef struct stat64 of_stat_t; @@ -132,11 +132,11 @@ static WINAPI BOOLEAN (*func_CreateHardLinkW)(LPCWSTR, LPCWSTR, LPSECURITY_ATTRIBUTES); #endif #ifdef OF_WINDOWS -static of_time_interval_t +static OFTimeInterval filetimeToTimeInterval(const FILETIME *filetime) { return (double)((int64_t)filetime->dwHighDateTime << 32 | filetime->dwLowDateTime) / 10000000.0 - 11644473600.0; } @@ -260,11 +260,11 @@ # ifdef OF_AMIGAOS4 struct ExamineData *ed; # else struct FileInfoBlock fib; # endif - of_time_interval_t timeInterval; + OFTimeInterval timeInterval; struct Locale *locale; struct DateStamp *date; if ((lock = Lock([path cStringWithEncoding: [OFLocale encoding]], SHARED_LOCK)) == 0) @@ -313,11 +313,11 @@ # else date = &fib.fib_Date; # endif timeInterval += date->ds_Days * 86400.0; timeInterval += date->ds_Minute * 60.0; - timeInterval += date->ds_Tick / (of_time_interval_t)TICKS_PER_SECOND; + timeInterval += date->ds_Tick / (OFTimeInterval)TICKS_PER_SECOND; buffer->st_atime = buffer->st_mtime = buffer->st_ctime = timeInterval; # ifdef OF_AMIGAOS4 FreeDosObject(DOS_EXAMINEDATA, ed); @@ -701,11 +701,11 @@ failedAttribute: attributeKey errNo: errno]; } #elif defined(OF_AMIGAOS) /* AmigaOS does not support access time. */ - of_time_interval_t modificationTime = + OFTimeInterval modificationTime = modificationDate.timeIntervalSince1970; struct Locale *locale; struct DateStamp date; modificationTime -= 252460800; /* 1978-01-01 */ @@ -737,13 +737,12 @@ exceptionWithURL: URL attributes: attributes failedAttribute: attributeKey errNo: retrieveError()]; #else - of_time_interval_t lastAccessTime = - lastAccessDate.timeIntervalSince1970; - of_time_interval_t modificationTime = + OFTimeInterval lastAccessTime = lastAccessDate.timeIntervalSince1970; + OFTimeInterval modificationTime = modificationDate.timeIntervalSince1970; struct timeval times[2] = { { .tv_sec = (time_t)lastAccessTime, .tv_usec = Index: src/OFKernelEventObserver.h ================================================================== --- src/OFKernelEventObserver.h +++ src/OFKernelEventObserver.h @@ -211,11 +211,11 @@ * @brief Observes all objects until an event happens on an object or the * timeout is reached. * * @param timeInterval The time to wait for an event, in seconds */ -- (void)observeForTimeInterval: (of_time_interval_t)timeInterval; +- (void)observeForTimeInterval: (OFTimeInterval)timeInterval; /** * @brief Observes all objects until an event happens on an object or the * specified date is reached. * Index: src/OFKernelEventObserver.m ================================================================== --- src/OFKernelEventObserver.m +++ src/OFKernelEventObserver.m @@ -243,11 +243,11 @@ - (void)observe { [self observeForTimeInterval: -1]; } -- (void)observeForTimeInterval: (of_time_interval_t)timeInterval +- (void)observeForTimeInterval: (OFTimeInterval)timeInterval { OF_UNRECOGNIZED_SELECTOR } - (void)observeUntilDate: (OFDate *)date Index: src/OFKqueueKernelEventObserver.m ================================================================== --- src/OFKqueueKernelEventObserver.m +++ src/OFKqueueKernelEventObserver.m @@ -151,11 +151,11 @@ errNo: errno]; [super removeObjectForWriting: object]; } -- (void)observeForTimeInterval: (of_time_interval_t)timeInterval +- (void)observeForTimeInterval: (OFTimeInterval)timeInterval { struct timespec timeout; struct kevent eventList[EVENTLIST_SIZE]; int events; Index: src/OFObject.h ================================================================== --- src/OFObject.h +++ src/OFObject.h @@ -138,11 +138,11 @@ } /** * @brief A time interval in seconds. */ -typedef double of_time_interval_t; +typedef double OFTimeInterval; /** * @struct of_point_t OFObject.h ObjFW/OFObject.h * * @brief A point. @@ -821,11 +821,11 @@ * @brief Performs the specified selector after the specified delay. * * @param selector The selector to perform * @param delay The delay after which the selector will be performed */ -- (void)performSelector: (SEL)selector afterDelay: (of_time_interval_t)delay; +- (void)performSelector: (SEL)selector afterDelay: (OFTimeInterval)delay; /** * @brief Performs the specified selector with the specified object after the * specified delay. * @@ -834,11 +834,11 @@ * selector * @param delay The delay after which the selector will be performed */ - (void)performSelector: (SEL)selector withObject: (nullable id)object - afterDelay: (of_time_interval_t)delay; + afterDelay: (OFTimeInterval)delay; /** * @brief Performs the specified selector with the specified objects after the * specified delay. * @@ -850,11 +850,11 @@ * @param delay The delay after which the selector will be performed */ - (void)performSelector: (SEL)selector withObject: (nullable id)object1 withObject: (nullable id)object2 - afterDelay: (of_time_interval_t)delay; + afterDelay: (OFTimeInterval)delay; /** * @brief Performs the specified selector with the specified objects after the * specified delay. * @@ -869,11 +869,11 @@ */ - (void)performSelector: (SEL)selector withObject: (nullable id)object1 withObject: (nullable id)object2 withObject: (nullable id)object3 - afterDelay: (of_time_interval_t)delay; + afterDelay: (OFTimeInterval)delay; /** * @brief Performs the specified selector with the specified objects after the * specified delay. * @@ -891,11 +891,11 @@ - (void)performSelector: (SEL)selector withObject: (nullable id)object1 withObject: (nullable id)object2 withObject: (nullable id)object3 withObject: (nullable id)object4 - afterDelay: (of_time_interval_t)delay; + afterDelay: (OFTimeInterval)delay; # ifdef OF_HAVE_THREADS /** * @brief Performs the specified selector on the specified thread. * @@ -1072,11 +1072,11 @@ * @param thread The thread on which to perform the selector * @param delay The delay after which the selector will be performed */ - (void)performSelector: (SEL)selector onThread: (OFThread *)thread - afterDelay: (of_time_interval_t)delay; + afterDelay: (OFTimeInterval)delay; /** * @brief Performs the specified selector on the specified thread with the * specified object after the specified delay. * @@ -1087,11 +1087,11 @@ * @param delay The delay after which the selector will be performed */ - (void)performSelector: (SEL)selector onThread: (OFThread *)thread withObject: (nullable id)object - afterDelay: (of_time_interval_t)delay; + afterDelay: (OFTimeInterval)delay; /** * @brief Performs the specified selector on the specified thread with the * specified objects after the specified delay. * @@ -1105,11 +1105,11 @@ */ - (void)performSelector: (SEL)selector onThread: (OFThread *)thread withObject: (nullable id)object1 withObject: (nullable id)object2 - afterDelay: (of_time_interval_t)delay; + afterDelay: (OFTimeInterval)delay; /** * @brief Performs the specified selector on the specified thread with the * specified objects after the specified delay. * @@ -1126,11 +1126,11 @@ - (void)performSelector: (SEL)selector onThread: (OFThread *)thread withObject: (nullable id)object1 withObject: (nullable id)object2 withObject: (nullable id)object3 - afterDelay: (of_time_interval_t)delay; + afterDelay: (OFTimeInterval)delay; /** * @brief Performs the specified selector on the specified thread with the * specified objects after the specified delay. * @@ -1150,11 +1150,11 @@ onThread: (OFThread *)thread withObject: (nullable id)object1 withObject: (nullable id)object2 withObject: (nullable id)object3 withObject: (nullable id)object4 - afterDelay: (of_time_interval_t)delay; + afterDelay: (OFTimeInterval)delay; # endif /** * @brief This method is called when @ref resolveClassMethod: or * @ref resolveInstanceMethod: returned false. It should return a target Index: src/OFObject.m ================================================================== --- src/OFObject.m +++ src/OFObject.m @@ -663,11 +663,11 @@ #endif return imp(self, selector, object1, object2, object3, object4); } -- (void)performSelector: (SEL)selector afterDelay: (of_time_interval_t)delay +- (void)performSelector: (SEL)selector afterDelay: (OFTimeInterval)delay { void *pool = objc_autoreleasePoolPush(); [OFTimer scheduledTimerWithTimeInterval: delay target: self @@ -677,11 +677,11 @@ objc_autoreleasePoolPop(pool); } - (void)performSelector: (SEL)selector withObject: (id)object - afterDelay: (of_time_interval_t)delay + afterDelay: (OFTimeInterval)delay { void *pool = objc_autoreleasePoolPush(); [OFTimer scheduledTimerWithTimeInterval: delay target: self @@ -693,11 +693,11 @@ } - (void)performSelector: (SEL)selector withObject: (id)object1 withObject: (id)object2 - afterDelay: (of_time_interval_t)delay + afterDelay: (OFTimeInterval)delay { void *pool = objc_autoreleasePoolPush(); [OFTimer scheduledTimerWithTimeInterval: delay target: self @@ -711,11 +711,11 @@ - (void)performSelector: (SEL)selector withObject: (id)object1 withObject: (id)object2 withObject: (id)object3 - afterDelay: (of_time_interval_t)delay + afterDelay: (OFTimeInterval)delay { void *pool = objc_autoreleasePoolPush(); [OFTimer scheduledTimerWithTimeInterval: delay target: self @@ -731,11 +731,11 @@ - (void)performSelector: (SEL)selector withObject: (id)object1 withObject: (id)object2 withObject: (id)object3 withObject: (id)object4 - afterDelay: (of_time_interval_t)delay + afterDelay: (OFTimeInterval)delay { void *pool = objc_autoreleasePoolPush(); [OFTimer scheduledTimerWithTimeInterval: delay target: self @@ -955,11 +955,11 @@ objc_autoreleasePoolPop(pool); } - (void)performSelector: (SEL)selector onThread: (OFThread *)thread - afterDelay: (of_time_interval_t)delay + afterDelay: (OFTimeInterval)delay { void *pool = objc_autoreleasePoolPush(); [thread.runLoop addTimer: [OFTimer timerWithTimeInterval: delay target: self @@ -970,11 +970,11 @@ } - (void)performSelector: (SEL)selector onThread: (OFThread *)thread withObject: (id)object - afterDelay: (of_time_interval_t)delay + afterDelay: (OFTimeInterval)delay { void *pool = objc_autoreleasePoolPush(); [thread.runLoop addTimer: [OFTimer timerWithTimeInterval: delay target: self @@ -987,11 +987,11 @@ - (void)performSelector: (SEL)selector onThread: (OFThread *)thread withObject: (id)object1 withObject: (id)object2 - afterDelay: (of_time_interval_t)delay + afterDelay: (OFTimeInterval)delay { void *pool = objc_autoreleasePoolPush(); [thread.runLoop addTimer: [OFTimer timerWithTimeInterval: delay target: self @@ -1006,11 +1006,11 @@ - (void)performSelector: (SEL)selector onThread: (OFThread *)thread withObject: (id)object1 withObject: (id)object2 withObject: (id)object3 - afterDelay: (of_time_interval_t)delay + afterDelay: (OFTimeInterval)delay { void *pool = objc_autoreleasePoolPush(); [thread.runLoop addTimer: [OFTimer timerWithTimeInterval: delay target: self @@ -1027,11 +1027,11 @@ onThread: (OFThread *)thread withObject: (id)object1 withObject: (id)object2 withObject: (id)object3 withObject: (id)object4 - afterDelay: (of_time_interval_t)delay + afterDelay: (OFTimeInterval)delay { void *pool = objc_autoreleasePoolPush(); [thread.runLoop addTimer: [OFTimer timerWithTimeInterval: delay target: self Index: src/OFPollKernelEventObserver.m ================================================================== --- src/OFPollKernelEventObserver.m +++ src/OFPollKernelEventObserver.m @@ -160,11 +160,11 @@ removeObject(self, object, object.fileDescriptorForWriting, POLLOUT); [super removeObjectForWriting: object]; } -- (void)observeForTimeInterval: (of_time_interval_t)timeInterval +- (void)observeForTimeInterval: (OFTimeInterval)timeInterval { void *pool; struct pollfd *FDs; int events; size_t nFDs; Index: src/OFRunLoop.m ================================================================== --- src/OFRunLoop.m +++ src/OFRunLoop.m @@ -1620,11 +1620,11 @@ } #endif /* Watch for I/O events until the next timer is due */ if (nextTimer != nil || deadline != nil) { - of_time_interval_t timeout; + OFTimeInterval timeout; if (nextTimer != nil && deadline == nil) timeout = nextTimer.timeIntervalSinceNow; else if (nextTimer == nil && deadline != nil) timeout = deadline.timeIntervalSinceNow; Index: src/OFSelectKernelEventObserver.m ================================================================== --- src/OFSelectKernelEventObserver.m +++ src/OFSelectKernelEventObserver.m @@ -167,11 +167,11 @@ FD_CLR((of_socket_t)fd, &_writeFDs); [super removeObjectForWriting: object]; } -- (void)observeForTimeInterval: (of_time_interval_t)timeInterval +- (void)observeForTimeInterval: (OFTimeInterval)timeInterval { fd_set readFDs; fd_set writeFDs; struct timeval timeout; int events; Index: src/OFTarArchiveEntry.m ================================================================== --- src/OFTarArchiveEntry.m +++ src/OFTarArchiveEntry.m @@ -102,11 +102,11 @@ header + 116, 8, ULONG_MAX); _size = (unsigned long long)octalValueFromBuffer( header + 124, 12, ULLONG_MAX); _modificationDate = [[OFDate alloc] initWithTimeIntervalSince1970: - (of_time_interval_t)octalValueFromBuffer( + (OFTimeInterval)octalValueFromBuffer( header + 136, 12, ULLONG_MAX)]; _type = header[156]; targetFileName = stringFromBuffer(header + 157, 100, encoding); if (targetFileName.length > 0) Index: src/OFThread.h ================================================================== --- src/OFThread.h +++ src/OFThread.h @@ -215,11 +215,11 @@ * @brief Suspends execution of the current thread for the specified time * interval. * * @param timeInterval The number of seconds to sleep */ -+ (void)sleepForTimeInterval: (of_time_interval_t)timeInterval; ++ (void)sleepForTimeInterval: (OFTimeInterval)timeInterval; /** * @brief Suspends execution of the current thread until the specified date. * * @param date The date to wait for Index: src/OFThread.m ================================================================== --- src/OFThread.m +++ src/OFThread.m @@ -233,11 +233,11 @@ return DNSResolver; # endif } #endif -+ (void)sleepForTimeInterval: (of_time_interval_t)timeInterval ++ (void)sleepForTimeInterval: (OFTimeInterval)timeInterval { if (timeInterval < 0) return; #if defined(OF_WINDOWS) Index: src/OFTimer.h ================================================================== --- src/OFTimer.h +++ src/OFTimer.h @@ -42,11 +42,11 @@ */ OF_SUBCLASSING_RESTRICTED @interface OFTimer: OFObject { OFDate *_fireDate; - of_time_interval_t _interval; + OFTimeInterval _interval; id _target; id _Nullable _object1, _object2, _object3, _object4; SEL _selector; unsigned char _arguments; bool _repeats; @@ -64,11 +64,11 @@ /** * @brief The time interval in which the timer will repeat, if it is a * repeating timer. */ -@property (readonly, nonatomic) of_time_interval_t timeInterval; +@property (readonly, nonatomic) OFTimeInterval timeInterval; /** * @brief Whether the timer is repeating. */ @property (readonly, nonatomic, getter=isRepeating) bool repeating; @@ -95,11 +95,11 @@ * @param target The target on which to call the selector * @param selector The selector to call on the target * @param repeats Whether the timer repeats after it has been executed * @return A new, autoreleased timer */ -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector repeats: (bool)repeats; /** @@ -110,11 +110,11 @@ * @param selector The selector to call on the target * @param object An object to pass when calling the selector on the target * @param repeats Whether the timer repeats after it has been executed * @return A new, autoreleased timer */ -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (nullable id)object repeats: (bool)repeats; @@ -129,11 +129,11 @@ * @param object2 The second object to pass when calling the selector on the * target * @param repeats Whether the timer repeats after it has been executed * @return A new, autoreleased timer */ -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (nullable id)object1 object: (nullable id)object2 repeats: (bool)repeats; @@ -151,11 +151,11 @@ * @param object3 The third object to pass when calling the selector on the * target * @param repeats Whether the timer repeats after it has been executed * @return A new, autoreleased timer */ -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (nullable id)object1 object: (nullable id)object2 object: (nullable id)object3 @@ -176,11 +176,11 @@ * @param object4 The fourth object to pass when calling the selector on the * target * @param repeats Whether the timer repeats after it has been executed * @return A new, autoreleased timer */ -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (nullable id)object1 object: (nullable id)object2 object: (nullable id)object3 @@ -194,11 +194,11 @@ * @param timeInterval The time interval after which the timer should be fired * @param repeats Whether the timer repeats after it has been executed * @param block The block to invoke when the timer fires * @return A new, autoreleased timer */ -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval repeats: (bool)repeats block: (of_timer_block_t)block; #endif /** @@ -208,11 +208,11 @@ * @param target The target on which to call the selector * @param selector The selector to call on the target * @param repeats Whether the timer repeats after it has been executed * @return A new, autoreleased timer */ -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector repeats: (bool)repeats; /** @@ -223,11 +223,11 @@ * @param selector The selector to call on the target * @param object An object to pass when calling the selector on the target * @param repeats Whether the timer repeats after it has been executed * @return A new, autoreleased timer */ -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (nullable id)object repeats: (bool)repeats; @@ -242,11 +242,11 @@ * @param object2 The second object to pass when calling the selector on the * target * @param repeats Whether the timer repeats after it has been executed * @return A new, autoreleased timer */ -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (nullable id)object1 object: (nullable id)object2 repeats: (bool)repeats; @@ -264,11 +264,11 @@ * @param object3 The third object to pass when calling the selector on the * target * @param repeats Whether the timer repeats after it has been executed * @return A new, autoreleased timer */ -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (nullable id)object1 object: (nullable id)object2 object: (nullable id)object3 @@ -289,11 +289,11 @@ * @param object4 The fourth object to pass when calling the selector on the * target * @param repeats Whether the timer repeats after it has been executed * @return A new, autoreleased timer */ -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (nullable id)object1 object: (nullable id)object2 object: (nullable id)object3 @@ -307,11 +307,11 @@ * @param timeInterval The time interval after which the timer should be fired * @param repeats Whether the timer repeats after it has been executed * @param block The block to invoke when the timer fires * @return A new, autoreleased timer */ -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval repeats: (bool)repeats block: (of_timer_block_t)block; #endif - (instancetype)init OF_UNAVAILABLE; @@ -327,11 +327,11 @@ * @param selector The selector to call on the target * @param repeats Whether the timer repeats after it has been executed * @return An initialized timer */ - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector repeats: (bool)repeats; /** @@ -346,11 +346,11 @@ * @param object An object to pass when calling the selector on the target * @param repeats Whether the timer repeats after it has been executed * @return An initialized timer */ - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector object: (nullable id)object repeats: (bool)repeats; @@ -369,11 +369,11 @@ * target * @param repeats Whether the timer repeats after it has been executed * @return An initialized timer */ - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector object: (nullable id)object1 object: (nullable id)object2 repeats: (bool)repeats; @@ -395,11 +395,11 @@ * target * @param repeats Whether the timer repeats after it has been executed * @return An initialized timer */ - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector object: (nullable id)object1 object: (nullable id)object2 object: (nullable id)object3 @@ -424,11 +424,11 @@ * target * @param repeats Whether the timer repeats after it has been executed * @return An initialized timer */ - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector object: (nullable id)object1 object: (nullable id)object2 object: (nullable id)object3 @@ -446,11 +446,11 @@ * @param repeats Whether the timer repeats after it has been executed * @param block The block to invoke when the timer fires * @return An initialized timer */ - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval repeats: (bool)repeats block: (of_timer_block_t)block; #endif /** Index: src/OFTimer.m ================================================================== --- src/OFTimer.m +++ src/OFTimer.m @@ -31,11 +31,11 @@ #import "OFInvalidArgumentException.h" @implementation OFTimer @synthesize timeInterval = _interval, repeating = _repeats, valid = _valid; -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector repeats: (bool)repeats { void *pool = objc_autoreleasePoolPush(); @@ -52,11 +52,11 @@ objc_autoreleasePoolPop(pool); return [timer autorelease]; } -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (id)object repeats: (bool)repeats { @@ -75,11 +75,11 @@ objc_autoreleasePoolPop(pool); return [timer autorelease]; } -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (id)object1 object: (id)object2 repeats: (bool)repeats @@ -100,11 +100,11 @@ objc_autoreleasePoolPop(pool); return [timer autorelease]; } -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (id)object1 object: (id)object2 object: (id)object3 @@ -127,11 +127,11 @@ objc_autoreleasePoolPop(pool); return [timer autorelease]; } -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (id)object1 object: (id)object2 object: (id)object3 @@ -157,11 +157,11 @@ return [timer autorelease]; } #ifdef OF_HAVE_BLOCKS -+ (instancetype)scheduledTimerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)scheduledTimerWithTimeInterval: (OFTimeInterval)timeInterval repeats: (bool)repeats block: (of_timer_block_t)block { void *pool = objc_autoreleasePoolPush(); OFDate *fireDate = [OFDate dateWithTimeIntervalSinceNow: timeInterval]; @@ -177,11 +177,11 @@ return [timer autorelease]; } #endif -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector repeats: (bool)repeats { void *pool = objc_autoreleasePoolPush(); @@ -196,11 +196,11 @@ objc_autoreleasePoolPop(pool); return [timer autorelease]; } -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (id)object repeats: (bool)repeats { @@ -217,11 +217,11 @@ objc_autoreleasePoolPop(pool); return [timer autorelease]; } -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (id)object1 object: (id)object2 repeats: (bool)repeats @@ -240,11 +240,11 @@ objc_autoreleasePoolPop(pool); return [timer autorelease]; } -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (id)object1 object: (id)object2 object: (id)object3 @@ -265,11 +265,11 @@ objc_autoreleasePoolPop(pool); return [timer autorelease]; } -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval target: (id)target selector: (SEL)selector object: (id)object1 object: (id)object2 object: (id)object3 @@ -293,11 +293,11 @@ return [timer autorelease]; } #ifdef OF_HAVE_BLOCKS -+ (instancetype)timerWithTimeInterval: (of_time_interval_t)timeInterval ++ (instancetype)timerWithTimeInterval: (OFTimeInterval)timeInterval repeats: (bool)repeats block: (of_timer_block_t)block { void *pool = objc_autoreleasePoolPush(); OFDate *fireDate = [OFDate dateWithTimeIntervalSinceNow: timeInterval]; @@ -317,11 +317,11 @@ { OF_INVALID_INIT_METHOD } - (instancetype)of_initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector object: (id)object1 object: (id)object2 object: (id)object3 @@ -354,11 +354,11 @@ return self; } - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector repeats: (bool)repeats { return [self of_initWithFireDate: fireDate @@ -372,11 +372,11 @@ arguments: 0 repeats: repeats]; } - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector object: (id)object repeats: (bool)repeats { @@ -391,11 +391,11 @@ arguments: 1 repeats: repeats]; } - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector object: (id)object1 object: (id)object2 repeats: (bool)repeats @@ -411,11 +411,11 @@ arguments: 2 repeats: repeats]; } - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector object: (id)object1 object: (id)object2 object: (id)object3 @@ -432,11 +432,11 @@ arguments: 3 repeats: repeats]; } - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval target: (id)target selector: (SEL)selector object: (id)object1 object: (id)object2 object: (id)object3 @@ -455,11 +455,11 @@ repeats: repeats]; } #ifdef OF_HAVE_BLOCKS - (instancetype)initWithFireDate: (OFDate *)fireDate - interval: (of_time_interval_t)interval + interval: (OFTimeInterval)interval repeats: (bool)repeats block: (of_timer_block_t)block { self = [super init]; @@ -538,11 +538,11 @@ OF_ENSURE(_arguments <= 4); if (_repeats && _valid) { int64_t missedIntervals = -_fireDate.timeIntervalSinceNow / _interval; - of_time_interval_t newFireDate; + OFTimeInterval newFireDate; OFRunLoop *runLoop; /* In case the clock was changed backwards */ if (missedIntervals < 0) missedIntervals = 0; Index: src/condition.h ================================================================== --- src/condition.h +++ src/condition.h @@ -20,11 +20,11 @@ #if !defined(OF_HAVE_THREADS) || \ (!defined(OF_HAVE_PTHREADS) && !defined(OF_WINDOWS) && !defined(OF_AMIGAOS)) # error No conditions available! #endif -/* For of_time_interval_t */ +/* For OFTimeInterval */ #import "OFObject.h" #import "mutex.h" #if defined(OF_HAVE_PTHREADS) @@ -53,16 +53,16 @@ extern int of_condition_new(of_condition_t *condition); extern int of_condition_signal(of_condition_t *condition); extern int of_condition_broadcast(of_condition_t *condition); extern int of_condition_wait(of_condition_t *condition, of_mutex_t *mutex); extern int of_condition_timed_wait(of_condition_t *condition, - of_mutex_t *mutex, of_time_interval_t timeout); + of_mutex_t *mutex, OFTimeInterval timeout); #ifdef OF_AMIGAOS extern int of_condition_wait_or_signal(of_condition_t *condition, of_mutex_t *mutex, ULONG *signalMask); extern int of_condition_timed_wait_or_signal(of_condition_t *condition, - of_mutex_t *mutex, of_time_interval_t timeout, ULONG *signalMask); + of_mutex_t *mutex, OFTimeInterval timeout, ULONG *signalMask); #endif extern int of_condition_free(of_condition_t *condition); #ifdef __cplusplus } #endif Index: src/platform/amiga/condition.m ================================================================== --- src/platform/amiga/condition.m +++ src/platform/amiga/condition.m @@ -122,21 +122,21 @@ return error; } int of_condition_timed_wait(of_condition_t *condition, of_mutex_t *mutex, - of_time_interval_t timeout) + OFTimeInterval timeout) { ULONG signalMask = 0; return of_condition_timed_wait_or_signal(condition, mutex, timeout, &signalMask); } int of_condition_timed_wait_or_signal(of_condition_t *condition, of_mutex_t *mutex, - of_time_interval_t timeout, ULONG *signalMask) + OFTimeInterval timeout, ULONG *signalMask) { struct of_condition_waiting_task waitingTask = { .task = FindTask(NULL), .sigBit = AllocSignal(-1) }; Index: src/platform/posix/condition.m ================================================================== --- src/platform/posix/condition.m +++ src/platform/posix/condition.m @@ -41,11 +41,11 @@ return pthread_cond_wait(condition, mutex); } int of_condition_timed_wait(of_condition_t *condition, of_mutex_t *mutex, - of_time_interval_t timeout) + OFTimeInterval timeout) { struct timespec ts; ts.tv_sec = (time_t)timeout; ts.tv_nsec = (long)((timeout - ts.tv_sec) * 1000000000); Index: src/platform/windows/condition.m ================================================================== --- src/platform/windows/condition.m +++ src/platform/windows/condition.m @@ -94,11 +94,11 @@ } } int of_condition_timed_wait(of_condition_t *condition, of_mutex_t *mutex, - of_time_interval_t timeout) + OFTimeInterval timeout) { int error; DWORD status; if ((error = of_mutex_unlock(mutex)) != 0)