Search in sources :

Example 1 with Stage

use of limelight.model.Stage in project limelight by slagyr.

the class JavaProductionTest method loadsStagesWithOptions.

@Test
public void loadsStagesWithOptions() throws Exception {
    assumeTrue(TestUtil.notHeadless());
    fs.createTextFile("/testProduction/stages.xml", "<stages><egats title='Eureka!'/></stages>");
    production.loadStages();
    final Stage stage = production.getTheater().get("egats");
    assertEquals(FramedStage.class, stage.getClass());
    FramedStage framedStage = (FramedStage) stage;
    assertEquals("Eureka!", framedStage.getTitle());
}
Also used : Stage(limelight.model.Stage) FramedStage(limelight.ui.model.FramedStage) FramedStage(limelight.ui.model.FramedStage) Test(org.junit.Test)

Example 2 with Stage

use of limelight.model.Stage in project limelight by slagyr.

the class JavaProductionTest method loadsStages.

@Test
public void loadsStages() throws Exception {
    assumeTrue(TestUtil.notHeadless());
    fs.createTextFile("/testProduction/stages.xml", "<stages><egats/></stages>");
    production.loadStages();
    final Stage stage = production.getTheater().get("egats");
    assertNotNull(stage);
    assertEquals("egats", stage.getName());
}
Also used : Stage(limelight.model.Stage) FramedStage(limelight.ui.model.FramedStage) Test(org.junit.Test)

Example 3 with Stage

use of limelight.model.Stage in project limelight by slagyr.

the class UtilitiesTest method riggerScene.

@Test
public void riggerScene() throws Exception {
    utilities.openRigger();
    final Stage stage = production.getTheater().get("rigger");
    assertEquals(true, stage.isOpen());
    assertEquals("rigger", stage.getScene().getAbsoluteName());
}
Also used : Stage(limelight.model.Stage) FramedStage(limelight.ui.model.FramedStage)

Example 4 with Stage

use of limelight.model.Stage in project limelight by slagyr.

the class Devtool method refresh.

public void refresh(Event e) {
    PanelEvent event = (PanelEvent) e;
    final Production production = event.getRecipient().getRoot().getProduction();
    final List<Stage> stages = production.getTheater().getStages();
    for (Stage stage : stages) {
        production.openScene(stage.getScene().getResourceLoader().getRoot(), stage, new Opts());
    }
//      (let [scene (.getRoot (.getRecipient e))
//        stage (.getStage scene)
//        production (.getProduction scene)
//        stages (.getStages (.getTheater production))]
//    (println stages)
//    (doall (map
//      (fn [stage]
//        (println "stage: " stage)
//        (.openScene production (.getName (.getScene stage)) stage (limelight.util.Opts. {})))
//      stages))
}
Also used : PanelEvent(limelight.ui.events.panel.PanelEvent) Opts(limelight.util.Opts) Production(limelight.model.Production) Stage(limelight.model.Stage)

Example 5 with Stage

use of limelight.model.Stage in project limelight by slagyr.

the class Utilities method alert.

public Object alert(String message) {
    alertMessage = message;
    alertResponse = null;
    Stage alertStage = establishStage("Alert", dialogStageOptions);
    production.openScene("alert", "Alert", Util.toMap());
    waitForResponse(alertMonitor);
    alertStage.close();
    return alertResponse;
}
Also used : Stage(limelight.model.Stage)

Aggregations

Stage (limelight.model.Stage)7 FramedStage (limelight.ui.model.FramedStage)3 Test (org.junit.Test)2 HashMap (java.util.HashMap)1 Production (limelight.model.Production)1 Theater (limelight.model.Theater)1 PanelEvent (limelight.ui.events.panel.PanelEvent)1 Opts (limelight.util.Opts)1