分享添加
This commit is contained in:
@@ -28,7 +28,7 @@ const scan = () => {
|
||||
webview.currentWebview().append(bc);
|
||||
bc.start();
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
const firstPaths = [
|
||||
'/check',
|
||||
@@ -53,17 +53,26 @@ const backButtonHandler = () => {
|
||||
const init = () => {
|
||||
if (!isApp()) return;
|
||||
plus.key.addEventListener('backbutton', backButtonHandler);
|
||||
}
|
||||
};
|
||||
|
||||
const destory = () => {
|
||||
if (!isApp()) return;
|
||||
plus.key.removeEventListener('backbutton', backButtonHandler);
|
||||
}
|
||||
};
|
||||
|
||||
const share = (content: string) => {
|
||||
if (!isApp()) return;
|
||||
plus.share.sendWithSystem({
|
||||
type: 'text',
|
||||
content,
|
||||
}, () => { });
|
||||
};
|
||||
|
||||
export {
|
||||
init,
|
||||
isApp,
|
||||
scan,
|
||||
share,
|
||||
destory,
|
||||
};
|
||||
|
||||
@@ -71,5 +80,6 @@ export default {
|
||||
init,
|
||||
isApp,
|
||||
scan,
|
||||
share,
|
||||
destory,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user