浏览代码

Merge branch 'master' into siyaoH/1.17/grid

/main
siyao 3 年前
当前提交
b6d68eb0
共有 9 个文件被更改,包括 6 次插入5 次删除
  1. 2
      README-ZH.md
  2. 2
      README.md
  3. 2
      com.unity.uiwidgets/Runtime/engine/UIWidgetsPanel.cs
  4. 4
      com.unity.uiwidgets/Runtime/widgets/title.cs
  5. 1
      engine/src/lib/ui/window/pointer_data_packet_converter.cc

2
README-ZH.md


#### Wiki
目前开发团队仍在改进UIWidgets Wiki。 由于UIWidgets主要来源于Flutter,你也可以参考Flutter Wiki中与UIWidgets API对应部分的详细描述。
同时,你可以加入我们的讨论组( https://learn.unity.com/g/uiwidgets )
同时,你也可以加入我们的[讨论组](https://unity.cn/plate/uiwidgets)来和大家交流使用心得
#### 常问问题解答

2
README.md


The develop team is still working on the UIWidgets Wiki. However, since UIWidgets is mainly derived from Flutter,
you can refer to Flutter Wiki to access detailed descriptions of UIWidgets APIs
from those of their Flutter counterparts.
Meanwhile, you can join the discussion channel at (https://learn.unity.com/g/uiwidgets)
Meanwhile, you can join our [discussion channel](https://unity.cn/plate/uiwidgets) to keep in touch with the community.
#### FAQ

2
com.unity.uiwidgets/Runtime/engine/UIWidgetsPanel.cs


}
Vector2? _getPointerPosition(Vector2 position) {
var worldCamera = canvas.worldCamera;
var worldCamera = canvas.renderMode == RenderMode.ScreenSpaceOverlay ? null : canvas.worldCamera;
if (RectTransformUtility.ScreenPointToLocalPointInRectangle(
rect: rectTransform, screenPoint: position, cam: worldCamera, out var localPoint)) {
var scaleFactor = canvas.scaleFactor;

4
com.unity.uiwidgets/Runtime/widgets/title.cs


Widget child = null
) : base(key: key) {
D.assert(title != null);
D.assert(color != null && color.alpha == 0xFF);
//in flutter, the background color is not allowed to be transparent because there is nothing behind the UI. But in UIWidgets it is
//possible to put a unity scene under the ui panel. Therefore we can discard the assertion on "color.alpha == 0xFF" here
D.assert(color != null);
this.color = color;
this.child = child;
this.title = title;

1
engine/src/lib/ui/window/pointer_data_packet_converter.cc


PointerData synthesized_hover_event = pointer_data;
synthesized_hover_event.change = PointerData::Change::kHover;
synthesized_hover_event.synthesized = 1;
synthesized_hover_event.buttons = state.previous_buttons;
UpdateDeltaAndState(synthesized_hover_event, state);
converted_pointers.push_back(synthesized_hover_event);

部分文件因为文件数量过多而无法显示

正在加载...
取消
保存