diff --git a/CHANGELOG.md b/CHANGELOG.md index 2f9307a8..e8cae866 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,14 @@ Removed - 删除功能/接口 Fixed - 修复问题 Others - 其他 --> +## 2024-11-14 【普通更新】 +### Feature +* 普通: WXSDK代码简化 +* 普通: 增强JsonMapper报错信息 +* 普通: 适配插件版本升级到1.2.62 +### Fixed +* 普通: WX.Cloud.Init 自定义环境报错 + ## 2024-10-8 【重要更新】 ### Feature * 普通: UDPSocket.write适配 diff --git a/Editor/WXConvertCore.cs b/Editor/WXConvertCore.cs index 953a2c20..98b01a04 100644 --- a/Editor/WXConvertCore.cs +++ b/Editor/WXConvertCore.cs @@ -216,6 +216,56 @@ namespace WeChatWASM return WXExportError.SUCCEED; } + private static int GetEnabledFlagStringIndex(string inAllText, string inTagStr) + { + try + { + int tagStrIdx = inAllText.IndexOf(inTagStr); + if (tagStrIdx == -1) throw new Exception($"Tag string '{inTagStr}' not found."); + + int enabledStrIdx = inAllText.IndexOf("enabled: ", tagStrIdx); + if (enabledStrIdx == -1) throw new Exception("'enabled: ' string not found after tag."); + + // inAllText[enabledStrIdx] == 'e' + // And that is to say, inAllText[enabledStrIdx + 9] should be 0 or 1 + return enabledStrIdx + 9; + } + catch (Exception ex) + { + UnityEngine.Debug.LogError($"Failed to get enabled flag string index: {ex.Message}"); + throw; + } + } + + private static void SetPluginCompatibilityByModifyingMetadataFile(string inAssetPath, bool inEnabled) + { + try + { + string metaPath = AssetDatabase.GetTextMetaFilePathFromAssetPath(inAssetPath); // 获取.meta文件的路径 + string enableFlagStr = inEnabled? "1" : "0"; + + // 读取.meta文件 + // 处理WebGL + string metaContent = File.ReadAllText(metaPath); + int idxWebGLEnableFlag = GetEnabledFlagStringIndex(metaContent, "WebGL: WebGL"); + + metaContent = metaContent.Remove(idxWebGLEnableFlag, 1).Insert(idxWebGLEnableFlag, enableFlagStr); + // WeixinMiniGame + int idxWeixinMiniGameEnableFlag = GetEnabledFlagStringIndex(metaContent, "WeixinMiniGame: WeixinMiniGame"); + + metaContent = metaContent.Remove(idxWeixinMiniGameEnableFlag, 1).Insert(idxWeixinMiniGameEnableFlag, enableFlagStr); + + // 写回.meta文件 + + File.WriteAllText(metaPath, metaContent); + AssetDatabase.ImportAsset(inAssetPath, ImportAssetOptions.ForceUpdate); + } + catch (Exception ex) + { + UnityEngine.Debug.LogError($"Failed to enable plugin asset: {ex.Message}"); + } + } + private static void ProcessWxPerfBinaries() { string[] wxPerfPlugins; @@ -250,6 +300,7 @@ namespace WeChatWASM #else wxPerfJSBridgeImporter.SetCompatibleWithPlatform(BuildTarget.WebGL, config.CompileOptions.enablePerfAnalysis); #endif + SetPluginCompatibilityByModifyingMetadataFile(wxPerfPlugins[0], config.CompileOptions.enablePerfAnalysis); } { @@ -262,6 +313,7 @@ namespace WeChatWASM #else wxPerf2022Importer.SetCompatibleWithPlatform(BuildTarget.WebGL, bShouldEnablePerf2022Plugin); #endif + SetPluginCompatibilityByModifyingMetadataFile(wxPerfPlugins[1], bShouldEnablePerf2022Plugin); } { @@ -274,36 +326,29 @@ namespace WeChatWASM #else wxPerf2021Importer.SetCompatibleWithPlatform(BuildTarget.WebGL, bShouldEnablePerf2021Plugin); #endif + SetPluginCompatibilityByModifyingMetadataFile(wxPerfPlugins[2], bShouldEnablePerf2021Plugin); } - - for (int i = 0; i < wxPerfPlugins.Length; i++) - { - var importer = AssetImporter.GetAtPath(wxPerfPlugins[i]) as PluginImporter; - importer.SaveAndReimport(); - AssetDatabase.WriteImportSettingsIfDirty(wxPerfPlugins[i]); - AssetDatabase.Refresh(); - } + AssetDatabase.Refresh(); } private static bool IsCompatibleWithUnity202203OrNewer() { #if UNITY_2022_3_OR_NEWER return true; -#endif +#else return false; +#endif } static bool IsCompatibleWithUnity202103To202203() { #if UNITY_2022_3_OR_NEWER return false; -#endif - -#if !UNITY_2021_3_OR_NEWER +#elif !UNITY_2021_3_OR_NEWER return false; -#endif - +#else return true; +#endif } private static void CheckBuildTarget() diff --git a/Editor/WXPluginVersion.cs b/Editor/WXPluginVersion.cs index 2944906a..32298e37 100644 --- a/Editor/WXPluginVersion.cs +++ b/Editor/WXPluginVersion.cs @@ -1,8 +1,8 @@ -namespace WeChatWASM +namespace WeChatWASM { public class WXPluginVersion { - public static string pluginVersion = "202410210239"; // 这一行不要改他,导出的时候会自动替换 + public static string pluginVersion = "202411141147"; // 这一行不要改他,导出的时候会自动替换 } public class WXPluginConf diff --git a/Editor/wx-editor.dll b/Editor/wx-editor.dll index dd0b76ae..20c96109 100644 Binary files a/Editor/wx-editor.dll and b/Editor/wx-editor.dll differ diff --git a/Editor/wx-editor.xml.meta b/Editor/wx-editor.xml.meta index c59ecda2..770e7a5d 100644 --- a/Editor/wx-editor.xml.meta +++ b/Editor/wx-editor.xml.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: bb654cc867f7f01422a0f96772382a10 +guid: d7b9a503098a826e42d62de42937c364 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/Plugins/LitJson.dll b/Runtime/Plugins/LitJson.dll index 93d00558..d1ce0182 100644 Binary files a/Runtime/Plugins/LitJson.dll and b/Runtime/Plugins/LitJson.dll differ diff --git a/Runtime/Plugins/SDK-Call-JS-Old.jslib b/Runtime/Plugins/SDK-Call-JS-Old.jslib index 0f190828..4d3e66b7 100755 --- a/Runtime/Plugins/SDK-Call-JS-Old.jslib +++ b/Runtime/Plugins/SDK-Call-JS-Old.jslib @@ -1058,4 +1058,7 @@ mergeInto(LibraryManager.library, { stringToUTF8(returnStr, buffer, bufferSize); return buffer; }, + WX_SetPreferredFramesPerSecond: function(fps) { + window.WXWASMSDK.WX_SetPreferredFramesPerSecond(fps); + } }); diff --git a/Runtime/Plugins/SDK-Call-JS.jslib b/Runtime/Plugins/SDK-Call-JS.jslib index 17a85e0b..3256e5b8 100644 --- a/Runtime/Plugins/SDK-Call-JS.jslib +++ b/Runtime/Plugins/SDK-Call-JS.jslib @@ -1,694 +1,31 @@ mergeInto(LibraryManager.library, { -WX_AddCard:function(conf, callbackId) { - window.WXWASMSDK.WX_AddCard(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); +WX_OneWayFunction:function(functionName, successType, failType, completeType, conf, callbackId) { + window.WXWASMSDK.WX_OneWayFunction(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(successType), _WXPointer_stringify_adaptor(failType), _WXPointer_stringify_adaptor(completeType), _WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); }, -WX_AuthPrivateMessage:function(conf, callbackId) { - window.WXWASMSDK.WX_AuthPrivateMessage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); +WX_OneWayNoFunction_v: function (functionName) { + window.WXWASMSDK.WX_OneWayNoFunction_v(_WXPointer_stringify_adaptor(functionName)); }, -WX_Authorize:function(conf, callbackId) { - window.WXWASMSDK.WX_Authorize(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); +WX_OneWayNoFunction_vs: function (functionName, param1) { + window.WXWASMSDK.WX_OneWayNoFunction_vs(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(param1)); }, -WX_CheckIsAddedToMyMiniProgram:function(conf, callbackId) { - window.WXWASMSDK.WX_CheckIsAddedToMyMiniProgram(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); +WX_OneWayNoFunction_vt: function (functionName, param1) { + window.WXWASMSDK.WX_OneWayNoFunction_vt(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(param1)); }, -WX_CheckSession:function(conf, callbackId) { - window.WXWASMSDK.WX_CheckSession(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); +WX_OneWayNoFunction_vst: function (functionName, param1, param2) { + window.WXWASMSDK.WX_OneWayNoFunction_vst(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(param1), _WXPointer_stringify_adaptor(param2)); }, -WX_ChooseImage:function(conf, callbackId) { - window.WXWASMSDK.WX_ChooseImage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); +WX_OneWayNoFunction_vsn: function (functionName, param1, param2) { + window.WXWASMSDK.WX_OneWayNoFunction_vsn(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(param1), param2); }, -WX_ChooseMedia:function(conf, callbackId) { - window.WXWASMSDK.WX_ChooseMedia(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); +WX_OneWayNoFunction_vnns: function (functionName, param1, param2, param3) { + window.WXWASMSDK.WX_OneWayNoFunction_vnns(_WXPointer_stringify_adaptor(functionName), param1, param2, _WXPointer_stringify_adaptor(param3)); }, -WX_ChooseMessageFile:function(conf, callbackId) { - window.WXWASMSDK.WX_ChooseMessageFile(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); +WX_OnEventRegister:function(functionName, resType) { + window.WXWASMSDK.WX_OnEventRegister(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(resType)); }, -WX_CloseBLEConnection:function(conf, callbackId) { - window.WXWASMSDK.WX_CloseBLEConnection(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); +WX_OffEventRegister:function(functionName) { + window.WXWASMSDK.WX_OffEventRegister(_WXPointer_stringify_adaptor(functionName)); }, -WX_CloseBluetoothAdapter:function(conf, callbackId) { - window.WXWASMSDK.WX_CloseBluetoothAdapter(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_CompressImage:function(conf, callbackId) { - window.WXWASMSDK.WX_CompressImage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_CreateBLEConnection:function(conf, callbackId) { - window.WXWASMSDK.WX_CreateBLEConnection(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_CreateBLEPeripheralServer:function(conf, callbackId) { - window.WXWASMSDK.WX_CreateBLEPeripheralServer(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ExitMiniProgram:function(conf, callbackId) { - window.WXWASMSDK.WX_ExitMiniProgram(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ExitVoIPChat:function(conf, callbackId) { - window.WXWASMSDK.WX_ExitVoIPChat(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_FaceDetect:function(conf, callbackId) { - window.WXWASMSDK.WX_FaceDetect(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetAvailableAudioSources:function(conf, callbackId) { - window.WXWASMSDK.WX_GetAvailableAudioSources(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetBLEDeviceCharacteristics:function(conf, callbackId) { - window.WXWASMSDK.WX_GetBLEDeviceCharacteristics(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetBLEDeviceRSSI:function(conf, callbackId) { - window.WXWASMSDK.WX_GetBLEDeviceRSSI(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetBLEDeviceServices:function(conf, callbackId) { - window.WXWASMSDK.WX_GetBLEDeviceServices(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetBLEMTU:function(conf, callbackId) { - window.WXWASMSDK.WX_GetBLEMTU(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetBackgroundFetchData:function(conf, callbackId) { - window.WXWASMSDK.WX_GetBackgroundFetchData(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetBackgroundFetchToken:function(conf, callbackId) { - window.WXWASMSDK.WX_GetBackgroundFetchToken(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetBatteryInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetBatteryInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetBeacons:function(conf, callbackId) { - window.WXWASMSDK.WX_GetBeacons(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetBluetoothAdapterState:function(conf, callbackId) { - window.WXWASMSDK.WX_GetBluetoothAdapterState(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetBluetoothDevices:function(conf, callbackId) { - window.WXWASMSDK.WX_GetBluetoothDevices(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetChannelsLiveInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetChannelsLiveInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetChannelsLiveNoticeInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetChannelsLiveNoticeInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetClipboardData:function(conf, callbackId) { - window.WXWASMSDK.WX_GetClipboardData(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetConnectedBluetoothDevices:function(conf, callbackId) { - window.WXWASMSDK.WX_GetConnectedBluetoothDevices(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetDeviceBenchmarkInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetDeviceBenchmarkInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetExtConfig:function(conf, callbackId) { - window.WXWASMSDK.WX_GetExtConfig(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetFuzzyLocation:function(conf, callbackId) { - window.WXWASMSDK.WX_GetFuzzyLocation(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetGameClubData:function(conf, callbackId) { - window.WXWASMSDK.WX_GetGameClubData(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetGroupEnterInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetGroupEnterInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetInferenceEnvInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetInferenceEnvInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetLocalIPAddress:function(conf, callbackId) { - window.WXWASMSDK.WX_GetLocalIPAddress(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetNetworkType:function(conf, callbackId) { - window.WXWASMSDK.WX_GetNetworkType(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetPrivacySetting:function(conf, callbackId) { - window.WXWASMSDK.WX_GetPrivacySetting(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetScreenBrightness:function(conf, callbackId) { - window.WXWASMSDK.WX_GetScreenBrightness(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetScreenRecordingState:function(conf, callbackId) { - window.WXWASMSDK.WX_GetScreenRecordingState(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetSetting:function(conf, callbackId) { - window.WXWASMSDK.WX_GetSetting(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetShareInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetShareInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetStorageInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetStorageInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetSystemInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetSystemInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetSystemInfoAsync:function(conf, callbackId) { - window.WXWASMSDK.WX_GetSystemInfoAsync(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetUserInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetUserInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetUserInteractiveStorage:function(conf, callbackId) { - window.WXWASMSDK.WX_GetUserInteractiveStorage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetWeRunData:function(conf, callbackId) { - window.WXWASMSDK.WX_GetWeRunData(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_HideKeyboard:function(conf, callbackId) { - window.WXWASMSDK.WX_HideKeyboard(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_HideLoading:function(conf, callbackId) { - window.WXWASMSDK.WX_HideLoading(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_HideShareMenu:function(conf, callbackId) { - window.WXWASMSDK.WX_HideShareMenu(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_HideToast:function(conf, callbackId) { - window.WXWASMSDK.WX_HideToast(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_InitFaceDetect:function(conf, callbackId) { - window.WXWASMSDK.WX_InitFaceDetect(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_IsBluetoothDevicePaired:function(conf, callbackId) { - window.WXWASMSDK.WX_IsBluetoothDevicePaired(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_JoinVoIPChat:function(conf, callbackId) { - window.WXWASMSDK.WX_JoinVoIPChat(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_Login:function(conf, callbackId) { - window.WXWASMSDK.WX_Login(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_MakeBluetoothPair:function(conf, callbackId) { - window.WXWASMSDK.WX_MakeBluetoothPair(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_NavigateToMiniProgram:function(conf, callbackId) { - window.WXWASMSDK.WX_NavigateToMiniProgram(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_NotifyBLECharacteristicValueChange:function(conf, callbackId) { - window.WXWASMSDK.WX_NotifyBLECharacteristicValueChange(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenAppAuthorizeSetting:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenAppAuthorizeSetting(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenBluetoothAdapter:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenBluetoothAdapter(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenCard:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenCard(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenChannelsActivity:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenChannelsActivity(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenChannelsEvent:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenChannelsEvent(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenChannelsLive:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenChannelsLive(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenChannelsUserProfile:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenChannelsUserProfile(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenCustomerServiceChat:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenCustomerServiceChat(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenCustomerServiceConversation:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenCustomerServiceConversation(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenPrivacyContract:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenPrivacyContract(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenSetting:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenSetting(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenSystemBluetoothSetting:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenSystemBluetoothSetting(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_PreviewImage:function(conf, callbackId) { - window.WXWASMSDK.WX_PreviewImage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_PreviewMedia:function(conf, callbackId) { - window.WXWASMSDK.WX_PreviewMedia(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ReadBLECharacteristicValue:function(conf, callbackId) { - window.WXWASMSDK.WX_ReadBLECharacteristicValue(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_RemoveStorage:function(conf, callbackId) { - window.WXWASMSDK.WX_RemoveStorage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_RemoveUserCloudStorage:function(conf, callbackId) { - window.WXWASMSDK.WX_RemoveUserCloudStorage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ReportScene:function(conf, callbackId) { - window.WXWASMSDK.WX_ReportScene(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_RequestMidasFriendPayment:function(conf, callbackId) { - window.WXWASMSDK.WX_RequestMidasFriendPayment(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_RequestMidasPayment:function(conf, callbackId) { - window.WXWASMSDK.WX_RequestMidasPayment(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_RequestMidasPaymentGameItem:function(conf, callbackId) { - window.WXWASMSDK.WX_RequestMidasPaymentGameItem(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_RequestSubscribeMessage:function(conf, callbackId) { - window.WXWASMSDK.WX_RequestSubscribeMessage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_RequestSubscribeSystemMessage:function(conf, callbackId) { - window.WXWASMSDK.WX_RequestSubscribeSystemMessage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_RequirePrivacyAuthorize:function(conf, callbackId) { - window.WXWASMSDK.WX_RequirePrivacyAuthorize(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_RestartMiniProgram:function(conf, callbackId) { - window.WXWASMSDK.WX_RestartMiniProgram(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SaveFileToDisk:function(conf, callbackId) { - window.WXWASMSDK.WX_SaveFileToDisk(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SaveImageToPhotosAlbum:function(conf, callbackId) { - window.WXWASMSDK.WX_SaveImageToPhotosAlbum(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ScanCode:function(conf, callbackId) { - window.WXWASMSDK.WX_ScanCode(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetBLEMTU:function(conf, callbackId) { - window.WXWASMSDK.WX_SetBLEMTU(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetBackgroundFetchToken:function(conf, callbackId) { - window.WXWASMSDK.WX_SetBackgroundFetchToken(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetClipboardData:function(conf, callbackId) { - window.WXWASMSDK.WX_SetClipboardData(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetDeviceOrientation:function(conf, callbackId) { - window.WXWASMSDK.WX_SetDeviceOrientation(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetEnableDebug:function(conf, callbackId) { - window.WXWASMSDK.WX_SetEnableDebug(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetInnerAudioOption:function(conf, callbackId) { - window.WXWASMSDK.WX_SetInnerAudioOption(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetKeepScreenOn:function(conf, callbackId) { - window.WXWASMSDK.WX_SetKeepScreenOn(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetMenuStyle:function(conf, callbackId) { - window.WXWASMSDK.WX_SetMenuStyle(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetScreenBrightness:function(conf, callbackId) { - window.WXWASMSDK.WX_SetScreenBrightness(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetStatusBarStyle:function(conf, callbackId) { - window.WXWASMSDK.WX_SetStatusBarStyle(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetUserCloudStorage:function(conf, callbackId) { - window.WXWASMSDK.WX_SetUserCloudStorage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_SetVisualEffectOnCapture:function(conf, callbackId) { - window.WXWASMSDK.WX_SetVisualEffectOnCapture(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ShowActionSheet:function(conf, callbackId) { - window.WXWASMSDK.WX_ShowActionSheet(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ShowKeyboard:function(conf, callbackId) { - window.WXWASMSDK.WX_ShowKeyboard(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ShowLoading:function(conf, callbackId) { - window.WXWASMSDK.WX_ShowLoading(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ShowModal:function(conf, callbackId) { - window.WXWASMSDK.WX_ShowModal(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ShowShareImageMenu:function(conf, callbackId) { - window.WXWASMSDK.WX_ShowShareImageMenu(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ShowShareMenu:function(conf, callbackId) { - window.WXWASMSDK.WX_ShowShareMenu(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_ShowToast:function(conf, callbackId) { - window.WXWASMSDK.WX_ShowToast(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StartAccelerometer:function(conf, callbackId) { - window.WXWASMSDK.WX_StartAccelerometer(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StartBeaconDiscovery:function(conf, callbackId) { - window.WXWASMSDK.WX_StartBeaconDiscovery(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StartBluetoothDevicesDiscovery:function(conf, callbackId) { - window.WXWASMSDK.WX_StartBluetoothDevicesDiscovery(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StartCompass:function(conf, callbackId) { - window.WXWASMSDK.WX_StartCompass(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StartDeviceMotionListening:function(conf, callbackId) { - window.WXWASMSDK.WX_StartDeviceMotionListening(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StopAccelerometer:function(conf, callbackId) { - window.WXWASMSDK.WX_StopAccelerometer(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StopBeaconDiscovery:function(conf, callbackId) { - window.WXWASMSDK.WX_StopBeaconDiscovery(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StopBluetoothDevicesDiscovery:function(conf, callbackId) { - window.WXWASMSDK.WX_StopBluetoothDevicesDiscovery(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StopCompass:function(conf, callbackId) { - window.WXWASMSDK.WX_StopCompass(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StopDeviceMotionListening:function(conf, callbackId) { - window.WXWASMSDK.WX_StopDeviceMotionListening(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StopFaceDetect:function(conf, callbackId) { - window.WXWASMSDK.WX_StopFaceDetect(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_UpdateKeyboard:function(conf, callbackId) { - window.WXWASMSDK.WX_UpdateKeyboard(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_UpdateShareMenu:function(conf, callbackId) { - window.WXWASMSDK.WX_UpdateShareMenu(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_UpdateVoIPChatMuteConfig:function(conf, callbackId) { - window.WXWASMSDK.WX_UpdateVoIPChatMuteConfig(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_UpdateWeChatApp:function(conf, callbackId) { - window.WXWASMSDK.WX_UpdateWeChatApp(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_VibrateLong:function(conf, callbackId) { - window.WXWASMSDK.WX_VibrateLong(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_VibrateShort:function(conf, callbackId) { - window.WXWASMSDK.WX_VibrateShort(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_WriteBLECharacteristicValue:function(conf, callbackId) { - window.WXWASMSDK.WX_WriteBLECharacteristicValue(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_StartGameLive:function(conf, callbackId) { - window.WXWASMSDK.WX_StartGameLive(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_CheckGameLiveEnabled:function(conf, callbackId) { - window.WXWASMSDK.WX_CheckGameLiveEnabled(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetUserCurrentGameliveInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetUserCurrentGameliveInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetUserRecentGameLiveInfo:function(conf, callbackId) { - window.WXWASMSDK.WX_GetUserRecentGameLiveInfo(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_GetUserGameLiveDetails:function(conf, callbackId) { - window.WXWASMSDK.WX_GetUserGameLiveDetails(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenChannelsLiveCollection:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenChannelsLiveCollection(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenPage:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenPage(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_RequestSubscribeLiveActivity:function(conf, callbackId) { - window.WXWASMSDK.WX_RequestSubscribeLiveActivity(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, -WX_OpenBusinessView:function(conf, callbackId) { - window.WXWASMSDK.WX_OpenBusinessView(_WXPointer_stringify_adaptor(conf), _WXPointer_stringify_adaptor(callbackId)); -}, - -WX_ExitPointerLock:function() { - window.WXWASMSDK.WX_ExitPointerLock(); -}, -WX_OperateGameRecorderVideo:function(option){ - window.WXWASMSDK.WX_OperateGameRecorderVideo(_WXPointer_stringify_adaptor(option)); -}, -WX_RemoveStorageSync:function(key){ - window.WXWASMSDK.WX_RemoveStorageSync(_WXPointer_stringify_adaptor(key)); -}, -WX_ReportEvent:function(eventId, data){ - window.WXWASMSDK.WX_ReportEvent(_WXPointer_stringify_adaptor(eventId), _WXPointer_stringify_adaptor(data)); -}, -WX_ReportPerformance:function(id, value, dimensions){ - window.WXWASMSDK.WX_ReportPerformance(id, value, _WXPointer_stringify_adaptor(dimensions)); -}, -WX_ReportUserBehaviorBranchAnalytics:function(option){ - window.WXWASMSDK.WX_ReportUserBehaviorBranchAnalytics(_WXPointer_stringify_adaptor(option)); -}, -WX_RequestPointerLock:function() { - window.WXWASMSDK.WX_RequestPointerLock(); -}, -WX_ReserveChannelsLive:function(option){ - window.WXWASMSDK.WX_ReserveChannelsLive(_WXPointer_stringify_adaptor(option)); -}, -WX_RevokeBufferURL:function(url){ - window.WXWASMSDK.WX_RevokeBufferURL(_WXPointer_stringify_adaptor(url)); -}, -WX_SetPreferredFramesPerSecond:function(fps){ - window.WXWASMSDK.WX_SetPreferredFramesPerSecond(fps); -}, -WX_SetStorageSync:function(key, data){ - window.WXWASMSDK.WX_SetStorageSync(_WXPointer_stringify_adaptor(key), _WXPointer_stringify_adaptor(data)); -}, -WX_ShareAppMessage:function(option){ - window.WXWASMSDK.WX_ShareAppMessage(_WXPointer_stringify_adaptor(option)); -}, -WX_TriggerGC:function() { - window.WXWASMSDK.WX_TriggerGC(); -}, - -WX_OnAccelerometerChange:function() { - window.WXWASMSDK.WX_OnAccelerometerChange(); -}, -WX_OffAccelerometerChange:function() { - window.WXWASMSDK.WX_OffAccelerometerChange(); -}, -WX_OnAudioInterruptionBegin:function() { - window.WXWASMSDK.WX_OnAudioInterruptionBegin(); -}, -WX_OffAudioInterruptionBegin:function() { - window.WXWASMSDK.WX_OffAudioInterruptionBegin(); -}, -WX_OnAudioInterruptionEnd:function() { - window.WXWASMSDK.WX_OnAudioInterruptionEnd(); -}, -WX_OffAudioInterruptionEnd:function() { - window.WXWASMSDK.WX_OffAudioInterruptionEnd(); -}, -WX_OnBLEConnectionStateChange:function() { - window.WXWASMSDK.WX_OnBLEConnectionStateChange(); -}, -WX_OffBLEConnectionStateChange:function() { - window.WXWASMSDK.WX_OffBLEConnectionStateChange(); -}, -WX_OnBLEMTUChange:function() { - window.WXWASMSDK.WX_OnBLEMTUChange(); -}, -WX_OffBLEMTUChange:function() { - window.WXWASMSDK.WX_OffBLEMTUChange(); -}, -WX_OnBLEPeripheralConnectionStateChanged:function() { - window.WXWASMSDK.WX_OnBLEPeripheralConnectionStateChanged(); -}, -WX_OffBLEPeripheralConnectionStateChanged:function() { - window.WXWASMSDK.WX_OffBLEPeripheralConnectionStateChanged(); -}, -WX_OnBackgroundFetchData:function() { - window.WXWASMSDK.WX_OnBackgroundFetchData(); -}, -WX_OnBeaconServiceChange:function() { - window.WXWASMSDK.WX_OnBeaconServiceChange(); -}, -WX_OffBeaconServiceChange:function() { - window.WXWASMSDK.WX_OffBeaconServiceChange(); -}, -WX_OnBeaconUpdate:function() { - window.WXWASMSDK.WX_OnBeaconUpdate(); -}, -WX_OffBeaconUpdate:function() { - window.WXWASMSDK.WX_OffBeaconUpdate(); -}, -WX_OnBluetoothAdapterStateChange:function() { - window.WXWASMSDK.WX_OnBluetoothAdapterStateChange(); -}, -WX_OffBluetoothAdapterStateChange:function() { - window.WXWASMSDK.WX_OffBluetoothAdapterStateChange(); -}, -WX_OnBluetoothDeviceFound:function() { - window.WXWASMSDK.WX_OnBluetoothDeviceFound(); -}, -WX_OffBluetoothDeviceFound:function() { - window.WXWASMSDK.WX_OffBluetoothDeviceFound(); -}, -WX_OnCompassChange:function() { - window.WXWASMSDK.WX_OnCompassChange(); -}, -WX_OffCompassChange:function() { - window.WXWASMSDK.WX_OffCompassChange(); -}, -WX_OnDeviceMotionChange:function() { - window.WXWASMSDK.WX_OnDeviceMotionChange(); -}, -WX_OffDeviceMotionChange:function() { - window.WXWASMSDK.WX_OffDeviceMotionChange(); -}, -WX_OnDeviceOrientationChange:function() { - window.WXWASMSDK.WX_OnDeviceOrientationChange(); -}, -WX_OffDeviceOrientationChange:function() { - window.WXWASMSDK.WX_OffDeviceOrientationChange(); -}, -WX_OnError:function() { - window.WXWASMSDK.WX_OnError(); -}, -WX_OffError:function() { - window.WXWASMSDK.WX_OffError(); -}, -WX_OnHide:function() { - window.WXWASMSDK.WX_OnHide(); -}, -WX_OffHide:function() { - window.WXWASMSDK.WX_OffHide(); -}, -WX_OnInteractiveStorageModified:function() { - window.WXWASMSDK.WX_OnInteractiveStorageModified(); -}, -WX_OffInteractiveStorageModified:function() { - window.WXWASMSDK.WX_OffInteractiveStorageModified(); -}, -WX_OnKeyDown:function() { - window.WXWASMSDK.WX_OnKeyDown(); -}, -WX_OffKeyDown:function() { - window.WXWASMSDK.WX_OffKeyDown(); -}, -WX_OnKeyUp:function() { - window.WXWASMSDK.WX_OnKeyUp(); -}, -WX_OffKeyUp:function() { - window.WXWASMSDK.WX_OffKeyUp(); -}, -WX_OnKeyboardComplete:function() { - window.WXWASMSDK.WX_OnKeyboardComplete(); -}, -WX_OffKeyboardComplete:function() { - window.WXWASMSDK.WX_OffKeyboardComplete(); -}, -WX_OnKeyboardConfirm:function() { - window.WXWASMSDK.WX_OnKeyboardConfirm(); -}, -WX_OffKeyboardConfirm:function() { - window.WXWASMSDK.WX_OffKeyboardConfirm(); -}, -WX_OnKeyboardHeightChange:function() { - window.WXWASMSDK.WX_OnKeyboardHeightChange(); -}, -WX_OffKeyboardHeightChange:function() { - window.WXWASMSDK.WX_OffKeyboardHeightChange(); -}, -WX_OnKeyboardInput:function() { - window.WXWASMSDK.WX_OnKeyboardInput(); -}, -WX_OffKeyboardInput:function() { - window.WXWASMSDK.WX_OffKeyboardInput(); -}, -WX_OnMemoryWarning:function() { - window.WXWASMSDK.WX_OnMemoryWarning(); -}, -WX_OffMemoryWarning:function() { - window.WXWASMSDK.WX_OffMemoryWarning(); -}, -WX_OnMenuButtonBoundingClientRectWeightChange:function() { - window.WXWASMSDK.WX_OnMenuButtonBoundingClientRectWeightChange(); -}, -WX_OffMenuButtonBoundingClientRectWeightChange:function() { - window.WXWASMSDK.WX_OffMenuButtonBoundingClientRectWeightChange(); -}, -WX_OnMessage:function() { - window.WXWASMSDK.WX_OnMessage(); -}, -WX_OnMouseDown:function() { - window.WXWASMSDK.WX_OnMouseDown(); -}, -WX_OffMouseDown:function() { - window.WXWASMSDK.WX_OffMouseDown(); -}, -WX_OnMouseMove:function() { - window.WXWASMSDK.WX_OnMouseMove(); -}, -WX_OffMouseMove:function() { - window.WXWASMSDK.WX_OffMouseMove(); -}, -WX_OnMouseUp:function() { - window.WXWASMSDK.WX_OnMouseUp(); -}, -WX_OffMouseUp:function() { - window.WXWASMSDK.WX_OffMouseUp(); -}, -WX_OnNetworkStatusChange:function() { - window.WXWASMSDK.WX_OnNetworkStatusChange(); -}, -WX_OffNetworkStatusChange:function() { - window.WXWASMSDK.WX_OffNetworkStatusChange(); -}, -WX_OnNetworkWeakChange:function() { - window.WXWASMSDK.WX_OnNetworkWeakChange(); -}, -WX_OffNetworkWeakChange:function() { - window.WXWASMSDK.WX_OffNetworkWeakChange(); -}, -WX_OnScreenRecordingStateChanged:function() { - window.WXWASMSDK.WX_OnScreenRecordingStateChanged(); -}, -WX_OffScreenRecordingStateChanged:function() { - window.WXWASMSDK.WX_OffScreenRecordingStateChanged(); -}, -WX_OnShareMessageToFriend:function() { - window.WXWASMSDK.WX_OnShareMessageToFriend(); -}, -WX_OnShow:function() { - window.WXWASMSDK.WX_OnShow(); -}, -WX_OffShow:function() { - window.WXWASMSDK.WX_OffShow(); -}, -WX_OnUnhandledRejection:function() { - window.WXWASMSDK.WX_OnUnhandledRejection(); -}, -WX_OffUnhandledRejection:function() { - window.WXWASMSDK.WX_OffUnhandledRejection(); -}, -WX_OnUserCaptureScreen:function() { - window.WXWASMSDK.WX_OnUserCaptureScreen(); -}, -WX_OffUserCaptureScreen:function() { - window.WXWASMSDK.WX_OffUserCaptureScreen(); -}, -WX_OnVoIPChatInterrupted:function() { - window.WXWASMSDK.WX_OnVoIPChatInterrupted(); -}, -WX_OffVoIPChatInterrupted:function() { - window.WXWASMSDK.WX_OffVoIPChatInterrupted(); -}, -WX_OnVoIPChatMembersChanged:function() { - window.WXWASMSDK.WX_OnVoIPChatMembersChanged(); -}, -WX_OffVoIPChatMembersChanged:function() { - window.WXWASMSDK.WX_OffVoIPChatMembersChanged(); -}, -WX_OnVoIPChatSpeakersChanged:function() { - window.WXWASMSDK.WX_OnVoIPChatSpeakersChanged(); -}, -WX_OffVoIPChatSpeakersChanged:function() { - window.WXWASMSDK.WX_OffVoIPChatSpeakersChanged(); -}, -WX_OnVoIPChatStateChanged:function() { - window.WXWASMSDK.WX_OnVoIPChatStateChanged(); -}, -WX_OffVoIPChatStateChanged:function() { - window.WXWASMSDK.WX_OffVoIPChatStateChanged(); -}, -WX_OnWheel:function() { - window.WXWASMSDK.WX_OnWheel(); -}, -WX_OffWheel:function() { - window.WXWASMSDK.WX_OffWheel(); -}, -WX_OnWindowResize:function() { - window.WXWASMSDK.WX_OnWindowResize(); -}, -WX_OffWindowResize:function() { - window.WXWASMSDK.WX_OffWindowResize(); -}, - WX_OnAddToFavorites:function() { window.WXWASMSDK.WX_OnAddToFavorites(); }, @@ -735,332 +72,89 @@ WX_OnGameLiveStateChange_Resolve:function(conf){ window.WXWASMSDK.WX_OnGameLiveStateChange_Resolve(_WXPointer_stringify_adaptor(conf)); }, -WX_SetHandoffQuery:function( - query -){ - var res = window.WXWASMSDK.WX_SetHandoffQuery(_WXPointer_stringify_adaptor(query)); - return res; +WX_SyncFunction_bs: function(functionName, param1){ + return window.WXWASMSDK.WX_SyncFunction_bs(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(param1)); }, -WX_GetAccountInfoSync:function( -){ - var res = window.WXWASMSDK.WX_GetAccountInfoSync(); +WX_SyncFunction_t: function(functionName, returnType){ + var res = window.WXWASMSDK.WX_SyncFunction_t(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(returnType)); var bufferSize = lengthBytesUTF8(res || '') + 1; var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; + stringToUTF8((res || ''), buffer, bufferSize); + return buffer; }, -WX_GetAppAuthorizeSetting:function( -){ - var res = window.WXWASMSDK.WX_GetAppAuthorizeSetting(); +WX_SyncFunction_tt: function(functionName, returnType, param1){ + var res = window.WXWASMSDK.WX_SyncFunction_tt(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(returnType), _WXPointer_stringify_adaptor(param1)); var bufferSize = lengthBytesUTF8(res || '') + 1; var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); + stringToUTF8((res || ''), buffer, bufferSize); return buffer; }, -WX_GetAppBaseInfo:function( -){ - var res = window.WXWASMSDK.WX_GetAppBaseInfo(); +WX_SyncFunction_b: function(functionName){ + return window.WXWASMSDK.WX_SyncFunction_b(_WXPointer_stringify_adaptor(functionName)); +}, +WX_SyncFunction_bsnn: function(functionName, param1, param2, param3){ + return window.WXWASMSDK.WX_SyncFunction_bsnn(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(param1), param2, param3); +}, +WX_SyncFunction_bt: function(functionName, param1){ + return window.WXWASMSDK.WX_SyncFunction_bt(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(param1)); +}, +WX_SyncFunction_nt: function(functionName, param1){ + return window.WXWASMSDK.WX_SyncFunction_nt(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(param1)); +}, +WX_SyncFunction_ss: function(functionName, param1){ + var res = window.WXWASMSDK.WX_SyncFunction_ss(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(param1)); var bufferSize = lengthBytesUTF8(res || '') + 1; var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); + stringToUTF8((res || ''), buffer, bufferSize); return buffer; }, -WX_GetBatteryInfoSync:function( -){ - var res = window.WXWASMSDK.WX_GetBatteryInfoSync(); +WX_SyncFunction_tnn: function(functionName, returnType, param1, param2){ + var res = window.WXWASMSDK.WX_SyncFunction_tnn(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(returnType), param1, param2); var bufferSize = lengthBytesUTF8(res || '') + 1; var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); + stringToUTF8((res || ''), buffer, bufferSize); return buffer; }, -WX_GetDeviceInfo:function( -){ - var res = window.WXWASMSDK.WX_GetDeviceInfo(); +WX_ClassOneWayFunction:function(functionName, returnType, successType, failType, completeType, conf) { + var res = window.WXWASMSDK.WX_ClassOneWayFunction(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(returnType), _WXPointer_stringify_adaptor(successType), _WXPointer_stringify_adaptor(failType), _WXPointer_stringify_adaptor(completeType), _WXPointer_stringify_adaptor(conf)); var bufferSize = lengthBytesUTF8(res || '') + 1; var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); + stringToUTF8((res || ''), buffer, bufferSize); return buffer; }, -WX_GetEnterOptionsSync:function( -){ - var res = window.WXWASMSDK.WX_GetEnterOptionsSync(); +WX_ClassFunction: function(functionName, returnType, option) { + var res = window.WXWASMSDK.WX_ClassFunction(_WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(returnType), _WXPointer_stringify_adaptor(option)); var bufferSize = lengthBytesUTF8(res || '') + 1; var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); + stringToUTF8((res || ''), buffer, bufferSize); return buffer; }, -WX_GetExptInfoSync:function( - keys -){ - var res = window.WXWASMSDK.WX_GetExptInfoSync(_WXPointer_stringify_adaptor(keys)); +WX_ClassSetProperty: function(className, id, key, value) { + window.WXWASMSDK.WX_ClassSetProperty(_WXPointer_stringify_adaptor(className), _WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(key), _WXPointer_stringify_adaptor(value)); +}, +WX_ClassOnEventFunction: function(className, functionName, returnType, id, eventName) { + window.WXWASMSDK.WX_ClassOnEventFunction(_WXPointer_stringify_adaptor(className), _WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(returnType), _WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(eventName)); +}, +WX_ClassOffEventFunction: function(className, functionName, id, eventType) { + window.WXWASMSDK.WX_ClassOffEventFunction(_WXPointer_stringify_adaptor(className), _WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(eventType)); +}, +WX_ClassOneWayNoFunction_v: function(className, functionName, id) { + window.WXWASMSDK.WX_ClassOneWayNoFunction_v(_WXPointer_stringify_adaptor(className), _WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(id)); +}, +WX_ClassOneWayNoFunction_vs: function(className, functionName, id, param1) { + window.WXWASMSDK.WX_ClassOneWayNoFunction_vs(_WXPointer_stringify_adaptor(className), _WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(param1)); +}, +WX_ClassOneWayNoFunction_t: function(className, functionName, returnType, id) { + var res = window.WXWASMSDK.WX_ClassOneWayNoFunction_t(_WXPointer_stringify_adaptor(className), _WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(returnType), _WXPointer_stringify_adaptor(id)); var bufferSize = lengthBytesUTF8(res || '') + 1; var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); + stringToUTF8((res || ''), buffer, bufferSize); return buffer; }, -WX_GetExtConfigSync:function( -){ - var res = window.WXWASMSDK.WX_GetExtConfigSync(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; +WX_ClassOneWayNoFunction_vt: function(className, functionName, id, param1) { + window.WXWASMSDK.WX_ClassOneWayNoFunction_vt(_WXPointer_stringify_adaptor(className), _WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(param1)); }, -WX_GetLaunchOptionsSync:function( -){ - var res = window.WXWASMSDK.WX_GetLaunchOptionsSync(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; +WX_ClassOneWayNoFunction_vn: function(className, functionName, id, param1) { + window.WXWASMSDK.WX_ClassOneWayNoFunction_vs(_WXPointer_stringify_adaptor(className), _WXPointer_stringify_adaptor(functionName), _WXPointer_stringify_adaptor(id), param1); }, -WX_GetMenuButtonBoundingClientRect:function( -){ - var res = window.WXWASMSDK.WX_GetMenuButtonBoundingClientRect(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_GetStorageInfoSync:function( -){ - var res = window.WXWASMSDK.WX_GetStorageInfoSync(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_GetSystemInfoSync:function( -){ - var res = window.WXWASMSDK.WX_GetSystemInfoSync(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_GetSystemSetting:function( -){ - var res = window.WXWASMSDK.WX_GetSystemSetting(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_GetWindowInfo:function( -){ - var res = window.WXWASMSDK.WX_GetWindowInfo(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_CreateImageData:function( - width,height -){ - var res = window.WXWASMSDK.WX_CreateImageData(width,height); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_CreatePath2D:function( -){ - var res = window.WXWASMSDK.WX_CreatePath2D(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_IsPointerLocked:function( -){ - var res = window.WXWASMSDK.WX_IsPointerLocked(); - return res; -}, -WX_IsVKSupport:function( - version -){ - var res = window.WXWASMSDK.WX_IsVKSupport(_WXPointer_stringify_adaptor(version)); - return res; -}, -WX_SetCursor:function( - path,x,y -){ - var res = window.WXWASMSDK.WX_SetCursor(_WXPointer_stringify_adaptor(path),x,y); - return res; -}, -WX_SetMessageToFriendQuery:function( - option -){ - var res = window.WXWASMSDK.WX_SetMessageToFriendQuery(_WXPointer_stringify_adaptor(option)); - return res; -}, -WX_GetTextLineHeight:function( - option -){ - var res = window.WXWASMSDK.WX_GetTextLineHeight(_WXPointer_stringify_adaptor(option)); - return res; -}, -WX_LoadFont:function( - path -){ - var res = window.WXWASMSDK.WX_LoadFont(_WXPointer_stringify_adaptor(path)); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_GetGameLiveState:function( -){ - var res = window.WXWASMSDK.WX_GetGameLiveState(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, - -WX_DownloadFile:function(conf) { - var res = window.WXWASMSDK.WX_DownloadFile(_WXPointer_stringify_adaptor(conf)); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_CreateFeedbackButton:function(option) { - var res = window.WXWASMSDK.WX_CreateFeedbackButton(_WXPointer_stringify_adaptor(option)); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_GetLogManager:function(option) { - var res = window.WXWASMSDK.WX_GetLogManager(_WXPointer_stringify_adaptor(option)); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_GetRealtimeLogManager:function() { - var res = window.WXWASMSDK.WX_GetRealtimeLogManager(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_GetUpdateManager:function() { - var res = window.WXWASMSDK.WX_GetUpdateManager(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_CreateVideoDecoder:function() { - var res = window.WXWASMSDK.WX_CreateVideoDecoder(); - var bufferSize = lengthBytesUTF8(res || '') + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, - -WX_DownloadTaskAbort:function(id) { - window.WXWASMSDK.WX_DownloadTaskAbort(_WXPointer_stringify_adaptor(id)); -}, -WX_DownloadTaskOffHeadersReceived:function(id) { - window.WXWASMSDK.WX_DownloadTaskOffHeadersReceived(_WXPointer_stringify_adaptor(id)); -}, -WX_DownloadTaskOffProgressUpdate:function(id) { - window.WXWASMSDK.WX_DownloadTaskOffProgressUpdate(_WXPointer_stringify_adaptor(id)); -}, -WX_DownloadTaskOnHeadersReceived:function(id) { - window.WXWASMSDK.WX_DownloadTaskOnHeadersReceived(_WXPointer_stringify_adaptor(id)); -}, -WX_DownloadTaskOnProgressUpdate:function(id) { - window.WXWASMSDK.WX_DownloadTaskOnProgressUpdate(_WXPointer_stringify_adaptor(id)); -}, -WXFeedbackButtonSetProperty: function(id, key, value) { - window.WXWASMSDK.WXFeedbackButtonSetProperty(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(key), _WXPointer_stringify_adaptor(value)); -}, - - - - -WX_FeedbackButtonDestroy:function(id) { - window.WXWASMSDK.WX_FeedbackButtonDestroy(_WXPointer_stringify_adaptor(id)); -}, -WX_FeedbackButtonHide:function(id) { - window.WXWASMSDK.WX_FeedbackButtonHide(_WXPointer_stringify_adaptor(id)); -}, -WX_FeedbackButtonOffTap:function(id) { - window.WXWASMSDK.WX_FeedbackButtonOffTap(_WXPointer_stringify_adaptor(id)); -}, -WX_FeedbackButtonOnTap:function(id) { - window.WXWASMSDK.WX_FeedbackButtonOnTap(_WXPointer_stringify_adaptor(id)); -}, -WX_FeedbackButtonShow:function(id) { - window.WXWASMSDK.WX_FeedbackButtonShow(_WXPointer_stringify_adaptor(id)); -}, -WX_LogManagerDebug:function(id, args) { - window.WXWASMSDK.WX_LogManagerDebug(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(args)); -}, -WX_LogManagerInfo:function(id, args) { - window.WXWASMSDK.WX_LogManagerInfo(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(args)); -}, -WX_LogManagerLog:function(id, args) { - window.WXWASMSDK.WX_LogManagerLog(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(args)); -}, -WX_LogManagerWarn:function(id, args) { - window.WXWASMSDK.WX_LogManagerWarn(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(args)); -}, -WX_RealtimeLogManagerAddFilterMsg:function(id, msg) { - window.WXWASMSDK.WX_RealtimeLogManagerAddFilterMsg(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(msg)); -}, -WX_RealtimeLogManagerError:function(id, args) { - window.WXWASMSDK.WX_RealtimeLogManagerError(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(args)); -}, -WX_RealtimeLogManagerInfo:function(id, args) { - window.WXWASMSDK.WX_RealtimeLogManagerInfo(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(args)); -}, -WX_RealtimeLogManagerSetFilterMsg:function(id, msg) { - window.WXWASMSDK.WX_RealtimeLogManagerSetFilterMsg(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(msg)); -}, -WX_RealtimeLogManagerWarn:function(id, args) { - window.WXWASMSDK.WX_RealtimeLogManagerWarn(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(args)); -}, -WX_UpdateManagerApplyUpdate:function(id) { - window.WXWASMSDK.WX_UpdateManagerApplyUpdate(_WXPointer_stringify_adaptor(id)); -}, -WX_UpdateManagerOnCheckForUpdate:function(id) { - window.WXWASMSDK.WX_UpdateManagerOnCheckForUpdate(_WXPointer_stringify_adaptor(id)); -}, -WX_UpdateManagerOnUpdateFailed:function(id) { - window.WXWASMSDK.WX_UpdateManagerOnUpdateFailed(_WXPointer_stringify_adaptor(id)); -}, -WX_UpdateManagerOnUpdateReady:function(id) { - window.WXWASMSDK.WX_UpdateManagerOnUpdateReady(_WXPointer_stringify_adaptor(id)); -}, -WX_VideoDecoderGetFrameData:function(id) { - var res = window.WXWASMSDK.WX_VideoDecoderGetFrameData(_WXPointer_stringify_adaptor(id)); - var bufferSize = lengthBytesUTF8(res) + 1; - var buffer = _malloc(bufferSize); - stringToUTF8(res, buffer, bufferSize); - return buffer; -}, -WX_VideoDecoderRemove:function(id) { - window.WXWASMSDK.WX_VideoDecoderRemove(_WXPointer_stringify_adaptor(id)); -}, -WX_VideoDecoderSeek:function(id, position) { - window.WXWASMSDK.WX_VideoDecoderSeek(_WXPointer_stringify_adaptor(id), position); -}, -WX_VideoDecoderStart:function(id, option) { - window.WXWASMSDK.WX_VideoDecoderStart(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(option)); -}, -WX_VideoDecoderStop:function(id) { - window.WXWASMSDK.WX_VideoDecoderStop(_WXPointer_stringify_adaptor(id)); -}, -WX_VideoDecoderOff:function(id, eventName) { - window.WXWASMSDK.WX_VideoDecoderOff(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(eventName)); -}, -WX_VideoDecoderOn:function(id, eventName) { - window.WXWASMSDK.WX_VideoDecoderOn(_WXPointer_stringify_adaptor(id), _WXPointer_stringify_adaptor(eventName)); -}, - }) \ No newline at end of file diff --git a/Runtime/Plugins/WxPerfJsBridge.jslib.meta b/Runtime/Plugins/WxPerfJsBridge.jslib.meta index 373be8ac..fb4bbc04 100644 --- a/Runtime/Plugins/WxPerfJsBridge.jslib.meta +++ b/Runtime/Plugins/WxPerfJsBridge.jslib.meta @@ -19,7 +19,7 @@ PluginImporter: Exclude Editor: 1 Exclude Linux64: 1 Exclude OSXUniversal: 1 - Exclude WeixinMiniGame: 0 + Exclude WeixinMiniGame: 1 Exclude Win: 1 Exclude Win64: 1 - first: @@ -38,7 +38,7 @@ PluginImporter: - first: Facebook: WebGL second: - enabled: 1 + enabled: 0 settings: {} - first: Standalone: Linux64 @@ -67,12 +67,12 @@ PluginImporter: - first: WebGL: WebGL second: - enabled: 1 + enabled: 0 settings: {} - first: WeixinMiniGame: WeixinMiniGame second: - enabled: 1 + enabled: 0 settings: {} userData: assetBundleName: diff --git a/Runtime/Plugins/wx-perf.dll b/Runtime/Plugins/wx-perf.dll index 1e147c66..fd3fc6aa 100644 Binary files a/Runtime/Plugins/wx-perf.dll and b/Runtime/Plugins/wx-perf.dll differ diff --git a/Runtime/Plugins/wx-runtime-editor.dll b/Runtime/Plugins/wx-runtime-editor.dll index 6370c7c2..ed3148eb 100644 Binary files a/Runtime/Plugins/wx-runtime-editor.dll and b/Runtime/Plugins/wx-runtime-editor.dll differ diff --git a/Runtime/Plugins/wx-runtime-editor.xml b/Runtime/Plugins/wx-runtime-editor.xml index 2166fe39..ab9d6bc2 100644 --- a/Runtime/Plugins/wx-runtime-editor.xml +++ b/Runtime/Plugins/wx-runtime-editor.xml @@ -329,14 +329,14 @@ 成功回调 失败回调 - + [DownloadTask.abort()](https://developers.weixin.qq.com/minigame/dev/api/network/download/DownloadTask.abort.html) 需要基础库: `1.4.0` 中断下载任务 - + [DownloadTask.offHeadersReceived(function listener)](https://developers.weixin.qq.com/minigame/dev/api/network/download/DownloadTask.offHeadersReceived.html) 需要基础库: `2.1.0` @@ -349,7 +349,7 @@ ``` - + [DownloadTask.offProgressUpdate(function listener)](https://developers.weixin.qq.com/minigame/dev/api/network/download/DownloadTask.offProgressUpdate.html) 需要基础库: `2.1.0` @@ -362,14 +362,14 @@ ``` - + [DownloadTask.onHeadersReceived(function listener)](https://developers.weixin.qq.com/minigame/dev/api/network/download/DownloadTask.onHeadersReceived.html) 需要基础库: `2.1.0` 监听 HTTP Response Header 事件。会比请求完成事件更早 - + [DownloadTask.onProgressUpdate(function listener)](https://developers.weixin.qq.com/minigame/dev/api/network/download/DownloadTask.onProgressUpdate.html) 需要基础库: `1.4.0` @@ -404,19 +404,19 @@ 按钮上的文本,仅当 type 为 `text` 时有效 - + [FeedbackButton.destroy()](https://developers.weixin.qq.com/minigame/dev/api/open-api/feedback/FeedbackButton.destroy.html) 销毁意见反馈按钮 - + [FeedbackButton.hide()](https://developers.weixin.qq.com/minigame/dev/api/open-api/feedback/FeedbackButton.hide.html) 隐藏意见反馈按钮。 - + [FeedbackButton.offTap(function listener)](https://developers.weixin.qq.com/minigame/dev/api/open-api/feedback/FeedbackButton.offTap.html) 移除意见反馈按钮的点击事件的监听函数 @@ -428,13 +428,13 @@ ``` - + [FeedbackButton.onTap(function listener)](https://developers.weixin.qq.com/minigame/dev/api/open-api/feedback/FeedbackButton.onTap.html) 监听意见反馈按钮的点击事件 - + [FeedbackButton.show()](https://developers.weixin.qq.com/minigame/dev/api/open-api/feedback/FeedbackButton.show.html) 显示意见反馈按钮 @@ -1378,25 +1378,25 @@ 运行JS函数 - + [LogManager.debug()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/LogManager.debug.html) 写 debug 日志 - + [LogManager.info()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/LogManager.info.html) 写 info 日志 - + [LogManager.log()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/LogManager.log.html) 写 log 日志 - + [LogManager.warn()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/LogManager.warn.html) 写 warn 日志 @@ -3092,17 +3092,17 @@ 可参考[calc_signature](https://docs.qq.com/doc/DVUN0QWJja0J5c2x4) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -3155,7 +3155,7 @@ - 允许微信使用蓝牙的开关(仅 iOS 有效) + 允许微信使用蓝牙的开关(安卓基础库 3.5.0 以上有效) @@ -3751,7 +3751,7 @@ 下载资源的 url - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -3773,7 +3773,7 @@ 是否开启 Quic 协议(gQUIC Q43) - + 接口调用失败的回调函数 @@ -3789,7 +3789,7 @@ HTTP 请求的 Header,Header 中不能设置 Referer - + 接口调用成功的回调函数 @@ -4137,12 +4137,12 @@ 文本的内容 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -4168,7 +4168,7 @@ - 'bold': 粗体; - + 接口调用成功的回调函数 @@ -4178,17 +4178,17 @@ 需要添加的卡券列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4229,17 +4229,17 @@ shareTicket。可以从 wx.getEnterOptionsSync 中获取。详情 [shareTicket](#) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4269,32 +4269,32 @@ 需要获取权限的 scope,详见 [scope 列表](https://developers.weixin.qq.com/minigame/dev/guide/base-ability/authorize.html#scope-列表) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4304,22 +4304,22 @@ 是否被添加至 「我的小程序」 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -4329,7 +4329,7 @@ 最多可以选择的图片张数 - + 接口调用失败的回调函数 @@ -4350,7 +4350,7 @@ - 'camera': 使用相机; - + 接口调用成功的回调函数 @@ -4384,7 +4384,7 @@ - 'front': 使用前置摄像头; - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -4394,7 +4394,7 @@ 最多可以选择的文件个数,基础库2.25.0前,最多可支持9个文件,2.25.0及以后最多可支持20个文件 - + 接口调用失败的回调函数 @@ -4426,7 +4426,7 @@ - 'camera': 使用相机拍摄; - + 接口调用成功的回调函数 @@ -4484,7 +4484,7 @@ 最多可以选择的文件个数,可以 0~100 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -4495,12 +4495,12 @@ 根据文件拓展名过滤,仅 type==file 时有效。每一项都不能是空字符串。默认不过滤。 - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4554,17 +4554,17 @@ 蓝牙设备 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4611,17 +4611,17 @@ | 10013 | invalid_data | 连接 deviceId 为空或者是格式不正确 | - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4631,7 +4631,7 @@ 图片路径,图片的路径,支持本地路径、代码包路径 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -4648,7 +4648,7 @@ 压缩后图片的宽度,单位为px,若不填写则默认以compressedHeight为准等比缩放。 - + 接口调用失败的回调函数 @@ -4658,7 +4658,7 @@ 压缩质量,范围0~100,数值越小,质量越低,压缩率越高(仅对jpg有效)。 - + 接口调用成功的回调函数 @@ -4673,17 +4673,17 @@ 蓝牙设备 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4693,17 +4693,17 @@ 超时时间,单位 ms,不填表示不会超时 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4840,17 +4840,17 @@ 描述service的Object - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5010,17 +5010,17 @@ service 的 UUID - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5030,12 +5030,12 @@ 广播自定义参数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -5049,7 +5049,7 @@ - 'high': 功率高; - + 接口调用成功的回调函数 @@ -5110,17 +5110,17 @@ 制造商信息 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5150,47 +5150,47 @@ 可选,处理回包时使用 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5210,7 +5210,7 @@ 图像宽度 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -5235,12 +5235,12 @@ 是否返回当前图像的人脸(106 个点) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5320,17 +5320,17 @@ 右眼可信度 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5358,17 +5358,17 @@ 蓝牙服务 UUID。需要先调用 [wx.getBLEDeviceServices](https://developers.weixin.qq.com/minigame/dev/api/device/bluetooth-ble/wx.getBLEDeviceServices.html) 获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5423,17 +5423,17 @@ 蓝牙设备 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5448,17 +5448,17 @@ 蓝牙设备 id。需要已经通过 [wx.createBLEConnection](https://developers.weixin.qq.com/minigame/dev/api/device/bluetooth-ble/wx.createBLEConnection.html) 建立连接 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5483,17 +5483,17 @@ 蓝牙设备 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5516,17 +5516,17 @@ 缓存数据类别,取值为 periodic 或 pre - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5556,17 +5556,17 @@ 客户端拿到缓存数据的时间戳 ms。(iOS 时间戳存在异常,8.0.27 修复) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5581,17 +5581,17 @@ 自定义的登录态 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5612,17 +5612,17 @@ 设备电量,范围 1 - 100 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5697,17 +5697,17 @@ Beacon 设备广播的 UUID - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5722,17 +5722,17 @@ 是否正在搜索设备 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5787,7 +5787,7 @@ 视频号 id,以“sph”开头的id,可在视频号助手获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -5798,7 +5798,7 @@ 结束时间,筛选指定时间段的直播。若上传了startTime,未上传endTime,则endTime默认取当前时间 - + 接口调用失败的回调函数 @@ -5809,7 +5809,7 @@ 起始时间,筛选指定时间段的直播。若上传了endTime,未上传startTime,则startTime默认为0 - + 接口调用成功的回调函数 @@ -5860,8 +5860,10 @@ 直播状态 可选值: + - 1: 直播状态不存在(针对未开过直播的主播); - 2: 直播中; - - 3: 直播结束; + - 3: 直播已结束; + - 4: 直播准备中(未开播); @@ -5869,17 +5871,17 @@ 视频号 id,以“sph”开头的id,可在视频号助手获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5920,17 +5922,17 @@ 预告状态:0可用 1取消 2已用 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5945,17 +5947,17 @@ 蓝牙设备主服务的 UUID 列表(支持 16/32/128 位 UUID) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5975,34 +5977,34 @@ 蓝牙设备名称,某些设备可能没有 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6012,17 +6014,17 @@ 第三方平台自定义的数据 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6050,17 +6052,17 @@ 需要获取的数据指标的对象数组 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6095,17 +6097,17 @@ 使用 sha1( rawData + sessionkey ) 得到字符串,用于校验用户信息 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6149,17 +6151,17 @@ 加密算法的初始向量,详细见[加密数据解密算法](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/signature.html) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6169,17 +6171,17 @@ AI推理引擎版本 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6199,17 +6201,17 @@ 本机局域网子网掩码,基础库 2.24.0 开始支持 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6238,24 +6240,55 @@ 信号强弱,单位 dbm - + + + 需要基础库: `3.5.3` + 是否处于弱网环境 + + + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + + + 手机号实时验证,向用户申请,并在用户同意后,快速填写和实时验证手机号 [具体说明](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/getRealtimePhoneNumber.html)。 + + + + + 当手机号快速验证或手机号实时验证额度用尽时,是否对用户展示“申请获取你的手机号,但该功能使用次数已达当前小程序上限,暂时无法使用”的提示,默认展示。 + + + + + 接口调用成功的回调函数 + + + + + 接口调用结束的回调函数(调用成功、失败都会执行) + + + + + 接口调用失败的回调函数 + + + 接口调用成功的回调函数 - 是否需要用户授权隐私协议(如果开发者没有在[mp后台-设置-服务内容声明-用户隐私保护指引]中声明隐私收集类型则会返回false;如果开发者声明了隐私收集,且用户之前同意过隐私协议则会返回false;如果开发者声明了隐私收集,且用户还没同意过则返回true;如果用户之前同意过、但后来小程序又新增了隐私收集类型也会返回true) + 是否需要用户授权隐私协议(如果开发者没有在「MP后台-设置-服务内容声明-用户隐私保护指引」中声明隐私收集类型则会返回false;如果开发者声明了隐私收集,且用户之前同意过隐私协议则会返回false;如果开发者声明了隐私收集,且用户还没同意过则返回true;如果用户之前同意过、但后来小程序又新增了隐私收集类型也会返回true) @@ -6263,17 +6296,17 @@ 隐私授权协议的名称 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6283,17 +6316,17 @@ 屏幕亮度值,范围 0 ~ 1,0 最暗,1 最亮 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6306,17 +6339,17 @@ - 'off': 关闭; - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6363,17 +6396,17 @@ shareTicket,详见[获取更多转发信息](#) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6384,17 +6417,17 @@ 超时时间,单位 ms - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6414,42 +6447,42 @@ 限制的空间大小,单位 KB - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -6463,7 +6496,7 @@ - 'zh_TW': 繁体中文; - + 接口调用成功的回调函数 @@ -6553,17 +6586,17 @@ 要获取的 key 列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6595,17 +6628,17 @@ 加密算法的初始向量,详见 [用户数据的签名验证和加解密](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/signature.html#加密数据解密算法) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6626,27 +6659,27 @@ 加密算法的初始向量,详细见[加密数据解密算法](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/signature.html) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -6657,17 +6690,17 @@ 目前 toast 和 loading 相关接口可以相互混用,此参数可用于取消混用特性 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -6678,17 +6711,17 @@ 本接口为 Beta 版本,暂只在 Android 平台支持。需要隐藏的转发按钮名称列表,默认['shareAppMessage', 'shareTimeline']。按钮名称合法值包含 "shareAppMessage"、"shareTimeline" 两种 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -6699,22 +6732,22 @@ 目前 toast 和 loading 相关接口可以相互混用,此参数可用于取消混用特性 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6724,17 +6757,17 @@ 蓝牙设备 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6759,12 +6792,12 @@ 验证所需的时间戳 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -6788,7 +6821,7 @@ - 'video': 视频房间,结合 [voip-room](#) 组件可显示成员画面; - + 接口调用成功的回调函数 @@ -6840,17 +6873,17 @@ 在此通话中的成员 openId 名单 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6887,17 +6920,17 @@ pin 码,Base64 格式。 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6907,12 +6940,32 @@ 超时时间,单位 ms + + + 接口调用结束的回调函数(调用成功、失败都会执行) + + + + + 需要返回给上一个小程序的数据,上一个小程序可在 `App.onShow` 中获取到这份数据。 [详情](#)。 + + + + + 接口调用失败的回调函数 + + + + + 接口调用成功的回调函数 + + 要打开的小程序 appId - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -6931,7 +6984,7 @@ 需要传递给目标小程序的数据,目标小程序可在 `App.onLaunch`,`App.onShow` 中获取到这份数据。如果跳转的是小游戏,可以在 [wx.onShow](https://developers.weixin.qq.com/minigame/dev/api/base/app/life-cycle/wx.onShow.html)、[wx.getLaunchOptionsSync](https://developers.weixin.qq.com/minigame/dev/api/base/app/life-cycle/wx.getLaunchOptionsSync.html) 中可以获取到这份数据数据。 - + 接口调用失败的回调函数 @@ -6953,7 +7006,7 @@ 小程序链接,当传递该参数后,可以不传 appId 和 path。链接可以通过【小程序菜单】->【复制链接】获取。 - + 接口调用成功的回调函数 @@ -6978,17 +7031,17 @@ 是否启用 notify - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7519,27 +7572,27 @@ 变化后的窗口宽度,单位 px - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -7553,7 +7606,7 @@ - 'peripheral': 从机(外围设备)模式; - + 接口调用成功的回调函数 @@ -7563,17 +7616,17 @@ 需要打开的卡券列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7594,17 +7647,17 @@ 视频号 id,以“sph”开头的id,可在视频号助手获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7619,17 +7672,17 @@ 视频号 id,以“sph”开头的id,可在视频号助手获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7639,12 +7692,12 @@ 视频号 id,以“sph”开头的id,可在视频号助手获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -7659,7 +7712,7 @@ 直播 nonceId,通过 getChannelsLiveInfo 接口获取(基础库 v2.19.2 之前的版本需要填写) - + 接口调用成功的回调函数 @@ -7669,17 +7722,17 @@ 视频号 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7694,12 +7747,12 @@ 客服信息 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -7724,7 +7777,7 @@ 是否发送小程序气泡消息 - + 接口调用成功的回调函数 @@ -7734,12 +7787,12 @@ 客服链接 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -7769,7 +7822,7 @@ 是否显示会话内消息卡片,设置此参数为 true,用户进入客服会话会在右下角显示"可能要发送的小程序"提示,用户点击后可以快速发送小程序消息 - + 接口调用成功的回调函数 @@ -7784,32 +7837,32 @@ 在客服会话内点击小程序消息卡片进入小程序时,所带的小程序打开参数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7833,17 +7886,17 @@ 用户订阅消息设置,接口参数`withSubscriptions`值为`true`时才会返回。 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7898,7 +7951,7 @@ 需要预览的图片链接列表。[2.2.3](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) 起支持云文件ID。 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -7908,7 +7961,7 @@ 当前显示图片的链接 - + 接口调用失败的回调函数 @@ -7925,7 +7978,7 @@ 是否显示长按菜单。 - + 接口调用成功的回调函数 @@ -7935,7 +7988,7 @@ 需要预览的资源列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -7945,7 +7998,7 @@ 当前显示的资源序号 - + 接口调用失败的回调函数 @@ -7962,7 +8015,7 @@ 是否显示长按菜单。 - + 接口调用成功的回调函数 @@ -8000,17 +8053,17 @@ 蓝牙特征对应服务的 UUID - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8020,17 +8073,17 @@ 本地缓存中指定的 key - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8040,17 +8093,17 @@ 要删除掉 key 列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8060,7 +8113,7 @@ 场景ID,在「小程序管理后台」获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -8075,7 +8128,7 @@ 自定义维度数据,key在「小程序管理后台」获取。只支持能够通过JSON.stringify序列化的对象,且序列化后长度不超过1024个字符 - + 接口调用失败的回调函数 @@ -8085,7 +8138,7 @@ 自定义指标数据,key在「小程序管理后台」获取。只支持能够通过JSON.stringify序列化的对象,且序列化后长度不超过1024个字符 - + 接口调用成功的回调函数 @@ -8215,17 +8268,17 @@ 分区 ID - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8309,7 +8362,7 @@ 购买数量。mode=game 时必填。购买数量。详见 [buyQuantity 限制说明](#buyquantity-限制说明)。 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -8322,7 +8375,7 @@ - 1: 米大师沙箱环境; - + 接口调用失败的回调函数 @@ -8334,7 +8387,7 @@ - 'android': android; - + 接口调用成功的回调函数 @@ -8362,7 +8415,11 @@ | -15009 | | 虚拟支付接口错误码,由于健康系统限制,本次支付已超过限额(这种错误情况会有默认弹窗提示) | | -15010 | | 虚拟支付接口错误码,正式版小游戏不允许在沙箱环境支付 | | -15011 | | 请求的数据类型错误 | + | -15012 | | SIGNATURE错误 | | -15013 | | 代币未发布 | + | -15014 | | paysig错误 | + | -15015 | | sessionkey过期 | + | -15016 | | 道具价格错误 | | -15017 | | 订单已关闭 | | 1 | | 虚拟支付接口错误码,用户取消支付 | | 2 | | 虚拟支付接口错误码,客户端错误,判断到小程序在用户处于支付中时,又发起了一笔支付请求 | @@ -8396,7 +8453,11 @@ | -15009 | | 虚拟支付接口错误码,由于健康系统限制,本次支付已超过限额(这种错误情况会有默认弹窗提示) | | -15010 | | 虚拟支付接口错误码,正式版小游戏不允许在沙箱环境支付 | | -15011 | | 请求的数据类型错误 | + | -15012 | | SIGNATURE错误 | | -15013 | | 代币未发布 | + | -15014 | | paysig错误 | + | -15015 | | sessionkey过期 | + | -15016 | | 道具价格错误 | | -15017 | | 订单已关闭 | | 1 | | 虚拟支付接口错误码,用户取消支付 | | 2 | | 虚拟支付接口错误码,客户端错误,判断到小程序在用户处于支付中时,又发起了一笔支付请求 | @@ -8437,17 +8498,17 @@ 需要订阅的消息模板的id的集合,一次调用最多可订阅3条消息(注意:iOS客户端7.0.6版本、Android客户端7.0.7版本之后的一次性订阅/长期订阅才支持多个模板消息,iOS客户端7.0.5版本、Android客户端7.0.6版本之前的一次订阅只支持一个模板消息)消息模板id在[微信公众平台(mp.weixin.qq.com)-功能-订阅消息]中配置。每个tmplId对应的模板标题需要不相同,否则会被过滤。 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8475,17 +8536,17 @@ 系统订阅消息类型列表,一次调用最多可订阅3种类型的消息,目前支持两种类型,"SYS_MSG_TYPE_INTERACTIVE"(好友互动提醒)、"SYS_MSG_TYPE_RANK"(排行榜超越提醒) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8498,17 +8559,17 @@ 接口调用成功时errMsg值为'requestSubscribeSystemMessage:ok' - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8518,12 +8579,12 @@ 预告 id,通过 getChannelsLiveNoticeInfo 接口获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -8533,7 +8594,7 @@ 打开的页面路径,path 中 ? 后面的部分会成为 query - + 接口调用成功的回调函数 @@ -8543,17 +8604,17 @@ 待保存文件路径 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8563,27 +8624,27 @@ 图片文件路径,可以是临时文件路径或永久文件路径 (本地路径) ,不支持网络路径 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -8605,7 +8666,7 @@ - 'pdf417': PDF417 条码; - + 接口调用成功的回调函数 @@ -8665,17 +8726,17 @@ 最大传输单元。设置范围为 (22,512) 区间内,单位 bytes - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8695,17 +8756,17 @@ 自定义的登录态 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8715,17 +8776,17 @@ 剪贴板的内容 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8738,17 +8799,17 @@ - 'portrait': 竖屏; - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8758,27 +8819,27 @@ 是否打开调试 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -8798,7 +8859,7 @@ true 代表用扬声器播放,false 代表听筒播放,默认值为 true。 - + 接口调用成功的回调函数 @@ -8808,17 +8869,17 @@ 是否保持屏幕常亮 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8831,17 +8892,17 @@ - 'dark': 深色; - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8851,17 +8912,17 @@ 屏幕亮度值,范围 0 ~ 1,0 最暗,1 最亮。在安卓端支持传入特殊值 -1,表示屏幕亮度跟随系统变化 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8874,17 +8935,17 @@ - 'black': 浅色; - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8894,17 +8955,17 @@ 要修改的 KV 数据列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8919,17 +8980,17 @@ 数据的 value - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8979,12 +9040,12 @@ 警示文案 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -8994,7 +9055,7 @@ 按钮的文字颜色 - + 接口调用成功的回调函数 @@ -9035,17 +9096,17 @@ 是否为多行输入 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9055,12 +9116,12 @@ 提示的内容 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9070,7 +9131,7 @@ 是否显示透明蒙层,防止触摸穿透 - + 接口调用成功的回调函数 @@ -9085,7 +9146,7 @@ 取消按钮的文字,最多 4 个字符 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -9111,7 +9172,7 @@ 是否显示输入框 - + 接口调用失败的回调函数 @@ -9127,7 +9188,7 @@ 是否显示取消按钮 - + 接口调用成功的回调函数 @@ -9158,7 +9219,7 @@ 要分享的图片地址,必须为本地路径或临时路径 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -9169,7 +9230,7 @@ 从消息小程序入口打开小程序的路径,如果当前页面允许分享给朋友,则默认为当前页面路径,否则默认为小程序首页 - + 接口调用失败的回调函数 @@ -9183,20 +9244,20 @@ 需要基础库: `3.2.0` - 分享样式,可选 v2 + 分享样式,小程序可选 v2 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9207,7 +9268,7 @@ 本接口为 Beta 版本,暂只在 Android 平台支持。需要显示的转发按钮名称列表,默认['shareAppMessage']。按钮名称合法值包含 "shareAppMessage"、"shareTimeline" 两种 - + 接口调用成功的回调函数 @@ -9222,7 +9283,7 @@ 提示的内容 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -9232,7 +9293,7 @@ 提示的延迟时间 - + 接口调用失败的回调函数 @@ -9258,17 +9319,17 @@ 是否显示透明蒙层,防止触摸穿透 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9283,7 +9344,7 @@ - 'normal': 普通的回调频率,在 200ms/次 左右; - + 接口调用成功的回调函数 @@ -9293,12 +9354,12 @@ Beacon 设备广播的 UUID 列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9308,7 +9369,7 @@ 是否校验蓝牙开关,仅在 iOS 下有效。iOS 11 起,控制面板里关掉蓝牙,还是能继续使用 Beacon 服务。 - + 接口调用成功的回调函数 @@ -9318,12 +9379,12 @@ 是否允许重复上报同一设备。如果允许重复上报,则 [wx.onBlueToothDeviceFound](#) 方法会多次上报同一设备,但是 RSSI 值会有不同。 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9347,32 +9408,32 @@ 要搜索的蓝牙设备主服务的 UUID 列表(支持 16/32/128 位 UUID)。某些蓝牙设备会广播自己的主 service 的 UUID。如果设置此参数,则只搜索广播包有对应 UUID 的主服务的蓝牙设备。建议通过该参数过滤掉周边不需要处理的其他蓝牙设备。 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9386,97 +9447,97 @@ - 'normal': 普通的回调频率,在 200ms/次 左右; - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9486,17 +9547,17 @@ 键盘输入框的当前值 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9507,12 +9568,12 @@ 动态消息的 activityId。通过 [updatableMessage.createActivityId](https://developers.weixin.qq.com/minigame/dev/api-backend/open-api/updatable-message/updatableMessage.createActivityId.html) 接口获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9529,7 +9590,7 @@ 是否是动态消息,详见[动态消息](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/share/updatable-message.html) - + 接口调用成功的回调函数 @@ -9576,47 +9637,47 @@ 静音设置 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9627,17 +9688,17 @@ 震动强度类型,有效值为:heavy、medium、light - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9669,17 +9730,17 @@ 蓝牙设备特征对应的二进制值 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9697,32 +9758,32 @@ 自定义query - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9757,17 +9818,17 @@ 是否正在直播 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9777,17 +9838,17 @@ 最近几场直播的 feedId 列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9822,17 +9883,17 @@ 要查询的直播的id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9842,17 +9903,17 @@ 支持填写最多4个openid,该用户的直播间将在直播专区置顶显示;可不填 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9862,32 +9923,32 @@ 用于打开指定游戏内容页面的开放链接 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9907,17 +9968,17 @@ 要打开的业务类型,目前仅支持 'servicecommentpage' - + 调用成功、失败都会执行 - + 评价失败的回调 - + 评价成功的回调 @@ -9953,35 +10014,35 @@ 要发送的消息 - + [RealtimeLogManager.addFilterMsg(string msg)](https://developers.weixin.qq.com/minigame/dev/api/base/debug/RealtimeLogManager.addFilterMsg.html) 需要基础库: `2.14.4` 添加过滤关键字,暂不支持在插件使用 - + [RealtimeLogManager.error()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/RealtimeLogManager.error.html) 需要基础库: `2.14.4` 写 error 日志,暂不支持在插件使用 - + [RealtimeLogManager.info()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/RealtimeLogManager.info.html) 需要基础库: `2.14.4` 写 info 日志,暂不支持在插件使用 - + [RealtimeLogManager.setFilterMsg(string msg)](https://developers.weixin.qq.com/minigame/dev/api/base/debug/RealtimeLogManager.setFilterMsg.html) 需要基础库: `2.14.4` 设置过滤关键字,暂不支持在插件使用 - + [RealtimeLogManager.warn()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/RealtimeLogManager.warn.html) 需要基础库: `2.14.4` @@ -10352,7 +10413,7 @@ 绑定一个系统随机分配的可用端口,或绑定一个指定的端口号 - + [UpdateManager.applyUpdate()](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.applyUpdate.html) 强制小程序重启并使用新版本。在小程序新版本下载完成后(即收到 `onUpdateReady` 回调)调用。 @@ -10360,7 +10421,7 @@ [示例代码](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.html#示例代码) - + [UpdateManager.onCheckForUpdate(function listener)](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.onCheckForUpdate.html) 监听向微信后台请求检查更新结果事件。微信在小程序每次启动(包括热启动)时自动检查更新,不需由开发者主动触发。 @@ -10368,7 +10429,7 @@ [示例代码](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.html#示例代码) - + [UpdateManager.onUpdateFailed(function listener)](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.onUpdateFailed.html) 监听小程序更新失败事件。小程序有新版本,客户端主动触发下载(无需开发者触发),下载失败(可能是网络原因等)后回调 @@ -10376,7 +10437,7 @@ [示例代码](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.html#示例代码) - + [UpdateManager.onUpdateReady(function listener)](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.onUpdateReady.html) 监听小程序有版本更新事件。客户端主动触发下载(无需开发者触发),下载成功后回调 @@ -10636,49 +10697,49 @@ 取消监听视频下载(缓冲)事件 ,action 为空表示移除全部事件监听 - + [Object VideoDecoder.getFrameData()](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.getFrameData.html) 需要基础库: `2.11.1` 获取下一帧的解码数据 - + [Promise VideoDecoder.remove()](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.remove.html) 需要基础库: `2.11.1` 移除解码器 - + [Promise VideoDecoder.seek(number position)](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.seek.html) 需要基础库: `2.11.1` 跳到某个时间点解码 - + [Promise VideoDecoder.start(Object object)](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.start.html) 需要基础库: `2.11.1` 开始解码 - + [Promise VideoDecoder.stop()](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.stop.html) 需要基础库: `2.11.1` 停止解码 - + [VideoDecoder.off(string eventName, function callback)](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.off.html) 需要基础库: `2.11.1` 取消监听录制事件。当对应事件触发时,该回调函数不再执行 - + [VideoDecoder.on(string eventName, function callback)](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.on.html) 需要基础库: `2.11.1` diff --git a/Runtime/Plugins/wx-runtime-editor.xml.meta b/Runtime/Plugins/wx-runtime-editor.xml.meta index d9a1ca0f..0161bd24 100644 --- a/Runtime/Plugins/wx-runtime-editor.xml.meta +++ b/Runtime/Plugins/wx-runtime-editor.xml.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 4958853e03990c68eff5a74fdaf5c631 +guid: 01bdbebd66ee5a739cc6b349dba4cd99 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/Plugins/wx-runtime.dll b/Runtime/Plugins/wx-runtime.dll index d910665b..90864a56 100644 Binary files a/Runtime/Plugins/wx-runtime.dll and b/Runtime/Plugins/wx-runtime.dll differ diff --git a/Runtime/Plugins/wx-runtime.xml b/Runtime/Plugins/wx-runtime.xml index 8a2d9a83..11061707 100644 --- a/Runtime/Plugins/wx-runtime.xml +++ b/Runtime/Plugins/wx-runtime.xml @@ -335,14 +335,14 @@ 成功回调 失败回调 - + [DownloadTask.abort()](https://developers.weixin.qq.com/minigame/dev/api/network/download/DownloadTask.abort.html) 需要基础库: `1.4.0` 中断下载任务 - + [DownloadTask.offHeadersReceived(function listener)](https://developers.weixin.qq.com/minigame/dev/api/network/download/DownloadTask.offHeadersReceived.html) 需要基础库: `2.1.0` @@ -355,7 +355,7 @@ ``` - + [DownloadTask.offProgressUpdate(function listener)](https://developers.weixin.qq.com/minigame/dev/api/network/download/DownloadTask.offProgressUpdate.html) 需要基础库: `2.1.0` @@ -368,14 +368,14 @@ ``` - + [DownloadTask.onHeadersReceived(function listener)](https://developers.weixin.qq.com/minigame/dev/api/network/download/DownloadTask.onHeadersReceived.html) 需要基础库: `2.1.0` 监听 HTTP Response Header 事件。会比请求完成事件更早 - + [DownloadTask.onProgressUpdate(function listener)](https://developers.weixin.qq.com/minigame/dev/api/network/download/DownloadTask.onProgressUpdate.html) 需要基础库: `1.4.0` @@ -410,19 +410,19 @@ 按钮上的文本,仅当 type 为 `text` 时有效 - + [FeedbackButton.destroy()](https://developers.weixin.qq.com/minigame/dev/api/open-api/feedback/FeedbackButton.destroy.html) 销毁意见反馈按钮 - + [FeedbackButton.hide()](https://developers.weixin.qq.com/minigame/dev/api/open-api/feedback/FeedbackButton.hide.html) 隐藏意见反馈按钮。 - + [FeedbackButton.offTap(function listener)](https://developers.weixin.qq.com/minigame/dev/api/open-api/feedback/FeedbackButton.offTap.html) 移除意见反馈按钮的点击事件的监听函数 @@ -434,13 +434,13 @@ ``` - + [FeedbackButton.onTap(function listener)](https://developers.weixin.qq.com/minigame/dev/api/open-api/feedback/FeedbackButton.onTap.html) 监听意见反馈按钮的点击事件 - + [FeedbackButton.show()](https://developers.weixin.qq.com/minigame/dev/api/open-api/feedback/FeedbackButton.show.html) 显示意见反馈按钮 @@ -1384,25 +1384,25 @@ 运行JS函数 - + [LogManager.debug()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/LogManager.debug.html) 写 debug 日志 - + [LogManager.info()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/LogManager.info.html) 写 info 日志 - + [LogManager.log()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/LogManager.log.html) 写 log 日志 - + [LogManager.warn()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/LogManager.warn.html) 写 warn 日志 @@ -3098,17 +3098,17 @@ 可参考[calc_signature](https://docs.qq.com/doc/DVUN0QWJja0J5c2x4) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -3161,7 +3161,7 @@ - 允许微信使用蓝牙的开关(仅 iOS 有效) + 允许微信使用蓝牙的开关(安卓基础库 3.5.0 以上有效) @@ -3757,7 +3757,7 @@ 下载资源的 url - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -3779,7 +3779,7 @@ 是否开启 Quic 协议(gQUIC Q43) - + 接口调用失败的回调函数 @@ -3795,7 +3795,7 @@ HTTP 请求的 Header,Header 中不能设置 Referer - + 接口调用成功的回调函数 @@ -4143,12 +4143,12 @@ 文本的内容 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -4174,7 +4174,7 @@ - 'bold': 粗体; - + 接口调用成功的回调函数 @@ -4184,17 +4184,17 @@ 需要添加的卡券列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4235,17 +4235,17 @@ shareTicket。可以从 wx.getEnterOptionsSync 中获取。详情 [shareTicket](#) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4275,32 +4275,32 @@ 需要获取权限的 scope,详见 [scope 列表](https://developers.weixin.qq.com/minigame/dev/guide/base-ability/authorize.html#scope-列表) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4310,22 +4310,22 @@ 是否被添加至 「我的小程序」 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -4335,7 +4335,7 @@ 最多可以选择的图片张数 - + 接口调用失败的回调函数 @@ -4356,7 +4356,7 @@ - 'camera': 使用相机; - + 接口调用成功的回调函数 @@ -4390,7 +4390,7 @@ - 'front': 使用前置摄像头; - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -4400,7 +4400,7 @@ 最多可以选择的文件个数,基础库2.25.0前,最多可支持9个文件,2.25.0及以后最多可支持20个文件 - + 接口调用失败的回调函数 @@ -4432,7 +4432,7 @@ - 'camera': 使用相机拍摄; - + 接口调用成功的回调函数 @@ -4490,7 +4490,7 @@ 最多可以选择的文件个数,可以 0~100 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -4501,12 +4501,12 @@ 根据文件拓展名过滤,仅 type==file 时有效。每一项都不能是空字符串。默认不过滤。 - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4560,17 +4560,17 @@ 蓝牙设备 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4617,17 +4617,17 @@ | 10013 | invalid_data | 连接 deviceId 为空或者是格式不正确 | - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4637,7 +4637,7 @@ 图片路径,图片的路径,支持本地路径、代码包路径 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -4654,7 +4654,7 @@ 压缩后图片的宽度,单位为px,若不填写则默认以compressedHeight为准等比缩放。 - + 接口调用失败的回调函数 @@ -4664,7 +4664,7 @@ 压缩质量,范围0~100,数值越小,质量越低,压缩率越高(仅对jpg有效)。 - + 接口调用成功的回调函数 @@ -4679,17 +4679,17 @@ 蓝牙设备 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4699,17 +4699,17 @@ 超时时间,单位 ms,不填表示不会超时 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -4846,17 +4846,17 @@ 描述service的Object - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5016,17 +5016,17 @@ service 的 UUID - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5036,12 +5036,12 @@ 广播自定义参数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -5055,7 +5055,7 @@ - 'high': 功率高; - + 接口调用成功的回调函数 @@ -5116,17 +5116,17 @@ 制造商信息 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5156,47 +5156,47 @@ 可选,处理回包时使用 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5216,7 +5216,7 @@ 图像宽度 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -5241,12 +5241,12 @@ 是否返回当前图像的人脸(106 个点) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5326,17 +5326,17 @@ 右眼可信度 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5364,17 +5364,17 @@ 蓝牙服务 UUID。需要先调用 [wx.getBLEDeviceServices](https://developers.weixin.qq.com/minigame/dev/api/device/bluetooth-ble/wx.getBLEDeviceServices.html) 获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5429,17 +5429,17 @@ 蓝牙设备 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5454,17 +5454,17 @@ 蓝牙设备 id。需要已经通过 [wx.createBLEConnection](https://developers.weixin.qq.com/minigame/dev/api/device/bluetooth-ble/wx.createBLEConnection.html) 建立连接 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5489,17 +5489,17 @@ 蓝牙设备 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5522,17 +5522,17 @@ 缓存数据类别,取值为 periodic 或 pre - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5562,17 +5562,17 @@ 客户端拿到缓存数据的时间戳 ms。(iOS 时间戳存在异常,8.0.27 修复) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5587,17 +5587,17 @@ 自定义的登录态 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5618,17 +5618,17 @@ 设备电量,范围 1 - 100 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5703,17 +5703,17 @@ Beacon 设备广播的 UUID - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5728,17 +5728,17 @@ 是否正在搜索设备 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5793,7 +5793,7 @@ 视频号 id,以“sph”开头的id,可在视频号助手获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -5804,7 +5804,7 @@ 结束时间,筛选指定时间段的直播。若上传了startTime,未上传endTime,则endTime默认取当前时间 - + 接口调用失败的回调函数 @@ -5815,7 +5815,7 @@ 起始时间,筛选指定时间段的直播。若上传了endTime,未上传startTime,则startTime默认为0 - + 接口调用成功的回调函数 @@ -5866,8 +5866,10 @@ 直播状态 可选值: + - 1: 直播状态不存在(针对未开过直播的主播); - 2: 直播中; - - 3: 直播结束; + - 3: 直播已结束; + - 4: 直播准备中(未开播); @@ -5875,17 +5877,17 @@ 视频号 id,以“sph”开头的id,可在视频号助手获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5926,17 +5928,17 @@ 预告状态:0可用 1取消 2已用 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5951,17 +5953,17 @@ 蓝牙设备主服务的 UUID 列表(支持 16/32/128 位 UUID) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -5981,34 +5983,34 @@ 蓝牙设备名称,某些设备可能没有 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6018,17 +6020,17 @@ 第三方平台自定义的数据 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6056,17 +6058,17 @@ 需要获取的数据指标的对象数组 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6101,17 +6103,17 @@ 使用 sha1( rawData + sessionkey ) 得到字符串,用于校验用户信息 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6155,17 +6157,17 @@ 加密算法的初始向量,详细见[加密数据解密算法](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/signature.html) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6175,17 +6177,17 @@ AI推理引擎版本 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6205,17 +6207,17 @@ 本机局域网子网掩码,基础库 2.24.0 开始支持 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6244,24 +6246,55 @@ 信号强弱,单位 dbm - + + + 需要基础库: `3.5.3` + 是否处于弱网环境 + + + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + + + 手机号实时验证,向用户申请,并在用户同意后,快速填写和实时验证手机号 [具体说明](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/getRealtimePhoneNumber.html)。 + + + + + 当手机号快速验证或手机号实时验证额度用尽时,是否对用户展示“申请获取你的手机号,但该功能使用次数已达当前小程序上限,暂时无法使用”的提示,默认展示。 + + + + + 接口调用成功的回调函数 + + + + + 接口调用结束的回调函数(调用成功、失败都会执行) + + + + + 接口调用失败的回调函数 + + + 接口调用成功的回调函数 - 是否需要用户授权隐私协议(如果开发者没有在[mp后台-设置-服务内容声明-用户隐私保护指引]中声明隐私收集类型则会返回false;如果开发者声明了隐私收集,且用户之前同意过隐私协议则会返回false;如果开发者声明了隐私收集,且用户还没同意过则返回true;如果用户之前同意过、但后来小程序又新增了隐私收集类型也会返回true) + 是否需要用户授权隐私协议(如果开发者没有在「MP后台-设置-服务内容声明-用户隐私保护指引」中声明隐私收集类型则会返回false;如果开发者声明了隐私收集,且用户之前同意过隐私协议则会返回false;如果开发者声明了隐私收集,且用户还没同意过则返回true;如果用户之前同意过、但后来小程序又新增了隐私收集类型也会返回true) @@ -6269,17 +6302,17 @@ 隐私授权协议的名称 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6289,17 +6322,17 @@ 屏幕亮度值,范围 0 ~ 1,0 最暗,1 最亮 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6312,17 +6345,17 @@ - 'off': 关闭; - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6369,17 +6402,17 @@ shareTicket,详见[获取更多转发信息](#) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6390,17 +6423,17 @@ 超时时间,单位 ms - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6420,42 +6453,42 @@ 限制的空间大小,单位 KB - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -6469,7 +6502,7 @@ - 'zh_TW': 繁体中文; - + 接口调用成功的回调函数 @@ -6559,17 +6592,17 @@ 要获取的 key 列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6601,17 +6634,17 @@ 加密算法的初始向量,详见 [用户数据的签名验证和加解密](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/signature.html#加密数据解密算法) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6632,27 +6665,27 @@ 加密算法的初始向量,详细见[加密数据解密算法](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/signature.html) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -6663,17 +6696,17 @@ 目前 toast 和 loading 相关接口可以相互混用,此参数可用于取消混用特性 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -6684,17 +6717,17 @@ 本接口为 Beta 版本,暂只在 Android 平台支持。需要隐藏的转发按钮名称列表,默认['shareAppMessage', 'shareTimeline']。按钮名称合法值包含 "shareAppMessage"、"shareTimeline" 两种 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -6705,22 +6738,22 @@ 目前 toast 和 loading 相关接口可以相互混用,此参数可用于取消混用特性 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6730,17 +6763,17 @@ 蓝牙设备 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6765,12 +6798,12 @@ 验证所需的时间戳 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -6794,7 +6827,7 @@ - 'video': 视频房间,结合 [voip-room](#) 组件可显示成员画面; - + 接口调用成功的回调函数 @@ -6846,17 +6879,17 @@ 在此通话中的成员 openId 名单 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6893,17 +6926,17 @@ pin 码,Base64 格式。 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -6913,12 +6946,32 @@ 超时时间,单位 ms + + + 接口调用结束的回调函数(调用成功、失败都会执行) + + + + + 需要返回给上一个小程序的数据,上一个小程序可在 `App.onShow` 中获取到这份数据。 [详情](#)。 + + + + + 接口调用失败的回调函数 + + + + + 接口调用成功的回调函数 + + 要打开的小程序 appId - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -6937,7 +6990,7 @@ 需要传递给目标小程序的数据,目标小程序可在 `App.onLaunch`,`App.onShow` 中获取到这份数据。如果跳转的是小游戏,可以在 [wx.onShow](https://developers.weixin.qq.com/minigame/dev/api/base/app/life-cycle/wx.onShow.html)、[wx.getLaunchOptionsSync](https://developers.weixin.qq.com/minigame/dev/api/base/app/life-cycle/wx.getLaunchOptionsSync.html) 中可以获取到这份数据数据。 - + 接口调用失败的回调函数 @@ -6959,7 +7012,7 @@ 小程序链接,当传递该参数后,可以不传 appId 和 path。链接可以通过【小程序菜单】->【复制链接】获取。 - + 接口调用成功的回调函数 @@ -6984,17 +7037,17 @@ 是否启用 notify - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7525,27 +7578,27 @@ 变化后的窗口宽度,单位 px - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -7559,7 +7612,7 @@ - 'peripheral': 从机(外围设备)模式; - + 接口调用成功的回调函数 @@ -7569,17 +7622,17 @@ 需要打开的卡券列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7600,17 +7653,17 @@ 视频号 id,以“sph”开头的id,可在视频号助手获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7625,17 +7678,17 @@ 视频号 id,以“sph”开头的id,可在视频号助手获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7645,12 +7698,12 @@ 视频号 id,以“sph”开头的id,可在视频号助手获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -7665,7 +7718,7 @@ 直播 nonceId,通过 getChannelsLiveInfo 接口获取(基础库 v2.19.2 之前的版本需要填写) - + 接口调用成功的回调函数 @@ -7675,17 +7728,17 @@ 视频号 id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7700,12 +7753,12 @@ 客服信息 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -7730,7 +7783,7 @@ 是否发送小程序气泡消息 - + 接口调用成功的回调函数 @@ -7740,12 +7793,12 @@ 客服链接 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -7775,7 +7828,7 @@ 是否显示会话内消息卡片,设置此参数为 true,用户进入客服会话会在右下角显示"可能要发送的小程序"提示,用户点击后可以快速发送小程序消息 - + 接口调用成功的回调函数 @@ -7790,32 +7843,32 @@ 在客服会话内点击小程序消息卡片进入小程序时,所带的小程序打开参数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7839,17 +7892,17 @@ 用户订阅消息设置,接口参数`withSubscriptions`值为`true`时才会返回。 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -7904,7 +7957,7 @@ 需要预览的图片链接列表。[2.2.3](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) 起支持云文件ID。 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -7914,7 +7967,7 @@ 当前显示图片的链接 - + 接口调用失败的回调函数 @@ -7931,7 +7984,7 @@ 是否显示长按菜单。 - + 接口调用成功的回调函数 @@ -7941,7 +7994,7 @@ 需要预览的资源列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -7951,7 +8004,7 @@ 当前显示的资源序号 - + 接口调用失败的回调函数 @@ -7968,7 +8021,7 @@ 是否显示长按菜单。 - + 接口调用成功的回调函数 @@ -8006,17 +8059,17 @@ 蓝牙特征对应服务的 UUID - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8026,17 +8079,17 @@ 本地缓存中指定的 key - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8046,17 +8099,17 @@ 要删除掉 key 列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8066,7 +8119,7 @@ 场景ID,在「小程序管理后台」获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -8081,7 +8134,7 @@ 自定义维度数据,key在「小程序管理后台」获取。只支持能够通过JSON.stringify序列化的对象,且序列化后长度不超过1024个字符 - + 接口调用失败的回调函数 @@ -8091,7 +8144,7 @@ 自定义指标数据,key在「小程序管理后台」获取。只支持能够通过JSON.stringify序列化的对象,且序列化后长度不超过1024个字符 - + 接口调用成功的回调函数 @@ -8221,17 +8274,17 @@ 分区 ID - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8315,7 +8368,7 @@ 购买数量。mode=game 时必填。购买数量。详见 [buyQuantity 限制说明](#buyquantity-限制说明)。 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -8328,7 +8381,7 @@ - 1: 米大师沙箱环境; - + 接口调用失败的回调函数 @@ -8340,7 +8393,7 @@ - 'android': android; - + 接口调用成功的回调函数 @@ -8368,7 +8421,11 @@ | -15009 | | 虚拟支付接口错误码,由于健康系统限制,本次支付已超过限额(这种错误情况会有默认弹窗提示) | | -15010 | | 虚拟支付接口错误码,正式版小游戏不允许在沙箱环境支付 | | -15011 | | 请求的数据类型错误 | + | -15012 | | SIGNATURE错误 | | -15013 | | 代币未发布 | + | -15014 | | paysig错误 | + | -15015 | | sessionkey过期 | + | -15016 | | 道具价格错误 | | -15017 | | 订单已关闭 | | 1 | | 虚拟支付接口错误码,用户取消支付 | | 2 | | 虚拟支付接口错误码,客户端错误,判断到小程序在用户处于支付中时,又发起了一笔支付请求 | @@ -8402,7 +8459,11 @@ | -15009 | | 虚拟支付接口错误码,由于健康系统限制,本次支付已超过限额(这种错误情况会有默认弹窗提示) | | -15010 | | 虚拟支付接口错误码,正式版小游戏不允许在沙箱环境支付 | | -15011 | | 请求的数据类型错误 | + | -15012 | | SIGNATURE错误 | | -15013 | | 代币未发布 | + | -15014 | | paysig错误 | + | -15015 | | sessionkey过期 | + | -15016 | | 道具价格错误 | | -15017 | | 订单已关闭 | | 1 | | 虚拟支付接口错误码,用户取消支付 | | 2 | | 虚拟支付接口错误码,客户端错误,判断到小程序在用户处于支付中时,又发起了一笔支付请求 | @@ -8443,17 +8504,17 @@ 需要订阅的消息模板的id的集合,一次调用最多可订阅3条消息(注意:iOS客户端7.0.6版本、Android客户端7.0.7版本之后的一次性订阅/长期订阅才支持多个模板消息,iOS客户端7.0.5版本、Android客户端7.0.6版本之前的一次订阅只支持一个模板消息)消息模板id在[微信公众平台(mp.weixin.qq.com)-功能-订阅消息]中配置。每个tmplId对应的模板标题需要不相同,否则会被过滤。 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8481,17 +8542,17 @@ 系统订阅消息类型列表,一次调用最多可订阅3种类型的消息,目前支持两种类型,"SYS_MSG_TYPE_INTERACTIVE"(好友互动提醒)、"SYS_MSG_TYPE_RANK"(排行榜超越提醒) - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8504,17 +8565,17 @@ 接口调用成功时errMsg值为'requestSubscribeSystemMessage:ok' - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8524,12 +8585,12 @@ 预告 id,通过 getChannelsLiveNoticeInfo 接口获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -8539,7 +8600,7 @@ 打开的页面路径,path 中 ? 后面的部分会成为 query - + 接口调用成功的回调函数 @@ -8549,17 +8610,17 @@ 待保存文件路径 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8569,27 +8630,27 @@ 图片文件路径,可以是临时文件路径或永久文件路径 (本地路径) ,不支持网络路径 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -8611,7 +8672,7 @@ - 'pdf417': PDF417 条码; - + 接口调用成功的回调函数 @@ -8671,17 +8732,17 @@ 最大传输单元。设置范围为 (22,512) 区间内,单位 bytes - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8701,17 +8762,17 @@ 自定义的登录态 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8721,17 +8782,17 @@ 剪贴板的内容 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8744,17 +8805,17 @@ - 'portrait': 竖屏; - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8764,27 +8825,27 @@ 是否打开调试 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -8804,7 +8865,7 @@ true 代表用扬声器播放,false 代表听筒播放,默认值为 true。 - + 接口调用成功的回调函数 @@ -8814,17 +8875,17 @@ 是否保持屏幕常亮 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8837,17 +8898,17 @@ - 'dark': 深色; - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8857,17 +8918,17 @@ 屏幕亮度值,范围 0 ~ 1,0 最暗,1 最亮。在安卓端支持传入特殊值 -1,表示屏幕亮度跟随系统变化 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8880,17 +8941,17 @@ - 'black': 浅色; - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8900,17 +8961,17 @@ 要修改的 KV 数据列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8925,17 +8986,17 @@ 数据的 value - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -8985,12 +9046,12 @@ 警示文案 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9000,7 +9061,7 @@ 按钮的文字颜色 - + 接口调用成功的回调函数 @@ -9041,17 +9102,17 @@ 是否为多行输入 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9061,12 +9122,12 @@ 提示的内容 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9076,7 +9137,7 @@ 是否显示透明蒙层,防止触摸穿透 - + 接口调用成功的回调函数 @@ -9091,7 +9152,7 @@ 取消按钮的文字,最多 4 个字符 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -9117,7 +9178,7 @@ 是否显示输入框 - + 接口调用失败的回调函数 @@ -9133,7 +9194,7 @@ 是否显示取消按钮 - + 接口调用成功的回调函数 @@ -9164,7 +9225,7 @@ 要分享的图片地址,必须为本地路径或临时路径 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -9175,7 +9236,7 @@ 从消息小程序入口打开小程序的路径,如果当前页面允许分享给朋友,则默认为当前页面路径,否则默认为小程序首页 - + 接口调用失败的回调函数 @@ -9189,20 +9250,20 @@ 需要基础库: `3.2.0` - 分享样式,可选 v2 + 分享样式,小程序可选 v2 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9213,7 +9274,7 @@ 本接口为 Beta 版本,暂只在 Android 平台支持。需要显示的转发按钮名称列表,默认['shareAppMessage']。按钮名称合法值包含 "shareAppMessage"、"shareTimeline" 两种 - + 接口调用成功的回调函数 @@ -9228,7 +9289,7 @@ 提示的内容 - + 接口调用结束的回调函数(调用成功、失败都会执行) @@ -9238,7 +9299,7 @@ 提示的延迟时间 - + 接口调用失败的回调函数 @@ -9264,17 +9325,17 @@ 是否显示透明蒙层,防止触摸穿透 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9289,7 +9350,7 @@ - 'normal': 普通的回调频率,在 200ms/次 左右; - + 接口调用成功的回调函数 @@ -9299,12 +9360,12 @@ Beacon 设备广播的 UUID 列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9314,7 +9375,7 @@ 是否校验蓝牙开关,仅在 iOS 下有效。iOS 11 起,控制面板里关掉蓝牙,还是能继续使用 Beacon 服务。 - + 接口调用成功的回调函数 @@ -9324,12 +9385,12 @@ 是否允许重复上报同一设备。如果允许重复上报,则 [wx.onBlueToothDeviceFound](#) 方法会多次上报同一设备,但是 RSSI 值会有不同。 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9353,32 +9414,32 @@ 要搜索的蓝牙设备主服务的 UUID 列表(支持 16/32/128 位 UUID)。某些蓝牙设备会广播自己的主 service 的 UUID。如果设置此参数,则只搜索广播包有对应 UUID 的主服务的蓝牙设备。建议通过该参数过滤掉周边不需要处理的其他蓝牙设备。 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9392,97 +9453,97 @@ - 'normal': 普通的回调频率,在 200ms/次 左右; - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9492,17 +9553,17 @@ 键盘输入框的当前值 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9513,12 +9574,12 @@ 动态消息的 activityId。通过 [updatableMessage.createActivityId](https://developers.weixin.qq.com/minigame/dev/api-backend/open-api/updatable-message/updatableMessage.createActivityId.html) 接口获取 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 @@ -9535,7 +9596,7 @@ 是否是动态消息,详见[动态消息](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/share/updatable-message.html) - + 接口调用成功的回调函数 @@ -9582,47 +9643,47 @@ 静音设置 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9633,17 +9694,17 @@ 震动强度类型,有效值为:heavy、medium、light - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9675,17 +9736,17 @@ 蓝牙设备特征对应的二进制值 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9703,32 +9764,32 @@ 自定义query - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9763,17 +9824,17 @@ 是否正在直播 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9783,17 +9844,17 @@ 最近几场直播的 feedId 列表 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9828,17 +9889,17 @@ 要查询的直播的id - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9848,17 +9909,17 @@ 支持填写最多4个openid,该用户的直播间将在直播专区置顶显示;可不填 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9868,32 +9929,32 @@ 用于打开指定游戏内容页面的开放链接 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 - + 接口调用结束的回调函数(调用成功、失败都会执行) - + 接口调用失败的回调函数 - + 接口调用成功的回调函数 @@ -9913,17 +9974,17 @@ 要打开的业务类型,目前仅支持 'servicecommentpage' - + 调用成功、失败都会执行 - + 评价失败的回调 - + 评价成功的回调 @@ -9959,35 +10020,35 @@ 要发送的消息 - + [RealtimeLogManager.addFilterMsg(string msg)](https://developers.weixin.qq.com/minigame/dev/api/base/debug/RealtimeLogManager.addFilterMsg.html) 需要基础库: `2.14.4` 添加过滤关键字,暂不支持在插件使用 - + [RealtimeLogManager.error()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/RealtimeLogManager.error.html) 需要基础库: `2.14.4` 写 error 日志,暂不支持在插件使用 - + [RealtimeLogManager.info()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/RealtimeLogManager.info.html) 需要基础库: `2.14.4` 写 info 日志,暂不支持在插件使用 - + [RealtimeLogManager.setFilterMsg(string msg)](https://developers.weixin.qq.com/minigame/dev/api/base/debug/RealtimeLogManager.setFilterMsg.html) 需要基础库: `2.14.4` 设置过滤关键字,暂不支持在插件使用 - + [RealtimeLogManager.warn()](https://developers.weixin.qq.com/minigame/dev/api/base/debug/RealtimeLogManager.warn.html) 需要基础库: `2.14.4` @@ -10358,7 +10419,7 @@ 绑定一个系统随机分配的可用端口,或绑定一个指定的端口号 - + [UpdateManager.applyUpdate()](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.applyUpdate.html) 强制小程序重启并使用新版本。在小程序新版本下载完成后(即收到 `onUpdateReady` 回调)调用。 @@ -10366,7 +10427,7 @@ [示例代码](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.html#示例代码) - + [UpdateManager.onCheckForUpdate(function listener)](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.onCheckForUpdate.html) 监听向微信后台请求检查更新结果事件。微信在小程序每次启动(包括热启动)时自动检查更新,不需由开发者主动触发。 @@ -10374,7 +10435,7 @@ [示例代码](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.html#示例代码) - + [UpdateManager.onUpdateFailed(function listener)](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.onUpdateFailed.html) 监听小程序更新失败事件。小程序有新版本,客户端主动触发下载(无需开发者触发),下载失败(可能是网络原因等)后回调 @@ -10382,7 +10443,7 @@ [示例代码](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.html#示例代码) - + [UpdateManager.onUpdateReady(function listener)](https://developers.weixin.qq.com/minigame/dev/api/base/update/UpdateManager.onUpdateReady.html) 监听小程序有版本更新事件。客户端主动触发下载(无需开发者触发),下载成功后回调 @@ -10642,49 +10703,49 @@ 取消监听视频下载(缓冲)事件 ,action 为空表示移除全部事件监听 - + [Object VideoDecoder.getFrameData()](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.getFrameData.html) 需要基础库: `2.11.1` 获取下一帧的解码数据 - + [Promise VideoDecoder.remove()](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.remove.html) 需要基础库: `2.11.1` 移除解码器 - + [Promise VideoDecoder.seek(number position)](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.seek.html) 需要基础库: `2.11.1` 跳到某个时间点解码 - + [Promise VideoDecoder.start(Object object)](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.start.html) 需要基础库: `2.11.1` 开始解码 - + [Promise VideoDecoder.stop()](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.stop.html) 需要基础库: `2.11.1` 停止解码 - + [VideoDecoder.off(string eventName, function callback)](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.off.html) 需要基础库: `2.11.1` 取消监听录制事件。当对应事件触发时,该回调函数不再执行 - + [VideoDecoder.on(string eventName, function callback)](https://developers.weixin.qq.com/minigame/dev/api/media/video-decoder/VideoDecoder.on.html) 需要基础库: `2.11.1` diff --git a/Runtime/Plugins/wx-runtime.xml.meta b/Runtime/Plugins/wx-runtime.xml.meta index d9c2e40b..3c0c0556 100644 --- a/Runtime/Plugins/wx-runtime.xml.meta +++ b/Runtime/Plugins/wx-runtime.xml.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 05f03f853c30ba9a70aeea0e089ce713 +guid: b62580f0401d094a6394f069fac1303a DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/WX.cs b/Runtime/WX.cs index 046d53e3..cb2c765d 100644 --- a/Runtime/WX.cs +++ b/Runtime/WX.cs @@ -489,6 +489,11 @@ namespace WeChatWASM /// [wx.getChannelsLiveInfo(Object object)](https://developers.weixin.qq.com/minigame/dev/api/open-api/channels/wx.getChannelsLiveInfo.html) /// 需要基础库: `2.15.0` /// 获取视频号直播信息 + /// **常见错误码说明** + /// 100008 视频号需要认证 + /// 40097 入参异常 + /// 1416104 视频号获取到的数据为空 + /// 1416100 非法的视频号id /// public static void GetChannelsLiveInfo(GetChannelsLiveInfoOption callback) { @@ -719,6 +724,7 @@ namespace WeChatWASM /// wx.getNetworkType({ /// success (res) { /// const networkType = res.networkType + /// const weakNet = res.weakNet /// } /// }) /// ``` @@ -728,6 +734,18 @@ namespace WeChatWASM WXSDKManagerHandler.Instance.GetNetworkType(callback); } + /// + /// [wx.getPhoneNumber(Object object)](https://developers.weixin.qq.com/minigame/dev/api/open-api/user-info/wx.getPhoneNumber.html) + /// 手机号快速验证,向用户申请,并在用户同意后,快速填写和验证手机 [具体说明](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/getPhoneNumber.html) + /// **** + /// ## 注意事项 + /// - 用户点击后才可进行调用 + /// + public static void GetPhoneNumber(GetPhoneNumberOption callback) + { + WXSDKManagerHandler.Instance.GetPhoneNumber(callback); + } + /// /// [wx.getPrivacySetting(Object object)](https://developers.weixin.qq.com/minigame/dev/api/open-api/privacy/wx.getPrivacySetting.html) /// 需要基础库: `2.32.3` @@ -1143,6 +1161,28 @@ namespace WeChatWASM WXSDKManagerHandler.Instance.MakeBluetoothPair(callback); } + /// + /// [wx.navigateBackMiniProgram(Object object)](https://developers.weixin.qq.com/minigame/dev/api/navigate/wx.navigateBackMiniProgram.html) + /// 需要基础库: `3.5.6` + /// 返回到上一个小程序。只有在当前小程序是被其他小程序打开时可以调用成功。 + /// 注意:**微信客户端 iOS 6.5.9,Android 6.5.10 及以上版本支持** + /// **示例代码** + /// ```js + /// wx.navigateBackMiniProgram({ + /// extraData: { + /// foo: 'bar' + /// }, + /// success(res) { + /// // 返回成功 + /// } + /// }) + /// ``` + /// + public static void NavigateBackMiniProgram(NavigateBackMiniProgramOption callback) + { + WXSDKManagerHandler.Instance.NavigateBackMiniProgram(callback); + } + /// /// [wx.navigateToMiniProgram(Object object)](https://developers.weixin.qq.com/minigame/dev/api/navigate/wx.navigateToMiniProgram.html) /// 需要基础库: `2.2.0` @@ -1422,11 +1462,11 @@ namespace WeChatWASM /// | 类型 | 说明 | 最低版本 | /// |------|------| -------| /// | 小程序码 | | - /// | 微信个人码 | 不支持小游戏 | [2.18.0](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) | - /// | 企业微信个人码 | 不支持小游戏 | [2.18.0](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) | - /// | 普通群码 | 指仅包含微信用户的群,不支持小游戏 | [2.18.0](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) | - /// | 互通群码 | 指既有微信用户也有企业微信用户的群,不支持小游戏 | [2.18.0](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) | - /// | 公众号二维码 | 不支持小游戏 | [2.18.0](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) | + /// | 微信个人码 | | [2.18.0](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) | + /// | 企业微信个人码 | | [2.18.0](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) | + /// | 普通群码 | 指仅包含微信用户的群 | [2.18.0](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) | + /// | 互通群码 | 指既有微信用户也有企业微信用户的群 | [2.18.0](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) | + /// | 公众号二维码 | | [2.18.0](https://developers.weixin.qq.com/miniprogram/dev/framework/compatibility.html) | /// **示例代码** /// ```js /// wx.previewImage({ @@ -1569,8 +1609,7 @@ namespace WeChatWASM /// /// [wx.requestMidasPayment(Object object)](https://developers.weixin.qq.com/minigame/dev/api/midas-payment/wx.requestMidasPayment.html) /// 需要基础库: `2.19.2` - /// 发起购买游戏币支付请求,可参考[虚拟支付2.0游戏币](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/virtual-payment/coins.html) - /// 虚拟支付全流程可参考[技术手册-虚拟支付篇](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/virtual-payment/guide.html) + /// 发起购买游戏币支付请求,可参考[虚拟支付2.0游戏币](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/virtual-payment/coins.html),虚拟支付全流程可参考[技术手册-虚拟支付篇](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/virtual-payment/guide.html) /// **buyQuantity 限制说明** /// 购买游戏币的时候,buyQuantity 不可任意填写。需满足 buyQuantity * 游戏币单价 = 限定的价格等级。如:游戏币单价为 0.1 元,一次购买最少数量是 10。 /// 有效价格等级如下: @@ -1614,7 +1653,7 @@ namespace WeChatWASM /// /// [wx.requestMidasPaymentGameItem(Object object)](https://developers.weixin.qq.com/minigame/dev/api/midas-payment/wx.requestMidasPaymentGameItem.html) /// 需要基础库: `2.19.2` - /// 发起道具直购支付请求,可参考[虚拟支付2.0道具直购](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/virtual-payment/goods.html ),虚拟支付全流程可参考[技术手册-虚拟支付篇](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/virtual-payment/guide.html) + /// 发起道具直购支付请求,可参考[虚拟支付2.0道具直购](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/virtual-payment/goods.html),虚拟支付全流程可参考[技术手册-虚拟支付篇](https://developers.weixin.qq.com/minigame/dev/guide/open-ability/virtual-payment/guide.html) /// **示例代码** /// ```js /// wx.requestMidasPaymentGameItem({ @@ -2620,15 +2659,6 @@ namespace WeChatWASM WXSDKManagerHandler.Instance.RevokeBufferURL(url); } - /// - /// [wx.setPreferredFramesPerSecond(number fps)](https://developers.weixin.qq.com/minigame/dev/api/render/frame/wx.setPreferredFramesPerSecond.html) - /// 可以修改渲染帧率。默认渲染帧率为 60 帧每秒。修改后,requestAnimationFrame 的回调频率会发生改变。 - /// - public static void SetPreferredFramesPerSecond(double fps) - { - WXSDKManagerHandler.Instance.SetPreferredFramesPerSecond(fps); - } - /// /// [wx.setStorageSync(string key, any data)](https://developers.weixin.qq.com/minigame/dev/api/storage/wx.setStorageSync.html) /// 将数据存储在本地缓存中指定的 key 中。会覆盖掉原来该 key 对应的内容。除非用户主动删除或因存储空间原因被系统清理,否则数据都一直可用。单个 key 允许存储的最大数据长度为 1MB,所有数据存储上限为 10MB。 @@ -2651,7 +2681,7 @@ namespace WeChatWASM /// 主动拉起转发,进入选择通讯录界面。 /// **** /// ## 注意事项 - /// - 转发图片说明:仅当自定义分享图片权限被封禁时用 imageUrlId,其他情况都会用 imageUrl。 imageUrl 不填时使用游戏画面截图。 + /// - 转发图片说明:imageUrl,imageUrlId 都存在时,优先使用 imageUrl。 imageUrl,imageUrlId 都不填时使用游戏画面截图。 /// public static void ShareAppMessage(ShareAppMessageOption option) { @@ -3456,7 +3486,7 @@ namespace WeChatWASM /// 监听用户点击右上角菜单的「分享到朋友圈」按钮时触发的事件。本接口为 Beta 版本,暂只在 Android 平台支持。 /// **** /// ## 注意事项 - /// - 转发图片说明:仅当自定义分享图片权限被封禁时用 imageUrlId,其他情况都会用 imageUrl。 imageUrl 不填时使用当前游戏的icon。 + /// - 转发图片说明:imageUrl,imageUrlId 都存在时,优先使用 imageUrl。 imageUrl,imageUrlId 都不填时使用当前游戏的icon。 /// public static void OnShareTimeline(Action> callback) { diff --git a/Runtime/WXBase.cs b/Runtime/WXBase.cs index d82b1092..52ccdce1 100644 --- a/Runtime/WXBase.cs +++ b/Runtime/WXBase.cs @@ -1081,6 +1081,14 @@ namespace WeChatWASM WXSDKManagerHandler.Instance.OffGyroscopeChange(result); } #endregion + /// + /// [wx.setPreferredFramesPerSecond(number fps)](https://developers.weixin.qq.com/minigame/dev/api/render/frame/wx.setPreferredFramesPerSecond.html) + /// 可以修改渲染帧率。默认渲染帧率为 60 帧每秒。修改后,requestAnimationFrame 的回调频率会发生改变。 + /// + public static void SetPreferredFramesPerSecond(double fps) + { + WXSDKManagerHandler.Instance.SetPreferredFramesPerSecond(fps); + } /// /// 设置分辨率 /// diff --git a/Runtime/WXSDKPerf/WXPerfEngine.cs b/Runtime/WXSDKPerf/WXPerfEngine.cs index c4807145..8e67e11c 100644 --- a/Runtime/WXSDKPerf/WXPerfEngine.cs +++ b/Runtime/WXSDKPerf/WXPerfEngine.cs @@ -24,11 +24,10 @@ namespace WXSDKPerf { #if UNITY_EDITOR return; -#endif - +#else m_PerfEngineImplementation = new WXPerfEngine_Implementation(); - m_PerfEngineImplementation.StartPerfEngine(); +#endif } @@ -36,7 +35,7 @@ namespace WXSDKPerf { #if UNITY_EDITOR return; -#endif +#else if (m_PerfEngineImplementation == null) { UnityEngine.Debug.LogError("Annotation: Invalid m_PerfEngineImplementation! "); @@ -44,6 +43,7 @@ namespace WXSDKPerf } m_PerfEngineImplementation.Annotation(InAnnotationString); +#endif } } diff --git a/Runtime/wechat-default/check-version.js.meta b/Runtime/wechat-default/check-version.js.meta index 5c161214..8f3c4eeb 100644 --- a/Runtime/wechat-default/check-version.js.meta +++ b/Runtime/wechat-default/check-version.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 71d499c3ddcdc7fd5d533d776b9aaa75 +guid: 8a1247b573dd310a1b2a64ba21756bdf DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/data-package/game.js.meta b/Runtime/wechat-default/data-package/game.js.meta index e46432e0..f5a4116c 100644 --- a/Runtime/wechat-default/data-package/game.js.meta +++ b/Runtime/wechat-default/data-package/game.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 6f597ccca77fde750d0f4c8196abad68 +guid: 79c953592cf5081e24ec64910469c256 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/events.js.meta b/Runtime/wechat-default/events.js.meta index 8f3efa21..91e8d11f 100644 --- a/Runtime/wechat-default/events.js.meta +++ b/Runtime/wechat-default/events.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 43ad945f913c72b896e9d15aad3768eb +guid: 99e734d080d959d56ae6a52ab2f90b24 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/game.js.meta b/Runtime/wechat-default/game.js.meta index 56538d16..0f43b325 100644 --- a/Runtime/wechat-default/game.js.meta +++ b/Runtime/wechat-default/game.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 27ad8aed1211ef5700a5dceedabc3789 +guid: d07e957b862d3577394bb5f30c841b27 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/game.json.meta b/Runtime/wechat-default/game.json.meta index e0e6d8e6..90253b45 100644 --- a/Runtime/wechat-default/game.json.meta +++ b/Runtime/wechat-default/game.json.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: c27a7dcb61c857845933242605f12552 +guid: 3d369640bad5dde9208f01b22ffa181b DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/images/background.jpg.meta b/Runtime/wechat-default/images/background.jpg.meta index 9e2504a2..01a2105e 100644 --- a/Runtime/wechat-default/images/background.jpg.meta +++ b/Runtime/wechat-default/images/background.jpg.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 8f67335d1f6d64763c449e3f8333da8d +guid: 3495bc6c3989dcf8e88863081dc22452 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/images/unity_logo.png.meta b/Runtime/wechat-default/images/unity_logo.png.meta index fe84255d..cd8fbe30 100644 --- a/Runtime/wechat-default/images/unity_logo.png.meta +++ b/Runtime/wechat-default/images/unity_logo.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: d0b13ce5a5d5764bc56872405651a7ff +guid: 979f3d4d2e35c62b4b4f519b1e8eadf4 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/data/index.js.meta b/Runtime/wechat-default/open-data/data/index.js.meta index eaed6418..0ac6e5ac 100644 --- a/Runtime/wechat-default/open-data/data/index.js.meta +++ b/Runtime/wechat-default/open-data/data/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: e28043f273092279a57bc7a786d0e972 +guid: 531ab265ffa88403ffc4ce4ab706bb11 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/data/utils.js.meta b/Runtime/wechat-default/open-data/data/utils.js.meta index 3ab77104..46d43747 100644 --- a/Runtime/wechat-default/open-data/data/utils.js.meta +++ b/Runtime/wechat-default/open-data/data/utils.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 5a5565bbe0032420a545eee6d3fdafb2 +guid: 323d4d77d13e49d058d4e031060a89dd DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/index.js.meta b/Runtime/wechat-default/open-data/index.js.meta index c3bdc199..79caaf73 100644 --- a/Runtime/wechat-default/open-data/index.js.meta +++ b/Runtime/wechat-default/open-data/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 8cc99e1805b239924f629900abe94b27 +guid: 953a2adfd422461e390eca30fc86730c DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/loading.js.meta b/Runtime/wechat-default/open-data/loading.js.meta index e4225e0b..7c0bc722 100644 --- a/Runtime/wechat-default/open-data/loading.js.meta +++ b/Runtime/wechat-default/open-data/loading.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 66aa05df83a04d9ab223807415093d4c +guid: 731ce494d806fb3223bdd49c00f66608 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/image/avatar.png.meta b/Runtime/wechat-default/open-data/render/image/avatar.png.meta index 6c8a461f..d8986a44 100644 --- a/Runtime/wechat-default/open-data/render/image/avatar.png.meta +++ b/Runtime/wechat-default/open-data/render/image/avatar.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: d9cff7bb9cc2097ab2847c5c19df7309 +guid: 35bc38a057afeea49631a8531525b9c9 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/image/button1.png.meta b/Runtime/wechat-default/open-data/render/image/button1.png.meta index 1cea6ada..ecebe7f0 100644 --- a/Runtime/wechat-default/open-data/render/image/button1.png.meta +++ b/Runtime/wechat-default/open-data/render/image/button1.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 929cecb008bf1b22d3ed01632c4710a4 +guid: 06b0d68ee061f759cf54cc972ebb1a36 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/image/button2.png.meta b/Runtime/wechat-default/open-data/render/image/button2.png.meta index 3fa57610..23b54512 100644 --- a/Runtime/wechat-default/open-data/render/image/button2.png.meta +++ b/Runtime/wechat-default/open-data/render/image/button2.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 914b7fa4f2146f905840dd5d17bd0470 +guid: 2078030a00a1994c7ce98919545d976c DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/image/button3.png.meta b/Runtime/wechat-default/open-data/render/image/button3.png.meta index abf3c0dd..fcdad7a6 100644 --- a/Runtime/wechat-default/open-data/render/image/button3.png.meta +++ b/Runtime/wechat-default/open-data/render/image/button3.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 70d4e228c2130c0cb591c18e93e1f550 +guid: b3f682ba70ebc841b606df12b001d010 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/image/loading.png.meta b/Runtime/wechat-default/open-data/render/image/loading.png.meta index f4c08099..835f556a 100644 --- a/Runtime/wechat-default/open-data/render/image/loading.png.meta +++ b/Runtime/wechat-default/open-data/render/image/loading.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 407cd4a4842f57c245ec12a0bbfdb8a0 +guid: 126c6cabeaac54d0d1ddf8c3c844648c DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/image/nameBg.png.meta b/Runtime/wechat-default/open-data/render/image/nameBg.png.meta index 9e189b70..e01e24de 100644 --- a/Runtime/wechat-default/open-data/render/image/nameBg.png.meta +++ b/Runtime/wechat-default/open-data/render/image/nameBg.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 5dcea72e479af431bbf3b484bbdc3be7 +guid: 951b66720a211df06a2c37c7a4e6deb8 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/image/rankAvatar.png.meta b/Runtime/wechat-default/open-data/render/image/rankAvatar.png.meta index a6f5aa02..d02ac484 100644 --- a/Runtime/wechat-default/open-data/render/image/rankAvatar.png.meta +++ b/Runtime/wechat-default/open-data/render/image/rankAvatar.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a4048857e3963e76a356912abebdfdb3 +guid: 46409f256e5c5a004e7723caa67e205e DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/image/rankBg.png.meta b/Runtime/wechat-default/open-data/render/image/rankBg.png.meta index b32026d9..86da7e9b 100644 --- a/Runtime/wechat-default/open-data/render/image/rankBg.png.meta +++ b/Runtime/wechat-default/open-data/render/image/rankBg.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 93f2f5ab96e4e7323c0951d2a1df08bc +guid: 2749f6c15e441c6a6df17a597a310ded DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/image/shareBg.png.meta b/Runtime/wechat-default/open-data/render/image/shareBg.png.meta index 259e07de..fd6fd355 100644 --- a/Runtime/wechat-default/open-data/render/image/shareBg.png.meta +++ b/Runtime/wechat-default/open-data/render/image/shareBg.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: b6ef441642af4b48fe036b6fc7791b2c +guid: 9973d534a5cb9e55f8a51042fb7c3d20 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/image/shareBg2.png.meta b/Runtime/wechat-default/open-data/render/image/shareBg2.png.meta index 502a00aa..d6640ec7 100644 --- a/Runtime/wechat-default/open-data/render/image/shareBg2.png.meta +++ b/Runtime/wechat-default/open-data/render/image/shareBg2.png.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 104242df64dda252be23f8d0334d1fd9 +guid: 4d58d6cad7803c6af5c1686144f09ac6 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/styles/friendRank.js.meta b/Runtime/wechat-default/open-data/render/styles/friendRank.js.meta index 64e9c0a6..bd83dac5 100644 --- a/Runtime/wechat-default/open-data/render/styles/friendRank.js.meta +++ b/Runtime/wechat-default/open-data/render/styles/friendRank.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: d4c10c96785f6c571728d49328adb4ac +guid: 4161f5d60279a2b7a19482423c66908c DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/styles/tips.js.meta b/Runtime/wechat-default/open-data/render/styles/tips.js.meta index 0b4c7e34..3f350fa4 100644 --- a/Runtime/wechat-default/open-data/render/styles/tips.js.meta +++ b/Runtime/wechat-default/open-data/render/styles/tips.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 11e3ccd0c0a6a9630690b31edf1e8278 +guid: 8c8d5f23952a30055cf46cdf40daf274 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/tpls/friendRank.js.meta b/Runtime/wechat-default/open-data/render/tpls/friendRank.js.meta index 786eb934..d4b54d7b 100644 --- a/Runtime/wechat-default/open-data/render/tpls/friendRank.js.meta +++ b/Runtime/wechat-default/open-data/render/tpls/friendRank.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 18805ddc7c20dd265ee0e09160909167 +guid: f9eb78ff7a8937ac5dfb48245b04a8ba DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/open-data/render/tpls/tips.js.meta b/Runtime/wechat-default/open-data/render/tpls/tips.js.meta index 0537ef9e..3690f02e 100644 --- a/Runtime/wechat-default/open-data/render/tpls/tips.js.meta +++ b/Runtime/wechat-default/open-data/render/tpls/tips.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 27d5d8319f99972551e99b428046d349 +guid: 6fff18b45179ff821e3781366c16adf4 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/plugin-config.js.meta b/Runtime/wechat-default/plugin-config.js.meta index 082b543b..3588b78e 100644 --- a/Runtime/wechat-default/plugin-config.js.meta +++ b/Runtime/wechat-default/plugin-config.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 6c1857e5257891e531d2499778d2d3fb +guid: 131a5002fac1acf6b63596e65a931f2c DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/plugins/check-update.js.meta b/Runtime/wechat-default/plugins/check-update.js.meta index 10f9a756..3062f9a6 100644 --- a/Runtime/wechat-default/plugins/check-update.js.meta +++ b/Runtime/wechat-default/plugins/check-update.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 1085c3f760d99c59e74204bada08bd38 +guid: 23ff41e809be2278962c3d135476ee3c DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/plugins/screen-adapter.js.meta b/Runtime/wechat-default/plugins/screen-adapter.js.meta index 577effa5..5a117b4d 100644 --- a/Runtime/wechat-default/plugins/screen-adapter.js.meta +++ b/Runtime/wechat-default/plugins/screen-adapter.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 71c5adfc57d46fbbd7c42c51f0995322 +guid: 31cc91af1db2b99581a7387b77891439 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/project.config.json.meta b/Runtime/wechat-default/project.config.json.meta index 79259635..3af6654d 100644 --- a/Runtime/wechat-default/project.config.json.meta +++ b/Runtime/wechat-default/project.config.json.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: f369ff54a7b4c168522930c72667b5f6 +guid: 6e9739e1de3ee18c4fb8a1317faaadcd DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/texture-config.js.meta b/Runtime/wechat-default/texture-config.js.meta index 0bdfd53b..1d1bef89 100644 --- a/Runtime/wechat-default/texture-config.js.meta +++ b/Runtime/wechat-default/texture-config.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 7222f386088173381a6a1187d33dfe1c +guid: 66c3c6f4958b979c243d5533de996d68 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-namespace.js.meta b/Runtime/wechat-default/unity-namespace.js.meta index 47467863..ed72a7bb 100644 --- a/Runtime/wechat-default/unity-namespace.js.meta +++ b/Runtime/wechat-default/unity-namespace.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 78806020e93f51735707f1f7a3f68ca7 +guid: 7f27d833ad935fa805512a84298eaea4 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/TCPSocket/index.js.meta b/Runtime/wechat-default/unity-sdk/TCPSocket/index.js.meta index ba5a06a5..f27125d1 100644 --- a/Runtime/wechat-default/unity-sdk/TCPSocket/index.js.meta +++ b/Runtime/wechat-default/unity-sdk/TCPSocket/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a5f33632b2e0b80e2db1020ae0a7b496 +guid: 766bddd5446563ef8e2c47c71aa40451 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/UDPSocket/index.js.meta b/Runtime/wechat-default/unity-sdk/UDPSocket/index.js.meta index 2ee108d6..9ee85ca9 100644 --- a/Runtime/wechat-default/unity-sdk/UDPSocket/index.js.meta +++ b/Runtime/wechat-default/unity-sdk/UDPSocket/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 7b499f7630aa7f5776e7d5662446c5d3 +guid: 0f6f1ac5d67c594fef68a767dad077e5 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/ad.js.meta b/Runtime/wechat-default/unity-sdk/ad.js.meta index 54c132da..a2b48cee 100644 --- a/Runtime/wechat-default/unity-sdk/ad.js.meta +++ b/Runtime/wechat-default/unity-sdk/ad.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a2b821d15c7b7d03e4113c0d9e232c76 +guid: b0391791882adfe7474af8871ba1507a DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/audio/common.js.meta b/Runtime/wechat-default/unity-sdk/audio/common.js.meta index 7842ebdb..134efcec 100644 --- a/Runtime/wechat-default/unity-sdk/audio/common.js.meta +++ b/Runtime/wechat-default/unity-sdk/audio/common.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: c43f7810390cf2690dd3912e4610055c +guid: dd320d849117093592f7fce740ac1bdc DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/audio/const.js.meta b/Runtime/wechat-default/unity-sdk/audio/const.js.meta index dd9ff7bb..b2e1d212 100644 --- a/Runtime/wechat-default/unity-sdk/audio/const.js.meta +++ b/Runtime/wechat-default/unity-sdk/audio/const.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 0724291fe64922a17efd6cb0a65ec727 +guid: ff9fe60d890673322bc7ed54360cbaae DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/audio/index.js.meta b/Runtime/wechat-default/unity-sdk/audio/index.js.meta index 59bf5348..017df4d1 100644 --- a/Runtime/wechat-default/unity-sdk/audio/index.js.meta +++ b/Runtime/wechat-default/unity-sdk/audio/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 5c6ada0ed52036ece580e2f2befe93f7 +guid: 668714634739620987464e00472dd2c4 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/audio/inner-audio.js.meta b/Runtime/wechat-default/unity-sdk/audio/inner-audio.js.meta index da9fcd3b..7d85840b 100644 --- a/Runtime/wechat-default/unity-sdk/audio/inner-audio.js.meta +++ b/Runtime/wechat-default/unity-sdk/audio/inner-audio.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: fcab8f06f70223dba5ab466e60dfaf36 +guid: bec2f228c70bb650886701990e963ec6 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/audio/store.js.meta b/Runtime/wechat-default/unity-sdk/audio/store.js.meta index bd13bdac..f8564f90 100644 --- a/Runtime/wechat-default/unity-sdk/audio/store.js.meta +++ b/Runtime/wechat-default/unity-sdk/audio/store.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 648b5273e77d65ec3144195c6812078f +guid: c75e2388a71a8e562b9a053722e599c2 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/audio/unity-audio.js.meta b/Runtime/wechat-default/unity-sdk/audio/unity-audio.js.meta index 16e223a1..f77d306c 100644 --- a/Runtime/wechat-default/unity-sdk/audio/unity-audio.js.meta +++ b/Runtime/wechat-default/unity-sdk/audio/unity-audio.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 276445e4c18507653996f49b941b9b96 +guid: 7006a91caef44308276e578d482a49d2 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/audio/utils.js.meta b/Runtime/wechat-default/unity-sdk/audio/utils.js.meta index 65f5fe08..fb4b9d6f 100644 --- a/Runtime/wechat-default/unity-sdk/audio/utils.js.meta +++ b/Runtime/wechat-default/unity-sdk/audio/utils.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 749e2209b3d2511a5feb7a13c17efc10 +guid: 0964f41cb20a736fdec3d1b5c5af48fa DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/authorize.js.meta b/Runtime/wechat-default/unity-sdk/authorize.js.meta index 8b8e655c..4897af75 100644 --- a/Runtime/wechat-default/unity-sdk/authorize.js.meta +++ b/Runtime/wechat-default/unity-sdk/authorize.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: d9776ae6e4626e6cb529908485fc204d +guid: 8c8265f85df2fae934e43fddf225db35 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/bluetooth/index.js.meta b/Runtime/wechat-default/unity-sdk/bluetooth/index.js.meta index e7450d13..cc3ed16f 100644 --- a/Runtime/wechat-default/unity-sdk/bluetooth/index.js.meta +++ b/Runtime/wechat-default/unity-sdk/bluetooth/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 5b2ad10c6ce1242b26937c49f9c8a22d +guid: 543747602ed8b955436592aeff496702 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/camera.js.meta b/Runtime/wechat-default/unity-sdk/camera.js.meta index 119d7c5b..3a486927 100644 --- a/Runtime/wechat-default/unity-sdk/camera.js.meta +++ b/Runtime/wechat-default/unity-sdk/camera.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 1f35ba1a02cf8ae421d1135c6672e92c +guid: 289d11dd2b99cdc444315bb581071a7b DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/canvas-context.js.meta b/Runtime/wechat-default/unity-sdk/canvas-context.js.meta index 62bfd10c..bc203c71 100644 --- a/Runtime/wechat-default/unity-sdk/canvas-context.js.meta +++ b/Runtime/wechat-default/unity-sdk/canvas-context.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 9878f3900011e395917f007e50fbfbf1 +guid: ef38590f60857344e9ba9e8972d892a6 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/canvas.js.meta b/Runtime/wechat-default/unity-sdk/canvas.js.meta index 8784ed4b..d43ff71d 100644 --- a/Runtime/wechat-default/unity-sdk/canvas.js.meta +++ b/Runtime/wechat-default/unity-sdk/canvas.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 2250a10bdd08bd01e33c6ecde6abc54b +guid: 8928cde6f8dc7badb406c80e4f974c19 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/chat.js.meta b/Runtime/wechat-default/unity-sdk/chat.js.meta index ec5fef6a..c9ecb145 100644 --- a/Runtime/wechat-default/unity-sdk/chat.js.meta +++ b/Runtime/wechat-default/unity-sdk/chat.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 5f038f13e12b40016fef88b856538326 +guid: ecb588c5857c7e0de9a55e9493f32bfb DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/cloud.js b/Runtime/wechat-default/unity-sdk/cloud.js index babe75e4..48ad3ebb 100644 --- a/Runtime/wechat-default/unity-sdk/cloud.js +++ b/Runtime/wechat-default/unity-sdk/cloud.js @@ -32,7 +32,7 @@ export default { wx.cloud.init(); } else { - CloudList[config.env].init(config); + wx.cloud.init(config); } }, WX_CloudCallFunction(env, conf, callbackId) { diff --git a/Runtime/wechat-default/unity-sdk/cloud.js.meta b/Runtime/wechat-default/unity-sdk/cloud.js.meta index b07793bc..63487d5e 100644 --- a/Runtime/wechat-default/unity-sdk/cloud.js.meta +++ b/Runtime/wechat-default/unity-sdk/cloud.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 6ed202f67b2919b280ce4125ea73f966 +guid: 377258b0bae3f0a3dda9bf70b233dcaa DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/conf.js.meta b/Runtime/wechat-default/unity-sdk/conf.js.meta index b215e689..f43a03ef 100644 --- a/Runtime/wechat-default/unity-sdk/conf.js.meta +++ b/Runtime/wechat-default/unity-sdk/conf.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: f24f398b2c5aa388aabf8344793fa200 +guid: f93aa301cb7a969f8386e0292ebd3ccd DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/file-info.js.meta b/Runtime/wechat-default/unity-sdk/file-info.js.meta index 242f723e..8c3d59a3 100644 --- a/Runtime/wechat-default/unity-sdk/file-info.js.meta +++ b/Runtime/wechat-default/unity-sdk/file-info.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: dd99894629490ac337c33882994121ef +guid: f1af4e76799774c7b92c18a06e929cdd DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/fix.js.meta b/Runtime/wechat-default/unity-sdk/fix.js.meta index 07eee7ef..ec1aba85 100644 --- a/Runtime/wechat-default/unity-sdk/fix.js.meta +++ b/Runtime/wechat-default/unity-sdk/fix.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 8f23cbbc407aeea73854d77e4f926827 +guid: 29e769883b5fcc934b821c25a9a22c1c DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/font/fix-cmap.js.meta b/Runtime/wechat-default/unity-sdk/font/fix-cmap.js.meta index e7269412..a3c13317 100644 --- a/Runtime/wechat-default/unity-sdk/font/fix-cmap.js.meta +++ b/Runtime/wechat-default/unity-sdk/font/fix-cmap.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 9792e94ba797c1d7a839b7af36c16d50 +guid: e5ed04bc49703466b850b706e954f545 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/font/index.js.meta b/Runtime/wechat-default/unity-sdk/font/index.js.meta index 9ae3bb13..5b5f9edf 100644 --- a/Runtime/wechat-default/unity-sdk/font/index.js.meta +++ b/Runtime/wechat-default/unity-sdk/font/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 61888d25ed644241a11211777adeb147 +guid: 98b1b2b795fa0b5fb7bf6fad2a1ce599 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/font/read-metrics.js.meta b/Runtime/wechat-default/unity-sdk/font/read-metrics.js.meta index 822703a2..60c4421d 100644 --- a/Runtime/wechat-default/unity-sdk/font/read-metrics.js.meta +++ b/Runtime/wechat-default/unity-sdk/font/read-metrics.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 5a724a35334cacf412c9e2f3acc7f422 +guid: 836dee44cd3f3b9cc7cd34f7ffc36c8f DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/font/split-sc.js.meta b/Runtime/wechat-default/unity-sdk/font/split-sc.js.meta index fe356297..6023cc1b 100644 --- a/Runtime/wechat-default/unity-sdk/font/split-sc.js.meta +++ b/Runtime/wechat-default/unity-sdk/font/split-sc.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 0ab028cd74f6a4d3050a882ea4e9b8e2 +guid: d1a41b5f07ff17bdcc4fdd1a4b8315ea DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/font/util.js.meta b/Runtime/wechat-default/unity-sdk/font/util.js.meta index 0c235ea0..c32f76ad 100644 --- a/Runtime/wechat-default/unity-sdk/font/util.js.meta +++ b/Runtime/wechat-default/unity-sdk/font/util.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 05ad7dea7abc82eced86c7cfed64fdd2 +guid: 3b9b7e634c503e8c6b3ce0c396abca9c DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/fs.js.meta b/Runtime/wechat-default/unity-sdk/fs.js.meta index 393c072c..4ad16dd9 100644 --- a/Runtime/wechat-default/unity-sdk/fs.js.meta +++ b/Runtime/wechat-default/unity-sdk/fs.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 8d0a19aaa7549075831f77437c5dbbaa +guid: eb800297b61247d41bbf60b9902a2fc4 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/game-club.js.meta b/Runtime/wechat-default/unity-sdk/game-club.js.meta index 737ee99d..beaf2df6 100644 --- a/Runtime/wechat-default/unity-sdk/game-club.js.meta +++ b/Runtime/wechat-default/unity-sdk/game-club.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 1150a5dba7e4cce22d887cfb49789c73 +guid: ba00566c1ff471dc82d70c7b74709ac3 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/game-recorder.js.meta b/Runtime/wechat-default/unity-sdk/game-recorder.js.meta index 3ab1ef58..7bd6c8c7 100644 --- a/Runtime/wechat-default/unity-sdk/game-recorder.js.meta +++ b/Runtime/wechat-default/unity-sdk/game-recorder.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 50ff86be764df91afcc9739ac9ac9872 +guid: 029769ef7bf31119d222436f7c2e9e38 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/gyroscope/index.js.meta b/Runtime/wechat-default/unity-sdk/gyroscope/index.js.meta index c9c70c4e..5dfe2f81 100644 --- a/Runtime/wechat-default/unity-sdk/gyroscope/index.js.meta +++ b/Runtime/wechat-default/unity-sdk/gyroscope/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: c8576c2b6895f01b9f09f22a8c1eb53d +guid: 7240d703aa50908bac720346b7bcbef9 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/index.js.meta b/Runtime/wechat-default/unity-sdk/index.js.meta index a5587aaa..8d964463 100644 --- a/Runtime/wechat-default/unity-sdk/index.js.meta +++ b/Runtime/wechat-default/unity-sdk/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: d4421922a9caa43cb22f649240f75694 +guid: 36a91578755ee2617a665209d70d9854 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/logger.js.meta b/Runtime/wechat-default/unity-sdk/logger.js.meta index c72ef7f9..705566b4 100644 --- a/Runtime/wechat-default/unity-sdk/logger.js.meta +++ b/Runtime/wechat-default/unity-sdk/logger.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 7f190f8a8b96a27440842086c821518c +guid: be04e6c960eb3e3e73b4768e5d718c6c DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/mobileKeyboard/index.js.meta b/Runtime/wechat-default/unity-sdk/mobileKeyboard/index.js.meta index 5043cc34..20c7b789 100644 --- a/Runtime/wechat-default/unity-sdk/mobileKeyboard/index.js.meta +++ b/Runtime/wechat-default/unity-sdk/mobileKeyboard/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: f887b6fae8bdf1479fa48aa0d705e0fe +guid: 58ba27f52b783990fde257bc7aed85bf DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/module-helper.js.meta b/Runtime/wechat-default/unity-sdk/module-helper.js.meta index 459cb57b..7048bc6e 100644 --- a/Runtime/wechat-default/unity-sdk/module-helper.js.meta +++ b/Runtime/wechat-default/unity-sdk/module-helper.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 34d12bc6b08c49eafc1d4506ab0ff0bb +guid: 8f5ddd9f5eea4d4f3db0fa5fc9844d6d DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/open-data.js.meta b/Runtime/wechat-default/unity-sdk/open-data.js.meta index fb9b4093..6a98e7ec 100644 --- a/Runtime/wechat-default/unity-sdk/open-data.js.meta +++ b/Runtime/wechat-default/unity-sdk/open-data.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: aa89889a48c5cb2aa606b07f96e46b52 +guid: f79052ad77b04b833d44865832471fc4 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/recorder.js.meta b/Runtime/wechat-default/unity-sdk/recorder.js.meta index b50a6862..4903d45d 100644 --- a/Runtime/wechat-default/unity-sdk/recorder.js.meta +++ b/Runtime/wechat-default/unity-sdk/recorder.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 2d5e814fe75eedce1663a654d887f1e9 +guid: 3232c9317c5d73372a9524f21f564ba2 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/resType.js b/Runtime/wechat-default/unity-sdk/resType.js index 9235347b..7ce705b8 100644 --- a/Runtime/wechat-default/unity-sdk/resType.js +++ b/Runtime/wechat-default/unity-sdk/resType.js @@ -571,6 +571,7 @@ export const ResType = { hasSystemProxy: 'bool', networkType: 'string', signalStrength: 'number', + weakNet: 'bool', errMsg: 'string', }, GetPrivacySettingSuccessCallbackResult: { diff --git a/Runtime/wechat-default/unity-sdk/resType.js.meta b/Runtime/wechat-default/unity-sdk/resType.js.meta index 73fbb076..5cdcce2f 100644 --- a/Runtime/wechat-default/unity-sdk/resType.js.meta +++ b/Runtime/wechat-default/unity-sdk/resType.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a84303c59e300838851050d29b0c431b +guid: 6d5fa787e34212c77b6ee0cdcea51371 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/resTypeOther.js.meta b/Runtime/wechat-default/unity-sdk/resTypeOther.js.meta index 41a9df96..db7cbc82 100644 --- a/Runtime/wechat-default/unity-sdk/resTypeOther.js.meta +++ b/Runtime/wechat-default/unity-sdk/resTypeOther.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 7e68194a0b2eefe3c22c9933857f5f1d +guid: 439aa898bd68964ace7479e0a4bf5063 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/response.js.meta b/Runtime/wechat-default/unity-sdk/response.js.meta index bec49d92..34e7db26 100644 --- a/Runtime/wechat-default/unity-sdk/response.js.meta +++ b/Runtime/wechat-default/unity-sdk/response.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 699ac195f0704b1241f038a3a3eb332b +guid: 12ab4a8611a027144f8414c0681a8358 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/sdk.js b/Runtime/wechat-default/unity-sdk/sdk.js index c0de7e82..d1230f71 100644 --- a/Runtime/wechat-default/unity-sdk/sdk.js +++ b/Runtime/wechat-default/unity-sdk/sdk.js @@ -1,4035 +1,121 @@ import moduleHelper from './module-helper'; -import { uid, formatResponse, formatJsonStr, onEventCallback, offEventCallback, getListObject, stringifyRes } from './utils'; -let OnAccelerometerChangeList; -let OnAudioInterruptionBeginList; -let OnAudioInterruptionEndList; -let OnBLEConnectionStateChangeList; -let OnBLEMTUChangeList; -let OnBLEPeripheralConnectionStateChangedList; -let OnBeaconServiceChangeList; -let OnBeaconUpdateList; -let OnBluetoothAdapterStateChangeList; -let OnBluetoothDeviceFoundList; -let OnCompassChangeList; -let OnDeviceMotionChangeList; -let OnDeviceOrientationChangeList; -let OnErrorList; -let OnHideList; -let OnInteractiveStorageModifiedList; -let OnKeyDownList; -let OnKeyUpList; -let OnKeyboardCompleteList; -let OnKeyboardConfirmList; -let OnKeyboardHeightChangeList; -let OnKeyboardInputList; -let OnMemoryWarningList; -let OnMenuButtonBoundingClientRectWeightChangeList; -let OnMouseDownList; -let OnMouseMoveList; -let OnMouseUpList; -let OnNetworkStatusChangeList; -let OnNetworkWeakChangeList; -let OnScreenRecordingStateChangedList; -let OnShowList; -let OnUnhandledRejectionList; -let OnUserCaptureScreenList; -let OnVoIPChatInterruptedList; -let OnVoIPChatMembersChangedList; -let OnVoIPChatSpeakersChangedList; -let OnVoIPChatStateChangedList; -let OnWheelList; -let OnWindowResizeList; +import { uid, formatResponse, formatJsonStr, stringifyRes } from './utils'; +const onEventLists = {}; let wxOnAddToFavoritesResolveConf; let wxOnCopyUrlResolveConf; let wxOnHandoffResolveConf; let wxOnShareTimelineResolveConf; let wxOnGameLiveStateChangeResolveConf; -const DownloadTaskList = {}; -const FeedbackButtonList = {}; -const LogManagerList = {}; -const RealtimeLogManagerList = {}; -const UpdateManagerList = {}; -const VideoDecoderList = {}; -const wxDownloadTaskHeadersReceivedList = {}; -const wxDownloadTaskProgressUpdateList = {}; -const wxFeedbackButtonTapList = {}; -const wxVideoDecoderList = {}; -const getDownloadTaskObject = getListObject(DownloadTaskList, 'DownloadTask'); -const getFeedbackButtonObject = getListObject(FeedbackButtonList, 'FeedbackButton'); -const getLogManagerObject = getListObject(LogManagerList, 'LogManager'); -const getRealtimeLogManagerObject = getListObject(RealtimeLogManagerList, 'RealtimeLogManager'); -const getUpdateManagerObject = getListObject(UpdateManagerList, 'UpdateManager'); -const getVideoDecoderObject = getListObject(VideoDecoderList, 'VideoDecoder'); +const ClassLists = {}; +const ClassOnEventLists = {}; +function getClassObject(className, id) { + if (!ClassLists[className]) { + ClassLists[className] = {}; + } + const obj = ClassLists[className][id]; + if (!obj) { + console.error(`${className} 不存在:`, id); + } + return obj; +} +; + +// eslint-disable-next-line @typescript-eslint/naming-convention +function WX_OneWayNoFunction(functionName, ...params) { + wx[functionName.replace(/^\w/, a => a.toLowerCase())](...params); +} + + +const onlyReadyResponse = [ + 'getSystemSetting', + 'getAppAuthorizeSetting', +]; +// eslint-disable-next-line @typescript-eslint/naming-convention +function WX_SyncFunction(functionName, ...params) { + return wx[functionName.replace(/^\w/, a => a.toLowerCase())](...params); +} + +// eslint-disable-next-line @typescript-eslint/naming-convention +function WX_ClassOneWayNoFunction(className, functionName, id, ...params) { + const obj = getClassObject(className, id); + if (!obj) { + return; + } + obj[functionName.replace(/^\w/, a => a.toLowerCase())](...params); +} export default { - WX_AddCard(conf, callbackId) { + WX_OneWayFunction(functionName, successType, failType, completeType, conf, callbackId) { + const lowerFunctionName = functionName.replace(/^\w/, a => a.toLowerCase()); const config = formatJsonStr(conf); - wx.addCard({ - ...config, - success(res) { - formatResponse('AddCardSuccessCallbackResult', res); - moduleHelper.send('AddCardCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('AddCardCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('AddCardCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_AuthPrivateMessage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.authPrivateMessage({ - ...config, - success(res) { - formatResponse('AuthPrivateMessageSuccessCallbackResult', res); - moduleHelper.send('AuthPrivateMessageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('AuthPrivateMessageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('AuthPrivateMessageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_Authorize(conf, callbackId) { - const config = formatJsonStr(conf); - wx.authorize({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('AuthorizeCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('AuthorizeCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('AuthorizeCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_CheckIsAddedToMyMiniProgram(conf, callbackId) { - const config = formatJsonStr(conf); - wx.checkIsAddedToMyMiniProgram({ - ...config, - success(res) { - formatResponse('CheckIsAddedToMyMiniProgramSuccessCallbackResult', res); - moduleHelper.send('CheckIsAddedToMyMiniProgramCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CheckIsAddedToMyMiniProgramCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CheckIsAddedToMyMiniProgramCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_CheckSession(conf, callbackId) { - const config = formatJsonStr(conf); - wx.checkSession({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CheckSessionCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CheckSessionCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CheckSessionCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ChooseImage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.chooseImage({ - ...config, - success(res) { - formatResponse('ChooseImageSuccessCallbackResult', res); - moduleHelper.send('ChooseImageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ChooseImageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ChooseImageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ChooseMedia(conf, callbackId) { - const config = formatJsonStr(conf); - wx.chooseMedia({ - ...config, - success(res) { - formatResponse('ChooseMediaSuccessCallbackResult', res); - moduleHelper.send('ChooseMediaCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ChooseMediaCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ChooseMediaCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ChooseMessageFile(conf, callbackId) { - const config = formatJsonStr(conf); - wx.chooseMessageFile({ - ...config, - success(res) { - formatResponse('ChooseMessageFileSuccessCallbackResult', res); - moduleHelper.send('ChooseMessageFileCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ChooseMessageFileCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ChooseMessageFileCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_CloseBLEConnection(conf, callbackId) { - const config = formatJsonStr(conf); - wx.closeBLEConnection({ - ...config, - success(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('CloseBLEConnectionCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('CloseBLEConnectionCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('CloseBLEConnectionCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_CloseBluetoothAdapter(conf, callbackId) { - const config = formatJsonStr(conf); - wx.closeBluetoothAdapter({ - ...config, - success(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('CloseBluetoothAdapterCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('CloseBluetoothAdapterCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('CloseBluetoothAdapterCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_CompressImage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.compressImage({ - ...config, - success(res) { - formatResponse('CompressImageSuccessCallbackResult', res); - moduleHelper.send('CompressImageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CompressImageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CompressImageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_CreateBLEConnection(conf, callbackId) { - const config = formatJsonStr(conf); - wx.createBLEConnection({ - ...config, - success(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('CreateBLEConnectionCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('CreateBLEConnectionCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('CreateBLEConnectionCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_CreateBLEPeripheralServer(conf, callbackId) { - const config = formatJsonStr(conf); - wx.createBLEPeripheralServer({ - ...config, - success(res) { - formatResponse('CreateBLEPeripheralServerSuccessCallbackResult', res); - moduleHelper.send('CreateBLEPeripheralServerCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CreateBLEPeripheralServerCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CreateBLEPeripheralServerCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ExitMiniProgram(conf, callbackId) { - const config = formatJsonStr(conf); - wx.exitMiniProgram({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ExitMiniProgramCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ExitMiniProgramCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ExitMiniProgramCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ExitVoIPChat(conf, callbackId) { - const config = formatJsonStr(conf); - wx.exitVoIPChat({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ExitVoIPChatCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ExitVoIPChatCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ExitVoIPChatCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_FaceDetect(conf, callbackId) { - const config = formatJsonStr(conf); - wx.faceDetect({ - ...config, - success(res) { - formatResponse('FaceDetectSuccessCallbackResult', res); - moduleHelper.send('FaceDetectCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('FaceDetectCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('FaceDetectCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetAvailableAudioSources(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getAvailableAudioSources({ - ...config, - success(res) { - formatResponse('GetAvailableAudioSourcesSuccessCallbackResult', res); - moduleHelper.send('GetAvailableAudioSourcesCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetAvailableAudioSourcesCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetAvailableAudioSourcesCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetBLEDeviceCharacteristics(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getBLEDeviceCharacteristics({ - ...config, - success(res) { - formatResponse('GetBLEDeviceCharacteristicsSuccessCallbackResult', res); - moduleHelper.send('GetBLEDeviceCharacteristicsCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetBLEDeviceCharacteristicsCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetBLEDeviceCharacteristicsCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetBLEDeviceRSSI(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getBLEDeviceRSSI({ - ...config, - success(res) { - formatResponse('GetBLEDeviceRSSISuccessCallbackResult', res); - moduleHelper.send('GetBLEDeviceRSSICallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetBLEDeviceRSSICallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetBLEDeviceRSSICallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetBLEDeviceServices(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getBLEDeviceServices({ - ...config, - success(res) { - formatResponse('GetBLEDeviceServicesSuccessCallbackResult', res); - moduleHelper.send('GetBLEDeviceServicesCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetBLEDeviceServicesCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetBLEDeviceServicesCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetBLEMTU(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getBLEMTU({ - ...config, - success(res) { - formatResponse('GetBLEMTUSuccessCallbackResult', res); - moduleHelper.send('GetBLEMTUCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetBLEMTUCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetBLEMTUCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetBackgroundFetchData(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getBackgroundFetchData({ - ...config, - success(res) { - formatResponse('GetBackgroundFetchDataSuccessCallbackResult', res); - moduleHelper.send('GetBackgroundFetchDataCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetBackgroundFetchDataCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetBackgroundFetchDataCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetBackgroundFetchToken(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getBackgroundFetchToken({ - ...config, - success(res) { - formatResponse('GetBackgroundFetchTokenSuccessCallbackResult', res); - moduleHelper.send('GetBackgroundFetchTokenCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetBackgroundFetchTokenCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetBackgroundFetchTokenCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetBatteryInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getBatteryInfo({ - ...config, - success(res) { - formatResponse('GetBatteryInfoSuccessCallbackResult', res); - moduleHelper.send('GetBatteryInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetBatteryInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetBatteryInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetBeacons(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getBeacons({ - ...config, - success(res) { - formatResponse('GetBeaconsSuccessCallbackResult', res); - moduleHelper.send('GetBeaconsCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BeaconError', res); - moduleHelper.send('GetBeaconsCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BeaconError', res); - moduleHelper.send('GetBeaconsCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetBluetoothAdapterState(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getBluetoothAdapterState({ - ...config, - success(res) { - formatResponse('GetBluetoothAdapterStateSuccessCallbackResult', res); - moduleHelper.send('GetBluetoothAdapterStateCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetBluetoothAdapterStateCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetBluetoothAdapterStateCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetBluetoothDevices(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getBluetoothDevices({ - ...config, - success(res) { - formatResponse('GetBluetoothDevicesSuccessCallbackResult', res); - moduleHelper.send('GetBluetoothDevicesCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetBluetoothDevicesCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetBluetoothDevicesCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetChannelsLiveInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getChannelsLiveInfo({ - ...config, - success(res) { - formatResponse('GetChannelsLiveInfoSuccessCallbackResult', res); - moduleHelper.send('GetChannelsLiveInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetChannelsLiveInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetChannelsLiveInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetChannelsLiveNoticeInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getChannelsLiveNoticeInfo({ - ...config, - success(res) { - formatResponse('GetChannelsLiveNoticeInfoSuccessCallbackResult', res); - moduleHelper.send('GetChannelsLiveNoticeInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetChannelsLiveNoticeInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetChannelsLiveNoticeInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetClipboardData(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getClipboardData({ - ...config, - success(res) { - formatResponse('GetClipboardDataSuccessCallbackOption', res); - moduleHelper.send('GetClipboardDataCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetClipboardDataCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetClipboardDataCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetConnectedBluetoothDevices(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getConnectedBluetoothDevices({ - ...config, - success(res) { - formatResponse('GetConnectedBluetoothDevicesSuccessCallbackResult', res); - moduleHelper.send('GetConnectedBluetoothDevicesCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetConnectedBluetoothDevicesCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('GetConnectedBluetoothDevicesCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetDeviceBenchmarkInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getDeviceBenchmarkInfo({ - ...config, - success(res) { - formatResponse('GetDeviceBenchmarkInfoSuccessCallbackResult', res); - moduleHelper.send('GetDeviceBenchmarkInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetDeviceBenchmarkInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetDeviceBenchmarkInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetExtConfig(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getExtConfig({ - ...config, - success(res) { - formatResponse('GetExtConfigSuccessCallbackResult', res); - moduleHelper.send('GetExtConfigCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetExtConfigCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetExtConfigCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetFuzzyLocation(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getFuzzyLocation({ - ...config, - success(res) { - formatResponse('GetFuzzyLocationSuccessCallbackResult', res); - moduleHelper.send('GetFuzzyLocationCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetFuzzyLocationCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetFuzzyLocationCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetGameClubData(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getGameClubData({ - ...config, - success(res) { - formatResponse('GetGameClubDataSuccessCallbackResult', res); - moduleHelper.send('GetGameClubDataCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetGameClubDataCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetGameClubDataCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetGroupEnterInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getGroupEnterInfo({ - ...config, - success(res) { - formatResponse('GetGroupEnterInfoSuccessCallbackResult', res); - moduleHelper.send('GetGroupEnterInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GetGroupEnterInfoError', res); - moduleHelper.send('GetGroupEnterInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GetGroupEnterInfoError', res); - moduleHelper.send('GetGroupEnterInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetInferenceEnvInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getInferenceEnvInfo({ - ...config, - success(res) { - formatResponse('GetInferenceEnvInfoSuccessCallbackResult', res); - moduleHelper.send('GetInferenceEnvInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetInferenceEnvInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetInferenceEnvInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetLocalIPAddress(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getLocalIPAddress({ - ...config, - success(res) { - formatResponse('GetLocalIPAddressSuccessCallbackResult', res); - moduleHelper.send('GetLocalIPAddressCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetLocalIPAddressCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetLocalIPAddressCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetNetworkType(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getNetworkType({ - ...config, - success(res) { - formatResponse('GetNetworkTypeSuccessCallbackResult', res); - moduleHelper.send('GetNetworkTypeCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetNetworkTypeCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetNetworkTypeCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetPrivacySetting(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getPrivacySetting({ - ...config, - success(res) { - formatResponse('GetPrivacySettingSuccessCallbackResult', res); - moduleHelper.send('GetPrivacySettingCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetPrivacySettingCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetPrivacySettingCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetScreenBrightness(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getScreenBrightness({ - ...config, - success(res) { - formatResponse('GetScreenBrightnessSuccessCallbackOption', res); - moduleHelper.send('GetScreenBrightnessCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetScreenBrightnessCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetScreenBrightnessCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetScreenRecordingState(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getScreenRecordingState({ - ...config, - success(res) { - formatResponse('GetScreenRecordingStateSuccessCallbackResult', res); - moduleHelper.send('GetScreenRecordingStateCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetScreenRecordingStateCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetScreenRecordingStateCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetSetting(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getSetting({ - ...config, - success(res) { - formatResponse('GetSettingSuccessCallbackResult', res); - moduleHelper.send('GetSettingCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetSettingCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetSettingCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetShareInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getShareInfo({ - ...config, - success(res) { - formatResponse('GetGroupEnterInfoSuccessCallbackResult', res); - moduleHelper.send('GetShareInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetShareInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetShareInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetStorageInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getStorageInfo({ - ...config, - success(res) { - formatResponse('GetStorageInfoSuccessCallbackOption', res); - moduleHelper.send('GetStorageInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetStorageInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetStorageInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetSystemInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getSystemInfo({ - ...config, - success(res) { - formatResponse('SystemInfo', res); - moduleHelper.send('GetSystemInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetSystemInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetSystemInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetSystemInfoAsync(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getSystemInfoAsync({ - ...config, - success(res) { - formatResponse('SystemInfo', res); - moduleHelper.send('GetSystemInfoAsyncCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetSystemInfoAsyncCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetSystemInfoAsyncCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetUserInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getUserInfo({ - ...config, - success(res) { - formatResponse('GetUserInfoSuccessCallbackResult', res); - moduleHelper.send('GetUserInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetUserInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetUserInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetUserInteractiveStorage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getUserInteractiveStorage({ - ...config, - success(res) { - formatResponse('GetUserInteractiveStorageSuccessCallbackResult', res); - moduleHelper.send('GetUserInteractiveStorageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GetUserInteractiveStorageFailCallbackResult', res); - moduleHelper.send('GetUserInteractiveStorageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetUserInteractiveStorageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetWeRunData(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getWeRunData({ - ...config, - success(res) { - formatResponse('GetWeRunDataSuccessCallbackResult', res); - moduleHelper.send('GetWeRunDataCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetWeRunDataCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetWeRunDataCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_HideKeyboard(conf, callbackId) { - const config = formatJsonStr(conf); - wx.hideKeyboard({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideKeyboardCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideKeyboardCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideKeyboardCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_HideLoading(conf, callbackId) { - const config = formatJsonStr(conf); - wx.hideLoading({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideLoadingCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideLoadingCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideLoadingCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_HideShareMenu(conf, callbackId) { - const config = formatJsonStr(conf); - wx.hideShareMenu({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideShareMenuCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideShareMenuCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideShareMenuCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_HideToast(conf, callbackId) { - const config = formatJsonStr(conf); - wx.hideToast({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideToastCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideToastCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('HideToastCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_InitFaceDetect(conf, callbackId) { - const config = formatJsonStr(conf); - wx.initFaceDetect({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('InitFaceDetectCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('InitFaceDetectCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('InitFaceDetectCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_IsBluetoothDevicePaired(conf, callbackId) { - const config = formatJsonStr(conf); - wx.isBluetoothDevicePaired({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('IsBluetoothDevicePairedCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('IsBluetoothDevicePairedCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('IsBluetoothDevicePairedCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_JoinVoIPChat(conf, callbackId) { - const config = formatJsonStr(conf); - wx.joinVoIPChat({ - ...config, - success(res) { - formatResponse('JoinVoIPChatSuccessCallbackResult', res); - moduleHelper.send('JoinVoIPChatCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('JoinVoIPChatError', res); - moduleHelper.send('JoinVoIPChatCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('JoinVoIPChatError', res); - moduleHelper.send('JoinVoIPChatCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_Login(conf, callbackId) { - const config = formatJsonStr(conf); - if (!config.timeout) { - delete config.timeout; + + if (lowerFunctionName === 'login') { + if (!config.timeout) { + delete config.timeout; + } } - wx.login({ - ...config, - success(res) { - formatResponse('LoginSuccessCallbackResult', res); - moduleHelper.send('LoginCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('RequestFailCallbackErr', res); - moduleHelper.send('LoginCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('LoginCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_MakeBluetoothPair(conf, callbackId) { - const config = formatJsonStr(conf); - wx.makeBluetoothPair({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('MakeBluetoothPairCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('MakeBluetoothPairCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('MakeBluetoothPairCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_NavigateToMiniProgram(conf, callbackId) { - const config = formatJsonStr(conf); - wx.navigateToMiniProgram({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('NavigateToMiniProgramCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('NavigateToMiniProgramCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('NavigateToMiniProgramCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_NotifyBLECharacteristicValueChange(conf, callbackId) { - const config = formatJsonStr(conf); - wx.notifyBLECharacteristicValueChange({ - ...config, - success(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('NotifyBLECharacteristicValueChangeCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('NotifyBLECharacteristicValueChangeCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('NotifyBLECharacteristicValueChangeCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenAppAuthorizeSetting(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openAppAuthorizeSetting({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenAppAuthorizeSettingCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenAppAuthorizeSettingCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenAppAuthorizeSettingCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenBluetoothAdapter(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openBluetoothAdapter({ - ...config, - success(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('OpenBluetoothAdapterCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('OpenBluetoothAdapterCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('OpenBluetoothAdapterCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenCard(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openCard({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenCardCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenCardCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenCardCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenChannelsActivity(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openChannelsActivity({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsActivityCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsActivityCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsActivityCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenChannelsEvent(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openChannelsEvent({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsEventCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsEventCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsEventCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenChannelsLive(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openChannelsLive({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsLiveCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsLiveCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsLiveCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenChannelsUserProfile(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openChannelsUserProfile({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsUserProfileCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsUserProfileCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsUserProfileCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenCustomerServiceChat(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openCustomerServiceChat({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenCustomerServiceChatCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenCustomerServiceChatCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenCustomerServiceChatCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenCustomerServiceConversation(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openCustomerServiceConversation({ - ...config, - success(res) { - formatResponse('OpenCustomerServiceConversationSuccessCallbackResult', res); - moduleHelper.send('OpenCustomerServiceConversationCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenCustomerServiceConversationCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenCustomerServiceConversationCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenPrivacyContract(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openPrivacyContract({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenPrivacyContractCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenPrivacyContractCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenPrivacyContractCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenSetting(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openSetting({ - ...config, - success(res) { - formatResponse('OpenSettingSuccessCallbackResult', res); - moduleHelper.send('OpenSettingCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenSettingCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenSettingCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenSystemBluetoothSetting(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openSystemBluetoothSetting({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenSystemBluetoothSettingCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenSystemBluetoothSettingCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenSystemBluetoothSettingCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_PreviewImage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.previewImage({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('PreviewImageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('PreviewImageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('PreviewImageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_PreviewMedia(conf, callbackId) { - const config = formatJsonStr(conf); - wx.previewMedia({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('PreviewMediaCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('PreviewMediaCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('PreviewMediaCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ReadBLECharacteristicValue(conf, callbackId) { - const config = formatJsonStr(conf); - wx.readBLECharacteristicValue({ - ...config, - success(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('ReadBLECharacteristicValueCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('ReadBLECharacteristicValueCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('ReadBLECharacteristicValueCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_RemoveStorage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.removeStorage({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RemoveStorageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RemoveStorageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RemoveStorageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_RemoveUserCloudStorage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.removeUserCloudStorage({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RemoveUserCloudStorageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RemoveUserCloudStorageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RemoveUserCloudStorageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ReportScene(conf, callbackId) { - const config = formatJsonStr(conf); - if (GameGlobal.manager && GameGlobal.manager.setGameStage) { - GameGlobal.manager.setGameStage(config.sceneId); + else if (lowerFunctionName === 'reportScene') { + if (GameGlobal.manager && GameGlobal.manager.setGameStage) { + GameGlobal.manager.setGameStage(config.sceneId); + } } - wx.reportScene({ + wx[lowerFunctionName]({ ...config, success(res) { - formatResponse('ReportSceneSuccessCallbackResult', res); - moduleHelper.send('ReportSceneCallback', JSON.stringify({ + formatResponse(successType, res); + moduleHelper.send(`${functionName}Callback`, JSON.stringify({ callbackId, type: 'success', res: JSON.stringify(res), })); }, fail(res) { - formatResponse('ReportSceneFailCallbackErr', res); - moduleHelper.send('ReportSceneCallback', JSON.stringify({ + formatResponse(failType, res); + moduleHelper.send(`${functionName}Callback`, JSON.stringify({ callbackId, type: 'fail', res: JSON.stringify(res), })); }, complete(res) { - formatResponse('ReportSceneError', res); - moduleHelper.send('ReportSceneCallback', JSON.stringify({ + formatResponse(completeType, res); + moduleHelper.send(`${functionName}Callback`, JSON.stringify({ callbackId, type: 'complete', res: JSON.stringify(res), })); }, }); }, - WX_RequestMidasFriendPayment(conf, callbackId) { - const config = formatJsonStr(conf); - wx.requestMidasFriendPayment({ - ...config, - success(res) { - formatResponse('RequestMidasFriendPaymentSuccessCallbackResult', res); - moduleHelper.send('RequestMidasFriendPaymentCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('MidasFriendPaymentError', res); - moduleHelper.send('RequestMidasFriendPaymentCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('MidasFriendPaymentError', res); - moduleHelper.send('RequestMidasFriendPaymentCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); + WX_OneWayNoFunction_v(functionName) { + WX_OneWayNoFunction(functionName); }, - WX_RequestMidasPayment(conf, callbackId) { - const config = formatJsonStr(conf); - wx.requestMidasPayment({ - ...config, - success(res) { - formatResponse('RequestMidasPaymentSuccessCallbackResult', res); - moduleHelper.send('RequestMidasPaymentCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('RequestMidasPaymentFailCallbackErr', res); - moduleHelper.send('RequestMidasPaymentCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('MidasPaymentError', res); - moduleHelper.send('RequestMidasPaymentCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); + WX_OneWayNoFunction_vs(functionName, param1) { + WX_OneWayNoFunction(functionName, param1); }, - WX_RequestMidasPaymentGameItem(conf, callbackId) { - const config = formatJsonStr(conf); - wx.requestMidasPaymentGameItem({ - ...config, - success(res) { - formatResponse('MidasPaymentError', res); - moduleHelper.send('RequestMidasPaymentGameItemCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('MidasPaymentError', res); - moduleHelper.send('RequestMidasPaymentGameItemCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('MidasPaymentError', res); - moduleHelper.send('RequestMidasPaymentGameItemCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); + WX_OneWayNoFunction_vt(functionName, param1) { + const formatParam1 = formatJsonStr(param1); + WX_OneWayNoFunction(functionName, formatParam1); }, - WX_RequestSubscribeMessage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.requestSubscribeMessage({ - ...config, - success(res) { - formatResponse('RequestSubscribeMessageSuccessCallbackResult', res); - moduleHelper.send('RequestSubscribeMessageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('RequestSubscribeMessageFailCallbackResult', res); - moduleHelper.send('RequestSubscribeMessageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RequestSubscribeMessageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); + WX_OneWayNoFunction_vst(functionName, param1, param2) { + const formatParam2 = formatJsonStr(param2); + WX_OneWayNoFunction(functionName, param1, formatParam2); }, - WX_RequestSubscribeSystemMessage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.requestSubscribeSystemMessage({ - ...config, - success(res) { - formatResponse('RequestSubscribeSystemMessageSuccessCallbackResult', res); - moduleHelper.send('RequestSubscribeSystemMessageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('RequestSubscribeMessageFailCallbackResult', res); - moduleHelper.send('RequestSubscribeSystemMessageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RequestSubscribeSystemMessageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); + WX_OneWayNoFunction_vsn(functionName, param1, param2) { + WX_OneWayNoFunction(functionName, param1, param2); }, - WX_RequirePrivacyAuthorize(conf, callbackId) { - const config = formatJsonStr(conf); - wx.requirePrivacyAuthorize({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RequirePrivacyAuthorizeCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RequirePrivacyAuthorizeCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RequirePrivacyAuthorizeCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); + WX_OneWayNoFunction_vnns(functionName, param1, param2, param3) { + WX_OneWayNoFunction(functionName, param1, param2, param3); }, - WX_RestartMiniProgram(conf, callbackId) { - const config = formatJsonStr(conf); - wx.restartMiniProgram({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RestartMiniProgramCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RestartMiniProgramCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RestartMiniProgramCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SaveFileToDisk(conf, callbackId) { - const config = formatJsonStr(conf); - wx.saveFileToDisk({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SaveFileToDiskCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SaveFileToDiskCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SaveFileToDiskCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SaveImageToPhotosAlbum(conf, callbackId) { - const config = formatJsonStr(conf); - wx.saveImageToPhotosAlbum({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SaveImageToPhotosAlbumCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SaveImageToPhotosAlbumCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SaveImageToPhotosAlbumCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ScanCode(conf, callbackId) { - const config = formatJsonStr(conf); - wx.scanCode({ - ...config, - success(res) { - formatResponse('ScanCodeSuccessCallbackResult', res); - moduleHelper.send('ScanCodeCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ScanCodeCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ScanCodeCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetBLEMTU(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setBLEMTU({ - ...config, - success(res) { - formatResponse('SetBLEMTUSuccessCallbackResult', res); - moduleHelper.send('SetBLEMTUCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('SetBLEMTUFailCallbackResult', res); - moduleHelper.send('SetBLEMTUCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetBLEMTUCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetBackgroundFetchToken(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setBackgroundFetchToken({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetBackgroundFetchTokenCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetBackgroundFetchTokenCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetBackgroundFetchTokenCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetClipboardData(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setClipboardData({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetClipboardDataCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetClipboardDataCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetClipboardDataCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetDeviceOrientation(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setDeviceOrientation({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetDeviceOrientationCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetDeviceOrientationCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetDeviceOrientationCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetEnableDebug(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setEnableDebug({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetEnableDebugCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetEnableDebugCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetEnableDebugCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetInnerAudioOption(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setInnerAudioOption({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetInnerAudioOptionCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetInnerAudioOptionCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetInnerAudioOptionCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetKeepScreenOn(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setKeepScreenOn({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetKeepScreenOnCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetKeepScreenOnCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetKeepScreenOnCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetMenuStyle(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setMenuStyle({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetMenuStyleCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetMenuStyleCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetMenuStyleCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetScreenBrightness(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setScreenBrightness({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetScreenBrightnessCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetScreenBrightnessCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetScreenBrightnessCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetStatusBarStyle(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setStatusBarStyle({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetStatusBarStyleCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetStatusBarStyleCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetStatusBarStyleCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetUserCloudStorage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setUserCloudStorage({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetUserCloudStorageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetUserCloudStorageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetUserCloudStorageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_SetVisualEffectOnCapture(conf, callbackId) { - const config = formatJsonStr(conf); - wx.setVisualEffectOnCapture({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetVisualEffectOnCaptureCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetVisualEffectOnCaptureCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('SetVisualEffectOnCaptureCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ShowActionSheet(conf, callbackId) { - const config = formatJsonStr(conf); - wx.showActionSheet({ - ...config, - success(res) { - formatResponse('ShowActionSheetSuccessCallbackResult', res); - moduleHelper.send('ShowActionSheetCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowActionSheetCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowActionSheetCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ShowKeyboard(conf, callbackId) { - const config = formatJsonStr(conf); - wx.showKeyboard({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowKeyboardCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowKeyboardCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowKeyboardCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ShowLoading(conf, callbackId) { - const config = formatJsonStr(conf); - wx.showLoading({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowLoadingCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowLoadingCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowLoadingCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ShowModal(conf, callbackId) { - const config = formatJsonStr(conf); - wx.showModal({ - ...config, - success(res) { - formatResponse('ShowModalSuccessCallbackResult', res); - moduleHelper.send('ShowModalCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowModalCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowModalCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ShowShareImageMenu(conf, callbackId) { - const config = formatJsonStr(conf); - wx.showShareImageMenu({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowShareImageMenuCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowShareImageMenuCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowShareImageMenuCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ShowShareMenu(conf, callbackId) { - const config = formatJsonStr(conf); - wx.showShareMenu({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowShareMenuCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowShareMenuCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowShareMenuCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ShowToast(conf, callbackId) { - const config = formatJsonStr(conf); - wx.showToast({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowToastCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowToastCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('ShowToastCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StartAccelerometer(conf, callbackId) { - const config = formatJsonStr(conf); - wx.startAccelerometer({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartAccelerometerCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartAccelerometerCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartAccelerometerCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StartBeaconDiscovery(conf, callbackId) { - const config = formatJsonStr(conf); - wx.startBeaconDiscovery({ - ...config, - success(res) { - formatResponse('BeaconError', res); - moduleHelper.send('StartBeaconDiscoveryCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BeaconError', res); - moduleHelper.send('StartBeaconDiscoveryCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BeaconError', res); - moduleHelper.send('StartBeaconDiscoveryCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StartBluetoothDevicesDiscovery(conf, callbackId) { - const config = formatJsonStr(conf); - wx.startBluetoothDevicesDiscovery({ - ...config, - success(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('StartBluetoothDevicesDiscoveryCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('StartBluetoothDevicesDiscoveryCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('StartBluetoothDevicesDiscoveryCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StartCompass(conf, callbackId) { - const config = formatJsonStr(conf); - wx.startCompass({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartCompassCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartCompassCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartCompassCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StartDeviceMotionListening(conf, callbackId) { - const config = formatJsonStr(conf); - wx.startDeviceMotionListening({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartDeviceMotionListeningCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartDeviceMotionListeningCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartDeviceMotionListeningCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StopAccelerometer(conf, callbackId) { - const config = formatJsonStr(conf); - wx.stopAccelerometer({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopAccelerometerCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopAccelerometerCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopAccelerometerCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StopBeaconDiscovery(conf, callbackId) { - const config = formatJsonStr(conf); - wx.stopBeaconDiscovery({ - ...config, - success(res) { - formatResponse('BeaconError', res); - moduleHelper.send('StopBeaconDiscoveryCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BeaconError', res); - moduleHelper.send('StopBeaconDiscoveryCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BeaconError', res); - moduleHelper.send('StopBeaconDiscoveryCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StopBluetoothDevicesDiscovery(conf, callbackId) { - const config = formatJsonStr(conf); - wx.stopBluetoothDevicesDiscovery({ - ...config, - success(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('StopBluetoothDevicesDiscoveryCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('StopBluetoothDevicesDiscoveryCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('StopBluetoothDevicesDiscoveryCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StopCompass(conf, callbackId) { - const config = formatJsonStr(conf); - wx.stopCompass({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopCompassCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopCompassCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopCompassCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StopDeviceMotionListening(conf, callbackId) { - const config = formatJsonStr(conf); - wx.stopDeviceMotionListening({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopDeviceMotionListeningCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopDeviceMotionListeningCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopDeviceMotionListeningCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StopFaceDetect(conf, callbackId) { - const config = formatJsonStr(conf); - wx.stopFaceDetect({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopFaceDetectCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopFaceDetectCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StopFaceDetectCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_UpdateKeyboard(conf, callbackId) { - const config = formatJsonStr(conf); - wx.updateKeyboard({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateKeyboardCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateKeyboardCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateKeyboardCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_UpdateShareMenu(conf, callbackId) { - const config = formatJsonStr(conf); - wx.updateShareMenu({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateShareMenuCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateShareMenuCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateShareMenuCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_UpdateVoIPChatMuteConfig(conf, callbackId) { - const config = formatJsonStr(conf); - wx.updateVoIPChatMuteConfig({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateVoIPChatMuteConfigCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateVoIPChatMuteConfigCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateVoIPChatMuteConfigCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_UpdateWeChatApp(conf, callbackId) { - const config = formatJsonStr(conf); - wx.updateWeChatApp({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateWeChatAppCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateWeChatAppCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('UpdateWeChatAppCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_VibrateLong(conf, callbackId) { - const config = formatJsonStr(conf); - wx.vibrateLong({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('VibrateLongCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('VibrateLongCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('VibrateLongCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_VibrateShort(conf, callbackId) { - const config = formatJsonStr(conf); - wx.vibrateShort({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('VibrateShortCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('VibrateShortFailCallbackResult', res); - moduleHelper.send('VibrateShortCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('VibrateShortCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_WriteBLECharacteristicValue(conf, callbackId) { - const config = formatJsonStr(conf); - wx.writeBLECharacteristicValue({ - ...config, - success(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('WriteBLECharacteristicValueCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('WriteBLECharacteristicValueCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('BluetoothError', res); - moduleHelper.send('WriteBLECharacteristicValueCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_StartGameLive(conf, callbackId) { - const config = formatJsonStr(conf); - wx.startGameLive({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartGameLiveCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartGameLiveCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('StartGameLiveCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_CheckGameLiveEnabled(conf, callbackId) { - const config = formatJsonStr(conf); - wx.checkGameLiveEnabled({ - ...config, - success(res) { - formatResponse('CheckGameLiveEnabledSuccessCallbackOption', res); - moduleHelper.send('CheckGameLiveEnabledCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CheckGameLiveEnabledCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('CheckGameLiveEnabledCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetUserCurrentGameliveInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getUserCurrentGameliveInfo({ - ...config, - success(res) { - formatResponse('GetUserCurrentGameliveInfoSuccessCallbackOption', res); - moduleHelper.send('GetUserCurrentGameliveInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetUserCurrentGameliveInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetUserCurrentGameliveInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetUserRecentGameLiveInfo(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getUserRecentGameLiveInfo({ - ...config, - success(res) { - formatResponse('GetUserGameLiveDetailsSuccessCallbackOption', res); - moduleHelper.send('GetUserRecentGameLiveInfoCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetUserRecentGameLiveInfoCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetUserRecentGameLiveInfoCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_GetUserGameLiveDetails(conf, callbackId) { - const config = formatJsonStr(conf); - wx.getUserGameLiveDetails({ - ...config, - success(res) { - formatResponse('GetUserGameLiveDetailsSuccessCallbackOption', res); - moduleHelper.send('GetUserGameLiveDetailsCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetUserGameLiveDetailsCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('GetUserGameLiveDetailsCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenChannelsLiveCollection(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openChannelsLiveCollection({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsLiveCollectionCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsLiveCollectionCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenChannelsLiveCollectionCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenPage(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openPage({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenPageCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenPageCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenPageCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_RequestSubscribeLiveActivity(conf, callbackId) { - const config = formatJsonStr(conf); - wx.requestSubscribeLiveActivity({ - ...config, - success(res) { - formatResponse('RequestSubscribeLiveActivitySuccessCallbackResult', res); - moduleHelper.send('RequestSubscribeLiveActivityCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RequestSubscribeLiveActivityCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('RequestSubscribeLiveActivityCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_OpenBusinessView(conf, callbackId) { - const config = formatJsonStr(conf); - wx.openBusinessView({ - ...config, - success(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenBusinessViewCallback', JSON.stringify({ - callbackId, type: 'success', res: JSON.stringify(res), - })); - }, - fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenBusinessViewCallback', JSON.stringify({ - callbackId, type: 'fail', res: JSON.stringify(res), - })); - }, - complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('OpenBusinessViewCallback', JSON.stringify({ - callbackId, type: 'complete', res: JSON.stringify(res), - })); - }, - }); - }, - WX_ExitPointerLock() { - wx.exitPointerLock(); - }, - WX_OperateGameRecorderVideo(option) { - wx.operateGameRecorderVideo(formatJsonStr(option)); - }, - WX_RemoveStorageSync(key) { - wx.removeStorageSync(key); - }, - WX_ReportEvent(eventId, data) { - wx.reportEvent(eventId, formatJsonStr(data)); - }, - WX_ReportPerformance(id, value, dimensions) { - wx.reportPerformance(id, value, dimensions); - }, - WX_ReportUserBehaviorBranchAnalytics(option) { - wx.reportUserBehaviorBranchAnalytics(formatJsonStr(option)); - }, - WX_RequestPointerLock() { - wx.requestPointerLock(); - }, - WX_ReserveChannelsLive(option) { - wx.reserveChannelsLive(formatJsonStr(option)); - }, - WX_RevokeBufferURL(url) { - wx.revokeBufferURL(url); - }, - WX_SetPreferredFramesPerSecond(fps) { - wx.setPreferredFramesPerSecond(fps); - }, - WX_SetStorageSync(key, data) { - wx.setStorageSync(key, formatJsonStr(data)); - }, - WX_ShareAppMessage(option) { - wx.shareAppMessage(formatJsonStr(option)); - }, - WX_TriggerGC() { - wx.triggerGC(); - }, - WX_OnAccelerometerChange() { - if (!OnAccelerometerChangeList) { - OnAccelerometerChangeList = []; + WX_OnEventRegister(functionName, resType) { + if (!onEventLists[functionName]) { + onEventLists[functionName] = []; } const callback = (res) => { - formatResponse('OnAccelerometerChangeListenerResult', res); + formatResponse(resType, res); const resStr = stringifyRes(res); - moduleHelper.send('_OnAccelerometerChangeCallback', resStr); + moduleHelper.send(`_${functionName}Callback`, resStr); }; - OnAccelerometerChangeList.push(callback); - wx.onAccelerometerChange(callback); + onEventLists[functionName].push(callback); + wx[functionName.replace(/^\w/, a => a.toLowerCase())](callback); }, - WX_OffAccelerometerChange() { - (OnAccelerometerChangeList || []).forEach((v) => { - wx.offAccelerometerChange(v); - }); - }, - WX_OnAudioInterruptionBegin() { - if (!OnAudioInterruptionBeginList) { - OnAudioInterruptionBeginList = []; - } - const callback = (res) => { - formatResponse('GeneralCallbackResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnAudioInterruptionBeginCallback', resStr); - }; - OnAudioInterruptionBeginList.push(callback); - wx.onAudioInterruptionBegin(callback); - }, - WX_OffAudioInterruptionBegin() { - (OnAudioInterruptionBeginList || []).forEach((v) => { - wx.offAudioInterruptionBegin(v); - }); - }, - WX_OnAudioInterruptionEnd() { - if (!OnAudioInterruptionEndList) { - OnAudioInterruptionEndList = []; - } - const callback = (res) => { - formatResponse('GeneralCallbackResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnAudioInterruptionEndCallback', resStr); - }; - OnAudioInterruptionEndList.push(callback); - wx.onAudioInterruptionEnd(callback); - }, - WX_OffAudioInterruptionEnd() { - (OnAudioInterruptionEndList || []).forEach((v) => { - wx.offAudioInterruptionEnd(v); - }); - }, - WX_OnBLEConnectionStateChange() { - if (!OnBLEConnectionStateChangeList) { - OnBLEConnectionStateChangeList = []; - } - const callback = (res) => { - formatResponse('OnBLEConnectionStateChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnBLEConnectionStateChangeCallback', resStr); - }; - OnBLEConnectionStateChangeList.push(callback); - wx.onBLEConnectionStateChange(callback); - }, - WX_OffBLEConnectionStateChange() { - (OnBLEConnectionStateChangeList || []).forEach((v) => { - wx.offBLEConnectionStateChange(v); - }); - }, - WX_OnBLEMTUChange() { - if (!OnBLEMTUChangeList) { - OnBLEMTUChangeList = []; - } - const callback = (res) => { - formatResponse('OnBLEMTUChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnBLEMTUChangeCallback', resStr); - }; - OnBLEMTUChangeList.push(callback); - wx.onBLEMTUChange(callback); - }, - WX_OffBLEMTUChange() { - (OnBLEMTUChangeList || []).forEach((v) => { - wx.offBLEMTUChange(v); - }); - }, - WX_OnBLEPeripheralConnectionStateChanged() { - if (!OnBLEPeripheralConnectionStateChangedList) { - OnBLEPeripheralConnectionStateChangedList = []; - } - const callback = (res) => { - formatResponse('OnBLEPeripheralConnectionStateChangedListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnBLEPeripheralConnectionStateChangedCallback', resStr); - }; - OnBLEPeripheralConnectionStateChangedList.push(callback); - wx.onBLEPeripheralConnectionStateChanged(callback); - }, - WX_OffBLEPeripheralConnectionStateChanged() { - (OnBLEPeripheralConnectionStateChangedList || []).forEach((v) => { - wx.offBLEPeripheralConnectionStateChanged(v); - }); - }, - WX_OnBackgroundFetchData() { - const callback = (res) => { - formatResponse('OnBackgroundFetchDataListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnBackgroundFetchDataCallback', resStr); - }; - wx.onBackgroundFetchData(callback); - }, - WX_OnBeaconServiceChange() { - if (!OnBeaconServiceChangeList) { - OnBeaconServiceChangeList = []; - } - const callback = (res) => { - formatResponse('OnBeaconServiceChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnBeaconServiceChangeCallback', resStr); - }; - OnBeaconServiceChangeList.push(callback); - wx.onBeaconServiceChange(callback); - }, - WX_OffBeaconServiceChange() { - (OnBeaconServiceChangeList || []).forEach((v) => { - wx.offBeaconServiceChange(v); - }); - }, - WX_OnBeaconUpdate() { - if (!OnBeaconUpdateList) { - OnBeaconUpdateList = []; - } - const callback = (res) => { - formatResponse('OnBeaconUpdateListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnBeaconUpdateCallback', resStr); - }; - OnBeaconUpdateList.push(callback); - wx.onBeaconUpdate(callback); - }, - WX_OffBeaconUpdate() { - (OnBeaconUpdateList || []).forEach((v) => { - wx.offBeaconUpdate(v); - }); - }, - WX_OnBluetoothAdapterStateChange() { - if (!OnBluetoothAdapterStateChangeList) { - OnBluetoothAdapterStateChangeList = []; - } - const callback = (res) => { - formatResponse('OnBluetoothAdapterStateChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnBluetoothAdapterStateChangeCallback', resStr); - }; - OnBluetoothAdapterStateChangeList.push(callback); - wx.onBluetoothAdapterStateChange(callback); - }, - WX_OffBluetoothAdapterStateChange() { - (OnBluetoothAdapterStateChangeList || []).forEach((v) => { - wx.offBluetoothAdapterStateChange(v); - }); - }, - WX_OnBluetoothDeviceFound() { - if (!OnBluetoothDeviceFoundList) { - OnBluetoothDeviceFoundList = []; - } - const callback = (res) => { - formatResponse('OnBluetoothDeviceFoundListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnBluetoothDeviceFoundCallback', resStr); - }; - OnBluetoothDeviceFoundList.push(callback); - wx.onBluetoothDeviceFound(callback); - }, - WX_OffBluetoothDeviceFound() { - (OnBluetoothDeviceFoundList || []).forEach((v) => { - wx.offBluetoothDeviceFound(v); - }); - }, - WX_OnCompassChange() { - if (!OnCompassChangeList) { - OnCompassChangeList = []; - } - const callback = (res) => { - formatResponse('OnCompassChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnCompassChangeCallback', resStr); - }; - OnCompassChangeList.push(callback); - wx.onCompassChange(callback); - }, - WX_OffCompassChange() { - (OnCompassChangeList || []).forEach((v) => { - wx.offCompassChange(v); - }); - }, - WX_OnDeviceMotionChange() { - if (!OnDeviceMotionChangeList) { - OnDeviceMotionChangeList = []; - } - const callback = (res) => { - formatResponse('OnDeviceMotionChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnDeviceMotionChangeCallback', resStr); - }; - OnDeviceMotionChangeList.push(callback); - wx.onDeviceMotionChange(callback); - }, - WX_OffDeviceMotionChange() { - (OnDeviceMotionChangeList || []).forEach((v) => { - wx.offDeviceMotionChange(v); - }); - }, - WX_OnDeviceOrientationChange() { - if (!OnDeviceOrientationChangeList) { - OnDeviceOrientationChangeList = []; - } - const callback = (res) => { - formatResponse('OnDeviceOrientationChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnDeviceOrientationChangeCallback', resStr); - }; - OnDeviceOrientationChangeList.push(callback); - wx.onDeviceOrientationChange(callback); - }, - WX_OffDeviceOrientationChange() { - (OnDeviceOrientationChangeList || []).forEach((v) => { - wx.offDeviceOrientationChange(v); - }); - }, - WX_OnError() { - if (!OnErrorList) { - OnErrorList = []; - } - const callback = (res) => { - formatResponse('Error', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnErrorCallback', resStr); - }; - OnErrorList.push(callback); - wx.onError(callback); - }, - WX_OffError() { - (OnErrorList || []).forEach((v) => { - wx.offError(v); - }); - }, - WX_OnHide() { - if (!OnHideList) { - OnHideList = []; - } - const callback = (res) => { - formatResponse('GeneralCallbackResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnHideCallback', resStr); - }; - OnHideList.push(callback); - wx.onHide(callback); - }, - WX_OffHide() { - (OnHideList || []).forEach((v) => { - wx.offHide(v); - }); - }, - WX_OnInteractiveStorageModified() { - if (!OnInteractiveStorageModifiedList) { - OnInteractiveStorageModifiedList = []; - } - const callback = (res) => { - const resStr = res; - moduleHelper.send('_OnInteractiveStorageModifiedCallback', resStr); - }; - OnInteractiveStorageModifiedList.push(callback); - wx.onInteractiveStorageModified(callback); - }, - WX_OffInteractiveStorageModified() { - (OnInteractiveStorageModifiedList || []).forEach((v) => { - wx.offInteractiveStorageModified(v); - }); - }, - WX_OnKeyDown() { - if (!OnKeyDownList) { - OnKeyDownList = []; - } - const callback = (res) => { - formatResponse('OnKeyDownListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnKeyDownCallback', resStr); - }; - OnKeyDownList.push(callback); - wx.onKeyDown(callback); - }, - WX_OffKeyDown() { - (OnKeyDownList || []).forEach((v) => { - wx.offKeyDown(v); - }); - }, - WX_OnKeyUp() { - if (!OnKeyUpList) { - OnKeyUpList = []; - } - const callback = (res) => { - formatResponse('OnKeyDownListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnKeyUpCallback', resStr); - }; - OnKeyUpList.push(callback); - wx.onKeyUp(callback); - }, - WX_OffKeyUp() { - (OnKeyUpList || []).forEach((v) => { - wx.offKeyUp(v); - }); - }, - WX_OnKeyboardComplete() { - if (!OnKeyboardCompleteList) { - OnKeyboardCompleteList = []; - } - const callback = (res) => { - formatResponse('OnKeyboardInputListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnKeyboardCompleteCallback', resStr); - }; - OnKeyboardCompleteList.push(callback); - wx.onKeyboardComplete(callback); - }, - WX_OffKeyboardComplete() { - (OnKeyboardCompleteList || []).forEach((v) => { - wx.offKeyboardComplete(v); - }); - }, - WX_OnKeyboardConfirm() { - if (!OnKeyboardConfirmList) { - OnKeyboardConfirmList = []; - } - const callback = (res) => { - formatResponse('OnKeyboardInputListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnKeyboardConfirmCallback', resStr); - }; - OnKeyboardConfirmList.push(callback); - wx.onKeyboardConfirm(callback); - }, - WX_OffKeyboardConfirm() { - (OnKeyboardConfirmList || []).forEach((v) => { - wx.offKeyboardConfirm(v); - }); - }, - WX_OnKeyboardHeightChange() { - if (!OnKeyboardHeightChangeList) { - OnKeyboardHeightChangeList = []; - } - const callback = (res) => { - formatResponse('OnKeyboardHeightChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnKeyboardHeightChangeCallback', resStr); - }; - OnKeyboardHeightChangeList.push(callback); - wx.onKeyboardHeightChange(callback); - }, - WX_OffKeyboardHeightChange() { - (OnKeyboardHeightChangeList || []).forEach((v) => { - wx.offKeyboardHeightChange(v); - }); - }, - WX_OnKeyboardInput() { - if (!OnKeyboardInputList) { - OnKeyboardInputList = []; - } - const callback = (res) => { - formatResponse('OnKeyboardInputListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnKeyboardInputCallback', resStr); - }; - OnKeyboardInputList.push(callback); - wx.onKeyboardInput(callback); - }, - WX_OffKeyboardInput() { - (OnKeyboardInputList || []).forEach((v) => { - wx.offKeyboardInput(v); - }); - }, - WX_OnMemoryWarning() { - if (!OnMemoryWarningList) { - OnMemoryWarningList = []; - } - const callback = (res) => { - formatResponse('OnMemoryWarningListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnMemoryWarningCallback', resStr); - }; - OnMemoryWarningList.push(callback); - wx.onMemoryWarning(callback); - }, - WX_OffMemoryWarning() { - (OnMemoryWarningList || []).forEach((v) => { - wx.offMemoryWarning(v); - }); - }, - WX_OnMenuButtonBoundingClientRectWeightChange() { - if (!OnMenuButtonBoundingClientRectWeightChangeList) { - OnMenuButtonBoundingClientRectWeightChangeList = []; - } - const callback = (res) => { - formatResponse('OnMenuButtonBoundingClientRectWeightChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnMenuButtonBoundingClientRectWeightChangeCallback', resStr); - }; - OnMenuButtonBoundingClientRectWeightChangeList.push(callback); - wx.onMenuButtonBoundingClientRectWeightChange(callback); - }, - WX_OffMenuButtonBoundingClientRectWeightChange() { - (OnMenuButtonBoundingClientRectWeightChangeList || []).forEach((v) => { - wx.offMenuButtonBoundingClientRectWeightChange(v); - }); - }, - WX_OnMessage() { - const callback = (res) => { - const resStr = res; - moduleHelper.send('_OnMessageCallback', resStr); - }; - wx.onMessage(callback); - }, - WX_OnMouseDown() { - if (!OnMouseDownList) { - OnMouseDownList = []; - } - const callback = (res) => { - formatResponse('OnMouseDownListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnMouseDownCallback', resStr); - }; - OnMouseDownList.push(callback); - wx.onMouseDown(callback); - }, - WX_OffMouseDown() { - (OnMouseDownList || []).forEach((v) => { - wx.offMouseDown(v); - }); - }, - WX_OnMouseMove() { - if (!OnMouseMoveList) { - OnMouseMoveList = []; - } - const callback = (res) => { - formatResponse('OnMouseMoveListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnMouseMoveCallback', resStr); - }; - OnMouseMoveList.push(callback); - wx.onMouseMove(callback); - }, - WX_OffMouseMove() { - (OnMouseMoveList || []).forEach((v) => { - wx.offMouseMove(v); - }); - }, - WX_OnMouseUp() { - if (!OnMouseUpList) { - OnMouseUpList = []; - } - const callback = (res) => { - formatResponse('OnMouseDownListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnMouseUpCallback', resStr); - }; - OnMouseUpList.push(callback); - wx.onMouseUp(callback); - }, - WX_OffMouseUp() { - (OnMouseUpList || []).forEach((v) => { - wx.offMouseUp(v); - }); - }, - WX_OnNetworkStatusChange() { - if (!OnNetworkStatusChangeList) { - OnNetworkStatusChangeList = []; - } - const callback = (res) => { - formatResponse('OnNetworkStatusChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnNetworkStatusChangeCallback', resStr); - }; - OnNetworkStatusChangeList.push(callback); - wx.onNetworkStatusChange(callback); - }, - WX_OffNetworkStatusChange() { - (OnNetworkStatusChangeList || []).forEach((v) => { - wx.offNetworkStatusChange(v); - }); - }, - WX_OnNetworkWeakChange() { - if (!OnNetworkWeakChangeList) { - OnNetworkWeakChangeList = []; - } - const callback = (res) => { - formatResponse('OnNetworkWeakChangeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnNetworkWeakChangeCallback', resStr); - }; - OnNetworkWeakChangeList.push(callback); - wx.onNetworkWeakChange(callback); - }, - WX_OffNetworkWeakChange() { - (OnNetworkWeakChangeList || []).forEach((v) => { - wx.offNetworkWeakChange(v); - }); - }, - WX_OnScreenRecordingStateChanged() { - if (!OnScreenRecordingStateChangedList) { - OnScreenRecordingStateChangedList = []; - } - const callback = (res) => { - formatResponse('OnScreenRecordingStateChangedListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnScreenRecordingStateChangedCallback', resStr); - }; - OnScreenRecordingStateChangedList.push(callback); - wx.onScreenRecordingStateChanged(callback); - }, - WX_OffScreenRecordingStateChanged() { - (OnScreenRecordingStateChangedList || []).forEach((v) => { - wx.offScreenRecordingStateChanged(v); - }); - }, - WX_OnShareMessageToFriend() { - const callback = (res) => { - formatResponse('OnShareMessageToFriendListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnShareMessageToFriendCallback', resStr); - }; - wx.onShareMessageToFriend(callback); - }, - WX_OnShow() { - if (!OnShowList) { - OnShowList = []; - } - const callback = (res) => { - formatResponse('OnShowListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnShowCallback', resStr); - }; - OnShowList.push(callback); - wx.onShow(callback); - }, - WX_OffShow() { - (OnShowList || []).forEach((v) => { - wx.offShow(v); - }); - }, - WX_OnUnhandledRejection() { - if (!OnUnhandledRejectionList) { - OnUnhandledRejectionList = []; - } - const callback = (res) => { - formatResponse('OnUnhandledRejectionListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnUnhandledRejectionCallback', resStr); - }; - OnUnhandledRejectionList.push(callback); - wx.onUnhandledRejection(callback); - }, - WX_OffUnhandledRejection() { - (OnUnhandledRejectionList || []).forEach((v) => { - wx.offUnhandledRejection(v); - }); - }, - WX_OnUserCaptureScreen() { - if (!OnUserCaptureScreenList) { - OnUserCaptureScreenList = []; - } - const callback = (res) => { - formatResponse('OnUserCaptureScreenListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnUserCaptureScreenCallback', resStr); - }; - OnUserCaptureScreenList.push(callback); - wx.onUserCaptureScreen(callback); - }, - WX_OffUserCaptureScreen() { - (OnUserCaptureScreenList || []).forEach((v) => { - wx.offUserCaptureScreen(v); - }); - }, - WX_OnVoIPChatInterrupted() { - if (!OnVoIPChatInterruptedList) { - OnVoIPChatInterruptedList = []; - } - const callback = (res) => { - formatResponse('OnVoIPChatInterruptedListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnVoIPChatInterruptedCallback', resStr); - }; - OnVoIPChatInterruptedList.push(callback); - wx.onVoIPChatInterrupted(callback); - }, - WX_OffVoIPChatInterrupted() { - (OnVoIPChatInterruptedList || []).forEach((v) => { - wx.offVoIPChatInterrupted(v); - }); - }, - WX_OnVoIPChatMembersChanged() { - if (!OnVoIPChatMembersChangedList) { - OnVoIPChatMembersChangedList = []; - } - const callback = (res) => { - formatResponse('OnVoIPChatMembersChangedListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnVoIPChatMembersChangedCallback', resStr); - }; - OnVoIPChatMembersChangedList.push(callback); - wx.onVoIPChatMembersChanged(callback); - }, - WX_OffVoIPChatMembersChanged() { - (OnVoIPChatMembersChangedList || []).forEach((v) => { - wx.offVoIPChatMembersChanged(v); - }); - }, - WX_OnVoIPChatSpeakersChanged() { - if (!OnVoIPChatSpeakersChangedList) { - OnVoIPChatSpeakersChangedList = []; - } - const callback = (res) => { - formatResponse('OnVoIPChatSpeakersChangedListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnVoIPChatSpeakersChangedCallback', resStr); - }; - OnVoIPChatSpeakersChangedList.push(callback); - wx.onVoIPChatSpeakersChanged(callback); - }, - WX_OffVoIPChatSpeakersChanged() { - (OnVoIPChatSpeakersChangedList || []).forEach((v) => { - wx.offVoIPChatSpeakersChanged(v); - }); - }, - WX_OnVoIPChatStateChanged() { - if (!OnVoIPChatStateChangedList) { - OnVoIPChatStateChangedList = []; - } - const callback = (res) => { - formatResponse('OnVoIPChatStateChangedListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnVoIPChatStateChangedCallback', resStr); - }; - OnVoIPChatStateChangedList.push(callback); - wx.onVoIPChatStateChanged(callback); - }, - WX_OffVoIPChatStateChanged() { - (OnVoIPChatStateChangedList || []).forEach((v) => { - wx.offVoIPChatStateChanged(v); - }); - }, - WX_OnWheel() { - if (!OnWheelList) { - OnWheelList = []; - } - const callback = (res) => { - formatResponse('OnWheelListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnWheelCallback', resStr); - }; - OnWheelList.push(callback); - wx.onWheel(callback); - }, - WX_OffWheel() { - (OnWheelList || []).forEach((v) => { - wx.offWheel(v); - }); - }, - WX_OnWindowResize() { - if (!OnWindowResizeList) { - OnWindowResizeList = []; - } - const callback = (res) => { - formatResponse('OnWindowResizeListenerResult', res); - const resStr = stringifyRes(res); - moduleHelper.send('_OnWindowResizeCallback', resStr); - }; - OnWindowResizeList.push(callback); - wx.onWindowResize(callback); - }, - WX_OffWindowResize() { - (OnWindowResizeList || []).forEach((v) => { - wx.offWindowResize(v); + WX_OffEventRegister(functionName) { + (onEventLists[functionName] || []).forEach((v) => { + wx[functionName.replace(/^On/, 'off')](v); }); }, WX_OnAddToFavorites() { @@ -4133,219 +219,90 @@ export default { WX_OffGameLiveStateChange() { wx.offGameLiveStateChange(); }, - WX_SetHandoffQuery(query) { - const res = wx.setHandoffQuery(formatJsonStr(query)); + WX_SyncFunction_bs(functionName, param1) { + const res = WX_SyncFunction(functionName, param1); return res; }, - WX_GetAccountInfoSync() { - const res = wx.getAccountInfoSync(); - formatResponse('AccountInfo', res); + WX_SyncFunction_t(functionName, returnType) { + const res = WX_SyncFunction(functionName); + if (onlyReadyResponse.includes(functionName.replace(/^\w/, a => a.toLowerCase()))) { + formatResponse(returnType, JSON.parse(JSON.stringify(res))); + return JSON.stringify(res); + } + formatResponse(returnType, res); return JSON.stringify(res); }, - WX_GetAppAuthorizeSetting() { - const res = wx.getAppAuthorizeSetting(); - formatResponse('AppAuthorizeSetting', JSON.parse(JSON.stringify(res))); + WX_SyncFunction_tt(functionName, returnType, param1) { + const res = WX_SyncFunction(functionName, formatJsonStr(param1)); + formatResponse(returnType, res); return JSON.stringify(res); }, - WX_GetAppBaseInfo() { - const res = wx.getAppBaseInfo(); - formatResponse('AppBaseInfo', res); - return JSON.stringify(res); - }, - WX_GetBatteryInfoSync() { - const res = wx.getBatteryInfoSync(); - formatResponse('GetBatteryInfoSyncResult', res); - return JSON.stringify(res); - }, - WX_GetDeviceInfo() { - const res = wx.getDeviceInfo(); - formatResponse('DeviceInfo', res); - return JSON.stringify(res); - }, - WX_GetEnterOptionsSync() { - const res = wx.getEnterOptionsSync(); - formatResponse('EnterOptionsGame', res); - return JSON.stringify(res); - }, - WX_GetExptInfoSync(keys) { - const res = wx.getExptInfoSync(formatJsonStr(keys)); - formatResponse('IAnyObject', res); - return JSON.stringify(res); - }, - WX_GetExtConfigSync() { - const res = wx.getExtConfigSync(); - formatResponse('IAnyObject', res); - return JSON.stringify(res); - }, - WX_GetLaunchOptionsSync() { - const res = wx.getLaunchOptionsSync(); - formatResponse('LaunchOptionsGame', res); - return JSON.stringify(res); - }, - WX_GetMenuButtonBoundingClientRect() { - const res = wx.getMenuButtonBoundingClientRect(); - formatResponse('ClientRect', res); - return JSON.stringify(res); - }, - WX_GetStorageInfoSync() { - const res = wx.getStorageInfoSync(); - formatResponse('GetStorageInfoSyncOption', res); - return JSON.stringify(res); - }, - WX_GetSystemInfoSync() { - const res = wx.getSystemInfoSync(); - formatResponse('SystemInfo', res); - return JSON.stringify(res); - }, - WX_GetSystemSetting() { - const res = wx.getSystemSetting(); - formatResponse('SystemSetting', JSON.parse(JSON.stringify(res))); - return JSON.stringify(res); - }, - WX_GetWindowInfo() { - const res = wx.getWindowInfo(); - formatResponse('WindowInfo', res); - return JSON.stringify(res); - }, - WX_CreateImageData(width, height) { - const res = wx.createImageData(width, height); - formatResponse('ImageData', res); - return JSON.stringify(res); - }, - WX_CreatePath2D() { - const res = wx.createPath2D(); - formatResponse('Path2D', res); - return JSON.stringify(res); - }, - WX_IsPointerLocked() { - const res = wx.isPointerLocked(); + WX_SyncFunction_b(functionName) { + const res = WX_SyncFunction(functionName); return res; }, - WX_IsVKSupport(version) { - const res = wx.isVKSupport(formatJsonStr(version)); + WX_SyncFunction_bsnn(functionName, param1, param2, param3) { + const res = WX_SyncFunction(functionName, param1, param2, param3); return res; }, - WX_SetCursor(path, x, y) { - const res = wx.setCursor(formatJsonStr(path), x, y); + WX_SyncFunction_bt(functionName, param1) { + const res = WX_SyncFunction(functionName, formatJsonStr(param1)); return res; }, - WX_SetMessageToFriendQuery(option) { - const res = wx.setMessageToFriendQuery(formatJsonStr(option)); + WX_SyncFunction_nt(functionName, param1) { + const res = WX_SyncFunction(functionName, formatJsonStr(param1)); return res; }, - WX_GetTextLineHeight(option) { - const res = wx.getTextLineHeight(formatJsonStr(option)); + WX_SyncFunction_ss(functionName, param1) { + const res = WX_SyncFunction(functionName, param1); return res; }, - WX_LoadFont(path) { - const res = wx.loadFont(formatJsonStr(path)); - return res; - }, - WX_GetGameLiveState() { - const res = wx.getGameLiveState(); - formatResponse('GameLiveState', res); + WX_SyncFunction_tnn(functionName, returnType, param1, param2) { + const res = WX_SyncFunction(functionName, param1, param2); + formatResponse(returnType, res); return JSON.stringify(res); }, - WX_DownloadFile(conf) { + WX_ClassOneWayFunction(functionName, returnType, successType, failType, completeType, conf) { const config = formatJsonStr(conf); const callbackId = uid(); - const obj = wx.downloadFile({ + const obj = wx[functionName.replace(/^\w/, a => a.toLowerCase())]({ ...config, success(res) { - formatResponse('DownloadFileSuccessCallbackResult', res); - moduleHelper.send('DownloadFileCallback', JSON.stringify({ + formatResponse(successType, res); + moduleHelper.send(`${functionName}Callback`, JSON.stringify({ callbackId, type: 'success', res: JSON.stringify(res), })); }, fail(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('DownloadFileCallback', JSON.stringify({ + formatResponse(failType, res); + moduleHelper.send(`${functionName}Callback`, JSON.stringify({ callbackId, type: 'fail', res: JSON.stringify(res), })); }, complete(res) { - formatResponse('GeneralCallbackResult', res); - moduleHelper.send('DownloadFileCallback', JSON.stringify({ + formatResponse(completeType, res); + moduleHelper.send(`${functionName}Callback`, JSON.stringify({ callbackId, type: 'complete', res: JSON.stringify(res), })); }, }); - DownloadTaskList[callbackId] = obj; + if (!ClassLists[returnType]) { + ClassLists[returnType] = {}; + } + ClassLists[returnType][callbackId] = obj; return callbackId; }, - WX_CreateFeedbackButton(option) { - const obj = wx.createFeedbackButton(formatJsonStr(option)); - const key = uid(); - FeedbackButtonList[key] = obj; - return key; - }, - WX_GetLogManager(option) { - const obj = wx.getLogManager(formatJsonStr(option)); - const key = uid(); - LogManagerList[key] = obj; - return key; - }, - WX_GetRealtimeLogManager() { - const obj = wx.getRealtimeLogManager(); - const key = uid(); - RealtimeLogManagerList[key] = obj; - return key; - }, - WX_GetUpdateManager() { - const obj = wx.getUpdateManager(); - const key = uid(); - UpdateManagerList[key] = obj; - return key; - }, - WX_CreateVideoDecoder() { - const obj = wx.createVideoDecoder(); - const key = uid(); - VideoDecoderList[key] = obj; - return key; - }, - WX_DownloadTaskAbort(id) { - const obj = getDownloadTaskObject(id); - if (!obj) { - return; + WX_ClassFunction(functionName, returnType, option) { + const obj = wx[functionName.replace(/^\w/, a => a.toLowerCase())](formatJsonStr(option)); + const id = uid(); + if (!ClassLists[returnType]) { + ClassLists[returnType] = {}; } - obj.abort(); + ClassLists[returnType][id] = obj; + return id; }, - WX_DownloadTaskOffHeadersReceived(id) { - const obj = getDownloadTaskObject(id); - if (!obj) { - return; - } - offEventCallback(wxDownloadTaskHeadersReceivedList, (v) => { - obj.offHeadersReceived(v); - }, id); - }, - WX_DownloadTaskOffProgressUpdate(id) { - const obj = getDownloadTaskObject(id); - if (!obj) { - return; - } - offEventCallback(wxDownloadTaskProgressUpdateList, (v) => { - obj.offProgressUpdate(v); - }, id); - }, - WX_DownloadTaskOnHeadersReceived(id) { - const obj = getDownloadTaskObject(id); - if (!obj) { - return; - } - const callback = onEventCallback(wxDownloadTaskHeadersReceivedList, '_DownloadTaskOnHeadersReceivedCallback', id, id); - obj.onHeadersReceived(callback); - }, - WX_DownloadTaskOnProgressUpdate(id) { - const obj = getDownloadTaskObject(id); - if (!obj) { - return; - } - const callback = onEventCallback(wxDownloadTaskProgressUpdateList, '_DownloadTaskOnProgressUpdateCallback', id, id); - obj.onProgressUpdate(callback); - }, - WXFeedbackButtonSetProperty(id, key, value) { - const obj = getFeedbackButtonObject(id); + WX_ClassSetProperty(className, id, key, value) { + const obj = getClassObject(className, id); if (!obj) { return; } @@ -4362,209 +319,84 @@ export default { obj[key] = value; } }, - WX_FeedbackButtonDestroy(id) { - const obj = getFeedbackButtonObject(id); + WX_ClassOnEventFunction(className, functionName, returnType, id, eventName) { + const obj = getClassObject(className, id); if (!obj) { return; } - obj.destroy(); - }, - WX_FeedbackButtonHide(id) { - const obj = getFeedbackButtonObject(id); - if (!obj) { - return; - } - obj.hide(); - }, - WX_FeedbackButtonOffTap(id) { - const obj = getFeedbackButtonObject(id); - if (!obj) { - return; - } - offEventCallback(wxFeedbackButtonTapList, (v) => { - obj.offTap(v); - }, id); - }, - WX_FeedbackButtonOnTap(id) { - const obj = getFeedbackButtonObject(id); - if (!obj) { - return; - } - const callback = onEventCallback(wxFeedbackButtonTapList, '_FeedbackButtonOnTapCallback', id, id); - obj.onTap(callback); - }, - WX_FeedbackButtonShow(id) { - const obj = getFeedbackButtonObject(id); - if (!obj) { - return; - } - obj.show(); - }, - WX_LogManagerDebug(id, args) { - const obj = getLogManagerObject(id); - if (!obj) { - return; - } - obj.debug(args); - }, - WX_LogManagerInfo(id, args) { - const obj = getLogManagerObject(id); - if (!obj) { - return; - } - obj.info(args); - }, - WX_LogManagerLog(id, args) { - const obj = getLogManagerObject(id); - if (!obj) { - return; - } - obj.log(args); - }, - WX_LogManagerWarn(id, args) { - const obj = getLogManagerObject(id); - if (!obj) { - return; - } - obj.warn(args); - }, - WX_RealtimeLogManagerAddFilterMsg(id, msg) { - const obj = getRealtimeLogManagerObject(id); - if (!obj) { - return; - } - obj.addFilterMsg(msg); - }, - WX_RealtimeLogManagerError(id, args) { - const obj = getRealtimeLogManagerObject(id); - if (!obj) { - return; - } - obj.error(args); - }, - WX_RealtimeLogManagerInfo(id, args) { - const obj = getRealtimeLogManagerObject(id); - if (!obj) { - return; - } - obj.info(args); - }, - WX_RealtimeLogManagerSetFilterMsg(id, msg) { - const obj = getRealtimeLogManagerObject(id); - if (!obj) { - return; - } - obj.setFilterMsg(msg); - }, - WX_RealtimeLogManagerWarn(id, args) { - const obj = getRealtimeLogManagerObject(id); - if (!obj) { - return; - } - obj.warn(args); - }, - WX_UpdateManagerApplyUpdate(id) { - const obj = getUpdateManagerObject(id); - if (!obj) { - return; - } - obj.applyUpdate(); - }, - WX_UpdateManagerOnCheckForUpdate(id) { - const obj = getUpdateManagerObject(id); - if (!obj) { - return; + if (!ClassOnEventLists[className + functionName]) { + ClassOnEventLists[className + functionName] = {}; } const callback = (res) => { - formatResponse('OnCheckForUpdateListenerResult', res); + if (returnType !== 'string') { + formatResponse(returnType, res); + } + if (!eventName) { + // eslint-disable-next-line no-param-reassign + eventName = ''; + } const resStr = JSON.stringify({ - callbackId: id, + callbackId: id + eventName, res: JSON.stringify(res), }); - moduleHelper.send('_UpdateManagerOnCheckForUpdateCallback', resStr); + moduleHelper.send(`_${className}${functionName}Callback`, resStr); }; - obj.onCheckForUpdate(callback); + if (!ClassOnEventLists[className + functionName][id + eventName]) { + ClassOnEventLists[className + functionName][id + eventName] = []; + } + ClassOnEventLists[className + functionName][id + eventName].push(callback); + // WXVideoDecoder OnEvent 不规范 特殊处理 + if (className === 'WXVideoDecoder') { + obj[functionName.replace(/^\w/, a => a.toLowerCase())](eventName, callback); + } + else { + obj[functionName.replace(/^\w/, a => a.toLowerCase())](callback); + } }, - WX_UpdateManagerOnUpdateFailed(id) { - const obj = getUpdateManagerObject(id); + WX_ClassOffEventFunction(className, functionName, id, eventName) { + const obj = getClassObject(className, id); if (!obj) { return; } - const callback = (res) => { - formatResponse('GeneralCallbackResult', res); - const resStr = JSON.stringify({ - callbackId: id, - res: JSON.stringify(res), - }); - moduleHelper.send('_UpdateManagerOnUpdateFailedCallback', resStr); - }; - obj.onUpdateFailed(callback); - }, - WX_UpdateManagerOnUpdateReady(id) { - const obj = getUpdateManagerObject(id); - if (!obj) { + if (!eventName) { + // eslint-disable-next-line no-param-reassign + eventName = ''; + } + // eslint-disable-next-line no-param-reassign + functionName = functionName.replace(/Off/, 'On'); + if (!ClassOnEventLists[className + functionName][id + eventName]) { return; } - const callback = (res) => { - formatResponse('GeneralCallbackResult', res); - const resStr = JSON.stringify({ - callbackId: id, - res: JSON.stringify(res), - }); - moduleHelper.send('_UpdateManagerOnUpdateReadyCallback', resStr); - }; - obj.onUpdateReady(callback); + ClassOnEventLists[className + functionName][id + eventName].forEach((v) => { + + if (className === 'WXVideoDecoder') { + obj[functionName.replace(/^\w/, (a) => a.toLowerCase())](eventName, v); + } + else { + obj[functionName.replace(/^\w/, (a) => a.toLowerCase())](v); + } + }); + delete ClassOnEventLists[className + functionName][id + eventName]; }, - WX_VideoDecoderGetFrameData(id) { - const obj = getVideoDecoderObject(id); - if (!obj) { - return JSON.stringify(formatResponse('FrameDataOptions')); - } - return JSON.stringify(formatResponse('FrameDataOptions', obj.getFrameData(), id)); + WX_ClassOneWayNoFunction_v(className, functionName, id) { + WX_ClassOneWayNoFunction(className, functionName, id); }, - WX_VideoDecoderRemove(id) { - const obj = getVideoDecoderObject(id); - if (!obj) { - return; - } - obj.remove(); + WX_ClassOneWayNoFunction_vs(className, functionName, id, param1) { + WX_ClassOneWayNoFunction(className, functionName, id, param1); }, - WX_VideoDecoderSeek(id, position) { - const obj = getVideoDecoderObject(id); + WX_ClassOneWayNoFunction_t(className, functionName, returnType, id) { + const obj = getClassObject(className, id); if (!obj) { - return; + return JSON.stringify(formatResponse(returnType)); } - obj.seek(position); + const res = obj[functionName.replace(/^\w/, a => a.toLowerCase())](); + return JSON.stringify(formatResponse(returnType, res, id)); }, - WX_VideoDecoderStart(id, option) { - const obj = getVideoDecoderObject(id); - if (!obj) { - return; - } - obj.start(formatJsonStr(option)); + WX_ClassOneWayNoFunction_vt(className, functionName, id, param1) { + const formatParam1 = formatJsonStr(param1); + WX_ClassOneWayNoFunction(className, functionName, id, formatParam1); }, - WX_VideoDecoderStop(id) { - const obj = getVideoDecoderObject(id); - if (!obj) { - return; - } - obj.stop(); - }, - WX_VideoDecoderOff(id, eventName) { - const obj = getVideoDecoderObject(id); - if (!obj) { - return; - } - offEventCallback(wxVideoDecoderList, (v) => { - obj.off(eventName, v); - }, id); - }, - WX_VideoDecoderOn(id, eventName) { - const obj = getVideoDecoderObject(id); - if (!obj) { - return; - } - const callback = onEventCallback(wxVideoDecoderList, '_VideoDecoderOnCallback', id, id + eventName); - obj.on(eventName, callback); + WX_ClassOneWayNoFunction_vn(className, functionName, id, param1) { + WX_ClassOneWayNoFunction(className, functionName, id, param1); }, }; diff --git a/Runtime/wechat-default/unity-sdk/sdk.js.meta b/Runtime/wechat-default/unity-sdk/sdk.js.meta index a7d2b449..7ba4d8bb 100644 --- a/Runtime/wechat-default/unity-sdk/sdk.js.meta +++ b/Runtime/wechat-default/unity-sdk/sdk.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: e37f7a1e880187e4fdf866e356531bce +guid: eedcdccb46592975f6cc969ba8c92d59 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/share.js.meta b/Runtime/wechat-default/unity-sdk/share.js.meta index eb1b0dd5..e1553e55 100644 --- a/Runtime/wechat-default/unity-sdk/share.js.meta +++ b/Runtime/wechat-default/unity-sdk/share.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: bbd62c26c40c6015731c2bdb03baba50 +guid: 835ddc94e8a02c48fa220413f0d32985 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/storage.js.meta b/Runtime/wechat-default/unity-sdk/storage.js.meta index 4c20fcb8..37c7ed69 100644 --- a/Runtime/wechat-default/unity-sdk/storage.js.meta +++ b/Runtime/wechat-default/unity-sdk/storage.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 65201d2457263753b6a3eec11eda6ecd +guid: ce94b115142efbd114758cff4dddf68d DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/texture.js.meta b/Runtime/wechat-default/unity-sdk/texture.js.meta index e0427354..3f968a1a 100644 --- a/Runtime/wechat-default/unity-sdk/texture.js.meta +++ b/Runtime/wechat-default/unity-sdk/texture.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: b308df842b56fb4005a2e78b57dc52cc +guid: 3ea9157a0cbc01964fa6bc6d0937e56d DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/touch/index.js.meta b/Runtime/wechat-default/unity-sdk/touch/index.js.meta index ab7fbd5a..71f665bc 100644 --- a/Runtime/wechat-default/unity-sdk/touch/index.js.meta +++ b/Runtime/wechat-default/unity-sdk/touch/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a3a9e498c9d6fd9cd82c5ba05377b4d3 +guid: 4deb544a60d9f161065ae0706b17cdbf DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/upload-file.js.meta b/Runtime/wechat-default/unity-sdk/upload-file.js.meta index 7098e0c2..3c7df460 100644 --- a/Runtime/wechat-default/unity-sdk/upload-file.js.meta +++ b/Runtime/wechat-default/unity-sdk/upload-file.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 9e2525d6c69952c445ffffad7d0cd8e2 +guid: 746d0e6a576ecdbf002f3e434aaa5a9c DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/userinfo.js.meta b/Runtime/wechat-default/unity-sdk/userinfo.js.meta index 0d14f56d..9d431118 100644 --- a/Runtime/wechat-default/unity-sdk/userinfo.js.meta +++ b/Runtime/wechat-default/unity-sdk/userinfo.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 9456a64a9d9dde693d3dff88fa6ac293 +guid: 5a59e2d18e6490f632b7ec0b06bae3a6 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/util.js b/Runtime/wechat-default/unity-sdk/util.js index ff6112c5..3108ab05 100644 --- a/Runtime/wechat-default/unity-sdk/util.js +++ b/Runtime/wechat-default/unity-sdk/util.js @@ -171,4 +171,7 @@ export default { args, })); }, + WX_SetPreferredFramesPerSecond(fps) { + wx.setPreferredFramesPerSecond(fps); + }, }; diff --git a/Runtime/wechat-default/unity-sdk/util.js.meta b/Runtime/wechat-default/unity-sdk/util.js.meta index 766cd1ce..592a5678 100644 --- a/Runtime/wechat-default/unity-sdk/util.js.meta +++ b/Runtime/wechat-default/unity-sdk/util.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 000a31f9de0bd5bbb12bd3972e71f8c2 +guid: 86677fe9d310a342dae4a89ec0dd1a33 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/utils.js.meta b/Runtime/wechat-default/unity-sdk/utils.js.meta index 059fc8c6..f3c91099 100644 --- a/Runtime/wechat-default/unity-sdk/utils.js.meta +++ b/Runtime/wechat-default/unity-sdk/utils.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a772a0ed6d065114a403349fad8b8766 +guid: faec95781e883c1ae3e45d4ef7a7b308 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/video.js.meta b/Runtime/wechat-default/unity-sdk/video.js.meta index b52e5b7b..26987108 100644 --- a/Runtime/wechat-default/unity-sdk/video.js.meta +++ b/Runtime/wechat-default/unity-sdk/video.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: dd542a626b6166c8cea2ca68c4b8cfd0 +guid: 983fe23edf518c1de8a6298d767d1b94 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/unity-sdk/video/index.js.meta b/Runtime/wechat-default/unity-sdk/video/index.js.meta index c28fcc43..d5ff3201 100644 --- a/Runtime/wechat-default/unity-sdk/video/index.js.meta +++ b/Runtime/wechat-default/unity-sdk/video/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 8b7c1e26170eb361e91944ef7f24c5a9 +guid: e46207f3163f00f19a28af9cbd1a1144 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/wasmcode/game.js.meta b/Runtime/wechat-default/wasmcode/game.js.meta index d0e826dd..9bb54230 100644 --- a/Runtime/wechat-default/wasmcode/game.js.meta +++ b/Runtime/wechat-default/wasmcode/game.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 2d7a86758ca46e61490d4865f3c09f1a +guid: 133b19a8c99d282caaad0cd1a710d7b0 DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/weapp-adapter.js.meta b/Runtime/wechat-default/weapp-adapter.js.meta index 892817f3..2bb3b6e2 100644 --- a/Runtime/wechat-default/weapp-adapter.js.meta +++ b/Runtime/wechat-default/weapp-adapter.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: d422da93f22c61b5aa2f5db194a28def +guid: 96b354eb7b6f2cb91b34a1b25b09a2ef DefaultImporter: externalObjects: {} userData: diff --git a/Runtime/wechat-default/workers/response/index.js.meta b/Runtime/wechat-default/workers/response/index.js.meta index 81e74ea8..9b687091 100644 --- a/Runtime/wechat-default/workers/response/index.js.meta +++ b/Runtime/wechat-default/workers/response/index.js.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 4e5f01c5a3ede28740118cb1b1907d77 +guid: 1e77fdb82bf84363942d816f42b00731 DefaultImporter: externalObjects: {} userData: diff --git a/WebGLTemplates/WXTemplate/index.html b/WebGLTemplates/WXTemplate/index.html index d450eecc..c0ac2da0 100644 --- a/WebGLTemplates/WXTemplate/index.html +++ b/WebGLTemplates/WXTemplate/index.html @@ -377,238 +377,16 @@ WX_CloudDeleteFile() {}, WX_CloudCDN() {}, WXLaunchOperaBridge() {}, - WX_AddCard(conf, callbackId){}, - WX_AuthPrivateMessage(conf, callbackId){}, - WX_Authorize(conf, callbackId){}, - WX_CheckIsAddedToMyMiniProgram(conf, callbackId){}, - WX_CheckSession(conf, callbackId){}, - WX_ChooseImage(conf, callbackId){}, - WX_ChooseMedia(conf, callbackId){}, - WX_ChooseMessageFile(conf, callbackId){}, - WX_CloseBLEConnection(conf, callbackId){}, - WX_CloseBluetoothAdapter(conf, callbackId){}, - WX_CompressImage(conf, callbackId){}, - WX_CreateBLEConnection(conf, callbackId){}, - WX_CreateBLEPeripheralServer(conf, callbackId){}, - WX_ExitMiniProgram(conf, callbackId){}, - WX_ExitVoIPChat(conf, callbackId){}, - WX_FaceDetect(conf, callbackId){}, - WX_GetAvailableAudioSources(conf, callbackId){}, - WX_GetBLEDeviceCharacteristics(conf, callbackId){}, - WX_GetBLEDeviceRSSI(conf, callbackId){}, - WX_GetBLEDeviceServices(conf, callbackId){}, - WX_GetBLEMTU(conf, callbackId){}, - WX_GetBackgroundFetchData(conf, callbackId){}, - WX_GetBackgroundFetchToken(conf, callbackId){}, - WX_GetBatteryInfo(conf, callbackId){}, - WX_GetBeacons(conf, callbackId){}, - WX_GetBluetoothAdapterState(conf, callbackId){}, - WX_GetBluetoothDevices(conf, callbackId){}, - WX_GetChannelsLiveInfo(conf, callbackId){}, - WX_GetChannelsLiveNoticeInfo(conf, callbackId){}, - WX_GetClipboardData(conf, callbackId){}, - WX_GetConnectedBluetoothDevices(conf, callbackId){}, - WX_GetDeviceBenchmarkInfo(conf, callbackId){}, - WX_GetExtConfig(conf, callbackId){}, - WX_GetFuzzyLocation(conf, callbackId){}, - WX_GetGameClubData(conf, callbackId){}, - WX_GetGroupEnterInfo(conf, callbackId){}, - WX_GetInferenceEnvInfo(conf, callbackId){}, - WX_GetLocalIPAddress(conf, callbackId){}, - WX_GetNetworkType(conf, callbackId){}, - WX_GetPrivacySetting(conf, callbackId){}, - WX_GetScreenBrightness(conf, callbackId){}, - WX_GetScreenRecordingState(conf, callbackId){}, - WX_GetSetting(conf, callbackId){}, - WX_GetShareInfo(conf, callbackId){}, - WX_GetStorageInfo(conf, callbackId){}, - WX_GetSystemInfo(conf, callbackId){}, - WX_GetSystemInfoAsync(conf, callbackId){}, - WX_GetUserInfo(conf, callbackId){}, - WX_GetUserInteractiveStorage(conf, callbackId){}, - WX_GetWeRunData(conf, callbackId){}, - WX_HideKeyboard(conf, callbackId){}, - WX_HideLoading(conf, callbackId){}, - WX_HideShareMenu(conf, callbackId){}, - WX_HideToast(conf, callbackId){}, - WX_InitFaceDetect(conf, callbackId){}, - WX_IsBluetoothDevicePaired(conf, callbackId){}, - WX_JoinVoIPChat(conf, callbackId){}, - WX_Login(conf, callbackId){}, - WX_MakeBluetoothPair(conf, callbackId){}, - WX_NavigateToMiniProgram(conf, callbackId){}, - WX_NotifyBLECharacteristicValueChange(conf, callbackId){}, - WX_OpenAppAuthorizeSetting(conf, callbackId){}, - WX_OpenBluetoothAdapter(conf, callbackId){}, - WX_OpenCard(conf, callbackId){}, - WX_OpenChannelsActivity(conf, callbackId){}, - WX_OpenChannelsEvent(conf, callbackId){}, - WX_OpenChannelsLive(conf, callbackId){}, - WX_OpenChannelsUserProfile(conf, callbackId){}, - WX_OpenCustomerServiceChat(conf, callbackId){}, - WX_OpenCustomerServiceConversation(conf, callbackId){}, - WX_OpenPrivacyContract(conf, callbackId){}, - WX_OpenSetting(conf, callbackId){}, - WX_OpenSystemBluetoothSetting(conf, callbackId){}, - WX_PreviewImage(conf, callbackId){}, - WX_PreviewMedia(conf, callbackId){}, - WX_ReadBLECharacteristicValue(conf, callbackId){}, - WX_RemoveStorage(conf, callbackId){}, - WX_RemoveUserCloudStorage(conf, callbackId){}, - WX_ReportScene(conf, callbackId){}, - WX_RequestMidasFriendPayment(conf, callbackId){}, - WX_RequestMidasPayment(conf, callbackId){}, - WX_RequestMidasPaymentGameItem(conf, callbackId){}, - WX_RequestSubscribeMessage(conf, callbackId){}, - WX_RequestSubscribeSystemMessage(conf, callbackId){}, - WX_RequirePrivacyAuthorize(conf, callbackId){}, - WX_RestartMiniProgram(conf, callbackId){}, - WX_SaveFileToDisk(conf, callbackId){}, - WX_SaveImageToPhotosAlbum(conf, callbackId){}, - WX_ScanCode(conf, callbackId){}, - WX_SetBLEMTU(conf, callbackId){}, - WX_SetBackgroundFetchToken(conf, callbackId){}, - WX_SetClipboardData(conf, callbackId){}, - WX_SetDeviceOrientation(conf, callbackId){}, - WX_SetEnableDebug(conf, callbackId){}, - WX_SetInnerAudioOption(conf, callbackId){}, - WX_SetKeepScreenOn(conf, callbackId){}, - WX_SetMenuStyle(conf, callbackId){}, - WX_SetScreenBrightness(conf, callbackId){}, - WX_SetStatusBarStyle(conf, callbackId){}, - WX_SetUserCloudStorage(conf, callbackId){}, - WX_SetVisualEffectOnCapture(conf, callbackId){}, - WX_ShowActionSheet(conf, callbackId){}, - WX_ShowKeyboard(conf, callbackId){}, - WX_ShowLoading(conf, callbackId){}, - WX_ShowModal(conf, callbackId){}, - WX_ShowShareImageMenu(conf, callbackId){}, - WX_ShowShareMenu(conf, callbackId){}, - WX_ShowToast(conf, callbackId){}, - WX_StartAccelerometer(conf, callbackId){}, - WX_StartBeaconDiscovery(conf, callbackId){}, - WX_StartBluetoothDevicesDiscovery(conf, callbackId){}, - WX_StartCompass(conf, callbackId){}, - WX_StartDeviceMotionListening(conf, callbackId){}, - WX_StopAccelerometer(conf, callbackId){}, - WX_StopBeaconDiscovery(conf, callbackId){}, - WX_StopBluetoothDevicesDiscovery(conf, callbackId){}, - WX_StopCompass(conf, callbackId){}, - WX_StopDeviceMotionListening(conf, callbackId){}, - WX_StopFaceDetect(conf, callbackId){}, - WX_UpdateKeyboard(conf, callbackId){}, - WX_UpdateShareMenu(conf, callbackId){}, - WX_UpdateVoIPChatMuteConfig(conf, callbackId){}, - WX_UpdateWeChatApp(conf, callbackId){}, - WX_VibrateLong(conf, callbackId){}, - WX_VibrateShort(conf, callbackId){}, - WX_WriteBLECharacteristicValue(conf, callbackId){}, - WX_StartGameLive(conf, callbackId){}, - WX_CheckGameLiveEnabled(conf, callbackId){}, - WX_GetUserCurrentGameliveInfo(conf, callbackId){}, - WX_GetUserRecentGameLiveInfo(conf, callbackId){}, - WX_GetUserGameLiveDetails(conf, callbackId){}, - WX_OpenChannelsLiveCollection(conf, callbackId){}, - WX_OpenPage(conf, callbackId){}, - WX_RequestSubscribeLiveActivity(conf, callbackId){}, - WX_OpenBusinessView(conf, callbackId){}, - - WX_ExitPointerLock() {}, - WX_OperateGameRecorderVideo() {}, - WX_RemoveStorageSync() {}, - WX_ReportEvent() {}, - WX_ReportPerformance() {}, - WX_ReportUserBehaviorBranchAnalytics() {}, - WX_RequestPointerLock() {}, - WX_ReserveChannelsLive() {}, - WX_RevokeBufferURL() {}, WX_SetPreferredFramesPerSecond() {}, - WX_SetStorageSync() {}, - WX_ShareAppMessage() {}, - WX_TriggerGC() {}, - - WX_OnAccelerometerChange() {}, - WX_OffAccelerometerChange() {}, - WX_OnAudioInterruptionBegin() {}, - WX_OffAudioInterruptionBegin() {}, - WX_OnAudioInterruptionEnd() {}, - WX_OffAudioInterruptionEnd() {}, - WX_OnBLEConnectionStateChange() {}, - WX_OffBLEConnectionStateChange() {}, - WX_OnBLEMTUChange() {}, - WX_OffBLEMTUChange() {}, - WX_OnBLEPeripheralConnectionStateChanged() {}, - WX_OffBLEPeripheralConnectionStateChanged() {}, - WX_OnBackgroundFetchData() {}, - WX_OnBeaconServiceChange() {}, - WX_OffBeaconServiceChange() {}, - WX_OnBeaconUpdate() {}, - WX_OffBeaconUpdate() {}, - WX_OnBluetoothAdapterStateChange() {}, - WX_OffBluetoothAdapterStateChange() {}, - WX_OnBluetoothDeviceFound() {}, - WX_OffBluetoothDeviceFound() {}, - WX_OnCompassChange() {}, - WX_OffCompassChange() {}, - WX_OnDeviceMotionChange() {}, - WX_OffDeviceMotionChange() {}, - WX_OnDeviceOrientationChange() {}, - WX_OffDeviceOrientationChange() {}, - WX_OnError() {}, - WX_OffError() {}, - WX_OnHide() {}, - WX_OffHide() {}, - WX_OnInteractiveStorageModified() {}, - WX_OffInteractiveStorageModified() {}, - WX_OnKeyDown() {}, - WX_OffKeyDown() {}, - WX_OnKeyUp() {}, - WX_OffKeyUp() {}, - WX_OnKeyboardComplete() {}, - WX_OffKeyboardComplete() {}, - WX_OnKeyboardConfirm() {}, - WX_OffKeyboardConfirm() {}, - WX_OnKeyboardHeightChange() {}, - WX_OffKeyboardHeightChange() {}, - WX_OnKeyboardInput() {}, - WX_OffKeyboardInput() {}, - WX_OnMemoryWarning() {}, - WX_OffMemoryWarning() {}, - WX_OnMenuButtonBoundingClientRectWeightChange() {}, - WX_OffMenuButtonBoundingClientRectWeightChange() {}, - WX_OnMessage() {}, - WX_OnMouseDown() {}, - WX_OffMouseDown() {}, - WX_OnMouseMove() {}, - WX_OffMouseMove() {}, - WX_OnMouseUp() {}, - WX_OffMouseUp() {}, - WX_OnNetworkStatusChange() {}, - WX_OffNetworkStatusChange() {}, - WX_OnNetworkWeakChange() {}, - WX_OffNetworkWeakChange() {}, - WX_OnScreenRecordingStateChanged() {}, - WX_OffScreenRecordingStateChanged() {}, - WX_OnShareMessageToFriend() {}, - WX_OnShow() {}, - WX_OffShow() {}, - WX_OnUnhandledRejection() {}, - WX_OffUnhandledRejection() {}, - WX_OnUserCaptureScreen() {}, - WX_OffUserCaptureScreen() {}, - WX_OnVoIPChatInterrupted() {}, - WX_OffVoIPChatInterrupted() {}, - WX_OnVoIPChatMembersChanged() {}, - WX_OffVoIPChatMembersChanged() {}, - WX_OnVoIPChatSpeakersChanged() {}, - WX_OffVoIPChatSpeakersChanged() {}, - WX_OnVoIPChatStateChanged() {}, - WX_OffVoIPChatStateChanged() {}, - WX_OnWheel() {}, - WX_OffWheel() {}, - WX_OnWindowResize() {}, - WX_OffWindowResize() {}, - + WX_OneWayFunction(functionName, successType, failType, completeType, conf, callbackId){}, + WX_OneWayNoFunction_v() {}, + WX_OneWayNoFunction_vs() {}, + WX_OneWayNoFunction_vt() {}, + WX_OneWayNoFunction_vst() {}, + WX_OneWayNoFunction_vsn() {}, + WX_OneWayNoFunction_vnns() {}, + WX_OnEventRegister() {}, + WX_OffEventRegister() {}, WX_OnAddToFavorites() {}, WX_OnAddToFavorites_Resolve(conf){}, WX_OffAddToFavorites() {}, @@ -625,118 +403,44 @@ WX_OnGameLiveStateChange_Resolve(conf){}, WX_OffGameLiveStateChange() {}, - WX_SetHandoffQuery(query){ + WX_SyncFunction_t() { return ""; }, - WX_GetAccountInfoSync(){ - return JSON.stringify({}); - }, - WX_GetAppAuthorizeSetting(){ - return JSON.stringify({}); - }, - WX_GetAppBaseInfo(){ - return JSON.stringify({}); - }, - WX_GetBatteryInfoSync(){ - return JSON.stringify({}); - }, - WX_GetDeviceInfo(){ - return JSON.stringify({}); - }, - WX_GetEnterOptionsSync(){ - return JSON.stringify({}); - }, - WX_GetExptInfoSync(keys){ - return JSON.stringify({}); - }, - WX_GetExtConfigSync(){ - return JSON.stringify({}); - }, - WX_GetLaunchOptionsSync(){ - return JSON.stringify({}); - }, - WX_GetMenuButtonBoundingClientRect(){ - return JSON.stringify({}); - }, - WX_GetStorageInfoSync(){ - return JSON.stringify({}); - }, - WX_GetSystemInfoSync(){ - return JSON.stringify({}); - }, - WX_GetSystemSetting(){ - return JSON.stringify({}); - }, - WX_GetWindowInfo(){ - return JSON.stringify({}); - }, - WX_CreateImageData(width, height){ - return JSON.stringify({}); - }, - WX_CreatePath2D(){ - return JSON.stringify({}); - }, - WX_IsPointerLocked(){ + WX_SyncFunction_tt() { return ""; }, - WX_IsVKSupport(version){ + WX_SyncFunction_bt() { + return false; + }, + WX_SyncFunction_nt() { + return 0; + }, + WX_SyncFunction_bs() { + return false; + }, + WX_SyncFunction_b() { + return false; + }, + WX_SyncFunction_bsnn() { + return false; + }, + WX_SyncFunction_ss() { return ""; }, - WX_SetCursor(path, x, y){ + WX_SyncFunction_tnn() { return ""; }, - WX_SetMessageToFriendQuery(option){ + WX_ClassFunction() {return ""}, + WX_ClassOneWayFunction() {return ""}, + WX_ClassSetProperty() {}, + WX_ClassOneWayNoFunction_v() {}, + WX_ClassOneWayNoFunction_vs() {}, + WX_ClassOneWayNoFunction_t() { return ""; }, - WX_GetTextLineHeight(option){ - return ""; - }, - WX_LoadFont(path){ - return ""; - }, - WX_GetGameLiveState(){ - return JSON.stringify({}); - }, - - WX_DownloadFile() {return ""}, - WX_CreateFeedbackButton() {return ""}, - WX_GetLogManager() {return ""}, - WX_GetRealtimeLogManager() {return ""}, - WX_GetUpdateManager() {return ""}, - WX_CreateVideoDecoder() {return ""}, - - WX_DownloadTaskAbort() {}, - WX_DownloadTaskOffHeadersReceived() {}, - WX_DownloadTaskOffProgressUpdate() {}, - WX_DownloadTaskOnHeadersReceived() {}, - WX_DownloadTaskOnProgressUpdate() {}, - WXFeedbackButtonSetProperty() {}, - WX_FeedbackButtonDestroy() {}, - WX_FeedbackButtonHide() {}, - WX_FeedbackButtonOffTap() {}, - WX_FeedbackButtonOnTap() {}, - WX_FeedbackButtonShow() {}, - WX_LogManagerDebug() {}, - WX_LogManagerInfo() {}, - WX_LogManagerLog() {}, - WX_LogManagerWarn() {}, - WX_RealtimeLogManagerAddFilterMsg() {}, - WX_RealtimeLogManagerError() {}, - WX_RealtimeLogManagerInfo() {}, - WX_RealtimeLogManagerSetFilterMsg() {}, - WX_RealtimeLogManagerWarn() {}, - WX_UpdateManagerApplyUpdate() {}, - WX_UpdateManagerOnCheckForUpdate() {}, - WX_UpdateManagerOnUpdateFailed() {}, - WX_UpdateManagerOnUpdateReady() {}, - WX_VideoDecoderGetFrameData() {}, - WX_VideoDecoderRemove() {}, - WX_VideoDecoderSeek() {}, - WX_VideoDecoderStart() {}, - WX_VideoDecoderStop() {}, - WX_VideoDecoderOff() {}, - WX_VideoDecoderOn() {}, - }; + WX_ClassOneWayNoFunction_vt() {}, + WX_ClassOnEventFunction() {}, + WX_ClassOffEventFunction() {}, }; var downloadedTextures = {}; var downloadingTextures = {}; var textureHandler = { diff --git a/WebGLTemplates/WXTemplate2020/index.html b/WebGLTemplates/WXTemplate2020/index.html index a114e0db..3c6925cc 100644 --- a/WebGLTemplates/WXTemplate2020/index.html +++ b/WebGLTemplates/WXTemplate2020/index.html @@ -449,238 +449,16 @@ WX_CloudDeleteFile() {}, WX_CloudCDN() {}, WXLaunchOperaBridge() {}, - WX_AddCard(conf, callbackId){}, - WX_AuthPrivateMessage(conf, callbackId){}, - WX_Authorize(conf, callbackId){}, - WX_CheckIsAddedToMyMiniProgram(conf, callbackId){}, - WX_CheckSession(conf, callbackId){}, - WX_ChooseImage(conf, callbackId){}, - WX_ChooseMedia(conf, callbackId){}, - WX_ChooseMessageFile(conf, callbackId){}, - WX_CloseBLEConnection(conf, callbackId){}, - WX_CloseBluetoothAdapter(conf, callbackId){}, - WX_CompressImage(conf, callbackId){}, - WX_CreateBLEConnection(conf, callbackId){}, - WX_CreateBLEPeripheralServer(conf, callbackId){}, - WX_ExitMiniProgram(conf, callbackId){}, - WX_ExitVoIPChat(conf, callbackId){}, - WX_FaceDetect(conf, callbackId){}, - WX_GetAvailableAudioSources(conf, callbackId){}, - WX_GetBLEDeviceCharacteristics(conf, callbackId){}, - WX_GetBLEDeviceRSSI(conf, callbackId){}, - WX_GetBLEDeviceServices(conf, callbackId){}, - WX_GetBLEMTU(conf, callbackId){}, - WX_GetBackgroundFetchData(conf, callbackId){}, - WX_GetBackgroundFetchToken(conf, callbackId){}, - WX_GetBatteryInfo(conf, callbackId){}, - WX_GetBeacons(conf, callbackId){}, - WX_GetBluetoothAdapterState(conf, callbackId){}, - WX_GetBluetoothDevices(conf, callbackId){}, - WX_GetChannelsLiveInfo(conf, callbackId){}, - WX_GetChannelsLiveNoticeInfo(conf, callbackId){}, - WX_GetClipboardData(conf, callbackId){}, - WX_GetConnectedBluetoothDevices(conf, callbackId){}, - WX_GetDeviceBenchmarkInfo(conf, callbackId){}, - WX_GetExtConfig(conf, callbackId){}, - WX_GetFuzzyLocation(conf, callbackId){}, - WX_GetGameClubData(conf, callbackId){}, - WX_GetGroupEnterInfo(conf, callbackId){}, - WX_GetInferenceEnvInfo(conf, callbackId){}, - WX_GetLocalIPAddress(conf, callbackId){}, - WX_GetNetworkType(conf, callbackId){}, - WX_GetPrivacySetting(conf, callbackId){}, - WX_GetScreenBrightness(conf, callbackId){}, - WX_GetScreenRecordingState(conf, callbackId){}, - WX_GetSetting(conf, callbackId){}, - WX_GetShareInfo(conf, callbackId){}, - WX_GetStorageInfo(conf, callbackId){}, - WX_GetSystemInfo(conf, callbackId){}, - WX_GetSystemInfoAsync(conf, callbackId){}, - WX_GetUserInfo(conf, callbackId){}, - WX_GetUserInteractiveStorage(conf, callbackId){}, - WX_GetWeRunData(conf, callbackId){}, - WX_HideKeyboard(conf, callbackId){}, - WX_HideLoading(conf, callbackId){}, - WX_HideShareMenu(conf, callbackId){}, - WX_HideToast(conf, callbackId){}, - WX_InitFaceDetect(conf, callbackId){}, - WX_IsBluetoothDevicePaired(conf, callbackId){}, - WX_JoinVoIPChat(conf, callbackId){}, - WX_Login(conf, callbackId){}, - WX_MakeBluetoothPair(conf, callbackId){}, - WX_NavigateToMiniProgram(conf, callbackId){}, - WX_NotifyBLECharacteristicValueChange(conf, callbackId){}, - WX_OpenAppAuthorizeSetting(conf, callbackId){}, - WX_OpenBluetoothAdapter(conf, callbackId){}, - WX_OpenCard(conf, callbackId){}, - WX_OpenChannelsActivity(conf, callbackId){}, - WX_OpenChannelsEvent(conf, callbackId){}, - WX_OpenChannelsLive(conf, callbackId){}, - WX_OpenChannelsUserProfile(conf, callbackId){}, - WX_OpenCustomerServiceChat(conf, callbackId){}, - WX_OpenCustomerServiceConversation(conf, callbackId){}, - WX_OpenPrivacyContract(conf, callbackId){}, - WX_OpenSetting(conf, callbackId){}, - WX_OpenSystemBluetoothSetting(conf, callbackId){}, - WX_PreviewImage(conf, callbackId){}, - WX_PreviewMedia(conf, callbackId){}, - WX_ReadBLECharacteristicValue(conf, callbackId){}, - WX_RemoveStorage(conf, callbackId){}, - WX_RemoveUserCloudStorage(conf, callbackId){}, - WX_ReportScene(conf, callbackId){}, - WX_RequestMidasFriendPayment(conf, callbackId){}, - WX_RequestMidasPayment(conf, callbackId){}, - WX_RequestMidasPaymentGameItem(conf, callbackId){}, - WX_RequestSubscribeMessage(conf, callbackId){}, - WX_RequestSubscribeSystemMessage(conf, callbackId){}, - WX_RequirePrivacyAuthorize(conf, callbackId){}, - WX_RestartMiniProgram(conf, callbackId){}, - WX_SaveFileToDisk(conf, callbackId){}, - WX_SaveImageToPhotosAlbum(conf, callbackId){}, - WX_ScanCode(conf, callbackId){}, - WX_SetBLEMTU(conf, callbackId){}, - WX_SetBackgroundFetchToken(conf, callbackId){}, - WX_SetClipboardData(conf, callbackId){}, - WX_SetDeviceOrientation(conf, callbackId){}, - WX_SetEnableDebug(conf, callbackId){}, - WX_SetInnerAudioOption(conf, callbackId){}, - WX_SetKeepScreenOn(conf, callbackId){}, - WX_SetMenuStyle(conf, callbackId){}, - WX_SetScreenBrightness(conf, callbackId){}, - WX_SetStatusBarStyle(conf, callbackId){}, - WX_SetUserCloudStorage(conf, callbackId){}, - WX_SetVisualEffectOnCapture(conf, callbackId){}, - WX_ShowActionSheet(conf, callbackId){}, - WX_ShowKeyboard(conf, callbackId){}, - WX_ShowLoading(conf, callbackId){}, - WX_ShowModal(conf, callbackId){}, - WX_ShowShareImageMenu(conf, callbackId){}, - WX_ShowShareMenu(conf, callbackId){}, - WX_ShowToast(conf, callbackId){}, - WX_StartAccelerometer(conf, callbackId){}, - WX_StartBeaconDiscovery(conf, callbackId){}, - WX_StartBluetoothDevicesDiscovery(conf, callbackId){}, - WX_StartCompass(conf, callbackId){}, - WX_StartDeviceMotionListening(conf, callbackId){}, - WX_StopAccelerometer(conf, callbackId){}, - WX_StopBeaconDiscovery(conf, callbackId){}, - WX_StopBluetoothDevicesDiscovery(conf, callbackId){}, - WX_StopCompass(conf, callbackId){}, - WX_StopDeviceMotionListening(conf, callbackId){}, - WX_StopFaceDetect(conf, callbackId){}, - WX_UpdateKeyboard(conf, callbackId){}, - WX_UpdateShareMenu(conf, callbackId){}, - WX_UpdateVoIPChatMuteConfig(conf, callbackId){}, - WX_UpdateWeChatApp(conf, callbackId){}, - WX_VibrateLong(conf, callbackId){}, - WX_VibrateShort(conf, callbackId){}, - WX_WriteBLECharacteristicValue(conf, callbackId){}, - WX_StartGameLive(conf, callbackId){}, - WX_CheckGameLiveEnabled(conf, callbackId){}, - WX_GetUserCurrentGameliveInfo(conf, callbackId){}, - WX_GetUserRecentGameLiveInfo(conf, callbackId){}, - WX_GetUserGameLiveDetails(conf, callbackId){}, - WX_OpenChannelsLiveCollection(conf, callbackId){}, - WX_OpenPage(conf, callbackId){}, - WX_RequestSubscribeLiveActivity(conf, callbackId){}, - WX_OpenBusinessView(conf, callbackId){}, - - WX_ExitPointerLock() {}, - WX_OperateGameRecorderVideo() {}, - WX_RemoveStorageSync() {}, - WX_ReportEvent() {}, - WX_ReportPerformance() {}, - WX_ReportUserBehaviorBranchAnalytics() {}, - WX_RequestPointerLock() {}, - WX_ReserveChannelsLive() {}, - WX_RevokeBufferURL() {}, WX_SetPreferredFramesPerSecond() {}, - WX_SetStorageSync() {}, - WX_ShareAppMessage() {}, - WX_TriggerGC() {}, - - WX_OnAccelerometerChange() {}, - WX_OffAccelerometerChange() {}, - WX_OnAudioInterruptionBegin() {}, - WX_OffAudioInterruptionBegin() {}, - WX_OnAudioInterruptionEnd() {}, - WX_OffAudioInterruptionEnd() {}, - WX_OnBLEConnectionStateChange() {}, - WX_OffBLEConnectionStateChange() {}, - WX_OnBLEMTUChange() {}, - WX_OffBLEMTUChange() {}, - WX_OnBLEPeripheralConnectionStateChanged() {}, - WX_OffBLEPeripheralConnectionStateChanged() {}, - WX_OnBackgroundFetchData() {}, - WX_OnBeaconServiceChange() {}, - WX_OffBeaconServiceChange() {}, - WX_OnBeaconUpdate() {}, - WX_OffBeaconUpdate() {}, - WX_OnBluetoothAdapterStateChange() {}, - WX_OffBluetoothAdapterStateChange() {}, - WX_OnBluetoothDeviceFound() {}, - WX_OffBluetoothDeviceFound() {}, - WX_OnCompassChange() {}, - WX_OffCompassChange() {}, - WX_OnDeviceMotionChange() {}, - WX_OffDeviceMotionChange() {}, - WX_OnDeviceOrientationChange() {}, - WX_OffDeviceOrientationChange() {}, - WX_OnError() {}, - WX_OffError() {}, - WX_OnHide() {}, - WX_OffHide() {}, - WX_OnInteractiveStorageModified() {}, - WX_OffInteractiveStorageModified() {}, - WX_OnKeyDown() {}, - WX_OffKeyDown() {}, - WX_OnKeyUp() {}, - WX_OffKeyUp() {}, - WX_OnKeyboardComplete() {}, - WX_OffKeyboardComplete() {}, - WX_OnKeyboardConfirm() {}, - WX_OffKeyboardConfirm() {}, - WX_OnKeyboardHeightChange() {}, - WX_OffKeyboardHeightChange() {}, - WX_OnKeyboardInput() {}, - WX_OffKeyboardInput() {}, - WX_OnMemoryWarning() {}, - WX_OffMemoryWarning() {}, - WX_OnMenuButtonBoundingClientRectWeightChange() {}, - WX_OffMenuButtonBoundingClientRectWeightChange() {}, - WX_OnMessage() {}, - WX_OnMouseDown() {}, - WX_OffMouseDown() {}, - WX_OnMouseMove() {}, - WX_OffMouseMove() {}, - WX_OnMouseUp() {}, - WX_OffMouseUp() {}, - WX_OnNetworkStatusChange() {}, - WX_OffNetworkStatusChange() {}, - WX_OnNetworkWeakChange() {}, - WX_OffNetworkWeakChange() {}, - WX_OnScreenRecordingStateChanged() {}, - WX_OffScreenRecordingStateChanged() {}, - WX_OnShareMessageToFriend() {}, - WX_OnShow() {}, - WX_OffShow() {}, - WX_OnUnhandledRejection() {}, - WX_OffUnhandledRejection() {}, - WX_OnUserCaptureScreen() {}, - WX_OffUserCaptureScreen() {}, - WX_OnVoIPChatInterrupted() {}, - WX_OffVoIPChatInterrupted() {}, - WX_OnVoIPChatMembersChanged() {}, - WX_OffVoIPChatMembersChanged() {}, - WX_OnVoIPChatSpeakersChanged() {}, - WX_OffVoIPChatSpeakersChanged() {}, - WX_OnVoIPChatStateChanged() {}, - WX_OffVoIPChatStateChanged() {}, - WX_OnWheel() {}, - WX_OffWheel() {}, - WX_OnWindowResize() {}, - WX_OffWindowResize() {}, - + WX_OneWayFunction(functionName, successType, failType, completeType, conf, callbackId){}, + WX_OneWayNoFunction_v() {}, + WX_OneWayNoFunction_vs() {}, + WX_OneWayNoFunction_vt() {}, + WX_OneWayNoFunction_vst() {}, + WX_OneWayNoFunction_vsn() {}, + WX_OneWayNoFunction_vnns() {}, + WX_OnEventRegister() {}, + WX_OffEventRegister() {}, WX_OnAddToFavorites() {}, WX_OnAddToFavorites_Resolve(conf){}, WX_OffAddToFavorites() {}, @@ -697,118 +475,44 @@ WX_OnGameLiveStateChange_Resolve(conf){}, WX_OffGameLiveStateChange() {}, - WX_SetHandoffQuery(query){ + WX_SyncFunction_t() { return ""; }, - WX_GetAccountInfoSync(){ - return JSON.stringify({}); - }, - WX_GetAppAuthorizeSetting(){ - return JSON.stringify({}); - }, - WX_GetAppBaseInfo(){ - return JSON.stringify({}); - }, - WX_GetBatteryInfoSync(){ - return JSON.stringify({}); - }, - WX_GetDeviceInfo(){ - return JSON.stringify({}); - }, - WX_GetEnterOptionsSync(){ - return JSON.stringify({}); - }, - WX_GetExptInfoSync(keys){ - return JSON.stringify({}); - }, - WX_GetExtConfigSync(){ - return JSON.stringify({}); - }, - WX_GetLaunchOptionsSync(){ - return JSON.stringify({}); - }, - WX_GetMenuButtonBoundingClientRect(){ - return JSON.stringify({}); - }, - WX_GetStorageInfoSync(){ - return JSON.stringify({}); - }, - WX_GetSystemInfoSync(){ - return JSON.stringify({}); - }, - WX_GetSystemSetting(){ - return JSON.stringify({}); - }, - WX_GetWindowInfo(){ - return JSON.stringify({}); - }, - WX_CreateImageData(width, height){ - return JSON.stringify({}); - }, - WX_CreatePath2D(){ - return JSON.stringify({}); - }, - WX_IsPointerLocked(){ + WX_SyncFunction_tt() { return ""; }, - WX_IsVKSupport(version){ + WX_SyncFunction_bt() { + return false; + }, + WX_SyncFunction_nt() { + return 0; + }, + WX_SyncFunction_bs() { + return false; + }, + WX_SyncFunction_b() { + return false; + }, + WX_SyncFunction_bsnn() { + return false; + }, + WX_SyncFunction_ss() { return ""; }, - WX_SetCursor(path, x, y){ + WX_SyncFunction_tnn() { return ""; }, - WX_SetMessageToFriendQuery(option){ + WX_ClassFunction() {return ""}, + WX_ClassOneWayFunction() {return ""}, + WX_ClassSetProperty() {}, + WX_ClassOneWayNoFunction_v() {}, + WX_ClassOneWayNoFunction_vs() {}, + WX_ClassOneWayNoFunction_t() { return ""; }, - WX_GetTextLineHeight(option){ - return ""; - }, - WX_LoadFont(path){ - return ""; - }, - WX_GetGameLiveState(){ - return JSON.stringify({}); - }, - - WX_DownloadFile() {return ""}, - WX_CreateFeedbackButton() {return ""}, - WX_GetLogManager() {return ""}, - WX_GetRealtimeLogManager() {return ""}, - WX_GetUpdateManager() {return ""}, - WX_CreateVideoDecoder() {return ""}, - - WX_DownloadTaskAbort() {}, - WX_DownloadTaskOffHeadersReceived() {}, - WX_DownloadTaskOffProgressUpdate() {}, - WX_DownloadTaskOnHeadersReceived() {}, - WX_DownloadTaskOnProgressUpdate() {}, - WXFeedbackButtonSetProperty() {}, - WX_FeedbackButtonDestroy() {}, - WX_FeedbackButtonHide() {}, - WX_FeedbackButtonOffTap() {}, - WX_FeedbackButtonOnTap() {}, - WX_FeedbackButtonShow() {}, - WX_LogManagerDebug() {}, - WX_LogManagerInfo() {}, - WX_LogManagerLog() {}, - WX_LogManagerWarn() {}, - WX_RealtimeLogManagerAddFilterMsg() {}, - WX_RealtimeLogManagerError() {}, - WX_RealtimeLogManagerInfo() {}, - WX_RealtimeLogManagerSetFilterMsg() {}, - WX_RealtimeLogManagerWarn() {}, - WX_UpdateManagerApplyUpdate() {}, - WX_UpdateManagerOnCheckForUpdate() {}, - WX_UpdateManagerOnUpdateFailed() {}, - WX_UpdateManagerOnUpdateReady() {}, - WX_VideoDecoderGetFrameData() {}, - WX_VideoDecoderRemove() {}, - WX_VideoDecoderSeek() {}, - WX_VideoDecoderStart() {}, - WX_VideoDecoderStop() {}, - WX_VideoDecoderOff() {}, - WX_VideoDecoderOn() {}, - }; + WX_ClassOneWayNoFunction_vt() {}, + WX_ClassOnEventFunction() {}, + WX_ClassOffEventFunction() {}, }; var downloadedTextures = {}; var downloadingTextures = {}; var textureHandler = { diff --git a/WebGLTemplates/WXTemplate2022/index.html b/WebGLTemplates/WXTemplate2022/index.html index 72adfa2a..1f2a2bad 100755 --- a/WebGLTemplates/WXTemplate2022/index.html +++ b/WebGLTemplates/WXTemplate2022/index.html @@ -526,238 +526,16 @@ WX_CloudDeleteFile() {}, WX_CloudCDN() {}, WXLaunchOperaBridge() {}, - WX_AddCard(conf, callbackId){}, - WX_AuthPrivateMessage(conf, callbackId){}, - WX_Authorize(conf, callbackId){}, - WX_CheckIsAddedToMyMiniProgram(conf, callbackId){}, - WX_CheckSession(conf, callbackId){}, - WX_ChooseImage(conf, callbackId){}, - WX_ChooseMedia(conf, callbackId){}, - WX_ChooseMessageFile(conf, callbackId){}, - WX_CloseBLEConnection(conf, callbackId){}, - WX_CloseBluetoothAdapter(conf, callbackId){}, - WX_CompressImage(conf, callbackId){}, - WX_CreateBLEConnection(conf, callbackId){}, - WX_CreateBLEPeripheralServer(conf, callbackId){}, - WX_ExitMiniProgram(conf, callbackId){}, - WX_ExitVoIPChat(conf, callbackId){}, - WX_FaceDetect(conf, callbackId){}, - WX_GetAvailableAudioSources(conf, callbackId){}, - WX_GetBLEDeviceCharacteristics(conf, callbackId){}, - WX_GetBLEDeviceRSSI(conf, callbackId){}, - WX_GetBLEDeviceServices(conf, callbackId){}, - WX_GetBLEMTU(conf, callbackId){}, - WX_GetBackgroundFetchData(conf, callbackId){}, - WX_GetBackgroundFetchToken(conf, callbackId){}, - WX_GetBatteryInfo(conf, callbackId){}, - WX_GetBeacons(conf, callbackId){}, - WX_GetBluetoothAdapterState(conf, callbackId){}, - WX_GetBluetoothDevices(conf, callbackId){}, - WX_GetChannelsLiveInfo(conf, callbackId){}, - WX_GetChannelsLiveNoticeInfo(conf, callbackId){}, - WX_GetClipboardData(conf, callbackId){}, - WX_GetConnectedBluetoothDevices(conf, callbackId){}, - WX_GetDeviceBenchmarkInfo(conf, callbackId){}, - WX_GetExtConfig(conf, callbackId){}, - WX_GetFuzzyLocation(conf, callbackId){}, - WX_GetGameClubData(conf, callbackId){}, - WX_GetGroupEnterInfo(conf, callbackId){}, - WX_GetInferenceEnvInfo(conf, callbackId){}, - WX_GetLocalIPAddress(conf, callbackId){}, - WX_GetNetworkType(conf, callbackId){}, - WX_GetPrivacySetting(conf, callbackId){}, - WX_GetScreenBrightness(conf, callbackId){}, - WX_GetScreenRecordingState(conf, callbackId){}, - WX_GetSetting(conf, callbackId){}, - WX_GetShareInfo(conf, callbackId){}, - WX_GetStorageInfo(conf, callbackId){}, - WX_GetSystemInfo(conf, callbackId){}, - WX_GetSystemInfoAsync(conf, callbackId){}, - WX_GetUserInfo(conf, callbackId){}, - WX_GetUserInteractiveStorage(conf, callbackId){}, - WX_GetWeRunData(conf, callbackId){}, - WX_HideKeyboard(conf, callbackId){}, - WX_HideLoading(conf, callbackId){}, - WX_HideShareMenu(conf, callbackId){}, - WX_HideToast(conf, callbackId){}, - WX_InitFaceDetect(conf, callbackId){}, - WX_IsBluetoothDevicePaired(conf, callbackId){}, - WX_JoinVoIPChat(conf, callbackId){}, - WX_Login(conf, callbackId){}, - WX_MakeBluetoothPair(conf, callbackId){}, - WX_NavigateToMiniProgram(conf, callbackId){}, - WX_NotifyBLECharacteristicValueChange(conf, callbackId){}, - WX_OpenAppAuthorizeSetting(conf, callbackId){}, - WX_OpenBluetoothAdapter(conf, callbackId){}, - WX_OpenCard(conf, callbackId){}, - WX_OpenChannelsActivity(conf, callbackId){}, - WX_OpenChannelsEvent(conf, callbackId){}, - WX_OpenChannelsLive(conf, callbackId){}, - WX_OpenChannelsUserProfile(conf, callbackId){}, - WX_OpenCustomerServiceChat(conf, callbackId){}, - WX_OpenCustomerServiceConversation(conf, callbackId){}, - WX_OpenPrivacyContract(conf, callbackId){}, - WX_OpenSetting(conf, callbackId){}, - WX_OpenSystemBluetoothSetting(conf, callbackId){}, - WX_PreviewImage(conf, callbackId){}, - WX_PreviewMedia(conf, callbackId){}, - WX_ReadBLECharacteristicValue(conf, callbackId){}, - WX_RemoveStorage(conf, callbackId){}, - WX_RemoveUserCloudStorage(conf, callbackId){}, - WX_ReportScene(conf, callbackId){}, - WX_RequestMidasFriendPayment(conf, callbackId){}, - WX_RequestMidasPayment(conf, callbackId){}, - WX_RequestMidasPaymentGameItem(conf, callbackId){}, - WX_RequestSubscribeMessage(conf, callbackId){}, - WX_RequestSubscribeSystemMessage(conf, callbackId){}, - WX_RequirePrivacyAuthorize(conf, callbackId){}, - WX_RestartMiniProgram(conf, callbackId){}, - WX_SaveFileToDisk(conf, callbackId){}, - WX_SaveImageToPhotosAlbum(conf, callbackId){}, - WX_ScanCode(conf, callbackId){}, - WX_SetBLEMTU(conf, callbackId){}, - WX_SetBackgroundFetchToken(conf, callbackId){}, - WX_SetClipboardData(conf, callbackId){}, - WX_SetDeviceOrientation(conf, callbackId){}, - WX_SetEnableDebug(conf, callbackId){}, - WX_SetInnerAudioOption(conf, callbackId){}, - WX_SetKeepScreenOn(conf, callbackId){}, - WX_SetMenuStyle(conf, callbackId){}, - WX_SetScreenBrightness(conf, callbackId){}, - WX_SetStatusBarStyle(conf, callbackId){}, - WX_SetUserCloudStorage(conf, callbackId){}, - WX_SetVisualEffectOnCapture(conf, callbackId){}, - WX_ShowActionSheet(conf, callbackId){}, - WX_ShowKeyboard(conf, callbackId){}, - WX_ShowLoading(conf, callbackId){}, - WX_ShowModal(conf, callbackId){}, - WX_ShowShareImageMenu(conf, callbackId){}, - WX_ShowShareMenu(conf, callbackId){}, - WX_ShowToast(conf, callbackId){}, - WX_StartAccelerometer(conf, callbackId){}, - WX_StartBeaconDiscovery(conf, callbackId){}, - WX_StartBluetoothDevicesDiscovery(conf, callbackId){}, - WX_StartCompass(conf, callbackId){}, - WX_StartDeviceMotionListening(conf, callbackId){}, - WX_StopAccelerometer(conf, callbackId){}, - WX_StopBeaconDiscovery(conf, callbackId){}, - WX_StopBluetoothDevicesDiscovery(conf, callbackId){}, - WX_StopCompass(conf, callbackId){}, - WX_StopDeviceMotionListening(conf, callbackId){}, - WX_StopFaceDetect(conf, callbackId){}, - WX_UpdateKeyboard(conf, callbackId){}, - WX_UpdateShareMenu(conf, callbackId){}, - WX_UpdateVoIPChatMuteConfig(conf, callbackId){}, - WX_UpdateWeChatApp(conf, callbackId){}, - WX_VibrateLong(conf, callbackId){}, - WX_VibrateShort(conf, callbackId){}, - WX_WriteBLECharacteristicValue(conf, callbackId){}, - WX_StartGameLive(conf, callbackId){}, - WX_CheckGameLiveEnabled(conf, callbackId){}, - WX_GetUserCurrentGameliveInfo(conf, callbackId){}, - WX_GetUserRecentGameLiveInfo(conf, callbackId){}, - WX_GetUserGameLiveDetails(conf, callbackId){}, - WX_OpenChannelsLiveCollection(conf, callbackId){}, - WX_OpenPage(conf, callbackId){}, - WX_RequestSubscribeLiveActivity(conf, callbackId){}, - WX_OpenBusinessView(conf, callbackId){}, - - WX_ExitPointerLock() {}, - WX_OperateGameRecorderVideo() {}, - WX_RemoveStorageSync() {}, - WX_ReportEvent() {}, - WX_ReportPerformance() {}, - WX_ReportUserBehaviorBranchAnalytics() {}, - WX_RequestPointerLock() {}, - WX_ReserveChannelsLive() {}, - WX_RevokeBufferURL() {}, WX_SetPreferredFramesPerSecond() {}, - WX_SetStorageSync() {}, - WX_ShareAppMessage() {}, - WX_TriggerGC() {}, - - WX_OnAccelerometerChange() {}, - WX_OffAccelerometerChange() {}, - WX_OnAudioInterruptionBegin() {}, - WX_OffAudioInterruptionBegin() {}, - WX_OnAudioInterruptionEnd() {}, - WX_OffAudioInterruptionEnd() {}, - WX_OnBLEConnectionStateChange() {}, - WX_OffBLEConnectionStateChange() {}, - WX_OnBLEMTUChange() {}, - WX_OffBLEMTUChange() {}, - WX_OnBLEPeripheralConnectionStateChanged() {}, - WX_OffBLEPeripheralConnectionStateChanged() {}, - WX_OnBackgroundFetchData() {}, - WX_OnBeaconServiceChange() {}, - WX_OffBeaconServiceChange() {}, - WX_OnBeaconUpdate() {}, - WX_OffBeaconUpdate() {}, - WX_OnBluetoothAdapterStateChange() {}, - WX_OffBluetoothAdapterStateChange() {}, - WX_OnBluetoothDeviceFound() {}, - WX_OffBluetoothDeviceFound() {}, - WX_OnCompassChange() {}, - WX_OffCompassChange() {}, - WX_OnDeviceMotionChange() {}, - WX_OffDeviceMotionChange() {}, - WX_OnDeviceOrientationChange() {}, - WX_OffDeviceOrientationChange() {}, - WX_OnError() {}, - WX_OffError() {}, - WX_OnHide() {}, - WX_OffHide() {}, - WX_OnInteractiveStorageModified() {}, - WX_OffInteractiveStorageModified() {}, - WX_OnKeyDown() {}, - WX_OffKeyDown() {}, - WX_OnKeyUp() {}, - WX_OffKeyUp() {}, - WX_OnKeyboardComplete() {}, - WX_OffKeyboardComplete() {}, - WX_OnKeyboardConfirm() {}, - WX_OffKeyboardConfirm() {}, - WX_OnKeyboardHeightChange() {}, - WX_OffKeyboardHeightChange() {}, - WX_OnKeyboardInput() {}, - WX_OffKeyboardInput() {}, - WX_OnMemoryWarning() {}, - WX_OffMemoryWarning() {}, - WX_OnMenuButtonBoundingClientRectWeightChange() {}, - WX_OffMenuButtonBoundingClientRectWeightChange() {}, - WX_OnMessage() {}, - WX_OnMouseDown() {}, - WX_OffMouseDown() {}, - WX_OnMouseMove() {}, - WX_OffMouseMove() {}, - WX_OnMouseUp() {}, - WX_OffMouseUp() {}, - WX_OnNetworkStatusChange() {}, - WX_OffNetworkStatusChange() {}, - WX_OnNetworkWeakChange() {}, - WX_OffNetworkWeakChange() {}, - WX_OnScreenRecordingStateChanged() {}, - WX_OffScreenRecordingStateChanged() {}, - WX_OnShareMessageToFriend() {}, - WX_OnShow() {}, - WX_OffShow() {}, - WX_OnUnhandledRejection() {}, - WX_OffUnhandledRejection() {}, - WX_OnUserCaptureScreen() {}, - WX_OffUserCaptureScreen() {}, - WX_OnVoIPChatInterrupted() {}, - WX_OffVoIPChatInterrupted() {}, - WX_OnVoIPChatMembersChanged() {}, - WX_OffVoIPChatMembersChanged() {}, - WX_OnVoIPChatSpeakersChanged() {}, - WX_OffVoIPChatSpeakersChanged() {}, - WX_OnVoIPChatStateChanged() {}, - WX_OffVoIPChatStateChanged() {}, - WX_OnWheel() {}, - WX_OffWheel() {}, - WX_OnWindowResize() {}, - WX_OffWindowResize() {}, - + WX_OneWayFunction(functionName, successType, failType, completeType, conf, callbackId){}, + WX_OneWayNoFunction_v() {}, + WX_OneWayNoFunction_vs() {}, + WX_OneWayNoFunction_vt() {}, + WX_OneWayNoFunction_vst() {}, + WX_OneWayNoFunction_vsn() {}, + WX_OneWayNoFunction_vnns() {}, + WX_OnEventRegister() {}, + WX_OffEventRegister() {}, WX_OnAddToFavorites() {}, WX_OnAddToFavorites_Resolve(conf){}, WX_OffAddToFavorites() {}, @@ -774,118 +552,44 @@ WX_OnGameLiveStateChange_Resolve(conf){}, WX_OffGameLiveStateChange() {}, - WX_SetHandoffQuery(query){ + WX_SyncFunction_t() { return ""; }, - WX_GetAccountInfoSync(){ - return JSON.stringify({}); - }, - WX_GetAppAuthorizeSetting(){ - return JSON.stringify({}); - }, - WX_GetAppBaseInfo(){ - return JSON.stringify({}); - }, - WX_GetBatteryInfoSync(){ - return JSON.stringify({}); - }, - WX_GetDeviceInfo(){ - return JSON.stringify({}); - }, - WX_GetEnterOptionsSync(){ - return JSON.stringify({}); - }, - WX_GetExptInfoSync(keys){ - return JSON.stringify({}); - }, - WX_GetExtConfigSync(){ - return JSON.stringify({}); - }, - WX_GetLaunchOptionsSync(){ - return JSON.stringify({}); - }, - WX_GetMenuButtonBoundingClientRect(){ - return JSON.stringify({}); - }, - WX_GetStorageInfoSync(){ - return JSON.stringify({}); - }, - WX_GetSystemInfoSync(){ - return JSON.stringify({}); - }, - WX_GetSystemSetting(){ - return JSON.stringify({}); - }, - WX_GetWindowInfo(){ - return JSON.stringify({}); - }, - WX_CreateImageData(width, height){ - return JSON.stringify({}); - }, - WX_CreatePath2D(){ - return JSON.stringify({}); - }, - WX_IsPointerLocked(){ + WX_SyncFunction_tt() { return ""; }, - WX_IsVKSupport(version){ + WX_SyncFunction_bt() { + return false; + }, + WX_SyncFunction_nt() { + return 0; + }, + WX_SyncFunction_bs() { + return false; + }, + WX_SyncFunction_b() { + return false; + }, + WX_SyncFunction_bsnn() { + return false; + }, + WX_SyncFunction_ss() { return ""; }, - WX_SetCursor(path, x, y){ + WX_SyncFunction_tnn() { return ""; }, - WX_SetMessageToFriendQuery(option){ + WX_ClassFunction() {return ""}, + WX_ClassOneWayFunction() {return ""}, + WX_ClassSetProperty() {}, + WX_ClassOneWayNoFunction_v() {}, + WX_ClassOneWayNoFunction_vs() {}, + WX_ClassOneWayNoFunction_t() { return ""; }, - WX_GetTextLineHeight(option){ - return ""; - }, - WX_LoadFont(path){ - return ""; - }, - WX_GetGameLiveState(){ - return JSON.stringify({}); - }, - - WX_DownloadFile() {return ""}, - WX_CreateFeedbackButton() {return ""}, - WX_GetLogManager() {return ""}, - WX_GetRealtimeLogManager() {return ""}, - WX_GetUpdateManager() {return ""}, - WX_CreateVideoDecoder() {return ""}, - - WX_DownloadTaskAbort() {}, - WX_DownloadTaskOffHeadersReceived() {}, - WX_DownloadTaskOffProgressUpdate() {}, - WX_DownloadTaskOnHeadersReceived() {}, - WX_DownloadTaskOnProgressUpdate() {}, - WXFeedbackButtonSetProperty() {}, - WX_FeedbackButtonDestroy() {}, - WX_FeedbackButtonHide() {}, - WX_FeedbackButtonOffTap() {}, - WX_FeedbackButtonOnTap() {}, - WX_FeedbackButtonShow() {}, - WX_LogManagerDebug() {}, - WX_LogManagerInfo() {}, - WX_LogManagerLog() {}, - WX_LogManagerWarn() {}, - WX_RealtimeLogManagerAddFilterMsg() {}, - WX_RealtimeLogManagerError() {}, - WX_RealtimeLogManagerInfo() {}, - WX_RealtimeLogManagerSetFilterMsg() {}, - WX_RealtimeLogManagerWarn() {}, - WX_UpdateManagerApplyUpdate() {}, - WX_UpdateManagerOnCheckForUpdate() {}, - WX_UpdateManagerOnUpdateFailed() {}, - WX_UpdateManagerOnUpdateReady() {}, - WX_VideoDecoderGetFrameData() {}, - WX_VideoDecoderRemove() {}, - WX_VideoDecoderSeek() {}, - WX_VideoDecoderStart() {}, - WX_VideoDecoderStop() {}, - WX_VideoDecoderOff() {}, - WX_VideoDecoderOn() {}, - }; + WX_ClassOneWayNoFunction_vt() {}, + WX_ClassOnEventFunction() {}, + WX_ClassOffEventFunction() {}, }; var downloadedTextures = {}; var downloadingTextures = {}; var textureHandler = { diff --git a/package.json b/package.json index d69e710d..ee2c99a1 100644 --- a/package.json +++ b/package.json @@ -1 +1 @@ -{"name":"com.qq.weixin.minigame","displayName":"WXSDK","description":"WeChat Mini Game Tuanjie Engine Adapter SDK Package.","version":"0.1.21","unity":"2019.4","unityRelease":"29f1","keywords":["Tuanjie","WX"],"dependencies":{}} +{"name":"com.qq.weixin.minigame","displayName":"WXSDK","description":"WeChat Mini Game Tuanjie Engine Adapter SDK Package.","version":"0.1.22","unity":"2019.4","unityRelease":"29f1","keywords":["Tuanjie","WX"],"dependencies":{}}