PositionData.initializeValues C# (CSharp) Method

initializeValues() private method

private initializeValues ( ) : void
return void
    private void initializeValues()
    {
        RectTransform rect = GetComponent<RectTransform>();
        Vector3 rightUpper = new Vector3(Screen.width * rect.anchorMax.x, Screen.height * rect.anchorMax.y, 0);
        rightUpper = Camera.main.ScreenToWorldPoint(rightUpper);
        positionXMax = rightUpper.x;
        positionYMax = rightUpper.y;
        Vector3 leftLower = new Vector3(Screen.width * rect.anchorMin.x, Screen.height * rect.anchorMin.y, 0);
        leftLower = Camera.main.ScreenToWorldPoint(leftLower);
        positionXMin = leftLower.x;
        positionYMin = leftLower.y;
    }