浏览代码

auto commit

app
jfinn 3 年前
父节点
当前提交
eef2609166
共有 1 个文件被更改,包括 6 次插入3 次删除
  1. 6
    3
      mdev/rn_vshot.native.js

+ 6
- 3
mdev/rn_vshot.native.js 查看文件

@@ -7,15 +7,18 @@ import { Header, LoadingIndicator, Text } from '../react/features/base/react';
7 7
 
8 8
 class ExampleCaptureOnMountManually extends Component {
9 9
   componentDidMount () {
10
-    this.refs.viewShot.capture().then(uri => {
10
+  	// captureScreen
11
+    // this.refs.viewShot.capture().then(uri => {
12
+    this.refs.captureScreen.capture().then(uri => {
11 13
       console.log("do something with ", uri);
12 14
     });
13 15
   }
14 16
   render() {
17
+      // <ViewShot ref="viewShot" options={{ format: "jpg", quality: 0.9 }}>
15 18
     return (
16
-      <captureScreen ref="viewShot" options={{ format: "jpg", quality: 0.9 }}>
19
+      <ViewShot ref="captureScreen" options={{ format: "jpg", quality: 0.9 }}>
17 20
         <Text>...Something to rasterize...</Text>
18
-      </captureScreen>
21
+      </ViewShot>
19 22
     );
20 23
   }
21 24
 }

正在加载...
取消
保存