Android 未接收动作\摄像机\按钮广播事件

Android 未接收动作\摄像机\按钮广播事件,android,Android,我想用广播接收器来处理行动按钮。我在androidmanifest文件中添加了以下内容 <receiver android:name="MappedKeysIntentReceiver"> <intent-filter android:priority = "999"> <action android:name="android.intent.action.ACTION_CAMERA_BUTTON" />

我想用广播接收器来处理行动按钮。我在androidmanifest文件中添加了以下内容

<receiver android:name="MappedKeysIntentReceiver">
        <intent-filter android:priority = "999">
            <action android:name="android.intent.action.ACTION_CAMERA_BUTTON" />
        </intent-filter>
    </receiver>

但我不会在按下摄像头按钮时收听广播,但是如果我手动注册,那么我就接收到了事件。 有人能解释一下这种行为吗。我希望在清单文件中指定接收者,而不是手动注册它。我已经在lg optimus gt540和Milestone上试用过,它们都运行2.1安卓操作系统


谢谢

你的动作名称错了。当表示为字符串时,它是android.intent.action.CAMERA_按钮