IT. Expert System.

Android Reference

KeyEvent.Callback


android.view

Interface KeyEvent.Callback

    • Method Summary

      Methods
      Modifier and Type Method and Description
      boolean onKeyDown(int keyCode, KeyEvent event)
      Called when a key down event has occurred.
      boolean onKeyLongPress(int keyCode, KeyEvent event)
      Called when a long press 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. If you return true, you can first call KeyEvent.startTracking() to have the framework track the event through its onKeyUp(int, KeyEvent) and also call your onKeyLongPress(int, KeyEvent) if it occurs.
        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.
      • onKeyLongPress

        boolean onKeyLongPress(int keyCode,
                             KeyEvent event)
        Called when a long press has occurred. If you return true, the final key up will have KeyEvent.FLAG_CANCELED and KeyEvent.FLAG_CANCELED_LONG_PRESS set. Note that in order to receive this callback, someone in the event change must return true from onKeyDown(int, android.view.KeyEvent) and call KeyEvent.startTracking() on the event.
        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.


Content

Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)

SQL

HTML

PHP

CSS

Java Script

MYSQL

JQUERY

VBS

REGEX

C

C++

C#

Design patterns

RFC (standard status)

RFC (proposed standard status)

RFC (draft standard status)

RFC (informational status)

RFC (experimental status)

RFC (best current practice status)

RFC (historic status)

RFC (unknown status)

IT dictionary

License.
All information of this service is derived from the free sources and is provided solely in the form of quotations. This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 365 / . Delta: 0.03373 с