Move apoint_{cut,paste}() to interaction unit

These functions get the current selection, call day_*_item() and fix the
current selection on the appointment panel, so move them where they
belong.

Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
This commit is contained in:
Lukas Fleischer
2012-06-27 08:02:30 +02:00
parent 44d3c96828
commit 47d5fe2d45
4 changed files with 55 additions and 55 deletions

View File

@@ -287,7 +287,7 @@ int main(int argc, char **argv)
case KEY_GENERIC_CUT:
if (wins_slctd() == APP && apoint_hilt() != 0) {
cut_item = apoint_cut(&inday.nb_events, &inday.nb_apoints);
cut_item = interact_day_item_cut(&inday.nb_events, &inday.nb_apoints);
inday = do_storage(0);
wins_update(FLAG_CAL | FLAG_APP);
}
@@ -295,7 +295,7 @@ int main(int argc, char **argv)
case KEY_GENERIC_PASTE:
if (wins_slctd() == APP) {
apoint_paste(&inday.nb_events, &inday.nb_apoints, cut_item);
interact_day_item_paste(&inday.nb_events, &inday.nb_apoints, cut_item);
cut_item = 0;
inday = do_storage(0);
wins_update(FLAG_CAL | FLAG_APP);