Flash inside Android WebView - How to automatically set full screen mode?

I am loading Flash SWF in Android WebView.

I want SWF to instantly become full-screen and focused.

The name of the class that the flash handles is com.adobe.flashplayer.FlashPaintSurface . Watching the log, when I press the full-screen flash mode manually, it calls com.adobe.flashplayer.FlashPaintSurface.toggleFullScreen() .

The first part of my question: how can I call this method manually for my Flash SWF?

Please note that with web browsing with built-in flash memory, the only way I seem to be able to completely shield it (so that in the pop-up Flash window the surfaceview instead of the flash appears on top of the webview view ) by touching the screen with two fingers while the interface will not appear at the top of the screen and will not happen reliably.

To focus inside my webview class, I call:

 @Override protected boolean drawChild (Canvas canvas, View child, long drawingTime) { if (child.getClass().getName().equals("com.adobe.flashplayer.FlashPaintSurface")) { child.requestFocus(); } return super.drawChild(canvas, child, drawingTime); } 

This does not set the focus as I thought. Although I assume that if full-screen mode is correct, FlashPaintSurface should give focus. But if the first part is not feasible, I would be interested, at least, not to focus on SWF by clicking on it at startup.

Note that I am doing this dynamically without invoking my own SWF files, which I am doing myself, so I cannot solve this using ActionScript.

+8
android flash webview fullscreen
source share
2 answers

I had success using the code of my previous solution for the Problem of loading FLV video in a web browser . This can help.

The embed tag is as follows:

 <embed style="width:100%; height:100%" src="./FLVPlayer.swf?fullscreen=true&video=./expression_sad.flv" autoplay="true" quality="high" bgcolor="#000000" name="VideoPlayer" align="middle" allowScriptAccess="*" allowFullScreen="true" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"> </embed> 
0
source share

Each Adobe Android application uses the file "application.xml" - by default, as a descriptor:

Take a look at this file before writing code for this. It changes each revision, but the last time I used it to set this variable (Full_screen).

0
source share

All Articles