code: private CommonControlState getControlType(Which state) {
          switch (state) {
  
          case ICON_DISABLED:
              return CommonControlState.DISABLED;
  
          case ICON_ENABLED:
          case ICON_FOCUSED:
              return CommonControlState.ENABLED;
  
          case ICON_PRESSED:
          case ICON_PRESSED_FOCUSED:
              return CommonControlState.PRESSED;
  
          case ICON_SELECTED:
          case ICON_SELECTED_FOCUSED:
              return CommonControlState.SELECTED;
  
          case ICON_PRESSED_SELECTED:
          case ICON_PRESSED_SELECTED_FOCUSED:
              return CommonControlState.PRESSED_SELECTED;
  
          case ICON_DISABLED_SELECTED:
              return CommonControlState.DISABLED_SELECTED;
          }
  
          return null;
      }
docs: Get the CommonControlState for the state.
  
  @param  state the control state.
  
  @return the common control color state.