Package FlaNium.WinAPI.elements
Class Window
- java.lang.Object
-
- org.openqa.selenium.remote.RemoteWebElement
-
- FlaNium.WinAPI.DesktopElement
-
- FlaNium.WinAPI.elements.Window
-
- All Implemented Interfaces:
org.openqa.selenium.interactions.Locatable,org.openqa.selenium.SearchContext,org.openqa.selenium.TakesScreenshot,org.openqa.selenium.WebElement,org.openqa.selenium.WrapsDriver
public class Window extends DesktopElement
-
-
Constructor Summary
Constructors Constructor Description Window(org.openqa.selenium.WebElement element)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()Closes the window.MenucontextMenu()Gets the context menu for the window.booleanisModal()Gets if the window is modal.List<Window>modalWindows()Gets a list of all modal child windows.voidmove(int x, int y)Moves the window to the given coordinates.TitleBarpopup()Gets the current WPF popup window.voidsetTransparency(byte alpha)Brings the element to the foreground.Stringtitle()Gets the title of the window.TitleBartitleBar()Gets the "TitleBar" of the window.-
Methods inherited from class FlaNium.WinAPI.DesktopElement
callValueCommand, callValueCommand, callValueCommand, callValueCommand, callValueCommand, callValueCommand, callVoidCommand, castTo, createLocalDateTimeFromResponse, createRemoteWebElementFromResponse, createRemoteWebElementsFromResponse, exe, execute, getActiveWindow, getAttribute, getElementRect, getName, mouseActions, parseDateTime, parseDouble, screenshotActions, setAsRootElement, toCoordinateElement, touchActions
-
Methods inherited from class org.openqa.selenium.remote.RemoteWebElement
clear, click, equals, execute, findElement, findElement, findElements, findElements, getAccessibleName, getAriaRole, getCoordinates, getCssValue, getDomAttribute, getDomProperty, getId, getLocation, getRect, getScreenshotAs, getShadowRoot, getSize, getTagName, getText, getWrappedDriver, hashCode, isDisplayed, isEnabled, isSelected, sendKeys, setFileDetector, setFoundBy, setId, setParent, submit, toJson, toString
-
-
-
-
Method Detail
-
title
public String title()
Gets the title of the window.- Returns:
-
isModal
public boolean isModal()
Gets if the window is modal.- Returns:
-
titleBar
public TitleBar titleBar()
Gets the "TitleBar" of the window.- Returns:
-
popup
public TitleBar popup()
Gets the current WPF popup window.- Returns:
-
contextMenu
public Menu contextMenu()
Gets the context menu for the window. Note: It uses the FrameworkType of the window as lookup logic. Use "GetContextMenuByFrameworkType" if you want to control this.- Returns:
-
close
public void close()
Closes the window.
-
move
public void move(int x, int y)Moves the window to the given coordinates.- Parameters:
x-y-
-
setTransparency
public void setTransparency(byte alpha)
Brings the element to the foreground.- Parameters:
alpha-
-
-