yolo助手AI ui 1.5.0
This commit is contained in:
@@ -1,12 +1,23 @@
|
||||
// src/utils/wsActions.js
|
||||
import { toBuffer } from '@/utils/bufferUtils';
|
||||
|
||||
const mouseData = {
|
||||
type: 2,
|
||||
action: 0,
|
||||
pointerId: 0,
|
||||
position: {
|
||||
point: { x: 0, y: 0 },
|
||||
screenSize: { width: 320, height: 720 },
|
||||
},
|
||||
pressure: 1,
|
||||
buttons: 1,
|
||||
};
|
||||
// 传入 wslist、isStopLike 等需要依赖的外部变量
|
||||
export function createWsActions(wslist) {
|
||||
// 通用 ws 发送方法
|
||||
function send(index, payload) {
|
||||
if (wslist[index]) {
|
||||
|
||||
|
||||
setTimeout(() => {
|
||||
mouseData.action = 1;
|
||||
wslist[index].send(toBuffer(mouseData));
|
||||
@@ -39,7 +50,7 @@ export function createWsActions(wslist) {
|
||||
getmesNum: (udid, index) => send(index, { udid, action: 'dump', type: 'getmesNum', index, resourceId: 'com.zhiliaoapp.musically:id/jyv' }), //获取收件箱消息数量
|
||||
clickMesage: (udid, index) => send(index, { udid, action: 'click', type: 'clickMesage', index, resourceId: 'com.zhiliaoapp.musically:id/e3_' }), //点击有消息的私信
|
||||
clickSysMesage: (udid, index) => send(index, { udid, action: 'click', type: 'clickSysMesage', index, resourceId: 'com.zhiliaoapp.musically:id/j7s' }), //点击有消息的系统通知
|
||||
// isVideoAndLive: (udid, index) => send(index, { udid, action: 'click', type: 'isVideoAndLive', index, resourceId: 'com.zhiliaoapp.musically:id/long_press_layout' }), //获取是视频还是直播
|
||||
isVideoAndLive: (udid, index) => send(index, { udid, action: 'click', type: 'isVideoAndLive', index, resourceId: 'com.zhiliaoapp.musically:id/long_press_layout' }), //获取是视频还是直播
|
||||
addHost: (udid, index) => send(index, { udid, action: 'click', type: 'addHost', index, resourceId: 'com.zhiliaoapp.musically:id/fuq' }), //视频页面的关注
|
||||
isHost: (udid, index) => send(index, { udid, action: 'click', type: 'isHost', index, resourceId: 'com.zhiliaoapp.musically:id/fuq' }), //判断视频页面的关注
|
||||
search: (udid, index) => send(index, { udid, action: 'click', type: 'search', index, resourceId: 'com.zhiliaoapp.musically:id/gtz' }), //搜索页面
|
||||
|
||||
Reference in New Issue
Block a user