use of jmri.jmrix.AbstractMonPaneScaffold in project JMRI by JMRI.
the class EcosMonPaneTest method checkAutoScrollCheckBox.
// Test checking the AutoScroll checkbox.
// for some reason the EcosMonPane has the checkbox value reversed on
// startup compared to other AbstractMonPane derivatives.
@Override
@Test
public void checkAutoScrollCheckBox() {
Assume.assumeFalse(GraphicsEnvironment.isHeadless());
AbstractMonPaneScaffold s = new AbstractMonPaneScaffold(pane);
// for Jemmy to work, we need the pane inside of a frame
JmriJFrame f = new JmriJFrame();
try {
pane.initComponents();
} catch (Exception ex) {
Assert.fail("Could not load pane: " + ex);
}
f.add(pane);
// set title if available
if (pane.getTitle() != null) {
f.setTitle(pane.getTitle());
}
f.pack();
f.setVisible(true);
Assert.assertTrue(s.getAutoScrollCheckBoxValue());
s.checkAutoScrollCheckBox();
Assert.assertFalse(s.getAutoScrollCheckBoxValue());
f.setVisible(false);
f.dispose();
}
use of jmri.jmrix.AbstractMonPaneScaffold in project JMRI by JMRI.
the class MrcMonPanelTest method checkAutoScrollCheckBox.
// Test checking the AutoScroll checkbox.
// for some reason the MrcMonPanel has the checkbox value reversed on
// startup compared to other AbstractMonPane derivatives.
@Override
@Test
public void checkAutoScrollCheckBox() {
Assume.assumeFalse(GraphicsEnvironment.isHeadless());
AbstractMonPaneScaffold s = new AbstractMonPaneScaffold(pane);
JmriJFrame f = new JmriJFrame();
try {
pane.initComponents();
} catch (Exception ex) {
Assert.fail("Could not load pane: " + ex);
}
f.add(pane);
// set title if available
if (pane.getTitle() != null) {
f.setTitle(pane.getTitle());
}
f.pack();
f.setVisible(true);
Assert.assertTrue(s.getAutoScrollCheckBoxValue());
s.checkAutoScrollCheckBox();
Assert.assertFalse(s.getAutoScrollCheckBoxValue());
f.setVisible(false);
f.dispose();
}
use of jmri.jmrix.AbstractMonPaneScaffold in project JMRI by JMRI.
the class LocoMonPaneTest method checkAutoScrollCheckBox.
// Test checking the AutoScroll checkbox.
// for some reason the LocoMonPane has the checkbox value reversed on
// startup compared to other AbstractMonPane derivatives.
@Override
@Test
public void checkAutoScrollCheckBox() {
Assume.assumeFalse(GraphicsEnvironment.isHeadless());
AbstractMonPaneScaffold s = new AbstractMonPaneScaffold(pane);
// for Jemmy to work, we need the pane inside of a frame
JmriJFrame f = new JmriJFrame();
try {
pane.initComponents();
} catch (Exception ex) {
Assert.fail("Could not load pane: " + ex);
}
f.add(pane);
// set title if available
if (pane.getTitle() != null) {
f.setTitle(pane.getTitle());
}
f.pack();
f.setVisible(true);
Assert.assertTrue(s.getAutoScrollCheckBoxValue());
s.checkAutoScrollCheckBox();
Assert.assertFalse(s.getAutoScrollCheckBoxValue());
f.setVisible(false);
f.dispose();
}
use of jmri.jmrix.AbstractMonPaneScaffold in project JMRI by JMRI.
the class NceMonPanelTest method checkAutoScrollCheckBox.
// Test checking the AutoScroll checkbox.
// for some reason the EcosMonPane has the checkbox value reversed on
// startup compared to other AbstractMonPane derivatives.
@Override
@Test
public void checkAutoScrollCheckBox() {
Assume.assumeFalse(GraphicsEnvironment.isHeadless());
AbstractMonPaneScaffold s = new AbstractMonPaneScaffold(pane);
// for Jemmy to work, we need the pane inside of a frame
JmriJFrame f = new JmriJFrame();
try {
pane.initComponents();
} catch (Exception ex) {
Assert.fail("Could not load pane: " + ex);
}
f.add(pane);
// set title if available
if (pane.getTitle() != null) {
f.setTitle(pane.getTitle());
}
f.pack();
f.setVisible(true);
Assert.assertTrue(s.getAutoScrollCheckBoxValue());
s.checkAutoScrollCheckBox();
Assert.assertFalse(s.getAutoScrollCheckBoxValue());
f.setVisible(false);
f.dispose();
}
Aggregations