Build 1.0_r1(from source)

android.view
Interface KeyEvent.Callback

All Known Implementing Classes:
AbsListView, AbsoluteLayout, AbsSeekBar, AbsSpinner, Activity, ActivityGroup, AdapterView, AlertDialog, AliasActivity, AnalogClock, AutoCompleteTextView, Button, CharacterPickerDialog, CheckBox, CheckedTextView, Chronometer, CompoundButton, DatePicker, DatePickerDialog, DialerFilter, Dialog, DigitalClock, EditText, ExpandableListActivity, ExpandableListView, FrameLayout, Gallery, GridView, ImageButton, ImageSwitcher, ImageView, LauncherActivity, LinearLayout, ListActivity, ListView, MediaController, MultiAutoCompleteTextView, PreferenceActivity, ProgressBar, ProgressDialog, RadioButton, RadioGroup, RatingBar, RelativeLayout, ScrollView, SearchDialog, SeekBar, Spinner, SurfaceView, TabActivity, TabHost, TableLayout, TableRow, TabWidget, TestBrowserActivity, TestListActivity, TextDialog, TextSwitcher, TextView, TimePicker, TimePickerDialog, ToggleButton, TwoLineListItem, VideoView, View, ViewAnimator, ViewFlipper, ViewGroup, ViewStub, ViewSwitcher, WebView, ZoomButton, ZoomControls
Enclosing class:
KeyEvent

public static interface KeyEvent.Callback


Method Summary
 boolean onKeyDown(int keyCode, KeyEvent event)
          Called when a key down event has occurred.
 boolean onKeyMultiple(int keyCode, int count, KeyEvent event)
          Called when multiple down/up pairs of the same key have occurred in a row.
 boolean onKeyUp(int keyCode, KeyEvent event)
          Called when a key up event has occurred.
 

Method Detail

onKeyDown

boolean onKeyDown(int keyCode,
                  KeyEvent event)
Called when a key down event has occurred.

Parameters:
keyCode - The value in event.getKeyCode().
event - Description of the key event.
Returns:
If you handled the event, return true. If you want to allow the event to be handled by the next receiver, return false.

onKeyUp

boolean onKeyUp(int keyCode,
                KeyEvent event)
Called when a key up event has occurred.

Parameters:
keyCode - The value in event.getKeyCode().
event - Description of the key event.
Returns:
If you handled the event, return true. If you want to allow the event to be handled by the next receiver, return false.

onKeyMultiple

boolean onKeyMultiple(int keyCode,
                      int count,
                      KeyEvent event)
Called when multiple down/up pairs of the same key have occurred in a row.

Parameters:
keyCode - The value in event.getKeyCode().
count - Number of pairs as returned by event.getRepeatCount().
event - Description of the key event.
Returns:
If you handled the event, return true. If you want to allow the event to be handled by the next receiver, return false.

Build 1.0_r1(from source)

Please submit a feedback, bug or feature