Ver código fonte

Docs: Clean up.

Mr.doob 1 ano atrás
pai
commit
0e82b23dd1

+ 2 - 2
manual/en/responsive.html

@@ -228,8 +228,8 @@ you passed in. <strong>This is strongly NOT RECOMMENDED</strong>. See below</p>
 <pre class="prettyprint showlinemods notranslate lang-js" translate="no">    function resizeRendererToDisplaySize(renderer) {
       const canvas = renderer.domElement;
       const pixelRatio = window.devicePixelRatio;
-      const width  = Math.floor(canvas.clientWidth  * pixelRatio);
-      const height = Math.floor(canvas.clientHeight * pixelRatio);
+      const width  = Math.floor( canvas.clientWidth  * pixelRatio );
+      const height = Math.floor( canvas.clientHeight * pixelRatio );
       const needResize = canvas.width !== width || canvas.height !== height;
       if (needResize) {
         renderer.setSize(width, height, false);

+ 2 - 2
manual/examples/responsive-hd-dpi.html

@@ -83,8 +83,8 @@ function main() {
 
 		const canvas = renderer.domElement;
 		const pixelRatio = window.devicePixelRatio;
-		const width = Math.floor(canvas.clientWidth * pixelRatio);
-		const height = Math.floor(canvas.clientHeight * pixelRatio);
+		const width = Math.floor( canvas.clientWidth * pixelRatio );
+		const height = Math.floor( canvas.clientHeight * pixelRatio );
 		const needResize = canvas.width !== width || canvas.height !== height;
 		if ( needResize ) {
 

+ 2 - 2
manual/fr/responsive.html

@@ -235,8 +235,8 @@ ratio que vous avez demandé.
 <pre class="prettyprint showlinemods notranslate lang-js" translate="no">    function resizeRendererToDisplaySize(renderer) {
       const canvas = renderer.domElement;
       const pixelRatio = window.devicePixelRatio;
-      const width  = Math.floor(canvas.clientWidth  * pixelRatio);
-      const height = Math.floor(canvas.clientHeight * pixelRatio);
+      const width  = Math.floor( canvas.clientWidth  * pixelRatio );
+      const height = Math.floor( canvas.clientHeight * pixelRatio );
       const needResize = canvas.width !== width || canvas.height !== height;
       if (needResize) {
         renderer.setSize(width, height, false);

+ 2 - 2
manual/ja/responsive.html

@@ -166,8 +166,8 @@ CSSピクセルからデバイスピクセルへの乗数をブラウザに伝
 <pre class="prettyprint showlinemods notranslate lang-js" translate="no">    function resizeRendererToDisplaySize(renderer) {
       const canvas = renderer.domElement;
       const pixelRatio = window.devicePixelRatio;
-      const width  = Math.floor(canvas.clientWidth  * pixelRatio);
-      const height = Math.floor(canvas.clientHeight * pixelRatio);
+      const width  = Math.floor( canvas.clientWidth  * pixelRatio );
+      const height = Math.floor( canvas.clientHeight * pixelRatio );
       const needResize = canvas.width !== width || canvas.height !== height;
       if (needResize) {
         renderer.setSize(width, height, false);

+ 2 - 2
manual/ko/responsive.html

@@ -217,8 +217,8 @@ Three.js에게 넘겨주는 것이죠.</p>
 <pre class="prettyprint showlinemods notranslate lang-js" translate="no">    function resizeRendererToDisplaySize(renderer) {
       const canvas = renderer.domElement;
       const pixelRatio = window.devicePixelRatio;
-      const width  = Math.floor(canvas.clientWidth  * pixelRatio);
-      const height = Math.floor(canvas.clientHeight * pixelRatio);
+      const width  = Math.floor( canvas.clientWidth  * pixelRatio );
+      const height = Math.floor( canvas.clientHeight * pixelRatio );
       const needResize = canvas.width !== width || canvas.height !== height;
       if (needResize) {
         renderer.setSize(width, height, false);

+ 2 - 2
manual/ru/responsive.html

@@ -222,8 +222,8 @@ html, body {
 <pre class="prettyprint showlinemods notranslate notranslate" translate="no">    function resizeRendererToDisplaySize(renderer) {
       const canvas = renderer.domElement;
       const pixelRatio = window.devicePixelRatio;
-      const width = Math.floor(canvas.clientWidth * pixelRatio);
-      const height = Math.floor(canvas.clientHeight * pixelRatio);
+      const width = Math.floor( canvas.clientWidth * pixelRatio );
+      const height = Math.floor( canvas.clientHeight * pixelRatio );
       const needResize = canvas.width !== width || canvas.height !== height;
       if (needResize) {
         renderer.setSize(width, height, false);

+ 2 - 2
manual/zh/responsive.html

@@ -215,8 +215,8 @@ html, body {
         <pre class="prettyprint showlinemods notranslate lang-js" translate="no">    function resizeRendererToDisplaySize(renderer) {
       const canvas = renderer.domElement;
       const pixelRatio = window.devicePixelRatio;
-      const width = Math.floor(canvas.clientWidth * pixelRatio);
-      const height = Math.floor(canvas.clientHeight * pixelRatio);
+      const width = Math.floor( canvas.clientWidth * pixelRatio );
+      const height = Math.floor( canvas.clientHeight * pixelRatio );
       const needResize = canvas.width !== width || canvas.height !== height;
       if (needResize) {
         renderer.setSize(width, height, false);