Skip to content

Commit

Permalink
make EditRoute dialog working again
Browse files Browse the repository at this point in the history
  • Loading branch information
andreas committed Jan 9, 2025
1 parent 6d9fbc1 commit 12374b8
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions viewer/gui/EditRoutePage.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -264,11 +264,12 @@ class EditRouteDialog extends React.Component{
inverted: newInverted
})
}}
close={false}
>Invert</DB>
{this.props.editAction &&
<DB name="edit"
onClick={()=>{
this.props.closeCallback();
this.save();
this.props.editAction();
}}
>
Expand All @@ -278,23 +279,25 @@ class EditRouteDialog extends React.Component{
<div className="dialogButtons">
< DB name="load"
onClick={this.loadNewRoute}
close={false}
>Load</DB>
{ canDelete && <DB name="delete"
onClick={() => {this.delete(); }}
onClick={() => {this.delete(); }} close={false}
>Delete</DB>}
<DB name="copy"
onClick={() => this.save(true)}
close={false}
disabled={(!this.state.nameChanged || existingName)}
>
Save As
</DB>
<DB name="cancel"
onClick={this.props.closeCallback}
>Cancel</DB>
{this.state.nameChanged ?
<DB name="ok"
onClick={() => this.save()}
disabled={existingName}
close={false}
>
Rename
</DB> :
Expand Down

0 comments on commit 12374b8

Please sign in to comment.