changeset 3:ffbf478b80c2

add Makefile; put missing braces back (that were removed in r399518436fcf)
author paulo@thepaulopc
date Fri, 13 Nov 2009 00:21:59 -0800
parents 399518436fcf
children 3d971e53bcd5
files Makefile menus.c
diffstat 2 files changed, 21 insertions(+), 8 deletions(-) [+]
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/Makefile	Fri Nov 13 00:21:59 2009 -0800
     1.3 @@ -0,0 +1,9 @@
     1.4 +GCC=gcc
     1.5 +CFLAGS=-I/usr/include/ -I/usr/include/dvdread -I/usr/include/dvdnav
     1.6 +LDFLAGS=-L/usr/lib -ldvdnav
     1.7 +
     1.8 +dvdnav-rip: menus.o
     1.9 +	$(GCC) -o $@ $(LDFLAGS) $^
    1.10 +
    1.11 +menus.o: menus.c
    1.12 +	$(GCC) -c $(CFLAGS) $^
     2.1 --- a/menus.c	Fri Nov 13 00:02:37 2009 -0800
     2.2 +++ b/menus.c	Fri Nov 13 00:21:59 2009 -0800
     2.3 @@ -127,12 +127,14 @@
     2.4  			 * user input to make menus and other interactive stills work.
     2.5  			 * A length of 0xff means an indefinite still which has to be skipped
     2.6  			 * indirectly by some user interaction. */
     2.7 -			dvdnav_still_event_t *still_event = (dvdnav_still_event_t *)buf;
     2.8 -			if (still_event->length < 0xff)
     2.9 -			  printf("Skipping %d seconds of still frame\n", still_event->length);
    2.10 -			else
    2.11 -			  printf("Skipping indefinite length still frame\n");
    2.12 -			dvdnav_still_skip(dvdnav);
    2.13 +			{
    2.14 +				dvdnav_still_event_t *still_event = (dvdnav_still_event_t *)buf;
    2.15 +				if (still_event->length < 0xff)
    2.16 +				  printf("Skipping %d seconds of still frame\n", still_event->length);
    2.17 +				else
    2.18 +				  printf("Skipping indefinite length still frame\n");
    2.19 +				dvdnav_still_skip(dvdnav);
    2.20 +			}
    2.21  			break;
    2.22  		case DVDNAV_WAIT:
    2.23  			/* We have reached a point in DVD playback, where timing is critical.
    2.24 @@ -157,8 +159,10 @@
    2.25  		case DVDNAV_HIGHLIGHT:
    2.26  			/* Player applications should inform their overlay engine to highlight the
    2.27  			 * given button */
    2.28 -			dvdnav_highlight_event_t *highlight_event = (dvdnav_highlight_event_t *)buf;
    2.29 -			printf("Selected button %d\n", highlight_event->buttonN);
    2.30 +			{
    2.31 +				dvdnav_highlight_event_t *highlight_event = (dvdnav_highlight_event_t *)buf;
    2.32 +				printf("Selected button %d\n", highlight_event->buttonN);
    2.33 +			}
    2.34  			break;
    2.35  		case DVDNAV_VTS_CHANGE:
    2.36  			/* Some status information like video aspect and video scale permissions do