From 4871f254b3e5759f22b3bb27b382313b0cd35376 Mon Sep 17 00:00:00 2001 From: lecoanet Date: Wed, 19 May 2004 19:36:13 +0000 Subject: Changed the extent of some GL ifdef so that the file compile without GL defined. --- generic/tkZinc.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'generic') diff --git a/generic/tkZinc.c b/generic/tkZinc.c index b065698..dfa9614 100644 --- a/generic/tkZinc.c +++ b/generic/tkZinc.c @@ -981,6 +981,7 @@ ZnGLSwapBuffers(ZnGLContextEntry *ce, #endif +#ifdef GL static void InitRendering(ZnWInfo *wi) { @@ -989,7 +990,6 @@ InitRendering(ZnWInfo *wi) GLfloat r[2]; /* Min, Max */ GLint i[1]; -#ifdef GL if (wi->render) { # ifdef _WIN32 /* @@ -1163,8 +1163,8 @@ InitRendering(ZnWInfo *wi) ZnGLReleaseContext(ce); } -#endif /* GL */ } +#endif /* GL */ /* @@ -7064,7 +7064,9 @@ Event(ClientData client_data, /* Information about widget. */ SET(wi->flags, ZN_CONFIGURE_EVENT); if (!wi->gc) { SET(wi->flags, ZN_REALIZED); +#ifdef GL InitRendering(wi); +#endif /* * Get the work GC and suppress GraphicExpose @@ -7938,10 +7940,11 @@ static void Destroy(char *mem_ptr) /* Info about the widget. */ { ZnWInfo *wi = (ZnWInfo *) mem_ptr; - unsigned int num, i; + unsigned int num; Tcl_HashSearch search; Tcl_HashEntry *entry; #ifdef GL + unsigned int i; ZnGLContextEntry *ce; ZnWInfo **wip; #endif @@ -8266,10 +8269,10 @@ Repair(ZnWInfo *wi) ZnTriStrip tristrip; #ifdef GL XColor *color; + ZnGLContextEntry *ce; #endif int int_width = Tk_Width(wi->win); int int_height = Tk_Height(wi->win); - ZnGLContextEntry *ce; /*SET(wi->flags, ZN_CONFIGURE_EVENT);*/ if (wi->render) { -- cgit v1.1