C# Класс ACAT.Lib.Extension.AppAgents.WindowsExplorer.WindowsExplorerAgentBase

Base class application agent for Windows Explorer. Enables navigation through files and folders in Explorer, create folders, clipboard operations, opening files etc.
Наследование: ACAT.Lib.Core.AgentManagement.GenericAppAgentBase
Показать файл Открыть проект

Защищенные свойства (Protected)

Свойство Тип Описание
autoSwitchScanners bool

Открытые методы

Метод Описание
CheckWidgetEnabled ( ACAT.Lib.Core.AgentManagement.CheckEnabledArgs arg ) : void

Invoked to set the 'enabled' state of a widget. This will depend on the current context.

OnContextMenuRequest ( ACAT.Lib.Core.Utility.WindowActivityMonitorInfo monitorInfo ) : void

Displays the contextual menu

OnFocusChanged ( ACAT.Lib.Core.Utility.WindowActivityMonitorInfo monitorInfo, bool &handled ) : void

Invoked when the foreground window focus changes. Depending on which element has focus in the acrobat reader window, display the appropriate scanner

OnFocusLost ( ) : void

Focus shifted to another app. This agent is getting deactivated.

OnRunCommand ( String command, object commandArg, bool &handled ) : void

Invoked to run a command

Защищенные методы

Метод Описание
getMenu ( ACAT.Lib.Core.Utility.WindowActivityMonitorInfo monitorInfo, String &panelClass ) : bool

Gets the menu for the Explorer window in focus. Checks if the file explorer is active and returns the contextual menu name for it

getWindowElement ( IntPtr hWndMain ) : AutomationElement

Returns the automation element for the window handle

isDesktopWindow ( AutomationElement focusedElement ) : bool

Checks if the focused element is the desktop

isFileExplorer ( AutomationElement windowElement ) : bool

Checks if the window element is the Windows Explorer window

Приватные методы

Метод Описание
displayScanner ( ACAT.Lib.Core.Utility.WindowActivityMonitorInfo monitorInfo, bool &handled ) : void

Displays the scanner appropriate for the element that is currently in focus in the Windows explorer window

showMenu ( String menuName, String title ) : void

Dispays the menu indicated by the menu name

Описание методов

CheckWidgetEnabled() публичный Метод

Invoked to set the 'enabled' state of a widget. This will depend on the current context.
public CheckWidgetEnabled ( ACAT.Lib.Core.AgentManagement.CheckEnabledArgs arg ) : void
arg ACAT.Lib.Core.AgentManagement.CheckEnabledArgs contains info about the widget
Результат void

OnContextMenuRequest() публичный Метод

Displays the contextual menu
public OnContextMenuRequest ( ACAT.Lib.Core.Utility.WindowActivityMonitorInfo monitorInfo ) : void
monitorInfo ACAT.Lib.Core.Utility.WindowActivityMonitorInfo Foreground window info
Результат void

OnFocusChanged() публичный Метод

Invoked when the foreground window focus changes. Depending on which element has focus in the acrobat reader window, display the appropriate scanner
public OnFocusChanged ( ACAT.Lib.Core.Utility.WindowActivityMonitorInfo monitorInfo, bool &handled ) : void
monitorInfo ACAT.Lib.Core.Utility.WindowActivityMonitorInfo Foreground window info
handled bool set to true if handled
Результат void

OnFocusLost() публичный Метод

Focus shifted to another app. This agent is getting deactivated.
public OnFocusLost ( ) : void
Результат void

OnRunCommand() публичный Метод

Invoked to run a command
public OnRunCommand ( String command, object commandArg, bool &handled ) : void
command String The command to execute
commandArg object Optional arguments for the command
handled bool set this to true if handled
Результат void

getMenu() защищенный Метод

Gets the menu for the Explorer window in focus. Checks if the file explorer is active and returns the contextual menu name for it
protected getMenu ( ACAT.Lib.Core.Utility.WindowActivityMonitorInfo monitorInfo, String &panelClass ) : bool
monitorInfo ACAT.Lib.Core.Utility.WindowActivityMonitorInfo fg window info
panelClass String returns the panel class of the menu
Результат bool

getWindowElement() защищенный Метод

Returns the automation element for the window handle
protected getWindowElement ( IntPtr hWndMain ) : AutomationElement
hWndMain System.IntPtr window handle
Результат System.Windows.Automation.AutomationElement

isDesktopWindow() защищенный Метод

Checks if the focused element is the desktop
protected isDesktopWindow ( AutomationElement focusedElement ) : bool
focusedElement System.Windows.Automation.AutomationElement element in focus
Результат bool

isFileExplorer() защищенный Метод

Checks if the window element is the Windows Explorer window
protected isFileExplorer ( AutomationElement windowElement ) : bool
windowElement System.Windows.Automation.AutomationElement element in focus
Результат bool

Описание свойств

autoSwitchScanners защищенное свойство

If set to true, the agent will autoswitch the scanners depending on which element has focus. Eg: Alphabet scanner if an edit text window has focus, the contextual menu if the main document has focus
protected bool autoSwitchScanners
Результат bool