Project

General

Profile

« Previous | Next » 

Revision 8c8c78f4

Added by Andreas Kohlbecker about 5 years ago

avoide setting the readonly suffix multiple times

View differences:

src/main/java/eu/etaxonomy/vaadin/component/CompositeCustomField.java
289 289

  
290 290
    protected void updateCaptionReadonlyNotice(boolean readOnly) {
291 291
        if(readOnly){
292
            setCaption(getCaption() + READ_ONLY_CAPTION_SUFFIX);
292
            if(!getCaption().contains(READ_ONLY_CAPTION_SUFFIX)){
293
                setCaption(getCaption() + READ_ONLY_CAPTION_SUFFIX);
294
            }
293 295
        } else {
294 296
            setCaption(getCaption().replace(READ_ONLY_CAPTION_SUFFIX, ""));
295 297
        }

Also available in: Unified diff