mirror of
https://github.com/osukey/osukey.git
synced 2025-08-03 14:46:38 +09:00
Wire up enum-backed dropdowns
This commit is contained in:
10
osu.Game/Configuration/ConfineMouseMode.cs
Normal file
10
osu.Game/Configuration/ConfineMouseMode.cs
Normal file
@ -0,0 +1,10 @@
|
||||
using System;
|
||||
namespace osu.Game.Configuration
|
||||
{
|
||||
public enum ConfineMouseMode
|
||||
{
|
||||
Never,
|
||||
Fullscreen,
|
||||
Always
|
||||
}
|
||||
}
|
12
osu.Game/Configuration/FrameSync.cs
Normal file
12
osu.Game/Configuration/FrameSync.cs
Normal file
@ -0,0 +1,12 @@
|
||||
using System;
|
||||
namespace osu.Game.Configuration
|
||||
{
|
||||
public enum FrameSync
|
||||
{
|
||||
VSync = 1,
|
||||
Limit120 = 0,
|
||||
Unlimited = 2,
|
||||
CompletelyUnlimited = 4,
|
||||
Custom = 5
|
||||
}
|
||||
}
|
10
osu.Game/Configuration/HiddenAttribute.cs
Normal file
10
osu.Game/Configuration/HiddenAttribute.cs
Normal file
@ -0,0 +1,10 @@
|
||||
using System;
|
||||
namespace osu.Game.Configuration
|
||||
{
|
||||
public class HiddenAttribute
|
||||
{
|
||||
public HiddenAttribute()
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
@ -1,6 +1,7 @@
|
||||
//Copyright (c) 2007-2016 ppy Pty Ltd <contact@ppy.sh>.
|
||||
//Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||
|
||||
using System;
|
||||
using osu.Framework.Configuration;
|
||||
using osu.Framework.Platform;
|
||||
using osu.Game.Modes;
|
||||
@ -11,6 +12,7 @@ namespace osu.Game.Configuration
|
||||
{
|
||||
protected override void InitialiseDefaults()
|
||||
{
|
||||
#pragma warning disable CS0612 // Type or member is obsolete
|
||||
Set(OsuConfig.Width, 1366, 640);
|
||||
Set(OsuConfig.Height, 768, 480);
|
||||
Set(OsuConfig.MouseSpeed, 1.0);
|
||||
@ -111,17 +113,18 @@ namespace osu.Game.Configuration
|
||||
Set(OsuConfig.NotifySubmittedThread, true);
|
||||
Set(OsuConfig.PopupDuringGameplay, true);
|
||||
Set(OsuConfig.ProgressBarType, ProgressBarType.Pie);
|
||||
//Set(OsuConfig.RankType, RankingType.Top);
|
||||
Set(OsuConfig.RankType, RankingType.Top);
|
||||
Set(OsuConfig.RefreshRate, 60);
|
||||
Set(OsuConfig.OverrideRefreshRate, Get<int>(OsuConfig.RefreshRate) != 60);
|
||||
//Set(OsuConfig.ScaleMode, ScaleMode.WidescreenConservative);
|
||||
Set(OsuConfig.ScoreboardVisible, true);
|
||||
Set(OsuConfig.ScoreMeter, ScoreMeterType.Error);
|
||||
//Set(OsuConfig.ScoreMeter, OsuGame.Tournament ? ScoreMeterType.Colour : ScoreMeterType.Error);
|
||||
Set(OsuConfig.ScreenshotId, 0);
|
||||
Set(OsuConfig.MenuSnow, false);
|
||||
Set(OsuConfig.MenuTriangles, true);
|
||||
Set(OsuConfig.SongSelectThumbnails, true);
|
||||
//Set(OsuConfig.ScreenshotFormat, ImageFileFormat.Jpg);
|
||||
Set(OsuConfig.ScreenshotFormat, ScreenshotFormat.Jpg);
|
||||
Set(OsuConfig.ShowReplayComments, true);
|
||||
Set(OsuConfig.ShowSpectators, true);
|
||||
Set(OsuConfig.ShowStoryboard, true);
|
||||
@ -154,7 +157,7 @@ namespace osu.Game.Configuration
|
||||
Set(OsuConfig.DisplayStarsMaximum, 10, 0, 10);
|
||||
Set(OsuConfig.DisplayStarsMinimum, 0, 0, 10);
|
||||
Set(OsuConfig.AudioDevice, string.Empty);
|
||||
//Set(OsuConfig.ReleaseStream, ReleaseStream.Lazer, true);
|
||||
Set(OsuConfig.ReleaseStream, ReleaseStream.Lazer);
|
||||
Set(OsuConfig.UpdateFailCount, 0);
|
||||
Set(OsuConfig.SavePassword, false);
|
||||
Set(OsuConfig.SaveUsername, true);
|
||||
@ -163,7 +166,7 @@ namespace osu.Game.Configuration
|
||||
Set(OsuConfig.Letterboxing, Get<bool>(OsuConfig.Fullscreen));
|
||||
Set(OsuConfig.LetterboxPositionX, 0, -100, 100);
|
||||
Set(OsuConfig.LetterboxPositionY, 0, -100, 100);
|
||||
//Set(OsuConfig.FrameSync, FrameSync.Limit120);
|
||||
Set(OsuConfig.FrameSync, FrameSync.Limit120);
|
||||
bool unicodeDefault = false;
|
||||
switch (Get<string>(OsuConfig.Language))
|
||||
{
|
||||
@ -178,6 +181,9 @@ namespace osu.Game.Configuration
|
||||
Set(OsuConfig.Ticker, false);
|
||||
Set(OsuConfig.CompatibilityContext, false);
|
||||
Set(OsuConfig.CanForceOptimusCompatibility, true);
|
||||
Set(OsuConfig.ConfineMouse, Get<bool>(OsuConfig.ConfineMouseToFullscreen) ?
|
||||
ConfineMouseMode.Fullscreen : ConfineMouseMode.Never);
|
||||
#pragma warning restore CS0612 // Type or member is obsolete
|
||||
}
|
||||
|
||||
//todo: make a UnicodeString class/struct rather than requiring this helper method.
|
||||
@ -322,6 +328,8 @@ namespace osu.Game.Configuration
|
||||
RawInput,
|
||||
AbsoluteToOsuWindow,
|
||||
ConfineMouse,
|
||||
[Obsolete]
|
||||
ConfineMouseToFullscreen,
|
||||
ShowMenuTips,
|
||||
HiddenShowFirstApproach,
|
||||
ComboColourSliderBall,
|
||||
|
14
osu.Game/Configuration/RankingType.cs
Normal file
14
osu.Game/Configuration/RankingType.cs
Normal file
@ -0,0 +1,14 @@
|
||||
using System;
|
||||
namespace osu.Game.Configuration
|
||||
{
|
||||
public enum RankingType
|
||||
{
|
||||
Local,
|
||||
[DisplayName("Global")]
|
||||
Top,
|
||||
[DisplayName("Selected Mods")]
|
||||
SelectedMod,
|
||||
Friends,
|
||||
Country
|
||||
}
|
||||
}
|
11
osu.Game/Configuration/ReleaseStream.cs
Normal file
11
osu.Game/Configuration/ReleaseStream.cs
Normal file
@ -0,0 +1,11 @@
|
||||
using System;
|
||||
namespace osu.Game.Configuration
|
||||
{
|
||||
public enum ReleaseStream
|
||||
{
|
||||
Lazer,
|
||||
//Stable40,
|
||||
//Beta40,
|
||||
//Stable
|
||||
}
|
||||
}
|
10
osu.Game/Configuration/ScoreMeterType.cs
Normal file
10
osu.Game/Configuration/ScoreMeterType.cs
Normal file
@ -0,0 +1,10 @@
|
||||
using System;
|
||||
namespace osu.Game.Configuration
|
||||
{
|
||||
public enum ScoreMeterType
|
||||
{
|
||||
None,
|
||||
Colour,
|
||||
Error
|
||||
}
|
||||
}
|
12
osu.Game/Configuration/ScreenshotFormat.cs
Normal file
12
osu.Game/Configuration/ScreenshotFormat.cs
Normal file
@ -0,0 +1,12 @@
|
||||
using System;
|
||||
namespace osu.Game.Configuration
|
||||
{
|
||||
public enum ScreenshotFormat
|
||||
{
|
||||
Bmp = 0, // TODO: Figure out the best way to hide this from the dropdown
|
||||
[DisplayName("JPG (web-friendly)")]
|
||||
Jpg = 1,
|
||||
[DisplayName("PNG (lossless)")]
|
||||
Png = 2
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user