edit: Don't reprint edited object when done with it

Interactive edit prints the edited object, then reads player input.
If it gets key and value, it applies them to the object, and repeats.
If it gets nothing, it prints the edited object again, and stops.

Remove this last print, because it's not really useful.  The object is
commonly the same after reading input as before.  Except when a nation
gets updated while "edit c" is waiting for input: then the second
print actually reflects the updates.  Has always been that way.

Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
This commit is contained in:
Markus Armbruster 2013-03-03 07:12:07 +01:00
parent 2975ea02ae
commit f2bf352e66
2 changed files with 1 additions and 80 deletions

View file

@ -152,26 +152,8 @@ edit(void)
key = getin(buf, &ptr);
if (!key)
return RET_SYN;
if (!*key) {
switch (ewhat) {
case 'c':
print_nat(np);
break;
case 'l':
print_sect(&sect);
break;
case 's':
print_ship(&ship);
break;
case 'u':
print_land(&land);
break;
case 'p':
print_plane(&plane);
break;
}
if (!*key)
return RET_OK;
}
} else
return RET_OK;