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
6e76cc76
Commit
6e76cc76
authored
Dec 18, 2007
by
Kirill K. Smirnov
Committed by
Alexandre Julliard
Dec 18, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
server: Properly notify renderer while activating another screen buffer.
parent
beb2dfec
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
39 additions
and
35 deletions
+39
-35
console.c
server/console.c
+39
-35
No files found.
server/console.c
View file @
6e76cc76
...
...
@@ -302,6 +302,43 @@ static struct object *create_console_input( struct thread* renderer )
return
&
console_input
->
obj
;
}
static
void
generate_sb_initial_events
(
struct
console_input
*
console_input
)
{
struct
screen_buffer
*
screen_buffer
=
console_input
->
active
;
struct
console_renderer_event
evt
;
evt
.
event
=
CONSOLE_RENDERER_ACTIVE_SB_EVENT
;
memset
(
&
evt
.
u
,
0
,
sizeof
(
evt
.
u
));
console_input_events_append
(
console_input
->
evt
,
&
evt
);
evt
.
event
=
CONSOLE_RENDERER_SB_RESIZE_EVENT
;
evt
.
u
.
resize
.
width
=
screen_buffer
->
width
;
evt
.
u
.
resize
.
height
=
screen_buffer
->
height
;
console_input_events_append
(
console_input
->
evt
,
&
evt
);
evt
.
event
=
CONSOLE_RENDERER_DISPLAY_EVENT
;
evt
.
u
.
display
.
left
=
screen_buffer
->
win
.
left
;
evt
.
u
.
display
.
top
=
screen_buffer
->
win
.
top
;
evt
.
u
.
display
.
width
=
screen_buffer
->
win
.
right
-
screen_buffer
->
win
.
left
+
1
;
evt
.
u
.
display
.
height
=
screen_buffer
->
win
.
bottom
-
screen_buffer
->
win
.
top
+
1
;
console_input_events_append
(
console_input
->
evt
,
&
evt
);
evt
.
event
=
CONSOLE_RENDERER_UPDATE_EVENT
;
evt
.
u
.
update
.
top
=
0
;
evt
.
u
.
update
.
bottom
=
screen_buffer
->
height
-
1
;
console_input_events_append
(
console_input
->
evt
,
&
evt
);
evt
.
event
=
CONSOLE_RENDERER_CURSOR_GEOM_EVENT
;
evt
.
u
.
cursor_geom
.
size
=
screen_buffer
->
cursor_size
;
evt
.
u
.
cursor_geom
.
visible
=
screen_buffer
->
cursor_visible
;
console_input_events_append
(
console_input
->
evt
,
&
evt
);
evt
.
event
=
CONSOLE_RENDERER_CURSOR_POS_EVENT
;
evt
.
u
.
cursor_pos
.
x
=
screen_buffer
->
cursor_x
;
evt
.
u
.
cursor_pos
.
y
=
screen_buffer
->
cursor_y
;
console_input_events_append
(
console_input
->
evt
,
&
evt
);
}
static
struct
screen_buffer
*
create_console_output
(
struct
console_input
*
console_input
)
{
struct
screen_buffer
*
screen_buffer
;
...
...
@@ -341,40 +378,8 @@ static struct screen_buffer *create_console_output( struct console_input *consol
if
(
!
console_input
->
active
)
{
struct
console_renderer_event
evt
;
console_input
->
active
=
(
struct
screen_buffer
*
)
grab_object
(
screen_buffer
);
/* generate the initial events */
evt
.
event
=
CONSOLE_RENDERER_ACTIVE_SB_EVENT
;
memset
(
&
evt
.
u
,
0
,
sizeof
(
evt
.
u
));
console_input_events_append
(
console_input
->
evt
,
&
evt
);
evt
.
event
=
CONSOLE_RENDERER_SB_RESIZE_EVENT
;
evt
.
u
.
resize
.
width
=
screen_buffer
->
width
;
evt
.
u
.
resize
.
height
=
screen_buffer
->
height
;
console_input_events_append
(
console_input
->
evt
,
&
evt
);
evt
.
event
=
CONSOLE_RENDERER_DISPLAY_EVENT
;
evt
.
u
.
display
.
left
=
screen_buffer
->
win
.
left
;
evt
.
u
.
display
.
top
=
screen_buffer
->
win
.
top
;
evt
.
u
.
display
.
width
=
screen_buffer
->
win
.
right
-
screen_buffer
->
win
.
left
+
1
;
evt
.
u
.
display
.
height
=
screen_buffer
->
win
.
bottom
-
screen_buffer
->
win
.
top
+
1
;
console_input_events_append
(
console_input
->
evt
,
&
evt
);
evt
.
event
=
CONSOLE_RENDERER_UPDATE_EVENT
;
evt
.
u
.
update
.
top
=
0
;
evt
.
u
.
update
.
bottom
=
screen_buffer
->
height
-
1
;
console_input_events_append
(
console_input
->
evt
,
&
evt
);
evt
.
event
=
CONSOLE_RENDERER_CURSOR_GEOM_EVENT
;
evt
.
u
.
cursor_geom
.
size
=
screen_buffer
->
cursor_size
;
evt
.
u
.
cursor_geom
.
visible
=
screen_buffer
->
cursor_visible
;
console_input_events_append
(
console_input
->
evt
,
&
evt
);
evt
.
event
=
CONSOLE_RENDERER_CURSOR_POS_EVENT
;
evt
.
u
.
cursor_pos
.
x
=
screen_buffer
->
cursor_x
;
evt
.
u
.
cursor_pos
.
y
=
screen_buffer
->
cursor_y
;
console_input_events_append
(
console_input
->
evt
,
&
evt
);
generate_sb_initial_events
(
console_input
);
}
return
screen_buffer
;
}
...
...
@@ -665,8 +670,7 @@ static int set_console_input_info( const struct set_console_input_info_request *
{
if
(
console
->
active
)
release_object
(
console
->
active
);
console
->
active
=
screen_buffer
;
evt
.
event
=
CONSOLE_RENDERER_ACTIVE_SB_EVENT
;
console_input_events_append
(
console
->
evt
,
&
evt
);
generate_sb_initial_events
(
console
);
}
else
release_object
(
screen_buffer
);
...
...
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