2020-08-16 01:22:23 +00:00
|
|
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
|
|
|
// See the LICENCE file in the repository root for full licence text.
|
|
|
|
|
2022-06-17 07:37:17 +00:00
|
|
|
#nullable disable
|
|
|
|
|
2020-08-16 01:22:23 +00:00
|
|
|
using osu.Framework.Input;
|
2022-08-07 15:11:15 +00:00
|
|
|
using osu.Framework.Localisation;
|
|
|
|
using osu.Game.Localisation;
|
2020-08-16 01:22:23 +00:00
|
|
|
|
|
|
|
namespace osu.Game.Input
|
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// Determines the situations in which the mouse cursor should be confined to the window.
|
|
|
|
/// Expands upon <see cref="ConfineMouseMode"/> by providing the option to confine during gameplay.
|
|
|
|
/// </summary>
|
|
|
|
public enum OsuConfineMouseMode
|
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// The mouse cursor will be free to move outside the game window.
|
|
|
|
/// </summary>
|
2022-08-09 14:35:19 +00:00
|
|
|
[LocalisableDescription(typeof(MouseSettingsStrings), nameof(MouseSettingsStrings.NeverConfine))]
|
2020-08-16 01:22:23 +00:00
|
|
|
Never,
|
|
|
|
|
|
|
|
/// <summary>
|
2020-10-06 12:09:35 +00:00
|
|
|
/// The mouse cursor will be locked to the window bounds during gameplay,
|
2020-08-16 01:22:23 +00:00
|
|
|
/// but may otherwise move freely.
|
|
|
|
/// </summary>
|
2022-08-09 14:35:19 +00:00
|
|
|
[LocalisableDescription(typeof(MouseSettingsStrings), nameof(MouseSettingsStrings.ConfineDuringGameplay))]
|
2020-10-06 12:09:35 +00:00
|
|
|
DuringGameplay,
|
2020-08-16 01:22:23 +00:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// The mouse cursor will always be locked to the window bounds while the game has focus.
|
|
|
|
/// </summary>
|
2022-08-09 14:35:19 +00:00
|
|
|
[LocalisableDescription(typeof(MouseSettingsStrings), nameof(MouseSettingsStrings.AlwaysConfine))]
|
2020-08-16 01:22:23 +00:00
|
|
|
Always
|
|
|
|
}
|
|
|
|
}
|