public override void NavigateTo()
 {
     ToolsButton.Click();
     ManageEmployeesButton.Click();
     //Verify the Manage Employees page actually loaded
     driver.Title.Should().Be("ATM - Manage Employees", "the Manage Employees Page should have loaded");
 }
    public static string GetCommand()
    {
        if (currentSelectedButton)
        {
            ToolsButton tools = currentSelectedButton.GetComponent <ToolsButton>();
            if (tools)
            {
                return(tools.command);
            }
        }

        return(null);
    }
示例#3
0
        public ToggleButton AddToggleButton(ToolsButton toolsButton, Keys shortcutKey)
        {
            ToggleButton button = this.AddToggleButton(toolsButton);

#if FRB_XNA
            if (shortcutKey != Keys.None)
#endif
            {
                mShortcutAssociation.Add(shortcutKey, button);
            }

            return(button);
        }
示例#4
0
        public ToggleButton AddToggleButton(ToolsButton toolsButton)
        {
            // since MDX doesn't have the .None enum for Key, code duplication is happening:

            ToggleButton button = this.AddToggleButton();

            int    row, column;
            string text;

            GetRowAndColumnFor(toolsButton, out row, out column, out text);

            button.Text = text;
            button.SetOverlayTextures(column, row);

            return(button);
        }
示例#5
0
 public override void NavigateTo()
 {
     ToolsButton.Click();
     ManageRoutesButton.Click();
 }
示例#6
0
        private void GetRowAndColumnFor(ToolsButton toolsButton, out int row, out int column, out string buttonText)
        {

            switch (toolsButton)
            {
                case ToolsButton.Move:
                    row = 0;
                    column = 2;
                    buttonText = "Move";
                    break;
                case ToolsButton.Rotate:
                    row = 0;
                    column = 0;
                    buttonText = "Rotate";
                    break;
                case ToolsButton.Scale:
                    row = 0;
                    column = 1;
                    buttonText = "Scale";
                    break;
                case ToolsButton.Attach:
                    row = 0;
                    column = 7;
                    buttonText = "Attach";
                    break;
                case ToolsButton.Detach:
                    row = 0;
                    column = 10;
                    buttonText = "Detach";
                    break;
                case ToolsButton.Copy:
                    row = 0;
                    column = 9;
                    buttonText = "Duplicate";
                    break;
                case ToolsButton.Play:
                    row = 1;
                    column = 9;
                    buttonText = "Play";
                    break;
                case ToolsButton.Stop:
                    row = 1;
                    column = 11;
                    buttonText = "Stop";
                    break;
                case ToolsButton.Rewind:
                    row = 1;
                    column = 10;
                    buttonText = "Rewind";
                    break;
                default:
                    row = 0;
                    column = 0;
                    buttonText = "";
                    break;
            }
        }
示例#7
0
        public ToggleButton AddToggleButton(ToolsButton toolsButton, Keys shortcutKey)
        {
            ToggleButton button = this.AddToggleButton(toolsButton);

#if FRB_XNA
            if (shortcutKey != Keys.None)
#endif
            {
                mShortcutAssociation.Add(shortcutKey, button);
            }

            return button;
        }
示例#8
0
        public ToggleButton AddToggleButton(ToolsButton toolsButton)
        {
            // since MDX doesn't have the .None enum for Key, code duplication is happening:

            ToggleButton button = this.AddToggleButton();

            int row, column;
            string text;

            GetRowAndColumnFor(toolsButton, out row, out column, out text);

            button.Text = text;
            button.SetOverlayTextures(column, row);

            return button;
        }
示例#9
0
        private void GetRowAndColumnFor(ToolsButton toolsButton, out int row, out int column, out string buttonText)
        {
            switch (toolsButton)
            {
            case ToolsButton.Move:
                row        = 0;
                column     = 2;
                buttonText = "Move";
                break;

            case ToolsButton.Rotate:
                row        = 0;
                column     = 0;
                buttonText = "Rotate";
                break;

            case ToolsButton.Scale:
                row        = 0;
                column     = 1;
                buttonText = "Scale";
                break;

            case ToolsButton.Attach:
                row        = 0;
                column     = 7;
                buttonText = "Attach";
                break;

            case ToolsButton.Detach:
                row        = 0;
                column     = 10;
                buttonText = "Detach";
                break;

            case ToolsButton.Copy:
                row        = 0;
                column     = 9;
                buttonText = "Duplicate";
                break;

            case ToolsButton.Play:
                row        = 1;
                column     = 9;
                buttonText = "Play";
                break;

            case ToolsButton.Stop:
                row        = 1;
                column     = 11;
                buttonText = "Stop";
                break;

            case ToolsButton.Rewind:
                row        = 1;
                column     = 10;
                buttonText = "Rewind";
                break;

            default:
                row        = 0;
                column     = 0;
                buttonText = "";
                break;
            }
        }
