/** * Move the focus to the next logical field. * @param sfCurrent The currently selected screen field. * @param iSelectField The screen field to select (next/prev/first/last). */ public void selectField(ScreenField sfCurrent, int iSelectField) { ScreenField sField = this.getComponentAfter(sfCurrent, iSelectField); if (sField != null) sField.requestFocus(); } /**
/** * Move the focus to the next logical field. * @param sfCurrent The currently selected screen field. * @param iSelectField The screen field to select (next/prev/first/last). */ public void selectField(ScreenField sfCurrent, int iSelectField) { ScreenField sField = this.getComponentAfter(sfCurrent, iSelectField); if (sField != null) sField.requestFocus(); } /**
/** * The Field has Changed. * Change to focus to the target field. * @param bDisplayOption If true, display the change. * @param iMoveMode The type of move being done (init/read/screen). * @return The error code (or NORMAL_RETURN if okay). */ public int fieldChanged(boolean bDisplayOption, int iMoveMode) { if (m_screenField == null) this.lookupSField(); if (m_bChangeIfNull != null) { if ((m_bChangeIfNull.booleanValue()) && (!this.getOwner().isNull())) return DBConstants.NORMAL_RETURN; if ((!m_bChangeIfNull.booleanValue()) && (this.getOwner().isNull())) return DBConstants.NORMAL_RETURN; } if (m_screenField != null) m_screenField.requestFocus(); return DBConstants.NORMAL_RETURN; } /**
/** * The Field has Changed. * Change to focus to the target field. * @param bDisplayOption If true, display the change. * @param iMoveMode The type of move being done (init/read/screen). * @return The error code (or NORMAL_RETURN if okay). */ public int fieldChanged(boolean bDisplayOption, int iMoveMode) { if (m_screenField == null) this.lookupSField(); if (m_bChangeIfNull != null) { if ((m_bChangeIfNull.booleanValue()) && (!this.getOwner().isNull())) return DBConstants.NORMAL_RETURN; if ((!m_bChangeIfNull.booleanValue()) && (this.getOwner().isNull())) return DBConstants.NORMAL_RETURN; } if (m_screenField != null) m_screenField.requestFocus(); return DBConstants.NORMAL_RETURN; } /**
/** * Constructor. * @param record The main record for this screen. * @param itsLocation The location of this component within the parent. * @param parentScreen The parent screen. * @param fieldConverter The field this screen field is linked to. * @param iDisplayFieldDesc Do I display the field desc?. */ public void init(Record record, ScreenLocation itsLocation, BasePanel parentScreen, Converter fieldConverter, int iDisplayFieldDesc, Map<String,Object> properties) { super.init(record, itsLocation, parentScreen, fieldConverter, iDisplayFieldDesc, properties); if (this.getRecord(Profile.PROFILE_FILE).getField(Profile.PROFILE_CODE).getComponent(0) != null) ((ScreenField)this.getRecord(Profile.PROFILE_FILE).getField(Profile.PROFILE_CODE).getComponent(0)).requestFocus(); } /**