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
34b8c639
Commit
34b8c639
authored
Apr 06, 2011
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
server: Warp the mouse inside the clipping rectangle when it's set.
parent
39bac051
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
queue.c
server/queue.c
+6
-0
No files found.
server/queue.c
View file @
34b8c639
...
...
@@ -350,12 +350,18 @@ static void set_cursor_pos( struct desktop *desktop, int x, int y )
static
void
set_clip_rectangle
(
struct
desktop
*
desktop
,
const
rectangle_t
*
rect
)
{
rectangle_t
top_rect
,
new_rect
;
int
x
,
y
;
get_top_window_rectangle
(
desktop
,
&
top_rect
);
if
(
!
rect
||
!
intersect_rect
(
&
new_rect
,
&
top_rect
,
rect
))
new_rect
=
top_rect
;
if
(
!
memcmp
(
&
desktop
->
cursor
.
clip
,
&
new_rect
,
sizeof
(
new_rect
)
))
return
;
desktop
->
cursor
.
clip
=
new_rect
;
if
(
desktop
->
cursor
.
clip_msg
)
post_desktop_message
(
desktop
,
desktop
->
cursor
.
clip_msg
,
0
,
0
);
/* warp the mouse to be inside the clip rect */
x
=
min
(
max
(
desktop
->
cursor
.
x
,
desktop
->
cursor
.
clip
.
left
),
desktop
->
cursor
.
clip
.
right
-
1
);
y
=
min
(
max
(
desktop
->
cursor
.
y
,
desktop
->
cursor
.
clip
.
top
),
desktop
->
cursor
.
clip
.
bottom
-
1
);
if
(
x
!=
desktop
->
cursor
.
x
||
y
!=
desktop
->
cursor
.
y
)
set_cursor_pos
(
desktop
,
x
,
y
);
}
/* change the foreground input and reset the cursor clip rect */
...
...
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