Project

General

Profile

« Previous | Next » 

Revision 234cba57

Added by Katja Luther over 1 year ago

fix #10169: checkedElements should not contain null values

View differences:

eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/preference/wizard/CheckBoxTreeComposite.java
103 103
                        checkedElements = tempArray;
104 104
                    }
105 105
                }else{
106
                    int index = 0;
106
                    
107 107
                    if (checkedElements != null){
108
                    	Object[] tempArray = new Object[checkedElements.length -1];
109
                    	int index = 0;
108 110
                        for (Object o:checkedElements){
109
                            if (o != null && o.equals(item.getData())){
110
                                break;
111
                            if (o != null && !o.equals(item.getData())){
112
                            	tempArray[index] = o;
113
                            	index++;
111 114
                            }
112
                            index ++;
113 115
                        }
114
                        checkedElements[index] = null;
116
                        checkedElements = tempArray;
115 117
                    }
116 118
                }
117 119

  

Also available in: Unified diff