浏览代码

fix direct lineTo issue in canvas.

/main
kg 6 年前
当前提交
8bfe5534
共有 2 个文件被更改,包括 14 次插入0 次删除
  1. 7
      Runtime/ui/painting/path.cs
  2. 7
      README-ZH.md.meta

7
Runtime/ui/painting/path.cs


var cmd = (PathCommand) commands[i];
switch (cmd) {
case PathCommand.moveTo:
this._commandx = commands[i + 1];
this._commandy = commands[i + 2];
i += 3;
break;
this._expandBounds(this._commandx, this._commandy);
this._expandBounds(commands[i + 1], commands[i + 2]);
this._commandx = commands[i + 1];
this._commandy = commands[i + 2];

this._expandBounds(this._commandx, this._commandy);
this._expandBounds(commands[i + 1], commands[i + 2]);
this._expandBounds(commands[i + 3], commands[i + 4]);
this._expandBounds(commands[i + 5], commands[i + 6]);

void _addPoint(PathPoint point) {
if (this._paths.Count == 0) {
this.addPath();
this.addPoint(0, 0, PointFlags.corner);
}
var path = this._paths.Last();

7
README-ZH.md.meta


fileFormatVersion: 2
guid: 10bb16e0fd5d84445aa576a308664220
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
正在加载...
取消
保存