mirror of
https://github.com/ppy/osu.git
synced 2025-02-15 17:33:02 +08:00
Bring code in line with SDL2 defaults
This commit is contained in:
parent
d5a60ed335
commit
285e62be9a
@ -138,7 +138,7 @@ namespace osu.Desktop
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
// SDL2 DesktopWindow
|
// SDL2 DesktopWindow
|
||||||
case DesktopWindow desktopWindow:
|
case SDL2DesktopWindow desktopWindow:
|
||||||
desktopWindow.CursorState |= CursorState.Hidden;
|
desktopWindow.CursorState |= CursorState.Hidden;
|
||||||
desktopWindow.SetIconFromStream(iconStream);
|
desktopWindow.SetIconFromStream(iconStream);
|
||||||
desktopWindow.Title = Name;
|
desktopWindow.Title = Name;
|
||||||
|
@ -22,9 +22,9 @@ namespace osu.Desktop
|
|||||||
{
|
{
|
||||||
// Back up the cwd before DesktopGameHost changes it
|
// Back up the cwd before DesktopGameHost changes it
|
||||||
var cwd = Environment.CurrentDirectory;
|
var cwd = Environment.CurrentDirectory;
|
||||||
bool useSdl = args.Contains("--sdl");
|
bool useOsuTK = args.Contains("--tk");
|
||||||
|
|
||||||
using (DesktopGameHost host = Host.GetSuitableHost(@"osu", true, useSdl: useSdl))
|
using (DesktopGameHost host = Host.GetSuitableHost(@"osu", true, useOsuTK: useOsuTK))
|
||||||
{
|
{
|
||||||
host.ExceptionThrown += handleException;
|
host.ExceptionThrown += handleException;
|
||||||
|
|
||||||
|
@ -208,7 +208,7 @@ namespace osu.Game.Overlays.Settings.Sections.Graphics
|
|||||||
private IReadOnlyList<Size> getResolutions()
|
private IReadOnlyList<Size> getResolutions()
|
||||||
{
|
{
|
||||||
var resolutions = new List<Size> { new Size(9999, 9999) };
|
var resolutions = new List<Size> { new Size(9999, 9999) };
|
||||||
var currentDisplay = game.Window?.CurrentDisplay.Value;
|
var currentDisplay = game.Window?.CurrentDisplayBindable.Value;
|
||||||
|
|
||||||
if (currentDisplay != null)
|
if (currentDisplay != null)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user