Package org.wikipediacleaner.api.data

Examples of org.wikipediacleaner.api.data.ProgressionValue


      boolean isSelected, boolean hasFocus,
      int row, int column) {
    Component component = super.getTableCellRendererComponent(
        table, value, isSelected, hasFocus, row, column);
    if (value instanceof ProgressionValue) {
      ProgressionValue progression = (ProgressionValue) value;
      int status = progression.getStatus();
      if (status < 0) {
        if (isSelected) {
          component.setBackground(table.getSelectionBackground());
          component.setForeground(Color.GREEN);
        } else {
          component.setBackground(Color.GREEN);
          component.setForeground(table.getForeground());
        }
      } else if (status > 0) {
        if (isSelected) {
          component.setBackground(table.getSelectionBackground());
          component.setForeground(Color.RED);
        } else {
          component.setBackground(Color.RED);
          component.setForeground(table.getForeground());
        }
      } else {
        if (isSelected) {
          component.setBackground(table.getSelectionBackground());
          if ((progression.getCurrent() != null) && (progression.getGoal() == null)) {
            component.setForeground(Color.GRAY);
          } else {
            component.setForeground(table.getSelectionForeground());
          }
        } else {
          component.setBackground(table.getBackground());
          if ((progression.getCurrent() != null) && (progression.getGoal() == null)) {
            component.setForeground(Color.GRAY);
          } else {
            component.setForeground(table.getForeground());
          }
        }
View Full Code Here

TOP

Related Classes of org.wikipediacleaner.api.data.ProgressionValue

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.