calendar_move_*() gathered together into calendar_move()

This commit is contained in:
Frederic Culot 2007-12-10 18:56:08 +00:00
parent 3e429667db
commit 4227e47ae4
2 changed files with 15 additions and 10 deletions

View File

@ -1,4 +1,4 @@
/* $calcurse: calcurse.c,v 1.57 2007/10/21 13:42:34 culot Exp $ */
/* $calcurse: calcurse.c,v 1.58 2007/12/10 18:56:08 culot Exp $ */
/*
* Calcurse - text-based organizer
@ -368,7 +368,7 @@ main(int argc, char **argv)
if (wins_slctd() == CAL || ch == CTRL('L')) {
do_storage = true;
day_changed = true;
calendar_move_right();
calendar_move(RIGHT);
}
break;
@ -379,7 +379,7 @@ main(int argc, char **argv)
if (wins_slctd() == CAL || ch == CTRL('H')) {
do_storage = true;
day_changed = true;
calendar_move_left();
calendar_move(LEFT);
}
break;
@ -390,7 +390,7 @@ main(int argc, char **argv)
if (wins_slctd() == CAL || ch == CTRL('K')) {
do_storage = true;
day_changed = true;
calendar_move_up();
calendar_move(UP);
} else {
if ((wins_slctd() == APP) &&
(apoint_hilt() > 1)) {
@ -412,7 +412,7 @@ main(int argc, char **argv)
if (wins_slctd() == CAL || ch == CTRL('J')) {
do_storage = true;
day_changed = true;
calendar_move_down();
calendar_move(DOWN);
} else {
if ((wins_slctd() == APP) &&
(apoint_hilt() < inday.nb_events +

View File

@ -1,4 +1,4 @@
/* $calcurse: calendar.h,v 1.7 2007/08/31 19:41:24 culot Exp $ */
/* $calcurse: calendar.h,v 1.8 2007/12/10 19:00:45 culot Exp $ */
/*
* Calcurse - text-based organizer
@ -60,6 +60,14 @@ typedef enum {
MOON_PHASES
} pom_e;
typedef enum {
UP,
DOWN,
LEFT,
RIGHT,
MOVES
} move_t;
void calendar_start_date_thread(void);
void calendar_stop_date_thread(void);
void calendar_set_current_date(void);
@ -72,10 +80,7 @@ date_t *calendar_get_slctd_day(void);
long calendar_get_slctd_day_sec(void);
void calendar_update_panel(WINDOW *);
void calendar_change_day(void);
void calendar_move_right(void);
void calendar_move_left(void);
void calendar_move_up(void);
void calendar_move_down(void);
void calendar_move(move_t);
char *calendar_get_pom(time_t);
#endif /* CALCURSE_CALENDAR_H */