IsScreenSaverEnabled Property

Guide.IsScreenSaverEnabled Property

Gets or sets the current state of the screen saver. This property has no effect for Windows games.

Namespace: Microsoft.Xna.Framework.GamerServices
Assembly: Microsoft.Xna.Framework.GamerServices (in microsoft.xna.framework.gamerservices.dll)

public static bool IsScreenSaverEnabled { get; set; }

Property Value

true if the screen saver is enabled; false otherwise.

The IsScreenSaverEnabled property is a per-game property. Disabling the screen saver for a game does not permanently disable the screen saver. Use this method when displaying cut-scenes or during periods when the gamer could become inactive for a long time.

Bb975751.note(en-us,XNAGameStudio.41).gifWindows Phone Specific Information

This property changes the UserIdleDetection setting on Windows Phone. It can be used to prevent the screen from locking when the game does not expect touch input for a time. This is particularly useful for games that use alternative input methods to touch such as sound or accelerometer input.

Xbox 360, Windows 7, Windows Vista, Windows XP

Community Additions

© 2015 Microsoft