IT. Expert System.

Android Reference


Class CameraEffectsRecordingSample

    • Constructor Detail

      • CameraEffectsRecordingSample

        public CameraEffectsRecordingSample()
    • Method Detail

      • onKeyDown

        public boolean onKeyDown(int keyCode,
                        KeyEvent event)
        Description copied from class: Activity
        Called when a key was pressed down and not handled by any of the views inside of the activity. So, for example, key presses while the cursor is inside a TextView will not trigger the event (unless it is a navigation to another object) because TextView handles its own key presses.

        If the focused view didn't want this event, this method is called.

        The default implementation takes care of KeyEvent.KEYCODE_BACK by calling Activity.onBackPressed(), though the behavior varies based on the application compatibility mode: for Build.VERSION_CODES.ECLAIR or later applications, it will set up the dispatch to call Activity.onKeyUp(int, android.view.KeyEvent) where the action will be performed; for earlier applications, it will perform the action immediately in on-down, as those versions of the platform behaved.

        Other additional default key handling may be performed if configured with Activity.setDefaultKeyMode(int).

        Specified by:
        onKeyDown in interface KeyEvent.Callback
        onKeyDown in class Activity
        keyCode - The value in event.getKeyCode().
        event - Description of the key event.
        Return true to prevent this event from being propagated further, or false to indicate that you have not handled this event and it should continue to be propagated.
        See Also:
        Activity.onKeyUp(int, android.view.KeyEvent), KeyEvent
      • onPause

        protected void onPause()
        Description copied from class: Activity
        Called as part of the activity lifecycle when an activity is going into the background, but has not (yet) been killed. The counterpart to Activity.onResume().

        When activity B is launched in front of activity A, this callback will be invoked on A. B will not be created until A's Activity.onPause() returns, so be sure to not do anything lengthy here.

        This callback is mostly used for saving any persistent state the activity is editing, to present a "edit in place" model to the user and making sure nothing is lost if there are not enough resources to start the new activity without first killing this one. This is also a good place to do things like stop animations and other things that consume a noticeable amount of CPU in order to make the switch to the next activity as fast as possible, or to close resources that are exclusive access such as the camera.

        In situations where the system needs more memory it may kill paused processes to reclaim resources. Because of this, you should be sure that all of your state is saved by the time you return from this function. In general Activity.onSaveInstanceState(android.os.Bundle) is used to save per-instance state in the activity and this method is used to store global persistent data (in content providers, files, etc.)

        After receiving this call you will usually receive a following call to Activity.onStop() (after the next activity has been resumed and displayed), however in some cases there will be a direct call back to Activity.onResume() without going through the stopped state.

        Derived classes must call through to the super class's implementation of this method. If they do not, an exception will be thrown.

        onPause in class Activity
        See Also:
        Activity.onResume(), Activity.onSaveInstanceState(android.os.Bundle), Activity.onStop()


Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)





Java Script








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

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: 4229 / 159232320. Delta: 0.04937 с