Tabnine Logo
SurfaceView.requestLayout
Code IndexAdd Tabnine to your IDE (free)

How to use
requestLayout
method
in
android.view.SurfaceView

Best Java code snippets using android.view.SurfaceView.requestLayout (Showing top 2 results out of 315)

origin: Affectiva/android-sdk-samples

  @SuppressWarnings("SuspiciousNameCombination")
  @Override
  public void onCameraSizeSelected(int width, int height, Frame.ROTATE rotate) {
    if (rotate == Frame.ROTATE.BY_90_CCW || rotate == Frame.ROTATE.BY_90_CW) {
      previewWidth = height;
      previewHeight = width;
    } else {
      previewHeight = height;
      previewWidth = width;
    }
    cameraPreview.requestLayout();
  }
}
origin: Affectiva/android-sdk-samples

/**
 * Update the camera width and height variables, then request a resize of the SurfaceView.
 * Notice that CameraHelper notifies us of the physical, pre-rotation width and height of the camera
 * frames, so we need to account for possible rotation in this method.
 */
@Override
public void onFrameSizeSelected(int width, int height, Frame.ROTATE rotation) {
  if (rotation == Frame.ROTATE.BY_90_CW || rotation == Frame.ROTATE.BY_90_CCW) {
    previewHeight = width;
    previewWidth = height;
  } else {
    previewWidth = width;
    previewHeight = height;
  }
  surfaceView.requestLayout();
}
android.viewSurfaceViewrequestLayout

Popular methods of SurfaceView

  • getHolder
  • <init>
  • onMeasure
  • onInitializeAccessibilityEvent
  • onInitializeAccessibilityNodeInfo
  • setLayoutParams
  • onKeyDown
  • setOnTouchListener
  • onDetachedFromWindow
  • setVisibility
  • getLayoutParams
  • onAttachedToWindow
  • getLayoutParams,
  • onAttachedToWindow,
  • onTouchEvent,
  • onSizeChanged,
  • setOnClickListener,
  • getHeight,
  • getWidth,
  • setKeepScreenOn,
  • onLayout,
  • setZOrderOnTop

Popular in Java

  • Making http requests using okhttp
  • setRequestProperty (URLConnection)
  • setContentView (Activity)
  • scheduleAtFixedRate (Timer)
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • Window (java.awt)
    A Window object is a top-level window with no borders and no menubar. The default layout for a windo
  • EOFException (java.io)
    Thrown when a program encounters the end of a file or stream during an input operation.
  • SocketException (java.net)
    This SocketException may be thrown during socket creation or setting options, and is the superclass
  • UnknownHostException (java.net)
    Thrown when a hostname can not be resolved.
  • Properties (java.util)
    A Properties object is a Hashtable where the keys and values must be Strings. Each property can have
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now