 
         let threshold: Float = 0.4
         var max: Float = 0
-        var type = UIPressType.Select
+        var pressType = UIPressType.Select
 
         let up = dpad.up.value
         let down = dpad.down.value


        if up > max {
            max = up
            type = .UpArrow
        }
        if down > max {
            max = down
            type = .DownArrow
        }
        if left > max {
            max = left
            type = .LeftArrow
        }
        if right > max {
            max = right
            type = .RightArrow
        }

        if max > threshold {
            self.buttonPressed(type)
        }
    }

    func handleButtonA(button: GCControllerButtonInput) {
        if button.pressed && buttonXPending {
            buttonXPending = false
            buttonPressed(.Menu)
        } else if button.pressed {
            buttonAPending = true
            eventDate = NSDate()


    override func completePendingUpdate() {
        if buttonAPending && buttonXPending {
            playNote(.Menu)
            buttonAPending = false
            buttonXPending = false
        } else if buttonAPending {
            playNote(.Select)
            buttonAPending = false
        } else if buttonXPending {
            playNote(.PlayPause)
            buttonXPending = false
        }
    }
