google tv - Portrait Orientation on Android Smart TV -


i had used following code show screen in portrait mode.

view root = findviewbyid(android.r.id.content);

displaymetrics displaymetrics = new displaymetrics(); getwindowmanager().getdefaultdisplay().getmetrics(displaymetrics); int height = displaymetrics.heightpixels; int width = displaymetrics.widthpixels;  root.getlayoutparams().height = width; root.getlayoutparams().width = height; root.requestlayout();  root.setpivotx(height); root.setpivoty(height);  animator anim = animatorinflater.loadanimator(this, r.anim.rotate_90);       anim.settarget(root); anim.start(); 

my root view contain videoview. after screen rotation videoview played, doesn't show video frames, plays audio of video source only. , need show mouse cursor on portrait mode. how handle this?

note:

i had tried implement portrait orientation smart tv application.as per developer site no possibility implement portrait on google tv. refer link


Comments

Popular posts from this blog

c++ - OpenCV Error: Assertion failed <scn == 3 ::scn == 4> in unknown function, -

php - render data via PDO::FETCH_FUNC vs loop -

The canvas has been tainted by cross-origin data in chrome only -