コード例 #1
0
        private static void OAuthOnReplyNative(ref NativeBindings.OAuthResponseNative response)
        {
            NativeBindings.OAuthResponseNative newResponse = response;

            int contextHash = newResponse.Context.ToInt32();

            if (oAuthCallbacks.TryGetValue(contextHash, out OAuthPair currentPair))
            {
                MLThreadDispatch.Call(response.Response, currentPair.Schema, currentPair.Callback);
                return;
            }

            MLPluginLog.ErrorFormat("MLDispatch OAuth callback received with no context");
        }
コード例 #2
0
        private static void HandleOnMLAudioSetMicMuteCallback([MarshalAs(UnmanagedType.I1)] bool isMuted, IntPtr callback)
        {
            Instance.isMicrophoneMuted = isMuted;

            MLThreadDispatch.Call(isMuted, OnMicrophoneMuteChanged);
        }
コード例 #3
0
        private static void HandleOnMLAudioSetMasterVolumeCallback(float volume, IntPtr callback)
        {
            Instance.masterVolume = volume;

            MLThreadDispatch.Call(volume, OnMasterVolumeChanged);
        }