Package ch.tatool.core.display.swing.status

Examples of ch.tatool.core.display.swing.status.StatusPanel


    }
   
    /** Updates the level status panel. */
    protected void updateStatusRegion(ExecutionContext context) {
      // update the level status panel if one such exists
      StatusPanel levelPanel = StatusRegionUtil.getStatusPanel(StatusPanel.STATUS_PANEL_LEVEL);
      if (levelPanel != null) {
        levelPanel.setProperty(StatusPanel.PROPERTY_VALUE, Level.getLevelProperty().getValueOrDefault(this));
      }
    }
View Full Code Here


    StatusRegionImpl statusRegion = StatusRegionUtil.getInstance();
   
    // reset
    if (resetIds != null) {
      for (String id : resetIds) {
        StatusPanel panel = statusRegion.getStatusPanel(id);
        if (panel != null) {
          panel.reset();
        }
      }
    }
   
    // disable
    if (disableIds != null) {
      for (String id : disableIds) {
        StatusPanel panel = statusRegion.getStatusPanel(id);
        if (panel != null) {
          panel.setEnabled(false);
        }
      }
    }
   
    // enable
    if (enableIds != null) {
      for (String id : enableIds) {
        StatusPanel panel = statusRegion.getStatusPanel(id);
        if (panel != null) {
          panel.setEnabled(true);
        }
      }
    }
  }
View Full Code Here

      // calculate the remaining time and then update the status panel
      long now = System.nanoTime() / convertRateToMillis;// System.currentTimeMillis();
      final long remainingTime = getDefaultTimerDuration()
          + getTimerStartTimestamp() - now;
     
      final StatusPanel statPanel = statusPanel;
      SwingUtilities.invokeLater(new Runnable() {
        public void run() {
          statPanel.setProperty(StatusPanel.PROPERTY_VALUE,
              remainingTime);
          statPanel.setEnabled(true);
        }
      });
    }
  }
View Full Code Here

  /**
   * Updates the statuspanel with the current trial count.
   */
  private void updateStatusPanel(ExecutionContext context) {
    // get the status panel if available
    StatusPanel panel = StatusRegionUtil.getStatusPanel(statusPanelId);
    if (panel != null) {
      panel.setEnabled(true);
      panel.setProperty(StatusPanel.PROPERTY_VALUE, trialCounter);
    }
  }
View Full Code Here

TOP

Related Classes of ch.tatool.core.display.swing.status.StatusPanel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.