org.fest.swing.fixture
Interface FocusableComponentFixture

All Known Subinterfaces:
CommonComponentFixture
All Known Implementing Classes:
DialogFixture, FrameFixture, GenericComponentFixture, JButtonFixture, JCheckBoxFixture, JComboBoxFixture, JFileChooserFixture, JInternalFrameFixture, JLabelFixture, JListFixture, JOptionPaneFixture, JPanelFixture, JPopupMenuFixture, JRadioButtonFixture, JScrollBarFixture, JScrollPaneFixture, JSliderFixture, JSpinnerFixture, JSplitPaneFixture, JTabbedPaneFixture, JTableFixture, JTextComponentFixture, JToggleButtonFixture, JToolBarFixture, JTreeFixture, WindowFixture

public interface FocusableComponentFixture

Understands simulation of input focus on a GUI component.

Author:
Alex Ruiz

Method Summary
 FocusableComponentFixture focus()
          Gives input focus to this fixture's GUI component.
 FocusableComponentFixture requireFocused()
          Asserts that this fixture's GUI component has input focus.
 

Method Detail

focus

FocusableComponentFixture focus()
Gives input focus to this fixture's GUI component.

Returns:
this fixture.
Throws:
IllegalStateException - if the component is disabled.
IllegalStateException - if the component is not showing on the screen.

requireFocused

FocusableComponentFixture requireFocused()
Asserts that this fixture's GUI component has input focus.

Returns:
this fixture.
Throws:
AssertionError - if this component does not have input focus.


Copyright © 2007-2011 FEST (Fixtures for Easy Software Testing). All Rights Reserved.