示例#10
0
 /// <summary>
 /// Click the 'Tools' button and select 'Log in as Applicant'
 /// </summary>
 public void LoginAsApplicant()
 {
     ToolsButton.WaitRetry(_driver).Click();
     LogInAsApplicantOption.WaitRetry(_driver).Click();
 }
示例#11
0
        /// <summary>
        /// 数据转换到控件
        /// </summary>
        protected ToolsBarSetting DataConvterCtrl(ToolsBarData BarData)
        {
            string          pathbase = Lemon.GetCSFRootDirectory();
            ToolsBarSetting result   = new ToolsBarSetting();

            //工具栏
            foreach (TBar tbar in BarData.Bars)
            {
                ToolsBar newBar = new ToolsBar();
                newBar.ParentFormName = tbar.ParentFormName;
                newBar.ToolsBarCode   = tbar.ToolsBarCode;
                newBar.ToolsBarName   = tbar.ToolsBarName;
                result.Bars.Add(newBar);
            }
            //按钮
            foreach (TButton tbtn in BarData.Buttons)
            {
                ToolsButton newBtn = new ToolsButton();
                newBtn.AssemblyPath  = pathbase + tbtn.Assembly;
                newBtn.FullClassName = tbtn.FullClassName;
                newBtn.GroupName     = tbtn.GroupName;
                newBtn.ItemImage     = pathbase + tbtn.ItemImage;
                newBtn.ItemIndex     = tbtn.ItemIndex;
                newBtn.Title         = tbtn.Title;
                newBtn.ToolsBarCode  = tbtn.ToolsBarCode;
                IControlToolsButton elm = Lemon.GetInstance <IControlToolsButton>(newBtn.AssemblyPath, newBtn.FullClassName);
                if (elm != null)
                {
                    newBtn.UIElement = elm;
                    result.Buttons.Add(newBtn);
                }
                else
                {
                    Lemon.SendMsgDebug("配置的工具栏按钮" + newBtn.ToolsBarCode + "没有实现IUIElement接口");
                }
            }
            //下拉框
            foreach (TComboBox tcb in BarData.ComboBoxs)
            {
                ToolsComboBox newCb = new ToolsComboBox();
                newCb.GroupName    = tcb.GroupName;
                newCb.ItemIndex    = tcb.ItemIndex;
                newCb.ToolsBarCode = tcb.ToolsBarCode;
                IControlToolsComoBoxItem cbelm = Lemon.GetInstance <IControlToolsComoBoxItem>(tcb.Assembly, tcb.FullClassName);
                if (cbelm != null)
                {
                    newCb.UIElement = cbelm;
                }
                else
                {
                    Lemon.SendMsgDebug("配置的工具栏下拉框" + newCb.ToolsBarCode + "没有实现IUIElement接口");
                }
                foreach (TComboBoxItem ti in tcb.Items)
                {
                    ToolsComboBoxItem newItem = new ToolsComboBoxItem();
                    ti.Assembly      = pathbase + ti.Assembly;
                    newItem.ItemData = ti;
                    IControlToolsComoBoxItem elm = Lemon.GetInstance <IControlToolsComoBoxItem>(ti.Assembly, ti.FullClassName);
                    if (elm != null)
                    {
                        newItem.UIElement = elm;
                        newCb.Items.Add(newItem);
                    }
                    else
                    {
                        Lemon.SendMsgDebug("配置的工具栏下拉框的选项" + ti.Title + "没有实现IUIElement接口");
                    }
                }
                result.ComboBoxs.Add(newCb);
            }
            //分栏
            foreach (TSeparator tsep in BarData.Separator)
            {
                ToolsSeparator newSep = new ToolsSeparator();
                newSep.GroupName    = tsep.GroupName;
                newSep.ItemIndex    = tsep.ItemIndex;
                newSep.ToolsBarCode = tsep.ToolsBarCode;
                result.Separator.Add(newSep);
            }
            return(result);
        }