예제 #1
0
        /// <summary>
        /// Set the Scan mode
        /// </summary>
        /// <param name="scanModeSelected">Sets the selected scan mode specified in the ScanMode enum</param>
        public void SetScanMode(ScanMode scanModeSelected)
        {
            OpenOptionsPanel();

            if (!_controlPanel.ScrollPressWait("#hpid-option-scan-mode", "#hpid-option-scan-mode-screen", TimeSpan.FromSeconds(5)))
            {
                throw new DeviceWorkflowException("Unable to select scan mode option.");
            }

            _controlPanel.ScrollPress($"#hpid-scan-mode-selection-{scanModeSelected.ToString().ToLower()}");

            Pacekeeper.Sync();
            _controlPanel.PressWait(".hp-button-done", ".hp-option-list");
        }
예제 #2
0
            /// <summary>
            /// 指定されたスキャンモードの名称を取得します.
            /// </summary>
            /// <param name="scanMode">名称を取得したいスキャンモード</param>
            /// <returns>スキャンモードの名称</returns>
            public static string ToString(ScanMode scanMode)
            {
                string modeString = "";

                switch (scanMode)
                {
                case ScanMode.Automatic:
                    modeString = Properties.Strings.Automatic;
                    break;

                case ScanMode.SemiAuto:
                    modeString = Properties.Strings.SemiAuto;
                    break;

                default:
                    modeString = scanMode.ToString();
                    break;
                }
                return(modeString);
            }
예제 #3
0
 private static string createMessage(ScanMode _correctMode)
 {
     return("Scan mode need to be " + _correctMode.ToString() + ". ");
 }