Merge cut/delete

Remove the cut function and merge it into the del-item command. This
allows for vim-style cutting/pasting.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
This commit is contained in:
Lukas Fleischer
2012-07-07 19:14:33 +02:00
parent 88588ad704
commit 13c21ac280
6 changed files with 85 additions and 160 deletions

View File

@@ -275,7 +275,7 @@ int main(int argc, char **argv)
case KEY_DEL_ITEM:
if (wins_slctd() == APP && apoint_hilt() != 0) {
interact_day_item_delete(&inday.nb_events, &inday.nb_apoints);
interact_day_item_delete(&inday.nb_events, &inday.nb_apoints, reg);
inday = do_storage(0);
wins_update(FLAG_CAL | FLAG_APP | FLAG_STA);
} else if (wins_slctd() == TOD && todo_hilt() != 0) {
@@ -284,14 +284,6 @@ int main(int argc, char **argv)
}
break;
case KEY_GENERIC_CUT:
if (wins_slctd() == APP && apoint_hilt() != 0) {
interact_day_item_cut(&inday.nb_events, &inday.nb_apoints, reg);
inday = do_storage(0);
wins_update(FLAG_CAL | FLAG_APP);
}
break;
case KEY_GENERIC_COPY:
if (wins_slctd() == APP && apoint_hilt() != 0) {
interact_day_item_copy(&inday.nb_events, &inday.nb_apoints, reg);