浏览代码

minor fixes

/main
Xingwei Zhu 3 年前
当前提交
7fa01859
共有 2 个文件被更改,包括 7 次插入3 次删除
  1. 7
      com.unity.uiwidgets/Runtime/async/stream_multi.cs
  2. 3
      com.unity.uiwidgets/Runtime/async/stream_transformers.cs

7
com.unity.uiwidgets/Runtime/async/stream_multi.cs


using System;
namespace Unity.UIWidgets.async {
/**
* Stream.multi is not supported by flutter 1.17.5 yet, but it might be useful for developers. To address this issue, we put all the necessary codes for this feature
* in this single file.
*
* [TODO] remove this code when we eventually upgrade UIWidgets to above 2.0
*/
public class StreamMultiUtils<T>
{
public static Stream<T> multi(Action<MultiStreamController<T>> onListen, bool isBroadcast = false) {

3
com.unity.uiwidgets/Runtime/async/stream_transformers.cs


using System;
using Unity.UIWidgets.async;
using UnityEngine;
namespace Unity.UIWidgets.async {
class _EventSinkWrapper<T> : EventSink<T> {

_handleData(data, _sink);
}
else {
Debug.Log("potential bad type casting !!!!");
_sink.add((T)((object)data));
}
}

正在加载...
取消
保存