---
core-dave/src/org/openstreetmap/josm/data/osm/OsmPrimitive.java | 35 +---------
1 file changed, 5 insertions(+), 30 deletions(-)
diff -puN src/org/openstreetmap/josm/data/osm/OsmPrimitive.java~remove-primitive-selection-implementation src/org/openstreetmap/josm/data/osm/OsmPrimitive.java
a
|
b
|
abstract public class OsmPrimitive imple
|
39 | 39 | private static final int FLAG_DISABLED = 1 << 2; |
40 | 40 | private static final int FLAG_DELETED = 1 << 3; |
41 | 41 | private static final int FLAG_FILTERED = 1 << 4; |
42 | | private static final int FLAG_SELECTED = 1 << 5; |
43 | | private static final int FLAG_HAS_DIRECTIONS = 1 << 6; |
44 | | private static final int FLAG_TAGGED = 1 << 7; |
| 42 | private static final int FLAG_HAS_DIRECTIONS = 1 << 5; |
| 43 | private static final int FLAG_TAGGED = 1 << 6; |
45 | 44 | |
46 | 45 | /** |
47 | 46 | * Replies the sub-collection of {@see OsmPrimitive}s of type <code>type</code> present in |
… |
… |
abstract public class OsmPrimitive imple
|
174 | 173 | /** |
175 | 174 | * Sets whether this primitive is disabled or not. |
176 | 175 | * |
177 | | * @param selected true, if this primitive is disabled; false, otherwise |
| 176 | * @param disabled true, if this primitive is disabled; false, otherwise |
178 | 177 | */ |
179 | 178 | public void setDisabled(boolean disabled) { |
180 | 179 | if (disabled) { |
… |
… |
abstract public class OsmPrimitive imple
|
196 | 195 | /** |
197 | 196 | * Sets whether this primitive is filtered out or not. |
198 | 197 | * |
199 | | * @param selected true, if this primitive is filtered out; false, otherwise |
| 198 | * @param filtered true, if this primitive is filtered out; false, otherwise |
200 | 199 | */ |
201 | 200 | public void setFiltered(boolean filtered) { |
202 | 201 | if (filtered) { |
… |
… |
abstract public class OsmPrimitive imple
|
215 | 214 | } |
216 | 215 | |
217 | 216 | /** |
218 | | * Sets whether this primitive is selected or not. |
219 | | * |
220 | | * @param selected true, if this primitive is selected; false, otherwise |
221 | | * @since 1899 |
222 | | */ |
223 | | @Deprecated public void setSelected(boolean selected) { |
224 | | if (selected) { |
225 | | flags |= FLAG_SELECTED; |
226 | | } else { |
227 | | flags &= ~FLAG_SELECTED; |
228 | | } |
229 | | } |
230 | | /** |
231 | | * Replies true, if this primitive is selected. |
232 | | * |
233 | | * @return true, if this primitive is selected |
234 | | * @since 1899 |
235 | | */ |
236 | | @Deprecated public boolean isSelected() { |
237 | | return (flags & FLAG_SELECTED) != 0; |
238 | | } |
239 | | |
240 | | /** |
241 | 217 | * Marks this primitive as being modified. |
242 | 218 | * |
243 | 219 | * @param modified true, if this primitive is to be modified |
… |
… |
abstract public class OsmPrimitive imple
|
452 | 428 | /** |
453 | 429 | * Sets whether this primitive is deleted or not. |
454 | 430 | * |
455 | | * Also marks this primitive as modified if deleted is true and sets selected to false. |
| 431 | * Also marks this primitive as modified if deleted is true. |
456 | 432 | * |
457 | 433 | * @param deleted true, if this primitive is deleted; false, otherwise |
458 | 434 | */ |
… |
… |
abstract public class OsmPrimitive imple
|
463 | 439 | flags &= ~FLAG_DELETED; |
464 | 440 | } |
465 | 441 | setModified(deleted); |
466 | | setSelected(false); |
467 | 442 | } |
468 | 443 | |
469 | 444 | /** |