最終更新:2013-03-07 (木) 22:49:21 (2752d)  

UIKit/UIEvent
Top / UIKit / UIEvent

http://developer.apple.com/library/ios/#documentation/uikit/reference/UIEvent_Class/Reference/Reference.html

イベントの種類

  • There are three general types of event: touch events, motion events, and remote-control events.
  • UITouch

Tasks

Getting the Touches for an Event

  • allTouches?
  • touchesForView?
  • touchesForWindow?

Getting Event Attributes

  • timestamp - property

Getting the Event Type

  • type - property - UIEventType?
    typedef enum {
       UIEventTypeTouches,
       UIEventTypeMotion,
       UIEventTypeRemoteControl,
    } UIEventType;
  • subtype - property - UIEventSubtype?
    typedef enum {
       UIEventSubtypeNone                              = 0,
    
       UIEventSubtypeMotionShake                       = 1,
    
       UIEventSubtypeRemoteControlPlay                 = 100,
       UIEventSubtypeRemoteControlPause                = 101,
       UIEventSubtypeRemoteControlStop                 = 102,
       UIEventSubtypeRemoteControlTogglePlayPause      = 103,
       UIEventSubtypeRemoteControlNextTrack            = 104,
       UIEventSubtypeRemoteControlPreviousTrack        = 105,
       UIEventSubtypeRemoteControlBeginSeekingBackward = 106,
       UIEventSubtypeRemoteControlEndSeekingBackward   = 107,
       UIEventSubtypeRemoteControlBeginSeekingForward  = 108,
       UIEventSubtypeRemoteControlEndSeekingForward    = 109,
    } UIEventSubtype;

Getting the Touches for a Gesture Recognizer

  • touchesForGestureRecognizer?

関連