Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-gpu
Commits
aabb8c74
Commit
aabb8c74
authored
Oct 26, 2009
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
XCB window: avoid matchbox hack if matchbox is not running
Then we don't need to process all root window property events.
parent
fd23a5c3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
10 deletions
+16
-10
modules/video_output/xcb/window.c
modules/video_output/xcb/window.c
+16
-10
No files found.
modules/video_output/xcb/window.c
View file @
aabb8c74
...
...
@@ -192,7 +192,9 @@ static void CacheAtoms (vout_window_sys_t *p_sys)
wm_state_fs_ck
=
intern_string
(
conn
,
"_NET_WM_STATE_FULLSCREEN"
);
#ifdef MATCHBOX_HACK
xcb_intern_atom_cookie_t
mb_current_app_window
;
mb_current_app_window
=
intern_string
(
conn
,
"_MB_CURRENT_APP_WINDOW"
);
mb_current_app_window
=
xcb_intern_atom
(
conn
,
true
,
strlen
(
"_MB_CURRENT_APP_WINDOW"
),
"_MB_CURRENT_APP_WINDOW"
);
#endif
p_sys
->
wm_state
=
get_atom
(
conn
,
wm_state_ck
);
...
...
@@ -314,18 +316,20 @@ static int Open (vlc_object_t *obj)
xcb_atom_t
wm_window_role
=
get_atom
(
conn
,
wm_window_role_ck
);
set_ascii_prop
(
conn
,
window
,
wm_window_role
,
"vlc-video"
);
/* Cache any EWMH atom we may need later */
CacheAtoms
(
p_sys
);
#ifdef MATCHBOX_HACK
uint32_t
value
=
XCB_EVENT_MASK_PROPERTY_CHANGE
;
xcb_change_window_attributes
(
conn
,
scr
->
root
,
XCB_CW_EVENT_MASK
,
&
value
);
if
(
p_sys
->
mb_current_app_window
)
{
uint32_t
value
=
XCB_EVENT_MASK_PROPERTY_CHANGE
;
xcb_change_window_attributes
(
conn
,
scr
->
root
,
XCB_CW_EVENT_MASK
,
&
value
);
}
#endif
/* Make the window visible */
xcb_map_window
(
conn
,
window
);
/* Cache any EWMH atom we may need later */
CacheAtoms
(
p_sys
);
/* Create the event thread. It will dequeue all events, so any checked
* request from this thread must be completed at this point. */
if
((
p_sys
->
keys
!=
NULL
)
...
...
@@ -333,8 +337,9 @@ static int Open (vlc_object_t *obj)
DestroyKeyHandler
(
p_sys
->
keys
);
#ifdef MATCHBOX_HACK
xcb_set_input_focus
(
p_sys
->
conn
,
XCB_INPUT_FOCUS_POINTER_ROOT
,
wnd
->
handle
.
xid
,
XCB_CURRENT_TIME
);
if
(
p_sys
->
mb_current_app_window
)
xcb_set_input_focus
(
p_sys
->
conn
,
XCB_INPUT_FOCUS_POINTER_ROOT
,
wnd
->
handle
.
xid
,
XCB_CURRENT_TIME
);
#endif
xcb_flush
(
conn
);
/* Make sure map_window is sent (should be useless) */
return
VLC_SUCCESS
;
...
...
@@ -390,7 +395,8 @@ static void *Thread (void *data)
if
(
ProcessKeyEvent
(
p_sys
->
keys
,
ev
)
==
0
)
continue
;
#ifdef MATCHBOX_HACK
if
((
ev
->
response_type
&
0x7f
)
==
XCB_PROPERTY_NOTIFY
)
if
(
p_sys
->
mb_current_app_window
&&
(
ev
->
response_type
&
0x7f
)
==
XCB_PROPERTY_NOTIFY
)
{
const
xcb_property_notify_event_t
*
pne
=
(
xcb_property_notify_event_t
*
)
ev
;
...
...
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