/** * Set the field or file that owns this listener. * This method calls doNewRecord when the owner is set. * @see doNewRecord. * @param owner My owner. */ public void setOwner(ListenerOwner owner) { super.setOwner(owner); if (owner == null) return; boolean bEnabledFlag = this.setEnabledListener(true); // Disabled automatically on setOwner. try { // Open this table and move to the control record if (!this.getOwner().isOpen()) if (this.isEnabled()) // Not on a slave this.getOwner().open(); // Open the control file if (this.getOwner().getEditMode() == Constants.EDIT_NONE) if (this.isEnabled()) // Not on a slave this.doNewRecord(true); // Read the control file } catch (DBException ex) { ex.printStackTrace(); } finally { this.setEnabledListener(bEnabledFlag); // Set back } } /**
/** * Set the field or file that owns this listener. * This method calls doNewRecord when the owner is set. * @see doNewRecord. * @param owner My owner. */ public void setOwner(ListenerOwner owner) { super.setOwner(owner); if (owner == null) return; boolean bEnabledFlag = this.setEnabledListener(true); // Disabled automatically on setOwner. try { // Open this table and move to the control record if (!this.getOwner().isOpen()) if (this.isEnabled()) // Not on a slave this.getOwner().open(); // Open the control file if (this.getOwner().getEditMode() == Constants.EDIT_NONE) if (this.isEnabled()) // Not on a slave this.doNewRecord(true); // Read the control file } catch (DBException ex) { ex.printStackTrace(); } finally { this.setEnabledListener(bEnabledFlag); // Set back } } /**
/** * Set the field or file that owns this listener. * This method calls doNewRecord when the owner is set. * @see doNewRecord. * @param owner My owner. */ public void setOwner(ListenerOwner owner) { super.setOwner(owner); if (owner == null) return; boolean bEnabledFlag = this.setEnabledListener(true); // Disabled automatically on setOwner. try { // Open this table and move to the control record if (!this.getOwner().isOpen()) if (this.isEnabled()) // Not on a slave this.getOwner().open(); // Open the control file if (this.getOwner().getEditMode() == Constants.EDIT_NONE) if (this.isEnabled()) // Not on a slave this.doNewRecord(true); // Read the control file } catch (DBException ex) { ex.printStackTrace(); } finally { this.setEnabledListener(bEnabledFlag); // Set back } } /**