From 920eefd4a7d3f92e26ccf54808012d3e98eec991 Mon Sep 17 00:00:00 2001 From: curt Date: Wed, 22 Apr 1998 13:25:39 +0000 Subject: [PATCH] C++ - ifing the code. Starting a bit of reorganization of lighting code. --- Main/{GLUTkey.c => GLUTkey.cxx} | 19 ++++--- Main/{GLUTkey.h => GLUTkey.hxx} | 18 +++--- Main/GLUTmain.cxx | 30 +++++----- Main/Makefile.am | 6 +- Main/Makefile.in | 6 +- Main/fg_getopt.h | 10 +++- Main/{fg_init.c => fg_init.cxx} | 98 +++++++++++++++++++-------------- Main/{fg_init.h => fg_init.hxx} | 17 +++--- Main/{views.c => views.cxx} | 18 ++++-- Main/{views.h => views.hxx} | 24 ++++---- 10 files changed, 139 insertions(+), 107 deletions(-) rename Main/{GLUTkey.c => GLUTkey.cxx} (97%) rename Main/{GLUTkey.h => GLUTkey.hxx} (88%) rename Main/{fg_init.c => fg_init.cxx} (89%) rename Main/{fg_init.h => fg_init.hxx} (85%) rename Main/{views.c => views.cxx} (96%) rename Main/{views.h => views.hxx} (88%) diff --git a/Main/GLUTkey.c b/Main/GLUTkey.cxx similarity index 97% rename from Main/GLUTkey.c rename to Main/GLUTkey.cxx index cf0e458df..c60dbb0a0 100644 --- a/Main/GLUTkey.c +++ b/Main/GLUTkey.cxx @@ -35,16 +35,15 @@ #include #include -#include -#include
-#include
- -#include - #include #include // Added autopilot.h to list, Jeff Goeke-Smith +#include +#include #include +#include "GLUTkey.hxx" +#include "views.hxx" + extern int show_hud; /* HUD state */ extern int displayInstruments; @@ -257,9 +256,13 @@ void GLUTspecialkey(int k, int x, int y) { /* $Log$ -/* Revision 1.33 1998/04/18 04:11:25 curt -/* Moved fg_debug to it's own library, added zlib support. +/* Revision 1.1 1998/04/22 13:25:40 curt +/* C++ - ifing the code. +/* Starting a bit of reorganization of lighting code. /* + * Revision 1.33 1998/04/18 04:11:25 curt + * Moved fg_debug to it's own library, added zlib support. + * * Revision 1.32 1998/04/14 02:21:01 curt * Incorporated autopilot heading hold contributed by: Jeff Goeke-Smith * diff --git a/Main/GLUTkey.h b/Main/GLUTkey.hxx similarity index 88% rename from Main/GLUTkey.h rename to Main/GLUTkey.hxx index 1eb9ecbab..185afa005 100644 --- a/Main/GLUTkey.h +++ b/Main/GLUTkey.hxx @@ -28,8 +28,8 @@ #define _GLUTKEY_H -#ifdef __cplusplus -extern "C" { +#ifndef __cplusplus +# error This library requires C++ #endif @@ -42,23 +42,23 @@ extern "C" { #include #include + /* Handle keyboard events */ void GLUTkey(unsigned char k, int x, int y); void GLUTspecialkey(int k, int x, int y); -#ifdef __cplusplus -} -#endif - - #endif /* _GLUTKEY_H */ /* $Log$ -/* Revision 1.9 1998/04/21 17:02:36 curt -/* Prepairing for C++ integration. +/* Revision 1.1 1998/04/22 13:25:41 curt +/* C++ - ifing the code. +/* Starting a bit of reorganization of lighting code. /* + * Revision 1.9 1998/04/21 17:02:36 curt + * Prepairing for C++ integration. + * * Revision 1.8 1998/04/03 22:09:02 curt * Converting to Gnu autoconf system. * diff --git a/Main/GLUTmain.cxx b/Main/GLUTmain.cxx index fbfde978d..d45e3ae6f 100644 --- a/Main/GLUTmain.cxx +++ b/Main/GLUTmain.cxx @@ -40,35 +40,35 @@ # include #endif -#include -#include
-#include
-#include
-#include
- #include // Line to command line arguments #include // for VERSION #include #include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include #include +#include #include #include #include #include #include -#include +#include #include