Exemplo n.º 1
0
        public Vector2 GetMessageWindowPosition(EODHeight height, EODTextTips tips, bool expanded)
        {
            var topLeftHeight = height;

            if (height == EODHeight.TallTall)
            {
                topLeftHeight = EODHeight.Tall;
            }
            var position = GetTopLeft(topLeftHeight);

            if (tips == EODTextTips.Long)
            {
                position += (Vector2)Script.GetControlProperty("EODMsgWinLong", "position");
            }
            else
            {
                position += (Vector2)Script.GetControlProperty("EODMsgWinShort", "position");
            }

            if (height == EODHeight.TallTall && expanded)
            {
                position += (Vector2)Script.GetControlProperty("EODDoublePanelMsgOffset");
            }
            return(position);
        }
Exemplo n.º 2
0
 public Vector2 GetChromeOffset(EODHeight height)
 {
     switch (height)
     {
     case EODHeight.Tall:
     case EODHeight.TallTall:
         return(new Vector2(0, -20));
     }
     return(Vector2.Zero);
 }
Exemplo n.º 3
0
        public Vector2 GetPanelPosition(EODHeight height)
        {
            switch (height)
            {
            case EODHeight.TallTall:
                return(GetTopLeft(EODHeight.TallTall) + (Vector2)Script.GetControlProperty("EODBackgroundOffsetTallTall"));

            default:
                return(GetTopLeft(height));
            }
        }
Exemplo n.º 4
0
        public Vector2 GetMessageWindowTextPosition(EODHeight height, bool expanded)
        {
            var topLeftHeight = height;

            if (height == EODHeight.TallTall)
            {
                topLeftHeight = EODHeight.Tall;
            }
            var position = GetTopLeft(topLeftHeight) + (Vector2)Script.GetControlProperty("MsgWinTextEntry", "position");

            if (height == EODHeight.TallTall && expanded)
            {
                position += (Vector2)Script.GetControlProperty("EODDoublePanelMsgOffset");
            }
            return(position);
        }
Exemplo n.º 5
0
        public Vector2 GetOffset(EODHeight height)
        {
            switch (height)
            {
            case EODHeight.Normal:
                return((Vector2)Script.GetControlProperty("EODActiveOffset"));

            case EODHeight.Tall:
                return((Vector2)Script.GetControlProperty("EODActiveOffsetTall"));

            case EODHeight.Trade:
                return((Vector2)Script.GetControlProperty("EODActiveOffsetTrade"));

            case EODHeight.TallTall:
                return((Vector2)Script.GetControlProperty("EODActiveOffsetTallTall"));
            }
            throw new Exception("Unknown eod height");
        }
Exemplo n.º 6
0
        public Vector2 GetTimerTextPosition(EODHeight height, bool expanded)
        {
            var topLeftHeight = height;

            if (height == EODHeight.TallTall)
            {
                topLeftHeight = EODHeight.Tall;
                var position = GetTopLeft(topLeftHeight) + (Vector2)Script.GetControlProperty("TimerTextEntry", "position");
                if (expanded)
                {
                    position += (Vector2)Script.GetControlProperty("EODDoublePanelMsgOffset");
                }
                return(position);
            }
            else
            {
                return(GetTopLeft(height) + (Vector2)Script.GetControlProperty("TimerTextEntry", "position"));
            }
        }
Exemplo n.º 7
0
        public string GetHeightSuffix(EODHeight height, bool considerDoubleAsTall)
        {
            switch (height)
            {
            case EODHeight.Tall:
                return("Tall");

            case EODHeight.TallTall:
                if (considerDoubleAsTall)
                {
                    return("Tall");
                }
                else
                {
                    return("");
                }

            default:
                return("");
            }
        }
Exemplo n.º 8
0
 public Vector2 GetExpandBackPosition(EODHeight height)
 {
     return(GetPanelPosition(EODHeight.Tall) + (Vector2)Script.GetControlProperty("EODExpandBack", "position"));
 }
Exemplo n.º 9
0
 public Vector2 GetContractButtonPosition(EODHeight height)
 {
     return(Baseline + (Vector2)Script.GetControlProperty("EODContractButton", "position"));
 }
Exemplo n.º 10
0
 public Vector2 GetChromePosition(string control, EODHeight height)
 {
     return(Baseline + (Vector2)Script.GetControlProperty(control, "position") + GetChromeOffset(height));
 }
Exemplo n.º 11
0
 /// <summary>
 /// Top left of the EOD, this is where the EOD plugin itself is placed
 /// </summary>
 /// <param name="height"></param>
 /// <returns></returns>
 public Vector2 GetTopLeft(EODHeight height)
 {
     return(Baseline - GetOffset(height));
 }
Exemplo n.º 12
0
 public string GetHeightSuffix(EODHeight height)
 {
     return(GetHeightSuffix(height, false));
 }
Exemplo n.º 13
0
 public Vector2 GetTimerTextPosition(EODHeight height)
 {
     return(GetTopLeft(height) + (Vector2)Script.GetControlProperty("TimerTextEntry", "position"));
 }