Codota Logo
SurfaceView.requestLayout
Code IndexAdd Codota 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)

  • Common ways to obtain SurfaceView
private void myMethod () {
SurfaceView s =
  • Codota IconContext context;new SurfaceView(context)
  • Codota IconView view;(SurfaceView) view.findViewById(id)
  • Codota IconViewStub viewStub;(SurfaceView) viewStub.inflate()
  • Smart code suggestions by Codota
}
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

  • Creating JSON documents from java classes using gson
  • setContentView (Activity)
  • onCreateOptionsMenu (Activity)
  • getSupportFragmentManager (FragmentActivity)
    Return the FragmentManager for interacting with fragments associated with this activity.
  • FlowLayout (java.awt)
    A flow layout arranges components in a left-to-right flow, much like lines of text in a paragraph. F
  • Date (java.sql)
    A class which can consume and produce dates in SQL Date format. Dates are represented in SQL as yyyy
  • BlockingQueue (java.util.concurrent)
    A java.util.Queue that additionally supports operations that wait for the queue to become non-empty
  • Callable (java.util.concurrent)
    A task that returns a result and may throw an exception. Implementors define a single method with no
  • JComboBox (javax.swing)
  • SAXParseException (org.xml.sax)
    Encapsulate an XML parse error or warning.This exception may include information for locating the er
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now