[prev in list] [next in list] [prev in thread] [next in thread] 

List:       bzflag-commits
Subject:    SF.net SVN: bzflag:[22177] trunk/bzflag/src/bzflag/ControlPanel.cxx
From:       atupone () users ! sourceforge ! net
Date:       2011-10-27 12:22:36
Message-ID: E1RJOyi-0003jM-97 () sfp-svn-4 ! v30 ! ch3 ! sourceforge ! com
[Download RAW message or body]

Revision: 22177
          http://bzflag.svn.sourceforge.net/bzflag/?rev=22177&view=rev
Author:   atupone
Date:     2011-10-27 12:22:35 +0000 (Thu, 27 Oct 2011)
Log Message:
-----------
The scope of the variable 'xpos' & 'ypos' can be reduced
Variable 'drawnTabWidth' is assigned a value that is never used

Modified Paths:
--------------
    trunk/bzflag/src/bzflag/ControlPanel.cxx

Modified: trunk/bzflag/src/bzflag/ControlPanel.cxx
===================================================================
--- trunk/bzflag/src/bzflag/ControlPanel.cxx	2011-10-27 12:16:44 UTC (rev 22176)
+++ trunk/bzflag/src/bzflag/ControlPanel.cxx	2011-10-27 12:22:35 UTC (rev 22177)
@@ -524,9 +524,6 @@
   OpenGLGState::resetState();
 
   // draw the lines around the console panel
-  long xpos;
-  long ypos;
-
   float outlineOpacity = RENDERER.getPanelOpacity();
   float fudgeFactor = BZDBCache::hudGUIBorderOpacityFactor;	// bzdb cache this \
manybe?  if ( outlineOpacity < 1.0f )
@@ -537,7 +534,11 @@
 
   // nice border
   glColor4f(teamColor[0], teamColor[1], teamColor[2],outlineOpacity );
-  glBegin(GL_LINE_LOOP); {
+  glBegin(GL_LINE_LOOP);
+  {
+    long xpos;
+    long ypos;
+
     // bottom left
     xpos = x + messageAreaPixels[0] - 1;
     ypos = y + messageAreaPixels[1] - 1;
@@ -558,7 +559,6 @@
     }
 
     // across the top from right to left
-    long int drawnTabWidth = 0;
     for (int tab = (int)tabs->size() - 1; tab >= 0; tab--) {
 
       if (messageMode == MessageModes(tab)) {
@@ -574,7 +574,6 @@
 	xpos -= long(tabTextWidth[tab]);
 	glVertex2f((float) xpos, (float) ypos);
       }
-      drawnTabWidth += long(tabTextWidth[tab]);
     }
 
     // over from panel on right

This was sent by the SourceForge.net collaborative development platform, the world's \
largest Open Source development site.


------------------------------------------------------------------------------
The demand for IT networking professionals continues to grow, and the
demand for specialized networking skills is growing even more rapidly.
Take a complimentary Learning@Cisco Self-Assessment and learn 
about Cisco certifications, training, and career opportunities. 
http://p.sf.net/sfu/cisco-dev2dev
_______________________________________________
BZFlag-commits mailing list
BZFlag-commits@lists.SourceForge.net
https://lists.SourceForge.net/lists/listinfo/bzflag-commits
irc: #BZFlag @ irc.freenode.net


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic