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
5ff23d22
Commit
5ff23d22
authored
Jul 10, 2020
by
Jacek Caban
Committed by
Alexandre Julliard
Jul 10, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernelbase: Use IOCTL_CONDRV_SET_OUTPUT_INFO in SetConsoleCursorPosition.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
3b81ea31
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
13 deletions
+7
-13
console.c
dlls/kernelbase/console.c
+7
-13
No files found.
dlls/kernelbase/console.c
View file @
5ff23d22
...
...
@@ -1195,23 +1195,18 @@ BOOL WINAPI DECLSPEC_HOTPATCH SetConsoleCursorInfo( HANDLE handle, CONSOLE_CURSO
*/
BOOL
WINAPI
DECLSPEC_HOTPATCH
SetConsoleCursorPosition
(
HANDLE
handle
,
COORD
pos
)
{
struct
condrv_output_info_params
params
=
{
SET_CONSOLE_OUTPUT_INFO_CURSOR_POS
};
CONSOLE_SCREEN_BUFFER_INFO
info
;
int
w
,
h
,
do_move
=
0
;
BOOL
ret
;
TRACE
(
"%p %d %d
\n
"
,
handle
,
pos
.
X
,
pos
.
Y
);
SERVER_START_REQ
(
set_console_output_info
)
{
req
->
handle
=
console_handle_unmap
(
handle
);
req
->
cursor_x
=
pos
.
X
;
req
->
cursor_y
=
pos
.
Y
;
req
->
mask
=
SET_CONSOLE_OUTPUT_INFO_CURSOR_POS
;
ret
=
!
wine_server_call_err
(
req
);
}
SERVER_END_REQ
;
params
.
info
.
cursor_x
=
pos
.
X
;
params
.
info
.
cursor_y
=
pos
.
Y
;
if
(
!
console_ioctl
(
handle
,
IOCTL_CONDRV_SET_OUTPUT_INFO
,
&
params
,
sizeof
(
params
),
NULL
,
0
,
NULL
))
return
FALSE
;
if
(
!
ret
||
!
GetConsoleScreenBufferInfo
(
handle
,
&
info
))
return
FALSE
;
if
(
!
GetConsoleScreenBufferInfo
(
handle
,
&
info
))
return
FALSE
;
/* if cursor is no longer visible, scroll the visible window... */
w
=
info
.
srWindow
.
Right
-
info
.
srWindow
.
Left
+
1
;
...
...
@@ -1240,8 +1235,7 @@ BOOL WINAPI DECLSPEC_HOTPATCH SetConsoleCursorPosition( HANDLE handle, COORD pos
}
info
.
srWindow
.
Bottom
=
info
.
srWindow
.
Top
+
h
-
1
;
if
(
do_move
)
ret
=
SetConsoleWindowInfo
(
handle
,
TRUE
,
&
info
.
srWindow
);
return
ret
;
return
!
do_move
||
SetConsoleWindowInfo
(
handle
,
TRUE
,
&
info
.
srWindow
);
}
...
...
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