class AutoRotateTextView : TextView, OrientationSensor.OrientationListener
Rotate on device rotation it use the OrientationSensor Class. To use it the OrientationSensor must be start on Activity resume and stop on Activity pause.
AutoRotateTextView(context: Context) AutoRotateTextView(context: Context, attrs: AttributeSet) AutoRotateTextView(context: Context, attrs: AttributeSet, defStyleAttr: int) |
fun onAttachedToWindow(): void |
|
fun onDetachedFromWindow(): void |
|
fun onDraw(canvas: Canvas): void |
|
fun onOrientationChange(screenOrientation: OrientationSensor.ScreenOrientation): void
Would be set by the OrientationSensor Event. |