Changeset 26720 in osm for applications/editors/josm/plugins/smed
- Timestamp:
- 2011-09-28T14:18:15+02:00 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/panels/PanelCol.java
r26713 r26720 43 43 dlg.mark.setColour(ent, col); 44 44 if (ent != Ent.LIGHT) { 45 stackCol.get(stackIdx).setBackground(dlg.mark.ColMAP.get(dlg.mark.getColour(ent, stackIdx))); 45 if (button == offButton) { 46 stack.remove(stackCol.get(stackIdx)); 47 stackCol.remove(stackIdx); 48 } else if (button == addButton) { 49 stackCol.add(stackIdx, new JRadioButton()); 50 stackCol.get(stackIdx).setBorder(BorderFactory.createLineBorder(Color.magenta, 2)); 51 stack.add(stackCol.get(stackIdx)); 52 } 53 for (int i = 0; stackCol.size() > i; i++) { 54 stackCol.get(i).setBounds(37, (89 + (i * (60 / stackCol.size()))), 30, (60 / stackCol.size())); 55 stackCol.get(i).setBackground(dlg.mark.ColMAP.get(dlg.mark.getColour(ent, i))); 56 } 46 57 } 47 58 } … … 95 106 stack.setBounds(37, 89, 30, 60); 96 107 this.add(stack); 97 Col col; 98 for (int i = 0; (col = dlg.mark.getColour(ent, i)) != Col.UNKNOWN; i++) { 99 stackCol.add(new JRadioButton()); 108 if (dlg.mark != null) { 109 for (int i = 0; dlg.mark.getColour(ent, i) != Col.UNKNOWN; i++) { 110 stackCol.add(new JRadioButton()); 111 } 100 112 } 101 102 113 } 103 114 }
Note:
See TracChangeset
for help on using the changeset viewer.