您最多选择25个主题
主题必须以中文或者字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
38 行
920 B
38 行
920 B
using UnityEngine;
|
|
using Rect = UIWidgets.ui.Rect;
|
|
using Canvas = UIWidgets.ui.Canvas;
|
|
|
|
namespace UIWidgets.flow {
|
|
public class PrerollContext {
|
|
public RasterCache rasterCache;
|
|
}
|
|
|
|
public class PaintContext {
|
|
public Canvas canvas;
|
|
}
|
|
|
|
public abstract class Layer {
|
|
private ContainerLayer _parent;
|
|
|
|
public ContainerLayer parent {
|
|
get { return this._parent; }
|
|
set { this._parent = value; }
|
|
}
|
|
|
|
private Rect _paintBounds = Rect.zero;
|
|
|
|
public Rect paintBounds {
|
|
get { return this._paintBounds; }
|
|
set { this._paintBounds = value; }
|
|
}
|
|
|
|
public bool needsPainting {
|
|
get { return !this._paintBounds.isEmpty; }
|
|
}
|
|
|
|
public virtual void preroll(PrerollContext context, Matrix4x4 matrix) {
|
|
}
|
|
|
|
public abstract void paint(PaintContext context);
|
|
}
|
|
}
|