mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 08:52:55 +08:00
Disable relative mode for TournamentGame
This commit is contained in:
parent
bb6e50eb27
commit
d17c431faf
@ -2,18 +2,21 @@
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using System.Drawing;
|
||||
using osu.Framework.Extensions.Color4Extensions;
|
||||
using System.Linq;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Configuration;
|
||||
using osu.Framework.Extensions.Color4Extensions;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Colour;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Graphics.Shapes;
|
||||
using osu.Framework.Graphics.Colour;
|
||||
using osu.Game.Graphics.Cursor;
|
||||
using osu.Game.Tournament.Models;
|
||||
using osu.Framework.Input.Handlers.Mouse;
|
||||
using osu.Framework.Platform;
|
||||
using osu.Game.Graphics;
|
||||
using osu.Game.Graphics.Cursor;
|
||||
using osu.Game.Graphics.UserInterface;
|
||||
using osu.Game.Tournament.Models;
|
||||
using osuTK;
|
||||
using osuTK.Graphics;
|
||||
|
||||
@ -36,7 +39,7 @@ namespace osu.Game.Tournament
|
||||
private LoadingSpinner loadingSpinner;
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
private void load(FrameworkConfigManager frameworkConfig)
|
||||
private void load(FrameworkConfigManager frameworkConfig, GameHost host)
|
||||
{
|
||||
windowSize = frameworkConfig.GetBindable<Size>(FrameworkSetting.WindowedSize);
|
||||
windowMode = frameworkConfig.GetBindable<WindowMode>(FrameworkSetting.WindowMode);
|
||||
@ -48,6 +51,9 @@ namespace osu.Game.Tournament
|
||||
Margin = new MarginPadding(40),
|
||||
});
|
||||
|
||||
var m = (MouseHandler)host.AvailableInputHandlers.Single(t => t is MouseHandler);
|
||||
m.UseRelativeMode.Value = false;
|
||||
|
||||
loadingSpinner.Show();
|
||||
|
||||
BracketLoadTask.ContinueWith(_ => LoadComponentsAsync(new[]
|
||||
|
Loading…
Reference in New Issue
Block a user