Type Method

startPeriodicEvents(afterDelay:withPeriod:)

Begins generating periodic events for the current thread.

Declaration

class func startPeriodicEvents(afterDelay delay: TimeInterval, withPeriod period: TimeInterval)

Parameters

delaySeconds

The number of seconds that NSEvent should wait before beginning to generate periodic events.

periodSeconds

The period in seconds between the generated events.

Discussion

Raises an NSInternalInconsistencyException if periodic events are already being generated for the current thread. This method is typically used in a modal loop while tracking mouse-dragged events.

See Also

Requesting and Stopping Periodic Events

class func stopPeriodicEvents()

Stops generating periodic events for the current thread and discards any periodic events remaining in the queue.