This commit is contained in:
orangemug
2018-05-28 11:15:16 +01:00
parent 0aabd33538
commit c71fbcf436
4 changed files with 11 additions and 7 deletions

View File

@@ -167,7 +167,7 @@ export default class App extends React.Component {
})
}
onSortEnd(move) {
onMoveLayer(move) {
let { oldIndex, newIndex } = move;
let layers = this.state.mapStyle.layers;
oldIndex = clamp(oldIndex, 0, layers.length-1);
@@ -352,7 +352,7 @@ export default class App extends React.Component {
/>
const layerList = <LayerList
onSortEnd={this.onSortEnd.bind(this)}
onMoveLayer={this.onMoveLayer.bind(this)}
onLayerDestroy={this.onLayerDestroy.bind(this)}
onLayerCopy={this.onLayerCopy.bind(this)}
onLayerVisibilityToggle={this.onLayerVisibilityToggle.bind(this)}
@@ -371,7 +371,7 @@ export default class App extends React.Component {
sources={this.state.sources}
vectorLayers={this.state.vectorLayers}
spec={this.state.spec}
onSortEnd={this.onSortEnd.bind(this)}
onMoveLayer={this.onMoveLayer.bind(this)}
onLayerChanged={this.onLayerChanged.bind(this)}
onLayerDestroy={this.onLayerDestroy.bind(this)}
onLayerCopy={this.onLayerCopy.bind(this)}