浏览代码

GetMouse is not available on 64-bit. (Carbon functionality?)

woollybah 11 年之前
父节点
当前提交
95795988fe
共有 1 个文件被更改,包括 3 次插入4 次删除
  1. 3 4
      system.mod/system.macos.m

+ 3 - 4
system.mod/system.macos.m

@@ -155,10 +155,9 @@ static int mouseViewPos( NSView *view,int *x,int *y ){
 	NSPoint point;
 	NSWindow *window;
 	if( displayCaptured || !view ){
-		Point point;
-		GetMouse( &point );
-		*x=point.h;
-		*y=point.v;
+		point = [NSEvent mouseLocation];
+		*x=point.x;
+		*y=point.y;
 		return 1;
 	}
 	window=[view window];