Package org.fest.swing.driver
Class JSplitPaneDriver
java.lang.Object
org.fest.swing.driver.ComponentDriver
org.fest.swing.driver.ContainerDriver
org.fest.swing.driver.JComponentDriver
org.fest.swing.driver.JSplitPaneDriver
Understands functional testing of
JSplitPanes:
- user input simulation
- state verification
- property value query
org.fest.swing.fixture in your tests.-
Field Summary
Fields inherited from class org.fest.swing.driver.ComponentDriver
robot -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidmoveDividerTo(JSplitPane splitPane, int location) Sets the divider position to an absolute position.private voidsimulateMovingDivider(JSplitPane split, int location) private voidsimulateMovingDivider(JSplitPane splitPane, GenericRange<Point> range) private voidsimulateMovingDividerHorizontally(JSplitPane splitPane, int location) private voidsimulateMovingDividerVertically(JSplitPane splitPane, int location) private static GenericRange<Point>validateAndFindWhereToMoveDividerHorizontally(JSplitPane splitPane, int location) private static GenericRange<Point>validateAndFindWhereToMoveDividerVertically(JSplitPane splitPane, int location) private static GenericRange<Point>whereToMoveDividerHorizontally(JSplitPane splitPane, int location) private static GenericRange<Point>whereToMoveDividerVertically(JSplitPane splitPane, int location) Methods inherited from class org.fest.swing.driver.JComponentDriver
clientProperty, invokeAction, isVisible, isVisible, requireToolTip, requireToolTip, scrollToVisibleMethods inherited from class org.fest.swing.driver.ContainerDriver
move, resize, resizeHeight, resizeWidthMethods inherited from class org.fest.swing.driver.ComponentDriver
assertIsEnabledAndShowing, click, click, click, click, click, doubleClick, drag, dragOver, drop, focus, focusAndWaitForFocusGain, invokePopupMenu, invokePopupMenu, moveMouseIgnoringAnyError, moveMouseIgnoringAnyError, performAccessibleActionOf, pressAndReleaseKey, pressAndReleaseKey, pressAndReleaseKeys, pressKey, propertyName, releaseKey, requireDisabled, requireEnabled, requireEnabled, requireFocused, requireNotVisible, requireSize, requireVisible, rightClick, settings, waitForShowing
-
Constructor Details
-
JSplitPaneDriver
Creates a newJSplitPaneDriver.- Parameters:
robot- the robot to use to simulate user input.
-
-
Method Details
-
moveDividerTo
Sets the divider position to an absolute position.Since 1.2, this method respects the minimum and maximum values of the left and right components inside the given
JSplitPane.- Parameters:
splitPane- the targetJSplitPane.location- the location to move the divider to.- Throws:
IllegalStateException- if theJSplitPaneis disabled.IllegalStateException- if theJSplitPaneis not showing on the screen.
-
simulateMovingDivider
-
simulateMovingDividerVertically
-
validateAndFindWhereToMoveDividerVertically
@RunsInEDT private static GenericRange<Point> validateAndFindWhereToMoveDividerVertically(JSplitPane splitPane, int location) -
whereToMoveDividerVertically
@RunsInCurrentThread private static GenericRange<Point> whereToMoveDividerVertically(JSplitPane splitPane, int location) -
simulateMovingDividerHorizontally
-
validateAndFindWhereToMoveDividerHorizontally
@RunsInEDT private static GenericRange<Point> validateAndFindWhereToMoveDividerHorizontally(JSplitPane splitPane, int location) -
whereToMoveDividerHorizontally
@RunsInCurrentThread private static GenericRange<Point> whereToMoveDividerHorizontally(JSplitPane splitPane, int location) -
simulateMovingDivider
-