diff options
author | dos-reis <gdr@axiomatics.org> | 2013-04-01 00:49:23 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2013-04-01 00:49:23 +0000 |
commit | 86c534a99a9eda6be04595e2fecc433e51ddaed2 (patch) | |
tree | b9931d602f93f875ed2669ab78b0970dc27aa3e4 /src/graph/view3D | |
parent | 664e27a1d8f4927285e8c4f89870796c9d9f518e (diff) | |
download | open-axiom-86c534a99a9eda6be04595e2fecc433e51ddaed2.tar.gz |
More C cleanups
Diffstat (limited to 'src/graph/view3D')
-rw-r--r-- | src/graph/view3D/control3d.c | 10 | ||||
-rw-r--r-- | src/graph/view3D/main3d.c | 4 | ||||
-rw-r--r-- | src/graph/view3D/spadAction3d.c | 6 | ||||
-rw-r--r-- | src/graph/view3D/write3d.c | 8 |
4 files changed, 15 insertions, 13 deletions
diff --git a/src/graph/view3D/control3d.c b/src/graph/view3D/control3d.c index 9099d1f5..2fb407e6 100644 --- a/src/graph/view3D/control3d.c +++ b/src/graph/view3D/control3d.c @@ -874,7 +874,7 @@ makeControlPanel (void) { Window cw; - int i, num; + int i; controlPanelStruct *control; buttonStruct *buttons; controlXY cXY; @@ -891,9 +891,11 @@ makeControlPanel (void) cXY = getControlXY(0); - mousebits = XCreateBitmapFromData(dsply,rtWindow, mouseBitmap_bits, + mousebits = XCreateBitmapFromData(dsply,rtWindow, + (const char*) mouseBitmap_bits, mouseBitmap_width, mouseBitmap_height); - mousemask = XCreateBitmapFromData(dsply,rtWindow, mouseMask_bits, + mousemask = XCreateBitmapFromData(dsply,rtWindow, + (const char*) mouseMask_bits, mouseMask_width, mouseMask_height); cwAttrib.background_pixel = backgroundColor; cwAttrib.border_pixel = foregroundColor; @@ -925,7 +927,7 @@ makeControlPanel (void) /* Define and assign a mouse cursor */ control->controlWindow = cw; - num = initButtons(control->buttonQueue); + initButtons(control->buttonQueue); buttons = control->buttonQueue; for (i=controlButtonsStart3D; i<(controlButtonsEnd3D); i++) { controlAttrib.event_mask = (control->buttonQueue[i]).mask; diff --git a/src/graph/view3D/main3d.c b/src/graph/view3D/main3d.c index 63805c25..90616192 100644 --- a/src/graph/view3D/main3d.c +++ b/src/graph/view3D/main3d.c @@ -253,7 +253,7 @@ main(void) { XGCValues controlGCVals; - int i, code; + int i; char property[256]; char *prop = &property[0]; @@ -520,7 +520,7 @@ main(void) /**** Get Data from the Viewport Manager ****/ i = 123; /* Used in viewman, what is this for? */ - code = check(write(Socket,&i,intSize)); + check(write(Socket,&i,intSize)); /* Check if I am getting stuff from OpenAxiom or, if I am viewAlone. */ readViewman(&viewAloned,intSize); diff --git a/src/graph/view3D/spadAction3d.c b/src/graph/view3D/spadAction3d.c index c9af638b..0c3861f3 100644 --- a/src/graph/view3D/spadAction3d.c +++ b/src/graph/view3D/spadAction3d.c @@ -81,7 +81,7 @@ scalePoint (viewTriple *p) int spadAction (void) { - int code, viewCommand; + int viewCommand; float f1, f2, f3; int i1, i2, i3; @@ -271,7 +271,7 @@ spadAction (void) break; case closeAll: - code = check(write(Socket,&ack,intSize)); + check(write(Socket,&ack,intSize)); goodbye(-1); @@ -387,7 +387,7 @@ spadAction (void) ack++; - code = check(write(Socket,&ack,intSize)); + check(write(Socket,&ack,intSize)); return(0); } diff --git a/src/graph/view3D/write3d.c b/src/graph/view3D/write3d.c index d84f0c13..724fe5cc 100644 --- a/src/graph/view3D/write3d.c +++ b/src/graph/view3D/write3d.c @@ -58,7 +58,7 @@ int writeViewport (int thingsToWrite) { - int i, j, k, ii, code, *anIndex; + int i, j, k, ii, *anIndex; LLPoint *anLLPoint; LPoint *anLPoint; viewTriple *aPt; @@ -71,7 +71,7 @@ writeViewport (int thingsToWrite) XGetWindowAttributes(dsply,viewport->titleWindow,&vwInfo); sprintf(viewDirName,"%s%s",filename,".VIEW"); sprintf(command,"%s%s%s","rm -r ",viewDirName," > /dev/null 2>&1"); - code = system(command); + system(command); sprintf(command,"%s%s%s","mkdir ",viewDirName," > /dev/null 2>&1"); system(command); if (0) { @@ -142,7 +142,7 @@ writeViewport (int thingsToWrite) /*** Create the pixmap (bitmaps need leaf name) ***/ sprintf(viewBitmapFilename,"%s%s%s",viewDirName,"/","image.bm"); XGetWindowAttributes(dsply,viewport->viewWindow,&vwInfo); - code = XWriteBitmapFile(dsply,viewBitmapFilename, + XWriteBitmapFile(dsply,viewBitmapFilename, viewport->titleWindow,vwInfo.width, vwInfo.height+vwInfo.border_width+20,-1,-1); break; @@ -183,7 +183,7 @@ writeViewport (int thingsToWrite) drawViewport(Xoption); writeTitle(); sprintf(viewBitmapFilename,"%s%s%s",viewDirName,"/","image.bm"); - code = XWriteBitmapFile(dsply,viewBitmapFilename, + XWriteBitmapFile(dsply,viewBitmapFilename, viewport->titleWindow,vwInfo.width, vwInfo.height+vwInfo.border_width+20,-1,-1); |