@Override public void propertyChange(PropertyChangeEvent evt) { if (evt.getPropertyName().equals(Layer.VISIBLE_PROP)) { repaint(); } else if (evt.getPropertyName().equals(Layer.OPACITY_PROP)) { Layer l = (Layer) evt.getSource(); if (l.isVisible()) { changedLayer = l; repaint(); } } else if (evt.getPropertyName().equals(OsmDataLayer.REQUIRES_SAVE_TO_DISK_PROP) || evt.getPropertyName().equals(OsmDataLayer.REQUIRES_UPLOAD_TO_SERVER_PROP)) { OsmDataLayer layer = (OsmDataLayer) evt.getSource(); if (layer == getEditLayer()) { refreshTitle(); } } }
private void onEditLayerChanged(OsmDataLayer oldEditLayer) { fireEditLayerChanged(oldEditLayer, editLayer); refreshTitle(); }
@Override public void uploadDiscouragedChanged(OsmDataLayer layer, boolean newValue) { if (layer == getEditLayer()) { refreshTitle(); } }