Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
1c4d8938
Commit
1c4d8938
authored
May 07, 2013
by
Ken Thomases
Committed by
Alexandre Julliard
May 07, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winemac: Apply cursor clipping to events that were in Cocoa's queue when clipping started.
parent
d9ae2f3e
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
2 deletions
+14
-2
cocoa_app.m
dlls/winemac.drv/cocoa_app.m
+14
-2
No files found.
dlls/winemac.drv/cocoa_app.m
View file @
1c4d8938
...
...
@@ -1177,6 +1177,9 @@ int macdrv_err_on;
{
CGPoint
point
=
CGEventGetLocation
([
anEvent
CGEvent
]);
if
(
clippingCursor
)
[
self
clipCursorLocation
:
&
point
];
event
=
macdrv_create_event
(
MOUSE_MOVED_ABSOLUTE
,
targetWindow
);
event
->
mouse_moved
.
x
=
point
.
x
;
event
->
mouse_moved
.
y
=
point
.
y
;
...
...
@@ -1230,6 +1233,9 @@ int macdrv_err_on;
CGPoint
pt
=
CGEventGetLocation
([
theEvent
CGEvent
]);
BOOL
process
;
if
(
clippingCursor
)
[
self
clipCursorLocation
:
&
pt
];
if
(
pressed
)
{
// Test if the click was in the window's content area.
...
...
@@ -1308,8 +1314,14 @@ int macdrv_err_on;
{
CGEventRef
cgevent
=
[
theEvent
CGEvent
];
CGPoint
pt
=
CGEventGetLocation
(
cgevent
);
NSPoint
nspoint
=
[
self
flippedMouseLocation
:
NSPointFromCGPoint
(
pt
)];
NSRect
contentRect
=
[
window
contentRectForFrameRect
:[
window
frame
]];
NSPoint
nspoint
;
NSRect
contentRect
;
if
(
clippingCursor
)
[
self
clipCursorLocation
:
&
pt
];
nspoint
=
[
self
flippedMouseLocation
:
NSPointFromCGPoint
(
pt
)];
contentRect
=
[
window
contentRectForFrameRect
:[
window
frame
]];
// Only process the event if it was in the window's content area.
if
(
NSPointInRect
(
nspoint
,
contentRect
))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment