index.d.ts 835 字节
Newer Older
Q
qiang 已提交
1 2 3
declare namespace UniNamespace {
  type OnUserCaptureScreenCallback = (res?: { errMsg: string }) => void
}
Q
qiang 已提交
4

Q
qiang 已提交
5
declare interface Uni {
Q
qiang 已提交
6 7 8 9 10
  /**
   * 监听用户主动截屏事件,用户使用系统截屏按键截屏时触发此事件。
   *
   * 文档: [https://uniapp.dcloud.net.cn/api/system/capture-screen.html#onusercapturescreen](https://uniapp.dcloud.net.cn/api/system/capture-screen.html#onusercapturescreen)
   */
Q
qiang 已提交
11
  onUserCaptureScreen(callback: UniNamespace.OnUserCaptureScreenCallback): void;
Q
qiang 已提交
12 13 14 15 16
  /**
   * 用户主动截屏事件。取消事件监听。
   *
   * 文档: [https://uniapp.dcloud.net.cn/api/system/capture-screen.html#offusercapturescreen](https://uniapp.dcloud.net.cn/api/system/capture-screen.html#offusercapturescreen)
   */
Q
qiang 已提交
17
  offUserCaptureScreen(callback: UniNamespace.OnUserCaptureScreenCallback): void;
Q
qiang 已提交
18
}