Changeset 13486 in josm for trunk/src/org/openstreetmap/josm/gui/dialogs/relation/ReferringRelationsBrowserModel.java
- Timestamp:
- 2018-03-03T17:59:48+01:00 (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/dialogs/relation/ReferringRelationsBrowserModel.java
r12657 r13486 8 8 9 9 import org.openstreetmap.josm.data.osm.DataSet; 10 import org.openstreetmap.josm.data.osm.DataSet.DownloadPolicy; 10 11 import org.openstreetmap.josm.data.osm.Relation; 11 12 import org.openstreetmap.josm.data.osm.RelationMember; … … 35 36 } 36 37 38 /** 39 * Sets the relation. 40 * @param relation the relation 41 */ 37 42 public void setRelation(Relation relation) { 38 43 this.relation = relation; … … 62 67 } 63 68 69 /** 70 * Populates the model with parent referrers. 71 * @param parents parent referrers 72 */ 64 73 public void populate(List<Relation> parents) { 65 74 referrers.clear(); … … 93 102 } 94 103 104 /** 105 * Determines if reloading the relation is possible/authorized. 106 * @return {@code true} if reloading the relation is possible/authorized 107 */ 95 108 public boolean canReload() { 96 return relation != null && !relation.isNew(); 109 return relation != null && !relation.isNew() 110 && !relation.getDataSet().isLocked() 111 && !DownloadPolicy.BLOCKED.equals(relation.getDataSet().getDownloadPolicy()); 97 112 } 98 113 114 /** 115 * Returns the relation. 116 * @return the relation 117 */ 99 118 public Relation getRelation() { 100 119 return relation;
Note:
See TracChangeset
for help on using the changeset viewer.