* Module descriptor
*****************************************************************************/
vlc_module_begin();
- set_category( CAT_INTERFACE );
- set_subcategory( SUBCAT_INTERFACE_CONTROL );
set_description( _("X Screensaver disabler") );
set_capability( "interface", 0 );
set_callbacks( Activate, NULL );
}
/*
- * Allways load the hotkeys interface if it exists
+ * Always load the hotkeys interface if it exists
*/
VLC_AddIntf( 0, "hotkeys,none", VLC_FALSE, VLC_FALSE );
+ /*
+ * If needed, load the Xscreensaver interface
+ * Currently, only for X
+ */
+#ifdef HAVE_X11_XLIB_H
+ if( config_GetInt( p_vlc, "disable-screensaver" ) == 1 )
+ {
+ VLC_AddIntf( 0, "screensaver", VLC_FALSE, VLC_FALSE );
+ }
+#endif
+
/*
* FIXME: kludge to use a p_vlc-local variable for the Mozilla plugin
*/
#define VIDEO_ON_TOP_LONGTEXT N_("Always place the video window on top of " \
"other windows." )
+#define SS_TEXT N_("Disable screensaver")
+#define SS_LONGTEXT N_("Disable the screensaver during video playback." )
+
#define VIDEO_DECO_TEXT N_("Window decorations")
#define VIDEO_DECO_LONGTEXT N_( \
"If this option is disabled, VLC will avoid creating window caption, " \
#endif
add_bool( "video-on-top", 0, NULL, VIDEO_ON_TOP_TEXT,
VIDEO_ON_TOP_LONGTEXT, VLC_FALSE );
+ add_bool( "disable-screensaver", VLC_TRUE, NULL, SS_TEXT, SS_LONGTEXT,
+ VLC_TRUE );
set_section( N_("Snapshot") , NULL );
add_directory( "snapshot-path", NULL, NULL, SNAP_PATH_TEXT,