示例#1
0
        /**
         * @param index
         * @return true if the element at the specified index is read only
         */
        public Boolean isIndexReadonly(FormIndex index)
        {
            if (index.isBeginningOfFormIndex() || index.isEndOfFormIndex())
            {
                return(true);
            }

            TreeReference ref_           = form.getChildInstanceRef(index);
            Boolean       isAskNewRepeat = (getEvent(index) == FormEntryController.EVENT_PROMPT_NEW_REPEAT ||
                                            getEvent(index) == FormEntryController.EVENT_REPEAT_JUNCTURE);

            if (isAskNewRepeat)
            {
                return(false);
            }
            else
            {
                TreeElement node = form.Instance.resolveReference(ref_);
                return(!node.isEnabled());
            }
        }
示例#2
0
 public Boolean isReadOnly()
 {
     return(!mTreeElement.isEnabled());
 }