iPhone的震动 基于SDK8.0 Swift实现

  1. 导入AudioToolbox.framework包
  2. 在swift文件中 

    import AudioToolbox

  3.  

    AudioServicesPlaySystemSound(SystemSoundID.convertFromIntegerLiteral(UInt32(kSystemSoundID_Vibrate)))

posted on 2014-09-02 14:55  SCaptain  阅读(511)  评论(0编辑  收藏  举报

导航