Przeglądaj źródła

Editor: Improved video render UX on mobile.

Mr.doob 1 rok temu
rodzic
commit
2315ae8cbf
1 zmienionych plików z 6 dodań i 0 usunięć
  1. 6 0
      editor/js/Sidebar.Project.Video.js

+ 6 - 0
editor/js/Sidebar.Project.Video.js

@@ -69,6 +69,12 @@ function SidebarProjectVideo( editor ) {
 		const top = ( screen.height - height ) / 2;
 		const top = ( screen.height - height ) / 2;
 
 
 		const output = window.open( '', '_blank', `location=no,left=${left},top=${top},width=${width},height=${height}` );
 		const output = window.open( '', '_blank', `location=no,left=${left},top=${top},width=${width},height=${height}` );
+
+		const meta = document.createElement( 'meta' );
+		meta.name = 'viewport';
+		meta.content = 'width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0';
+		output.document.head.appendChild( meta );
+
 		output.document.body.style.background = '#000';
 		output.document.body.style.background = '#000';
 		output.document.body.style.margin = '0px';
 		output.document.body.style.margin = '0px';
 		output.document.body.style.overflow = 'hidden';
 		output.document.body.style.overflow = 'hidden';