public static void Put(IHeatmapHandler component) { var wComp = component as WindowComponent; var corners = new Vector3[4]; (wComp.transform as RectTransform).GetWorldCorners(corners); var leftBottom = HeatmapSystem.GetScreenPoint(wComp, corners[0]); //var topRight = HeatmapSystem.GetScreenPoint(wComp, corners[2]); var inputPosition = WindowSystemInput.GetPointerPosition(); //var w = topRight.x - leftBottom.x; //var h = topRight.y - leftBottom.y; var pos = new Vector2(inputPosition.x - leftBottom.x, inputPosition.y - leftBottom.y); HeatmapSystem.Put(component, pos, ClickType.Component); }
public static void Put() { HeatmapSystem.Put(null, WindowSystemInput.GetPointerPosition(), ClickType.Screen); }