native.newWebView on top of native.newVideo

Hello,

We wanted to have somewhat of an  Interactive Video. We understand the limitation of the Corona canvas being behind the native elements. So, we wanted to have a  Webview on top of a Video. The idea is to have the Webview handle the touch events.

On iOS, it looks good! and could work. On Android, however, it seems that the Webview element is behind the Video element. :frowning:

Is there a way we could bring the Webview toFront ?? Or does anyone have an idea how we can make it work on Android?

Thank you,

Mars Team.

I would think the last object created would be on top. But maybe Android has some different rules. Let me ask.

Rob

Please do, because I most definitely created the webview second…

Any news on this? We wanted to see if creating a WebView over a Video is possible to start our project…

No, our team is pretty busy working on some large important projects and getting research time asked out of workflow is hard to get right now.  Maybe file a bug report? That at least gets it into our system to be assigned to an engineer.

Rob

I checked here and it appears that Corona indeed adds new objects on top of each other, but for any reason the video is always showing on top of the webview… maybe is it a Android issue?

Debugging Android view hierarchy:

  1. Creating the WebView after the newVideo:

    02-28 23:09:26.364: com.ansca.corona.graphics.opengl.CoronaGLSurfaceView{199fdde V.E… … 0,0-1080,1794} 02-28 23:09:26.364: com.ansca.corona.CoronaVideoView{19eebbf VFE… … 0,297-540,600 #1} 02-28 23:09:26.364: com.ansca.corona.CoronaVideoView$CenteredLayout{138c28c V.E… …I. 269,448-809,1345 #1} 02-28 23:09:26.364: com.ansca.corona.CoronaWebView{4b9add5 VFEDHVC… .F…I. 269,317-809,1214 #2} 02-28 23:09:26.364: android.widget.AbsoluteLayout{dc419ea V.E… …I. 0,0-1080,1794} 02-28 23:09:26.364: android.widget.FrameLayout{16084db V.E… …I. 0,0-1080,1794} 02-28 23:09:26.364: android.widget.AbsoluteLayout{af57b78 V.E… … 0,0-1080,1794} 02-28 23:09:26.365: android.widget.FrameLayout{cf45251 VFE… …I. 0,0-1080,1794} 02-28 23:09:26.365: android.widget.FrameLayout{c1eab6 V.E… …I. 0,0-1080,1794 #1020002 android:id/content} 02-28 23:09:26.365: android.widget.LinearLayout{6d893b7 V.E… …I. 0,0-1080,1794}

  2. Creating the newVideo after the WebView:

    02-28 23:12:24.182 : com.ansca.corona.graphics.opengl.CoronaGLSurfaceView{199fdde V.E… … 0,0-1080,1794} 02-28 23:12:24.182 : com.ansca.corona.CoronaWebView{19eebbf VFEDHVC… …I. 269,317-809,1214 #1} 02-28 23:12:24.183 : com.ansca.corona.CoronaVideoView{138c28c VFE… .F… 0,297-540,600 #2} 02-28 23:12:24.183 : com.ansca.corona.CoronaVideoView$CenteredLayout{4b9add5 V.E… …I. 269,448-809,1345 #2} 02-28 23:12:24.183 : android.widget.AbsoluteLayout{dc419ea V.E… …I. 0,0-1080,1794} 02-28 23:12:24.183 : android.widget.FrameLayout{16084db V.E… …I. 0,0-1080,1794} 02-28 23:12:24.183 : android.widget.AbsoluteLayout{af57b78 V.E… … 0,0-1080,1794} 02-28 23:12:24.183 : android.widget.FrameLayout{cf45251 VFE… …I. 0,0-1080,1794} 02-28 23:12:24.183 : android.widget.FrameLayout{c1eab6 V.E… …I. 0,0-1080,1794 #1020002 android:id/content} 02-28 23:12:24.183 : android.widget.LinearLayout{6d893b7 V.E… …I. 0,0-1080,1794}

I would think the last object created would be on top. But maybe Android has some different rules. Let me ask.

Rob

Please do, because I most definitely created the webview second…

Any news on this? We wanted to see if creating a WebView over a Video is possible to start our project…

No, our team is pretty busy working on some large important projects and getting research time asked out of workflow is hard to get right now.  Maybe file a bug report? That at least gets it into our system to be assigned to an engineer.

Rob

I checked here and it appears that Corona indeed adds new objects on top of each other, but for any reason the video is always showing on top of the webview… maybe is it a Android issue?

Debugging Android view hierarchy:

  1. Creating the WebView after the newVideo:

    02-28 23:09:26.364: com.ansca.corona.graphics.opengl.CoronaGLSurfaceView{199fdde V.E… … 0,0-1080,1794} 02-28 23:09:26.364: com.ansca.corona.CoronaVideoView{19eebbf VFE… … 0,297-540,600 #1} 02-28 23:09:26.364: com.ansca.corona.CoronaVideoView$CenteredLayout{138c28c V.E… …I. 269,448-809,1345 #1} 02-28 23:09:26.364: com.ansca.corona.CoronaWebView{4b9add5 VFEDHVC… .F…I. 269,317-809,1214 #2} 02-28 23:09:26.364: android.widget.AbsoluteLayout{dc419ea V.E… …I. 0,0-1080,1794} 02-28 23:09:26.364: android.widget.FrameLayout{16084db V.E… …I. 0,0-1080,1794} 02-28 23:09:26.364: android.widget.AbsoluteLayout{af57b78 V.E… … 0,0-1080,1794} 02-28 23:09:26.365: android.widget.FrameLayout{cf45251 VFE… …I. 0,0-1080,1794} 02-28 23:09:26.365: android.widget.FrameLayout{c1eab6 V.E… …I. 0,0-1080,1794 #1020002 android:id/content} 02-28 23:09:26.365: android.widget.LinearLayout{6d893b7 V.E… …I. 0,0-1080,1794}

  2. Creating the newVideo after the WebView:

    02-28 23:12:24.182 : com.ansca.corona.graphics.opengl.CoronaGLSurfaceView{199fdde V.E… … 0,0-1080,1794} 02-28 23:12:24.182 : com.ansca.corona.CoronaWebView{19eebbf VFEDHVC… …I. 269,317-809,1214 #1} 02-28 23:12:24.183 : com.ansca.corona.CoronaVideoView{138c28c VFE… .F… 0,297-540,600 #2} 02-28 23:12:24.183 : com.ansca.corona.CoronaVideoView$CenteredLayout{4b9add5 V.E… …I. 269,448-809,1345 #2} 02-28 23:12:24.183 : android.widget.AbsoluteLayout{dc419ea V.E… …I. 0,0-1080,1794} 02-28 23:12:24.183 : android.widget.FrameLayout{16084db V.E… …I. 0,0-1080,1794} 02-28 23:12:24.183 : android.widget.AbsoluteLayout{af57b78 V.E… … 0,0-1080,1794} 02-28 23:12:24.183 : android.widget.FrameLayout{cf45251 VFE… …I. 0,0-1080,1794} 02-28 23:12:24.183 : android.widget.FrameLayout{c1eab6 V.E… …I. 0,0-1080,1794 #1020002 android:id/content} 02-28 23:12:24.183 : android.widget.LinearLayout{6d893b7 V.E… …I. 0,0-1080,1794}