[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [29466] trunk/blender/intern/ghost/intern/ GHOST_SystemWin32.cpp: Got the okay from Nathan to commit this: It' s a small patch for Win32 Ghost that prevents a Blender window from setting the cursor position when it 's not the active window.

Mitchell Stokes mogurijin at gmail.com
Tue Jun 15 19:12:21 CEST 2010


Revision: 29466
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=29466
Author:   moguri
Date:     2010-06-15 19:12:21 +0200 (Tue, 15 Jun 2010)

Log Message:
-----------
Got the okay from Nathan to commit this: It's a small patch for Win32 Ghost that prevents a Blender window from setting the cursor position when it's not the active window.

Modified Paths:
--------------
    trunk/blender/intern/ghost/intern/GHOST_SystemWin32.cpp

Modified: trunk/blender/intern/ghost/intern/GHOST_SystemWin32.cpp
===================================================================
--- trunk/blender/intern/ghost/intern/GHOST_SystemWin32.cpp	2010-06-15 12:06:30 UTC (rev 29465)
+++ trunk/blender/intern/ghost/intern/GHOST_SystemWin32.cpp	2010-06-15 17:12:21 UTC (rev 29466)
@@ -271,6 +271,8 @@
 
 GHOST_TSuccess GHOST_SystemWin32::setCursorPosition(GHOST_TInt32 x, GHOST_TInt32 y)
 {
+	if (!GetActiveWindow())
+		return GHOST_kFailure;
 	return ::SetCursorPos(x, y) == TRUE ? GHOST_kSuccess : GHOST_kFailure;
 }
 





More information about the Bf-blender-cvs mailing list