Updated copyright notice to 2011
[xboard.git] / winboard / winboard.c
index a04d77f..f27a1e6 100644 (file)
@@ -5,7 +5,7 @@
  * Massachusetts. \r
  *\r
  * Enhancements Copyright 1992-2001, 2002, 2003, 2004, 2005, 2006,\r
- * 2007, 2008, 2009, 2010 Free Software Foundation, Inc.\r
+ * 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.\r
  *\r
  * Enhancements Copyright 2005 Alessandro Scotti\r
  *\r
@@ -4112,23 +4112,9 @@ MouseEvent(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
   switch (message) {\r
   case WM_LBUTTONDOWN:\r
       if (PtInRect((LPRECT) &whiteRect, pt)) {\r
-        if (gameMode == EditPosition) {\r
-         SetWhiteToPlayEvent();\r
-        } else if (gameMode == EditGame || GetKeyState(VK_SHIFT) < 0) {\r
-          AdjustClock(flipClock, -1);\r
-       } else if (gameMode == IcsPlayingBlack ||\r
-                  gameMode == MachinePlaysWhite) {\r
-         CallFlagEvent();\r
-        }\r
+        ClockClick(flipClock);\r
       } else if (PtInRect((LPRECT) &blackRect, pt)) {\r
-       if (gameMode == EditPosition) {\r
-         SetBlackToPlayEvent();\r
-        } else if (gameMode == EditGame || GetKeyState(VK_SHIFT) < 0) {\r
-          AdjustClock(!flipClock, -1);\r
-       } else if (gameMode == IcsPlayingWhite ||\r
-                  gameMode == MachinePlaysBlack) {\r
-         CallFlagEvent();\r
-       }\r
+       ClockClick(!flipClock);\r
       }\r
       dragInfo.start.x = dragInfo.start.y = -1;\r
       dragInfo.from = dragInfo.start;\r