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
198f8954
Commit
198f8954
authored
Oct 17, 2009
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use inhibit plugin
TODO: - only inhibit screen saver when input is *not* paused.
parent
ab044dcd
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
0 deletions
+13
-0
src/video_output/window.c
src/video_output/window.c
+13
-0
No files found.
src/video_output/window.c
View file @
198f8954
...
...
@@ -31,12 +31,14 @@
#include <vlc_common.h>
#include <vlc_vout_window.h>
#include "inhibit.h"
#include <libvlc.h>
typedef
struct
{
vout_window_t
wnd
;
module_t
*
module
;
vlc_inhibit_t
*
inhibit
;
}
window_t
;
vout_window_t
*
vout_window_New
(
vlc_object_t
*
obj
,
...
...
@@ -72,6 +74,15 @@ vout_window_t *vout_window_New(vlc_object_t *obj,
vlc_object_release
(
window
);
return
NULL
;
}
/* Hook for screensaver inhibition */
if
(
cfg
->
type
==
VOUT_WINDOW_TYPE_XID
)
{
w
->
inhibit
=
vlc_inhibit_Create
(
VLC_OBJECT
(
window
),
window
->
handle
.
xid
);
if
(
w
->
inhibit
!=
NULL
)
vlc_inhibit_Set
(
w
->
inhibit
,
true
);
/* FIXME: ^ wait for vout activation, pause */
}
return
window
;
}
...
...
@@ -81,6 +92,8 @@ void vout_window_Delete(vout_window_t *window)
return
;
window_t
*
w
=
(
window_t
*
)
window
;
if
(
w
->
inhibit
)
vlc_inhibit_Destroy
(
w
->
inhibit
);
vlc_object_detach
(
window
);
module_unneed
(
window
,
w
->
module
);
...
...
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